[Gambas-user] Is exif Orientation obtainable without any exif libs/commands?
dickson.tim at googlemail.com
Tue Dec 6 15:30:42 CET 2022
why don't you look at the exif lib (that may not be on a system), and
see how it does it. that should give you a pointer on implementing a
this doc may help.
looks like you need the 0x0112 tag.
On 05/12/2022 17:17, Bruce Steers wrote:
> On Mon, 5 Dec 2022 at 16:20, Rolf-Werner Eilert <rwe-sse at osnanet.de>
> Am 05.12.22 um 17:06 schrieb Bruce Steers:
> > So i've found exiftool is a tool to easily retrieve Orientation
> > 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
> > 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
> > ----[ http://gambaswiki.org/wiki/doc/netiquette ]----
> Without looking in detail, but it should be in different positions
> depending on the file format. So for instance you would have to know
> where and how it is saved in a jpg file, open the file in binary
> and jump to the information. The same with other file formats.
> Or did I get you wrong?
> Yes that's what I'm "suspecting" may be possible.
> Just wondering if anyone has tried and failed, or tried and succeeded ?
> looks like it's possible. I found this page...
> Has something i may be able to convert.
> And plenty to study
> Just hoping someone else might have already looked into it and have
> some working or unfinished code or just information they might share
> on the topic before i have to start at square 1.
> ----[http://gambaswiki.org/wiki/doc/netiquette ]----
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the User