Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0031493Community[OCCT] OCCT:Modeling Datapublic2020-04-09 07:362020-04-09 07:36
Assigned Tomsv 
PlatformWindowsOSWindowsOS Version10
Product Version[OCCT] 7.3.0 
Target VersionFixed in Version 
Summary0031493: GCPnts_AbscissaPoint and CPnts_AbscissaPoint do not work properly for abscissa values larger than the curve length
DescriptionGCPnts_AbscissaPoint and CPnts_AbscissaPoint do not work properly for abscissa values larger than the curve length.
Lets call the parameter interval of the curve [c0, c1].
The curve seems to be extrapolated correctly for the abscissa calculation within a certain parameter range [p0, p1], with p0 < c0 < c1 < p1.
So [p0, p1] contains [c0, c1]. That means: The parameter range where the calculation works well is larger than the parameter range of the curve itself.
But outside this larger parameter range [p0, p] the calculation just does not work correctly any more.
Steps To ReproduceTColgp_Array1OfPnt Poles(1, 3);
Poles.SetValue(1, gp_Pnt(0, 0, 0));
Poles.SetValue(2, gp_Pnt(1, 0, 0));
Poles.SetValue(3, gp_Pnt(2, 0, 0));

TColStd_Array1OfReal Knots(1, 2);
Knots.SetValue(1, 0);
Knots.SetValue(2, 1);

TColStd_Array1OfInteger Multis(1, 2);
Multis.SetValue(1, 3);
Multis.SetValue(2, 3);
const int Degree = 2;

const Handle(Geom_BSplineCurve) BSplineCurve = new Geom_BSplineCurve(Poles, Knots, Multis, Degree, false);

const GeomAdaptor_Curve AdaptorCurve(BSplineCurve);

// The abscissa values are larger than the curve length
const double Abscissa1 = 4;
const double Abscissa2 = 8;

const GCPnts_AbscissaPoint GC_Abscissa1(AdaptorCurve, Abscissa1, BSplineCurve->FirstParameter());
const GCPnts_AbscissaPoint GC_Abscissa2(AdaptorCurve, Abscissa2, BSplineCurve->FirstParameter());

const CPnts_AbscissaPoint C_Abscissa1(AdaptorCurve, Abscissa1, BSplineCurve->FirstParameter(), 0.001);
const CPnts_AbscissaPoint C_Abscissa2(AdaptorCurve, Abscissa2, BSplineCurve->FirstParameter(), 0.001);

// The parameters for the different abscissa values should not be equal.
// Actual they are equal for both computation methods: GCPnts_AbscissaPoint and CPnts_AbscissaPoint
const double GC_Dist1_Param = GC_Abscissa1.Parameter();
const double GC_Dist2_Param = GC_Abscissa2.Parameter();

const double C_Dist1_Param = C_Abscissa1.Parameter();
const double C_Dist2_Param = C_Abscissa2.Parameter();
TagsNo tags attached.
Test case number
Attached Files

- Relationships

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2020-04-09 07:36 alexzkw New Issue
2020-04-09 07:36 alexzkw Assigned To => msv

Copyright © 2000 - 2021 MantisBT Team
Powered by Mantis Bugtracker