I have issue using OpenCV 3 tracking module for tracking. It behaves same, either I use interface class (cv::Tracker) or class with implementation (like cv::TrackerMedianFlo
I ran into the same problem and here's my solution: Open the file in opencv_contrib/modules/tracking/src/tracker.cpp and apply the following changes:
- if( isInit )
+ /*if( isInit )
{
return false;
}
+ */
I recompiled opencv3 and reinstalled it. That fixed it for me. I think they did not want people to reinitialize the tracker for some reason. I am not sure why?