Current samplerate of Wasapi exclusive / KS / Asio playback

VB-Cable A & B, HIFI-Cable, ASIO Bridge
elviz
Posts: 5
Joined: Tue Nov 21, 2017 2:23 pm

Current samplerate of Wasapi exclusive / KS / Asio playback

Postby elviz » Wed Nov 29, 2017 5:23 pm

Hello,

Modern online audio services and players, such as Tidal, foobar2000, jRiver, support low level audio APIs. This means that the samplerate is not always the default samplerate defined in the audio device properties. Tidal does not even tell the current sample rate it outputs using Wasapi Exclusive and there are 88200hz and 96000hz mastered content in addition to 44100hz content. If i start a "masters" record in Tidal i need to randomly change the samplerate until the audio stops being buggy.

When using VB (hifi) Cable the audio capturing needs to somehow follow the samplerate of the playback software. This is not done in the current audio middleware software (an app between VB-cable and audio hardware). This is not a feature tho, its a problem. I am pretty sure many would like to support this feature if it was just available.

How is following of correct playback format in the capture side done with VB (hifi) Cable? I don't want resampling. The Asio Bridge application seems to always know the correct samplerate. Can i tap into the source of that information? How is this information obtained programmagically using for instance c++? Or maybe there is a registry entry that can be read? Maybe there is a DLL i could link to and API to get the information?

Vincent Burel
Site Admin
Posts: 460
Joined: Sun Jan 17, 2010 12:01 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby Vincent Burel » Fri Dec 01, 2017 9:49 am

yes, ASIO Bridge takes in account the HIFI-CABLE input sample rate to adjust the samplerate of the ASIO device.
this is made to use ASIO device to listen to an audio stream in bitperfect mode.

Voicemeeter is different, its virtual input is not master. We recommend to place the VAIO internal samplerate to 96 kHz and run Voicemeeter main stream in 96 kHz too (given by device selected as output A1)... Then you will have a possible upsampling on virtual input (if you player send 44.1 or 48 kHz sound), but this the better option (upsampling generates minimal distorsion).

elviz
Posts: 5
Joined: Tue Nov 21, 2017 2:23 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby elviz » Fri Dec 01, 2017 1:07 pm

Thanks for the suggestion. But like i said, sample rate conversion is not what i am looking for. I am putting a ton of effort to keep things bit perfect and i have tens of thousands of eur/usd invested in the audio system. And a lot of time invested in software development too. "Minimal distortion" is too much distortion in this system.

I am looking for to know the correct sample rate. Its cumbersome to change the sample rate manually if the input sample rate changes. Asio Bridge seems to know it, so it is possible. I just need to know How Asio Bridge software does this thing.

One possibility is to built my own virtual audio driver. A while ago it seemed like a overkill, just because that one number is so hard to get, but I don't know...seems like it is the only viable option left.

Vincent Burel
Site Admin
Posts: 460
Joined: Sun Jan 17, 2010 12:01 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby Vincent Burel » Wed Dec 06, 2017 6:33 am

you are not supposed to hear upscaling (note this is a regular operation also made in DAC).
so your better option is to place Voicemeeter and its VAIO in 96 kHz

elviz
Posts: 5
Joined: Tue Nov 21, 2017 2:23 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby elviz » Thu Dec 07, 2017 1:40 am

If i had that one number (samplerate) or any other number that be used to derive the current sample rate, then the problem would be solved. It is amazing how hard it is to get to know that one number. It is almost like it is purposely hidden from virtual audio applications.

One possibility is to run the Asio Bridge as a child process and grab the number from its window once every second or so. Maybe using kernel streaming capture (instead of wasapi exclusive) would tell the current samplerate? Maybe somehow capturing straight from the output device (not the recording device) would help?

Upsampling everything to 96khz just creates more problems and most likely decreases quality. If it is using windows default resampling routines, it is not going to be good. I certainly can hear differences between upsampling libraries and upsampling parameters. Most of them are not good enough. There are a few good algorithms tho if run with certain parameters. I know there are people who tell you that you cannot hear this and that, but i think upsampling is not one of those problem-free operations.

The whole point is to transport the audio bit perfect and then forward it to the DAC. The DAC can do its own high quality upsampling filtering, which is of course needed for normal operation. I'd like to know if this is kind of bit perfect transfer that requires detection of current samplerate is somehow possible with current version of VB-audio hifi cable or would it require further development of the hifi cable driver?

Vincent Burel
Site Admin
Posts: 460
Joined: Sun Jan 17, 2010 12:01 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby Vincent Burel » Thu Dec 07, 2017 7:02 am

elviz wrote:If i had that one number (samplerate) or any other number that be used to derive the current sample rate, then the problem would be solved.


Which problem ? if you place Voicemeeter VAIO in 96kHz and Voicemeeter main stream in 96 kHz (output A1 Device) you will have no audio problem from 44.1 to 96 kHz. As i said it is not possible to set Voicemeeter VAIO as master (like it is for HIFI-CABLE & ASIO Bridge).

