gmagick

package module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 10, 2017 License: BSD-3-Clause Imports: 10 Imported by: 0

README

Go bindings for GraphicsMagick

Install GraphicsMagick libraries and header files

Windows
pacman -S mingw-w64-x86_64-gcc
pacman -S mingw-w64-x86_64-zlib
pacman -S mingw-w64-x86_64-pkg-config
pacman -S mingw-w64-x86_64-graphicsmagick
  • Add following environment variable:
set PATH=<msys64>\mingw64\bin;%PATH%
set PKG_CONFIG_PATH=<msys64>\mingw64\lib\pkgconfig
set MAGICK_CODER_MODULE_PATH=<msys64>\mingw64\lib\GraphicsMagick-1.3.25\modules-Q8\coders

(BTW: you should change <msys64> to your installation path of msys2)

MacOS

Install GraphicsMagick using Homebrew or MacPorts
An example of MacPorts:

  • sudo port install graphicsmagick
  • export PKG_CONFIG_PATH=/opt/local/lib/pkgconfig
CentOS
  • ensure epel-release was installed. (help)
  • yum install GraphicsMagick-devel
Ubuntu
  • sudo apt-get install libgraphicsmagick1-dev

Install golang bindings

  • go get github.com/gographics/gmagick

Example

package main

import (
    "flag"
    "github.com/gographics/gmagick"
)

func resize(orig string, dest string) {
    mw := gmagick.NewMagickWand()
    defer mw.Destroy()
    mw.ReadImage(orig)
    filter := gmagick.FILTER_LANCZOS
    w := mw.GetImageWidth()
    h := mw.GetImageHeight()
    mw.ResizeImage(w/2, h/2, filter, 1)
    mw.WriteImage(dest)
}

func main() {
    f := flag.String("from", "", "original image file ...")
    t := flag.String("to", "", "target file ...")
    flag.Parse()

    gmagick.Initialize()
    defer gmagick.Terminate()

    resize(*f, *t)
}

====================================================

Todo List

  • CloneMagickWand
  • ClonePixelWand
  • ClonePixelWands
  • CopyMagickString
  • DestroyMagickWand
  • DestroyPixelWand
  • FormatMagickString
  • FormatMagickStringList
  • MagickAdaptiveThresholdImage
  • MagickAddImage
  • MagickAddNoiseImage
  • MagickAffineTransformImage
  • MagickAnimateImages
  • MagickAnnotateImage
  • MagickAppendImages
  • MagickAverageImages
  • MagickBlackThresholdImage
  • MagickBlurImage
  • MagickBorderImage
  • MagickCdlImage
  • MagickCharcoalImage
  • MagickChopImage
  • MagickClipImage
  • MagickClipPathImage
  • MagickCloneDrawingWand
  • MagickCoalesceImages
  • MagickColorFloodfillImage
  • MagickColorizeImage
  • MagickCommentImage
  • MagickCompareImageChannels
  • MagickCompareImages
  • MagickCompositeImage
  • MagickContrastImage
  • MagickConvolveImage
  • MagickCropImage
  • MagickCycleColormapImage
  • MagickDeconstructImages
  • MagickDescribeImage
  • MagickDespeckleImage
  • MagickDestroyDrawingWand
  • MagickDisplayImage
  • MagickDisplayImages
  • MagickDrawAffine
  • MagickDrawAllocateWand
  • MagickDrawAnnotation
  • MagickDrawArc
  • MagickDrawBezier
  • MagickDrawCircle
  • MagickDrawClearException
  • MagickDrawColor
  • MagickDrawComment
  • MagickDrawComposite
  • MagickDrawEllipse
  • MagickDrawGetClipPath
  • MagickDrawGetClipRule
  • MagickDrawGetClipUnits
  • MagickDrawGetException
  • MagickDrawGetFillColor
  • MagickDrawGetFillOpacity
  • MagickDrawGetFillRule
  • MagickDrawGetFontFamily
  • MagickDrawGetFont
  • MagickDrawGetFontSize
  • MagickDrawGetFontStretch
  • MagickDrawGetFontStyle
  • MagickDrawGetFontWeight
  • MagickDrawGetGravity
  • MagickDrawGetStrokeAntialias
  • MagickDrawGetStrokeColor
  • MagickDrawGetStrokeDashArray
  • MagickDrawGetStrokeDashOffset
  • MagickDrawGetStrokeLineCap
  • MagickDrawGetStrokeLineJoin
  • MagickDrawGetStrokeMiterLimit
  • MagickDrawGetStrokeOpacity
  • MagickDrawGetStrokeWidth
  • MagickDrawGetTextAntialias
  • MagickDrawGetTextDecoration
  • MagickDrawGetTextEncoding
  • MagickDrawGetTextUnderColor
  • MagickDrawImage
  • MagickDrawLine
  • MagickDrawMatte
  • MagickDrawPathClose
  • MagickDrawPathCurveToAbsolute
  • MagickDrawPathCurveToQuadraticBezierAbsolute
  • MagickDrawPathCurveToQuadraticBezierRelative
  • MagickDrawPathCurveToQuadraticBezierSmoothAbsolute
  • MagickDrawPathCurveToQuadraticBezierSmoothRelative
  • MagickDrawPathCurveToRelative
  • MagickDrawPathCurveToSmoothAbsolute
  • MagickDrawPathCurveToSmoothRelative
  • MagickDrawPathEllipticArcAbsolute
  • MagickDrawPathEllipticArcRelative
  • MagickDrawPathFinish
  • MagickDrawPathLineToAbsolute
  • MagickDrawPathLineToHorizontalAbsolute
  • MagickDrawPathLineToHorizontalRelative
  • MagickDrawPathLineToRelative
  • MagickDrawPathLineToVerticalAbsolute
  • MagickDrawPathLineToVerticalRelative
  • MagickDrawPathMoveToAbsolute
  • MagickDrawPathMoveToRelative
  • MagickDrawPathStart
  • MagickDrawPeekGraphicContext
  • MagickDrawPoint
  • MagickDrawPolygon
  • MagickDrawPolyline
  • MagickDrawPopClipPath
  • MagickDrawPopDefs
  • MagickDrawPopGraphicContext
  • MagickDrawPopPattern
  • MagickDrawPushClipPath
  • MagickDrawPushDefs
  • MagickDrawPushGraphicContext
  • MagickDrawPushPattern
  • MagickDrawRectangle
  • MagickDrawRender(deprecated)
  • MagickDrawRotate
  • MagickDrawRoundRectangle
  • MagickDrawScale
  • MagickDrawSetClipPath
  • MagickDrawSetClipRule
  • MagickDrawSetClipUnits
  • MagickDrawSetFillColor
  • MagickDrawSetFillOpacity
  • MagickDrawSetFillPatternURL
  • MagickDrawSetFillRule
  • MagickDrawSetFontFamily
  • MagickDrawSetFont
  • MagickDrawSetFontSize
  • MagickDrawSetFontStretch
  • MagickDrawSetFontStyle
  • MagickDrawSetFontWeight
  • MagickDrawSetGravity
  • MagickDrawSetStrokeAntialias
  • MagickDrawSetStrokeColor
  • MagickDrawSetStrokeDashArray
  • MagickDrawSetStrokeDashOffset
  • MagickDrawSetStrokeLineCap
  • MagickDrawSetStrokeLineJoin
  • MagickDrawSetStrokeMiterLimit
  • MagickDrawSetStrokeOpacity
  • MagickDrawSetStrokePatternURL
  • MagickDrawSetStrokeWidth
  • MagickDrawSetTextAntialias
  • MagickDrawSetTextDecoration
  • MagickDrawSetTextEncoding
  • MagickDrawSetTextUnderColor
  • MagickDrawSetViewbox
  • MagickDrawSkewX
  • MagickDrawSkewY
  • MagickDrawTranslate
  • MagickEdgeImage
  • MagickEmbossImage
  • MagickEnhanceImage
  • MagickEqualizeImage
  • MagickExtentImage
  • MagickFlattenImages
  • MagickFlipImage
  • MagickFlopImage
  • MagickFrameImage
  • MagickFxImageChannel
  • MagickFxImage
  • MagickGammaImageChannel
  • MagickGammaImage
  • MagickGetConfigureInfo
  • MagickGetCopyright
  • MagickGetException
  • MagickGetFilename
  • MagickGetHomeURL
  • MagickGetImageAttribute
  • MagickGetImageBackgroundColor
  • MagickGetImageBluePrimary
  • MagickGetImageBorderColor
  • MagickGetImageBoundingBox
  • MagickGetImageChannelDepth
  • MagickGetImageChannelExtrema
  • MagickGetImageChannelMean
  • MagickGetImageColormapColor
  • MagickGetImageColors
  • MagickGetImageColorspace
  • MagickGetImageCompose
  • MagickGetImageCompression
  • MagickGetImageDelay
  • MagickGetImageDepth
  • MagickGetImageDispose
  • MagickGetImageExtrema
  • MagickGetImageFilename
  • MagickGetImageFormat
  • MagickGetImageFuzz
  • MagickGetImageGamma
  • MagickGetImageGeometry
  • MagickGetImageGravity
  • MagickGetImage
  • MagickGetImageGreenPrimary
  • MagickGetImageHeight
  • MagickGetImageHistogram
  • MagickGetImageIndex
  • MagickGetImageInterlaceScheme
  • MagickGetImageIterations
  • MagickGetImageMatte
  • MagickGetImageMatteColor
  • MagickGetImagePage
  • MagickGetImagePixels
  • MagickGetImageProfile
  • MagickGetImageRedPrimary
  • MagickGetImageRenderingIntent
  • MagickGetImageResolution
  • MagickGetImageSavedType
  • MagickGetImageScene
  • MagickGetImageSignature
  • MagickGetImageSize
  • MagickGetImageType
  • MagickGetImageUnits
  • MagickGetImageVirtualPixelMethod
  • MagickGetImageWhitePoint
  • MagickGetImageWidth
  • MagickGetNumberImages
  • MagickGetPackageName
  • MagickGetQuantumDepth
  • MagickGetReleaseDate
  • MagickGetResourceLimit
  • MagickGetSamplingFactors
  • MagickGetSize
  • MagickGetVersion
  • MagickHaldClutImage
  • MagickHasNextImage
  • MagickHasPreviousImage
  • MagickImplodeImage
  • MagickLabelImage
  • MagickLevelImageChannel
  • MagickLevelImage
  • MagickMagnifyImage
  • MagickMapImage
  • MagickMatteFloodfillImage
  • MagickMedianFilterImage
  • MagickMinifyImage
  • MagickModulateImage
  • MagickMontageImage
  • MagickMorphImages
  • MagickMosaicImages
  • MagickMotionBlurImage
  • MagickNegateImageChannel
  • MagickNegateImage
  • MagickNewDrawingWand
  • MagickNextImage
  • MagickNormalizeImage
  • MagickOilPaintImage
  • MagickOpaqueImage
  • MagickPingImage
  • MagickPreviewImages
  • MagickPreviousImage
  • MagickProfileImage
  • MagickQuantizeImage
  • MagickQuantizeImages
  • MagickQueryFontMetrics
  • MagickQueryFonts
  • MagickQueryFormats
  • MagickRadialBlurImage
  • MagickRaiseImage
  • MagickReadImageBlob
  • MagickReadImageFile
  • MagickReadImage
  • MagickReduceNoiseImage
  • MagickRelinquishMemory
  • MagickRemoveImage
  • MagickRemoveImageProfile
  • MagickResampleImage
  • MagickResetIterator
  • MagickResizeImage
  • MagickRollImage
  • MagickRotateImage
  • MagickSampleImage
  • MagickScaleImage
  • MagickSeparateImageChannel
  • MagickSetCompressionQuality
  • MagickSetDepth
  • MagickSetFilename
  • MagickSetFormat
  • MagickSetImageAttribute
  • MagickSetImageBackgroundColor
  • MagickSetImageBluePrimary
  • MagickSetImageBorderColor
  • MagickSetImageChannelDepth
  • MagickSetImageColormapColor
  • MagickSetImageColorspace
  • MagickSetImageCompose
  • MagickSetImageCompression
  • MagickSetImageDelay
  • MagickSetImageDepth
  • MagickSetImageDispose
  • MagickSetImageFilename
  • MagickSetImageFormat
  • MagickSetImageFuzz
  • MagickSetImageGamma
  • MagickSetImageGravity
  • MagickSetImage
  • MagickSetImageGreenPrimary
  • MagickSetImageIndex
  • MagickSetImageInterlaceScheme
  • MagickSetImageIterations
  • MagickSetImageMatte
  • MagickSetImageMatteColor
  • MagickSetImageOption
  • MagickSetImagePage
  • MagickSetImagePixels
  • MagickSetImageProfile
  • MagickSetImageRedPrimary
  • MagickSetImageRenderingIntent
  • MagickSetImageResolution
  • MagickSetImageSavedType
  • MagickSetImageScene
  • MagickSetImageType
  • MagickSetImageUnits
  • MagickSetImageVirtualPixelMethod
  • MagickSetImageWhitePoint
  • MagickSetInterlaceScheme
  • MagickSetPassphrase
  • MagickSetResolution
  • MagickSetResolutionUnits
  • MagickSetResourceLimit
  • MagickSetSamplingFactors
  • MagickSetSize
  • MagickSharpenImage
  • MagickShaveImage
  • MagickShearImage
  • MagickSolarizeImage
  • MagickSpreadImage
  • MagickSteganoImage
  • MagickStereoImage
  • MagickStripImage
  • MagickSwirlImage
  • MagickTextureImage
  • MagickThresholdImageChannel
  • MagickThresholdImage
  • MagickTintImage
  • MagickTransformImage
  • MagickTransparentImage
  • MagickTrimImage
  • MagickUnsharpMaskImage
  • MagickWaveImage
  • MagickWhiteThresholdImage
  • MagickWriteImageBlob
  • MagickWriteImageFile
  • MagickWriteImage
  • MagickWriteImagesFile
  • MagickWriteImages
  • NewMagickWand
  • NewPixelWand
  • NewPixelWands
  • PixelGetBlack
  • PixelGetBlackQuantum
  • PixelGetBlue
  • PixelGetBlueQuantum
  • PixelGetColorAsString
  • PixelGetColorCount
  • PixelGetCyan
  • PixelGetCyanQuantum
  • PixelGetException
  • PixelGetGreen
  • PixelGetGreenQuantum
  • PixelGetMagenta
  • PixelGetMagentaQuantum
  • PixelGetOpacity
  • PixelGetOpacityQuantum
  • PixelGetQuantumColor
  • PixelGetRed
  • PixelGetRedQuantum
  • PixelGetYellow
  • PixelGetYellowQuantum
  • PixelSetBlack
  • PixelSetBlackQuantum
  • PixelSetBlue
  • PixelSetBlueQuantum
  • PixelSetColorCount
  • PixelSetColor
  • PixelSetCyan
  • PixelSetCyanQuantum
  • PixelSetGreen
  • PixelSetGreenQuantum
  • PixelSetMagenta
  • PixelSetMagentaQuantum
  • PixelSetOpacity
  • PixelSetOpacityQuantum
  • PixelSetQuantumColor
  • PixelSetRed
  • PixelSetRedQuantum
  • PixelSetYellow
  • PixelSetYellowQuantum
  • QueryMagickColor

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Destroy

func Destroy(d types.Destroyer)

Destroy instance of Destroyer If GOGC=off you should call obj.Destroy() manually

func GetCopyright

func GetCopyright() string

Returns the ImageMagick API copyright as a string constant.

func GetHomeURL

func GetHomeURL() string

Returns the ImageMagick home URL.

func GetPackageName

func GetPackageName() string

Returns the ImageMagick package name as a string constant.

func GetQuantumDepth

func GetQuantumDepth() (string, uint)

Returns the ImageMagick quantum depth as a string constant.

