Axis-Aligned Bounding Box
예제 #1
0
파일: AABB.cs 프로젝트: WCell/WCell-Terrain
 /// <summary>
 /// Checks if a Ray intersects an AABB.
 /// </summary>
 /// <param name="box">The AABB in question.</param>
 /// <param name="ray">The Ray in question.</param>
 /// <returns>True if the two intersect.</returns>
 public static bool Intersects(AABB box, Ray ray)
 {
     return box.Bounds.Intersects(ray) != null;
 }
예제 #2
0
파일: WMO.cs 프로젝트: WCell/WCell-Terrain
 public void CreateAABB(Vector3 min, Vector3 max)
 {
     AABB = new AABB(min, max);
 }
예제 #3
0
파일: AABB.cs 프로젝트: WCell/WCell-Terrain
 /// <summary>
 /// Checks if two AABBs intersect.
 /// </summary>
 /// <param name="box1">One AABB</param>
 /// <param name="box2">The other AABB</param>
 /// <returns>True if the two intersect.</returns>
 public static bool Intersects(AABB box1, AABB box2)
 {
     return true;
     //return box1.Bounds.Intersects(box2.Bounds);
 }