background | mixed | The background color |
x_shear | float | The number of degrees to shear on the x axis |
y_shear | float | The number of degrees to shear on the y axis |
function shearImage($imagePath, $color, $shearX, $shearY) { $imagick = new \Imagick(realpath($imagePath)); $imagick->shearimage($color, $shearX, $shearY); header("Content-Type: image/jpg"); echo $imagick->getImageBlob(); }