4 ms·
Feels like PIDs are the wrong tool for this problem. Stuff to do with matching animations up to physics is usually better solved with inverse kinematics.
by bruce343434 3y ago
Feels like PIDs are the wrong tool for this problem. Stuff to do with matching animations up to physics is usually better solved with inverse kinematics.
- azeemba 3y agoWhat are you imagining in this situation? How would one use IK with a running animation? You could remove the root motion of the animation and control the position of runner in code. This would allow controlling the position/speed easily but to look natural you still have to tweak the animation speed dynamically. Just changing the foot position via IK would not be enough to make the animation look natural. So feels like you are still left with the original problem of tweaking the animation speed.
- turtledragonfly 3y agoNot the person you asked, but here's a video you might like: https://www.youtube.com/watch?v=LNidsMesxSE&t=268s https://www.youtube.com/watch?v=LNidsMesxSE&t=268s In that example, they do the character's physics first (just a ball), then match the animation to it. The animation speed is controlled by a "surveyor wheel" approach — go to to 336s in the video for that part. So, the animation speed is derived from the physics, rather than the physics speed being derived from the animation. I wouldn't call that "IK" exactly, which would be more for things like matching the foot to individual stair steps as the character walks up them, or such. But I suppose in a broader sense it is, since you're deciding on a physical goal a-priori, then forcing the animation to match that goal.
- azeemba 3y agoThanks for the link! The ideas are presented so well. Really a cool approach too
- oreally 3y agoMy understanding is PIDs are vastly preferred in situations where very often real world measurements have a degree of error in them. Like having the wheels of your car slip extra distance when you put your foot on the paddle for a specific amount of time. It's a feedback system of sorts. If there's no error in measurements, sure, a mix of IK and blending seems to be a lot easier to implement.