-
-
Notifications
You must be signed in to change notification settings - Fork 21.6k
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
Custom Skeleton3DEditorPlugin #36409
Conversation
8e62e87
to
2cb436b
Compare
0f656a4
to
d2a866e
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.
@fire you did a really good job here, and this addition improves a lot the skeleton usability!
However, you can find some little tweaks that you can do to the code in order to improve it.
Another comment that I've is that there are too much hard written numbers that makes the code hard to read. See:
for (int i = 0; i < 12; i++) {
What 12 stands for? In these cases would be nice have something like:
const int spin_slider_count = 12;
for (int i = 0; i < spin_slider_count; i++) {
6b9a524
to
c4de366
Compare
Ready for second review. I didn't feel like figuring the math for iterating this and it's less clear with that math. transform_slider[0]->set_value(tform.get_basis()[Vector3::AXIS_X].x);
transform_slider[1]->set_value(tform.get_basis()[Vector3::AXIS_X].y);
transform_slider[2]->set_value(tform.get_basis()[Vector3::AXIS_X].z);
transform_slider[3]->set_value(tform.get_basis()[Vector3::AXIS_Y].x);
transform_slider[4]->set_value(tform.get_basis()[Vector3::AXIS_Y].y);
transform_slider[5]->set_value(tform.get_basis()[Vector3::AXIS_Y].z);
transform_slider[6]->set_value(tform.get_basis()[Vector3::AXIS_Z].x);
transform_slider[7]->set_value(tform.get_basis()[Vector3::AXIS_Z].y);
transform_slider[8]->set_value(tform.get_basis()[Vector3::AXIS_Z].z); |
Noticed that Bone Custom [Pose] is missing. |
c4de366
to
86e066b
Compare
You can use this one: const int matrix_row_count = 3;
const int matrix_column_count = 3;
for(int c = 0; c < matrix_column_count; c++){
for(int r = 0; r < matrix_row_count; r++){
transform_slider[(c*matrix_row_count) + r]->set_value(tform.get_basis()[c][r]);
}
} |
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.
The code looks better now, once fixed the above code it's good to be merged. However, I'm approving it now. Thanks :)
d3bdeb2
to
64f4eef
Compare
Merged AndreaCatania's suggestion, but currently testing a bug with the matrix step being "1". |
8237371
to
f4ea475
Compare
3bac5db
to
0aac719
Compare
Updated to master. Waiting on the build. |
0aac719
to
a920714
Compare
The spinners used in the inspector only allow integer values, they should have float values. I would also get rid of the custom grid of spinners and use the same inspector controls useed in Vector3 and Transform properties, but that could be done on a separate PR. |
Co-authored-by: Marios Staikopoulos <marios@staik.net>
a920714
to
f7fdc87
Compare
@JFonS I changed the default to Agreed, the matrix changes can be another pr. |
Thanks a lot! @fire Would you be able to prepare a PR backporting this for the |
Would be nice to have for 3.2 as skeleton editing is currently very hard with 175 bones |
Is it possible to use this on 3.2, and if so, how? I am trying to make a 3d game and it seems impossible if I can't access my rigged models. |
@slapin @keymastar 3.2 version is being worked on here: #39090 and not merged yet. |
That's great to hear. Thanks for letting me know. |
Thanks! Looking forward to it.
…On Thu, May 28, 2020 at 5:53 PM keymastar ***@***.***> wrote:
@slapin <https://github.com/slapin> @keymastar
<https://github.com/keymastar> 3.2 version is being worked on here: #39090
<#39090> and not merged yet.
That's great to hear. Thanks for letting me know.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#36409 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAABPU5BRDDPL3S4RDVROADRTZ3F3ANCNFSM4KY4OZDQ>
.
|
Removing |
I am not seeing the "Create physical skeleton" option anymore after this commit. The menu dropdown at the top seems to be missing. Was this intentional? |
Is not intentional. |
@fire commenting out options->hide() seemed to fix it https://github.com/godotengine/godot/blob/master/editor/plugins/skeleton_3d_editor_plugin.cpp#L668 |
@Sawrr Can you make a pull request, should be simple to test. |
I think there is still open issues regarding to the Skeleton 3D Editor. I am using a model with no more than 150 bones and every time that I make a left/right click in the skeleton node, Godot crashes. I have already tried using the DAE and the GLTF/GLB exports methods... but the result is the same. I was hopeful that this new release would fix it but no success :( . Context and Environment:MacBook Pro macOS Catalina 10.15.1 Is it a memory issue of my computer or is it a real bug? Btw, the animations and constraints using the bones works normally. It only crashes when selecting the skeleton node. Thanks in advance |
IIRC the 3.2 cherrypick hasn't happened yet, so it's on master only? |
Co-authored-by: Marios Staikopoulos marios@staik.net
Sponsored by IMVU.
Features:
Drag and drop skeleton parentage move with UNDO!
Rest and pose are exposed as transforms with degrees as units. [UPDATED]
Can key transforms into animation tracks.
Handles the other variables that represent a bone.
Ensure all used labels are translatable.
DOES NOT FREEZE THE EDITOR FOR 30 seconds swapping between the skeleton and any other node!!!
Use for testing:
https://github.com/KhronosGroup/glTF-Sample-Models/blob/master/2.0/Fox/glTF-Binary/Fox.glb
Bugsquad edit: Fixes #35652.