func GetReleaseDate

func GetReleaseDate() string

Returns the ImageMagick release date as a string constant.

func GetResourceLimit

func GetResourceLimit(rtype ResourceType) int64

Returns the specified resource limit in megabytes.

func GetVersion

func GetVersion() (string, uint)

Returns the ImageMagick API version as a string constant and as a number.

func Initialize

func Initialize()

Initializes the MagickWand environment

func Terminate

func Terminate()

Terminates the MagickWand environment wait until all imageMagick objects destroyed

Types

type AffineMatrix

type AffineMatrix struct {
	// contains filtered or unexported fields
}

AffineMatrix represents an ImageMagick AffineMatrix struct

func (*AffineMatrix) RotateX

func (a *AffineMatrix) RotateX() float64

RotateX returns the RX value

func (*AffineMatrix) RotateY

func (a *AffineMatrix) RotateY() float64

RotateY returns the RY value

func (*AffineMatrix) ScaleX

func (a *AffineMatrix) ScaleX() float64

ScaleX returns the SX value

func (*AffineMatrix) ScaleY

func (a *AffineMatrix) ScaleY() float64

ScaleY returns the SY value

func (*AffineMatrix) SetRotateX

func (a *AffineMatrix) SetRotateX(val float64)

SetRotateX sets the RX value

func (*AffineMatrix) SetRotateY

func (a *AffineMatrix) SetRotateY(val float64)

SetRotateY sets the RY value

func (*AffineMatrix) SetScaleX

func (a *AffineMatrix) SetScaleX(val float64)

SetScaleX sets the SX value

func (*AffineMatrix) SetScaleY

func (a *AffineMatrix) SetScaleY(val float64)

SetScaleY sets the SY value

func (*AffineMatrix) SetTranslateX

func (a *AffineMatrix) SetTranslateX(val float64)

SetTranslateX sets the TX value

func (*AffineMatrix) SetTranslateY

func (a *AffineMatrix) SetTranslateY(val float64)

SetTranslateY sets the TY value

func (*AffineMatrix) TranslateX

func (a *AffineMatrix) TranslateX() float64

TranslateX returns the TX value

func (*AffineMatrix) TranslateY

func (a *AffineMatrix) TranslateY() float64

TranslateY returns the TY value

type ChannelType

type ChannelType int
const (
	CHANNEL_UNDEFINED ChannelType = C.UndefinedChannel
	CHANNEL_RED       ChannelType = C.RedChannel
	CHANNEL_GRAY      ChannelType = C.GrayChannel
	CHANNEL_CYAN      ChannelType = C.CyanChannel
	CHANNEL_GREEN     ChannelType = C.GreenChannel
	CHANNEL_MAGENTA   ChannelType = C.MagentaChannel
	CHANNEL_BLUE      ChannelType = C.BlueChannel
	CHANNEL_YELLOW    ChannelType = C.YellowChannel
	CHANNEL_OPACITY   ChannelType = C.OpacityChannel
	CHANNEL_BLACK     ChannelType = C.BlackChannel
	CHANNEL_INDEX     ChannelType = C.IndexChannel
	CHANNELS_ALL      ChannelType = C.AllChannels
)

type ClipPathUnits

type ClipPathUnits int
const (
	CLIP_USER_SPACE          ClipPathUnits = C.UserSpace
	CLIP_USER_SPACE_ON_USE   ClipPathUnits = C.UserSpaceOnUse
	CLIP_OBJECT_BOUNDING_BOX ClipPathUnits = C.ObjectBoundingBox
)

type ColorspaceType

type ColorspaceType int
const (
	COLORSPACE_UNDEFINED   ColorspaceType = C.UndefinedColorspace
	COLORSPACE_RGB         ColorspaceType = C.RGBColorspace
	COLORSPACE_GRAY        ColorspaceType = C.GRAYColorspace
	COLORSPACE_TRANSPARENT ColorspaceType = C.TransparentColorspace
	COLORSPACE_OHTA        ColorspaceType = C.OHTAColorspace
	COLORSPACE_XYZ         ColorspaceType = C.XYZColorspace
	COLORSPACE_YCBCR       ColorspaceType = C.YCbCrColorspace
	COLORSPACE_YCC         ColorspaceType = C.YCCColorspace
	COLORSPACE_YIQ         ColorspaceType = C.YIQColorspace
	COLORSPACE_YPBPR       ColorspaceType = C.YPbPrColorspace
	COLORSPACE_YUV         ColorspaceType = C.YUVColorspace
	COLORSPACE_CMYK        ColorspaceType = C.CMYKColorspace
	COLORSPACE_SRGB        ColorspaceType = C.sRGBColorspace
	COLORSPACE_HSL         ColorspaceType = C.HSLColorspace
	COLORSPACE_HWB         ColorspaceType = C.HWBColorspace
	COLORSPACE_REC601LUMA  ColorspaceType = C.Rec601LumaColorspace
	COLORSPACE_REC601YCBCR ColorspaceType = C.Rec601YCbCrColorspace
	COLORSPACE_REC709LUMA  ColorspaceType = C.Rec709LumaColorspace
	COLORSPACE_REC709YCBCR ColorspaceType = C.Rec709YCbCrColorspace
)

type CompositeOperator

type CompositeOperator int
const (
	COMPOSITE_OP_UNDEFINED    CompositeOperator = C.UndefinedCompositeOp
	COMPOSITE_OP_NO           CompositeOperator = C.NoCompositeOp
	COMPOSITE_OP_ATOP         CompositeOperator = C.AtopCompositeOp
	COMPOSITE_OP_BUMPMAP      CompositeOperator = C.BumpmapCompositeOp
	COMPOSITE_OP_CLEAR        CompositeOperator = C.ClearCompositeOp
	COMPOSITE_OP_COLOR_BURN   CompositeOperator = C.ColorBurnCompositeOp
	COMPOSITE_OP_COLOR_DODGE  CompositeOperator = C.ColorDodgeCompositeOp
	COMPOSITE_OP_COLORIZE     CompositeOperator = C.ColorizeCompositeOp
	COMPOSITE_OP_COPY_BLACK   CompositeOperator = C.CopyBlackCompositeOp
	COMPOSITE_OP_COPY_BLUE    CompositeOperator = C.CopyBlueCompositeOp
	COMPOSITE_OP_COPY         CompositeOperator = C.CopyCompositeOp
	COMPOSITE_OP_COPY_CYAN    CompositeOperator = C.CopyCyanCompositeOp
	COMPOSITE_OP_COPY_GREEN   CompositeOperator = C.CopyGreenCompositeOp
	COMPOSITE_OP_COPY_MAGENTA CompositeOperator = C.CopyMagentaCompositeOp
	COMPOSITE_OP_COPY_OPACITY CompositeOperator = C.CopyOpacityCompositeOp
	COMPOSITE_OP_COPY_RED     CompositeOperator = C.CopyRedCompositeOp
	COMPOSITE_OP_COPY_YELLOW  CompositeOperator = C.CopyYellowCompositeOp
	COMPOSITE_OP_DARKEN       CompositeOperator = C.DarkenCompositeOp
	COMPOSITE_OP_DIFFERENCE   CompositeOperator = C.DifferenceCompositeOp
	COMPOSITE_OP_DISPLACE     CompositeOperator = C.DisplaceCompositeOp
	COMPOSITE_OP_DISSOLVE     CompositeOperator = C.DissolveCompositeOp
	COMPOSITE_OP_EXCLUSION    CompositeOperator = C.ExclusionCompositeOp
	COMPOSITE_OP_HARD_LIGHT   CompositeOperator = C.HardLightCompositeOp
	COMPOSITE_OP_HUE          CompositeOperator = C.HueCompositeOp
	COMPOSITE_OP_IN           CompositeOperator = C.InCompositeOp
	COMPOSITE_OP_LIGHTEN      CompositeOperator = C.LightenCompositeOp
	COMPOSITE_OP_LINEAR_LIGHT CompositeOperator = C.LinearLightCompositeOp
	COMPOSITE_OP_LUMINIZE     CompositeOperator = C.LuminizeCompositeOp
	COMPOSITE_OP_MODULATE     CompositeOperator = C.ModulateCompositeOp
	COMPOSITE_OP_MULTIPLY     CompositeOperator = C.MultiplyCompositeOp
	COMPOSITE_OP_OUT          CompositeOperator = C.OutCompositeOp
	COMPOSITE_OP_OVER         CompositeOperator = C.OverCompositeOp
	COMPOSITE_OP_OVERLAY      CompositeOperator = C.OverlayCompositeOp
	COMPOSITE_OP_PLUS         CompositeOperator = C.PlusCompositeOp
	COMPOSITE_OP_REPLACE      CompositeOperator = C.ReplaceCompositeOp
	COMPOSITE_OP_SATURATE     CompositeOperator = C.SaturateCompositeOp
	COMPOSITE_OP_SCREEN       CompositeOperator = C.ScreenCompositeOp
	COMPOSITE_OP_SOFT_LIGHT   CompositeOperator = C.SoftLightCompositeOp
	COMPOSITE_OP_THRESHOLD    CompositeOperator = C.ThresholdCompositeOp
	COMPOSITE_OP_XOR          CompositeOperator = C.XorCompositeOp
	COMPOSITE_OP_VIVID_LIGHT  CompositeOperator = C.VividLightCompositeOp
	COMPOSITE_OP_PIN_LIGHT    CompositeOperator = C.PinLightCompositeOp
	COMPOSITE_OP_LINEAR_DODGE CompositeOperator = C.LinearDodgeCompositeOp
	COMPOSITE_OP_LINEAR_BURN  CompositeOperator = C.LinearBurnCompositeOp
)

type CompressionType

type CompressionType int
const (
	COMPRESSION_UNDEFINED     CompressionType = C.UndefinedCompression
	COMPRESSION_NO            CompressionType = C.NoCompression
	COMPRESSION_BZIP          CompressionType = C.BZipCompression
	COMPRESSION_FAX           CompressionType = C.FaxCompression
	COMPRESSION_GROUP4        CompressionType = C.Group4Compression
	COMPRESSION_JPEG          CompressionType = C.JPEGCompression
	COMPRESSION_JPEG2000      CompressionType = C.JPEG2000Compression
	COMPRESSION_LOSSLESS_JPEG CompressionType = C.LosslessJPEGCompression
	COMPRESSION_LZW           CompressionType = C.LZWCompression
	COMPRESSION_RLE           CompressionType = C.RLECompression
	COMPRESSION_ZIP           CompressionType = C.ZipCompression
	COMPRESSION_LZMA          CompressionType = C.LZMACompression
	COMPRESSION_JBIG1         CompressionType = C.JBIG1Compression
	COMPRESSION_JBIG2         CompressionType = C.JBIG2Compression
)

type DecorationType

type DecorationType int
const (
	DECORATION_NONE         DecorationType = C.NoDecoration
	DECORATION_UNDERLINE    DecorationType = C.UnderlineDecoration
	DECORATION_OVERLINE     DecorationType = C.OverlineDecoration
	DECORATION_LINE_THROUGH DecorationType = C.LineThroughDecoration
)

type DisposeType

type DisposeType int
const (
	DISPOSE_UNDEFINED  DisposeType = C.UndefinedDispose
	DISPOSE_NONE       DisposeType = C.NoneDispose
	DISPOSE_BACKGROUND DisposeType = C.BackgroundDispose
	DISPOSE_PREVIOUS   DisposeType = C.PreviousDispose
)

type DrawingWand

type DrawingWand struct {
	// contains filtered or unexported fields
}

func NewDrawingWand

func NewDrawingWand() *DrawingWand

Returns a drawing wand required for all other methods in the API.

func (*DrawingWand) Affine

func (dw *DrawingWand) Affine(affine *AffineMatrix)

Adjusts the current affine transformation matrix with the specified affine transformation matrix. Note that the current affine transform is adjusted rather than replaced.

affine: Affine matrix parameters

func (*DrawingWand) Annotation

func (dw *DrawingWand) Annotation(x, y float64, text string)

Draws text on the image. x: x ordinate to left of text y: y ordinate to text baseline text: text to draw

func (*DrawingWand) Arc

func (dw *DrawingWand) Arc(sx, sy, ex, ey, sd, ed float64)

Draws an arc falling within a specified bounding rectangle on the image.

sx: starting x ordinate of bounding rectangle

sy: starting y ordinate of bounding rectangle

ex: ending x ordinate of bounding rectangle

ey: ending y ordinate of bounding rectangle

sd: starting degrees of rotation

ed: ending degrees of rotation

func (*DrawingWand) Bezier

func (dw *DrawingWand) Bezier(coordinates []PointInfo)

Draws a bezier curve through a set of points on the image.

func (*DrawingWand) Circle

func (dw *DrawingWand) Circle(ox, oy, px, py float64)

Draws a circle on the image.

ox: origin x ordinate

oy: origin y ordinate

px: perimeter x ordinate

py: perimeter y ordinate

func (*DrawingWand) Clone

func (dw *DrawingWand) Clone() *DrawingWand

Makes an exact copy of the specified wand.

func (*DrawingWand) Color

func (dw *DrawingWand) Color(x, y float64, pm PaintMethod)

Draws color on image using the current fill color, starting at specified position, and using specified paint method. The available paint methods are:

x: x ordinate.

y: y ordinate.

pm: paint method. PointMethod: Recolors the target pixel. ReplaceMethod: Recolor any pixel that matches the target pixel. FloodfillMethod: Recolors target pixels and matching neighbors. ResetMethod: Recolor all pixels.

func (*DrawingWand) Comment

func (dw *DrawingWand) Comment(comment string)

Adds a comment to a vector output stream.

func (*DrawingWand) Composite

func (dw *DrawingWand) Composite(compose CompositeOperator, x, y, width, height float64, mw *MagickWand)

Composites an image onto the current image, using the specified composition operator, specified position, and at the specified size.

compose: composition operator

x: x ordinate of top left corner

y: y ordinate of top left corner

width: Width to resize image to prior to compositing. Specify zero to use existing width.

height: Height to resize image to prior to compositing. Specify zero to use existing height.

mw: Image to composite is obtained from this wand.

func (*DrawingWand) DecreaseCount

func (dw *DrawingWand) DecreaseCount()

Decrease DrawingWand ref counter and set according "can be terminated status"

func (*DrawingWand) Destroy

func (dw *DrawingWand) Destroy()

Frees all resources associated with the drawing wand. Once the drawing wand has been freed, it should not be used and further unless it re-allocated.

func (*DrawingWand) Ellipse

func (dw *DrawingWand) Ellipse(ox, oy, rx, ry, start, end float64)

Draws an ellipse on the image.

ox: origin x ordinate

oy: origin y ordinate

rx: radius in x

ry: radius in y

start: starting rotation in degrees

end: ending rotation in degrees

func (*DrawingWand) GetClipPath

func (dw *DrawingWand) GetClipPath() string

Obtains the current clipping path ID.

func (*DrawingWand) GetClipRule

func (dw *DrawingWand) GetClipRule() FillRule

Returns the current polygon fill rule to be used by the clipping path.

func (*DrawingWand) GetClipUnits

func (dw *DrawingWand) GetClipUnits() ClipPathUnits

Returns the interpretation of clip path units.

func (*DrawingWand) GetFillColor

func (dw *DrawingWand) GetFillColor() (pw *PixelWand)

Returns the fill color used for drawing filled objects.

func (*DrawingWand) GetFillOpacity

func (dw *DrawingWand) GetFillOpacity() float64

Returns the opacity used when drawing using the fill color or fill texture. Fully opaque is 1.0.

func (*DrawingWand) GetFillRule

func (dw *DrawingWand) GetFillRule() FillRule

Returns the fill rule used while drawing polygons.

func (*DrawingWand) GetFont

func (dw *DrawingWand) GetFont() string

Returns a string specifying the font used when annotating with text.

func (*DrawingWand) GetFontFamily

