mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 08:51:24 +00:00
- set up some basic reverb.
I'm not sure if this is working out as the original "reverb" was just too crappy and generic. It may be best to just disable it.
This commit is contained in:
parent
417d425f27
commit
3914eb5f85
3 changed files with 18 additions and 5 deletions
|
@ -2366,5 +2366,4 @@ void I_BuildALResamplersList(FOptionValues* opt)
|
|||
#endif
|
||||
}
|
||||
|
||||
|
||||
#endif // NO_OPENAL
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
#include "s_soundinternal.h"
|
||||
#include "m_swap.h"
|
||||
#include "superfasthash.h"
|
||||
#include "c_cvars.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#undef DrawText
|
||||
|
@ -1725,6 +1726,22 @@ void SoundEngine::AddRandomSound(int Owner, TArray<uint32_t> list)
|
|||
S_sfx[Owner].NearLimit = -1;
|
||||
}
|
||||
|
||||
extern ReverbContainer* ForcedEnvironment;
|
||||
|
||||
CVAR(Bool, snd_reverb, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
||||
void FX_SetReverb(int strength)
|
||||
{
|
||||
if (snd_reverb)
|
||||
{
|
||||
// todo: optimize environments. The original "reverb" was garbage and not usable as reference.
|
||||
if (strength < 64) strength = 0x1400;
|
||||
else if (strength < 192) strength = 0x1500;
|
||||
else strength = 0x1900;
|
||||
ForcedEnvironment = S_FindEnvironment(strength);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#include "basics.h"
|
||||
#include "stats.h"
|
||||
#include "v_text.h"
|
||||
|
|
|
@ -430,10 +430,7 @@ inline void FX_StopAllSounds(void)
|
|||
soundEngine->StopAllChannels();
|
||||
}
|
||||
|
||||
inline void FX_SetReverb(int strength)
|
||||
{
|
||||
// todo: investigate how this works and set a proper environment.
|
||||
}
|
||||
void FX_SetReverb(int strength);
|
||||
|
||||
inline void FX_SetReverbDelay(int delay)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue