Ported regular_points() to XS and renamed it to equally_spaced_points()

This commit is contained in:
Alessandro Ranellucci 2013-11-11 20:59:58 +01:00
parent 6bb425e88d
commit 885ab5844e
8 changed files with 45 additions and 34 deletions

View file

@ -53,6 +53,15 @@ Polygon::split_at_first_point() const
return this->split_at_index(0);
}
Points
Polygon::equally_spaced_points(double distance) const
{
Polyline* polyline = this->split_at_first_point();
Points pts = polyline->equally_spaced_points(distance);
delete polyline;
return pts;
}
double
Polygon::area() const
{