title: cvQueryFrame() returns grey frames
body: <p>cvQueryFrame() returns grey frames UNLESS I put a put a breakpoint at <code>cvQueryFrame(capture)</code>. The program just needs to hit the breakpoint once and then afterwards I get proper frames from the camera. I've tried delays, dummy frames, combination of the two but it just doesn't seem to work without that breakpoint. </p>
  
  <pre><code>cvNamedWindow("video", CV_WINDOW_AUTOSIZE);
  CvCapture *capture  = cvCaptureFromCAM(1);
  if (capture == NULL)
  {
      return -1;
  }
  
  Mat frame;
  for(int i = 0;i&lt;10;i++)
  {
      frame = cvQueryFrame(capture);
  }
  
  
  while(1)
  {
      try
      {
      frame = cvQueryFrame(capture);
      imshow("video", frame);
      char c = cvWaitKey(1);
      if(c == 33)
          break;
      }
  
      catch(Exception e)
      {
          break;
      }
  }
  cvReleaseCapture( &amp;capture);
  cvDestroyWindow( "video" );
  
  return 0;
  </code></pre>