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:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2010-02-01 18:32:55 +0300
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2010-02-01 18:32:55 +0300
commit81cd4edfb66569f25d518d1fb3526acf7701c773 (patch)
tree57091c1d5d1c1cd8189c932a881ed203eb595d3d /source/blender/editors/transform/transform_manipulator.c
parent90e2b22feeb142d190b7aa2dd1e98fdd48f572bc (diff)
Fix #20891: opengl animation render could mess up the view.
The problem was that wmPushMatrix/wmOrtho/.. and similar functions did not work well for offscreen rendering. It would have been possible to make a fake subwindow for this, but I decided to just remove this extra layer as it does not seem to have much purpose and has been quite confusing when trying to fix other bugs. The relevant matrices are already stored in RegionView3D so there will be no increase in calls to glGetFloat, which may have been a performance reason to use this system in the past.
Diffstat (limited to 'source/blender/editors/transform/transform_manipulator.c')
-rw-r--r--source/blender/editors/transform/transform_manipulator.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/source/blender/editors/transform/transform_manipulator.c b/source/blender/editors/transform/transform_manipulator.c
index 205d6f3479f..a75b64f5e43 100644
--- a/source/blender/editors/transform/transform_manipulator.c
+++ b/source/blender/editors/transform/transform_manipulator.c
@@ -767,7 +767,7 @@ static void preOrthoFront(int ortho, float twmat[][4], int axis)
copy_m4_m4(omat, twmat);
orthogonalize_m4(omat, axis);
glPushMatrix();
- wmMultMatrix(omat);
+ glMultMatrixf(omat);
glFrontFace( is_mat4_flipped(omat)?GL_CW:GL_CCW);
}
}
@@ -864,14 +864,14 @@ static void draw_manipulator_rotate(View3D *v3d, RegionView3D *rv3d, int moving,
copy_m4_m4(matt, rv3d->twmat); // to copy the parts outside of [3][3]
// XXX mul_m4_m3m4(matt, t->mat, rv3d->twmat);
if (ortho) {
- wmMultMatrix(matt);
+ glMultMatrixf(matt);
glFrontFace( is_mat4_flipped(matt)?GL_CW:GL_CCW);
}
}
else {
if (ortho) {
glFrontFace( is_mat4_flipped(rv3d->twmat)?GL_CW:GL_CCW);
- wmMultMatrix(rv3d->twmat);
+ glMultMatrixf(rv3d->twmat);
}
}
@@ -1028,7 +1028,7 @@ static void draw_manipulator_rotate(View3D *v3d, RegionView3D *rv3d, int moving,
}
/* restore */
- wmLoadMatrix(rv3d->viewmat);
+ glLoadMatrixf(rv3d->viewmat);
gluDeleteQuadric(qobj);
if(v3d->zbuf) glEnable(GL_DEPTH_TEST);
@@ -1130,11 +1130,11 @@ static void draw_manipulator_scale(View3D *v3d, RegionView3D *rv3d, int moving,
copy_m4_m4(matt, rv3d->twmat); // to copy the parts outside of [3][3]
// XXX mul_m4_m3m4(matt, t->mat, rv3d->twmat);
- wmMultMatrix(matt);
+ glMultMatrixf(matt);
glFrontFace( is_mat4_flipped(matt)?GL_CW:GL_CCW);
}
else {
- wmMultMatrix(rv3d->twmat);
+ glMultMatrixf(rv3d->twmat);
glFrontFace( is_mat4_flipped(rv3d->twmat)?GL_CW:GL_CCW);
}
@@ -1179,7 +1179,7 @@ static void draw_manipulator_scale(View3D *v3d, RegionView3D *rv3d, int moving,
}
/* restore */
- wmLoadMatrix(rv3d->viewmat);
+ glLoadMatrixf(rv3d->viewmat);
if(v3d->zbuf) glEnable(GL_DEPTH_TEST);
glFrontFace(GL_CCW);
@@ -1240,7 +1240,7 @@ static void draw_manipulator_translate(View3D *v3d, RegionView3D *rv3d, int movi
glPopMatrix();
/* and now apply matrix, we move to local matrix drawing */
- wmMultMatrix(rv3d->twmat);
+ glMultMatrixf(rv3d->twmat);
/* axis */
glLoadName(-1);
@@ -1281,7 +1281,7 @@ static void draw_manipulator_translate(View3D *v3d, RegionView3D *rv3d, int movi
}
gluDeleteQuadric(qobj);
- wmLoadMatrix(rv3d->viewmat);
+ glLoadMatrixf(rv3d->viewmat);
if(v3d->zbuf) glEnable(GL_DEPTH_TEST);
@@ -1336,10 +1336,10 @@ static void draw_manipulator_rotate_cyl(View3D *v3d, RegionView3D *rv3d, int mov
// XXX if (t->flag & T_USES_MANIPULATOR) {
// XXX mul_m4_m3m4(matt, t->mat, rv3d->twmat);
// XXX }
- wmMultMatrix(matt);
+ glMultMatrixf(matt);
}
else {
- wmMultMatrix(rv3d->twmat);
+ glMultMatrixf(rv3d->twmat);
}
glFrontFace( is_mat4_flipped(rv3d->twmat)?GL_CW:GL_CCW);
@@ -1383,7 +1383,7 @@ static void draw_manipulator_rotate_cyl(View3D *v3d, RegionView3D *rv3d, int mov
/* restore */
gluDeleteQuadric(qobj);
- wmLoadMatrix(rv3d->viewmat);
+ glLoadMatrixf(rv3d->viewmat);
if(v3d->zbuf) glEnable(GL_DEPTH_TEST);