diff --git a/t3lib/class.t3lib_stdgraphic.php b/t3lib/class.t3lib_stdgraphic.php index e3d1db2..1379c41 100644 --- a/t3lib/class.t3lib_stdgraphic.php +++ b/t3lib/class.t3lib_stdgraphic.php @@ -274,7 +274,6 @@ class t3lib_stdGraphic { // preserve alpha transparency if ($this->saveAlphaLayer) { - imagealphablending($destImg, FALSE); imagesavealpha($destImg, TRUE); $Bcolor = imagecolorallocatealpha($destImg, 0, 0, 0, 127); imagefill($destImg, 0, 0, $Bcolor); @@ -292,7 +291,6 @@ class t3lib_stdGraphic { $cpImg = $this->imageCreateFromFile($BBmask[3]); $destImg = imagecreatetruecolor($w, $h); if ($this->saveAlphaLayer) { - imagealphablending($destImg, FALSE); imagesavealpha($destImg, TRUE); $Bcolor = imagecolorallocatealpha($destImg, 0, 0, 0, 127); imagefill($destImg, 0, 0, $Bcolor); @@ -439,6 +437,11 @@ class t3lib_stdGraphic { function imagecopyresized(&$im, $cpImg, $Xstart, $Ystart, $cpImgCutX, $cpImgCutY, $w, $h, $w, $h) { if ($this->imagecopyresized_fix) { $im_base = imagecreatetruecolor(imagesx($im), imagesy($im)); // Make true color image + if ($this->saveAlphaLayer) { + $transparentColor = imagecolorallocatealpha($im_base, 0, 0, 0, 127); + imagefill($im_base, 0, 0, $transparentColor); + imagesavealpha($im_base, TRUE); + } imagecopyresized($im_base, $im, 0, 0, 0, 0, imagesx($im), imagesy($im), imagesx($im), imagesy($im)); // Copy the source image onto that imagecopyresized($im_base, $cpImg, $Xstart, $Ystart, $cpImgCutX, $cpImgCutY, $w, $h, $w, $h); // Then copy the $cpImg onto that (the actual operation!) $im = $im_base; // Set pointer @@ -2829,7 +2832,6 @@ class t3lib_stdGraphic { if (function_exists('imagecreatefrompng')) { $imageHandle = imageCreateFromPng($sourceImg); if ($this->saveAlphaLayer) { - imagealphablending($imageHandle, FALSE); imagesavealpha($imageHandle, TRUE); } return $imageHandle; diff --git a/typo3/sysext/cms/tslib/class.tslib_gifbuilder.php b/typo3/sysext/cms/tslib/class.tslib_gifbuilder.php index 7c88aef..6836911 100644 --- a/typo3/sysext/cms/tslib/class.tslib_gifbuilder.php +++ b/typo3/sysext/cms/tslib/class.tslib_gifbuilder.php @@ -378,7 +378,6 @@ class tslib_gifBuilder extends t3lib_stdGraphic { && (empty($this->setup['format']) || $this->setup['format'] === 'png')) { // Set transparency properties - imagealphablending($this->im, FALSE); imagesavealpha($this->im, TRUE); // Fill with a transparent background