Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - teunissenstefan

Pages: [1]
1
Graphics / Gradient Rectangle
« on: August 20, 2014, 09:26:04 pm »
I was searching for how to use gradient, then I found this: http://en.sfml-dev.org/forums/index.php?topic=6750.0
I tried the code that laurent provided but it doesn't work. No errors, just a black screen.
Pieces of code in question:
sf::Vertex backgroundgr[] =
        {
                sf::Vertex(sf::Vector2f(0, 0), sf::Color::Blue),
                sf::Vertex(sf::Vector2f(0, 1280), sf::Color::Blue),
                sf::Vertex(sf::Vector2f(720, 0), sf::Color::Cyan),
                sf::Vertex(sf::Vector2f(720, 1280), sf::Color::Cyan)
        };

m_window.draw(backgroundgr, 4, sf::Quads);
Now, I don't know if I'm using it wrong, or if it just doesn't work.  :-\

2
General / Switching 'scenes'
« on: August 17, 2014, 11:56:09 pm »
How do you switch 'scenes' in SFML? Example: From the menu to the game.
This is something that I have not seen anywhere :/

Pages: [1]