Hi, this is a little post to warn all can read it, about the ilogical way to think on the view frustum.
Suposse you have the bounding box (of an object to be rendered), your camera's frustum and you can calculate if a point is inside the camera's view frustum, then:
- A = All points of the bounding box are inside the frustum.
- B = Some part of the object are in the frustum and must be rendered.
- A-->B, that is, if all points are into the view frustum then the object if completely inside the frustum.
- The oposit of A-->B is not (no A -->no B). That is, if all points of the bounding box are outside the view frustum then the object is outside the view frustum. This is false.
The right oposite proposition for A-->B is "not (A-->B)" or "not (no A or B)" or "A and no B", and this a very different thing than the previous and erroneous definition.
Finally (thanks Brandon) the right to think to know when to draw a object because it is present in the camera view frustum is (or could be):
- If all points of the bounding box are inside the frustum, then the object is completely inside the frustum and must be render,
- if all points are outside by the left plane, or all points are outside by the right plane, etc, then the object is completely outside the frustum and must not be drawn.
- other cases, portions of the object intersects with the view frustum and can be drawn.