Imagick::resampleImage

(PECL imagick 2.0.0)

Imagick::resampleImageResample image to desired resolution

Descrierea

Imagick::resampleImage ( float $x_resolution , float $y_resolution , int $filter , float $blur ) : bool

Resample image to desired resolution.

Parametri

x_resolution

y_resolution

filter

blur

Valorile întoarse

Întoarce TRUE în caz de succes.

Exemple

Example #1 Imagick::resampleImage()

<?php
function resampleImage($imagePath) {
    
$imagick = new \Imagick(realpath($imagePath));

    
$imagick->resampleImage(200200, \Imagick::FILTER_LANCZOS1);
    
header("Content-Type: image/jpg");
    echo 
$imagick->getImageBlob();
}

?>