mirror of
https://github.com/opencv/opencv.git
synced 2025-01-18 22:44:02 +08:00
fixed bug in gpu::PyrLKOpticalFlow::dense
vector index out of range
This commit is contained in:
parent
6484732509
commit
a0be7b57f5
@ -200,6 +200,9 @@ void cv::gpu::PyrLKOpticalFlow::dense(const GpuMat& prevImg, const GpuMat& nextI
|
||||
pyrDown(nextPyr_[level - 1], nextPyr_[level]);
|
||||
}
|
||||
|
||||
uPyr_.resize(2);
|
||||
vPyr_.resize(2);
|
||||
|
||||
ensureSizeIsEnough(prevImg.size(), CV_32FC1, uPyr_[0]);
|
||||
ensureSizeIsEnough(prevImg.size(), CV_32FC1, vPyr_[0]);
|
||||
ensureSizeIsEnough(prevImg.size(), CV_32FC1, uPyr_[1]);
|
||||
|
Loading…
Reference in New Issue
Block a user