imagescale
(PHP 5 >= 5.5.0, PHP 7, PHP 8)
imagescale — Scale an image using the given new width and height
Description
Note:
Unlike many of other image functions, imagescale() does
not modify the passed image; instead, a
new image is returned.
Return Values
Return the scaled image object on success or false on failure.
Errors/Exceptions
Throws a ValueError if width
or height would cause over-/underflow.
Throws a ValueError if mode is invalid.