|
Blender V5.0
|
C++ functions to deal with Armature collections (i.e. the successor of bone layers). More...
#include "BLI_map.hh"#include "BKE_armature.hh"#include "DNA_action_types.h"#include "DNA_armature_types.h"Go to the source code of this file.
Namespaces | |
| namespace | blender |
| namespace | blender::animrig |
Enumerations | |
| enum class | MoveLocation { Before , After } |
C++ functions to deal with Armature collections (i.e. the successor of bone layers).
Definition in file ANIM_bone_collections.hh.
|
strong |
| Enumerator | |
|---|---|
| Before | |
| After | |
Definition at line 176 of file ANIM_bone_collections.hh.
| void ANIM_armature_bonecoll_active_index_set | ( | bArmature * | armature, |
| int | bone_collection_index ) |
Set the bone collection with the given index as the active one.
Pass -1 to clear the active bone collection.
Definition at line 416 of file animrig/intern/bone_collections.cc.
References bArmature_Runtime::active_collection, bArmature_Runtime::active_collection_index, bArmature::active_collection_name, armature_bonecoll_active_clear(), bArmature::collection_array, bArmature::collection_array_num, BoneCollection::name, bArmature::runtime, and STRNCPY().
Referenced by ANIM_armature_bonecoll_remove_from_index(), blender::animrig::armature_bonecoll_child_number_set(), armature_copy_data(), bonecoll_insert_at_index(), blender::ui::bonecollections::BoneCollectionDragController::on_drag_start(), blender::ui::bonecollections::BoneCollectionDropTarget::on_drop(), and blender::animrig::tests::TEST_F().
| void ANIM_armature_bonecoll_active_name_set | ( | bArmature * | armature, |
| const char * | name ) |
Set the bone collection with the given name as the active one.
Pass an empty name to clear the active bone collection. A non-existent name will also cause the active bone collection to be cleared.
Definition at line 430 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_active_set(), ANIM_armature_bonecoll_get_by_name(), and name.
Referenced by blender::animrig::tests::TEST_F(), and blender::animrig::tests::TEST_F().
| void ANIM_armature_bonecoll_active_runtime_refresh | ( | bArmature * | armature | ) |
Refresh the Armature runtime info about the active bone collection.
The ground truth for the active bone collection is the collection's name, whereas the runtime info also contains the active collection's index and pointer. This function updates the runtime info to point to the named collection. If that named collection cannot be found, the name will be cleared.
Definition at line 436 of file animrig/intern/bone_collections.cc.
References bArmature_Runtime::active_collection, bArmature_Runtime::active_collection_index, bArmature::active_collection_name, armature_bonecoll_active_clear(), and bArmature::runtime.
Referenced by ANIM_armature_bonecoll_insert_copy_after(), ANIM_armature_runtime_refresh(), and bone_collection_move_exec().
| void ANIM_armature_bonecoll_active_set | ( | bArmature * | armature, |
| BoneCollection * | bcoll ) |
Set the given bone collection as the active one.
Pass nullptr to clear the active bone collection.
The bone collection MUST already be owned by this armature. If it is not, this function will simply clear the active bone collection.
Definition at line 397 of file animrig/intern/bone_collections.cc.
References bArmature_Runtime::active_collection, bArmature_Runtime::active_collection_index, bArmature::active_collection_name, armature_bonecoll_active_clear(), blender::animrig::armature_bonecoll_find_index(), BoneCollection::name, bArmature::runtime, and STRNCPY().
Referenced by add_or_move_to_collection_bcoll(), ANIM_armature_bonecoll_active_name_set(), ANIM_armature_bonecoll_new(), bone_collection_add_exec(), bone_collection_create_and_assign_exec(), blender::ed::object::object_armature_add_exec(), blender::animrig::tests::TEST_F(), blender::ed::outliner::tree_element_bonecollection_activate(), and undoarm_to_editarm().
| bool ANIM_armature_bonecoll_assign | ( | BoneCollection * | bcoll, |
| Bone * | bone ) |
Assign the bone to the bone collection.
No-op if the bone is already a member of the collection.
Definition at line 880 of file animrig/intern/bone_collections.cc.
References add_membership(), add_reference(), BoneCollection::bones, and LISTBASE_FOREACH.
Referenced by ANIM_armature_bonecoll_assign_and_move(), assign_to_collection_exec(), bone_collection_assign_exec(), bone_collection_create_and_assign_exec(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), and version_bonegroups_to_bonecollections().
Definition at line 1042 of file animrig/intern/bone_collections.cc.
References bArmature_Runtime::active_collection, ANIM_armature_bonecoll_assign_editbone(), and bArmature::runtime.
Referenced by armature_bone_primitive_add_exec().
| bool ANIM_armature_bonecoll_assign_and_move | ( | BoneCollection * | bcoll, |
| Bone * | bone ) |
Definition at line 914 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_assign(), and ANIM_armature_bonecoll_unassign_all().
Referenced by move_to_collection_exec().
| bool ANIM_armature_bonecoll_assign_and_move_editbone | ( | BoneCollection * | bcoll, |
| EditBone * | ebone ) |
Definition at line 920 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_assign_editbone(), and ANIM_armature_bonecoll_unassign_all_editbone().
Referenced by move_to_collection_exec().
| bool ANIM_armature_bonecoll_assign_editbone | ( | BoneCollection * | bcoll, |
| EditBone * | ebone ) |
Definition at line 895 of file animrig/intern/bone_collections.cc.
References BoneCollectionReference::bcoll, BLI_addtail(), EditBone::bone_collections, LISTBASE_FOREACH, and MEM_callocN().
Referenced by ANIM_armature_bonecoll_assign_active(), ANIM_armature_bonecoll_assign_and_move_editbone(), assign_to_collection_exec(), bone_collection_assign_exec(), bone_collection_create_and_assign_exec(), ED_armature_ebone_add_primitive(), and mirror_bone_collection_assignments().
| bool ANIM_armature_bonecoll_contains_active_bone | ( | const bArmature * | armature, |
| const BoneCollection * | bcoll ) |
Return whether the Armature's active bone is assigned to the given bone collection.
Definition at line 1063 of file animrig/intern/bone_collections.cc.
References bArmature::act_bone, bArmature::act_edbone, bcoll_list_contains(), EditBone::bone_collections, Bone_Runtime::collections, bArmature::edbo, and Bone::runtime.
Referenced by blender::ui::bonecollections::BoneCollectionItem::build_row(), and menu_add_item_for_move_assign_unassign().
| BoneCollection * ANIM_armature_bonecoll_get_by_name | ( | bArmature * | armature, |
| const char * | name ) |
Definition at line 725 of file animrig/intern/bone_collections.cc.
References bonecolls_get_by_name(), and name.
Referenced by ANIM_armature_bonecoll_active_name_set(), get_bonecoll_named_or_active(), mirror_bone_collection_assignments(), and undoarm_to_editarm().
| int ANIM_armature_bonecoll_get_index_by_name | ( | bArmature * | armature, |
| const char * | name ) |
Scan the bone collections to find the one with the given name.
Definition at line 730 of file animrig/intern/bone_collections.cc.
References bArmature::collection_array, bArmature::collection_array_num, BoneCollection::name, name, and STREQ.
Referenced by blender::animrig::tests::TEST_F().
| void ANIM_armature_bonecoll_hide_all | ( | bArmature * | armature | ) |
Definition at line 1032 of file animrig/intern/bone_collections.cc.
References ANIM_bonecoll_hide().
| BoneCollection * ANIM_armature_bonecoll_insert_copy_after | ( | bArmature * | armature_dst, |
| const bArmature * | armature_src, | ||
| const BoneCollection * | anchor_in_dst, | ||
| const BoneCollection * | bcoll_to_copy ) |
Add a bone collection to the Armature.
If anchor is null or isn't found, this inserts the copy at the start of the collection array.
NOTE: this should not typically be used. It is only used by the library overrides system to apply override operations.
Definition at line 353 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_active_runtime_refresh(), blender::animrig::armature_bonecoll_find_index(), blender::animrig::armature_bonecoll_is_root(), BLI_assert_msg, bonecoll_ensure_name_unique(), bonecoll_insert_as_root(), copy_and_update_ownership(), bArmature::id, liboverride_recursively_add_children(), BoneCollection::name, ID::name, and printf.
Referenced by blender::animrig::tests::TEST_F().
| bool ANIM_armature_bonecoll_is_editable | ( | const bArmature * | armature, |
| const BoneCollection * | bcoll ) |
Determine whether the given bone collection is editable.
Bone collections are editable when they are local, so either on a local Armature or added to a linked Armature via a library override in the local file.
Definition at line 458 of file animrig/intern/bone_collections.cc.
References BKE_lib_override_library_is_system_defined(), BONE_COLLECTION_OVERRIDE_LIBRARY_LOCAL, BoneCollection::flags, bArmature::id, ID_IS_LINKED, and ID_IS_OVERRIDE_LIBRARY.
Referenced by active_bone_collection_poll(), add_or_move_to_collection_bcoll(), bone_collection_assign_exec(), blender::ui::bonecollections::BoneCollectionItem::build_row(), blender::ui::bonecollections::BoneCollectionItem::create_drag_controller(), move_to_collection_menu_create(), blender::ui::bonecollections::BoneCollectionDropTarget::on_drop(), blender::ui::bonecollections::BoneCollectionItem::supports_renaming(), and blender::animrig::tests::TEST_F().
| void ANIM_armature_bonecoll_is_expanded_set | ( | BoneCollection * | bcoll, |
| bool | is_expanded ) |
Expand or collapse a bone collection in the tree view.
Definition at line 855 of file animrig/intern/bone_collections.cc.
References BONE_COLLECTION_EXPANDED, and BoneCollection::flags.
Referenced by blender::animrig::bonecolls_copy_expanded_flag(), and blender::ui::bonecollections::BoneCollectionItem::set_collapsed().
| bool ANIM_armature_bonecoll_is_visible_effectively | ( | const bArmature * | armature, |
| const BoneCollection * | bcoll ) |
Determine whether this bone collection is visible, taking into account the visibility of its ancestors and the "solo" flags that are in use.
Definition at line 842 of file animrig/intern/bone_collections.cc.
References ARM_BCOLL_SOLO_ACTIVE, and bArmature::flag.
Referenced by any_bone_collection_visible().
| void ANIM_armature_bonecoll_is_visible_set | ( | bArmature * | armature, |
| BoneCollection * | bcoll, | ||
| bool | is_visible ) |
Show or hide this bone collection.
Calling this with a hard-coded is_visible parameter is equivalent to calling the dedicated show/hide functions. Prefer the dedicated functions for clarity.
Definition at line 795 of file animrig/intern/bone_collections.cc.
References ANIM_bonecoll_hide(), and ANIM_bonecoll_show().
| bool ANIM_armature_bonecoll_move | ( | bArmature * | armature, |
| BoneCollection * | bcoll, | ||
| int | step ) |
Move the bone collection by step places up/down.
Definition at line 569 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_move_to_index(), blender::animrig::armature_bonecoll_find_index(), bArmature::collection_array_num, and step.
Referenced by bone_collection_move_exec().
| int ANIM_armature_bonecoll_move_before_after_index | ( | bArmature * | armature, |
| int | from_index, | ||
| int | to_index, | ||
| MoveLocation | before_after ) |
Definition at line 527 of file animrig/intern/bone_collections.cc.
References After, ANIM_armature_bonecoll_move_to_index(), blender::animrig::armature_bonecoll_find_parent_index(), blender::animrig::armature_bonecoll_move_to_parent(), Before, and bonecoll_child_number().
Referenced by blender::ui::bonecollections::BoneCollectionDropTarget::on_drop(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), and blender::animrig::tests::TEST_F().
| bool ANIM_armature_bonecoll_move_to_index | ( | bArmature * | armature, |
| int | from_index, | ||
| int | to_index ) |
Move the bone collection at from_index to its sibling at to_index.
The element at to_index is shifted to make space; it is not overwritten. This shift happens towards from_index.
This operation does not change the total number of elements in the array.
TODO: add ASCII-art illustration of left & right movement.
Definition at line 477 of file animrig/intern/bone_collections.cc.
References blender::animrig::armature_bonecoll_find_parent_index(), blender::animrig::armature_bonecoll_is_child_of(), blender::animrig::internal::bonecolls_move_to_index(), BoneCollection::child_index, bArmature::collection_array, and bArmature::collection_array_num.
Referenced by ANIM_armature_bonecoll_move(), ANIM_armature_bonecoll_move_before_after_index(), blender::animrig::tests::TEST_F(), and blender::animrig::tests::TEST_F().
| void ANIM_armature_bonecoll_name_set | ( | bArmature * | armature, |
| BoneCollection * | bcoll, | ||
| const char * | name ) |
Definition at line 586 of file animrig/intern/bone_collections.cc.
References BKE_animdata_fix_paths_rename_all(), bonecoll_ensure_name_unique(), DATA_, bArmature::id, BoneCollection::name, name, STRNCPY(), and STRNCPY_UTF8.
Referenced by blender::ed::outliner::namebutton_fn().
| BoneCollection * ANIM_armature_bonecoll_new | ( | bArmature * | armature, |
| const char * | name, | ||
| int | parent_index = -1 ) |
Add a new bone collection to the given armature.
| parent_index | Index into the Armature's collections_array. -1 adds it as a root (i.e. parentless) collection. |
The Armature owns the returned pointer.
Definition at line 212 of file animrig/intern/bone_collections.cc.
References bArmature_Runtime::active_collection, ANIM_armature_bonecoll_active_set(), ANIM_bonecoll_new(), BONE_COLLECTION_OVERRIDE_LIBRARY_LOCAL, bonecoll_ensure_name_unique(), bonecoll_insert_as_child(), bonecoll_insert_as_root(), BoneCollection::flags, bArmature::id, ID_IS_LINKED, ID_IS_OVERRIDE_LIBRARY, name, and bArmature::runtime.
Referenced by add_or_move_to_collection_bcoll(), bone_collection_add_exec(), bone_collection_create_and_assign_exec(), join_armature_remap_collection(), mirror_bone_collection_assignments(), blender::ed::object::object_armature_add_exec(), blender::animrig::tests::ArmatureBoneCollectionsLiboverrides::SetUp(), blender::animrig::tests::ArmatureBoneCollectionsTestList::SetUp(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), version_bonegroups_to_bonecollections(), and version_bonelayers_to_bonecollections().
| void ANIM_armature_bonecoll_reconstruct | ( | bArmature * | armature | ) |
Reconstruct the bone collection memberships, based on the bone runtime data.
This is needed to transition out of armature edit mode. That removes all bones, and recreates them from the edit-bones.
Definition at line 983 of file animrig/intern/bone_collections.cc.
References blender::animrig::ANIM_armature_foreach_bone(), BLI_freelistN(), and bArmature::bonebase.
Referenced by ED_armature_from_edit().
| void ANIM_armature_bonecoll_remove | ( | bArmature * | armature, |
| BoneCollection * | bcoll ) |
Remove a bone collection from the armature.
Definition at line 707 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_remove_from_index(), and blender::animrig::armature_bonecoll_find_index().
Referenced by bone_collection_create_and_assign_exec(), bone_collection_remove_exec(), blender::ui::bonecollections::BoneCollectionItem::delete_item(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), blender::animrig::tests::TEST_F(), and blender::animrig::tests::TEST_F().
| void ANIM_armature_bonecoll_remove_from_index | ( | bArmature * | armature, |
| const int | index ) |
Remove the bone collection at index from the armature.
Definition at line 609 of file animrig/intern/bone_collections.cc.
References bArmature_Runtime::active_collection_index, ANIM_armature_bonecoll_active_index_set(), ANIM_armature_refresh_solo_active(), blender::animrig::armature_bonecoll_find_parent_index(), blender::animrig::armature_bonecoll_is_child_of(), blender::animrig::armature_bonecoll_move_to_parent(), BLI_assert, BLI_assert_msg, bonecoll_child_number(), blender::animrig::internal::bonecoll_unassign_and_free(), blender::animrig::internal::bonecolls_find_index_near(), blender::animrig::internal::bonecolls_move_to_index(), BoneCollection::child_count, BoneCollection::child_index, bArmature::collection_array, bArmature::collection_array_num, bArmature::collection_root_count, NC_OBJECT, ND_BONE_COLLECTION, bArmature::runtime, and WM_main_add_notifier().
Referenced by ANIM_armature_bonecoll_remove().
| void ANIM_armature_bonecoll_show_all | ( | bArmature * | armature | ) |
Definition at line 1025 of file animrig/intern/bone_collections.cc.
References ANIM_bonecoll_show().
Referenced by blender::ed::object::modifier_skin_armature_create().
Definition at line 1079 of file animrig/intern/bone_collections.cc.
References ANIM_bone_in_visible_collection(), BoneCollectionReference::bcoll, BONE_COLLECTION_VISIBLE, Bone_Runtime::collections, ListBase::first, BoneCollection::flags, and Bone::runtime.
Referenced by ANIM_armature_bonecoll_show_from_pchan().
Definition at line 1094 of file animrig/intern/bone_collections.cc.
References ANIM_bonecoll_is_visible_editbone(), BoneCollectionReference::bcoll, BONE_COLLECTION_VISIBLE, EditBone::bone_collections, ListBase::first, and BoneCollection::flags.
Referenced by blender::ed::object::jump_to_bone().
| void ANIM_armature_bonecoll_show_from_pchan | ( | bArmature * | armature, |
| const bPoseChannel * | pchan ) |
Definition at line 1109 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_show_from_bone(), and bPoseChannel::bone.
Referenced by blender::ed::object::jump_to_bone().
| void ANIM_armature_bonecoll_solo_set | ( | bArmature * | armature, |
| BoneCollection * | bcoll, | ||
| bool | is_solo ) |
Set or clear this bone collection's solo flag.
Definition at line 807 of file animrig/intern/bone_collections.cc.
References ANIM_armature_refresh_solo_active(), ARM_BCOLL_SOLO_ACTIVE, BONE_COLLECTION_SOLO, bArmature::flag, and BoneCollection::flags.
Referenced by blender::animrig::tests::TEST_F().
| bool ANIM_armature_bonecoll_unassign | ( | BoneCollection * | bcoll, |
| Bone * | bone ) |
Definition at line 926 of file animrig/intern/bone_collections.cc.
References BLI_freelinkN(), BoneCollection::bones, Bone_Runtime::collections, LISTBASE_FOREACH_MUTABLE, and Bone::runtime.
Referenced by ANIM_armature_bonecoll_unassign_all(), bone_collection_unassign_exec(), bone_collection_unassign_named_exec(), blender::animrig::internal::bonecoll_unassign_and_free(), and blender::animrig::tests::TEST_F().
| void ANIM_armature_bonecoll_unassign_all | ( | Bone * | bone | ) |
Definition at line 952 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_unassign(), Bone_Runtime::collections, LISTBASE_FOREACH_MUTABLE, and Bone::runtime.
Referenced by ANIM_armature_bonecoll_assign_and_move().
| void ANIM_armature_bonecoll_unassign_all_editbone | ( | EditBone * | ebone | ) |
Definition at line 961 of file animrig/intern/bone_collections.cc.
References ANIM_armature_bonecoll_unassign_editbone(), EditBone::bone_collections, and LISTBASE_FOREACH_MUTABLE.
Referenced by ANIM_armature_bonecoll_assign_and_move_editbone().
| bool ANIM_armature_bonecoll_unassign_editbone | ( | BoneCollection * | bcoll, |
| EditBone * | ebone ) |
Definition at line 968 of file animrig/intern/bone_collections.cc.
References BLI_freelinkN(), EditBone::bone_collections, and LISTBASE_FOREACH_MUTABLE.
Referenced by ANIM_armature_bonecoll_unassign_all_editbone(), bone_collection_unassign_exec(), bone_collection_unassign_named_exec(), blender::animrig::internal::bonecoll_unassign_and_free(), and mirror_bone_collection_assignments().
| void ANIM_armature_refresh_solo_active | ( | bArmature * | armature | ) |
Refresh the ARM_BCOLL_SOLO_ACTIVE flag.
Definition at line 824 of file animrig/intern/bone_collections.cc.
References ARM_BCOLL_SOLO_ACTIVE, BONE_COLLECTION_SOLO, and bArmature::flag.
Referenced by ANIM_armature_bonecoll_remove_from_index(), and ANIM_armature_bonecoll_solo_set().
| void ANIM_armature_runtime_free | ( | bArmature * | armature | ) |
Free armature & bone runtime data. TODO: move to BKE?
Definition at line 114 of file animrig/intern/bone_collections.cc.
References blender::animrig::ANIM_armature_foreach_bone(), and bArmature::bonebase.
Referenced by ANIM_armature_runtime_refresh(), and armature_free_data().
| void ANIM_armature_runtime_refresh | ( | bArmature * | armature | ) |
Recalculate the armature & bone runtime data.
TODO: move to BKE?
Definition at line 98 of file animrig/intern/bone_collections.cc.
References add_reverse_pointers(), ancestors_visible_update(), ANIM_armature_bonecoll_active_runtime_refresh(), and ANIM_armature_runtime_free().
Referenced by armature_blend_read_data(), armature_copy_data(), ED_armature_join_objects_exec(), and undoarm_to_editarm().
Return true when any of the bone's collections is visible.
Definition at line 1016 of file animrig/intern/bone_collections.cc.
References any_bone_collection_visible(), Bone_Runtime::collections, and Bone::runtime.
Referenced by add_verts_to_dgroups(), ANIM_armature_bonecoll_show_from_bone(), ANIM_bonecoll_is_visible_actbone(), ANIM_bonecoll_is_visible_pchan(), blender::ed::transform::armature_bone_transflags_update(), BKE_pose_channel_active(), BKE_pose_is_bonecoll_visible(), blender::animrig::bone_is_visible(), blender::animrig::bone_is_visible(), dgroup_skinnable_cb(), pose_hide_exec(), and pose_reveal_exec().
| void ANIM_bonecoll_free | ( | BoneCollection * | bcoll, |
| bool | do_id_user_count = true ) |
Free the bone collection.
You don't typically need this function, unless you created a bone collection outside the scope of a bArmature. Normally bone collections are owned (and thus managed) by the armature.
| do_id_user_count | Whether to update user counts for IDs referenced from IDProperties of the bone collection. Needs to be false when freeing an evaluated copy, true otherwise. |
Definition at line 70 of file animrig/intern/bone_collections.cc.
References BLI_assert_msg, BLI_listbase_is_empty(), BoneCollection::bones, IDP_FreeProperty_ex(), BoneCollection::prop, and BoneCollection::system_properties.
Referenced by armature_free_data(), blender::animrig::internal::bonecoll_unassign_and_free(), blender::animrig::tests::TEST(), blender::animrig::tests::TEST(), and blender::animrig::tests::TEST_F().
| void ANIM_bonecoll_hide | ( | bArmature * | armature, |
| BoneCollection * | bcoll ) |
Hide this bone collection.
This marks the bone collection as 'hidden'. This also effectively hides its descendants, regardless of their visibility state.
Definition at line 789 of file animrig/intern/bone_collections.cc.
References ancestors_visible_descendants_update(), BONE_COLLECTION_VISIBLE, and BoneCollection::flags.
Referenced by ANIM_armature_bonecoll_hide_all(), ANIM_armature_bonecoll_is_visible_set(), blender::animrig::tests::TEST_F(), version_bonegroups_to_bonecollections(), and version_bonelayers_to_bonecollections().
|
inline |
Definition at line 321 of file ANIM_bone_collections.hh.
References bArmature::act_bone, and ANIM_bone_in_visible_collection().
Referenced by draw_selected_name().
Returns true when the edit-bone's collection is visible.
Definition at line 1020 of file animrig/intern/bone_collections.cc.
References any_bone_collection_visible(), and EditBone::bone_collections.
Referenced by ANIM_armature_bonecoll_show_from_ebone(), armature_bone_primitive_add_exec(), armature_reveal_exec(), blender::animrig::bone_is_visible(), and v3d_editarmature_buts().
|
inline |
Definition at line 316 of file ANIM_bone_collections.hh.
References ANIM_bone_in_visible_collection(), and bPoseChannel::bone.
Referenced by animviz_build_motionpath_targets(), snap_curs_to_sel_ex(), and snap_sel_to_grid_exec().
| BoneCollection * ANIM_bonecoll_new | ( | const char * | name | ) |
Construct a new BoneCollection with the given name.
The caller owns the returned pointer.
You don't typically use this function directly, but rather create a bone collection on a bArmature.
Definition at line 53 of file animrig/intern/bone_collections.cc.
References DATA_, BoneCollection::flags, MEM_callocN(), BoneCollection::name, name, and STRNCPY_UTF8.
Referenced by ANIM_armature_bonecoll_new(), blender::animrig::tests::TEST(), blender::animrig::tests::TEST(), and blender::animrig::tests::TEST_F().
| void ANIM_bonecoll_show | ( | bArmature * | armature, |
| BoneCollection * | bcoll ) |
Show this bone collection.
This marks the bone collection as 'visible'. Whether it is effectively visible also depends on the visibility state of its ancestors.
Definition at line 783 of file animrig/intern/bone_collections.cc.
References ancestors_visible_descendants_update(), BONE_COLLECTION_VISIBLE, and BoneCollection::flags.
Referenced by ANIM_armature_bonecoll_is_visible_set(), and ANIM_armature_bonecoll_show_all().