PHP Class Pimcore\Image\Adapter\Imagick

Inheritance: extends Pimcore\Image\Adapter
显示文件 Open project: pimcore/pimcore Class Usage Examples

Protected Properties

Property Type Description
$CMYKColorProfile string
$RGBColorProfile string
$imagePath string
$resource Imagick

Public Methods

Method Description
addOverlay ( string $image, integer $x, integer $y, integer $alpha = 100, $composite = "COMPOSITE_DEFAULT", string $origin = 'top-left' ) : self
addOverlayFit ( $image, string $composite = "COMPOSITE_DEFAULT" )
applyMask ( $image ) : self
brightnessSaturation ( integer $brightness = 100, integer $saturation = 100, integer $hue = 100 )
crop ( $x, $y, $width, $height ) : self
frame ( $width, $height )
gaussianBlur ( integer $radius, float $sigma = 1 )
getCMYKColorProfile ( ) : string
getDimensions ( ) : array
getRGBColorProfile ( ) : string
getVectorFormatEmbeddedRasterDimensions ( ) : array | null
getVectorRasterDimensions ( ) : array
grayscale ( ) : self
isVectorGraphic ( null $imagePath = null ) : boolean
load ( $imagePath, array $options = [] )
mirror ( $mode )
resize ( $width, $height ) : self
rotate ( $angle )
roundCorners ( $width, $height )
save ( $path, null $format = null, null $quality = null )
sepia ( ) : self
setBackgroundColor ( $color ) : self
setBackgroundImage ( $image, null | string $mode = null )
setCMYKColorProfile ( string $CMYKColorProfile )
setColorspaceToRGB ( )
setRGBColorProfile ( string $RGBColorProfile )
sharpen ( integer $radius, float $sigma = 1, float $amount = 1, float $threshold = 0.05 )
trim ( $tolerance ) : self

Protected Methods

Method Description
createImage ( $width, $height, $color = "transparent" ) : Imagick
destroy ( ) : void
hasAlphaChannel ( ) : boolean

Method Details

addOverlay() public method

public addOverlay ( string $image, integer $x, integer $y, integer $alpha = 100, $composite = "COMPOSITE_DEFAULT", string $origin = 'top-left' ) : self
$image string
$x integer Amount of horizontal pixels the overlay should be offset from the origin
$y integer Amount of vertical pixels the overlay should be offset from the origin
$alpha integer Opacity in a scale of 0 (transparent) to 100 (opaque)
$origin string Origin of the X and Y coordinates (top-left, top-right, bottom-left, bottom-right or center)
return self

addOverlayFit() public method

public addOverlayFit ( $image, string $composite = "COMPOSITE_DEFAULT" )
$image
$composite string

applyMask() public method

public applyMask ( $image ) : self
$image
return self

brightnessSaturation() public method

public brightnessSaturation ( integer $brightness = 100, integer $saturation = 100, integer $hue = 100 )
$brightness integer
$saturation integer
$hue integer

createImage() protected method

protected createImage ( $width, $height, $color = "transparent" ) : Imagick
$width
$height
return Imagick

crop() public method

public crop ( $x, $y, $width, $height ) : self
$x
$y
$width
$height
return self

destroy() protected method

protected destroy ( ) : void
return void

frame() public method

public frame ( $width, $height )
$width
$height

gaussianBlur() public method

public gaussianBlur ( integer $radius, float $sigma = 1 )
$radius integer
$sigma float

getCMYKColorProfile() public static method

public static getCMYKColorProfile ( ) : string
return string

getDimensions() public method

public getDimensions ( ) : array
return array

getRGBColorProfile() public static method

public static getRGBColorProfile ( ) : string
return string

getVectorFormatEmbeddedRasterDimensions() public method

getVectorRasterDimensions() public method

public getVectorRasterDimensions ( ) : array
return array

grayscale() public method

public grayscale ( ) : self
return self

hasAlphaChannel() protected method

protected hasAlphaChannel ( ) : boolean
return boolean

isVectorGraphic() public method

public isVectorGraphic ( null $imagePath = null ) : boolean
$imagePath null
return boolean

load() public method

public load ( $imagePath, array $options = [] )
$imagePath
$options array

mirror() public method

public mirror ( $mode )
$mode

resize() public method

public resize ( $width, $height ) : self
$width
$height
return self

rotate() public method

public rotate ( $angle )
$angle

roundCorners() public method

public roundCorners ( $width, $height )
$width
$height

save() public method

public save ( $path, null $format = null, null $quality = null )
$path
$format null
$quality null

sepia() public method

public sepia ( ) : self
return self

setBackgroundColor() public method

public setBackgroundColor ( $color ) : self
$color
return self

setBackgroundImage() public method

public setBackgroundImage ( $image, null | string $mode = null )
$image
$mode null | string

setCMYKColorProfile() public static method

public static setCMYKColorProfile ( string $CMYKColorProfile )
$CMYKColorProfile string

setColorspaceToRGB() public method

public setColorspaceToRGB ( )

setRGBColorProfile() public static method

public static setRGBColorProfile ( string $RGBColorProfile )
$RGBColorProfile string

sharpen() public method

public sharpen ( integer $radius, float $sigma = 1, float $amount = 1, float $threshold = 0.05 )
$radius integer
$sigma float
$amount float
$threshold float

trim() public method

public trim ( $tolerance ) : self
$tolerance
return self

Property Details

$CMYKColorProfile protected_oe static_oe property

protected static string $CMYKColorProfile
return string

$RGBColorProfile protected_oe static_oe property

protected static string $RGBColorProfile
return string

$imagePath protected_oe property

protected string $imagePath
return string

$resource protected_oe property

protected Imagick,Pimcore\Image\Adapter $resource
return Imagick