TTK
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ttk::Triangulation Class Reference

Triangulation is a class that provides time and memory efficient traversal methods on triangulations of piecewise linear manifolds. It provides the following features:

  1. Given a vertex, it provides: the list of edges that are connected to it, the list of its neighbors, its link, its star, etc.
  2. Given an edge, it provides: its vertices, its star, etc.
  3. Given a triangle, its provides: its vertices, its edges, etc.
  4. Given a tetrahedron, its provides: its vertices, its edges, its neighbor tetrahedra, etc.
  5. Given a triangulation, it provides: its list of vertices, edges, triangles and tetrahedra.
More...

#include <Triangulation.h>

Inheritance diagram for ttk::Triangulation:
ttk::AbstractTriangulation ttk::Wrapper ttk::Debug ttk::BaseClass

Public Member Functions

 Triangulation ()
 
 ~Triangulation ()
 
int clear ()
 
size_t footprint () const
 
int getCellEdge (const SimplexId &cellId, const int &localEdgeId, SimplexId &edgeId) const
 
SimplexId getCellEdgeNumber (const SimplexId &cellId) const
 
const std::vector< std::vector< SimplexId > > * getCellEdges ()
 
int getCellNeighbor (const SimplexId &cellId, const int &localNeighborId, SimplexId &neighborId) const
 
SimplexId getCellNeighborNumber (const SimplexId &cellId) const
 
const std::vector< std::vector< SimplexId > > * getCellNeighbors ()
 
int getCellTriangle (const SimplexId &cellId, const int &localTriangleId, SimplexId &triangleId) const
 
SimplexId getCellTriangleNumber (const SimplexId &cellId) const
 
const std::vector< std::vector< SimplexId > > * getCellTriangles ()
 
int getCellVertex (const SimplexId &cellId, const int &localVertexId, SimplexId &vertexId) const
 
SimplexId getCellVertexNumber (const SimplexId &cellId) const
 
int getDimensionality () const
 
const std::vector< std::pair< SimplexId, SimplexId > > * getEdges ()
 
int getEdgeLink (const SimplexId &edgeId, const int &localLinkId, SimplexId &linkId) const
 
SimplexId getEdgeLinkNumber (const SimplexId &edgeId) const
 
const std::vector< std::vector< SimplexId > > * getEdgeLinks ()
 
int getEdgeStar (const SimplexId &edgeId, const int &localStarId, SimplexId &starId) const
 
SimplexId getEdgeStarNumber (const SimplexId &edgeId) const
 
const std::vector< std::vector< SimplexId > > * getEdgeStars ()
 
int getEdgeTriangle (const SimplexId &edgeId, const int &localTriangleId, SimplexId &triangleId) const
 
SimplexId getEdgeTriangleNumber (const SimplexId &edgeId) const
 
const std::vector< std::vector< SimplexId > > * getEdgeTriangles ()
 
int getEdgeVertex (const SimplexId &edgeId, const int &localVertexId, SimplexId &vertexId) const
 
int getGridDimensions (std::vector< int > &dimensions)
 
SimplexId getNumberOfCells () const
 
SimplexId getNumberOfEdges () const
 
SimplexId getNumberOfTriangles () const
 
SimplexId getNumberOfVertices () const
 
const std::vector< std::vector< SimplexId > > * getTriangles ()
 
int getTriangleEdge (const SimplexId &triangleId, const int &localEdgeId, SimplexId &edgeId) const
 
SimplexId getTriangleEdgeNumber (const SimplexId &triangleId) const
 
const std::vector< std::vector< SimplexId > > * getTriangleEdges ()
 
int getTriangleLink (const SimplexId &triangleId, const int &localLinkId, SimplexId &linkId) const
 
SimplexId getTriangleLinkNumber (const SimplexId &triangleId) const
 
const std::vector< std::vector< SimplexId > > * getTriangleLinks ()
 
int getTriangleStar (const SimplexId &triangleId, const int &localStarId, SimplexId &starId) const
 
SimplexId getTriangleStarNumber (const SimplexId &triangleId) const
 
const std::vector< std::vector< SimplexId > > * getTriangleStars ()
 
int getTriangleVertex (const SimplexId &triangleId, const int &localVertexId, SimplexId &vertexId) const
 
int getVertexEdge (const SimplexId &vertexId, const int &localEdgeId, SimplexId &edgeId) const
 
SimplexId getVertexEdgeNumber (const SimplexId &vertexId) const
 
const std::vector< std::vector< SimplexId > > * getVertexEdges ()
 
int getVertexLink (const SimplexId &vertexId, const int &localLinkId, SimplexId &linkId) const
 
SimplexId getVertexLinkNumber (const SimplexId &vertexId) const
 
const std::vector< std::vector< SimplexId > > * getVertexLinks ()
 
int getVertexNeighbor (const SimplexId &vertexId, const int &localNeighborId, SimplexId &neighborId) const
 
SimplexId getVertexNeighborNumber (const SimplexId &vertexId) const
 
const std::vector< std::vector< SimplexId > > * getVertexNeighbors ()
 
int getVertexPoint (const SimplexId &vertexId, float &x, float &y, float &z) const
 
int getVertexStar (const SimplexId &vertexId, const int &localStarId, SimplexId &starId) const
 
SimplexId getVertexStarNumber (const SimplexId &vertexId) const
 
const std::vector< std::vector< SimplexId > > * getVertexStars ()
 
int getVertexTriangle (const SimplexId &vertexId, const int &localTriangleId, SimplexId &triangleId) const
 
SimplexId getVertexTriangleNumber (const SimplexId &vertexId) const
 
const std::vector< std::vector< SimplexId > > * getVertexTriangles ()
 
bool isEdgeOnBoundary (const SimplexId &edgeId) const
 
bool isEmpty () const
 
bool isTriangleOnBoundary (const SimplexId &triangleId) const
 
bool isVertexOnBoundary (const SimplexId &vertexId) const
 
int preprocessBoundaryEdges ()
 
int preprocessBoundaryTriangles ()
 
int preprocessBoundaryVertices ()
 
int preprocessCellEdges ()
 
int preprocessCellNeighbors ()
 
int preprocessCellTriangles ()
 
int preprocessEdges ()
 
int preprocessEdgeLinks ()
 
int preprocessEdgeStars ()
 
int preprocessEdgeTriangles ()
 
int preprocessTriangles ()
 
int preprocessTriangleEdges ()
 
int preprocessTriangleLinks ()
 
int preprocessTriangleStars ()
 
int preprocessVertexEdges ()
 
int preprocessVertexLinks ()
 
int preprocessVertexNeighbors ()
 
int preprocessVertexStars ()
 
int preprocessVertexTriangles ()
 
int setDebugLevel (const int &debugLevel)
 Tune the debug level (default: 0) More...
 
int setInputCells (const SimplexId &cellNumber, const LongSimplexId *cellArray)
 
int setInputGrid (const float &xOrigin, const float &yOrigin, const float &zOrigin, const float &xSpacing, const float &ySpacing, const float &zSpacing, const SimplexId &xDim, const SimplexId &yDim, const SimplexId &zDim)
 
