OpenXcom Forum

Contributions => Programming => Topic started by: kevL on September 08, 2013, 09:56:57 pm

Title: audio: default sample rate (discuss )
Post by: kevL on September 08, 2013, 09:56:57 pm
Engine/Options.cpp, createDefault(), line 111 sets the default sample rate in options.cfg ...

the value is currently "22050". A problem is that the original files (https://www.ufopaedia.org/index.php?title=SOUND#Differences_between_versions) have a rate of 11.025k. The result sounds harsh to this audio-engineer's ears


Suggest: changing the default value to "11025"

caveat, results may be system dependent.

--
difference between oXc and UFO:
oXc, https://www.youtube.com/watch?feature=player_detailpage&v=MMLb7dpO9fE#t=455 - tinny metallic zing (sort of an aftereffect)
UFO, https://www.youtube.com/watch?feature=player_detailpage&v=2W0DnuLQpQ0 - normal (muted slightly due to recording, and the 5.5k cutoff of the lower sample rate)
Title: Re: audio: default sample rate (discuss )
Post by: SupSuper on September 09, 2013, 03:33:52 am
It's because 22050Hz 16-bit are "standard" and cause no problems across systems. Different settings can make SDL_Mixer not play anything or just die on various platforms, so it's left as an option for the audio purists.

And technically the original is 11025Hz 8-bit ;) (or 8000 6-bit for original DOS version)
Title: Re: audio: default sample rate (discuss )
Post by: kevL on September 09, 2013, 04:12:48 am
ok Sup, i figured there was a reason

but the difference to me is glaring and extremely *annoying* ... it was probly the very first thing I changed in options.cfg


thanks,