func (dw *DrawingWand) GetFontFamily() string

Returns the font family to use when annotating with text.

func (*DrawingWand) GetFontSize

func (dw *DrawingWand) GetFontSize() float64

func (*DrawingWand) GetFontStretch

func (dw *DrawingWand) GetFontStretch() StretchType

Returns the font stretch used when annotating with text.

func (*DrawingWand) GetFontStyle

func (dw *DrawingWand) GetFontStyle() StyleType

Returns the font style used when annotating with text.

func (*DrawingWand) GetFontWeight

func (dw *DrawingWand) GetFontWeight() uint

Returns the font weight used when annotating with text.

func (*DrawingWand) GetGravity

func (dw *DrawingWand) GetGravity() GravityType

Returns the text placement gravity used when annotating with text.

func (*DrawingWand) GetLastError

func (dw *DrawingWand) GetLastError() error

Returns the kind, reason and description of any error that occurs when using other methods in this API

func (*DrawingWand) GetStrokeAntialias

func (dw *DrawingWand) GetStrokeAntialias() bool

Returns the current stroke antialias setting. Stroked outlines are antialiased by default. When antialiasing is disabled stroked pixels are thresholded to determine if the stroke color or underlying canvas color should be used.

func (*DrawingWand) GetStrokeColor

func (dw *DrawingWand) GetStrokeColor() (pw *PixelWand)

Returns the color used for stroking object outlines.

func (*DrawingWand) GetStrokeDashArray

func (dw *DrawingWand) GetStrokeDashArray() (nums []float64)

Returns an array representing the pattern of dashes and gaps used to stroke paths (see SetStrokeDashArray). The array must be freed once it is no longer required by the user.

func (*DrawingWand) GetStrokeDashOffset

func (dw *DrawingWand) GetStrokeDashOffset() float64

Returns the offset into the dash pattern to start the dash.

func (*DrawingWand) GetStrokeLineCap

func (dw *DrawingWand) GetStrokeLineCap() LineCap

Returns the shape to be used at the end of open subpaths when they are stroked. Values of LineCap are UndefinedCap, ButtCap, RoundCap, and SquareCap.

func (*DrawingWand) GetStrokeLineJoin

func (dw *DrawingWand) GetStrokeLineJoin() LineJoin

Returns the shape to be used at the corners of paths (or other vector shapes) when they are stroked. Values of LineJoin are UndefinedJoin, MiterJoin, RoundJoin, and BevelJoin.

func (*DrawingWand) GetStrokeMiterLimit

func (dw *DrawingWand) GetStrokeMiterLimit() uint

Returns the miter limit. When two line segments meet at a sharp angle and miter joins have been specified for 'lineJoin', it is possible for the miter to extend far beyond the thickness of the line stroking the path. The miterLimit' imposes a limit on the ratio of the miter length to the 'lineWidth'.

func (*DrawingWand) GetStrokeOpacity

func (dw *DrawingWand) GetStrokeOpacity() float64

Returns the opacity of stroked object outlines.

func (*DrawingWand) GetStrokeWidth

func (dw *DrawingWand) GetStrokeWidth() float64

Returns the width of the stroke used to draw object outlines.

func (*DrawingWand) GetTextAntialias

func (dw *DrawingWand) GetTextAntialias() bool

Returns the current text antialias setting, which determines whether text is antialiased. Text is antialiased by default.

func (*DrawingWand) GetTextDecoration

func (dw *DrawingWand) GetTextDecoration() DecorationType

Returns the decoration applied when annotating with text.

func (*DrawingWand) GetTextEncoding

func (dw *DrawingWand) GetTextEncoding() string

Returns a string which specifies the code set used for text annotations.

func (*DrawingWand) GetTextUnderColor

func (dw *DrawingWand) GetTextUnderColor() (pw *PixelWand)

Returns the color of a background rectangle to place under text annotations.

func (*DrawingWand) IncreaseCount

func (dw *DrawingWand) IncreaseCount()

Increase DrawingWand ref counter and set according "can`t be terminated status"

func (*DrawingWand) Line

func (dw *DrawingWand) Line(sx, sy, ex, ey float64)

Draws a line on the image using the current stroke color, stroke opacity, and stroke width.

sx: starting x ordinate

sy: starting y ordinate

ex: ending x ordinate

ey: ending y ordinate

func (*DrawingWand) Matte

func (dw *DrawingWand) Matte(x, y float64, pmethod PaintMethod)

Paints on the image's opacity channel in order to set effected pixels to transparent. to influence the opacity of pixels. The available paint methods are:

	ResetMethod: Select all pixels.

	PointMethod: Select the target pixel

	ReplaceMethod: Select any pixel that matches the target pixel.

	FloodfillMethod: Select the target pixel and matching neighbors.

	FillToBorderMethod: Select the target pixel and neighbors not matching
                     border color.

x, y: x, y ordinates pmethod: paint method

func (*DrawingWand) PathClose

func (dw *DrawingWand) PathClose()

Adds a path element to the current path which closes the current subpath by drawing a straight line from the current point to the current subpath's most recent starting point (usually, the most recent moveto point).

func (*DrawingWand) PathCurveToAbsolute

func (dw *DrawingWand) PathCurveToAbsolute(x1, y1, x2, y2, x, y float64)

Draws a cubic Bezier curve from the current point to (x,y) using (x1,y1) as the control point at the beginning of the curve and (x2,y2) as the control point at the end of the curve using absolute coordinates. At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier.

x1, y1: x, y ordinates of control point for curve beginning

x2, y2: x, y ordinates of control point for curve ending

x, y: x, y ordinates of the end of the curve

func (*DrawingWand) PathCurveToQuadraticBezierAbsolute

func (dw *DrawingWand) PathCurveToQuadraticBezierAbsolute(x1, y1, x, y float64)

Draws a quadratic Bezier curve from the current point to (x,y) using (x1,y1) as the control point using absolute coordinates. At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier.

x1, y1: ordinates of the control point

x, y: ordinates of final point

func (*DrawingWand) PathCurveToQuadraticBezierRelative

func (dw *DrawingWand) PathCurveToQuadraticBezierRelative(x1, y1, x, y float64)

Draws a quadratic Bezier curve from the current point to (x,y) using (x1,y1) as the control point using relative coordinates. At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier. x1, y1: ordinates of the control point x, y: ordinates of final point

func (*DrawingWand) PathCurveToQuadraticBezierSmoothAbsolute

func (dw *DrawingWand) PathCurveToQuadraticBezierSmoothAbsolute(x, y float64)

Draws a quadratic Bezier curve (using absolute coordinates) from the current point to (x,y). The control point is assumed to be the reflection of the control point on the previous command relative to the current point. (If there is no previous command or if the previous command was not a PathCurveToQuadraticBezierAbsolute, PathCurveToQuadraticBezierRelative, PathCurveToQuadraticBezierSmoothAbsolute or PathCurveToQuadraticBezierSmoothRelative, assume the control point is coincident with the current point.). At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier.

x, y: ordinates of final point

func (*DrawingWand) PathCurveToQuadraticBezierSmoothRelative

func (dw *DrawingWand) PathCurveToQuadraticBezierSmoothRelative(x, y float64)

Draws a quadratic Bezier curve (using relative coordinates) from the current point to (x,y). The control point is assumed to be the reflection of the control point on the previous command relative to the current point. (If there is no previous command or if the previous command was not a PathCurveToQuadraticBezierAbsolute, PathCurveToQuadraticBezierRelative, PathCurveToQuadraticBezierSmoothAbsolute or PathCurveToQuadraticBezierSmoothRelative, assume the control point is coincident with the current point.). At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier.

x, y: ordinates of final point

func (*DrawingWand) PathCurveToRelative

func (dw *DrawingWand) PathCurveToRelative(x1, y1, x2, y2, x, y float64)

Draws a cubic Bezier curve from the current point to (x,y) using (x1,y1) as the control point at the beginning of the curve and (x2,y2) as the control point at the end of the curve using relative coordinates. At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier.

x1, y1: x, y ordinates of control point for curve beginning

x2, y2: x, y ordinates of control point for curve ending

x, y: x, y ordinates of the end of the curve

func (*DrawingWand) PathCurveToSmoothAbsolute

func (dw *DrawingWand) PathCurveToSmoothAbsolute(x2, y2, x, y float64)

Draws a cubic Bezier curve from the current point to (x,y) using absolute coordinates. The first control point is assumed to be the reflection of the second control point on the previous command relative to the current point. (If there is no previous command or if the previous command was not an PathCurveToAbsolute, PathCurveToRelative, PathCurveToSmoothAbsolute or PathCurveToSmoothRelative, assume the first control point is coincident with the current point.) (x2,y2) is the second control point (i.e., the control point at the end of the curve). At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier.

x2, y2: ordinates of second control point

x, y: ordinates of termination point

func (*DrawingWand) PathCurveToSmoothRelative

func (dw *DrawingWand) PathCurveToSmoothRelative(x2, y2, x, y float64)

Draws a cubic Bezier curve from the current point to (x,y) using relative coordinates. The first control point is assumed to be the reflection of the second control point on the previous command relative to the current point. (If there is no previous command or if the previous command was not an PathCurveToAbsolute, PathCurveToRelative, PathCurveToSmoothAbsolute or PathCurveToSmoothRelative, assume the first control point is coincident with the current point.) (x2,y2) is the second control point (i.e., the control point at the end of the curve). At the end of the command, the new current point becomes the final (x,y) coordinate pair used in the polybezier.

x2, y2: ordinates of second control point

x, y: ordinates of termination point

func (*DrawingWand) PathEllipticArcAbsolute

func (dw *DrawingWand) PathEllipticArcAbsolute(rx, ry, xAxisRotation float64, largeArcFlag, sweepFlag bool, x, y float64)

Draws an elliptical arc from the current point to (x, y) using absolute coordinates. The size and orientation of the ellipse are defined by two radii (rx, ry) and an xAxisRotation, which indicates how the ellipse as a whole is rotated relative to the current coordinate system. The center (cx, cy) of the ellipse is calculated automagically to satisfy the constraints imposed by the other parameters. largeArcFlag and sweepFlag contribute to the automatic calculations and help determine how the arc is drawn. If largeArcFlag is true then draw the larger of the available arcs. If sweepFlag is true, then draw the arc matching a clock-wise rotation.

rx, ry: x, y radius

xAxisRotation: indicates how the ellipse as a whole is rotated relative to the current coordinate system

largeArcFlag: If true then draw the larger of the available arcs

sweepFlag: If true then draw the arc matching a clock-wise rotation

func (*DrawingWand) PathEllipticArcRelative

func (dw *DrawingWand) PathEllipticArcRelative(rx, ry, xAxisRotation float64, largeArcFlag, sweepFlag bool, x, y float64)

Draws an elliptical arc from the current point to (x, y) using relative coordinates. The size and orientation of the ellipse are defined by two radii (rx, ry) and an xAxisRotation, which indicates how the ellipse as a whole is rotated relative to the current coordinate system. The center (cx, cy) of the ellipse is calculated automagically to satisfy the constraints imposed by the other parameters. largeArcFlag and sweepFlag contribute to the automatic calculations and help determine how the arc is drawn. If largeArcFlag is true then draw the larger of the available arcs. If sweepFlag is true, then draw the arc matching a clock-wise rotation.

rx, ry: x, y radius

xAxisRotation: indicates how the ellipse as a whole is rotated relative to the current coordinate system

largeArcFlag: If true then draw the larger of the available arcs

sweepFlag: If true then draw the arc matching a clock-wise rotation

func (*DrawingWand) PathFinish

func (dw *DrawingWand) PathFinish()

Terminates the current path.

func (*DrawingWand) PathLineToAbsolute

func (dw *DrawingWand) PathLineToAbsolute(x, y float64)

Draws a line path from the current point to the given coordinate using absolute coordinates. The coordinate then becomes the new current point.

x, y: target x and y ordinates

func (*DrawingWand) PathLineToHorizontalAbsolute

func (dw *DrawingWand) PathLineToHorizontalAbsolute(x float64)

Draws a horizontal line path from the current point to the target point using absolute coordinates. The target point then becomes the new current point.

x: target x ordinate

func (*DrawingWand) PathLineToHorizontalRelative

func (dw *DrawingWand) PathLineToHorizontalRelative(x float64)

Draws a horizontal line path from the current point to the target point using relative coordinates. The target point then becomes the new current point.

x: target x ordinate

func (*DrawingWand) PathLineToRelative

func (dw *DrawingWand) PathLineToRelative(x, y float64)

Draws a line path from the current point to the given coordinate using relative coordinates. The coordinate then becomes the new current point.

x, y: target x and y ordinates

func (*DrawingWand) PathLineToVerticalAbsolute

func (dw *DrawingWand) PathLineToVerticalAbsolute(y float64)

Draws a vertical line path from the current point to the target point using absolute coordinates. The target point then becomes the new current point.

y: target y ordinate

func (*DrawingWand) PathLineToVerticalRelative

func (dw *DrawingWand) PathLineToVerticalRelative(y float64)

Draws a vertical line path from the current point to the target point using relative coordinates. The target point then becomes the new current point.

y: target y ordinate

func (*DrawingWand) PathMoveToAbsolute

func (dw *DrawingWand) PathMoveToAbsolute(x, y float64)

Starts a new sub-path at the given coordinate using absolute coordinates. The current point then becomes the specified coordinate.

x, y: target x and y ordinates

func (*DrawingWand) PathMoveToRelative

func (dw *DrawingWand) PathMoveToRelative(x, y float64)

Starts a new sub-path at the given coordinate using relative coordinates. The current point then becomes the specified coordinate.

x, y: target x and y ordinates

func (*DrawingWand) PathStart

func (dw *DrawingWand) PathStart()

Declares the start of a path drawing list which is terminated by a matching PathFinish() command. All other Path commands must be enclosed between a PathStart() and a PathFinish() command. This is because path drawing commands are subordinate commands and they do not function by themselves.

func (*DrawingWand) Point

func (dw *DrawingWand) Point(x, y float64)

Draws a point using the current fill color.

x, y: target x, y coordinates

func (*DrawingWand) Polygon

func (dw *DrawingWand) Polygon(coordinates []PointInfo)

Draws a polygon using the current stroke, stroke width, and fill color or texture, using the specified array of coordinates.

func (*DrawingWand) Polyline

func (dw *DrawingWand) Polyline(coordinates []PointInfo)

Draws a polyline using the current stroke, stroke width, and fill color or texture, using the specified array of coordinates.

func (*DrawingWand) PopClipPath

func (dw *DrawingWand) PopClipPath()

Terminates a clip path definition.

func (*DrawingWand) PopDefs

func (dw *DrawingWand) PopDefs()

Terminates a definition list.

func (*DrawingWand) PopPattern

func (dw *DrawingWand) PopPattern()

Terminates a pattern definition.

func (*DrawingWand) PushClipPath

func (dw *DrawingWand) PushClipPath(clipMaskId string)

Starts a clip path definition which is comprized of any number of drawing commands and terminated by a DrawPopClipPath() command.

clipMaskId: string identifier to associate with the clip path for later use.

func (*DrawingWand) PushDefs

func (dw *DrawingWand) PushDefs()

Indicates that commands up to a terminating PopDefs() command create named elements (e.g. clip-paths, textures, etc.) which may safely be processed earlier for the sake of efficiency.

func (*DrawingWand) PushPattern

func (dw *DrawingWand) PushPattern(patternId string, x, y, width, height float64)

Indicates that subsequent commands up to a PopPattern() command comprise the definition of a named pattern. The pattern space is assigned top left corner coordinates, a width and height, and becomes its own drawing space. Anything which can be drawn may be used in a pattern definition. Named patterns may be used as stroke or brush definitions.

patternId: pattern identification for later reference

x, y: ordinates of top left corner

width, height of pattern space

func (*DrawingWand) Rectangle

func (dw *DrawingWand) Rectangle(x1, y1, x2, y2 float64)

Draws a rectangle given two coordinates and using the current stroke, stroke width, and fill settings.

x1, y1: ordinates of first coordinate

x2, y2: ordinates of second coordinate

func (*DrawingWand) Rotate

func (dw *DrawingWand) Rotate(degrees float64)

Applies the specified rotation to the current coordinate space.

degrees: degrees of rotation

func (*DrawingWand) RoundRectangle

func (dw *DrawingWand) RoundRectangle(x1, y1, x2, y2, rx, ry float64)

Draws a rounted rectangle given two coordinates, x & y corner radiuses and using the current stroke, stroke width, and fill settings.

x1, y1: ordinates of first coordinate

x2, y2: ordinates of second coordinate

rx, ry: radius of corner in horizontal and vertical directions

func (*DrawingWand) Scale

func (dw *DrawingWand) Scale(x, y float64)

Adjusts the scaling factor to apply in the horizontal and vertical directions to the current coordinate space.

x: horizontal scale factor

y: vertical scale factor

func (*DrawingWand) SetClipPath

func (dw *DrawingWand) SetClipPath(clipMaskId string)

Associates a named clipping path with the image. Only the areas drawn on by the clipping path will be modified as C.ssize_t(as) it remains in effect. clipMaskId: name of clipping path to associate with image

func (*DrawingWand) SetClipRule

func (dw *DrawingWand) SetClipRule(fillRule FillRule)

Set the polygon fill rule to be used by the clipping path.

func (*DrawingWand) SetClipUnits

func (dw *DrawingWand) SetClipUnits(clipUnits ClipPathUnits)

Sets the interpretation of clip path units. clipUnits: units to use

func (*DrawingWand) SetFillColor

func (dw *DrawingWand) SetFillColor(fillWand *PixelWand)

Sets the fill color to be used for drawing filled objects.

func (*DrawingWand) SetFillOpacity

func (dw *DrawingWand) SetFillOpacity(opacity float64)

Sets the opacity to use when drawing using the fill color or fill texture. Fully opaque is 1.0.

func (*DrawingWand) SetFillPatternURL

func (dw *DrawingWand) SetFillPatternURL(fillUrl string)

Sets the URL to use as a fill pattern for filling objects. Only local URLs ("#identifier") are supported at this time. These local URLs are normally created by defining a named fill pattern with PushPattern/PopPattern.

fillUrl: URL to use to obtain fill pattern.

func (*DrawingWand) SetFillRule

func (dw *DrawingWand) SetFillRule(fillRule FillRule)

Sets the fill rule to use while drawing polygons.

func (*DrawingWand) SetFont

func (dw *DrawingWand) SetFont(fontName string)

Sets the fully-sepecified font to use when annotating with text.

func (*DrawingWand) SetFontFamily

func (dw *DrawingWand) SetFontFamily(fontFamily string)

Sets the font family to use when annotating with text.

func (*DrawingWand) SetFontSize

func (dw *DrawingWand) SetFontSize(pointSize float64)

Sets the font pointsize to use when annotating with text.

pointSize: text pointsize

func (*DrawingWand) SetFontStretch

func (dw *DrawingWand) SetFontStretch(fontStretch StretchType)

Sets the font stretch to use when annotating with text. The AnyStretch enumeration acts as a wild-card "don't care" option.

func (*DrawingWand) SetFontStyle

func (dw *DrawingWand) SetFontStyle(style StyleType)

Sets the font style to use when annotating with text. The AnyStyle enumeration acts as a wild-card "don't care" option.

func (*DrawingWand) SetFontWeight

func (dw *DrawingWand) SetFontWeight(fontWeight uint)

Sets the font weight to use when annotating with text.

fontWeight: font weight (valid range 100-900)

func (*DrawingWand) SetGravity

func (dw *DrawingWand) SetGravity(gravity GravityType)

Sets the text placement gravity to use when annotating with text.

func (*DrawingWand) SetStrokeAntialias

func (dw *DrawingWand) SetStrokeAntialias(antialias bool)

Controls whether stroked outlines are antialiased. Stroked outlines are antialiased by default. When antialiasing is disabled stroked pixels are thresholded to determine if the stroke color or underlying canvas color should be used.

antialias: set to false to disable antialiasing

func (*DrawingWand) SetStrokeColor

func (dw *DrawingWand) SetStrokeColor(strokeWand *PixelWand)

Sets the color used for stroking object outlines.

func (*DrawingWand) SetStrokeDashArray

func (dw *DrawingWand) SetStrokeDashArray(dash []float64)

Specifies the pattern of dashes and gaps used to stroke paths. The stroke dash array represents an array of numbers that specify the lengths of alternating dashes and gaps in pixels. If an odd number of values is provided, then the list of values is repeated to yield an even number of values. To remove an existing dash array, pass an empty slice. A typical stroke dash array might contain the members 5 3 2.

func (*DrawingWand) SetStrokeDashOffset

func (dw *DrawingWand) SetStrokeDashOffset(offset float64)

Specifies the offset into the dash pattern to start the dash.

func (*DrawingWand) SetStrokeLineCap

func (dw *DrawingWand) SetStrokeLineCap(lineCap LineCap)

Specifies the shape to be used at the end of open subpaths when they are stroked.

func (*DrawingWand) SetStrokeLineJoin

func (dw *DrawingWand) SetStrokeLineJoin(lineJoin LineJoin)

Specifies the shape to be used at the corners of paths (or other vector shapes) when they are stroked.

func (*DrawingWand) SetStrokeMiterLimit

func (dw *DrawingWand) SetStrokeMiterLimit(miterLimit uint)

Specifies the miter limit. When two line segments meet at a sharp angle and miter joins have been specified for 'lineJoin', it is possible for the miter to extend far beyond the thickness of the line stroking the path. The miterLimit' imposes a limit on the ratio of the miter length to the 'lineWidth'.

func (*DrawingWand) SetStrokeOpacity

func (dw *DrawingWand) SetStrokeOpacity(opacity float64)

Specifies the opacity of stroked object outlines.

opacity: stroke opacity. The value 1.0 is opaque.

func (*DrawingWand) SetStrokePatternURL

func (dw *DrawingWand) SetStrokePatternURL(strokeUrl string)

Sets the pattern used for stroking object outlines.

strokeUrl: URL specifying pattern ID (e.g. "#pattern_id")

func (*DrawingWand) SetStrokeWidth

func (dw *DrawingWand) SetStrokeWidth(width float64)

Sets the width of the stroke used to draw object outlines.

func (*DrawingWand) SetTextAntialias

func (dw *DrawingWand) SetTextAntialias(antialias bool)

Controls whether text is antialiased. Text is antialiased by default.

func (*DrawingWand) SetTextDecoration

func (dw *DrawingWand) SetTextDecoration(decoration DecorationType)

Specifies a decoration to be applied when annotating with text.

func (*DrawingWand) SetTextEncoding

func (dw *DrawingWand) SetTextEncoding(encoding string)

Specifies the code set to use for text annotations. The only character encoding which may be specified at this time is "UTF-8" for representing Unicode as a sequence of bytes. Specify an empty string to set text encoding to the system's default. Successful text annotation using Unicode may require fonts designed to support Unicode.

func (*DrawingWand) SetTextUnderColor

func (dw *DrawingWand) SetTextUnderColor(underWand *PixelWand)

Specifies the color of a background rectangle to place under text annotations.

func (*DrawingWand) SetViewbox

func (dw *DrawingWand) SetViewbox(x1, y1, x2, y2 uint)

Sets the overall canvas size to be recorded with the drawing vector data. Usually this will be specified using the same size as the canvas image. When the vector data is saved to SVG or MVG formats, the viewbox is use to specify the size of the canvas image that a viewer will render the vector data on.

x1: left x ordinate

y1: top y ordinate

x2: right x ordinate

y2: bottom y ordinate

func (*DrawingWand) SkewX

func (dw *DrawingWand) SkewX(degrees float64)

Skews the current coordinate system in the horizontal direction.

degrees: number of degrees to skew the coordinates

func (*DrawingWand) SkewY

func (dw *DrawingWand) SkewY(degrees float64)

Skews the current coordinate system in the vertical direction.

degrees: number of degrees to skew the coordinates

func (*DrawingWand) Translate

func (dw *DrawingWand) Translate(x, y float64)

Applies a translation to the current coordinate system which moves the coordinate system origin to the specified coordinate.

x, y: new x, y ordinate for coordinate system origin

type DrawingWandException

type DrawingWandException struct {
	// contains filtered or unexported fields
}

func (*DrawingWandException) Error

func (dwe *DrawingWandException) Error() string

type ExceptionType

type ExceptionType int
const (
	EXCEPTION_UNDEFINED          ExceptionType = C.UndefinedException
	EXCEPTION_WARNING            ExceptionType = C.WarningException
	WARNING_RESOURCE_LIMIT       ExceptionType = C.ResourceLimitWarning
	WARNING_TYPE                 ExceptionType = C.TypeWarning
	WARNING_OPTION               ExceptionType = C.OptionWarning
	WARNING_DELEGATE             ExceptionType = C.DelegateWarning
	WARNING_MISSING_DELEGATE     ExceptionType = C.MissingDelegateWarning
	WARNING_CORRUPT_IMAGE        ExceptionType = C.CorruptImageWarning
	WARNING_FILE_OPEN            ExceptionType = C.FileOpenWarning
	WARNING_BLOB                 ExceptionType = C.BlobWarning
	WARNING_STREAM               ExceptionType = C.StreamWarning
	WARNING_CACHE                ExceptionType = C.CacheWarning
	WARNING_CODER                ExceptionType = C.CoderWarning
	WARNING_MODULE               ExceptionType = C.ModuleWarning
	WARNING_DRAW                 ExceptionType = C.DrawWarning
	WARNING_IMAGE                ExceptionType = C.ImageWarning
	WARNING_WAND                 ExceptionType = C.WandWarning
	WARNING_XSERVER              ExceptionType = C.XServerWarning
	WARNING_MONITOR              ExceptionType = C.MonitorWarning
	WARNING_REGISTRY             ExceptionType = C.RegistryWarning
	WARNING_CONFIGURE            ExceptionType = C.ConfigureWarning
	EXCEPTION_ERROR              ExceptionType = C.ErrorException
	ERROR_RESOURCE_LIMIT         ExceptionType = C.ResourceLimitError
	ERROR_TYPE                   ExceptionType = C.TypeError
	ERROR_OPTION                 ExceptionType = C.OptionError
	ERROR_DELEGATE               ExceptionType = C.DelegateError
	ERROR_MISSING_DELEGATE       ExceptionType = C.MissingDelegateError
	ERROR_CORRUPT_IMAGE          ExceptionType = C.CorruptImageError
	ERROR_FILE_OPEN              ExceptionType = C.FileOpenError
	ERROR_BLOB                   ExceptionType = C.BlobError
	ERROR_STREAM                 ExceptionType = C.StreamError
	ERROR_CACHE                  ExceptionType = C.CacheError
	ERROR_CODER                  ExceptionType = C.CoderError
	ERROR_MODULE                 ExceptionType = C.ModuleError
	ERROR_DRAW                   ExceptionType = C.DrawError
	ERROR_IMAGE                  ExceptionType = C.ImageError
	ERROR_WAND                   ExceptionType = C.WandError
	ERROR_XSERVER                ExceptionType = C.XServerError
	ERROR_MONITOR                ExceptionType = C.MonitorError
	ERROR_REGISTRY               ExceptionType = C.RegistryError
	ERROR_CONFIGURE              ExceptionType = C.ConfigureError
	EXCEPTION_FATAL_ERROR        ExceptionType = C.FatalErrorException
	FATAL_ERROR_RESOURCE_LIMIT   ExceptionType = C.ResourceLimitFatalError
	FATAL_ERROR_TYPE             ExceptionType = C.TypeFatalError
	FATAL_ERROR_OPTION           ExceptionType = C.OptionFatalError
	FATAL_ERROR_DELEGATE         ExceptionType = C.DelegateFatalError
	FATAL_ERROR_MISSING_DELEGATE ExceptionType = C.MissingDelegateFatalError
	FATAL_ERROR_CORRUPT_IMAGE    ExceptionType = C.CorruptImageFatalError
	FATAL_ERROR_FILE_OPEN        ExceptionType = C.FileOpenFatalError
	FATAL_ERROR_BLOB             ExceptionType = C.BlobFatalError
	FATAL_ERROR_STREAM           ExceptionType = C.StreamFatalError
	FATAL_ERROR_CACHE            ExceptionType = C.CacheFatalError
	FATAL_ERROR_CODER            ExceptionType = C.CoderFatalError
	FATAL_ERROR_MODULE           ExceptionType = C.ModuleFatalError
	FATAL_ERROR_DRAW             ExceptionType = C.DrawFatalError
	FATAL_ERROR_IMAGE            ExceptionType = C.ImageFatalError
	FATAL_ERROR_WAND             ExceptionType = C.WandFatalError
	FATAL_ERROR_XSERVER          ExceptionType = C.XServerFatalError
	FATAL_ERROR_MONITOR          ExceptionType = C.MonitorFatalError
	FATAL_ERROR_REGISTRY         ExceptionType = C.RegistryFatalError
	FATAL_ERROR_CONFIGURE        ExceptionType = C.ConfigureFatalError
)

func (*ExceptionType) String

func (et *ExceptionType) String() string

type FillRule

type FillRule int
const (
	FILL_UNDEFINED FillRule = C.UndefinedRule
	FILL_EVEN_ODD  FillRule = C.EvenOddRule
	FILL_NON_ZERO  FillRule = C.NonZeroRule
)

type FilterType

type FilterType int
const (
	FILTER_UNDEFINED FilterType = C.UndefinedFilter
	FILTER_POINT     FilterType = C.PointFilter
	FILTER_BOX       FilterType = C.BoxFilter
	FILTER_TRIANGLE  FilterType = C.TriangleFilter
	FILTER_HERMITE   FilterType = C.HermiteFilter
	FILTER_HANNING   FilterType = C.HanningFilter
	FILTER_HAMMING   FilterType = C.HammingFilter
	FILTER_BLACKMAN  FilterType = C.BlackmanFilter
	FILTER_GAUSSIAN  FilterType = C.GaussianFilter
	FILTER_QUADRATIC FilterType = C.QuadraticFilter
	FILTER_CUBIC     FilterType = C.CubicFilter
	FILTER_CATROM    FilterType = C.CatromFilter
	FILTER_MITCHELL  FilterType = C.MitchellFilter
	FILTER_SINC      FilterType = C.SincFilter
	FILTER_LANCZOS   FilterType = C.LanczosFilter
)

type FontMetrics

type FontMetrics struct {
	CharacterWidth           float64
	CharacterHeight          float64
	Ascender                 float64
	Descender                float64
	TextWidth                float64
	TextHeight               float64
	MaximumHorizontalAdvance float64
}

% Element Description % ------------------------------------------------- % 0 character width % 1 character height % 2 ascender % 3 descender % 4 text width % 5 text height % 6 maximum horizontal advance

func NewFontMetricsFromArray

func NewFontMetricsFromArray(arr []float64) *FontMetrics

type GravityType

type GravityType int
const (
	GRAVITY_FORGET     GravityType = C.ForgetGravity
	GRAVITY_NORTH_WEST GravityType = C.NorthWestGravity
	GRAVITY_NORTH      GravityType = C.NorthGravity
	GRAVITY_NORTH_EAST GravityType = C.NorthEastGravity
	GRAVITY_WEST       GravityType = C.WestGravity
	GRAVITY_CENTER     GravityType = C.CenterGravity
	GRAVITY_EAST       GravityType = C.EastGravity
	GRAVITY_SOUTH_WEST GravityType = C.SouthWestGravity
	GRAVITY_SOUTH      GravityType = C.SouthGravity
	GRAVITY_SOUTH_EAST GravityType = C.SouthEastGravity
	GRAVITY_STATIC     GravityType = C.StaticGravity
)