int setInputPoints (const SimplexId &pointNumber, const void *pointSet, const bool &doublePrecision=false)
 
int setThreadNumber (const ThreadId &threadNumber)
 Tune the number of active threads (default: number of logical cores) More...
 
int setWrapper (const Wrapper *wrapper)
 
- Public Member Functions inherited from ttk::AbstractTriangulation
 AbstractTriangulation ()
 
 ~AbstractTriangulation ()
 
virtual bool hasPreprocessedBoundaryEdges () const
 
virtual bool hasPreprocessedBoundaryTriangles () const
 
virtual bool hasPreprocessedBoundaryVertices () const
 
virtual bool hasPreprocessedCellEdges () const
 
virtual bool hasPreprocessedCellNeighbors () const
 
virtual bool hasPreprocessedCellTriangles () const
 
virtual bool hasPreprocessedEdgeLinks () const
 
virtual bool hasPreprocessedEdgeStars () const
 
virtual bool hasPreprocessedEdgeTriangles () const
 
virtual bool hasPreprocessedEdges () const
 
virtual bool hasPreprocessedTriangles () const
 
virtual bool hasPreprocessedTriangleEdges () const
 
virtual bool hasPreprocessedTriangleLinks () const
 
virtual bool hasPreprocessedTriangleStars () const
 
virtual bool hasPreprocessedVertexEdges () const
 
virtual bool hasPreprocessedVertexLinks () const
 
virtual bool hasPreprocessedVertexNeighbors () const
 
virtual bool hasPreprocessedVertexStars () const
 
virtual bool hasPreprocessedVertexTriangles () const
 
template<class itemType >
size_t tableTableFootprint (const vector< vector< itemType >> &table, const string tableName, stringstream *msg) const
 
- Public Member Functions inherited from ttk::Wrapper
 Wrapper ()
 
 ~Wrapper ()
 
- Public Member Functions inherited from ttk::Debug
 Debug ()
 
virtual ~Debug ()
 
virtual int dMsg (std::ostream &stream, std::string msg, const int &debugLevel=infoMsg) const
 
int err (const std::string msg, const int &debugLevel=fatalMsg) const
 
int msg (const char *msg, const int &debugLevel=infoMsg) const
 
- Public Member Functions inherited from ttk::BaseClass
 BaseClass ()
 
virtual ~BaseClass ()
 
int getThreadNumber () const
 
int setThreadNumber (const int threadNumber)
 

Protected Member Functions

bool isEmptyCheck () const
 
- Protected Member Functions inherited from ttk::AbstractTriangulation
bool needsToAbort ()
 
template<class itemType >
size_t tableFootprint (const std::vector< itemType > &table, const std::string tableName="", std::stringstream *msg=NULL) const
 
template<class itemType >
size_t tableTableFootprint (const std::vector< std::vector< itemType >> &table, const std::string tableName="", std::stringstream *msg=NULL) const
 
int updateProgress (const float &progress)
 

Protected Attributes

int gridDimensions_ [3]
 
AbstractTriangulationabstractTriangulation_
 
ExplicitTriangulation explicitTriangulation_
 
ImplicitTriangulation implicitTriangulation_
 
- Protected Attributes inherited from ttk::AbstractTriangulation
bool hasPreprocessedBoundaryEdges_
 
bool hasPreprocessedBoundaryTriangles_
 
bool hasPreprocessedBoundaryVertices_
 
bool hasPreprocessedCellEdges_
 
bool hasPreprocessedCellNeighbors_
 
bool hasPreprocessedCellTriangles_
 
bool hasPreprocessedEdges_
 
bool hasPreprocessedEdgeLinks_
 
bool hasPreprocessedEdgeStars_
 
bool hasPreprocessedEdgeTriangles_
 
bool hasPreprocessedTriangles_
 
bool hasPreprocessedTriangleEdges_
 
bool hasPreprocessedTriangleLinks_
 
bool hasPreprocessedTriangleStars_
 
bool hasPreprocessedVertexEdges_
 
bool hasPreprocessedVertexLinks_
 
bool hasPreprocessedVertexNeighbors_
 
bool hasPreprocessedVertexStars_
 
bool hasPreprocessedVertexTriangles_
 
std::vector< bool > boundaryEdges_
 
std::vector< bool > boundaryTriangles_
 
std::vector< bool > boundaryVertices_
 
std::vector< std::vector< SimplexId > > cellEdgeList_
 
std::vector< std::vector< SimplexId > > cellNeighborList_
 
std::vector< std::vector< SimplexId > > cellTriangleList_
 
std::vector< std::vector< SimplexId > > edgeLinkList_
 
std::vector< std::pair< SimplexId, SimplexId > > edgeList_
 
std::vector< std::vector< SimplexId > > edgeStarList_
 
std::vector< std::vector< SimplexId > > edgeTriangleList_
 
std::vector< std::vector< SimplexId > > triangleList_
 
std::vector< std::vector< SimplexId > > triangleEdgeList_
 
std::vector< std::vector< SimplexId > > triangleLinkList_
 
std::vector< std::vector< SimplexId > > triangleStarList_
 
std::vector< std::vector< SimplexId > > vertexEdgeList_
 
std::vector< std::vector< SimplexId > > vertexLinkList_
 
std::vector< std::vector< SimplexId > > vertexNeighborList_
 
std::vector< std::vector< SimplexId > > vertexStarList_
 
std::vector< std::vector< SimplexId > > vertexTriangleList_
 
- Protected Attributes inherited from ttk::Wrapper
float processingProgress_
 
- Protected Attributes inherited from ttk::Debug
int debugLevel_
 
- Protected Attributes inherited from ttk::BaseClass
bool lastObject_
 
int threadNumber_
 
Wrapperwrapper_
 

Additional Inherited Members

- Public Types inherited from ttk::Debug
enum  debugPriority {
  fatalMsg, timeMsg, memoryMsg, infoMsg,
  detailedInfoMsg, advancedInfoMsg
}
 

Detailed Description

Triangulation is a class that provides time and memory efficient traversal methods on triangulations of piecewise linear manifolds. It provides the following features:

  1. Given a vertex, it provides: the list of edges that are connected to it, the list of its neighbors, its link, its star, etc.
  2. Given an edge, it provides: its vertices, its star, etc.
  3. Given a triangle, its provides: its vertices, its edges, etc.
  4. Given a tetrahedron, its provides: its vertices, its edges, its neighbor tetrahedra, etc.
  5. Given a triangulation, it provides: its list of vertices, edges, triangles and tetrahedra.
Author
Julien Tierny julie.nosp@m.n.ti.nosp@m.erny@.nosp@m.lip6.nosp@m..fr
Date
January 2016.

Triangulation supports both explicit and implicit triangulations:

  1. Explicit triangulations: Given a list of points and a list of cells, Triangulation provides time efficient accesses (requiring adequate pre-processing, see the documentation furtherdown).
  2. Implicit triangulations: Given a regular grid (origin, spacings and dimensions), Triangulation will perform an implicit triangulation of the grid, enabling both time and memory efficient traversals of triangulations of regular grids.

