libigl v2.5.0
|
Fake halfedge for fast and easy navigation on triangle meshes with vertex_triangle_adjacency and triangle_triangle adjacency. More...
#include <HalfEdgeIterator.h>
Public Member Functions | |
HalfEdgeIterator (const Eigen::MatrixBase< DerivedF > &_F, const Eigen::MatrixBase< DerivedFF > &_FF, const Eigen::MatrixBase< DerivedFFi > &_FFi, int _fi, int _ei, bool _reverse=false) | |
Init the HalfEdgeIterator by specifying Face,Edge Index and Orientation. | |
void | flipF () |
Change Face. | |
void | flipE () |
Change Edge. | |
void | flipV () |
Change Vertex. | |
bool | isBorder () |
Determine if on border. | |
bool | NextFE () |
Change to next edge skipping the border. | |
int | Vi () |
Get vertex index. | |
int | Fi () |
Get face index. | |
int | Ei () |
Get edge index. | |
bool | operator== (HalfEdgeIterator &p2) |
Check if two HalfEdgeIterator are the same. | |
Fake halfedge for fast and easy navigation on triangle meshes with vertex_triangle_adjacency and triangle_triangle adjacency.
Note: this is different to classical Half Edge data structure. Instead, it follows cell-tuple in [Brisson, 1989] "Representing geometric structures in d dimensions: topology and order." This class can achieve local navigation similar to half edge in OpenMesh But the logic behind each atom operation is different. So this should be more properly called TriangleTupleIterator.
Each tuple contains information on (face, edge, vertex) and encoded by (face, edge \in {0,1,2}, bool reverse)
igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::HalfEdgeIterator | ( | const Eigen::MatrixBase< DerivedF > & | _F, |
const Eigen::MatrixBase< DerivedFF > & | _FF, | ||
const Eigen::MatrixBase< DerivedFFi > & | _FFi, | ||
int | _fi, | ||
int | _ei, | ||
bool | _reverse = false |
||
) |
Init the HalfEdgeIterator by specifying Face,Edge Index and Orientation.
[in] | F | F by 3 list of "faces" |
[in] | FF | F by 3 list of triangle-triangle adjacency. |
[in] | FFi | F by 3 list of FF inverse. For FF and FFi, refer to "triangle_triangle_adjacency.h" |
[in] | _fi | index of the selected face |
[in] | _ii | index of the selected face |
[in] | _reverse | orientation of the selected face |
void igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::flipF | ( | ) |
Change Face.
void igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::flipE | ( | ) |
Change Edge.
void igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::flipV | ( | ) |
Change Vertex.
bool igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::isBorder | ( | ) |
Determine if on border.
bool igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::NextFE | ( | ) |
Change to next edge skipping the border.
/\ c | b /\ / \ | / \ / d \ | / a \ /______|/______\ v In this example, if a and d are of-border and the pos is iterating counterclockwise, this method iterate through the faces incident on vertex v, producing the sequence a, b, c, d, a, b, c, ...
int igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::Vi | ( | ) |
Get vertex index.
int igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::Fi | ( | ) |
Get face index.
int igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::Ei | ( | ) |
Get edge index.
bool igl::HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi >::operator== | ( | HalfEdgeIterator< DerivedF, DerivedFF, DerivedFFi > & | p2 | ) |
Check if two HalfEdgeIterator are the same.