FiniteSingularity / obs-composite-blur

A comprehensive blur plugin for OBS that provides several different blur algorithms, and proper compositing.
GNU General Public License v2.0
380 stars 30 forks source link

[FEATURE] - Pixelate Smoothing #64

Closed FiniteSingularity closed 9 months ago

FiniteSingularity commented 1 year ago

Is your feature request related to a problem? Please describe. Currently the Pixelate filter only samples the pixel at the very center of the larger pixel. This creates pixels that can flicker quite a bit as the source moves, and the color value at the exact center of the pixel changes.

Describe the solution you'd like A smoothing factor should be added where at higher values rather than just sampling the center pixel, the filter will sample a larger area average color. To do this, one could easily use a pass of the Dual Kawase filter before sampling, with very little impact on performance. This smoothing value might range from zero (no smoothing) to 1, where an equivalent area to the total pixel size is sampled.

Describe alternatives you've considered This can currently be simulated by adding two stacked composite blur filters- a Kawase Blur, then a pixelate. As it is a common use case, it would be convenient to have this as a built-in option.