hi, I am not a developer yet, I am a student of informatics engineering, now, I have a idea to do shadows, using the border attribute of objects, in theory use a parallel degrade, started in the inside part of the border, and go to transparent at the end of border for shadow to out and reverse to shadow in. this is my idea (I don't speak English well), I will develop this option someday and bring it to you, now I bring you only a idea, if somebody developed this thing, tell me please, bye,
PD:this shadow is something like the shadows of gimp or fireworks, this kind of shadows give realism to a image in svg
Jairo Gonzalez wrote:
hi, I am not a developer yet, I am a student of informatics engineering, now, I have a idea to do shadows, using the border attribute of objects, in theory use a parallel degrade, started in the inside part of the border, and go to transparent at the end of border for shadow to out and reverse to shadow in. this is my idea (I don't speak English well), I will develop this option someday and bring it to you, now I bring you only a idea, if somebody developed this thing, tell me please, bye,
PD:this shadow is something like the shadows of gimp or fireworks, this kind of shadows give realism to a image in svg
SVG provides one way to do shadows right: using the Blur filter, it should look exactly the same as the shadows from Gimp, but for now Inkscape does not support any kind of filters.
In the meantime, the Blur Edge effect may be used as a workaround with passable results. Personally, I am not a big fan of implementing yet another workaround instead of the real deal (SVG filters), but I guess developing this as an effect plugin may be a good learning experience and an introduction to the Inkscape codebase (but IMO the effort would be better spent on other effects).
2006/4/26, Jairo Gonzalez <gonzalez.jairo@...400...>:
hi, I am not a developer yet, I am a student of informatics engineering, now, I have a idea to do shadows, using the border attribute of objects, in theory use a parallel degrade, started in the inside part of the border, and go to transparent at the end of border for shadow to out and reverse to shadow in. this is my idea (I don't speak English well), I will develop this option someday and bring it to you, now I bring you only a idea, if somebody developed this thing, tell me please, bye,
Well, this is not going to work, why? Because parallel degrade only works for a direction. A border has multiple directions. So you say: easy, just make a rectangle for each line. But you have to join different rectangles, how to join rectangles? (you need memory, complexity of code, bad) and they are beziers too (1000 rectangles for each curve?, more complexity...).
Simply this could be done, but is too low level for inkscape, you need to modify the graphic libraries, and is very boring and slow to code, so I think is very difficult someone does this. In fact, I have some code that does exacly this, but is very complex just to paint four faces polygons (imagine something like Inkscape with unlimited face polygons and beziers, complexity grow exponentially with number of faces).For each four faces I need four rectangles, and four "edge rectangles".
The good is that is much faster than Blur filter, and you can make lights as well as shadows. The bad is that complexity is simply impossible to control (unless you reduce everything to simpler units[more complexity,it will overflow your capabilities])
PD:this shadow is something like the shadows of gimp or fireworks, this kind of shadows give realism to a image in svg
Blur filter is very easy to program, and it doesn't depend of context. Just create a matrix as a kernel, and apply to the image. It could be made somewhat faster taking advantage of parallel processors and hardware, and if Xara guys free their engine, it will be possible to not reinvent the wheel. So when Inkscape implements shadows, I feel it's going to be via Blur filters. Jose Hevia
participants (3)
-
Jairo Gonzalez
-
Jose Hevia
-
Nicu Buculei