Python: GPU Offscreen Rendering
authorJeroen Bakker <j.bakker@atmind.nl>
Thu, 6 Jun 2019 06:37:43 +0000 (08:37 +0200)
committerJeroen Bakker <j.bakker@atmind.nl>
Thu, 6 Jun 2019 06:38:05 +0000 (08:38 +0200)
When using python offscreen rendering the background was not drawn in
EEVEE. Users would expect that when calling the `draw_view3d` method
that it shows the same as in the 3d viewport.

Seems to be a difference between the meaning of draw_background in b279
and b280. In B279 the world background would be drawn. In B280 the
transparency is changed.

Reviewed By: campbellbarton, fclem

Maniphest Tasks: T61768

Differential Revision: https://developer.blender.org/D5022

source/blender/python/gpu/gpu_py_offscreen.c

index 561aff4..b5f4d26 100644 (file)
@@ -253,7 +253,7 @@ static PyObject *bpygpu_offscreen_draw_view3d(BPyGPUOffScreen *self,
                            GPU_offscreen_height(self->ofs),
                            (float(*)[4])py_mat_view->matrix,
                            (float(*)[4])py_mat_projection->matrix,
-                           false,
+                           true,
                            true,
                            "",
                            true,