diff --git a/neo/renderer/NVRHI/RenderBackend_NVRHI.cpp b/neo/renderer/NVRHI/RenderBackend_NVRHI.cpp index baf70f90..7718b08e 100644 --- a/neo/renderer/NVRHI/RenderBackend_NVRHI.cpp +++ b/neo/renderer/NVRHI/RenderBackend_NVRHI.cpp @@ -1597,11 +1597,11 @@ void idRenderBackend::GL_EndFrame() commandList->close(); - deviceManager->GetDevice()->executeCommandList( commandList ); - // required for Vulkan: transition our swap image to present deviceManager->EndFrame(); + deviceManager->GetDevice()->executeCommandList( commandList ); + // update jitter for perspective matrix taaPass->AdvanceFrame(); } diff --git a/neo/renderer/RenderBackend.cpp b/neo/renderer/RenderBackend.cpp index 60951145..94bccaef 100644 --- a/neo/renderer/RenderBackend.cpp +++ b/neo/renderer/RenderBackend.cpp @@ -5382,12 +5382,12 @@ void idRenderBackend::ExecuteBackEndCommands( const emptyCommand_t* cmds ) DrawFlickerBox(); - GL_EndFrame(); - // stop rendering on this thread uint64 backEndFinishTime = Sys_Microseconds(); pc.cpuTotalMicroSec = backEndFinishTime - backEndStartTime; + GL_EndFrame(); + if( r_debugRenderToTexture.GetInteger() == 1 ) { common->Printf( "3d: %i, 2d: %i, SetBuf: %i, CpyRenders: %i, CpyFrameBuf: %i\n", c_draw3d, c_draw2d, c_setBuffers, c_copyRenders, pc.c_copyFrameBuffer ); diff --git a/neo/sys/DeviceManager_VK.cpp b/neo/sys/DeviceManager_VK.cpp index 98135277..77f420a5 100644 --- a/neo/sys/DeviceManager_VK.cpp +++ b/neo/sys/DeviceManager_VK.cpp @@ -272,7 +272,7 @@ private: nvrhi::vulkan::DeviceHandle m_NvrhiDevice; nvrhi::DeviceHandle m_ValidationLayer; - nvrhi::CommandListHandle m_BarrierCommandList; + //nvrhi::CommandListHandle m_BarrierCommandList; // SRS - no longer needed std::queue m_PresentSemaphoreQueue; vk::Semaphore m_PresentSemaphore; @@ -1220,7 +1220,7 @@ bool DeviceManager_VK::CreateDeviceAndSwapChain() CHECK( createSwapChain() ); - m_BarrierCommandList = m_NvrhiDevice->createCommandList(); + //m_BarrierCommandList = m_NvrhiDevice->createCommandList(); // SRS - no longer needed // SRS - Give each swapchain image its own semaphore in case of overlap (e.g. MoltenVK async queue submit) for( int i = 0; i < m_SwapChainImages.size(); i++ ) @@ -1257,7 +1257,7 @@ void DeviceManager_VK::DestroyDeviceAndSwapChain() } m_PresentSemaphore = vk::Semaphore(); - m_BarrierCommandList = nullptr; + //m_BarrierCommandList = nullptr; // SRS - no longer needed destroySwapChain(); @@ -1320,9 +1320,10 @@ void DeviceManager_VK::EndFrame() { m_NvrhiDevice->queueSignalSemaphore( nvrhi::CommandQueue::Graphics, m_PresentSemaphore, 0 ); - m_BarrierCommandList->open(); // umm... - m_BarrierCommandList->close(); - m_NvrhiDevice->executeCommandList( m_BarrierCommandList ); + // SRS - Don't need barrier commandlist if EndFrame() is called before executeCommandList() in idRenderBackend::GL_EndFrame() + //m_BarrierCommandList->open(); // umm... + //m_BarrierCommandList->close(); + //m_NvrhiDevice->executeCommandList( m_BarrierCommandList ); } void DeviceManager_VK::Present()