QGIS API Documentation 3.28.0-Firenze (ed3ad0430f)
Public Member Functions | List of all members
QgsMeshVertexCirculator Class Reference

Convenient class that turn around a vertex and provide information about faces and vertices. More...

#include <qgstopologicalmesh.h>

Public Member Functions

 QgsMeshVertexCirculator (const QgsTopologicalMesh &topologicalMesh, int vertexIndex)
 Constructor with topologicalMesh and vertexIndex. More...
 
 QgsMeshVertexCirculator (const QgsTopologicalMesh::TopologicalFaces &topologicalFaces, int faceIndex, int vertexIndex)
 Constructor with topologicFaces, vertexIndex and the index faceIndex of the face containing the vertex. More...
 
 QgsMeshVertexCirculator (const QgsTopologicalMesh::TopologicalFaces &topologicalFaces, int vertexIndex)
 Constructor with topologicFaces, vertexIndex. More...
 
QgsMeshFace currentFace () const
 Returns the current face, empty face if the circulator pass a boundary or circulator is invalid. More...
 
int currentFaceIndex () const
 Returns the current face index, -1 if the circulator has passed a boundary or circulator is invalid. More...
 
int degree () const
 Returns the degree of the vertex, that is the count of other vertices linked. More...
 
QList< int > facesAround () const
 Returns all the faces indexes around the vertex. More...
 
bool goBoundaryClockwise () const
 Sets the circulator on the boundary face turning clockwise, return false is there isn't boundary face. More...
 
bool goBoundaryCounterClockwise () const
 Sets the circulator on the boundary face turning counter clockwise, return false is there isn't boundary face. More...
 
bool isValid () const
 Returns whether the vertex circulator is valid. More...
 
int oppositeVertexClockwise () const
 Returns the opposite vertex of the current face and on the edge on the side turning clockwise. More...
 
int oppositeVertexCounterClockwise () const
 Returns the opposite vertex of the current face and on the edge on the side turning counter clockwise. More...
 
int turnClockwise () const
 Turns counter clockwise around the vertex and returns the new current face, -1 if the circulator pass a boundary or circulator is invalid. More...
 
int turnCounterClockwise () const
 Turns counter clockwise around the vertex and returns the new current face, -1 if the circulator pass a boundary or circulator is invalid. More...
 

Detailed Description

Convenient class that turn around a vertex and provide information about faces and vertices.

Since
QGIS 3.22

Definition at line 379 of file qgstopologicalmesh.h.

Constructor & Destructor Documentation

◆ QgsMeshVertexCirculator() [1/3]

QgsMeshVertexCirculator::QgsMeshVertexCirculator ( const QgsTopologicalMesh topologicalMesh,
int  vertexIndex 
)

Constructor with topologicalMesh and vertexIndex.

Definition at line 55 of file qgstopologicalmesh.cpp.

◆ QgsMeshVertexCirculator() [2/3]

QgsMeshVertexCirculator::QgsMeshVertexCirculator ( const QgsTopologicalMesh::TopologicalFaces topologicalFaces,
int  faceIndex,
int  vertexIndex 
)

Constructor with topologicFaces, vertexIndex and the index faceIndex of the face containing the vertex.

Note
This circulator only concerns faces that are in the same bloc of the face faceIndex. Other faces that could be share only the vertex vertexIndex can't be accessible with this circulator

Definition at line 74 of file qgstopologicalmesh.cpp.

◆ QgsMeshVertexCirculator() [3/3]

QgsMeshVertexCirculator::QgsMeshVertexCirculator ( const QgsTopologicalMesh::TopologicalFaces topologicalFaces,
int  vertexIndex 
)

Constructor with topologicFaces, vertexIndex.

Note
This circulator only concerns faces that are in the same bloc of the first face linked to the vertex vertexIndex. Other faces that could be share only the vertex vertexIndex can't be accessible with this circulator

Definition at line 86 of file qgstopologicalmesh.cpp.

Member Function Documentation

◆ currentFace()

QgsMeshFace QgsMeshVertexCirculator::currentFace ( ) const

Returns the current face, empty face if the circulator pass a boundary or circulator is invalid.

Definition at line 138 of file qgstopologicalmesh.cpp.

◆ currentFaceIndex()

int QgsMeshVertexCirculator::currentFaceIndex ( ) const

Returns the current face index, -1 if the circulator has passed a boundary or circulator is invalid.

Definition at line 133 of file qgstopologicalmesh.cpp.

◆ degree()

int QgsMeshVertexCirculator::degree ( ) const

Returns the degree of the vertex, that is the count of other vertices linked.

Definition at line 248 of file qgstopologicalmesh.cpp.

◆ facesAround()

QList< int > QgsMeshVertexCirculator::facesAround ( ) const

Returns all the faces indexes around the vertex.

Definition at line 221 of file qgstopologicalmesh.cpp.

◆ goBoundaryClockwise()

bool QgsMeshVertexCirculator::goBoundaryClockwise ( ) const

Sets the circulator on the boundary face turning clockwise, return false is there isn't boundary face.

Definition at line 146 of file qgstopologicalmesh.cpp.

◆ goBoundaryCounterClockwise()

bool QgsMeshVertexCirculator::goBoundaryCounterClockwise ( ) const

Sets the circulator on the boundary face turning counter clockwise, return false is there isn't boundary face.

Definition at line 163 of file qgstopologicalmesh.cpp.

◆ isValid()

bool QgsMeshVertexCirculator::isValid ( ) const

Returns whether the vertex circulator is valid.

Definition at line 216 of file qgstopologicalmesh.cpp.

◆ oppositeVertexClockwise()

int QgsMeshVertexCirculator::oppositeVertexClockwise ( ) const

Returns the opposite vertex of the current face and on the edge on the side turning clockwise.

Definition at line 180 of file qgstopologicalmesh.cpp.

◆ oppositeVertexCounterClockwise()

int QgsMeshVertexCirculator::oppositeVertexCounterClockwise ( ) const

Returns the opposite vertex of the current face and on the edge on the side turning counter clockwise.

Definition at line 198 of file qgstopologicalmesh.cpp.

◆ turnClockwise()

int QgsMeshVertexCirculator::turnClockwise ( ) const

Turns counter clockwise around the vertex and returns the new current face, -1 if the circulator pass a boundary or circulator is invalid.

Definition at line 115 of file qgstopologicalmesh.cpp.

◆ turnCounterClockwise()

int QgsMeshVertexCirculator::turnCounterClockwise ( ) const

Turns counter clockwise around the vertex and returns the new current face, -1 if the circulator pass a boundary or circulator is invalid.

Definition at line 97 of file qgstopologicalmesh.cpp.


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