Imagick::transformImage

(No version information available, might be only in CVS)

Imagick::transformImage — Convenience method for setting crop size and the image geometry

Описание

Imagick Imagick::transformImage ( string $crop , string $geometry )
Внимание

К настоящему времени эта функция еще не была документирована; для ознакомления доступен только список аргументов.

A convenience method for setting crop size and the image geometry from strings

Список параметров

crop

A crop geometry string. This geometry defines a subregion of the image to crop.

geometry

An image geometry string. This geometry defines the final size of the image.

Возвращаемые значения

Returns TRUE on success.

Примеры

Пример #1 Using Imagick::transformImage():

The example creates a 100x100 black image.

<?php
$image 
= new Imagick();
$image->newImage300200"black" );
$new_image $image->transformImage"100x100""100x100" );
$new_image->writeImage('test_out.jpg');
?>

Коментарии

While working with this function I noticed that it actually returns the image resource (instead of TRUE), so rather than just doing this;

$resource->transformImage('0x0','500x500');

Which would NOT resize $resource. I had to do this;

$resource = $resource->transformImage('0x0','500x500');

Hope this helps!

    Поддержать сайт на родительском проекте КГБ