Class SurfaceMesh
Defined in File SurfaceMesh.h
Nested Relationships
Nested Types
Class Documentation
-
class SurfaceMesh
A halfedge data structure for polygonal meshes.
Iterator Types
-
using VertexIterator = HandleIterator<Vertex>
this class iterates linearly over all vertices
See also
vertices_begin(), vertices_end()
See also
HalfedgeIterator, EdgeIterator, FaceIterator
-
using HalfedgeIterator = HandleIterator<Halfedge>
this class iterates linearly over all halfedges
See also
halfedges_begin(), halfedges_end()
See also
VertexIterator, EdgeIterator, FaceIterator
-
using EdgeIterator = HandleIterator<Edge>
this class iterates linearly over all edges
See also
edges_begin(), edges_end()
See also
VertexIterator, HalfedgeIterator, FaceIterator
-
using FaceIterator = HandleIterator<Face>
this class iterates linearly over all faces
See also
faces_begin(), faces_end()
See also
VertexIterator, HalfedgeIterator, EdgeIterator
Container Types
-
using VertexContainer = HandleContainer<Vertex>
helper class for iterating through all vertices using range-based for-loops.
See also
vertices()
-
using HalfedgeContainer = HandleContainer<Halfedge>
helper class for iterating through all halfedges using range-based for-loops.
See also
halfedges()
-
using EdgeContainer = HandleContainer<Edge>
helper class for iterating through all edges using range-based for-loops.
See also
edges()
-
using FaceContainer = HandleContainer<Face>
helper class for iterating through all faces using range-based for-loops.
See also
faces()
Construction, destruction, assignment
-
SurfaceMesh()
default constructor
-
virtual ~SurfaceMesh() = default
destructor
-
inline SurfaceMesh(const SurfaceMesh &rhs)
copy constructor: copies
rhsto*this. performs a deep copy of all properties.
-
SurfaceMesh(SurfaceMesh &&rhs) = default
move constructor: moves
rhsto*this.
-
SurfaceMesh &operator=(const SurfaceMesh &rhs)
assign
rhsto*this. performs a deep copy of all properties.
-
SurfaceMesh &operator=(SurfaceMesh &&rhs) = default
move assign
rhsto*this.
-
SurfaceMesh &assign(const SurfaceMesh &rhs)
assign
rhsto*this. does not copy custom properties.
File IO
-
void read(const std::string &filename, const IOFlags &flags = IOFlags())
Read mesh from file
filenamecontrolled byflags.File extension determines file type. Supported formats and vertex attributes (a=ASCII, b=binary):
Format
ASCII
Binary
Normals
Colors
Texcoords
OFF
yes
yes
a / b
a
a / b
OBJ
yes
no
a
no
no
STL
yes
yes
no
no
no
PLY
yes
yes
no
no
no
PMP
no
yes
no
no
no
XYZ
yes
no
a
no
no
AGI
yes
no
a
a
no
In addition, the OBJ and PMP formats support reading per-halfedge texture coordinates.
-
inline void write(const std::string &filename, const IOFlags &flags = IOFlags())
Write mesh to file
filenamecontrolled byflags.File extension determines file type. Supported formats and vertex attributes (a=ASCII, b=binary):
Format
ASCII
Binary
Normals
Colors
Texcoords
OFF
yes
yes
a
a
a
OBJ
yes
no
a
no
no
STL
yes
no
no
no
no
PLY
yes
yes
no
no
no
PMP
no
yes
no
no
no
XYZ
yes
no
a
no
no
In addition, the OBJ and PMP formats support writing per-halfedge texture coordinates.
-
void write_const(const std::string &filename, const IOFlags &flags = IOFlags()) const
const version of write. Requires that the mesh has no garbage.
-
void read(const HighFive::Group &group)
Read the mesh from a HDF5 Group.
-
inline void write(HighFive::Group &group)
Write the mesh to a HDF5 Group.
-
void write_const(HighFive::Group &group) const
const version of write. Requires that the mesh has no garbage.
-
void unload(HighFive::Group &group)
write content of the mesh into
groupand shallow_clear() the mesh.
-
void restore(const HighFive::Group &group)
restore content of the mesh after a call to unload(
group).
Add new elements by hand
-
Face add_face(const std::vector<Vertex> &vertices)
Add a new face with vertex list
vertices.See also
add_triangle, add_quad
- Throws:
TopologyException – in case a topological error occurs.
Memory Management
-
inline size_t vertices_size() const
returns number of (deleted and valid) vertices in the mesh
-
inline size_t halfedges_size() const
returns number of (deleted and valid) halfedges in the mesh
-
inline size_t edges_size() const
returns number of (deleted and valid) edges in the mesh
-
inline size_t faces_size() const
returns number of (deleted and valid) faces in the mesh
-
inline size_t n_vertices() const
returns number of vertices in the mesh
-
inline size_t n_halfedges() const
returns number of halfedge in the mesh
-
inline size_t n_edges() const
returns number of edges in the mesh
-
inline size_t n_faces() const
returns number of faces in the mesh
-
inline bool is_empty() const
returns true if the mesh is empty, i.e., has no vertices
-
virtual void clear()
clear mesh: remove all vertices, edges, faces
-
void shallow_clear()
shallow clear mesh: remove the content of all properties (including positions and connectivity), but keep the properties themselves.
This is useful after calling unload() and a subsequent restore(), if you want to save memory. Can be undone by calling restore() again.
Note that the n_faces() etc. methods will still return the correct values.
-
void free_memory()
remove unused memory from vectors
-
void reserve(size_t nvertices = 0, size_t nedges = 0, size_t nfaces = 0)
reserve memory (mainly used in file readers)
Passing in zero for any parameter will attempt to calculate that value using Euler’s formula.
-
void garbage_collection()
remove deleted elements
-
inline bool is_deleted(Vertex v) const
returns whether vertex
vis deletedSee also
garbage_collection()
-
inline bool is_deleted(Halfedge h) const
returns whether halfedge
his deletedSee also
garbage_collection()
-
inline bool is_deleted(Edge e) const
returns whether edge
eis deletedSee also
garbage_collection()
-
inline bool is_deleted(Face f) const
returns whether face
fis deletedSee also
garbage_collection()
-
inline bool is_valid(Vertex v) const
return whether vertex
vis valid, i.e. the index is stores it within the array bounds.
-
inline bool is_valid(Halfedge h) const
return whether halfedge
his valid, i.e. the index is stores it within the array bounds.
Low-level connectivity
-
inline Halfedge halfedge(Vertex v) const
returns an outgoing halfedge of vertex
v. ifvis a boundary vertex this will be a boundary halfedge.
-
inline bool is_isolated(Vertex v) const
returns whether
vis isolated, i.e., not incident to any edge
-
inline bool is_manifold(Vertex v) const
returns whether
vis a manifold vertex (not incident to several patches)
-
inline void set_next_halfedge(Halfedge h, Halfedge nh)
sets the next halfedge of
hwithin the face tonh
-
inline void set_prev_halfedge(Halfedge h, Halfedge ph)
sets the previous halfedge of
hand the next halfedge ofphtonh
-
inline Halfedge prev_halfedge(Halfedge h) const
returns the previous halfedge within the incident face
-
inline Halfedge ccw_rotated_halfedge(Halfedge h) const
returns the halfedge that is rotated counter-clockwise around the start vertex of
h. it is the opposite halfedge of the previous halfedge ofh.
-
inline Halfedge cw_rotated_halfedge(Halfedge h) const
returns the halfedge that is rotated clockwise around the start vertex of
h. it is the next halfedge of the opposite halfedge ofh.
-
inline Edge edge(Halfedge h) const
return the edge that contains halfedge
has one of its two halfedges.
-
inline bool is_boundary(Halfedge h) const
returns whether h is a boundary halfege, i.e., if its face does not exist.
-
inline Halfedge halfedge(Edge e, unsigned int i = 0) const
returns the
i'thhalfedge of edgee.ihas to be 0 or 1.
-
inline Vertex vertex(Edge e, unsigned int i) const
returns the
i'thvertex of edgee.ihas to be 0 or 1.
-
inline Face face(Edge e, unsigned int i) const
returns the face incident to the
i'thhalfedge of edgee.ihas to be 0 or 1.
Property handling
-
template<class T>
inline T &add_object_property(const std::string &name, const T t = T()) add a object property of type
Twith namenameand default valuet. fails if a property namednameexists already, since the name has to be unique. in this case it returns an invalid property
-
template<class T>
inline boost::optional<T&> get_object_property(const std::string &name) get the object property named
nameof typeT. returns an invalid Property if the property does not exist or if the type does not match.
-
template<class T>
inline boost::optional<const T&> get_object_property(const std::string &name) const get the object property named
nameof typeT. returns an invalid Property if the property does not exist or if the type does not match.
-
template<class T>
inline T &object_property(const std::string &name, const T t = T()) if a object property of type
Twith namenameexists, it is returned. otherwise this property is added (with default valuet)
-
template<class T>
inline void remove_object_property(const std::string &name)
-
inline const std::type_info &get_object_propertyType(const std::string &name)
get the type_info
Tof face property namedname. returns an typeid(void) if the property does not exist or if the type does not match.
-
inline std::vector<std::string> object_properties() const
returns the names of all face properties
-
template<class T>
inline VertexProperty<T> add_vertex_property(const std::string &name, const T t = T()) add a vertex property of type
Twith namenameand default valuet. fails if a property namednameexists already, since the name has to be unique. in this case it returns an invalid property
-
template<class T>
inline VertexProperty<T> get_vertex_property(const std::string &name) get the vertex property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline VertexConstProperty<T> get_vertex_property(const std::string &name) const get the vertex property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline VertexProperty<T> vertex_property(const std::string &name, const T t = T()) if a vertex property of type
Twith namenameexists, it is returned. otherwise this property is added (with default valuet)
-
template<class T>
inline void remove_vertex_property(VertexProperty<T> &p) remove the vertex property
p
-
template<class T>
inline void remove_vertex_property(const std::string &name)
-
inline bool has_vertex_property(const std::string &name) const
does the mesh have a vertex property with name
name?
-
template<class T>
inline HalfedgeProperty<T> add_halfedge_property(const std::string &name, const T t = T()) add a halfedge property of type
Twith namenameand default valuet. fails if a property namednameexists already, since the name has to be unique. in this case it returns an invalid property.
-
template<class T>
inline EdgeProperty<T> add_edge_property(const std::string &name, const T t = T()) add a edge property of type
Twith namenameand default valuet. fails if a property namednameexists already, since the name has to be unique. in this case it returns an invalid property.
-
template<class T>
inline HalfedgeProperty<T> get_halfedge_property(const std::string &name) get the halfedge property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline HalfedgeConstProperty<T> get_halfedge_property(const std::string &name) const get the halfedge property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline EdgeProperty<T> get_edge_property(const std::string &name) get the edge property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline EdgeConstProperty<T> get_edge_property(const std::string &name) const get the edge property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline HalfedgeProperty<T> halfedge_property(const std::string &name, const T t = T()) if a halfedge property of type
Twith namenameexists, it is returned. otherwise this property is added (with default valuet)
-
template<class T>
inline EdgeProperty<T> edge_property(const std::string &name, const T t = T()) if an edge property of type
Twith namenameexists, it is returned. otherwise this property is added (with default valuet)
-
template<class T>
inline void remove_halfedge_property(HalfedgeProperty<T> &p) remove the halfedge property
p
-
template<class T>
inline void remove_halfedge_property(const std::string &name)
-
inline bool has_halfedge_property(const std::string &name) const
does the mesh have a halfedge property with name
name?
-
template<class T>
inline void remove_edge_property(const std::string &name)
-
inline bool has_edge_property(const std::string &name) const
does the mesh have an edge property with name
name?
-
inline const std::type_info &get_halfedge_property_type(const std::string &name)
get the type_info
Tof halfedge property namedname. returns an typeid(void) if the property does not exist or if the type does not match.
-
inline const std::type_info &get_vertex_property_type(const std::string &name)
get the type_info
Tof vertex property namedname. returns an typeid(void) if the property does not exist or if the type does not match.
-
inline const std::type_info &get_edge_property_type(const std::string &name)
get the type_info
Tof edge property namedname. returns an typeid(void) if the property does not exist or if the type does not match.
-
inline std::vector<std::string> vertex_properties() const
returns the names of all vertex properties
-
inline std::vector<std::string> halfedge_properties() const
returns the names of all halfedge properties
-
inline std::vector<std::string> edge_properties() const
returns the names of all edge properties
-
template<class T>
inline FaceProperty<T> add_face_property(const std::string &name, const T t = T()) add a face property of type
Twith namenameand default valuet. fails if a property namednameexists already, since the name has to be unique. in this case it returns an invalid property
-
template<class T>
inline FaceProperty<T> get_face_property(const std::string &name) get the face property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline FaceConstProperty<T> get_face_property(const std::string &name) const get the face property named
nameof typeT. returns an invalid VertexProperty if the property does not exist or if the type does not match.
-
template<class T>
inline FaceProperty<T> face_property(const std::string &name, const T t = T()) if a face property of type
Twith namenameexists, it is returned. otherwise this property is added (with default valuet)
-
template<class T>
inline void remove_face_property(const std::string &name)
-
inline bool has_face_property(const std::string &name) const
does the mesh have a face property with name
name?
-
inline const std::type_info &get_face_property_type(const std::string &name)
get the type_info
Tof face property namedname. returns an typeid(void) if the property does not exist or if the type does not match.
-
inline std::vector<std::string> face_properties() const
returns the names of all face properties
-
void property_stats() const
prints the names of all properties
-
inline void copy_properties(const SurfaceMesh &src)
-
inline PropertyMap<Face> gen_face_copy_map(const SurfaceMesh &src)
Generate a PropertyMap to copy face properties from
srcto faces in this mesh.- Parameters:
src – The source mesh. May be *this if you want to copy within the same mesh.
-
inline PropertyMap<Vertex> gen_vertex_copy_map(const SurfaceMesh &src)
See also
gen_face_copy_map()
-
inline PropertyMap<Edge> gen_edge_copy_map(const SurfaceMesh &src)
See also
gen_face_copy_map()
-
inline PropertyMap<Halfedge> gen_halfedge_copy_map(const SurfaceMesh &src)
See also
gen_face_copy_map()
Iterators and circulators
-
inline VertexIterator vertices_begin() const
returns start iterator for vertices
-
inline VertexIterator vertices_end() const
returns end iterator for vertices
-
inline VertexContainer vertices() const
returns vertex container for C++11 range-based for-loops
-
inline HalfedgeIterator halfedges_begin() const
returns start iterator for halfedges
-
inline HalfedgeIterator halfedges_end() const
returns end iterator for halfedges
-
inline HalfedgeContainer halfedges() const
returns halfedge container for C++11 range-based for-loops
-
inline EdgeIterator edges_begin() const
returns start iterator for edges
-
inline EdgeIterator edges_end() const
returns end iterator for edges
-
inline EdgeContainer edges() const
returns edge container for C++11 range-based for-loops
-
inline VertexAroundVertexCirculator vertices(Vertex v) const
returns circulator for vertices around vertex
v
-
inline HalfedgeAroundVertexCirculator halfedges(Vertex v) const
returns circulator for outgoing halfedges around vertex
v
-
inline FaceIterator faces_begin() const
returns start iterator for faces
-
inline FaceIterator faces_end() const
returns end iterator for faces
-
inline FaceContainer faces() const
returns face container for C++11 range-based for-loops
-
inline FaceAroundVertexCirculator faces(Vertex v) const
returns circulator for faces around vertex
v
-
inline VertexAroundFaceCirculator vertices(Face f) const
returns circulator for vertices of face
f
-
inline HalfedgeAroundFaceCirculator halfedges(Face f) const
returns circulator for halfedges of face
f
-
inline HalfedgeAroundFaceCirculator boundary_circulator(Halfedge h) const
returns circulator for halfedges of a boundary “Face”
Higher-level Topological Operations
-
inline Halfedge insert_vertex(Edge e, const Point &p)
Subdivide the edge
e= (v0,v1) by splitting it into the two edge (v0,p) and (p,v1). Note that this function does not introduce any other edge or faces. It simply splits the edge. Returns halfedge that points top.See also
insert_vertex(Edge, Vertex)
See also
insert_vertex(Halfedge, Vertex)
-
inline Halfedge insert_vertex(Edge e, Vertex v)
Subdivide the edge
e= (v0,v1) by splitting it into the two edge (v0,v) and (v,v1). Note that this function does not introduce any other edge or faces. It simply splits the edge. Returns halfedge that points top.See also
insert_vertex(Edge, Point)
See also
insert_vertex(Halfedge, Vertex)
-
Halfedge insert_vertex(Halfedge h0, Vertex v)
Subdivide the halfedge
h= (v0,v1) by splitting it into the two halfedges (v0,v) and (v,v1). Note that this function does not introduce any other edge or faces. It simply splits the edge. Returns the halfedge that points from v1 tov.See also
insert_vertex(Edge, Point)
See also
insert_vertex(Edge, Vertex)
-
bool is_triangle_mesh() const
returns whether the mesh a triangle mesh. this function simply tests each face, and therefore is not very efficient.
See also
trianglate(), triangulate(Face)
-
bool is_quad_mesh() const
returns whether the mesh a quad mesh. this function simply tests each face, and therefore is not very efficient.
-
bool is_collapse_ok(Halfedge v0v1)
returns whether collapsing the halfedge
v0v1is topologically legal.- Attention
This function is only valid for triangle meshes.
-
void collapse(Halfedge h)
Collapse the halfedge
hby moving its start vertex into its target vertex. For non-boundary halfedges this function removes one vertex, three edges, and two faces. For boundary halfedges it removes one vertex, two edges and one face.- Attention
This function is only valid for triangle meshes.
- Attention
Halfedge collapses might lead to invalid faces. Call is_collapse_ok(Halfedge) to be sure the collapse is legal.
- Attention
The removed items are only marked as deleted. You have to call garbage_collection() to finally remove them.
-
bool remove_edge(Edge e)
Remove edge and merge its two incident faces into one. This operation requires that the edge has two incident faces and that these two are not equal.
-
inline Vertex split(Face f, const Point &p)
Split the face
fby first adding pointpto the mesh and then inserting edges betweenpand the vertices off. For a triangle this is a standard one-to-three split.See also
split(Face, Vertex)
-
void split(Face f, Vertex v)
Split the face
fby inserting edges betweenvand the vertices off. For a triangle this is a standard one-to-three split.See also
split(Face, const Point&)
-
inline Halfedge split(Edge e, const Point &p)
Split the edge
eby first adding pointpto the mesh and then connecting it to the two vertices of the adjacent triangles that are opposite to edgee. Returns the halfedge pointing topthat is created by splitting the existing edgee.See also
split(Edge, Vertex)
- Attention
This function is only valid for triangle meshes.
-
Halfedge split(Edge e, Vertex v)
Split the edge
eby connecting vertexvit to the two vertices of the adjacent triangles that are opposite to edgee. Returns the halfedge pointing tovthat is created by splitting the existing edgee.See also
split(Edge, Point)
- Attention
This function is only valid for triangle meshes.
-
Halfedge insert_edge(Halfedge h0, Halfedge h1)
insert edge between the to-vertices v0 of
h0and v1 ofh1. returns the new halfedge from v0 to v1.- Attention
h0andh1have to belong to the same face
-
bool is_flip_ok(Edge e) const
Check whether flipping edge
eis topologicallySee also
flip(Edge)
- Attention
This function is only valid for triangle meshes.
-
void flip(Edge e)
Flip the edge
e. Removes the edgeeand add an edge between the two vertices opposite to edgeeof the two incident triangles.See also
is_flip_ok()
- Attention
This function is only valid for triangle meshes.
- Attention
Flipping an edge may result in a non-manifold mesh, hence check for yourself whether this operation is allowed or not!
-
size_t valence(Vertex v) const
returns the valence (number of incident edges or neighboring vertices) of vertex
v.
-
void duplicate_non_manifold_vertices(bool print = true)
attempts to fix non-manifold vertices by inserting a new vertex per connected patch
-
void remove_degenerate_faces(bool print = true)
removes any broken faces
-
void delete_many_faces(const FaceProperty<bool> &faces)
deletes all flagged faces and restores consistency
this is a lot faster for deleting large, preferably connected regions of the mesh than individually calling delete_face for each face. This is because delete_face needs to return a consistent halfedge structure after every single remove, even if the restored parts will be removed during a later call. This method can remove all removable parts first, and only then restore consistency where it is actually necessary. Another advantage is that most parts of this can be parallelized with OpenMP, which would not work for delete_face.
-
void split_mesh(std::vector<SurfaceMesh> &output, FaceProperty<IndexType> &face_dist, VertexProperty<IndexType> &vertex_dist)
Split the mesh into subset meshes. face_dist and vertex_dist contain the index of the target mesh in output or PMP_MAX_INDEX if the face or vertex should not be copied.
- Attention
All neighboring vertices and faces must be in the same subset. If your mesh does not meet this requirement, please duplicate faces/vertices until it does.
-
void join_mesh(const std::vector<const SurfaceMesh*> &input)
Adds everything in the input meshes to the current mesh.
-
inline bool has_garbage() const
are there any deleted entities?
Unifies h0 and h1 into a single edge, combining adjacent vertices. Requires both halfedges to be boundary halfedges.
-
inline std::vector<Point> &positions()
- Returns:
vector of point positions
-
inline const std::vector<Point> &positions() const
- Returns:
vector of point positions
-
BoundingBox bounds() const
compute the bounding box of the object
Allocate new elements
-
inline Vertex new_vertex()
Allocate a new vertex, resize vertex properties accordingly.
- Throws:
AllocationException – in case of failure to allocate a new vertex.
-
inline Halfedge new_edge()
Allocate a new edge, resize edge and halfedge properties accordingly.
- Throws:
AllocationException – in case of failure to allocate a new edge.
-
inline Halfedge new_edge(Vertex start, Vertex end)
Allocate a new edge, resize edge and halfedge properties accordingly.
- Throws:
AllocationException – in case of failure to allocate a new edge.
- Parameters:
start – starting Vertex of the new edge
end – end Vertex of the new edge
-
inline Face new_face()
Allocate a new face, resize face properties accordingly.
- Throws:
AllocationException – in case of failure to allocate a new face.
-
class CirculatorLoopDetector
-
class FaceAroundVertexCirculator
this class circulates through all incident faces of a vertex. it also acts as a container-concept for C++11 range-based for loops.
See also
VertexAroundVertexCirculator, HalfedgeAroundVertexCirculator, faces(Vertex)
Public Functions
-
inline FaceAroundVertexCirculator(const SurfaceMesh *m, Vertex v)
construct with mesh and vertex (vertex should not be isolated!)
-
inline bool operator==(const FaceAroundVertexCirculator &rhs) const
are two circulators equal?
-
inline bool operator!=(const FaceAroundVertexCirculator &rhs) const
are two circulators different?
-
inline FaceAroundVertexCirculator &operator++()
pre-increment (rotates counter-clockwise)
-
inline FaceAroundVertexCirculator &operator--()
pre-decrement (rotate clockwise)
-
inline operator bool() const
cast to bool: true if vertex is not isolated
-
inline FaceAroundVertexCirculator &begin()
-
inline FaceAroundVertexCirculator &end()
-
inline FaceAroundVertexCirculator(const SurfaceMesh *m, Vertex v)
-
class HalfedgeAroundFaceCirculator
this class circulates through all halfedges of a face. it also acts as a container-concept for C++11 range-based for loops.
See also
VertexAroundFaceCirculator, halfedges(Face)
Public Functions
-
inline HalfedgeAroundFaceCirculator(const SurfaceMesh *m, Face f)
default constructur
-
inline HalfedgeAroundFaceCirculator(const SurfaceMesh *m, Halfedge start)
-
inline bool operator==(const HalfedgeAroundFaceCirculator &rhs) const
are two circulators equal?
-
inline bool operator!=(const HalfedgeAroundFaceCirculator &rhs) const
are two circulators different?
-
inline HalfedgeAroundFaceCirculator &operator++()
pre-increment (rotates counter-clockwise)
-
inline HalfedgeAroundFaceCirculator &operator--()
pre-decrement (rotates clockwise)
-
inline HalfedgeAroundFaceCirculator &begin()
-
inline HalfedgeAroundFaceCirculator &end()
-
inline HalfedgeAroundFaceCirculator(const SurfaceMesh *m, Face f)
-
class HalfedgeAroundVertexCirculator
this class circulates through all outgoing halfedges of a vertex. it also acts as a container-concept for C++11 range-based for loops.
See also
VertexAroundVertexCirculator, halfedges(Vertex)
Public Functions
-
inline HalfedgeAroundVertexCirculator(const SurfaceMesh *mesh, Vertex v)
default constructor
-
inline bool operator==(const HalfedgeAroundVertexCirculator &rhs) const
are two circulators equal?
-
inline bool operator!=(const HalfedgeAroundVertexCirculator &rhs) const
are two circulators different?
-
inline HalfedgeAroundVertexCirculator &operator++()
pre-increment (rotate couter-clockwise)
-
inline HalfedgeAroundVertexCirculator &operator--()
pre-decrement (rotate clockwise)
-
inline operator bool() const
cast to bool: true if vertex is not isolated
-
inline HalfedgeAroundVertexCirculator &begin()
-
inline HalfedgeAroundVertexCirculator &end()
-
inline HalfedgeAroundVertexCirculator(const SurfaceMesh *mesh, Vertex v)
-
template<class HandleT>
class HandleContainer Public Functions
-
inline HandleContainer(HandleIterator<HandleT> begin, HandleIterator<HandleT> end)
-
inline HandleIterator<HandleT> begin() const
-
inline HandleIterator<HandleT> end() const
-
inline HandleContainer(HandleIterator<HandleT> begin, HandleIterator<HandleT> end)
-
template<class HandleT>
class HandleIterator : public lvr2::MeshHandleIterator<HandleT> Public Functions
-
inline HandleIterator(HandleT handle, const SurfaceMesh *m)
Default constructor.
-
inline bool operator==(const HandleIterator<HandleT> &rhs) const
are two iterators equal?
-
inline virtual bool operator==(const lvr2::MeshHandleIterator<HandleT> &other) const override
-
inline bool operator!=(const HandleIterator<HandleT> &rhs) const
are two iterators different?
-
inline virtual bool operator!=(const lvr2::MeshHandleIterator<HandleT> &other) const override
-
inline virtual HandleIterator &operator++() override
pre-increment iterator
-
inline HandleIterator operator++(int)
post-increment iterator
-
inline HandleIterator &operator--()
pre-decrement iterator
-
inline HandleIterator(HandleT handle, const SurfaceMesh *m)
-
class VertexAroundFaceCirculator
this class circulates through the vertices of a face. it also acts as a container-concept for C++11 range-based for loops.
See also
HalfedgeAroundFaceCirculator, vertices(Face)
Public Functions
-
inline VertexAroundFaceCirculator(const SurfaceMesh *m, Face f)
default constructor
-
inline bool operator==(const VertexAroundFaceCirculator &rhs) const
are two circulators equal?
-
inline bool operator!=(const VertexAroundFaceCirculator &rhs) const
are two circulators different?
-
inline VertexAroundFaceCirculator &operator++()
pre-increment (rotates counter-clockwise)
-
inline VertexAroundFaceCirculator &operator--()
pre-decrement (rotates clockwise)
-
inline VertexAroundFaceCirculator &begin()
-
inline VertexAroundFaceCirculator &end()
-
inline VertexAroundFaceCirculator(const SurfaceMesh *m, Face f)
-
class VertexAroundVertexCirculator
this class circulates through all one-ring neighbors of a vertex. it also acts as a container-concept for C++11 range-based for loops.
See also
HalfedgeAroundVertexCirculator, vertices(Vertex)
Public Functions
-
inline VertexAroundVertexCirculator(const SurfaceMesh *mesh, Vertex v)
default constructor
-
inline bool operator==(const VertexAroundVertexCirculator &rhs) const
are two circulators equal?
-
inline bool operator!=(const VertexAroundVertexCirculator &rhs) const
are two circulators different?
-
inline VertexAroundVertexCirculator &operator++()
pre-increment (rotate couter-clockwise)
-
inline VertexAroundVertexCirculator &operator--()
pre-decrement (rotate clockwise)
-
inline operator bool() const
cast to bool: true if vertex is not isolated
-
inline VertexAroundVertexCirculator &begin()
-
inline VertexAroundVertexCirculator &end()
-
inline VertexAroundVertexCirculator(const SurfaceMesh *mesh, Vertex v)
-
using VertexIterator = HandleIterator<Vertex>