[Bf-blender-cvs] [41c45aef969] greasepencil-refactor: GPencil: Refactor: Fix multiedit having less predecence than onion skin
Clément Foucault
noreply at git.blender.org
Tue Jan 7 15:31:46 CET 2020
Commit: 41c45aef969c32169495f5190ac5895c9bb83775
Author: Clément Foucault
Date: Tue Jan 7 12:49:33 2020 +0100
Branches: greasepencil-refactor
https://developer.blender.org/rB41c45aef969c32169495f5190ac5895c9bb83775
GPencil: Refactor: Fix multiedit having less predecence than onion skin
===================================================================
M source/blender/blenkernel/intern/gpencil.c
===================================================================
diff --git a/source/blender/blenkernel/intern/gpencil.c b/source/blender/blenkernel/intern/gpencil.c
index 823f75de3f3..96c62802b50 100644
--- a/source/blender/blenkernel/intern/gpencil.c
+++ b/source/blender/blenkernel/intern/gpencil.c
@@ -3722,7 +3722,23 @@ void BKE_gpencil_visible_stroke_iter(
continue;
}
- if (is_onion && (gpl->onion_flag & GP_LAYER_ONIONSKIN)) {
+ if (is_multiedit) {
+ sta_gpf = end_gpf = NULL;
+ /* Check the whole range and tag the editable frames. */
+ LISTBASE_FOREACH (bGPDframe *, gpf, &gpl->frames) {
+ if (gpf == act_gpf || (gpf->flag & GP_FRAME_SELECT)) {
+ gpf->runtime.onion_id = 0;
+ if (sta_gpf == NULL) {
+ sta_gpf = gpf;
+ }
+ end_gpf = gpf->next;
+ }
+ else {
+ gpf->runtime.onion_id = INT_MAX;
+ }
+ }
+ }
+ else if (is_onion && (gpl->onion_flag & GP_LAYER_ONIONSKIN)) {
if (act_gpf) {
bGPDframe *last_gpf = gpl->frames.last;
@@ -3762,22 +3778,6 @@ void BKE_gpencil_visible_stroke_iter(
sta_gpf = gpl->frames.first;
end_gpf = NULL;
}
- else if (is_multiedit) {
- sta_gpf = end_gpf = NULL;
- /* Check the whole range and tag the editable frames. */
- LISTBASE_FOREACH (bGPDframe *, gpf, &gpl->frames) {
- if (gpf == act_gpf || (gpf->flag & GP_FRAME_SELECT)) {
- gpf->runtime.onion_id = 0;
- if (sta_gpf == NULL) {
- sta_gpf = gpf;
- }
- end_gpf = gpf->next;
- }
- else {
- gpf->runtime.onion_id = INT_MAX;
- }
- }
- }
else {
/* Bypass multiedit/onion skinning. */
end_gpf = sta_gpf = NULL;
More information about the Bf-blender-cvs
mailing list