DHART
Loading...
Searching...
No Matches
nanort::TriangleMesh< T > Class Template Reference

#include <nanort.h>

+ Collaboration diagram for nanort::TriangleMesh< T >:

Public Member Functions

 TriangleMesh (const T *vertices, const unsigned int *faces, const size_t vertex_stride_bytes)
 
void BoundingBox (real3< T > *bmin, real3< T > *bmax, unsigned int prim_index) const
 Compute bounding box for prim_indexth triangle. This function is called for each primitive in BVH build. More...
 

Public Attributes

const T * vertices_
 
const unsigned int * faces_
 
const size_t vertex_stride_bytes_
 

Detailed Description

template<typename T = float>
class nanort::TriangleMesh< T >

Definition at line 931 of file nanort.h.

Constructor & Destructor Documentation

◆ TriangleMesh()

template<typename T = float>
nanort::TriangleMesh< T >::TriangleMesh ( const T *  vertices,
const unsigned int *  faces,
const size_t  vertex_stride_bytes 
)
inline

Definition at line 933 of file nanort.h.

Member Function Documentation

◆ BoundingBox()

template<typename T = float>
void nanort::TriangleMesh< T >::BoundingBox ( real3< T > *  bmin,
real3< T > *  bmax,
unsigned int  prim_index 
) const
inline

Compute bounding box for prim_indexth triangle. This function is called for each primitive in BVH build.

Definition at line 942 of file nanort.h.

References nanort::TriangleMesh< T >::faces_, nanort::get_vertex_addr(), nanort::TriangleMesh< T >::vertex_stride_bytes_, and nanort::TriangleMesh< T >::vertices_.

+ Here is the call graph for this function:

Member Data Documentation

◆ faces_

template<typename T = float>
const unsigned int* nanort::TriangleMesh< T >::faces_

Definition at line 967 of file nanort.h.

Referenced by nanort::TriangleMesh< T >::BoundingBox().

◆ vertex_stride_bytes_

template<typename T = float>
const size_t nanort::TriangleMesh< T >::vertex_stride_bytes_

Definition at line 968 of file nanort.h.

Referenced by nanort::TriangleMesh< T >::BoundingBox().

◆ vertices_

template<typename T = float>
const T* nanort::TriangleMesh< T >::vertices_

Definition at line 966 of file nanort.h.

Referenced by nanort::TriangleMesh< T >::BoundingBox().


The documentation for this class was generated from the following file: