diff options
author | Philipp Oeser <info@graphics-engineer.com> | 2020-08-05 12:58:29 +0300 |
---|---|---|
committer | Philipp Oeser <info@graphics-engineer.com> | 2020-08-05 15:09:00 +0300 |
commit | 229fe01a152124308ad8552e6b792b9ebdaeec5a (patch) | |
tree | e165efa211e4d30a06a913697bfaa5958c251a47 | |
parent | f9aba4f6e190b9411ab3cd68e9c6d90cc68eb5c7 (diff) |
PyDoc: use glClearColor before glClear in gpu docs
ref T79491
Maniphest Tasks: T79491
Differential Revision: https://developer.blender.org/D8471
-rw-r--r-- | doc/python_api/examples/gpu.7.py | 1 | ||||
-rw-r--r-- | doc/python_api/examples/gpu.8.py | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/doc/python_api/examples/gpu.7.py b/doc/python_api/examples/gpu.7.py index 56cbb93c61a..d6055898807 100644 --- a/doc/python_api/examples/gpu.7.py +++ b/doc/python_api/examples/gpu.7.py @@ -20,6 +20,7 @@ from gpu_extras.presets import draw_circle_2d offscreen = gpu.types.GPUOffScreen(512, 512) with offscreen.bind(): + bgl.glClearColor(0.0, 0.0, 0.0, 0.0) bgl.glClear(bgl.GL_COLOR_BUFFER_BIT) with gpu.matrix.push_pop(): # reset matrices -> use normalized device coordinates [-1, 1] diff --git a/doc/python_api/examples/gpu.8.py b/doc/python_api/examples/gpu.8.py index 470bd8a2dad..e67c601def9 100644 --- a/doc/python_api/examples/gpu.8.py +++ b/doc/python_api/examples/gpu.8.py @@ -25,6 +25,7 @@ RING_AMOUNT = 10 offscreen = gpu.types.GPUOffScreen(WIDTH, HEIGHT) with offscreen.bind(): + bgl.glClearColor(0.0, 0.0, 0.0, 0.0) bgl.glClear(bgl.GL_COLOR_BUFFER_BIT) with gpu.matrix.push_pop(): # reset matrices -> use normalized device coordinates [-1, 1] |