Wildmeshing Toolkit
NavigatableSimplex.hpp
Go to the documentation of this file.
1 #pragma once
2 #include <wmtk/Tuple.hpp>
3 #include "IdSimplex.hpp"
4 #include "Simplex.hpp"
5 
6 namespace wmtk {
7 class Mesh;
8 }
9 namespace wmtk::simplex {
10 class IdSimplex;
11 
12 
13 // An extension to a simplex that can be used for some sort of navigation at the time it is created.
14 // Useful for tracking the input of operations where the simplex id is valuable
16 {
17 public:
18  friend class wmtk::Mesh;
19  NavigatableSimplex(const Mesh& m, const Simplex& s);
20  NavigatableSimplex(const Mesh& m, const PrimitiveType& ptype, const Tuple& t) ;
21  operator Simplex() const;
22 
23 
24  const Tuple& tuple() const { return m_tuple; }
25 
26 protected:
27  NavigatableSimplex(const PrimitiveType& ptype, const Tuple& t, int64_t index)
28  : IdSimplex{ptype, index}
29  , m_tuple(t)
30  {}
31 
32 
33 private:
35 };
36 } // namespace wmtk::simplex
int64_t index() const
Definition: IdSimplex.hpp:32
friend class NavigatableSimplex
Definition: IdSimplex.hpp:18
NavigatableSimplex(const PrimitiveType &ptype, const Tuple &t, int64_t index)
Definition: Accessor.hpp:6