I'm writing a real-time audio application that runs a stream in exclusive mode. In order to properly present data to the device, it needs to arrive in a format that isn't of my own choosing. All of my audio processing is done with floating point samples before being sent to the device, and the device's wave format might not be (and probably isn't) set to WAVE_FORMAT_IEEE_FLOAT
- for example, it might be WAVE_FORMAT_EXTENSIBLE
or WAVE_FORMAT_PCM
.
Is there an API that makes it easy to convert between one wave format (floating point) and another (the device's format)?