This commit is contained in:
Anselme 2017-08-15 17:55:28 +02:00
parent b62ca7963d
commit 4c60315805

View File

@ -152,12 +152,13 @@ void DeferredPipeline::renderGL(Scene *scene)
// LIGHTING PASS
m_lightingBuffer->bindFBO();
if(m_skybox != nullptr)
m_skybox->renderGL(m_camera);
glDepthFunc(GL_LEQUAL);
glEnable(GL_BLEND);
glBlendFunc(GL_ONE, GL_ONE);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
if(m_skybox != nullptr)
m_skybox->renderGL(m_camera);
m_gBuffer->bindTextures();
for(SceneIterator<Light*>* lightIt = scene->getLights();
lightIt->isValid(); lightIt->next())