D3DKMT_OPENSYNCOBJECTFROMNTHANDLE2 structure (d3dkmthk.h)

D3DKMT_OPENSYNCOBJECTFROMNTHANDLE2 is used with D3DKMTOpenSyncObjectFromNtHandle2 to open a monitored fence object.

Syntax

typedef struct _D3DKMT_OPENSYNCOBJECTFROMNTHANDLE2 {
  [in]  HANDLE                             hNtHandle;
  [in]  D3DKMT_HANDLE                      hDevice;
  [in]  D3DDDI_SYNCHRONIZATIONOBJECT_FLAGS Flags;
  [out] D3DKMT_HANDLE                      hSyncObject;
  union {
    struct {
      VOID                                  *FenceValueCPUVirtualAddress;
      D3DKMT_ALIGN64 D3DGPU_VIRTUAL_ADDRESS FenceValueGPUVirtualAddress;
      UINT                                  EngineAffinity;
    } MonitoredFence;
          D3DKMT_ALIGN64 UINT64 Reserved[8];
  };
} D3DKMT_OPENSYNCOBJECTFROMNTHANDLE2;

Members

[in] hNtHandle

NT handle for the sync object to be opened.

[in] hDevice

Device handle to use this sync object on.

[in] Flags

Specifies the desired sync object behavior for this device, such as wait and signal semantics and TDR handling.

[out] hSyncObject

Handle to the sync object that can be used in this process.

MonitoredFence

Contains sync object virtual addresses that can be used in this process.

[out] MonitoredFence.FenceValueCPUVirtualAddress

A read-only mapping of the fence value for the CPU. This is a user mode address readable from the process that created the monitored fence object. For 32 bit platforms that support 64 bit atomic reads via methods such as InterlockedCompareExchange64(pointer,0,0), the mapping will be made read-write instead of read-only to avoid an access violation during the interlocked operation. Depending on the value of No64BitAtomics cap, this address points to either a 32 bit or a 64 bit underlying value.

[out] MonitoredFence.FenceValueGPUVirtualAddress

A read-write mapping of the fence value for the GPU. A driver can signal a new fence value by inserting a GPU write command for this address into a command buffer, and the DirectX graphics kernel will unblock waiters for this fence object value. This GPU virtual address is mapped asynchronously, and the driver should wait for the device that opened or created the monitored fence synchronization object to reach PagingFenceValue on its paging fence object prior to accessing this GPU virtual address. Depending on the value of No64BitAtomics cap, this address points to either a 32 bit or a 64 bit underlying value.

[in] MonitoredFence.EngineAffinity

A bit field, where each bit position (starting from zero) defines a physical adapter index in a linked display adapter link where the GPU virtual address will be committed. Zero means that GPU virtual address will be committed to all physical adapters.

Reserved[8]

The consolidated value of the MonitoredFence structure.

Requirements

Requirement Value
Minimum supported client Windows 10
Minimum supported server Windows Server 2016
Header d3dkmthk.h (include D3dkmthk.h)

See also

D3DKMTOpenSyncObjectFromNtHandle2