[thelist] PHP: Image creation on the fly with resizing from UPLOAD file form not always correct.

Ryan Tames rytames at telusplanet.net
Fri Aug 15 03:07:41 CDT 2003


On 9 Aug 2003 at 15:59, Damien COLA wrote:

I'm probally not much help to you, but here it goes anyway...

I've never had the problem personally, except for a simple C
app I coded; however, the problem could be cuased by
not loading the original image file as a Binary (+b) (on windows
systems - unix systems treat all files as 8 byte variants).

Could be a RAM problem too, depending on when it happens.
For example, if the server is heavy loaded at that time. Or
maybe even a floating point error on images that have certain
simularities (in size), and it gets rounded up but the pixel dimensions
don't fit perfectly.

Maybe the image that is uploaded was compressed to much to begin
with, and saving the server side image in various size, and recompression
just cuases way to much data loss, and the image turns out
crappy. On small thumbnail images, you won't see the difference to
much, but larger ones you will.



More information about the thelist mailing list