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:
authorSergey Sharybin <sergey.vfx@gmail.com>2017-04-19 11:26:40 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2017-04-19 16:22:58 +0300
commit288892bf08f380afdfe7f2f8f5b1ca2d2e037fe3 (patch)
treee0cf69efaad904000ee93541b67d94d94d4c0ff3 /source/blender/editors/interface
parentba4d23fe37ee626c92c61bf0f78f64dcc2d95114 (diff)
Make UI block drawing closer to master
There is no need to break assumptions of what's being modified by this call and what's restored. The changes in this function simply spread crappyness outside of the UI block.
Diffstat (limited to 'source/blender/editors/interface')
-rw-r--r--source/blender/editors/interface/interface.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/blender/editors/interface/interface.c b/source/blender/editors/interface/interface.c
index bc7f835390c..365ebfc17c4 100644
--- a/source/blender/editors/interface/interface.c
+++ b/source/blender/editors/interface/interface.c
@@ -1377,6 +1377,9 @@ void UI_block_draw(const bContext *C, uiBlock *block)
ui_but_to_pixelrect(&rect, ar, block, NULL);
/* pixel space for AA widgets */
+ glMatrixMode(GL_PROJECTION);
+ gpuPushProjectionMatrix();
+ glMatrixMode(GL_MODELVIEW);
gpuPushMatrix();
gpuLoadIdentity();
@@ -1402,7 +1405,10 @@ void UI_block_draw(const bContext *C, uiBlock *block)
}
}
- /* restore model-view matrix */
+ /* restore matrix */
+ glMatrixMode(GL_PROJECTION);
+ gpuPopProjectionMatrix();
+ glMatrixMode(GL_MODELVIEW);
gpuPopMatrix();
if (multisample_enabled)