Castlekeep
A isometric castle build simulator
 All Classes Namespaces
renderer.h
1 
22 #ifndef RENDERER_H
23 #define RENDERER_H
24 
25 #include "types.h"
26 #include "window.h"
27 
28 namespace CastleKeep
29 {
30  class Sprite;
31 
32  enum class RenderBackend
33  {
34  SDL2,
35  OPENGL,
36  OPENGLES
37  };
38 
39  struct RenderInfo
40  {
41 
42  };
43 
44  class Renderer
45  {
46  public:
47  Renderer(Window *window, Color background);
48  virtual ~Renderer();
49  virtual void render(const RenderInfo &info)=0;
50  virtual void renderSprite(const Sprite &sprite)=0;
51  virtual void renderSpriteArray(Sprite sprites[], int length)=0;
52  virtual void clearScreen()=0;
53  virtual Sprite* createSpriteFromPixelBuffer(uint8_t buffer);
54  private:
55  Window *_window;
56  Color _background;
57  };
58 
59 }
60 
61 #endif
Definition: renderer.h:44
Definition: types.h:29
Definition: sprite.h:27
Definition: renderer.h:39
Definition: window.h:29