Platforms to show: All Mac Windows Linux Cross-Platform

Back to GMImageMBS class.

Previous items

GMImageMBS.transformReset

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Reset transformation parameters to default.

GMImageMBS.transformRotation(angle as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Rotation to use when annotating with text or drawing.

GMImageMBS.transformScale(tx as Double, ty as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Scale to use when annotating with text or drawing.

GMImageMBS.transformSkewX(x as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Skew to use in X axis when annotating with text or drawing.

GMImageMBS.transformSkewY(y as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Skew to use in Y axis when annotating with text or drawing.

GMImageMBS.transparent(color as GMColorMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Add matte channel to image, setting pixels matching color to transparent.
Example
dim p as Picture = LogoMBS(500)
dim image as new GMImageMBS(p)

dim c as new GMColorMBS("white")
image.transparent(c)

Backdrop=image.CombinePictureWithMask

GMImageMBS.trim

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Trim edges that are the background color from the image.
Example
dim p as Picture = LogoMBS(500)
// make the logo picture bigger
dim q as Picture = New Picture(700,700,32)

q.Graphics.DrawPicture p,100,100

dim image as new GMImageMBS(q)

// now trim the white border away
image.trim

Backdrop=image.CopyPicture

See ColorFuzz property for how far the pixel value can differentiate.

GMImageMBS.unregisterId

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Not documented.

GMImageMBS.unsharpmask(radius as Double, sigma as Double, amount as Double, threshold as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Replace image with a sharpened version of the original image using the unsharp mask algorithm.
Example
dim p as Picture = LogoMBS(500)
dim image as new GMImageMBS(p)

image.unsharpmask(10,1,0.5,50)

Backdrop=image.CopyPicture

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.

GMImageMBS.unsharpmaskChannel(channel as Integer, radius as Double, sigma as Double, amount as Double, threshold as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Replace image channel with a sharpened version of the original image using the unsharp mask algorithm.
Example
dim p as Picture = LogoMBS(500)
dim image as new GMImageMBS(p)

image.unsharpmaskChannel(Image.RedChannel, 10,1,0.5,50)

Backdrop=image.CopyPicture

channel:image channel to modify.
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.

GMImageMBS.wave(amplitude as Double=25.0, wavelength as Double=150.0)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Map image pixels to a sine wave.
Example
dim p as Picture = LogoMBS(500)
dim image as new GMImageMBS(p)

image.wave

Backdrop=image.CopyPicture

GMImageMBS.write(blob as GMBlobMBS, magick as string)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Write single image frame to in-memory Blob, with optional format and adjoin parameters.

See also:

GMImageMBS.write(blob as GMBlobMBS, magick as string, depth as UInt32)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Write single image frame to in-memory Blob, with optional format and adjoin parameters.

See also:

GMImageMBS.write(file as folderitem)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Write single image frame to a file.
Example
// this converts 32 bit PNG with alpha channel to BMP

dim f as FolderItem = SpecialFolder.Desktop.Child("test.png")
dim p as Picture = Picture.Open(f)

dim g as new GMImageMBS( new GMGeometryMBS(p.Width, p.Height), new GMColorGrayMBS(1.0))

g.type = g.TrueColorMatteType
g.matte = True
g.magick = "BMP"

g.SetPicture(p, 0, 0)
g.SetPictureMask(p.mask.invertMBS, 0, 0)

f = SpecialFolder.Desktop.Child("test.bmp")
g.write(f)

See also:

GMImageMBS.write(x as Integer, y as Integer, columns as Integer, rows as Integer, map as string, type as Integer, Pixels as Ptr)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 16.4 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Write single image frame to an array of pixels with storage type specified by user (DispatchImage).

e.g. image.write( 0, 0, 640, 1, "RGB", 0, pixels )

See also:

GMImageMBS.zoom(geometry as GMGeometryMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 9.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Zoom (resize) image to specified size.
Example
dim p as Picture = LogoMBS(500)
dim image as new GMImageMBS(p)

image.zoom(new GMGeometryMBS(200,200))

Backdrop=image.CopyPicture

GMImageMBS.ZPL(Header as boolean = true) as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 20.4 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Queries image as ZPL hex image.

This is for sending data to a receipt printer. The picture is taken as black & white image and we build the hex string, you can send to the printer.
Picture needs to have a width dividable by 8.

Set Header to false for skipping header and footer.

Previous items

The items on this page are in the following plugins: MBS GraphicsMagick Plugin.


💬 Ask a question or report a problem
The biggest plugin in space...