[Overview][Types][Procedures and functions][Index] |
Gets an array of points for a polygon which approximates an ellipse in the specified rectangle.
Source position: graphmath.pp line 76
function EllipsePolygon( |
const aRect: TRect |
):TPointArray; |
aRect |
|
Rectangle instance with the bounds for an X- and Y-aligned ellipse. |
Array with the points for the polygon.
EllipsePolygon is a TPointArray function used to calculate the array of points which approximate an ellipse bounded by the rectangle specified in the ARect argument. In EllipsePolygon, the ellipse is aligned to X and Y axes in the rectangle. It calculates the center point, radii, and diameter for the ellipse using ARect as well as the minimum number of points needed such that the distance between the edges of the rectangle and the mathematical circle is less than the rounding error (0.5) and a smoother stepping value of 0.4. The points for the polygon are calculated and stored in the return value.
Added in LCL version 4.0.
Version 4.0 | Generated 2025-05-03 | Home |