Marblecore Imaging Library Documentation

Documentation Introduction
Documentation / Marblecore Imaging / Methods / MaskOverlayFromStream

MaskOverlayFromStream method

Mask the alpha channel of the specified stream over the image. The mask image needs to be a 32 bits image.

Syntax

Boolean MaskOverlayFromStream(pStream As Stream, nLength As Number, bInvert As Boolean, nBackgroundColor As Number, nBackgroundOpacity As Number, nLeft As Number, nTop As Number, nWidth As Number, nHeight As Number)

Return value

Returns true if the function succeeded.

Parameters

ParameterTypeRequiredDescription
pStreamStreamYesPointer to the memory stream.
nLengthNumberYesNumber of bytes passed through the stream.
bInvertBooleanNoOptional parameter which can be used to invert the mask.
nBackgroundColorNumberNoOptional parameter which specifies the background color to use. If omitted the current background color will be used for non-transparent images or an alpha channel will be used for transparent images.
nBackgroundOpacityNumberNoOptional parameter which specifies the background opacity.
nLeftNumberNoOptional parameter which can be used to specify a clipping rectangle. This parameter specifies the left coordinate of the rectangle.
nTopNumberNoOptional parameter which can be used to specify a clipping rectangle. This parameter specifies the top coordinate of the rectangle.
nWidthNumberNoOptional parameter which can be used to specify a clipping rectangle. This parameter specifies the width of the rectangle.
nHeightNumberNoOptional parameter which can be used to specify a clipping rectangle. This parameter specifies the height of the rectangle.

Category

Masking

See also

Mask | MaskOverlayFromBase64 | MaskOverlayFromFile | MaskOverlayFromSerializedStream | MaskOverlayFromURL | Working with streams