Index: ps/trunk/source/renderer/Renderer.cpp =================================================================== --- ps/trunk/source/renderer/Renderer.cpp +++ ps/trunk/source/renderer/Renderer.cpp @@ -525,11 +525,16 @@ // to clear the color attachment. // We don't need a depth test to render so we don't care about the // depth-stencil attachment content. + // In case of Atlas we don't have g_Game, so we still need to clear depth. + const Renderer::Backend::AttachmentLoadOp depthStencilLoadOp = + g_AtlasGameLoop && g_AtlasGameLoop->view + ? Renderer::Backend::AttachmentLoadOp::CLEAR + : Renderer::Backend::AttachmentLoadOp::DONT_CARE; m->deviceCommandContext->BeginFramebufferPass( m->deviceCommandContext->GetDevice()->GetCurrentBackbuffer( Renderer::Backend::AttachmentLoadOp::DONT_CARE, Renderer::Backend::AttachmentStoreOp::STORE, - Renderer::Backend::AttachmentLoadOp::DONT_CARE, + depthStencilLoadOp, Renderer::Backend::AttachmentStoreOp::DONT_CARE)); } @@ -718,13 +723,15 @@ } g_Game->GetView()->GetCamera()->SetProjection(projection); - if (needsPresent && g_VideoMode.GetBackendDevice()->AcquireNextBackbuffer()) + if (!needsPresent || g_VideoMode.GetBackendDevice()->AcquireNextBackbuffer()) { RenderFrameImpl(false, false); m->deviceCommandContext->ReadbackFramebufferSync(0, 0, tileWidth, tileHeight, tileData); m->deviceCommandContext->Flush(); - g_VideoMode.GetBackendDevice()->Present(); + + if (needsPresent) + g_VideoMode.GetBackendDevice()->Present(); } // Copy the tile pixels into the main image Index: ps/trunk/source/tools/atlas/GameInterface/ActorViewer.cpp =================================================================== --- ps/trunk/source/tools/atlas/GameInterface/ActorViewer.cpp +++ ps/trunk/source/tools/atlas/GameInterface/ActorViewer.cpp @@ -543,7 +543,7 @@ deviceCommandContext->GetDevice()->GetCurrentBackbuffer( Renderer::Backend::AttachmentLoadOp::DONT_CARE, Renderer::Backend::AttachmentStoreOp::STORE, - Renderer::Backend::AttachmentLoadOp::DONT_CARE, + Renderer::Backend::AttachmentLoadOp::CLEAR, Renderer::Backend::AttachmentStoreOp::DONT_CARE)); sceneRenderer.RenderScene(deviceCommandContext);