So, after years of not understanding exactly why my image resizing script for uploaded images was crashing, I finally get it (after reading through a forum which gave the few extra hints I was missing). I thought it was a problem caused by the size of the photo, in bytes, being uploaded, but now realize that when PHP loads an image as a variable it loads it like a bitmap, so 2048x2048x24 bits = 12.6 MB of variable memory alone (if that is wrong at any point, please tell me!).
After finally getting that, I still haven't solved my problem. Does anyone know of a way to keep an image compressed in any way (like how a JPEG compresses the image) for resizing, or of any stand alone scripts that will resize larger images through php? Any insight would be greatly appreciated!
Compressing Images
Moderator: General Moderators
Re: Compressing Images
PHP has to have the image as a bitmap prior any processing of its data.
Simply, you can't (or it's too difficult to) process the image in the compressed domain (i.e. JPEG, GIF, etc. binary file), you have to process it in the spatial domain (i.e. bitmap).
Simply, you can't (or it's too difficult to) process the image in the compressed domain (i.e. JPEG, GIF, etc. binary file), you have to process it in the spatial domain (i.e. bitmap).
There are 10 types of people in this world, those who understand binary and those who don't
Re: Compressing Images
I had a feeling that might be the answer... Thanks though!