title: How to feed frames into motion detector object AForge.net?
body: <p>I'm trying to get a simple motion detection program working using the AForge.net framework. On the AForge website is an example of such a program, but it's quite vague:</p>
  
  <pre><code>    // create motion detector
  MotionDetector detector = new MotionDetector(
      new SimpleBackgroundModelingDetector( ),
      new MotionAreaHighlighting( ) );
  
  // continuously feed video frames to motion detector
  while ( ... )
  {
      // process new video frame and check motion level
      if ( detector.ProcessFrame( videoFrame ) &gt; 0.02 )
      {
          // ring alarm or do something else
      }
  }
  </code></pre>
  
  <p>I need some help with the condition for the while loop, as I can't find a solution for how to feed video frames into the MotionDetector object. </p>
  
  <p>Thanks.</p>