public bool Contains(BB container, Vector2 contained)
 {
     Vector2 a, b, c, d;
     container.GetBounds(out a, out b, out c, out d);
     return (TestNormalCCW(ref d, ref c, ref contained)
         && TestNormalCCW(ref c, ref b, ref contained)
         && TestNormalCCW(ref b, ref a, ref contained)
         && TestNormalCCW(ref a, ref d, ref contained));
 }
Example #2
0
        public bool Contains(BB container, Vector2 contained)
        {
            Vector2 a, b, c, d;

            container.GetBounds(out a, out b, out c, out d);
            return(TestNormalCCW(ref d, ref c, ref contained) &&
                   TestNormalCCW(ref c, ref b, ref contained) &&
                   TestNormalCCW(ref b, ref a, ref contained) &&
                   TestNormalCCW(ref a, ref d, ref contained));
        }