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

Function DispatchSize

SampleFramework11/v1.02/Utility.cpp:111–116  ·  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

109
110// Computes a compute shader dispatch size given a thread group size, and number of elements to process
111uint32 DispatchSize(uint32 tgSize, uint32 numElements)
112{
113 uint32 dispatchSize = numElements / tgSize;
114 dispatchSize += numElements % tgSize > 0 ? 1 : 0;
115 return dispatchSize;
116}
117
118void SetCSInputs(ID3D11DeviceContext* context, ID3D11ShaderResourceView* srv0, ID3D11ShaderResourceView* srv1,
119 ID3D11ShaderResourceView* srv2, ID3D11ShaderResourceView* srv3)

Callers 3

AfterResetMethod · 0.85
OnResizeMethod · 0.85
GetTextureDataFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected