- Phalcon\Image\Adapter\AbstractAdapter
- Phalcon\Image\Adapter\AdapterInterface
- Phalcon\Image\Adapter\Gd
- Phalcon\Image\Adapter\Imagick
- Phalcon\Image\Enum
- Phalcon\Image\Exception
- Phalcon\Image\ImageFactory
Abstract Class Phalcon\Image\Adapter\AbstractAdapter
| Namespace | Phalcon\Image\Adapter | | Uses | Phalcon\Image\Enum, Phalcon\Image\Exception | | Implements | AdapterInterface |
Phalcon\Image\Adapter
All image adapters must use this class
Properties¶
//
protected static checked = false;
//
protected file;
/**
* Image height
*
* @var int
*/
protected height;
//
protected image;
/**
* Image mime type
*
* @var string
*/
protected mime;
//
protected realpath;
/**
* Image type
*
* Driver dependent
*
* @var int
*/
protected type;
/**
* Image width
*
* @var int
*/
protected width;
Methods¶
Set the background color of an image Blur imagepublic function crop( int $width, int $height, int $offsetX = null, int $offsetY = null ): AdapterInterface;
public function liquidRescale( int $width, int $height, int $deltaX = int, int $rigidity = int ): AbstractAdapter;
public function reflection( int $height, int $opacity = int, bool $fadeIn = bool ): AdapterInterface;
public function resize( int $width = null, int $height = null, int $master = static-constant-access ): AdapterInterface;
public function text( string $text, mixed $offsetX = bool, mixed $offsetY = bool, int $opacity = int, string $color = string, int $size = int, string $fontfile = null ): AdapterInterface;
public function watermark( AdapterInterface $watermark, int $offsetX = int, int $offsetY = int, int $opacity = int ): AdapterInterface;
Interface Phalcon\Image\Adapter\AdapterInterface
| Namespace | Phalcon\Image\Adapter | | Uses | Phalcon\Image\Enum |
This file is part of the Phalcon Framework.
(c) Phalcon Team team@phalcon.io
For the full copyright and license information, please view the LICENSE.txt file that was distributed with this source code.
Methods¶
public function crop( int $width, int $height, int $offsetX = null, int $offsetY = null ): AdapterInterface;
public function reflection( int $height, int $opacity = int, bool $fadeIn = bool ): AdapterInterface;
public function resize( int $width = null, int $height = null, int $master = static-constant-access ): AdapterInterface;
public function text( string $text, int $offsetX = int, int $offsetY = int, int $opacity = int, string $color = string, int $size = int, string $fontfile = null ): AdapterInterface;
public function watermark( AdapterInterface $watermark, int $offsetX = int, int $offsetY = int, int $opacity = int ): AdapterInterface;
Class Phalcon\Image\Adapter\Gd
| Namespace | Phalcon\Image\Adapter | | Uses | Phalcon\Image\Enum, Phalcon\Image\Exception | | Extends | AbstractAdapter |
This file is part of the Phalcon Framework.
(c) Phalcon Team team@phalcon.io
For the full copyright and license information, please view the LICENSE.txt file that was distributed with this source code.
Properties¶
Methods¶
protected function processText( string $text, int $offsetX, int $offsetY, int $opacity, int $r, int $g, int $b, int $size, string $fontfile );
protected function processWatermark( AdapterInterface $watermark, int $offsetX, int $offsetY, int $opacity );
Class Phalcon\Image\Adapter\Imagick
| Namespace | Phalcon\Image\Adapter | | Uses | Phalcon\Image\Enum, Phalcon\Image\Exception | | Extends | AbstractAdapter |
Phalcon\Image\Adapter\Imagick
Image manipulation support. Allows images to be resized, cropped, etc.
$image = new \Phalcon\Image\Adapter\Imagick("upload/test.jpg");
$image->resize(200, 200)->rotate(90)->crop(100, 100);
if ($image->save()) {
echo "success";
}
Properties¶
Methods¶
\Phalcon\Image\Adapter\Imagick constructor Destroys the loaded image to free up resources. Checks if Imagick is enabled Get instance Sets the limit for a particular resource in megabytes@link https://php.net/manual/ru/imagick.constants.php#imagick.constants.resourcetypes
Execute a background. Blur image Execute a crop. Execute a flip. This method scales the images using liquid rescaling method. Only support Imagick Composite one image onto another Pixelate image Execute a reflection. Execute a render. Execute a resize. Execute a rotation. Execute a save. Execute a sharpen.protected function processText( string $text, mixed $offsetX, mixed $offsetY, int $opacity, int $r, int $g, int $b, int $size, string $fontfile );
protected function processWatermark( AdapterInterface $image, int $offsetX, int $offsetY, int $opacity );
Class Phalcon\Image\Enum
| Namespace | Phalcon\Image |
This file is part of the Phalcon Framework.
(c) Phalcon Team team@phalcon.io
For the full copyright and license information, please view the LICENSE.txt file that was distributed with this source code.
Constants¶
const AUTO = 4;
const HEIGHT = 3;
const HORIZONTAL = 11;
const INVERSE = 5;
const NONE = 1;
const PRECISE = 6;
const TENSILE = 7;
const VERTICAL = 12;
const WIDTH = 2;
Class Phalcon\Image\Exception
| Namespace | Phalcon\Image | | Extends | \Phalcon\Exception |
This file is part of the Phalcon Framework.
(c) Phalcon Team team@phalcon.io
For the full copyright and license information, please view the LICENSE.txt file that was distributed with this source code.
Class Phalcon\Image\ImageFactory
| Namespace | Phalcon\Image | | Uses | Phalcon\Config, Phalcon\Factory\AbstractFactory, Phalcon\Helper\Arr, Phalcon\Image\Adapter\AdapterInterface | | Extends | AbstractFactory |
Phalcon\Image/ImageFactory