13
0

Triggerbox: support for files that use a space between bpm value and bpm text

This commit is contained in:
Ben Loftis 2022-01-26 11:50:52 -06:00
parent 0350e58eb7
commit 3362f7d4fa

View File

@ -1171,6 +1171,8 @@ AudioTrigger::estimate_tempo ()
std::cerr << "Determine tempo for " << name() << std::endl; std::cerr << "Determine tempo for " << name() << std::endl;
if (((bi = str.find (" bpm")) != string::npos) || if (((bi = str.find (" bpm")) != string::npos) ||
((bi = str.find ("bpm")) != string::npos) ||
((bi = str.find (" BPM")) != string::npos) ||
((bi = str.find ("BPM")) != string::npos) ){ ((bi = str.find ("BPM")) != string::npos) ){
string sub (str.substr (0, bi)); string sub (str.substr (0, bi));