Fermat
Classes | Public Types | Public Methods | List of all members
cugar::Bvh_sah_builder Class Reference

Detailed description

An SAH-based bvh builder for 3d bboxes

#include <bvh_sah_builder.h>

Classes

class  IndexSortPredicate
 
class  Predicate
 
struct  Stats
 

Public Types

typedef Vector3f vector_type
 
typedef Bbox3f bbox_type
 
typedef Bvh< 3u > bvh_type
 
typedef Bvh_node bvh_node_type
 

Public Methods

 Bvh_sah_builder ()
 constructor
 
void set_max_leaf_size (const uint32 max_leaf_size)
 set bvh parameters
 
void set_force_splitting (const bool flag)
 set force splitting
 
void set_force_alignment (const bool flag)
 set force 'max leaf size'-aligned splits
 
void set_single_axis_threshold (const uint32 v)
 set single axis test threshold
 
template<typename Iterator >
void build (Iterator begin, Iterator end, bvh_type *bvh, Stats *stats=NULL)
 
template<typename Iterator , typename CostIterator >
void build (Iterator begin, Iterator end, CostIterator cost_begin, bvh_type *bvh, Stats *stats=NULL)
 
uint32 index (const uint32 i) const
 remapped point index
 
template<typename Iterator >
void build (const Iterator begin, const Iterator end, bvh_type *bvh)
 

Member Function Documentation

◆ build() [1/2]

template<typename Iterator >
void cugar::Bvh_sah_builder::build ( Iterator  begin,
Iterator  end,
bvh_type bvh,
Stats stats = NULL 
)

build

Iterator is supposed to dereference to a Bbox3f

Parameters
beginfirst point
endlast point
bvhoutput bvh

◆ build() [2/2]

template<typename Iterator , typename CostIterator >
void cugar::Bvh_sah_builder::build ( Iterator  begin,
Iterator  end,
CostIterator  cost_begin,
bvh_type bvh,
Stats stats = NULL 
)

build

Iterator is supposed to dereference to a Bbox3f

Parameters
beginfirst point
endlast point
bvhoutput bvh

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