ggoblin wrote: ↑Wed Jul 06, 2022 10:00 pm
Do you know what
AimControlHandleAtNeighbor
and
CorrectControlHandleAngles
do...
Aim..AtNeighbour -- points the control handle to the next point -- In EditBezier, I use it only when the point curvature is 0 so the bezier handle that is NOT being tweaked stays pointed along the path to the next point (which is not the subject of curve deformation)
I haven't a clue about Correct...Angles -- So blind guesswork: maybe there's a possibility that the angle can go out of range (by +/- 2Pi??) and this goes through making all the angles "behave" (and stay in range - which might be -Pi to Pi or 0 to 2Pi????)
===
[Cross post -- sorry!!]
for your 2 point circle:
---------------------------
what I'd try is to get the orthogonal to the straight line between the two mesh points at each of the points -- these should be the tangents along which the control handles need to point -- work out the handle positions along those lines.
I think this is right (apologies in advance if not!): so for a point at {x,y} with a normalised tangent that runs from there to {xt, yt}; the length of the 'circle' Bezier handle is (4/3)*TAN(PI/(2*n)); so where n = 2 -> 4/3*TAN(PI/4) -> 4/3 ; scale the tangent up by 4/3 giving {xs, ys} which gives you the end of one handle; and the end of the other handle is {2x-xs, 2y-ys}
hth