What to do to efficiently use an external animation library?

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
eye776
Posts: 94
Joined: Sun Dec 28, 2008 11:07 pm

What to do to efficiently use an external animation library?

Post by eye776 »

I'm trying to cut as much as possible out of irrlicht's keyframe "animation pipeline", to remove overhead.

I'm using EJUOR_CONTROL to position bones with an external animation library.

Sorry, for stating questions in bold to attract attention.
Many people use the TL;DR way of reading. :D

Is this enough ?
1) Strip animation and
2) Call setRenderFromIdentity(true) for the scene node

This is how keyframes are stripped:

Code: Select all

ACTORTOOLDLL_API void ACTORTOOLDLL_CALLCONV EditStripAnimation()
	{
		if(__AT_CONTEXT->__AT_WORK_MESH == NULL)
			return;

		if(__AT_CONTEXT->__AT_WORK_MESH->getMeshType() == scene::EAMT_SKINNED)
		{
			core::array<scene::ISkinnedMesh::SJoint*> joints = 
				((scene::ISkinnedMesh*)__AT_CONTEXT->__AT_WORK_MESH)->getAllJoints();
			
			for(u32 i = 1; i < joints.size(); i++)
			{
				//Clear all joint animation keys - model takes less space on disk
				joints[i]->PositionKeys.clear();
				joints[i]->RotationKeys.clear();
				joints[i]->ScaleKeys.clear();
			}
		}
	}
Is there something else that can/ has to be done for better performance ?
Is this enough for using the same mesh with multiple scene nodes ?

EDIT: Well, nevermind, the question is badly written. I'll think it over and ask later.
Post Reply