Notifications
Clear all
[Closed] Bézier Curve question
Mar 27, 2019 9:05 am
Hi there
Here it is the function for the 3 points Bézier Curve to find the Beziear Curve point for .5
--based on 3 points
function Bezier3pt P1 P2 P3 Param =
(
return ( (((1-Param)^2) * P1) + (2 * (1-Param) * Param * P2) + ((Param^2) * P3) )
)
delete objects
p1=(point pos:[0,0,0] wirecolor:red).pos
p2=(point pos:[35,0,65]wirecolor:red)
p3=(point pos:[115,0,0]wirecolor:red).pos
thebizPt = point wirecolor:green pos:(Bezier3pt p1 p2.pos p3 .5)
--for my question I delete the P2
delete p2
Now we have P1 P3 the param which is .5 and the Bézier point for .5 here it is the ” thebizPt “
Now my question is:
Is there any way to find the deleted P2 position?
Thanks in advance
4 Replies
Mar 27, 2019 9:05 am
Your bezier curve is just a second degree parabola. You can get its equation using P1, P3 and ‘thebizPt’ (the same one as using P1, P2 and P3).
But to get P2, you need some data about it (its param, an X coordinate, a Tangent slope in it…).
1 Reply