#include"hensu.h" void threshold(LPDWORD image_in,LPDWORD image_out,int thresh,int mode) { int x,y,n; for(y=0;y=thresh) image_out[x+y*iWidth]=HIGH; else image_out[x+y*iWidth]=LOW; } } } void histgram(LPDWORD image_in,long hist[256]) { int x,y,n; for(n=0;n<256;n++) hist[n]=0; for(y=0;y255) i=255; sum+=hist_in[i]; } hist_out[n]=(long)(sum/5.0+0.5); } }