For all issues regarding the Forums use, please, refer to the Forum Rules.

### Our Solutions

Need professional assistance?
Consider our:

Need to speed up your development?
Have a look at our:

Need some functionality extending standard OCCT capabilities?
Check out our:

# Linear interpolation of points and curves

Forums:

I would like to do a simple linear interpolation of points to create a curve or a linear interpolation of section curves to create a surface. I was able to use GeomAPI_PointsToBSpline with min_degree=max_degree=1, but this fails with GeomFill_AppSurf. It generates a Standard_OutOfRange RuntimeError.

I use the GeomFill_SectionGenerator to make sure all the curves are compatible (same degree and knot vector) and GeomFill_Line(NbPoints = # of curves in section generator). It works for most cases but fails when trying to do a linear interpolation.

Is there another tool to use or some changes I can make to my process?

Thanks.

### have you solve the problem? I

have you solve the problem? I have the same question.

### Not entirely. To create a

Not entirely. To create a polyline I can use GeomAPI_PointsToBSpline with a min/max degree set to 1. But I haven't solved the surface case yet. I ended up writing my own surface interpolation starting from "The NURBS Book"...

### I want to obtain a line by

I want to obtain a line by some points ,have you any ideal?

### Hi,

Hi,

I only get a polyline  not a line using GeomAPI_PointsToBSpline. I want to get one line by points,do you know how to nInterpolate it?

thanks!

### I guess I don't understand

I guess I don't understand what you need. You have multiple points and you want to generate a 1st degree curve between them? Do you only have two points and you want a simple line between the two? Do you want a Geom_Line or Geom_BSplineCurve? The Geom_Line is an infinite line.

Try using the GeomAPI_PointsToBSpline with min/max degree = 1, if you want a finite Geom_BSplineCurve.

### You oculd use gce_MakeLin to

You oculd use gce_MakeLin to create a gp_Lin between two points.