BeginBufferedPaint function (uxtheme.h)

Begins a buffered paint operation.

Syntax

HPAINTBUFFER BeginBufferedPaint(
        HDC             hdcTarget,
        const RECT      *prcTarget,
        BP_BUFFERFORMAT dwFormat,
  [in]  BP_PAINTPARAMS  *pPaintParams,
  [out] HDC             *phdc
);

Parameters

hdcTarget

Type: HDC

The handle of the target DC on which the buffer will be painted.

prcTarget

Type: const RECT*

A pointer to a RECT structure that specifies the area of the target DC in which to paint.

dwFormat

Type: BP_BUFFERFORMAT

A member of the BP_BUFFERFORMAT enumeration that specifies the format of the buffer.

[in] pPaintParams

Type: BP_PAINTPARAMS*

A pointer to a BP_PAINTPARAMS structure that defines the paint operation parameters. This value can be NULL.

[out] phdc

Type: HDC*

When this function returns, points to the handle of the new device context.

Return value

Type: HPAINTBUFFER

A handle to the buffered paint context. If this function fails, the return value is NULL, and phdc is NULL. To get extended error information, call GetLastError.

The returned handle is freed when EndBufferedPaint is called.

An application should call BufferedPaintInit on the calling thread before calling BeginBufferedPaint, and BufferedPaintUnInit before the thread is terminated. Failure to call BufferedPaintInit may result in degraded performance due to internal data being initialized and destroyed for each buffered paint operation.

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2008 [desktop apps only]
Target Platform Windows
Header uxtheme.h
DLL UxTheme.dll