dsfml.graphics.circleshape

This class inherits all the functions of $(TRANSFORMABLE_LINK) (position, rotation, scale, bounds, ...) as well as the functions of $(SHAPE_LINK) (outline, color, texture, ...).

Members

Classes

CircleShape
class CircleShape

Specialized shape representing a circle.

Examples

1 auto circle = new CircleShape();
2 circle.radius = 150;
3 circle.outlineColor = Color.Red;
4 circle.outlineThickness = 5;
5 circle.position = Vector2f(10, 20);
6 ...
7 window.draw(circle);

*$(PARA Since the graphics card can't draw perfect circles, we have to fake them with multiple triangles connected to each other. The "points count" property of $(U CircleShape) defines how many of these triangles to use, and therefore defines the quality of the circle.)

See Also

$(SHAPE_LINK), $(RECTANGLESHAPE_LINK), $(CONVEXSHAPE_LINK)

Meta