Combining marker tracking with optical flow


Here’s a very simple example of combining the usual marker detection algorithm with optical flow.

Basically we’d try to find the candidate marker first, and store its position. When the subsequent call of the method to find the marker fails, we switch to optical flow to predict where the marker has moved.

You can see the sample result here, blue outline indicates that the marker is detected using the usual method. Red indicates that it’s found using lucas kanade’s optical flow.

You can get the source code for this example here:


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s