type ImageType

type ImageType int
const (
	IMAGE_TYPE_UNDEFINED              ImageType = C.UndefinedType
	IMAGE_TYPE_BILEVEL                ImageType = C.BilevelType
	IMAGE_TYPE_GRAYSCALE              ImageType = C.GrayscaleType
	IMAGE_TYPE_GRAYSCALE_MATTE        ImageType = C.GrayscaleMatteType
	IMAGE_TYPE_PALETTE                ImageType = C.PaletteType
	IMAGE_TYPE_PALETTE_MATTE          ImageType = C.PaletteMatteType
	IMAGE_TYPE_TRUE_COLOR             ImageType = C.TrueColorType
	IMAGE_TYPE_TRUE_COLOR_MATTE       ImageType = C.TrueColorMatteType
	IMAGE_TYPE_COLOR_SEPARATION       ImageType = C.ColorSeparationType
	IMAGE_TYPE_COLOR_SEPARATION_MATTE ImageType = C.ColorSeparationMatteType
	IMAGE_TYPE_OPTIMIZE               ImageType = C.OptimizeType
)

type InterlaceType

type InterlaceType int
const (
	INTERLACE_UNDEFINED InterlaceType = C.UndefinedInterlace
	INTERLACE_NO        InterlaceType = C.NoInterlace
	INTERLACE_LINE      InterlaceType = C.LineInterlace
	INTERLACE_PLANE     InterlaceType = C.PlaneInterlace
	INTERLACE_PARTITION InterlaceType = C.PartitionInterlace
)

type LineCap

type LineCap int
const (
	LINE_CAP_UNDEFINED LineCap = C.UndefinedCap
	LINE_CAP_BUTT      LineCap = C.ButtCap
	LINE_CAP_ROUND     LineCap = C.RoundCap
	LINE_CAP_SQUARE    LineCap = C.SquareCap
)

type LineJoin

type LineJoin int
const (
	LINE_JOIN_UNDEFINED LineJoin = C.UndefinedJoin
	LINE_JOIN_MITER     LineJoin = C.MiterJoin
	LINE_JOIN_ROUND     LineJoin = C.RoundJoin
	LINE_JOIN_BEVEL     LineJoin = C.BevelJoin
)

type MagickWand

type MagickWand struct {
	// contains filtered or unexported fields
}

This struct represents the MagickWand C API of GraphicsMagick

func NewMagickWand

func NewMagickWand() *MagickWand

Returns a wand required for all other methods in the API. A fatal exception is thrown if there is not enough memory to allocate the wand.

func (*MagickWand) AdaptiveThresholdImage

func (mw *MagickWand) AdaptiveThresholdImage(width, height uint, offset int) error

Selects an individual threshold for each pixel based on the range of intensity values in its local neighborhood. This allows for thresholding of an image whose global intensity histogram doesn't contain distinctive peaks.

func (*MagickWand) AddImage

func (mw *MagickWand) AddImage(wand *MagickWand) error

Adds a clone of the images from the second wand and inserts them into the first wand. Use SetLastIterator(), to append new images into an existing wand, current image will be set to last image so later adds with also be appened to end of wand. Use SetFirstIterator() to prepend new images into wand, any more images added will also be prepended before other images in the wand. However the order of a list of new images will not change. Otherwise the new images will be inserted just after the current image, and any later image will also be added after this current image but before the previously added images. Caution is advised when multiple image adds are inserted into the middle of the wand image list.

func (*MagickWand) AddNoiseImage

func (mw *MagickWand) AddNoiseImage(noiseType NoiseType) error

Adds random noise to the image

func (*MagickWand) AffineTransformImage

func (mw *MagickWand) AffineTransformImage(drawingWand *DrawingWand) error

Transforms an image as dictaded by the affine matrix of the drawing wand

func (*MagickWand) AnimateImages

func (mw *MagickWand) AnimateImages(server string) error

Animates an image or image sequence

func (*MagickWand) AnnotateImage

func (mw *MagickWand) AnnotateImage(drawingWand *DrawingWand, x, y, angle float64, text string) error

Annotates an image with text

x: ordinate to left of text

y: ordinate to text baseline

angle: rotate text relative to this angle

func (*MagickWand) AppendImages

func (mw *MagickWand) AppendImages(topToBottom bool) *MagickWand

Append the images in a wand from the current image onwards, creating a new wand with the single image result. This is affected by the gravity and background setting of the first image. Typically you would call either ResetIterator() or SetFirstImage() before calling this function to ensure that all the images in the wand's image list will be appended together. By default, images are stacked left-to-right. Set topToBottom to true to stack them top-to-bottom.

func (*MagickWand) AverageImages

func (mw *MagickWand) AverageImages() *MagickWand

Average a set of images

func (*MagickWand) BlackThresholdImage

func (mw *MagickWand) BlackThresholdImage(threshold *PixelWand) error

This is like ThresholdImage() but forces all pixels below the threshold into black while leaving all pixels above the threshold unchanged.

func (*MagickWand) BlurImage

func (mw *MagickWand) BlurImage(radius, sigma float64) error

Blurs an image. We convolve the image with a gaussian operator of the given radius and standard deviation (sigma). For reasonable results, the radius should be larger than sigma. Use a radius of 0 and BlurImage() selects a suitable radius for you.

radius: the radius of the, in pixels, not counting the center pixel.

sigma: the standard deviation of the, in pixels

func (*MagickWand) BorderImage

func (mw *MagickWand) BorderImage(borderColor *PixelWand, width, height uint) error

Surrounds the image with a border of the color defined by the bordercolor pixel wand.

func (*MagickWand) CharcoalImage

func (mw *MagickWand) CharcoalImage(radius, sigma float64) error

Simulates a charcoal drawing

radius: the radius of the Gaussian, in pixels, not counting the center pixel

sigma: the standard deviation of the Gaussian, in pixels

func (*MagickWand) ChopImage

func (mw *MagickWand) ChopImage(width, height uint, x, y int) error

Removes a region of an image and collapses the image to occupy the removed portion.

width, height: the region width and height

x, y: the region x and y offsets

func (*MagickWand) ClipImage

func (mw *MagickWand) ClipImage() error

Clips along the first path from the 8BIM profile, if present

func (*MagickWand) Clone

func (mw *MagickWand) Clone() *MagickWand

Makes an exact copy of the MagickWand object

func (*MagickWand) CoalesceImages

func (mw *MagickWand) CoalesceImages() *MagickWand

Composites a set of images while respecting any page offsets and disposal methods. GIF, MIFF, and MNG animation sequences typically start with an image background and each subsequent image varies in size and offset. CoalesceImages() returns a new sequence where each image in the sequence is the same size as the first and composited with the next image in the sequence.

func (*MagickWand) ColorizeImage

func (mw *MagickWand) ColorizeImage(colorize, opacity *PixelWand) error

Blends the fill color with each pixel in the image

func (*MagickWand) CommentImage

func (mw *MagickWand) CommentImage(comment string) error

Adds a comment to your image

func (*MagickWand) CompareImageChannels

func (mw *MagickWand) CompareImageChannels(reference *MagickWand, channel ChannelType, metric MetricType) (wand *MagickWand, distortion float64)

Compares one or more image channels of an image to a reconstructed image and returns the difference image

func (*MagickWand) CompareImages

func (mw *MagickWand) CompareImages(reference *MagickWand, metric MetricType) (wand *MagickWand, distortion float64)

CompareImages() compares an image to a reconstructed image and returns the specified difference image. Returns the new MagickWand and the computed distortion between the images

func (*MagickWand) CompositeImage

func (mw *MagickWand) CompositeImage(source *MagickWand, compose CompositeOperator, x, y int) error

Composite one image onto another at the specified offset. source: The magick wand holding source image. compose: This operator affects how the composite is applied to the image. The default is Over.

x: the column offset of the composited image.

y: the row offset of the composited image.

func (*MagickWand) ContrastImage

func (mw *MagickWand) ContrastImage(sharpen bool) error

Enhances the intensity differences between the lighter and darker elements of the image. Set sharpen to a value other than 0 to increase the image contrast otherwise the contrast is reduced.

sharpen: increase or decrease image contrast

func (*MagickWand) ConvolveImage

func (mw *MagickWand) ConvolveImage(order uint, kernel []float64) error

Applies a custom convolution kernel to the image.

order: the number of cols and rows in the filter kernel

kernel: an array of doubles, representing the convolution kernel

func (*MagickWand) CropImage

func (mw *MagickWand) CropImage(width, height uint, x, y int) error

Extracts a region of the image

func (*MagickWand) CycleColormapImage

func (mw *MagickWand) CycleColormapImage(displace int) error

Displaces an Image's colormap by a given number of positions. If you cycle the colormap a number of times you can produce a psychodelic effect.

func (*MagickWand) DeconstructImages

func (mw *MagickWand) DeconstructImages() *MagickWand

Compares each image with the next in a sequence and returns the maximum bouding region of any pixel differences it discovers.

func (*MagickWand) DecreaseCount

func (mw *MagickWand) DecreaseCount()

Decrease MagickWand ref counter and set according "can be terminated status"

func (*MagickWand) DescribeImage

func (mw *MagickWand) DescribeImage() string

Describes an image by formatting its attributes to an allocated string which must be freed by the user. Attributes include the image width, height, size, and others. The string is similar to the output of 'identify -verbose'.

func (*MagickWand) DespeckleImage

func (mw *MagickWand) DespeckleImage() error

Reduces the speckle noise in an image while perserving the edges of the original image.

func (*MagickWand) Destroy

func (mw *MagickWand) Destroy()

Deallocates memory associated with an MagickWand

func (*MagickWand) DisplayImage

func (mw *MagickWand) DisplayImage(server string) error

Displays and image

func (*MagickWand) DisplayImages

func (mw *MagickWand) DisplayImages(server string) error

Displays and image or image sequence

func (*MagickWand) DrawImage

func (mw *MagickWand) DrawImage(dw *DrawingWand) error

Draws vectors on the image as described by DrawingWand.

func (*MagickWand) EdgeImage

func (mw *MagickWand) EdgeImage(radius float64) error

Enhance edges within the image with a convolution filter of the given radius. Use a radius of 0 and Edge() selects a suitable radius for you.

radius: the radius of the pixel neighborhood

func (*MagickWand) EmbossImage

func (mw *MagickWand) EmbossImage(radius, sigma float64) error

Returns a grayscale image with a three-dimensional effect. We convolve the image with a Gaussian operator of the given radius and standard deviation (sigma). For reasonable results, radius should be larger than sigma. Use a radius of 0 and Emboss() selects a suitable radius for you.

radius: the radius of the Gaussian, in pixels, not counting the center pixel

sigma: the standard deviation of the Gaussian, in pixels

func (*MagickWand) EnhanceImage

func (mw *MagickWand) EnhanceImage() error

Applies a digital filter that improves the quality of a noisy image

func (*MagickWand) EqualizeImage

func (mw *MagickWand) EqualizeImage() error

Equalizes the image histogram.

func (*MagickWand) ExtentImage

func (mw *MagickWand) ExtentImage(width, height uint, x, y int) error

Extends the image as defined by the geometry, gravitt, and wand background color. Set the (x,y) offset of the geometry to move the original wand relative to the extended wand.

width: the region width.

height: the region height.

x: the region x offset.

y: the region y offset.

func (*MagickWand) FlipImage

func (mw *MagickWand) FlipImage() error

Creates a vertical mirror image by reflecting the pixels around the central x-axis.

func (*MagickWand) FlopImage

func (mw *MagickWand) FlopImage() error

Creates a horizontal mirror image by reflecting the pixels around the central y-axis.

func (*MagickWand) FrameImage

func (mw *MagickWand) FrameImage(matteColor *PixelWand, width, height uint, innerBevel, outerBevel int) error

Adds a simulated three-dimensional border around the image. The width and height specify the border width of the vertical and horizontal sides of the frame. The inner and outer bevels indicate the width of the inner and outer shadows of the frame.

matteColor: the frame color pixel wand.

width: the border width.

height: the border height.

innerBevel: the inner bevel width.

outerBevel: the outer bevel width.

func (*MagickWand) FxImage

func (mw *MagickWand) FxImage(expression string) (fxmw *MagickWand, err error)

Evaluate expression for each pixel in the image.

func (*MagickWand) FxImageChannel

func (mw *MagickWand) FxImageChannel(channel ChannelType, expression string) *MagickWand

Evaluate expression for each pixel in the image's channel

func (*MagickWand) GammaImage

func (mw *MagickWand) GammaImage(gamma float64) error

Gamma-corrects an image. The same image viewed on different devices will have perceptual differences in the way the image's intensities are represented on the screen. Specify individual gamma levels for the red, green, and blue channels, or adjust all three with the gamma parameter. Values typically range from 0.8 to 2.3. You can also reduce the influence of a particular channel with a gamma value of 0.

func (*MagickWand) GammaImageChannel

func (mw *MagickWand) GammaImageChannel(channel ChannelType, gamma float64) error

Gamma-corrects an image's channel. The same image viewed on different devices will have perceptual differences in the way the image's intensities are represented on the screen. Specify individual gamma levels for the red, green, and blue channels, or adjust all three with the gamma parameter. Values typically range from 0.8 to 2.3. You can also reduce the influence of a particular channel with a gamma value of 0.

func (*MagickWand) GetFilename

func (mw *MagickWand) GetFilename() string

Returns the filename associated with an image sequence.

func (*MagickWand) GetImage

func (mw *MagickWand) GetImage() *MagickWand

Gets the image at the current image index.

func (*MagickWand) GetImageAttribute

func (mw *MagickWand) GetImageAttribute(attributeName string) string

Returns an image attribute as a string

func (*MagickWand) GetImageBackgroundColor

func (mw *MagickWand) GetImageBackgroundColor() (bgColor *PixelWand, err error)

Returns the image background color.

func (*MagickWand) GetImageBluePrimary

func (mw *MagickWand) GetImageBluePrimary() (x, y float64, err error)

Returns the chromaticy blue primary point for the image.

x: the chromaticity blue primary x-point.

y: the chromaticity blue primary y-point.

func (*MagickWand) GetImageBorderColor

func (mw *MagickWand) GetImageBorderColor() (borderColor *PixelWand, err error)

Returns the image border color.

func (*MagickWand) GetImageChannelDepth

func (mw *MagickWand) GetImageChannelDepth(channel ChannelType) uint

Gets the depth for one or more image channels.

func (*MagickWand) GetImageChannelMean

func (mw *MagickWand) GetImageChannelMean(channel ChannelType) (mean, stdev float64, err error)

Gets the mean and standard deviation of one or more image channels.

func (*MagickWand) GetImageColormapColor

func (mw *MagickWand) GetImageColormapColor(index uint) (color *PixelWand, err error)

Returns the color of the specified colormap index.

func (*MagickWand) GetImageColors

func (mw *MagickWand) GetImageColors() uint

Gets the number of unique colors in the image.

func (*MagickWand) GetImageColorspace

func (mw *MagickWand) GetImageColorspace() ColorspaceType

Gets the image colorspace.

func (*MagickWand) GetImageCompose

func (mw *MagickWand) GetImageCompose() CompositeOperator

Returns the composite operator associated with the image.

func (*MagickWand) GetImageCompression

func (mw *MagickWand) GetImageCompression() CompressionType

Gets the image compression.

func (*MagickWand) GetImageDelay

func (mw *MagickWand) GetImageDelay() uint

Gets the image delay.

func (*MagickWand) GetImageDepth

func (mw *MagickWand) GetImageDepth() uint

Gets the image depth.

func (*MagickWand) GetImageDispose

func (mw *MagickWand) GetImageDispose() DisposeType