Apart from pre-processes, Triangulation requires no memory overhead in addition to the input data.

Note
Only pre-process the information you need! See the documentation further down.
See also
ttkTriangulation

Definition at line 45 of file Triangulation.h.

Constructor & Destructor Documentation

◆ Triangulation()

Triangulation::Triangulation ( )

Definition at line 6 of file Triangulation.cpp.

◆ ~Triangulation()

Triangulation::~Triangulation ( )

Definition at line 13 of file Triangulation.cpp.

Member Function Documentation

◆ clear()

int ttk::Triangulation::clear ( void  )
inlinevirtual

Reset the triangulation data-structures.

Returns
Returns 0 upon success, negative values otherwise.

Reimplemented from ttk::AbstractTriangulation.

Definition at line 54 of file Triangulation.h.

◆ footprint()

size_t ttk::Triangulation::footprint ( ) const
inlinevirtual

Computes and displays the memory footprint of the data-structure.

Returns
Returns 0 upon success, negative values otherwise.

Reimplemented from ttk::AbstractTriangulation.

Definition at line 65 of file Triangulation.h.

◆ getCellEdge()

int ttk::Triangulation::getCellEdge ( const SimplexId cellId,
const int &  localEdgeId,
SimplexId edgeId 
) const
inlinevirtual

Get the localEdgeId-th edge of the cellId-th cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

In 1D, this function is equivalent to getCellNeighbor().

Precondition
For this function to behave correctly, preprocessCellEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
cellIdInput global cell identifier.
localEdgeIdInput local edge identifier, in [0, getCellEdgeNumber()].
edgeIdOutput global edge identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellEdgeNumber()
getCellNeighbor()

Implements ttk::AbstractTriangulation.

Definition at line 95 of file Triangulation.h.

◆ getCellEdgeNumber()

SimplexId ttk::Triangulation::getCellEdgeNumber ( const SimplexId cellId) const
inlinevirtual

Get the number of edges for the cellId-th cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

In 1D, this function is equivalent to getCellNeighborNumber().

Precondition
For this function to behave correctly, preprocessCellEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
cellIdInput global cell identifier.
Returns
Returns the number of cell edges.
See also
getCellNeighborNumber()

Implements ttk::AbstractTriangulation.

Definition at line 143 of file Triangulation.h.

◆ getCellEdges()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getCellEdges ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of edges for all cells.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

The number of entries in this list is equal to the number of cells. Each entry is a std::vector of identifiers whose size is equal to the number of edges for the corresponding cell.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

In 1D, this function is equivalent to getCellNeighbors().

Precondition
For this function to behave correctly, preprocessCellEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the cell edge list.
See also
getCellNeighbors()

Implements ttk::AbstractTriangulation.

Definition at line 196 of file Triangulation.h.

◆ getCellNeighbor()

int ttk::Triangulation::getCellNeighbor ( const SimplexId cellId,
const int &  localNeighborId,
SimplexId neighborId 
) const
inlinevirtual

Get the localNeighborId-th cell neighbor of the cellId-th cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Precondition
For this function to behave correctly, preprocessCellNeighbors() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
cellIdInput global cell identifier.
localNeighborIdInput local neighbor identifier, in [0, getCellNeighborNumber()].
neighborIdOutput global neighbor cell identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellNeighborNumber()

Implements ttk::AbstractTriangulation.

Definition at line 240 of file Triangulation.h.

◆ getCellNeighborNumber()

SimplexId ttk::Triangulation::getCellNeighborNumber ( const SimplexId cellId) const
inlinevirtual

Get the number of cell neighbors for the cellId-th cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Precondition
For this function to behave correctly, preprocessCellNeighbors() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
cellIdInput global cell identifier.
Returns
Returns the number of cell neighbors.

Implements ttk::AbstractTriangulation.

Definition at line 280 of file Triangulation.h.

◆ getCellNeighbors()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getCellNeighbors ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of cell neighbors for all cells.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

The number of entries in this list is equal to the number of cells. Each entry is a std::vector of identifiers whose size is equal to the number of neighbor cells for the corresponding cell.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessCellNeighbors() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the cell neighbor list.

Implements ttk::AbstractTriangulation.

Definition at line 325 of file Triangulation.h.

◆ getCellTriangle()

int ttk::Triangulation::getCellTriangle ( const SimplexId cellId,
const int &  localTriangleId,
SimplexId triangleId 
) const
inlinevirtual

Get the localTriangleId-th triangle id of the cellId-th cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

In 2D, this function is equivalent to getCellNeighbor().

Precondition
For this function to behave correctly, preprocessCellTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
cellIdInput global cell identifier.
localTriangleIdInput local triangle identifier, in [0, getCellTriangleNumber()].
triangleIdOutput global triangle identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellTriangleNumber()
getCellNeighbor()

Implements ttk::AbstractTriangulation.

Definition at line 366 of file Triangulation.h.

◆ getCellTriangleNumber()

SimplexId ttk::Triangulation::getCellTriangleNumber ( const SimplexId cellId) const
inlinevirtual

Get the number of triangles for the cellId-th cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

In 2D, this function is equivalent to getCellNeighborNumber().

Precondition
For this function to behave correctly, preprocessCellTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
cellIdInput global cell identifier.
Returns
Returns the number of cell triangles.
See also
getCellNeighborNumber()

Implements ttk::AbstractTriangulation.

Definition at line 419 of file Triangulation.h.

◆ getCellTriangles()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getCellTriangles ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of triangles for all cells.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Also, the notion of triangle only makes sense if the triangulation has a dimension greater than 2 (otherwise, use the cell information).

The number of entries in this list is equal to the number of cells. Each entry is a std::vector of identifiers whose size is equal to the number of triangles for the corresponding cell.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

In 2D, this function is equivalent to getCellNeighbors().

Precondition
For this function to behave correctly, preprocessCellTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the cell triangle list.
See also
getCellNeighbors()

Implements ttk::AbstractTriangulation.

Definition at line 478 of file Triangulation.h.

◆ getCellVertex()

int ttk::Triangulation::getCellVertex ( const SimplexId cellId,
const int &  localVertexId,
SimplexId vertexId 
) const
inlinevirtual

Get the localVertexId-th vertex identifier of the cellId-th cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Parameters
cellIdInput global cell identifier.
localVertexIdInput local vertex identifier, in [0, getCellVertexNumber()].
vertexIdOuput global vertex identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellVertexNumber()

Implements ttk::AbstractTriangulation.

Definition at line 517 of file Triangulation.h.

◆ getCellVertexNumber()

SimplexId ttk::Triangulation::getCellVertexNumber ( const SimplexId cellId) const
inlinevirtual

Get the number of vertices in a cell.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Parameters
cellIdInput global cell identifier.
Returns
Number of vertices in the cell.

Implements ttk::AbstractTriangulation.

Definition at line 539 of file Triangulation.h.

