diff --git a/src/Intervention/Image/Gd/Commands/ResizeCommand.php b/src/Intervention/Image/Gd/Commands/ResizeCommand.php index 382d9709..e8ef7c75 100644 --- a/src/Intervention/Image/Gd/Commands/ResizeCommand.php +++ b/src/Intervention/Image/Gd/Commands/ResizeCommand.php @@ -44,7 +44,7 @@ class ResizeCommand extends AbstractCommand protected function modify($image, $dst_x, $dst_y, $src_x, $src_y, $dst_w, $dst_h, $src_w, $src_h) { // create new image - $modified = imagecreatetruecolor($dst_w, $dst_h); + $modified = imagecreatetruecolor(intval($dst_w), intval($dst_h)); // get current image $resource = $image->getCore(); @@ -70,8 +70,8 @@ class ResizeCommand extends AbstractCommand $dst_y, $src_x, $src_y, - $dst_w, - $dst_h, + intval($dst_w), + intval($dst_h), $src_w, $src_h );