[Bf-blender-cvs] [a346a7dd109] master: GPencil: Don't show only lines in draw mode

Antonio Vazquez noreply at git.blender.org
Fri Feb 19 18:00:37 CET 2021


Commit: a346a7dd109a58ec38bc35f44a4089e5b54f5044
Author: Antonio Vazquez
Date:   Fri Feb 19 18:00:16 2021 +0100
Branches: master
https://developer.blender.org/rBa346a7dd109a58ec38bc35f44a4089e5b54f5044

GPencil: Don't show only lines in draw mode

As now is possible to use multiframe in Draw mode, the option to display only lines must be disabled.

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

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

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

diff --git a/source/blender/draw/engines/gpencil/gpencil_engine.c b/source/blender/draw/engines/gpencil/gpencil_engine.c
index 5eaeeca8bab..8bb336ebc96 100644
--- a/source/blender/draw/engines/gpencil/gpencil_engine.c
+++ b/source/blender/draw/engines/gpencil/gpencil_engine.c
@@ -488,6 +488,7 @@ static void gpencil_stroke_cache_populate(bGPDlayer *gpl,
 {
   gpIterPopulateData *iter = (gpIterPopulateData *)thunk;
 
+  bGPdata *gpd = iter->ob->data;
   MaterialGPencilStyle *gp_style = BKE_gpencil_material_settings(iter->ob, gps->mat_nr + 1);
 
   const bool is_render = iter->pd->is_render;
@@ -496,8 +497,8 @@ static void gpencil_stroke_cache_populate(bGPDlayer *gpl,
                      (!is_render && ((gps->flag & GP_STROKE_NOFILL) != 0));
   bool show_fill = (gps->tot_triangles > 0) && ((gp_style->flag & GP_MATERIAL_FILL_SHOW) != 0) &&
                    (!iter->pd->simplify_fill) && ((gps->flag & GP_STROKE_NOFILL) == 0);
-
-  bool only_lines = gpl && gpf && gpl->actframe != gpf && iter->pd->use_multiedit_lines_only;
+  bool only_lines = !GPENCIL_PAINT_MODE(gpd) && gpl && gpf && gpl->actframe != gpf &&
+                    iter->pd->use_multiedit_lines_only;
   bool is_onion = gpl && gpf && gpf->runtime.onion_id != 0;
   bool hide_onion = is_onion && ((gp_style->flag & GP_MATERIAL_HIDE_ONIONSKIN) != 0);
   if ((hide_material) || (!show_stroke && !show_fill) || (only_lines && !is_onion) ||



More information about the Bf-blender-cvs mailing list