◆ getDimensionality()

int ttk::Triangulation::getDimensionality ( void  ) const
inlinevirtual

Get the dimensionality of the triangulation (this value is equal to the dimension of the simplex with largest dimensionality).

Returns
Returns the dimensionality of the triangulation.

Implements ttk::AbstractTriangulation.

Definition at line 551 of file Triangulation.h.

◆ getEdgeLink()

int ttk::Triangulation::getEdgeLink ( const SimplexId edgeId,
const int &  localLinkId,
SimplexId linkId 
) const
inlinevirtual

Get the localLinkId-th simplex of the link of the edgeId-th edge.

The output linkId refers in 2D to a vertex identifier and in 3D to an edge identifier. It returns a negative value in 1D.

Precondition
For this function to behave correctly, preprocessEdgeLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier.
localLinkIdInput local link simplex identifier, in [0, getEdgeLinkNumber()].
linkIdOutput link simplex identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getEdgeLinkNumber()

Implements ttk::AbstractTriangulation.

Definition at line 624 of file Triangulation.h.

◆ getEdgeLinkNumber()

SimplexId ttk::Triangulation::getEdgeLinkNumber ( const SimplexId edgeId) const
inlinevirtual

Get the number of simplicies in the link of the edgeId-th edge.

In 2D, this will return the number of vertices in the link, in 3D the number of edges. It returns a negative value in 1D.

Precondition
For this function to behave correctly, preprocessEdgeLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier.
Returns
Returns the number of cells in the link of the edge.

Implements ttk::AbstractTriangulation.

Definition at line 665 of file Triangulation.h.

◆ getEdgeLinks()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getEdgeLinks ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of link simplices for all edges.

The number of entries in this list is equal to the number of edges. Each entry is a std::vector of identifiers representing vertices in 2D and edges in 3D. It returns NULL in 1D.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessEdgeLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the edge link list.

Implements ttk::AbstractTriangulation.

Definition at line 710 of file Triangulation.h.

◆ getEdges()

const std::vector<std::pair<SimplexId, SimplexId> >* ttk::Triangulation::getEdges ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of edges of the triangulation.

Here the notion of edge only makes sense if the triangulation has a dimension greater than 1 (otherwise, use the cell information).

The number of entries in this list is equal to the number of edges. Each entry is a std::pair of vertex identifiers.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the edge list.

Implements ttk::AbstractTriangulation.

Definition at line 583 of file Triangulation.h.

◆ getEdgeStar()

int ttk::Triangulation::getEdgeStar ( const SimplexId edgeId,
const int &  localStarId,
SimplexId starId 
) const
inlinevirtual

Get the localStarId-th cell of the star of the edgeId-th edge.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Also, the notion of edge only makes sense if the triangulation has a dimension greater than 1 (otherwise, use the cell information).

Precondition
For this function to behave correctly, preprocessEdgeStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier.
localStarIdInput local star cell identifier, in [0, getEdgeStarNumber()].
starIdOutput global star cell identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getEdgeStarNumber()

Implements ttk::AbstractTriangulation.

Definition at line 754 of file Triangulation.h.

◆ getEdgeStarNumber()

SimplexId ttk::Triangulation::getEdgeStarNumber ( const SimplexId edgeId) const
inlinevirtual

Get the number of star cells for the edgeId-th edge.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Also, the notion of edge only makes sense if the triangulation has a dimension greater than 1 (otherwise, use the cell information).

Precondition
For this function to behave correctly, preprocessEdgeStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier
Returns
Returns the number of star cells.

Implements ttk::AbstractTriangulation.

Definition at line 798 of file Triangulation.h.

◆ getEdgeStars()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getEdgeStars ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of star cell identifiers for all edges.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Also, the notion of edge only makes sense if the triangulation has a dimension greater than 1 (otherwise, use the cell information).

The number of entries in this list is equal to the number of edges. Each entry is a std::vector of identifiers whose size is equal to the number of star cells for the corresponding edge.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessEdgeStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the edge star list.

Implements ttk::AbstractTriangulation.

Definition at line 848 of file Triangulation.h.

◆ getEdgeTriangle()

int ttk::Triangulation::getEdgeTriangle ( const SimplexId edgeId,
const int &  localTriangleId,
SimplexId triangleId 
) const
inlinevirtual

Get the localTriangleId-th triangle id of the edgeId-th edge.

In 2D, this function is equivalent to getEdgeStar().

Precondition
For this function to behave correctly, preprocessEdgeTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier.
localTriangleIdInput local triangle identifier, in [0, getEdgeTriangleNumber()].
triangleIdOutput global triangle identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getEdgeTriangleNumber()
getEdgeStar()

Implements ttk::AbstractTriangulation.

Definition at line 889 of file Triangulation.h.

◆ getEdgeTriangleNumber()

SimplexId ttk::Triangulation::getEdgeTriangleNumber ( const SimplexId edgeId) const
inlinevirtual

Get the number of triangles for the edgeId-th edge.

In 2D, this function is equivalent to getEdgeStarNumber().

Precondition
For this function to behave correctly, preprocessEdgeTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier.
Returns
Returns the number of edge triangles.
See also
getEdgeStarNumber

Implements ttk::AbstractTriangulation.

Definition at line 939 of file Triangulation.h.

◆ getEdgeTriangles()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getEdgeTriangles ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of triangles for all edges.

The number of entries in this list is equal to the number of edges. Each entry is a std::vector of identifiers whose size is equal to the number of triangles for the corresponding edge.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

In 2D, this function is equivalent to getEdgeStars().

Precondition
For this function to behave correctly, preprocessEdgeTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the edge triangle list.
See also
getEdgeStars

Implements ttk::AbstractTriangulation.

Definition at line 993 of file Triangulation.h.

◆ getEdgeVertex()

int ttk::Triangulation::getEdgeVertex ( const SimplexId edgeId,
const int &  localVertexId,
SimplexId vertexId 
) const
inlinevirtual

Get the localVertexId-th vertex identifier of the edgeId-th edge.

In 1D, this function is equivalent to getCellVertex().

Precondition
For this function to behave correctly, preprocessEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier.
localVertexIdInput local vertex identifier (0 or 1).
vertexIdOutput global vertex identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellVertex()

Implements ttk::AbstractTriangulation.

Definition at line 1039 of file Triangulation.h.

◆ getGridDimensions()

int ttk::Triangulation::getGridDimensions ( std::vector< int > &  dimensions)
inline

Get the dimensions of the grid if the current object is the implicit triangulation of a regular grid.

Parameters
dimensionsVector that will be filled with the dimensions of the grid. This std::vector has 3 entries (first: x, second: y, third: z).
Returns
Returns 0 upon success, negative values otherwise (for instance, if the object is not representing a regular grid).

Definition at line 1076 of file Triangulation.h.

◆ getNumberOfCells()

SimplexId ttk::Triangulation::getNumberOfCells ( void  ) const
inlinevirtual

Get the number of cells in the triangulation.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Returns
Returns the number of cells.

