Method | Description | |
---|---|---|
__construct ( |
Base constructor. | |
create ( integer $width, integer $height, string $bgColor = null, integer $alpha = 100 ) : Webiny\Component\Image\ImageInterface | Create a blank image with of given dimensions and fill it with $bgColor. | |
load ( string $string ) : Webiny\Component\Image\ImageInterface | Create a new ImageInterface instance form the given binary string. | |
open ( |
Creates a new ImageInterface instance from the given image at the provided path. | |
resource ( mixed $resource ) : Webiny\Component\Image\ImageInterface | Create a new ImageInterface instance from the given resource. |
Method | Description | |
---|---|---|
getLibraryInstance ( string $library ) : Imagine\Gd\Imagine | Imagine\Gmagick\Imagine | Imagine\Imagick\Imagine | Create a library instance based on given library name. |
public __construct ( |
||
$config |
public create ( integer $width, integer $height, string $bgColor = null, integer $alpha = 100 ) : Webiny\Component\Image\ImageInterface | ||
$width | integer | Width of the new image. |
$height | integer | Height of the new image. |
$bgColor | string | Background color. Following formats are acceptable - "fff" - "ffffff" - array(255,255,255) |
$alpha | integer | Alpha transparency. |
return | Webiny\Component\Image\ImageInterface |
public open ( |
||
$image | Path to an image on the disk. | |
return | Webiny\Component\Image\ImageInterface |