Leadtools Send comments on this topic. | Back to Introduction - All Topics | Help Version 15.3.5
CreateMaskFromRegion Method
See Also 
Leadtools Namespace > RasterImage Class : CreateMaskFromRegion Method




Creates a 1-bit mask image from the region that is defined in the image.

Syntax

Visual Basic (Declaration) 
Public Function CreateMaskFromRegion() As RasterImage
Visual Basic (Usage)Copy Code
Dim instance As RasterImage
Dim value As RasterImage
 
value = instance.CreateMaskFromRegion()
C# 
public RasterImage CreateMaskFromRegion()
Managed Extensions for C++ 
public: RasterImage* CreateMaskFromRegion(); 
C++/CLI 
public:
RasterImage^ CreateMaskFromRegion(); 

Return Value

The newly created RasterImage which will be updated with a 1-bit, black-and-white image, where pixels from the region are white, and all others are black.

Example

This example will load an image, sets a color region using black, and then creates a 1-bit mask image from that image and saves it to disk .

Remarks

For more information, refer to Implementing Transparency.

For more information, refer to Creating a Region.

For more information, refer to Saving A Region.

For more information, refer to Working with the Existing Region.

Requirements

Target Platforms: Microsoft .NET Framework 2.0, Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also