Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
KennethVanhoey
CGoGN
Commits
acd4feb8
Commit
acd4feb8
authored
Oct 15, 2012
by
Pierre Kraemer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
optim gestion plongement dans operateurs EmbeddedMap2
parent
17225370
Changes
24
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
103 additions
and
100 deletions
+103
-100
Apps/deprecated/tp_master.cpp
Apps/deprecated/tp_master.cpp
+1
-1
Apps/deprecated/tutoriel.cpp
Apps/deprecated/tutoriel.cpp
+1
-1
include/Algo/Decimation/edgeSelector.hpp
include/Algo/Decimation/edgeSelector.hpp
+1
-1
include/Algo/Decimation/geometryApproximator.hpp
include/Algo/Decimation/geometryApproximator.hpp
+2
-2
include/Algo/ImplicitHierarchicalMesh/ihm.hpp
include/Algo/ImplicitHierarchicalMesh/ihm.hpp
+1
-1
include/Algo/ImplicitHierarchicalMesh/ihm3.hpp
include/Algo/ImplicitHierarchicalMesh/ihm3.hpp
+1
-1
include/Algo/Modelisation/primitives3d.hpp
include/Algo/Modelisation/primitives3d.hpp
+1
-1
include/Algo/Multiresolution/Map2MR/map2MR_PrimalRegular.hpp
include/Algo/Multiresolution/Map2MR/map2MR_PrimalRegular.hpp
+5
-5
include/Algo/Multiresolution/Map3MR/map3MR_PrimalAdapt.hpp
include/Algo/Multiresolution/Map3MR/map3MR_PrimalAdapt.hpp
+1
-1
include/Algo/Multiresolution/Map3MR/map3MR_PrimalRegular.hpp
include/Algo/Multiresolution/Map3MR/map3MR_PrimalRegular.hpp
+13
-13
include/Algo/ProgressiveMesh/pmesh.hpp
include/Algo/ProgressiveMesh/pmesh.hpp
+3
-3
include/Algo/VolumetricProgressiveMesh/vpmesh.hpp
include/Algo/VolumetricProgressiveMesh/vpmesh.hpp
+3
-3
include/Topology/generic/attribmap.hpp
include/Topology/generic/attribmap.hpp
+1
-1
include/Topology/generic/attributeHandler.hpp
include/Topology/generic/attributeHandler.hpp
+1
-1
include/Topology/generic/cellmarker.h
include/Topology/generic/cellmarker.h
+2
-2
include/Topology/generic/dartmarker.h
include/Topology/generic/dartmarker.h
+0
-1
include/Topology/generic/ecell.hpp
include/Topology/generic/ecell.hpp
+1
-1
include/Topology/generic/genericmap.h
include/Topology/generic/genericmap.h
+1
-1
include/Topology/generic/genericmap.hpp
include/Topology/generic/genericmap.hpp
+6
-6
src/Algo/ImplicitHierarchicalMesh/ihm3.cpp
src/Algo/ImplicitHierarchicalMesh/ihm3.cpp
+1
-1
src/Topology/gmap/embeddedGMap2.cpp
src/Topology/gmap/embeddedGMap2.cpp
+9
-9
src/Topology/gmap/embeddedGMap3.cpp
src/Topology/gmap/embeddedGMap3.cpp
+6
-6
src/Topology/map/embeddedMap2.cpp
src/Topology/map/embeddedMap2.cpp
+33
-29
src/Topology/map/embeddedMap3.cpp
src/Topology/map/embeddedMap3.cpp
+9
-9
No files found.
Apps/deprecated/tp_master.cpp
View file @
acd4feb8
...
...
@@ -92,7 +92,7 @@ private:
// Assigne un nouveau plongement au sommet. Les anciens plongements sont libérés.
void
newVertex
(
Dart
d
)
{
setOrbitEmbeddingNewCell
<
VERTEX
>
(
d
);
setOrbitEmbedding
On
NewCell
<
VERTEX
>
(
d
);
}
public:
...
...
Apps/deprecated/tutoriel.cpp
View file @
acd4feb8
...
...
@@ -95,7 +95,7 @@ private:
// Assigne un nouveau plongement au sommet. Les anciens plongements sont libérés.
void
newVertex
(
Dart
d
)
{
setOrbitEmbeddingNewCell
(
VERTEX
,
d
);
setOrbitEmbedding
On
NewCell
(
VERTEX
,
d
);
}
public:
...
...
include/Algo/Decimation/edgeSelector.hpp
View file @
acd4feb8
...
...
@@ -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
setOrbitEmbeddingNewCell
<
VERTEX
>(
d2
)
;
unsigned
int
newV
=
m
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
d2
)
;
this
->
m_position
[
newV
]
=
m_positionApproximator
->
getApprox
(
d
)
;
// compute things on the coarse version of the mesh
...
...
include/Algo/Decimation/geometryApproximator.hpp
View file @
acd4feb8
...
...
@@ -211,7 +211,7 @@ void Approximator_MidEdge<PFP>::approximate(Dart d)
// temporary edge collapse
m
.
extractTrianglePair
(
d
)
;
unsigned
int
newV
=
m
.
template
setOrbitEmbeddingNewCell
<
VERTEX
>(
d2
)
;
unsigned
int
newV
=
m
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
d2
)
;
this
->
m_attrV
[
0
]
->
operator
[](
newV
)
=
this
->
m_approx
[
0
][
d
]
;
// compute the detail vector
...
...
@@ -260,7 +260,7 @@ void Approximator_HalfCollapse<PFP>::approximate(Dart d)
// temporary edge collapse
m
.
extractTrianglePair
(
d
)
;
unsigned
int
newV
=
m
.
template
setOrbitEmbeddingNewCell
<
VERTEX
>(
d2
)
;
unsigned
int
newV
=
m
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
d2
)
;
for
(
unsigned
int
i
=
0
;
i
<
this
->
m_attrV
.
size
()
;
++
i
)
{
this
->
m_attrV
[
i
]
->
operator
[](
newV
)
=
this
->
m_approx
[
i
][
d
]
;
...
...
include/Algo/ImplicitHierarchicalMesh/ihm.hpp
View file @
acd4feb8
...
...
@@ -349,7 +349,7 @@ T& AttributeHandler_IHM<T, ORBIT>::operator[](Dart d)
if
(
index
==
EMBNULL
)
{
index
=
m
->
setOrbitEmbeddingNewCell
<
ORBIT
>
(
d
)
;
index
=
m
->
setOrbitEmbedding
On
NewCell
<
ORBIT
>
(
d
)
;
m
->
m_nextLevelCell
[
orbit
]
->
operator
[](
index
)
=
EMBNULL
;
}
...
...
include/Algo/ImplicitHierarchicalMesh/ihm3.hpp
View file @
acd4feb8
...
...
@@ -616,7 +616,7 @@ T& AttributeHandler_IHM<T, ORBIT>::operator[](Dart d)
if
(
index
==
EMBNULL
)
{
index
=
m
->
setOrbitEmbeddingNewCell
<
ORBIT
>
(
d
)
;
index
=
m
->
setOrbitEmbedding
On
NewCell
<
ORBIT
>
(
d
)
;
m
->
m_nextLevelCell
[
orbit
]
->
operator
[](
index
)
=
EMBNULL
;
}
...
...
include/Algo/Modelisation/primitives3d.hpp
View file @
acd4feb8
...
...
@@ -176,7 +176,7 @@ void Primitive3D<PFP>::embedHexaGrid(float x, float y, float z)
typename
PFP
::
VEC3
pos
(
-
x
/
2.0
f
+
dx
*
float
(
k
),
-
y
/
2.0
f
+
dy
*
float
(
j
),
-
z
/
2.0
f
+
dz
*
float
(
i
));
Dart
d
=
m_tableVertDarts
[
i
*
nbs
+
j
*
(
m_nx
+
1
)
+
k
];
m_map
.
template
setOrbitEmbeddingNewCell
<
VERTEX
>(
d
);
m_map
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
d
);
m_positions
[
d
]
=
pos
;
}
}
...
...
include/Algo/Multiresolution/Map2MR/map2MR_PrimalRegular.hpp
View file @
acd4feb8
...
...
@@ -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
setOrbitEmbeddingNewCell
<
VERTEX
>(
d
)
;
m_map
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
d
)
;
if
(
m_map
.
template
getEmbedding
<
VERTEX
>(
m_map
.
phi1
(
d
))
==
EMBNULL
)
m_map
.
template
setOrbitEmbeddingNewCell
<
VERTEX
>(
d
)
;
m_map
.
template
setOrbitEmbedding
On
NewCell
<
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
setOrbitEmbeddingNewCell
<
VERTEX
>(
m_map
.
phi1
(
d
))
;
m_map
.
template
setOrbitEmbedding
On
NewCell
<
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
setOrbitEmbeddingNewCell
<
VERTEX
>(
m_map
.
phi1
(
ne
))
;
m_map
.
template
setOrbitEmbedding
On
NewCell
<
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
setOrbitEmbeddingNewCell
<
VERTEX
>(
cd
)
;
m_map
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
cd
)
;
Dart
fit
=
cd
;
do
...
...
include/Algo/Multiresolution/Map3MR/map3MR_PrimalAdapt.hpp
View file @
acd4feb8
...
...
@@ -83,7 +83,7 @@ void Map3MR<PFP>::swapEdges(Dart d, Dart e)
}
if
(
m_map
.
template
isOrbitEmbedded
<
VOLUME
>())
m_map
.
template
setOrbitEmbeddingNewCell
<
VOLUME
>(
d
);
m_map
.
template
setOrbitEmbedding
On
NewCell
<
VOLUME
>(
d
);
// propagateDartRelation(d, m_phi2) ;
...
...
include/Algo/Multiresolution/Map3MR/map3MR_PrimalRegular.hpp
View file @
acd4feb8
...
...
@@ -73,7 +73,7 @@ void Map3MR<PFP>::swapEdges(Dart d, Dart e)
}
if
(
m_map
.
template
isOrbitEmbedded
<
VOLUME
>())
m_map
.
template
setOrbitEmbeddingNewCell
<
VOLUME
>(
d
);
m_map
.
template
setOrbitEmbedding
On
NewCell
<
VOLUME
>(
d
);
}
}
...
...
@@ -203,9 +203,9 @@ void Map3MR<PFP>::addNewLevelTetraOcta(bool embedNewVertices)
// if(!shareVertexEmbeddings)
// {
// if(getEmbedding<VERTEX>(d) == EMBNULL)
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// setOrbitEmbedding
On
NewCell<VERTEX>(d) ;
// if(getEmbedding<VERTEX>(phi1(d)) == EMBNULL)
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// setOrbitEmbedding
On
NewCell<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 setOrbitEmbeddingNewCell<VERTEX>(m_map.phi1(d)) ;
// m_map.template setOrbitEmbedding
On
NewCell<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 setOrbitEmbeddingNewCell<VERTEX>(x) ;
// m_map.template setOrbitEmbedding
On
NewCell<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)
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// setOrbitEmbedding
On
NewCell<VERTEX>(d) ;
// if(getEmbedding<VERTEX>(phi1(d)) == EMBNULL)
// setOrbitEmbeddingNewCell<VERTEX>(phi1(d)) ;
// setOrbitEmbedding
On
NewCell<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)
// setOrbitEmbeddingNewCell<VERTEX>(phi1(d)) ;
// setOrbitEmbedding
On
NewCell<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)
// setOrbitEmbeddingNewCell<VERTEX>(phi1(ne)) ;
// setOrbitEmbedding
On
NewCell<VERTEX>(phi1(ne)) ;
dd
=
m_map
.
phi1
(
m_map
.
phi1
(
next
))
;
while
(
dd
!=
ne
)
// turn around the face and insert new edges
...
...
@@ -530,9 +530,9 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
// if(!shareVertexEmbeddings)
// {
// if(getEmbedding<VERTEX>(d) == EMBNULL)
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// setOrbitEmbedding
On
NewCell<VERTEX>(d) ;
// if(getEmbedding<VERTEX>(phi1(d)) == EMBNULL)
// setOrbitEmbeddingNewCell<VERTEX>(d) ;
// setOrbitEmbedding
On
NewCell<VERTEX>(d) ;
// }
//
// cutEdge(d) ;
...
...
@@ -541,7 +541,7 @@ void Map3MR<PFP>::addNewLevelHexa(bool embedNewVertices)
//
//// When importing MR files : activated for DEBUG
// if(embedNewVertices)
// setOrbitEmbeddingNewCell<VERTEX>(phi1(d)) ;
// setOrbitEmbedding
On
NewCell<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)
// setOrbitEmbeddingNewCell<VERTEX>(phi1(ne)) ;
// setOrbitEmbedding
On
NewCell<VERTEX>(phi1(ne)) ;
//
// dd = phi1(phi1(next)) ;
// while(dd != ne) // turn around the face and insert new edges
...
...
include/Algo/ProgressiveMesh/pmesh.hpp
View file @
acd4feb8
...
...
@@ -174,9 +174,9 @@ void ProgressiveMesh<PFP>::createPM(unsigned int percentWantedVertices)
edgeCollapse
(
vs
)
;
// collapse edge
unsigned
int
newV
=
m_map
.
template
setOrbitEmbeddingNewCell
<
VERTEX
>(
d2
)
;
unsigned
int
newE1
=
m_map
.
template
setOrbitEmbeddingNewCell
<
EDGE
>(
d2
)
;
unsigned
int
newE2
=
m_map
.
template
setOrbitEmbeddingNewCell
<
EDGE
>(
dd2
)
;
unsigned
int
newV
=
m_map
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
d2
)
;
unsigned
int
newE1
=
m_map
.
template
setOrbitEmbedding
On
NewCell
<
EDGE
>(
d2
)
;
unsigned
int
newE2
=
m_map
.
template
setOrbitEmbedding
On
NewCell
<
EDGE
>(
dd2
)
;
vs
->
setApproxV
(
newV
)
;
vs
->
setApproxE1
(
newE1
)
;
vs
->
setApproxE2
(
newE2
)
;
...
...
include/Algo/VolumetricProgressiveMesh/vpmesh.hpp
View file @
acd4feb8
...
...
@@ -132,9 +132,9 @@ void VolumetricProgressiveMesh<PFP>::createPM(unsigned int percentWantedVertices
edgeCollapse
(
vs
)
;
// collapse edge
unsigned
int
newV
=
m_map
.
template
setOrbitEmbeddingNewCell
<
VERTEX
>(
d2
)
;
unsigned
int
newE1
=
m_map
.
template
setOrbitEmbeddingNewCell
<
EDGE
>(
d2
)
;
unsigned
int
newE2
=
m_map
.
template
setOrbitEmbeddingNewCell
<
EDGE
>(
dd2
)
;
unsigned
int
newV
=
m_map
.
template
setOrbitEmbedding
On
NewCell
<
VERTEX
>(
d2
)
;
unsigned
int
newE1
=
m_map
.
template
setOrbitEmbedding
On
NewCell
<
EDGE
>(
d2
)
;
unsigned
int
newE2
=
m_map
.
template
setOrbitEmbedding
On
NewCell
<
EDGE
>(
dd2
)
;
vs
->
setApproxV
(
newV
)
;
vs
->
setApproxE1
(
newE1
)
;
vs
->
setApproxE2
(
newE2
)
;
...
...
include/Topology/generic/attribmap.hpp
View file @
acd4feb8
...
...
@@ -121,7 +121,7 @@ void AttribMap::bijectiveOrbitEmbedding()
{
if
(
counter
[
d
]
>
0
)
{
unsigned
int
newEmb
=
setOrbitEmbeddingNewCell
<
ORBIT
>
(
d
)
;
unsigned
int
newEmb
=
setOrbitEmbedding
On
NewCell
<
ORBIT
>
(
d
)
;
copyCell
<
ORBIT
>
(
newEmb
,
emb
)
;
}
counter
[
d
]
++
;
...
...
include/Topology/generic/attributeHandler.hpp
View file @
acd4feb8
...
...
@@ -138,7 +138,7 @@ inline T& AttributeHandler<T, ORBIT>::operator[](Dart d)
unsigned
int
a
=
m_map
->
getEmbedding
<
ORBIT
>
(
d
)
;
/*
if (a == EMBNULL)
a = m_map->setOrbitEmbeddingNewCell<ORBIT>(d) ;
a = m_map->setOrbitEmbedding
On
NewCell<ORBIT>(d) ;
*/
return
m_attrib
->
operator
[](
a
)
;
}
...
...
include/Topology/generic/cellmarker.h
View file @
acd4feb8
...
...
@@ -133,7 +133,7 @@ public:
unsigned
int
a
=
m_map
.
getEmbedding
<
CELL
>
(
d
)
;
// if (a == EMBNULL)
// a = m_map.setOrbitEmbeddingNewCell<CELL>(d) ;
// a = m_map.setOrbitEmbedding
On
NewCell<CELL>(d) ;
m_markVector
->
operator
[](
a
).
setMark
(
m_mark
)
;
}
...
...
@@ -147,7 +147,7 @@ public:
unsigned
int
a
=
m_map
.
getEmbedding
<
CELL
>
(
d
)
;
// if (a == EMBNULL)
// a = m_map.setOrbitEmbeddingNewCell<CELL>(d) ;
// a = m_map.setOrbitEmbedding
On
NewCell<CELL>(d) ;
m_markVector
->
operator
[](
a
).
unsetMark
(
m_mark
)
;
}
...
...
include/Topology/generic/dartmarker.h
View file @
acd4feb8
...
...
@@ -46,7 +46,6 @@ protected:
Mark
m_mark
;
AttributeMultiVector
<
Mark
>*
m_markVector
;
unsigned
int
m_thread
;
// unsigned int m_idReg ;
bool
releaseOnDestruct
;
public:
...
...
include/Topology/generic/ecell.hpp
View file @
acd4feb8
...
...
@@ -146,7 +146,7 @@ ECellDart<DIM> ECellDart<DIM>::operator[](Dart d)
unsigned
int
a
=
s_map
->
getEmbedding
(
d
,
DIM
);
if
(
a
==
EMBNULL
)
a
=
s_map
->
setOrbitEmbeddingNewCell
(
DIM
,
d
);
a
=
s_map
->
setOrbitEmbedding
On
NewCell
(
DIM
,
d
);
return
ECellDart
<
DIM
>
(
a
);
}
...
...
include/Topology/generic/genericmap.h
View file @
acd4feb8
...
...
@@ -404,7 +404,7 @@ public:
* @return index of the attribute in table
*/
template
<
unsigned
int
ORBIT
>
unsigned
int
setOrbitEmbeddingNewCell
(
Dart
d
)
;
unsigned
int
setOrbitEmbedding
On
NewCell
(
Dart
d
)
;
/**
* Associate an new cell to all darts of an orbit
...
...
include/Topology/generic/genericmap.hpp
View file @
acd4feb8
...
...
@@ -373,7 +373,7 @@ inline void GenericMap::initOrbitEmbedding(Dart d, unsigned int em)
}
template
<
unsigned
int
ORBIT
>
inline
unsigned
int
GenericMap
::
setOrbitEmbeddingNewCell
(
Dart
d
)
inline
unsigned
int
GenericMap
::
setOrbitEmbedding
On
NewCell
(
Dart
d
)
{
assert
(
isOrbitEmbedded
<
ORBIT
>
()
||
!
"Invalid parameter: orbit not embedded"
);
unsigned
int
em
=
newCell
<
ORBIT
>
();
...
...
@@ -396,12 +396,12 @@ inline void GenericMap::copyCell(Dart d, Dart e)
assert
(
isOrbitEmbedded
<
ORBIT
>
()
||
!
"Invalid parameter: orbit not embedded"
);
unsigned
int
dE
=
getEmbedding
<
ORBIT
>
(
d
)
;
unsigned
int
eE
=
getEmbedding
<
ORBIT
>
(
e
)
;
if
(
eE
!=
EMBNULL
)
// if the source is NULL, nothing to copy
{
if
(
dE
==
EMBNULL
)
// if the dest is NULL, create a new cell
dE
=
setOrbitEmbeddingNewCell
<
ORBIT
>
(
d
)
;
//
if(eE != EMBNULL) // if the source is NULL, nothing to copy
//
{
//
if(dE == EMBNULL) // if the dest is NULL, create a new cell
//
dE = setOrbitEmbedding
On
NewCell<ORBIT>(d) ;
m_attribs
[
ORBIT
].
copyLine
(
dE
,
eE
)
;
// copy the data
}
//
}
}
template
<
unsigned
int
ORBIT
>
...
...
src/Algo/ImplicitHierarchicalMesh/ihm3.cpp
View file @
acd4feb8
...
...
@@ -111,7 +111,7 @@ void ImplicitHierarchicalMap3::swapEdges(Dart d, Dart e)
}
if
(
isOrbitEmbedded
<
VOLUME
>
())
setOrbitEmbeddingNewCell
<
VOLUME
>
(
d
);
setOrbitEmbedding
On
NewCell
<
VOLUME
>
(
d
);
}
}
...
...
src/Topology/gmap/embeddedGMap2.cpp
View file @
acd4feb8
...
...
@@ -44,7 +44,7 @@ void EmbeddedGMap2::splitVertex(Dart d, Dart e)
setDartEmbedding
<
VERTEX
>
(
beta2
(
phi1
(
dd
)),
vEmb
)
;
setDartEmbedding
<
VERTEX
>
(
beta0
(
dd
),
vEmb
)
;
setOrbitEmbeddingNewCell
<
VERTEX
>
(
e
)
;
setOrbitEmbedding
On
NewCell
<
VERTEX
>
(
e
)
;
copyCell
<
VERTEX
>
(
e
,
d
)
;
}
...
...
@@ -91,7 +91,7 @@ Dart EmbeddedGMap2::cutEdge(Dart d)
unsigned
int
eEmb
=
getEmbedding
<
EDGE
>
(
d
)
;
setDartEmbedding
<
EDGE
>
(
phi2
(
d
),
eEmb
)
;
setDartEmbedding
<
EDGE
>
(
beta0
(
d
),
eEmb
)
;
setOrbitEmbeddingNewCell
<
EDGE
>
(
nd
)
;
setOrbitEmbedding
On
NewCell
<
EDGE
>
(
nd
)
;
copyCell
<
EDGE
>
(
nd
,
d
)
;
}
...
...
@@ -264,7 +264,7 @@ bool EmbeddedGMap2::flipBackEdge(Dart d)
// {
// if(!sameFace(d,e))
// {
// setOrbitEmbeddingNewCell<FACE>(e);
// setOrbitEmbedding
On
NewCell<FACE>(e);
// copyCell<FACE>(e, d) ;
// }
// else
...
...
@@ -282,7 +282,7 @@ bool EmbeddedGMap2::flipBackEdge(Dart d)
//
// if (isOrbitEmbedded<VERTEX>())
// {
// setOrbitEmbeddingNewCell<VERTEX>(d);
// setOrbitEmbedding
On
NewCell<VERTEX>(d);
// copyCell<VERTEX>(d, dPrev);
// }
//
...
...
@@ -290,7 +290,7 @@ bool EmbeddedGMap2::flipBackEdge(Dart d)
// {
// if(!sameFace(d, dPrev))
// {
// setOrbitEmbeddingNewCell<FACE>(d);
// setOrbitEmbedding
On
NewCell<FACE>(d);
// copyCell<FACE>(d, dPrev) ;
// }
// else
...
...
@@ -332,7 +332,7 @@ void EmbeddedGMap2::unsewFaces(Dart d)
{
if
(
!
sameVertex
(
d
,
e
))
{
setOrbitEmbeddingNewCell
<
VERTEX
>
(
e
);
setOrbitEmbedding
On
NewCell
<
VERTEX
>
(
e
);
copyCell
<
VERTEX
>
(
e
,
d
);
}
...
...
@@ -341,14 +341,14 @@ void EmbeddedGMap2::unsewFaces(Dart d)
if
(
!
sameVertex
(
d
,
e
))
{
setOrbitEmbeddingNewCell
<
VERTEX
>
(
e
);
setOrbitEmbedding
On
NewCell
<
VERTEX
>
(
e
);
copyCell
<
VERTEX
>
(
e
,
d
);
}
}
if
(
isOrbitEmbedded
<
EDGE
>
())
{
setOrbitEmbeddingNewCell
<
EDGE
>
(
e
);
setOrbitEmbedding
On
NewCell
<
EDGE
>
(
e
);
copyCell
<
EDGE
>
(
e
,
d
);
}
}
...
...
@@ -399,7 +399,7 @@ void EmbeddedGMap2::splitFace(Dart d, Dart e)
unsigned
int
fEmb
=
getEmbedding
<
FACE
>
(
d
)
;
setDartEmbedding
<
FACE
>
(
phi_1
(
d
),
fEmb
)
;
setDartEmbedding
<
FACE
>
(
beta1
(
phi_1
(
d
)),
fEmb
)
;
setOrbitEmbeddingNewCell
<
FACE
>
(
e
)
;
setOrbitEmbedding
On
NewCell
<
FACE
>
(
e
)
;
copyCell
<
FACE
>
(
e
,
d
)
;
}
}
...
...
src/Topology/gmap/embeddedGMap3.cpp
View file @
acd4feb8
...
...
@@ -59,7 +59,7 @@ Dart EmbeddedGMap3::cutEdge(Dart d)
}
while
(
e
!=
d
)
;
// embed a new cell for the new edge and copy the attributes' line (c) Lionel
setOrbitEmbeddingNewCell
<
EDGE
>
(
phi1
(
d
))
;
setOrbitEmbedding
On
NewCell
<
EDGE
>
(
phi1
(
d
))
;
copyCell
<
EDGE
>
(
phi1
(
d
),
d
)
;
}
...
...
@@ -169,7 +169,7 @@ void EmbeddedGMap3::splitFace(Dart d, Dart e)
setDartEmbedding
<
FACE
>
(
beta1
(
ee
),
fEmb
)
;
setDartEmbedding
<
FACE
>
(
beta0
(
beta1
(
ee
)),
fEmb
)
;
setDartEmbedding
<
FACE
>
(
beta1
(
beta0
(
beta1
(
ee
))),
fEmb
)
;
setOrbitEmbeddingNewCell
<
FACE
>
(
e
);
setOrbitEmbedding
On
NewCell
<
FACE
>
(
e
);
copyCell
<
FACE
>
(
e
,
d
);
}
...
...
@@ -248,7 +248,7 @@ void EmbeddedGMap3::unsewVolumes(Dart d)
if
(
!
sameVertex
(
dit
,
dd
))
{
setOrbitEmbedding
<
VERTEX
>
(
dit
,
getEmbedding
<
VERTEX
>
(
dit
))
;
setOrbitEmbeddingNewCell
<
VERTEX
>
(
dd
);
setOrbitEmbedding
On
NewCell
<
VERTEX
>
(
dd
);
copyCell
<
VERTEX
>
(
dd
,
dit
);
}
else
...
...
@@ -265,7 +265,7 @@ void EmbeddedGMap3::unsewVolumes(Dart d)
if
(
!
sameEdge
(
dit
,
dd
))
{
setOrbitEmbedding
<
EDGE
>
(
dit
,
getEmbedding
<
EDGE
>
(
dit
))
;
setOrbitEmbeddingNewCell
<
EDGE
>
(
dd
);
setOrbitEmbedding
On
NewCell
<
EDGE
>
(
dd
);
copyCell
<
EDGE
>
(
dd
,
dit
);
}
else
...
...
@@ -286,7 +286,7 @@ void EmbeddedGMap3::unsewVolumes(Dart d)
// embed the unsewn face with the face embedding
if
(
isOrbitEmbedded
<
FACE
>
())
{
setOrbitEmbeddingNewCell
<
FACE
>
(
dd
);
setOrbitEmbedding
On
NewCell
<
FACE
>
(
dd
);
copyCell
<
FACE
>
(
dd
,
d
);
}
}
...
...
@@ -348,7 +348,7 @@ void EmbeddedGMap3::splitVolume(std::vector<Dart>& vd)
{
Dart
v
=
vd
.
front
()
;
Dart
v23
=
alpha2
(
v
)
;
setOrbitEmbeddingNewCell
<
VOLUME
>
(
v23
)
;
setOrbitEmbedding
On
NewCell
<
VOLUME
>
(
v23
)
;
copyCell
<
VOLUME
>
(
v23
,
v
)
;
}
}
...
...
src/Topology/map/embeddedMap2.cpp
View file @
acd4feb8
...
...
@@ -39,9 +39,8 @@ void EmbeddedMap2::splitVertex(Dart d, Dart e)
if
(
isOrbitEmbedded
<
VERTEX
>
())
{
copyDartEmbedding
<
VERTEX
>
(
phi1
(
dd
),
d
)
;
copyDartEmbedding
<
VERTEX
>
(
phi1
(
ee
),
e
)
;
setOrbitEmbeddingNewCell
<
VERTEX
>
(
e
)
;
initDartEmbedding
<
VERTEX
>
(
phi1
(
dd
),
getEmbedding
<
VERTEX
>
(
d
))
;
setOrbitEmbeddingOnNewCell
<
VERTEX
>
(
e
)
;
copyCell
<
VERTEX
>
(
e
,
d
)
;
}
...
...
@@ -52,8 +51,8 @@ void EmbeddedMap2::splitVertex(Dart d, Dart e)
if
(
isOrbitEmbedded
<
FACE
>
())
{
copy
DartEmbedding
<
FACE
>
(
phi1
(
dd
),
dd
)
;
copy
DartEmbedding
<
FACE
>
(
phi1
(
ee
),
ee
)
;
init
DartEmbedding
<
FACE
>
(
phi1
(
dd
),
getEmbedding
<
FACE
>
(
dd
)
)
;
init
DartEmbedding
<
FACE
>
(
phi1
(
ee
),
getEmbedding
<
FACE
>
(
ee
)
)
;
}
}
...
...
@@ -81,16 +80,16 @@ Dart EmbeddedMap2::cutEdge(Dart d)
if
(
isOrbitEmbedded
<
EDGE
>
())
{
copy
DartEmbedding
<
EDGE
>
(
phi2
(
d
),
d
)
;
setOrbitEmbeddingNewCell
<
EDGE
>
(
nd
)
;
init
DartEmbedding
<
EDGE
>
(
phi2
(
d
),
getEmbedding
<
EDGE
>
(
d
)
)
;
setOrbitEmbedding
On
NewCell
<
EDGE
>
(
nd
)
;
copyCell
<
EDGE
>
(
nd
,
d
)
;
}
if
(
isOrbitEmbedded
<
FACE
>
())
{
copy
DartEmbedding
<
FACE
>
(
nd
,
d
)
;
init
DartEmbedding
<
FACE
>
(
nd
,
getEmbedding
<
FACE
>
(
d
)
)
;
Dart
e
=
phi2
(
nd
)
;
copy
DartEmbedding
<
FACE
>
(
phi1
(
e
),
e
)
;
init
DartEmbedding
<
FACE
>
(
phi1
(
e
),
getEmbedding
<
FACE
>
(
e
)
)
;
}
return
nd
;
...
...
@@ -187,11 +186,13 @@ bool EmbeddedMap2::flipEdge(Dart d)
copyDartEmbedding
<
VERTEX
>
(
d
,
phi1
(
e
))
;
copyDartEmbedding
<
VERTEX
>
(
e
,
phi1
(
d
))
;
}
if
(
isOrbitEmbedded
<
FACE
>
())
{
copyDartEmbedding
<
FACE
>
(
phi_1
(
d
),
d
)
;
copyDartEmbedding
<
FACE
>
(
phi_1
(
e
),
e
)
;
}
return
true
;
}
return
false
;
...
...
@@ -208,11 +209,13 @@ bool EmbeddedMap2::flipBackEdge(Dart d)
copyDartEmbedding
<
VERTEX
>
(
d
,
phi1
(
e
))
;
copyDartEmbedding
<
VERTEX
>
(
e
,
phi1
(
d
))
;
}
if
(
isOrbitEmbedded
<
FACE
>
())
{
copyDartEmbedding
<
FACE
>
(
phi1
(
d
),
d
)
;
copyDartEmbedding
<
FACE
>
(
phi1
(
e
),
e
)
;
}
return
true
;
}
return
false
;
...
...
@@ -238,7 +241,7 @@ void EmbeddedMap2::swapEdges(Dart d, Dart e)
}
if
(
isOrbitEmbedded
<
VOLUME
>
())
setOrbitEmbeddingNewCell
<
VOLUME
>
(
d
);
setOrbitEmbedding
On
NewCell
<
VOLUME
>
(
d
);
}
//void EmbeddedMap2::insertEdgeInVertex(Dart d, Dart e)
...
...
@@ -254,7 +257,7 @@ void EmbeddedMap2::swapEdges(Dart d, Dart e)
// {
// if(!sameFace(d,e))
// {
// setOrbitEmbeddingNewCell<FACE>(e);
// setOrbitEmbedding
On
NewCell<FACE>(e);
// copyCell<FACE>(e, d) ;
// }
// else
...
...
@@ -272,7 +275,7 @@ void EmbeddedMap2::swapEdges(Dart d, Dart e)
//
// if (isOrbitEmbedded<VERTEX>())
// {
// setOrbitEmbeddingNewCell<VERTEX>(d);
// setOrbitEmbedding
On
NewCell<VERTEX>(d);
// copyCell<VERTEX>(d, dPrev);
// }
//
...
...
@@ -280,7 +283,7 @@ void EmbeddedMap2::swapEdges(Dart d, Dart e)
// {
// if(!sameFace(d, dPrev))
// {
// setOrbitEmbeddingNewCell<FACE>(d);
// setOrbitEmbedding
On
NewCell<FACE>(d);
// copyCell<FACE>(d, dPrev) ;
// }
// else
...
...
@@ -322,21 +325,21 @@ void EmbeddedMap2::unsewFaces(Dart d)
Dart
ee
=
phi1
(
e
)
;
if
(
!
sameVertex
(
d
,
ee
))
{
setOrbitEmbeddingNewCell
<
VERTEX
>
(
ee
);
setOrbitEmbedding
On
NewCell
<
VERTEX
>
(
ee
);
copyCell
<
VERTEX
>
(
ee
,
d
);
}
Dart
dd
=
phi1
(
d
)
;
if
(
!
sameVertex
(
e
,
dd
))
{
setOrbitEmbeddingNewCell
<
VERTEX
>
(
dd
);
setOrbitEmbedding
On
NewCell
<
VERTEX
>
(
dd
);
copyCell
<
VERTEX
>
(
dd
,
e
);
}
}