I am using the SFML library, which in its latest RC allows you to manipulate vertices and draw them like so :
// define a 100x100 square, red, with a 40x40 texture mapped on it
sf::Vertex vertices[] =
{
sf::Vertex(sf::Vector2f( 0, 0), sf::Color::White, sf::Vector2f( 0, 0)),
sf::Vertex(sf::Vector2f( 0, 100), sf::Color::White, sf::Vector2f( 0, 40)),
sf::Vertex(sf::Vector2f(100, 100), sf::Color::White, sf::Vector2f(40, 40)),
sf::Vertex(sf::Vector2f(100, 0), sf::Color::White, sf::Vector2f(40, 0))
};
Now my question is: what would be the best way to draw a curve / an angular sector?
The rendering process is calling OpenGL so you may be more familliar with it than SFML.
Basically is it possible to draw curves by not defining 1 point per pixel?
thanks
Without using OpenGL directly, no. But usually curves are made of a sequence of lines. Just calc points of your curve (no need to be one per pixel), and draw a line strip.