Bug fix in flann wrapper

This commit is contained in:
Marius Muja 2011-01-06 05:46:08 +00:00
parent 9bf80fb209
commit 204c54291d

View File

@ -104,7 +104,7 @@ Index_<T>::Index_(const Mat& dataset, const IndexParams& params)
{
CV_Assert(dataset.type() == CvType<T>::type());
CV_Assert(dataset.isContinuous());
::cvflann::Matrix<float> m_dataset((T*)dataset.ptr<T>(0), dataset.rows, dataset.cols);
::cvflann::Matrix<T> m_dataset((T*)dataset.ptr<T>(0), dataset.rows, dataset.cols);
nnIndex = new ::cvflann::Index<T>(m_dataset, params);
nnIndex->buildIndex();