PeriDyno 1.0.0
Loading...
Searching...
No Matches
dyno::SparseOctree< TDataType > Class Template Reference

#include <SparseOctree.h>

Public Types

typedef TDataType::Real Real
 
typedef TDataType::Coord Coord
 

Public Member Functions

 SparseOctree ()
 
 ~SparseOctree ()
 
void release ()
 Call release() to release allocated memory explicitly, do not call this function from the decontructor.
 
void setSpace (Coord lo, Real h, Real L)
 
void construct (const DArray< Coord > &points, Real radius)
 
void construct (const DArray< AABB > &aabb)
 
void construct (const DArray< OctreeNode > &nodes)
 
int getLevelMax ()
 
CPU_FUNC OctreeNode queryNode (Level l, OcIndex x, OcIndex y, OcIndex z)
 
GPU_FUNC Level requestLevelNumber (const AABB box)
 
GPU_FUNC int requestIntersectionNumber (const AABB box)
 
GPU_FUNC void reqeustIntersectionIds (int *ids, const AABB box)
 
GPU_FUNC int requestIntersectionNumberFromLevel (const AABB box, int level)
 
GPU_FUNC int requestIntersectionNumberFromLevel (const AABB box, AABB *data, int level)
 
GPU_FUNC void reqeustIntersectionIdsFromLevel (int *ids, const AABB box, int level)
 
GPU_FUNC void reqeustIntersectionIdsFromLevel (int *ids, const AABB box, AABB *data, int level)
 
GPU_FUNC int requestIntersectionNumberFromBottom (const AABB box)
 
GPU_FUNC void reqeustIntersectionIdsFromBottom (int *ids, const AABB box)
 
GPU_FUNC int requestIntersectionNumberFromBottom (const AABB box, AABB *data)
 
GPU_FUNC void reqeustIntersectionIdsFromBottom (int *ids, const AABB box, AABB *data)
 
void printAllNodes ()
 
void printPostOrderedTree ()
 

Private Member Functions

GPU_FUNC int requestIntersectionNumber (const OcKey key, const Level l)
 
GPU_FUNC int requestIntersectionNumber (const OcKey key, const Level l, const AABB box, AABB *data)
 
GPU_FUNC void reqeustIntersectionIds (int *ids, int &shift, const OcKey key, const Level l)
 
GPU_FUNC void reqeustIntersectionIds (int *ids, int &shift, const OcKey key, const Level l, const AABB box, AABB *data)
 

Private Attributes

int m_level_max
 levels are numbered from 0 to m_level_max;
 
Real m_h
 
Real m_L
 
Coord m_lo
 
DArray< OctreeNodem_all_nodes
 
DArray< OctreeNodem_post_ordered_nodes
 
DArray< int > data_count
 
DArray< int > duplicates_count
 
DArray< int > node_count
 
DArray< OctreeNodeaux_nodes
 
DArray< OctreeNodenode_buffer
 
DArray< OctreeNodenonRepeatNodes_cpy
 

Detailed Description

template<typename TDataType>
class dyno::SparseOctree< TDataType >

Definition at line 110 of file SparseOctree.h.

Member Typedef Documentation

◆ Coord

template<typename TDataType>
typedef TDataType::Coord dyno::SparseOctree< TDataType >::Coord

Definition at line 114 of file SparseOctree.h.

◆ Real

template<typename TDataType>
typedef TDataType::Real dyno::SparseOctree< TDataType >::Real

Definition at line 113 of file SparseOctree.h.

Constructor & Destructor Documentation

◆ SparseOctree()

template<typename TDataType>
dyno::SparseOctree< TDataType >::SparseOctree ( )

◆ ~SparseOctree()

template<typename TDataType>
dyno::SparseOctree< TDataType >::~SparseOctree ( )

Member Function Documentation

◆ construct() [1/3]

template<typename TDataType>
void dyno::SparseOctree< TDataType >::construct ( const DArray< AABB > & aabb)

◆ construct() [2/3]

template<typename TDataType>
void dyno::SparseOctree< TDataType >::construct ( const DArray< Coord > & points,
Real radius )

◆ construct() [3/3]

template<typename TDataType>
void dyno::SparseOctree< TDataType >::construct ( const DArray< OctreeNode > & nodes)

◆ getLevelMax()

template<typename TDataType>
int dyno::SparseOctree< TDataType >::getLevelMax ( )
inline

Definition at line 132 of file SparseOctree.h.

◆ printAllNodes()

template<typename TDataType>
void dyno::SparseOctree< TDataType >::printAllNodes ( )

◆ printPostOrderedTree()

template<typename TDataType>
void dyno::SparseOctree< TDataType >::printPostOrderedTree ( )

◆ queryNode()

template<typename TDataType>
CPU_FUNC OctreeNode dyno::SparseOctree< TDataType >::queryNode ( Level l,
OcIndex x,
OcIndex y,
OcIndex z )

◆ release()

template<typename TDataType>
void dyno::SparseOctree< TDataType >::release ( )

Call release() to release allocated memory explicitly, do not call this function from the decontructor.

◆ reqeustIntersectionIds() [1/3]

template<typename TDataType>
GPU_FUNC void dyno::SparseOctree< TDataType >::reqeustIntersectionIds ( int * ids,
const AABB box )

◆ reqeustIntersectionIds() [2/3]

template<typename TDataType>
GPU_FUNC void dyno::SparseOctree< TDataType >::reqeustIntersectionIds ( int * ids,
int & shift,
const OcKey key,
const Level l )
private

