diff options
author | Alexander Gavrilov <angavrilov@gmail.com> | 2019-05-11 21:16:46 +0300 |
---|---|---|
committer | Alexander Gavrilov <angavrilov@gmail.com> | 2019-05-11 21:20:21 +0300 |
commit | ebc44aae9897607a7d19a642d1a2fdffa2b24400 (patch) | |
tree | 43191d4c9a91688403d63e79c76b61c509c060b0 /source/blender/python/intern/bpy_rna_anim.c | |
parent | 83d35c25d0fcc9b095ef1a0e1c5c290bb04d3017 (diff) |
Python API: expose more keyframing flags for use in keyframe_insert.
Expose REPLACE and CYCLE_AWARE, and add AVAILABLE for completeness.
These flags are generic and safe to use, and necessary to match
the behavior of certain UI options.
Diffstat (limited to 'source/blender/python/intern/bpy_rna_anim.c')
-rw-r--r-- | source/blender/python/intern/bpy_rna_anim.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/source/blender/python/intern/bpy_rna_anim.c b/source/blender/python/intern/bpy_rna_anim.c index 79c31c8caad..710ae0433e0 100644 --- a/source/blender/python/intern/bpy_rna_anim.c +++ b/source/blender/python/intern/bpy_rna_anim.c @@ -263,8 +263,9 @@ static int pyrna_struct_keyframe_parse(PointerRNA *ptr, /* flag may be null (no option currently for remove keyframes e.g.). */ if (r_options) { - if (pyoptions && (pyrna_set_to_enum_bitfield( - rna_enum_keying_flag_items, pyoptions, r_options, error_prefix) == -1)) { + if (pyoptions && + (pyrna_set_to_enum_bitfield( + rna_enum_keying_flag_items_api, pyoptions, r_options, error_prefix) == -1)) { return -1; } @@ -299,8 +300,11 @@ char pyrna_struct_keyframe_insert_doc[] = "F-Curves.\n" " - ``INSERTKEY_VISUAL`` Insert keyframes based on 'visual transforms'.\n" " - ``INSERTKEY_XYZ_TO_RGB`` Color for newly added transformation F-Curves (Location, " - "Rotation, Scale)\n" - " and also Color is based on the transform axis.\n" + "Rotation, Scale) is based on the transform axis.\n" + " - ``INSERTKEY_REPLACE`` Only replace already exising keyframes.\n" + " - ``INSERTKEY_AVAILABLE`` Only insert into already existing F-Curves.\n" + " - ``INSERTKEY_CYCLE_AWARE`` Take cyclic extrapolation into account " + "(Cycle-Aware Keying option).\n" " :type flag: set\n" " :return: Success of keyframe insertion.\n" " :rtype: boolean\n"; |