IDirect3DResource9::SetPriority
IDirect3DResource9::SetPriority
Assigns the resource-management priority for this resource.
DWORD SetPriority( DWORD PriorityNew );
Parameters
- PriorityNew
[in] DWORD value that specifies the new resource-management priority for the resource. Possible values are- D3D9_RESOURCE_PRIORITY_DISCARD
- D3D9_RESOURCE_PRIORITY_LOW
- D3D9_RESOURCE_PRIORITY_NORMAL
- D3D9_RESOURCE_PRIORITY_HIGH
- D3D9_RESOURCE_PRIORITY_MAXIMUM
Return Values
Returns the previous priority value for the resource.
Remarks
Priorities are used to determine when resources are to be removed from memory. A resource assigned a low priority is removed before a resource with a high priority. If two resources have the same priority, the resource that was used more recently is kept in memory; the other resource is removed.
Values other than D3D9_RESOURCE_PRIORITY_DISCARD and D3D9_RESOURCE_PRIORITY_MAXIMUM are treated as hints by the scheduler.
Requirements
Header: Declared in D3d9.h.