cocos2d-x  3.1rc0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
QuadCommand Class Reference

Command used to render one or more Quads. More...

#include <CCQuadCommand.h>

Inheritance diagram for QuadCommand:
RenderCommand

Public Member Functions

 QuadCommand ()
 ~QuadCommand ()
void init (float globalOrder, GLuint texutreID, GLProgramState *shader, BlendFunc blendType, V3F_C4B_T2F_Quad *quads, ssize_t quadCount, const Mat4 &mv)
 Initializes the command with a globalZOrder, a texture ID, a GLProgram, a blending function, a pointer to quads, quantity of quads, and the Model View transform to be used for the quads. More...
 
void useMaterial () const
uint32_t getMaterialID () const
GLuint getTextureID () const
V3F_C4B_T2F_QuadgetQuads () const
ssize_t getQuadCount () const
GLProgramStategetGLProgramState () const
BlendFunc getBlendType () const
const Mat4getModelView () const
- Public Member Functions inherited from RenderCommand
float getGlobalOrder () const
 Get Render Command Id. More...
 
Type getType () const
 Returns the Command type. More...
 

Static Public Attributes

static const int MATERIAL_ID_DO_NOT_BATCH = 0

Protected Member Functions

void generateMaterialID ()
- Protected Member Functions inherited from RenderCommand
 RenderCommand ()
virtual ~RenderCommand ()
void printID ()

Protected Attributes

uint32_t _materialID
GLuint _textureID
GLProgramState_glProgramState
BlendFunc _blendType
V3F_C4B_T2F_Quad_quads
ssize_t _quadsCount
Mat4 _mv
- Protected Attributes inherited from RenderCommand
Type _type
float _globalOrder

Additional Inherited Members

- Public Types inherited from RenderCommand
enum  Type {
  UNKNOWN_COMMAND, QUAD_COMMAND, CUSTOM_COMMAND, BATCH_COMMAND,
  GROUP_COMMAND, MESH_COMMAND
}
 

Detailed Description

Command used to render one or more Quads.

Constructor & Destructor Documentation

Member Function Documentation

void generateMaterialID ( )
protected
BlendFunc getBlendType ( ) const
inline
GLProgramState* getGLProgramState ( ) const
inline
uint32_t getMaterialID ( ) const
inline
const Mat4& getModelView ( ) const
inline
ssize_t getQuadCount ( ) const
inline
V3F_C4B_T2F_Quad* getQuads ( ) const
inline
GLuint getTextureID ( ) const
inline
void init ( float  globalOrder,
GLuint  texutreID,
GLProgramState shader,
BlendFunc  blendType,
V3F_C4B_T2F_Quad quads,
ssize_t  quadCount,
const Mat4 mv 
)

Initializes the command with a globalZOrder, a texture ID, a GLProgram, a blending function, a pointer to quads, quantity of quads, and the Model View transform to be used for the quads.

void useMaterial ( ) const

Member Data Documentation

BlendFunc _blendType
protected
GLProgramState* _glProgramState
protected
uint32_t _materialID
protected
Mat4 _mv
protected
V3F_C4B_T2F_Quad* _quads
protected
ssize_t _quadsCount
protected
GLuint _textureID
protected
const int MATERIAL_ID_DO_NOT_BATCH = 0
static

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