diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2020-10-05 17:02:32 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2020-10-05 17:02:32 +0300 |
commit | 7f3fe5b45c1826e46ffc4f6e96d3fafb8e01af3d (patch) | |
tree | 187ba8229e4342f6294eeab95325492eecb54adf /source | |
parent | 54f248fa87afd4836fb7154056cd0e8d920401f1 (diff) |
GPencil: Fix unreported Layer SOLO mode broken
During the refactor, this feature was removed by error.
When this option is enabled, only the frames with a keyframe are displayed in Draw mode. This is used when fill an animation to paint only in the frames with real drawing.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/gpencil.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/gpencil.c b/source/blender/blenkernel/intern/gpencil.c index 7bc3daf037f..980d608df77 100644 --- a/source/blender/blenkernel/intern/gpencil.c +++ b/source/blender/blenkernel/intern/gpencil.c @@ -2563,6 +2563,12 @@ void BKE_gpencil_visible_stroke_iter(ViewLayer *view_layer, /* Use evaluated frame (with modifiers for active stroke)/ */ act_gpf = gpl->actframe; if (act_gpf) { + /* If layer solo mode and Paint mode, only keyframes with data are displayed. */ + if (GPENCIL_PAINT_MODE(gpd) && (gpl->flag & GP_LAYER_SOLO_MODE) && + (act_gpf->framenum != cfra)) { + continue; + } + act_gpf->runtime.onion_id = 0; if (layer_cb) { layer_cb(gpl, act_gpf, NULL, thunk); |