Skip to content

Latest commit

 

History

History
99 lines (67 loc) · 4.15 KB

nc-d3dumddi-pfnd3dddi_offerallocations2cb.md

File metadata and controls

99 lines (67 loc) · 4.15 KB
UID title description old-location tech.root ms.date keywords ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames f1_keywords topic_type api_type api_location api_name
NC:d3dumddi.PFND3DDDI_OFFERALLOCATIONS2CB
PFND3DDDI_OFFERALLOCATIONS2CB (d3dumddi.h)
The PFND3DDDI_OFFERALLOCATIONS2CB callback function is called by the user-mode display driver to offer video memory allocations for reuse.
display\pfnofferallocations2cb.htm
display
05/10/2018
PFND3DDDI_OFFERALLOCATIONS2CB callback function
PFND3DDDI_OFFERALLOCATIONS2CB, PFND3DDDI_OFFERALLOCATIONS2CB callback, d3dumddi/pfnOfferAllocations2Cb, display.pfnofferallocations2cb, pfnOfferAllocations2Cb, pfnOfferAllocations2Cb callback function [Display Devices]
d3dumddi.h
D3dumddi.h
Windows
Windows 10
Windows Server 2016
Windows
PFND3DDDI_OFFERALLOCATIONS2CB
d3dumddi/PFND3DDDI_OFFERALLOCATIONS2CB
APIRef
kbSyntax
UserDefined
d3dumddi.h
PFND3DDDI_OFFERALLOCATIONS2CB

PFND3DDDI_OFFERALLOCATIONS2CB callback function

-description

Called by the user-mode display driver to offer video memory allocations for reuse.

-parameters

-param hDevice

A handle to the display device (graphics context). The Direct3D runtime passed the user-mode driver this handle as the hDevice member of the D3DDDIARG_CREATEDEVICE structure at device creation.

-param unnamedParam2

pData [in]

A pointer to a D3DDDICB_OFFERALLOCATIONS2 structure that defines the video memory allocations that the driver offers.

-returns

Returns one of the following values.

Return code Description
S_OK The allocations were successfully offered.
Note: If the driver does not need to call pfnOfferAllocations2Cb , it should return S_OK.
D3DDDIERR_DEVICEREMOVED The video memory manager or display miniport driver could not complete the operation because either a Plug and Play (PnP) Stop event or a Timeout Detection and Recovery (TDR) event occurred.
Note: If this error code is returned, the driver's calling function (typically the pfnOfferResources routine) must return this error code to the Direct3D runtime.
E_INVALIDARG An invalid parameter was supplied.

-remarks

The user-mode display driver calls pfnOfferAllocations2Cb to notify the Microsoft DirectX graphics kernel subsystem that, after it completes any previously submitted render operations, it can offer the allocations' memory for other processes to use.

After the driver calls pfnOfferAllocations2Cb to offer an allocation to reuse, it must call pfnReclaimAllocations3Cb before it locks the allocation or submits it for rendering operations.

pfnOfferAllocations2Cb functions identically to pfnOfferAllocationsCb, except that it takes flags into account through the pData parameter.

-see-also

D3DDDIARG_CREATEDEVICE

D3DDDICB_OFFERALLOCATIONS2

D3DDDI_DEVICECALLBACKS

pfnOfferResources

pfnReclaimAllocations3Cb