Salome HOME
projects
/
modules
/
smesh.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
23304: [EDF 10304] Radial Quadrangle on ellipse
[modules/smesh.git]
/
src
/
StdMeshers
/
StdMeshers_MEFISTO_2D.cxx
diff --git
a/src/StdMeshers/StdMeshers_MEFISTO_2D.cxx
b/src/StdMeshers/StdMeshers_MEFISTO_2D.cxx
index 0616b630da55deb296c525626d583a9f11a2bd56..7ae149535504400bdcbb0ee387bddb4d9037dcab 100644
(file)
--- a/
src/StdMeshers/StdMeshers_MEFISTO_2D.cxx
+++ b/
src/StdMeshers/StdMeshers_MEFISTO_2D.cxx
@@
-1,4
+1,4
@@
-// Copyright (C) 2007-201
5
CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-201
6
CEA/DEN, EDF R&D, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@
-31,6
+31,7
@@
#include "SMDS_EdgePosition.hxx"
#include "SMDS_MeshElement.hxx"
#include "SMDS_MeshNode.hxx"
#include "SMDS_EdgePosition.hxx"
#include "SMDS_MeshElement.hxx"
#include "SMDS_MeshNode.hxx"
+#include "SMESHDS_Mesh.hxx"
#include "SMESH_Comment.hxx"
#include "SMESH_Gen.hxx"
#include "SMESH_Mesh.hxx"
#include "SMESH_Comment.hxx"
#include "SMESH_Gen.hxx"
#include "SMESH_Mesh.hxx"
@@
-587,7
+588,7
@@
bool StdMeshers_MEFISTO_2D::LoadPoints(TWireVector & wires,
F = TopoDS::Face( _helper->GetSubShape() );
TopExp::MapShapesAndAncestors( F, TopAbs_VERTEX, TopAbs_WIRE, VWMap );
int nbVertices = 0;
F = TopoDS::Face( _helper->GetSubShape() );
TopExp::MapShapesAndAncestors( F, TopAbs_VERTEX, TopAbs_WIRE, VWMap );
int nbVertices = 0;
- for (
in
t iW = 0; iW < wires.size(); ++iW )
+ for (
size_
t iW = 0; iW < wires.size(); ++iW )
nbVertices += wires[ iW ]->NbEdges();
if ( nbVertices == VWMap.Extent() )
VWMap.Clear(); // wires have no common vertices
nbVertices += wires[ iW ]->NbEdges();
if ( nbVertices == VWMap.Extent() )
VWMap.Clear(); // wires have no common vertices
@@
-595,10
+596,10
@@
bool StdMeshers_MEFISTO_2D::LoadPoints(TWireVector & wires,
int m = 0;
int m = 0;
- for (
in
t iW = 0; iW < wires.size(); ++iW )
+ for (
size_
t iW = 0; iW < wires.size(); ++iW )
{
const vector<UVPtStruct>& uvPtVec = wires[ iW ]->GetUVPtStruct();
{
const vector<UVPtStruct>& uvPtVec = wires[ iW ]->GetUVPtStruct();
- if ( uvPtVec.size() != wires[ iW ]->NbPoints() ) {
+ if (
(int)
uvPtVec.size() != wires[ iW ]->NbPoints() ) {
return error(COMPERR_BAD_INPUT_MESH,SMESH_Comment("Unexpected nb of points on wire ")
<< iW << ": " << uvPtVec.size()<<" != "<<wires[ iW ]->NbPoints()
<< ", probably because of invalid node parameters on geom edges");
return error(COMPERR_BAD_INPUT_MESH,SMESH_Comment("Unexpected nb of points on wire ")
<< iW << ": " << uvPtVec.size()<<" != "<<wires[ iW ]->NbPoints()
<< ", probably because of invalid node parameters on geom edges");
@@
-696,7
+697,7
@@
void StdMeshers_MEFISTO_2D::ComputeScaleOnFace(SMESH_Mesh & aMesh,
double xmax = -1.e300;
double ymin = 1.e300;
double ymax = -1.e300;
double xmax = -1.e300;
double ymin = 1.e300;
double ymax = -1.e300;
- int nbp = 23;
+
const
int nbp = 23;
scalex = 1;
scaley = 1;
scalex = 1;
scaley = 1;
@@
-720,13
+721,8
@@
void StdMeshers_MEFISTO_2D::ComputeScaleOnFace(SMESH_Mesh & aMesh,
ymin = p.Y();
if (p.Y() > ymax)
ymax = p.Y();
ymin = p.Y();
if (p.Y() > ymax)
ymax = p.Y();
- // MESSAGE(" "<< f<<" "<<l<<" "<<param<<" "<<xmin<<" "<<xmax<<" "<<ymin<<" "<<ymax);
}
}
}
}
- // SCRUTE(xmin);
- // SCRUTE(xmax);
- // SCRUTE(ymin);
- // SCRUTE(ymax);
double xmoy = (xmax + xmin) / 2.;
double ymoy = (ymax + ymin) / 2.;
double xsize = xmax - xmin;
double xmoy = (xmax + xmin) / 2.;
double ymoy = (ymax + ymin) / 2.;
double xsize = xmax - xmin;
@@
-754,23
+750,14
@@
void StdMeshers_MEFISTO_2D::ComputeScaleOnFace(SMESH_Mesh & aMesh,
}
scalex = length_x / xsize;
scaley = length_y / ysize;
}
scalex = length_x / xsize;
scaley = length_y / ysize;
-// SCRUTE(xsize);
-// SCRUTE(ysize);
double xyratio = xsize*scalex/(ysize*scaley);
const double maxratio = 1.e2;
double xyratio = xsize*scalex/(ysize*scaley);
const double maxratio = 1.e2;
- //SCRUTE(xyratio);
if (xyratio > maxratio) {
if (xyratio > maxratio) {
- SCRUTE( scaley );
scaley *= xyratio / maxratio;
scaley *= xyratio / maxratio;
- SCRUTE( scaley );
}
else if (xyratio < 1./maxratio) {
}
else if (xyratio < 1./maxratio) {
- SCRUTE( scalex );
scalex *= 1 / xyratio / maxratio;
scalex *= 1 / xyratio / maxratio;
- SCRUTE( scalex );
}
}
- ASSERT(scalex);
- ASSERT(scaley);
}
// namespace
}
// namespace