Here is the list of all the Wave APIs that used for recording and playing audio in Windows simply:
The APIs are given by calling steps, refer MSDN for the detail.
waveInOpen Open the Wave device for recording. waveInPrepareHeader Prepare the Wave header for recording. waveInAddBuffer Add buffer waveInStart Start recording. Recorded data will be saved in a specifIEd buffer. waveInUnprepareHeader After finishing the record process, should un-prepare Wave header. waveInClose Close the recording device.
waveOutOpen Open the Wave device for playing. waveOutPrepareHeader Prepare the Wave header for playing. waveOutWrite Play the buffer. waveOutUnprepareHeader Un-prepare the Wave header. waveOutClose Close the playing device.
The most important tech on using there Api is the buffer and buffer size.