HomeImagickImagickDrawImagickPixelImagick Pixel IteratorImagick KernelDevelopmentTutorial Source codeReport an issue
Category
Example

Imagick::meanShiftImage

← magnifyImage   medianFilterImage →

Example

function meanShiftImage(
    $image_path,
    int $width,
    int $height,
    float $color_distance
) {
    $imagick = new \Imagick(realpath($image_path));
    $imagick->meanShiftImage(
        $width,
        $height,
        $color_distance * Imagick::getQuantum()
    );
    header("Content-Type: image/jpeg");
    echo $imagick->getImageBlob();
}