Fixed major bug in incident mesh triangulation code