我想实现的东西接近到什么Adobe Illustrator中不使用画笔工具。它正确地分析和简化了路径,包括它的贝赛尔手柄。我实现了Ramer–Douglas–Peucker_algorithm然而,彼时实际上不是我所需要的。它非常适用于线段,但在贝赛尔手柄并不因素。是否有一个算法,能做到这样的算法,但考虑到三次Bezier手柄?与这一个问题是一个曲线可以以一角度,但该算法只看到一条直线。
I'm trying to achieve something close to what Adobe Illustrator does with the brush tool. It correctly analyzes and simplifies the path, including its bezier handles. I implemented the Ramer–Douglas–Peucker_algorithm however, it wound up not really being what I needed. It works very well for line segments, but doesn't factor in bezier handles. Is there an algorithm that can do like this algorithm, but take into consideration cubic bezier handles? The problem with this one is that a curve could be at an angle but the algorithm only sees a straight line.
感谢
推荐答案您可能想探索最小二乘法拟合贝塞尔曲线。这里是一个线程和的一个PDF 。我几年前做了这样的事情,可能会有帮助,发现的杰拉尔德·法林的图书有益的,但我不记得是哪一个。
You probably want to explore least squares fitting for Bezier curves. Here's one thread and a pdf that may be helpful.. I did this sort of thing several years ago, and found one of Gerald Farin's books helpful, but I can't remember which one.
更多推荐
简化三次贝塞尔路径?
发布评论