X-Git-Url: https://www.fleuret.org/cgi-bin/gitweb/gitweb.cgi?a=blobdiff_plain;f=rich_image.cc;h=61b7a8406ea7969667fb987d36bd43f8e7c33697;hb=71a84ea2658cd96726bcf4e582010c24bf2583cf;hp=f3b4b5465652b54a596890a53e96ca359dcc310f;hpb=d922ad61d35e9a6996730bec24b16f8bf7bc426c;p=folded-ctf.git diff --git a/rich_image.cc b/rich_image.cc index f3b4b54..61b7a84 100644 --- a/rich_image.cc +++ b/rich_image.cc @@ -12,7 +12,9 @@ // You should have received a copy of the GNU General Public License // // along with this program. If not, see . // // // -// Written by Francois Fleuret, (C) IDIAP // +// Written by Francois Fleuret // +// (C) Idiap Research Institute // +// // // Contact for comments & bug reports // /////////////////////////////////////////////////////////////////////////// @@ -88,7 +90,7 @@ void RichImage::compute_one_scale_edge_maps(int width, int height, } } - const unsigned int var_square_size = 16; + const int var_square_size = 16; int k00 = - 2 + width * (- 2); int k01 = - 1 + width * (- 2); @@ -148,13 +150,13 @@ void RichImage::compute_one_scale_edge_maps(int width, int height, y - int(var_square_size/2) >= 0 && y + int(var_square_size/2) < height) { - unsigned int s = + int s = + local_sum_pixel_map[ - var_square_size/2 + width * ( - var_square_size / 2)] + local_sum_pixel_map[ + var_square_size/2 + width * ( + var_square_size / 2)] - local_sum_pixel_map[ - var_square_size/2 + width * ( + var_square_size / 2)] - local_sum_pixel_map[ + var_square_size/2 + width * ( - var_square_size / 2)]; - unsigned int s_sq = + int s_sq = + local_sum_sq_pixel_map[ - var_square_size/2 + width * ( - var_square_size / 2)] + local_sum_sq_pixel_map[ + var_square_size/2 + width * ( + var_square_size / 2)] - local_sum_sq_pixel_map[ - var_square_size/2 + width * ( + var_square_size / 2)] @@ -384,11 +386,6 @@ void RichImage::compute_rich_structure() { delete[] scale_pixel_maps; } -void RichImage::crop(int xmin, int ymin, int width, int height) { - free(); - Image::crop(xmin, ymin, width, height); -} - RichImage::RichImage() : Image() { _width_at_scale = 0; _height_at_scale = 0;