Skip to content
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 3D skeleton preview to Advanced Importer #96094

Merged

Conversation

SaracenOne
Copy link
Member

@SaracenOne SaracenOne commented Aug 26, 2024

This PR rebases and extends the earlier PR by @jeronimo-schreyer with the following additions:

  • Fixes the preview of skeletons becoming deformed and mangled when importing a skeleton with scaling.
  • Instead of retaining the preview of the skeleton when one is selected, when you select an animation there is now a dedicated button for making the skeleton visible when previewing animations.
    godot windows editor dev x86_64_TjzQlWaFUn
  • Factors the generation of the skeleton previews when calculating the scenes' overall bounding box.

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
@SaracenOne SaracenOne force-pushed the add_3d_skeleton_to_advanced_importer branch from 6de60e0 to f0f9a57 Compare August 27, 2024 01:10
Copy link
Member

@fire fire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks ok to me.

  • Did an online review
  • Did not compile godot engine
  • Did not run a test project

@fire fire requested a review from a team September 3, 2024 17:45
@fire
Copy link
Member

fire commented Sep 3, 2024

@jeronimo-schreyer Feel free to test if you want, since this is an updated version of your old pr.

editor/import/3d/scene_import_settings.h Outdated Show resolved Hide resolved
editor/import/3d/scene_import_settings.cpp Outdated Show resolved Hide resolved
editor/import/3d/scene_import_settings.cpp Outdated Show resolved Hide resolved
@jeronimo-schreyer
Copy link
Contributor

Sure, I can test on Windows 10 and Linux Manjaro 24. Also test changes proposed by @AThousandShips

Better size calculation in advanced importer preview.
Uses the skeleton mesh to calculate the scene's bounding box.
This improves some situations where a mesh instances' scale
does not match its visual representation when a skeleton
is applied.

Advanced importer skeletal preview UX improvement.
Make the visibility of the skeletal preview in the advanced importer
when selecting an animation dependent on a new dedicated toggle button
rather than carrying over whether a skeletal node was or was not previously
selected before selecting the animation.

Advanced importer skeletal preview fix.
Fixes the preview on scaled skeletons in the advanced importer by applying the node's scale
to the preview and generating a skin for it.
@SaracenOne SaracenOne force-pushed the add_3d_skeleton_to_advanced_importer branch from f0f9a57 to 6532eff Compare September 7, 2024 01:09
@SaracenOne
Copy link
Member Author

I've implemented @AThousandShips' changes, so this should be good to merge now unless anyone has any additional changes to request.

@fire
Copy link
Member

fire commented Sep 7, 2024

I reran the failed integration test job

@akien-mga akien-mga merged commit 82688e9 into godotengine:master Sep 8, 2024
21 checks passed
@akien-mga
Copy link
Member

Thanks!

@fire fire deleted the add_3d_skeleton_to_advanced_importer branch September 9, 2024 05:12
@akien-mga akien-mga changed the title Add 3D Skeleton Preview to Advanced Importer Add 3D skeleton preview to Advanced Importer Sep 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Show skeleton bones in the Advanced Import Settings preview
5 participants