Force all pixels above the threshold into white
$threshold
Is like Imagick::ThresholdImage() but force all pixels above the threshold into white while leaving all pixels below the threshold unchanged.
threshold
Returns true on success.
true
Example #1 Imagick::whiteThresholdImage
<?php function whiteThresholdImage($imagePath, $color) { $imagick = new \Imagick(realpath($imagePath)); $imagick->whiteThresholdImage($color); header("Content-Type: image/jpg"); echo $imagick->getImageBlob(); } ?>