array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'de', ), 'this' => array ( 0 => 'imagick.whitethresholdimage.php', 1 => 'Imagick::whiteThresholdImage', 2 => 'Force all pixels above the threshold into white', ), 'up' => array ( 0 => 'class.imagick.php', 1 => 'Imagick', ), 'prev' => array ( 0 => 'imagick.waveimage.php', 1 => 'Imagick::waveImage', ), 'next' => array ( 0 => 'imagick.writeimage.php', 1 => 'Imagick::writeImage', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/imagick/imagick/whitethresholdimage.xml', ), 'history' => array ( ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); contributors($setup); ?>

Imagick::whiteThresholdImage

(PECL imagick 2, PECL imagick 3)

Imagick::whiteThresholdImageForce all pixels above the threshold into white

Beschreibung

public Imagick::whiteThresholdImage(mixed $threshold): bool

Is like Imagick::ThresholdImage() but force all pixels above the threshold into white while leaving all pixels below the threshold unchanged.

Parameter-Liste

threshold

Rückgabewerte

Liefert true bei Erfolg.

Changelog

Version Beschreibung
PECL imagick 2.1.0 Now allows a string representing the color as a parameter. Previous versions allow only an ImagickPixel object.

Beispiele

Beispiel #1 Imagick::whiteThresholdImage()

<?php
function whiteThresholdImage($imagePath, $color) {
$imagick = new \Imagick(realpath($imagePath));
$imagick->whiteThresholdImage($color);
header("Content-Type: image/jpg");
echo
$imagick->getImageBlob();
}

?>