From 626ee0c98dca0e71946366898de590cf454f5644 Mon Sep 17 00:00:00 2001 From: wandererfan Date: Thu, 21 Mar 2019 12:17:04 -0400 Subject: [PATCH] Fix TD Dfx export - spline conversion --- src/Mod/Import/App/ImpExpDxf.cpp | 2 +- src/Mod/TechDraw/App/Geometry.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Mod/Import/App/ImpExpDxf.cpp b/src/Mod/Import/App/ImpExpDxf.cpp index 794e27edec..edd1bc9749 100644 --- a/src/Mod/Import/App/ImpExpDxf.cpp +++ b/src/Mod/Import/App/ImpExpDxf.cpp @@ -606,7 +606,7 @@ void ImpExpDxfWrite::exportBSpline(BRepAdaptor_Curve& c) gp_Pnt s,ePt; Standard_Real tol3D = 0.001; - Standard_Integer maxDegree = 3, maxSegment = 100; + Standard_Integer maxDegree = 3, maxSegment = 200; Handle(BRepAdaptor_HCurve) hCurve = new BRepAdaptor_HCurve(c); Approx_Curve3d approx(hCurve, tol3D, GeomAbs_C0, maxSegment, maxDegree); if (approx.IsDone() && approx.HasResult()) { diff --git a/src/Mod/TechDraw/App/Geometry.cpp b/src/Mod/TechDraw/App/Geometry.cpp index 123be79795..7aa60fe8a4 100644 --- a/src/Mod/TechDraw/App/Geometry.cpp +++ b/src/Mod/TechDraw/App/Geometry.cpp @@ -530,7 +530,7 @@ BSpline::BSpline(const TopoDS_Edge &e) } Standard_Real tol3D = 0.001; //1/1000 of a mm? screen can't resolve this - Standard_Integer maxDegree = 3, maxSegment = 100; + Standard_Integer maxDegree = 3, maxSegment = 200; Handle(BRepAdaptor_HCurve) hCurve = new BRepAdaptor_HCurve(c); // approximate the curve using a tolerance //Approx_Curve3d approx(hCurve, tol3D, GeomAbs_C2, maxSegment, maxDegree); //gives degree == 5 ==> too many poles ==> buffer overrun