Gets the image disposal method.

func (*MagickWand) GetImageFilename

func (mw *MagickWand) GetImageFilename() string

Returns the filename of a particular image in a sequence.

func (*MagickWand) GetImageFormat

func (mw *MagickWand) GetImageFormat() string

Returns the format of a particular image in a sequence.

func (*MagickWand) GetImageFuzz

func (mw *MagickWand) GetImageFuzz() float64

Gets the image fuzz.

func (*MagickWand) GetImageGamma

func (mw *MagickWand) GetImageGamma() float64

Gets the image gamma.

func (*MagickWand) GetImageGravity

func (mw *MagickWand) GetImageGravity() GravityType

Gets the image gravity.

func (*MagickWand) GetImageGreenPrimary

func (mw *MagickWand) GetImageGreenPrimary() (x, y float64, err error)

Returns the chromaticy green primary point.

x: the chromaticity green primary x-point.

y: the chromaticity green primary y-point.

func (*MagickWand) GetImageHeight

func (mw *MagickWand) GetImageHeight() uint

Returns the image height.

func (*MagickWand) GetImageHistogram

func (mw *MagickWand) GetImageHistogram() (numberColors uint, pws []PixelWand)

Returns the image histogram as an array of PixelWand wands.

numberColors: the number of unique colors in the image and the number of pixel wands returned.

func (*MagickWand) GetImageIndex

func (mw *MagickWand) GetImageIndex() uint

Returns the position of the iterator in the image list

func (*MagickWand) GetImageInterlaceScheme

func (mw *MagickWand) GetImageInterlaceScheme() InterlaceType

Gets the image interlace scheme.

func (*MagickWand) GetImageIterations

func (mw *MagickWand) GetImageIterations() uint

Gets the image iterations.

func (*MagickWand) GetImageMatteColor

func (mw *MagickWand) GetImageMatteColor() (matteColor *PixelWand, err error)

Returns the image matte color.

func (*MagickWand) GetImagePage

func (mw *MagickWand) GetImagePage() (w, h uint, x, y int, err error)

Returns the page geometry associated with the image.

w, h: the page width and height

x, h: the page x-offset and y-offset.

func (*MagickWand) GetImageRedPrimary

func (mw *MagickWand) GetImageRedPrimary() (x, y float64, err error)

Returns the chromaticy red primary point.

x, y: the chromaticity red primary x/y-point.

func (*MagickWand) GetImageResolution

func (mw *MagickWand) GetImageResolution() (x, y float64, err error)

Gets the image X and Y resolution.

func (*MagickWand) GetImageSavedType

func (mw *MagickWand) GetImageSavedType() ImageType

Gets the image type that will be used when the image is saved. This may be different to the current image type, returned by GetImageType().

func (*MagickWand) GetImageSignature

func (mw *MagickWand) GetImageSignature() string

Generates an SHA-256 message digest for the image pixel stream.

func (*MagickWand) GetImageType

func (mw *MagickWand) GetImageType() ImageType

Gets the potential image type To ensure the image type matches its potential, use SetImageType(): wand.SetImageType(wand.GetImageType())

func (*MagickWand) GetImageUnits

func (mw *MagickWand) GetImageUnits() ResolutionType

Gets the image units of resolution.

func (*MagickWand) GetImageWhitePoint

func (mw *MagickWand) GetImageWhitePoint() (x, y float64, err error)

Returns the chromaticy white point.

x, y: the chromaticity white x/y-point.

func (*MagickWand) GetImageWidth

func (mw *MagickWand) GetImageWidth() uint

Returns the image width.

func (*MagickWand) GetLastError

func (mw *MagickWand) GetLastError() error

Returns the kind, reason and description of any error that occurs when using other methods in this API

func (*MagickWand) GetNumberImages

func (mw *MagickWand) GetNumberImages() uint

Returns the number of images associated with a magick wand.

func (*MagickWand) GetSamplingFactors

func (mw *MagickWand) GetSamplingFactors() (factors []float64)

Gets the horizontal and vertical sampling factor.

func (*MagickWand) GetSize

func (mw *MagickWand) GetSize() (uint, uint, error)

Returns the size associated with the magick wand.

func (*MagickWand) HaldClutImage

func (mw *MagickWand) HaldClutImage(hald *MagickWand) error

Replaces colors in the image from a Hald color lookup table. A Hald color lookup table is a 3-dimensional color cube mapped to 2 dimensions. Create it with the HALD coder. You can apply any color transformation to the Hald image and then use this method to apply the transform to the image.

func (*MagickWand) HasNextImage

func (mw *MagickWand) HasNextImage() bool

Returns true if the wand has more images when traversing the list in the forward direction

func (*MagickWand) HasPreviousImage

func (mw *MagickWand) HasPreviousImage() bool

Returns true if the wand has more images when traversing the list in the reverse direction

func (*MagickWand) ImplodeImage

func (mw *MagickWand) ImplodeImage(radius float64) error

Creates a new image that is a copy of an existing one with the image pixels "implode" by the specified percentage.

func (*MagickWand) IncreaseCount

func (mw *MagickWand) IncreaseCount()

Increase MagickWand ref counter and set according "can`t be terminated status"

func (*MagickWand) LabelImage

func (mw *MagickWand) LabelImage(label string) error

Adds a label to your image.

func (*MagickWand) LevelImage

func (mw *MagickWand) LevelImage(blackPoint, gamma, whitePoint float64) error

Adjusts the levels of an image by scaling the colors falling between specified white and black points to the full available quantum range. The parameters provided represent the black, mid, and white points. The black point specifies the darkest color in the image. Colors darker than the black point are set to zero. Mid point specifies a gamma correction to apply to the image. White point specifies the lightest color in the image. Colors brighter than the white point are set to the maximum quantum value.

func (*MagickWand) LevelImageChannel

func (mw *MagickWand) LevelImageChannel(channel ChannelType, blackPoint, gamma, whitePoint float64) error

Adjusts the levels of an image by scaling the colors falling between specified white and black points to the full available quantum range. The parameters provided represent the black, mid, and white points. The black point specifies the darkest color in the image. Colors darker than the black point are set to zero. Mid point specifies a gamma correction to apply to the image. White point specifies the lightest color in the image. Colors brighter than the white point are set to the maximum quantum value.

func (*MagickWand) MagickGetImageGeometry

func (mw *MagickWand) MagickGetImageGeometry() string

Gets the image geometry string. NULL is returned if the image does not contain a geometry string.

func (*MagickWand) MagnifyImage

func (mw *MagickWand) MagnifyImage() error

This is a convenience method that scales an image proportionally to twice its original size.

func (*MagickWand) MapImage

func (mw *MagickWand) MapImage(from *MagickWand, dither uint) error

Replaces the colors of an image with the closest color from a reference image.

from: reference image

dither: Set this integer value to something other than zero to dither the mapped image.

func (*MagickWand) MatteFloodfillImage

func (mw *MagickWand) MatteFloodfillImage(opacity Quantum, fuzz float64, borderColor *PixelWand, x int, y int) error

Changes the transparency value of any pixel that matches target and is an immediate neighbor. If the method FillToBorderMethod is specified, the transparency value is changed for any neighbor pixel that does not match the bordercolor member of image.

func (*MagickWand) MedianFilterImage

func (mw *MagickWand) MedianFilterImage(radius float64) error

Applies a digital filter that improves the quality of a noisy image. Each pixel is replaced by the median in a set of neighboring pixels as defined by radius.

func (*MagickWand) MinifyImage

func (mw *MagickWand) MinifyImage() error

This is a convenience method that scales an image proportionally to one-half its original size

func (*MagickWand) ModulateImage

func (mw *MagickWand) ModulateImage(brightness, saturation, hue float64) error

Lets you control the brightness, saturation, and hue of an image. Hue is the percentage of absolute rotation from the current position. For example 50 results in a counter-clockwise rotation of 90 degrees, 150 results in a clockwise rotation of 90 degrees, with 0 and 200 both resulting in a rotation of 180 degrees. To increase the color brightness by 20 and decrease the color saturation by 10 and leave the hue unchanged, use: 120, 90, 100.

brightness: the percent change in brighness.

saturation: the percent change in saturation.

hue: the percent change in hue.

func (*MagickWand) MontageImage

func (mw *MagickWand) MontageImage(dw *DrawingWand, tileGeo string, thumbGeo string, mode MontageMode, frame string) *MagickWand

Creates a composite image by combining several separate images. The images are tiled on the composite image with the name of the image optionally appearing just below the individual tile.

dw: the drawing wand. The font name, size, and color are obtained from this wand.

tileGeo: the number of tiles per row and page (e.g. 6x4+0+0).

thumbGeo: Preferred image size and border size of each thumbnail (e.g. 120x120+4+3>).

mode: Thumbnail framing mode: Frame, Unframe, or Concatenate.

frame: Surround the image with an ornamental border (e.g. 15x15+3+3). The frame color is that of the thumbnail's matte color.

func (*MagickWand) MorphImages

func (mw *MagickWand) MorphImages(numFrames uint) *MagickWand

Method morphs a set of images. Both the image pixels and size are linearly interpolated to give the appearance of a meta-morphosis from one image to the next.

numFrames: the number of in-between images to generate.

func (*MagickWand) MosaicImages

func (mw *MagickWand) MosaicImages() *MagickWand

inlays an image sequence to form a single coherent picture. It returns a wand with each image in the sequence composited at the location defined by the page offset of the image.

func (*MagickWand) MotionBlurImage

func (mw *MagickWand) MotionBlurImage(radius, sigma, angle float64) error

Simulates motion blur. We convolve the image with a Gaussian operator of the given radius and standard deviation (sigma). For reasonable results, radius should be larger than sigma. Use a radius of 0 and MotionBlurImage() selects a suitable radius for you. Angle gives the angle of the blurring motion.

radius: the radius of the Gaussian, in pixels, not counting the center pixel.

sigma: the standard deviation of the Gaussian, in pixels.

angle: apply the effect along this angle.

func (*MagickWand) NegateImage

func (mw *MagickWand) NegateImage(gray bool) error

Negates the colors in the reference image. The Grayscale option means that only grayscale values within the image are negated. You can also reduce the influence of a particular channel with a gamma value of 0.

gray: If true, only negate grayscale pixels within the image.

func (*MagickWand) NegateImageChannel

func (mw *MagickWand) NegateImageChannel(channel ChannelType, gray bool) error

Negates the colors in the reference image. The Grayscale option means that only grayscale values within the image are negated. You can also reduce the influence of a particular channel with a gamma value of 0.

gray: If true, only negate grayscale pixels within the image.

func (*MagickWand) NextImage

func (mw *MagickWand) NextImage() bool

Sets the next image in the wand as the current image. It is typically used after ResetIterator(), after which its first use will set the first image as the current image (unless the wand is empty). It will return false when no more images are left to be returned which happens when the wand is empty, or the current image is the last image. When the above condition (end of image list) is reached, the iterator is automaticall set so that you can start using PreviousImage() to again/ iterate over the images in the reverse direction, starting with the last image (again). You can jump to this condition immeditally using SetLastIterator().

func (*MagickWand) NormalizeImage

func (mw *MagickWand) NormalizeImage() error

Enhances the contrast of a color image by adjusting the pixels color to span the entire range of colors available. You can also reduce the influence of a particular channel with a gamma value of 0.

func (*MagickWand) OilPaintImage

func (mw *MagickWand) OilPaintImage(radius float64) error

Applies a special effect filter that simulates an oil painting. Each pixel is replaced by the most frequent color occurring in a circular region defined by radius.

radius: the radius of the circular neighborhood.

func (*MagickWand) OpaqueImage

func (mw *MagickWand) OpaqueImage(target, fill *PixelWand, fuzz float64) error

func (*MagickWand) PingImage

func (mw *MagickWand) PingImage(filename string) error

This is like ReadImage() except the only valid information returned is the image width, height, size, and format. It is designed to efficiently obtain this information from a file without reading the entire image sequence into memory.

func (*MagickWand) PreviewImages

func (mw *MagickWand) PreviewImages(preview PreviewType) *MagickWand

Tiles 9 thumbnails of the specified image with an image processing operation applied at varying strengths. This helpful to quickly pin-point an appropriate parameter for an image processing operation.

func (*MagickWand) PreviousImage

func (mw *MagickWand) PreviousImage() bool

Sets the previous image in the wand as the current image. It is typically used after SetLastIterator(), after which its first use will set the last image as the current image (unless the wand is empty). It will return false when no more images are left to be returned which happens when the wand is empty, or the current image is the first image. At that point the iterator is than reset to again process images in the forward direction, again starting with the first image in list. Images added at this point are prepended. Also at that point any images added to the wand using AddImages() or ReadImages() will be prepended before the first image. In this sense the condition is not quite exactly the same as ResetIterator().

func (*MagickWand) QuantizeImage

func (mw *MagickWand) QuantizeImage(numColors uint, colorspace ColorspaceType, treedepth uint, dither bool, measureError bool) error

Analyzes the colors within a reference image and chooses a fixed number of colors to represent the image. The goal of the algorithm is to minimize the color difference between the input and output image while minimizing the processing time.

numColors: the number of colors.

colorspace: Perform color reduction in this colorspace, typically RGBColorspace.

treedepth: Normally, this integer value is zero or one. A zero or one tells Quantize to choose a optimal tree depth of Log4(number_colors). A tree of this depth generally allows the best representation of the reference image with the least amount of memory and the fastest computational speed. In some cases, such as an image with low color dispersion (a few number of colors), a value other than Log4(number_colors) is required. To expand the color tree completely, use a value of 8.

dither: A value other than zero distributes the difference between an original image and the corresponding color reduced image to neighboring pixels along a Hilbert curve.

measureError: A value other than zero measures the difference between the original and quantized images. This difference is the total quantization error. The error is computed by summing over all pixels in an image the distance squared in RGB space between each reference pixel value and its quantized value.

func (*MagickWand) QuantizeImages

func (mw *MagickWand) QuantizeImages(numColors uint, colorspace ColorspaceType, treedepth uint, dither bool, measureError bool) error

Analyzes the colors within a sequence of images and chooses a fixed number of colors to represent the image. The goal of the algorithm is to minimize the color difference between the input and output image while minimizing the processing time.

numColors: the number of colors.

colorspace: Perform color reduction in this colorspace, typically RGBColorspace.

treedepth: Normally, this integer value is zero or one. A zero or one tells Quantize to choose a optimal tree depth of Log4(number_colors). A tree of this depth generally allows the best representation of the reference image with the least amount of memory and the fastest computational speed. In some cases, such as an image with low color dispersion (a few number of colors), a value other than Log4(number_colors) is required. To expand the color tree completely, use a value of 8.

dither: A value other than zero distributes the difference between an original image and the corresponding color reduced image to neighboring pixels along a Hilbert curve.

measureError: A value other than zero measures the difference between the original and quantized images. This difference is the total quantization error. The error is computed by summing over all pixels in an image the distance squared in RGB space between each reference pixel value and its quantized value.

func (*MagickWand) QueryFontMetrics

func (mw *MagickWand) QueryFontMetrics(dw *DrawingWand, textLine string) *FontMetrics

Returns a FontMetrics struct

func (*MagickWand) QueryFonts

func (mw *MagickWand) QueryFonts(pattern string) (fonts []string)

Returns any font that match the specified pattern (e.g. "*" for all)

func (*MagickWand) QueryFormats

func (mw *MagickWand) QueryFormats(pattern string) (formats []string)

Returns any supported image format that match the specified pattern (e.g. "*" for all)

func (*MagickWand) RadialBlurImage

func (mw *MagickWand) RadialBlurImage(angle float64) error

Radial blurs an image.

func (*MagickWand) RaiseImage

func (mw *MagickWand) RaiseImage(width uint, height uint, x int, y int, raise bool) error

