Browse Source

APP_Framework/Framework/:complete ordinary mean_filter

pull/9/head
chunyexixiaoyu 11 months ago
parent
commit
d16c698789
  1. 17
      APP_Framework/Framework/knowing/filter/mean_filter/ordinary_mean_filter.c
  2. 2
      APP_Framework/Framework/knowing/filter/mean_filter/ordinary_mean_filter.h

17
APP_Framework/Framework/knowing/filter/mean_filter/ordinary_mean_filter.c

@ -1 +1,16 @@
#include <ordinary_mean_filter.h>
#include <ordinary_mean_filter.h>
/**
* @description:
* @param {int *} hander array address
* @param {int} len array length
* @return {*}
*/
int OrdinaryMeanFilter(int * hander,int len)
{
int sum = 0;
for(int i = 0;i < len ;i++)
{
sum = sum + *(hander +i);
}
return (int)(sum/len);
}

2
APP_Framework/Framework/knowing/filter/mean_filter/ordinary_mean_filter.h

@ -1,4 +1,4 @@
#ifndef _ORDINARY_MEAN_FILTER_H
#define _ORDINARY_MEAN_FILTER_H
int OrdinaryMeanFilter(int * hander,int len);
#endif
Loading…
Cancel
Save