Example #1
0
        // Make a tetrahedron without texture coordinates or smoothing.
        public static void AddTetrahedron(this MeshGeometry3D mesh, bool centered = true)
        {
            // Get the points.
            Point3D A, B, C, D;

            G3.TetrahedronPoints(out A, out B, out C, out D, centered);

            // Make the triangles.
            mesh.AddPolygon(A, B, C);
            mesh.AddPolygon(A, C, D);
            mesh.AddPolygon(A, D, B);
            mesh.AddPolygon(D, C, B);
        }
Example #2
0
        public static void VerifyTetrahedron()
        {
            // Get the points.
            Point3D A, B, C, D;

            G3.TetrahedronPoints(out A, out B, out C, out D, true);

            // Verify the points.
            G3.VerifyPoints(A, B, C, D);

            // Verify the triangles.
            G3.VerifyPolygon(A, B, C);
            G3.VerifyPolygon(A, C, D);
            G3.VerifyPolygon(A, D, B);
            G3.VerifyPolygon(D, C, B);
        }