diff options
author | Joshua Leung <aligorith@gmail.com> | 2016-03-12 17:49:26 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2016-03-13 08:28:30 +0300 |
commit | 570fbba3f33484111a472a835522d5ec30143a7c (patch) | |
tree | 061c03e275a602490afccefac1ed98a553ba2a9a /source/blender/editors/gpencil | |
parent | b10e3cc9973e415189e9f0cdb6af504c41dd9e41 (diff) |
Keyframing: Added ToolSetting for choosing default keyframe type
To make it easier for animators working in a multipass pose-to-pose workflow
when inserting breakdown keyframes and so forth, it is now possible to specify
the "type" of keyframe being created (i.e. the colour of the keyframe, when drawn
in the Dope Sheet).
Usage:
1) Choose the type of keyframe ("Keyframe", "Breakdown", "Extreme", etc.) from
the new dropdown located between the AutoKeying and KeyingSet widgets on the
timeline header.
2) Insert keyframes
3) Rejoyce that your newly created keyframes have now been coloured for you already
in the DopeSheet.
Todo:
* Look into a way of using the actual keyframe colours (from the theme) for the icons
of these types.
Diffstat (limited to 'source/blender/editors/gpencil')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_convert.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/gpencil/gpencil_convert.c b/source/blender/editors/gpencil/gpencil_convert.c index ab02000a200..c47985ebc1b 100644 --- a/source/blender/editors/gpencil/gpencil_convert.c +++ b/source/blender/editors/gpencil/gpencil_convert.c @@ -398,7 +398,7 @@ static void gp_stroke_path_animation_add_keyframes(ReportList *reports, PointerR if ((cfra - last_valid_time) < MIN_TIME_DELTA) { cfra = last_valid_time + MIN_TIME_DELTA; } - insert_keyframe_direct(reports, ptr, prop, fcu, cfra, INSERTKEY_FAST); + insert_keyframe_direct(reports, ptr, prop, fcu, cfra, BEZT_KEYTYPE_KEYFRAME, INSERTKEY_FAST); last_valid_time = cfra; } else if (G.debug & G_DEBUG) { @@ -410,7 +410,7 @@ static void gp_stroke_path_animation_add_keyframes(ReportList *reports, PointerR if ((cfra - last_valid_time) < MIN_TIME_DELTA) { cfra = last_valid_time + MIN_TIME_DELTA; } - insert_keyframe_direct(reports, ptr, prop, fcu, cfra, INSERTKEY_FAST); + insert_keyframe_direct(reports, ptr, prop, fcu, cfra, BEZT_KEYTYPE_KEYFRAME, INSERTKEY_FAST); last_valid_time = cfra; } else { @@ -418,7 +418,7 @@ static void gp_stroke_path_animation_add_keyframes(ReportList *reports, PointerR * and also far enough from (not yet added!) end_stroke keyframe! */ if ((cfra - last_valid_time) > MIN_TIME_DELTA && (end_stroke_time - cfra) > MIN_TIME_DELTA) { - insert_keyframe_direct(reports, ptr, prop, fcu, cfra, INSERTKEY_FAST); + insert_keyframe_direct(reports, ptr, prop, fcu, cfra, BEZT_KEYTYPE_BREAKDOWN, INSERTKEY_FAST); last_valid_time = cfra; } else if (G.debug & G_DEBUG) { @@ -472,7 +472,7 @@ static void gp_stroke_path_animation(bContext *C, ReportList *reports, Curve *cu cu->ctime = 0.0f; cfra = (float)gtd->start_frame; - insert_keyframe_direct(reports, ptr, prop, fcu, cfra, INSERTKEY_FAST); + insert_keyframe_direct(reports, ptr, prop, fcu, cfra, BEZT_KEYTYPE_KEYFRAME, INSERTKEY_FAST); cu->ctime = cu->pathlen; if (gtd->realtime) { @@ -481,7 +481,7 @@ static void gp_stroke_path_animation(bContext *C, ReportList *reports, Curve *cu else { cfra = (float)gtd->end_frame; } - insert_keyframe_direct(reports, ptr, prop, fcu, cfra, INSERTKEY_FAST); + insert_keyframe_direct(reports, ptr, prop, fcu, cfra, BEZT_KEYTYPE_KEYFRAME, INSERTKEY_FAST); } else { /* Use actual recorded timing! */ |