cocos2d-x  2.2
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
CCAnimationFrame Class Reference

CCAnimationFrame A frame of the animation. More...

#include <CCAnimation.h>

Inheritance diagram for CCAnimationFrame:
CCObject CCCopying

Public Member Functions

 CCAnimationFrame ()
virtual ~CCAnimationFrame ()
virtual CCObjectcopyWithZone (CCZone *pZone)
bool initWithSpriteFrame (CCSpriteFrame *spriteFrame, float delayUnits, CCDictionary *userInfo)
 initializes the animation frame with a spriteframe, number of delay units and a notification user info More...
 
virtual CCSpriteFramegetSpriteFrame (void)
 getSpriteFrame More...
 
virtual void setSpriteFrame (CCSpriteFrame *var)
 setSpriteFrame More...
 
virtual CCDictionarygetUserInfo (void)
 getUserInfo More...
 
virtual void setUserInfo (CCDictionary *var)
 setUserInfo More...
 
- Public Member Functions inherited from CCObject
 CCObject (void)
virtual ~CCObject (void)
void release (void)
void retain (void)
CCObjectautorelease (void)
CCObjectcopy (void)
bool isSingleReference (void) const
unsigned int retainCount (void) const
virtual bool isEqual (const CCObject *pObject)
virtual void acceptVisitor (CCDataVisitor &visitor)
virtual void update (float dt)

Protected Attributes

CCSpriteFramem_pSpriteFrame
 CCSpriteFrameName to be used. More...
 
float m_fDelayUnits
 how many units of time the frame takes More...
 
CCDictionarym_pUserInfo
 getDelayUnits More...
 
- Protected Attributes inherited from CCObject
unsigned int m_uReference
unsigned int m_uAutoReleaseCount

Additional Inherited Members

- Public Attributes inherited from CCObject
unsigned int m_uID
int m_nLuaID

Detailed Description

CCAnimationFrame A frame of the animation.

It contains information like:

  • sprite frame name
  • # of delay units.
  • offset
Since
v2.0

Constructor & Destructor Documentation

virtual ~CCAnimationFrame ( )
virtual

Member Function Documentation

virtual CCObject* copyWithZone ( CCZone pZone)
virtual

Reimplemented from CCCopying.

virtual CCSpriteFrame*
getSpriteFrame
( void  )
virtual

getSpriteFrame

virtual CCDictionary* getUserInfo ( void  )
virtual

getUserInfo

bool initWithSpriteFrame ( CCSpriteFrame spriteFrame,
float  delayUnits,
CCDictionary userInfo 
)

initializes the animation frame with a spriteframe, number of delay units and a notification user info

virtual void setSpriteFrame ( CCSpriteFrame var)
virtual

setSpriteFrame

virtual void setUserInfo ( CCDictionary var)
virtual

setUserInfo

Member Data Documentation

float m_fDelayUnits
protected

how many units of time the frame takes

CCSpriteFrame* m_pSpriteFrame
protected

CCSpriteFrameName to be used.

CCDictionary* m_pUserInfo
protected

getDelayUnits

setDelayUnits A CCAnimationFrameDisplayedNotification notification will be broadcast when the frame is displayed with this dictionary as UserInfo. If UserInfo is nil, then no notification will be broadcast.


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