Also if you open the Voicemeeter VAIO Control Panel, you will see the input samplerate (the one used by the application connected to it) and the VAIO will do the upscaling. The upscaling can be done by Windows /Kmixer if the player application does not use Voicemeeter virtual input in exclusive mode (wich is often not the case in fact).

Upsampling everything to 96khz just creates more problems and most likely decreases quality.


No, it's today a general operation done everywhere (video as well) and again upsamling is what your DAC does before generating analog signal. Make a blind test, it's very difficult to hear an audio upscaling, even a bad upscaling.

The whole point is to transport the audio bit perfect and then forward it to the DAC


Then, use direct connection from ASIO player to ASIO device, this is the only way to be sure about bit perfect playback.
HIFI-CABLE & ASIO Bridge warrant a bit perfect transport between HIFI-Cable input and ASIO output , but we don't know how the player send audio to HIFI Cable input (by kmixer or not).

All these questions are very complicated, that's also why we did Voicemeeter, to allow users to forget these points and stay focus on their audio production.

elviz
Posts: 5
Joined: Tue Nov 21, 2017 2:23 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby elviz » Thu Dec 07, 2017 4:47 pm

Vincent Burel wrote:
elviz wrote:If i had that one number (samplerate) or any other number that be used to derive the current sample rate, then the problem would be solved.


Which problem ?


The problem of having bitperfect audio with changing samplerates without manually changing the samplerate in my software. That is the only problem to solve. If i can use my bit perfect test with my DAC succesfully with subsequent 44.1, 88.2 and 96khz test signals, then the problem is solved (MSB The Analog Dac has in-built bitperfect test).

Vincent Burel wrote:No, it's today a general operation done everywhere (video as well) and again upsamling is what your DAC does before generating analog signal. Make a blind test, it's very difficult to hear an audio upscaling, even a bad upscaling.


Lets stop with the upsampling and ABX and all that jazz. Upsampling and resampling in general is something i am not going to do in this context. It does not solve the problem. nor it is any kind of standard. I'll rather have the manual samplerate selection. With manual selection bit perfect test works.

Vincent Burel wrote:Then, use direct connection from ASIO player to ASIO device, this is the only way to be sure about bit perfect playback.


My solution involves networked audio stream to a small linux device so it is not possible to just use ASIO player with ASIO device. And I want every audio application to work, not just one ASIO player. And i have all that already. Only thing missing is the solution to the small problem of manual sample rate selection which you have somehow solved.

Vincent Burel wrote:HIFI-CABLE & ASIO Bridge warrant a bit perfect transport between HIFI-Cable input and ASIO output , but we don't know how the player send audio to HIFI Cable input (by kmixer or not).


But you do know the information. See the image below.

Vincent Burel wrote:All these questions are very complicated, that's also why we did Voicemeeter, to allow users to forget these points and stay focus on their audio production.


Luckily the problem is not complicated, since you have already solved the problem. Now you just need to tell me if you are willing to tell me how you solved the problem. You can tell me the solution private too if you don't like other people to step into that swamp. I can write an NDA too if its some big secret. I can find how it was done myself too if i had the source code.

Voicemeeter is not solution to the problem. It's a solution to many problems and probably good for 99.9% of the situations. But not this one.

This is the number i want to obtain with my own c++ software (the circled part).
Image

Vincent Burel
Site Admin
Posts: 460
Joined: Sun Jan 17, 2010 12:01 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby Vincent Burel » Thu Dec 07, 2017 7:18 pm

ok, i think I got it:
you are developper and you want to know how to get by program:
the virtual audio input samplerate of our HIFI Cable displayed in ASIO Bridge ?

Sorry, this information is given by a private API.

elviz
Posts: 5
Joined: Tue Nov 21, 2017 2:23 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby elviz » Thu Dec 07, 2017 8:21 pm

Yes, exactly. I want to know that internal samplerate of the VB-Audio driver which seems to be visible Asio Bridge application. And yes, i am a developer.

Ok, how private is that API :)? Any chance to get partial support for it...pretty please... ;)?
Maybe a small chance that a future version would send windows message when sample rate changes or something like that? So you I could tap into some of the internal information without exposing your private API. Just a suggestion...

Vincent Burel
Site Admin
Posts: 460
Joined: Sun Jan 17, 2010 12:01 pm

Re: Current samplerate of Wasapi exclusive / KS / Asio playback

Postby Vincent Burel » Fri Dec 08, 2017 8:39 am

elviz wrote:Maybe a small chance that a future version would send windows message when sample rate changes or something like that? So you I could tap into some of the internal information without exposing your private API. Just a suggestion...


will think about...


Return to “VB-CABLE, The Virtual Audio Cable”

Who is online

Users browsing this forum: No registered users and 1 guest