29 {0,
"DEFAULT", 0,
"Default Colors",
""},
30 {1,
"THEME01", ICON_COLORSET_01_VEC,
"01 - Theme Color Set",
""},
31 {2,
"THEME02", ICON_COLORSET_02_VEC,
"02 - Theme Color Set",
""},
32 {3,
"THEME03", ICON_COLORSET_03_VEC,
"03 - Theme Color Set",
""},
33 {4,
"THEME04", ICON_COLORSET_04_VEC,
"04 - Theme Color Set",
""},
34 {5,
"THEME05", ICON_COLORSET_05_VEC,
"05 - Theme Color Set",
""},
35 {6,
"THEME06", ICON_COLORSET_06_VEC,
"06 - Theme Color Set",
""},
36 {7,
"THEME07", ICON_COLORSET_07_VEC,
"07 - Theme Color Set",
""},
37 {8,
"THEME08", ICON_COLORSET_08_VEC,
"08 - Theme Color Set",
""},
38 {9,
"THEME09", ICON_COLORSET_09_VEC,
"09 - Theme Color Set",
""},
39 {10,
"THEME10", ICON_COLORSET_10_VEC,
"10 - Theme Color Set",
""},
40 {11,
"THEME11", ICON_COLORSET_11_VEC,
"11 - Theme Color Set",
""},
41 {12,
"THEME12", ICON_COLORSET_12_VEC,
"12 - Theme Color Set",
""},
42 {13,
"THEME13", ICON_COLORSET_13_VEC,
"13 - Theme Color Set",
""},
43 {14,
"THEME14", ICON_COLORSET_14_VEC,
"14 - Theme Color Set",
""},
44 {15,
"THEME15", ICON_COLORSET_15_VEC,
"15 - Theme Color Set",
""},
45 {16,
"THEME16", ICON_COLORSET_16_VEC,
"16 - Theme Color Set",
""},
46 {17,
"THEME17", ICON_COLORSET_17_VEC,
"17 - Theme Color Set",
""},
47 {18,
"THEME18", ICON_COLORSET_18_VEC,
"18 - Theme Color Set",
""},
48 {19,
"THEME19", ICON_COLORSET_19_VEC,
"19 - Theme Color Set",
""},
49 {20,
"THEME20", ICON_COLORSET_20_VEC,
"20 - Theme Color Set",
""},
50 {-1,
"CUSTOM", 0,
"Custom Color Set",
""},
51 {0,
nullptr, 0,
nullptr,
nullptr},
54constexpr int COLOR_SETS_MAX_THEMED_INDEX = 20;
59# include <fmt/format.h>
87 ID *
id =
ptr->owner_id;
94 ID *
id =
ptr->owner_id;
103 ID *
id =
ptr->owner_id;
115 if (value.owner_id ==
nullptr && value.data ==
nullptr) {
116 arm->act_bone =
nullptr;
119 if (value.owner_id != &arm->id) {
122 if (
GS(ob->id.name) !=
ID_OB || (ob->data != arm)) {
123 printf(
"ERROR: armature set active bone - new active does not come from this armature\n");
128 arm->act_bone =
static_cast<Bone *
>(value.data);
139 if (value.owner_id ==
nullptr && value.data ==
nullptr) {
140 arm->act_edbone =
nullptr;
143 if (value.owner_id != &arm->id) {
147 arm->act_edbone =
static_cast<EditBone *
>(value.data);
155 if (arm->
edbo ==
nullptr) {
158 "Armature '%s' not in edit mode, cannot add an editbone",
165static void rna_Armature_edit_bone_remove(
bArmature *arm,
170 if (arm->
edbo ==
nullptr) {
173 "Armature '%s' not in edit mode, cannot remove an editbone",
181 "Armature '%s' does not contain bone '%s'",
203static int rna_iterator_bone_collections_all_length(
PointerRNA *
ptr)
221static int rna_iterator_bone_collections_roots_length(
PointerRNA *
ptr)
243 arm->collection_array + bcoll->child_index,
249static int rna_iterator_bone_collection_children_length(
PointerRNA *
ptr)
252 return bcoll->child_count;
267 if (parent_index < 0) {
290 if (to_parent_index >= 0) {
292 if (to_parent_index == from_bcoll_index ||
301 armature, from_bcoll_index, -1, from_parent_index, to_parent_index);
306static int rna_BoneCollections_active_index_get(
PointerRNA *
ptr)
309 return arm->runtime.active_collection_index;
312static void rna_BoneCollections_active_index_set(
PointerRNA *
ptr,
const int bone_collection_index)
320static void rna_BoneCollections_active_index_range(
328 *
max =
max_ii(0, arm->collection_array_num - 1);
336 if (parent ==
nullptr) {
343 if (parent_index < 0) {
346 "Bone collection '%s' not found in Armature '%s'",
357static void rna_BoneCollections_active_name_set(
PointerRNA *
ptr,
const char *
name)
366 if (from < 0 || from >=
count || to < 0 || to >=
count ||
383static void rna_BoneCollection_is_visible_set(
PointerRNA *
ptr,
const bool is_visible)
391static bool rna_BoneCollection_is_visible_effectively_get(
PointerRNA *
ptr)
398static void rna_BoneCollection_is_solo_set(
PointerRNA *
ptr,
const bool is_solo)
406static void rna_BoneCollection_is_expanded_set(
PointerRNA *
ptr,
const bool is_expanded)
412static std::optional<std::string> rna_BoneCollection_path(
const PointerRNA *
ptr)
415 char name_esc[
sizeof(bcoll->
name) * 2];
417 return fmt::format(
"collections_all[\"{}\"]", name_esc);
432static void rna_BoneCollectionMemberships_clear(
Bone *bone)
438static bool rna_BoneCollection_is_editable_get(
PointerRNA *
ptr)
452static int rna_BoneCollection_child_number_get(
PointerRNA *
ptr)
458static void rna_BoneCollection_child_number_set(
PointerRNA *
ptr,
const int new_child_number)
493 ListBase bone_collection_refs = bone->runtime.collections;
509 ListBase bone_collection_refs = ebone->bone_collections;
514static bool rna_Armature_collections_override_apply(
Main *bmain,
538 printf(
"Unsupported RNA override operation on armature collections, ignoring\n");
547 arm_dst, arm_src, bcoll_anchor, bcoll_src);
558static std::optional<std::string> rna_BoneColor_path_posebone(
const PointerRNA *
ptr)
571 if (&checkBone->color ==
ptr->data) {
573 "pointer magic to find the pose bone failed (found the wrong bone)");
578 BLI_assert_msg(found,
"pointer magic to find the pose bone failed (did not find the bone)");
581 char name_esc[
sizeof(bone->
name) * 2];
583 return fmt::format(
"pose.bones[\"{}\"].color", name_esc);
586static std::optional<std::string> rna_BoneColor_path_bone(
const PointerRNA *
ptr)
591 const Bone *bone =
reinterpret_cast<const Bone *
>(bone_ptr);
600 if (&checkBone->color == ptr->data) {
601 BLI_assert_msg(checkBone == bone,
602 "pointer magic to find the pose bone failed (found the wrong bone)");
606 BLI_assert_msg(found,
"pointer magic to find the pose bone failed (did not find the bone)");
609 char name_esc[
sizeof(bone->
name) * 2];
611 return fmt::format(
"bones[\"{}\"].color", name_esc);
614static std::optional<std::string> rna_BoneColor_path_editbone(
const PointerRNA *
ptr)
628 if (&checkBone->color ==
ptr->data) {
630 "pointer magic to find the pose bone failed (found the wrong bone)");
635 BLI_assert_msg(found,
"pointer magic to find the pose bone failed (did not find the bone)");
638 char name_esc[
sizeof(bone->
name) * 2];
640 return fmt::format(
"bones[\"{}\"].color", name_esc);
643static std::optional<std::string> rna_BoneColor_path(
const PointerRNA *
ptr)
645 const ID *owner =
ptr->owner_id;
646 BLI_assert_msg(owner,
"expecting all bone colors to have an owner");
648 switch (
GS(owner->
name)) {
650 return rna_BoneColor_path_posebone(
ptr);
653 if (arm->
edbo ==
nullptr) {
654 return rna_BoneColor_path_bone(
ptr);
656 return rna_BoneColor_path_editbone(
ptr);
664void rna_BoneColor_palette_index_set(
PointerRNA *
ptr,
const int new_palette_index)
666 if (new_palette_index < -1 || new_palette_index > COLOR_SETS_MAX_THEMED_INDEX) {
674 ID *
id =
ptr->owner_id;
698 ID *
id =
ptr->owner_id;
734 ID *
id =
ptr->owner_id;
743static std::optional<std::string> rna_Bone_path(
const PointerRNA *
ptr)
745 const ID *
id =
ptr->owner_id;
747 char name_esc[
sizeof(bone->
name) * 2];
756 return fmt::format(
"pose.bones[\"{}\"].bone", name_esc);
761 return fmt::format(
"bones[\"{}\"]", name_esc);
776static std::optional<std::string> rna_EditBone_path(
const PointerRNA *
ptr)
779 char name_esc[
sizeof(ebone->
name) * 2];
782 return fmt::format(
"edit_bones[\"{}\"]", name_esc);
797static void rna_EditBone_name_set(
PointerRNA *
ptr,
const char *value)
801 char oldname[
sizeof(ebone->name)], newname[
sizeof(ebone->name)];
811static void rna_Bone_name_set(
PointerRNA *
ptr,
const char *value)
815 char oldname[
sizeof(bone->
name)], newname[
sizeof(bone->
name)];
825static void rna_EditBone_connected_check(
EditBone *ebone)
842static void rna_EditBone_connected_set(
PointerRNA *
ptr,
bool value)
853 rna_EditBone_connected_check(ebone);
867 if (parbone ==
nullptr) {
882 if (parbone == ebone) {
886 for (pbone = parbone->parent; pbone; pbone = pbone->parent) {
887 if (pbone == ebone) {
893 rna_EditBone_connected_check(ebone);
897static void rna_EditBone_matrix_get(
PointerRNA *
ptr,
float *values)
903static void rna_EditBone_matrix_set(
PointerRNA *
ptr,
const float *values)
936 for (
Object *obt =
static_cast<Object *
>(bmain->objects.first); obt;
937 obt =
static_cast<Object *
>(obt->id.next))
939 if (obt->data == arm && obt->pose) {
942 if (pchan && pchan->
bone == bone) {
949 rna_Armature_dependency_update(bmain, scene,
ptr);
966 if (hbone ==
nullptr || value.
owner_id ==
ptr->owner_id) {
977 if (hbone ==
nullptr || value.
owner_id ==
ptr->owner_id) {
996 if (hbone ==
nullptr || value.
owner_id ==
ptr->owner_id) {
1007 if (hbone ==
nullptr || value.
owner_id ==
ptr->owner_id) {
1042 rna_Armature_update_data(bmain, scene,
ptr);
1050 if (bone->childbase.first) {
1053 else if (bone->
next) {
1061 if (bone && bone->
next) {
1068 iter->valid = (
internal->link !=
nullptr);
1088 return (arm->
edbo !=
nullptr);
1091static void rna_Armature_transform(
bArmature *arm,
const float mat[16])
1096static int rna_Armature_relation_line_position_get(
PointerRNA *
ptr)
1103static void rna_Armature_relation_line_position_set(
PointerRNA *
ptr,
const int value)
1147 "A color palette is user-defined, instead of using a theme-defined one");
1155 prop,
"Custom",
"The custom bone colors, used when palette is 'CUSTOM'");
1163# define RNA_DEF_CURVEBONE_UPDATE(prop, is_posebone, is_editbone) \
1165 if (is_posebone) { \
1166 RNA_def_property_update(prop, NC_OBJECT | ND_POSE, "rna_Pose_update"); \
1168 else if (is_editbone) { \
1169 RNA_def_property_update(prop, 0, "rna_Armature_editbone_transform_update"); \
1172 RNA_def_property_update(prop, 0, "rna_Armature_update_data"); \
1184 prop,
"Roll In",
"Roll offset for the start of the B-Bone, adjusts twist");
1191 prop,
"Roll Out",
"Roll offset for the end of the B-Bone, adjusts twist");
1194 if (is_posebone ==
false) {
1197 prop,
"Inherit End Roll",
"Add Roll Out of the Start Handle bone to the Roll In value");
1208 prop,
"In X",
"X-axis handle offset for start of the B-Bone's curve, adjusts curvature");
1215 prop,
"In Z",
"Z-axis handle offset for start of the B-Bone's curve, adjusts curvature");
1222 prop,
"Out X",
"X-axis handle offset for end of the B-Bone's curve, adjusts curvature");
1229 prop,
"Out Z",
"Z-axis handle offset for end of the B-Bone's curve, adjusts curvature");
1249 if (is_posebone ==
false) {
1252 prop,
"Scale Easing",
"Multiply the final easing values by the Scale In/Out Y factors");
1267 "Scale factors for the start of the B-Bone, adjusts thickness (for tapering effects)");
1279 "Scale factors for the end of the B-Bone, adjusts thickness (for tapering effects)");
1282# undef RNA_DEF_CURVEBONE_UPDATE
1292 "Use connected parent and children to compute the handle"},
1297 "Use the position of the specified bone to compute the handle"},
1302 "Use the offset of the specified bone from rest pose to compute the handle"},
1307 "Use the orientation of the specified bone to compute the handle, ignoring the location"},
1308 {0,
nullptr, 0,
nullptr,
nullptr},
1316 "Fast mapping that is good for most situations, but ignores the rest pose "
1317 "curvature of the B-Bone"},
1322 "Slower mapping that gives better deformation for B-Bones that are sharply "
1323 "curved in rest pose"},
1324 {0,
nullptr, 0,
nullptr,
nullptr},
1333 "Inherit scaling, but remove shearing of the child in the rest orientation"},
1338 "Rotate non-uniform parent scaling to align with the child, applying parent X "
1339 "scale to child X axis, and so forth"},
1344 "Inherit uniform scaling representing the overall change in the volume of the parent"},
1350 "Ignore parent scaling without compensating for parent shear. "
1351 "Replicates the effect of disabling the original Inherit Scale checkbox."},
1352 {0,
nullptr, 0,
nullptr,
nullptr},
1360 "Use display mode from armature (default)"},
1361 {
ARM_DRAW_TYPE_OCTA,
"OCTAHEDRAL", 0,
"Octahedral",
"Display bones as octahedral shape"},
1367 "Display bones as boxes, showing subdivision and B-Splines"},
1372 "Display bones as extruded spheres, showing deformation influence volume"},
1377 "Display bones as thin wires, showing subdivision and B-Splines"},
1378 {0,
nullptr, 0,
nullptr,
nullptr},
1422 prop,
"Connected",
"When bone has a parent, bone's head is stuck to the parent's tail");
1428 prop,
"Inherit Rotation",
"Bone inherits rotation or scale from parent bone");
1435 "Multiply Vertex Group with Envelope",
1436 "When deforming bone, multiply effects of Vertex Group weights with Envelope influence");
1446 prop,
"Inherit Scale",
"Specifies how the bone inherits scaling from the parent bone");
1458 prop,
"Relative Parenting",
"Object children will use relative transform, like deform");
1467 "Bone is always displayed in wireframe regardless of viewport shading mode "
1468 "(useful for non-obstructive custom bone shapes)");
1477 "When bone does not have a parent, it receives cyclic offset effects (Deprecated)");
1502 prop,
"Envelope Deform Distance",
"Bone deformation distance (for Envelope deform only)");
1508 prop,
"Envelope Deform Weight",
"Bone deformation weight (for Envelope deform only)");
1523 prop,
"Envelope Head Radius",
"Radius of head of bone (for Envelope deform only)");
1537 prop,
"Envelope Tail Radius",
"Radius of tail of bone (for Envelope deform only)");
1550 prop,
"B-Bone Segments",
"Number of subdivisions of bone (for B-Bones only)");
1558 "B-Bone Vertex Mapping Mode",
1559 "Selects how the vertices are mapped to B-Bone segments based on their position");
1590 prop,
"B-Bone Start Handle Type",
"Selects how the start handle of the B-Bone is computed");
1598 prop,
"rna_EditBone_bbone_prev_get",
"rna_EditBone_bbone_prev_set",
nullptr,
nullptr);
1608 prop,
"B-Bone Start Handle",
"Bone that serves as the start handle for the B-Bone curve");
1613 "Start Handle Scale",
1614 "Multiply B-Bone Scale In channels by the local scale values of the start handle. "
1615 "This is done after the Scale Easing option and isn't affected by it.");
1623 "Start Handle Ease",
1624 "Multiply the B-Bone Ease In channel by the local Y scale value of the start handle. "
1625 "This is done after the Scale Easing option and isn't affected by it.");
1635 prop,
"B-Bone End Handle Type",
"Selects how the end handle of the B-Bone is computed");
1643 prop,
"rna_EditBone_bbone_next_get",
"rna_EditBone_bbone_next_set",
nullptr,
nullptr);
1653 prop,
"B-Bone End Handle",
"Bone that serves as the end handle for the B-Bone curve");
1659 "Multiply B-Bone Scale Out channels by the local scale values of the end handle. "
1660 "This is done after the Scale Easing option and isn't affected by it.");
1669 "Multiply the B-Bone Ease Out channel by the local Y scale value of the end handle. "
1670 "This is done after the Scale Easing option and isn't affected by it.");
1684 srna =
RNA_def_struct(brna,
"BoneCollectionMemberships",
nullptr);
1687 srna,
"Bone Collection Memberships",
"The Bone Collections that contain this Bone");
1690 func =
RNA_def_function(srna,
"clear",
"rna_BoneCollectionMemberships_clear");
1726 "rna_Bone_collections_begin",
1727 "rna_iterator_listbase_next",
1728 "rna_iterator_listbase_end",
1729 "rna_Bone_collections_get",
1762 "Bone Armature-Relative Matrix",
1764 "4 bone matrix relative to armature");
1771 prop,
"Tail",
"Location of tail end of the bone relative to its parent");
1779 prop,
"Armature-Relative Tail",
"Location of tail end of the bone relative to armature");
1787 prop,
"Head",
"Location of head end of the bone relative to its parent");
1795 prop,
"Armature-Relative Head",
"Location of head end of the bone relative to armature");
1824 "rna_EditBone_collections_begin",
1825 "rna_iterator_listbase_next",
1826 "rna_iterator_listbase_end",
1827 "rna_Bone_collections_get",
1841 prop,
"rna_EditBone_parent_get",
"rna_EditBone_parent_set",
nullptr,
nullptr);
1871 prop,
"rna_EditBone_length_get",
"rna_EditBone_length_set",
nullptr);
1920 "Matrix combining location and rotation of the bone (head position, direction and roll), "
1921 "in armature space (does not include/support bone's length/size)");
1923 prop,
"rna_EditBone_matrix_get",
"rna_EditBone_matrix_set",
nullptr);
1977 prop,
nullptr,
"rna_Armature_act_edit_bone_set",
nullptr,
nullptr);
1986 parm =
RNA_def_string(func,
"name",
"Object", 0,
"",
"New name for the bone");
1989 parm =
RNA_def_pointer(func,
"bone",
"EditBone",
"",
"Newly created edit bone");
1997 parm =
RNA_def_pointer(func,
"bone",
"EditBone",
"",
"EditBone to remove");
2015 srna,
"Armature Bone Collections",
"The Bone Collections of this Armature");
2023 prop,
nullptr,
"rna_BoneCollections_active_set",
nullptr,
nullptr);
2033 "Active Collection Index",
2034 "The index of the Armature's active bone collection; -1 when there "
2035 "is no active collection. Note that this is indexing the underlying array of bone "
2036 "collections, which may not be in the order you expect. Root collections are listed first, "
2037 "and siblings are always sequential. Apart from that, bone collections can be in any order, "
2038 "and thus incrementing or decrementing this index can make the active bone collection jump "
2039 "around in unexpected ways. For a more predictable interface, use ``active`` or "
2040 "``active_name``.");
2042 "rna_BoneCollections_active_index_get",
2043 "rna_BoneCollections_active_index_set",
2044 "rna_BoneCollections_active_index_range");
2053 "Active Collection Name",
2054 "The name of the Armature's active bone collection; empty when there "
2055 "is no active collection");
2064 "Read-only flag that indicates there is at least one bone collection marked as 'solo'");
2076 "Name of the new collection. Blender will ensure it is unique within the "
2077 "collections of the Armature.");
2083 "Parent Collection",
2084 "If not None, the new bone collection becomes a child of this collection");
2087 func,
"bonecollection",
"BoneCollection",
"",
"Newly created bone collection");
2094 "Remove the bone collection from the armature. If this bone collection has any children, "
2095 "they will be reassigned to their grandparent; in other words, the children will take the "
2096 "place of the removed bone collection.");
2101 "The bone collection to remove");
2107 "Move a bone collection to a different position in the "
2108 "collection list. This can only be used to reorder siblings, "
2109 "and not to change parent-child relationships.");
2112 func,
"from_index", -1, INT_MIN, INT_MAX,
"From Index",
"Index to move", 0, 10000);
2114 parm =
RNA_def_int(func,
"to_index", -1, INT_MIN, INT_MAX,
"To Index",
"Target index", 0, 10000);
2131 "Display bones as octahedral shape (default)"},
2137 "Display bones as boxes, showing subdivision and B-Splines"},
2142 "Display bones as extruded spheres, showing deformation influence volume"},
2147 "Display bones as thin wires, showing subdivision and B-Splines"},
2148 {0,
nullptr, 0,
nullptr,
nullptr},
2152 {0,
"POSE", 0,
"Pose Position",
"Show armature in posed state"},
2157 "Show Armature in binding pose state (no posing possible)"},
2158 {0,
nullptr, 0,
nullptr,
nullptr},
2161 {0,
"TAIL", 0,
"Tail",
"Draw the relationship line from the parent tail to the child head"},
2162 {1,
"HEAD", 0,
"Head",
"Draw the relationship line from the parent head to the child head"},
2163 {0,
nullptr, 0,
nullptr,
nullptr},
2170 "Armature data-block containing a hierarchy of bones, usually used for rigging characters");
2176 parm =
RNA_def_float_matrix(func,
"matrix", 4, 4,
nullptr, 0.0f, 0.0f,
"",
"Matrix", 0.0f, 0.0f);
2189 "rna_Armature_bones_next",
2194 "rna_Armature_bones_lookup_string",
2210 "rna_iterator_bone_collections_roots_begin",
2211 "rna_iterator_array_next",
2212 "rna_iterator_array_end",
2213 "rna_iterator_array_dereference_get",
2214 "rna_iterator_bone_collections_roots_length",
2221 prop,
nullptr,
nullptr,
"rna_Armature_collections_override_apply");
2229 "rna_iterator_bone_collections_all_begin",
2230 "rna_iterator_array_next",
2231 "rna_iterator_array_end",
2232 "rna_iterator_array_dereference_get",
2233 "rna_iterator_bone_collections_all_length",
2238 prop,
"Bone Collections (All)",
"List of all bone collections of the armature");
2253 prop,
"Pose Position",
"Show armature in binding pose or final posed state");
2277 "The position for the axes on the bone. Increasing the value moves it "
2278 "closer to the tip; decreasing moves it closer to the root.");
2285 "Relation Line Position",
2286 "The start position of the relation lines from parent to child bones");
2290 "rna_Armature_relation_line_position_get",
2291 "rna_Armature_relation_line_position_set",
2304 prop,
"X-Axis Mirror",
"Apply changes to matching bone on opposite side of X-Axis");
2311 prop,
"Display Custom Bone Shapes",
"Display bones with their custom shapes");
2348 prop,
"Expanded",
"This bone collection is expanded in the bone collections tree view");
2357 prop,
"Visible",
"Bones in this collection will be visible in pose/object mode");
2366 "Ancestors Effectively Visible",
2367 "True when all of the ancestors of this bone collection are marked as "
2368 "visible; always True for root bone collections");
2375 "Effective Visibility",
2376 "Whether this bone collection is effectively visible in the viewport. This is True when "
2377 "this bone collection and all of its ancestors are visible, or when it is marked as "
2384 prop,
"Solo",
"Show only this bone collection, and others also marked as 'solo'");
2394 "Is Local Override",
2395 "This collection was added via a library override in the current blend file");
2402 "This collection is owned by a local Armature, or was added via a "
2403 "library override in the current blend file");
2409 "rna_BoneCollection_bones_begin",
2410 "rna_iterator_listbase_next",
2411 "rna_iterator_listbase_end",
2412 "rna_BoneCollection_bones_get",
2421 "Bones assigned to this bone collection. In armature edit mode this "
2422 "will always return an empty list of bones, as the bone collection "
2423 "memberships are only synchronized when exiting edit mode.");
2428 "rna_iterator_bone_collection_children_begin",
2429 "rna_iterator_array_next",
2430 "rna_iterator_array_end",
2431 "rna_iterator_array_dereference_get",
2432 "rna_iterator_bone_collection_children_length",
2444 prop,
"rna_BoneCollection_parent_get",
"rna_BoneCollection_parent_set",
nullptr,
nullptr);
2447 "Parent bone collection. Note that accessing this requires a scan of "
2448 "all the bone collections to find the parent.");
2457 "Index of this bone collection in the armature.collections_all array. Note that finding "
2458 "this index requires a scan of all the bone collections, so do access this with care.");
2463 prop,
"rna_BoneCollection_child_number_get",
"rna_BoneCollection_child_number_set",
nullptr);
2467 "Index of this collection into its parent's list of children. Note that finding "
2468 "this index requires a scan of all the bone collections, so do access this with care.");
C++ functions to deal with Armature collections (i.e. the successor of bone layers).
void ANIM_armature_bonecoll_active_set(bArmature *armature, BoneCollection *bcoll)
bool ANIM_armature_bonecoll_is_editable(const bArmature *armature, const BoneCollection *bcoll)
BoneCollection * ANIM_armature_bonecoll_insert_copy_after(bArmature *armature_dst, const bArmature *armature_src, const BoneCollection *anchor_in_dst, const BoneCollection *bcoll_to_copy)
void ANIM_armature_bonecoll_is_expanded_set(BoneCollection *bcoll, bool is_expanded)
void ANIM_armature_bonecoll_active_name_set(bArmature *armature, const char *name)
void ANIM_armature_bonecoll_unassign_all(Bone *bone)
bool ANIM_armature_bonecoll_move_to_index(bArmature *armature, int from_index, int to_index)
bool ANIM_armature_bonecoll_is_visible_effectively(const bArmature *armature, const BoneCollection *bcoll)
void ANIM_armature_bonecoll_name_set(bArmature *armature, BoneCollection *bcoll, const char *name)
void ANIM_armature_bonecoll_solo_set(bArmature *armature, BoneCollection *bcoll, bool is_solo)
BoneCollection * ANIM_armature_bonecoll_new(bArmature *armature, const char *name, int parent_index=-1)
void ANIM_armature_bonecoll_is_visible_set(bArmature *armature, BoneCollection *bcoll, bool is_visible)
void ANIM_armature_bonecoll_active_index_set(bArmature *armature, int bone_collection_index)
Blender kernel action and pose functionality.
bPoseChannel * BKE_pose_channel_find_name(const bPose *pose, const char *name)
void BKE_pchan_rebuild_bbone_handles(bPose *pose, bPoseChannel *pchan)
Bone * BKE_armature_find_bone_name(bArmature *arm, const char *name)
bool BKE_id_is_in_global_main(ID *id)
void BKE_reportf(ReportList *reports, eReportType type, const char *format,...) ATTR_PRINTF_FORMAT(3
void BKE_report(ReportList *reports, eReportType type, const char *message)
#define BLI_assert_msg(a, msg)
int BLI_findindex(const ListBase *listbase, const void *vlink) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
#define LISTBASE_FOREACH(type, var, list)
MINLINE int max_ii(int a, int b)
MINLINE float len_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void sub_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void copy_v3_v3(float r[3], const float a[3])
MINLINE void madd_v3_v3v3fl(float r[3], const float a[3], const float b[3], float f)
MINLINE float normalize_v3(float n[3])
char * STRNCPY(char(&dst)[N], const char *src)
size_t BLI_str_escape(char *__restrict dst, const char *__restrict src, size_t dst_maxncpy) ATTR_NONNULL(1
#define STRNCPY_UTF8(dst, src)
#define BLI_STR_UTF8_MULTIPLICATION_SIGN
#define BLT_I18NCONTEXT_ID_ARMATURE
void DEG_id_tag_update(ID *id, unsigned int flags)
void DEG_relations_tag_update(Main *bmain)
#define ID_IS_LINKED(_id)
@ LIBOVERRIDE_OP_INSERT_AFTER
@ BONE_COLLECTION_VISIBLE
@ BONE_COLLECTION_ANCESTORS_VISIBLE
@ BONE_COLLECTION_EXPANDED
@ BONE_COLLECTION_OVERRIDE_LIBRARY_LOCAL
@ BONE_RELATIVE_PARENTING
@ ARM_DRAW_RELATION_FROM_HEAD
@ ARM_DRAW_TYPE_ARMATURE_DEFINED
@ BBONE_ADD_PARENT_END_ROLL
@ BBONE_HANDLE_SCALE_EASE
@ BONE_INHERIT_SCALE_FULL
@ BONE_INHERIT_SCALE_NONE
@ BONE_INHERIT_SCALE_FIX_SHEAR
@ BONE_INHERIT_SCALE_NONE_LEGACY
@ BONE_INHERIT_SCALE_ALIGNED
@ BONE_INHERIT_SCALE_AVERAGE
#define RNA_TRANSLATION_PREC_DEFAULT
@ PROPOVERRIDE_OVERRIDABLE_LIBRARY
@ PROPOVERRIDE_NO_COMPARISON
@ PROPOVERRIDE_LIBRARY_INSERTION
#define ND_BONE_COLLECTION
#define ND_SPACE_OUTLINER
EditBone * ED_armature_ebone_add(bArmature *arm, const char *name)
void ED_armature_transform(bArmature *arm, const float mat[4][4], const bool do_props)
void ED_armature_bone_rename(Main *bmain, bArmature *arm, const char *oldnamep, const char *newnamep)
void ED_armature_ebone_transform_mirror_update(bArmature *arm, EditBone *ebo, bool check_select)
void ED_armature_ebone_to_mat4(EditBone *ebone, float r_mat[4][4])
void ED_armature_ebone_remove(bArmature *arm, EditBone *exBone)
void ED_armature_ebone_from_mat4(EditBone *ebone, const float mat[4][4])
BMesh const char void * data
float length(VecOp< float, D >) RET
static void ANIM_armature_foreach_bone(ListBase *bones, CB callback)
int armature_bonecoll_child_number_find(const bArmature *armature, const ::BoneCollection *bcoll)
int armature_bonecoll_find_index(const bArmature *armature, const ::BoneCollection *bcoll)
bool armature_bonecoll_is_descendant_of(const bArmature *armature, int potential_parent_index, int potential_descendant_index)
int armature_bonecoll_find_parent_index(const bArmature *armature, int bcoll_index)
int armature_bonecoll_child_number_set(bArmature *armature, ::BoneCollection *bcoll, int new_child_number)
int armature_bonecoll_move_to_parent(bArmature *armature, int from_bcoll_index, int to_child_num, int from_parent_index, int to_parent_index)
const PointerRNA PointerRNA_NULL
void rna_iterator_listbase_begin(CollectionPropertyIterator *iter, PointerRNA *ptr, ListBase *lb, IteratorSkipFunc skip)
void RNA_property_update_main(Main *bmain, Scene *scene, PointerRNA *ptr, PropertyRNA *prop)
void rna_iterator_array_begin(CollectionPropertyIterator *iter, PointerRNA *ptr, void *data, size_t itemsize, int64_t length, bool free_ptr, IteratorSkipFunc skip)
void rna_pointer_create_with_ancestors(const PointerRNA &parent, StructRNA *type, void *data, PointerRNA &r_ptr)
PointerRNA RNA_pointer_create_discrete(ID *id, StructRNA *type, void *data)
PointerRNA RNA_pointer_create_with_parent(const PointerRNA &parent, StructRNA *type, void *data)
void rna_def_animdata_common(StructRNA *srna)
static void rna_def_armature_collections(BlenderRNA *brna, PropertyRNA *cprop)
static void rna_def_bone_collection_memberships(BlenderRNA *brna, PropertyRNA *cprop)
void RNA_def_armature(BlenderRNA *brna)
static void rna_def_bone(BlenderRNA *brna)
static void rna_def_bonecollection(BlenderRNA *brna)
const EnumPropertyItem rna_enum_color_palettes_items[]
#define RNA_DEF_CURVEBONE_UPDATE(prop, is_posebone, is_editbone)
static void rna_def_bone_common(StructRNA *srna, int editbone)
static void rna_def_edit_bone(BlenderRNA *brna)
static void rna_def_armature(BlenderRNA *brna)
static void rna_def_armature_edit_bones(BlenderRNA *brna, PropertyRNA *cprop)
void rna_def_bone_curved_common(StructRNA *srna, bool is_posebone, bool is_editbone)
static void rna_def_armature_bones(BlenderRNA *brna, PropertyRNA *cprop)
static void rna_def_bonecolor(BlenderRNA *brna)
void RNA_api_armature_edit_bone(StructRNA *srna)
void RNA_api_bone(StructRNA *srna)
void RNA_api_bonecollection(StructRNA *srna)
void RNA_def_property_boolean_sdna(PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit)
void RNA_def_struct_name_property(StructRNA *srna, PropertyRNA *prop)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_property_pointer_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_define_lib_overridable(const bool make_overridable)
void RNA_def_struct_path_func(StructRNA *srna, const char *path)
void RNA_def_struct_system_idprops_func(StructRNA *srna, const char *system_idproperties)
void RNA_def_parameter_clear_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void RNA_def_property_string_funcs(PropertyRNA *prop, const char *get, const char *length, const char *set)
void RNA_def_property_float_default(PropertyRNA *prop, float value)
void RNA_def_function_return(FunctionRNA *func, PropertyRNA *ret)
void RNA_def_property_float_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
void RNA_define_verify_sdna(bool verify)
void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description)
void RNA_def_property_string_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_ui_icon(PropertyRNA *prop, int icon, int consecutive)
void RNA_def_property_srna(PropertyRNA *prop, const char *type)
PropertyRNA * RNA_def_float_matrix(StructOrFunctionRNA *cont_, const char *identifier, const int rows, const int columns, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_def_property_collection_funcs(PropertyRNA *prop, const char *begin, const char *next, const char *end, const char *get, const char *length, const char *lookupint, const char *lookupstring, const char *assignint)
void RNA_def_struct_ui_text(StructRNA *srna, const char *name, const char *description)
const float rna_default_scale_3d[3]
void RNA_def_property_boolean_bitset_array_sdna(PropertyRNA *prop, const char *structname, const char *propname, const int64_t booleanbit, const int length)
void RNA_def_property_boolean_funcs(PropertyRNA *prop, const char *get, const char *set)
void RNA_def_property_multi_array(PropertyRNA *prop, int dimension, const int length[])
void RNA_def_property_enum_items(PropertyRNA *prop, const EnumPropertyItem *item)
void RNA_def_struct_sdna(StructRNA *srna, const char *structname)
FunctionRNA * RNA_def_function(StructRNA *srna, const char *identifier, const char *call)
void RNA_def_property_array(PropertyRNA *prop, int length)
void RNA_def_property_range(PropertyRNA *prop, double min, double max)
PropertyRNA * RNA_def_pointer(StructOrFunctionRNA *cont_, const char *identifier, const char *type, const char *ui_name, const char *ui_description)
void RNA_def_property_struct_type(PropertyRNA *prop, const char *type)
void RNA_def_property_collection_sdna(PropertyRNA *prop, const char *structname, const char *propname, const char *lengthpropname)
void RNA_def_function_ui_description(FunctionRNA *func, const char *description)
void RNA_def_property_update(PropertyRNA *prop, int noteflag, const char *func)
const int rna_matrix_dimsize_4x4[]
PropertyRNA * RNA_def_property(StructOrFunctionRNA *cont_, const char *identifier, int type, int subtype)
void RNA_def_property_enum_funcs(PropertyRNA *prop, const char *get, const char *set, const char *item)
void RNA_def_property_enum_bitflag_sdna(PropertyRNA *prop, const char *structname, const char *propname)
StructRNA * RNA_def_struct(BlenderRNA *brna, const char *identifier, const char *from)
void RNA_def_function_flag(FunctionRNA *func, int flag)
void RNA_def_property_clear_flag(PropertyRNA *prop, PropertyFlag flag)
void RNA_def_property_pointer_funcs(PropertyRNA *prop, const char *get, const char *set, const char *type_fn, const char *poll)
void RNA_def_property_enum_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_int_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
const int rna_matrix_dimsize_3x3[]
void RNA_def_struct_ui_icon(StructRNA *srna, int icon)
void RNA_def_struct_idprops_func(StructRNA *srna, const char *idproperties)
void RNA_def_property_override_funcs(PropertyRNA *prop, const char *diff, const char *store, const char *apply)
void RNA_def_property_translation_context(PropertyRNA *prop, const char *context)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
void RNA_def_property_float_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_ui_range(PropertyRNA *prop, double min, double max, double step, int precision)
void RNA_def_property_int_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_float_array_default(PropertyRNA *prop, const float *array)
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, const int default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
void RNA_def_property_boolean_negative_sdna(PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit)
void RNA_def_property_override_flag(PropertyRNA *prop, PropertyOverrideFlag flag)
void RNA_def_parameter_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
struct IDProperty * system_properties
IDProperty * system_properties
union CollectionPropertyIterator::@220100362304005352221007113371015217044252346141 internal
ListBaseIterator listbase
IDProperty * system_properties
IDOverrideLibraryPropertyOperation * liboverride_operation
int collection_root_count
struct BoneCollection ** collection_array
void WM_main_add_notifier(uint type, void *reference)