Aspect ratio problem with pictures from my cell phone

35 views
Skip to first unread message

Lord Beowulf

unread,
Oct 7, 2022, 9:05:19 AM10/7/22
to Gallery 3 Users
Hi All,

I've never seen this before, but I created a gallery folder of pictures I'd taken from my Samsung Galaxy S21 and all of the portrait images are causing problems.  It's apparent that the files are still raster scanned in the landscape direction, which I suspect is the issue, and are just flagged internally for the rotation.  You can tell that when the full size image downloads slowly from my website and it fills in from the left or right instead of the top.  Thus, what I'm getting are thumbnails and full sized views that are squashed to the landscape aspect ratio, while the resized image on the gallery page has been chopped off.  If I right click on each of the images and view in a new tab, they are actually correct, so it's simply that Gallery thinks they're a different size than they are.  I loaded these using Server Add in 3.1.0, so it's possible the bug is there, but who knows.  I've upgraded to 3.1.5 with no improvement.  I suspect I can manually edit the database, but I'd like an easier fix!  Any ideas?

Thanks,

Beo

mikt...@hotmail.com

unread,
Oct 8, 2022, 6:25:08 AM10/8/22
to Gallery 3 Users
Beo,

Try loading and activating the "autorotate" module and then re upload them. The module runs when photos are uploaded to set them right and works very well with Apple photos that show upside-down, see if it fixes the Samsung ones.
I use it on both of these sites.


Tony

Lord Beowulf

unread,
Oct 8, 2022, 7:56:19 AM10/8/22
to Gallery 3 Users
Hi Tony,

I already have it.  I suspect it may be related to this statement in the Wiki:

  • It appears that on some hosted accounts (hostgator is the only instance I have knowledge of now), the rotation of large images will fail. See this ticket and this post in the forums. If anyone has further insight, please update one of those two locations.
The odd thing is that swapping the numbers in the database fixes it, so there should be no need to rotate these images.  The browser displays them properly as long as the correct information is in the correct field in the database.

J.R.

unread,
Oct 8, 2022, 2:39:51 PM10/8/22
to gallery...@googlegroups.com
Beo,

Is there only one location in the database where the dimensions of uploaded images are stored?

-- J.R.
--
WHEN USING AN EMAIL PROGRAM to reply to this message, click REPLY TO LIST or REPLY TO ALL so your reply goes out to everyone in the group. If you click REPLY or REPLY TO SENDER Google will *only* send your reply to the original author (not recommended).
 
To post a NEW MESSAGE to the group, send an new email to:
gallery...@googlegroups.com
 
To view or sign in to this group on the web, use this URL:
https://groups.google.com/forum/#!forum/gallery-3-users
---
You received this message because you are subscribed to the Google Groups "Gallery 3 Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gallery-3-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gallery-3-users/7b80fe60-3734-4cca-8371-a7cfbfeb7555n%40googlegroups.com.

Lord Beowulf

unread,
Oct 14, 2022, 7:01:26 PM10/14/22
to Gallery 3 Users
There are actually three different dimensions; the actual picture, the resized image (always 640x??) and the thumbnail (always 200x??).  If I just swap all three sets of numbers on the portrait images, everything looks right.  I'd need to look into the auto-rotate module to see what it's supposed to be doing, but I'm suspecting it's failing and the database doesn't match the image or something.  Chrome still displays properly, so I don't know that the forced rotation is necessary.  I might try disabling the module and see what happens.  On the other hand, if the browser reads the EXIF data to display but Gallery ignores it in setting up the page, that would explain it too, again under the assumption that the auto-rotate module is failing.  Presumably there was a reason for it to exist, so that seems logical.  On the other hand, it seems that it would have been easier to just make Gallery set up the database correctly in the first place.  There are a number of potential ways to address this and I'll probably work on a fix if I keep seeing this, but not today!  =)

Thanks,

Beo

Miktrain _

unread,
Oct 15, 2022, 2:06:58 AM10/15/22
to gallery...@googlegroups.com
Beo,
The resize can be set in the settings/advanced, mine is set to 800.
The thumbnail can also be set on the same page but l have not changed mine.
Just click on the number and enter the size you want.


Tony

From: gallery...@googlegroups.com <gallery...@googlegroups.com> on behalf of Lord Beowulf <mdf...@foegelle.net>
Sent: Saturday, October 15, 2022 9:31:26 AM
To: Gallery 3 Users <gallery...@googlegroups.com>
Subject: Re: [gallery-3-users] Re: Aspect ratio problem with pictures from my cell phone
 
You received this message because you are subscribed to a topic in the Google Groups "Gallery 3 Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/gallery-3-users/GU4ktAZTEKE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to gallery-3-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gallery-3-users/66dd39ae-6e1b-46c4-a623-42065484eacen%40googlegroups.com.

Lord Beowulf

unread,
Jan 3, 2023, 8:42:50 AM1/3/23
to Gallery 3 Users
Hi All:

So I'm still having this problem with G3 getting the dimensions in the database backwards.  I'm using ServerAdd because (as usual) the images are too big to upload directly.  Not sure if it's in the ServerAdd module vs. a general problem.  Screenshot 2023-01-03 072137.jpg
Screenshot 2023-01-03 072225.jpg

Screenshot 2023-01-03 072317.jpg

You can see the problem in the database.  All of the pictures have height and width in landscape orientation. 

Screenshot 2023-01-03 073040.jpg
If I flip the width and height in the database for each version (resize, thumb, and full) then they'll display correctly.

Screenshot 2023-01-03 073332.jpg
Screenshot 2023-01-03 073355.jpg


Thanks,

Beo
Reply all
Reply to author
Forward
0 new messages