-
Notifications
You must be signed in to change notification settings - Fork 0
/
Window.h
34 lines (28 loc) · 718 Bytes
/
Window.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
//
// Created by Athos Innocenti on 30/10/2018.
//
#ifndef FLYJOYRIDE_WINDOW_H
#define FLYJOYRIDE_WINDOW_H
#include <SFML/Graphics.hpp>
class Window {
public:
Window();
Window(const std::string &title, const sf::Vector2u &size);
~Window();
void beginDraw();
void endDraw();
void update();
bool isDone() { return done; };
sf::RenderWindow *getRenderWindow();
sf::Vector2u getWindowSize();
void draw(sf::Drawable &drawable);
private:
void setup(const std::string &title, const sf::Vector2u &size);
void destroy();
void create();
sf::RenderWindow window;
sf::Vector2u windowSize;
std::string windowTitle;
bool done;
};
#endif //FLYJOYRIDE_WINDOW_H