summaryrefslogtreecommitdiff
path: root/src/i_sound.c
diff options
context:
space:
mode:
authorSimon Howard2014-03-23 00:55:13 -0400
committerSimon Howard2014-03-23 00:55:13 -0400
commit765ca3a04dafe63b8803443067293ee46f53b951 (patch)
treea8f9fea996d5551748088c51149f8013fd7c78fd /src/i_sound.c
parenta3e2dbc78825378307509201f904a1de3bf8bab8 (diff)
downloadchocolate-doom-765ca3a04dafe63b8803443067293ee46f53b951.tar.gz
chocolate-doom-765ca3a04dafe63b8803443067293ee46f53b951.tar.bz2
chocolate-doom-765ca3a04dafe63b8803443067293ee46f53b951.zip
music: Add config var for external music program.
Mix_SetMusicCMD() allows a program to be specified to configure an external program to be invoked for music playback. Add a config variable (snd_musiccmd) to allow this to be set from a configuration file. Thanks to Holering for his comments on Doomworld about how to do this.
Diffstat (limited to 'src/i_sound.c')
-rw-r--r--src/i_sound.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/i_sound.c b/src/i_sound.c
index 7aa3a31b..d71dacd7 100644
--- a/src/i_sound.c
+++ b/src/i_sound.c
@@ -52,6 +52,10 @@ int snd_cachesize = 64 * 1024 * 1024;
int snd_maxslicetime_ms = 28;
+// External command to invoke to play back music.
+
+char *snd_musiccmd = "";
+
// Low-level sound and music modules we are using
static sound_module_t *sound_module;
@@ -440,6 +444,7 @@ void I_BindSoundVariables(void)
M_BindVariable("snd_sbdma", &snd_sbdma);
M_BindVariable("snd_mport", &snd_mport);
M_BindVariable("snd_maxslicetime_ms", &snd_maxslicetime_ms);
+ M_BindVariable("snd_musiccmd", &snd_musiccmd);
M_BindVariable("snd_samplerate", &snd_samplerate);
M_BindVariable("snd_cachesize", &snd_cachesize);
M_BindVariable("opl_io_port", &opl_io_port);