// d3dumddi.h
PFND3DDDI_SIGNALSYNCHRONIZATIONOBJECTCB Pfnd3dddiSignalsynchronizationobjectcb;
HRESULT Pfnd3dddiSignalsynchronizationobjectcb(
HANDLE hDevice,
const D3DDDICB_SIGNALSYNCHRONIZATIONOBJECT *unnamedParam2
)
{...}
View the official Windows Driver Kit DDI referenceNo description available.
The pfnSignalSynchronizationObjectCb function inserts a signal on the specified synchronization objects in the specified context DMA stream.
hDeviceA handle to a display device (that is, the graphics context).
unnamedParam2pData [in]
A pointer to a D3DDDICB_SIGNALSYNCHRONIZATIONOBJECT structure that describes the synchronization objects and context DMA stream that signaling is set up on.
pfnSignalSynchronizationObjectCb returns one of the following values:
| Return code | Description |
|---|---|
| S_OK | The signaling was successfully set up. |
| E_INVALIDARG | Parameters were validated and determined to be incorrect. |
This function might also return other HRESULT values.
Direct3D Version 11 Note: For more information about how the driver calls pfnSignalSynchronizationObjectCb, see Changes from Direct3D 10.
The following code example shows how to insert a signal on synchronization objects.
HRESULT CD3DContext::SyncEngines(DWORD dwEngineReleasingControl, DWORD dwEngineAcquiringControl) {
HRESULT hr;
D3DDDICB_WAITFORSYNCHRONIZATIONOBJECT sWaitObject;
D3DDDICB_SIGNALSYNCHRONIZATIONOBJECT sSignalObject;
sSignalObject.hContext = m_sContexts[dwEngineReleasingControl].hContext;
sSignalObject.ObjectCount = 1;
sSignalObject.ObjectHandleArray[0] = m_hEngineSyncObject;
hr = m_d3dCallbacks.pfnSignalSynchronizationObjectCb(m_hD3D, &sSignalObject);
if (FAILED(hr)) {
DBG_BREAK;
return hr;
}
sWaitObject.hContext = m_sContexts[dwEngineAcquiringControl].hContext;
sWaitObject.ObjectCount = 1;
sWaitObject.ObjectHandleArray[0] = m_hEngineSyncObject;
hr = m_d3dCallbacks.pfnWaitForSynchronizationObjectCb(m_hD3D, &sWaitObject);
if (FAILED(hr)) {
DBG_BREAK;
}
return hr;
}
D3DDDICB_SIGNALSYNCHRONIZATIONOBJECT