OGRE-Next  3.0.0
Object-Oriented Graphics Rendering Engine
Animation

Classes

class  Ogre::AnimableObject
 Defines an interface to classes which have one or more AnimableValue instances to expose. More...
 
class  Ogre::AnimableValue
 Defines an object property which is animable, i.e. More...
 
class  Ogre::Bone
 Class representing a Bone in the join hierarchy of a skeleton. More...
 
struct  Ogre::BySkeletonDef
 
class  Ogre::SkeletonAnimation
 Represents the instance of a Skeletal animation based on its definition. More...
 
struct  Ogre::SkeletonAnimManager
 This is how the Skeleton system works in 2.0: There is one BoneMemoryManager per skeleton. More...
 
class  Ogre::SkeletonInstance
 Instance of a Skeleton, main external interface for retrieving bone positions and applying animations. More...
 
class  Ogre::SkeletonManager
 Handles the management of skeleton resources. More...
 
class  Ogre::TagPoint
 TagPoints are like SceneNodes, that can be children of a Bone. More...
 
class  Ogre::v1::Animation
 An animation sequence. More...
 
class  Ogre::v1::AnimationContainer
 An animation container interface, which allows generic access to sibling animations. More...
 
class  Ogre::v1::AnimationState
 Represents the state of an animation and the weight of its influence. More...
 
class  Ogre::v1::AnimationStateControllerValue
 ControllerValue wrapper class for AnimationState. More...
 
class  Ogre::v1::AnimationStateSet
 Class encapsulating a set of AnimationState objects. More...
 
class  Ogre::v1::AnimationTrack
 A 'track' in an animation sequence, i.e. More...
 
class  Ogre::v1::KeyFrame
 A key frame in an animation sequence defined by an AnimationTrack. More...
 
struct  Ogre::v1::LinkedSkeletonAnimationSource
 Link to another skeleton to share animations. More...
 
class  Ogre::v1::NodeAnimationTrack
 Specialised AnimationTrack for dealing with node transforms. More...
 
class  Ogre::v1::NumericAnimationTrack
 Specialised AnimationTrack for dealing with generic animable values. More...
 
class  Ogre::v1::NumericKeyFrame
 Specialised KeyFrame which stores any numeric value. More...
 
class  Ogre::v1::OldBone
 A bone in a skeleton. More...
 
class  Ogre::v1::OldNodeAnimationTrack
 Specialised AnimationTrack for dealing with node transforms. More...
 
class  Ogre::v1::OldSkeletonManager
 Handles the management of skeleton resources. More...
 
class  Ogre::v1::Pose
 A pose is a linked set of vertex offsets applying to one set of vertex data. More...
 
class  Ogre::v1::Skeleton
 A collection of OldBone objects used to animate a skinned mesh. More...
 
class  Ogre::v1::SkeletonSerializer
 Class for serialising skeleton data to/from an OGRE .skeleton file. More...
 
class  Ogre::v1::TagPoint
 A tagged point on a skeleton, which can be used to attach entities to on specific other entities. More...
 
class  Ogre::v1::TimeIndex
 Time index object used to search keyframe at the given position. More...
 
class  Ogre::v1::TransformKeyFrame
 Specialised KeyFrame which stores a full transform. More...
 
class  Ogre::v1::VertexAnimationTrack
 Specialised AnimationTrack for dealing with changing vertex position information. More...
 
class  Ogre::v1::VertexMorphKeyFrame
 Specialised KeyFrame which stores absolute vertex positions for a complete buffer, designed to be interpolated with other keys in the same track. More...
 
class  Ogre::v1::VertexPoseKeyFrame
 Specialised KeyFrame which references a Mesh::Pose at a certain influence level, which stores offsets for a subset of the vertices in a buffer to provide a blendable pose. More...
 
struct  Ogre::VertexBoneAssignment
 Records the assignment of a single vertex to a single bone with the corresponding weight. More...
 

Macros

#define OGRE_MAX_NUM_BONES   256
 

Typedefs

typedef MapIterator< AnimationStateMapOgre::v1::AnimationStateIterator
 
typedef map< String, AnimationState * >::type Ogre::v1::AnimationStateMap
 
typedef ConstMapIterator< AnimationStateMapOgre::v1::ConstAnimationStateIterator
 
typedef ConstVectorIterator< EnabledAnimationStateListOgre::v1::ConstEnabledAnimationStateIterator
 
typedef list< AnimationState * >::type Ogre::v1::EnabledAnimationStateList
 
typedef vector< Pose * >::type Ogre::v1::PoseList
 

Enumerations

enum  Ogre::v1::SkeletonAnimationBlendMode { Ogre::v1::ANIMBLEND_AVERAGE = 0 , Ogre::v1::ANIMBLEND_CUMULATIVE = 1 }
 
enum  Ogre::SkeletonChunkID {
  Ogre::SKELETON_HEADER = 0x1000 , Ogre::SKELETON_BLENDMODE = 0x1010 , Ogre::SKELETON_BONE = 0x2000 , Ogre::SKELETON_BONE_PARENT = 0x3000 ,
  Ogre::SKELETON_ANIMATION = 0x4000 , Ogre::SKELETON_ANIMATION_BASEINFO = 0x4010 , Ogre::SKELETON_ANIMATION_TRACK = 0x4100 , Ogre::SKELETON_ANIMATION_TRACK_KEYFRAME = 0x4110 ,
  Ogre::SKELETON_ANIMATION_LINK = 0x5000
}
 Definition of the OGRE .skeleton file format. More...
 
