turns out some like interpolated, others don't. snd_interp conrols this.

Defaults to on so those used to 11k sampling won't be too suprised.
This commit is contained in:
Bill Currie 2000-10-06 18:42:03 +00:00
parent 73d0b16350
commit b17b8afa3c
3 changed files with 5 additions and 1 deletions

View file

@ -172,6 +172,8 @@ extern cvar_t *loadas8bit;
extern cvar_t *bgmvolume;
extern cvar_t *volume;
extern cvar_t *snd_interp;
extern qboolean snd_initialized;
extern int snd_blocked;

View file

@ -99,6 +99,7 @@ cvar_t *ambient_level;
cvar_t *ambient_fade;
cvar_t *snd_noextraupdate;
cvar_t *snd_show;
cvar_t *snd_interp;
cvar_t *_snd_mixahead;
@ -205,6 +206,7 @@ void S_Init (void)
ambient_fade = Cvar_Get("ambient_fade", "100", CVAR_NONE, "None");
snd_noextraupdate = Cvar_Get("snd_noextraupdate", "0", CVAR_NONE, "None");
snd_show = Cvar_Get("snd_show", "0", CVAR_NONE, "None");
snd_interp = Cvar_Get("snd_interp", "1", CVAR_ARCHIVE, "control sample interpolation");
_snd_mixahead = Cvar_Get("_snd_mixahead", "0.1", CVAR_ARCHIVE, "None");
if (COM_CheckParm("-nosound"))

View file

@ -99,7 +99,7 @@ void ResampleSfx (sfx_t *sfx, int inrate, int inwidth, byte *data)
}
} else {
// general case
if (stepscale < 1) {
if (snd_interp->int_val && stepscale < 1) {
int points = 1/stepscale;
int j;