Creates a simulated three-dimensional button-like effect by lightening and darkening the edges of the image. Members width and height of raise_info define the width of the vertical and horizontal edge of the effect. width,

height, x, y: Define the dimensions of the area to raise.

raise: A value other than zero creates a 3-D raise effect, otherwise it has a lowered effect.

func (*MagickWand) ReadImage

func (mw *MagickWand) ReadImage(filename string) error

Reads an image or image sequence. The images are inserted at the current image pointer position. Use SetFirstIterator(), SetLastIterator, or SetImageIndex() to specify the current image pointer position at the beginning of the image list, the end, or anywhere in-between respectively.

func (*MagickWand) ReadImageBlob

func (mw *MagickWand) ReadImageBlob(blob []byte) error

Reads an image or image sequence from a blob.

func (*MagickWand) ReadImageFile

func (mw *MagickWand) ReadImageFile(img *os.File) error

Reads an image or image sequence from an open file descriptor.

func (*MagickWand) ReduceNoiseImage

func (mw *MagickWand) ReduceNoiseImage(radius float64) error

Smooths the contours o an image while still preserving edge information. The algorithm works by replacing each pixel with its neighbor closes in value. A neighbor is defined by radius. Use a radius of 0 and the function selects a suitable radius for you.

func (*MagickWand) RemoveImage

func (mw *MagickWand) RemoveImage() error

Removes an image from the image list.

func (*MagickWand) RemoveImageProfile

func (mw *MagickWand) RemoveImageProfile(name string) []byte

Removes the named image profile and returns it.

name: name of profile to return: ICC, IPTC, or generic profile.

func (*MagickWand) ResampleImage

func (mw *MagickWand) ResampleImage(xRes, yRes float64, filter FilterType, blur float64) error

Resample image to desired resolution.

xRes/yRes: the new image x/y resolution.

filter: Image filter to use.

blur: the blur factor where > 1 is blurry, < 1 is sharp.

func (*MagickWand) ResetIterator

func (mw *MagickWand) ResetIterator()

This method resets the wand iterator. It is typically used either before iterating though images, or before calling specific methods such as AppendImages() to append all images together. Afterward you can use NextImage() to iterate over all the images in a wand container, starting with the first image. Using this before AddImages() or ReadImages() will cause new images to be inserted between the first and second image.

func (*MagickWand) ResizeImage

func (mw *MagickWand) ResizeImage(cols, rows uint, filter FilterType, blur float64) error

Scales an image to the desired dimensions

cols: the number of cols in the scaled image.

rows: the number of rows in the scaled image.

filter: Image filter to use.

blur: the blur factor where > 1 is blurry, < 1 is sharp.

func (*MagickWand) RollImage

func (mw *MagickWand) RollImage(x, y int) error

Offsets an image as defined by x and y.

x: the x offset.

y: the y offset.

func (*MagickWand) RotateImage

func (mw *MagickWand) RotateImage(background *PixelWand, degrees float64) error

Rotates an image the specified number of degrees. Empty triangles left over from rotating the image are filled with the background color.

background: the background pixel wand.

degrees: the number of degrees to rotate the image.

func (*MagickWand) SampleImage

func (mw *MagickWand) SampleImage(cols, rows uint) error

Scales an image to the desired dimensions with pixel sampling. Unlike other scaling methods, this method does not introduce any additional color into the scaled image.

func (*MagickWand) ScaleImage

func (mw *MagickWand) ScaleImage(cols, rows uint) error

Scales the size of an image to the given dimensions.

func (*MagickWand) SeparateImageChannel

func (mw *MagickWand) SeparateImageChannel(channel ChannelType) error

Separates a channel from the image and returns a grayscale image. A channel is a particular color component of each pixel in the image.

func (*MagickWand) SetCompressionQuality

func (mw *MagickWand) SetCompressionQuality(quality uint) error

Sets the wand compression quality.

func (*MagickWand) SetFormat

func (mw *MagickWand) SetFormat(format string) error

Sets the format of the magick wand.

func (*MagickWand) SetImage

func (mw *MagickWand) SetImage(source *MagickWand) error

Replaces the last image returned by SetImageIndex(), NextImage(), PreviousImage() with the images from the specified wand.

func (*MagickWand) SetImageAttribute

func (mw *MagickWand) SetImageAttribute(name, value string) error

Sets an image attribute

func (*MagickWand) SetImageBackgroundColor

func (mw *MagickWand) SetImageBackgroundColor(background *PixelWand) error

Sets the image background color.

func (*MagickWand) SetImageBluePrimary

func (mw *MagickWand) SetImageBluePrimary(x, y float64) error

Sets the image chromaticity blue primary point.

func (*MagickWand) SetImageBorderColor

func (mw *MagickWand) SetImageBorderColor(border *PixelWand) error

Sets the image border color.

func (*MagickWand) SetImageChannelDepth

func (mw *MagickWand) SetImageChannelDepth(channel ChannelType, depth uint) error

Sets the depth of a particular image channel.

depth: the image depth in bits.

func (*MagickWand) SetImageColormapColor

func (mw *MagickWand) SetImageColormapColor(index uint, color *PixelWand) error

Sets the color of the specified colormap index.

index: the offset into the image colormap.

color: return the colormap color in this wand.

func (*MagickWand) SetImageColorspace

func (mw *MagickWand) SetImageColorspace(colorspace ColorspaceType) error

Sets the image colorspace.

func (*MagickWand) SetImageCompose

func (mw *MagickWand) SetImageCompose(compose CompositeOperator) error

Sets the image composite operator, useful for specifying how to composite / the image thumbnail when using the MontageImage() method.

func (*MagickWand) SetImageCompression

func (mw *MagickWand) SetImageCompression(compression CompressionType) error

Sets the image compression.

func (*MagickWand) SetImageDelay

func (mw *MagickWand) SetImageDelay(delay uint) error

Sets the image delay.

delay: the image delay in ticks-per-second units.

func (*MagickWand) SetImageDepth

func (mw *MagickWand) SetImageDepth(depth uint) error

Sets the image depth.

depth: the image depth in bits: 8, 16, or 32.

func (*MagickWand) SetImageDispose

func (mw *MagickWand) SetImageDispose(dispose DisposeType) error

Sets the image disposal method.

func (*MagickWand) SetImageFilename

func (mw *MagickWand) SetImageFilename(filename string) error

Sets the filename of a particular image in a sequence.

func (*MagickWand) SetImageFormat

func (mw *MagickWand) SetImageFormat(format string) error

Sets the format of a particular image in a sequence.

format: the image format.

func (*MagickWand) SetImageFuzz

func (mw *MagickWand) SetImageFuzz(fuzz float64) error

Sets the image fuzz.

func (*MagickWand) SetImageGamma

func (mw *MagickWand) SetImageGamma(gamma float64) error

Sets the image gamma.

func (*MagickWand) SetImageGravity

func (mw *MagickWand) SetImageGravity(gravity GravityType) error

Sets the image gravity type.

func (*MagickWand) SetImageGreenPrimary

func (mw *MagickWand) SetImageGreenPrimary(x, y float64) error

Sets the image chromaticity green primary point.

func (*MagickWand) SetImageIndex

func (mw *MagickWand) SetImageIndex(index int) bool

This method set the iterator to the given position in the image list specified with the index parameter. A zero index will set the first image as current, and so on. Negative indexes can be used to specify an image relative to the end of the images in the wand, with -1 being the last image in the wand. If the index is invalid (range too large for number of images in wand) the function will return false. In that case the current image will not change. After using any images added to the wand using AddImage() or ReadImage() will be added after the image indexed, regardless of if a zero (first image in list) or negative index (from end) is used. Jumping to index 0 is similar to ResetIterator() but differs in how NextImage() behaves afterward.

func (*MagickWand) SetImageInterlaceScheme

func (mw *MagickWand) SetImageInterlaceScheme(interlace InterlaceType) error

Sets the image interlace scheme.

func (*MagickWand) SetImageIterations

func (mw *MagickWand) SetImageIterations(iterations uint) error

Sets the image iterations.

func (*MagickWand) SetImageMatte

func (mw *MagickWand) SetImageMatte(matte bool) error

Sets the image matte channel.

func (*MagickWand) SetImageMatteColor

func (mw *MagickWand) SetImageMatteColor(matte *PixelWand) error

Sets the image matte color.

func (*MagickWand) SetImagePage

func (mw *MagickWand) SetImagePage(width, height uint, x, y int) error

Sets the page geometry of the image.

func (*MagickWand) SetImageRedPrimary

func (mw *MagickWand) SetImageRedPrimary(x, y float64) error

Sets the image chromaticity red primary point.

func (*MagickWand) SetImageRenderingIntent

func (mw *MagickWand) SetImageRenderingIntent(ri RenderingIntent) error

Sets the image rendering intent.

func (*MagickWand) SetImageResolution

func (mw *MagickWand) SetImageResolution(xRes, yRes float64) error

Sets the image resolution.

func (*MagickWand) SetImageSavedType

func (mw *MagickWand) SetImageSavedType(it ImageType) error

Sets the image type that will be used when the image is saved.

func (*MagickWand) SetImageScene

func (mw *MagickWand) SetImageScene(scene uint) error

Sets the image scene.

func (*MagickWand) SetImageType

func (mw *MagickWand) SetImageType(imgtype ImageType) error

Sets the image type.

func (*MagickWand) SetImageUnits

func (mw *MagickWand) SetImageUnits(units ResolutionType) error

Sets the image units of resolution.

func (*MagickWand) SetImageVirtualPixelMethod

func (mw *MagickWand) SetImageVirtualPixelMethod(method VirtualPixelMethod) VirtualPixelMethod

Sets the image virtual pixel method.

func (*MagickWand) SetImageWhitePoint

func (mw *MagickWand) SetImageWhitePoint(x, y float64) error

Sets the image chromaticity white point.

func (*MagickWand) SetInterlaceScheme

func (mw *MagickWand) SetInterlaceScheme(scheme InterlaceType) error

Sets the image interlacing scheme

func (*MagickWand) SetPassphrase

func (mw *MagickWand) SetPassphrase(passphrase string) error

Sets the passphrase.

func (*MagickWand) SetResolution

func (mw *MagickWand) SetResolution(xRes, yRes float64) error

Sets the image resolution.

func (*MagickWand) SetResolutionUnits

func (mw *MagickWand) SetResolutionUnits(units ResolutionType) error

Sets the resolution units of the magick wand. It should be used in conjunction with SetResolution(). This method works both before and after an image has been read.

func (*MagickWand) SetResourceLimit

func (mw *MagickWand) SetResourceLimit(rtype ResourceType, limit uint) error

Sets the limit for a particular resource in megabytes.

func (*MagickWand) SetSamplingFactors

func (mw *MagickWand) SetSamplingFactors(samplingFactors []float64) error

Sets the image sampling factors.

samplingFactors: An array of floats representing the sampling factor for each color component (in RGB order).

func (*MagickWand) SetSize

func (mw *MagickWand) SetSize(width, heigh uint) error

Sets the size of the magick wand. Set it before you read a raw image format such as RGB, GRAY, or CMYK.

func (*MagickWand) SharpenImage

func (mw *MagickWand) SharpenImage(radius, sigma float64) error

Sharpens an image. We convolve the image with a Gaussian operator of the given radius and standard deviation (sigma). For reasonable results, the radius should be larger than sigma. Use a radius of 0 and SharpenImage() selects a suitable radius for you.

radius: the radius of the Gaussian, in pixels, not counting the center pixel.

sigma: the standard deviation of the Gaussian, in pixels.

func (*MagickWand) ShaveImage

func (mw *MagickWand) ShaveImage(cols, rows uint) error

Shaves pixels from the image edges. It allocates the memory necessary for the new Image structure and returns a pointer to the new image.

func (*MagickWand) ShearImage

func (mw *MagickWand) ShearImage(background *PixelWand, xShear, yShear float64) error

Slides one edge of an image along the X or Y axis, creating a parallelogram. An X direction shear slides an edge along the X axis, while a Y direction shear slides an edge along the Y axis. The amount of the shear is controlled by a shear angle. For X direction shears, xShear is measured relative to the Y axis, and similarly, for Y direction shears yShear is measured relative to the X axis. Empty triangles left over from shearing the image are filled with the background color.

func (*MagickWand) SolarizeImage

func (mw *MagickWand) SolarizeImage(threshold float64) error

Applies a special effect to the image, similar to the effect achieved in a photo darkroom by selectively exposing areas of photo sensitive paper to light. Threshold ranges from 0 to QuantumRange and is a measure of the extent of the solarization.

threshold: define the extent of the solarization.

func (*MagickWand) SpreadImage

func (mw *MagickWand) SpreadImage(radius float64) error

Is a special effects method that randomly displaces each pixel in a block defined by the radius parameter.

radius: Choose a random pixel in a neighborhood of this extent.

func (*MagickWand) SteganoImage

func (mw *MagickWand) SteganoImage(watermark *MagickWand, offset int) *MagickWand

Hides a digital watermark within the image. Recover the hidden watermark later to prove that the authenticity of an image. Offset defines the start position within the image to hide the watermark.

offset: start hiding at this offset into the image.

func (*MagickWand) StereoImage

func (mw *MagickWand) StereoImage(offset *MagickWand) *MagickWand

Composites two images and produces a single image that is the composite of a left and right image of a stereo pair.

func (*MagickWand) StripImage

func (mw *MagickWand) StripImage() error

Strips an image of all profiles and comments.

func (*MagickWand) SwirlImage

func (mw *MagickWand) SwirlImage(degrees float64) error

Swirls the pixels about the center of the image, where degrees indicates the sweep of the arc through which each pixel is moved. You get a more dramatic effect as the degrees move from 1 to 360.

degrees: define the tightness of the swirling effect.

func (*MagickWand) TextureImage

func (mw *MagickWand) TextureImage(texture *MagickWand) *MagickWand

Repeatedly tiles the texture image across and down the image canvas.

func (*MagickWand) ThresholdImage

func (mw *MagickWand) ThresholdImage(threshold float64) error

Changes the value of individual pixels based on the intensity of each pixel compared to threshold. The result is a high-contrast, two color image.

threshold: define the threshold value.

func (*MagickWand) ThresholdImageChannel

func (mw *MagickWand) ThresholdImageChannel(channel ChannelType, threshold float64) error

Changes the value of individual pixels based on the intensity of each pixel compared to threshold. The result is a high-contrast, two color image.

threshold: define the threshold value.

func (*MagickWand) TintImage

func (mw *MagickWand) TintImage(tint, opacity *PixelWand) error

Applies a color vector to each pixel in the image. The length of the vector is 0 for black and white and at its maximum for the midtones. The vector weighting function is f(x)=(1-(4.0*((x-0.5)*(x-0.5)))).

tint: the tint pixel wand.

opacity: the opacity pixel wand.

func (*MagickWand) TransformImage

func (mw *MagickWand) TransformImage(crop string, geometry string) *MagickWand

Is a convenience method that behaves like ResizeImage() or CropImage() but accepts scaling and/or cropping information as a region geometry specification. If the operation fails, a NULL image handle is returned. crop: a crop geometry string. This geometry defines a subregion of the image to crop. geometry: an image geometry string. This geometry defines the final size of the image.

func (*MagickWand) TransparentImage

func (mw *MagickWand) TransparentImage(target *PixelWand, opacity C.Quantum, fuzz float64) error

Changes any pixel that matches color with the color defined by fill.

func (*MagickWand) TrimImage

func (mw *MagickWand) TrimImage(fuzz float64) error

Remove edges that are the background color from the image.

fuzz: by default target must match a particular pixel color exactly. However, in many cases two colors may differ by a small amount. The fuzz member of image defines how much tolerance is acceptable to consider two colors as the same. For example, set fuzz to 10 and the color red at intensities of 100 and 102 respectively are now interpreted as the same color for the purposes of the floodfill.

func (*MagickWand) UnsharpMaskImage

