Imagick
extends AbstractDraw
in package
Draw class for Imagick
Tags
Table of Contents
Properties
- $fillColor : Colorinterface|null
- Fill color
- $image : mixed
- Image object
- $opacity : int|float|null
- Opacity
- $strokeColor : Colorinterface|null
- Stroke color
- $strokeWidth : int
- Stroke width
Methods
- __construct() : mixed
- Constructor
- arc() : Imagick
- Draw an arc on the image.
- chord() : Imagick
- Draw a chord on the image.
- circle() : Imagick
- Method to add a circle to the image.
- ellipse() : Imagick
- Draw an ellipse on the image.
- getFillColor() : Colorinterface
- Get fill color
- getImage() : AbstractAdapter|null
- Get the image object
- getOpacity() : mixed
- Get the opacity
- getStrokeColor() : Colorinterface
- Get stroke color
- getStrokeWidth() : int
- Get stroke width
- hasImage() : bool
- Has the image object
- line() : Imagick
- Draw a line on the image.
- pie() : Imagick
- Draw a pie slice on the image.
- polygon() : Imagick
- Draw a polygon on the image.
- rectangle() : Imagick
- Draw a rectangle on the image.
- roundedRectangle() : Imagick
- Draw a rounded rectangle on the image.
- roundedSquare() : Imagick
- Draw a rounded square on the image.
- setFillColor() : AbstractDraw
- Set fill color
- setImage() : AbstractEditObject
- Set the image object
- setOpacity() : Imagick
- Set the opacity
- setStrokeColor() : AbstractDraw
- Set stroke color
- setStrokeWidth() : AbstractDraw
- Get stroke width
- square() : Imagick
- Draw a square on the image.
Properties
$fillColor
Fill color
protected
Colorinterface|null
$fillColor
= null
$image
Image object
protected
mixed
$image
= null
$opacity
Opacity
protected
int|float|null
$opacity
= 1.0
$strokeColor
Stroke color
protected
Colorinterface|null
$strokeColor
= null
$strokeWidth
Stroke width
protected
int
$strokeWidth
= 0
Methods
__construct()
Constructor
public
__construct([AbstractAdapter|null $image = null ]) : mixed
Instantiate an image edit object
Parameters
- $image : AbstractAdapter|null = null
arc()
Draw an arc on the image.
public
arc(int $x, int $y, int $start, int $end, int $w[, int|null $h = null ]) : Imagick
Parameters
- $x : int
- $y : int
- $start : int
- $end : int
- $w : int
- $h : int|null = null
Tags
Return values
Imagickchord()
Draw a chord on the image.
public
chord(int $x, int $y, int $start, int $end, int $w[, int|null $h = null ]) : Imagick
Parameters
- $x : int
- $y : int
- $start : int
- $end : int
- $w : int
- $h : int|null = null
Tags
Return values
Imagickcircle()
Method to add a circle to the image.
public
circle(int $x, int $y, int $w) : Imagick
Parameters
- $x : int
- $y : int
- $w : int
Tags
Return values
Imagickellipse()
Draw an ellipse on the image.
public
ellipse(int $x, int $y, int $w[, int|null $h = null ]) : Imagick
Parameters
- $x : int
- $y : int
- $w : int
- $h : int|null = null
Tags
Return values
ImagickgetFillColor()
Get fill color
public
getFillColor() : Colorinterface
Return values
ColorinterfacegetImage()
Get the image object
public
getImage() : AbstractAdapter|null
Return values
AbstractAdapter|nullgetOpacity()
Get the opacity
public
getOpacity() : mixed
getStrokeColor()
Get stroke color
public
getStrokeColor() : Colorinterface
Return values
ColorinterfacegetStrokeWidth()
Get stroke width
public
getStrokeWidth() : int
Return values
inthasImage()
Has the image object
public
hasImage() : bool
Return values
boolline()
Draw a line on the image.
public
line(int $x1, int $y1, int $x2, int $y2) : Imagick
Parameters
- $x1 : int
- $y1 : int
- $x2 : int
- $y2 : int
Tags
Return values
Imagickpie()
Draw a pie slice on the image.
public
pie(int $x, int $y, int $start, int $end, int $w[, int|null $h = null ]) : Imagick
Parameters
- $x : int
- $y : int
- $start : int
- $end : int
- $w : int
- $h : int|null = null
Tags
Return values
Imagickpolygon()
Draw a polygon on the image.
public
polygon(array<string|int, mixed> $points) : Imagick
Parameters
- $points : array<string|int, mixed>
Tags
Return values
Imagickrectangle()
Draw a rectangle on the image.
public
rectangle(int $x, int $y, int $w[, int|null $h = null ]) : Imagick
Parameters
- $x : int
- $y : int
- $w : int
- $h : int|null = null
Tags
Return values
ImagickroundedRectangle()
Draw a rounded rectangle on the image.
public
roundedRectangle(int $x, int $y, int $w[, int|null $h = null ][, int|null $rx = 10 ][, int|null $ry = null ]) : Imagick
Parameters
- $x : int
- $y : int
- $w : int
- $h : int|null = null
- $rx : int|null = 10
- $ry : int|null = null
Tags
Return values
ImagickroundedSquare()
Draw a rounded square on the image.
public
roundedSquare(int $x, int $y, int $w[, int $rx = 10 ][, int|null $ry = null ]) : Imagick
Parameters
- $x : int
- $y : int
- $w : int
- $rx : int = 10
- $ry : int|null = null
Tags
Return values
ImagicksetFillColor()
Set fill color
public
setFillColor(ColorInterface $color) : AbstractDraw
Parameters
- $color : ColorInterface
Return values
AbstractDrawsetImage()
Set the image object
public
setImage(AbstractAdapter $image) : AbstractEditObject
Parameters
- $image : AbstractAdapter
Return values
AbstractEditObjectsetOpacity()
Set the opacity
public
setOpacity(int|float $opacity) : Imagick
Parameters
- $opacity : int|float
Return values
ImagicksetStrokeColor()
Set stroke color
public
setStrokeColor(ColorInterface $color) : AbstractDraw
Parameters
- $color : ColorInterface
Return values
AbstractDrawsetStrokeWidth()
Get stroke width
public
setStrokeWidth(int $w) : AbstractDraw
Parameters
- $w : int
Return values
AbstractDrawsquare()
Draw a square on the image.
public
square(int $x, int $y, int $w) : Imagick
Parameters
- $x : int
- $y : int
- $w : int