Bug fix in flann wrapper
authorMarius Muja <no@email>
Thu, 6 Jan 2011 05:46:08 +0000 (05:46 +0000)
committerMarius Muja <no@email>
Thu, 6 Jan 2011 05:46:08 +0000 (05:46 +0000)
modules/flann/include/opencv2/flann/flann.hpp

index 0a9f38f..aecb584 100644 (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();