![]() |
![]() |
![]() |
Resource.SetPriority Method |
Language: |
Assigns the resource-management priority for the current resource.
Visual Basic Public Function SetPriority( _
ByVal priorityNew As Integer _
) As IntegerC# public int SetPriority(
int priorityNew
);C++ public:
int SetPriority(
int priorityNew
);JScript public function SetPriority(
priorityNew : int
) : int;
priorityNew System.Int32
New resource-management priority for the resource.
System.Int32
Previous priority value for the resource.
Resource.SetPriority is used for priority control of managed resources. This method returns 0 on nonmanaged resources.
Priorities are used to determine when managed resources should 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 one that was used more recently is kept in memory, while the other is removed. Managed resources have a default priority of 0.
BaseTexture, IndexBuffer, Surface, VertexBuffer
Send comments about this topic to Microsoft. © Microsoft Corporation. All rights reserved.
Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center