I want to create a program that is capeable of tracking the motion of an object through a field of vision by input of a webcam. the idea is that the webcam will eventually be mounted on a servo platform and will follow motion throughout a room. the application has recently been interfaced with a webcam however the most recent version on theweb has not. download it from http://craig552.tripod.com/vdo.zip .
it basicly works by comparing two images together, one frame and the next, at the moment its my friends finger waving across the screen. the images are compared by every 10th pixel, increasing this value slows the process but increases resoloution and vice-versa. at the moment the program marks the point of focus as the pixel with the greatest difference between the two images, i want it to make the point of focus the largest region of difference. if you run the application you can clearly see the shadow of the finger move across the motion window however i do not know how to make the computer recognise this. any help would be greatly appreciated. secondly it takes far too long to compare each frame, and annoyingly the process does not work when the pictureboxes are invisible, off the screen of covered by another control, is there another function out there that does the same job but doesnt take so long, again any help would be greatly appreciated.

craig