Taming feTurbulence Effects' Display with feComposite
In the case of some primitives, effects may apply themselves across the bounding box of the entire object (such as you saw with feTurbulence). In most cases, this will not be a desirable effect; you will want your effects to take the shape of the objects they are applied to. Thus, you'll need to use a primitive such as feComposite to merge certain filter effects with the shape of the original object.
At a common level of usage, feComposite's syntax is simple, as shown in the following:
<feComposite in=”id1” in2=”id2” operator=”value”/>.
As feComposite involves the compositing of two sets of content, it needs the capabilities for two inputs, hence the addition of the in2 attribute. How these ...
Get Sams Teach Yourself SVG in 24 Hours now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.