Skip to content

Commit

Permalink
Fix axis reset of unmapped bones on retargeting
Browse files Browse the repository at this point in the history
  • Loading branch information
ydeltastar committed May 4, 2024
1 parent 7ebc866 commit ffbc8f4
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions editor/import/3d/post_import_plugin_skeleton_rest_fixer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -472,13 +472,9 @@ void PostImportPluginSkeletonRestFixer::internal_process(InternalImportCategory
int prof_idx = profile->find_bone(src_bone_name);
if (prof_idx >= 0) {
tgt_rot = src_pg.inverse() * prof_skeleton->get_bone_global_rest(prof_idx).basis; // Mapped bone uses reference pose.
}
/*
// If there is rest-relative animation, this logic may be work fine, but currently not so...
} else {
// tgt_rot = src_pg.inverse() * old_skeleton_global_rest[src_idx].basis; // Non-Mapped bone keeps global rest.
tgt_rot = src_pg.inverse() * old_skeleton_global_rest[src_idx].basis; // Non-Mapped bone keeps global rest.
}
*/
}

if (src_skeleton->get_bone_parent(src_idx) >= 0) {
Expand Down

0 comments on commit ffbc8f4

Please sign in to comment.