TTK
Loading...
Searching...
No Matches
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ttk::RangeDrivenOctree Class Reference

TTK optional package for octree based range queries in bivariate volumetric data. More...

#include <RangeDrivenOctree.h>

Inheritance diagram for ttk::RangeDrivenOctree:
ttk::Debug ttk::BaseClass

Classes

struct  OctreeNode
 

Public Member Functions

 RangeDrivenOctree ()
 
template<class dataTypeU , class dataTypeV , typename triangulationType >
int build (const triangulationType *const triangulation)
 
bool empty () const
 
void flush ()
 
int getTet2NodeMap (std::vector< SimplexId > &map, const bool &forSegmentation=false) const
 
int rangeSegmentQuery (const std::pair< double, double > &p0, const std::pair< double, double > &p1, std::vector< SimplexId > &cellList) const
 
void setCellList (const SimplexId *cellList)
 
void setCellNumber (const SimplexId &cellNumber)
 
void setLeafMinimumCellNumber (const SimplexId &number)
 
void setLeafMinimumDomainVolumeRatio (const float &ratio)
 
void setLeafMinimumRangeAreaRatio (const float &ratio)
 
void setPointList (const float *pointList)
 
void setRange (const void *u, const void *v)
 
void setVertexNumber (const SimplexId &vertexNumber)
 
int stats (std::ostream &stream)
 
int statNode (const SimplexId &nodeId, std::ostream &stream)
 
- Public Member Functions inherited from ttk::Debug
 Debug ()
 
 ~Debug () override
 
virtual int setDebugLevel (const int &debugLevel)
 
int setWrapper (const Wrapper *wrapper) override
 
int printMsg (const std::string &msg, const debug::Priority &priority=debug::Priority::INFO, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cout) const
 
int printMsg (const std::vector< std::string > &msgs, const debug::Priority &priority=debug::Priority::INFO, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cout) const
 
int printErr (const std::string &msg, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cerr) const
 
int printWrn (const std::string &msg, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cerr) const
 
int printMsg (const std::string &msg, const double &progress, const double &time, const int &threads, const double &memory, const debug::LineMode &lineMode=debug::LineMode::NEW, const debug::Priority &priority=debug::Priority::PERFORMANCE, std::ostream &stream=std::cout) const
 
int printMsg (const std::string &msg, const double &progress, const double &time, const debug::LineMode &lineMode=debug::LineMode::NEW, const debug::Priority &priority=debug::Priority::PERFORMANCE, std::ostream &stream=std::cout) const
 
int printMsg (const std::string &msg, const double &progress, const double &time, const int &threads, const debug::LineMode &lineMode=debug::LineMode::NEW, const debug::Priority &priority=debug::Priority::PERFORMANCE, std::ostream &stream=std::cout) const
 
int printMsg (const std::string &msg, const double &progress, const debug::LineMode &lineMode=debug::LineMode::NEW, const debug::Priority &priority=debug::Priority::PERFORMANCE, std::ostream &stream=std::cout) const
 
int printMsg (const std::string &msg, const double &progress, const debug::Priority &priority, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cout) const
 
int printMsg (const std::vector< std::vector< std::string > > &rows, const debug::Priority &priority=debug::Priority::INFO, const bool hasHeader=true, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cout) const
 
int printMsg (const debug::Separator &separator, const debug::LineMode &lineMode=debug::LineMode::NEW, const debug::Priority &priority=debug::Priority::INFO, std::ostream &stream=std::cout) const
 
int printMsg (const debug::Separator &separator, const debug::Priority &priority, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cout) const
 
int printMsg (const std::string &msg, const debug::Separator &separator, const debug::LineMode &lineMode=debug::LineMode::NEW, const debug::Priority &priority=debug::Priority::INFO, std::ostream &stream=std::cout) const
 
void setDebugMsgPrefix (const std::string &prefix)
 
- Public Member Functions inherited from ttk::BaseClass
 BaseClass ()
 
virtual ~BaseClass ()=default
 
int getThreadNumber () const
 
virtual int setThreadNumber (const int threadNumber)
 
virtual int setWrapper (const Wrapper *wrapper)
 

Protected Member Functions

template<class dataTypeU , class dataTypeV >
int buildNode (const std::vector< SimplexId > &cellList, const std::array< std::pair< float, float >, 3 > &domainBox, const std::pair< std::pair< double, double >, std::pair< double, double > > &rangeBox, SimplexId &nodeId)
 
int rangeSegmentQuery (const std::pair< double, double > &p0, const std::pair< double, double > &p1, const SimplexId &nodeId, std::vector< SimplexId > &cellList) const
 
bool segmentIntersection (const std::pair< double, double > &p0, const std::pair< double, double > &p1, const std::pair< double, double > &q0, const std::pair< double, double > &q1) const
 
