I am trying to use calcOpticalFlowPyrLK for feature tracking. Function is used as follows
TermCriteria termcrit(CV_TERMCRIT_ITER|CV_TERMCRIT_EPS,20,0.03);
Size winSize(31,31);
vector < uchar > status;
vector < float > err;
calcOpticalFlowPyrLK(prevGray, gray, point[0], point[1], status, err, winSize, 3, termcrit, 0, 0, 0.001);
All the parameter are correct. In point[0] there are already given set of points. But while i try to execute the program it gives following error. I am using Visual C++ 2010.
.....................................
First-chance exception at 0x74c426df (msvcr100.dll) in GFFER.exe: 0xC0000005: Access violation writing location 0x058fe000. Unhandled exception at 0x74c426df (msvcr100.dll) in GFFER.exe: 0xC0000005: Access violation writing location 0x058fe000.
.....................................
Do you have any idea how can i resolve this problem.
Thanks in advance!!