I have a the set of points my curve has to pass through, 2 of those are the start and end points. I'm looking for a way to find the control points of my bezier curve (mostly quadratic and cubic) by using points on the curve.
ex: I have 4 points: start,end and 2 points on the curve, the first and last control point are the start and end point but how do I determine the middle control point.
Can I do the same with a cubic bezier curve and 5 points ? (start,end and 3 on the curve)
I cannot use spline interpolation because the tool I'm using only allows for bezier curves.
thank you all
EDIT: so far it got:
I have 4 points on the curve, [$C_0,C_1,C_2,C_3$]
since first and last are control points: $[Q_0=C_0, Q_2=C_3]$
Bezier equation: $B(t)=(1-t)^2*Q_0+2(1-t)*t*Q_1+t^2*Q_2$
From this I can make 2 equation:
$C_1=(1-t_1)^2*Q_0+2(1-t_1)*t_1*Q_1+t_1^2*Q_2$
$C_2=(1-t_2)^2*Q_0+2(1-t_2)*t_2*Q_1+t_2^2*Q_2$
which is 2 equation, 3 unknown (infinite possiblity)
adding more points from the curve would give me n equation with n+1 unknown.
Maybe I'm wrong and there's no way to calculate the control points from just points on the curve (and no t value, the percentage along the curve at which they are located)
EDIT 2: Is there a way to find the control points WITHOUT EVER specifying the $t$ values? I can provide as many point on the curve as needed but assigning $t$ values to these points would be very imprecise. (I'm trying to model curves of a real life object). Unless I'm wrong, There is only 1 set of control points that generate a certain curve