Commit 17225370 authored by Pierre Kraemer's avatar Pierre Kraemer

embedOrbit->setOrbitEmbedding + optim about EMBNULL

parent 0d75d907
......@@ -92,7 +92,7 @@ private:
// Assigne un nouveau plongement au sommet. Les anciens plongements sont libérés.
void newVertex(Dart d) {
embedNewCell<VERTEX>(d);
setOrbitEmbeddingNewCell<VERTEX>(d);
}
public:
......
......@@ -95,7 +95,7 @@ private:
// Assigne un nouveau plongement au sommet. Les anciens plongements sont libérés.
void newVertex(Dart d) {
embedNewCell(VERTEX,d);
setOrbitEmbeddingNewCell(VERTEX,d);
}
public:
......
......@@ -898,7 +898,7 @@ void EdgeSelector_Curvature<PFP>::computeEdgeInfo(Dart d, EdgeInfo& einfo)
Dart d2 = m.phi2(m.phi_1(d)) ;
Dart dd2 = m.phi2(m.phi_1(dd)) ;
m.extractTrianglePair(d) ;
unsigned int newV = m.template embedNewCell<VERTEX>(d2) ;
unsigned int newV = m.template setOrbitEmbeddingNewCell<VERTEX>(d2) ;
this->m_position[newV] = m_positionApproximator->getApprox(d) ;
// compute things on the coarse version of the mesh
......@@ -911,8 +911,8 @@ void EdgeSelector_Curvature<PFP>::computeEdgeInfo(Dart d, EdgeInfo& einfo)
// vertex split to reset the initial connectivity and embeddings
m.insertTrianglePair(d, d2, dd2) ;
m.template embedOrbit<VERTEX>(d, v1) ;
m.template embedOrbit<VERTEX>(dd, v2) ;
m.template setOrbitEmbedding<VERTEX>(d, v1) ;
m.template setOrbitEmbedding<VERTEX>(dd, v2) ;
REAL err = 0 ;
......
......@@ -211,7 +211,7 @@ void Approximator_MidEdge<PFP>::approximate(Dart d)
// temporary edge collapse
m.extractTrianglePair(d) ;
unsigned int newV = m.template embedNewCell<VERTEX>(d2) ;
unsigned int newV = m.template setOrbitEmbeddingNewCell<VERTEX>(d2) ;
this->m_attrV[0]->operator[](newV) = this->m_approx[0][d] ;
// compute the detail vector
......@@ -220,8 +220,8 @@ void Approximator_MidEdge<PFP>::approximate(Dart d)
// vertex split to reset the initial connectivity and embeddings
m.insertTrianglePair(d, d2, dd2) ;
m.template embedOrbit<VERTEX>(d, m.template getEmbedding<VERTEX>(d)) ;
m.template embedOrbit<VERTEX>(dd, m.template getEmbedding<VERTEX>(dd)) ;
m.template setOrbitEmbedding<VERTEX>(d, m.template getEmbedding<VERTEX>(d)) ;
m.template setOrbitEmbedding<VERTEX>(dd, m.template getEmbedding<VERTEX>(dd)) ;
}
}
......@@ -260,7 +260,7 @@ void Approximator_HalfCollapse<PFP>::approximate(Dart d)
// temporary edge collapse
m.extractTrianglePair(d) ;
unsigned int newV = m.template embedNewCell<VERTEX>(d2) ;
unsigned int newV = m.template setOrbitEmbeddingNewCell<VERTEX>(d2) ;
for (unsigned int i = 0 ; i < this->m_attrV.size() ; ++i)
{
this->m_attrV[i]->operator[](newV) = this->m_approx[i][d] ;
......@@ -275,8 +275,8 @@ void Approximator_HalfCollapse<PFP>::approximate(Dart d)
// vertex split to reset the initial connectivity and embeddings
m.insertTrianglePair(d, d2, dd2) ;
m.template embedOrbit<VERTEX>(d, m.template getEmbedding<VERTEX>(d)) ;
m.template embedOrbit<VERTEX>(dd, m.template getEmbedding<VERTEX>(dd)) ;
m.template setOrbitEmbedding<VERTEX>(d, m.template getEmbedding<VERTEX>(d)) ;
m.template setOrbitEmbedding<VERTEX>(dd, m.template getEmbedding<VERTEX>(dd)) ;
}
}
......
......@@ -175,7 +175,7 @@ void SimplifTrian<PFP>::updateCriterias(Dart d)
CRIT_IT it = m_edgeCrit.insert(std::make_pair(key,cr));
// store iterator on edge
unsigned int em = m_map.getEmbedding(d, EDGE);
m_map.embedOrbit<EDGE>(d, em);
m_map.setOrbitEmbedding<EDGE>(d, em);
m_edgeEmb[em] = it;
m_protectMarker.mark(em) ;
......@@ -235,7 +235,7 @@ Dart SimplifTrian<PFP>::edgeCollapse(Dart d, typename PFP::VEC3& newPos)
// embed new vertex
unsigned int emb = m_map.getEmbedding(d2, VERTEX);
m_map.embedOrbit<VERTEX>(d2, emb);
m_map.setOrbitEmbedding<VERTEX>(d2, emb);
m_positions[d2] = newPos;
m_valences[d2] = v_d + v_dd - 4;
......
......@@ -122,12 +122,12 @@ void CollapseEdgeOperator<PFP>::split(typename PFP::MAP& m, VertexAttribute<type
// //vertexSplit(vs) ; // split vertex
// //map.vertexSplit()
//
// m_map.template embedOrbit<VERTEX>(d, v1) ; // embed the
// m_map.template embedOrbit<VERTEX>(dd, v2) ; // new vertices
// m_map.template embedOrbit<EDGE>(d1, e1) ;
// m_map.template embedOrbit<EDGE>(d2, e2) ; // and new edges
// m_map.template embedOrbit<EDGE>(dd1, e3) ;
// m_map.template embedOrbit<EDGE>(dd2, e4) ;
// m_map.template setOrbitEmbedding<VERTEX>(d, v1) ; // embed the
// m_map.template setOrbitEmbedding<VERTEX>(dd, v2) ; // new vertices
// m_map.template setOrbitEmbedding<EDGE>(d1, e1) ;
// m_map.template setOrbitEmbedding<EDGE>(d2, e2) ; // and new edges
// m_map.template setOrbitEmbedding<EDGE>(dd1, e3) ;
// m_map.template setOrbitEmbedding<EDGE>(dd2, e4) ;
}
/****************************************************************************************************
......
......@@ -258,8 +258,8 @@ inline void ImplicitHierarchicalMap::splitFace(Dart d, Dart e)
{
unsigned int cur = m_curLevel ;
m_curLevel = m_maxLevel ;
this->embedOrbit<FACE>(d, this->getEmbedding<FACE>(d)) ;
this->embedOrbit<FACE>(e, this->getEmbedding<FACE>(e)) ;
this->setOrbitEmbedding<FACE>(d, this->getEmbedding<FACE>(d)) ;
this->setOrbitEmbedding<FACE>(e, this->getEmbedding<FACE>(e)) ;
m_curLevel = cur ;
}
}
......@@ -349,7 +349,7 @@ T& AttributeHandler_IHM<T, ORBIT>::operator[](Dart d)
if(index == EMBNULL)
{
index = m->embedNewCell<ORBIT>(d) ;
index = m->setOrbitEmbeddingNewCell<ORBIT>(d) ;
m->m_nextLevelCell[orbit]->operator[](index) = EMBNULL ;
}
......
......@@ -616,7 +616,7 @@ T& AttributeHandler_IHM<T, ORBIT>::operator[](Dart d)
if(index == EMBNULL)
{
index = m->embedNewCell<ORBIT>(d) ;
index = m->setOrbitEmbeddingNewCell<ORBIT>(d) ;
m->m_nextLevelCell[orbit]->operator[](index) = EMBNULL ;
}
......
......@@ -829,7 +829,7 @@ void subdivideLoop(typename PFP::MAP& map, Dart d, AttributeHandler<typename PFP
}while(f != x);
}
map.template embedOrbit<VERTEX>(centralDart, map.template getEmbedding<VERTEX>(centralDart));
map.template setOrbitEmbedding<VERTEX>(centralDart, map.template getEmbedding<VERTEX>(centralDart));
//Third step : 3-sew internal faces
for (std::vector<std::pair<Dart,Dart> >::iterator it = subdividedfaces.begin(); it != subdividedfaces.end(); ++it)
......@@ -1224,7 +1224,7 @@ Dart subdivideVolume(typename PFP::MAP& map, Dart d, AttributeHandler<typename P
}while(f != x);
}
map.template embedOrbit<VERTEX>(centralDart, map.template getEmbedding<VERTEX>(centralDart));
map.template setOrbitEmbedding<VERTEX>(centralDart, map.template getEmbedding<VERTEX>(centralDart));
//Third step : 3-sew internal faces
for (std::vector<std::pair<char, std::pair<Dart,Dart> > >::iterator it = subdividedfaces.begin(); it != subdividedfaces.end(); ++it)
......
......@@ -98,12 +98,12 @@ public:
unsigned int newEmb = vID[children[0]->indices[idx]] ;
if(oldEmb == EMBNULL)
{
map.template embedOrbit<VERTEX>(dd, newEmb) ;
map.template setOrbitEmbedding<VERTEX>(dd, newEmb) ;
map.pushLevel() ;
for(unsigned int i = map.getCurrentLevel() + 1; i <= map.getMaxLevel(); ++i)
{
map.setCurrentLevel(i) ;
map.template embedOrbit<VERTEX>(dd, newEmb) ;
map.template setOrbitEmbedding<VERTEX>(dd, newEmb) ;
}
map.popLevel() ;
}
......
......@@ -49,6 +49,8 @@ bool importMesh(typename PFP::MAP& map, MeshTablesSurface<PFP>& mts)
DartMarkerNoUnmark m(map) ;
FunctorInitEmb<typename PFP::MAP, VERTEX> fsetemb(map);
// for each face of table
for(unsigned int i = 0; i < nbf; ++i)
{
......@@ -77,9 +79,7 @@ bool importMesh(typename PFP::MAP& map, MeshTablesSurface<PFP>& mts)
for (unsigned int j = 0; j < nbe; ++j)
{
unsigned int em = edgesBuffer[j]; // get embedding
FunctorSetEmb<typename PFP::MAP, VERTEX> fsetemb(map, em);
// foreach_dart_of_orbit_in_parent<typename PFP::MAP>(&map, VERTEX, d, fsetemb) ;
fsetemb.changeEmb(em) ;
map.template foreach_dart_of_orbit<PFP::MAP::VERTEX_OF_PARENT>(d, fsetemb);
m.mark(d) ; // mark on the fly to unmark on second loop
......
......@@ -118,7 +118,7 @@ bool importMoka(typename PFP::MAP& gmap, const std::string& filename, std::vecto
}
for(typename std::map<Dart, unsigned int>::iterator it = map_dart_emb.begin() ; it != map_dart_emb.end() ; ++it)
gmap.template embedOrbit<VERTEX>(it->first, it->second);
gmap.template setOrbitEmbedding<VERTEX>(it->first, it->second);
gmap.closeMap();
......
......@@ -257,7 +257,7 @@ Polyhedron<PFP>* extrusion_scale_prim(typename PFP::MAP& the_map, VertexAttribut
else position[em] = P;
Dart d = vertD[index++];
the_map.template embedOrbit<VERTEX>(d, em);
the_map.template setOrbitEmbedding<VERTEX>(d, em);
// rotate again to put profile in the good position along the path
// pos4=Geom::Vec4f ((*ip)[0],(*ip)[1],(*ip)[2], 1.0f);
......
......@@ -783,7 +783,7 @@ void Polyhedron<PFP>::embedGrid(float x, float y, float z)
VEC3 pos(-x/2 + dx*float(j), -y/2 + dy*float(i), z);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[i*(m_nx+1)+j];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
}
......@@ -814,7 +814,7 @@ void Polyhedron<PFP>::embedCylinder(float bottom_radius, float top_radius, float
VEC3 pos(x, y, -height/2 + dz*float(i));
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[i*(m_nx)+j];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
......@@ -824,7 +824,7 @@ void Polyhedron<PFP>::embedCylinder(float bottom_radius, float top_radius, float
VEC3 pos(0.0f, 0.0f, -height/2 );
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[indexUmbrella++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
if (m_top_closed)
......@@ -832,7 +832,7 @@ void Polyhedron<PFP>::embedCylinder(float bottom_radius, float top_radius, float
VEC3 pos(0.0f ,0.0f, height/2 );
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[indexUmbrella];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
......@@ -864,7 +864,7 @@ void Polyhedron<PFP>::embedCone(float radius, float height)
VEC3 pos(x, y, h);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[i*(m_nx)+j];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
......@@ -874,14 +874,14 @@ void Polyhedron<PFP>::embedCone(float radius, float height)
VEC3 pos(0.0f, 0.0f, -height/2 );
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[indexUmbrella++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
// top always closed in cone
VEC3 pos(0.0f ,0.0f, height/2.0f );
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[indexUmbrella];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
template <typename PFP>
......@@ -910,7 +910,7 @@ void Polyhedron<PFP>::embedSphere(float radius)
VEC3 pos(x, y, h );
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[i*(m_nx)+j];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
......@@ -918,13 +918,13 @@ void Polyhedron<PFP>::embedSphere(float radius)
VEC3 pos(0.0f, 0.0f, -radius);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[m_nx*(m_nz+1)];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
// top pole
pos = VEC3(0.0f, 0.0f, radius);
em = m_positions.insert(pos);
d = m_tableVertDarts[m_nx*(m_nz+1)+1];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
template <typename PFP>
......@@ -952,7 +952,7 @@ void Polyhedron<PFP>::embedTore(float big_radius, float small_radius)
VEC3 pos(x, y, z);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[j*(m_nx)+i];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
}
......@@ -983,7 +983,7 @@ void Polyhedron<PFP>::embedCube(float sx, float sy, float sz)
VEC3 pos(x, -sy/2.0f, z);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[index++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
for (unsigned int i = 0; i < m_ny; ++i)
{
......@@ -991,7 +991,7 @@ void Polyhedron<PFP>::embedCube(float sx, float sy, float sz)
VEC3 pos(sx/2.0f, y, z);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[index++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
for (unsigned int i = 0; i < m_nx; ++i)
{
......@@ -999,7 +999,7 @@ void Polyhedron<PFP>::embedCube(float sx, float sy, float sz)
VEC3 pos(x, sy/2.0f, z);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[index++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
for (unsigned int i = 0; i < m_ny ;++i)
{
......@@ -1007,7 +1007,7 @@ void Polyhedron<PFP>::embedCube(float sx, float sy, float sz)
VEC3 pos(-sx/2.0f, y, z);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[index++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
......@@ -1019,7 +1019,7 @@ void Polyhedron<PFP>::embedCube(float sx, float sy, float sz)
VEC3 pos(-sx/2.0f+float(j)*dx, -sy/2.0f+float(i)*dy, sz/2.0f);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[index++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
......@@ -1031,7 +1031,7 @@ void Polyhedron<PFP>::embedCube(float sx, float sy, float sz)
VEC3 pos(-sx/2.0f+float(j)*dx, sy/2.0f-float(i)*dy, -sz/2.0f);
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[index++];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
}
......@@ -1104,7 +1104,7 @@ void Polyhedron<PFP>::embedTwistedStrip(float radius_min, float radius_max, flo
VEC3 pos(r*cos(alpha*float(i)), r*sin(alpha*float(i)), rw*sin(beta*float(i)));
unsigned int em = m_positions.insert(pos);
Dart d = m_tableVertDarts[i*(m_nx+1)+j];
m_map.template embedOrbit<VERTEX>(d, em);
m_map.template setOrbitEmbedding<VERTEX>(d, em);
}
}
}
......
......@@ -176,7 +176,7 @@ void Primitive3D<PFP>::embedHexaGrid(float x, float y, float z)
typename PFP::VEC3 pos(-x/2.0f + dx*float(k), -y/2.0f + dy*float(j), -z/2.0f + dz*float(i));
Dart d = m_tableVertDarts[ i*nbs+j*(m_nx+1)+k ];
m_map.template embedNewCell<VERTEX>(d);
m_map.template setOrbitEmbeddingNewCell<VERTEX>(d);
m_positions[d] = pos;
}
}
......
......@@ -607,7 +607,7 @@ void catmullClarkVol(typename PFP::MAP& map, EMBV& attributs, const FunctorSelec
// if(phi3(f1) == f1 && phi3(f2) == f2)
// sewVolumes(f1, f2, false);
// }
// embedOrbit<VERTEX>(centralDart, getEmbedding<VERTEX>(centralDart));
// setOrbitEmbedding<VERTEX>(centralDart, getEmbedding<VERTEX>(centralDart));
//attributs[map.phi1(ne)] = attBary[*it];
//
// setCurrentLevel(getMaxLevel() - 1) ;
......@@ -618,13 +618,13 @@ void catmullClarkVol(typename PFP::MAP& map, EMBV& attributs, const FunctorSelec
// TraversorE<typename PFP::MAP> travE2(map);
// for (Dart d = travE2.begin(); d != travE2.end(); d = travE2.next())
// {
// map.embedOrbit<VERTEX>(map.phi1(d), map.getEmbedding<VERTEX>(map.phi1(d)));
// map.setOrbitEmbedding<VERTEX>(map.phi1(d), map.getEmbedding<VERTEX>(map.phi1(d)));
// }
//
// TraversorF<typename PFP::MAP> travF2(map) ;
// for (Dart d = travF2.begin(); d != travF2.end(); d = travF2.next())
// {
// map.embedOrbit<VERTEX>(map.phi2(map.phi1(d)), map.getEmbedding<VERTEX>(map.phi2(map.phi1(d))));
// map.setOrbitEmbedding<VERTEX>(map.phi2(map.phi1(d)), map.getEmbedding<VERTEX>(map.phi2(map.phi1(d))));
// }
......
......@@ -304,14 +304,14 @@ void unlinkFromEdge(typename PFP::MAP& map, Dart d)
// unsigned int dVEmb = map.getEmbedding<VERTEX>(d) ;
// if(dVEmb != EMBNULL)
// {
// map.embedOrbit<VERTEX>(d, dVEmb) ;
// map.setOrbitEmbedding<VERTEX>(d, dVEmb) ;
// map.setDartEmbedding<VERTEX>(d, EMBNULL) ;
// }
//
// unsigned int d3VEmb = map.getEmbedding<VERTEX>(d3) ;
// if(d3VEmb != EMBNULL)
// {
// map.embedOrbit<VERTEX>(d3, d3VEmb) ;
// map.setOrbitEmbedding<VERTEX>(d3, d3VEmb) ;
// map.setDartEmbedding<VERTEX>(d3, EMBNULL) ;
// }
// }
......
......@@ -291,7 +291,7 @@ void Map2MR_PM<PFP>::coarsen()
//std::cout << std::endl;
m_map.template embedOrbit<VERTEX>(dres, m_map.template getEmbedding<VERTEX>(dres));
m_map.template setOrbitEmbedding<VERTEX>(dres, m_map.template getEmbedding<VERTEX>(dres));
}
}
......@@ -324,7 +324,7 @@ void Map2MR_PM<PFP>::refine()
//std::cout << std::endl;
m_map.template embedOrbit<VERTEX>(dres, m_map.template getEmbedding<VERTEX>(dres));
m_map.template setOrbitEmbedding<VERTEX>(dres, m_map.template getEmbedding<VERTEX>(dres));
}
}
......
......@@ -69,9 +69,9 @@ void Map2MR<PFP>::addNewLevel(bool triQuad, bool embedNewVertices)
if(!shareVertexEmbeddings && embedNewVertices)
{
if(m_map.template getEmbedding<VERTEX>(d) == EMBNULL)
m_map.template embedNewCell<VERTEX>(d) ;
m_map.template setOrbitEmbeddingNewCell<VERTEX>(d) ;
if(m_map.template getEmbedding<VERTEX>(m_map.phi1(d)) == EMBNULL)
m_map.template embedNewCell<VERTEX>(d) ;
m_map.template setOrbitEmbeddingNewCell<VERTEX>(d) ;
}
m_map.cutEdge(d) ;
......@@ -79,7 +79,7 @@ void Map2MR<PFP>::addNewLevel(bool triQuad, bool embedNewVertices)
travE.skip(m_map.phi1(d)) ;
if(embedNewVertices)
m_map.template embedNewCell<VERTEX>(m_map.phi1(d)) ;
m_map.template setOrbitEmbeddingNewCell<VERTEX>(m_map.phi1(d)) ;
}
// split faces
......@@ -124,7 +124,7 @@ void Map2MR<PFP>::addNewLevel(bool triQuad, bool embedNewVertices)
travF.skip(dd) ;
if(embedNewVertices)
m_map.template embedNewCell<VERTEX>(m_map.phi1(ne)) ;
m_map.template setOrbitEmbeddingNewCell<VERTEX>(m_map.phi1(ne)) ;
dd = m_map.phi1(m_map.phi1(next)) ;
while(dd != ne) // turn around the face and insert new edges
......@@ -169,7 +169,7 @@ void Map2MR<PFP>::addNewLevelSqrt3(bool embedNewVertices)
Dart cd = m_map.phi2(x);
if(embedNewVertices)
m_map.template embedNewCell<VERTEX>(cd) ;
m_map.template setOrbitEmbeddingNewCell<VERTEX>(cd) ;
Dart fit = cd ;
do
......
......@@ -83,7 +83,7 @@ void Map3MR<PFP>::swapEdges(Dart d, Dart e)
}
if(m_map.template isOrbitEmbedded<VOLUME>())
m_map.template embedNewCell<VOLUME>(d);
m_map.template setOrbitEmbeddingNewCell<VOLUME>(d);
// propagateDartRelation(d, m_phi2) ;
......@@ -630,7 +630,7 @@ void Map3MR<PFP>::subdivideVolume(Dart d)
for(Dart ditWV = traWV.begin(); ditWV != traWV.end(); ditWV = traWV.next())
{
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
m_map.template embedOrbit<VERTEX>(ditWV, EMBNULL);
m_map.template setOrbitEmbedding<VERTEX>(ditWV, EMBNULL);
(*vertexVertexFunctor)(ditWV) ;
Dart e = ditWV;
......@@ -703,9 +703,9 @@ void Map3MR<PFP>::subdivideVolume(Dart d)
}
}
m_map.template embedOrbit<VERTEX>(centralDart, EMBNULL);
m_map.template setOrbitEmbedding<VERTEX>(centralDart, EMBNULL);
(*volumeVertexFunctor)(centralDart) ;
m_map.template embedOrbit<VERTEX>(centralDart, m_map.template getEmbedding<VERTEX>(centralDart));
m_map.template setOrbitEmbedding<VERTEX>(centralDart, m_map.template getEmbedding<VERTEX>(centralDart));
propagateOrbitEmbedding<VERTEX>(centralDart) ;
......@@ -716,7 +716,7 @@ void Map3MR<PFP>::subdivideVolume(Dart d)
{
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
m_map.setCurrentLevel(m_map.getMaxLevel()-1) ;
m_map.template embedOrbit<VERTEX>(m_map.phi1(d), m_map.template getEmbedding<VERTEX>(m_map.phi1(d)));
m_map.template setOrbitEmbedding<VERTEX>(m_map.phi1(d), m_map.template getEmbedding<VERTEX>(m_map.phi1(d)));
}
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
......@@ -725,7 +725,7 @@ void Map3MR<PFP>::subdivideVolume(Dart d)
for (Dart d = travF2.begin(); d != travF2.end(); d = travF2.next())
{
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
m_map.template embedOrbit<VERTEX>(m_map.phi2(m_map.phi1(d)), map.template getEmbedding<VERTEX>(m_map.phi2(m_map.phi1(d))));
m_map.template setOrbitEmbedding<VERTEX>(m_map.phi2(m_map.phi1(d)), map.template getEmbedding<VERTEX>(m_map.phi2(m_map.phi1(d))));
m_map.setCurrentLevel(m_map.getMaxLevel()-1) ;
}
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
......@@ -780,7 +780,7 @@ void Map3MR<PFP>::subdivideVolumeTetOcta(Dart d)
setCurrentLevel(vLevel + 1) ;
for(Dart dit = traV.begin(); dit != traV.end(); dit = traV.next())
{
embedOrbit<VERTEX>(dit, EMBNULL);
setOrbitEmbedding<VERTEX>(dit, EMBNULL);
(*vertexVertexFunctor)(dit) ;
Dart f1 = phi1(dit);
......@@ -859,8 +859,8 @@ void Map3MR<PFP>::subdivideVolumeTetOcta(Dart d)
}while(f != x);
}
embedOrbit<VERTEX>(centralDart, EMBNULL);
embedOrbit<VERTEX>(centralDart, getEmbedding<VERTEX>(centralDart));
setOrbitEmbedding<VERTEX>(centralDart, EMBNULL);
setOrbitEmbedding<VERTEX>(centralDart, getEmbedding<VERTEX>(centralDart));
(*volumeVertexFunctor)(centralDart) ;
propagateOrbitEmbedding<VERTEX>(centralDart) ;
}
......
......@@ -73,7 +73,7 @@ void Map3MR<PFP>::swapEdges(Dart d, Dart e)
}
if(m_map.template isOrbitEmbedded<VOLUME>())
m_map.template embedNewCell<VOLUME>(d);
m_map.template setOrbitEmbeddingNewCell<VOLUME>(d);
}
}
......@@ -203,9 +203,9 @@ void Map3MR<PFP>::addNewLevelTetraOcta(bool embedNewVertices)
// if(!shareVertexEmbeddings)
// {
// if(getEmbedding<VERTEX>(d) == EMBNULL)
// embedNewCell<VERTEX>(d) ;
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// if(getEmbedding<VERTEX>(phi1(d)) == EMBNULL)
// embedNewCell<VERTEX>(d) ;
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// }
m_map.cutEdge(d) ;
......@@ -214,7 +214,7 @@ void Map3MR<PFP>::addNewLevelTetraOcta(bool embedNewVertices)
// When importing MR files
// if(embedNewVertices)
// m_map.template embedNewCell<VERTEX>(m_map.phi1(d)) ;
// m_map.template setOrbitEmbeddingNewCell<VERTEX>(m_map.phi1(d)) ;
}
//2. split faces - triangular faces
......@@ -332,7 +332,7 @@ void Map3MR<PFP>::addNewLevelTetraOcta(bool embedNewVertices)
// When importing MR files
//if(embedNewVertices)
// m_map.template embedNewCell<VERTEX>(x) ;
// m_map.template setOrbitEmbeddingNewCell<VERTEX>(x) ;
}
m_map.setCurrentLevel(m_map.getMaxLevel() - 1) ;
}
......@@ -368,9 +368,9 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
// if(!shareVertexEmbeddings)
// {
// if(getEmbedding<VERTEX>(d) == EMBNULL)
// embedNewCell<VERTEX>(d) ;
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// if(getEmbedding<VERTEX>(phi1(d)) == EMBNULL)
// embedNewCell<VERTEX>(phi1(d)) ;
// setOrbitEmbeddingNewCell<VERTEX>(phi1(d)) ;
// }
m_map.cutEdge(d) ;
......@@ -379,7 +379,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
// When importing MR files : activated for DEBUG
// if(embedNewVertices)
// embedNewCell<VERTEX>(phi1(d)) ;
// setOrbitEmbeddingNewCell<VERTEX>(phi1(d)) ;
}
//2. split faces - quadrangule faces
......@@ -400,7 +400,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
// When importing MR files : activated for DEBUG
// if(embedNewVertices)
// embedNewCell<VERTEX>(phi1(ne)) ;
// setOrbitEmbeddingNewCell<VERTEX>(phi1(ne)) ;
dd = m_map.phi1(m_map.phi1(next)) ;
while(dd != ne) // turn around the face and insert new edges
......@@ -477,7 +477,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
if(m_map.phi3(f1) == f1 && m_map.phi3(f2) == f2)
m_map.sewVolumes(f1, f2, false);
}
m_map.template embedOrbit<VERTEX>(centralDart, m_map.template getEmbedding<VERTEX>(centralDart));
m_map.template setOrbitEmbedding<VERTEX>(centralDart, m_map.template getEmbedding<VERTEX>(centralDart));
m_map.setCurrentLevel(m_map.getMaxLevel() - 1) ;
}
......@@ -488,7 +488,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
for (Dart d = travE2.begin(); d != travE2.end(); d = travE2.next())
{
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
m_map.template embedOrbit<VERTEX>(m_map.phi1(d), m_map.template getEmbedding<VERTEX>(m_map.phi1(d)));
m_map.template setOrbitEmbedding<VERTEX>(m_map.phi1(d), m_map.template getEmbedding<VERTEX>(m_map.phi1(d)));
m_map.setCurrentLevel(m_map.getMaxLevel()-1) ;
}
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
......@@ -498,7 +498,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
for (Dart d = travF2.begin(); d != travF2.end(); d = travF2.next())
{
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
m_map.template embedOrbit<VERTEX>(m_map.phi2(m_map.phi1(d)), m_map.template getEmbedding<VERTEX>(m_map.phi2(m_map.phi1(d))));
m_map.template setOrbitEmbedding<VERTEX>(m_map.phi2(m_map.phi1(d)), m_map.template getEmbedding<VERTEX>(m_map.phi2(m_map.phi1(d))));
m_map.setCurrentLevel(m_map.getMaxLevel()-1) ;
}
m_map.setCurrentLevel(m_map.getMaxLevel()) ;
......@@ -530,9 +530,9 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
// if(!shareVertexEmbeddings)
// {
// if(getEmbedding<VERTEX>(d) == EMBNULL)
// embedNewCell<VERTEX>(d) ;
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// if(getEmbedding<VERTEX>(phi1(d)) == EMBNULL)
// embedNewCell<VERTEX>(d) ;
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// }
//
// cutEdge(d) ;
......@@ -541,7 +541,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
//
//// When importing MR files : activated for DEBUG
// if(embedNewVertices)
// embedNewCell<VERTEX>(phi1(d)) ;
// setOrbitEmbeddingNewCell<VERTEX>(phi1(d)) ;
// }
//
// //2. split faces - quadrangule faces
......@@ -587,7 +587,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
//
// // When importing MR files : activated for DEBUG
// if(embedNewVertices)
// embedNewCell<VERTEX>(phi1(ne)) ;
// setOrbitEmbeddingNewCell<VERTEX>(phi1(ne)) ;
//
// dd = phi1(phi1(next)) ;
// while(dd != ne) // turn around the face and insert new edges
......@@ -681,7 +681,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
//// if(phi3(f1) == f1 && phi3(f2) == f2)
//// sewVolumes(f1, f2, false);
//// }
//// embedOrbit<VERTEX>(centralDart, getEmbedding<VERTEX>(centralDart));