[ZMusic] fluid_samplerate doesn't have any effect.

Is there something that doesn't work right in the latest GZDoom? Post about it here.

Moderator: GZDoom Developers

Forum rules
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.

If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.

Please make a new topic for every bug. Don't combine multiple bugs into a single topic. Thanks!

[ZMusic] fluid_samplerate doesn't have any effect.

Postby KynikossDragonn » Sun Jun 19, 2022 3:08 am

FluidSynth in ZMusic seems hardcoded to only run at 44100, but I run all my audio at 48000. If I have "Nearest" set as the resampler in OpenAL, FluidSynth becomes noticeably aliased.

I would expect "fluid_samplerate 48000" would cause ZMusic to run FluidSynth at that rate but it doesn't seem to do this... Setting the cvar in GZDoom and/or Raze and restarting the entire sound system produces no results, FluidSynth is started at 44100 Hz sampling rate regardless.

I'm running a ZMusic compiled with this commit that appears to still be the latest I've compiled recently.
User avatar
KynikossDragonn
『霧雨魔理沙のペットドラゴン』
 
Joined: 12 Dec 2020
Location: Independence, KS, USA
Twitch ID: kynikossdragonn
Github ID: KynikossDragonn
Operating System: Other Linux 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: Intel (Modern GZDoom)

Re: [ZMusic] fluid_samplerate doesn't have any effect.

Postby Graf Zahl » Mon Jun 20, 2022 12:10 am

The reason why this does not work is that ZMusic has a two-stage approach to sample rate, but GZDoom does not pass in its output rate so it always defaults to 44100, overriding the custom setting. ZMusic works as intended, the bug is on GZDoom's side.

But you really shouldn't run the "nearest" resampler as it creates lots of such problems with other sounds that are not as easily solved. Something will always get undesirable aliasing.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: [ZMusic] fluid_samplerate doesn't have any effect.

Postby KynikossDragonn » Mon Jun 20, 2022 2:44 am

Oh... huh, so it has to be fixed in GZDoom/Raze itself?

For context: I use the "Nearest" when playing with original sounds (especially with Duke Nukem 3D and Blood), on some GZDoom mods I switch to Linear, in some rare cases I switch it to "bsinc24".
User avatar
KynikossDragonn
『霧雨魔理沙のペットドラゴン』
 
Joined: 12 Dec 2020
Location: Independence, KS, USA
Twitch ID: kynikossdragonn
Github ID: KynikossDragonn
Operating System: Other Linux 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: Intel (Modern GZDoom)


Return to Bugs

Who is online

Users browsing this forum: No registered users and 0 guests