In this code:
#include <SFML/Graphics.hpp>
int main()
{
sf::RenderWindow window{sf::VideoMode{300, 300}, "Window Title"};
sf::VertexArray points{sf::Points, 4};
// which two of these are the top left and bottom right corner
points[0].position = sf::Vector2f{0, 0};
points[1].position = sf::Vector2f{1, 1};
points[2].position = sf::Vector2f{299, 299};
points[3].position = sf::Vector2f{300, 300};
while (window.isOpen())
{
sf::Event event;
while (window.pollEvent(event))
if (event.type == sf::Event::Closed)
window.close();
window.clear(); window.draw(points); window.display();
}
}
What are the boundaries? 0-299 or 1-300 (width or height)? Also, the question in the comment.