Expand Minimize

D3DDDIARG_OPENRESOURCE structure

The D3DDDIARG_OPENRESOURCE structure contains information for opening a shared resource.

Syntax


typedef struct _D3DDDIARG_OPENRESOURCE {
  UINT                      NumAllocations;
#if (D3D_UMD_INTERFACE_VERSION >= D3D_UMD_INTERFACE_VERSION_WIN7)
  union {
    D3DDDI_OPENALLOCATIONINFO  *pOpenAllocationInfo;
    D3DDDI_OPENALLOCATIONINFO2 *pOpenAllocationInfo2;
  };
#else 
  D3DDDI_OPENALLOCATIONINFO *pOpenAllocationInfo;
#endif 
  D3DKMT_HANDLE             hKMResource;
  VOID                      *pPrivateDriverData;
  UINT                      PrivateDriverDataSize;
  HANDLE                    hResource;
  D3DDDI_ROTATION           Rotation;
  D3DDDI_OPENRESOURCEFLAGS  Flags;
} D3DDDIARG_OPENRESOURCE;

Members

NumAllocations

[in] The number of elements in the array that is specified by pOpenAllocationInfo. NumAllocations represents the number of allocations to open.

pOpenAllocationInfo

[in] An array of D3DDDI_OPENALLOCATIONINFO structures that describe the allocations in the resource to open.

pOpenAllocationInfo2

This member is reserved and should be set to zero.

This member is available beginning with Windows 7.

pOpenAllocationInfo

[in] An array of D3DDDI_OPENALLOCATIONINFO structures that describe the allocations in the resource to open.

hKMResource

[in] A D3DKMT_HANDLE data type that represents a kernel-mode handle to the resource that is associated with the allocations.

This kernel-mode handle represents an existing shared resource that was previously created through a call to the user-mode display driver's CreateResource function.

pPrivateDriverData

[in] A pointer to private data that was passed to the display miniport driver when the resource was created. This data is per resource and not per allocation like the private data in each allocation's D3DDDI_OPENALLOCATIONINFO structure.

PrivateDriverDataSize

[in] The size, in bytes, of the private data that is pointed to by pPrivateDriverData.

hResource

[in/out] A handle to the resource that is associated with the allocations.

The user-mode display driver should save this handle and use it to identify the resource anytime that the driver calls back into the Microsoft Direct3D runtime. The user-mode display driver should generate a unique handle and pass it back to the Direct3D runtime. The Direct3D runtime uses this handle in driver calls to identify the resource.

Rotation

[in] A D3DDDI_ROTATION-typed value that identifies the orientation of the shared primary resource.

When the primary resource is used with a full-screen device and is rotated, the driver might be required to create interim allocations to handle the full-screen device. The Fullscreen bitfield flag is set in the Flags member to indicate that the primary resource is used with a full-screen device.

Flags

[in] A D3DDDI_OPENRESOURCEFLAGS structure that identifies the type of resource to open.

Remarks

The Primary and SharedResource bit-field flags are set in the Flags member of the D3DDDIARG_CREATERESOURCE structure in a call to the CreateResource function to create a shared primary resource.

Requirements

Version

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

Header

D3dumddi.h (include D3dumddi.h)

See also

CreateResource
D3DDDI_OPENALLOCATIONINFO
D3DDDI_OPENRESOURCEFLAGS
D3DDDI_ROTATION
D3DDDIARG_CREATERESOURCE
OpenResource

 

 

Send comments about this topic to Microsoft

Show:
© 2015 Microsoft