Example #1
0
void CRecoImage::FindDescriptors(SIFT& SIFTDetector)
{
	Mat image; 
	if(!this->LoadImg(image))
	{
		CRecoLogMgr::Instance()->WriteLog("CRecoImage -> FindFeatures !FAILURE! Could not open or find the image. Path is: " + this->GetFullImagePath()); 
	}
	
	SIFTDetector.detect(image, this->_KeyPoints);
	SIFTDetector.compute(image, this->_KeyPoints, this->_Descriptors);
}
Example #2
0
Mat Pyramids::extractFeatures(const Mat &im, vector<KeyPoint> &keypoints, int step)
{
	Mat features;
	SIFT dec;
	if (step <= 0)
		dec.detect(im, keypoints);
	else
		keypoints = extractDenseKeypoints(im, step);
	dec.compute(im, keypoints, features);
	return features;
}