-
-
Notifications
You must be signed in to change notification settings - Fork 21.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for visualizing bones in Advanced Import Settings #78188
Add support for visualizing bones in Advanced Import Settings #78188
Conversation
@jeronimo-schreyer Did you forget to push local changes? This PR still has merge conflicts due to not being rebased yet. |
Can you merge into one commit? |
08996e2
to
7194323
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will probably be fine once the translation thing is addressed and the PR is rebased.
65219f4
to
189c1b3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM👍
Could you please amend your commit message to remove this part?
It's not relevant to the changes and doesn't need to be stored in the git history. |
Skeleton3D *skeleton = Object::cast_to<Skeleton3D>(p_node); | ||
if (skeleton) { | ||
bones_mesh_preview->set_mesh(Skeleton3DGizmoPlugin::get_bones_mesh(skeleton, -1, true)); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This relationship doesn't seem right to me. We shouldn't rely directly on plugin code here, that defeats the purpose of it being a plugin. We also can't use the same pattern going forward if we need to bring more viewport gizmos to the advanced import dialog preview.
I think it's time to integrate viewport/gizmo plugins into this preview, or alternatively devise a separate pluggable interface.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We talked about this at the animation asset meeting and we would like this change. Saracen has already approved the technical aspects.
I don't think this is such a big issue since it's a static function and both are in editor/ so there is no linking problem.
@AThousandShips would it be possible to review this usage of a plugin function from the import code and determine if this is ok?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll take a look :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think there's any issue with this, both are fully contained in the editor, and it saves a lot of code duplication, could theoretically move it to Skeleton3D or similar but it being a plugin here doesn't change anything in my opinion, as it's not a module or similar but fully integrated
189c1b3
to
72ee1f3
Compare
72ee1f3
to
3fa8d87
Compare
@jeronimo-schreyer do you think you will have time to resolve the pending review feedback? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like the skeleton should match the animations when they are being played back. It currently doesn't seem to do that when I tested it.
Maybe you should just take over. It would be really nice to have this done for 4.3 and we don't have much more time |
96a203f
to
c61708a
Compare
When an imported model Skeleton3D type node is selected, the bones are drawn using lines or octahedrons to provide a clearer reference to their position. Refactored Skeleton3DGizmoPlugin::redraw now uses a static function to generate bone meshes
c61708a
to
714527c
Compare
Superseded by #96094. |
When an imported model Skeleton3D type node is selected, the bones are drawn using lines or octahedrons to provide a clearer reference to their position. Refactored Skeleton3DGizmoPlugin::redraw now uses a static function to generate bone meshes
Update
editor/import/scene_import_settings.cpp
editor/import/scene_import_settings.h
editor/plugins/skeleton_3d_editor_plugin.h
editor/plugins/skeleton_3d_editor_plugin.cpp