You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
iOS and iPadOS devices now store images as HEIC by default.
As long as "Automatic" or "Most Compatible" is seletect in the browser's upload sheet, the device will convert to JPEG on upload, but if "Current" is selected or the uploader is dragging and dropping from the Photos app on their Mac, an HEIC file will be uploaded and refused.
I also asked @newbold who runs https://some.pics which converts HEIC uploads to JPEG, and he gave permission to share that they use heif-convert as a command line utility:
IMHO, uploaded images should go into our block storage unaltered. I think Fastly would be the way to go for the transformation step. They support HEIC and others. So if we tack ?format=auto to the image URLs, it should just work. We can just increase the mime types we permit to be uploaded for images. So, we can be liberal in what we accept and conservative in what we send. If it is a type of file that we cannot directly handle with Pillow (for making resized 'small', 'thumbnail' variants), we could use Fastly for those as well. I've been thinking about doing just that so we don't have to make those variants at all, but haven't done that yet.
iOS and iPadOS devices now store images as HEIC by default.
As long as "Automatic" or "Most Compatible" is seletect in the browser's upload sheet, the device will convert to JPEG on upload, but if "Current" is selected or the uploader is dragging and dropping from the Photos app on their Mac, an HEIC file will be uploaded and refused.
A big problem with HEIC is that only Safari supports displaying it https://en.wikipedia.org/wiki/High_Efficiency_Image_File_Format#Support so many services simply don't accept it.
A few services do accept HEIC and take on the conversion to JPEG themselves, and maybe MLTSHP could be one of them.
My knowledge in this space is unfortunately limited to just research, but here's how WordPress does HEIC conversion to JPEG on upload:
They experimented with client-side processing but ran into some licensing issues WordPress/gutenberg#61447 but maybe this is something that Fastly could do for us? https://www.fastly.com/documentation/reference/io/
I also asked @newbold who runs https://some.pics which converts HEIC uploads to JPEG, and he gave permission to share that they use heif-convert as a command line utility:
// convert heic/heif if($mime === 'image/heic' || $mime === 'image/heif') { $uploaded_pic_jpg = tempnam("/tmp", "some.pics.jpg."); $convert = shell_exec("heif-convert $uploaded_pic $uploaded_pic_jpg.jpg"); $uploaded_pic = $uploaded_pic_jpg.'.jpg'; $mime = 'image/jpeg'; unlink($uploaded_pic_jpg); }
The text was updated successfully, but these errors were encountered: