Commit 9560fac9 authored by Jonas Johan Solsvik's avatar Jonas Johan Solsvik 🎮
Browse files

main.cpp / add window TODOs

parent 591ed0b9
......@@ -6,9 +6,18 @@
int main()
{
// # Create the main window and camera
sf::RenderWindow window(sf::VideoMode(800, 600), "Double trouble");
window.setFramerateLimit(90);
sf::View camera(sf::FloatRect(0, 0, 800, 600));
//
// ## TODO
// - [ ] Make framerate limit adjustable
// - [ ] Make video and camera size the same as hardware window size
// - [ ] Resize video and camera size when user resizes window.
//
const int WIDTH = 800;
const int HEIGHT = 600;
const int FRAMERATE_LIMIT = 90;
sf::RenderWindow window(sf::VideoMode(WIDTH, HEIGHT), "Double trouble");
window.setFramerateLimit(FRAMERATE_LIMIT);
sf::View camera(sf::FloatRect(0, 0, WIDTH, HEIGHT));
camera.setCenter(0, 0);
window.setView(camera);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment