The goal of view frustum culling is to be able to identify what is inside the frustum (totally or partially), and cull everything that is not inside. Only the stuff that is inside the frustum, even if only partially, is sent to the graphics hardware. This Process is not only working with meshes, but also wording with particles and lights.
Bounding Box
A bounding box will be generated during the loading process for each GameObject.
Obtain a light’s volume radius by solving the attenuation equation. However, this equation will never exactly reach the value zero, so there won’t be a solution. But solve it for a brightness value that is close to zero.
Demo
The frustum process will never be seen by player, however I created a test camera which can switch between default perspective and test perspective.
Implementation
Frustum culling process is only happening with the main camera. So I make it a component, which only need to be attached to camera object.
Assets
- Character and animation from mixamo.
- Model by SilverTm from UE4 Marketplace.