public void CorrectThickness()
        {
            var source = TestData.GetBodyFromBRep(Path.Combine(_BasePath, "FindBiggestFace_Source.brep"));

            Assume.That(source?.GetBRep() != null);

            var slicer = new SliceByPlanes(source.GetBRep(), source.GetBRep().Faces()[0], 1);

            Assert.IsTrue(slicer.CreateSlices(true));
            Assert.AreEqual(1, slicer.Slices.Length);
            Assert.AreEqual(10.0, slicer.SliceThickness, 1e-10);
        }
        public void SliceRotated()
        {
            var source = TestData.GetBodyFromBRep(Path.Combine(_BasePath, "SliceRotated_Source.brep"));

            Assume.That(source?.GetBRep() != null);

            var slicer = new SliceByPlanes(source.GetBRep(), source.GetBRep().Faces()[4], 1);

            Assert.IsTrue(slicer.CreateSlices(true));
            Assert.AreEqual(1, slicer.Slices.Length);
            AssertHelper.IsSameModel2D(slicer.Slices[0].BRep, Path.Combine(_BasePath, "SliceRotated"));
        }
        public void UseFarthestOpFace()
        {
            var source = TestGeomGenerator.CreateImprint().Body;

            Assume.That(source?.GetBRep() != null);
            (source.Shape as Imprint).Depth = 10;

            var slicer = new SliceByPlanes(source.GetBRep(), source.GetBRep().Faces()[4], 1);

            Assert.IsTrue(slicer.CreateSlices(true));
            Assert.AreEqual(1, slicer.Slices.Length);
            Assert.AreEqual(15.0, slicer.SliceThickness, 1e-10);
        }
        public void TwoLayers()
        {
            var source = TestData.GetBodyFromBRep(Path.Combine(_BasePath, "TwoLayers_Source.brep"));

            Assume.That(source?.GetBRep() != null);

            var slicer = new SliceByPlanes(source.GetBRep(), source.GetBRep().Faces()[0], 2);

            Assert.IsTrue(slicer.CreateSlices(true));
            Assert.AreEqual(2, slicer.Slices.Length);
            AssertHelper.IsSameModel2D(slicer.Slices[0].BRep, Path.Combine(_BasePath, "TwoLayers1"));
            AssertHelper.IsSameModel2D(slicer.Slices[1].BRep, Path.Combine(_BasePath, "TwoLayers2"));
        }