Class DxgiDevice2
The IDXGIDevice2
interface implements a derived class for DXGI objects that produce image data. The interface exposes methods to block CPU processing until the GPU completes processing, and to offer resources to the operating system.
Inherited Members
Namespace: JeremyAnsel.DirectX.Dxgi
Assembly: JeremyAnsel.DirectX.Dxgi.dll
Syntax
public sealed class DxgiDevice2 : DxgiObject, IDisposable, IDxgiReleasable
Constructors
| Edit this page View SourceDxgiDevice2(object)
Initializes a new instance of the DxgiDevice2 class.
Declaration
public DxgiDevice2(object device)
Parameters
Type | Name | Description |
---|---|---|
object | device | A device interface which implements the |
Properties
| Edit this page View SourceHandle
Gets an handle representing the DXGI object interface.
Declaration
public override object Handle { get; }
Property Value
Type | Description |
---|---|
object |
Overrides
| Edit this page View SourceMaximumFrameLatency
Gets or sets the number of frames that the system is allowed to queue for rendering.
Declaration
public uint MaximumFrameLatency { get; set; }
Property Value
Type | Description |
---|---|
uint | The number of frames that can be queued for render. This value defaults to 3, but can range from 1 to 16. |
Methods
| Edit this page View SourceGetAdapter()
Returns the adapter for the specified device.
Declaration
public DxgiAdapter2 GetAdapter()
Returns
Type | Description |
---|---|
DxgiAdapter2 | The adapter for the specified device. |
OfferResources(DxgiResource2[], DxgiOfferResourcePriority)
Allows the operating system to free the video memory of resources by discarding their content.
Declaration
public void OfferResources(DxgiResource2[] resources, DxgiOfferResourcePriority priority)
Parameters
Type | Name | Description |
---|---|---|
DxgiResource2[] | resources | An array of pointers to |
DxgiOfferResourcePriority | priority | A |
QueryResourceResidency(DxgiResource2[])
Gets the residency status of an array of resources.
Declaration
public DxgiResidency[] QueryResourceResidency(DxgiResource2[] resources)
Parameters
Type | Name | Description |
---|---|---|
DxgiResource2[] | resources | An array of |
Returns
Type | Description |
---|---|
DxgiResidency[] | An array of |
ReclaimResources(DxgiResource2[])
Restores access to resources that were previously offered by calling IDXGIDevice2::OfferResources
.
Declaration
public bool[] ReclaimResources(DxgiResource2[] resources)
Parameters
Type | Name | Description |
---|---|---|
DxgiResource2[] | resources | An array of pointers to |
Returns
Type | Description |
---|---|
bool[] | A pointer to an array that receives Boolean values. Each value in the array corresponds to a resource at the same index that the ppResources parameter specifies. The runtime sets each Boolean value to |