CamShift Object Tracking (Composition by Peter)

Author: Peter
License: Creative Commons Attribution-NonCommercial-ShareAlike
Date: 2012.06.17
Compatibility: 10.6, 10.7
Required plugins:
CVDetection Plugin

This sample composition demonstrates the CamShift object tracking method.

In this example an initial Haar detection will be performed to define the tracking area which get passed over to the CamShift tracking. The tracking results are send through a Kalman filter to stabilize and predict the object movement (e.g. when the object is covered or only partly visible).The tracking results will be constantly re-evaluated according to a given threshold and the CamShift parameters automatically adjusted.

Still a lot of work in progress and plenty to optimize...

The attached CVDetection.plugin will need to be copied to (your user folder)/Library/Graphics/Quartz Composer Plug-Ins first

Blob Tracking Plugin (Carasuelo OpenCV 0.02a) (Composition by benoitlahoz)

Author: benoitlahoz
License: Creative Commons Attribution
Date: 2012.01.23
Compatibility: 10.6, 10.7
Required plugins:
Kineme GL


A new plugin in the Carasuelo OpenCV bundle : Blob Tracking. I implemented the cvblob library and externalized a lot of parameters to prepare the image, and to set the tracking accuracy. It's supposed to work with 10.6 and 10.7 in 32/64.

It outputs a structure of blobs with coordinates, angle, and tracking datas (has been active for x frames, has been inactive for x frames, exists since...).

An image output is available, with the possibility to output the intermediate image. It runs quite fast on my MBP 13" even when the frame isn't resized (640x480).

The 3 example comps (Blob Tracking, Contours and Presence) are documented. I have to work again on these 2 plugins to make them fit a CVImage class I wrote to simplify OpenCV use.

There's a big issue on the image dimensions, as I have a trouble with "special" width on input images, but in most case it should be ok for everyone. I'm working on it, but if someone has an idea...

Please tell me if it works for you !

I would be glad to see what you do with it.

OpenCV Blob Tracking (built for Kinect)

boumabouma's picture

Hi everyone,

I'm pretty new here, but this website/community has helped me a lot during my last project so I figured it's time to donate back :).

During this last project I was building an installation that used Kinect to detect your silhouette and hands, with which you could then control it. Like so:

The reason we used blob tracking is because Synapse was of no use to us due to the calibration every user has to go through. Please note that despite that, Synapse is more accurate and less heavy on your CPU :)

Long story short, I've built this plugin I wanted to share with you. It uses OpenCV and CvBlob to detect the blobs and outputs their position and size as a Structure. The minimum blob size and "movement threshold" (to smooth out glitchyness from the depth image) can be configured in QC.

However, I'm not very experienced with 'cmake', 'make' and install-name, so I've got some problems with including the openCV lib in the plugin. What still needs to be done is:

  • Build (cmake/make) the opencv and cvblob libraries for all required platforms (currently only Snow Leopard 64bits is included I think)
  • change the install-name of the libs so QC can find them from the plugin bundle.

I've been fiddling around with it, but no luck so far. If anyone could give me some pointers or help out that would be swell.

For now this means the plugin wont work without some extra work: placing the openCV and cvblob libraries in /usr/local/lib I've included the libs for 64bit Snow Leopard (in the zipfile in /usr-local/lib), simply copying them and the plugin to their designated place should do the trick. Obviously, building the libraries on your system will also work and you'll know for sure the libs are compatible.

Let me know what you think.

OpenCV Contours & Convex Hull 2 Structure plugin [DEPRECATED] (Composition by benoitlahoz)

Author: benoitlahoz
License: Public Domain
Date: 2011.10.19
Compatibility: 10.6, 10.7
Required plugins:
Kineme GL, Carasuelo OpenCV

[EDIT 20120124 - UPDATED - please see this post now :]

My first OpenCV plugin : it gets the contours and convex hulls present in the input image and output a structure of lines structure.

Very-alpha-version : it doesn't support for the moment a difference between the image size and the renderer size, but I'm working on it.

(BTW : i'm looking for a way to get the renderer size in pixels inside of my program... if someone knows how to do this :-/)

I didn't use the Canny filter which slows a lot the comp. I would be interested to know the performance on others machine than mine.


  • Track blobs [EDIT : done in the new plugin, see below]
  • Delaunay Triangulation
  • Output Image (arghhh)
  • ...

Thanks to Mirek OpenCV plugin that helped me to understand how to convert the input image to OpenCV. Thanks to Mehmet for the threshold CIKernel.

Works in 32/64 bits

motion detection

MikeP's picture

hi everybody,

does anyone know of a patch that does hand motion detection with quartz? I've tried cvtools-face-target.qtz which captures the face, but what do I need for it to capture and follow my hand? I'm very new to openCV.

thank you for any suggestions