Export (0) Print
Expand All

ID3D10Resource::SetEvictionPriority method

Set the eviction priority of a resource.

Syntax


void SetEvictionPriority(
  [in]  UINT EvictionPriority
);

Parameters

EvictionPriority [in]

Type: UINT

Eviction priority for the resource, which is one of the following values:

  • DXGI_RESOURCE_PRIORITY_MINIMUM
  • DXGI_RESOURCE_PRIORITY_LOW
  • DXGI_RESOURCE_PRIORITY_NORMAL
  • DXGI_RESOURCE_PRIORITY_HIGH
  • DXGI_RESOURCE_PRIORITY_MAXIMUM

Return value

Returns nothing.

Remarks

Resource priorities determine which resource to evict from video memory when the system has run out of video memory. The resource will not be lost; it will be removed from video memory and placed into system memory, or possibly placed onto the hard drive. The resource will be loaded back into video memory when it is required.

A resource that is set to the maximum priority, DXGI_RESOURCE_PRIORITY_MAXIMUM, is only evicted if there is no other way of resolving the incoming memory request. The Windows Display Driver Model (WDDM) tries to split an incoming memory request to its minimum size and evict lower-priority resources before evicting a resource with maximum priority.

Changing the priorities of resources should be done carefully. The wrong eviction priorities could be a detriment to performance rather than an improvement. See QueryResourceResidency for additional information.

This method is a wrapper for SetEvictionPriority and is provided in the ID3D10Resource Interface interface for convenience.

Requirements

Header

D3D10.h

Library

D3D10.lib

See also

ID3D10Resource Interface

 

 

Community Additions

ADD
Show:
© 2014 Microsoft