diff src/MatchFeeder.h @ 60:faa523be20f9 refactors_no_float

Update both Feeders so as to recognise the end of one input before the other has ended. MatchFeeder does this by detecting trailing silence (as both its inputs are technically the same length since the shorter is zero-padded) and reporting that to Finder. MatchFeatureFeeder simply recognises missing features at the end and won't queue them.
author Chris Cannam
date Fri, 14 Nov 2014 13:53:58 +0000
parents 16870e8770ae
children a540137d393b
line wrap: on
line diff
--- a/src/MatchFeeder.h	Fri Nov 14 10:25:57 2014 +0000
+++ b/src/MatchFeeder.h	Fri Nov 14 13:53:58 2014 +0000
@@ -47,7 +47,7 @@
      * calculated by the two feeders.
      */
     Features feedAndGetFeatures(const float *const *input);
-
+    
     Finder *getFinder() { return finder; }
 
 protected:
@@ -66,6 +66,10 @@
 
     std::queue<float *> q1;
     std::queue<float *> q2;
+
+    int n;
+    int lastIn1;
+    int lastIn2;
 };
 
 #endif