Forums > Jitter

face detection as a trigger

Aug 19 2009 | 11:00 am

I’m a student just starting with Jitter, and i desperately need some help.. I’m trying to use face detection to then trigger an effect (i.e distortion of users image, like data moshing or something similar), then when the user moves away from the camera the effect stops and returns to normal. It’s probably incredibly simple but have been confused for a few days on getting the idea together, I have come across patches for both face detection and for creating numerous effects with live video but am having problems connecting the two – any help or advice would be great….


Aug 19 2009 | 4:12 pm

Check out the [cv.jit.faces] object for face detection/tracking. Here’s a simple patch using it:

— Pasted Max Patch, click to expand. —

In this example I use [jit.streak], but any effect could be used. The main idea is that [cv.jit.faces] is queried for the number of faces in an image and then that data is used to decide how much of/ if an effect is applied to the original image. Hope this helps!


Aug 20 2009 | 12:50 pm

Brilliant! Thank you so much for your help – this gets me started, and just what I was looking for. Perfect.


May 31 2011 | 2:41 pm

Sorry for bumping this but how do I run the patcher described above?

I want to do something similar. I would like to have Jitter render a black screen over a movieclip when there is no face detected but I have no idea how to achieve this with Max/msp/Jitter. However, it is the only software package that is able to run opencv on my cam.

Jun 01 2011 | 7:30 am

Hello, could someone please explain this to me?

Jun 02 2011 | 11:48 am

I just want to see the example of above or be provided with a direction on how I can turn down the brightness of a movie clip when no face is detected.

Jun 03 2011 | 1:46 pm

The patcher does not seem to work (error 9505) but thank you so much for the link!

Jun 04 2011 | 6:10 pm

works fine here. did you make sure you copied everything including

— Pasted Max Patch, click to expand. —
Jul 19 2015 | 3:21 pm

New to Max. Just tried this patch on a trial version of Max 7, Macbook Pro with and Intel chip running Yosemite, but I’m not getting a video signal on the patch, just black boxes. Other face tracking patches I’ve tried also seem unable to access the camera. Anyone have any ideas what the problem might be?

Jul 20 2015 | 5:38 am

Hi Zeesy,

Do the cv.jit.faces objects appear as the same colour as the jit.rgb2luma and jit.qt.grab objects? If not, you will need to download the cv.jit object collection.

I’m running the same system as you and the patch works fine, but I have the cv.jit collection.

Jul 20 2015 | 5:36 pm

cv.jit lib here:

then install: harddrive>users>shared>Max7>Packages (just drop the whole folder in here)

Jul 22 2015 | 4:42 pm

the latest cv.jit library (updated for 64 bit and max 7) is found here, along with some instructional videos:

Viewing 13 posts - 1 through 13 (of 13 total)

Forums > Jitter