A single instance of an SPA animation. It's instanced like this so that the same animation can be played back multiple times at once; the instance keeps track of which frame the animation is currently at.
Public Member Functions | |
| SPAInstance (SPA animation) | |
| Creates a new playable instance of the given SPA animation. You'll need to call Setup. More... | |
| SPAInstance (SPA animation, ShaderSet shaders) | |
| Creates a new playable instance of the given SPA animation using the given shader set. More... | |
| void | SetContext (Css.RenderableData context) |
| Sets the given context. Enables the node to receive events. More... | |
| void | dispatchEvent (string name) |
| Dispatches an event to the event receiver, if there is one. More... | |
| void | Setup () |
| Sets up this instance using the default shader set. Not lit by default. More... | |
| void | Setup (bool lit) |
| Sets up this instance using the default shader set. More... | |
| void | Setup (ShaderSet shaders) |
| Sets up this instance with a given shader set. More... | |
| void | Setup (Shader shader) |
| Sets this up with a particular shader. More... | |
| void | Update (float deltaTime) |
| Advances the animation. Different animations may be at different frame rates, so this regulates the frame rate too. More... | |
| void | Stop () |
| Stops this instance. If you continue to display it after this is called, the animation will appear frozen on the last frame. More... | |
Public Attributes | |
| bool | Done |
| True if the animation is over. More... | |
| int | AtFrame |
| Which frame ID we're up to in the current sprite. More... | |
| SPA | Animation |
| The animation this instance belongs to. More... | |
| bool | Loop =true |
| True if this animation should loop. More... | |
| int | OverallFrame |
| The frame ID in the overall animation. More... | |
| float | FrameDelay |
| How long to wait before advancing the frame, in seconds. More... | |
| float | CurrentDelay |
| How long we've waited so far since the frame was last advanced. More... | |
| float | Elapsed |
| The overall elapsed time. More... | |
| SPASprite | CurrentSprite |
| The current sprite we're using. Contains the graphic itself. More... | |
| Material | AnimatedMaterial |
| The material this instance is using. More... | |
| Dom.EventTarget | EventReceiver |
| A receiver for various events triggered by this SPA. More... | |
| SPAInstance | InstanceAfter |
| Currently playing instances are stored in a linked list. This is the instance in the list after this one. PowerUI.SPA.FirstInstance More... | |
| SPAInstance | InstanceBefore |
| Currently playing instances are stored in a linked list. This is theinstance in the list before this one. PowerUI.SPA.FirstInstance More... | |
Private Member Functions | |
| void | SetSprite (int index) |
| Sets the sprite with the given ID as the active one. More... | |
|
inline |
Creates a new playable instance of the given SPA animation. You'll need to call Setup.
Creates a new playable instance of the given SPA animation using the given shader set.
|
inline |
Dispatches an event to the event receiver, if there is one.
|
inline |
Sets the given context. Enables the node to receive events.
|
inlineprivate |
Sets the sprite with the given ID as the active one.
| index | The ID of the sprite. |
|
inline |
Sets up this instance using the default shader set. Not lit by default.
|
inline |
Sets up this instance using the default shader set.
|
inline |
Sets up this instance with a given shader set.
|
inline |
Sets this up with a particular shader.
|
inline |
Stops this instance. If you continue to display it after this is called, the animation will appear frozen on the last frame.
|
inline |
Advances the animation. Different animations may be at different frame rates, so this regulates the frame rate too.
| Material Spa.SPAInstance.AnimatedMaterial |
The material this instance is using.
| SPA Spa.SPAInstance.Animation |
The animation this instance belongs to.
| int Spa.SPAInstance.AtFrame |
Which frame ID we're up to in the current sprite.
| float Spa.SPAInstance.CurrentDelay |
How long we've waited so far since the frame was last advanced.
| SPASprite Spa.SPAInstance.CurrentSprite |
The current sprite we're using. Contains the graphic itself.
| bool Spa.SPAInstance.Done |
True if the animation is over.
| float Spa.SPAInstance.Elapsed |
The overall elapsed time.
| Dom.EventTarget Spa.SPAInstance.EventReceiver |
A receiver for various events triggered by this SPA.
| float Spa.SPAInstance.FrameDelay |
How long to wait before advancing the frame, in seconds.
| SPAInstance Spa.SPAInstance.InstanceAfter |
Currently playing instances are stored in a linked list. This is the instance in the list after this one. PowerUI.SPA.FirstInstance
| SPAInstance Spa.SPAInstance.InstanceBefore |
Currently playing instances are stored in a linked list. This is theinstance in the list before this one. PowerUI.SPA.FirstInstance
| bool Spa.SPAInstance.Loop =true |
True if this animation should loop.
| int Spa.SPAInstance.OverallFrame |
The frame ID in the overall animation.