summaryrefslogtreecommitdiff
path: root/drumgizmo/input
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2016-05-14 11:56:44 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2016-05-14 11:56:44 +0200
commit7aff3e6c4736690b9bc3e900a61c8ab8d172bf26 (patch)
treedadc7409b0a6b51cbd6773c79cb62e0a8699686a /drumgizmo/input
parent5fbb64651f6a6511fdd7b407b74c4a16c3bbae89 (diff)
Temporary fix for midimap loading in command line tool.
Diffstat (limited to 'drumgizmo/input')
-rw-r--r--drumgizmo/input/midifile.cc8
-rw-r--r--drumgizmo/input/midifile.h1
2 files changed, 5 insertions, 4 deletions
diff --git a/drumgizmo/input/midifile.cc b/drumgizmo/input/midifile.cc
index 76dff12..27a8e04 100644
--- a/drumgizmo/input/midifile.cc
+++ b/drumgizmo/input/midifile.cc
@@ -59,7 +59,7 @@ bool MidifileInputEngine::init(const Instruments& instruments)
std::cerr << "[MidifileInputEngine] Missing midi filename\n";
return false;
}
- if(midimap == "")
+ if(midimap_file == "")
{
std::cerr << "[MidifileInputEngine] Missing midimap filename\n";
return false;
@@ -71,10 +71,10 @@ bool MidifileInputEngine::init(const Instruments& instruments)
<< "'\n";
return false;
}
- if(!loadMidiMap(midimap, instruments))
+ if(!loadMidiMap(midimap_file, instruments))
{
std::cerr << "[MidifileInputEngine] Failed to parse midimap '"
- << midimap << "'\n";
+ << midimap_file << "'\n";
return false;
}
return true;
@@ -103,7 +103,7 @@ void MidifileInputEngine::setParm(const std::string& parm, const std::string& va
else if(parm == "midimap")
{
// apply midimap filename
- midimap = value;
+ midimap_file = value;
}
else if(parm == "loop")
{
diff --git a/drumgizmo/input/midifile.h b/drumgizmo/input/midifile.h
index 08dc249..a0e8fa6 100644
--- a/drumgizmo/input/midifile.h
+++ b/drumgizmo/input/midifile.h
@@ -54,6 +54,7 @@ private:
smf_t* smf;
smf_event_t* current_event;
+ std::string midimap_file;
std::string file;
float speed;
int track;