title: how to use vector<Point2f> in c++
body: <p>I want to use this code(<a href="http://docs.opencv.org/2.4/modules/calib3d/doc/camera_calibration_and_3d_reconstruction.html" rel="nofollow noreferrer">source</a>) to find fundamental matrix in opencv.</p>
  
  <pre><code>int point_count = 100;
      vector&lt;Point2f&gt; points1(point_count);
      vector&lt;Point2f&gt; points2(point_count);
  
      // initialize the points here ... */
      for( int i = 0; i &lt; point_count; i++ )
      {
          points1[i] = ...;
          points2[i] = ...;
      }
  
      Mat fundamental_matrix =
       findFundamentalMat(points1, points2, FM_RANSAC, 3, 0.99);
  </code></pre>
  
  <p>but I don't know how to initialise points1, points2 in for loop.
  I have tried using:</p>
  
  <pre><code>points1[i] = 10.0;
  points1[i] = (10.0, 20.0);
  points1[i] = {10.0, 20.0};
  </code></pre>
  
  <p>but getting error like this</p>
  
  <pre><code>no match for ‘operator=’ (operand types are ‘cv::Point_&lt;float&gt;’ and ‘double’)
  </code></pre>
  
  <p>in all of them.</p>