Changeset View
Changeset View
Standalone View
Standalone View
source/blender/io/collada/SkinInfo.cpp
| Show First 20 Lines • Show All 208 Lines • ▼ Show 20 Lines | if (!BKE_object_is_child_recursive(ob_arm, ob)) { | ||||
| bc_set_parent(ob, ob_arm, C); | bc_set_parent(ob, ob_arm, C); | ||||
| } | } | ||||
| #else | #else | ||||
| Object workob; | Object workob; | ||||
| ob->parent = ob_arm; | ob->parent = ob_arm; | ||||
| ob->partype = PAROBJECT; | ob->partype = PAROBJECT; | ||||
| BKE_object_workob_calc_parent(scene, ob, &workob); | BKE_object_workob_calc_parent(scene, ob, &workob); | ||||
| invert_m4_m4(ob->parentinv, workob.obmat); | invert_m4_m4(ob->parentinv, workob.object_to_world); | ||||
| DEG_id_tag_update(&obn->id, ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY); | DEG_id_tag_update(&obn->id, ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY); | ||||
| #endif | #endif | ||||
| copy_m4_m4(ob->obmat, bind_shape_matrix); | copy_m4_m4(ob->object_to_world, bind_shape_matrix); | ||||
| BKE_object_apply_mat4(ob, ob->obmat, false, false); | BKE_object_apply_mat4(ob, ob->object_to_world, false, false); | ||||
| amd->deformflag = ARM_DEF_VGROUP; | amd->deformflag = ARM_DEF_VGROUP; | ||||
| /* create all vertex groups */ | /* create all vertex groups */ | ||||
| std::vector<JointData>::iterator it; | std::vector<JointData>::iterator it; | ||||
| int joint_index; | int joint_index; | ||||
| for (it = joint_data.begin(), joint_index = 0; it != joint_data.end(); it++, joint_index++) { | for (it = joint_data.begin(), joint_index = 0; it != joint_data.end(); it++, joint_index++) { | ||||
| const char *name = "Group"; | const char *name = "Group"; | ||||
| ▲ Show 20 Lines • Show All 99 Lines • Show Last 20 Lines | |||||