title: How to get video frame from AVCaptureOutput face detect metadata objects
body: <p>I am able to get face detection from a video stream working following the StacheCam example from <a href="https://developer.apple.com/devcenter/download.action?path=/wwdc_2012/wwdc_2012_sample_code/wwdc_2012_session_code.dmg" rel="nofollow">WWDC 2012</a>.</p>
  
  <p>However, I cannot get the corresponding image frame.  I have both </p>
  
  <pre><code>captureOutput:didOutputSampleBuffer:fromConnection:
  </code></pre>
  
  <p>and</p>
  
  <pre><code>captureOutput:didOutputMetadataObjects:fromConnection:
  </code></pre>
  
  <p>firing and giving me data but both are asynchronous calls and I don't see a way to accurately sync a facebox with a frame.  </p>