- Protected Member Functions inherited from ttk::Debug
int printMsgInternal (const std::string &msg, const std::string &right, const std::string &filler, const debug::Priority &priority=debug::Priority::INFO, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cout) const
 
int printMsgInternal (const std::string &msg, const debug::Priority &priority, const debug::LineMode &lineMode, std::ostream &stream=std::cout) const
 
int welcomeMsg (std::ostream &stream)
 

Protected Attributes

const void * u_ {}
 
const void * v_ {}
 
const float * pointList_ {}
 
const SimplexIdcellList_ {}
 
float domainVolume_ {}
 
float leafMinimumDomainVolumeRatio_ {0.01F}
 
float leafMinimumRangeAreaRatio_ {0.01F}
 
float rangeArea_ {}
 
SimplexId cellNumber_ {}
 
SimplexId vertexNumber_ {}
 
SimplexId leafMinimumCellNumber_ {6}
 
SimplexId rootId_ {}
 
SimplexId queryResultNumber_ {}
 
std::vector< OctreeNodenodeList_ {}
 
std::vector< std::array< std::pair< float, float >, 3 > > cellDomainBox_ {}
 
std::vector< std::pair< std::pair< double, double >, std::pair< double, double > > > cellRangeBox_ {}
 
- Protected Attributes inherited from ttk::Debug
int debugLevel_
 
std::string debugMsgPrefix_
 
std::string debugMsgNamePrefix_
 
- Protected Attributes inherited from ttk::BaseClass
bool lastObject_
 
int threadNumber_
 
Wrapperwrapper_
 

Additional Inherited Members

- Static Protected Attributes inherited from ttk::Debug
static COMMON_EXPORTS debug::LineMode lastLineMode = ttk::debug::LineMode::NEW
 

Detailed Description

TTK optional package for octree based range queries in bivariate volumetric data.

Author
Julien Tierny julie.nosp@m.n.ti.nosp@m.erny@.nosp@m.lip6.nosp@m..fr
Date
March 2015.

This class accelerates range-driven queries in bivariate volumetric data. This class is typically used to accelerate fiber surface computation.

Related publication
"Fast and Exact Fiber Surface Extraction for Tetrahedral Meshes"
Pavol Klacansky, Julien Tierny, Hamish Carr, Zhao Geng
IEEE Transactions on Visualization and Computer Graphics, 2016.

See also
FiberSurface.h for a usage example.

Definition at line 27 of file RangeDrivenOctree.h.

Constructor & Destructor Documentation

◆ RangeDrivenOctree()

RangeDrivenOctree::RangeDrivenOctree ( )

Definition at line 9 of file RangeDrivenOctree.cpp.

Member Function Documentation

◆ build()

template<class dataTypeU , class dataTypeV , typename triangulationType >
int ttk::RangeDrivenOctree::build ( const triangulationType *const  triangulation)
inline

Definition at line 130 of file RangeDrivenOctree.h.

◆ buildNode()

template<class dataTypeU , class dataTypeV >
int ttk::RangeDrivenOctree::buildNode ( const std::vector< SimplexId > &  cellList,
const std::array< std::pair< float, float >, 3 > &  domainBox,
const std::pair< std::pair< double, double >, std::pair< double, double > > &  rangeBox,
SimplexId nodeId 
)
protected

Definition at line 303 of file RangeDrivenOctree.h.

◆ empty()

bool ttk::RangeDrivenOctree::empty ( ) const
inline

Definition at line 34 of file RangeDrivenOctree.h.

◆ flush()

void RangeDrivenOctree::flush ( )

Definition at line 13 of file RangeDrivenOctree.cpp.

◆ getTet2NodeMap()

int RangeDrivenOctree::getTet2NodeMap ( std::vector< SimplexId > &  map,
const bool &  forSegmentation = false 
) const

Definition at line 19 of file RangeDrivenOctree.cpp.

◆ rangeSegmentQuery() [1/2]

int RangeDrivenOctree::rangeSegmentQuery ( const std::pair< double, double > &  p0,
const std::pair< double, double > &  p1,
const SimplexId nodeId,
std::vector< SimplexId > &  cellList 
) const
protected

Definition at line 68 of file RangeDrivenOctree.cpp.

◆ rangeSegmentQuery() [2/2]

int RangeDrivenOctree::rangeSegmentQuery ( const std::pair< double, double > &  p0,
const std::pair< double, double > &  p1,
std::vector< SimplexId > &  cellList 
) const

Definition at line 44 of file RangeDrivenOctree.cpp.

◆ segmentIntersection()

bool RangeDrivenOctree::segmentIntersection ( const std::pair< double, double > &  p0,
const std::pair< double, double > &  p1,
const std::pair< double, double > &  q0,
const std::pair< double, double > &  q1 
) const
protected

Definition at line 351 of file RangeDrivenOctree.cpp.

◆ setCellList()

