ellipseEstimated function
List<PointD>
ellipseEstimated(
- double x,
- double y,
- DrawConfig config,
- EllipseParams ellipseParams,
Implementation
List<PointD> ellipseEstimated(
double x, double y, DrawConfig config, EllipseParams ellipseParams) {
final List<PointD> corePoints = [];
final double radOffset = config.offsetSymmetric(0.5) - pi / 2;
for (double angle = radOffset;
angle < (pi * 2 + radOffset - 0.01);
angle = angle + ellipseParams.increment!) {
final PointD p = PointD(
config.offsetSymmetric(1) + x + ellipseParams.rx! * cos(angle),
config.offsetSymmetric(1) + y + ellipseParams.ry! * sin(angle),
);
corePoints.add(p);
}
return corePoints;
}