mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
Merge pull request #3400 from jedateach/fixes/imagick-crop-notice
FIX: Image_Backend -> croppedResize function doesn't include a backgroundColor
This commit is contained in:
commit
ef272be0db
@ -247,12 +247,8 @@ class ImagickBackend extends Imagick implements Image_Backend {
|
||||
return $this;
|
||||
}
|
||||
|
||||
if(!$backgroundColor){
|
||||
$backgroundColor = new ImagickPixel('transparent');
|
||||
}
|
||||
|
||||
$new = clone $this;
|
||||
$new->setBackgroundColor($backgroundColor);
|
||||
$new->setBackgroundColor(new ImagickPixel('transparent'));
|
||||
|
||||
if(($geo['width']/$width) < ($geo['height']/$height)){
|
||||
$new->cropImage($geo['width'], floor($height*$geo['width']/$width),
|
||||
|
Loading…
x
Reference in New Issue
Block a user