fix: image flips after stripping orientation exif

rrr-marble 4 years ago
parent ca4cac9c02
commit 6aa2ef112e

@ -47,6 +47,10 @@ def process_pictures():
(k[5:], v) for k, v in image.metadata.items() if k.startswith("exif:") (k[5:], v) for k, v in image.metadata.items() if k.startswith("exif:")
) )
with image.clone() as cloned: with image.clone() as cloned:
# adjust an image so that its orientation is suitable for viewing
# (i.e. top-left orientation) by checking EXIF data
cloned.auto_orient()
# strip an image of all profiles and comments
cloned.strip() # Q: may damage icc, do we allow that or use smh else? cloned.strip() # Q: may damage icc, do we allow that or use smh else?
cloned.transform(resize="50%") # Q: what do we want here? cloned.transform(resize="50%") # Q: what do we want here?
# move them to the processed folder # move them to the processed folder

Loading…
Cancel
Save