Commit 6fc984cb authored by Pierre Kraemer's avatar Pierre Kraemer
Browse files

MR primal : compute vertices attributes with functors ?

parent e0942ffc
...@@ -35,6 +35,10 @@ class Map2MR_Primal : public EmbeddedMap2 ...@@ -35,6 +35,10 @@ class Map2MR_Primal : public EmbeddedMap2
protected: protected:
bool shareVertexEmbeddings ; bool shareVertexEmbeddings ;
FunctorType& vertexVertexFunctor ;
FunctorType& edgeVertexFunctor ;
FunctorType& faceVertexFunctor ;
public: public:
Map2MR_Primal() ; Map2MR_Primal() ;
...@@ -95,6 +99,7 @@ public: ...@@ -95,6 +99,7 @@ public:
*/ */
bool faceIsSubdividedOnce(Dart d) ; bool faceIsSubdividedOnce(Dart d) ;
protected:
/*************************************************** /***************************************************
* EMBEDDINGS MANAGEMENT * * EMBEDDINGS MANAGEMENT *
***************************************************/ ***************************************************/
...@@ -110,6 +115,7 @@ public: ...@@ -110,6 +115,7 @@ public:
*/ */
void addNewLevel() ; void addNewLevel() ;
public:
/** /**
* subdivide the edge of d to the next level * subdivide the edge of d to the next level
*/ */
...@@ -129,6 +135,18 @@ public: ...@@ -129,6 +135,18 @@ public:
* coarsen the face of d from the next level * coarsen the face of d from the next level
*/ */
void coarsenFace(Dart d) ; void coarsenFace(Dart d) ;
/**
* vertices attributes management
*/
void setVertexVertexFunctor(FunctorType& f) { vertexVertexFunctor = f ; }
void computeVertexVertex(Dart d) { vertexVertexFunctor(d) ; }
void setEdgeVertexFunctor(FunctorType& f) { edgeVertexFunctor = f ; }
void computeEdgeVertex(Dart d) { edgeVertexFunctor(d) ; }
void setFaceVertexFunctor(FunctorType& f) { faceVertexFunctor = f ; }
void computeFaceVertex(Dart d) { faceVertexFunctor(d) ; }
} ; } ;
} // namespace CGoGN } // namespace CGoGN
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment