raw() public method

Returns the raw data for this image.
public raw ( boolean $convert = false ) : string
$convert boolean Ignored for imagick driver.
return string The raw image data.
Esempio 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;
 }