From b738b1eab3c6f002f4125db5aa437d1e2ac49760 Mon Sep 17 00:00:00 2001 From: Vincent Lejeune Date: Thu, 23 Jan 2014 20:17:17 +0100 Subject: [PATCH] Revert fog move after transparent pass. --- src/graphics/render.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/graphics/render.cpp b/src/graphics/render.cpp index 3b722abcb..ed0663658 100644 --- a/src/graphics/render.cpp +++ b/src/graphics/render.cpp @@ -231,6 +231,13 @@ void IrrDriver::renderGLSL(float dt) PROFILER_POP_CPU_MARKER(); + if (World::getWorld()->getTrack()->isFogEnabled()) + { + PROFILER_PUSH_CPU_MARKER("- Fog", 0xFF, 0x00, 0x00); + m_post_processing->renderFog(camnode->getAbsolutePosition(), irr_driver->getInvProjViewMatrix()); + PROFILER_POP_CPU_MARKER(); + } + PROFILER_PUSH_CPU_MARKER("- Glow", 0xFF, 0xFF, 0x00); // Render anything glowing. @@ -295,13 +302,6 @@ void IrrDriver::renderGLSL(float dt) m_scene_manager->drawAll(m_renderpass); PROFILER_POP_CPU_MARKER(); - if (World::getWorld()->getTrack()->isFogEnabled()) - { - PROFILER_PUSH_CPU_MARKER("- Fog", 0xFF, 0x00, 0x00); - m_post_processing->renderFog(camnode->getAbsolutePosition(), irr_driver->getInvProjViewMatrix()); - PROFILER_POP_CPU_MARKER(); - } - PROFILER_PUSH_CPU_MARKER("- Displacement", 0x00, 0x00, 0xFF); // Handle displacing nodes, if any const u32 displacingcount = m_displacing.size();