-
-
Notifications
You must be signed in to change notification settings - Fork 21.8k
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
Fixed Pos/Rot/Scl 3D Tracks insertion in SkeletonEditor
#53885
Fixed Pos/Rot/Scl 3D Tracks insertion in SkeletonEditor
#53885
Conversation
2771ec1
to
5b417bc
Compare
5b417bc
to
a6d5662
Compare
a737906
to
32f62b7
Compare
@lyuma want to get rid the popup, so I'm working on changing UI to popup's toggle into the button above and moving rest option. Probably the method itself will not change significantly, so this can be reviewed at the same time. |
061da57
to
c1052f4
Compare
Okay, it seems to be organized. 2021-10-17.7.29.33-1.movThe reason there are two types of keying in 3DSkeleton is that, unlike 2DNodes, there are some cases where we need to avoid adding unnecessary tracks. For example, you basically don't want to insert tracks for hair or clothing bones controlled by spring bone addon, or for bones controlled by IK. Alternatively, it may be better to have the property of "keyable" on the bone itself, but for now, I am assuming the use case of generating all the bones at once, deleting the tracks that are not needed, and inserting keys only for the tracks that already exist. Also, rest options has been moved into skeleton options, if there are more options related to rest, consider moving to another location. |
db5547c
to
ebfa42f
Compare
Added some shortcuts. Key insertion defaults to the "Insert" key which same as in 2D, but no default shortcuts are assigned for Init-Pose and Pose-to-Rest others due to consider to conflicts. |
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.
Seems good overall to me.
Vector<int> Animation::find_tracks(const NodePath &p_path) const {
The only place I see this used is to search for a specific track by type (e.g. TYPE_ROTATION_3D
). Is there ever a case where you have multiple tracks with the same path and the same type?
Maybe find_track_with_type()
would be better?
@lyuma Make sense. The previous |
01f4f42
to
70fad87
Compare
Replaced all previous |
70fad87
to
74c2801
Compare
74c2801
to
653e2a5
Compare
Thanks! |
Fixed Pos/Rot/Scl 3D Tracks insertion in
SkeletonEditor
to be adopt #53689. Also, implemented to pop up a dialog when inserting multiple tracks withSkeletonEditor
.I also added
Animation::find_tracks()
, since we now have multiple (Pos/Rot/Scl) tracks with the same path name. However, now it coexists withAnimation::find_track()
, so if we are not considering performance, we may as well unifyAnimation::find_track()
intoAnimation::find_tracks()
for maintainability.By the way, anyone mentioned about the recording-mode in the 2D animation feature, but I think it can be added as another enhancement PR to apply it to 3D later.