Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 8 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(3)
你想要的是一个三次Hermite样条线:
其中 p0 是起点,p1 是终点,m0 是起点切线,m1 是终点切线
What you want is a Cubic Hermite Spline:
where p0 is the start point, p1 is the end point, m0 is the start tangent, and m1 is the end tangent
您可以进行线性插值和三次插值,并在两个插值函数之间进行插值。
IE。
其中 t 的范围为 0...1
you could have a linear interpolation and a cubic interpolation and interpolate between the two interpolation functions.
ie.
where t ranges from 0...1
好吧,一种简单的方法是这样的:
或以编程方式(立方调整):
对于另一种,只需省略“移动”:
或以编程方式(立方调整):
Well, a simple way would be this:
Or programmatically (cubical adjusting):
For the other one, simply leave out the "moving":
Or programmatically (cubical adjusting):