Implementing Wolfire's Procedural Animation in Urho?

What’s the best way to blend between single animation keyframes with custom animation curves in Urho? I’m trying to implement the following technique: … e-Approach … ion-redux/

I’ve tried using single keyframes as separate states, but i wasn’t able to find a way to blend between them inside AnimationController using curves.

1 Like

You could try to extend AnimationController to allow using spline interpolation for the time/fading.
Also possible to make your own class for managing animations.

Relevant: … ation.html

I’m not sure if i follow. The attribute animation only allows me to apply Linear/Spline interpolated animation routines to objects which accept SetObjectAnimation. Does a bone accept that? Would it be a matter of SetObjectAnimation on each bone, following the position/rotation of the next pose?

Attribute animation can be used for attributes of anything that derives from Animatable.

Attributes list: … _list.html

It doesn’t seem AnimationController uses the time as an attribute. That means it will require either extending it or making custom animation controller.

Alternative approach would be to use Urho3D::Spline instead of attributes.

Bone data is not an attribute, so, that approach would not be possible. You will have to extend the animation controller and, for each bone, apply your custom interpolation routine between frames. How are your animations structured? Full rigid frames or different animations for each pose?

IMHO, different animations for each pose would be easier to blend. So you have one animation called “walking_pose1” and “walking_pose2” and you can interpolate, and call that “walking”.

You don’t need to do it per bone, you just need to control the weight of each animation.

Is there any documentation or example on how to switch blending modes between animation frames?

Could you elaborate what blend modes do you mean?

Could this be what you’re looking for?

bool AnimationController::SetBlendMode(const String& name, AnimationBlendMode mode)

Also, welcome the forums @burt! :confetti_ball:

Thank you! I’m not sure. AnimationBlendMode seems to only allow either Additive or Lerp. How can i customize how the frames are blended by using a ease-in/ease-out function and the time it should interpolate?

Imagine that I have just two frames, with very different poses: Legs together, legs apart. I want to customize how those two are blended to create a real time animation based on how fast the character is going, etc.


MotionWheel, does the surveyer’s wheel tracking. It’s fairly robust but be aware that it’s really only designed for 1 direction recording (it can do forward/back along the given axis, but it’s not well suited for that), so recording the 4 ground-plane directions requires 4 components.

Basically, component tracks the accumulated motion along a vector (dotted for accuracy) and provides a wheel with arbitrary ticks to facilitate intelligible fractions out of it and visual interpretation. Or just use it to record how long as something has been falling, do watch out for being sure to use Reset/Resize for teleport or changes in gait.

Working on a different controller that does the DOOM method with pie-slices and void-blend zones on the surface-plane.

Utilities for yanking keyframes out of animations. Pretty poorly tested (and edited immediately before being gist uploaded to strip out phases and morph tracks that don’t exist in master).

You can use a 3 key run animation Overgrowth style but then use a curve to select frame times to extract out a 30 key animation that has been sigmoid squashed or w/e (sample sigmoid/logit adjusted, but output linear).

More useful as a base.