From e6ab9ee3b32cf368f213085e5c66971252fc458e Mon Sep 17 00:00:00 2001 From: Marcin Kurczewski Date: Mon, 10 Nov 2014 09:03:09 +0100 Subject: [PATCH] Improved transparency appearance in JPG thumbnails --- src/Services/ImageManipulation/ImagickImageManipulator.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Services/ImageManipulation/ImagickImageManipulator.php b/src/Services/ImageManipulation/ImagickImageManipulator.php index 0469227d..c6fee9d8 100644 --- a/src/Services/ImageManipulation/ImagickImageManipulator.php +++ b/src/Services/ImageManipulation/ImagickImageManipulator.php @@ -44,6 +44,8 @@ class ImagickImageManipulator implements IImageManipulator switch ($format) { case self::FORMAT_JPEG: + $imageResource->setImageBackgroundColor('white'); + $imageResource = $imageResource->flattenImages(); $imageResource->setImageFormat('jpeg'); break;