diff options
| author | Lioncash <mathew1800@gmail.com> | 2014-08-17 15:17:04 -0400 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2014-08-17 15:17:04 -0400 |
| commit | 15a3b30e27121ad89805b2e3ac8920d3a5e92960 (patch) | |
| tree | 1758da2240fd1f73bb5801f6f95e2b3a5c4a4bf4 /Source/Core/VideoBackends/OGL/PostProcessing.cpp | |
| parent | e3e1869493d95ea88c68941642c785553b833fa1 (diff) | |
| parent | 7e3d1050f0f25f659dded00a9df787195b47e7b5 (diff) | |
Merge pull request #790 from lioncash/ogl-cleanup
Small OGL cleanup
Diffstat (limited to 'Source/Core/VideoBackends/OGL/PostProcessing.cpp')
| -rw-r--r-- | Source/Core/VideoBackends/OGL/PostProcessing.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/Source/Core/VideoBackends/OGL/PostProcessing.cpp b/Source/Core/VideoBackends/OGL/PostProcessing.cpp index dee133ed03..15c89a9443 100644 --- a/Source/Core/VideoBackends/OGL/PostProcessing.cpp +++ b/Source/Core/VideoBackends/OGL/PostProcessing.cpp @@ -164,24 +164,28 @@ void OpenGLPostProcessing::Update(u32 width, u32 height) void OpenGLPostProcessing::ApplyShader() { // shader didn't changed - if (m_config.GetShader() == g_ActiveConfig.sPostProcessingShader) return; + if (m_config.GetShader() == g_ActiveConfig.sPostProcessingShader) + return; m_enable = false; m_shader.Destroy(); m_uniform_bindings.clear(); // shader disabled - if (g_ActiveConfig.sPostProcessingShader == "") return; + if (g_ActiveConfig.sPostProcessingShader == "") + return; // so need to compile shader std::string code = m_config.LoadShader(); - if (code == "") return; + if (code == "") + return; code = LoadShaderOptions(code); // and compile it - if (!ProgramShaderCache::CompileShader(m_shader, s_vertex_shader, code.c_str())) { + if (!ProgramShaderCache::CompileShader(m_shader, s_vertex_shader, code.c_str())) + { ERROR_LOG(VIDEO, "Failed to compile post-processing shader %s", m_config.GetShader().c_str()); return; } |