Implements ttk::AbstractTriangulation.

Definition at line 1096 of file Triangulation.h.

◆ getNumberOfEdges()

SimplexId ttk::Triangulation::getNumberOfEdges ( void  ) const
inlinevirtual

Get the number of edges in the triangulation.

In 1D, this function is equivalent to getNumberOfCells().

Precondition
For this function to behave correctly, preprocessEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns the number of edges.
See also
getNumberOfCells()

Implements ttk::AbstractTriangulation.

Definition at line 1119 of file Triangulation.h.

◆ getNumberOfTriangles()

SimplexId ttk::Triangulation::getNumberOfTriangles ( void  ) const
inlinevirtual

Get the number of triangles in the triangulation.

In 2D, this function is equivalent to getNumberOfCells().

Precondition
For this function to behave correctly, preprocessTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns the number of triangles.
See also
getNumberOfCells()

Implements ttk::AbstractTriangulation.

Definition at line 1155 of file Triangulation.h.

◆ getNumberOfVertices()

SimplexId ttk::Triangulation::getNumberOfVertices ( void  ) const
inlinevirtual

Get the number of vertices in the triangulation.

Returns
Returns the number of vertices.

Implements ttk::AbstractTriangulation.

Definition at line 1184 of file Triangulation.h.

◆ getTriangleEdge()

int ttk::Triangulation::getTriangleEdge ( const SimplexId triangleId,
const int &  localEdgeId,
SimplexId edgeId 
) const
inlinevirtual

Get the localEdgeId-th edge of the triangleId-th triangle.

In 2D, this function is equivalent to getCellEdge().

Precondition
For this function to behave correctly, preprocessTriangleEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global triangle identifier.
localEdgeIdInput local edge identifier, in [0, getTriangleEdgeNumber()].
edgeIdOutput global edge identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getTriangleEdgeNumber()
getCellEdge()

Implements ttk::AbstractTriangulation.

Definition at line 1254 of file Triangulation.h.

◆ getTriangleEdgeNumber()

SimplexId ttk::Triangulation::getTriangleEdgeNumber ( const SimplexId triangleId) const
inlinevirtual

Get the number of edges of the triangleId-th triangle.

In 2D, this function is equivalent to getCellEdgeNumber().

Precondition
For this function to behave correctly, preprocessTriangleEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global triangle identifier.
Returns
Returns the number of cells in the link of the triangle.
See also
getCellEdgeNumber()

Implements ttk::AbstractTriangulation.

Definition at line 1303 of file Triangulation.h.

◆ getTriangleEdges()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getTriangleEdges ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of edges for all triangles.

The number of entries in this list is equal to the number of triangles. Each entry is a std::vector of identifiers representing the edges connected to the triangle (3).

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

In 2D, this function is equivalent to getCellEdges().

Precondition
For this function to behave correctly, preprocessTriangleEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the triangle edge list.
See also
getCellEdges()

Implements ttk::AbstractTriangulation.

Definition at line 1356 of file Triangulation.h.

◆ getTriangleLink()

int ttk::Triangulation::getTriangleLink ( const SimplexId triangleId,
const int &  localLinkId,
SimplexId linkId 
) const
inlinevirtual

Get the localLinkId-th simplex of the link of the triangleId-th triangle.

The notion of triangle link only makes sense in 3D, where the output linkId refers to a vertex identifier.

Precondition
For this function to behave correctly, preprocessTriangleLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global triangle identifier.
localLinkIdInput local link simplex identifier, in [0, getTriangleLinkNumber()].
linkIdOutput link simplex identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getTriangleLinkNumber()

Implements ttk::AbstractTriangulation.

Definition at line 1403 of file Triangulation.h.

◆ getTriangleLinkNumber()

SimplexId ttk::Triangulation::getTriangleLinkNumber ( const SimplexId triangleId) const
inlinevirtual

Get the number of simplices in the link of the triangleId-th triangle.

The notion of triangle link only makes sense in 3D, where the number of vertices in the link will be returned.

Precondition
For this function to behave correctly, preprocessTriangleLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global triangle identifier.
Returns
Returns the number of simplices in the link of the triangle.

Implements ttk::AbstractTriangulation.

Definition at line 1446 of file Triangulation.h.

◆ getTriangleLinks()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getTriangleLinks ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of link simplices for all triangles.

The number of entries in this list is equal to the number of triangles. Each entry is a std::vector of identifiers representing a vertex.

The notion of triangle link only makes sense in 3D.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessTriangleLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the triangle link list.

Implements ttk::AbstractTriangulation.

Definition at line 1492 of file Triangulation.h.

◆ getTriangles()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getTriangles ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of triangles of the triangulation.

Here the notion of triangle only makes sense if the triangulation has a dimension greater than 2 (otherwise, use the cell information).

The number of entries in this list is equal to the number of triangles. Each entry is a std::vector of vertex identifiers.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the triangle list.

Implements ttk::AbstractTriangulation.

Definition at line 1217 of file Triangulation.h.

◆ getTriangleStar()

int ttk::Triangulation::getTriangleStar ( const SimplexId triangleId,
const int &  localStarId,
SimplexId starId 
) const
inlinevirtual

Get the localStarId-th cell of the star of the triangleId-th triangle.

The notion of triangle star only makes sense in 3D, where the output starId refers to a tetrahedron identifier.

Precondition
For this function to behave correctly, preprocessTriangleStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global triangle identifier.
localStarIdInput local star cell identifier, in [0, getTriangleStarNumber()].
starIdOutput global star cell identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getTriangleStarNumber()

Implements ttk::AbstractTriangulation.

Definition at line 1534 of file Triangulation.h.

◆ getTriangleStarNumber()

SimplexId ttk::Triangulation::getTriangleStarNumber ( const SimplexId triangleId) const
inlinevirtual

Get the number of star cells for the triangleId-th triangle.

The notion of triangle star only makes sense in 3D, where the number of tetrahedra in the star will be returned.

Precondition
For this function to behave correctly, preprocessTriangleStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global triangle identifier.
Returns
Returns the number of star cells.

Implements ttk::AbstractTriangulation.

Definition at line 1576 of file Triangulation.h.

◆ getTriangleStars()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getTriangleStars ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of star cell identifiers for all triangles.

The number of entries in this list is equal to the number of triangles. Each entry is a std::vector of identifiers whose size is equal to the number of star cells for the corresponding triangle.

The notion of triangle star only makes sense in 3D.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessTriangleStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the triangle star list.

Implements ttk::AbstractTriangulation.

Definition at line 1623 of file Triangulation.h.

◆ getTriangleVertex()

int ttk::Triangulation::getTriangleVertex ( const SimplexId triangleId,
const int &  localVertexId,
SimplexId vertexId 
) const
inlinevirtual

Get the localVertexId-th vertex identifier of the triangleId-th triangle.

In 2D, this function is equivalent to getCellVertex().

Precondition
For this function to behave correctly, preprocessTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global edge identifier.
localVertexIdInput local vertex identifier (in [0, 2]).
vertexIdOutput global vertex identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellVertex()

