| 73 | static SharedCache<FullScreenPass::SharedData, Device*> sSharedCache; |
| 74 | |
| 75 | FullScreenPass::FullScreenPass(ref<Device> pDevice, const ProgramDesc& progDesc, const DefineList& programDefines) |
| 76 | : BaseGraphicsPass(pDevice, progDesc, programDefines) |
| 77 | { |
| 78 | // Get shared VB and VAO. |
| 79 | mpSharedData = sSharedCache.acquire(mpDevice, [this]() { return std::make_shared<SharedData>(mpDevice); }); |
| 80 | |
| 81 | // Create depth stencil state |
| 82 | FALCOR_ASSERT(mpState); |
| 83 | auto pDsState = DepthStencilState::create(DepthStencilState::Desc().setDepthEnabled(false)); |
| 84 | mpState->setDepthStencilState(pDsState); |
| 85 | |
| 86 | mpState->setVao(mpSharedData->pVao); |
| 87 | } |
| 88 | |
| 89 | FullScreenPass::~FullScreenPass() = default; |
| 90 | |