Example #1
0
        private static Bounds_d BoundsOfPair(ssBVHNode <GO> nodea, ssBVHNode <GO> nodeb)
        {
            Bounds_d box = nodea.Bounds;

            box.ExpandToFit(nodeb.Bounds);
            return(box);
        }
Example #2
0
        private void ExpandVolume(Bounds_d bounds)
        {
            Bounds_d oldBox = Bounds;

            Bounds.ExpandToFit(bounds);

            if (!oldBox.Equals(Bounds) && Parent != null)
            {
                Parent.ExpandVolume(Bounds);
            }
        }
Example #3
0
        private double SAofList(SSBVHNodeAdaptor <GO> nAda, List <GO> list)
        {
            Bounds_d box = nAda.GetObjectBounds(list[0]);

            for (int i = 1; i < list.Count - 1; i++)
            {
                box.ExpandToFit(nAda.GetObjectBounds(list[i]));
            }

            return(SA(ref box));
        }