Hy,
The object dt_lua_image_t does’nt have any information to know if the image is in portrait mode.
Is there any other object to query to get that information ?
Hy,
The object dt_lua_image_t does’nt have any information to know if the image is in portrait mode.
Is there any other object to query to get that information ?
maybe there is an API for getting width and height and then you can check which side is longer?
remember to handle x==y
Thanks for your proposition. Unfortunalety this doesn’t work with the photo I have.
All photos are given a size of 5792x3804 whether they are in landscape mode or in portrait mode.
That was also my first guess but it’s not working that way.
maybe check the exif table if your camera stored some information about it?
On the UI, it’s possible to filter by aspect ratio. Is that perhaps available as a tag? (I’m not at the computer now, cannot check. Also, even if it is a tag, it’s a ‘virtual’ one, I guess, not one of the regular tags attached to the image in the DB and stored in the XMP file).
Checking the exif table is a last resort solution. It will require launching exiftool or something like that to collect information. This information is already present in dartkable.
It will be a much slower process.
aspect ratio is also an information that is not available in lua dt_lua_image_t.