Beispiel #1
0
 public static bool CompareEqual(STLVertex v1, STLVertex v2, double tolerance = 0.0001)
 {
     //return Math.Sqrt(Math.Pow(v2.X - v1.X, 2) + Math.Pow(v2.Y - v1.Y, 2)) < tolerance;
     return(Math.Abs(v2.X - v1.X) < tolerance && Math.Abs(v2.Y - v1.Y) < tolerance);
 }
Beispiel #2
0
 public void PrintVertex(string tag, STLVertex vertex)
 {
     Console.WriteLine($"({vertex.Flag}){tag} X: {Math.Round(vertex.X, 4)}, Y: {Math.Round(vertex.Y, 4)}, Z: {Math.Round(vertex.Z, 4)}");
 }