public bool Includes( IBounds bounds ) { bool visible = false; foreach ( Plane plane in planes ) { if ( bounds.Intersects( plane ) != PlaneIntersectionType.Back ) { visible = true; break; } } return visible; }
public bool Includes(IBounds bounds) { bool visible = false; foreach (Plane plane in planes) { if (bounds.Intersects(plane) != PlaneIntersectionType.Back) { visible = true; break; } } return(visible); }
/// <summary> /// Determine if bounding box is contained by frustum /// </summary> /// <param name="box">Bounding box</param> /// <returns>Containment type</returns> public ContainmentType Contains(IBounds bounds) { bool flag = false; foreach (Plane plane in planes) { switch (bounds.Intersects(plane)) { case PlaneIntersectionType.Back: return(ContainmentType.Disjoint); case PlaneIntersectionType.Intersecting: { flag = true; break; } } } return(!flag ? ContainmentType.Contains : ContainmentType.Intersects); }
/// <summary> /// Determine if bounding box is contained by frustum /// </summary> /// <param name="box">Bounding box</param> /// <returns>Containment type</returns> public ContainmentType Contains( IBounds bounds ) { bool flag = false; foreach ( Plane plane in planes ) { switch ( bounds.Intersects( plane ) ) { case PlaneIntersectionType.Back: return ContainmentType.Disjoint; case PlaneIntersectionType.Intersecting: { flag = true; break; } } } return !flag ? ContainmentType.Contains : ContainmentType.Intersects; }