[image] Supply correct width and height limits to interpolate

The supplied width and height were for the new rather than the old image so
some reads would access pixels beyond the edge of the image.
This commit is contained in:
Charlie Brej 2009-08-11 16:47:37 +01:00
parent 52f9e0eae9
commit 25f5ddeb05

View file

@ -352,7 +352,7 @@ ply_image_resize (ply_image_t *image,
{
old_x = x * scale_x;
new_image->layout.as_pixels[x + y * width] =
ply_image_interpolate (image, width, height, old_x, old_y);
ply_image_interpolate (image, old_width, old_height, old_x, old_y);
}
}
return new_image;