Mindstorms and OpenCV used in Face Tracking

Post your NXJ projects, project ideas, etc here!

Moderators: imaqine, 99jonathan, roger

New User
Posts: 17
Joined: Sat Jun 04, 2011 2:55 am

Mindstorms and OpenCV used in Face Tracking

Postby Aravind » Thu Sep 01, 2011 10:01 pm


This is a project that I built that uses OpenCV along with LeJOS Mindstorms. Basically there is a webcam mounted on a tilting arm, which in turn is on a rotating platform, so the camera has four degrees of freedom. They are all powered by the NXT motors. The camera captures data and sends it to a computer, where a Java program(with OpenCV) tracks the head. If the head moves away from the center of the video frame either vertically or horizontally, the Java Program sends Bluetooth commands to the NXT to either tilt the camera forwards or backwards, or rotate the camera CW or CCW. In this way the face is always at the center of the video frame. This is a fun project which can be used to properly center the camera without the need for a cameraman when blogging, etc. Here is a video of the project in action: http://www.youtube.com/watch?v=6i4vjW7E74w
You can get the source code off here: http://homebrewcode.blogspot.com/2011/0 ... psnxt.html

Any suggestions on how to improve the project will be greatly appreciated!


Return to “NXJ Projects”

Who is online

Users browsing this forum: No registered users and 1 guest