It is often desirable to perform a search for objects in a scene. Specifically, it is useful to determine whether objects are located within a search area and / or to identify the nearest objects to a search point.
Ray tracing systems have capabilities that are nearly sufficient to perform such a search. For instance,
ray tracing systems build acceleration structures such as
bounding volume hierarchies (“BVHs”) that help to accelerate the evaluation of a
ray. These BVHs are also useful for performing object searches.
Ray tracing hardware includes functionality related to performing a
ray-box test, which can be adapted for searching whether an object is within a search area.
Ray tracing hardware also includes functionality related to instances. In ray tracing, instances are copies of geometry, with an instance transform (e.g., scale, shear, rotation) applied. As objects being searched for may be instances, the instance-related functionality is useful for object searching.