MCPcopy Create free account
hub / github.com/TheRealMJP/Shadows / DispatchSize

Function DispatchSize

Shadows/SampleFramework11/Utility.cpp:96–101  ·  view source on GitHub ↗

Computes a compute shader dispatch size given a thread group size, and number of elements to process

Source from the content-addressed store, hash-verified

94
95// Computes a compute shader dispatch size given a thread group size, and number of elements to process
96uint32 DispatchSize(uint32 tgSize, uint32 numElements)
97{
98 uint32 dispatchSize = numElements / tgSize;
99 dispatchSize += numElements % tgSize > 0 ? 1 : 0;
100 return dispatchSize;
101}
102
103void SetCSInputs(ID3D11DeviceContext* context, ID3D11ShaderResourceView* srv0, ID3D11ShaderResourceView* srv1,
104 ID3D11ShaderResourceView* srv2, ID3D11ShaderResourceView* srv3)

Callers 4

RenderModelDepthGPUMethod · 0.85
ProjectCubemapToSHFunction · 0.85
GetTextureDataFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected