IDXGIDevice::SetGPUThreadPriority Method

Sets the GPU thread priority.

Syntax

public:
HRESULT SetGPUThreadPriority(
         INT Priority
)  

Parameters

Priority
Type: INT 

A value that specifies the required GPU thread priority. This value must be between -7 and 7, inclusive, where 0 represents normal priority.

Return value

Type: HRESULT 

Return S_OK if successful; otherwise, returns E_INVALIDARG if the Priority parameter is invalid.

Remarks

The values for the Priority parameter function as follows:

To use the SetGPUThreadPriority method, you should have a comprehensive understanding of GPU scheduling. You should profile your application to ensure that it behaves as intended. If used inappropriately, the SetGPUThreadPriority method can impede rendering speed and result in a poor user experience.

Requirements

Header: Declared in d3d11_x.h (dxgi.h on other Windows platforms).

Library: Use d3d11_x.lib (dxgi.lib on other Windows platforms).

See also

IDXGIDevice

IDXGIDevice Members