What is XAudio API, and how would I use it?

+
Hi all, newb here. Lovin' Cyberpunk 2077! (Well, mostly ... ) I have a question that I have not found an answer for with multiple Google searches. In the Sound section of the Settings Menu, there is a switch labeled "Use XAudio API." What is XAudio API in relation to this game, and under what circumstances would I want to use it?
 
Last edited by a moderator:

"WHAT IS XAUDIO API, AND HOW WOULD I USE IT?"

XAudio2 is a low-level audio API that provides signal processing and mixing foundation for developing high performance audio engines for games.

Source, Microsoft.


People also ask

What is an API in simple terms?

API stands for application programming interface. It allows two applications to communicate with one another to access data. Every action you take on your phone, like sending a direct message or checking the score of the baseball game, uses an API to access and deliver that information.

17 Apr 2019
 

"WHAT IS XAUDIO API, AND HOW WOULD I USE IT?"

XAudio2 is a low-level audio API that provides signal processing and mixing foundation for developing high performance audio engines for games.

Source, Microsoft.


People also ask​

What is an API in simple terms?

API stands for application programming interface. It allows two applications to communicate with one another to access data. Every action you take on your phone, like sending a direct message or checking the score of the baseball game, uses an API to access and deliver that information.

17 Apr 2019
Thanks for copy/pasting the first thing you found on google even after OP told you he already googled it extensively, but what he wanted to know, and what everyone googling this to this very day wants to know (got here from a page 1 result on google myself), is what is the xaudio API setting in relation to this game, and why would one would choose it over the native API?

Like, I can google "Dirext12" and "Vulkan" and find they're both graphical APIs, and what API stands for, etc... but that doesn't really answer the question of how those affect an individual game, which seems to be what OP is actually asking, when you read the words he wrote.

And like OP, I've found there is no answer anywhere on the internet, because evidently nobody fucking knows. It's just a setting in the options menu of a hundred million whatever dollar AAA game, and nobody knows what it actually does or what it's use-case is (compatibility or stability option for certain systems; better quality than native; or something else?). Just bonkers.
 
Last edited:
@JCDenton_2052 - Hope this reply answers your question.
@replythrowaway - I agree lots of people either speed read or don't read to fully comprehend what is being asked.

The very short answer, turn Xaudio2 ON

Discussion:
As you already know its a low level API and in this specific case it handles direct access to the sound cards processing capabilities. A long time ago MS-DOS 4.11, we had to settle for sound coming out from a mono speaker that was 2", stuck inside the computer case that sounded like a busted speaker, but WOW! My computer had sound effects! The process to getting that sound out, was writing a program that will interface with the motherboard to specify frequency and durations, no volume control. Your boss better not be around or they will definitely know you are not working. Anyways, that program can be considered a low level API. Then came Windows 3.0-3.1, and sound boards were becoming more ubiquitous. Now games can can have some fancy sound effects. In order for you to enjoy that sound, you needed to have the drivers installed (check) and the game either support SoundBlaster (API) audio directly or windows sound compatible. If the GAME supported SoundBlaster, it can access the sound card directly bypassing any processor interactions, no lag. However, if it did not, you had to settle for Windows sound processing which did involve the processor and you would get very "laggy" sound and sometimes it just would not work. Microsoft seeing that it will be left in the dust if it did not get its OS sound subsystem up to par when it comes to games and loosing money since they would have to pay royalties once SoundBlaster wised up, created DirectX. DirectX provided a universal way for Game developers to directly access the computer hardware, in this case the soundcard's abilities without using the processor. Now, any game developer can use DirectX and get sound out from their games without having to require SoundBlaster specific API. Over the years DirectX has progressed to include new features/options that hardware developers have added to their boards, thus requiring Microsoft to make revisions to DirectX.

So know we are at DirectX 12 and there are limitations to the sound system. To address some of those, XAudio2 comes into play. Notice the 'X'? Guess where it originates from... You got it, DirectX. XAudio2 includes more features that Game developers can utilize. However, your hardware must have those features built in to utilize them and/or other features of XAudio2 are just virtualizations. Just keep in mind, the game must call out those features. Since Cyberpunk does have an option for it, I assume that they are utilizing some of those features that are not available in DirectX 11 or 12.
Below is a link to Microsoft's XAudio2, intro. Scroll to the bottom to the heading "When to USE XAudio2".

 
Top Bottom