Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
4ec4d15c
Commit
4ec4d15c
authored
11 years ago
by
Van Dung Nguyen
Browse files
Options
Downloads
Patches
Plain Diff
remove
parent
1b298e90
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
Geo/GModel.cpp
+0
-45
0 additions, 45 deletions
Geo/GModel.cpp
Geo/GModel.h
+0
-3
0 additions, 3 deletions
Geo/GModel.h
with
0 additions
and
48 deletions
Geo/GModel.cpp
+
0
−
45
View file @
4ec4d15c
...
@@ -815,51 +815,6 @@ MVertex *GModel::getMeshVertexByTag(int n)
...
@@ -815,51 +815,6 @@ MVertex *GModel::getMeshVertexByTag(int n)
return
_vertexMapCache
[
n
];
return
_vertexMapCache
[
n
];
}
}
MVertex
*
GModel
::
getMeshVertexByCoordinates
(
double
x
,
double
y
,
double
z
,
double
tol
)
{
if
(
_vertexVectorCache
.
empty
()
&&
_vertexMapCache
.
empty
()){
Msg
::
Debug
(
"Rebuilding mesh vertex cache"
);
_vertexVectorCache
.
clear
();
_vertexMapCache
.
clear
();
bool
dense
=
(
getNumMeshVertices
()
==
_maxVertexNum
);
std
::
vector
<
GEntity
*>
entities
;
getEntities
(
entities
);
if
(
dense
){
Msg
::
Debug
(
"Good: we have a dense vertex numbering in the cache"
);
// numbering starts at 1
_vertexVectorCache
.
resize
(
_maxVertexNum
+
1
);
for
(
unsigned
int
i
=
0
;
i
<
entities
.
size
();
i
++
)
for
(
unsigned
int
j
=
0
;
j
<
entities
[
i
]
->
mesh_vertices
.
size
();
j
++
)
_vertexVectorCache
[
entities
[
i
]
->
mesh_vertices
[
j
]
->
getNum
()]
=
entities
[
i
]
->
mesh_vertices
[
j
];
}
else
{
for
(
unsigned
int
i
=
0
;
i
<
entities
.
size
();
i
++
)
for
(
unsigned
int
j
=
0
;
j
<
entities
[
i
]
->
mesh_vertices
.
size
();
j
++
)
_vertexMapCache
[
entities
[
i
]
->
mesh_vertices
[
j
]
->
getNum
()]
=
entities
[
i
]
->
mesh_vertices
[
j
];
}
}
for
(
unsigned
int
i
=
1
;
i
<
_vertexVectorCache
.
size
();
i
++
){
MVertex
*
v
=
_vertexVectorCache
[
i
];
double
l
=
sqrt
((
v
->
x
()
-
x
)
*
(
v
->
x
()
-
x
)
+
(
v
->
y
()
-
y
)
*
(
v
->
y
()
-
y
)
+
(
v
->
z
()
-
z
)
*
(
v
->
z
()
-
z
));
if
(
l
<
tol
)
return
v
;
}
for
(
std
::
map
<
int
,
MVertex
*>::
iterator
it
=
_vertexMapCache
.
begin
();
it
!=
_vertexMapCache
.
end
();
it
++
){
MVertex
*
v
=
it
->
second
;
double
l
=
sqrt
((
v
->
x
()
-
x
)
*
(
v
->
x
()
-
x
)
+
(
v
->
y
()
-
y
)
*
(
v
->
y
()
-
y
)
+
(
v
->
z
()
-
z
)
*
(
v
->
z
()
-
z
));
if
(
l
<
tol
)
return
v
;
}
MVertex
*
v
=
new
MVertex
(
x
,
y
,
z
);
_vertexVectorCache
.
push_back
(
v
);
_vertexMapCache
[
v
->
getNum
()]
=
v
;
return
v
;
};
void
GModel
::
getMeshVerticesForPhysicalGroup
(
int
dim
,
int
num
,
std
::
vector
<
MVertex
*>
&
v
)
void
GModel
::
getMeshVerticesForPhysicalGroup
(
int
dim
,
int
num
,
std
::
vector
<
MVertex
*>
&
v
)
{
{
v
.
clear
();
v
.
clear
();
...
...
This diff is collapsed.
Click to expand it.
Geo/GModel.h
+
0
−
3
View file @
4ec4d15c
...
@@ -368,9 +368,6 @@ class GModel
...
@@ -368,9 +368,6 @@ class GModel
// access a mesh vertex by tag, using the vertex cache
// access a mesh vertex by tag, using the vertex cache
MVertex
*
getMeshVertexByTag
(
int
n
);
MVertex
*
getMeshVertexByTag
(
int
n
);
// get a mesh vertex by coordinate, using the vertex cache
MVertex
*
getMeshVertexByCoordinates
(
double
x
,
double
y
,
double
z
,
double
tol
);
// get all the mesh vertices associated with the physical group
// get all the mesh vertices associated with the physical group
// of dimension "dim" and id number "num"
// of dimension "dim" and id number "num"
void
getMeshVerticesForPhysicalGroup
(
int
dim
,
int
num
,
std
::
vector
<
MVertex
*>
&
);
void
getMeshVerticesForPhysicalGroup
(
int
dim
,
int
num
,
std
::
vector
<
MVertex
*>
&
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment