Constructor
new Circle(center, radius)
Creates a new Circle from a center Point2D and a radius.
Parameters:
Name | Type | Description |
---|---|---|
center | Point2D | The center point of the circle as a Point2D. |
radius | number | The radius of the circle. |
- Source
Classes
Members
arc
Creates an Arc from the circle.
- Source
center
Returns the center point of the circle as a Point2D.
- Source
radius
Returns the radius of the circle.
- Source
Methods
area() → {number}
Returns the area of the circle.
- Source
Returns:
The area of the circle.
- Type:
- number
circumference() → {number}
Returns the circumference of the circle.
- Source
Returns:
The circumference of the circle.
- Type:
- number
vector_object_builder(samplesopt) → {VectorObjectBuilder}
Creates a new VectorObjectBuilder from the circle.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
samples | number | | <optional> | The number of samples to use to create the circle, by default 15. |
- Source
Returns:
A VectorObjectBuilder representing the circle.
- Type:
- VectorObjectBuilder