output coordinates of path problems
Stefan Schuermans

Stefan Schuermans commited on 2013-07-06 11:23:02
Showing 1 changed files, with 6 additions and 0 deletions.

... ...
@@ -45,6 +45,9 @@ bool Polygons::addLayer(const Layer &layer, double eqDist)
45 45
     // check that path is closed
46 46
     if (!path->mPoints.front().equals(path->mPoints.back(), eqDist)) {
47 47
       std::cerr << "path not closed" << std::endl;
48
+      Path::Points::const_iterator pt;
49
+      for (pt = path->mPoints.begin(); pt != path->mPoints.end(); ++pt)
50
+        std::cerr << "  " << pt->mX << "," << pt->mY << std::endl;
48 51
       return false;
49 52
     }
50 53
     // create simple polygon from path
... ...
@@ -56,6 +59,9 @@ bool Polygons::addLayer(const Layer &layer, double eqDist)
56 59
     // check that polygon is simple
57 60
     if (!simple.is_simple()) {
58 61
       std::cerr << "path is not simple (maybe self-itersecting?)" << std::endl;
62
+      Path::Points::const_iterator pt;
63
+      for (pt = path->mPoints.begin(); pt != path->mPoints.end(); ++pt)
64
+        std::cerr << "  " << pt->mX << "," << pt->mY << std::endl;
59 65
       return false;
60 66
     }
61 67
     // ensure orientation is clockwise (must be the same for all polygons)
62 68