ID3D11ShaderReflection::GetThreadGroupSize method (d3d11shader.h)

Retrieves the sizes, in units of threads, of the X, Y, and Z dimensions of the shader's thread-group grid.

Syntax

UINT GetThreadGroupSize(
  [out, optional] UINT *pSizeX,
  [out, optional] UINT *pSizeY,
  [out, optional] UINT *pSizeZ
);

Parameters

[out, optional] pSizeX

Type: UINT*

A pointer to the size, in threads, of the x-dimension of the thread-group grid. The maximum size is 1024.

[out, optional] pSizeY

Type: UINT*

A pointer to the size, in threads, of the y-dimension of the thread-group grid. The maximum size is 1024.

[out, optional] pSizeZ

Type: UINT*

A pointer to the size, in threads, of the z-dimension of the thread-group grid. The maximum size is 64.

Return value

Type: UINT

Returns the total size, in threads, of the thread-group grid by calculating the product of the size of each dimension.

*pSizeX * *pSizeY * *pSizeZ;

Remarks

This method's interface is hosted in the out-of-box DLL D3DCompiler_xx.dll.

When a compute shader is written it defines the actions of a single thread group only. If multiple thread groups are required, it is the role of the ID3D11DeviceContext::Dispatch call to issue multiple thread groups.

Requirements

Requirement Value
Target Platform Windows
Header d3d11shader.h
Library D3DCompiler.lib
DLL D3DCompiler_47.dll

See also

ID3D11ShaderReflection