Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDalai Felinto <dfelinto@gmail.com>2009-04-12 23:46:50 +0400
committerDalai Felinto <dfelinto@gmail.com>2009-04-12 23:46:50 +0400
commit8664e35adf6be85b2c9603171049c5a880ced147 (patch)
tree63ebada2129c6f5b72ccc36b791e7ec0755ebf33 /source/gameengine/Rasterizer
parent5b942b9d5b4e45de872ecceff8ccccfe2c94bbef (diff)
2DFilter bugfixes:
[#18154] 2dFilter and motion blur should run only once to all the scenes [#18504] The GL_PROJECTION matrix is being reset by the 2dfilter.
Diffstat (limited to 'source/gameengine/Rasterizer')
-rw-r--r--source/gameengine/Rasterizer/RAS_2DFilterManager.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp b/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp
index 282c7306285..176da51b183 100644
--- a/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp
+++ b/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp
@@ -435,11 +435,12 @@ void RAS_2DFilterManager::RenderFilters(RAS_ICanvas* canvas)
glViewport(0,0, texturewidth, textureheight);
glDisable(GL_DEPTH_TEST);
+ glPushMatrix(); //GL_MODELVIEW
+ glLoadIdentity(); // GL_MODELVIEW
glMatrixMode(GL_TEXTURE);
glLoadIdentity();
glMatrixMode(GL_PROJECTION);
- glLoadIdentity();
- glMatrixMode(GL_MODELVIEW);
+ glPushMatrix();
glLoadIdentity();
for(passindex =0; passindex<MAX_RENDER_PASS; passindex++)
@@ -466,6 +467,9 @@ void RAS_2DFilterManager::RenderFilters(RAS_ICanvas* canvas)
glEnable(GL_DEPTH_TEST);
glViewport(viewport[0],viewport[1],viewport[2],viewport[3]);
EndShaderProgram();
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
}
void RAS_2DFilterManager::EnableFilter(vector<STR_String>& propNames, void* gameObj, RAS_2DFILTER_MODE mode, int pass, STR_String& text)