My app use BASSWASAPI exclusive mode to play dsf in DoP mode in Windows, the app has a audio files list(with different dsd files in it) for continuous playing. When start playing, My code:
Bass.BASS_Init(...); // init "no sound" device
stream = BassDsd.BASS_DSD_StreamCreateFile("test.dsf", 0, 0, BASSFlag.BASS_DSD_DOP | BASSFlag.BASS_SAMPLE_FLOAT | BASSFlag.BASS_STREAM_DECODE, 0); // dsd audio in DoP mode
// get sample rate of the dsf file
BASS_CHANNELINFO ci;
ci = Bass.BASS_ChannelGetInfo(stream);
// Initializes a Wasapi device with specified sample rate
bool code = BassWasapi.BASS_WASAPI_Init(-1, ci.freq, ci.chans, BASSWASAPIInit.BASS_WASAPI_EXCLUSIVE, 0.4f, 0, _wasapiProc, user); // initialize the WASAPI output device
// Starts processing the current Wasapi device
code = BassWasapi.BASS_WASAPI_Start();
after the end of the first audio playing, my app respond to BASS_SYNC_END event in callback and start to play the next audio file, because the next audio file may have different sample rate, may be BassWasapi.BASS_WASAPI_Init should be called again? but I know from this forum that:
Unfortunately, that is isn't currently possible. A device can only be initialized once at a time in BASSWASAPI, the same as in BASS.
So, I try to call BassDsd.BASS_DSD_StreamCreateFile with another dsf file and BassWasapi.BASS_WASAPI_Start (without invoking BassWasapi.BASS_WASAPI_Init again) but no sound played.
what's the right way to continuously play different dsd audios in dop mode with WASAPI in windows ?