Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <SFML/Window.hpp>
- int main() {
- // This window works.
- sf::Window window( sf::VideoMode( 800, 600 ), "Test", sf::Style::Default, sf::ContextSettings( 0, 0, 0, 4, 2 ) );
- // Display the window.
- window.display();
- // Let the window sit for a bit.
- sf::sleep( sf::seconds( 5 ) );
- // Close the window.
- window.close();
- // This window fails.
- window.create( sf::VideoMode( 800, 600 ), "Test", sf::Style::Default, sf::ContextSettings( 0, 0, 0, 4, 3 ) ); // Crashes on this line.
- // Display the window.
- window.display();
- // Let the window sit for a bit.
- sf::sleep( sf::seconds( 5 ) );
- // Close it.
- window.close();
- // Exit.
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement