[Bug Report] Image clips with rotation metadata display incorrectly in wall view and lightbox
Describe the bug In wall view and lightbox, image clips with rotation metadata will be correctly rotated, but their new height and width are not accounted for. E.g. 1920x1080 -> rotated 90 degrees -> 1080x1920
In wall view, this leads to gaps being created around the image clip's preview because Stash is using the unrotated height and width.
In lightbox, this leads to image clips being zoomed in when opened, again because the wrong height and width are being used. (edit 2024-01-01 - the same problem appears in the fullscreen slideshow view)
Here is an example file: https://github.com/stashapp/stash/assets/146701633/8bd7253d-e710-448e-99a3-7a7792cf4f50
To Reproduce Steps to reproduce the behavior:
- Import example file into Stash
- View the file with other images in the Image Tab in Wall View
- While in wall view, open the image in the lightbox view
Stash Version: 0.25.1
Desktop: Windows 10 Chrome 123.0.6312.86
It seems it's related to how the image metadata is extracted and parsed:
- Stash calls
ffprobeto extract the image metadata including height, weight, and rotate -
ffprobedoes not seem to read theOrientationtag of EXIF data to produce therotatemetadata