Guest User

Untitled

a guest
Jun 27th, 2015
349
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.52 KB | None | 0 0
  1. struct VertexData
  2. {
  3.     math::Vec3 position;
  4.     math::Vec3 color;
  5. };
  6.  
  7. class SpriteBatchRenderer
  8. {
  9. private:
  10.     GLuint VAO, VBO, IBO;
  11.     //GLchar flags;
  12.     ResourcesManager* resman;
  13.     Shader* shader;
  14.     VertexData* buffer_pointer = nullptr;
  15.     GLuint num_sprites;
  16.  
  17. public:
  18.     SpriteBatchRenderer();
  19.     GLboolean Init(ResourcesManager &res, char bits, GLuint max_sprites, Shader* override_shader = nullptr);
  20.  
  21.     GLvoid Begin();
  22.     GLvoid Submit(math::Vec3 &pos, math::Vec2 &dims, math::Vec3 &col);
  23.     GLvoid End();
  24.     GLvoid Render();
  25. };
Advertisement
Add Comment
Please, Sign In to add comment