[fxtf-drafts] [filter-effects-1] Add edgemode=reflect (#527)

flackr has just created a new issue for https://github.com/w3c/fxtf-drafts:

== [filter-effects-1] Add edgemode=reflect ==
A reflect edgemode in [filter-effects-1](https://drafts.fxtf.org/filter-effects-1/#element-attrdef-feconvolvematrix-edgemode) would be very useful as the behavior for the backdrop-filter blur behavior (See #374) as it avoids a discontinuity when moving the filter over new content.

The behavior of this mode would be that pixels outside mirror the pixels inside, e.g. it would be as follows:
Original N-by-M image, where m=M-1 and n=N-1:
```
 11  12 ...  1m  1M
 21  22 ...  2m  2M
... ... ... ... ...
 n1  n2 ...  nm  nM
 N1  N2 ...  Nm  NM
```

Extended by two pixels using reflect:
```
 11  12 ...  1m  1M  1M  1m
 21  22 ...  2m  2M  2M  2m
... ... ... ... ... ... ...
 n1  n2 ...  nm  nM  nM  nm
 N1  N2 ...  Nm  NM  NM  Nm
 N1  N2 ...  Nm  NM  NM  Nm
 n1  n2 ...  nm  nM  nM  nm
```

We can debate whether the border pixels should repeat in reflect mode, but doing so has the nice property that a 2N by 2M sampling is exactly one additional copy of the image worth of pixels.

Please view or discuss this issue at https://github.com/w3c/fxtf-drafts/issues/527 using your GitHub account


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

Received on Monday, 28 August 2023 14:50:04 UTC