friendica.mbbit.de

Image upload distortes portraits to landscapes

@Friendica Developers @Friendica Developers

Please see here:


Yet another photo test, should all be PORTRAIT!


Please click on any image to confirm that they are portraits


1
utzer [Friendica] friendica (via ActivityPub)
@Marek Bachmann @Friendica Entwickler Marek is it from an iPhone, I can remember that iPhones often have the wrong orientation of the photo, I had this a lot with photos my sister send me by Signal. She has an iPhone.
1
Thanks for bringing this up, but it is not from an IPhone.
I guess it is an issue in our backend introduced eventually between last stable a current develop since on the last stable the problem does not occur, cf.
https://friendica.mbbit.de/photos/marek/album/7363616c6554657374 (current dev) and
https://kassel.social/photos/marek/album/7363616c6554657374 (stable)
1 1
Please review my shared dev post directly
https://friendica-dev.mbbit.de/display/fa8fe840-1863-ab4b-5219-e24583154924

directly to see additional issue description.
1
Tio friendica (via ActivityPub)
They are portraits for me when I click them. Desktop + Browser. My instance uses the Frio theme + some custom CSS on top that should not affect how these photos are displayed. idk if that's the sort of input you were looking for.
3 1
Hypolite Petovan friendica (via ActivityPub)
@Tio @Marek Bachmann @Friendica Entwickler Marek It looks like the smaller thumbnails are generated with the wrong orientation.
1 1
Tio friendica (via ActivityPub)
This is how they look for me:

They are squashed into a square shape. But when I click them they look proper:
1 1
Thank you very much. As @Hypolite Petovan mentioned, it is high likely that something goes wrong with the small thumbnail generation.

What would also help me if this someone else / other instances face this issue.
Instances need to run on the latest dev branch, since in the current stable I do not face this issue neither.

So if someone on a dev instance might try to upload a portrait photo and tell me if the problem also occurs, I will create a new issue for this phenom on git.
1
@Hypolite Petovan a general question which surely is in the scope of your expertise: Is there some method in git to check when a specific method / code block was last changed by a commit?
In this specific case, I would like to check when and what was changed in the Images::getScalingDimensions($width, $height, 90); method to confirm / rule out being the cause of this bug.
1
Hypolite Petovan friendica (via ActivityPub)
@Marek Bachmann Yes, it’s called git blame, although I’ve never used it in command line. In PHPStorm, it’s called “Annotate with git blame”.
1 1
Wow, what a cool function. Tested it in PHPStorm. It really tells me for any line which commit changed this line.
1 1
Just the name "blame" is a little rude :-D From this function's perspective, you are "to blame" for many code lines ;-)
1 1
Hypolite Petovan friendica (via ActivityPub)
@Marek Bachmann It’s a common criticism of the name of the feature, several alternatives have been suggested but there’s little chance any of them will be adopted.
1 1