You can use the Idirectsoundcapturebuffer8::getcaps method to get the size of the "capture buffer". Make sure that the dwsize member of the struct is initialized before using the DSCBCAPS structure as a parameter pass.
To get the format information when the buffer is created, you can call the Idirectsoundcapturebuffer8::getformat method. This method returns the format information in the form of a WAVEFORMATEX structure body.
Note: Your application can allow additional formatting information to exist WaveFormatEx the struct body when the GetFormat method is invoked for the first time using NULL as the Pwfxformat parameter. In this case, the DWORD pointed to by the Lpdwsizewritten parameter requires complete format information to receive the size of the structure.
To find out what an operation is currently being handled by a capture buffer, you can invoke the Idirectsoundcapturebuffer8::getstatus method. This method uses a combination of flags to populate a DWORD-type variable. These flags are used to indicate whether the buffer is currently busy capturing, if so, if so, if so, if so, if the loop, then the DSCBSTART_LOOPING flag is set when the Idirectsoundcapturebuffer8::start method is last called.
The Idirectsoundcapturebuffer8::getcurrentposition method returns the offset of the read pointer and the capture pointer within the buffer. The read pointer is at the end of the data that is currently fully captured to the buffer. The capture pointer is at the end of the data block that is currently being copied from the hardware. You can safely copy data from a buffer that is less than the offset of the read pointer.