SFML window 1

SFML window

sf::RenderWindow window(sf::VideoMode(900,900),"My window");
//VideoMode is an object who tell to the window which size take

Here is what the above code is Doing:
1. We create a window object called window.
2. We pass two parameters to the constructor of the window object.
3. The first parameter is a sf::VideoMode object. This object holds information about the size of the window we want to open.
4. The second parameter is a string, this is the title of the window.
5. The window object is displayed on screen.

Similar Posts