-
-
Notifications
You must be signed in to change notification settings - Fork 97
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
Implement additive animation using a base pose in AnimationNodeAdd2 #2700
Comments
I would also like to add that the same thing be applied to AnimationNodeAdd3, since it would use the same framework. |
In I agree that removing the old Is |
@TokageItLab Your points are valid and the NodeSub2 idea is a good solution, especially since its easier to understand. It might be a bit harder to implement though, but I'm not 100% sure |
Should I update the proposal? |
We don't know yet how it will be implemented in fact. You have been able to tell us what you want to do, so I think if the substance doesn't change significantly, you don't have to update it. |
Isn't this fixed? |
The addition is now done correctly, but the extraction node is not yet implemented. Changed title. |
Well, I would guess from the original title that this can be closed. The blending is now calculated based on rest correctly, so the Additive Blend should work fine. |
Closed by godotengine/godot#57675 |
Can these animation fixes benefit 3.x also? |
Describe the project you are working on
3D project with animations
Describe the problem or limitation you are having in your project
The only method currently in Godot to mix animations is through
Blend
nodes (Blend2/3, BlendSpace1D/2D, Blendtree) andAdd
nodes (Add2/3). These two types of blending effectively do the same thing, as they use the same internal blend_input() function (see godotengine/godot#37661).A vital part of character locomotion nowadays is to include additive animations - namely, animations that are overlayed upon other animations to create various realistic effects eg. leaning/changing character stance etc.
godotengine/godot#42302 attempts to address this issue by exposing a 'add_directly' parameter, but
it's very limited and is unclear in functionality. This is because additive animation requires a base pose from which the animation offsets can be calculated - the additive data should be extracted RELATIVE to a base pose, and the pull request does not actually specify or allow you to change what base pose is being used.
Here is an example of how UE4 allows you to change the base pose from which animation offsets are calculated.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
My proposal is to remove the old functionality of Add2/3 since they effectively do the same thing as Blend2/3 albeit in a different format. I haven't seen anyone using Add over Blend since it's not really more useful, and its also harder to understand what it actually does (less straight forward than blending two anims).
Instead, Add2/3 should solely be used for additive animations and a new graph input should be exposed called 'base' which will be used to extrapolate additive offsets.
Example use case from Stride engine:
Leftmost animation = Walk animation
Rightmost animation = Idle animation
Two animations in the center = Walk and Idle animations with Reload animation added ontop
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
'in' is the input feed.
'add' is the additive animation that is overlayed on top of the input feed ('in')
'base' is the reference pose used to calculate the offset of 'add' to apply to 'in'
If this enhancement will not be used often, can it be worked around with a few lines of script?
Additive animation is used very often to create a variety of different movements with lesser amounts of animation clips. Also, AnimationNode behaviour can not be scripted outside of core.
Is there a reason why this should be core and not an add-on in the asset library?
There is no way to change functionality of AnimationNodes outside of core.
Additional references :
https://doc.stride3d.net/latest/jp/manual/animation/additive-animation.html - see "Difference Clips" section (basically Stride's way of saying additive animation)
https://docs.unrealengine.com/udk/Three/AdditiveAnimations.html
The text was updated successfully, but these errors were encountered: