If registered, this is used as part of culling during rendering. This object is called before frustum culling occurs.

This interface extends IRefCountedObject. Your class must implement the functions in that interface also.

Implementation notes

  • IsThreadSafe should return whether this can be called from multiple threads safely. This is used to decide whether the culling can be parallelized for performance using ParallelFor.
  • Prepare is called up front before visibility checks are ran. If you return false from it, the custom visibility query is skipped.
  • IsVisible is called per object to check. The passed-in bounds can be used to determine the world location of what’s being checked.

In order for this query to anything very useful, you’ll likely need to add properties to it to store additional information. For example, storing the FSceneView from the CreateQuery function in ICustomCulling.

To register this with the rendering system, see example in ICustomCulling.