applyEffects() public method

Applies any effects in the effect queue.
public applyEffects ( )
Ejemplo n.º 1
0
 private function _roundBorder($image)
 {
     $context = array('tmpdir' => $this->_image->getTmpDir());
     $size = $image->getImageGeometry();
     $new = new Horde_Image_Imagick(array(), $context);
     $new->loadString($image->getImageBlob());
     $image->destroy();
     $new->addEffect('RoundCorners', array('border' => 2, 'bordercolor' => '#111'));
     $new->applyEffects();
     $return = new Imagick();
     $return->newImage($size['width'] + $this->_params['borderwidth'], $size['height'] + $this->_params['borderwidth'], $this->_params['bordercolor']);
     $return->setImageFormat($this->_image->getType());
     $return->clear();
     $return->readImageBlob($new->raw());
     return $return;
 }