Base class for Other grid.
More...
#include <Grid.h>
Inherits Object.
Inherited by Grid3D, and TiledGrid3D.
|
virtual | ~GridBase () |
| Destructor.
|
|
virtual void | blit ()=0 |
| Interface used to blit the texture with grid to screen.
|
|
virtual void | reuse ()=0 |
| Interface, Reuse the grid vertices.
|
|
virtual void | calculateVertexPoints ()=0 |
| Interface, Calculate the vertices used for the blit.
|
|
int | getReuseGrid () const |
| Get number of times that the grid will be reused.
|
|
void | setReuseGrid (int reuseGrid) |
| Set number of times that the grid will be reused.
|
|
const Vec2 & | getGridSize () const |
| The size of the grid.
|
|
void | setGridSize (const Vec2 &gridSize) |
| Set the size of the grid.
|
|
const Vec2 & | getStep () const |
| Pixels between the grids.
|
|
void | setStep (const Vec2 &step) |
| Get the pixels between the grids.
|
|
bool | isTextureFlipped () const |
| is texture flipped.
|
|
void | setTextureFlipped (bool flipped) |
| Set the texture flipped or not.
|
|
void | set2DProjection () |
| Change projection to 2D for grabbing.
|
|
void | setGridRect (const Rect &rect) |
| Set the effect grid rect.
|
|
const Rect & | getGridRect () const |
| Get the effect grid rect.
|
|
|
virtual void | beforeBlit () |
|
|
bool | initWithSize (const Vec2 &gridSize) |
|
|
bool | isActive () const |
|
|
void | beforeDraw () |
|
void | retain () |
| Retains the ownership.
|
|
void | release () |
| Releases the ownership immediately.
|
|
Object * | autorelease () |
| Releases the ownership sometime soon automatically.
|
|
unsigned int | getReferenceCount () const |
| Returns the Object's current reference count.
|
|
virtual | ~Object () |
| Destructor.
|
|
|
unsigned int | _ID |
| object id, ScriptSupport need public _ID
|
|
int | _luaID |
| Lua reference id.
|
|
Base class for Other grid.
◆ ~GridBase()
Destructor.
@js NA @lua NA
◆ beforeBlit()
virtual void beforeBlit |
( |
| ) |
|
|
inlinevirtual |
Interface for custom action when before or after draw. @js NA
Reimplemented in Grid3D.
◆ initWithSize()
bool initWithSize |
( |
const Vec2 & | gridSize | ) |
|
Init the Grid base.
- Parameters
-
gridSize | the size of the grid. |
texture | The texture used for grab. |
flipped | whether or not the grab texture should be flip by Y or not. |
rect | The effective grid rect. |
◆ isActive()
Getter and setter of the active state of the grid.
◆ beforeDraw()
Init and reset the status when render effects by using the grid.
◆ setGridRect()
void setGridRect |
( |
const Rect & | rect | ) |
|
Set the effect grid rect.
- Parameters
-
rect | The effect grid rect. |
◆ getGridRect()
const Rect & getGridRect |
( |
| ) |
const |
|
inline |
Get the effect grid rect.
- Returns
- Return the effect grid rect.
The documentation for this class was generated from the following file: