OpenCV can be used to track objects. As an example, let's build a system that tracks and follows a colored ball. OpenCV makes this activity amazingly simple; here are the steps:
Let's look specifically at the changes you need to make to
camera.py. The first three lines you add are as follows:
cv.Smooth(img,img,cv.CV_BLUR,3) hue_img = cv.CreateImage(cv.GetSize(img), 8, 3) cv.CvtColor(img,hue_img, cv.CV_BGR2HSV) ...