[Lazarus] TImage shows loaded image rotated by 90?

Marc Weustink marc at dommelstein.nl
Fri Sep 23 14:47:41 CEST 2016


LacaK wrote:
> Hi,
>
> I have JPEG image with width=2448 and height=3264.

No

> All programs in Windows show image with respect to his dimensions, so
> shorter is X and higher is Y.
>
> But when I load this image into TImage control (using Picture property)
> image is shown rotated by 90 degrees, with width=3264 and height=2448

That is correct. If you look at the exif info, you read:

Filename - 6.jpg
...
ImageWidth - 3264
ImageLength - 2448
...
ExifImageWidth - 3264
ExifImageHeight - 2448
...
Orientation - Right top

What you see is the result of "smart" image viewers, which read the exif 
info and read that you held the camera sideways and there fore rotate 
the image.
the image istself is still 3264x2448


Marc




More information about the Lazarus mailing list