Implements ttk::AbstractTriangulation.

Definition at line 1662 of file Triangulation.h.

◆ getVertexEdge()

int ttk::Triangulation::getVertexEdge ( const SimplexId vertexId,
const int &  localEdgeId,
SimplexId edgeId 
) const
inlinevirtual

Get the localEdgeId-th edge identifier connected to the vertexId-th vertex.

In 1D, this function is equivalent to getVertexStar().

Precondition
For this function to behave correctly, preprocessVertexEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
localEdgeIdInput local edge identifier, in [0, getVertexEdgeNumber()].
edgeIdOutput global edge identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexEdgeNumber()
getVertexStar()

Implements ttk::AbstractTriangulation.

Definition at line 1716 of file Triangulation.h.

◆ getVertexEdgeNumber()

SimplexId ttk::Triangulation::getVertexEdgeNumber ( const SimplexId vertexId) const
inlinevirtual

Get the number of edges connected to the vertexId-th vertex.

In 1D, this function is equivalent to getVertexStarNumber().

Precondition
For this function to behave correctly, preprocessVertexEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
Returns
Returns the number of edges connected to the vertex.
See also
getVertexStarNumber()

Implements ttk::AbstractTriangulation.

Definition at line 1763 of file Triangulation.h.

◆ getVertexEdges()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getVertexEdges ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of edge identifiers for all vertices.

The number of entries in this list is equal to the number of vertices. Each entry is a std::vector of identifiers whose size is equal to the number of edges connected to the corresponding vertex.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

In 1D, this function is equivalent to getVertexStars()

Precondition
For this function to behave correctly, preprocessVertexEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the vertex edge list.
See also
getVertexStars()

Implements ttk::AbstractTriangulation.

Definition at line 1814 of file Triangulation.h.

◆ getVertexLink()

int ttk::Triangulation::getVertexLink ( const SimplexId vertexId,
const int &  localLinkId,
SimplexId linkId 
) const
inlinevirtual

Get the localLinkId-th simplex of the link of the vertexId-th vertex.

The output linkId refers in 2D to an edge identifier and in 3D to a triangle identifier.

Precondition
For this function to behave correctly, preprocessVertexLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
localLinkIdInput local link simplex identifier, in [0, getVertexLinkNumber()].
linkIdOutput link simplex identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexLinkNumber()

Implements ttk::AbstractTriangulation.

Definition at line 1858 of file Triangulation.h.

◆ getVertexLinkNumber()

SimplexId ttk::Triangulation::getVertexLinkNumber ( const SimplexId vertexId) const
inlinevirtual

Get the number of simplices in the link of the vertexId-th vertex.

In 2D, this will return the number of edges in the link, in 3D the number of triangles.

Precondition
For this function to behave correctly, preprocessVertexLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
Returns
Returns the number of cells in the link of the vertex.

Implements ttk::AbstractTriangulation.

Definition at line 1898 of file Triangulation.h.

◆ getVertexLinks()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getVertexLinks ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of link simplices for all vertices.

The number of entries in this list is equal to the number of vertices. Each entry is a std::vector of identifiers representing edges in 2D and triangles in 3D.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessVertexLinks() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the vertex link list.

Implements ttk::AbstractTriangulation.

Definition at line 1942 of file Triangulation.h.

◆ getVertexNeighbor()

int ttk::Triangulation::getVertexNeighbor ( const SimplexId vertexId,
const int &  localNeighborId,
SimplexId neighborId 
) const
inlinevirtual

Get the localNeighborId-th vertex neighbor of the vertexId-th vertex.

Precondition
For this function to behave correctly, preprocessVertexNeighbors() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
localNeighborIdInput local neighbor identifier, in [0, getVertexNeighborNumber()].
neighborIdOutput global neighbor vertex identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexNeighborNumber()

Implements ttk::AbstractTriangulation.

Definition at line 1978 of file Triangulation.h.

◆ getVertexNeighborNumber()

SimplexId ttk::Triangulation::getVertexNeighborNumber ( const SimplexId vertexId) const
inlinevirtual

Get the number of vertex neighbors for the vertexId-th vertex.

Precondition
For this function to behave correctly, preprocessVertexNeighbors() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
Returns
Returns the number vertex neighbors.

Implements ttk::AbstractTriangulation.

Definition at line 2015 of file Triangulation.h.

◆ getVertexNeighbors()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getVertexNeighbors ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of vertex neighbor identifiers for all vertices.

The number of entries in this list is equal to the number of vertices. Each entry is a std::vector of identifiers whose size is equal to the number of vertex neighbors for the corresponding vertex.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessVertexNeighbors() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the vertex neighbor list.

Implements ttk::AbstractTriangulation.

Definition at line 2058 of file Triangulation.h.

◆ getVertexPoint()

int ttk::Triangulation::getVertexPoint ( const SimplexId vertexId,
float &  x,
float &  y,
float &  z 
) const
inlinevirtual

Get the point (3D coordinates) for the vertexId-th vertex.

Parameters
vertexIdInput global vertex identifier.
xOutput x coordinate.
yOutput y coordinate.
zOutput z coordinate.
Returns
Returns 0 upon success, negative values otherwise.

Implements ttk::AbstractTriangulation.

Definition at line 2083 of file Triangulation.h.

◆ getVertexStar()

int ttk::Triangulation::getVertexStar ( const SimplexId vertexId,
const int &  localStarId,
SimplexId starId 
) const
inlinevirtual

Get the localStarId-th cell of the star of the vertexId-th vertex.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Precondition
For this function to behave correctly, preprocessVertexStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
localStarIdInput local star cell identifier, in [0, getVertexStarNumber()].
starIdOutput global star cell identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexStarNumber()

Implements ttk::AbstractTriangulation.

Definition at line 2120 of file Triangulation.h.

◆ getVertexStarNumber()

SimplexId ttk::Triangulation::getVertexStarNumber ( const SimplexId vertexId) const
inlinevirtual

Get the number of star cells for the vertexId-th vertex.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Precondition
For this function to behave correctly, preprocessVertexStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier
Returns
Returns the number of star cells.

Implements ttk::AbstractTriangulation.

Definition at line 2160 of file Triangulation.h.

◆ getVertexStars()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getVertexStars ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of star cell identifiers for all vertices.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

The number of entries in this list is equal to the number of vertices. Each entry is a std::vector of identifiers whose size is equal to the number of star cells for the corresponding vertex.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

Precondition
For this function to behave correctly, preprocessVertexStars() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the vertex star list.

Implements ttk::AbstractTriangulation.

Definition at line 2204 of file Triangulation.h.

◆ getVertexTriangle()

int ttk::Triangulation::getVertexTriangle ( const SimplexId vertexId,
const int &  localTriangleId,
SimplexId triangleId 
) const
inlinevirtual

Get the localTriangleId-th triangle id of the vertexId-th vertex.

In 2D, this function is equivalent to getVertexStar().

