#include <lugre_spritelist.h>
Public Member Functions | |
| cSprite () | |
| void | Set (const float x, const float y, const float _w, const float _h, const Ogre::Vector2 &uv_0, const Ogre::Vector2 &uv_x, const Ogre::Vector2 &uv_y, const float z=0.0, const Ogre::ColourValue &vCol=Ogre::ColourValue::White) |
| void | Set (const float x, const float y, const float _w, const float _h, const Ogre::Vector2 &uv_0, const float uv_w, const float uv_h, const float z=0.0, const Ogre::ColourValue &vCol=Ogre::ColourValue::White) |
| simpler form without rotation | |
| void | SetCol (const Ogre::ColourValue &col) |
| void | WriteGeometry (cRobRenderOp &pGeometry, const bool bVertexCol) |
| bool | WriteGeometryClipped (cRobRenderOp &pGeometry, const bool bVertexCol, const Ogre::Rectangle &rClip) |
| returns false if sprite was skipped for being outside | |
Public Attributes | |
| Ogre::Vector3 | p |
| float | w |
| float | h |
| Ogre::Vector2 | mvTexCoord0 |
| Ogre::Vector2 | mvTexCoordX |
| right vector, might be used for rotated sprites | |
| Ogre::Vector2 | mvTexCoordY |
| Ogre::ColourValue | mvCol |
| only a single colour per sprite supported so far, as colour-transitions are tricky with clipping | |
Definition at line 196 of file lugre_spritelist.h.
| Lugre::cSpriteList::cSprite::cSprite | ( | ) | [inline] |
Definition at line 205 of file lugre_spritelist.h.
| void Lugre::cSpriteList::cSprite::Set | ( | const float | x, | |
| const float | y, | |||
| const float | _w, | |||
| const float | _h, | |||
| const Ogre::Vector2 & | uv_0, | |||
| const Ogre::Vector2 & | uv_x, | |||
| const Ogre::Vector2 & | uv_y, | |||
| const float | z = 0.0, |
|||
| const Ogre::ColourValue & | vCol = Ogre::ColourValue::White | |||
| ) | [inline] |
lt=left,top wh=width,height uv_0 : texcoords at left,top vertex uv_0+uv_x = texcoords at right,top vertex (two coordinates to allow rotation in atlas etc) uv_0+uv_y = texcoords at left,bottom vertex (two coordinates to allow rotation in atlas etc)
Definition at line 211 of file lugre_spritelist.h.
References h, mvCol, mvTexCoord0, mvTexCoordX, mvTexCoordY, p, and w.
Referenced by Set().
| void Lugre::cSpriteList::cSprite::Set | ( | const float | x, | |
| const float | y, | |||
| const float | _w, | |||
| const float | _h, | |||
| const Ogre::Vector2 & | uv_0, | |||
| const float | uv_w, | |||
| const float | uv_h, | |||
| const float | z = 0.0, |
|||
| const Ogre::ColourValue & | vCol = Ogre::ColourValue::White | |||
| ) | [inline] |
| void Lugre::cSpriteList::cSprite::SetCol | ( | const Ogre::ColourValue & | col | ) | [inline] |
| void Lugre::cSpriteList::cSprite::WriteGeometry | ( | cRobRenderOp & | pGeometry, | |
| const bool | bVertexCol | |||
| ) |
Definition at line 248 of file lugre_spritelist.cpp.
References SPRITE_VERTEX, and SPRITE_VERTEX_COL.
| bool Lugre::cSpriteList::cSprite::WriteGeometryClipped | ( | cRobRenderOp & | pGeometry, | |
| const bool | bVertexCol, | |||
| const Ogre::Rectangle & | rClip | |||
| ) |
returns false if sprite was skipped for being outside
Definition at line 262 of file lugre_spritelist.cpp.
References h, Lugre::mymax(), Lugre::mymin(), p, SPRITE_VERTEX, SPRITE_VERTEX_COL, and w.
| Ogre::Vector3 Lugre::cSpriteList::cSprite::p |
Definition at line 197 of file lugre_spritelist.h.
Referenced by Set(), Lugre::cSpriteList_L::SpriteList_SetSpritePos(), Lugre::cSpriteList::UpdateRelBounds(), and WriteGeometryClipped().
Definition at line 198 of file lugre_spritelist.h.
Referenced by Set(), Lugre::cSpriteList::UpdateRelBounds(), and WriteGeometryClipped().
Definition at line 199 of file lugre_spritelist.h.
Referenced by Set(), Lugre::cSpriteList::UpdateRelBounds(), and WriteGeometryClipped().
| Ogre::Vector2 Lugre::cSpriteList::cSprite::mvTexCoord0 |
| Ogre::Vector2 Lugre::cSpriteList::cSprite::mvTexCoordX |
right vector, might be used for rotated sprites
Definition at line 201 of file lugre_spritelist.h.
Referenced by Set().
| Ogre::Vector2 Lugre::cSpriteList::cSprite::mvTexCoordY |
| Ogre::ColourValue Lugre::cSpriteList::cSprite::mvCol |
only a single colour per sprite supported so far, as colour-transitions are tricky with clipping
Definition at line 203 of file lugre_spritelist.h.
1.5.6