diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2017-04-14 15:13:38 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2017-04-14 19:07:16 +0300 |
commit | cb2c4bfb74ca7f385bbd8d7c3445a49a2d1b7b8d (patch) | |
tree | 516eb56f5d9247784a94f6d02d91ad247040f6a5 /source/blender/editors/space_view3d/view3d_draw.c | |
parent | e7c4eddace27272ba4d14f7e2fd0a39256e3c656 (diff) |
GPU Matrix API refactor: Stick to a single 4x4 stack for 2D and 3D
* Brings us closer to core profile, all matrices are working, and apart
from a problem with text drawing, Blender is working fine.
* Reduce the coding overhead of having to setup/teardown when
alternating between 2D and 3D drawing sessions.
* Gives us fewer modes and states we need to keep track of.
Unfortunatelly this also "rejects a fundamental change" the original
design was trying to make - that 2D is different from 3D and
deserves its own best implementation.
That said, it is still aligned with the function API design as
originally implemented (i.e., it still uses gpuTranslate2D, ...).
Finally, if you build with core profile and this patch you get:
https://developer.blender.org/F545352
[The text glitch is an unrelated issue].
Reviewers: merwin, sergey, brecht
Differential Revision: https://developer.blender.org/D2626
Diffstat (limited to 'source/blender/editors/space_view3d/view3d_draw.c')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_draw.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/source/blender/editors/space_view3d/view3d_draw.c b/source/blender/editors/space_view3d/view3d_draw.c index 0d5e6440355..c9f70945866 100644 --- a/source/blender/editors/space_view3d/view3d_draw.c +++ b/source/blender/editors/space_view3d/view3d_draw.c @@ -2294,8 +2294,6 @@ static void view3d_draw_view(const bContext *C, ARegion *ar, DrawData *draw_data glClear(GL_DEPTH_BUFFER_BIT); // glDisable(GL_DEPTH_TEST); /* should be set by default */ - gpuMatrixBegin3D(); - view3d_draw_background(C); /* clears/overwrites entire color buffer */ view3d_draw_setup_view(C, ar); @@ -2318,8 +2316,6 @@ static void view3d_draw_view(const bContext *C, ARegion *ar, DrawData *draw_data view3d_draw_reference_images(C); view3d_draw_manipulators(C, ar); - gpuMatrixEnd(); - glDisable(GL_DEPTH_TEST); view3d_draw_region_info(C, ar); |