Skip to content

Commit

Permalink
Fix default the beat detector to be the QMUL beat tracker.
Browse files Browse the repository at this point in the history
  • Loading branch information
rryan committed Dec 27, 2018
1 parent 352d8c3 commit 260071e
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/preferences/beatdetectionsettings.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,21 +50,20 @@ class BeatDetectionSettings {
BPM_CONFIG_KEY, BPM_FAST_ANALYSIS_ENABLED, false);

QString getBeatPluginId() const {
QString vampPlugin = m_pConfig->getValue<QString>(ConfigKey(
QString plugin_id = m_pConfig->getValue<QString>(ConfigKey(
VAMP_CONFIG_KEY, VAMP_ANALYZER_BEAT_PLUGIN_ID));
if (vampPlugin.isEmpty()) {
return "qm-tempotracker:0";
if (plugin_id.isEmpty()) {
return getBeatPluginIdDefault();
}
// TODO(rryan): Update to new plugins based on VAMP ones.
return vampPlugin;
return plugin_id;
}
void setBeatPluginId(const QString& plugin_id) {
m_pConfig->setValue(
ConfigKey(VAMP_CONFIG_KEY, VAMP_ANALYZER_BEAT_PLUGIN_ID),
plugin_id);
}
QString getBeatPluginIdDefault() const {
// TODO(rryan)
return "qm-tempotracker";
}
void setBeatPluginIdDefault() {
Expand Down

0 comments on commit 260071e

Please sign in to comment.