]> gerrit.simantics Code Review - simantics/3d.git/blobdiff - org.simantics.g3d/src/org/simantics/g3d/shape/Tube.java
ArcCylinder with custom start angle
[simantics/3d.git] / org.simantics.g3d / src / org / simantics / g3d / shape / Tube.java
index 0300f068b601711001d5413e1fee21dd05a00902..6b1bf618b7533f8183aed58c4210b27278b4f790 100644 (file)
@@ -72,7 +72,7 @@ public class Tube {
                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");
                }
                
@@ -194,9 +194,9 @@ public class Tube {
                                int iv = c*resolution + s;
                                
                                /*
-                            iv+1 ---- iv + resolution + 1
-                                     | /|
-                                     |/ |
+                                iv+1 ---- iv + resolution + 1
+                                         | /|
+                                         |/ |
                                   iv ---- iv + resolution 
                                */
                                if (s < resolution - 1) {