AB4D Forum

Full Version: Triangulator
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,
Why triangulating this polygon throws an exception? Its shape seems to be valid.
Code:
List<Point> points = new List<Point>()
{
    new Point(6,2),
    new Point(3,4),
    new Point(0,2),
    new Point(1,0),
    new Point(3,2),
    new Point(5,0)
};
Ab3d.Utilities.Triangulator.Triangulate(points);
I agree - the shape is valid.

It looks like there is a problem in my implementation of the ear clipping algorithm. I will have to redesign it. Because this seems to be a more time consuming task, I currently do not have time to do it. I hope I will have more time in the following days.
Thanks for checking. Im looking forward to the solution.
I have improved the triangulation algorithm. I have send the pre-release version to LukaszW.

The official version with the improved triangulation will be published soon.