mirror of
https://github.com/opencv/opencv.git
synced 2024-11-29 13:47:32 +08:00
Merge pull request #3379 from akarsakov:gftt_empty_src
This commit is contained in:
commit
4a9cfbf806
@ -275,6 +275,12 @@ void cv::goodFeaturesToTrack( InputArray _image, OutputArray _corners,
|
||||
_mask, blockSize, useHarrisDetector, harrisK))
|
||||
|
||||
Mat image = _image.getMat(), eig, tmp;
|
||||
if (image.empty())
|
||||
{
|
||||
_corners.release();
|
||||
return;
|
||||
}
|
||||
|
||||
if( useHarrisDetector )
|
||||
cornerHarris( image, eig, blockSize, 3, harrisK );
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user