X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;ds=sidebyside;f=snd_mem.c;h=3da76b39b108d3c4f98990e5f0570409a6ad6e92;hb=ee5a722ac33ca5801658cd2ac168a6a1327edcee;hp=15e571b37c1a368b185ff034a755b4df453ca86f;hpb=cd7454f9df6b152a24c5a28750041d27023fbc1f;p=xonotic%2Fdarkplaces.git diff --git a/snd_mem.c b/snd_mem.c index 15e571b3..3da76b39 100644 --- a/snd_mem.c +++ b/snd_mem.c @@ -80,7 +80,7 @@ snd_buffer_t *Snd_CreateSndBuffer (const unsigned char *samples, unsigned int sa { size_t newsampleframes, memsize; snd_buffer_t* sb; - + newsampleframes = (double)sampleframes * (double)sb_speed / (double)in_format->speed; memsize = newsampleframes * in_format->channels * in_format->width; @@ -311,6 +311,7 @@ qboolean S_LoadSound (sfx_t *sfx, qboolean complain) return true; // If we weren't able to load it previously, no need to retry + // Note: S_PrecacheSound clears this flag to cause a retry if (sfx->flags & SFXFLAG_FILEMISSING) return false; @@ -325,7 +326,7 @@ qboolean S_LoadSound (sfx_t *sfx, qboolean complain) if (len < 0) { // name too long - Con_Printf("S_LoadSound: name \"%s\" is too long\n", sfx->name); + Con_DPrintf("S_LoadSound: name \"%s\" is too long\n", sfx->name); return false; } if (S_LoadWavFile (namebuffer, sfx)) @@ -341,7 +342,7 @@ qboolean S_LoadSound (sfx_t *sfx, qboolean complain) if (len < 0) { // name too long - Con_Printf("S_LoadSound: name \"%s\" is too long\n", sfx->name); + Con_DPrintf("S_LoadSound: name \"%s\" is too long\n", sfx->name); return false; } if (S_LoadWavFile (namebuffer, sfx)) @@ -354,6 +355,6 @@ qboolean S_LoadSound (sfx_t *sfx, qboolean complain) // Can't load the sound! sfx->flags |= SFXFLAG_FILEMISSING; if (complain) - Con_Printf("S_LoadSound: Couldn't load \"%s\"\n", sfx->name); + Con_DPrintf("S_LoadSound: Couldn't load \"%s\"\n", sfx->name); return false; }