Support alternative audio backend
Hi,
Currently osu! heavily relies on BASS for audio. However, as BASS is closed-source, one can't easily bring up osu! on platforms unsupported by BASS; some recent ARM64, PPC64 devices and upcoming Loongson boards come to mind.
Is there any plan to abstract out the audio backend, so people on these niche platforms can begin work to port osu! to their favourite non-x86 rigs?
Yep, definitely open to alternatives. Implementation should already be relatively straightforward (make AudioManager provided by the host in a similar way to other components).
This goes hand in hand with the GameHost refactor I’m working on, that allows for different backend implementations to be dropped in (a prerequisite for Veldrid support).
I suggest using SDL as the alternative. It would be better for Linux users since it supports modern audio drivers for Linux, which can decrease the audio latency. Users can also set the SDL_AUDIODRIVER environment variable to manually override the driver used. The list of audio drivers supported can be found at the repository.
@huupoke12 It's been a while but IIRC the main hurdle is osu! makes heavy use of the audio effects provided by BASS, for mods like DT NC and such. All DSP code would have to be reimplemented, with adequate performance, if one were to replace BASS, and that's probably why this is still TODO today.
This doesn't need discussion, sorry. It needs implementation. It's not (and will never be) a priority for osu!'s use case, and it's not going to be prioritised by the team until after osu!lazer replaces osu!stable.
In-fact, the only osu-framework-side implementation is to expose sufficient abstractions from AudioManager and all related components (SampleStore/TrackStore/etc) in order to create implementation-specific components. The rest can be done as its own nuget package.
@huupoke12 It's been a while but IIRC the main hurdle is osu! makes heavy use of the audio effects provided by BASS, for mods like DT NC and such. All DSP code would have to be reimplemented, with adequate performance, if one were to replace BASS, and that's probably why this is still TODO today.
i see, so its not as easy as it seems at first, thanks
This doesn't need discussion, sorry. It needs implementation. It's not (and will never be) a priority for osu!'s use case, and it's not going to be prioritised by the team until after osu!lazer replaces osu!stable.
In-fact, the only osu-framework-side implementation is to expose sufficient abstractions from
AudioManagerand all related components (SampleStore/TrackStore/etc) in order to create implementation-specific components. The rest can be done as its own nuget package.
this seems more complex than my skill level of understanding, i hope we can find a solution eventually, thanks. coming from a BSD user who BASS is unavailable and i cannot compile it.