1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-14 13:30:48 +03:00

Replacing french comments by english one

This commit is contained in:
bugmaster
2011-04-28 16:28:27 +00:00
committed by bugmaster
parent 94354caf54
commit 81bba7173e
140 changed files with 4625 additions and 4701 deletions

View File

@@ -138,54 +138,52 @@ is
-- Edge/Face and evolutif radius
class SurfRstConstRad;
---Purpose: Copie de CSConstRad mais avec une pcurve sur surface
-- comme support.
---Purpose: Copy of CSConstRad with pcurve on surface
-- as support.
class RstRstEvolRad;
---Purpose: Function to approximate by AppSurface for
-- Edge/Edge and evolutif radius
--
class RstRstConstRad;
---Purpose: Copie de CSConstRad mais avec une pcurve sur surface
-- comme support.
---Purpose: Copy of CSConstRad with a pcurve on surface
-- as support.
class SurfPointConstRadInv;
---Purpose: Fonction de recadrage entre un point et une surface.
---Purpose: Function of reframing between a point and a surface.
class SurfCurvConstRadInv;
---Purpose: Fonction de recadrage entre une restriction surface de
-- la surface et une courbe.
---Purpose: Function of reframing between a restriction surface of the
-- surface and a curve.
class SurfPointEvolRadInv;
---Purpose: Fonction de recadrage entre un point et une surface.
---Purpose: Fonction of reframing between a point and a surface.
class CurvPointRadInv;
---Purpose: Fonction de recadrage entre un point et une courbe.
-- valable dans les cas rsyon constant et rayon evolutif
---Purpose: Function of reframing between a point and a curve.
-- valid in cases of constant and progressive radius
class SurfCurvEvolRadInv;
---Purpose: Fonction de recadrage entre une restriction surface de
-- la surface et une courbe.
---Purpose: Function of reframing between a surface restriction
-- of the surface and a curve.
class SurfRstLineBuilder;
---Purpose: Construction d'une BRepBlend_Line entre une surface et
-- une pcurve sur surface a partir d'une solution de
-- depart approchee. Les entrees sorties de ce builder
-- sont de meme nature que celle d'un walking
-- traditionnel, mais les exigences sur la Line ne sont
-- pas les memes. Si l'on garanti toujours la
-- determination du range de validite, on ne respecte
-- plus les criteres de bonne repartition des sections en
-- vue d'un lissage. En resume la Line resultat est f(t)
-- oriented.
---Purpose: Construction of a BRepBlend_Line between a surface and
-- a pcurve on surface from an approached
-- starting solution. The output entries of this builder
-- are of the same nature as of the traditional walking
-- but the requirements on the Line are not the same
-- If the determination of validity range is always
-- guaranteed, the criteria of correct repartition of sections
-- before smoothing are not respected. The resulting Line
-- is f(t) oriented.
class RstRstLineBuilder;
---Purpose: Construction d'une BRepBlend_Line entre deux pcurves a
-- partir d'une solution de depart approchee. Les
-- entrees sorties de ce builder sont de meme nature que
-- celle d'un walking traditionnel, mais les exigences
-- sur la Line ne sont pas les memes. Si l'on garanti
-- toujours la determination du range de validite, on ne
-- respecte plus les criteres de bonne repartition des
-- sections en vue d'un lissage. En resume la Line
-- resultat est f(t) oriented.
---Purpose: Construction of a BRepBlend_Line between two pcurves
-- from an approached starting solution. The output
-- entries of this builder are of the same nature
-- as of a traditional walking, but the requirements
-- to the Line are not the same. If the determination of validity range is always
-- guaranteed, the criteria of correct repartition of sections
-- before smoothing are not respected. The resulting Line
-- is f(t) oriented.
end BRepBlend;

View File

