Merge pull request #1000 from ivan-korolev:fix_sift_bug_2892
This commit is contained in:
commit
308c7f5f6e
@ -774,9 +774,6 @@ void SIFT::operator()(InputArray _image, InputArray _mask,
|
|||||||
findScaleSpaceExtrema(gpyr, dogpyr, keypoints);
|
findScaleSpaceExtrema(gpyr, dogpyr, keypoints);
|
||||||
KeyPointsFilter::removeDuplicated( keypoints );
|
KeyPointsFilter::removeDuplicated( keypoints );
|
||||||
|
|
||||||
if( !mask.empty() )
|
|
||||||
KeyPointsFilter::runByPixelsMask( keypoints, mask );
|
|
||||||
|
|
||||||
if( nfeatures > 0 )
|
if( nfeatures > 0 )
|
||||||
KeyPointsFilter::retainBest(keypoints, nfeatures);
|
KeyPointsFilter::retainBest(keypoints, nfeatures);
|
||||||
//t = (double)getTickCount() - t;
|
//t = (double)getTickCount() - t;
|
||||||
@ -791,6 +788,9 @@ void SIFT::operator()(InputArray _image, InputArray _mask,
|
|||||||
kpt.pt *= scale;
|
kpt.pt *= scale;
|
||||||
kpt.size *= scale;
|
kpt.size *= scale;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( !mask.empty() )
|
||||||
|
KeyPointsFilter::runByPixelsMask( keypoints, mask );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user