本文整理匯總了PHP中imagick::distortImage方法的典型用法代碼示例。如果您正苦於以下問題:PHP imagick::distortImage方法的具體用法?PHP imagick::distortImage怎麽用?PHP imagick::distortImage使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類imagick
的用法示例。
在下文中一共展示了imagick::distortImage方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: imagejpeg
}
//Waving the image
$x = 0;
$y = 0;
$period = 10;
wave_image($image, $x, $y, $image_width, $image_height, $amplitude);
// Create the image and save it to a temporary file
imagejpeg($image, $name);
// Create a new image from the created one using this time ImageMagick function
$image = new imagick($name);
$image->setImageFormat('png');
$image->setImageVirtualPixelMethod(Imagick::VIRTUALPIXELMETHOD_TRANSPARENT);
// Perspective points
$points = array(0, 0, 0, 0, 0, 90, 0, 90, 90, 0, 90, 0, 90, 90, 90, 65);
// Distorte the image
$image->distortImage(Imagick::DISTORTION_PERSPECTIVE, $points, TRUE);
// Print the new image
echo $image;
// Delete the last image
unlink($name);
} else {
if ($_GET['lvl'] === "Captcha_with_3D_radius" and !empty($_GET['text'])) {
$parts = str_split($text, 15);
// If the number of characters is higher than 15, then divide it after each 15 characters counted
set_time_limit(0);
header('Content-type: image/gif');
require 'Text3D.class.php';
require 'GIFEncoder.class.php';
$j = 0;
$k = 0;
if (strlen($text) > 15 and strlen($text) < 25) {