Re: [svgwg] Filter primitive subregion interpretation (#1047)

> The spec (both SVG 1.1 and the 2.0 draft) contain this half-sentence when talking about the filter primitive subregion:
> 
> ```
> the default subregion is 0%,0%,100%,100%, where as a special-case the percentages are relative to the dimensions of the [filter region] 
> (https://www.w3.org/TR/SVG11/filters.html#FilterEffectsRegion), thus making the the default [filter primitive subregion](https://www.w3.org/TR/SVG11/filters.html#FilterPrimitiveSubRegion) equal to the [filter region](https://www.w3.org/TR/SVG11/filters.html#FilterEffectsRegion).
> ```
> 
> It isn't entirely clear (at least to me) if this this just an awkward way of saying "the default filter primitive subregion is equal to the filter region",

Yes, this.

> or if it prescibes how percentage are to be interpreted in x, y, width, height set on filter primitves.

No, only for the default values in the specific cases...
 
> This quick experiment:
> 
> `<svg xmlns="http://www.w3.org/2000/svg" width="500" height="500"> <defs> <filter id="filter"> <feFlood flood-color='pink' x='0' y='0' width='10%' height='50'/> </filter> </defs> <rect transform="scale(2)" x='20' y="100" width="100" height="100" filter="url(#filter)" /> <rect transform="scale(2)" x='20' y="100" width="100" height="100" fill='none' stroke='black' stroke-width='1px' /> </svg>`
> 
> shows that browsers and inkscape interpret the 10% relative to the viewport, not relative to the filter region.

...so in this case the percentage value is resolved per the defined `primitiveUnits`.

-- 
GitHub Notification of comment by fsoder
Please view or discuss this issue at https://github.com/w3c/svgwg/issues/1047#issuecomment-3724130595 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 8 January 2026 14:29:01 UTC