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

0029257: GeomPlate generates surface in unexpected place

Treatment of the parameter EnlargeCoeff in the constructor of GeomPlate_MakeApprox has been corrected. Now the bounds of the result surface are correctly enlarged.

The new draw command 'pullupface' has been implemented to check behavior of GeomPlate.

The test case "perf modalg bug453_2" has been corrected. Now the area is computed the same on both Linux and Windows.
This commit is contained in:
msv
2017-10-24 15:01:49 +03:00
parent daf73ab7c9
commit 9e5aec8af6
5 changed files with 462 additions and 9 deletions

View File

@@ -257,10 +257,12 @@ GeomPlate_MakeApprox::GeomPlate_MakeApprox(const Handle(GeomPlate_Surface)& Surf
Standard_Real U0=0., U1=0., V0=0., V1=0.;
myPlate->RealBounds(U0, U1, V0, V1);
U0 = EnlargeCoeff * U0;
U1 = EnlargeCoeff * U1;
V0 = EnlargeCoeff * V0;
V1 = EnlargeCoeff * V1;
Standard_Real aDU = (U1 - U0) * (EnlargeCoeff - 1) * 0.5;
Standard_Real aDV = (V1 - V0) * (EnlargeCoeff - 1) * 0.5;
U0 = U0 - aDU;
U1 = U1 + aDU;
V0 = V0 - aDV;
V1 = V1 + aDV;
Standard_Integer nb1 = 0, nb2 = 0, nb3 = 1;
Handle(TColStd_HArray1OfReal) nul1 =
@@ -351,10 +353,12 @@ GeomPlate_MakeApprox::GeomPlate_MakeApprox(const Handle(GeomPlate_Surface)& Surf
Standard_Real U0=0., U1=0., V0=0., V1=0.;
myPlate->RealBounds(U0, U1, V0, V1);
U0 = EnlargeCoeff * U0;
U1 = EnlargeCoeff * U1;
V0 = EnlargeCoeff * V0;
V1 = EnlargeCoeff * V1;
Standard_Real aDU = (U1 - U0) * (EnlargeCoeff - 1) * 0.5;
Standard_Real aDV = (V1 - V0) * (EnlargeCoeff - 1) * 0.5;
U0 = U0 - aDU;
U1 = U1 + aDU;
V0 = V0 - aDV;
V1 = V1 + aDV;
Standard_Real seuil = Tol3d;
if (CritOrder==0&&Tol3d<10*dmax) {