示例#1
0
        public bool Intersects(Bounds bounds)
        {
            //!!!!slowly

            var points = bounds.ToPoints();

            foreach (var plane in Planes)
            {
                bool allClipped = true;
                foreach (var p in points)
                {
                    if (plane.GetSide(p) == Plane.Side.Negative)
                    {
                        allClipped = false;
                        break;
                    }
                }
                if (allClipped)
                {
                    return(false);
                }
            }

            return(true);
        }