Exiftran for seamless photos rotations #363
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi,
I implemented the option to rotate the photos accordingly to their exif tags using
exiftran
(which does lossless rotation, as a plus). The rotation is done once for all when the photo is uploaded.Changes:
Image.php
: I added the code in Image.php to handle the rotationAdminUpload.php
: one function call just below the video conversion callSettings.php
: Added settings configurationdefault.ini
: added the new stringsDockerfile
for both docker images are updated with the new dependency (exiftran, indeed)Use case:
I share the folder
Photos
with adlna
server which is not able to rotate the photos for the players.Plus, in my setup the patch in #312 (in #322) does not seem to work at all.
I am by no means a php programmer, but I hope my code is good enough to be merged.
Let me know your comments :)