I've set up a program that can record sounds from a microphone using a Wave-in header, and it stores the data inside the WaveInHDR, I believe, in the "lpstr" part of the header. I am planning to use this data to perform some analysis, such as determining the frequency of a sample.

What I was wondering was how I should access this data? I know that I can retrieve the length of the data I need in bytes via WaveInHDR.dwBufferLength, but how should it be read? As far as I know, lpstr is a pointer to a string, and what do I need to do with it to retrieve the integers for the PCM (I'm assuming that it is Pulse Code Modulation that is at the pointer)?

If anyone has any knowledge about this, or a better way for me to retrieve the frequency from a Wave-in header sample that'd be great. Thanks!