Author Topic: Get sound data from an apps that uses the Windows' mixer  (Read 656 times)

Kokonut

  • Guest
Hello All,
" A 'loopback' device captures Windows' mixer output for the associated output device, ie. the sound from all apps that are using the device. "

So I did capture this "looopback" device, it works very well and I have the total sound stream of all the applications running on the computer.

But I would like to capture ONLY one application data stream and of course choose the application I want the sound stream from.

For instance , I need to ear, on the speakers, the  "systems sounds" and a "VLC movie", but I want record only the "VLC data sound stream"
How I can separate the two signals ? As you know, the windows' mixer gives all together in a single stream . . .

Is it possible and how ?

Best Regards
Kokonut

Ian @ un4seen

  • Administrator
  • Posts: 24792
As far as I know, the only way to achieve that is by using a virtual device, eg. Virtual Audio Cable. You would set VLC to play on it and set your app to record from it.

Kokonut

  • Guest
Thank you Ian.

       As my application is written with Bass, do you how I can interface Bass function libraries with Virtual Audio Cable software ?
       I've heard of that piece of software, but so far I've never used it.

Have a nice Christmas.

Best Regards
Kokonut

Ian @ un4seen

  • Administrator
  • Posts: 24792
You would use BASS's recording functions to capture the sound from the virtual device, much like you did with the loopback device. The only change would be the device number in the BASS_RecordInit call, ie. you would use the virtual device's number there (you can find that by using BASS_RecordGetDeviceInfo to enumerate the available devices).

saga

  • Posts: 2634
As far as I know, the only way to achieve that is by using a virtual device, eg. Virtual Audio Cable. You would set VLC to play on it and set your app to record from it.
FYI, there has been an update to Windows 10 that allows recording the loopback from specific applications (or more precisely, from a specific process ID). It also allows to do the opposite, i.e. recording from all applications but a specific one: https://learn.microsoft.com/en-us/samples/microsoft/windows-classic-samples/applicationloopbackaudio-sample/
Microsoft is a bit unclear about the minimum requirements, official documents say that this feature was introduced with Windows 11 but it is also available in the latest Windows 10 update, and some sources suggest that it was available as early as Windows 10 version 2004 (April 2020 update).