[Gambas-user] Is exif Orientation obtainable without any exif libs/commands?

Bruce Steers bsteers4 at gmail.com
Mon Dec 5 17:06:25 CET 2022


So i've found exiftool is a tool to easily retrieve Orientation flag from
an image but it's not on all systems, not by default at least.

Was wondering if anyone has a method to retrieve exif flags from an image
or the Orientation one at least?

I found rotating and saving an image back to file removed it's Orientation
flag so that's cool.

But I also found that to save a similar size file back i needed an
instruction like...
hPicture.Save(sPath, 92)

I had to play with the quality value and found 92 about the right value for
a similar size file.
Wondered if there was a better way to save the image back with identical
file size (i assume a rotated image to be the same mass/size)

Ultimately I'm looking to spin my images round to be correct way up with
zero quality change.

The only piece of the puzzle gambas seems to lack is detecting the exif
Orientation flag.
Something in my mind suspects gambas Read could possibly be able to get the
data from the files?

Respects
BruceS
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20221205/deade380/attachment.htm>


More information about the User mailing list