mesosoi / silverwaregames-io-issue-tracker

Issue Tracker for SilverwareGames.io
https://silverwaregames.io
4 stars 1 forks source link

Posts on mobile don't orient correctly sometimes. #221

Open michaelplzno opened 11 months ago

michaelplzno commented 11 months ago
image
mesosoi commented 11 months ago

Most of the photos taken from phone display like that on all platforms. Discord is among these apps where I experienced this problem, too. I don't know why. Maybe it's a bug or a feature of built-in PHP image library.

michaelplzno commented 11 months ago

I'll look into some articles on this issue. 😎

On Fri, Dec 1, 2023 at 10:39 AM mesosoi @.***> wrote:

Most of the photos taken from phone display like that on all platforms. Discord is among these apps where I experienced this problem, too. I don't know why. Maybe it's a bug or a feature of built-in PHP image library.

— Reply to this email directly, view it on GitHub https://github.com/mesosoi/silverwaregames-io-issue-tracker/issues/221#issuecomment-1836323826, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAUK4BON2R4XEBWNJ7LP4LLYHH22TAVCNFSM6AAAAABAC7EUH2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMZWGMZDGOBSGY . You are receiving this because you authored the thread.Message ID: @.*** com>

michaelplzno commented 10 months ago

Can you give me some more info on what functions you are using to process and load the images so I can look this up better?

mesosoi commented 9 months ago

Can you give me some more info on what functions you are using to process and load the images so I can look this up better?

I found the potential reason of why is it happening: some phones don't rotate photos taken from an angle different from the default one, but rather save it as regular photos and store the angle in EXIF data. Mobile software handles such metadata and rotates these photos back juts fine, but PHP-GD either ignores this value or resets it to zero. Tried to explain it as easy as possible. There's a potential solution for this I found and going to try in this update.

mesosoi commented 9 months ago

Also, there's no such a bug as "while I post in your post" mentioned on the screenshot, or at least I've never stumbled upon it and don't know how to reproduce it.

michaelplzno commented 9 months ago

I'm not sure why I wrote "while I post in your post" that's a weird line.