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:
authorJeroen Bakker <j.bakker@atmind.nl>2019-06-14 11:49:05 +0300
committerJeroen Bakker <j.bakker@atmind.nl>2019-06-14 11:49:05 +0300
commit31a99a3ab45a72476df781288f1c81763df57c62 (patch)
tree58bbaff351b9eb0dc6977828673c7886628a1706
parent3bfd81ce29472d8217eca1c7c107da16e751baea (diff)
Fix T65763: Reset GPU when exporting annotations
When exporting annotations using `bpy.ops.render.opengl` the annotations where only correct in the first frame. In the second frame the annotations was shifted by half the resolution. This change will reset the GPU matrices when the annotations are rendered.
-rw-r--r--source/blender/editors/render/render_opengl.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/editors/render/render_opengl.c b/source/blender/editors/render/render_opengl.c
index 110dc7aaaf1..72e6c6fdf03 100644
--- a/source/blender/editors/render/render_opengl.c
+++ b/source/blender/editors/render/render_opengl.c
@@ -331,6 +331,7 @@ static void screen_opengl_render_doit(const bContext *C, OGLRender *oglrender, R
GPU_clear_color(0.0f, 0.0f, 0.0f, 0.0f);
GPU_clear(GPU_COLOR_BIT | GPU_DEPTH_BIT);
+ GPU_matrix_reset();
wmOrtho2(0, scene->r.xsch, 0, scene->r.ysch);
GPU_matrix_translate_2f(scene->r.xsch / 2, scene->r.ysch / 2);