for (int i = 0; i < vertices.size() - 1; i++) {
t.set(vertices.get(i+1));
t.sub(vertices.get(i));
- if (t.lengthSquared() < 0.000001)
+ if (t.lengthSquared() < 0.0000001)
throw new IllegalArgumentException("vertices at index " + i + " are too close to each other");
}
int iv = c*resolution + s;
/*
- iv+1 ---- iv + resolution + 1
- | /|
- |/ |
+ iv+1 ---- iv + resolution + 1
+ | /|
+ |/ |
iv ---- iv + resolution
*/
if (s < resolution - 1) {