diff NoteHypothesis.cpp @ 66:7ad142c710c6 parameters

Add some parameters
author Chris Cannam
date Fri, 30 Aug 2013 15:35:49 +0100
parents c06fe5350b34
children
line wrap: on
line diff
--- a/NoteHypothesis.cpp	Thu Dec 06 17:27:16 2012 +0000
+++ b/NoteHypothesis.cpp	Fri Aug 30 15:35:49 2013 +0100
@@ -28,9 +28,10 @@
 
 using Vamp::RealTime;
 
-NoteHypothesis::NoteHypothesis()
+NoteHypothesis::NoteHypothesis(float slack) :
+    m_state(New),
+    m_slack(slack)
 {
-    m_state = New;
 }
 
 NoteHypothesis::~NoteHypothesis()
@@ -65,7 +66,7 @@
 {
     if (m_pending.empty()) return false;
     return ((s.time - m_pending[m_pending.size()-1].time) > 
-            RealTime::fromMilliseconds(40));
+            RealTime::fromMilliseconds(m_slack));
 }
 
 bool