diff options
author | Alexey Yakovenko <wakeroid@gmail.com> | 2010-01-23 16:19:06 +0100 |
---|---|---|
committer | Alexey Yakovenko <wakeroid@gmail.com> | 2010-01-23 16:19:06 +0100 |
commit | 6b39d96bcbac546c103ebf5c7fbf676a71ae6ff1 (patch) | |
tree | a8caf02ceea9a2729e5ffa151fc28c567756a9fb | |
parent | 4ef57de537972b6c0f10da984fa78910b09c2194 (diff) |
correct samplerate setting for synth-plugins
-rw-r--r-- | cdumb.c | 2 | ||||
-rw-r--r-- | cgme.c | 2 | ||||
-rw-r--r-- | plugins/adplug/adplug-db.cpp | 2 | ||||
-rw-r--r-- | plugins/sid/csid.cpp | 2 |
4 files changed, 4 insertions, 4 deletions
@@ -70,7 +70,7 @@ cdumb_init (DB_playItem_t *it) { _info->plugin = &plugin; _info->bps = 16; _info->channels = 2; - _info->samplerate = deadbeef->get_output ()->samplerate (); + _info->samplerate = deadbeef->conf_get_int ("synth.samplerate", 48000); _info->readpos = 0; if (cdumb_startrenderer (_info) < 0) { @@ -37,7 +37,7 @@ cgme_init (DB_playItem_t *it) { DB_fileinfo_t *_info = malloc (sizeof (gme_info_t)); gme_info_t *info = (gme_info_t*)_info; memset (_info, 0, sizeof (gme_info_t)); - int samplerate = deadbeef->get_output ()->samplerate (); + int samplerate = deadbeef->conf_get_int ("synth.samplerate", 48000); if (gme_open_file (it->fname, &info->emu, samplerate)) { plugin.free (_info); return NULL; diff --git a/plugins/adplug/adplug-db.cpp b/plugins/adplug/adplug-db.cpp index 6d6cb35c..17b6442c 100644 --- a/plugins/adplug/adplug-db.cpp +++ b/plugins/adplug/adplug-db.cpp @@ -52,7 +52,7 @@ adplug_init (DB_playItem_t *it) { // prepare to decode the track // return -1 on failure - int samplerate = deadbeef->get_output ()->samplerate (); + int samplerate = deadbeef->conf_get_int ("synth.samplerate", 48000); int bps = deadbeef->get_output ()->bitspersample (); int channels = 2; opl = new CEmuopl (samplerate, true, channels == 2); diff --git a/plugins/sid/csid.cpp b/plugins/sid/csid.cpp index 74d3423f..081f8c7b 100644 --- a/plugins/sid/csid.cpp +++ b/plugins/sid/csid.cpp @@ -291,7 +291,7 @@ csid_init (DB_playItem_t *it) { // resid->create (1); info->resid->filter (true); - int samplerate = deadbeef->get_output ()->samplerate (); + int samplerate = deadbeef->conf_get_int ("synth.samplerate", 48000); int bps = deadbeef->get_output ()->bitspersample (); info->resid->sampling (samplerate); |