- fixed SSAO shader texture assignments.

This commit is contained in:
Christoph Oelckers 2018-06-13 19:04:19 +02:00
parent ce50b0e46b
commit 0b9eaac5e1

View file

@ -129,8 +129,8 @@ void FGLRenderer::AmbientOccludeScene()
// Apply ambient occlusion
mBuffers->AmbientFB1.Bind();
mBuffers->LinearDepthTexture.Bind(0);
mBuffers->AmbientRandomTexture[randomTexture].Bind(1, GL_NEAREST, GL_REPEAT);
mBuffers->BindSceneNormalTexture(2);
mBuffers->AmbientRandomTexture[randomTexture].Bind(2, GL_NEAREST, GL_REPEAT);
mBuffers->BindSceneNormalTexture(1);
mSSAOShader->Bind();
if (gl_multisample > 1) mSSAOShader->Uniforms->SampleIndex = 0;
mSSAOShader->Uniforms->UVToViewA = { 2.0f * invFocalLenX, 2.0f * invFocalLenY };