filter(args)

Apply convolution mask filter either to the whole quadrille or at specific (row, col) cell.

Note

Filtering requires color-valued cells, i.e., image-pixelated quadrilles as created by createQuadrille(width, image) or createQuadrille(width, image, coherence).

Examples

filter(mask)

(press f to toggle filtered image; m to toggle mask display; and, s to rescale image)

edit, then run

filter(mask, row, col)

(mouse move to apply filter locally; press r to reset filtered image & s to rescale it)

edit, then run

Syntax

filter(mask, [row], [col])

Parameters

Param Description
mask Quadrille: quadrille of numbers representing the convolution mask
row Number: cell row coordinate, if undefined applies filter to the whole quadrille
col Number: cell col coordinate, if undefined applies filter to the whole quadrille
What this page's examples use
p5.quadrille
drawQuadrille createQuadrille mouseRow mouseCol tileDisplay width clone filter
p5.js
createCanvas background color loadImage key fill blue map red green colorMode rect RGB

Names the analysis can prove are called, and the line each one is documented on. Local variables and members of an unknown receiver are left out.