Last week I was working on adding the feature 'audio capturing' to
irrKlang. Basically this is recording audio data, using for example a microphone and some options to work with the data and to play it back again.
The most difficult part is to design a simple programming interface for this which is simple to use and which also works on all supported platforms and audio drivers. The implementation itself isn't that complicated. At least that was the plan :)
After I had finished the audio recording implementation in DirectSound8, I started to test it. The test program worked, and reported to have recorded some audio, but when I played it back nothing happened. Silence.
What was wrong? Had the driver enumerator selected a wrong device? Didn't the capture buffer copy thread work? Was there something wrong in the new pure-PCM-data audio source which was used to play back the recorded audio? There were so many possible points of failure, but most of them had been already tested out and I couldn't imagine what was wrong. So I debugged and investigated, and had nailed it down to the recording part. Somehow no recorded audio data came through. But I still didn't find the problem. Strange.
Then, someone gave me a call using skype. I accepted the call, but my conversational partner didn't hear me. D'oh! The microphone was broken. :)