◆ reqeustIntersectionIds() [3/3]

template<typename TDataType>
GPU_FUNC void dyno::SparseOctree< TDataType >::reqeustIntersectionIds ( int * ids,
int & shift,
const OcKey key,
const Level l,
const AABB box,
AABB * data )
private

◆ reqeustIntersectionIdsFromBottom() [1/2]

template<typename TDataType>
GPU_FUNC void dyno::SparseOctree< TDataType >::reqeustIntersectionIdsFromBottom ( int * ids,
const AABB box )

◆ reqeustIntersectionIdsFromBottom() [2/2]

template<typename TDataType>
GPU_FUNC void dyno::SparseOctree< TDataType >::reqeustIntersectionIdsFromBottom ( int * ids,
const AABB box,
AABB * data )

◆ reqeustIntersectionIdsFromLevel() [1/2]

template<typename TDataType>
GPU_FUNC void dyno::SparseOctree< TDataType >::reqeustIntersectionIdsFromLevel ( int * ids,
const AABB box,
AABB * data,
int level )

◆ reqeustIntersectionIdsFromLevel() [2/2]

template<typename TDataType>
GPU_FUNC void dyno::SparseOctree< TDataType >::reqeustIntersectionIdsFromLevel ( int * ids,
const AABB box,
int level )

◆ requestIntersectionNumber() [1/3]

template<typename TDataType>
GPU_FUNC int dyno::SparseOctree< TDataType >::requestIntersectionNumber ( const AABB box)

◆ requestIntersectionNumber() [2/3]

template<typename TDataType>
GPU_FUNC int dyno::SparseOctree< TDataType >::requestIntersectionNumber ( const OcKey key,
const Level l )
private

◆ requestIntersectionNumber() [3/3]

template<typename TDataType>
GPU_FUNC int dyno::SparseOctree< TDataType >::requestIntersectionNumber ( const OcKey key,
const Level l,
const AABB box,
AABB * data )
private

◆ requestIntersectionNumberFromBottom() [1/2]

template<typename TDataType>
GPU_FUNC int dyno::SparseOctree< TDataType >::requestIntersectionNumberFromBottom ( const AABB box)

◆ requestIntersectionNumberFromBottom() [2/2]

template<typename TDataType>
GPU_FUNC int dyno::SparseOctree< TDataType >::requestIntersectionNumberFromBottom ( const AABB box,
AABB * data )

◆ requestIntersectionNumberFromLevel() [1/2]

template<typename TDataType>
GPU_FUNC int dyno::SparseOctree< TDataType >::requestIntersectionNumberFromLevel ( const AABB box,
AABB * data,
int level )

◆ requestIntersectionNumberFromLevel() [2/2]

template<typename TDataType>
GPU_FUNC int dyno::SparseOctree< TDataType >::requestIntersectionNumberFromLevel ( const AABB box,
int level )

◆ requestLevelNumber()

template<typename TDataType>
GPU_FUNC Level dyno::SparseOctree< TDataType >::requestLevelNumber ( const AABB box)

◆ setSpace()

template<typename TDataType>
void dyno::SparseOctree< TDataType >::setSpace ( Coord lo,
Real h,
Real L )

Member Data Documentation

◆ aux_nodes

template<typename TDataType>
DArray<OctreeNode> dyno::SparseOctree< TDataType >::aux_nodes
private

Definition at line 183 of file SparseOctree.h.

◆ data_count

template<typename TDataType>
DArray<int> dyno::SparseOctree< TDataType >::data_count
private

Definition at line 180 of file SparseOctree.h.

◆ duplicates_count

template<typename TDataType>
DArray<int> dyno::SparseOctree< TDataType >::duplicates_count
private

Definition at line 181 of file SparseOctree.h.

◆ m_all_nodes

template<typename TDataType>
DArray<OctreeNode> dyno::SparseOctree< TDataType >::m_all_nodes
private

Definition at line 177 of file SparseOctree.h.

◆ m_h

template<typename TDataType>
Real dyno::SparseOctree< TDataType >::m_h
private

Definition at line 172 of file SparseOctree.h.

◆ m_L

template<typename TDataType>
Real dyno::SparseOctree< TDataType >::m_L
private

Definition at line 173 of file SparseOctree.h.

◆ m_level_max

template<typename TDataType>
int dyno::SparseOctree< TDataType >::m_level_max
private

levels are numbered from 0 to m_level_max;

Definition at line 170 of file SparseOctree.h.

◆ m_lo

template<typename TDataType>
Coord dyno::SparseOctree< TDataType >::m_lo
private

Definition at line 175 of file SparseOctree.h.

◆ m_post_ordered_nodes

template<typename TDataType>
DArray<OctreeNode> dyno::SparseOctree< TDataType >::m_post_ordered_nodes
private

Definition at line 178 of file SparseOctree.h.

◆ node_buffer

template<typename TDataType>
DArray<OctreeNode> dyno::SparseOctree< TDataType >::node_buffer
private

Definition at line 184 of file SparseOctree.h.

◆ node_count

template<typename TDataType>
DArray<int> dyno::SparseOctree< TDataType >::node_count
private

Definition at line 182 of file SparseOctree.h.

◆ nonRepeatNodes_cpy

template<typename TDataType>
DArray<OctreeNode> dyno::SparseOctree< TDataType >::nonRepeatNodes_cpy
private

Definition at line 185 of file SparseOctree.h.


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