I need to properly display an image depending on it exif image orientation tag.
I adjusted the rotation and flipping of the image for each case in the 8 possible image orientation options (described here)
I tested on the images in here
In Chrome (version 81.0) on Ubuntu 18.04, all image options display properly.
On MacOS and iOS I get different behaviors. Sometimes the images are not displayed properly I read here that the behavior may change depending on the version of the webkit browser engine.
I want to adjust the code to each use case:
- browser (e.g. Chrome, Firefox, Safari)
- engine version (e.g. webkit version < 13.4, webkit version >= 13.4, etc...)
I read here and here that detecting the user agent is usually a bad idea, and that it is better to detect the existence of the feature
In my case, the feature exists in the different versions but the behavior of the agent is different between versions? (I think)
What would be the best way to detect the handling of image orientation (handling of exif imageOrientation tag)
Thanks,
Avner