Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Thomas Pitiot
CGoGN
Commits
409564ae
Commit
409564ae
authored
Mar 17, 2014
by
Pierre Kraemer
Browse files
update mark vector of Dart & Cell Marker after load
parent
3b468c90
Changes
1
Show whitespace changes
Inline
Side-by-side
src/Topology/generic/genericmap.cpp
View file @
409564ae
...
...
@@ -326,6 +326,17 @@ void GenericMap::removeThreadMarker(unsigned int nb)
void
GenericMap
::
restore_shortcuts
()
{
// NB THREADS
std
::
vector
<
std
::
string
>
typeMark
;
unsigned
int
nbatt0
=
m_attribs
[
0
].
getAttributesTypes
(
typeMark
);
m_nbThreads
=
0
;
for
(
unsigned
int
i
=
0
;
i
<
nbatt0
;
++
i
)
{
if
(
typeMark
[
i
]
==
"Mark"
)
++
m_nbThreads
;
}
// EMBEDDING
// get container of dart orbit
...
...
@@ -384,8 +395,8 @@ void GenericMap::restore_shortcuts()
AttributeMultiVector
<
Mark
>*
amvMark
=
cont
.
getDataVector
<
Mark
>
(
i
);
m_markTables
[
orbit
][
thread
]
=
amvMark
;
if
((
orbit
==
DART
)
&&
(
thread
==
0
))
// for Marker of
dart of thread O keep the boundary marker
{
if
((
orbit
==
DART
)
&&
(
thread
==
0
))
// for
Dart
Marker of
thread O
{
// clear all marks expect boundary marks
Mark
m
(
m_boundaryMarkers
[
0
]
+
m_boundaryMarkers
[
1
]);
m
.
invert
();
for
(
unsigned
int
i
=
cont
.
begin
();
i
!=
cont
.
end
();
cont
.
next
(
i
))
...
...
@@ -400,16 +411,13 @@ void GenericMap::restore_shortcuts()
}
}
// NB THREADS
// restore mark vectors in Dart & Cell Markers
for
(
std
::
vector
<
DartMarkerGen
*>::
iterator
it
=
dartMarkers
.
begin
();
it
!=
dartMarkers
.
end
();
++
it
)
(
*
it
)
->
updateMarkVector
(
m_markTables
[
DART
][(
*
it
)
->
getThread
()]);
for
(
std
::
vector
<
CellMarkerGen
*>::
iterator
it
=
cellMarkers
.
begin
();
it
!=
cellMarkers
.
end
();
++
it
)
(
*
it
)
->
updateMarkVector
(
m_markTables
[(
*
it
)
->
getCell
()][(
*
it
)
->
getThread
()]);
std
::
vector
<
std
::
string
>
typeMark
;
unsigned
int
nbatt0
=
m_attribs
[
0
].
getAttributesTypes
(
typeMark
);
m_nbThreads
=
0
;
for
(
unsigned
int
i
=
0
;
i
<
nbatt0
;
++
i
)
{
if
(
typeMark
[
i
]
==
"Mark"
)
++
m_nbThreads
;
}
}
void
GenericMap
::
dumpAttributesAndMarkers
()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment