[Bf-blender-cvs] [7e5fe132053] greasepencil-object: Enable Onion Skinning in Edit and Sculpt mode
Antonio Vazquez
noreply at git.blender.org
Wed Aug 30 17:04:08 CEST 2017
Commit: 7e5fe1320537bf33c822773d6fe0b84a04e91f8c
Author: Antonio Vazquez
Date: Wed Aug 30 17:03:48 2017 +0200
Branches: greasepencil-object
https://developer.blender.org/rB7e5fe1320537bf33c822773d6fe0b84a04e91f8c
Enable Onion Skinning in Edit and Sculpt mode
Only disabled in weight paint mode
===================================================================
M source/blender/draw/engines/gpencil/gpencil_draw_cache_impl.c
===================================================================
diff --git a/source/blender/draw/engines/gpencil/gpencil_draw_cache_impl.c b/source/blender/draw/engines/gpencil/gpencil_draw_cache_impl.c
index 507548a7d13..e0d5b56c2c1 100644
--- a/source/blender/draw/engines/gpencil/gpencil_draw_cache_impl.c
+++ b/source/blender/draw/engines/gpencil/gpencil_draw_cache_impl.c
@@ -973,6 +973,7 @@ void DRW_gpencil_populate_datablock(GPENCIL_e_data *e_data, void *vedata, Scene
GPENCIL_StorageList *stl = ((GPENCIL_Data *)vedata)->stl;
bGPDframe *derived_gpf = NULL;
bool is_edit = (bool)(gpd->flag & (GP_DATA_STROKE_EDITMODE | GP_DATA_STROKE_SCULPTMODE | GP_DATA_STROKE_WEIGHTMODE));
+ bool no_onion = (bool)(gpd->flag & GP_DATA_STROKE_WEIGHTMODE);
if (G.debug_value == 668) {
printf("DRW_gpencil_populate_datablock: %s\n", gpd->id.name);
@@ -1017,7 +1018,7 @@ void DRW_gpencil_populate_datablock(GPENCIL_e_data *e_data, void *vedata, Scene
BLI_ghash_insert(gpl->derived_data, ob->id.name, derived_gpf);
}
/* draw onion skins */
- if ((!is_edit) && (gpl->flag & GP_LAYER_ONIONSKIN) &&
+ if ((!no_onion) && (gpl->flag & GP_LAYER_ONIONSKIN) &&
((!playing) || (gpl->flag & GP_LAYER_GHOST_ALWAYS)))
{
gpencil_draw_onionskins(cache, e_data, vedata, ts, ob, gpd, gpl, gpf);
More information about the Bf-blender-cvs
mailing list