func (mw *MagickWand) UnsharpMaskImage(radius, sigma, amount, threshold float64) error

Unsharpens an image. We convolve the image with a Gaussian operator of the given radius and standard deviation (sigma). For reasonable results, radius should be larger than sigma. Use a radius of 0 and UnsharpMaskImage() selects a suitable radius for you.

radius: the radius of the Gaussian, in pixels, not counting the center pixel.

sigma: the standard deviation of the Gaussian, in pixels.

amount: the percentage of the difference between the original and the blur image that is added back into the original.

threshold: the threshold in pixels needed to apply the diffence amount.

func (*MagickWand) WaveImage

func (mw *MagickWand) WaveImage(amplitude, wavelength float64) error

Creates a "ripple" effect in the image by shifting the pixels vertically along a sine wave whose amplitude and wavelength is specified by the given parameters.

amplitude, wavelength: Define the amplitude and wave length of the sine wave.

func (*MagickWand) WhiteThresholdImage

func (mw *MagickWand) WhiteThresholdImage(threshold *PixelWand) error

Is like ThresholdImage() but force all pixels above the threshold into white while leaving all pixels below the threshold unchanged.

func (*MagickWand) WriteImage

func (mw *MagickWand) WriteImage(filename string) error

Writes an image to the specified filename.

func (*MagickWand) WriteImageBlob

func (mw *MagickWand) WriteImageBlob() []byte

Implements direct to memory image formats. It returns the image as a byte array (a formatted "file" in memory), starting from the current position in the image sequence. Use MagickSetImageFormat() to set the format to write to the blob (GIF, JPEG, PNG, etc.).

func (*MagickWand) WriteImageFile

func (mw *MagickWand) WriteImageFile(out *os.File) error

Writes an image sequence to an open file descriptor.

func (*MagickWand) WriteImages

func (mw *MagickWand) WriteImages(filename string, adjoin bool) error

Writes an image or image sequence.

func (*MagickWand) WriteImagesFile

func (mw *MagickWand) WriteImagesFile(out *os.File, adjoin bool) error

Writes an image sequence to an open file descriptor.

type MagickWandException

type MagickWandException struct {
	// contains filtered or unexported fields
}

func (*MagickWandException) Error

func (mwe *MagickWandException) Error() string

type MetricType

type MetricType int
const (
	METRIC_UNDEFINED                  MetricType = C.UndefinedMetric
	METRIC_MEAN_ABSOLUTE_ERROR        MetricType = C.MeanAbsoluteErrorMetric
	METRIC_MEAN_SQUARED_ERROR         MetricType = C.MeanSquaredErrorMetric
	METRIC_PEAK_ABSOLUTE_ERROR        MetricType = C.PeakAbsoluteErrorMetric
	METRIC_PEAK_SIGNAL_TO_NOISE_RATIO MetricType = C.PeakSignalToNoiseRatioMetric
	METRIC_ROOT_MEAN_SQUARED_ERROR    MetricType = C.RootMeanSquaredErrorMetric
)

type MontageMode

type MontageMode int
const (
	MONTAGE_MODE_UNDEFINED   MontageMode = C.UndefinedMode
	MONTAGE_MODE_FRAME       MontageMode = C.FrameMode
	MONTAGE_MODE_UNFRAME     MontageMode = C.UnframeMode
	MONTAGE_MODE_CONCATENATE MontageMode = C.ConcatenateMode
)

type NoiseType

type NoiseType int
const (
	NOISE_UNDEFINED               NoiseType = C.UndefinedNoise
	NOISE_UNIFORM                 NoiseType = C.UniformNoise
	NOISE_GAUSSIAN                NoiseType = C.GaussianNoise
	NOISE_MULTIPLICATIVE_GAUSSIAN NoiseType = C.MultiplicativeGaussianNoise
	NOISE_IMPULSE                 NoiseType = C.ImpulseNoise
	NOISE_LAPLACIAN               NoiseType = C.LaplacianNoise
	NOISE_POISSON                 NoiseType = C.PoissonNoise
	NOISE_RANDOM                  NoiseType = C.RandomNoise
)

type PaintMethod

type PaintMethod int
const (
	PAINT_METHOD_POINT        PaintMethod = C.PointMethod
	PAINT_METHOD_REPLACE      PaintMethod = C.ReplaceMethod
	PAINT_METHOD_FLOODFILL    PaintMethod = C.FloodfillMethod
	PAINT_METHOD_FILLTOBORDER PaintMethod = C.FillToBorderMethod
	PAINT_METHOD_RESET        PaintMethod = C.ResetMethod
)

type PixelPacket

type PixelPacket struct {
	// contains filtered or unexported fields
}

type PixelWand

type PixelWand struct {
	// contains filtered or unexported fields
}

func NewPixelWand

func NewPixelWand() *PixelWand

Returns a new pixel wand

func (*PixelWand) Clone

func (pw *PixelWand) Clone() *PixelWand

Makes an exact copy of the wand

func (*PixelWand) DecreaseCount

func (pw *PixelWand) DecreaseCount()

Decrease PixelWand ref counter and set according "can be terminated status"

func (*PixelWand) Destroy

func (pw *PixelWand) Destroy()

Deallocates resources associated with a pixel wand

func (*PixelWand) GetBlack

func (pw *PixelWand) GetBlack() float64

Returns the normalized black color of the pixel wand

func (*PixelWand) GetBlackQuantum

func (pw *PixelWand) GetBlackQuantum() Quantum

Returns the black color of the pixel wand

func (*PixelWand) GetBlue

func (pw *PixelWand) GetBlue() float64

Returns the normalized blue color of the pixel wand

func (*PixelWand) GetBlueQuantum

func (pw *PixelWand) GetBlueQuantum() Quantum

Returns the blue color of the pixel wand

func (*PixelWand) GetColorAsString

func (pw *PixelWand) GetColorAsString() string

Returns the color of the pixel wand as a string

func (*PixelWand) GetColorCount

func (pw *PixelWand) GetColorCount() uint

Returns the color count associated with this color

func (*PixelWand) GetCyan

func (pw *PixelWand) GetCyan() float64

Returns the normalized cyan color of the pixel wand

func (*PixelWand) GetCyanQuantum

func (pw *PixelWand) GetCyanQuantum() Quantum

Returns the cyan color of the pixel wand

func (*PixelWand) GetGreen

func (pw *PixelWand) GetGreen() float64

Returns the normalized green color of the pixel wand

func (*PixelWand) GetGreenQuantum

func (pw *PixelWand) GetGreenQuantum() Quantum

Returns the green color of the pixel wand

func (*PixelWand) GetMagenta

func (pw *PixelWand) GetMagenta() float64

Returns the normalized magenta color of the pixel wand

func (*PixelWand) GetMagentaQuantum

func (pw *PixelWand) GetMagentaQuantum() Quantum

Returns the magenta color of the pixel wand

func (*PixelWand) GetOpacity

func (pw *PixelWand) GetOpacity() float64

Returns the normalized opacity color of the pixel wand

func (*PixelWand) GetOpacityQuantum

func (pw *PixelWand) GetOpacityQuantum() Quantum

Returns the opacity color of the pixel wand

func (*PixelWand) GetQuantumColor

func (pw *PixelWand) GetQuantumColor() *PixelPacket

Gets the color of the pixel wand as a PixelPacket

func (*PixelWand) GetRed

func (pw *PixelWand) GetRed() float64

Returns the normalized red color of the pixel wand

func (*PixelWand) GetRedQuantum

func (pw *PixelWand) GetRedQuantum() Quantum

Returns the red color of the pixel wand

func (*PixelWand) GetYellow

func (pw *PixelWand) GetYellow() float64

Returns the normalized yellow color of the pixel wand

func (*PixelWand) GetYellowQuantum

func (pw *PixelWand) GetYellowQuantum() Quantum

Returns the yellow color of the pixel wand

func (*PixelWand) IncreaseCount

func (pw *PixelWand) IncreaseCount()

Increase PixelWand ref counter and set according "can`t be terminated status"

func (*PixelWand) SetBlack

func (pw *PixelWand) SetBlack(black float64)

Sets the normalized black color of the pixel wand

func (*PixelWand) SetBlackQuantum

func (pw *PixelWand) SetBlackQuantum(black Quantum)

Sets the black color of the pixel wand

func (*PixelWand) SetBlue

func (pw *PixelWand) SetBlue(blue float64)

Sets the normalized blue color of the pixel wand

func (*PixelWand) SetBlueQuantum

func (pw *PixelWand) SetBlueQuantum(blue Quantum)

Sets the blue color of the pixel wand

func (*PixelWand) SetColor

func (pw *PixelWand) SetColor(color string) bool

Sets the color of the pixel wand with a string (e.g. "blue", "#0000ff", "rgb(0,0,255)", "cmyk(100,100,100,10)", etc.)

func (*PixelWand) SetColorCount

func (pw *PixelWand) SetColorCount(count uint)

Sets the color count of the pixel wand

func (*PixelWand) SetCyan

func (pw *PixelWand) SetCyan(cyan float64)

Sets the normalized cyan color of the pixel wand

func (*PixelWand) SetCyanQuantum

func (pw *PixelWand) SetCyanQuantum(cyan Quantum)

Sets the cyan color of the pixel wand

func (*PixelWand) SetGreen

func (pw *PixelWand) SetGreen(green float64)

Sets the normalized green color of the pixel wand

func (*PixelWand) SetGreenQuantum

func (pw *PixelWand) SetGreenQuantum(green Quantum)

Sets the green color of the pixel wand

func (*PixelWand) SetMagenta

func (pw *PixelWand) SetMagenta(magenta float64)

Sets the normalized magenta color of the pixel wand

func (*PixelWand) SetMagentaQuantum

func (pw *PixelWand) SetMagentaQuantum(magenta Quantum)

Sets the magenta color of the pixel wand

func (*PixelWand) SetOpacity

func (pw *PixelWand) SetOpacity(opacity float64)

Sets the normalized opacity color of the pixel wand

func (*PixelWand) SetOpacityQuantum

func (pw *PixelWand) SetOpacityQuantum(opacity Quantum)

Sets the opacity color of the pixel wand

func (*PixelWand) SetQuantumColor

func (pw *PixelWand) SetQuantumColor(color *PixelPacket)

Sets the color of the pixel wand

func (*PixelWand) SetRed

func (pw *PixelWand) SetRed(red float64)

Sets the normalized red color of the pixel wand

func (*PixelWand) SetRedQuantum

func (pw *PixelWand) SetRedQuantum(red Quantum)

Sets the red color of the pixel wand

func (*PixelWand) SetYellow

func (pw *PixelWand) SetYellow(yellow float64)

Sets the normalized yellow color of the pixel wand

func (*PixelWand) SetYellowQuantum

func (pw *PixelWand) SetYellowQuantum(yellow Quantum)

Sets the yellow color of the pixel wand

type PointInfo

type PointInfo struct {
	X float64
	Y float64
}

type PreviewType

type PreviewType int
const (
	PREVIEW_UNDEFINED        PreviewType = C.UndefinedPreview
	PREVIEW_ROTATE           PreviewType = C.RotatePreview
	PREVIEW_SHEAR            PreviewType = C.ShearPreview
	PREVIEW_ROLL             PreviewType = C.RollPreview
	PREVIEW_HUE              PreviewType = C.HuePreview
	PREVIEW_SATURATION       PreviewType = C.SaturationPreview
	PREVIEW_BRIGHTNESS       PreviewType = C.BrightnessPreview
	PREVIEW_GAMMA            PreviewType = C.GammaPreview
	PREVIEW_SPIFF            PreviewType = C.SpiffPreview
	PREVIEW_DULL             PreviewType = C.DullPreview
	PREVIEW_GRAYSCALE        PreviewType = C.GrayscalePreview
	PREVIEW_QUANTIZE         PreviewType = C.QuantizePreview
	PREVIEW_DESPECKLE        PreviewType = C.DespecklePreview
	PREVIEW_REDUCE_NOISE     PreviewType = C.ReduceNoisePreview
	PREVIEW_ADD_NOISE        PreviewType = C.AddNoisePreview
	PREVIEW_SHARPEN          PreviewType = C.SharpenPreview
	PREVIEW_BLUR             PreviewType = C.BlurPreview
	PREVIEW_THRESHOLD        PreviewType = C.ThresholdPreview
	PREVIEW_EDGE_DETECT      PreviewType = C.EdgeDetectPreview
	PREVIEW_SPREAD           PreviewType = C.SpreadPreview
	PREVIEW_SOLARIZE         PreviewType = C.SolarizePreview
	PREVIEW_SHADE            PreviewType = C.ShadePreview
	PREVIEW_RAISE            PreviewType = C.RaisePreview
	PREVIEW_SEGMENT          PreviewType = C.SegmentPreview
	PREVIEW_SWIRL            PreviewType = C.SwirlPreview
	PREVIEW_IMPLODE          PreviewType = C.ImplodePreview
	PREVIEW_WAVE             PreviewType = C.WavePreview
	PREVIEW_OIL_PAINT        PreviewType = C.OilPaintPreview
	PREVIEW_CHARCOAL_DRAWING PreviewType = C.CharcoalDrawingPreview
	PREVIEW_JPEG             PreviewType = C.JPEGPreview
)

type Quantum

type Quantum C.Quantum

type RenderingIntent

type RenderingIntent int
const (
	RENDERING_INTENT_UNDEFINED  RenderingIntent = C.UndefinedIntent
	RENDERING_INTENT_SATURATION RenderingIntent = C.SaturationIntent
	RENDERING_INTENT_PERCEPTUAL RenderingIntent = C.PerceptualIntent
	RENDERING_INTENT_ABSOLUTE   RenderingIntent = C.AbsoluteIntent
	RENDERING_INTENT_RELATIVE   RenderingIntent = C.RelativeIntent
)

type ResolutionType

type ResolutionType int
const (
	RESOLUTION_UNDEFINED             ResolutionType = C.UndefinedResolution
	RESOLUTION_PIXELS_PER_INCH       ResolutionType = C.PixelsPerInchResolution
	RESOLUTION_PIXELS_PER_CENTIMETER ResolutionType = C.PixelsPerCentimeterResolution
)

type ResourceType

type ResourceType int
const (
	RESOURCE_UNDEFINED ResourceType = C.UndefinedResource
	RESOURCE_AREA      ResourceType = C.AreaResource
	RESOURCE_DISK      ResourceType = C.DiskResource
	RESOURCE_FILE      ResourceType = C.FileResource
	RESOURCE_MAP       ResourceType = C.MapResource
	RESOURCE_MEMORY    ResourceType = C.MemoryResource
)

type StretchType

type StretchType int
const (
	STRETCH_NORMAL          StretchType = C.NormalStretch
	STRETCH_ULTRA_CONDENSED StretchType = C.UltraCondensedStretch
	STRETCH_EXTRA_CONDENSED StretchType = C.ExtraCondensedStretch
	STRETCH_CONDENSED       StretchType = C.CondensedStretch
	STRETCH_SEMI_CONDENSED  StretchType = C.SemiCondensedStretch
	STRETCH_SEMI_EXPANDED   StretchType = C.SemiExpandedStretch
	STRETCH_EXPANDED        StretchType = C.ExpandedStretch
	STRETCH_EXTRA_EXPANDED  StretchType = C.ExtraExpandedStretch
	STRETCH_ULTRA_EXPANDED  StretchType = C.UltraExpandedStretch
	STRETCH_ANY             StretchType = C.AnyStretch
)

type StyleType

type StyleType int
const (
	STYLE_NORMAL   StyleType = C.NormalStyle
	STYLE_ITALIC   StyleType = C.ItalicStyle
	STYLE_OBLIQUE  StyleType = C.ObliqueStyle
	STYLE_ANYSTYLE StyleType = C.AnyStyle
)

type VirtualPixelMethod

type VirtualPixelMethod int

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL