[Bf-blender-cvs] [98af74b9366] master: Fix T62297: Grease Pencil dots drawing crashes Blender
Antonioya
noreply at git.blender.org
Fri Mar 15 10:07:23 CET 2019
Commit: 98af74b9366b0e1006333fe9e493f3ea50ac952a
Author: Antonioya
Date: Fri Mar 15 10:07:18 2019 +0100
Branches: master
https://developer.blender.org/rB98af74b9366b0e1006333fe9e493f3ea50ac952a
Fix T62297: Grease Pencil dots drawing crashes Blender
Fix again this bug. Maybe it was introduced when change how wireframe mode by object works.
===================================================================
M source/blender/draw/engines/gpencil/gpencil_draw_utils.c
===================================================================
diff --git a/source/blender/draw/engines/gpencil/gpencil_draw_utils.c b/source/blender/draw/engines/gpencil/gpencil_draw_utils.c
index ce01044a885..a50b4fac15c 100644
--- a/source/blender/draw/engines/gpencil/gpencil_draw_utils.c
+++ b/source/blender/draw/engines/gpencil/gpencil_draw_utils.c
@@ -685,7 +685,7 @@ static DRWShadingGroup *DRW_gpencil_shgroup_point_create(
DRW_shgroup_uniform_float(grp, "pixfactor", &stl->storage->pixfactor, 1);
}
/* viewport x-ray */
- stl->shgroups[id].is_xray = (ob->dt == OB_WIRE) ? 1 : stl->storage->is_xray;
+ stl->shgroups[id].is_xray = ((ob) && (ob->dt == OB_WIRE)) ? 1 : stl->storage->is_xray;
DRW_shgroup_uniform_int(grp, "viewport_xray", (const int *)&stl->shgroups[id].is_xray, 1);
DRW_shgroup_uniform_int(grp, "shading_type", (const int *)&stl->storage->shade_render, 2);
}
More information about the Bf-blender-cvs
mailing list