2006-02-24 04:48:15 +00:00
|
|
|
#include "i_musicinterns.h"
|
2006-09-14 00:02:31 +00:00
|
|
|
#include "c_dispatch.h"
|
2006-02-24 04:48:15 +00:00
|
|
|
#include "i_music.h"
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
#include "i_system.h"
|
2006-02-24 04:48:15 +00:00
|
|
|
|
|
|
|
#include "templates.h"
|
|
|
|
#include "v_text.h"
|
2010-09-14 17:28:18 +00:00
|
|
|
#include "menu/menu.h"
|
2006-02-24 04:48:15 +00:00
|
|
|
|
|
|
|
static DWORD nummididevices;
|
|
|
|
static bool nummididevicesset;
|
2010-08-15 19:54:59 +00:00
|
|
|
|
2010-09-29 00:35:47 +00:00
|
|
|
#ifdef HAVE_FLUIDSYNTH
|
|
|
|
#define NUM_DEF_DEVICES 5
|
|
|
|
#else
|
|
|
|
#define NUM_DEF_DEVICES 4
|
|
|
|
#endif
|
|
|
|
|
|
|
|
static void AddDefaultMidiDevices(FOptionValues *opt)
|
|
|
|
{
|
|
|
|
int p;
|
|
|
|
FOptionValues::Pair *pair = &opt->mValues[opt->mValues.Reserve(NUM_DEF_DEVICES)];
|
|
|
|
#ifdef HAVE_FLUIDSYNTH
|
|
|
|
pair[0].Text = "FluidSynth";
|
|
|
|
pair[0].Value = -5.0;
|
|
|
|
p = 1;
|
|
|
|
#else
|
|
|
|
p = 0;
|
|
|
|
#endif
|
|
|
|
pair[p].Text = "GUS";
|
|
|
|
pair[p].Value = -4.0;
|
|
|
|
pair[p+1].Text = "OPL Synth Emulation";
|
|
|
|
pair[p+1].Value = -3.0;
|
|
|
|
pair[p+2].Text = "TiMidity++";
|
|
|
|
pair[p+2].Value = -2.0;
|
2014-06-26 23:58:18 +00:00
|
|
|
pair[p+3].Text = "Sound System";
|
2010-09-29 00:35:47 +00:00
|
|
|
pair[p+3].Value = -1.0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2010-10-02 04:12:21 +00:00
|
|
|
static void MIDIDeviceChanged(int newdev)
|
|
|
|
{
|
|
|
|
static int oldmididev = INT_MIN;
|
|
|
|
|
|
|
|
// If a song is playing, move it to the new device.
|
2011-05-20 00:26:22 +00:00
|
|
|
if (oldmididev != newdev)
|
2010-10-02 04:12:21 +00:00
|
|
|
{
|
2011-05-20 00:26:22 +00:00
|
|
|
if (currSong != NULL && currSong->IsMIDI())
|
2010-10-02 04:12:21 +00:00
|
|
|
{
|
2011-05-20 00:26:22 +00:00
|
|
|
MusInfo *song = currSong;
|
|
|
|
if (song->m_Status == MusInfo::STATE_Playing)
|
|
|
|
{
|
|
|
|
song->Stop();
|
|
|
|
song->Start(song->m_Looping);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
S_MIDIDeviceChanged();
|
2010-10-02 04:12:21 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
oldmididev = newdev;
|
|
|
|
}
|
|
|
|
|
2008-03-26 08:50:54 +00:00
|
|
|
#ifdef _WIN32
|
2010-10-02 04:12:21 +00:00
|
|
|
UINT mididevice;
|
2006-02-24 04:48:15 +00:00
|
|
|
|
|
|
|
CUSTOM_CVAR (Int, snd_mididevice, -1, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
|
|
|
{
|
|
|
|
if (!nummididevicesset)
|
|
|
|
return;
|
|
|
|
|
2010-08-15 19:54:59 +00:00
|
|
|
if ((self >= (signed)nummididevices) || (self < -5))
|
2006-02-24 04:48:15 +00:00
|
|
|
{
|
VERY IMPORTANT NOTE FOR ANYBODY BUILDING FROM THE TRUNK: This commit adds support
for FMOD Ex while at the same time removing support for FMOD 3. Be sure to update
your SDKs. GCC users, be sure to do a "make cleandep && make clean" before
building, or you will likely get inexplicable errors.
- Fixed: If you wanted to make cleandep with MinGW, you had to specifically
specify Makefile.mingw as the makefile to use.
- Added a normalizer to the OPL synth. It helped bring up the volume a little,
but not nearly as much as I would have liked.
- Removed MIDI Mapper references. It doesn't work with the stream API, and
it doesn't really exist on NT kernels, either.
- Reworked music volume: Except for MIDI, all music volume is controlled
through GSnd and not at the individual song level.
- Removed the mididevice global variable.
- Removed snd_midivolume. Now that all music uses a linear volume scale,
there's no need for two separate music volume controls.
- Increased snd_samplerate default up to 48000.
- Added snd_format, defaulting to "PCM-16".
- Added snd_speakermode, defaulting to "Auto".
- Replaced snd_fpu with snd_resampler, defaulting to "Linear".
- Bumped the snd_channels default up from a pitiful 12 to 32.
- Changed snd_3d default to true. The new cvar snd_hw3d determines if
hardware 3D support is used and default to false.
- Removed the libFLAC source, since FMOD Ex has native FLAC support.
- Removed the altsound code, since it was terribly gimped in comparison to
the FMOD code. It's original purpose was to have been as a springboard for
writing a non-FMOD sound system for Unix-y systems, but that never
happened.
- Finished preliminary FMOD Ex support.
SVN r789 (trunk)
2008-03-09 03:13:49 +00:00
|
|
|
Printf ("ID out of range. Using default device.\n");
|
|
|
|
self = 0;
|
2006-02-24 04:48:15 +00:00
|
|
|
return;
|
|
|
|
}
|
2010-10-02 04:12:21 +00:00
|
|
|
mididevice = MAX<UINT>(0, self);
|
|
|
|
MIDIDeviceChanged(self);
|
2006-02-24 04:48:15 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void I_InitMusicWin32 ()
|
|
|
|
{
|
|
|
|
nummididevices = midiOutGetNumDevs ();
|
|
|
|
nummididevicesset = true;
|
|
|
|
snd_mididevice.Callback ();
|
|
|
|
}
|
|
|
|
|
|
|
|
void I_ShutdownMusicWin32 ()
|
|
|
|
{
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
// Ancient bug a saw on NT 4.0 and an old version of FMOD 3: If waveout
|
|
|
|
// is used for sound and a MIDI is also played, then when I quit, the OS
|
2006-02-24 04:48:15 +00:00
|
|
|
// tells me a free block was modified after being freed. This is
|
|
|
|
// apparently a synchronization issue between two threads, because if I
|
|
|
|
// put this Sleep here after stopping the music but before shutting down
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
// the entire sound system, the error does not happen. Observed with a
|
|
|
|
// Vortex 2 (may Aureal rest in peace) and an Audigy (damn you, Creative!).
|
|
|
|
// I no longer have a system with NT4 drivers, so I don't know if this
|
|
|
|
// workaround is still needed or not.
|
|
|
|
if (OSPlatform == os_WinNT4)
|
|
|
|
{
|
|
|
|
Sleep(50);
|
|
|
|
}
|
2006-02-24 04:48:15 +00:00
|
|
|
}
|
|
|
|
|
2010-09-14 17:28:18 +00:00
|
|
|
void I_BuildMIDIMenuList (FOptionValues *opt)
|
2006-02-24 04:48:15 +00:00
|
|
|
{
|
2010-09-29 00:35:47 +00:00
|
|
|
AddDefaultMidiDevices(opt);
|
2010-09-14 17:28:18 +00:00
|
|
|
|
|
|
|
for (DWORD id = 0; id < nummididevices; ++id)
|
2006-02-24 04:48:15 +00:00
|
|
|
{
|
2010-09-14 17:28:18 +00:00
|
|
|
MIDIOUTCAPS caps;
|
|
|
|
MMRESULT res;
|
2006-02-24 04:48:15 +00:00
|
|
|
|
2010-09-14 17:28:18 +00:00
|
|
|
res = midiOutGetDevCaps (id, &caps, sizeof(caps));
|
|
|
|
assert(res == MMSYSERR_NOERROR);
|
|
|
|
if (res == MMSYSERR_NOERROR)
|
|
|
|
{
|
2010-09-29 00:35:47 +00:00
|
|
|
FOptionValues::Pair *pair = &opt->mValues[opt->mValues.Reserve(1)];
|
2010-09-14 17:28:18 +00:00
|
|
|
pair->Text = caps.szPname;
|
|
|
|
pair->Value = (float)id;
|
2006-02-24 04:48:15 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
static void PrintMidiDevice (int id, const char *name, WORD tech, DWORD support)
|
|
|
|
{
|
|
|
|
if (id == snd_mididevice)
|
|
|
|
{
|
|
|
|
Printf (TEXTCOLOR_BOLD);
|
|
|
|
}
|
|
|
|
Printf ("% 2d. %s : ", id, name);
|
|
|
|
switch (tech)
|
|
|
|
{
|
|
|
|
case MOD_MIDIPORT: Printf ("MIDIPORT"); break;
|
|
|
|
case MOD_SYNTH: Printf ("SYNTH"); break;
|
|
|
|
case MOD_SQSYNTH: Printf ("SQSYNTH"); break;
|
|
|
|
case MOD_FMSYNTH: Printf ("FMSYNTH"); break;
|
|
|
|
case MOD_MAPPER: Printf ("MAPPER"); break;
|
|
|
|
case MOD_WAVETABLE: Printf ("WAVETABLE"); break;
|
|
|
|
case MOD_SWSYNTH: Printf ("SWSYNTH"); break;
|
|
|
|
}
|
|
|
|
if (support & MIDICAPS_CACHE)
|
|
|
|
{
|
|
|
|
Printf (" CACHE");
|
|
|
|
}
|
|
|
|
if (support & MIDICAPS_LRVOLUME)
|
|
|
|
{
|
|
|
|
Printf (" LRVOLUME");
|
|
|
|
}
|
|
|
|
if (support & MIDICAPS_STREAM)
|
|
|
|
{
|
|
|
|
Printf (" STREAM");
|
|
|
|
}
|
|
|
|
if (support & MIDICAPS_VOLUME)
|
|
|
|
{
|
|
|
|
Printf (" VOLUME");
|
|
|
|
}
|
|
|
|
Printf (TEXTCOLOR_NORMAL "\n");
|
|
|
|
}
|
|
|
|
|
|
|
|
CCMD (snd_listmididevices)
|
|
|
|
{
|
|
|
|
UINT id;
|
|
|
|
MIDIOUTCAPS caps;
|
|
|
|
MMRESULT res;
|
|
|
|
|
2010-08-19 15:31:44 +00:00
|
|
|
#ifdef HAVE_FLUIDSYNTH
|
|
|
|
PrintMidiDevice (-5, "FluidSynth", MOD_SWSYNTH, 0);
|
|
|
|
#endif
|
2010-10-02 02:23:42 +00:00
|
|
|
PrintMidiDevice (-4, "Gravis Ultrasound Emulation", MOD_SWSYNTH, 0);
|
2008-04-09 03:55:04 +00:00
|
|
|
PrintMidiDevice (-3, "Emulated OPL FM Synth", MOD_FMSYNTH, 0);
|
2010-10-02 02:23:42 +00:00
|
|
|
PrintMidiDevice (-2, "TiMidity++", MOD_SWSYNTH, 0);
|
2014-09-11 21:16:56 +00:00
|
|
|
PrintMidiDevice (-1, "Sound System", 0, 0);
|
2006-02-24 04:48:15 +00:00
|
|
|
if (nummididevices != 0)
|
|
|
|
{
|
|
|
|
for (id = 0; id < nummididevices; ++id)
|
|
|
|
{
|
|
|
|
res = midiOutGetDevCaps (id, &caps, sizeof(caps));
|
|
|
|
if (res == MMSYSERR_NODRIVER)
|
|
|
|
strcpy (caps.szPname, "<Driver not installed>");
|
|
|
|
else if (res == MMSYSERR_NOMEM)
|
|
|
|
strcpy (caps.szPname, "<No memory for description>");
|
|
|
|
else if (res != MMSYSERR_NOERROR)
|
|
|
|
continue;
|
|
|
|
|
|
|
|
PrintMidiDevice (id, caps.szPname, caps.wTechnology, caps.dwSupport);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
// Everything but Windows uses this code.
|
|
|
|
|
|
|
|
CUSTOM_CVAR(Int, snd_mididevice, -1, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
|
|
|
{
|
2010-08-15 19:54:59 +00:00
|
|
|
if (self < -5)
|
|
|
|
self = -5;
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
else if (self > -1)
|
|
|
|
self = -1;
|
2010-10-02 04:12:21 +00:00
|
|
|
else
|
|
|
|
MIDIDeviceChanged(self);
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
}
|
|
|
|
|
2010-09-14 17:28:18 +00:00
|
|
|
void I_BuildMIDIMenuList (FOptionValues *opt)
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
{
|
2010-09-29 00:35:47 +00:00
|
|
|
AddDefaultMidiDevices(opt);
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
CCMD (snd_listmididevices)
|
|
|
|
{
|
2010-08-19 15:31:44 +00:00
|
|
|
#ifdef HAVE_FLUIDSYNTH
|
|
|
|
Printf("%s-5. FluidSynth\n", -5 == snd_mididevice ? TEXTCOLOR_BOLD : "");
|
|
|
|
#endif
|
2010-10-02 02:23:42 +00:00
|
|
|
Printf("%s-4. Gravis Ultrasound Emulation\n", -4 == snd_mididevice ? TEXTCOLOR_BOLD : "");
|
2008-04-09 03:55:04 +00:00
|
|
|
Printf("%s-3. Emulated OPL FM Synth\n", -3 == snd_mididevice ? TEXTCOLOR_BOLD : "");
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
Printf("%s-2. TiMidity++\n", -2 == snd_mididevice ? TEXTCOLOR_BOLD : "");
|
2010-08-13 07:07:26 +00:00
|
|
|
Printf("%s-1. Sound System\n", -1 == snd_mididevice ? TEXTCOLOR_BOLD : "");
|
- The garbage collector is now run one last time just before exiting the game.
- Removed movie volume from the sound menu and renamed some of the other
options to give the MIDI device name more room to display itself.
- Moved the midi device selection into the main sound menu.
- Added FMOD as MIDI device -1, to replace the MIDI mapper. This is still the
default device. By default, it uses exactly the same DLS instruments as the
Microsoft GS Wavetable Synth. If you have another set DLS level 1 patch set
you want to use, set the snd_midipatchfile cvar to specify where it should
load the instruments from.
- Changed the ProduceMIDI function to store its output into a TArray<BYTE>.
An overloaded version wraps around it to continue to supply file-writing
support for external Timidity++ usage.
- Added an FMOD credits banner to comply with their non-commercial license.
- Reimplemented the snd_buffersize cvar for the FMOD Ex sound system. Rather
than a time in ms, this is now the length in samples of the DSP buffer.
Also added the snd_buffercount cvar to offer complete control over the
call to FMOD::System::setDSPBufferSize(). Note that with any snd_samplerate
below about 44kHz, you will need to set snd_buffersize to avoid long
latencies.
- Reimplemented the snd_output cvar for the FMOD Ex sound system.
- Changed snd_samplerate default to 0. This now means to use the default
sample rate.
- Made snd_output, snd_output_format, snd_speakermode, snd_resampler, and
snd_hrtf available through the menu.
- Split the HRTF effect selection into its own cvar: snd_hrtf.
- Removed 96000 Hz option from the menu. It's still available through the
cvar, if desired.
- Fixed: If Windows sound init failed, retry with DirectSound. (Apparently,
WASAPI doesn't work with more than two speakers and PCM-Float output at the
same time.)
- Fixed: Area sounds only played from the front speakers once you got within
the 2D panning area.
SVN r854 (trunk)
2008-03-26 04:27:07 +00:00
|
|
|
}
|
2006-02-24 04:48:15 +00:00
|
|
|
#endif
|