was wondering something and thought it would be best to explain myself by abstracting my question to be more math related while still giving me my answer:
(whenever i refer to a point or direction just assume Vector2) does anyone know a module/name for a 2D spline that supports these criteria?:
is constructed by 2 points with a corresponding unit direction vector for the way the spline should articulate before reaching each point
a method to use a point in whatever process to determine a resultant point closest to the original that lays on the spline
a method like most other splines to still be able to provide a numerical value between 0-1 that returns a point ___% of the way across the entire spline
here is a code example and diagram to hopefully articulate the first two criteria better than my words can
sorry for the late response, but after some more research into what i actually am looking for i realised that, not only do both of these modules not align with the first and second criteria i provided, i dont believe its possible for any curve to follow my first criteria.
because of this, for now and for my usecase, i think i’ll be trying to use bezier curves, and then sampling positions across its length to get a rough estimate for the function i need leaving this post open though because this solution only really resolves criteria 2, i’ll need to make my own code for suitable control points based on requested direction values