Re: movement vector from video



Hi.

Take a look at OpenCV. It has some examples and one of them (lkdemo)
might help you with your problem. It may be overkill for this but it
should provide a robust solution for this.

So, what you need to do:

1) Install OpenCV (http://sourceforge.net/projects/opencvlibrary/)
On Ubuntu/Debian you can do like this: apt-get install libcv-dev
libcvaux-dev libhighgui-dev libcv1 libcvaux1 libhighgui1 opencv-doc

2) Go to the python examples (it exists as a C application as well but
using python means that you don't have to compile anything to try it
out) and run the lkdemo application.
On Ubuntu/Debian do: cd /usr/share/doc/opencv-doc/examples/python and
run ./lkdemo.py

Oh, by the way, you need to have a webcam for this.

You should get a window with the output of your webcam.

Click on some places in the image and then move stuff around... the
points will follow the objects.

So my idea is: you could create a program that generates a bunch of
points all over the image at some specific interval and keep track of
where points are created. In the next iteration you could see where
the points have moved just before you re-generate the points and
accumulate an average movement of the scene.

Hope this helps.

Regards, Stefan Freyr.

One of the examples that comes with the library is a
On Apr 10, 4:59 pm, "alp.guneysel" <alp.guney...@xxxxxxxxx> wrote:
hi,

i need to do a project something like in this video.http://www.youtube.com/watch?v=y6izXII54Qc(newsbreaker game)

this is a project they are screening on theaters before the movie, and
the audience participates with the game (simple arkanoid game) via
changing their position or their hands position.

i've accomplished this with tracking changing blobs, and if the blobs
are on the right half side of the screen, i would consider a right
move, if they are on the left side of the screen, i would consider it
a left move. however, this would be a cheat and not the best way to do
it.

any suggestions?

.