Bug fix: Ensure image sizes are rounded. #51

Merged
merged 1 commit into from Sep 16, 2011

Projects

None yet

2 participants

@drzax
Contributor
drzax commented Aug 30, 2011

Bug fix: Ensure image sizes are rounded. The imagecopyresampled function should be provided with integers, not floats.

Resize functions should round the the nearest pixel since pixels aren't divisible. It looks as though the imagecopyresampled function automatically rounds down when supplied with a float, which sometimes results in unwanted whitespace around the resized image.

@drzax drzax Bug fix: Ensure image sizes are rounded. The imagecopyresampled funct…
…ion should be provided with integers, not floats.
3880479
@wilr wilr merged commit c35c48b into silverstripe:master Sep 16, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment