Platforms to show: All Mac Windows Linux Cross-Platform

Back to GM16ImageMBS class.

GM16ImageMBS.raiseImage

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Raise image (lighten or darken the edges of an image to give a 3-D raised or lowered effect).
Example
Var p as Picture = LogoMBS(500)
Var image as new GM16ImageMBS(p)

image.raiseImage

Backdrop=image.CopyPicture

See also:

GM16ImageMBS.raiseImage(geometry as GM16GeometryMBS, raisedFlag as boolean=false)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Raise image (lighten or darken the edges of an image to give a 3-D raised or lowered effect).
Example
Var p as Picture = LogoMBS(500)
Var image as new GM16ImageMBS(p)

image.raiseImage(GM16GeometryMBS.Make(5,8))

Backdrop=image.CopyPicture

See also:

GM16ImageMBS.randomThreshold(thresholds as GM16GeometryMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Random threshold image.
Example
Var p as Picture = LogoMBS(500)
Var image as new GM16ImageMBS(p)

image.randomThreshold(GM16GeometryMBS.make("50x200"))

image.type = image.TrueColorType
Backdrop=image.CopyPicture

Changes the value of individual pixels based on the intensity of each pixel compared to a random threshold. The result is a low-contrast, two color image. The thresholds argument is a geometry containing LOWxHIGH thresholds. If the string contains 2x2, 3x3, or 4x4, then an ordered dither of order 2, 3, or 4 will be performed instead. If a channel argument is specified then only the specified channel is altered. This is a very fast alternative to 'quantize' based dithering.

GM16ImageMBS.randomThresholdChannel(thresholds as GM16GeometryMBS, channel as Integer)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Random threshold image channel.

Changes the value of individual pixels based on the intensity of each pixel compared to a random threshold. The result is a low-contrast, two color image. The thresholds argument is a geometry containing LOWxHIGH thresholds. If the string contains 2x2, 3x3, or 4x4, then an ordered dither of order 2, 3, or 4 will be performed instead. If a channel argument is specified then only the specified channel is altered. This is a very fast alternative to 'quantize' based dithering.

GM16ImageMBS.read(blob as GM16BlobMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Read single image frame from in-memory Blob.
Example
// get some image data (e.g. from blob in database)
Var logo as Picture = LogoMBS(500)
Var jpegData as string = PictureToJPEGStringMBS(logo, 80)

// new image
Var mp as new GM16ImageMBS
Var blob as new GM16BlobMBS(jpegData)

// read data from blob into this image object
mp.Read blob

// sometimes you need to explicit convert to RGB/RGBA
'mp.type = mp.TrueColorMatteType
Backdrop=mp.CombinePictureWithMask

See also:

GM16ImageMBS.read(width as UInt32, height as UInt32, map as string, StorageType as Integer, data as ptr)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Read single image frame from an array of raw pixels, with specified storage type (ConstituteImage).

Returns an Image corresponding to an image stored in a raw memory array format. The pixel data must be in scanline order top-to-bottom. The data can be unsigned char, unsigned short int, unsigned int, unsigned long, float, or double. Float and double require the pixels to be normalized to the range [0..1], otherwise the range is [0..MaxVal] where MaxVal is the maximum possible value for that type.

Note that for most 32-bit architectures the size of an unsigned long is the same as unsigned int, but for 64-bit architectures observing the LP64 standard, an unsigned long is 64 bits, while an unsigned int remains 32 bits. This should be considered when deciding if the data should be described as "Integer" or "Long".

For example, to create a 640x480 image from unsigned red-green-blue character data, use

image = new GM16ImageMBS(640, 480, "RGB", GM16ImageMBS.StorageTypeCharPixel, pixels);

width: width in pixels of the image.
height: height in pixels of the image.
map: This string reflects the expected ordering of the pixel array. It can be any combination or order of R = red, G = green, B = blue, A = alpha (same as Transparency), O = Opacity, T = Transparency, C = cyan, Y = yellow, M = magenta, K = black, or I = intensity (for grayscale). Specify "P" = pad, to skip over a quantum which is intentionally ignored. Creation of an alpha channel for CMYK images is currently not supported.
type: Define the data type of the pixels. Float and double types are expected to be normalized [0..1] otherwise [0..MaxRGB]. Choose from these types: StorageTypeCharPixel, StorageTypeShortPixel, StorageTypeIntegerPixel, StorageTypeLongPixel, StorageTypeFloatPixel, or StorageTypeDoublePixel.
pixels: This array of values contain the pixel components as defined by map and type. You must preallocate this array where the expected length varies depending on the values of width, height, map, and type.

See also:

GM16ImageMBS.reduceNoise

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Reduce noise in image using a noise peak elimination filter.
Example
Var p as Picture = LogoMBS(500)
Var image as new GM16ImageMBS(p)

image.reduceNoise

Backdrop=image.CopyPicture

See also:

GM16ImageMBS.reduceNoise(order as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Reduce noise in image using a noise peak elimination filter.

See also:

GM16ImageMBS.repage

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Resets the image page canvas and position.

GM16ImageMBS.resize(geo as GM16GeometryMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Resize image, specifying only geometry, with filter and blur obtained from Image default.
Example
Var f as folderitem = SpecialFolder.Desktop.Child("test.jpg")
Var image as new GM16ImageMBS(f)

// resize proportionally to fit
Var geo as new GM16GeometryMBS(500,500)
image.resize geo

window1.Title = image.formatExpression("%wx%h")
window1.Backdrop = image.CopyPicture

Same result as 'zoom' method.

See also:

GM16ImageMBS.resize(geo as GM16GeometryMBS, filterType as Integer)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Resize image, specifying geometry and filter, with blur using Image default.
Example
Var f as folderitem = SpecialFolder.Desktop.Child("test.jpg")
Var image as new GM16ImageMBS(f)

// resize proportionally to fit
Var geo as new GM16GeometryMBS(500,500)
image.resize geo, image.CubicFilter

window1.Title = image.formatExpression("%wx%h")
window1.Backdrop = image.CopyPicture

See also:

GM16ImageMBS.resize(geo as GM16GeometryMBS, filterType as Integer, blur as double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Resize image, specifying geometry, filter, and blur.
Example
Var f as folderitem = SpecialFolder.Desktop.Child("test.jpg")
Var image as new GM16ImageMBS(f)

// resize proportionally to fit
Var geo as new GM16GeometryMBS(500,500)
image.resize geo, image.CubicFilter, 3

window1.Title = image.formatExpression("%wx%h")
window1.Backdrop = image.CopyPicture

See also:

GM16ImageMBS.roll(columns as UInt32, rows as UInt32)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Roll image (rolls image vertically and horizontally) by specified number of columnms and rows).
Example
Var p as Picture = LogoMBS(500)
Var image as new GM16ImageMBS(p)

image.roll(30,30)

Backdrop=image.CopyPicture

See also:

GM16ImageMBS.roll(roll as GM16GeometryMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Roll image (rolls image vertically and horizontally) by specified number of columnms and rows).
Example
Var p as Picture = LogoMBS(500)
Var image as new GM16ImageMBS(p)

image.roll(GM16GeometryMBS.Make(0,0,30,30))

Backdrop=image.CopyPicture

See also:

GM16ImageMBS.rotate(degree as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method GraphicsMagick MBS GraphicsMagick Plugin 14.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Rotate image counter-clockwise by specified number of degrees.
Example
Var p as Picture = LogoMBS(500)
Var image as new GM16ImageMBS(p)

image.rotate(30)

Backdrop=image.CopyPicture

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


The biggest plugin in space...