38 #ifndef FCL_BV_SPLITTER_H 39 #define FCL_BV_SPLITTER_H 64 template <
typename BV>
69 using S =
typename BV::S;
83 const BV& bv,
unsigned int* primitive_indices,
int num_primitives);
118 void computeRule_bvcenter(
119 const BV& bv,
unsigned int* primitive_indices,
int num_primitives);
123 void computeRule_mean(
124 const BV& bv,
unsigned int* primitive_indices,
int num_primitives);
128 void computeRule_median(
129 const BV& bv,
unsigned int* primitive_indices,
int num_primitives);
131 template <
typename,
typename>
134 template <
typename,
typename>
137 template <
typename,
typename>
140 template <
typename,
typename>
144 template <
typename S,
typename BV>
147 template <
typename S,
typename BV>
150 template <
typename S,
typename BV>
155 unsigned int* primitive_indices,
161 template <
typename S,
typename BV>
166 unsigned int* primitive_indices,
int split_axis
The axis based on which the split decision is made. For most BV, the axis is aligned with one of the ...
Base interface for BV splitting algorithm.
void computeSplitValue_mean(const BV &bv, Vector3< S > *vertices, Triangle *triangles, unsigned int *primitive_indices, int num_primitives, BVHModelType type, const Vector3< S > &split_vector, S &split_value)
BVHModelType
BVH model type.
SplitMethodType
Three types of split algorithms are provided in FCL as default.
void computeSplitValue_bvcenter(const BV &bv, S &split_value)
Vector3< S > * vertices
The mesh vertices or points handled by the splitter.
Eigen::Matrix< S, 3, 1 > Vector3
Triangle * tri_indices
The triangles handled by the splitter.
Triangle with 3 indices for points.
Vector3< S > split_vector
void computeSplitVector(const BV &bv, Vector3< S > &split_vector)
BVHModelType type
Whether the geometry is mesh or point cloud.
void computeSplitValue_median(const BV &bv, Vector3< S > *vertices, Triangle *triangles, unsigned int *primitive_indices, int num_primitives, BVHModelType type, const Vector3< S > &split_vector, S &split_value)
A class describing the split rule that splits each BV node.
S split_value
The split threshold, different primitives are splitted according whether their projection on the spli...
SplitMethodType split_method
The split algorithm used.