30 lines
405 B
C
30 lines
405 B
C
|
#ifndef WINDOW_H
|
||
|
#define WINDOW_H
|
||
|
|
||
|
#include <SDL2/SDL.h>
|
||
|
#include <string>
|
||
|
#include <functional>
|
||
|
|
||
|
class Window
|
||
|
{
|
||
|
private:
|
||
|
SDL_Window* win;
|
||
|
SDL_Renderer* ren;
|
||
|
SDL_Event* e;
|
||
|
|
||
|
bool Running;
|
||
|
|
||
|
public:
|
||
|
|
||
|
Window(std::string title, int width, int height);
|
||
|
virtual ~Window();
|
||
|
|
||
|
void Setup();
|
||
|
void Draw(std::function<bool(Window*)> f);
|
||
|
void Events();
|
||
|
|
||
|
SDL_Renderer* GetRenderer();
|
||
|
|
||
|
};
|
||
|
#endif /* WINDOW_H */
|