| 40 | ComputeContext::~ComputeContext() {} |
| 41 | |
| 42 | void ComputeContext::dispatch(ComputeState* pState, ProgramVars* pVars, const uint3& dispatchSize) |
| 43 | { |
| 44 | pVars->prepareDescriptorSets(this); |
| 45 | |
| 46 | auto computeEncoder = mpLowLevelData->getComputeCommandEncoder(); |
| 47 | FALCOR_GFX_CALL(computeEncoder->bindPipelineWithRootObject(pState->getCSO(pVars)->getGfxPipelineState(), pVars->getShaderObject())); |
| 48 | FALCOR_GFX_CALL(computeEncoder->dispatchCompute((int)dispatchSize.x, (int)dispatchSize.y, (int)dispatchSize.z)); |
| 49 | mCommandsPending = true; |
| 50 | } |
| 51 | |
| 52 | void ComputeContext::dispatchIndirect(ComputeState* pState, ProgramVars* pVars, const Buffer* pArgBuffer, uint64_t argBufferOffset) |
| 53 | { |