public void SetToUnitFrustum(bool withNear = true, bool withFar = true) { _planeList.Clear(); _planeList.Add(Plane.Create(1.0f, 0.0f, 0.0f, 1.0f)); // left plane. _planeList.Add(Plane.Create(-1.0f, 0.0f, 0.0f, 1.0f)); // right plane. _planeList.Add(Plane.Create(0.0f, 1.0f, 0.0f, 1.0f)); // bottom plane. _planeList.Add(Plane.Create(0.0f, -1.0f, 0.0f, 1.0f)); // top plane. if (withNear) { _planeList.Add(Plane.Create(0.0f, 0.0f, 1.0f, 1.0f)); // near plane } if (withFar) { _planeList.Add(Plane.Create(0.0f, 0.0f, -1.0f, 1.0f)); // far plane } }
public static void Clear() { PlaneList.Clear(); BoxList.Clear(); }