How to calculate the average speed of monitored points?
Hi,
I'm tracking significant points in a video, representing moving objects. Currently, I have implemented the following:
- Open video
- Get next frame
- Convert color images to grayscale image
- Get significant points (using goodFeaturesToTrack)
- Get the next frame and his conversion
- Find significant points from the previous frame to the next (using calcOpticalFlowPyrLK)
Now, I want to perform the following:
- Calculate the velocity vector for each significant point
- Create a cluster of significant points according to their average velocity vectors (in other words, create a cluster for each moving object)
Is there any opencv method to perform that?
Thanks!