1
Graphics / Re: Gradient Rectangle
« on: August 21, 2014, 06:02:12 pm »
Hmm okay so that alone works, but not if
And if I just put
sf::Vertex backgroundgr[4];
is set in header?And if I just put
sf::Vertex backgroundgr[4] =
{
sf::Vertex(sf::Vector2f(0, 0), sf::Color::Blue),
sf::Vertex(sf::Vector2f(0, 1280), sf::Color::Blue),
sf::Vertex(sf::Vector2f(720, 1280), sf::Color::Cyan),
sf::Vertex(sf::Vector2f(720, 0), sf::Color::Cyan),
};
in the .cpp it says: backgroundgr : undeclared identifier
{
sf::Vertex(sf::Vector2f(0, 0), sf::Color::Blue),
sf::Vertex(sf::Vector2f(0, 1280), sf::Color::Blue),
sf::Vertex(sf::Vector2f(720, 1280), sf::Color::Cyan),
sf::Vertex(sf::Vector2f(720, 0), sf::Color::Cyan),
};