Esempio n. 1
0
        public CsgSolid Union(CsgSolid solid)
        {
            var a = new CsgNode(this);
            var b = new CsgNode(solid);

            a.ClipTo(b);
            b.ClipTo(a);
            b.Invert();
            b.ClipTo(a);
            b.Invert();
            a.Build(b.AllPolygons());
            return(new CsgSolid(a.AllPolygons()));
        }
Esempio n. 2
0
 public CsgNode(CsgSolid solid) : this()
 {
     Build(solid.Polygons.Select(x => x.Clone()).ToList());
 }