@@ -188,7 +188,7 @@ protected function process(string $action)
188188 imagesavealpha ($ dest , true );
189189 }
190190
191- $ copy ($ dest , $ src , 0 , 0 , $ this ->xAxis , $ this ->yAxis , $ this ->width , $ this ->height , $ origWidth , $ origHeight );
191+ $ copy ($ dest , $ src , 0 , 0 , ( int ) $ this ->xAxis , ( int ) $ this ->yAxis , $ this ->width , $ this ->height , $ origWidth , $ origHeight );
192192
193193 imagedestroy ($ src );
194194 $ this ->resource = $ dest ;
@@ -472,9 +472,9 @@ protected function textOverlay(string $text, array $options = [], bool $isShadow
472472 // Add the shadow to the source image
473473 if (! empty ($ options ['fontPath ' ])) {
474474 // We have to add fontheight because imagettftext locates the bottom left corner, not top-left corner.
475- imagettftext ($ src , $ options ['fontSize ' ], 0 , $ xAxis , $ yAxis + $ options ['fontheight ' ], $ color , $ options ['fontPath ' ], $ text );
475+ imagettftext ($ src , $ options ['fontSize ' ], 0 , ( int ) $ xAxis , ( int ) ( $ yAxis + $ options ['fontheight ' ]) , $ color , $ options ['fontPath ' ], $ text );
476476 } else {
477- imagestring ($ src , $ options ['fontSize ' ], $ xAxis , $ yAxis , $ text , $ color );
477+ imagestring ($ src , ( int ) $ options ['fontSize ' ], ( int ) $ xAxis , ( int ) $ yAxis , $ text , $ color );
478478 }
479479
480480 $ this ->resource = $ src ;
0 commit comments