OpenMesh

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PolyConnectivity.hh
1 /*===========================================================================*\
2 * *
3 * OpenMesh *
4 * Copyright (C) 2001-2014 by Computer Graphics Group, RWTH Aachen *
5 * www.openmesh.org *
6 * *
7 *---------------------------------------------------------------------------*
8 * This file is part of OpenMesh. *
9 * *
10 * OpenMesh is free software: you can redistribute it and/or modify *
11 * it under the terms of the GNU Lesser General Public License as *
12 * published by the Free Software Foundation, either version 3 of *
13 * the License, or (at your option) any later version with the *
14 * following exceptions: *
15 * *
16 * If other files instantiate templates or use macros *
17 * or inline functions from this file, or you compile this file and *
18 * link it with other files to produce an executable, this file does *
19 * not by itself cause the resulting executable to be covered by the *
20 * GNU Lesser General Public License. This exception does not however *
21 * invalidate any other reasons why the executable file might be *
22 * covered by the GNU Lesser General Public License. *
23 * *
24 * OpenMesh is distributed in the hope that it will be useful, *
25 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
26 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
27 * GNU Lesser General Public License for more details. *
28 * *
29 * You should have received a copy of the GNU LesserGeneral Public *
30 * License along with OpenMesh. If not, *
31 * see <http://www.gnu.org/licenses/>. *
32 * *
33 \*===========================================================================*/
34
35 /*===========================================================================*\
36 * *
37 * $Revision: 990 $ *
38 * $Date: 2014-02-05 10:01:07 +0100 (Mi, 05. Feb 2014) $ *
39 * *
40 \*===========================================================================*/
41
42 #ifndef OPENMESH_POLYCONNECTIVITY_HH
43 #define OPENMESH_POLYCONNECTIVITY_HH
44
45 #include <OpenMesh/Core/Mesh/ArrayKernel.hh>
46 #include <OpenMesh/Core/Mesh/IteratorsT.hh>
47 #include <OpenMesh/Core/Mesh/CirculatorsT.hh>
48
49 namespace OpenMesh
50 {
51
54 class OPENMESHDLLEXPORT PolyConnectivity : public ArrayKernel
55 {
56 public:
58
59 static const VertexHandle InvalidVertexHandle;
62 static const HalfedgeHandle InvalidHalfedgeHandle;
64 static const EdgeHandle InvalidEdgeHandle;
66 static const FaceHandle InvalidFaceHandle;
68
69 typedef PolyConnectivity This;
70
71 //--- iterators ---
72
78 typedef Iterators::GenericIteratorT<This, This::VertexHandle, ArrayKernel, &This::has_vertex_status, &This::n_vertices> VertexIter;
80 typedef Iterators::GenericIteratorT<This, This::HalfedgeHandle, ArrayKernel, &This::has_halfedge_status, &This::n_halfedges> HalfedgeIter;
81 typedef Iterators::GenericIteratorT<This, This::EdgeHandle, ArrayKernel, &This::has_edge_status, &This::n_edges> EdgeIter;
82 typedef Iterators::GenericIteratorT<This, This::FaceHandle, ArrayKernel, &This::has_face_status, &This::n_faces> FaceIter;
83
84 typedef VertexIter ConstVertexIter;
85 typedef HalfedgeIter ConstHalfedgeIter;
86 typedef EdgeIter ConstEdgeIter;
87 typedef FaceIter ConstFaceIter;
89
90 //--- circulators ---
91
97
98 /*
99 * Vertex-centered circulators
100 */
101 typedef Iterators::GenericCirculatorT<This, This::VertexHandle, This::VertexHandle,
102 &Iterators::GenericCirculatorBaseT<This>::toVertexHandle>
103 VertexVertexIter;
104
105 typedef Iterators::GenericCirculatorT<This, This::VertexHandle, This::HalfedgeHandle,
106 &Iterators::GenericCirculatorBaseT<This>::toHalfedgeHandle>
107 VertexOHalfedgeIter;
108
109 typedef Iterators::GenericCirculatorT<This, This::VertexHandle, This::HalfedgeHandle,
110 &Iterators::GenericCirculatorBaseT<This>::toOppositeHalfedgeHandle>
111 VertexIHalfedgeIter;
112
113 typedef Iterators::GenericCirculatorT<This, This::VertexHandle, This::FaceHandle,
114 &Iterators::GenericCirculatorBaseT<This>::toFaceHandle>
115 VertexFaceIter;
116
117 typedef Iterators::GenericCirculatorT<This, This::VertexHandle, This::EdgeHandle,
118 &Iterators::GenericCirculatorBaseT<This>::toEdgeHandle>
119 VertexEdgeIter;
120
121 typedef Iterators::GenericCirculatorT<This, This::FaceHandle, This::HalfedgeHandle,
122 &Iterators::GenericCirculatorBaseT<This>::toHalfedgeHandle>
123 HalfedgeLoopIter;
124
125 typedef VertexVertexIter ConstVertexVertexIter;
126 typedef VertexOHalfedgeIter ConstVertexOHalfedgeIter;
127 typedef VertexIHalfedgeIter ConstVertexIHalfedgeIter;
128 typedef VertexFaceIter ConstVertexFaceIter;
129 typedef VertexEdgeIter ConstVertexEdgeIter;
130
131 /*
132 * Face-centered circulators
133 */
134 typedef Iterators::GenericCirculatorT<This, This::FaceHandle, This::VertexHandle,
135 &Iterators::GenericCirculatorBaseT<This>::toVertexHandle>
136 FaceVertexIter;
137
138 typedef Iterators::GenericCirculatorT<This, This::FaceHandle, This::HalfedgeHandle,
139 &Iterators::GenericCirculatorBaseT<This>::toHalfedgeHandle>
140 FaceHalfedgeIter;
141
142 typedef Iterators::GenericCirculatorT<This, This::FaceHandle, This::EdgeHandle,
143 &Iterators::GenericCirculatorBaseT<This>::toEdgeHandle>
144 FaceEdgeIter;
145
146 typedef Iterators::GenericCirculatorT<This, This::FaceHandle, This::FaceHandle,
147 &Iterators::GenericCirculatorBaseT<This>::toOppositeFaceHandle>
148 FaceFaceIter;
149
150 typedef FaceVertexIter ConstFaceVertexIter;
151 typedef FaceHalfedgeIter ConstFaceHalfedgeIter;
152 typedef FaceEdgeIter ConstFaceEdgeIter;
153 typedef FaceFaceIter ConstFaceFaceIter;
154
155 /*
156 * Halfedge circulator
157 */
158 typedef HalfedgeLoopIter ConstHalfedgeLoopIter;
159
161
162 // --- shortcuts
163
168 typedef VertexHandle VHandle;
170 typedef HalfedgeHandle HHandle;
171 typedef EdgeHandle EHandle;
172 typedef FaceHandle FHandle;
173
174 typedef VertexIter VIter;
175 typedef HalfedgeIter HIter;
176 typedef EdgeIter EIter;
177 typedef FaceIter FIter;
178
179 typedef ConstVertexIter CVIter;
180 typedef ConstHalfedgeIter CHIter;
181 typedef ConstEdgeIter CEIter;
182 typedef ConstFaceIter CFIter;
183
184 typedef VertexVertexIter VVIter;
185 typedef VertexOHalfedgeIter VOHIter;
186 typedef VertexIHalfedgeIter VIHIter;
187 typedef VertexEdgeIter VEIter;
188 typedef VertexFaceIter VFIter;
189 typedef FaceVertexIter FVIter;
190 typedef FaceHalfedgeIter FHIter;
191 typedef FaceEdgeIter FEIter;
192 typedef FaceFaceIter FFIter;
193
194 typedef ConstVertexVertexIter CVVIter;
195 typedef ConstVertexOHalfedgeIter CVOHIter;
196 typedef ConstVertexIHalfedgeIter CVIHIter;
197 typedef ConstVertexEdgeIter CVEIter;
198 typedef ConstVertexFaceIter CVFIter;
199 typedef ConstFaceVertexIter CFVIter;
200 typedef ConstFaceHalfedgeIter CFHIter;
201 typedef ConstFaceEdgeIter CFEIter;
202 typedef ConstFaceFaceIter CFFIter;
204
205 public:
206
207 PolyConnectivity() {}
208 virtual ~PolyConnectivity() {}
209
210 inline static bool is_triangles()
211 { return false; }
212
215 inline void assign_connectivity(const PolyConnectivity& _other)
216 { ArrayKernel::assign_connectivity(_other); }
217
221
223 inline VertexHandle add_vertex()
224 { return new_vertex(); }
225
233 FaceHandle add_face(const std::vector<VertexHandle>& _vhandles);
234
235
245 FaceHandle add_face(VertexHandle _vh0, VertexHandle _vh1, VertexHandle _vh2);
246
257 FaceHandle add_face(VertexHandle _vh0, VertexHandle _vh1, VertexHandle _vh2, VertexHandle _vh3);
258
267 FaceHandle add_face(const VertexHandle* _vhandles, size_t _vhs_size);
268
270
272
273
278 bool is_collapse_ok(HalfedgeHandle _he);
279
280
286 void delete_vertex(VertexHandle _vh, bool _delete_isolated_vertices = true);
287
296 void delete_edge(EdgeHandle _eh, bool _delete_isolated_vertices=true);
297
308 void delete_face(FaceHandle _fh, bool _delete_isolated_vertices=true);
309
311
315
317 VertexIter vertices_begin();
319 ConstVertexIter vertices_begin() const;
321 VertexIter vertices_end();
323 ConstVertexIter vertices_end() const;
324
326 HalfedgeIter halfedges_begin();
328 ConstHalfedgeIter halfedges_begin() const;
330 HalfedgeIter halfedges_end();
332 ConstHalfedgeIter halfedges_end() const;
333
335 EdgeIter edges_begin();
337 ConstEdgeIter edges_begin() const;
339 EdgeIter edges_end();
341 ConstEdgeIter edges_end() const;
342
344 FaceIter faces_begin();
346 ConstFaceIter faces_begin() const;
348 FaceIter faces_end();
350 ConstFaceIter faces_end() const;
351
352 template<typename CONTAINER_TYPE, typename ITER_TYPE, ITER_TYPE (CONTAINER_TYPE::*begin_fn)(), ITER_TYPE (CONTAINER_TYPE::*end_fn)()>
353 class EntityRange {
354 public:
355 EntityRange(CONTAINER_TYPE &container) : container_(container) {}
356 ITER_TYPE begin() { return (container_.*begin_fn)(); }
357 ITER_TYPE end() { return (container_.*end_fn)(); }
358
359 private:
360 CONTAINER_TYPE &container_;
361 };
362 typedef EntityRange<const PolyConnectivity, PolyConnectivity::ConstVertexIter, &PolyConnectivity::vertices_begin, &PolyConnectivity::vertices_end> ConstVertexRange;
363 typedef EntityRange<const PolyConnectivity, PolyConnectivity::ConstHalfedgeIter, &PolyConnectivity::halfedges_begin, &PolyConnectivity::halfedges_end> ConstHalfedgeRange;
364 typedef EntityRange<const PolyConnectivity, PolyConnectivity::ConstEdgeIter, &PolyConnectivity::edges_begin, &PolyConnectivity::edges_end> ConstEdgeRange;
365 typedef EntityRange<const PolyConnectivity, PolyConnectivity::ConstFaceIter, &PolyConnectivity::faces_begin, &PolyConnectivity::faces_end> ConstFaceRange;
366
370 ConstVertexRange vertices() const { return ConstVertexRange(*this); }
371
375 ConstHalfedgeRange halfedges() const { return ConstHalfedgeRange(*this); }
376
380 ConstEdgeRange edges() const { return ConstEdgeRange(*this); }
381
385 ConstFaceRange faces() const { return ConstFaceRange(*this); }
387
388
389
393
395 VertexIter vertices_sbegin()
396 { return VertexIter(*this, VertexHandle(0), true); }
398 ConstVertexIter vertices_sbegin() const
399 { return ConstVertexIter(*this, VertexHandle(0), true); }
400
402 HalfedgeIter halfedges_sbegin()
403 { return HalfedgeIter(*this, HalfedgeHandle(0), true); }
405 ConstHalfedgeIter halfedges_sbegin() const
406 { return ConstHalfedgeIter(*this, HalfedgeHandle(0), true); }
407
409 EdgeIter edges_sbegin()
410 { return EdgeIter(*this, EdgeHandle(0), true); }
412 ConstEdgeIter edges_sbegin() const
413 { return ConstEdgeIter(*this, EdgeHandle(0), true); }
414
416 FaceIter faces_sbegin()
417 { return FaceIter(*this, FaceHandle(0), true); }
419 ConstFaceIter faces_sbegin() const
420 { return ConstFaceIter(*this, FaceHandle(0), true); }
421
423
424 //--- circulators ---
425
429
431 VertexVertexIter vv_iter(VertexHandle _vh)
432 { return VertexVertexIter(*this, _vh); }
434 VertexIHalfedgeIter vih_iter(VertexHandle _vh)
435 { return VertexIHalfedgeIter(*this, _vh); }
437 VertexOHalfedgeIter voh_iter(VertexHandle _vh)
438 { return VertexOHalfedgeIter(*this, _vh); }
440 VertexEdgeIter ve_iter(VertexHandle _vh)
441 { return VertexEdgeIter(*this, _vh); }
443 VertexFaceIter vf_iter(VertexHandle _vh)
444 { return VertexFaceIter(*this, _vh); }
445
447 ConstVertexVertexIter cvv_iter(VertexHandle _vh) const
448 { return ConstVertexVertexIter(*this, _vh); }
450 ConstVertexIHalfedgeIter cvih_iter(VertexHandle _vh) const
451 { return ConstVertexIHalfedgeIter(*this, _vh); }
453 ConstVertexOHalfedgeIter cvoh_iter(VertexHandle _vh) const
454 { return ConstVertexOHalfedgeIter(*this, _vh); }
456 ConstVertexEdgeIter cve_iter(VertexHandle _vh) const
457 { return ConstVertexEdgeIter(*this, _vh); }
459 ConstVertexFaceIter cvf_iter(VertexHandle _vh) const
460 { return ConstVertexFaceIter(*this, _vh); }
461
463 FaceVertexIter fv_iter(FaceHandle _fh)
464 { return FaceVertexIter(*this, _fh); }
466 FaceHalfedgeIter fh_iter(FaceHandle _fh)
467 { return FaceHalfedgeIter(*this, _fh); }
469 FaceEdgeIter fe_iter(FaceHandle _fh)
470 { return FaceEdgeIter(*this, _fh); }
472 FaceFaceIter ff_iter(FaceHandle _fh)
473 { return FaceFaceIter(*this, _fh); }
474
476 ConstFaceVertexIter cfv_iter(FaceHandle _fh) const
477 { return ConstFaceVertexIter(*this, _fh); }
479 ConstFaceHalfedgeIter cfh_iter(FaceHandle _fh) const
480 { return ConstFaceHalfedgeIter(*this, _fh); }
482 ConstFaceEdgeIter cfe_iter(FaceHandle _fh) const
483 { return ConstFaceEdgeIter(*this, _fh); }
485 ConstFaceFaceIter cff_iter(FaceHandle _fh) const
486 { return ConstFaceFaceIter(*this, _fh); }
487
488 // 'begin' circulators
489
491 VertexVertexIter vv_begin(VertexHandle _vh)
492 { return VertexVertexIter(*this, _vh); }
494 VertexIHalfedgeIter vih_begin(VertexHandle _vh)
495 { return VertexIHalfedgeIter(*this, _vh); }
497 VertexOHalfedgeIter voh_begin(VertexHandle _vh)
498 { return VertexOHalfedgeIter(*this, _vh); }
500 VertexEdgeIter ve_begin(VertexHandle _vh)
501 { return VertexEdgeIter(*this, _vh); }
503 VertexFaceIter vf_begin(VertexHandle _vh)
504 { return VertexFaceIter(*this, _vh); }
505
507 ConstVertexVertexIter cvv_begin(VertexHandle _vh) const
508 { return ConstVertexVertexIter(*this, _vh); }
510 ConstVertexIHalfedgeIter cvih_begin(VertexHandle _vh) const
511 { return ConstVertexIHalfedgeIter(*this, _vh); }
513 ConstVertexOHalfedgeIter cvoh_begin(VertexHandle _vh) const
514 { return ConstVertexOHalfedgeIter(*this, _vh); }
516 ConstVertexEdgeIter cve_begin(VertexHandle _vh) const
517 { return ConstVertexEdgeIter(*this, _vh); }
519 ConstVertexFaceIter cvf_begin(VertexHandle _vh) const
520 { return ConstVertexFaceIter(*this, _vh); }
521
523 FaceVertexIter fv_begin(FaceHandle _fh)
524 { return FaceVertexIter(*this, _fh); }
526 FaceHalfedgeIter fh_begin(FaceHandle _fh)
527 { return FaceHalfedgeIter(*this, _fh); }
529 FaceEdgeIter fe_begin(FaceHandle _fh)
530 { return FaceEdgeIter(*this, _fh); }
532 FaceFaceIter ff_begin(FaceHandle _fh)
533 { return FaceFaceIter(*this, _fh); }
535 HalfedgeLoopIter hl_begin(HalfedgeHandle _heh)
536 { return HalfedgeLoopIter(*this, _heh); }
537
539 ConstFaceVertexIter cfv_begin(FaceHandle _fh) const
540 { return ConstFaceVertexIter(*this, _fh); }
542 ConstFaceHalfedgeIter cfh_begin(FaceHandle _fh) const
543 { return ConstFaceHalfedgeIter(*this, _fh); }
545 ConstFaceEdgeIter cfe_begin(FaceHandle _fh) const
546 { return ConstFaceEdgeIter(*this, _fh); }
548 ConstFaceFaceIter cff_begin(FaceHandle _fh) const
549 { return ConstFaceFaceIter(*this, _fh); }
551 ConstHalfedgeLoopIter chl_begin(HalfedgeHandle _heh) const
552 { return ConstHalfedgeLoopIter(*this, _heh); }
553
554 // 'end' circulators
555
557 VertexVertexIter vv_end(VertexHandle _vh)
558 { return VertexVertexIter(*this, _vh, true); }
560 VertexIHalfedgeIter vih_end(VertexHandle _vh)
561 { return VertexIHalfedgeIter(*this, _vh, true); }
563 VertexOHalfedgeIter voh_end(VertexHandle _vh)
564 { return VertexOHalfedgeIter(*this, _vh, true); }
566 VertexEdgeIter ve_end(VertexHandle _vh)
567 { return VertexEdgeIter(*this, _vh, true); }
569 VertexFaceIter vf_end(VertexHandle _vh)
570 { return VertexFaceIter(*this, _vh, true); }
571
573 ConstVertexVertexIter cvv_end(VertexHandle _vh) const
574 { return ConstVertexVertexIter(*this, _vh, true); }
576 ConstVertexIHalfedgeIter cvih_end(VertexHandle _vh) const
577 { return ConstVertexIHalfedgeIter(*this, _vh, true); }
579 ConstVertexOHalfedgeIter cvoh_end(VertexHandle _vh) const
580 { return ConstVertexOHalfedgeIter(*this, _vh, true); }
582 ConstVertexEdgeIter cve_end(VertexHandle _vh) const
583 { return ConstVertexEdgeIter(*this, _vh, true); }
585 ConstVertexFaceIter cvf_end(VertexHandle _vh) const
586 { return ConstVertexFaceIter(*this, _vh, true); }
587
589 FaceVertexIter fv_end(FaceHandle _fh)
590 { return FaceVertexIter(*this, _fh, true); }
592 FaceHalfedgeIter fh_end(FaceHandle _fh)
593 { return FaceHalfedgeIter(*this, _fh, true); }
595 FaceEdgeIter fe_end(FaceHandle _fh)
596 { return FaceEdgeIter(*this, _fh, true); }
598 FaceFaceIter ff_end(FaceHandle _fh)
599 { return FaceFaceIter(*this, _fh, true); }
601 HalfedgeLoopIter hl_end(HalfedgeHandle _heh)
602 { return HalfedgeLoopIter(*this, _heh, true); }
603
605 ConstFaceVertexIter cfv_end(FaceHandle _fh) const
606 { return ConstFaceVertexIter(*this, _fh, true); }
608 ConstFaceHalfedgeIter cfh_end(FaceHandle _fh) const
609 { return ConstFaceHalfedgeIter(*this, _fh, true); }
611 ConstFaceEdgeIter cfe_end(FaceHandle _fh) const
612 { return ConstFaceEdgeIter(*this, _fh, true); }
614 ConstFaceFaceIter cff_end(FaceHandle _fh) const
615 { return ConstFaceFaceIter(*this, _fh, true); }
617 ConstHalfedgeLoopIter chl_end(HalfedgeHandle _heh) const
618 { return ConstHalfedgeLoopIter(*this, _heh, true); }
620
621
622 //===========================================================================
625 //===========================================================================
626
634 bool is_boundary(HalfedgeHandle _heh) const
635 { return ArrayKernel::is_boundary(_heh); }
636
645 bool is_boundary(EdgeHandle _eh) const
646 {
647 return (is_boundary(halfedge_handle(_eh, 0)) ||
648 is_boundary(halfedge_handle(_eh, 1)));
649 }
650
662 bool is_boundary(VertexHandle _vh) const
663 {
664 HalfedgeHandle heh(halfedge_handle(_vh));
665 return (!(heh.is_valid() && face_handle(heh).is_valid()));
666 }
667
677 bool is_boundary(FaceHandle _fh, bool _check_vertex=false) const;
678
689 bool is_manifold(VertexHandle _vh) const;
690
693 // --- shortcuts ---
694
696 inline FaceHandle opposite_face_handle(HalfedgeHandle _heh) const
697 { return face_handle(opposite_halfedge_handle(_heh)); }
698
699 // --- misc ---
700
704 void adjust_outgoing_halfedge(VertexHandle _vh);
705
707 HalfedgeHandle find_halfedge(VertexHandle _start_vh, VertexHandle _end_vh) const;
709 uint valence(VertexHandle _vh) const;
711 uint valence(FaceHandle _fh) const;
712
713 // --- connectivity operattions
714
729 void collapse(HalfedgeHandle _heh);
734 bool is_simple_link(EdgeHandle _eh) const;
739 bool is_simply_connected(FaceHandle _fh) const;
752 FaceHandle remove_edge(EdgeHandle _eh);
756 void reinsert_edge(EdgeHandle _eh);
766 HalfedgeHandle insert_edge(HalfedgeHandle _prev_heh, HalfedgeHandle _next_heh);
767
780 void split(FaceHandle _fh, VertexHandle _vh);
781
795 void split_copy(FaceHandle _fh, VertexHandle _vh);
796
810 void triangulate(FaceHandle _fh);
811
814 void triangulate();
815
826 void split_edge(EdgeHandle _eh, VertexHandle _vh);
827
839 void split_edge_copy(EdgeHandle _eh, VertexHandle _vh);
840
841
847 const Vertex& deref(VertexHandle _h) const { return vertex(_h); }
849 Vertex& deref(VertexHandle _h) { return vertex(_h); }
850 const Halfedge& deref(HalfedgeHandle _h) const { return halfedge(_h); }
851 Halfedge& deref(HalfedgeHandle _h) { return halfedge(_h); }
852 const Edge& deref(EdgeHandle _h) const { return edge(_h); }
853 Edge& deref(EdgeHandle _h) { return edge(_h); }
854 const Face& deref(FaceHandle _h) const { return face(_h); }
855 Face& deref(FaceHandle _h) { return face(_h); }
857
858 protected:
860 void collapse_edge(HalfedgeHandle _hh);
862 void collapse_loop(HalfedgeHandle _hh);
863
864
865
866 private: // Working storage for add_face()
867 struct AddFaceEdgeInfo
868 {
869 HalfedgeHandle halfedge_handle;
870 bool is_new;
871 bool needs_adjust;
872 };
873 std::vector<AddFaceEdgeInfo> edgeData_; //
874 std::vector<std::pair<HalfedgeHandle, HalfedgeHandle> > next_cache_; // cache for set_next_halfedge and vertex' set_halfedge
875 uint next_cache_count_;
876
877 };
878
879 }//namespace OpenMesh
880
881 #endif//OPENMESH_POLYCONNECTIVITY_HH
OpenMesh::PolyConnectivity::ConstEdgeRange
EntityRange< const PolyConnectivity, PolyConnectivity::ConstEdgeIter,&PolyConnectivity::edges_begin,&PolyConnectivity::edges_end > ConstEdgeRange
Begin iterator for vertices.
Definition: PolyConnectivity.hh:364
OpenMesh::PolyConnectivity::VEIter
VertexEdgeIter VEIter
Alias typedef.
Definition: PolyConnectivity.hh:187
OpenMesh::PolyConnectivity
Connectivity Class for polygonal meshes.
Definition: PolyConnectivity.hh:54
OpenMesh::EdgeHandle
Handle for a edge entity.
Definition: Handles.hh:128
OpenMesh::PolyConnectivity::cvv_end
ConstVertexVertexIter cvv_end(VertexHandle _vh) const
const vertex circulator
Definition: PolyConnectivity.hh:573
OpenMesh::PolyConnectivity::ve_end
VertexEdgeIter ve_end(VertexHandle _vh)
vertex - edge circulator
Definition: PolyConnectivity.hh:566
OpenMesh::PolyConnectivity::fe_iter
FaceEdgeIter fe_iter(FaceHandle _fh)
face - edge circulator
Definition: PolyConnectivity.hh:469
OpenMesh::PolyConnectivity::cfv_begin
ConstFaceVertexIter cfv_begin(FaceHandle _fh) const
const face - vertex circulator
Definition: PolyConnectivity.hh:539
OpenMesh::PolyConnectivity::cfv_end
ConstFaceVertexIter cfv_end(FaceHandle _fh) const
const face - vertex circulator
Definition: PolyConnectivity.hh:605
OpenMesh::PolyConnectivity::VOHIter
VertexOHalfedgeIter VOHIter
Alias typedef.
Definition: PolyConnectivity.hh:185
OpenMesh::PolyConnectivity::ff_end
FaceFaceIter ff_end(FaceHandle _fh)
face - face circulator
Definition: PolyConnectivity.hh:598
OpenMesh::PolyConnectivity::is_boundary
bool is_boundary(HalfedgeHandle _heh) const
Check if the halfedge is at the boundary.
Definition: PolyConnectivity.hh:634
OpenMesh::PolyConnectivity::faces_sbegin
FaceIter faces_sbegin()
Begin iterator for faces.
Definition: PolyConnectivity.hh:416
OpenMesh::PolyConnectivity::deref
Face & deref(FaceHandle _h)
Get item from handle.
Definition: PolyConnectivity.hh:855
OpenMesh::PolyConnectivity::vv_iter
VertexVertexIter vv_iter(VertexHandle _vh)
vertex - vertex circulator
Definition: PolyConnectivity.hh:431
OpenMesh::PolyConnectivity::vv_end
VertexVertexIter vv_end(VertexHandle _vh)
vertex - vertex circulator
Definition: PolyConnectivity.hh:557
OpenMesh::PolyConnectivity::CVIHIter
ConstVertexIHalfedgeIter CVIHIter
Alias typedef.
Definition: PolyConnectivity.hh:196
OpenMesh::PolyConnectivity::cfe_iter
ConstFaceEdgeIter cfe_iter(FaceHandle _fh) const
const face - edge circulator
Definition: PolyConnectivity.hh:482
OpenMesh::PolyConnectivity::cfv_iter
ConstFaceVertexIter cfv_iter(FaceHandle _fh) const
const face - vertex circulator
Definition: PolyConnectivity.hh:476
OpenMesh::PolyConnectivity::CFEIter
ConstFaceEdgeIter CFEIter
Alias typedef.
Definition: PolyConnectivity.hh:201
OpenMesh::PolyConnectivity::FEIter
FaceEdgeIter FEIter
Alias typedef.
Definition: PolyConnectivity.hh:191
OpenMesh::PolyConnectivity::CFIter
ConstFaceIter CFIter
Alias typedef.
Definition: PolyConnectivity.hh:182
OpenMesh::PolyConnectivity::FFIter
FaceFaceIter FFIter
Alias typedef.
Definition: PolyConnectivity.hh:192
OpenMesh::PolyConnectivity::cvoh_end
ConstVertexOHalfedgeIter cvoh_end(VertexHandle _vh) const
const vertex - outgoing halfedge circulator
Definition: PolyConnectivity.hh:579
OpenMesh::PolyConnectivity::cvih_end
ConstVertexIHalfedgeIter cvih_end(VertexHandle _vh) const
const vertex - incoming halfedge circulator
Definition: PolyConnectivity.hh:576
OpenMesh::PolyConnectivity::cve_begin
ConstVertexEdgeIter cve_begin(VertexHandle _vh) const
const vertex - edge circulator
Definition: PolyConnectivity.hh:516
OpenMesh::Iterators::GenericCirculatorBaseT
Definition: CirculatorsT.hh:159
OpenMesh::PolyConnectivity::hl_end
HalfedgeLoopIter hl_end(HalfedgeHandle _heh)
face - face circulator
Definition: PolyConnectivity.hh:601
OpenMesh::PolyConnectivity::CFHIter
ConstFaceHalfedgeIter CFHIter
Alias typedef.
Definition: PolyConnectivity.hh:200
OpenMesh::PolyConnectivity::vih_begin
VertexIHalfedgeIter vih_begin(VertexHandle _vh)
vertex - incoming halfedge circulator
Definition: PolyConnectivity.hh:494
OpenMesh::PolyConnectivity::FHIter
FaceHalfedgeIter FHIter
Alias typedef.
Definition: PolyConnectivity.hh:190
OpenMesh::BaseHandle::is_valid
bool is_valid() const
The handle is valid iff the index is not equal to -1.
Definition: Handles.hh:70
OpenMesh::PolyConnectivity::vih_end
VertexIHalfedgeIter vih_end(VertexHandle _vh)
vertex - incoming halfedge circulator
Definition: PolyConnectivity.hh:560
OpenMesh::PolyConnectivity::fh_iter
FaceHalfedgeIter fh_iter(FaceHandle _fh)
face - halfedge circulator
Definition: PolyConnectivity.hh:466
OpenMesh::PolyConnectivity::InvalidHalfedgeHandle
static const HalfedgeHandle InvalidHalfedgeHandle
Invalid handle.
Definition: PolyConnectivity.hh:62
OpenMesh::PolyConnectivity::fe_begin
FaceEdgeIter fe_begin(FaceHandle _fh)
face - edge circulator
Definition: PolyConnectivity.hh:529
OpenMesh::PolyConnectivity::HHandle
HalfedgeHandle HHandle
Alias typedef.
Definition: PolyConnectivity.hh:170
OpenMesh::PolyConnectivity::HIter
HalfedgeIter HIter
Alias typedef.
Definition: PolyConnectivity.hh:175
OpenMesh::PolyConnectivity::cvoh_begin
ConstVertexOHalfedgeIter cvoh_begin(VertexHandle _vh) const
const vertex - outgoing halfedge circulator
Definition: PolyConnectivity.hh:513
OpenMesh::PolyConnectivity::edges_sbegin
EdgeIter edges_sbegin()
Begin iterator for edges.
Definition: PolyConnectivity.hh:409
OpenMesh::PolyConnectivity::cve_end
ConstVertexEdgeIter cve_end(VertexHandle _vh) const
const vertex - edge circulator
Definition: PolyConnectivity.hh:582
OpenMesh::PolyConnectivity::vertices_sbegin
ConstVertexIter vertices_sbegin() const
Const begin iterator for vertices.
Definition: PolyConnectivity.hh:398
OpenMesh::PolyConnectivity::vf_iter
VertexFaceIter vf_iter(VertexHandle _vh)
vertex - face circulator
Definition: PolyConnectivity.hh:443
OpenMesh::PolyConnectivity::VIHIter
VertexIHalfedgeIter VIHIter
Alias typedef.
Definition: PolyConnectivity.hh:186
OpenMesh::PolyConnectivity::halfedges
ConstHalfedgeRange halfedges() const
Definition: PolyConnectivity.hh:375
OpenMesh::PolyConnectivity::deref
Halfedge & deref(HalfedgeHandle _h)
Get item from handle.
Definition: PolyConnectivity.hh:851
OpenMesh::PolyConnectivity::cfh_iter
ConstFaceHalfedgeIter cfh_iter(FaceHandle _fh) const
const face - halfedge circulator
Definition: PolyConnectivity.hh:479
OpenMesh::PolyConnectivity::cvv_begin
ConstVertexVertexIter cvv_begin(VertexHandle _vh) const
const vertex circulator
Definition: PolyConnectivity.hh:507
OpenMesh::PolyConnectivity::cff_begin
ConstFaceFaceIter cff_begin(FaceHandle _fh) const
const face - face circulator
Definition: PolyConnectivity.hh:548
OpenMesh::PolyConnectivity::chl_begin
ConstHalfedgeLoopIter chl_begin(HalfedgeHandle _heh) const
const halfedge circulator
Definition: PolyConnectivity.hh:551
OpenMesh::PolyConnectivity::fv_iter
FaceVertexIter fv_iter(FaceHandle _fh)
face - vertex circulator
Definition: PolyConnectivity.hh:463
OpenMesh::PolyConnectivity::voh_begin
VertexOHalfedgeIter voh_begin(VertexHandle _vh)
vertex - outgoing halfedge circulator
Definition: PolyConnectivity.hh:497
OpenMesh::PolyConnectivity::is_boundary
bool is_boundary(EdgeHandle _eh) const
Is the edge a boundary edge?
Definition: PolyConnectivity.hh:645
OpenMesh::PolyConnectivity::CVEIter
ConstVertexEdgeIter CVEIter
Alias typedef.
Definition: PolyConnectivity.hh:197
OpenMesh::PolyConnectivity::EdgeIter
Iterators::GenericIteratorT< This, This::EdgeHandle, ArrayKernel,&This::has_edge_status,&This::n_edges > EdgeIter
Linear iterator.
Definition: PolyConnectivity.hh:81
OpenMesh::PolyConnectivity::halfedges_sbegin
HalfedgeIter halfedges_sbegin()
Begin iterator for halfedges.
Definition: PolyConnectivity.hh:402
OpenMesh::PolyConnectivity::cfe_begin
ConstFaceEdgeIter cfe_begin(FaceHandle _fh) const
const face - edge circulator
Definition: PolyConnectivity.hh:545
OpenMesh::PolyConnectivity::edges_sbegin
ConstEdgeIter edges_sbegin() const
Const begin iterator for edges.
Definition: PolyConnectivity.hh:412
OpenMesh::PolyConnectivity::halfedges_sbegin
ConstHalfedgeIter halfedges_sbegin() const
Const begin iterator for halfedges.
Definition: PolyConnectivity.hh:405
OpenMesh::PolyConnectivity::VIter
VertexIter VIter
Alias typedef.
Definition: PolyConnectivity.hh:174
OpenMesh::PolyConnectivity::CVVIter
ConstVertexVertexIter CVVIter
Alias typedef.
Definition: PolyConnectivity.hh:194
OpenMesh::PolyConnectivity::ConstHalfedgeIter
HalfedgeIter ConstHalfedgeIter
Linear iterator.
Definition: PolyConnectivity.hh:85
OpenMesh::PolyConnectivity::vf_end
VertexFaceIter vf_end(VertexHandle _vh)
vertex - face circulator
Definition: PolyConnectivity.hh:569
OpenMesh::PolyConnectivity::faces
ConstFaceRange faces() const
Definition: PolyConnectivity.hh:385
OpenMesh::FaceHandle
Handle for a face entity.
Definition: Handles.hh:135
OpenMesh::VertexHandle
Handle for a vertex entity.
Definition: Handles.hh:114
OpenMesh::PolyConnectivity::deref
Edge & deref(EdgeHandle _h)
Get item from handle.
Definition: PolyConnectivity.hh:853
OpenMesh::Iterators::GenericIteratorT
Definition: IteratorsT.hh:82
OpenMesh::PolyConnectivity::VVIter
VertexVertexIter VVIter
Alias typedef.
Definition: PolyConnectivity.hh:184
OpenMesh::PolyConnectivity::CEIter
ConstEdgeIter CEIter
Alias typedef.
Definition: PolyConnectivity.hh:181
OpenMesh::PolyConnectivity::fe_end
FaceEdgeIter fe_end(FaceHandle _fh)
face - edge circulator
Definition: PolyConnectivity.hh:595
OpenMesh::PolyConnectivity::ff_iter
FaceFaceIter ff_iter(FaceHandle _fh)
face - face circulator
Definition: PolyConnectivity.hh:472
OpenMesh::PolyConnectivity::cff_iter
ConstFaceFaceIter cff_iter(FaceHandle _fh) const
const face - face circulator
Definition: PolyConnectivity.hh:485
OpenMesh::PolyConnectivity::ConstFaceIter
FaceIter ConstFaceIter
Linear iterator.
Definition: PolyConnectivity.hh:87
OpenMesh::PolyConnectivity::HalfedgeIter
Iterators::GenericIteratorT< This, This::HalfedgeHandle, ArrayKernel,&This::has_halfedge_status,&This::n_halfedges > HalfedgeIter
Linear iterator.
Definition: PolyConnectivity.hh:80
OpenMesh::PolyConnectivity::ve_iter
VertexEdgeIter ve_iter(VertexHandle _vh)
vertex - edge circulator
Definition: PolyConnectivity.hh:440
OpenMesh::PolyConnectivity::VFIter
VertexFaceIter VFIter
Alias typedef.
Definition: PolyConnectivity.hh:188
OpenMesh::PolyConnectivity::FHandle
FaceHandle FHandle
Alias typedef.
Definition: PolyConnectivity.hh:172
OpenMesh::PolyConnectivity::CVIter
ConstVertexIter CVIter
Alias typedef.
Definition: PolyConnectivity.hh:179
OpenMesh::PolyConnectivity::ConstFaceRange
EntityRange< const PolyConnectivity, PolyConnectivity::ConstFaceIter,&PolyConnectivity::faces_begin,&PolyConnectivity::faces_end > ConstFaceRange
Begin iterator for vertices.
Definition: PolyConnectivity.hh:365
OpenMesh::PolyConnectivity::cfh_end
ConstFaceHalfedgeIter cfh_end(FaceHandle _fh) const
const face - halfedge circulator
Definition: PolyConnectivity.hh:608
OpenMesh::PolyConnectivity::deref
const Halfedge & deref(HalfedgeHandle _h) const
Get item from handle.
Definition: PolyConnectivity.hh:850
OpenMesh::PolyConnectivity::deref
Vertex & deref(VertexHandle _h)
Get item from handle.
Definition: PolyConnectivity.hh:849
OpenMesh::ArrayKernel::is_boundary
bool is_boundary(HalfedgeHandle _heh) const
Is halfedge _heh a boundary halfedge (is its face handle invalid) ?
Definition: ArrayKernel.hh:358
OpenMesh::PolyConnectivity::vih_iter
VertexIHalfedgeIter vih_iter(VertexHandle _vh)
vertex - incoming halfedge circulator
Definition: PolyConnectivity.hh:434
OpenMesh::PolyConnectivity::EIter
EdgeIter EIter
Alias typedef.
Definition: PolyConnectivity.hh:176
OpenMesh::PolyConnectivity::vv_begin
VertexVertexIter vv_begin(VertexHandle _vh)
vertex - vertex circulator
Definition: PolyConnectivity.hh:491
OpenMesh::PolyConnectivity::cvf_iter
ConstVertexFaceIter cvf_iter(VertexHandle _vh) const
const vertex - face circulator
Definition: PolyConnectivity.hh:459
OpenMesh::PolyConnectivity::InvalidFaceHandle
static const FaceHandle InvalidFaceHandle
Invalid handle.
Definition: PolyConnectivity.hh:66
OpenMesh::PolyConnectivity::cvf_begin
ConstVertexFaceIter cvf_begin(VertexHandle _vh) const
const vertex - face circulator
Definition: PolyConnectivity.hh:519
OpenMesh::PolyConnectivity::FVIter
FaceVertexIter FVIter
Alias typedef.
Definition: PolyConnectivity.hh:189
OpenMesh::PolyConnectivity::CVOHIter
ConstVertexOHalfedgeIter CVOHIter
Alias typedef.
Definition: PolyConnectivity.hh:195
OpenMesh::PolyConnectivity::vertices
ConstVertexRange vertices() const
Definition: PolyConnectivity.hh:370
OpenMesh::PolyConnectivity::chl_end
ConstHalfedgeLoopIter chl_end(HalfedgeHandle _heh) const
const face - face circulator
Definition: PolyConnectivity.hh:617
OpenMesh::PolyConnectivity::CVFIter
ConstVertexFaceIter CVFIter
Alias typedef.
Definition: PolyConnectivity.hh:198
OpenMesh::PolyConnectivity::ConstVertexRange
EntityRange< const PolyConnectivity, PolyConnectivity::ConstVertexIter,&PolyConnectivity::vertices_begin,&PolyConnectivity::vertices_end > ConstVertexRange
Begin iterator for vertices.
Definition: PolyConnectivity.hh:362
OpenMesh::ArrayKernel::assign_connectivity
void assign_connectivity(const ArrayKernel &_other)
ArrayKernel uses the default copy constructor and assignment operator, which means that the connectiv...
Definition: ArrayKernel.cc:69
OpenMesh::PolyConnectivity::CFFIter
ConstFaceFaceIter CFFIter
Alias typedef.
Definition: PolyConnectivity.hh:202
OpenMesh::PolyConnectivity::cvih_begin
ConstVertexIHalfedgeIter cvih_begin(VertexHandle _vh) const
const vertex - incoming halfedge circulator
Definition: PolyConnectivity.hh:510
OpenMesh::PolyConnectivity::ConstVertexIter
VertexIter ConstVertexIter
Linear iterator.
Definition: PolyConnectivity.hh:84
OpenMesh::PolyConnectivity::cvoh_iter
ConstVertexOHalfedgeIter cvoh_iter(VertexHandle _vh) const
const vertex - outgoing halfedge circulator
Definition: PolyConnectivity.hh:453
OpenMesh::PolyConnectivity::cve_iter
ConstVertexEdgeIter cve_iter(VertexHandle _vh) const
const vertex - edge circulator
Definition: PolyConnectivity.hh:456
OpenMesh::PolyConnectivity::faces_sbegin
ConstFaceIter faces_sbegin() const
Const begin iterator for faces.
Definition: PolyConnectivity.hh:419
OpenMesh::PolyConnectivity::vertices_sbegin
VertexIter vertices_sbegin()
Begin iterator for vertices.
Definition: PolyConnectivity.hh:395
OpenMesh::PolyConnectivity::add_vertex
VertexHandle add_vertex()
Add a new vertex.
Definition: PolyConnectivity.hh:223
OpenMesh::PolyConnectivity::ConstHalfedgeRange
EntityRange< const PolyConnectivity, PolyConnectivity::ConstHalfedgeIter,&PolyConnectivity::halfedges_begin,&PolyConnectivity::halfedges_end > ConstHalfedgeRange
Begin iterator for vertices.
Definition: PolyConnectivity.hh:363
OpenMesh::PolyConnectivity::assign_connectivity
void assign_connectivity(const PolyConnectivity &_other)
assign_connectivity() method.
Definition: PolyConnectivity.hh:215
OpenMesh::PolyConnectivity::fv_begin
FaceVertexIter fv_begin(FaceHandle _fh)
face - vertex circulator
Definition: PolyConnectivity.hh:523
OpenMesh::PolyConnectivity::deref
const Face & deref(FaceHandle _h) const
Get item from handle.
Definition: PolyConnectivity.hh:854
OpenMesh::PolyConnectivity::fh_begin
FaceHalfedgeIter fh_begin(FaceHandle _fh)
face - halfedge circulator
Definition: PolyConnectivity.hh:526
OpenMesh::PolyConnectivity::ff_begin
FaceFaceIter ff_begin(FaceHandle _fh)
face - face circulator
Definition: PolyConnectivity.hh:532
OpenMesh::Iterators::GenericCirculatorT
Definition: CirculatorsT.hh:221
OpenMesh::PolyConnectivity::EntityRange
Definition: PolyConnectivity.hh:353
OpenMesh::PolyConnectivity::FIter
FaceIter FIter
Alias typedef.
Definition: PolyConnectivity.hh:177
OpenMesh::ArrayKernel
Mesh kernel using arrays for mesh item storage.
Definition: ArrayKernel.hh:85
OpenMesh::PolyConnectivity::deref
const Edge & deref(EdgeHandle _h) const
Get item from handle.
Definition: PolyConnectivity.hh:852
OpenMesh::PolyConnectivity::cfh_begin
ConstFaceHalfedgeIter cfh_begin(FaceHandle _fh) const
const face - halfedge circulator
Definition: PolyConnectivity.hh:542
OpenMesh::PolyConnectivity::EHandle
EdgeHandle EHandle
Alias typedef.
Definition: PolyConnectivity.hh:171
OpenMesh::PolyConnectivity::is_boundary
bool is_boundary(VertexHandle _vh) const
Is vertex _vh a boundary vertex ?
Definition: PolyConnectivity.hh:662
OpenMesh::PolyConnectivity::cvih_iter
ConstVertexIHalfedgeIter cvih_iter(VertexHandle _vh) const
const vertex - incoming halfedge circulator
Definition: PolyConnectivity.hh:450
OpenMesh::PolyConnectivity::cvf_end
ConstVertexFaceIter cvf_end(VertexHandle _vh) const
const vertex - face circulator
Definition: PolyConnectivity.hh:585
OpenMesh::HalfedgeHandle
Handle for a halfedge entity.
Definition: Handles.hh:121
OpenMesh::PolyConnectivity::vf_begin
VertexFaceIter vf_begin(VertexHandle _vh)
vertex - face circulator
Definition: PolyConnectivity.hh:503
OpenMesh::PolyConnectivity::ve_begin
VertexEdgeIter ve_begin(VertexHandle _vh)
vertex - edge circulator
Definition: PolyConnectivity.hh:500
OpenMesh::PolyConnectivity::CHIter
ConstHalfedgeIter CHIter
Alias typedef.
Definition: PolyConnectivity.hh:180
OpenMesh::PolyConnectivity::hl_begin
HalfedgeLoopIter hl_begin(HalfedgeHandle _heh)
halfedge circulator
Definition: PolyConnectivity.hh:535
OpenMesh::PolyConnectivity::FaceIter
Iterators::GenericIteratorT< This, This::FaceHandle, ArrayKernel,&This::has_face_status,&This::n_faces > FaceIter
Linear iterator.
Definition: PolyConnectivity.hh:82
OpenMesh::PolyConnectivity::cvv_iter
ConstVertexVertexIter cvv_iter(VertexHandle _vh) const
const vertex circulator
Definition: PolyConnectivity.hh:447
OpenMesh::PolyConnectivity::cff_end
ConstFaceFaceIter cff_end(FaceHandle _fh) const
const face - face circulator
Definition: PolyConnectivity.hh:614
OpenMesh::PolyConnectivity::opposite_face_handle
FaceHandle opposite_face_handle(HalfedgeHandle _heh) const
returns the face handle of the opposite halfedge
Definition: PolyConnectivity.hh:696
OpenMesh::PolyConnectivity::edges
ConstEdgeRange edges() const
Definition: PolyConnectivity.hh:380
OpenMesh::PolyConnectivity::CFVIter
ConstFaceVertexIter CFVIter
Alias typedef.
Definition: PolyConnectivity.hh:199
OpenMesh::PolyConnectivity::voh_end
VertexOHalfedgeIter voh_end(VertexHandle _vh)
vertex - outgoing halfedge circulator
Definition: PolyConnectivity.hh:563
OpenMesh::PolyConnectivity::voh_iter
VertexOHalfedgeIter voh_iter(VertexHandle _vh)
vertex - outgoing halfedge circulator
Definition: PolyConnectivity.hh:437
OpenMesh::PolyConnectivity::fv_end
FaceVertexIter fv_end(FaceHandle _fh)
face - vertex circulator
Definition: PolyConnectivity.hh:589
OpenMesh::PolyConnectivity::fh_end
FaceHalfedgeIter fh_end(FaceHandle _fh)
face - halfedge circulator
Definition: PolyConnectivity.hh:592
OpenMesh::PolyConnectivity::InvalidEdgeHandle
static const EdgeHandle InvalidEdgeHandle
Invalid handle.
Definition: PolyConnectivity.hh:64
OpenMesh::PolyConnectivity::cfe_end
ConstFaceEdgeIter cfe_end(FaceHandle _fh) const
const face - edge circulator
Definition: PolyConnectivity.hh:611
OpenMesh::PolyConnectivity::ConstEdgeIter
EdgeIter ConstEdgeIter
Linear iterator.
Definition: PolyConnectivity.hh:86