0

We use S3 storage for hosting our photos. There is a feature on our client that allows to put some masks on the image and send it to S3 to update it.

The problem is that when you initially download a photo it weights about 300kb, but when you do canvas.toBlob and send it on the S3 it weights about 1.5mb. How can I cope with this problem?

egovar
  • 1
  • https://stackoverflow.com/questions/14672746/how-to-compress-an-image-via-javascript-in-the-browser? – Andy Oct 20 '21 at 05:54
  • @Andy okay, will talk to our backend developers. The problem is I do not know whether s3 allows to decode dataURL or we will have to make a middleware for this – egovar Oct 20 '21 at 23:09
  • @Andy the other problem is that there are some "resize" actions, but it seems that we can save the file lossless just changing the encoding – egovar Oct 21 '21 at 04:34

0 Answers0