title: Convert std::list to cv::Mat in C++ using OpenCV
body: <p>I'm trying to solve an equation system using SVD: <code>cv::SVD::solveZ(A, x);</code>, but <code>A</code> needs to be a Matrix. OpenCV doesn't offer any convertion of a <code>std::list</code> to <code>cv::Mat</code>. So my question is, whether there is a smart way to convert it without having to convert the <code>std::list</code> to a <code>std::vector</code> before.</p>
  
  <p>The Matrix <code>A</code> is a 3xN matrix. My list contains <code>N</code> <code>cv::Point3d</code> elements.</p>
  
  <p>My code looks something like this:</p>
  
  <pre><code>std::list&lt;cv::Point3d&gt; points; // length: N
  cv::Mat A = cv::Mat(points).reshape(1); // that's how I do it with a std::vector&lt;cv::Point3d&gt;
  cv::Mat x;
  cv::SVD::solveZ(A, x); // homogeneous linear equation system Ax = 0
  </code></pre>
  
  <p>If anybody has an idea about it, then please tell me.</p>