How to get a sequenced serise of points on a curve..

I am trying to get a Serise of points on a curve like BSpline, circle or edge,

i am using:-

BRepTool::Curve(const TopoDS_Edge& E,TopLoc_Location& L,Standard_Real& First,Standard_Real& Last) ;

It gives just the two end points, i need a continious curve points,can anyone suggest me a way to get that...

Mark Blome's picture

Dear Mahimuddin Biswas,

you can simply use the Function Value(uparameter) for Geom_Curve objects and Value(uparam, vparam) for Geom_Surface objects, e.g. in your case:
CurveHandle = BRep_Tool().Curve(TopoDS().Edge(anEdge)) # Handle_Geom_Curve
P = CurveHandle.GetObject().Value(uparameter) # gp_Pnt
(I use PythonOCC, so this is python code)
You might also take a look at OCC class
GCPnts_AbscissaPoint
with which you can compute points on a curved bspline that have certain distances along the curve.

Regards,
Mark

Gilles Paiva's picture

Hi,

How can I create a spline? inf fact, I want to create 4 splines, and then a surface in the middle(the 4 splines will be linked and forma a surface).

I have no ides how to create this.