You are reading a single comment by @salad and its replies. Click here to read the full conversation.
  • Images are rotated by the server according to the EXIF information in the image, specifically the FlipDirection:

    • TopLeftSide = 1
    • TopRightSide = 2
    • BottomRightSide = 3
    • BottomLeftSide = 4
    • LeftSideTop = 5
    • RightSideTop = 6
    • RightSideBottom = 7
    • LeftSideBottom = 8

    If the EXIF is absent we leave the image alone.

    The EXIF may be absent, for example if the phone is not calibrated (the sensor that determines rotation, orientation, etc).

    I did some data thing on this a while ago to see whether this code was still needed. Some 95% of images provide it.

    If it is there... we rotate the image. If it is not, we leave it alone. Looking at the raw images that were uploaded it was not there.

    Were these images processed by some other program first?

  • If the EXIF is absent

    When one uploads an image as an attachement here it gets stripped of its EXIF

  • When one uploads an image as an attachement here it gets stripped of its EXIF

    Not true.

    When one downloads or views an image on this site the image is optimised for delivery and then the EXIF is stripped.

    But the upload is intact. During upload we rotate if necessary and then put it in Amazon S3, and on download it runs through Cloudflare Polish and EXIF is removed, and if you are using a .webp compatible browser it's converted to .webp.

    We optimise the download, not the upload.

About

Avatar for salad @salad started