2010/12/19 Jasper van de Gronde <th.v.d.gronde@...528...>:
As for speed. Well, that's always an interesting issue :) Without sacrificing quality or using hand-written assembly or the graphics card a lot of filters are currently about as fast as they're going to get (although getting them a bit faster is still possible, and there's also some room left for improvement in "overhead"). There are also filters which are still coded in a "stupid" way and have lots of room for improvement (this includes the morphology filter). In general, if there is a specific filter you have an issue with: file a bug, and remember to also state your expectations.
The Cairo branch includes a much better morhpology filter - it is O(N) in radius instead of O(N^2) like the old one. Other filters also have improved performance.
The big problem with filter rendering right now is not their performance, but that to render a filtered tile we need to know a lot of the background. For example, Gaussian blur needs to know not only the contents of the current tile but also things outside it. We currently do not cache anything, so we end up re-rendering the same things over and over. Performance in this case could be improved a lot through caching, but it requires some experimentation.
If you're talking about stroking or filling as being a kind of "effect" that acts upon an abstract shape, then I think that could indeed make sense. Is there any application that does this? And/or can you make more detailed mockups of how you would like to see this kind of thing work in Inkscape?
Sounds a lot like SVG 1.2 vector effects.
It sounds like you're looking to use BackgroundImage as source. This is supported, but does not work perfectly with all filters yet (basically it only works with filters that work per pixel, like the color matrix filter). It also has some other caveats, but that's a bit beyond the scope of this thread, if you're having trouble getting it to work, drop us a line.
The semantics of BackgroundImage in SVG 1.1 are do not make any sense whatsoever to me - you have to explicitly enable background accumulation, and it works differently than normal rendering. For example, opacity has no effect when rendering BackgroundImage.
Regards, Krzysztof