diff options
author | bunnei <bunneidev@gmail.com> | 2015-11-15 23:43:01 +0100 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2016-02-05 23:17:31 +0100 |
commit | 021cb0bced1d8045f04b85024b97a07a4d0df12f (patch) | |
tree | af2e041a2625ebde8c5f734f2e0ab911aba11625 /src/video_core/renderer_opengl/gl_state.cpp | |
parent | renderer_opengl: Initial implementation of basic specular lighting. (diff) | |
download | yuzu-021cb0bced1d8045f04b85024b97a07a4d0df12f.tar yuzu-021cb0bced1d8045f04b85024b97a07a4d0df12f.tar.gz yuzu-021cb0bced1d8045f04b85024b97a07a4d0df12f.tar.bz2 yuzu-021cb0bced1d8045f04b85024b97a07a4d0df12f.tar.lz yuzu-021cb0bced1d8045f04b85024b97a07a4d0df12f.tar.xz yuzu-021cb0bced1d8045f04b85024b97a07a4d0df12f.tar.zst yuzu-021cb0bced1d8045f04b85024b97a07a4d0df12f.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/renderer_opengl/gl_state.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_state.cpp b/src/video_core/renderer_opengl/gl_state.cpp index a82372995..ab4b6c7b1 100644 --- a/src/video_core/renderer_opengl/gl_state.cpp +++ b/src/video_core/renderer_opengl/gl_state.cpp @@ -170,6 +170,14 @@ void OpenGLState::Apply() { } } + // Lighting LUTs + for (unsigned i = 0; i < ARRAY_SIZE(lighting_lut); ++i) { + if (lighting_lut[i].texture_1d != cur_state.lighting_lut[i].texture_1d) { + glActiveTexture(GL_TEXTURE3 + i); + glBindTexture(GL_TEXTURE_1D, lighting_lut[i].texture_1d); + } + } + // Framebuffer if (draw.framebuffer != cur_state.draw.framebuffer) { glBindFramebuffer(GL_FRAMEBUFFER, draw.framebuffer); |