enum  Ogre::v1::VertexAnimationType { Ogre::v1::VAT_NONE = 0 , Ogre::v1::VAT_MORPH = 1 , Ogre::v1::VAT_POSE = 2 }
 Type of vertex animation. More...
 

Functions

bool Ogre::operator< (const VertexBoneAssignment &_l, uint32 _vertexIndex)
 
bool Ogre::operator< (uint32 _vertexIndex, const VertexBoneAssignment &_r)
 
bool Ogre::OrderSkeletonInstanceByMemory (const SkeletonInstance *_left, const SkeletonInstance *_right)
 

Detailed Description

Macro Definition Documentation

◆ OGRE_MAX_NUM_BONES

#define OGRE_MAX_NUM_BONES   256

Typedef Documentation

◆ AnimationStateIterator

◆ AnimationStateMap

◆ ConstAnimationStateIterator

◆ ConstEnabledAnimationStateIterator

◆ EnabledAnimationStateList

◆ PoseList

typedef vector<Pose *>::type Ogre::v1::PoseList

Enumeration Type Documentation

◆ SkeletonAnimationBlendMode

Enumerator
ANIMBLEND_AVERAGE 

Animations are applied by calculating a weighted average of all animations.

ANIMBLEND_CUMULATIVE 

Animations are applied by calculating a weighted cumulative total.

◆ SkeletonChunkID

Definition of the OGRE .skeleton file format.

.skeleton files are binary files (for read efficiency at runtime) and are arranged into chunks of data, very like 3D Studio's format. A chunk always consists of: unsigned short CHUNK_ID : one of the following chunk ids identifying the chunk unsigned long LENGTH : length of the chunk in bytes, including this header void* DATA : the data, which may contain other sub-chunks (various data types)

A .skeleton file contains both the definition of the Skeleton object and the animations it contains. It contains only a single skeleton but can contain multiple animations.

Enumerator
SKELETON_HEADER 
SKELETON_BLENDMODE 
SKELETON_BONE 
SKELETON_BONE_PARENT 
SKELETON_ANIMATION 
SKELETON_ANIMATION_BASEINFO 
SKELETON_ANIMATION_TRACK 
SKELETON_ANIMATION_TRACK_KEYFRAME 
SKELETON_ANIMATION_LINK 

◆ VertexAnimationType

Type of vertex animation.

Vertex animation comes in 2 types, morph and pose. The reason for the 2 types is that we have 2 different potential goals - to encapsulate a complete, flowing morph animation with multiple keyframes (a typical animation, but implemented by having snapshots of the vertex data at each keyframe), or to represent a single pose change, for example a facial expression. Whilst both could in fact be implemented using the same system, we choose to separate them since the requirements and limitations of each are quite different.

Morph animation is a simple approach where we have a whole series of snapshots of vertex data which must be interpolated, e.g. a running animation implemented as morph targets. Because this is based on simple snapshots, it's quite fast to use when animating an entire mesh because it's a simple linear change between keyframes. However, this simplistic approach does not support blending between multiple morph animations. If you need animation blending, you are advised to use skeletal animation for full-mesh animation, and pose animation for animation of subsets of meshes or where skeletal animation doesn't fit - for example facial animation. For animating in a vertex shader, morph animation is quite simple and just requires the 2 vertex buffers (one the original position buffer) of absolute position data, and an interpolation factor. Each track in a morph animation references a unique set of vertex data.
Pose animation is more complex. Like morph animation each track references a single unique set of vertex data, but unlike morph animation, each keyframe references 1 or more 'poses', each with an influence level. A pose is a series of offsets to the base vertex data, and may be sparse - ie it may not reference every vertex. Because they're offsets, they can be blended - both within a track and between animations. This set of features is very well suited to facial animation.
For example, let's say you modelled a face (one set of vertex data), and defined a set of poses which represented the various phonetic positions of the face. You could then define an animation called 'SayHello', containing a single track which referenced the face vertex data, and which included a series of keyframes, each of which referenced one or more of the facial positions at different influence levels - the combination of which over time made the face form the shapes required to say the word 'hello'. Since the poses are only stored once, but can be referenced may times in many animations, this is a very powerful way to build up a speech system.
The downside of pose animation is that it can be more difficult to set up. Also, since it uses more buffers (one for the base data, and one for each active pose), if you're animating in hardware using vertex shaders you need to keep an eye on how many poses you're blending at once. You define a maximum supported number in your vertex program definition, see the includes_pose_animation material script entry.
So, by partitioning the vertex animation approaches into 2, we keep the simple morph technique easy to use, whilst still allowing all the powerful techniques to be used. Note that morph animation cannot be blended with other types of vertex animation (pose animation or other morph animation); pose animation can be blended with other pose animation though, and both types can be combined with skeletal animation. Also note that all morph animation can be expressed as pose animation, but not vice versa.
Enumerator
VAT_NONE 

No animation.

VAT_MORPH 

Morph animation is made up of many interpolated snapshot keyframes.

VAT_POSE 

Pose animation is made up of a single delta pose keyframe.

Function Documentation

◆ operator<() [1/2]

bool Ogre::operator< ( const VertexBoneAssignment _l,
uint32  _vertexIndex 
)
inline

◆ operator<() [2/2]

bool Ogre::operator< ( uint32  _vertexIndex,
const VertexBoneAssignment _r 
)
inline

◆ OrderSkeletonInstanceByMemory()

bool Ogre::OrderSkeletonInstanceByMemory ( const SkeletonInstance _left,
const SkeletonInstance _right 
)
inline