Ejemplo n.º 1
0
        public void MidpointSphere2()
        {
            Mesh m = PrimitiveShapes.Sphere(2, subdivisionOperation: Mesh.SubdivideOperation.Midpoint);

            foreach (var e in m.HalfEdges)
            {
                Assert.IsNotNull(e.Face);
                Assert.IsNotNull(e.Next);
            }

            Assert.AreEqual(92, m.Vertices.Count());
            Assert.AreEqual(180, m.Faces.Count());
        }
Ejemplo n.º 2
0
        public void InternalFaceSphere2()
        {
            Mesh m = PrimitiveShapes.Sphere(2, subdivisionOperation: Mesh.SubdivideOperation.InternalFace);

            Assert.AreEqual(162, m.Vertices.Count());
            Assert.AreEqual(320, m.Faces.Count());
            Assert.AreEqual(960, m.HalfEdges.Count());

            foreach (var e in m.HalfEdges)
            {
                Assert.IsNotNull(e.Face);
                Assert.IsNotNull(e.Next);
            }
        }