mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-24 13:50:49 +03:00
0027079: Bad approximation of intersection curves with variable curvature
1. Method Approx_ComputeLine::Perform is modified: now it contains also recursive calls after new line computation made by new method ApproxInt_MultiLine::MakeMLOneMorePoint. 2. New method MakeMLOneMorePoint is added to ApproxInt_MultiLine: it builds new sub-line as a part of main line with new point added into the middle of the longest interval between existing points. 3. Method ShapeConstruct_ProjectCurveOnSurface::ApproxPCurve is modified to avoid regressions: now it takes care of the set of initial points to be enough close to each other so that an interval between two adjacent points is less than half-period of the surface. 4. Modification in ShapeConstruct_ProjectCurveOnSurface: correction of pcurves of edges which extremities are in the singularities of surface.
This commit is contained in:
@@ -41,6 +41,8 @@ public:
|
||||
|
||||
DEFINE_STANDARD_ALLOC
|
||||
|
||||
Standard_EXPORT BRepApprox_TheMultiLineOfApprox();
|
||||
|
||||
//! The class SvSurfaces is used when the approximation algorithm
|
||||
//! needs some extra points on the line <line>.
|
||||
//! A New line is then created which shares the same surfaces and functions.
|
||||
@@ -51,6 +53,8 @@ public:
|
||||
const Standard_Address PtrSvSurfaces,
|
||||
const Standard_Integer NbP3d,
|
||||
const Standard_Integer NbP2d,
|
||||
const Standard_Boolean ApproxU1V1,
|
||||
const Standard_Boolean ApproxU2V2,
|
||||
const Standard_Real xo,
|
||||
const Standard_Real yo,
|
||||
const Standard_Real zo,
|
||||
@@ -66,6 +70,8 @@ public:
|
||||
Standard_EXPORT BRepApprox_TheMultiLineOfApprox(const Handle(BRepApprox_ApproxLine)& line,
|
||||
const Standard_Integer NbP3d,
|
||||
const Standard_Integer NbP2d,
|
||||
const Standard_Boolean ApproxU1V1,
|
||||
const Standard_Boolean ApproxU2V2,
|
||||
const Standard_Real xo,
|
||||
const Standard_Real yo,
|
||||
const Standard_Real zo,
|
||||
@@ -106,30 +112,42 @@ public:
|
||||
|
||||
//! Returns the 3d and 2d points of the multipoint <MPointIndex>.
|
||||
Standard_EXPORT Standard_Boolean Tangency (const Standard_Integer MPointIndex, TColgp_Array1OfVec& tabV, TColgp_Array1OfVec2d& tabV2d) const;
|
||||
|
||||
//! Tries to make a sub-line between <Low> and <High> points of this line
|
||||
//! by adding <NbPointsToInsert> new points
|
||||
Standard_EXPORT BRepApprox_TheMultiLineOfApprox MakeMLBetween (const Standard_Integer Low,
|
||||
const Standard_Integer High,
|
||||
const Standard_Integer NbPointsToInsert) const;
|
||||
|
||||
Standard_EXPORT BRepApprox_TheMultiLineOfApprox MakeMLBetween (const Standard_Integer Low, const Standard_Integer High, const Standard_Integer NbPointsToInsert) const;
|
||||
|
||||
//! Tries to make a sub-line between <Low> and <High> points of this line
|
||||
//! by adding one more point between (indbad-1)-th and indbad-th points
|
||||
Standard_EXPORT Standard_Boolean MakeMLOneMorePoint (const Standard_Integer Low,
|
||||
const Standard_Integer High,
|
||||
const Standard_Integer indbad,
|
||||
BRepApprox_TheMultiLineOfApprox& OtherLine) const;
|
||||
|
||||
//! Dump of the current multi-line.
|
||||
Standard_EXPORT void Dump() const;
|
||||
|
||||
protected:
|
||||
BRepApprox_TheMultiLineOfApprox operator=(BRepApprox_TheMultiLineOfApprox&);
|
||||
|
||||
private:
|
||||
const Standard_Address PtrOnmySvSurfaces;
|
||||
const Handle(BRepApprox_ApproxLine) myLine;
|
||||
const Standard_Integer indicemin;
|
||||
const Standard_Integer indicemax;
|
||||
const Standard_Integer nbp3d;
|
||||
const Standard_Integer nbp2d;
|
||||
const Standard_Boolean p2donfirst;
|
||||
const Standard_Real Xo;
|
||||
const Standard_Real Yo;
|
||||
const Standard_Real Zo;
|
||||
const Standard_Real U1o;
|
||||
const Standard_Real V1o;
|
||||
const Standard_Real U2o;
|
||||
const Standard_Real V2o;
|
||||
Standard_Address PtrOnmySvSurfaces;
|
||||
Handle(BRepApprox_ApproxLine) myLine;
|
||||
Standard_Integer indicemin;
|
||||
Standard_Integer indicemax;
|
||||
Standard_Integer nbp3d;
|
||||
Standard_Integer nbp2d;
|
||||
Standard_Boolean myApproxU1V1;
|
||||
Standard_Boolean myApproxU2V2;
|
||||
Standard_Boolean p2donfirst;
|
||||
Standard_Real Xo;
|
||||
Standard_Real Yo;
|
||||
Standard_Real Zo;
|
||||
Standard_Real U1o;
|
||||
Standard_Real V1o;
|
||||
Standard_Real U2o;
|
||||
Standard_Real V2o;
|
||||
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user