PixelLightAPI  .
Public Types | Public Member Functions
PLRenderer::AnimationInfo Class Reference

Animation information. More...

#include <AnimationInfo.h>

Inheritance diagram for PLRenderer::AnimationInfo:
Inheritance graph
[legend]

List of all members.

Public Types

enum  EFlags { Loop = 1<<0, PingPong = 1<<1 }
 Animation flags. More...

Public Member Functions

PLRENDERER_API AnimationInfo ()
 Constructor.
virtual PLRENDERER_API ~AnimationInfo ()
 Destructor.
PLCore::uint32 GetType () const
 Returns the type of the animation.
void SetType (PLCore::uint32 nType=0)
 Sets the animation type.
PLCore::uint32 GetStartFrame () const
 Returns the animation start frame.
PLRENDERER_API void SetStartFrame (PLCore::uint32 nStartFrame=0)
 Sets the animation start frame.
PLCore::uint32 GetEndFrame () const
 Returns the animation end frame.
PLRENDERER_API void SetEndFrame (PLCore::uint32 nEndFrame=0)
 Sets the animation end frame.
PLCore::uint32 GetNumOfFrames () const
 Returns the number of animation frames.
float GetSpeed () const
 Get the animation speed.
void SetSpeed (float fSpeed=24.0f)
 Set the animation speed.
PLCore::uint32 GetFlags () const
 Get the animation information flags.
void SetFlags (PLCore::uint32 nFlags=0)
 Sets the animation information flags.
AnimationFrameInfoGetFrameInfo (PLCore::uint32 nIndex=0) const
 Returns information about a frame.
AnimationEventManagerGetEventManager ()
 Returns the event manager.
const AnimationEventManagerGetEventManager () const
virtual PLRENDERER_API
AnimationInfo
operator= (const AnimationInfo &cSource)
 Copy operator.
virtual PLRENDERER_API
PLCore::String 
GetSourceName () const
 Get the animation source name.

Detailed Description

Animation information.


Member Enumeration Documentation

Animation flags.

Enumerator:
Loop 

Loop animation

PingPong 

Ping pong animation


Constructor & Destructor Documentation

Constructor.

virtual PLRENDERER_API PLRenderer::AnimationInfo::~AnimationInfo ( ) [virtual]

Destructor.


Member Function Documentation

PLCore::uint32 PLRenderer::AnimationInfo::GetType ( ) const [inline]

Returns the type of the animation.

Returns:
Animation type (for instance 0=skeleton 1=vertex)
void PLRenderer::AnimationInfo::SetType ( PLCore::uint32  nType = 0) [inline]

Sets the animation type.

Parameters:
[in]nTypeAnimation type (for instance 0=skeleton 1=vertex)
PLCore::uint32 PLRenderer::AnimationInfo::GetStartFrame ( ) const [inline]

Returns the animation start frame.

Returns:
Animation start frame
PLRENDERER_API void PLRenderer::AnimationInfo::SetStartFrame ( PLCore::uint32  nStartFrame = 0)

Sets the animation start frame.

Parameters:
[in]nStartFrameAnimation start frame
PLCore::uint32 PLRenderer::AnimationInfo::GetEndFrame ( ) const [inline]

Returns the animation end frame.

Returns:
Animation end frame
PLRENDERER_API void PLRenderer::AnimationInfo::SetEndFrame ( PLCore::uint32  nEndFrame = 0)

Sets the animation end frame.

Parameters:
[in]nEndFrameAnimation end frame
PLCore::uint32 PLRenderer::AnimationInfo::GetNumOfFrames ( ) const [inline]

Returns the number of animation frames.

Returns:
Number of animation frames (normally EndFrame-StartFrame+1)
float PLRenderer::AnimationInfo::GetSpeed ( ) const [inline]

Get the animation speed.

Returns:
Playback speed of the animation, if negative, the animation is played reversed
void PLRenderer::AnimationInfo::SetSpeed ( float  fSpeed = 24.0f) [inline]

Set the animation speed.

Parameters:
[in]fSpeedNew playback speed for the animation, if negative, the animation is played reversed
PLCore::uint32 PLRenderer::AnimationInfo::GetFlags ( ) const [inline]

Get the animation information flags.

Returns:
Animation information flags (see EFlags)
void PLRenderer::AnimationInfo::SetFlags ( PLCore::uint32  nFlags = 0) [inline]

Sets the animation information flags.

Parameters:
[in]nFlagsAnimation information flags (see EFlags)
AnimationFrameInfo * PLRenderer::AnimationInfo::GetFrameInfo ( PLCore::uint32  nIndex = 0) const [inline]

Returns information about a frame.

Parameters:
[in]nIndexIndex of the frame the information should be returned
Returns:
Frame information, a null pointer if there's an error

Returns the event manager.

Returns:
Event manager
virtual PLRENDERER_API AnimationInfo& PLRenderer::AnimationInfo::operator= ( const AnimationInfo cSource) [virtual]

Copy operator.

Parameters:
[in]cSourceSource to copy from
Note:
  • The animation name itself is copied but at the end a number is added because each animation name must be unique!
Returns:
Reference to this instance
virtual PLRENDERER_API PLCore::String PLRenderer::AnimationInfo::GetSourceName ( ) const [virtual]

Get the animation source name.

Returns:
Animation source name, empty on error
Note:
  • If this is a skeleton animation, the source name is the name of a skeleton. (SkeletonManager::Get(...))
  • If this is a vertex animation, the source name is the name of a morph target animation. (pMyMesh->GetMorphTargetAnimationManager().Get(...))

Reimplemented in PLMesh::MorphTargetAni, and PLMesh::Skeleton.


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


PixelLight PixelLight 0.9.11-R1
Copyright (C) 2002-2012 by The PixelLight Team
Last modified Thu Feb 23 2012 14:09:38
The content of this PixelLight document is published under the
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported