corrected wrong position of declaration for variables in some magic tools.

This commit is contained in:
Shin-ichi TOYAMA 2009-05-26 15:00:26 +00:00
parent 7403371265
commit 82a232dca8
7 changed files with 26 additions and 22 deletions

View file

@ -139,6 +139,7 @@ static void do_sharpen_pixel(void * ptr, int which,
int grey;
int i,j;
double sobel_1=0,sobel_2=0;
double temp;
//Sobel weighting masks
const int sobel_weights_1[3][3] = { {1,2,1},
@ -160,7 +161,7 @@ static void do_sharpen_pixel(void * ptr, int which,
}
}
double temp = sqrt(sobel_1*sobel_1 + sobel_2*sobel_2);
temp = sqrt(sobel_1*sobel_1 + sobel_2*sobel_2);
temp = (temp/1443)*255.0;
// set image to white where edge value is below THRESHOLD