5#ifndef NIRT_I_GUI_SPRITE_BANK_HPP_INCLUDED
6#define NIRT_I_GUI_SPRITE_BANK_HPP_INCLUDED
8#include <nirtcpp/core/engine/IReferenceCounted.hpp>
9#include <nirtcpp/core/engine/irrArray.hpp>
10#include <nirtcpp/core/engine/SColor.hpp>
11#include <nirtcpp/core/engine/rect.hpp>
57 Frames.push_back(firstFrame);
116 u32 starttime=0,
u32 currenttime=0,
117 bool loop=
true,
bool center=
false) = 0;
140 u32 starttime=0,
u32 currenttime=0,
141 bool loop=
true,
bool center=
false) = 0;
Base class of most objects of the Nirtcpp Engine.
Definition IReferenceCounted.hpp:46
Axis aligned bounding box in 3d dimensional space.
Definition aabbox3d.hpp:22
Sprite bank interface.
Definition IGUISpriteBank.hpp:71
virtual u32 getTextureCount() const =0
Returns the number of textures held by the sprite bank.
virtual void draw2DSprite(u32 index, const core::rect< s32 > &destRect, const core::rect< s32 > *clip=0, const video::SColor *const colors=0, u32 timeTicks=0, bool loop=true)=0
Draws a sprite in 2d with destination rectangle and colors.
virtual void clear()=0
Clears sprites, rectangles and textures.
virtual void addTexture(video::ITexture *texture)=0
Adds a texture to the sprite bank.
virtual void setTexture(u32 index, video::ITexture *texture)=0
Changes one of the textures in the sprite bank.
virtual void draw2DSprite(u32 index, const core::position2di &pos, const core::rect< s32 > *clip=0, const video::SColor &color=video::SColor(255, 255, 255, 255), u32 starttime=0, u32 currenttime=0, bool loop=true, bool center=false)=0
Draws a sprite in 2d with position and color.
virtual video::ITexture * getTexture(u32 index) const =0
Gets the texture with the specified index.
virtual core::array< SGUISprite > & getSprites()=0
Returns the array of animated sprites within the sprite bank.
virtual core::array< core::rect< s32 > > & getPositions()=0
Returns the list of rectangles held by the sprite bank.
virtual s32 addTextureAsSprite(video::ITexture *texture)=0
Add the texture and use it for a single non-animated sprite.
virtual void draw2DSpriteBatch(const core::array< u32 > &indices, const core::array< core::position2di > &pos, const core::rect< s32 > *clip=0, const video::SColor &color=video::SColor(255, 255, 255, 255), u32 starttime=0, u32 currenttime=0, bool loop=true, bool center=false)=0
Draws a sprite batch in 2d using an array of positions and a color.
A single sprite frame.
Definition IGUISpriteBank.hpp:27
u32 rectNumber
Index in IGUISpriteBank::getPositions()
Definition IGUISpriteBank.hpp:44
u32 textureNumber
Texture index in IGUISpriteBank.
Definition IGUISpriteBank.hpp:41
A sprite composed of several frames.
Definition IGUISpriteBank.hpp:50
Interface of a Video Driver dependent Texture.
Definition ITexture.hpp:186
Class representing a 32 bit ARGB color.
Definition SColor.hpp:317
As of Nirtcpp 1.6, position2d is a synonym for vector2d.
Definition vector3d.hpp:11
signed int s32
32 bit signed variable.
Definition irrTypes.hpp:72
unsigned int u32
32 bit unsigned variable.
Definition irrTypes.hpp:64