On 25-4-2011 11:58, Alexandre Prokoudine wrote:
On Mon, Apr 25, 2011 at 1:50 PM, Ilya Baran wrote:
I like the fact that, judging by video, the testing app more or less allows to see the final curve as you draw, but I'm afraid that LPE based implementation will ruin half the fun.
Unfortunately, it doesn't let you see the final curve as you draw
Oh, in comparison to current implementaton in Inkscape it actually _does_ let you see it, because the solver in libspiro does really crazy stuff at times :) From the video I do see that the approximation is very close to what you draw first.
BTW, what would be the advantage of an LPE-based implementation?
Apart from being able to render it anywhere? None, I'm afraid. LPE is _very_ simplistic. There has been talk about implementing advanced curves in SVG v2, but this is where Tav could provide some input, not me.
Regarding an LPE-based implementation, an advantage is that the original sketch is stored, so you can tweak the curve fit parameters afterwards and see what it does to the curve. A clear disadvantage is that it is inherently slower, as it has to do the refitting everytime you move/transform/etc the path. Morever as LPE, you cannot tweak the end result with the normal node-tool; you would have to tweak the original path, which is probably cumbersome as it has many more nodes, etc.
So, I would not implement this as an LPE only, but as a replacement for the curvefitting in the pencil-tool (just like you did :).
( The LPE talk is somewhat interesting, because right now we don't have a 'smoothing/fitting' LPE! )
Ciao, Johan