MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/Falcor / bindCustomGPUDescriptorPool

Method bindCustomGPUDescriptorPool

Source/Falcor/Core/API/CopyContext.cpp:243–262  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

241void CopyContext::bindDescriptorHeaps() {}
242
243void CopyContext::bindCustomGPUDescriptorPool()
244{
245#if FALCOR_HAS_D3D12
246 mpDevice->requireD3D12();
247
248 const D3D12DescriptorPool* pGpuPool = mpDevice->getD3D12GpuDescriptorPool().get();
249 const D3D12DescriptorPool::ApiData* pData = pGpuPool->getApiData();
250 ID3D12DescriptorHeap* pHeaps[D3D12DescriptorPool::ApiData::kHeapCount];
251 uint32_t heapCount = 0;
252 for (uint32_t i = 0; i < std::size(pData->pHeaps); i++)
253 {
254 if (pData->pHeaps[i])
255 {
256 pHeaps[heapCount] = pData->pHeaps[i]->getApiHandle();
257 heapCount++;
258 }
259 }
260 mpLowLevelData->getCommandBufferNativeHandle().as<ID3D12GraphicsCommandList*>()->SetDescriptorHeaps(heapCount, pHeaps);
261#endif
262}
263
264void CopyContext::unbindCustomGPUDescriptorPool()
265{

Callers

nothing calls this directly

Calls 4

requireD3D12Method · 0.80
sizeFunction · 0.50
getMethod · 0.45

Tested by

no test coverage detected