Precondition
For this function to behave correctly, preprocessVertexTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
localTriangleIdInput local triangle identifier, in [0, getVertexTriangleNumber()].
triangleIdOutput global triangle identifier.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexTriangleNumber()
getVertexStar()

Implements ttk::AbstractTriangulation.

Definition at line 2243 of file Triangulation.h.

◆ getVertexTriangleNumber()

SimplexId ttk::Triangulation::getVertexTriangleNumber ( const SimplexId vertexId) const
inlinevirtual

Get the number of triangles for the vertexId-th vertex.

In 2D, this function is equivalent to getVertexStarNumber().

Precondition
For this function to behave correctly, preprocessVertexTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
Returns
Returns the number of vertex triangles.
See also
getVertexStarNumber()

Implements ttk::AbstractTriangulation.

Definition at line 2293 of file Triangulation.h.

◆ getVertexTriangles()

const std::vector<std::vector<SimplexId> >* ttk::Triangulation::getVertexTriangles ( )
inlinevirtual
Warning
YOU SHOULD NOT CALL THIS FUNCTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING.

Get the list of triangles for all vertices.

The number of entries in this list is equal to the number of vertices. Each entry is a std::vector of identifiers whose size is equal to the number of triangles for the corresponding vertex.

In implicit mode, this function will force the creation of such a list (which will be time and memory consuming). THIS IS USUALLY A BAD IDEA.

In 2D, this function is equivalent to getVertexStars().

Precondition
For this function to behave correctly, preprocessVertexTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Returns
Returns a pointer to the vertex triangle list.
See also
getVertexStars()

Implements ttk::AbstractTriangulation.

Definition at line 2348 of file Triangulation.h.

◆ isEdgeOnBoundary()

bool ttk::Triangulation::isEdgeOnBoundary ( const SimplexId edgeId) const
inlinevirtual

Check if the edge with global identifier edgeId is on the boundary of the domain.

For 2D triangulations, this function will return true if the edge is a boundary edge. For 3D triangulations, this function will return true if the edge belongs to a boundary triangle.

Here the notion of edge only makes sense if the triangulation has a dimension greater than 1 (otherwise, use the cell information).

Precondition
For this function to behave correctly, preprocessBoundaryEdges() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
edgeIdInput global edge identifier.
Returns
Returns true if the edge is on the boundary, false otherwise.

Implements ttk::AbstractTriangulation.

Definition at line 2396 of file Triangulation.h.

◆ isEmpty()

bool ttk::Triangulation::isEmpty ( ) const
inlinevirtual

Check if the data structure is empty or not.

Returns
Returns true if empty, false otherwise.

Implements ttk::AbstractTriangulation.

Definition at line 2417 of file Triangulation.h.

◆ isEmptyCheck()

bool ttk::Triangulation::isEmptyCheck ( ) const
inlineprotected

Definition at line 3158 of file Triangulation.h.

◆ isTriangleOnBoundary()

bool ttk::Triangulation::isTriangleOnBoundary ( const SimplexId triangleId) const
inlinevirtual

Check if the triangle with global identifier triangleId is on the boundary of the domain.

Here the notion of triangle only makes sense if the triangulation has a dimension greater than 2 (otherwise, use the cell information).

For 2D triangulations, this function will return false all the time. For 3D triangulations, this function will return true if the triangle is a boundary triangle.

Precondition
For this function to behave correctly, preprocessBoundaryTriangles() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
triangleIdInput global triangle identifier.
Returns
Returns true if the triangle is on the boundary, false otherwise.

Implements ttk::AbstractTriangulation.

Definition at line 2441 of file Triangulation.h.

◆ isVertexOnBoundary()

bool ttk::Triangulation::isVertexOnBoundary ( const SimplexId vertexId) const
inlinevirtual

Check if the vertex with global identifier vertexId is on the boundary of the domain.

For 2D triangulations, this function will return true if the vertex belongs to a boundary edge. For 3D triangulations, this function will return true if the vertex belongs to a boundary triangle.

Precondition
For this function to behave correctly, preprocessBoundaryVertices() needs to be called on this object prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude such a pre-processing step from any time performance measurement.
Parameters
vertexIdInput global vertex identifier.
Returns
Returns true if the vertex is on the boundary, false otherwise.

Implements ttk::AbstractTriangulation.

Definition at line 2477 of file Triangulation.h.

◆ preprocessBoundaryEdges()

int ttk::Triangulation::preprocessBoundaryEdges ( )
inlinevirtual

Pre-process the boundary edges.

This function should ONLY be called as a pre-condition to the following function(s):

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
isEdgeOnBoundary()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2509 of file Triangulation.h.

◆ preprocessBoundaryTriangles()

int ttk::Triangulation::preprocessBoundaryTriangles ( )
inlinevirtual

Pre-process the boundary triangles.

This function should ONLY be called as a pre-condition to the following function(s):

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
isTriangleOnBoundary()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2531 of file Triangulation.h.

◆ preprocessBoundaryVertices()

int ttk::Triangulation::preprocessBoundaryVertices ( )
inlinevirtual

Pre-process the boundary vertices.

This function should ONLY be called as a pre-condition to the following function(s):

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
isVertexOnBoundary()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2553 of file Triangulation.h.

◆ preprocessCellEdges()

int ttk::Triangulation::preprocessCellEdges ( )
inlinevirtual

Pre-process the cell edges.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellEdge()
getCellEdgeNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2577 of file Triangulation.h.

◆ preprocessCellNeighbors()

int ttk::Triangulation::preprocessCellNeighbors ( )
inlinevirtual

Pre-process the cell neighbors.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellNeighbor()
getCellNeighbors()
getCellNeighborNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2605 of file Triangulation.h.

◆ preprocessCellTriangles()

int ttk::Triangulation::preprocessCellTriangles ( )
inlinevirtual

Pre-process the cell triangles.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getCellTriangle()
getCellTriangles()
getCellTriangleNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2632 of file Triangulation.h.

◆ preprocessEdgeLinks()

int ttk::Triangulation::preprocessEdgeLinks ( )
inlinevirtual

Pre-process the edge links.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getEdgeLink()
getEdgeLinks()
getEdgeLinkNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2691 of file Triangulation.h.

◆ preprocessEdges()

int ttk::Triangulation::preprocessEdges ( )
inlinevirtual

Pre-process the edges.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getEdges()
getEdgeVertex()
getNumberOfEdges()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2664 of file Triangulation.h.

◆ preprocessEdgeStars()

int ttk::Triangulation::preprocessEdgeStars ( )
inlinevirtual

Pre-process the edge stars.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getEdgeStar()
getEdgeStars()
getEdgeStarNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2721 of file Triangulation.h.

◆ preprocessEdgeTriangles()

int ttk::Triangulation::preprocessEdgeTriangles ( )
inlinevirtual

Pre-process the edge triangles.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getEdgeTriangle()
getEdgeTriangles()
getEdgeTriangleNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2751 of file Triangulation.h.

◆ preprocessTriangleEdges()

int ttk::Triangulation::preprocessTriangleEdges ( )
inlinevirtual

