The SVGFilterElement interface provides access to the properties of <filter> elements, as well as methods to manipulate them.
SVGFilterElement.filterUnits Read only
SVGAnimatedEnumeration that corresponds to the filterUnits attribute of the given <filter> element. Takes one of the constants defined in SVGUnitTypes.SVGFilterElement.primitiveUnits Read only
SVGAnimatedEnumeration that corresponds to the primitiveUnits attribute of the given <filter> element. Takes one of the constants defined in SVGUnitTypes.SVGFilterElement.x Read only
SVGAnimatedLength that corresponds to the x attribute on the given <filter> element.SVGFilterElement.y Read only
SVGAnimatedLength that corresponds to the y attribute of the given <filter> element.SVGFilterElement.width Read only
SVGAnimatedLength that corresponds to the width attribute of the given <filter> element.SVGFilterElement.height Read only
SVGAnimatedLength that corresponds to the height attribute of the given <filter> element.SVGFilterElement.filterResX Read only
SVGAnimatedInteger that contains the X component of the filterRes attribute of the given <filter> element.SVGFilterElement.filterResY Read only
SVGAnimatedInteger that contains the Y component of the filterRes attribute of the given <filter> element.SVGFilterElement.setFilterRes()
filterRes attribute.| Specification | Status | Comment |
| Filter Effects Module Level 1 The definition of 'SVGFilterElement' in that specification. | Working Draft | Removed the inheritance from SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, and SVGUnitTypes and removed the setFilterRes() function |
| Scalable Vector Graphics (SVG) 1.1 (Second Edition) The definition of 'SVGFilterElement' in that specification. | Recommendation | Initial definition |
| Desktop | ||||||
|---|---|---|---|---|---|---|
| Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | |
| Basic support | Yes | Yes | ? | ? | Yes | ? |
| Mobile | |||||||
|---|---|---|---|---|---|---|---|
| Android webview | Chrome for Android | Edge Mobile | Firefox for Android | Opera for Android | iOS Safari | Samsung Internet | |
| Basic support | Yes | Yes | Yes | ? | Yes | ? | ? |
© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/SVGFilterElement