Code Monkey home page Code Monkey logo

Comments (6)

cascardian avatar cascardian commented on May 13, 2024 3

Thank you for the suggestion. I had done that, but waveOut had always resulted in more crackling for me, no matter my skew and latency finagling. But it's actually fully gone now. The only relevant thing I've changed is finally not using Realtek's driver (I use the onboard ALC1220 chip) anymore, and just going with Windows 10's basic driver. Man, such a better experience. I can even set lower latencies now, no need to even configure any skew.

That clears up my issue. Should this still stay up in case anyone would still like to implement a default device selection for the other backends?

from bsnes.

Sintendo avatar Sintendo commented on May 13, 2024

The WASAPI and XAudio 2.1 drivers do indeed not allow you to select the 'Default' audio device right now.

Do you have a specific reason for using the XAudio 2.1 driver? If not, may I suggest using the waveOut driver as an alternative?

from bsnes.

IPeluchito avatar IPeluchito commented on May 13, 2024

XAudio 2.1 has better effects and sound quality than waveOut ...

from bsnes.

Screwtapello avatar Screwtapello commented on May 13, 2024

I don't know why the WASAPI and XAudio2 drivers require a specific device to be selected, but it seems like a sensible thing to have. I would take a PR adding this feature.

from bsnes.

Sintendo avatar Sintendo commented on May 13, 2024

Part of the problem is that we're currently targeting XAudio 2.1, which cannot select the default audio output device. I think this version was chosen for compatibility with older Windows versions, but I don't recall the specifics. In any case, we'll need to move to at least 2.8 in order to support this.

I haven't looked into WASAPI, so I can't comment on what's needed there.

from bsnes.

Screwtapello avatar Screwtapello commented on May 13, 2024

My recollection is that XAudio 2.8 required Windows 8, while XAudio 2.7 could be installed on any OS version (including Windows 8) with the DirectX installer, so that made 2.7 the correct version to use. Apparently XAudio 2.9 now comes with Windows 10, and there's a redistributable version that works back to Win7, but it needs to be shipped with the executable and probably requires the MSVC toolchain... ugh. I'm also a little worried whether mingw32-w64's headers support later versions of the XAudio2 API, but I see mentions of XAudio 2.9 in their source tree so I assume it'll work eventually if it doesn't already.

The latest Steam Hardware Survey says ~90% of Windows gamers are using Windows 10, so as long as supporting later versions of XAudio doesn't break Win7 (i.e. as long as they can still use WASAPI or waveOut or DirectSound) it seems like a reasonable thing to do.

The XAudio docs also mention that the output sample-rate can change at runtime (say, somebody is playing a 48kHz audio stream, then plugs in USB headphones that only support 44.1kHz) and I bet ruby doesn't handle that very well at all. Still, I think that would be an improvement over the current situation (plug in headphones, audio keeps playing out the speaker) and for people whose headphones and speakers match, it'd be exactly right.

I would also like to hear more about WASAPI.

from bsnes.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.