i want to write a simple animation system based on key frames where this
Code: Select all
//pseudo code
struct PlatFormKeyframe
{
u32 time_slot; //at what time in the platforms local animation timeline this keyframe is
btTransform; //the transform at that time slot
}
something like this
Code: Select all
//pseudo
//2d matrices for ease of reading
matrix2 mat_keyframe1;
matrix2 mat_keyframe2;
mat_keyframe1 += mat_keyframe2;
//multiply each matrix element by the interpolation fraction e.g. 1/2, 1/4, 3/5 etc.
//get each component vector of the sum matrix and normalize it
also, i have bullet integrate with my project and i know bullet interpolates, but is there a easy way i could access those interpolation methods?
thank you
EDIT: after searching a bit it seems it should work alright. i already found someone else who uses this method.
here it is for anyone with a similar problem:
http://www.gamedev.net/topic/313474-mat ... rpolation/