pfnFlipOverlayCb routine

The pfnFlipOverlayCb function changes the allocation to display on the overlay or indicates to display the other field of the currently displaying allocation, when deinterlacing an interleaved resource.

Syntax


PFND3DDDI_FLIPOVERLAYCB pfnFlipOverlayCb;

__checkReturn HRESULT APIENTRY CALLBACK pfnFlipOverlayCb(
  _In_  HANDLE hDevice,
  _In_  const D3DDDICB_FLIPOVERLAY *pData
)
{ ... }

Parameters

hDevice [in]

A handle to the display device (graphics context).

pData [in]

A pointer to a D3DDDICB_FLIPOVERLAY structure that describes how to change the display on the overlay.

Return value

pfnFlipOverlayCb returns one of the following values:

Return codeDescription
S_OK

The display on the overlay object was successfully changed.

E_INVALIDARG

Parameters were validated and determined to be incorrect.

E_OUTOFMEMORY

pfnFlipOverlayCb could not allocate memory that was required for it to complete.

 

This function might also return other HRESULT values.

Examples

The following code example shows how to flip the overlay object.


HRESULT CD3DContext::FlipOverlay(CONST D3DDDIARG_FLIPOVERLAY* pFlipOverlay)
{
    D3DDDICB_FLIPOVERLAY FlipCB;
    DWORD_PTR dwResource = (DWORD_PTR) pFlipOverlay->hSource;
    dwResource += pFlipOverlay->SourceIndex;
    LONG dwTempPitch;

    FlipCB.hKernelOverlay = (D3DKMT_HANDLE) g_hOverlay;
    FlipCB.hSource = R200GetAllocationHandle(m_pR200Ctx,
                                    (DWORD)dwResource,
                                     &dwTempPitch);

    FlipCB.pPrivateDriverData = "This is a test";
    FlipCB.PrivateDriverDataSize = 10;

    HRESULT hr = m_d3dCallbacks.pfnFlipOverlayCb(m_hD3D, &FlipCB);

    return S_OK;
}

Requirements

Version

Available in Windows Vista and later versions of the Windows operating systems.

Header

D3dumddi.h (include D3dumddi.h)

See also

D3DDDI_DEVICECALLBACKS
D3DDDICB_FLIPOVERLAY

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft