• WANTED: Happy members who like to discuss audio and other topics related to our interest. Desire to learn and share knowledge of science required. There are many reviews of audio hardware and expert members to help answer your questions. Click here to have your audio equipment measured for free!

Beta Test: Multitone Loopback Analyzer software

OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
@bennetng just provided proof that the condition is indeed reversed in your code. That certainly explains a lot!

Yeah, the code was copied from DeltaWave, but the label for the setting was changed from Exclusive mode to Shared mode without changing the code.

WASAPI Exclusive can definitely do 24-bit. There is plenty of evidence with lots of applications that work just fine in 24-bit with WASAPI Exclusive (e.g. foobar).

I have the Windows drivers configured to 32 bits or 24 bits on Windows 8 and Windows 10. Either way, the only supported format reported is 16 bits in exclusive mode. I'll make the change to accept whatever bits the driver supports, so that others can test it with different Windows/drivers. In the current version, Multitone will reject anything less than 24 bits.
 

Sokel

Master Contributor
Joined
Sep 8, 2021
Messages
6,087
Likes
6,117
If the audio device supports hardware volume control (most of them do), then the Windows master volume control will still work even in WASAPI Exclusive mode, because changing the volume does not involve touching the bitstream. This is not a way to tell WASAPI Shared and WASAPI Exclusive apart unless your device relies on software volume control, which is atypical.
ASIO follows the settings of Multitone regardless the windows mixer setting,I suppose the same happens in WASAPI exclusive.
In shared mode the results,is this:


EDIT:I see what you mean now,different from ASIO,ok.
 
OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
I was a bit hesitated to post that screenshot but I suppose every .NET user should know the apps are by definition open-source. BTW, the software in my signature is also written in .NET and could be useful to identify if a file or a renderer is doing some strange stuff or not.

Not a problem. I had originally planned to obfuscate the code. The initial versions of DeltaWave were obfuscated and even digitally locked. Then I decided that I was just being too paranoid ;)
 

Blumlein 88

Grand Contributor
Forum Donor
Joined
Feb 23, 2016
Messages
20,747
Likes
37,560
I think this is a bit of a complication. On my development machine, I don't have any issues with WASAPI at 0dBFS -- the results are exactly the same for ASIO or for WASAPI. I think WASAPI is just generally to be avoided, if possible.
Sounds good to me. As I've said, I use ASIO when it is available and was only trying WASAPI to see if it worked right. It doesn't in all cases, and I learned you cannot count on WASAPI if you cannot force it into Exclusive mode.
 
OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
I feel it's slipping away, but I'm still trying for that raise... ;) Here's the updated version 1.0.24. Please check your WASAPI Exclusive setting, as the meaning has changed. If a driver supports less than 24 bits in exclusive mode, a warning will be displayed. Let me know if you can get it to work with more than 16 bits in exclusive mode!

Changes in 1.0.24

  • Fix & Change: WASAPI Shared mode setting renamed to WASAPI Exclusive. The meaning was previously swapped
  • Fix: Some ASIO drivers couldn’t be mixed with WASAPI or other ASIO drivers because each driver tried to open channels for input and output
1658518963720.png
 
Last edited:

edechamps

Addicted to Fun and Learning
Forum Donor
Joined
Nov 21, 2018
Messages
910
Likes
3,621
Location
London, United Kingdom
Either way, the only supported format reported is 16 bits in exclusive mode.

This is not normal and is almost certainly an issue with your code (assuming other apps can use WASAPI Exclusive in 24-bit just fine on the system you are testing this on).

IIRC some devices require 24-bit to be padded to 32 bits for 24-bit to work. Have you tried setting WAVEFORMATEX.wBitsPerSample to 32 but leave WAVEFORMATEXTENSIBLE.wValidBitsPerSample set to 24?
 

Blumlein 88

Grand Contributor
Forum Donor
Joined
Feb 23, 2016
Messages
20,747
Likes
37,560
It works in 16 bit which of course reduces the TD+N result with my setup by 7 or 8 db due to the higher noise floor.

When you hover over checking Exclusive mode it has the popup message that "This allows Windows to apply DSP and volume settings to playback" which was there for Shared mode. So you don't want it now.
 
OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
This is not normal and is almost certainly an issue with your code (assuming other apps can use WASAPI Exclusive in 24-bit just fine on the system you are testing this on).

IIRC some devices require 24-bit to be padded to 32 bits for 24-bit to work. Have you tried setting WAVEFORMATEX.wBitsPerSample to 32 but leave WAVEFORMATEXTENSIBLE.wValidBitsPerSample set to 24?

I get an error that only PCM and 32 bit float formats are supported when I try WaveFormatExtensible, so that's a no go. And no matter what other format I specify, I get back a device with support for 16 bits only. I'll keep digging.
 

Blumlein 88

Grand Contributor
Forum Donor
Joined
Feb 23, 2016
Messages
20,747
Likes
37,560
I've not found any software that supports 24 or 32 bit in Exclusive mode in playback with this Topping D10B. Maybe another device it would work.
 
OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
By the way, shared WASAPI mode isn't necessarily all bad :) Here's a digital loopback capture over a shared-mode WASAPI driver that I frequently use for testing. 100% BIT PERFECT (24 bit playback and capture using DeltaWave new recorder feature):

1658530011343.png
 

Blumlein 88

Grand Contributor
Forum Donor
Joined
Feb 23, 2016
Messages
20,747
Likes
37,560
By the way, shared WASAPI mode isn't necessarily all bad :) Here's a digital loopback capture over a shared-mode WASAPI driver that I frequently use for testing. 100% BIT PERFECT (24 bit playback and capture using DeltaWave new recorder feature):

View attachment 219835
I have not done so recently, but in the past confirmed Wasapi was bit perfect. I don't think I had a signal at 0 dbFS however. It looks like if no other APO's are invovled it is bit perfect until it gets limited above - .2 dbFS though I've not confirmed that yet.
 

Grooved

Addicted to Fun and Learning
Joined
Feb 26, 2021
Messages
679
Likes
441
I feel it's slipping away, but I'm still trying for that raise... ;) Here's the updated version 1.0.24. Please check your WASAPI Exclusive setting, as the meaning has changed. If a driver supports less than 24 bits in exclusive mode, a warning will be displayed. Let me know if you can get it to work with more than 16 bits in exclusive mode!

Changes in 1.0.24

  • Fix & Change: WASAPI Shared mode setting renamed to WASAPI Exclusive. The meaning was previously swapped
  • Fix: Some ASIO drivers couldn’t be mixed with WASAPI or other ASIO drivers because each driver tried to open channels for input and output
View attachment 219800
Hi @pkane , isn't it the "Microphone" input that is limited to 16bit? I just check and found on one of my computer that this input is at 16bit even if output are at 24bit.

I also got the same message while trying WASAPI with my old MOTU via ADAT.
What I don't understand is that with Multitone 1.0.23 and Shared mode unchecked, it was OK in 24bit. Now with 1.0.24 and Exclusive mode checked (should be the same than Shared mode unchecked), I get this message and can only measure at 16bit.

But, indeed, WASAPI Shared mode is also OK because if I uncheck Exclusive mode, the measurement is done at 24bit
 

Grooved

Addicted to Fun and Learning
Joined
Feb 26, 2021
Messages
679
Likes
441
I've not found any software that supports 24 or 32 bit in Exclusive mode in playback with this Topping D10B. Maybe another device it would work.
Hi @Blumlein 88 , I can test with the Tone2 Pro and see what happen as it shares the same ESS chip and XMOS chip (D10b has XU208 and Tone2 Pro the XU2016 but it should work the same way with the computer)
 
OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
Hi @pkane , isn't it the "Microphone" input that is limited to 16bit? I just check and found on one of my computer that this input is at 16bit even if output are at 24bit.

I also got the same message while trying WASAPI with my old MOTU via ADAT.
What I don't understand is that with Multitone 1.0.23 and Shared mode unchecked, it was OK in 24bit. Now with 1.0.24 and Exclusive mode checked (should be the same than Shared mode unchecked), I get this message and can only measure at 16bit.

But, indeed, WASAPI Shared mode is also OK because if I uncheck Exclusive mode, the measurement is done at 24bit

Right, exclusive mode setting was previously mislabeled. If you did try to use it before, it would generate an error because number of bits was below 24, which was the minimum Multitone expected. So prior to version .24, exclusive mode simply wouldn't work due to 16 bit limitation. Now it will work in 16 bits if you let it, but I doubt there's a great need for this :)

I'm still investigating how I can get more than 16 bits in exclusive mode. For some reason, the audio library I'm using isn't giving me anything above 16 bits in exclusive mode. I'll continue looking.

To keep measuring the way you've been doing it, simply uncheck the WASAPI Exclusive option in settings.
 
Last edited:

Grooved

Addicted to Fun and Learning
Joined
Feb 26, 2021
Messages
679
Likes
441
Right, exclusive mode setting was previously mislabeled. If you did try to use it before, it would generate an error because number of bits was below 24, which was the minimum Multitone expected. So prior to version .24, exclusive mode simply wouldn't work due to 16 bit limitation. Now it will work in 16 bits if you let it, but I doubt there's a great need for this :)

I'm still investigating how I can get more than 16 bits in exclusive mode. For some reason, the audio library I'm using isn't giving me anything above 16 bits in exclusive mode. I'll continue looking.

To keep measuring the way you've been doing it, simply uncheck the WASAPI Exclusive option in settings.
But it was working in .23 with my old MOTU, and at 24bit (I had the same result than now with Exclusive unchecked), so it would more mean that in .23 or older, the setting was the opposite of what we thought: unchecked "Shared mode" was actually setting "Shared mode", and when checked, instead of setting "Shared mode", it setting "Exclusive mode" and would explain why this one was not working for me (just not working at all, while now with .24, it display the message that it can only work in 16bit)

Another strange thing, but not due to Multitone I think: with this old MOTU, Windows let me only choose between 44.1/48 and 88.2/96 if I first change it in the driver panel, but with any sample rate, Windows only allow 16bit. It's with the WDM driver, but it works at 24bit with ASIO.

Now, since Multitone also offers 16bit only in Exclusive mode for this device, but 24bit in Shared mode (I get a better measurement), maybe the problem comes from here.
I also tried this thing: in Windows sound settings, I unchecked 44.1kHz on the inputs (can't do that on the ouputs), then Multitone will show this output as 48/32, even if the device is still set at 44.1 (and the outputs are shown at 44.1/32 in Multitone)
So this settings in Windows are doing something on what Mutltione will show)
 
OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
But it was working in .23 with my old MOTU, and at 24bit (I had the same result than now with Exclusive unchecked), so it would more mean that in .23 or older, the setting was the opposite of what we thought: unchecked "Shared mode" was actually setting "Shared mode", and when checked, instead of setting "Shared mode", it setting "Exclusive mode" and would explain why this one was not working for me (just not working at all, while now with .24, it display the message that it can only work in 16bit)

Suffice it to say that the setting was the opposite of what the label said in .23. The label is correct now in .24.
 

bennetng

Major Contributor
Joined
Nov 15, 2017
Messages
1,634
Likes
1,693
For some reason, the audio library I'm using isn't giving me anything above 16 bits in exclusive mode.
The same library that misread flac files in older versions of DeltaWave?
It does not seem to be able to decode mp3 in floating point as well, which may induce clipping.
In the case of 24-bit support, if it is related to what @edechamps mentioned, I'd try to look at how the library handles nBlockAlign and other relevant WaveFormat(Ex(tensible)) fields, or use your own code instead of someone else's. Ideally the software should allow users to choose between Event and Push mode to improve compatibility.

@Blumlein 88 I don't have any Topping stuff, but if for some reasons none of your app can get exclusive mode to work, try uninstall the Topping driver (disconnect the DAC, then open Device Manager, then go to View > Show hidden devices > find the Topping device > right click > uninstall > check delete driver software. This should force the Topping to use standard Microsoft driver and may help pkane to debug things.
 
Last edited:

Blumlein 88

Grand Contributor
Forum Donor
Joined
Feb 23, 2016
Messages
20,747
Likes
37,560
The same library that misread flac files in older versions of DeltaWave?
It does not seem to be able to decode mp3 in floating point as well, which may induce clipping.
In the case of 24-bit support, if it is related to what @edechamps mentioned, I'd try to look at how the library handles nBlockAlign and other relevant WaveFormat(Ex(tensible)) fields, or use your own code instead of someone else's. Ideally the software should allow users to choose between Event and Push mode to improve compatibility.

@Blumlein 88 I don't have any Topping stuff, but if for some reasons none of your app can get exclusive mode to work, try uninstall the Topping driver (disconnect the DAC, then open Device Manager, then go to View > Show hidden devices > find the Topping device > right click > uninstall > check delete driver software. This should force the Topping to use standard Microsoft driver and may help pkane to debug things.
Okay. I'm traveling over the weekend so it will be next week, but I'll give that a try.
 

Sokel

Master Contributor
Joined
Sep 8, 2021
Messages
6,087
Likes
6,117
Hi @Blumlein 88 , I can test with the Tone2 Pro and see what happen as it shares the same ESS chip and XMOS chip (D10b has XU208 and Tone2 Pro the XU2016 but it should work the same way with the computer)
Is that what exclusive is?
It works fine with 32bit,I tested all sample rates and bit-depths.


32bit.PNG
 
OP
pkane

pkane

Master Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
5,699
Likes
10,377
Location
North-East
The same library that misread flac files in older versions of DeltaWave?
It does not seem to be able to decode mp3 in floating point as well, which may induce clipping.
In the case of 24-bit support, if it is related to what @edechamps mentioned, I'd try to look at how the library handles nBlockAlign and other relevant WaveFormat(Ex(tensible)) fields, or use your own code instead of someone else's. Ideally the software should allow users to choose between Event and Push mode to improve compatibility.

@Blumlein 88 I don't have any Topping stuff, but if for some reasons none of your app can get exclusive mode to work, try uninstall the Topping driver (disconnect the DAC, then open Device Manager, then go to View > Show hidden devices > find the Topping device > right click > uninstall > check delete driver software. This should force the Topping to use standard Microsoft driver and may help pkane to debug things.
Yes, the same, overall library, but FLAC reader was a separate component written by someone else, and I needed to patch it to fix that bug.

I’ve stepped through the code in the library and it indeed finds only one format that’s supported, and that’s always 16 bits for some reason. Turns out the library code is doing exactly what I was doing in my own code: tries to open the device with various bit rates and formats until it finds one that works. This didn't help me find any format other than 16 bits and the library is doing the same thing.

I'm certainly not going to rewrite the audio library just to get the exclusive mode working with more bits. I'll continue looking, but so far I've found no solution for this issue.
 
Top Bottom