Add mesh BVH.
PiperOrigin-RevId: 530559807 Change-Id: Ibdafae22c7c74d15d707f205be73e4a571a6ae10
This commit is contained in:
committed by
Copybara-Service
parent
49066e1794
commit
4c487e07ed
@@ -771,6 +771,8 @@ struct mjModel_ {
|
||||
int* mesh_vertnum; // number of vertices (nmesh x 1)
|
||||
int* mesh_faceadr; // first face address (nmesh x 1)
|
||||
int* mesh_facenum; // number of faces (nmesh x 1)
|
||||
int* mesh_bvhadr; // address of bvh root (nmesh x 1)
|
||||
int* mesh_bvhnum; // number of bvh (nmesh x 1)
|
||||
int* mesh_normaladr; // first normal address (nmesh x 1)
|
||||
int* mesh_normalnum; // number of normals (nmesh x 1)
|
||||
int* mesh_texcoordadr; // texcoord data address; -1: no texcoord (nmesh x 1)
|
||||
|
||||
@@ -123,6 +123,7 @@ typedef enum mjtVisFlag_ { // flags enabling model element visualization
|
||||
mjVIS_STATIC, // static bodies
|
||||
mjVIS_SKIN, // skin
|
||||
mjVIS_MIDPHASE, // mid-phase bounding volume hierarchy
|
||||
mjVIS_MESHBVH, // mesh bounding volume hierarchy
|
||||
|
||||
mjNVISFLAG // number of visualization flags
|
||||
} mjtVisFlag;
|
||||
|
||||
@@ -281,6 +281,8 @@
|
||||
X ( int, mesh_texcoordnum, nmesh, 1 ) \
|
||||
X ( int, mesh_faceadr, nmesh, 1 ) \
|
||||
X ( int, mesh_facenum, nmesh, 1 ) \
|
||||
X ( int, mesh_bvhadr, nmesh, 1 ) \
|
||||
X ( int, mesh_bvhnum, nmesh, 1 ) \
|
||||
XMJV( int, mesh_graphadr, nmesh, 1 ) \
|
||||
X ( float, mesh_vert, nmeshvert, 3 ) \
|
||||
X ( float, mesh_normal, nmeshnormal, 3 ) \
|
||||
|
||||
Reference in New Issue
Block a user