diff --git a/src/Drivers/Gd/Color.php b/src/Drivers/Gd/Color.php index 351072bd..a7ef9a53 100644 --- a/src/Drivers/Gd/Color.php +++ b/src/Drivers/Gd/Color.php @@ -54,4 +54,9 @@ class Color extends AbstractColor implements ColorInterface return [$r, $g, $b, $a]; } + + public function toInt(): int + { + return $this->value; + } } diff --git a/src/Drivers/Gd/Modifiers/FillModifier.php b/src/Drivers/Gd/Modifiers/FillModifier.php index c2eb41d8..8306e762 100644 --- a/src/Drivers/Gd/Modifiers/FillModifier.php +++ b/src/Drivers/Gd/Modifiers/FillModifier.php @@ -24,7 +24,7 @@ class FillModifier implements ModifierInterface $filling = $this->getApplicableFilling(); foreach ($image as $frame) { - imagefilledrectangle($frame->getCore(), 0, 0, $width - 1, $height - 1, $filling); + imagefilledrectangle($frame->getCore(), 0, 0, $width - 1, $height - 1, $filling->toInt()); } return $image;