warp.mesh_get_bvh#

warp.mesh_get_bvh(id: uint64) uint64#
  • Kernel

Return the identifier of a mesh’s internal BVH.

The returned id can be passed directly to the bvh_query_* builtins (bvh_query_aabb(), bvh_query_ray(), bvh_query_capsule(), bvh_query_sphere()) to run broad-phase bounding-volume queries against the mesh’s triangle BVH; the bound indices they return are triangle (face) indices. Works for all BVH backends (including "cubql"), since cuBQL meshes are converted to Warp’s native BVH layout.

Parameters:

id – The mesh identifier