Cafu Engine
CafuModelT::AnimT Struct Reference

This struct describes one animation sequence, e.g. "run", "walk", "jump", etc. More...

#include "Model_cmdl.hpp"

Classes

struct  AnimJointT
 
struct  FrameT
 A keyframe in the animation. More...
 

Public Member Functions

void RecomputeBB (unsigned int FrameNr, const ArrayT< JointT > &Joints, const ArrayT< MeshT > &Meshes)
 Recomputes the bounding-box for the specified frame in this animation sequence. More...
 
bool IsLastFrameDup () const
 Returns whether the first frame in the sequence is equal to the last. More...
 

Public Attributes

std::string Name
 Name of this animation sequence. More...
 
float FPS
 Playback rate for this animation sequence. More...
 
int Next
 The sequence that should play after this. Use "this" for looping sequences, -1 for none. More...
 
ArrayT< AnimJointTAnimJoints
 AnimJoints.Size() == m_Joints.Size() More...
 
ArrayT< FrameTFrames
 List of keyframes this animation consists of. More...
 

Detailed Description

This struct describes one animation sequence, e.g. "run", "walk", "jump", etc.

We use it to obtain an array of joints (ArrayT<JointT>, just like m_Joints) for any point (frame number) in the animation sequence.

Member Function Documentation

bool CafuModelT::AnimT::IsLastFrameDup ( ) const

Returns whether the first frame in the sequence is equal to the last.

The editor may use this to ask the user if he wishes to delete the last frame.

void CafuModelT::AnimT::RecomputeBB ( unsigned int  FrameNr,
const ArrayT< JointT > &  Joints,
const ArrayT< MeshT > &  Meshes 
)

Recomputes the bounding-box for the specified frame in this animation sequence.

Parameters
FrameNrThe number of the frame to recompute the bounding-box for.
JointsThe joints of the related model.
MeshesThe meshes of the related model.

Member Data Documentation

ArrayT<AnimJointT> CafuModelT::AnimT::AnimJoints

AnimJoints.Size() == m_Joints.Size()

float CafuModelT::AnimT::FPS

Playback rate for this animation sequence.

ArrayT<FrameT> CafuModelT::AnimT::Frames

List of keyframes this animation consists of.

std::string CafuModelT::AnimT::Name

Name of this animation sequence.

int CafuModelT::AnimT::Next

The sequence that should play after this. Use "this" for looping sequences, -1 for none.


The documentation for this struct was generated from the following files: