does Actor have specified anim?

Let me dissuade you from the mistaken belief that Panda is a commercial product with a team of active developers. It is not so. Panda is developed entirely by volunteers. There is a small bit of financial backing provided by Disney, and CMU keeps the lights on for this website, but for the most part we depend on our users to contribute code, the same as just about any other free product you’ll find out there.

As to extending or reimplenting Actor:

There are only a handful of classes that are involved in the lower-level implementation of Actor. You have PartBundle, which is the root of the model’s bone hierarchy, and AnimBundle, which is the root of a corresponding hierarchy of animation tables.

All you need to do is get the PartBundle for your model and bind it to the AnimBundle for your animation, using PartBundle.bindAnim(). The return value of this call is an AnimControl, which represents the bound animation. You can control the animation (play, stop, pose, whatever) with the AnimControl. If you drop the AnimControl and let it garbage collect normally, the animation is automatically unbound.

To get the PartBundle, you find the model’s Character node, which is the root node of the model you loaded from disk. Character inherits from PartBundleNode which provides an interface that allows you to query the PartBundle(s) within it. Usually there is exactly one PartBundle corresponding to a model.

To get the AnimBundle, you find the animation’s AnimBundleNode, which is the root node of the animation file you loaded from disk.

So: load a model, find its PartBundle, load an animation, find its AnimBundle, bind them, and save the resulting AnimControl. That’s all that really matters. Everything else that Actor does is just cruft.

David

1 Like