From 6d8aa3f0c809b79215a8d93bb3cccec1d5665102 Mon Sep 17 00:00:00 2001 From: eap Date: Thu, 1 Sep 2011 11:34:43 +0000 Subject: [PATCH] Fix the bug reported at the SALOME forum http://salome-platform.org/forum/forum_10/510395693 map scale distribution of parameter to edge length --- src/StdMeshers/StdMeshers_Regular_1D.cxx | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/StdMeshers/StdMeshers_Regular_1D.cxx b/src/StdMeshers/StdMeshers_Regular_1D.cxx index 24aefeb86..bedf3692c 100644 --- a/src/StdMeshers/StdMeshers_Regular_1D.cxx +++ b/src/StdMeshers/StdMeshers_Regular_1D.cxx @@ -687,6 +687,14 @@ bool StdMeshers_Regular_1D::computeInternalParameters(SMESH_Mesh & theMesh, theParams.push_back( param ); } } + const double lenFactor = theLength/(l-f); + list::iterator u = theParams.begin(), uEnd = theParams.end(); + for ( ; u != uEnd; ++u ) + { + GCPnts_AbscissaPoint Discret( theC3d, (*u) * lenFactor, f ); + if ( Discret.IsDone() ) + *u = Discret.Parameter(); + } return true; } break; -- 2.39.2