Slicing a video into several video planes with a "weighted" effect

Javi Riverola's icon

I would like to take a video source and slicing it in a grid of different video planes, potentially dynamic so its possible to select rows and columns ( NXM : 3x3, 5x5, 3x1, 10x10, ... ).

I would like to have different options for slicing it, like plain slices, but also would be very interested in achieving an effect like the one in the picture ( what you see is that certain elements like the eyes and nose are more weighted, and the slices are calculated to give more weight to those elements, I guess that theres several options, manually specifiying the areas on the video of more weihght or detecting those via CV.JIT ? )

I was thinking about combining gl.multiple with video planes, manipulating texture coordinates, and using CV jit to detect the areas of the video. But my skills are not at the level of executing this properly.

All help is welcome thanks

Rob Ramirez's icon

Fun one!

Here's my take utilizing cv.jit.faces and some jit.gl.pix resampling


face-gridder.maxpat
Max Patch