jeudi 28 mai 2015

Using GD imagecreatefromgd2part for resizing images

I have been using SimpleImage.php for resizing images by URL that are then uploaded to an Aws S3 bucket. I have rewritten a lot of it to support transparencies for PNGs and GIFs but that isn't the issue I am talking about. Everything was working according to plan, until I reach images that are >5mb. Through my research, I have found that it isn't the size of the file that messes with imagecreatefromjpeg, imagecreatefromgif, or imagecreatefrompng, but the actual dimensions of the image itself. I could simiply increase the php memory limits, but I refuse to do this as it is risky in itself.

Long story short, I want to know if I could create images from an URL using imagecreatefromgd2part, resize the chunk, the combine it with other chunks of the same image to get a resized image. Chunking and merging is what I have been using for uploading the actual images to the bucket, now I want to know if it is possible to resize the chunks.




Aucun commentaire:

Enregistrer un commentaire