From cc6c4bac6b4e05994ba2bbb4441514eb899ee670 Mon Sep 17 00:00:00 2001 From: Egor Yusov Date: Sat, 1 Dec 2018 10:46:24 -0800 Subject: Added state transition mode to ClearRenderTarget() --- unityplugin/GhostCubeScene/src/GhostCubeScene.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'unityplugin') diff --git a/unityplugin/GhostCubeScene/src/GhostCubeScene.cpp b/unityplugin/GhostCubeScene/src/GhostCubeScene.cpp index b3762e6..49dd3a1 100644 --- a/unityplugin/GhostCubeScene/src/GhostCubeScene.cpp +++ b/unityplugin/GhostCubeScene/src/GhostCubeScene.cpp @@ -158,7 +158,7 @@ void GhostCubeScene::Render(UnityRenderingEvent RenderEventFunc) ITextureView *pDSV = m_pDepthBuffer->GetDefaultView(TEXTURE_VIEW_DEPTH_STENCIL); pCtx->SetRenderTargets(1, pRTVs, pDSV, SET_RENDER_TARGETS_FLAG_TRANSITION_ALL); const float ClearColor[] = { 0.f, 0.2f, 0.5f, 1.0f }; - pCtx->ClearRenderTarget(pRTVs[0], ClearColor); + pCtx->ClearRenderTarget(pRTVs[0], ClearColor, CLEAR_RENDER_TARGET_TRANSITION_STATE); pCtx->ClearDepthStencil(pDSV, CLEAR_DEPTH_FLAG, ReverseZ ? 0.f : 1.f, 0); if (DeviceCaps.DevType == DeviceType::D3D12) -- cgit v1.2.3