aboutsummaryrefslogtreecommitdiff
path: root/src/libjin/Graphics/je_sprite_sheet.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/libjin/Graphics/je_sprite_sheet.h')
-rw-r--r--src/libjin/Graphics/je_sprite_sheet.h44
1 files changed, 44 insertions, 0 deletions
diff --git a/src/libjin/Graphics/je_sprite_sheet.h b/src/libjin/Graphics/je_sprite_sheet.h
new file mode 100644
index 0000000..29f3a0e
--- /dev/null
+++ b/src/libjin/Graphics/je_sprite_sheet.h
@@ -0,0 +1,44 @@
+#ifndef __JE_SPRITE_SHEET_H
+#define __JE_SPRITE_SHEET_H
+
+#include <vector>
+
+#include "../math/je_quad.h"
+
+#include "je_sprite.h"
+
+namespace JinEngine
+{
+ namespace Graphics
+ {
+
+ class SpriteSheet
+ {
+ public:
+ ///
+ /// Create a new sprite in sheet.
+ ///
+ Sprite* createSprite(const Math::Quad& quad);
+
+ private:
+ class SpriteInSheet : public Sprite
+ {
+ public:
+
+ private:
+ ///
+ /// Quad in sprite sheet.
+ ///
+ Math::Quad quad;
+
+ };
+
+ std::vector<SpriteInSheet> mSprites;
+ Graphic* mGraphic;
+
+ };
+
+ } // namespace Graphics
+} // namespace JinEngine
+
+#endif \ No newline at end of file