5

Lets assume that I have a video playing in canvas and I want to do some basic analysis on that video like edge detection, motion detection and general motion direction. How should I approach this problem? Can you point me in the right direction to some simple algorithms and general ideas on how to implement them?

I'm assuming that those kinds of things aren't often coded in JS, so I'm not hoping for anything working out of the box.

Any ideas?

2 Answers 2

3

Take a look at OpenCV library. Maybe you can then use Python with JavaScript. For that, see Python WebBrowserProgramming and Best way to integrate Python and JavaScript?.

Sign up to request clarification or add additional context in comments.

3 Comments

Okay, so I found exactly what I was looking in there - opencv.willowgarage.com/documentation/… and more specifically, the CalcGlobalOrientation() function. But a few questions - why do I have to pass a mask as a parameter, and what's "mhi – Motion history image"?
This post has some on this type of task.
Hi, links are gone, subdomain is dead
0

The way I have done detection is comparing one frame to the next. It is simple and effective but sometimes not very reliable. This project has some examples of motion detection algorithms: http://www.codeproject.com/KB/audio-video/Motion_Detection.aspx

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.