[Bf-blender-cvs] [79ca5ad368f] master: Fix T70484: GPencil particles crash when original stroke is hidden

Antonio Vazquez noreply at git.blender.org
Thu Oct 3 19:03:43 CEST 2019


Commit: 79ca5ad368fb78c29c97d40be4a2c817c900fc58
Author: Antonio Vazquez
Date:   Thu Oct 3 19:03:27 2019 +0200
Branches: master
https://developer.blender.org/rB79ca5ad368fb78c29c97d40be4a2c817c900fc58

Fix T70484: GPencil particles crash when original stroke is hidden

Due the internal design of the drawing engine and the special requirements for 2D inside 3D, it's required to keep the original stroke visible in order to display the particles. If the original stroke is hidden, the particles are hidden too.

This commit only fix the segmentation fault. Make visible the particles when the original is hidden would require a complete redesign and maybe would break some 2D features.

===================================================================

M	source/blender/draw/engines/gpencil/gpencil_cache_utils.c

===================================================================

diff --git a/source/blender/draw/engines/gpencil/gpencil_cache_utils.c b/source/blender/draw/engines/gpencil/gpencil_cache_utils.c
index 33e6d73eeeb..f9df1342bf8 100644
--- a/source/blender/draw/engines/gpencil/gpencil_cache_utils.c
+++ b/source/blender/draw/engines/gpencil/gpencil_cache_utils.c
@@ -50,10 +50,6 @@ static bool gpencil_has_noninstanced_object(Object *ob_instance)
     if (ob->type != OB_GPENCIL) {
       continue;
     }
-    /* object must be visible (invisible objects don't create VBO data) */
-    if (!(DRW_object_visibility_in_active_context(ob) & OB_VISIBLE_SELF)) {
-      continue;
-    }
     /* is not duplicated and the name is equals */
     if ((ob->base_flag & BASE_FROM_DUPLI) == 0) {
       if (STREQ(ob->id.name, ob_instance->id.name)) {



More information about the Bf-blender-cvs mailing list