@@ -42,10 +42,10 @@ BRepBlend_AppFuncRoot::BRepBlend_AppFuncRoot(Handle(BRepBlend_Line)& Line,
if (myTolerance(ii)>Tol2d) { myTolerance(ii) = Tol2d;}
}
// Tableaux
// Tables
Func.GetShape( NbPoles, NbKnots, Degree, NbPoles2d);
// Calcul du BaryCentre (cas rationnel).
// Calculation of BaryCentre (rationnal case).
if (Func.IsRational()) {
Standard_Real Xmax =-1.e100, Xmin = 1.e100,
Ymax =-1.e100, Ymin = 1.e100,
@@ -68,8 +68,8 @@ BRepBlend_AppFuncRoot::BRepBlend_AppFuncRoot(Handle(BRepBlend_Line)& Line,
//================================================================================
// Function: D0
// Purpose : Calcul de la section pour v = Param, si le calcul echoue on rend
// Standard_False.
// Purpose : Calculation of section for v = Param, if calculation fails
// Standard_False is raised.
//================================================================================
Standard_Boolean BRepBlend_AppFuncRoot::D0(const Standard_Real Param,
const Standard_Real First,
@@ -89,8 +89,8 @@ Standard_Boolean BRepBlend_AppFuncRoot::D0(const Standard_Real Param,
//================================================================================
// Function: D1
// Purpose : Calcul de la derive partiel de la section par rapport a v
// pour v = Param, si le calcul echoue on rend Standard_False.
// Purpose : Calculation of the partial derivative of the section corresponding to v
// for v = Param, if the calculation fails Standard_False is raised.
//================================================================================
Standard_Boolean BRepBlend_AppFuncRoot::D1(const Standard_Real Param,
const Standard_Real First,
@@ -119,9 +119,9 @@ Standard_Boolean BRepBlend_AppFuncRoot::D1(const Standard_Real Param,
//===========================================================================
// Function: D2
// Purpose : Calcul de la derive et seconde partiel de la
// section par rapport a v.
// Pour v = Param, si le calcul echoue on rend Standard_False.
// Purpose : Calculation of the derivative and second partial of the
// section corresponding to v.
// For v = Param, if the calculation fails Standard_False is raised.
//===========================================================================
Standard_Boolean BRepBlend_AppFuncRoot::D2(const Standard_Real Param,
const Standard_Real First,
@@ -257,15 +257,15 @@ void BRepBlend_AppFuncRoot::GetMinimalWeight(TColStd_Array1OfReal& Weigths) cons
//
// Function : SearchPoint
//
// Purpose : Recherche du point solution au parametre Param (sur 2 Surfaces)
// Purpose : Find point solution with parameter Param (on 2 Surfaces)
//
// Algorithme :
// 1) On recheche une solution approximative a partir des Points dejas calcules
// 2) On Converge par une methode de type Newton
// Algorithm :
// 1) Approximative solution is found from already calculated Points
// 2) Convergence is done by a method of type Newton
//
// Causes possibles d'echecs :
// - Singularite sur les surfaces.
// - Manquent d'information dans la "line"issue du cheminement.
// Possible causes of fails :
// - Singularity on surfaces.
// - no information oin the "line" resulting from processing.
//
//================================================================================
@@ -275,24 +275,24 @@ Standard_Boolean BRepBlend_AppFuncRoot::SearchPoint(Blend_AppFunction& Func,
{
Standard_Boolean Trouve;
Standard_Integer dim = Func.NbVariables();
// (1) Recherche d'un point d'init
// (1) Find a point of init
Standard_Integer I1=1, I2=myLine->NbPoints(), Index;
Standard_Real t1, t2;
// (1.a) On verifie que c'est a l'interieur
// (1.a) It is checked if it is inside
if (Param < myLine->Point(I1).Parameter()) {return Standard_False;}
if (Param > myLine->Point(I2).Parameter()) {return Standard_False;}
// (1.b) On recheche l'intervalle
// (1.b) Find the interval
Trouve = SearchLocation(Param, I1, I2, Index);
// (1.c) Si le point est dejas calcule on le recupere
// (1.c) If the point is already calculated it is returned
if (Trouve) {
Pnt = myLine->Point(Index);
Vec(XInit,Pnt);
}
else {
// (1.d) Intialisation par interpolation lineaire
// (1.d) Intialisation by linear interpolation
Pnt = myLine->Point(Index);
Vec(X1,Pnt);
t1 = Pnt.Parameter();
@@ -308,7 +308,7 @@ Standard_Boolean BRepBlend_AppFuncRoot::SearchPoint(Blend_AppFunction& Func,
}
}
// (2) Calcul effectif de la solution ------------------------
// (2) Calculation of the solution ------------------------
Func.Set(Param);
Func.GetBounds(X1, X2);
math_FunctionSetRoot rsnld(Func, myTolerance, 30);
@@ -323,13 +323,13 @@ Standard_Boolean BRepBlend_AppFuncRoot::SearchPoint(Blend_AppFunction& Func,
}
rsnld.Root(Sol);
// (3) Stockage du point
// (3) Storage of the point
Point(Func,Param,Sol,Pnt);
// (4) Insertion du point si le cacul semble long.
// (4) Insertion of the point if the calculation seems long.
if ((!Trouve)&&(rsnld.NbIterations()>3)) {
#ifdef DEB
cout << "Evaluation en t = " << Param << "donne" << endl;
cout << "Evaluation in t = " << Param << "given" << endl;
rsnld.Dump(cout);
#endif
myLine->InsertBefore(Index+1, Pnt);
@@ -342,11 +342,11 @@ Standard_Boolean BRepBlend_AppFuncRoot::SearchPoint(Blend_AppFunction& Func,
//
// Function : SearchLocation
//
// Purpose : Recherche dichotomiqique du rang de l'intervalle parametrique contenant
// Param dans la liste de points calcule (myline)
// si le point de parametre Param est deja stocker dans la liste on rend
// True et ParamIndex correspond au rang du Point.
// La complexite de cet algorithme est de log(n)/log(2)
// Purpose : Binary search of the line of the parametric interval containing
// Param in the list of calculated points (myline)
// if the point of parameter Param is already stored in the list
// True is raised and ParamIndex corresponds to line of Point.
// Complexity of this algorithm is log(n)/log(2)
//================================================================================
Standard_Boolean BRepBlend_AppFuncRoot::SearchLocation(const Standard_Real Param,
const Standard_Integer FirstIndex,

View File

@@ -220,7 +220,7 @@ Standard_Boolean BRepBlend_RstRstConstRad::IsSolution(const math_Vector& Sol,
if (Abs(valsol(1)) <= Tol &&
Abs(valsol(2)) <= Tol ) {
// Calcul des tangentes
// Calculation of tangents
prmrst1 = Sol(1);
pt2drst1 = rst1->Value(prmrst1);
prmrst2 = Sol(2);
@@ -286,7 +286,7 @@ Standard_Boolean BRepBlend_RstRstConstRad::IsSolution(const math_Vector& Sol,
Sina = nplan.Dot(n1.Crossed(n2));
if (choix%2 != 0) {
Sina = -Sina; //nplan est change en -nplan
Sina = -Sina; //nplan is changed into -nplan
}
Angle = ACos(Cosa);
@@ -446,11 +446,11 @@ Blend_DecrochStatus BRepBlend_RstRstConstRad::Decroch(const math_Vector& Sol,
rstref1->Value(Sol(1)).Coord(u, v);
surfref1->D1(u, v,PtTmp1,d1u,d1v);
// Normale a la surface de reference 1
// Normal to the reference surface 1
NRst1 = d1u.Crossed(d1v);
rstref2->Value(Sol(2)).Coord(u, v);
surfref2->D1(u, v, PtTmp2, d1u, d1v);
// Normale a la surface de reference 2
// Normal to the reference surface 2
NRst2 = d1u.Crossed(d1v);
Standard_Boolean IsCenter;
@@ -483,7 +483,7 @@ Blend_DecrochStatus BRepBlend_RstRstConstRad::Decroch(const math_Vector& Sol,
TgRst2.Reverse();
}
// On retourne les vecteurs
// The vectors are returned
if (NRst1InPlane.Dot(TgRst1) > -1.e-10) {
if (NRst2InPlane.Dot(TgRst2) < 1.e-10) {
return Blend_DecrochBoth;
@@ -530,7 +530,7 @@ void BRepBlend_RstRstConstRad::Set(const BlendFunc_SectionShape TypeSection)
//=======================================================================
//function : CenterCircleRst1Rst2
//purpose : Calculer le centre du cercle passant par les deux points des restrictions
//purpose : Calculate the center of the circle passing by two points of restrictions
//=======================================================================
Standard_Boolean BRepBlend_RstRstConstRad::CenterCircleRst1Rst2(const gp_Pnt& PtRst1,
const gp_Pnt& PtRst2,
@@ -540,11 +540,11 @@ Standard_Boolean BRepBlend_RstRstConstRad::CenterCircleRst1Rst2(const gp_Pnt&
{
gp_Vec rst1rst2(PtRst1, PtRst2);
gp_Vec vdmedNor; //,NRst1; vdmedNor vecteur directeur de la Mediatrice
gp_Vec vdmedNor; //,NRst1; vdmedNor directong vector of the perpendicular bisector
Standard_Real norm2;
Standard_Real Dist;// distance entre le milieu de PtRst1,PtRst2 et Center
Standard_Real Dist;// distance between the middle of PtRst1,PtRst2 and Center
// Calcul du centre du cercle
// Calculate the center of the circle
VdMed = rst1rst2.Crossed(np);
norm2 = rst1rst2.SquareMagnitude();
Dist = ray * ray - 0.25 * norm2;
@@ -609,7 +609,7 @@ void BRepBlend_RstRstConstRad::Section(const Standard_Real Param,
Pdeb = 0; //ElCLib::Parameter(C, pts);
Pfin = ElCLib::Parameter(C, ptrst2);
// Test des angles negatif et quasi null : Cas Singulier
// Test of angles negative and almost null : Special Case
if (Pfin > 1.5 * PI) {
np.Reverse();
C.SetPosition(gp_Ax2(Center, np, ns));
@@ -646,7 +646,7 @@ Standard_Real BRepBlend_RstRstConstRad::GetSectionSize() const
void BRepBlend_RstRstConstRad::GetMinimalWeight(TColStd_Array1OfReal& Weights) const
{
BlendFunc::GetMinimalWeights(mySShape, myTConv, minang, maxang, Weights );
// On suppose que cela ne depend pas du Rayon!
// It is supposed that it does not depend on the Radius!
}
//=======================================================================
@@ -686,7 +686,7 @@ void BRepBlend_RstRstConstRad::GetShape (Standard_Integer& NbPoles,
//=======================================================================
//function : GetTolerance
//purpose : Determine les Tolerance a utiliser dans les approximations.
//purpose : Determine Tolerances to be used in approximations.
//=======================================================================
void BRepBlend_RstRstConstRad::GetTolerance(const Standard_Real BoundTol,
@@ -759,7 +759,7 @@ void BRepBlend_RstRstConstRad::Section(const Blend_Point& P,
Poles2d(Poles2d.Lower()).SetCoord(pt2d1.X(),pt2d1.Y());
Poles2d(Poles2d.Upper()).SetCoord(pt2d2.X(),pt2d2.Y());
// Cas Linear
// Linear case
if (mySShape == BlendFunc_Linear) {
Poles(low) = ptrst1;
Poles(upp) = ptrst2;
@@ -768,11 +768,11 @@ void BRepBlend_RstRstConstRad::Section(const Blend_Point& P,
return;
}
// Calcul du centre du cercle
// Calculate the center of the circle
Standard_Boolean IsCenter;
IsCenter = CenterCircleRst1Rst2(ptrst1, ptrst2, nplan, Center, NotUsed);
// normales a la section aux points
// normals to the section with points
ns = gp_Vec(Center, ptrst1).Normalized();
ns2 = gp_Vec(Center, ptrst2).Normalized();
@@ -873,8 +873,8 @@ Standard_Boolean BRepBlend_RstRstConstRad::Section(const Blend_Point& P,
n2.Normalize();
if (!istgt) {
// secmember contient les derivees des parametres sur les courbes
// par rapport a t
// secmember contains derivatives of parameters on curves
// compared to t
tgrst1 = secmember(1) * d11;
tgrst2 = secmember(2) * d21;
@@ -887,7 +887,7 @@ Standard_Boolean BRepBlend_RstRstConstRad::Section(const Blend_Point& P,
if (Dist > 1.E-07) {
gp_Vec d1P1P2CrosNp, dmed;
d1P1P2CrosNp = d1rst1rst2.Crossed(nplan) + rst1rst2.Crossed(dnplan);
// derivee de la mediatrice
// derivative of the perpendicular bisector
dmed = d1P1P2CrosNp - med.Dot(d1P1P2CrosNp) * med;
dmed /= normmed;
Dist = sqrt(Dist);
@@ -897,26 +897,26 @@ Standard_Boolean BRepBlend_RstRstConstRad::Section(const Blend_Point& P,
dmed.Reverse();
}
// on met dans dmed la derivee du coefficient Dist
// the derivative of coefficient Dist is located in dmed
dmed.SetLinearForm(Dist, dmed, d1Dist, med);
d1rst1rst2 *= 0.5;
// derivee de la Normale a la courbe en P1
// derivative of the Normal to the curve in P1
d1n1 = - (dmed + d1rst1rst2) / ray;
// derivee de la Normale a la courbe en P2
// derivative of the Normal to the curve in P2
d1n2 = (d1rst1rst2 - dmed) / ray;
}
else {
d1rst1rst2 *= 0.5;
// Normale a la courbe en P1
// Normal to the curve in P1
d1n1 = - d1rst1rst2 / ray;
// Normale a la courbe en P2
// Normal to the curve in P2
d1n2 = d1rst1rst2 / ray;
}
}
// Les poles 2d
// Tops 2d
Poles2d(Poles2d.Lower()).SetCoord(pt2drst1.X(), pt2drst1.Y());
Poles2d(Poles2d.Upper()).SetCoord(pt2drst2.X(), pt2drst2.Y());
@@ -931,7 +931,7 @@ Standard_Boolean BRepBlend_RstRstConstRad::Section(const Blend_Point& P,
DPoles2d(Poles2d.Upper()).SetCoord(a, b);
}
// Cas Linear
// Linear case
if (mySShape == BlendFunc_Linear) {
Poles(low) = ptrst1;
Poles(upp) = ptrst2;
@@ -946,8 +946,8 @@ Standard_Boolean BRepBlend_RstRstConstRad::Section(const Blend_Point& P,
return (!istgt);
}
// Cas du cercle
// tangente au centre du cercle
// Case of the circle
// tangent to the center of the circle
if (!istgt) {
tgct.SetLinearForm(-ray, d1n1, tgrst1);
}

View File

@@ -43,39 +43,39 @@ static void FusionneIntervalles(const TColStd_Array1OfReal& I1,
{
Standard_Integer ind1=1, ind2=1;
Standard_Real Epspar = Precision::PConfusion()*0.99;
// en suposant que le positionement fonctionne a PConfusion()/2
// supposed that the positioning works with PConfusion()/2
Standard_Real v1, v2;
// Initialisations : les IND1 et IND2 pointent sur le 1er element
// de chacune des 2 tables a traiter.INDS pointe sur le dernier
// element cree de TABSOR
// Initialisations : IND1 and IND2 point the 1st element
// of each of 2 tables to be processed. INDS points at the last
// created element of TABSOR
//--- On remplit TABSOR en parcourant TABLE1 et TABLE2 simultanement ---
//------------------ en eliminant les occurrences multiples ------------
//--- TABSOR is filled by parsing TABLE1 and TABLE2 simultaneously ---
//------------------ and removing multiple occurrencies ------------
while ((ind1<=I1.Upper()) && (ind2<=I2.Upper())) {
v1 = I1(ind1);
v2 = I2(ind2);
if (Abs(v1-v2)<= Epspar) {
// Ici les elements de I1 et I2 conviennent .
// elements of I1 and I2 fit here
Seq.Append((v1+v2)/2);
ind1++;
ind2++;
}
else if (v1 < v2) {
// Ici l' element de I1 convient.
// element of I1 fits here.
Seq.Append(v1);
ind1++;
}
else {
// Ici l' element de TABLE2 convient.
// element of TABLE2 fits here.
Seq.Append(v2);
ind2++;
}
}
if (ind1>I1.Upper()) {
//----- Ici I1 est epuise, on complete avec la fin de TABLE2 -------
//----- Here I1 is exhausted, completed using the end of TABLE2 -------
for (; ind2<=I2.Upper(); ind2++) {
Seq.Append(I2(ind2));
@@ -83,7 +83,7 @@ static void FusionneIntervalles(const TColStd_Array1OfReal& I1,
}
if (ind2>I2.Upper()) {
//----- Ici I2 est epuise, on complete avec la fin de I1 -------
//----- Here I2 is exhausted, completed using the end of I1 -------
for (; ind1<=I1.Upper(); ind1++) {
Seq.Append(I1(ind1));
@@ -291,7 +291,7 @@ Standard_Boolean BRepBlend_RstRstEvolRad::IsSolution(const math_Vector& Sol,
if (Abs(valsol(1)) <= Tol &&
Abs(valsol(2)) <= Tol ) {
// Calcul des tangentes
// Calculation of tangents
prmrst1 = Sol(1);
pt2drst1 = rst1->Value(prmrst1);
prmrst2 = Sol(2);
@@ -517,11 +517,11 @@ Blend_DecrochStatus BRepBlend_RstRstEvolRad::Decroch(const math_Vector& Sol,
rstref1->Value(Sol(1)).Coord(u, v);
surfref1->D1(u, v,PtTmp1,d1u,d1v);
// Normale a la surface de reference 1
// Normal to the reference surface 1
NRst1 = d1u.Crossed(d1v);
rstref2->Value(Sol(2)).Coord(u, v);
surfref2->D1(u, v, PtTmp2, d1u, d1v);
// Normale a la surface de reference 2
// Normal to the reference surface 2
NRst2 = d1u.Crossed(d1v);
Standard_Boolean IsCenter;
@@ -554,7 +554,7 @@ Blend_DecrochStatus BRepBlend_RstRstEvolRad::Decroch(const math_Vector& Sol,
TgRst2.Reverse();
}
// On retourne les vecteurs
// Vectors are returned
if (NRst1InPlane.Dot(TgRst1) > -1.e-10) {
if (NRst2InPlane.Dot(TgRst2) < 1.e-10) {
return Blend_DecrochBoth;
@@ -598,7 +598,7 @@ void BRepBlend_RstRstEvolRad::Set(const BlendFunc_SectionShape TypeSection)
//=======================================================================
//function : CenterCircleRst1Rst2
//purpose : Calculer le centre du cercle passant par les deux points des restrictions
//purpose : Calculate the center of circle passing by two points of restrictions
//=======================================================================
Standard_Boolean BRepBlend_RstRstEvolRad::CenterCircleRst1Rst2(const gp_Pnt& PtRst1,
const gp_Pnt& PtRst2,
@@ -608,11 +608,11 @@ Standard_Boolean BRepBlend_RstRstEvolRad::CenterCircleRst1Rst2(const gp_Pnt&
{
gp_Vec rst1rst2(PtRst1, PtRst2);
gp_Vec vdmedNor; //,NRst1; vdmedNor vecteur directeur de la Mediatrice
gp_Vec vdmedNor; //,NRst1; vdmedNor vector director of the perpendicular bisector
Standard_Real norm2;
Standard_Real Dist;// distance entre le milieu de PtRst1,PtRst2 et Center
Standard_Real Dist;// distance between the middle of PtRst1,PtRst2 and Center
// Calcul du centre du cercle
// Calculate the center of the circle
VdMed = rst1rst2.Crossed(np);
norm2 = rst1rst2.SquareMagnitude();
Dist = ray * ray - 0.25 * norm2;
@@ -678,7 +678,7 @@ void BRepBlend_RstRstEvolRad::Section(const Standard_Real Param,
Pdeb = 0; //ElCLib::Parameter(C, pts);
Pfin = ElCLib::Parameter(C, ptrst2);
// Test des angles negatif et quasi null : Cas Singulier
// Test negative and quasi null angles: Special case
if (Pfin > 1.5 * PI) {
np.Reverse();
C.SetPosition(gp_Ax2(Center, np, ns));
@@ -715,7 +715,7 @@ Standard_Real BRepBlend_RstRstEvolRad::GetSectionSize() const
void BRepBlend_RstRstEvolRad::GetMinimalWeight(TColStd_Array1OfReal& Weights) const
{
BlendFunc::GetMinimalWeights(mySShape, myTConv, minang, maxang, Weights );
// On suppose que cela ne depend pas du Rayon!
// It is supposed that it does not depend on the Radius!
}
//=======================================================================
@@ -788,7 +788,7 @@ void BRepBlend_RstRstEvolRad::GetShape (Standard_Integer& NbPoles,
//=======================================================================
//function : GetTolerance
//purpose : Determine les Tolerance a utiliser dans les approximations.
//purpose : Determine the Tolerance to be used in approximations.
//=======================================================================
void BRepBlend_RstRstEvolRad::GetTolerance(const Standard_Real BoundTol,
@@ -862,7 +862,7 @@ void BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
Poles2d(Poles2d.Lower()).SetCoord(pt2d1.X(),pt2d1.Y());
Poles2d(Poles2d.Upper()).SetCoord(pt2d2.X(),pt2d2.Y());
// Cas Linear
// Linear Case
if (mySShape == BlendFunc_Linear) {
Poles(low) = ptrst1;
Poles(upp) = ptrst2;
@@ -871,11 +871,11 @@ void BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
return;
}
// Calcul du centre du cercle
// Calculate the center of the circle
Standard_Boolean IsCenter;
IsCenter = CenterCircleRst1Rst2(ptrst1, ptrst2, nplan, Center, NotUsed);
// normales a la section aux points
// normals to the section with points
n1 = gp_Vec(Center, ptrst1).Normalized();
n2 = gp_Vec(Center, ptrst2).Normalized();
@@ -975,8 +975,8 @@ Standard_Boolean BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
gp_Vec n1(Center, ptrst1), n2(Center, ptrst2);
if (!istgt) {
// secmember contient les derivees des parametres sur les courbes
// par rapport a t
// secmember contains derivatives of parameters on curves
// corresponding to t
tgrst1 = secmember(1) * d11;
tgrst2 = secmember(2) * d21;
@@ -990,7 +990,7 @@ Standard_Boolean BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
if (Dist > 1.E-07) {
gp_Vec d1P1P2CrosNp, dmed;
d1P1P2CrosNp = d1rst1rst2.Crossed(nplan) + rst1rst2.Crossed(dnplan);
// derivee de la mediatrice
// derivative of the bisector
dmed = d1P1P2CrosNp - med.Dot(d1P1P2CrosNp) * med;
dmed /= normmed;
Dist = sqrt(Dist);
@@ -1002,13 +1002,13 @@ Standard_Boolean BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
dmed.Reverse();
}
// on met dans dmed la derivee du coefficient Dist
// derivative of the coefficient Dist is located in dmed
dmed.SetLinearForm(Dist, dmed, d1Dist, med);
d1rst1rst2 *= 0.5;
// derivee de la Normale a la courbe en P1
// derivative of the Normal to the curve in P1
d1n1 = - (d1rst1rst2 + dmed + Invdray * n1) / ray;
// derivee de la Normale a la courbe en P2
// derivative of the Normal to the curve in P2
d1n2 = (d1rst1rst2 - dmed - Invdray * n2) / ray;
}
else {
@@ -1024,7 +1024,7 @@ Standard_Boolean BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
n1.Normalize();
n2.Normalize();
// Les poles 2d
// Tops 2D
Poles2d(Poles2d.Lower()).SetCoord(pt2drst1.X(), pt2drst1.Y());
Poles2d(Poles2d.Upper()).SetCoord(pt2drst2.X(), pt2drst2.Y());
@@ -1039,7 +1039,7 @@ Standard_Boolean BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
DPoles2d(Poles2d.Upper()).SetCoord(a, b);
}
// Cas Linear
// Linear Case
if (mySShape == BlendFunc_Linear) {
Poles(low) = ptrst1;
Poles(upp) = ptrst2;
@@ -1054,8 +1054,8 @@ Standard_Boolean BRepBlend_RstRstEvolRad::Section(const Blend_Point& P,
return (!istgt);
}
// Cas du cercle
// tangente au centre du cercle
// Case of the circle
// tangent to the center of the circle
if (!istgt) {
tgct.SetLinearForm(-ray, d1n1, -dray, n1, tgrst1);
}

View File

@@ -31,7 +31,7 @@ static Standard_Integer IndexOfSection = 0;
extern Standard_Boolean Blend_GettraceDRAWSECT();
//-----------------------------------------------------
// Pour debug : visualisation de la section
// For debug : visualisation of the section
static Standard_Boolean BBPP(const Standard_Real param,
Blend_RstRstFunction& Func,
const math_Vector& sol,
@@ -80,27 +80,27 @@ static void tracederiv(Blend_RstRstFunction& Func,
Standard_Real scal = 1./ (param1 - param2);
cout<<endl;
cout<<"controle des derivees au point : "<<param1<<endl;
cout<<"control of derivatives at point : "<<param1<<endl;
for(i = 1; i <= hp; i++){
cout<<endl;
cout<<"point : "<<i<<endl;
cout<<"dx calcule : "<<TDP1(i).X()<<endl;
cout<<"dx estime : "<<scal*(TP1(i).X()-TP2(i).X())<<endl;
cout<<"dy calcule : "<<TDP1(i).Y()<<endl;
cout<<"dy estime : "<<scal*(TP1(i).Y()-TP2(i).Y())<<endl;
cout<<"dz calcule : "<<TDP1(i).Z()<<endl;
cout<<"dz estime : "<<scal*(TP1(i).Z()-TP2(i).Z())<<endl;
cout<<"dw calcule : "<<TDW1(i)<<endl;
cout<<"dw estime : "<<scal*(TW1(i)-TW2(i))<<endl;
cout<<"dx calculated : "<<TDP1(i).X()<<endl;
cout<<"dx estimated : "<<scal*(TP1(i).X()-TP2(i).X())<<endl;
cout<<"dy calculated : "<<TDP1(i).Y()<<endl;
cout<<"dy estimated : "<<scal*(TP1(i).Y()-TP2(i).Y())<<endl;
cout<<"dz calculated : "<<TDP1(i).Z()<<endl;
cout<<"dz estimated : "<<scal*(TP1(i).Z()-TP2(i).Z())<<endl;
cout<<"dw calculated : "<<TDW1(i)<<endl;
cout<<"dw estimated : "<<scal*(TW1(i)-TW2(i))<<endl;
}
for(i = 1; i <= hp2d; i++){
cout<<endl;
cout<<"point 2d : "<<i<<endl;
cout<<"dx calcule : "<<TDP2d1(i).X()<<endl;
cout<<"dx estime : "<<scal*(TP2d1(i).X()-TP2d2(i).X())<<endl;
cout<<"dy calcule : "<<TDP2d1(i).Y()<<endl;
cout<<"dy estime : "<<scal*(TP2d1(i).Y()-TP2d2(i).Y())<<endl;
cout<<"dx calculated : "<<TDP2d1(i).X()<<endl;
cout<<"dx estimated : "<<scal*(TP2d1(i).X()-TP2d2(i).X())<<endl;
cout<<"dy calculated : "<<TDP2d1(i).Y()<<endl;
cout<<"dy estimated : "<<scal*(TP2d1(i).Y()-TP2d2(i).Y())<<endl;
}
}
@@ -159,7 +159,7 @@ BRepBlend_RstRstLineBuilder::BRepBlend_RstRstLineBuilder
//=======================================================================
//function : Perform
//purpose : lance le processus de cheminement
//purpose : launch the processing
//=======================================================================
void BRepBlend_RstRstLineBuilder::Perform(Blend_RstRstFunction& Func,
@@ -229,7 +229,7 @@ void BRepBlend_RstRstLineBuilder::Perform(Blend_RstRstFunction& Func,
Drawsect(param, Func);
}
#endif
// Mettre a jour la ligne.
// Update the line.
line->Append(previousP);
Standard_Real U, V;
U = previousP.ParameterOnC1();
@@ -256,7 +256,7 @@ void BRepBlend_RstRstLineBuilder::Perform(Blend_RstRstFunction& Func,
//=======================================================================
//function : PerformFirstSection
//purpose : Creation de la premiere section
//purpose : Creation of the first section
//=======================================================================
Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
@@ -340,9 +340,9 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
if (!recadrst1 && !recadp1 && !recadrst2 && !recadp2) return Standard_False;
// on regarde si on a decroche ou sorti du domaine 1
// it is checked if the contact was lost or domain 1 was left
if (recadp1 && recadrst1) {
if (sens * (wrst1 - wp1) > tolgui){ //on sort du domaine d abord
if (sens * (wrst1 - wp1) > tolgui){ //at first one leaves the domain
wrst1 = wp1;
trst12 = solinvp1(2);
trst11 = BRepBlend_BlendTool::Parameter(Vtxp1, rst1);
@@ -350,7 +350,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
Vtxrst2 = Vtxp1;
recadrst1 = Standard_False;
}
else { // on a decroche
else { // the contact is lost
trst11 = solinvrst1(3);
trst12 = solinvrst1(2);
recadp1 = Standard_False;
@@ -368,9 +368,9 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
trst12 = solinvrst1(2);
}
// on regarde si on a decrocher ou sortie du domaine 2
// it is checked if the contact was lost or domain 2 was left
if (recadp2 && recadrst2) {
if (sens * (wrst2 - wp2) > tolgui) { //on sort du domaine d abord
if (sens * (wrst2 - wp2) > tolgui) { //at first one leaves the domain
wrst2 = wp2;
trst21 = solinvp2(2);
trst22 = BRepBlend_BlendTool::Parameter(Vtxp2, rst2);
@@ -396,7 +396,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
trst21 = solinvrst2(2);
}
// on regarde sur laquelle des courbes on decroche en premier
// it is checked on which curve the contact is lost earlier
if (recadrst1 && recadrst2) {
if (Abs(wrst1 - wrst2) < tolgui) {
State = Blend_OnRst12;
@@ -405,14 +405,14 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
sol(2) = trst22;
}
else if (sens * (wrst1 - wrst2) < 0) {
// on decroche sur Rst1
// contact lost on Rst1
State = Blend_OnRst1;
param = wrst1;
sol(1) = trst11;
sol(2) = trst12;
}
else {
// on decroche sur rst2
// contact lost on rst2
State = Blend_OnRst2;
param = wrst2;
sol(1) = trst21;
@@ -421,7 +421,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
Func.Set(param);
}
else if (recadrst1) {
// sol sur rst1
// ground on rst1
State = Blend_OnRst1;
param = wrst1;
sol(1) = trst11;
@@ -429,14 +429,14 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
Func.Set(param);
}
else if (recadrst2) {
// sol sur rst2
// ground on rst2
State = Blend_OnRst2;
param = wrst2;
sol(1) = trst21;
sol(2) = trst22;
Func.Set(param);
}
// on regarde sur laquelle des courbes on sort en premier
// it is checked on which curves one leaves first
else if (recadp1 && recadp2) {
if (Abs(wrst1 - wrst2) < tolgui) {
State = Blend_OnRst12;
@@ -445,14 +445,14 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
sol(2) = trst22;
}
else if (sens * (wrst1 - wrst2) < 0) {
// sol sur Rst1
// sol on Rst1
State = Blend_OnRst1;
param = wrst1;
sol(1) = trst11;
sol(2) = trst12;
}
else {
// sol sur rst2
// ground on rst2
State = Blend_OnRst2;
param = wrst2;
sol(1) = trst21;
@@ -461,7 +461,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
Func.Set(param);
}
else if (recadp1) {
// sol sur rst1
// ground on rst1
State = Blend_OnRst1;
param = wrst1;
sol(1) = trst11;
@@ -469,7 +469,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::PerformFirstSection
Func.Set(param);
}
else if (recadp2) {
// sol sur rst2
// ground on rst2
State = Blend_OnRst2;
param = wrst2;
sol(1) = trst21;
@@ -515,7 +515,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Complete(Blend_RstRstFunction& F
//=======================================================================
//function : InternalPerform
//purpose : algorithme de cheminement sauf aux extremites
//purpose : algorithm of processing without extremities
//=======================================================================
void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
@@ -527,7 +527,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
{
Standard_Real stepw = pasmax;
Standard_Integer nbp = line->NbPoints();
if(nbp >= 2){ //On reprend le dernier step s il n est pas trop petit.
if(nbp >= 2){ //The last step is redone if it is not too small.
if(sens < 0.){
stepw = (line->Point(2).Parameter() - line->Point(1).Parameter());
}
@@ -616,7 +616,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
recadp1 = recadp2 = recadrst1 = recadrst2 = Standard_False;
echecrecad = Standard_False;
if (situonc1 != TopAbs_IN) {
// pb inverse rst/rst
// pb inversion rst/rst
recadp1 = Recadre1(FinvP1, solinvp1, IsVtxp1, Vtxp1);
if (recadp1) {
wp1 = solinvp1(1);
@@ -627,7 +627,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
}
if (situonc2 != TopAbs_IN) {
// pb inverse point/surf
// pb inversion point/surf
recadp2 = Recadre2(FinvP2, solinvp2, IsVtxp2, Vtxp2);
if (recadp2) {
wp2 = solinvp2(1);
@@ -638,7 +638,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
}
if (decroch == Blend_DecrochRst1 || decroch == Blend_DecrochBoth) {
// pb inverse rst1/surf1
// pb inversion rst1/surf1
recadrst1 = Recadre1(Func, Finv1, solinvrst1, IsVtxrst1, Vtxrst1);
if (recadrst1) {
wrst1 = solinvrst1(1);
@@ -663,9 +663,9 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
if (recadp1 || recadp2 || recadrst1 || recadrst2) echecrecad = Standard_False;
if (!echecrecad) {
// on regarde si on a decroche ou sorti du domaine 1
// it is checked if the contact was lost or domain 1 was left
if (recadp1 && recadrst1) {
if (sens * (wrst1 - wp1) > tolgui){ //on sort du domaine d abord
if (sens * (wrst1 - wp1) > tolgui){ //first one leaves the domain
wrst1 = wp1;
trst12 = solinvp1(2);
trst11 = BRepBlend_BlendTool::Parameter(Vtxp1, rst1);
@@ -673,7 +673,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
Vtxrst2 = Vtxp1;
recadrst1 = Standard_False;
}
else { // on a decroche
else { // contact is lost
trst11 = solinvrst1(3);
trst12 = solinvrst1(2);
recadp1 = Standard_False;
@@ -691,9 +691,9 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
trst12 = solinvrst1(2);
}
// on regarde si on a decrocher ou sortie du domaine 2
// it is checked if the contact was lost or domain 2 was left
if (recadp2 && recadrst2) {
if (sens * (wrst2 - wp2) > tolgui) { //on sort du domaine d abord
if (sens * (wrst2 - wp2) > tolgui) { //first one leaves the domain
wrst2 = wp2;
trst21 = solinvp2(2);
trst22 = BRepBlend_BlendTool::Parameter(Vtxp2, rst2);
@@ -719,7 +719,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
trst21 = solinvrst2(2);
}
// on regarde sur laquelle des courbes on decroche en premier
// it is checked on which curve the contact is lost earlier
if (recadrst1 && recadrst2) {
if (Abs(wrst1 - wrst2) < tolgui) {
State = Blend_OnRst12;
@@ -729,7 +729,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
sol(2) = trst22;
}
else if (sens * (wrst1 - wrst2) < 0) {
// on decroche sur Rst1
// contact is lost on Rst1
State = Blend_OnRst1;
decroch = Blend_DecrochRst1;
param = wrst1;
@@ -737,7 +737,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
sol(2) = trst12;
}
else {
// on decroche sur rst2
// contact is lost on rst2
State = Blend_OnRst2;
decroch = Blend_DecrochRst2;
param = wrst2;
@@ -747,7 +747,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
Func.Set(param);
}
else if (recadrst1) {
// sol sur rst1
// ground on rst1
State = Blend_OnRst1;
decroch = Blend_DecrochRst1;
param = wrst1;
@@ -756,7 +756,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
Func.Set(param);
}
else if (recadrst2) {
// sol sur rst2
// ground on rst2
State = Blend_OnRst2;
decroch = Blend_DecrochRst2;
param = wrst2;
@@ -764,7 +764,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
sol(2) = trst22;
Func.Set(param);
}
// on regarde sur laquelle des courbes on sort en premier
// it is checked on which curve the contact is lost earlier
else if (recadp1 && recadp2) {
if (Abs(wrst1 - wrst2) < tolgui) {
State = Blend_OnRst12;
@@ -773,14 +773,14 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
sol(2) = trst22;
}
else if (sens * (wrst1 - wrst2) < 0) {
// sol sur Rst1
// ground on Rst1
State = Blend_OnRst1;
param = wrst1;
sol(1) = trst11;
sol(2) = trst12;
}
else {
// sol sur rst2
// ground on rst2
State = Blend_OnRst2;
param = wrst2;
sol(1) = trst21;
@@ -789,7 +789,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
Func.Set(param);
}
else if (recadp1) {
// sol sur rst1
// ground on rst1
State = Blend_OnRst1;
param = wrst1;
sol(1) = trst11;
@@ -797,7 +797,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
Func.Set(param);
}
else if (recadp2) {
// sol sur rst2
// ground on rst2
State = Blend_OnRst2;
param = wrst2;
sol(1) = trst21;
@@ -811,8 +811,8 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
State = TestArret(Func, Standard_True, State);
}
else{
// echec recadrage. On sort avec PointsConfondus
cout<<"echec recadrage"<<endl;
// reframing failed. Leave with PointsConfondus
cout<<"reframing failed"<<endl;
State = Blend_SamePoints;
}
}
@@ -825,7 +825,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
Drawsect(param, Func);
}
#endif
// Mettre a jour la ligne.
// Update the line.
if (sens > 0.) {
line->Append(previousP);
}
@@ -841,7 +841,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
previousP.ParameterOnC1(),
previousP.Parameter(), tolesp);
MakeExtremity(Extrst2, Standard_False, rst2, sol(2), IsVtxrst2, Vtxrst2);
// Indiquer que fin sur Bound.
// Show that end is on Bound.
}
else {
param = param + sens * stepw;
@@ -864,12 +864,12 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
previousP.Parameter(), tolesp);
Arrive = Standard_True;
if (line->NbPoints()>=2) {
// Indiquer qu on s arrete en cours de cheminement
cout<<"On n avance plus dans le cheminement"<<endl;
// Show that there is a stop during processing
cout<<"No more advancement in the processing"<<endl;
}
}
else {
param = parprec + sens * stepw; // on ne risque pas de depasser Bound.
param = parprec + sens * stepw; // there is no risk to exceed Bound.
}
}
break;
@@ -881,7 +881,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
Drawsect(param,Func);
}
#endif
// Mettre a jour la ligne.
// Update the line.
if (sens > 0.) {
line->Append(previousP);
}
@@ -898,7 +898,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
previousP.ParameterOnC1(),
previousP.Parameter(), tolesp);
MakeExtremity(Extrst2, Standard_False, rst2, sol(2), IsVtxrst2, Vtxrst2);
// Indiquer que fin sur Bound.
// Indicate that end is on Bound.
}
else {
param = param + sens * stepw;
@@ -970,8 +970,8 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
case Blend_SamePoints :
{
// On arrete
cout << " Points confondus dans le cheminement" << endl;
// Stop
cout << " Mixed points in the processing" << endl;
Extrst1.SetValue(previousP.PointOnC1(),
previousP.ParameterOnC1(),
previousP.Parameter(), tolesp);
@@ -1002,7 +1002,7 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction& Func,
//=======================================================================
//function : Recadre1
//purpose : On a decroche en 1
//purpose : Contact lost on 1
//=======================================================================
Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_RstRstFunction& Func,
@@ -1018,7 +1018,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_RstRstFunction&
Solinv(2) = sol(2);
Solinv(3) = sol(1);
// On recherche le point de non decrochement
// The point where contact is not lost is found
math_FunctionSetRoot rsnld(Finv, toler, 30);
rsnld.Perform(Finv, Solinv, infb, supb);
if (!rsnld.IsDone()) {
@@ -1028,8 +1028,8 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_RstRstFunction&
rsnld.Root(Solinv);
// On doit verifier la valeur de la fonction est bien
// sur la seconde restriction
// It is necessary to check if the function value meets the
// second restriction
if (Finv.IsSolution(Solinv, tolesp)) {
Standard_Real w = Solinv(2);
if(w < rst2->FirstParameter() - toler(2)||
@@ -1037,7 +1037,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_RstRstFunction&
return Standard_False;
}
// on regarde si on n est pas sur un Vertex
// it is checked if it is on a Vertex
domain1->Initialize(rst1);
domain1->InitVertexIterator();
IsVtx = !domain1->MoreVertex();
@@ -1055,8 +1055,8 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_RstRstFunction&
if (!domain1->MoreVertex()) {
IsVtx = Standard_False;
}
// On recalcule la section par resolution directe, sinon, on se recupere
// des incoherences entre le parametre et sol dues au baillement.
// The section is recalculated by direct solution, otherwise return
// incoherences between the parameter and the ground caused by yawn.
math_Vector infbound(1, 2), supbound(1, 2);
math_Vector parinit(1, 2), tolerance(1, 2);
@@ -1083,7 +1083,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_RstRstFunction&
//=======================================================================
//function : Recadre2
//purpose : On a decroche sur Rst2
//purpose : Contact lost on Rst2
//=======================================================================
Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre2(Blend_RstRstFunction& Func,
@@ -1108,7 +1108,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre2(Blend_RstRstFunction&
rsnld.Root(Solinv);
// On doit verifier la valeur de la fonction
// It is necessary to check the value of the function
if (Finv.IsSolution(Solinv, tolesp)) {
Standard_Real w = Solinv(2);
if(w < rst1->FirstParameter() - toler(2)||
@@ -1133,9 +1133,9 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre2(Blend_RstRstFunction&
if (!domain2->MoreVertex()) {
IsVtx = Standard_False;
}
// On recalcule la section par resolution directe, sinon, on se recupere
// des incoherences entre le parametre et sol dues au baillement.
// The section is recalculated by direct solution, otherwise return
// incoherences between the parameter and the ground caused by yawn.
math_Vector infbound(1, 2), supbound(1, 2);
math_Vector parinit(1,2), tolerance(1,2);
Func.GetTolerance(tolerance, tolesp);
@@ -1157,7 +1157,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre2(Blend_RstRstFunction&
//=======================================================================
//function : Recadre
//purpose : On est en fin de la courbe rst1
//purpose : This is the end of curve rst1
//=======================================================================
Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_CurvPointFuncInv& FinvP,
@@ -1165,8 +1165,8 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_CurvPointFuncInv&
Standard_Boolean& IsVtx,
Handle(Adaptor3d_HVertex)& Vtx)
{
// On se place sur le dernier ou le premier point, suivant le
// sens de cheminement.
// One is located on the last or the first point, following the
// direction of processing.
gp_Pnt2d p2drst1;
Standard_Real firstrst1 = rst1->FirstParameter();
Standard_Real lastrst1 = rst1->LastParameter();
@@ -1223,7 +1223,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre1(Blend_CurvPointFuncInv&
//=======================================================================
//function : Recadre2
//purpose : On est en fin de la courbe rst2
//purpose : This is the end of curve rst2
//=======================================================================
Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre2(Blend_CurvPointFuncInv& FinvP,
@@ -1231,8 +1231,8 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::Recadre2(Blend_CurvPointFuncInv&
Standard_Boolean& IsVtx,
Handle(Adaptor3d_HVertex)& Vtx)
{
// On se place sur le dernier ou le premier point, suivant le
// sens de cheminement.
// One is located on the last or the first point, following the
// direction of processing.
gp_Pnt2d p2drst2;
Standard_Real firstrst2 = rst2->FirstParameter();
Standard_Real lastrst2 = rst2->LastParameter();
@@ -1337,7 +1337,7 @@ void BRepBlend_RstRstLineBuilder::Transition(const Standard_Boolean OnF
//=======================================================================
//function : MakeExtremity
//purpose : fabrique l extremite d une courbe
//purpose : produce the extremity of a curve
//=======================================================================
void BRepBlend_RstRstLineBuilder::MakeExtremity(BRepBlend_Extremity& Extrem,
@@ -1408,9 +1408,9 @@ void BRepBlend_RstRstLineBuilder::MakeExtremity(BRepBlend_Extremity&
Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst1(const Blend_Point& CurPoint)
{
//Controles 3d du Blend_CSWalking.
//Controls 3d of Blend_CSWalking.
// regle par tests dans U4 correspond a 11.478 d
// rule by tests in U4 corresponds to 11.478
const Standard_Real CosRef3D = 0.98;
Standard_Real Cosi, Cosi2;
Standard_Boolean curpointistangent = CurPoint.IsTangencyPoint();
@@ -1438,7 +1438,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst1(const Blend_Poin
if (!prevpointistangent) prevNorme = prevTg.SquareMagnitude();
if (Norme <= tolesp * tolesp) {
// il faudra peut etre forcer meme point
// it can be necessary to force the same point
return Blend_SamePoints;
}
if(!prevpointistangent){
@@ -1446,7 +1446,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst1(const Blend_Poin
return Blend_SamePoints;
}
Cosi = sens * Corde * prevTg;
if (Cosi < 0.) { // angle 3d>pi/2. --> retour arriere
if (Cosi < 0.) { // angle 3d>pi/2. --> return back
return Blend_Backward;
}
@@ -1457,7 +1457,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst1(const Blend_Poin
}
if(!curpointistangent){
// Voir s il faut faire le controle sur le signe de prevtg*Tgsurf
// Check if it is necessary to control the sign of prevtg*Tgsurf
Cosi = sens * Corde * Tgsurf;
Cosi2 = Cosi * Cosi / Tgsurf.SquareMagnitude() / Norme;
if (Cosi2 < CosRef3D || Cosi < 0.) {
@@ -1466,7 +1466,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst1(const Blend_Poin
}
if (!curpointistangent && !prevpointistangent) {
// Estimation de la fleche courante
// Estimation of the current arrow
Standard_Real FlecheCourante =
(prevTg.Normalized().XYZ() - Tgsurf.Normalized().XYZ()).SquareModulus() * Norme / 64.;
@@ -1474,7 +1474,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst1(const Blend_Poin
return Blend_StepTooSmall;
}
if (FlecheCourante > fleche * fleche) {
// pas trop grand : commentaire interessant
// not too great
return Blend_StepTooLarge;
}
}
@@ -1489,9 +1489,9 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst1(const Blend_Poin
Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst2(const Blend_Point& CurPoint)
{
//Controles 3d du Blend_CSWalking.
//3D Controls of Blend_CSWalking.
// regle par tests dans U4 correspond a 11.478 d
// rule by tests in U4 corresponding to 11.478 d
const Standard_Real CosRef3D = 0.98;
Standard_Real Cosi, Cosi2;
Standard_Boolean curpointistangent = CurPoint.IsTangencyPoint();
@@ -1520,7 +1520,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst2(const Blend_Poin
if (!prevpointistangent) prevNorme = prevTg.SquareMagnitude();
if (Norme <= tolesp * tolesp){
// il faudra peut etre forcer meme point
// it can be necessary to force the same point
return Blend_SamePoints;
}
if (!prevpointistangent) {
@@ -1528,7 +1528,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst2(const Blend_Poin
return Blend_SamePoints;
}
Cosi = sens * Corde * prevTg;
if (Cosi < 0.) { // angle 3d>pi/2. --> retour arriere
if (Cosi < 0.) { // angle 3d>pi/2. --> return back
return Blend_Backward;
}
@@ -1539,7 +1539,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst2(const Blend_Poin
}
if (!curpointistangent) {
// Voir s il faut faire le controle sur le signe de prevtg*Tgsurf
// Check if it is necessary to control the sign of prevtg*Tgsurf
Cosi = sens * Corde * Tgsurf;
Cosi2 = Cosi * Cosi / Tgsurf.SquareMagnitude() / Norme;
if (Cosi2 < CosRef3D || Cosi < 0.) {
@@ -1548,7 +1548,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst2(const Blend_Poin
}
if(!curpointistangent && !prevpointistangent){
// Estimation de la fleche courante
// Estimation of the current arrow
Standard_Real FlecheCourante =
(prevTg.Normalized().XYZ() - Tgsurf.Normalized().XYZ()).SquareModulus() * Norme/64.;
@@ -1556,7 +1556,7 @@ Blend_Status BRepBlend_RstRstLineBuilder::CheckDeflectionOnRst2(const Blend_Poin
return Blend_StepTooSmall;
}
if (FlecheCourante > fleche * fleche) {
// pas trop grand : commentaire interessant
// not too great
return Blend_StepTooLarge;
}
}
@@ -1700,7 +1700,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::CheckInside(Blend_RstRstFunction&
math_Vector tolerance(1, 2);
Func.GetTolerance(tolerance, tolesp);
//cote pcurve 1.
//face pcurve 1.
Standard_Real v = sol(1);
if(v < rst1->FirstParameter() - tolerance(2)||
v > rst1->LastParameter() + tolerance(2)){
@@ -1712,7 +1712,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::CheckInside(Blend_RstRstFunction&
}
else SituOnC1 = TopAbs_ON;
//cote pcurve 2.
//face pcurve 2.
v = sol(2);
if(v < rst2->FirstParameter() - tolerance(2)||
v > rst2->LastParameter() + tolerance(2)){
@@ -1725,7 +1725,7 @@ Standard_Boolean BRepBlend_RstRstLineBuilder::CheckInside(Blend_RstRstFunction&
else SituOnC2 = TopAbs_ON;
//decrochage
//lost contact
gp_Vec tgrst1, norst1, tgrst2, norst2;
Decroch = Func.Decroch(sol,tgrst1, norst1, tgrst2, norst2);

View File

@@ -132,7 +132,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Derivatives(const math_Vector& X,
vref.Divide(norm);
vref.SetLinearForm(ray,vref,gp_Vec(ptrst,pts));
// Derivee par rapport a u1
// Derivative by u1
temp = d2u1.Crossed(d1v1).Added(d1u1.Crossed(d2uv1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -144,7 +144,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Derivatives(const math_Vector& X,
D(3,1) = D(3,1) * 2.;
// Derivee par rapport a v1
// Derivative by v1
temp = d2uv1.Crossed(d1v1).Added(d1u1.Crossed(d2v1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -201,9 +201,9 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Values(const math_Vector& X,
temp = vref/ray;
// F(3) = vref.SquareMagnitude() - ray*ray;
F(3) = (temp.SquareMagnitude() - 1)*ray*ray; // plus stable numeriquement
F(3) = (temp.SquareMagnitude() - 1)*ray*ray; // more stable numerically
// Derivee par rapport a u1
// Derivative by u1
temp = d2u1.Crossed(d1v1).Added(d1u1.Crossed(d2uv1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -216,7 +216,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Values(const math_Vector& X,
// Derivee par rapport a v1
// Derivative by v1
temp = d2uv1.Crossed(d1v1).Added(d1u1.Crossed(d2v1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -339,7 +339,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::IsSolution(const math_Vector& Sol,
Abs(valsol(2)) <= Tol &&
Abs(valsol(3)) <= 2*Tol*Abs(ray) ) {
// Calcul des tangentes
// Calculation of tangents
pt2ds = gp_Pnt2d(Sol(1),Sol(2));
prmrst = Sol(3);
@@ -395,14 +395,14 @@ Standard_Boolean BRepBlend_SurfRstConstRad::IsSolution(const math_Vector& Sol,
tg2drst.SetCoord(a,b);
}
// mise a jour de maxang
// update of maxang
if(ray>0.) ns.Reverse();
ns2 = -resul.Normalized();
Cosa = ns.Dot(ns2);
Sina = nplan.Dot(ns.Crossed(ns2));
if (choix%2 != 0) {
Sina = -Sina; //nplan est change en -nplan
Sina = -Sina; //nplan is changed to -nplan
}
Angle = ACos(Cosa);
@@ -578,7 +578,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Decroch(const math_Vector& Sol,
Standard_Real dot, NT = NRstInPlane.Magnitude();
NT *= TgRst.Magnitude();
if (Abs(NT) < 1.e-7) {
return Standard_False; // Singularite ou Incoherence.
return Standard_False; // Singularity or Incoherence.
}
dot = NRstInPlane.Dot(TgRst);
dot /= NT;
@@ -663,7 +663,7 @@ void BRepBlend_SurfRstConstRad::Section(const Standard_Real Param,
Pdeb = 0; //ElCLib::Parameter(C,pts);
Pfin = ElCLib::Parameter(C,ptrst);
// Test des angles negatif et quasi null : Cas Singulier
// Test negative and almost null angles : Special case
if (Pfin>1.5*PI) {
np.Reverse();
C.SetPosition(gp_Ax2(Center,np,ns));
@@ -700,7 +700,7 @@ Standard_Real BRepBlend_SurfRstConstRad::GetSectionSize() const
void BRepBlend_SurfRstConstRad::GetMinimalWeight(TColStd_Array1OfReal& Weights) const
{
BlendFunc::GetMinimalWeights(mySShape, myTConv, minang, maxang, Weights );
// On suppose que cela ne depend pas du Rayon!
// It is supposed that it does not depend on the Radius!
}
//=======================================================================
@@ -740,7 +740,7 @@ void BRepBlend_SurfRstConstRad::GetShape (Standard_Integer& NbPoles,
//=======================================================================
//function : GetTolerance
//purpose : Determine les Tolerance a utiliser dans les approximations.
//purpose : Find Tolerance to be used in approximations.
//=======================================================================
void BRepBlend_SurfRstConstRad::GetTolerance(const Standard_Real BoundTol,
@@ -803,7 +803,7 @@ void BRepBlend_SurfRstConstRad::Section(const Blend_Point& P,
nplan = d1gui.Normalized();
P.ParametersOnS(u1,v1);
w = P.ParameterOnC(); //jlr : point sur courbe pas sur surface
w = P.ParameterOnC(); //jlr : point on curve not on surface
gp_Pnt2d pt2d = rst->Value(w);
surf->D1(u1,v1,pts,d1u1,d1v1);
@@ -813,7 +813,7 @@ void BRepBlend_SurfRstConstRad::Section(const Blend_Point& P,
Poles2d(Poles2d.Lower()).SetCoord(u1,v1);
Poles2d(Poles2d.Upper()).SetCoord(pt2d.X(),pt2d.Y());
// Cas Linear
// Linear Case
if (mySShape == BlendFunc_Linear) {
Poles(low) = pts;
Poles(upp) = ptrst;
@@ -903,13 +903,13 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Section
ndotns = nplan.Dot(ns);
norm = ncrossns.Magnitude();
if (norm < Eps) {
norm = 1; // Insufisant, mais il ne faut pas planter
norm = 1; // Not enough, but it is not necessary to stop
#if DEB
cout << " SurfRstConstRad : Surface singuliere " << endl;
cout << " SurfRstConstRad : Singular Surface " << endl;
#endif
}
// Derivee de n1 par rapport a w
// Derivative of n1 corresponding to w
grosterme = ncrossns.Dot(dnplan.Crossed(ns))/norm/norm;
dnw.SetLinearForm((dnplan.Dot(ns)-grosterme*ndotns)/norm,nplan,
@@ -918,8 +918,8 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Section
temp.SetLinearForm(ndotns/norm,nplan, -1./norm,ns);
resul.SetLinearForm(ray,temp,gp_Vec(ptrst,pts));
secmember(3) = dnw.Dot(resul); // jag 950105 il manquait ray
secmember(3) = -2.*ray*secmember(3); // jag 950105 il manquait ray
secmember(3) = dnw.Dot(resul);
secmember(3) = -2.*ray*secmember(3);
math_Gauss Resol(gradsol, 1.e-9);
@@ -943,14 +943,14 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Section
tgs.SetLinearForm(secmember(1),d1u1,secmember(2),d1v1);
tgrst = secmember(3)*d1;
// Derivee de n1 par rapport a u1
// Derivative of n1 corresponding to u1
temp = d2u1.Crossed(d1v1).Added(d1u1.Crossed(d2uv1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resulu.SetLinearForm(-(grosterme*ndotns-nplan.Dot(temp))/norm,nplan,
grosterme/norm,ns,
-1./norm,temp);
// Derivee de n1 par rapport a v1
// Derivative of n1 corresponding to v1
temp = d2uv1.Crossed(d1v1).Added(d1u1.Crossed(d2v1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resulv.SetLinearForm(-(grosterme*ndotns-nplan.Dot(temp))/norm,nplan,
@@ -972,7 +972,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Section
ns2 = -resul.Normalized();
}
// Les poles 2d
// Tops 2D
Poles2d(Poles2d.Lower()).SetCoord(sol(1),sol(2));
Poles2d(Poles2d.Upper()).SetCoord(pt2drst.X(),pt2drst.Y());
@@ -984,7 +984,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Section
DPoles2d(Poles2d.Upper()).SetCoord(a,b);
}
// Cas Linear
// Linear Case
if (mySShape == BlendFunc_Linear) {
Poles(low) = pts;
Poles(upp) = ptrst;
@@ -999,7 +999,7 @@ Standard_Boolean BRepBlend_SurfRstConstRad::Section
return (!istgt);
}
// Cas du cercle
// Case of the circle
Center.SetXYZ(pts.XYZ()+ray*ns.XYZ());
if (!istgt) {
tgct = tgs.Added(ray*dnw);

View File

@@ -41,39 +41,39 @@ static void FusionneIntervalles(const TColStd_Array1OfReal& I1,
{
Standard_Integer ind1=1, ind2=1;
Standard_Real Epspar = Precision::PConfusion()*0.99;
// en suposant que le positionement fonctionne a PConfusion()/2
// it is supposed that positioning works with PConfusion()/2
Standard_Real v1, v2;
// Initialisations : les IND1 et IND2 pointent sur le 1er element
// de chacune des 2 tables a traiter.INDS pointe sur le dernier
// element cree de TABSOR
// Initialisation : IND1 and IND2 point at the first element
// of each of 2 tables to be processed. INDS points at the last
// element created by TABSOR
//--- On remplit TABSOR en parcourant TABLE1 et TABLE2 simultanement ---
//------------------ en eliminant les occurrences multiples ------------
//--- TABSOR is filled by parsing TABLE1 and TABLE2 simultaneously ---
//------------------ and eliminating multiple occurrencies ------------
while ((ind1<=I1.Upper()) && (ind2<=I2.Upper())) {
v1 = I1(ind1);
v2 = I2(ind2);
if (Abs(v1-v2)<= Epspar) {
// Ici les elements de I1 et I2 conviennent .
// Here the elements of I1 and I2 fit.
Seq.Append((v1+v2)/2);
ind1++;
ind2++;
}
else if (v1 < v2) {
// Ici l' element de I1 convient.
// Here the element of I1 fits.
Seq.Append(v1);
ind1++;
}
else {
// Ici l' element de TABLE2 convient.
// Here the element of TABLE2 fits.
Seq.Append(v2);
ind2++;
}
}
if (ind1>I1.Upper()) {
//----- Ici I1 est epuise, on complete avec la fin de TABLE2 -------
//----- Here I1 is exhausted, completed with the end of TABLE2 -------
for (; ind2<=I2.Upper(); ind2++) {
Seq.Append(I2(ind2));
@@ -81,7 +81,7 @@ static void FusionneIntervalles(const TColStd_Array1OfReal& I1,
}
if (ind2>I2.Upper()) {
//----- Ici I2 est epuise, on complete avec la fin de I1 -------
//----- Here I2 is exhausted, completed with the end of I1 -------
for (; ind1<=I1.Upper(); ind1++) {
Seq.Append(I1(ind1));
@@ -91,7 +91,7 @@ static void FusionneIntervalles(const TColStd_Array1OfReal& I1,
//=======================================================================
//function : BRepBlend_SurfRstEvolRad
//purpose : Contructeur
//purpose : Contructor
//=======================================================================
BRepBlend_SurfRstEvolRad::BRepBlend_SurfRstEvolRad
(const Handle(Adaptor3d_HSurface)& Surf,
@@ -188,7 +188,7 @@ Standard_Boolean BRepBlend_SurfRstEvolRad::Derivatives
vref.Divide(norm);
vref.SetLinearForm(ray,vref,gp_Vec(ptrst,pts));
// Derivee par rapport a u1
// Derivative corresponding to u1
temp = d2u1.Crossed(d1v1).Added(d1u1.Crossed(d2uv1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -199,7 +199,7 @@ Standard_Boolean BRepBlend_SurfRstEvolRad::Derivatives
D(3,1) = 2.*(resul.Dot(vref));
// Derivee par rapport a v1
// Derivative corresponding to v1
temp = d2uv1.Crossed(d1v1).Added(d1u1.Crossed(d2v1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -257,7 +257,7 @@ Standard_Boolean BRepBlend_SurfRstEvolRad::Values
F(3) = vref.SquareMagnitude() - ray*ray;
// Derivee par rapport a u1
// Derivative corresponding to u1
temp = d2u1.Crossed(d1v1).Added(d1u1.Crossed(d2uv1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -268,7 +268,7 @@ Standard_Boolean BRepBlend_SurfRstEvolRad::Values
D(3,1) = 2.*(resul.Dot(vref));
// Derivee par rapport a v1
// Derivative corresponding to v1
temp = d2uv1.Crossed(d1v1).Added(d1u1.Crossed(d2v1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resul.SetLinearForm(-ray/norm*(grosterme*ndotns-nplan.Dot(temp)),nplan,
@@ -317,8 +317,8 @@ void BRepBlend_SurfRstEvolRad::Set(const Standard_Real Param)
//=======================================================================
//function :
//purpose : Segmente la courbe a sa partie utile.
// La precision est prise arbitrairement petite !?
//purpose : Segments the curve in its useful part.
// Precision is taken arbitrary small !?
//=======================================================================
void BRepBlend_SurfRstEvolRad::Set
(const Standard_Real First,
@@ -391,7 +391,7 @@ const Standard_Real Tol)
Abs(valsol(2)) <= Tol &&
Abs(valsol(3)) <= 2*Tol*Abs(ray) ) {
// Calcul des tangentes
// Calculation of tangents
pt2ds = gp_Pnt2d(Sol(1),Sol(2));
prmrst = Sol(3);
@@ -451,14 +451,14 @@ const Standard_Real Tol)
else {
istangent = Standard_True;
}
// mise a jour de maxang
// update of maxang
if(ray>0.) ns.Reverse();
ns2 = -resul.Normalized();
Cosa = ns.Dot(ns2);
Sina = nplan.Dot(ns.Crossed(ns2));
if (choix%2 != 0) {
Sina = -Sina; //nplan est change en -nplan
Sina = -Sina; //nplan is changed into -nplan
}
Angle = ACos(Cosa);
@@ -625,7 +625,7 @@ gp_Vec& TgS) const
Standard_Real dot, NT = NRstInPlane.Magnitude();
NT *= TgRst.Magnitude();
if (Abs(NT) < 1.e-7) {
return Standard_False; // Singularite ou Incoherence.
return Standard_False; // Singularity or Incoherence.
}
dot = NRstInPlane.Dot(TgRst);
dot /= NT;
@@ -707,7 +707,7 @@ gp_Circ& C)
Pdeb = 0.; //ElCLib::Parameter(C,pts);
Pfin = ElCLib::Parameter(C,ptrst);
// Test des angles negatif et quasi null : Cas Singulier
// Test negative and almost null angles : Single Case
if (Pfin>1.5*PI) {
np.Reverse();
C.SetPosition(gp_Ax2(Center,np,ns));
@@ -741,7 +741,7 @@ gp_Circ& C)
void BRepBlend_SurfRstEvolRad::GetMinimalWeight(TColStd_Array1OfReal& Weigths) const
{
BlendFunc::GetMinimalWeights(mySShape, myTConv, minang, maxang, Weigths );
// On suppose que cela ne depend pas du Rayon!
// It is supposed that it does not depend on the Radius!
}
//=======================================================================
@@ -914,13 +914,13 @@ TColStd_Array1OfReal& DWeigths)
ndotns = nplan.Dot(ns);
norm = ncrossns.Magnitude();
if (norm < Eps) {
norm = 1; // Insufisant, mais il ne faut pas planter
norm = 1; // Not enough, but it is not necessary to stop
#if DEB
cout << " SurfRstEvolRad : Surface singuliere " << endl;
cout << " SurfRstEvolRad : Surface single " << endl;
#endif
}
// Derivee de n1 par rapport a w
// Derivative of n1 corresponding to w
grosterme = ncrossns.Dot(dnplan.Crossed(ns))/norm/norm;
dnw.SetLinearForm((dnplan.Dot(ns)-grosterme*ndotns)/norm,nplan,
@@ -953,14 +953,14 @@ TColStd_Array1OfReal& DWeigths)
tgs.SetLinearForm(secmember(1),d1u1,secmember(2),d1v1);
tgrst = secmember(3)*d1;
// Derivee de n1 par rapport a u1
// Derivative of n1 corresponding to u1
temp = d2u1.Crossed(d1v1).Added(d1u1.Crossed(d2uv1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resulu.SetLinearForm(-(grosterme*ndotns-nplan.Dot(temp))/norm,nplan,
grosterme/norm,ns,
-1./norm,temp);
// Derivee de n1 par rapport a v1
// Derivative of n1 corresponding to v1
temp = d2uv1.Crossed(d1v1).Added(d1u1.Crossed(d2v1));
grosterme = ncrossns.Dot(nplan.Crossed(temp))/norm/norm;
resulv.SetLinearForm(-(grosterme*ndotns-nplan.Dot(temp))/norm,nplan,
@@ -986,7 +986,7 @@ TColStd_Array1OfReal& DWeigths)
istgt = Standard_True;
}
// Les poles 2d
// Tops 2D
Poles2d(Poles2d.Lower()).SetCoord(sol(1),sol(2));
Poles2d(Poles2d.Upper()).SetCoord(pt2drst.X(),pt2drst.Y());
@@ -998,7 +998,7 @@ TColStd_Array1OfReal& DWeigths)
DPoles2d(Poles2d.Upper()).SetCoord(a,b);
}
// Cas Linear
// Linear Case
if (mySShape == BlendFunc_Linear) {
Poles(low) = pts;
Poles(upp) = ptrst;
@@ -1013,7 +1013,7 @@ TColStd_Array1OfReal& DWeigths)
return (!istgt);
}
// Cas du cercle
// Case of the circle
Center.SetXYZ(pts.XYZ()+ray*ns.XYZ());
if (!istgt) {
tgct.SetLinearForm(ray,dnw,dray,ns,tgs);
@@ -1030,7 +1030,7 @@ TColStd_Array1OfReal& DWeigths)
dnplan.Reverse();
}
if (!istgt) {
if (ray < 0.) { // pour eviter la connerie Abs(dray) qques lignes plus bas
if (ray < 0.) { // to avoid Abs(dray) some lines below
rayprim = -dray;
}
else rayprim = dray;
@@ -1103,7 +1103,7 @@ TColStd_Array1OfReal& Weigths)
nplan = d1gui.Normalized();
P.ParametersOnS(u1,v1);
w = P.ParameterOnC(); //jlr : point sur courbe pas sur surface
w = P.ParameterOnC(); //jlr : point on curve not on surface
gp_Pnt2d pt2d = rst->Value(w);
surf->D1(u1,v1,pts,d1u1,d1v1);
@@ -1114,7 +1114,7 @@ TColStd_Array1OfReal& Weigths)
Poles2d(Poles2d.Lower()).SetCoord(u1,v1);
Poles2d(Poles2d.Upper()).SetCoord(pt2d.X(),pt2d.Y());
// Cas Linear
// Linear case
if (mySShape == BlendFunc_Linear) {
Poles(low) = pts;
Poles(upp) = ptrst;

View File

@@ -29,7 +29,7 @@
#endif
static Standard_Integer IndexOfSection = 0;
extern Standard_Boolean Blend_GettraceDRAWSECT();
// Pour debug : visualisation de la section
// for debug : visualisation of the section
static Standard_Boolean BBPP(const Standard_Real param,
Blend_SurfRstFunction& Func,
const math_Vector& sol,
@@ -74,27 +74,27 @@ static void tracederiv(Blend_SurfRstFunction& Func,
Standard_Real scal = 1./(param1-param2);
cout<<endl;
cout<<"controle des derivees au point : "<<param1<<endl;
cout<<"control derivatives at point : "<<param1<<endl;
for(i = 1; i <= hp; i++){
cout<<endl;
cout<<"point : "<<i<<endl;
cout<<"dx calcule : "<<TDP1(i).X()<<endl;
cout<<"dx estime : "<<scal*(TP1(i).X()-TP2(i).X())<<endl;
cout<<"dy calcule : "<<TDP1(i).Y()<<endl;
cout<<"dy estime : "<<scal*(TP1(i).Y()-TP2(i).Y())<<endl;
cout<<"dz calcule : "<<TDP1(i).Z()<<endl;
cout<<"dz estime : "<<scal*(TP1(i).Z()-TP2(i).Z())<<endl;
cout<<"dw calcule : "<<TDW1(i)<<endl;
cout<<"dw estime : "<<scal*(TW1(i)-TW2(i))<<endl;
cout<<"dx calculated : "<<TDP1(i).X()<<endl;
cout<<"dx estimated : "<<scal*(TP1(i).X()-TP2(i).X())<<endl;
cout<<"dy calculated : "<<TDP1(i).Y()<<endl;
cout<<"dy estimated : "<<scal*(TP1(i).Y()-TP2(i).Y())<<endl;
cout<<"dz calculated : "<<TDP1(i).Z()<<endl;
cout<<"dz estimated : "<<scal*(TP1(i).Z()-TP2(i).Z())<<endl;
cout<<"dw calculated : "<<TDW1(i)<<endl;
cout<<"dw estimated : "<<scal*(TW1(i)-TW2(i))<<endl;
}
for(i = 1; i <= hp2d; i++){
cout<<endl;
cout<<"point 2d : "<<i<<endl;
cout<<"dx calcule : "<<TDP2d1(i).X()<<endl;
cout<<"dx estime : "<<scal*(TP2d1(i).X()-TP2d2(i).X())<<endl;
cout<<"dy calcule : "<<TDP2d1(i).Y()<<endl;
cout<<"dy estime : "<<scal*(TP2d1(i).Y()-TP2d2(i).Y())<<endl;
cout<<"dx calculated : "<<TDP2d1(i).X()<<endl;
cout<<"dx estimated : "<<scal*(TP2d1(i).X()-TP2d2(i).X())<<endl;
cout<<"dy calculated : "<<TDP2d1(i).Y()<<endl;
cout<<"dy estimated : "<<scal*(TP2d1(i).Y()-TP2d2(i).Y())<<endl;
}
}
@@ -133,8 +133,8 @@ static void Drawsect(const Standard_Real param,
//=======================================================================
//function : ArcToRecadre
//purpose : Cherche un arc candidat
// PrevIndex est utilise pour rejeter un arc deja teste
//purpose : Find a suitable arc
// PrevIndex is used to reject an already tested arc
//=======================================================================
Standard_Integer BRepBlend_SurfRstLineBuilder::
@@ -265,7 +265,7 @@ void BRepBlend_SurfRstLineBuilder::Perform(Blend_SurfRstFunction& Func,
Drawsect(param,Func);
}
#endif
// Mettre a jour la ligne.
// Update the line.
line->Append(previousP);
Standard_Real U,V;
previousP.ParametersOnS(U,V);
@@ -365,7 +365,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::PerformFirstSection
}
if (!recads && !recadp && !recadrst) return Standard_False;
if (recadp && recadrst) {
if(sens*(wrst-wp) > tolgui){ //on sort du domaine d abord
if(sens*(wrst-wp) > tolgui){ //first one leaves the domain
wrst = wp;
U = solinvp(2);
V = solinvp(3);
@@ -402,7 +402,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::PerformFirstSection
sol(3) = solinvs(2);
}
else if(sens*(ws-wrst)<0){
// sol sur surf
// ground on surf
State = Blend_OnRst1;
param = ws;
Arc->Value(solinvs(3)).Coord(U,V);
@@ -411,7 +411,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::PerformFirstSection
sol(3) = solinvs(2);
}
else{
// sol sur rst
// ground on rst
State = Blend_OnRst2;
param = wrst;
sol(1) = U;
@@ -421,7 +421,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::PerformFirstSection
Func.Set(param);
}
else if(recads){
// sol sur surf
// ground on surf
State = Blend_OnRst1;
param = ws;
Arc->Value(solinvs(3)).Coord(U,V);
@@ -431,7 +431,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::PerformFirstSection
Func.Set(param);
}
else if(recadrst){
// sol sur rst
// ground on rst
State = Blend_OnRst2;
param = wrst;
sol(1) = U;
@@ -487,7 +487,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
{
Standard_Real stepw = pasmax;
Standard_Integer nbp = line->NbPoints();
if(nbp >= 2){ //On reprend le dernier step s il n est pas trop petit.
if(nbp >= 2){ //The last step is reproduced if it is not too small.
if(sens < 0.){
stepw = (line->Point(2).Parameter() - line->Point(1).Parameter());
}
@@ -585,7 +585,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
recads = Recadre(FinvC,solinvs,Arc,IsVtxs,Vtxs);
if (recads) {
ws = solinvs(1);
// Il faut reevaluer le decrochage (BUC60360)
// It is necessary to reevaluate the deviation (BUC60360)
gp_Vec t, n;
Func.Set(ws);
Arc->Value(solinvs(3)).Coord(U,V);
@@ -622,7 +622,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
if(recadp || recads || recadrst) echecrecad = Standard_False;
if (!echecrecad) {
if (recadp && recadrst) {
if(sens*(wrst-wp) > tolgui){ //on sort du domaine d abord
if(sens*(wrst-wp) > tolgui){ //first one leaves the domain
wrst = wp;
U = solinvp(2);
V = solinvp(3);
@@ -661,7 +661,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
sol(3) = solinvs(3);
}
else if(sens*(ws-wrst)<0){
// sol sur surf
// ground on surf
decroch = 0;
State = Blend_OnRst1;
param = ws;
@@ -671,7 +671,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
sol(3) = solinvs(2);
}
else{
// sol sur rst
// ground on rst
State = Blend_OnRst2;
param = wrst;
sol(1) = U;
@@ -681,7 +681,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
Func.Set(param);
}
else if(recads){
// sol sur surf
// ground on surf
State = Blend_OnRst1;
param = ws;
Arc->Value(solinvs(3)).Coord(U,V);
@@ -691,7 +691,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
Func.Set(param);
}
else if(recadrst){
// sol sur rst
// ground on rst
State = Blend_OnRst2;
param = wrst;
sol(1) = U;
@@ -705,9 +705,9 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
State = TestArret(Func,Standard_True,State);
}
else{
// echec recadrage. On sort avec PointsConfondus
// Failed reframing. Leave with PointsConfondus
#if DEB
cout<<"SurfRstLineBuilder : echec recadrage"<<endl;
cout<<"SurfRstLineBuilder : failed reframing"<<endl;
#endif
State = Blend_SamePoints;
}
@@ -721,7 +721,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
Drawsect(param,Func);
}
#endif
// Mettre a jour la ligne.
// Update the line.
if (sens>0.) {
line->Append(previousP);
}
@@ -737,7 +737,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
sol(1),sol(2),
previousP.Parameter(),tolesp);
MakeExtremity(Extrst,Standard_False,rst,sol(3),IsVtxrst,Vtxrst);
// Indiquer que fin sur Bound.
// Indicate end on Bound.
}
else {
param = param + sens*stepw;
@@ -760,14 +760,14 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
previousP.Parameter(),tolesp);
Arrive = Standard_True;
if (line->NbPoints()>=2) {
// Indiquer qu on s arrete en cours de cheminement
// Indicate that one stops during the processing
#if DEB
cout<<"SurfRstLineBuilder :On n avance plus dans le cheminement"<<endl;
cout<<"SurfRstLineBuilder : No advancement in the processing"<<endl;
#endif
}
}
else {
param = parprec + sens*stepw; // on ne risque pas de depasser Bound.
param = parprec + sens*stepw; // no risk to exceed Bound.
}
}
break;
@@ -779,7 +779,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
Drawsect(param,Func);
}
#endif
// Mettre a jour la ligne.
// Update the line.
if (sens>0.) {
line->Append(previousP);
}
@@ -795,7 +795,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
Exts.SetValue(previousP.PointOnS(),sol(1),sol(2),
previousP.Parameter(),tolesp);
MakeExtremity(Extrst,Standard_False,rst,sol(3),IsVtxrst,Vtxrst);
// Indiquer que fin sur Bound.
// Indicate end on Bound.
}
else {
param = param + sens*stepw;
@@ -866,9 +866,9 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
case Blend_SamePoints :
{
// On arrete
// Stop
#if DEB
cout << "SurfRstLineBuilder Points confondus dans le cheminement" << endl;
cout << "SurfRstLineBuilder Points mixed in the processing" << endl;
#endif
previousP.ParametersOnS(U,V);
Exts.SetValue(previousP.PointOnS(),U,V,
@@ -899,7 +899,7 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction& Func,
//=======================================================================
//function : Recadre
//purpose : Recadre une section Surface / Restriction
//purpose : Reframe section Surface / Restriction
//=======================================================================
Standard_Boolean BRepBlend_SurfRstLineBuilder::Recadre(Blend_SurfCurvFuncInv& FinvC,
@@ -949,19 +949,19 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::Recadre(Blend_SurfCurvFuncInv&
#endif
}
else {
// On doit verifier la valeur de la fonction
// It is necessary to check the value of the function
rsnld.Root(Solinv);
recadre = FinvC.IsSolution(Solinv,tolesp);
}
// En cas d'echecs, on regarde si un autre arc
// peut faire l'affaire (cas des sorties a proximite d'un vertex)
// In case of fail, it is checked if another arc
// can be useful (case of output at the proximity of a vertex)
if (!recadre) {
IndexSol = ArcToRecadre(sol, IndexSol,
lastpt2d, pt2d, pmin);
if (IndexSol == 0) {
return Standard_False; // Pas d'autre solution
return Standard_False; // No other solution
}
domain1->Init();
@@ -988,7 +988,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::Recadre(Blend_SurfCurvFuncInv&
#endif
}
else {
// On doit verifier la valeur de la fonction
// It is necessary to check the value of the function
rsnld.Root(Solinv);
recadre = FinvC.IsSolution(Solinv,tolesp);
}
@@ -1074,8 +1074,8 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::Recadre(Blend_SurfRstFunction&
if (!domain2->MoreVertex()) {
IsVtx = Standard_False;
}
// On recalcule la section par resolution directe, sinon, on se recupere
// des incoherences entre le parametre et sol dues au baillement.
// The section is recalculated by direct resolution, otherwise
// incoherences between the parameter and the ground caused by yawn are returned.
math_Vector infbound(1,3),supbound(1,3);
math_Vector parinit(1,3),tolerance(1,3);
@@ -1285,9 +1285,9 @@ void BRepBlend_SurfRstLineBuilder::MakeExtremity(BRepBlend_Extremity&
Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnSurf(const Blend_Point& CurPoint)
{
//Controles 3d du Blend_CSWalking.
//Controls 3d of Blend_CSWalking.
// regle par tests dans U4 correspond a 11.478 d
// rule by tests in U4 corresponds to 11.478 d
const Standard_Real CosRef3D = 0.98;
Standard_Real Cosi=0, Cosi2=0;
Standard_Boolean curpointistangent = CurPoint.IsTangencyPoint();
@@ -1314,7 +1314,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnSurf(const Blend_Poi
if(!prevpointistangent) prevNorme = prevTg.SquareMagnitude();
if (Norme <= tolesp*tolesp){
// il faudra peut etre forcer meme point
// it can be necessary to force same point
return Blend_SamePoints;
}
if(!prevpointistangent){
@@ -1322,7 +1322,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnSurf(const Blend_Poi
return Blend_SamePoints;
}
Cosi = sens*Corde*prevTg;
if (Cosi <0.) { // angle 3d>pi/2. --> retour arriere
if (Cosi <0.) { // angle 3d>pi/2. --> return back
return Blend_Backward;
}
@@ -1333,7 +1333,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnSurf(const Blend_Poi
}
if(!curpointistangent){
// Voir s il faut faire le controle sur le signe de prevtg*Tgsurf
// Check if it is necessary to control the sign of prevtg*Tgsurf
Cosi = sens*Corde*Tgsurf;
Cosi2 = Cosi * Cosi / Tgsurf.SquareMagnitude() / Norme;
if (Cosi2 < CosRef3D || Cosi < 0.) {
@@ -1342,7 +1342,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnSurf(const Blend_Poi
}
if(!curpointistangent && !prevpointistangent){
// Estimation de la fleche courante
// Estimation of the current arrow
Standard_Real FlecheCourante =
(prevTg.Normalized().XYZ()-Tgsurf.Normalized().XYZ()).SquareModulus()*Norme/64.;
@@ -1350,7 +1350,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnSurf(const Blend_Poi
return Blend_StepTooSmall;
}
if (FlecheCourante > fleche*fleche) {
// pas trop grand : commentaire interessant
// not too great :
return Blend_StepTooLarge;
}
}
@@ -1365,9 +1365,9 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnSurf(const Blend_Poi
Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnRst(const Blend_Point& CurPoint)
{
//Controles 3d du Blend_CSWalking.
//Controls 3D of Blend_CSWalking.
// regle par tests dans U4 correspond a 11.478 d
// rule by tests in U4 corresponds to 11.478 d
const Standard_Real CosRef3D = 0.98;
Standard_Real Cosi, Cosi2;
Standard_Boolean curpointistangent = CurPoint.IsTangencyPoint();
@@ -1394,7 +1394,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnRst(const Blend_Poin
if(!prevpointistangent) prevNorme = prevTg.SquareMagnitude();
if (Norme <= tolesp*tolesp){
// il faudra peut etre forcer meme point
// it can be necessary to force same point
return Blend_SamePoints;
}
if(!prevpointistangent){
@@ -1402,7 +1402,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnRst(const Blend_Poin
return Blend_SamePoints;
}
Cosi = sens*Corde*prevTg;
if (Cosi <0.) { // angle 3d>pi/2. --> retour arriere
if (Cosi <0.) { // angle 3d>pi/2. --> return back
return Blend_Backward;
}
@@ -1413,7 +1413,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnRst(const Blend_Poin
}
if(!curpointistangent){
// Voir s il faut faire le controle sur le signe de prevtg*Tgsurf
// Check if it is necessary to control the sign of prevtg*Tgsurf
Cosi = sens*Corde*Tgsurf;
Cosi2 = Cosi * Cosi / Tgsurf.SquareMagnitude() / Norme;
if (Cosi2 < CosRef3D || Cosi < 0.) {
@@ -1422,7 +1422,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnRst(const Blend_Poin
}
if(!curpointistangent && !prevpointistangent){
// Estimation de la fleche courante
// Estimation of the current arrow
Standard_Real FlecheCourante =
(prevTg.Normalized().XYZ()-Tgsurf.Normalized().XYZ()).SquareModulus()*Norme/64.;
@@ -1430,7 +1430,7 @@ Blend_Status BRepBlend_SurfRstLineBuilder::CheckDeflectionOnRst(const Blend_Poin
return Blend_StepTooSmall;
}
if (FlecheCourante > fleche*fleche) {
// pas trop grand : commentaire interessant
// not too great
return Blend_StepTooLarge;
}
}
@@ -1568,7 +1568,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::CheckInside(Blend_SurfRstFunction
{
math_Vector tolerance(1,3);
Func.GetTolerance(tolerance,tolesp);
//cote pcurve.
//face pcurve.
Standard_Real w = sol(3);
if(w < rst->FirstParameter() - tolerance(3)||
w > rst->LastParameter() + tolerance(3)){
@@ -1580,11 +1580,11 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::CheckInside(Blend_SurfRstFunction
}
else SituOnC = TopAbs_ON;
//cote surface
//face surface
gp_Pnt2d p2d(sol(1),sol(2));
SituOnS = domain1->Classify(p2d,Min(tolerance(1),tolerance(2)),0);
//decrochage
//lost contact
gp_Vec tgs,nors;
Decroch = Func.Decroch(sol,tgs,nors);