Fix #124082: GPv3: New frames created in sculpt mode are empty
Allow inserting duplicate keys of visible drawing when using sculpt tools. Added new variable `is_tool_supported` to include cases where duplicating drawings is required. Pull Request: https://projects.blender.org/blender/blender/pulls/124087
This commit is contained in:
parent
969efcad7b
commit
924aa88877
@ -355,8 +355,10 @@ bool ensure_active_keyframe(const Scene &scene,
|
||||
const bool needs_new_drawing = is_first || (current_start_frame < current_frame);
|
||||
if (blender::animrig::is_autokey_on(&scene) && needs_new_drawing) {
|
||||
const Brush *brush = BKE_paint_brush_for_read(&scene.toolsettings->gp_paint->paint);
|
||||
if (((scene.toolsettings->gpencil_flags & GP_TOOL_FLAG_RETAIN_LAST) != 0) ||
|
||||
(brush->gpencil_tool == GPAINT_TOOL_ERASE))
|
||||
const bool is_tool_supported = (brush->gpencil_tool == GPAINT_TOOL_ERASE) ||
|
||||
(brush->sculpt_tool != 0);
|
||||
|
||||
if (((scene.toolsettings->gpencil_flags & GP_TOOL_FLAG_RETAIN_LAST) != 0) || is_tool_supported)
|
||||
{
|
||||
/* For additive drawing, we duplicate the frame that's currently visible and insert it at the
|
||||
* current frame.
|
||||
|
Loading…
Reference in New Issue
Block a user