43 #ifndef TETRAHEDRALMESHTOPOLOGYKERNEL_HH
44 #define TETRAHEDRALMESHTOPOLOGYKERNEL_HH
51 #include "../Core/TopologyKernel.hh"
52 #include "TetrahedralMeshIterators.hh"
73 virtual FaceHandle add_face(
const std::vector<HalfEdgeHandle>& _halfedges,
bool _topologyCheck =
false);
79 virtual CellHandle add_cell(
const std::vector<HalfFaceHandle>& _halffaces,
bool _topologyCheck =
false);
81 CellHandle add_cell(
const std::vector<VertexHandle>& _vertices,
bool _topologyCheck =
false);
84 HalfFaceHandle add_halfface(
const std::vector<HalfEdgeHandle>& _halfedges,
bool _topologyCheck =
false);
89 std::vector<VertexHandle> get_cell_vertices(
CellHandle ch)
const;
91 std::vector<VertexHandle> get_cell_vertices(
HalfFaceHandle hfh)
const;
94 std::vector<VertexHandle> get_halfface_vertices(
HalfFaceHandle hfh)
const;
109 friend class TetVertexIter;
111 typedef class TetVertexIter TetVertexIter;
113 TetVertexIter tv_iter(
const CellHandle& _ref_h,
int _max_laps = 1)
const {
114 return TetVertexIter(_ref_h,
this, _max_laps);
117 std::pair<TetVertexIter,TetVertexIter> tet_vertices(
const CellHandle& _ref_h,
int _max_laps = 1)
const {
118 TetVertexIter begin = tv_iter(_ref_h, _max_laps);
119 TetVertexIter end = make_end_circulator(begin);
120 return std::make_pair(begin, end);
127 template <
typename PropIterator,
typename Handle>
128 void swapPropertyElements(PropIterator begin, PropIterator end, Handle source, Handle destination)
130 PropIterator p_iter = begin;
131 for (; p_iter != end; ++p_iter)
132 (*p_iter)->swap_elements(source, destination);
A data structure based on PolyhedralMesh with specializations for tetrahedra.
virtual FaceHandle add_face(const std::vector< HalfEdgeHandle > &_halfedges, bool _topologyCheck=false)
Add face via incident edges.
virtual CellHandle add_cell(const std::vector< HalfFaceHandle > &_halffaces, bool _topologyCheck=false)
Add cell via incident halffaces.