// d3dumddi.h
PFND3DDDI_GETQUERYDATA Pfnd3dddiGetquerydata;
HRESULT Pfnd3dddiGetquerydata(
HANDLE hDevice,
const D3DDDIARG_GETQUERYDATA *unnamedParam2
)
{...}
View the official Windows Driver Kit DDI referenceNo description available.
The GetQueryData function retrieves information about a query.
hDeviceA handle to the display device (graphics context).
unnamedParam2pData [in, out]
A pointer to a D3DDDIARG_GETQUERYDATA structure that contains the information about the query that is retrieved from the driver.
GetQueryData returns one of the following values:
| Return code | Description |
|---|---|
| S_OK | The query operation completed and the query result is available. |
| S_FALSE | GetQueryData returned successfully. However, the query operation did not complete, so the query result is not available. |
| E_OUTOFMEMORY | GetQueryData could not allocate the required memory for it to complete. |
The Microsoft Direct3D runtime can call GetQueryData at any time after calling the user-mode display driver's IssueQuery function. The user-mode display driver should check the current fence value against the value that is stored in the driver's private query structure to determine if the query issue is complete.
If the query is completed, the driver should return S_OK; otherwise, the driver should return S_FALSE.
If a driver supports runtime-handled multiple-processor optimizations and exposes a DDI version of 0x0000000B or greater, the runtime will call GetQueryData in a reentrant manner. The driver returns the DDI-version value in the DriverVersion member of the D3D10DDIARG_OPENADAPTER structure in a call to the driver's OpenAdapter function. When the runtime calls GetQueryData in a reentrant manner, one thread can execute inside GetQueryData while another thread that references the same display device executes inside of another user-mode display driver function.