HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY > Struct Template Reference

#include <UT_BVHImpl.h>

Public Types

using FloatType = float
 
using BoxType = UT::Box< v4uf, NAXES >
 

Public Member Functions

template<typename TS >
SYS_FORCE_INLINE BVHQueryCone (const TS &p0, const TS &dir, const float angle, const POSITION_ARRAY &positions, const RADIUS_ARRAY &radii)
 
template<typename T >
SYS_FORCE_INLINEgetDistToSurface (const UT_FixedVector< T, NAXES > &point) const
 
template<typename T >
SYS_FORCE_INLINE bool sphereIntersects (const UT_FixedVector< T, NAXES > &center, const T rad) const
 
SYS_FORCE_INLINE bool isValid (uint tree_point_index) const
 
template<typename TS >
SYS_FORCE_INLINE float queryDistance2 (const TS &tree_point, const RADIUS_ARRAY &radii, uint index) const
 This must be the exact distance squared. More...
 
template<bool farthest>
SYS_FORCE_INLINE uint boxHitAndDist2 (const BoxType &boxes, const float max_dist_squared, const uint internal_node_num, v4uf &dist2) const
 

Public Attributes

const UT_FixedVector< float,
NAXES > 
myP0
 
const UT_FixedVector< float,
NAXES > 
myDir
 
const UT_FixedVector< v4uf, NAXES > myVP0
 
const POSITION_ARRAY & myPositions
 
const RADIUS_ARRAY & myRadii
 
const float myAngle
 
const float myCosAngle
 
const float mySinAngle
 

Static Public Attributes

static constexpr bool theAllPointsValid = false
 isValid() does need to be called, because theAllPointsValid is false (not every point is valid). More...
 

Detailed Description

template<uint NAXES, typename POSITION_ARRAY, typename RADIUS_ARRAY>
struct UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >

Definition at line 3397 of file UT_BVHImpl.h.

Member Typedef Documentation

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
using UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::BoxType = UT::Box<v4uf,NAXES>

Definition at line 3410 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
using UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::FloatType = float

Definition at line 3399 of file UT_BVHImpl.h.

Constructor & Destructor Documentation

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
template<typename TS >
SYS_FORCE_INLINE UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::BVHQueryCone ( const TS &  p0,
const TS &  dir,
const float  angle,
const POSITION_ARRAY &  positions,
const RADIUS_ARRAY &  radii 
)
inline

Definition at line 3414 of file UT_BVHImpl.h.

Member Function Documentation

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
template<bool farthest>
SYS_FORCE_INLINE uint UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::boxHitAndDist2 ( const BoxType boxes,
const float  max_dist_squared,
const uint  internal_node_num,
v4uf dist2 
) const
inline

The distance squared can be an underestimate, but not an overestimate, of the true distance squared. The reverse is the case if farthest is true. Also, if farthest is true, max_dist_squared is actually min_dist_squared.

Definition at line 3481 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
template<typename T >
SYS_FORCE_INLINE T UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::getDistToSurface ( const UT_FixedVector< T, NAXES > &  point) const
inline

Definition at line 3434 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
SYS_FORCE_INLINE bool UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::isValid ( uint  tree_point_index) const
inline

NOTE: This doesn't necessarily need to be const, for subclasses that have a limit on the number of invalid points hit before giving up, for example.

Definition at line 3455 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
template<typename TS >
SYS_FORCE_INLINE float UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::queryDistance2 ( const TS &  tree_point,
const RADIUS_ARRAY &  radii,
uint  index 
) const
inline

This must be the exact distance squared.

Definition at line 3464 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
template<typename T >
SYS_FORCE_INLINE bool UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::sphereIntersects ( const UT_FixedVector< T, NAXES > &  center,
const T  rad 
) const
inline

Definition at line 3447 of file UT_BVHImpl.h.

Member Data Documentation

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const float UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::myAngle

Definition at line 3406 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const float UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::myCosAngle

Definition at line 3406 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const UT_FixedVector<float,NAXES> UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::myDir

Definition at line 3402 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const UT_FixedVector<float,NAXES> UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::myP0

Definition at line 3401 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const POSITION_ARRAY& UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::myPositions

Definition at line 3404 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const RADIUS_ARRAY& UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::myRadii

Definition at line 3405 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const float UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::mySinAngle

Definition at line 3406 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
const UT_FixedVector<v4uf,NAXES> UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::myVP0

Definition at line 3403 of file UT_BVHImpl.h.

template<uint NAXES, typename POSITION_ARRAY , typename RADIUS_ARRAY >
constexpr bool UT::BVHQueryCone< NAXES, POSITION_ARRAY, RADIUS_ARRAY >::theAllPointsValid = false
static

isValid() does need to be called, because theAllPointsValid is false (not every point is valid).

Definition at line 3409 of file UT_BVHImpl.h.


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