Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/object/object_data_transform.c
| Show First 20 Lines • Show All 119 Lines • ▼ Show 20 Lines | |||||
| { | { | ||||
| armature_coords_and_quats_get_recurse(&arm->bonebase, elem_array); | armature_coords_and_quats_get_recurse(&arm->bonebase, elem_array); | ||||
| } | } | ||||
| static const struct ElemData_Armature *armature_coords_and_quats_apply_with_mat4_recurse( | static const struct ElemData_Armature *armature_coords_and_quats_apply_with_mat4_recurse( | ||||
| ListBase *bone_base, const struct ElemData_Armature *elem_array, const float mat[4][4]) | ListBase *bone_base, const struct ElemData_Armature *elem_array, const float mat[4][4]) | ||||
| { | { | ||||
| const struct ElemData_Armature *elem = elem_array; | const struct ElemData_Armature *elem = elem_array; | ||||
| for (Bone *bone = bone_base->first; bone; bone = bone->next) { | LISTBASE_FOREACH (Bone *, bone, bone_base) { | ||||
| #define COPY_PTR(member) memcpy(bone->member, elem->member, sizeof(bone->member)) | #define COPY_PTR(member) memcpy(bone->member, elem->member, sizeof(bone->member)) | ||||
| #define COPY_VAL(member) memcpy(&bone->member, &elem->member, sizeof(bone->member)) | #define COPY_VAL(member) memcpy(&bone->member, &elem->member, sizeof(bone->member)) | ||||
| COPY_PTR(head); | COPY_PTR(head); | ||||
| COPY_PTR(tail); | COPY_PTR(tail); | ||||
| COPY_VAL(roll); | COPY_VAL(roll); | ||||
| COPY_PTR(arm_head); | COPY_PTR(arm_head); | ||||
| COPY_PTR(arm_tail); | COPY_PTR(arm_tail); | ||||
| ▲ Show 20 Lines • Show All 446 Lines • Show Last 20 Lines | |||||