Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
Why sporadic corrupt data in real time audio capture
I try to read a few 10k samples from my sound card at 96k samples per second and then do some data analysis on them.
I have written a prog which captures one buffer via Windows Multimedia API and then stops recording.
When I analyze the buffer after capture I see occasionally jumps in the data: I capture a sine wave signal and I see phase jumps as if some samples would simply be missing. If this occurs it occurs always at the same sample position #2884 counted from the start i.e. at almost exactly 30 milliseconds after capture has started.
Can anybody give me a clue as to where my problem can come from and what I can do to avoid it?