|
Blender V5.3
|
Namespaces | |
| namespace | greasepencil |
| namespace | tests |
Classes | |
| struct | KeyframeCopyBuffer |
Typedefs | |
| using | pastebuf_match_func |
Functions | |
| std::optional< std::string > | flip_names (const StringRefNull rna_path) |
| static SlotMatchMethod | get_slot_match_method (const bool from_single, const bool to_single, const KeyframePasteContext &paste_context) |
| static const FCurve * | pastebuf_find_matching_copybuf_item (const pastebuf_match_func strategy, Main *bmain, const bAnimListElem &ale_to_paste_into, const bool from_single, const bool to_single, const KeyframePasteContext &paste_context) |
| bool | pastebuf_match_path_full (Main *, const FCurve &fcurve_to_match, const FCurve &fcurve_in_copy_buffer, animrig::slot_handle_t, const bool from_single, const bool to_single, const bool flip) |
| bool | pastebuf_match_path_property_and_component_length (Main *bmain, const FCurve &fcurve_to_match, const FCurve &fcurve_in_copy_buffer, const animrig::slot_handle_t slot_handle_in_copy_buffer, const bool from_single, const bool to_single, const bool flip) |
| bool | pastebuf_match_path_property (Main *, const FCurve &fcurve_to_match, const FCurve &fcurve_in_copy_buffer, animrig::slot_handle_t, const bool from_single, const bool, const bool) |
| bool | pastebuf_match_index_only (Main *, const FCurve &fcurve_to_match, const FCurve &fcurve_in_copy_buffer, animrig::slot_handle_t, const bool from_single, const bool, const bool) |
| static void | do_curve_mirror_flippping (const FCurve &fcurve, BezTriple &bezt) |
| static void | paste_animedit_keys_fcurve (FCurve *fcu, const FCurve &fcurve_in_copy_buffer, float offset[2], const eKeyMergeMode merge_mode, bool flip) |
Variables | |
| KeyframeCopyBuffer * | keyframe_copy_buffer = nullptr |
Definition at line 1595 of file keyframes_general.cc.
|
static |
Definition at line 1912 of file keyframes_general.cc.
References blender::FCurve::array_index, blender::BLI_strn_endswith(), do_curve_mirror_flippping(), ELEM, blender::ed::animation::KeyframeCopyBuffer::is_bone(), keyframe_copy_buffer, and blender::BezTriple::vec.
Referenced by do_curve_mirror_flippping(), and paste_animedit_keys_fcurve().
| std::optional< std::string > blender::ed::animation::flip_names | ( | StringRefNull | rna_path | ) |
Flip bone names in the RNA path, returning the flipped path.
Returns empty optional if the rna_path is not animating a bone, i.e. doesn't have the pose.bones[" prefix.
Definition at line 1576 of file keyframes_general.cc.
References blender::BLI_str_quoted_substr_range(), blender::BLI_string_flip_side_name(), flip_names(), and MAX_VGROUP_NAME.
Referenced by flip_names(), pastebuf_match_path_full(), and blender::ed::animation::tests::TEST_F().
|
static |
Determine whether slot names matter when matching copied data to selected-to-paste-into channels.
Definition at line 1624 of file keyframes_general.cc.
References BLI_assert_msg, get_slot_match_method(), keyframe_copy_buffer, blender::KeyframePasteContext::num_fcurves_selected, blender::ed::animation::KeyframeCopyBuffer::num_slots(), blender::KeyframePasteContext::num_slots_selected, and UNUSED_VARS_NDEBUG.
Referenced by get_slot_match_method(), and pastebuf_find_matching_copybuf_item().
|
static |
Definition at line 1951 of file keyframes_general.cc.
References blender::add_v2_v2(), blender::FCurve::bezt, BEZT_DESEL_ALL, blender::BEZT_FLAG_SELECT, BEZT_SEL_ALL, blender::BKE_fcurve_delete_keys_all(), blender::BKE_fcurve_delete_keys_selected(), blender::BKE_fcurve_handles_recalc(), do_curve_mirror_flippping(), blender::BezTriple::f2, blender::ed::animation::KeyframeCopyBuffer::first_frame, blender::animrig::insert_bezt_fcurve(), blender::INSERTKEY_OVERWRITE_FULL, keyframe_copy_buffer, blender::KEYFRAME_PASTE_MERGE_MIX, blender::KEYFRAME_PASTE_MERGE_OVER, blender::KEYFRAME_PASTE_MERGE_OVER_RANGE, blender::KEYFRAME_PASTE_MERGE_OVER_RANGE_ALL, blender::ed::animation::KeyframeCopyBuffer::last_frame, paste_animedit_keys_fcurve(), blender::FCurve::totvert, and blender::BezTriple::vec.
Referenced by blender::paste_animedit_keys(), and paste_animedit_keys_fcurve().
|
static |
Return the first item in the copy buffer that matches the given bAnimListElem.
| ale_to_paste_into | must be an ALE that represents an F-Curve. The entire ALE is passed (instead of just the F-Curve) as it provides information about the Action & Slot it came from. |
Definition at line 1690 of file keyframes_general.cc.
References blender::ALE_FCURVE, ATTR_FALLTHROUGH, blender::BLI_assert(), BLI_assert_msg, blender::ed::animation::KeyframeCopyBuffer::channelbag_for_slot(), blender::animrig::StripKeyframeData::channelbags(), blender::bAnimListElem::data, blender::bAnimListElem::datatype, blender::bAnimListElem::fcurve_owner_id, blender::animrig::Channelbag::fcurves(), blender::KeyframePasteContext::flip, get_slot_match_method(), blender::ID_AC, blender::ActionSlot::identifier, blender::animrig::Slot::is_selected(), keyframe_copy_buffer, blender::ed::animation::KeyframeCopyBuffer::keyframe_data, pastebuf_find_matching_copybuf_item(), blender::animrig::Action::slot_for_handle(), blender::ActionChannelbag::slot_handle, blender::bAnimListElem::slot_handle, blender::ed::animation::KeyframeCopyBuffer::SLOTLESS_SLOT_IDENTIFIER, Span< T >::Span(), and blender::gpu::wrap().
Referenced by blender::paste_animedit_keys(), and pastebuf_find_matching_copybuf_item().
| bool blender::ed::animation::pastebuf_match_index_only | ( | Main * | bmain, |
| const FCurve & | fcurve_to_match, | ||
| const FCurve & | fcurve_in_copy_buffer, | ||
| blender::animrig::slot_handle_t | slot_handle_in_copy_buffer, | ||
| bool | from_single, | ||
| bool | to_single, | ||
| bool | flip ) |
Least strict paste buffer matching method: array indices only.
Definition at line 1899 of file keyframes_general.cc.
References blender::FCurve::array_index, and pastebuf_match_index_only().
Referenced by blender::paste_animedit_keys(), pastebuf_match_index_only(), and blender::ed::animation::tests::TEST_F().
| bool blender::ed::animation::pastebuf_match_path_full | ( | Main * | bmain, |
| const FCurve & | fcurve_to_match, | ||
| const FCurve & | fcurve_in_copy_buffer, | ||
| blender::animrig::slot_handle_t | slot_handle_in_copy_buffer, | ||
| bool | from_single, | ||
| bool | to_single, | ||
| bool | flip ) |
Most strict paste buffer matching method: exact matches on RNA path and array index only.
Definition at line 1788 of file keyframes_general.cc.
References blender::FCurve::array_index, flip_names(), blender::ed::animation::KeyframeCopyBuffer::is_bone(), keyframe_copy_buffer, and pastebuf_match_path_full().
Referenced by blender::paste_animedit_keys(), pastebuf_match_path_full(), and blender::ed::animation::tests::TEST_F().
| bool blender::ed::animation::pastebuf_match_path_property | ( | Main * | bmain, |
| const FCurve & | fcurve_to_match, | ||
| const FCurve & | fcurve_in_copy_buffer, | ||
| blender::animrig::slot_handle_t | slot_handle_in_copy_buffer, | ||
| bool | from_single, | ||
| bool | to_single, | ||
| bool | flip ) |
Medium strict paste buffer matching method: match the property name (so not the entire RNA path) and the array index. This ignores the number of components, so c and a.b.c will match.
For RNA paths that end in a lookup index (like locations[0]), the property name preceding the index needs to match too.
Definition at line 1841 of file keyframes_general.cc.
References blender::FCurve::array_index, blender::Span< T >::is_empty(), blender::Span< T >::last(), pastebuf_match_path_property(), and blender::Span< T >::size().
Referenced by blender::paste_animedit_keys(), pastebuf_match_path_property(), pastebuf_match_path_property_and_component_length(), and blender::ed::animation::tests::TEST_F().
| bool blender::ed::animation::pastebuf_match_path_property_and_component_length | ( | Main * | bmain, |
| const FCurve & | fcurve_to_match, | ||
| const FCurve & | fcurve_in_copy_buffer, | ||
| animrig::slot_handle_t | slot_handle_in_copy_buffer, | ||
| bool | from_single, | ||
| bool | to_single, | ||
| bool | flip ) |
Medium strict paste buffer matching method: match the property name (so not the entire RNA path) and the array index, but only if the RNA path has the same number of components. For example, a.b.c and d.e.c match, but a.c does not.
Definition at line 1819 of file keyframes_general.cc.
References pastebuf_match_path_property(), and pastebuf_match_path_property_and_component_length().
Referenced by blender::paste_animedit_keys(), pastebuf_match_path_property_and_component_length(), and blender::ed::animation::tests::TEST_F().
| KeyframeCopyBuffer * blender::ed::animation::keyframe_copy_buffer = nullptr |
Definition at line 1263 of file keyframes_general.cc.
Referenced by blender::ANIM_fcurves_copybuf_free(), blender::ANIM_fcurves_copybuf_reset(), blender::copy_animedit_keys(), do_curve_mirror_flippping(), get_slot_match_method(), blender::paste_animedit_keys(), paste_animedit_keys_fcurve(), pastebuf_find_matching_copybuf_item(), and pastebuf_match_path_full().