Skip to content

Commit

Permalink
BUGFIX: Strip image to prevent wrong orientation information in exif …
Browse files Browse the repository at this point in the history
…data
  • Loading branch information
dlubitz committed Mar 14, 2024
1 parent 12c5ac3 commit 6b5e4fb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Neos.Media/Classes/Domain/Service/ImageService.php
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,9 @@ public function processImage(PersistentResource $originalResource, array $adjust
$imagineImage->usePalette(new RGB());
}

$stripFilter = new \Imagine\Filter\Basic\Strip();
$stripFilter->apply($imagineImage);

if ($this->imagineService instanceof Imagine && $originalResource->getFileExtension() === 'gif' && $this->isAnimatedGif(file_get_contents($resourceUri)) === true) {
$imagineImage->layers()->coalesce();
$layers = $imagineImage->layers();
Expand Down

0 comments on commit 6b5e4fb

Please sign in to comment.