Mask

Applies the given image mask to the current image. Any area containing transparency withing the mask will be removed from the original image. If the mask is larger than the image it will be resized to match the images dimensions.

public ImageFactory Mask(ImageLayer imageLayer)
    

Parameters

imageLayer
The ImageLayer containing the Image and Nullable<System.Drawing.Point> properties necessary to mask the image.
The point property is used to place the image mask if it not the same dimensions as the original image. If no position is set, the mask will be centered within the image.
public ImageFactory Mask(Image imageMask, Point? point = null)
    

Parameters

imageMask
The image containing the mask to apply.
point
The Nullable<System.Drawing.Point>to place the mask if it not the same dimensions as the original image. If no position is set, the mask will be centered within the image.

Examples

Original

original image

Masked

image with mask applied