Page 1 of 1

AHK 2 Gui Picture images rotated incorrectly

Posted: 07 Feb 2023, 00:10
by fatodubs
I'm working on a script to show images and wait for some input based on the orientation of the image.

The Picture Control, however, is showing the images in their original orientation (I assume) rather than their current orientation. Every other image viewer I have shows them correctly.

I believe the issue is that the images are being rotated by way of an EXIF orientation value, but AHK is ignoring that. The result is that AHK displays the picture incorrectly.

I've attached an image that SHOULD display upside down. In my GUI, it displays sideways.

Re: AHK 2 Gui Picture images rotated incorrectly

Posted: 17 Jun 2023, 22:42
by lexikos
Every other image viewer
I would say that AutoHotkey/Gui Picture isn't an image viewer.
I've attached an image that SHOULD display upside down. In my GUI, it displays sideways.
In my GUI, it displays upside down.

Code: Select all

g := Gui()
g.AddPicture(, "_BlueCase_21_0002.jpg")
g.Show()
I could not find any way to verify that the downloaded image still had an EXIF orientation value, using the software I have installed.

AutoHotkey/Gui/Picture/LoadPicture has no concept of EXIF metadata whatsoever. It just uses OS routines to load an image. It uses OleLoadPicture by default, or GDI+ if you use the AltSubmit option. I see no difference in behaviour between the two.