Pre-process the triangle edges.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getTriangleEdge()
getTriangleEdges()
getTriangleEdgeNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2818 of file Triangulation.h.

◆ preprocessTriangleLinks()

int ttk::Triangulation::preprocessTriangleLinks ( )
inlinevirtual

Pre-process the triangle links.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getTriangleLink()
getTriangleLinks()
getTriangleLinkNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2851 of file Triangulation.h.

◆ preprocessTriangles()

int ttk::Triangulation::preprocessTriangles ( )
inlinevirtual

Pre-process the triangles.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getNumberOfTriangles()
getTriangles()
getTriangleVertex()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2785 of file Triangulation.h.

◆ preprocessTriangleStars()

int ttk::Triangulation::preprocessTriangleStars ( )
inlinevirtual

Pre-process the triangle stars.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getTriangleStar()
getTriangleStars()
getTriangleStarNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2881 of file Triangulation.h.

◆ preprocessVertexEdges()

int ttk::Triangulation::preprocessVertexEdges ( )
inlinevirtual

Pre-process the vertex edges.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexEdge()
getVertexEdges()
getVertexEdgeNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2911 of file Triangulation.h.

◆ preprocessVertexLinks()

int ttk::Triangulation::preprocessVertexLinks ( )
inlinevirtual

Pre-process the vertex links.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexLink()
getVertexLinks()
getVertexLinkNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2940 of file Triangulation.h.

◆ preprocessVertexNeighbors()

int ttk::Triangulation::preprocessVertexNeighbors ( )
inlinevirtual

Pre-process the vertex neighbors.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexNeighbor()
getVertexNeighbors()
getVertexNeighborNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2967 of file Triangulation.h.

◆ preprocessVertexStars()

int ttk::Triangulation::preprocessVertexStars ( )
inlinevirtual

Pre-process the vertex stars.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexStar()
getVertexStars()
getVertexStarNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 2994 of file Triangulation.h.

◆ preprocessVertexTriangles()

int ttk::Triangulation::preprocessVertexTriangles ( )
inlinevirtual

Pre-process the vertex triangles.

This function should ONLY be called as a pre-condition to the following functions:

Precondition
This function should be called prior to any traversal, in a clearly distinct pre-processing step that involves no traversal at all. An error will be returned otherwise.
Note
It is recommended to exclude this pre-processing function from any time performance measurement.
Returns
Returns 0 upon success, negative values otherwise.
See also
getVertexTriangle()
getVertexTriangles()
getVertexTriangleNumber()

Reimplemented from ttk::AbstractTriangulation.

Definition at line 3021 of file Triangulation.h.

◆ setDebugLevel()

int ttk::Triangulation::setDebugLevel ( const int &  debugLevel)
inlinevirtual

Tune the debug level (default: 0)

Reimplemented from ttk::Debug.

Definition at line 3037 of file Triangulation.h.

◆ setInputCells()

int ttk::Triangulation::setInputCells ( const SimplexId cellNumber,
const LongSimplexId cellArray 
)
inline

Set the input cells for the triangulation.

Here the notion of cell refers to the simplicices of maximal dimension (3D: tetrahedra, 2D: triangles, 1D: edges).

Parameters
cellNumberNumber of input cells.
cellArrayPointer to the input cells. This pointer should point to an array of long long int where cells are stored one after the other. In particular, each cell starts by the number of vertices in it, followed by the identifiers of its vertices. This corresponds to the default cell array representation in VTK.
Returns
Returns 0 upon success, negative values otherwise.
Note
This function does not need to be called if the current object is a vtkTriangulation (this function is automatically called if needed through vtkTriangulation::setInputData()).
Warning
If this ttk::Triangulation object is already representing a valid triangulation, this information will be over-written (which means that pre-processing functions should be called again).

Definition at line 3064 of file Triangulation.h.

◆ setInputGrid()

int ttk::Triangulation::setInputGrid ( const float &  xOrigin,
const float &  yOrigin,
const float &  zOrigin,
const float &  xSpacing,
const float &  ySpacing,
const float &  zSpacing,
const SimplexId xDim,
const SimplexId yDim,
const SimplexId zDim 
)
inline

Set the specifications of the input grid to implicitly represent as a triangulation.

Parameters
xOriginInput x coordinate of the grid origin.
yOriginInput y coordinate of the grid origin.
zOriginInput z coordinate of the grid origin.
xSpacingInput spacing along the x dimension.
ySpacingInput spacing along the y dimension.
zSpacingInput spacing along the z dimension.
xDimInput number of vertices along the x dimension.
yDimInput number of vertices along the y dimension.
zDimInput number of vertices along the z dimension.
Returns
Returns 0 upon success, negative values otherwise.
Note
This function does not need to be called if the current object is a vtkTriangulation (this function is automatically called if needed through vtkTriangulation::setInputData()).
Warning
If this ttk::Triangulation object is already representing a valid triangulation, this information will be over-written (which means that pre-processing functions should be called again).

Definition at line 3093 of file Triangulation.h.

◆ setInputPoints()

int ttk::Triangulation::setInputPoints ( const SimplexId pointNumber,
const void *  pointSet,
const bool &  doublePrecision = false 
)
inline

Set the input 3D points of the triangulation.

Parameters
pointNumberNumber of input vertices.
pointSetPointer to the 3D points. This pointer should point to an array of float where points are stored one after the other. In particular, each point is represented by X-Y-Z coordinates (one after the other). This corresponds to the default point set representation in VTK.
Returns
Returns 0 upon success, negative values otherwise.
Note
This function does not need to be called if the current object is a vtkTriangulation (this function is automatically called if needed through vtkTriangulation::setInputData()).
Warning
If this ttk::Triangulation object is already representing a valid triangulation, this information will be over-written (which means that pre-processing functions should be called again).

Definition at line 3131 of file Triangulation.h.

◆ setThreadNumber()

int ttk::Triangulation::setThreadNumber ( const ThreadId threadNumber)
inline

Tune the number of active threads (default: number of logical cores)

Definition at line 3142 of file Triangulation.h.

◆ setWrapper()

int ttk::Triangulation::setWrapper ( const Wrapper wrapper)
inlinevirtual

Internal usage. Pass the execution context (debug level, number of threads, etc.) to the implementing classes.

Reimplemented from ttk::Debug.

Definition at line 3151 of file Triangulation.h.

Member Data Documentation

◆ abstractTriangulation_

AbstractTriangulation* ttk::Triangulation::abstractTriangulation_
protected

Definition at line 3171 of file Triangulation.h.

◆ explicitTriangulation_

ExplicitTriangulation ttk::Triangulation::explicitTriangulation_
protected

Definition at line 3172 of file Triangulation.h.

◆ gridDimensions_

int ttk::Triangulation::gridDimensions_[3]
protected

Definition at line 3169 of file Triangulation.h.

◆ implicitTriangulation_

ImplicitTriangulation ttk::Triangulation::implicitTriangulation_
protected

Definition at line 3173 of file Triangulation.h.


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