Towards Skeletal Animation Support

After reading a lot about the subject, I finally started my crusade to add skeletal animation support on Crimild. It’s going to be a behemoth task, so this will be the first post of many about the subject.

But before performing skeletal animations we need to have something to animate, right? The COLLADA file format specification seems to be the best choice once again. It successfully manages to store animated models with all of their complexities in a standard file format regardless of the tool used to create them.

Although Crimild’s COLLADA support was able to read static scenes, it turns out that rigged models (that is, models containing skeletal information) are stored in a different way. Then, my first task was to upgrade it in order to read the data in the correct fashion. I had to refactor a couple of methods in the importer in order to load both the skin (that is, the actual mesh) and the skeleton and a couple of hours later, the result looked at this:

A rigged model and its skeleton

The model is one of the many example files in the COLLADA Test Model Bank. In the image you can see the skin as well as several white lines that indicates the presence of a skeleton. Of course, the skeleton is drawn just for debugging purposes.

Here’s another model downloaded from 3DRT:

Another rigged model

One thing that keeps bothering me is that the COLLADA importer is getting bigger and bigger in each iteration, making it difficult to maintain (even for me). So I guess I’m gonna have to do some major code review there in the near future.

Stay tuned to know more about skeletal animation support in Crimild.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s