Changed ostringstream to ostream for new print_params and added the old
author1Hyena <hyena@hyena.net.ee>
Mon, 12 May 2014 20:01:44 +0000 (23:01 +0300)
committer1Hyena <hyena@hyena.net.ee>
Mon, 12 May 2014 20:01:44 +0000 (23:01 +0300)
version of print_params for backwards compatibility.

modules/flann/include/opencv2/flann/params.h

index 9ee5b1c..b40c39e 100644 (file)
@@ -79,14 +79,19 @@ T get_param(const IndexParams& params, std::string name)
     }
 }
 
-inline void print_params(const IndexParams& params, std::ostringstream& stream)
+inline void print_params(const IndexParams& params, std::ostream& stream)
 {
     IndexParams::const_iterator it;
+
     for(it=params.begin(); it!=params.end(); ++it) {
         stream << it->first << " : " << it->second << std::endl;
     }
 }
 
+inline void print_params(const IndexParams& params)
+{
+    print_params(params, std::cout);
+}
 
 }