다음을 통해 공유


CBitmapRenderTarget Class

 

The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.

The latest version of this topic can be found at CBitmapRenderTarget Class.

A wrapper for ID2D1BitmapRenderTarget.

Syntax

class CBitmapRenderTarget : public CRenderTarget;  

Members

Public Constructors

Name Description
CBitmapRenderTarget::CBitmapRenderTarget Constructs a CBitmapRenderTarget object.

Public Methods

Name Description
CBitmapRenderTarget::Attach Attaches existing render target interface to the object
CBitmapRenderTarget::Detach Detaches render target interface from the object
CBitmapRenderTarget::GetBitmap Retrieves the bitmap for this render target. The returned bitmap can be used for drawing operations.
CBitmapRenderTarget::GetBitmapRenderTarget Returns ID2D1BitmapRenderTarget interface

Public Operators

Name Description
CBitmapRenderTarget::operator ID2D1BitmapRenderTarget* Returns ID2D1BitmapRenderTarget interface

Protected Data Members

Name Description
CBitmapRenderTarget::m_pBitmapRenderTarget A pointer to an ID2D1BitmapRenderTarget object.

Inheritance Hierarchy

CObject

CRenderTarget

CBitmapRenderTarget

Requirements

Header: afxrendertarget.h

CBitmapRenderTarget::Attach

Attaches existing render target interface to the object

void Attach(ID2D1BitmapRenderTarget* pTarget);

Parameters

pTarget
Existing render target interface. Cannot be NULL

CBitmapRenderTarget::CBitmapRenderTarget

Constructs a CBitmapRenderTarget object.

CBitmapRenderTarget();

CBitmapRenderTarget::Detach

Detaches render target interface from the object

ID2D1BitmapRenderTarget* Detach();

Return Value

Pointer to detached render target interface.

CBitmapRenderTarget::GetBitmap

Retrieves the bitmap for this render target. The returned bitmap can be used for drawing operations.

BOOL GetBitmap(CD2DBitmap& bitmap);

Parameters

bitmap
When this method returns, contains the valid bitmap for this render target. This bitmap can be used for drawing operations.

Return Value

If the method succeeds, it returns TRUE. Otherwise, it returns FALSE.

CBitmapRenderTarget::GetBitmapRenderTarget

Returns ID2D1BitmapRenderTarget interface

ID2D1BitmapRenderTarget* GetBitmapRenderTarget();

Return Value

Pointer to an ID2D1BitmapRenderTarget interface or NULL if object is not initialized yet.

CBitmapRenderTarget::m_pBitmapRenderTarget

A pointer to an ID2D1BitmapRenderTarget object.

ID2D1BitmapRenderTarget* m_pBitmapRenderTarget;  

CBitmapRenderTarget::operator ID2D1BitmapRenderTarget*

Returns ID2D1BitmapRenderTarget interface

operator ID2D1BitmapRenderTarget*();

Return Value

Pointer to an ID2D1BitmapRenderTarget interface or NULL if object is not initialized yet.

See Also

Classes