International PHP Conference Munich 2021

La classe Imagick

(PECL imagick 2, PECL imagick 3)

Synopsis de la classe

Imagick implements Iterator {
public adaptiveBlurImage(float $radius, float $sigma, int $channel = Imagick::CHANNEL_DEFAULT): bool
public adaptiveResizeImage(
    int $columns,
    int $rows,
    bool $bestfit = false,
    bool $legacy = false
): bool
public adaptiveSharpenImage(float $radius, float $sigma, int $channel = Imagick::CHANNEL_DEFAULT): bool
public adaptiveThresholdImage(int $width, int $height, int $offset): bool
public addImage(Imagick $source): bool
public addNoiseImage(int $noise_type, int $channel = Imagick::CHANNEL_DEFAULT): bool
public affineTransformImage(ImagickDraw $matrix): bool
public animateImages(string $x_server): bool
public annotateImage(
    ImagickDraw $draw_settings,
    float $x,
    float $y,
    float $angle,
    string $text
): bool
public appendImages(bool $stack): Imagick
public autoLevelImage(int $channel = Imagick::CHANNEL_DEFAULT): bool
public blackThresholdImage(mixed $threshold): bool
public blueShiftImage(float $factor = 1.5): bool
public blurImage(float $radius, float $sigma, int $channel = ?): bool
public borderImage(mixed $bordercolor, int $width, int $height): bool
public brightnessContrastImage(float $brightness, float $contrast, int $channel = Imagick::CHANNEL_DEFAULT): bool
public charcoalImage(float $radius, float $sigma): bool
public chopImage(
    int $width,
    int $height,
    int $x,
    int $y
): bool
public clampImage(int $channel = Imagick::CHANNEL_DEFAULT): bool
public clear(): bool
public clipImage(): bool
public clipImagePath(string $pathname, string $inside): void
public clipPathImage(string $pathname, bool $inside): bool
public clone(): Imagick
public clutImage(Imagick $lookup_table, int $channel = Imagick::CHANNEL_DEFAULT): bool
public colorFloodfillImage(
    mixed $fill,
    float $fuzz,
    mixed $bordercolor,
    int $x,
    int $y
): bool
public colorizeImage(mixed $colorize, mixed $opacity, bool $legacy = false): bool
public colorMatrixImage(array $color_matrix = Imagick::CHANNEL_DEFAULT): bool
public combineImages(int $channelType): Imagick
public commentImage(string $comment): bool
public compareImageChannels(Imagick $image, int $channelType, int $metricType): array
public compareImageLayers(int $method): Imagick
public compareImages(Imagick $compare, int $metric): array
public compositeImage(
    Imagick $composite_object,
    int $composite,
    int $x,
    int $y,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public __construct(mixed $files = ?)
public contrastImage(bool $sharpen): bool
public contrastStretchImage(float $black_point, float $white_point, int $channel = Imagick::CHANNEL_DEFAULT): bool
public convolveImage(array $kernel, int $channel = Imagick::CHANNEL_DEFAULT): bool
public count(int $mode = 0): int
public cropImage(
    int $width,
    int $height,
    int $x,
    int $y
): bool
public cropThumbnailImage(int $width, int $height, bool $legacy = false): bool
public current(): Imagick
public cycleColormapImage(int $displace): bool
public decipherImage(string $passphrase): bool
public deleteImageArtifact(string $artifact): bool
public deleteImageProperty(string $name): bool
public deskewImage(float $threshold): bool
public despeckleImage(): bool
public destroy(): bool
public displayImage(string $servername): bool
public displayImages(string $servername): bool
public distortImage(int $method, array $arguments, bool $bestfit): bool
public drawImage(ImagickDraw $draw): bool
public edgeImage(float $radius): bool
public embossImage(float $radius, float $sigma): bool
public encipherImage(string $passphrase): bool
public enhanceImage(): bool
public equalizeImage(): bool
public evaluateImage(int $op, float $constant, int $channel = Imagick::CHANNEL_DEFAULT): bool
public exportImagePixels(
    int $x,
    int $y,
    int $width,
    int $height,
    string $map,
    int $STORAGE
): array
public extentImage(
    int $width,
    int $height,
    int $x,
    int $y
): bool
public filter(ImagickKernel $ImagickKernel, int $channel = Imagick::CHANNEL_UNDEFINED): bool
public flipImage(): bool
public floodFillPaintImage(
    mixed $fill,
    float $fuzz,
    mixed $target,
    int $x,
    int $y,
    bool $invert,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public flopImage(): bool
public forwardFourierTransformimage(bool $magnitude): bool
public frameImage(
    mixed $matte_color,
    int $width,
    int $height,
    int $inner_bevel,
    int $outer_bevel
): bool
public functionImage(int $function, array $arguments, int $channel = Imagick::CHANNEL_DEFAULT): bool
public fxImage(string $expression, int $channel = Imagick::CHANNEL_DEFAULT): Imagick
public gammaImage(float $gamma, int $channel = Imagick::CHANNEL_DEFAULT): bool
public gaussianBlurImage(float $radius, float $sigma, int $channel = Imagick::CHANNEL_DEFAULT): bool
public getColorspace(): int
public getCompression(): int
public getCompressionQuality(): int
public static getCopyright(): string
public getFilename(): string
public getFont(): string
public getFormat(): string
public getGravity(): int
public static getHomeURL(): string
public getImage(): Imagick
public getImageAlphaChannel(): int
public getImageArtifact(string $artifact): string
public getImageAttribute(string $key): string
public getImageBlob(): string
public getImageBluePrimary(): array
public getImageChannelDepth(int $channel): int
public getImageChannelDistortion(Imagick $reference, int $channel, int $metric): float
public getImageChannelDistortions(Imagick $reference, int $metric, int $channel = Imagick::CHANNEL_DEFAULT): float
public getImageChannelExtrema(int $channel): array
public getImageChannelKurtosis(int $channel = Imagick::CHANNEL_DEFAULT): array
public getImageChannelMean(int $channel): array
public getImageChannelRange(int $channel): array
public getImageColors(): int
public getImageColorspace(): int
public getImageCompose(): int
public getImageCompression(): int
public getImageDelay(): int
public getImageDepth(): int
public getImageDispose(): int
public getImageDistortion(MagickWand $reference, int $metric): float
public getImageExtrema(): array
public getImageFilename(): string
public getImageFormat(): string
public getImageGamma(): float
public getImageGeometry(): array
public getImageGravity(): int
public getImageGreenPrimary(): array
public getImageHeight(): int
public getImageHistogram(): array
public getImageIndex(): int
public getImageIterations(): int
public getImageLength(): int
public getImageMatte(): bool
public getImageMimeType(): string
public getImageOrientation(): int
public getImagePage(): array
public getImagePixelColor(int $x, int $y): ImagickPixel
public getImageProfile(string $name): string
public getImageProfiles(string $pattern = "*", bool $include_values = true): array
public getImageProperties(string $pattern = "*", bool $include_values = true): array
public getImageProperty(string $name): string
public getImageRedPrimary(): array
public getImageRegion(
    int $width,
    int $height,
    int $x,
    int $y
): Imagick
public getImageResolution(): array
public getImagesBlob(): string
public getImageScene(): int
public getImageSignature(): string
public getImageSize(): int
public getImageTotalInkDensity(): float
public getImageType(): int
public getImageUnits(): int
public getImageWhitePoint(): array
public getImageWidth(): int
public getInterlaceScheme(): int
public getIteratorIndex(): int
public getNumberImages(): int
public getOption(string $key): string
public static getPackageName(): string
public getPage(): array
public getPixelRegionIterator(
    int $x,
    int $y,
    int $columns,
    int $rows
): ImagickPixelIterator
public getPointSize(): float
public static getQuantum(): int
public static getQuantumDepth(): array
public static getQuantumRange(): array
public static getRegistry(string $key): string
public static getReleaseDate(): string
public static getResource(int $type): int
public static getResourceLimit(int $type): int
public getSamplingFactors(): array
public getSize(): array
public getSizeOffset(): int
public static getVersion(): array
public haldClutImage(Imagick $clut, int $channel = Imagick::CHANNEL_DEFAULT): bool
public hasNextImage(): bool
public hasPreviousImage(): bool
public identifyFormat(string $embedText): string|false
public identifyImage(bool $appendRawOutput = false): array
public implodeImage(float $radius): bool
public importImagePixels(
    int $x,
    int $y,
    int $width,
    int $height,
    string $map,
    int $storage,
    array $pixels
): bool
public inverseFourierTransformImage(Imagick $complement, bool $magnitude): bool
public labelImage(string $label): bool
public levelImage(
    float $blackPoint,
    float $gamma,
    float $whitePoint,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public linearStretchImage(float $blackPoint, float $whitePoint): bool
public liquidRescaleImage(
    int $width,
    int $height,
    float $delta_x,
    float $rigidity
): bool
public static listRegistry(): array
public magnifyImage(): bool
public mapImage(Imagick $map, bool $dither): bool
public matteFloodfillImage(
    float $alpha,
    float $fuzz,
    mixed $bordercolor,
    int $x,
    int $y
): bool
public medianFilterImage(float $radius): bool
public mergeImageLayers(int $layer_method): Imagick
public minifyImage(): bool
public modulateImage(float $brightness, float $saturation, float $hue): bool
public montageImage(
    ImagickDraw $draw,
    string $tile_geometry,
    string $thumbnail_geometry,
    int $mode,
    string $frame
): Imagick
public morphImages(int $number_frames): Imagick
public morphology(
    int $morphologyMethod,
    int $iterations,
    ImagickKernel $ImagickKernel,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public motionBlurImage(
    float $radius,
    float $sigma,
    float $angle,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public negateImage(bool $gray, int $channel = Imagick::CHANNEL_DEFAULT): bool
public newImage(
    int $cols,
    int $rows,
    mixed $background,
    string $format = ?
): bool
public newPseudoImage(int $columns, int $rows, string $pseudoString): bool
public nextImage(): bool
public normalizeImage(int $channel = Imagick::CHANNEL_DEFAULT): bool
public oilPaintImage(float $radius): bool
public opaquePaintImage(
    mixed $target,
    mixed $fill,
    float $fuzz,
    bool $invert,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public optimizeImageLayers(): bool
public orderedPosterizeImage(string $threshold_map, int $channel = Imagick::CHANNEL_DEFAULT): bool
public paintFloodfillImage(
    mixed $fill,
    float $fuzz,
    mixed $bordercolor,
    int $x,
    int $y,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public paintOpaqueImage(
    mixed $target,
    mixed $fill,
    float $fuzz,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public paintTransparentImage(mixed $target, float $alpha, float $fuzz): bool
public pingImage(string $filename): bool
public pingImageBlob(string $image): bool
public pingImageFile(resource $filehandle, string $fileName = ?): bool
public polaroidImage(ImagickDraw $properties, float $angle): bool
public posterizeImage(int $levels, bool $dither): bool
public previewImages(int $preview): bool
public previousImage(): bool
public profileImage(string $name, string $profile): bool
public quantizeImage(
    int $numberColors,
    int $colorspace,
    int $treedepth,
    bool $dither,
    bool $measureError
): bool
public quantizeImages(
    int $numberColors,
    int $colorspace,
    int $treedepth,
    bool $dither,
    bool $measureError
): bool
public queryFontMetrics(ImagickDraw $properties, string $text, bool $multiline = ?): array
public static queryFonts(string $pattern = "*"): array
public static queryFormats(string $pattern = "*"): array
public radialBlurImage(float $angle, int $channel = Imagick::CHANNEL_DEFAULT): bool
public raiseImage(
    int $width,
    int $height,
    int $x,
    int $y,
    bool $raise
): bool
public randomThresholdImage(float $low, float $high, int $channel = Imagick::CHANNEL_DEFAULT): bool
public readImage(string $filename): bool
public readImageBlob(string $image, string $filename = ?): bool
public readImageFile(resource $filehandle, string $fileName = null): bool
public readImages(array $filenames): bool
public recolorImage(array $matrix): bool
public reduceNoiseImage(float $radius): bool
public remapImage(Imagick $replacement, int $DITHER): bool
public removeImage(): bool
public removeImageProfile(string $name): string
public render(): bool
public resampleImage(
    float $x_resolution,
    float $y_resolution,
    int $filter,
    float $blur
): bool
public resetImagePage(string $page): bool
public resizeImage(
    int $columns,
    int $rows,
    int $filter,
    float $blur,
    bool $bestfit = false,
    bool $legacy = false
): bool
public rollImage(int $x, int $y): bool
public rotateImage(mixed $background, float $degrees): bool
public rotationalBlurImage(float $angle, int $channel = Imagick::CHANNEL_DEFAULT): bool
public roundCorners(
    float $x_rounding,
    float $y_rounding,
    float $stroke_width = 10,
    float $displace = 5,
    float $size_correction = -6
): bool
public sampleImage(int $columns, int $rows): bool
public scaleImage(
    int $cols,
    int $rows,
    bool $bestfit = false,
    bool $legacy = false
): bool
public segmentImage(
    int $COLORSPACE,
    float $cluster_threshold,
    float $smooth_threshold,
    bool $verbose = false
): bool
public selectiveBlurImage(
    float $radius,
    float $sigma,
    float $threshold,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public separateImageChannel(int $channel): bool
public sepiaToneImage(float $threshold): bool
public setBackgroundColor(mixed $background): bool
public setColorspace(int $COLORSPACE): bool
public setCompression(int $compression): bool
public setCompressionQuality(int $quality): bool
public setFilename(string $filename): bool
public setFirstIterator(): bool
public setFont(string $font): bool
public setFormat(string $format): bool
public setGravity(int $gravity): bool
public setImage(Imagick $replace): bool
public setImageAlphaChannel(int $mode): bool
public setImageArtifact(string $artifact, string $value): bool
public setImageAttribute(string $key, string $value): bool
public setImageBackgroundColor(mixed $background): bool
public setImageBias(float $bias): bool
public setImageBiasQuantum(string $bias): void
public setImageBluePrimary(float $x, float $y): bool
public setImageBorderColor(mixed $border): bool
public setImageChannelDepth(int $channel, int $depth): bool
public setImageClipMask(Imagick $clip_mask): bool
public setImageColormapColor(int $index, ImagickPixel $color): bool
public setImageColorspace(int $colorspace): bool
public setImageCompose(int $compose): bool
public setImageCompression(int $compression): bool
public setImageCompressionQuality(int $quality): bool
public setImageDelay(int $delay): bool
public setImageDepth(int $depth): bool
public setImageDispose(int $dispose): bool
public setImageExtent(int $columns, int $rows): bool
public setImageFilename(string $filename): bool
public setImageFormat(string $format): bool
public setImageGamma(float $gamma): bool
public setImageGravity(int $gravity): bool
public setImageGreenPrimary(float $x, float $y): bool
public setImageIndex(int $index): bool
public setImageInterlaceScheme(int $interlace_scheme): bool
public setImageInterpolateMethod(int $method): bool
public setImageIterations(int $iterations): bool
public setImageMatte(bool $matte): bool
public setImageMatteColor(mixed $matte): bool
public setImageOpacity(float $opacity): bool
public setImageOrientation(int $orientation): bool
public setImagePage(
    int $width,
    int $height,
    int $x,
    int $y
): bool
public setImageProfile(string $name, string $profile): bool
public setImageProperty(string $name, string $value): bool
public setImageRedPrimary(float $x, float $y): bool
public setImageRenderingIntent(int $rendering_intent): bool
public setImageResolution(float $x_resolution, float $y_resolution): bool
public setImageScene(int $scene): bool
public setImageTicksPerSecond(int $ticks_per_second): bool
public setImageType(int $image_type): bool
public setImageUnits(int $units): bool
public setImageVirtualPixelMethod(int $method): bool
public setImageWhitePoint(float $x, float $y): bool
public setInterlaceScheme(int $interlace_scheme): bool
public setIteratorIndex(int $index): bool
public setLastIterator(): bool
public setOption(string $key, string $value): bool
public setPage(
    int $width,
    int $height,
    int $x,
    int $y
): bool
public setPointSize(float $point_size): bool
public setProgressMonitor(callable $callback): bool
public static setRegistry(string $key, string $value): bool
public setResolution(float $x_resolution, float $y_resolution): bool
public static setResourceLimit(int $type, int $limit): bool
public setSamplingFactors(array $factors): bool
public setSize(int $columns, int $rows): bool
public setSizeOffset(int $columns, int $rows, int $offset): bool
public setType(int $image_type): bool
public shadeImage(bool $gray, float $azimuth, float $elevation): bool
public shadowImage(
    float $opacity,
    float $sigma,
    int $x,
    int $y
): bool
public sharpenImage(float $radius, float $sigma, int $channel = Imagick::CHANNEL_DEFAULT): bool
public shaveImage(int $columns, int $rows): bool
public shearImage(mixed $background, float $x_shear, float $y_shear): bool
public sigmoidalContrastImage(
    bool $sharpen,
    float $alpha,
    float $beta,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public sketchImage(float $radius, float $sigma, float $angle): bool
public smushImages(bool $stack, int $offset): Imagick
public solarizeImage(int $threshold): bool
public sparseColorImage(int $SPARSE_METHOD, array $arguments, int $channel = Imagick::CHANNEL_DEFAULT): bool
public spliceImage(
    int $width,
    int $height,
    int $x,
    int $y
): bool
public spreadImage(float $radius): bool
public statisticImage(
    int $type,
    int $width,
    int $height,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public steganoImage(Imagick $watermark_wand, int $offset): Imagick
public stereoImage(Imagick $offset_wand): bool
public stripImage(): bool
public subImageMatch(Imagick $Imagick, array &$offset = ?, float &$similarity = ?): Imagick
swirlImage(float $degrees): bool
textureImage(Imagick $texture_wand): Imagick
public thresholdImage(float $threshold, int $channel = Imagick::CHANNEL_DEFAULT): bool
public thumbnailImage(
    int $columns,
    int $rows,
    bool $bestfit = false,
    bool $fill = false,
    bool $legacy = false
): bool
public tintImage(mixed $tint, mixed $opacity, bool $legacy = false): bool
public __toString(): string
public transformImage(string $crop, string $geometry): Imagick
public transformImageColorspace(int $colorspace): bool
public transparentPaintImage(
    mixed $target,
    float $alpha,
    float $fuzz,
    bool $invert
): bool
public transposeImage(): bool
public transverseImage(): bool
public trimImage(float $fuzz): bool
public uniqueImageColors(): bool
public unsharpMaskImage(
    float $radius,
    float $sigma,
    float $amount,
    float $threshold,
    int $channel = Imagick::CHANNEL_DEFAULT
): bool
public valid(): bool
public vignetteImage(
    float $blackPoint,
    float $whitePoint,
    int $x,
    int $y
): bool
public waveImage(float $amplitude, float $length): bool
public whiteThresholdImage(mixed $threshold): bool
public writeImage(string $filename = NULL): bool
public writeImageFile(resource $filehandle, string $format = ?): bool
public writeImages(string $filename, bool $adjoin): bool
public writeImagesFile(resource $filehandle, string $format = ?): bool

Méthodes Image et méthodes globales

La classe Imagick permet d'agir sur plusieurs images simultanément et ce, grâce à une pile interne. Il y a toujours un pointeur interne, pointant sur l'image courante. Quelques fonctions agissent sur toutes les images d'une classe Imagick, mais la plupart uniquement sur l'image courante au regard de cette pile. Tout comme les conversions, les noms des méthodes peuvent contenir le nom de l'image, relatant uniquement l'effet sur l'image de la pile.

Méthodes de la classe

Vu le nombre de méthodes, voici une liste les présentant de façon générale :

Méthodes de la classe
Effets sur l'image Méthodes de récupération Méthodes de définition Lecture/écriture de l'image Autres
Imagick::adaptiveBlurImage() Imagick::getCompression() Imagick::setBackgroundColor() Imagick::__construct() Imagick::clear()
Imagick::adaptiveResizeImage() Imagick::getFilename() Imagick::setCompressionQuality() Imagick::addImage() Imagick::clone()
Imagick::adaptiveSharpenImage() Imagick::getFormat() Imagick::setCompression() Imagick::appendImages() Imagick::current()
Imagick::adaptiveThresholdImage() Imagick::getImageBackgroundColor() Imagick::setFilename() Imagick::getFilename() Imagick::destroy()
Imagick::addNoiseImage() Imagick::getImageBlob() Imagick::getImagesBlob() Imagick::setFormat() Imagick::getFormat()
Imagick::affinetransformimage() Imagick::getImageBluePrimary() Imagick::setImageBackgroundColor() Imagick::getImageFilename() Imagick::getHomeURL()
Imagick::annotateImage() Imagick::getImageBorderColor() Imagick::setFirstIterator() Imagick::getImageFormat() Imagick::commentImage()
Imagick::averageImages() Imagick::getImageChannelDepth() Imagick::setImageBias() Imagick::getImage() Imagick::getNumberImages()
Imagick::blackThresholdImage() Imagick::getImageChannelDistortion() Imagick::setImageBluePrimary() Imagick::setImageFilename() Imagick::getReleaseDate()
Imagick::blurImage() Imagick::getImageChannelExtrema() Imagick::setImageBorderColor() Imagick::setImageFormat() Imagick::getVersion()
Imagick::borderImage() Imagick::getImageChannelMean() Imagick::setImageChannelDepth() Imagick::readImageFile() Imagick::hasNextImage()
Imagick::charcoalImage() Imagick::getImageChannelStatistics() Imagick::setImageColormapColor() Imagick::readImage() Imagick::hasPreviousImage()
Imagick::chopImage() Imagick::getImageColormapColor() Imagick::setImageColorSpace() Imagick::writeImages() Imagick::labelImage()
Imagick::clipImage() Imagick::getImageColorspace() Imagick::setImageCompose() Imagick::writeImage() Imagick::newImage()
Imagick::clipPathImage() Imagick::getImageColors() Imagick::setImageCompression()   Imagick::newPseudoImage()
Imagick::coalesceImages() Imagick::getImageCompose() Imagick::setImageDelay()   Imagick::nextImage()
Imagick::colorFloodFillImage() Imagick::getImageDelay() Imagick::setImageDepth()   Imagick::pingImageBlob()
Imagick::colorizeImage() Imagick::getImageDepth() Imagick::setImageDispose()   Imagick::pingImageFile()
Imagick::combineImages() Imagick::getImageDispose() Imagick::setImageDispose()   Imagick::pingImage()
Imagick::compareImageChannels() Imagick::getImageDistortion() Imagick::setImageExtent()   Imagick::previousImage()
Imagick::compareImageLayers() Imagick::getImageExtrema() Imagick::setImageFilename()   Imagick::profileImage()
Imagick::compositeImage() Imagick::getImageFilename() Imagick::setImageFormat()   Imagick::queryFormats()
Imagick::contrastImage() Imagick::getImageFormat() Imagick::setImageGamma()   Imagick::removeImageProfile()
Imagick::contrastStretchImage() Imagick::getImageGamma() Imagick::setImageGreenPrimary()   Imagick::removeImage()
Imagick::convolveImage() Imagick::getImageGeometry() Imagick::setImageIndex()   Imagick::setFirstIterator()
Imagick::cropImage() Imagick::getImageGreenPrimary() Imagick::setImageInterpolateMethod()   Imagick::setImageIndex()
Imagick::cycleColormapImage() Imagick::getImageHeight() Imagick::setImageIterations()   Imagick::valid()
Imagick::deconstructImages() Imagick::getImageHistogram() Imagick::setImageMatteColor()   Imagick::getCopyright()
Imagick::drawImage() Imagick::getImageIndex() Imagick::setImageMatte()    
Imagick::edgeImage() Imagick::getImageInterlaceScheme() Imagick::setImagePage()    
Imagick::embossImage() Imagick::getImageInterpolateMethod() Imagick::setImageProfile()    
Imagick::enhanceImage() Imagick::getImageIterations() Imagick::setImageProperty()    
Imagick::equalizeImage() Imagick::getImageMatteColor() Imagick::setImageRedPrimary()    
Imagick::evaluateImage() Imagick::getImageMatte() Imagick::setImageRenderingIntent()    
Imagick::flattenImages() Imagick::getImagePage() Imagick::setImageResolution()    
Imagick::flipImage() Imagick::getImagePixelColor() Imagick::setImageScene()    
Imagick::flopImage() Imagick::getImageProfile() Imagick::setImageTicksPerSecond()    
  Imagick::getImageProperty() Imagick::setImageType()    
Imagick::fxImage() Imagick::getImageRedPrimary() Imagick::setImageUnits()    
Imagick::gammaImage() Imagick::getImageRegion() Imagick::setImageVirtualPixelMethod()    
Imagick::gaussianBlurImage() Imagick::getImageRenderingIntent() Imagick::setImageWhitepoint()    
Imagick::implodeImage() Imagick::getImageResolution() Imagick::setInterlaceScheme()    
Imagick::levelImage() Imagick::getImageScene() Imagick::setOption()    
Imagick::linearStretchImage() Imagick::getImageSignature() Imagick::setPage()    
Imagick::magnifyImage() Imagick::getImageTicksPerSecond() Imagick::setResolution()    
Imagick::matteFloodFillImage() Imagick::getImageTotalInkDensity() Imagick::setResourceLimit()    
Imagick::medianFilterImage() Imagick::getImageType() Imagick::setSamplingFactors()    
Imagick::minifyImage() Imagick::getImageUnits() Imagick::setSizeOffset()    
Imagick::modulateImage() Imagick::getImageVirtualPixelMethod() Imagick::setSize()    
Imagick::montageImage() Imagick::getImageWhitepoint() Imagick::setType()    
Imagick::morphImages() Imagick::getImageWidth()      
Imagick::mosaicImages() Imagick::getImage()      
Imagick::motionBlurImage() Imagick::getInterlaceScheme()      
Imagick::negateImage() Imagick::getNumberImages()      
Imagick::normalizeImage() Imagick::getOption()      
Imagick::oilPaintImage() Imagick::getPackageName()      
Imagick::optimizeImageLayers() Imagick::getPage()      
Imagick::paintOpaqueImage() Imagick::getPixelIterator()      
Imagick::paintTransparentImage() Imagick::getPixelRegionIterator()      
Imagick::posterizeImage() Imagick::getQuantumDepth()      
Imagick::radialBlurImage() Imagick::getQuantumRange()      
Imagick::raiseImage() Imagick::getResourceLimit()      
Imagick::randomThresholdImage() Imagick::getResource()      
Imagick::reduceNoiseImage() Imagick::getSamplingFactors()      
Imagick::render() Imagick::getSizeOffset()      
Imagick::resampleImage() Imagick::getSize()      
Imagick::resizeImage() Imagick::identifyImage()      
Imagick::rollImage() Imagick::getImageSize()      


add a note add a note

User Contributed Notes 3 notes

StealthFox at live dot com
12 years ago
Users looking to save  with these functions should know it can be done easily, for example

("Content-Type: image/{$Imagick->getImageFormat()}");
$data = $Imagick->getImageBlob ();
file_put_contents ('test.png', $data);

That would display the image, and then save it to test.png. Such things are helpful especially when you need to reload images after creating them or save for later. :)
benkuhl at gmail dot com
8 years ago
When using this library with PDFs, the term "image" applies to a page where the pointer begins at the last page of the document.


= new Imagick('myPdf.pdf'); //2 page PDF

$document->getNumberImages(); //returns 2

var_dump($document->hasNextImage()); //returns false - remember, we're on the last page
var_dump($document->hasPreviousImage()); //returns true


If you need to do more than generate thumbnails from a PDF, use XPDF:
php at mattjanssen dot com
10 years ago
You can find the documentation for all of these magick_wand--the interface Imagic seems to be built on--functions at
To Top