LEADTOOLS GDI/GDI+ (Leadtools.Drawing assembly) Send comments on this topic. | Back to Introduction - All Topics | Help Version 17.0.3.29
ChangeToHBitmap(RasterImage,IntPtr) Method
See Also 



image
The source image.
hdc
Handle to the device responsible for the conversion. The mapping mode of the device context must be MM_TEXT.
image
The source image.
hdc
Handle to the device responsible for the conversion. The mapping mode of the device context must be MM_TEXT.
Changes a LEADTOOLS Leadtools.RasterImage object to a Windows Device Dependent Bitmap (DDB).

Syntax

Visual Basic (Declaration) 
Overloads Public Shared Function ChangeToHBitmap( _
   ByVal image As RasterImage, _
   ByVal hdc As IntPtr _
) As IntPtr
Visual Basic (Usage)Copy Code
Dim image As RasterImage
Dim hdc As IntPtr
Dim value As IntPtr
 
value = RasterImageConverter.ChangeToHBitmap(image, hdc)
C# 
public static IntPtr ChangeToHBitmap( 
   RasterImage image,
   IntPtr hdc
)
C++/CLI 
public:
static IntPtr ChangeToHBitmap( 
   RasterImage^ image,
   IntPtr hdc
) 

Parameters

image
The source image.
hdc
Handle to the device responsible for the conversion. The mapping mode of the device context must be MM_TEXT.

Return Value

A handle to the device dependent bitmap (DDB) this method creates.

Example

For an example, refer to ChangeToHBitmap(RasterImage,IntPtr).

Remarks

This method results in only one copy of the image, and it invalidates this Leadtools.RasterImage object. You must call RasterImage.Dispose after calling this method.

For more information on DDBs and DIBs, refer to Using DIBs, DDBs, and the Clipboard.

For more information refer to RasterImage and GDI/GDI+.

Requirements

Target Platforms: Silverlight 3.0, Windows XP, Windows Server 2003 family, Windows Server 2008 family, Windows Vista, Windows 7, MAC OS/X (Intel Only)

See Also