A filter runs effects over what one object, and everything under it, draws: one contour around a character made of pieces, a glow behind a coin, a shadow under a row of enemies. useFilter makes it and add says what it filters, like a mask.
It takes outline, dropShadow and glow, made for it, and every effect of the screen: rect keeps a crt to a television's screen. Each object filtered costs a picture of its own, so many enemies go under one object with one filter.
One of your own is written as a screen effect is, fn effect(color, uv) in WGSL and GLSL with its knobs: the slime's hit flash. On an object, uv and resolution are its part of the screen, the colour comes multiplied by its alpha, and reach or padding give it room to draw around the object.