title: Virtual Instrument App Recording Functionality With RemoteIO
body: <p>I'm developing a virtual instrument app for iOS and am trying to implement a recording function so that the app can record and playback the music the user makes with the instrument. I'm currently using the CocosDenshion sound engine (with a few of my own hacks involving fades etc) which is based on OpenAL. From my research on the net it seems I have two options:</p>
  
  <ol>
  <li>Keep a record of the user's inputs (ie. which notes were played at what volume) so that the app can recreate the sound (but this cannot be shared/emailed).</li>
  <li>Hack my own low-level sound engine using AudioUnits &amp; specifically RemoteIO so that I manually mix all the sounds and populate the final output buffer by hand and hence can save said buffer to a file. This will be able to be shared by email etc.</li>
  </ol>
  
  <p>I have implemented a RemoteIO callback for rendering the output buffer in the hope that it would give me previously played data in the buffer but alas the buffer is always all 00.</p>
  
  <p>So my question is: is there an easier way to sniff/listen to what my app is sending to the speakers than my option 2 above?</p>
  
  <p>Thanks in advance for your help!</p>