void ttk::RangeDrivenOctree::setCellList ( const SimplexId cellList)
inline

Definition at line 47 of file RangeDrivenOctree.h.

◆ setCellNumber()

void ttk::RangeDrivenOctree::setCellNumber ( const SimplexId cellNumber)
inline

Definition at line 51 of file RangeDrivenOctree.h.

◆ setLeafMinimumCellNumber()

void ttk::RangeDrivenOctree::setLeafMinimumCellNumber ( const SimplexId number)
inline

Definition at line 55 of file RangeDrivenOctree.h.

◆ setLeafMinimumDomainVolumeRatio()

void ttk::RangeDrivenOctree::setLeafMinimumDomainVolumeRatio ( const float &  ratio)
inline

Definition at line 59 of file RangeDrivenOctree.h.

◆ setLeafMinimumRangeAreaRatio()

void ttk::RangeDrivenOctree::setLeafMinimumRangeAreaRatio ( const float &  ratio)
inline

Definition at line 63 of file RangeDrivenOctree.h.

◆ setPointList()

void ttk::RangeDrivenOctree::setPointList ( const float *  pointList)
inline

Definition at line 67 of file RangeDrivenOctree.h.

◆ setRange()

void ttk::RangeDrivenOctree::setRange ( const void *  u,
const void *  v 
)
inline

Definition at line 71 of file RangeDrivenOctree.h.

◆ setVertexNumber()

void ttk::RangeDrivenOctree::setVertexNumber ( const SimplexId vertexNumber)
inline

Definition at line 76 of file RangeDrivenOctree.h.

◆ statNode()

int RangeDrivenOctree::statNode ( const SimplexId nodeId,
std::ostream &  stream 
)

Definition at line 256 of file RangeDrivenOctree.cpp.

◆ stats()

int RangeDrivenOctree::stats ( std::ostream &  stream)

Definition at line 294 of file RangeDrivenOctree.cpp.

Member Data Documentation

◆ cellDomainBox_

std::vector<std::array<std::pair<float, float>, 3> > ttk::RangeDrivenOctree::cellDomainBox_ {}
protected

Definition at line 120 of file RangeDrivenOctree.h.

◆ cellList_

const SimplexId* ttk::RangeDrivenOctree::cellList_ {}
protected

Definition at line 113 of file RangeDrivenOctree.h.

◆ cellNumber_

SimplexId ttk::RangeDrivenOctree::cellNumber_ {}
protected

Definition at line 116 of file RangeDrivenOctree.h.

◆ cellRangeBox_

std::vector<std::pair<std::pair<double, double>, std::pair<double, double> > > ttk::RangeDrivenOctree::cellRangeBox_ {}
protected

Definition at line 122 of file RangeDrivenOctree.h.

◆ domainVolume_

float ttk::RangeDrivenOctree::domainVolume_ {}
protected

Definition at line 114 of file RangeDrivenOctree.h.

◆ leafMinimumCellNumber_

SimplexId ttk::RangeDrivenOctree::leafMinimumCellNumber_ {6}
protected

Definition at line 116 of file RangeDrivenOctree.h.

◆ leafMinimumDomainVolumeRatio_

float ttk::RangeDrivenOctree::leafMinimumDomainVolumeRatio_ {0.01F}
protected

Definition at line 114 of file RangeDrivenOctree.h.

◆ leafMinimumRangeAreaRatio_

float ttk::RangeDrivenOctree::leafMinimumRangeAreaRatio_ {0.01F}
protected

Definition at line 115 of file RangeDrivenOctree.h.

◆ nodeList_

std::vector<OctreeNode> ttk::RangeDrivenOctree::nodeList_ {}
protected

Definition at line 119 of file RangeDrivenOctree.h.

◆ pointList_

const float* ttk::RangeDrivenOctree::pointList_ {}
protected

Definition at line 112 of file RangeDrivenOctree.h.

◆ queryResultNumber_

SimplexId ttk::RangeDrivenOctree::queryResultNumber_ {}
mutableprotected

Definition at line 118 of file RangeDrivenOctree.h.

◆ rangeArea_

float ttk::RangeDrivenOctree::rangeArea_ {}
protected

Definition at line 115 of file RangeDrivenOctree.h.

◆ rootId_

SimplexId ttk::RangeDrivenOctree::rootId_ {}
protected

Definition at line 117 of file RangeDrivenOctree.h.

◆ u_

const void* ttk::RangeDrivenOctree::u_ {}
protected

Definition at line 110 of file RangeDrivenOctree.h.

◆ v_

const void* ttk::RangeDrivenOctree::v_ {}
protected

Definition at line 111 of file RangeDrivenOctree.h.

◆ vertexNumber_

SimplexId ttk::RangeDrivenOctree::vertexNumber_ {}
protected

Definition at line 116 of file RangeDrivenOctree.h.


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