X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=blobdiff_plain;f=src%2FBRepTools%2FBRepTools.cxx;h=7b75cc325b01731a4403c22dcaac0171ba763aa9;hb=9ae883970dd77a39d856b49e6883ed5d0e60d20f;hpb=8019a482b5208e9da2ba52f1202f500125df53b8 diff --git a/src/BRepTools/BRepTools.cxx b/src/BRepTools/BRepTools.cxx index 99b3828d6f..7b75cc325b 100644 --- a/src/BRepTools/BRepTools.cxx +++ b/src/BRepTools/BRepTools.cxx @@ -15,6 +15,7 @@ // commercial license or contractual agreement. +#include #include #include #include @@ -30,6 +31,7 @@ #include #include #include +#include #include #include #include @@ -1333,9 +1335,16 @@ Standard_Real BRepTools::EvalAndUpdateTol(const TopoDS_Edge& theE, first = Max(first, C2d->FirstParameter()); last = Min(last, C2d->LastParameter()); } + const Handle(Adaptor3d_Curve) aGeomAdaptorCurve = new GeomAdaptor_Curve(C3d, first, last); - GeomLib_CheckCurveOnSurface CT(C3d, S, first, last); - CT.Perform(C2d); + Handle(Adaptor2d_Curve2d) aGeom2dAdaptorCurve = new Geom2dAdaptor_Curve(C2d, first, last); + Handle(GeomAdaptor_Surface) aGeomAdaptorSurface = new GeomAdaptor_Surface(S); + + Handle(Adaptor3d_CurveOnSurface) anAdaptor3dCurveOnSurface = + new Adaptor3d_CurveOnSurface(aGeom2dAdaptorCurve, aGeomAdaptorSurface); + + GeomLib_CheckCurveOnSurface CT(aGeomAdaptorCurve); + CT.Perform(anAdaptor3dCurveOnSurface); if(CT.IsDone()) { newtol = CT.MaxDistance();