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
e051f352
Commit
e051f352
authored
11 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
try to fix crash on MSVC
parent
6c7a5b0d
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Geo/GFaceCompound.cpp
+29
-25
29 additions, 25 deletions
Geo/GFaceCompound.cpp
with
29 additions
and
25 deletions
Geo/GFaceCompound.cpp
+
29
−
25
View file @
e051f352
...
@@ -2679,14 +2679,17 @@ double GFaceCompound::checkAspectRatio() const
...
@@ -2679,14 +2679,17 @@ double GFaceCompound::checkAspectRatio() const
for
(
int
k
=
0
;
k
<
3
;
k
++
){
for
(
int
k
=
0
;
k
<
3
;
k
++
){
v
[
k
]
=
t
->
getVertex
(
k
);
v
[
k
]
=
t
->
getVertex
(
k
);
}
}
std
::
map
<
MVertex
*
,
SPoint3
>::
const_iterator
it0
=
coordinates
.
find
(
v
[
0
]);
std
::
map
<
MVertex
*
,
SPoint3
>::
const_iterator
it1
=
coordinates
.
find
(
v
[
1
]);
std
::
map
<
MVertex
*
,
SPoint3
>::
const_iterator
it2
=
coordinates
.
find
(
v
[
2
]);
double
p0
[
3
]
=
{
v
[
0
]
->
x
(),
v
[
0
]
->
y
(),
v
[
0
]
->
z
()};
double
p0
[
3
]
=
{
v
[
0
]
->
x
(),
v
[
0
]
->
y
(),
v
[
0
]
->
z
()};
double
p1
[
3
]
=
{
v
[
1
]
->
x
(),
v
[
1
]
->
y
(),
v
[
1
]
->
z
()};
double
p1
[
3
]
=
{
v
[
1
]
->
x
(),
v
[
1
]
->
y
(),
v
[
1
]
->
z
()};
double
p2
[
3
]
=
{
v
[
2
]
->
x
(),
v
[
2
]
->
y
(),
v
[
2
]
->
z
()};
double
p2
[
3
]
=
{
v
[
2
]
->
x
(),
v
[
2
]
->
y
(),
v
[
2
]
->
z
()};
double
a_3D
=
fabs
(
triangle_area
(
p0
,
p1
,
p2
));
double
a_3D
=
fabs
(
triangle_area
(
p0
,
p1
,
p2
));
area3D
+=
a_3D
;
area3D
+=
a_3D
;
std
::
map
<
MVertex
*
,
SPoint3
>::
const_iterator
it0
=
coordinates
.
find
(
v
[
0
]);
std
::
map
<
MVertex
*
,
SPoint3
>::
const_iterator
it1
=
coordinates
.
find
(
v
[
1
]);
std
::
map
<
MVertex
*
,
SPoint3
>::
const_iterator
it2
=
coordinates
.
find
(
v
[
2
]);
if
(
it0
!=
coordinates
.
end
()
&&
it1
!=
coordinates
.
end
()
&&
it2
!=
coordinates
.
end
()){
double
q0
[
3
]
=
{
it0
->
second
.
x
(),
it0
->
second
.
y
(),
0.0
};
double
q0
[
3
]
=
{
it0
->
second
.
x
(),
it0
->
second
.
y
(),
0.0
};
double
q1
[
3
]
=
{
it1
->
second
.
x
(),
it1
->
second
.
y
(),
0.0
};
double
q1
[
3
]
=
{
it1
->
second
.
x
(),
it1
->
second
.
y
(),
0.0
};
double
q2
[
3
]
=
{
it2
->
second
.
x
(),
it2
->
second
.
y
(),
0.0
};
double
q2
[
3
]
=
{
it2
->
second
.
x
(),
it2
->
second
.
y
(),
0.0
};
...
@@ -2695,6 +2698,7 @@ double GFaceCompound::checkAspectRatio() const
...
@@ -2695,6 +2698,7 @@ double GFaceCompound::checkAspectRatio() const
areaMin
=
std
::
min
(
areaMin
,
a_2D
);
areaMin
=
std
::
min
(
areaMin
,
a_2D
);
}
}
}
}
}
std
::
list
<
GEdge
*>::
const_iterator
it0
=
_U0
.
begin
();
std
::
list
<
GEdge
*>::
const_iterator
it0
=
_U0
.
begin
();
double
tot_length
=
0.0
;
double
tot_length
=
0.0
;
...
@@ -2704,7 +2708,7 @@ double GFaceCompound::checkAspectRatio() const
...
@@ -2704,7 +2708,7 @@ double GFaceCompound::checkAspectRatio() const
double
AR
=
M_PI
*
area3D
/
(
tot_length
*
tot_length
);
double
AR
=
M_PI
*
area3D
/
(
tot_length
*
tot_length
);
if
(
areaMin
>
0
&&
areaMin
<
limit
&&
nb
>
3
)
{
if
(
nb
>
3
&&
areaMin
>
0
&&
areaMin
<
limit
)
{
Msg
::
Warning
(
"Too small triangles in mapping (a_2D=%g)"
,
areaMin
);
Msg
::
Warning
(
"Too small triangles in mapping (a_2D=%g)"
,
areaMin
);
}
}
else
{
else
{
...
...
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