Export (0) Print
Expand All

IDWriteBitmapRenderTarget::GetMemoryDC method

Gets a handle to the memory device context.

Syntax


virtual HDC GetMemoryDC() = 0;

Parameters

This method has no parameters.

Return value

Type: HDC

Returns a device context handle to the memory device context.

Remarks

An application can use the device context to draw using GDI functions. An application can obtain the bitmap handle (HBITMAP) by calling GetCurrentObject. An application that wants information about the underlying bitmap, including a pointer to the pixel data, can call GetObject to fill in a DIBSECTION structure. The bitmap is always a 32-bit top-down DIB.

Note that this method takes no parameters and returns an HDC variable, not an HRESULT.


memoryHdc = g_pBitmapRenderTarget->GetMemoryDC();


The HDC returned here is still owned by the bitmap render targer object and should not be released or deleted by the client.

Requirements

Header

Dwrite.h

Library

Dwrite.lib

DLL

Dwrite.dll

See also

IDWriteBitmapRenderTarget

 

 

Community Additions

ADD
Show:
© 2015 Microsoft