mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
0027537: GCPnts_TangentialDeflection produces incorrect number of sample points for circular edge
* Round up number of sample points to satisfy deflection. * Test case added
This commit is contained in:
@@ -219,7 +219,8 @@ void GCPnts_TangentialDeflection::PerformCircular (const TheCurve& C)
|
||||
dfR, curvatureDeflection, angularDeflection, myMinLen);
|
||||
|
||||
const Standard_Real aDiff = lastu - firstu;
|
||||
Standard_Integer NbPoints = (Standard_Integer)(aDiff / Du);
|
||||
// Round up number of points to satisfy curvatureDeflection more precisely
|
||||
Standard_Integer NbPoints = (Standard_Integer)Ceiling(aDiff / Du);
|
||||
NbPoints = Max(NbPoints, minNbPnts - 1);
|
||||
Du = aDiff / NbPoints;
|
||||
|
||||
|
Reference in New Issue
Block a user