James Churchman jameschurchman@gmail.com [svg-developers]
2015-12-13 00:45:15 UTC
Hi List, I have several things that bug be when using filters, so i thought
i would document my thoughts :
*A) Combine feBlend spec with the CSS Blend modes*
CSS Blend modes currently allow the very powerful : *normal ( reset
), **screen,
overlay, darken, lighten, color-dodge, color-burn, hard-light, soft-light,
difference, exclusion, hue, saturation, color,luminosity*
However the blend modes offered in feBlend are very limited only
offering : *normal,
multiply, screen, darken, lighten*
Given that browsers already offer these very powerful blend modes these
could be combined and offered to the user in feBlend as well. e.g. :
<feBlend mode="color | saturation ( etc.. would be great) ">
*B) Inline feImage*
One of the most powerful features of SVG filters is feImage, especially
when importing other referenced parts of the document. This is still often
quite a verbose experience as you have to place external parts in a defs
tag, give them an id, reference that id etc...
It would be far cleaner if you could inline svg directly inside a special
filter tag. Maybe simply :
<feInlineImage height="50" width="50">
<circle cx="10" cy="10" r="15" fill="black" />
</feInlineImage>
*C) Importing / Referencing other filters in a filter*
It would be incredibly useful to be able to, like you can with an feImage
or a use element for graphical nodes, pull in another filter's filter
nodes, and therefore combine multiple filters into one far more powerful
filter. Maybe a "feUse" or "feCombine", e.g. in this very simple example :
<defs>
<filter id="blur">
<feGaussianBlur stdDeviation="10" />
</filter>
<filter id="hue_rotate">
<feColorMatrix type="hueRotate" values="180" />
</filter>
<filter id="blur_and_hue_rotate">
<feCombine input="url(#hue_rotate)"/>
<feCombine input="url(#blur)"/>
</filter>
</defs>
*D) Multiple filters per element*
Currently if you wish to apply multiple filters to an element, you
currently have to wrap the element in multiple group G elements, and place
each filter in turn on each element. The experience could be a lot better
if the filter attribute could contain a list of filters separated by spaces
maybe ( and with a definition of which order to apply them in) e.g. :
<elem filter="url(#filter_1) url(#filter_2) url(#filter_1)" />
Would very much welcome your comments!
James
i would document my thoughts :
*A) Combine feBlend spec with the CSS Blend modes*
CSS Blend modes currently allow the very powerful : *normal ( reset
), **screen,
overlay, darken, lighten, color-dodge, color-burn, hard-light, soft-light,
difference, exclusion, hue, saturation, color,luminosity*
However the blend modes offered in feBlend are very limited only
offering : *normal,
multiply, screen, darken, lighten*
Given that browsers already offer these very powerful blend modes these
could be combined and offered to the user in feBlend as well. e.g. :
<feBlend mode="color | saturation ( etc.. would be great) ">
*B) Inline feImage*
One of the most powerful features of SVG filters is feImage, especially
when importing other referenced parts of the document. This is still often
quite a verbose experience as you have to place external parts in a defs
tag, give them an id, reference that id etc...
It would be far cleaner if you could inline svg directly inside a special
filter tag. Maybe simply :
<feInlineImage height="50" width="50">
<circle cx="10" cy="10" r="15" fill="black" />
</feInlineImage>
*C) Importing / Referencing other filters in a filter*
It would be incredibly useful to be able to, like you can with an feImage
or a use element for graphical nodes, pull in another filter's filter
nodes, and therefore combine multiple filters into one far more powerful
filter. Maybe a "feUse" or "feCombine", e.g. in this very simple example :
<defs>
<filter id="blur">
<feGaussianBlur stdDeviation="10" />
</filter>
<filter id="hue_rotate">
<feColorMatrix type="hueRotate" values="180" />
</filter>
<filter id="blur_and_hue_rotate">
<feCombine input="url(#hue_rotate)"/>
<feCombine input="url(#blur)"/>
</filter>
</defs>
*D) Multiple filters per element*
Currently if you wish to apply multiple filters to an element, you
currently have to wrap the element in multiple group G elements, and place
each filter in turn on each element. The experience could be a lot better
if the filter attribute could contain a list of filters separated by spaces
maybe ( and with a definition of which order to apply them in) e.g. :
<elem filter="url(#filter_1) url(#filter_2) url(#filter_1)" />
Would very much welcome your comments!
James