| 39 | namespace Falcor |
| 40 | { |
| 41 | LowLevelContextData::LowLevelContextData(Device* pDevice, gfx::ICommandQueue* pQueue) : mpDevice(pDevice), mpGfxCommandQueue(pQueue) |
| 42 | { |
| 43 | mpFence = mpDevice->createFence(); |
| 44 | mpFence->breakStrongReferenceToDevice(); |
| 45 | |
| 46 | #if FALCOR_HAS_CUDA |
| 47 | // GFX currently doesn't support shared fences on Vulkan. |
| 48 | if (mpDevice->getType() == Device::Type::D3D12) |
| 49 | { |
| 50 | mpDevice->initCudaDevice(); |
| 51 | mpCudaFence = mpDevice->createFence(true); |
| 52 | mpCudaFence->breakStrongReferenceToDevice(); |
| 53 | mpCudaSemaphore = make_ref<cuda_utils::ExternalSemaphore>(mpCudaFence); |
| 54 | } |
| 55 | #endif |
| 56 | |
| 57 | openCommandBuffer(); |
| 58 | } |
| 59 | |
| 60 | LowLevelContextData::~LowLevelContextData() |
| 61 | { |
nothing calls this directly
no test coverage detected