diff src/Analyser.h @ 164:62ceae757fe0

Re-analyse frames when selection changes (this only pulls up a set of new candidates for now, can't do anything with them and the old ones are never removed)
author Chris Cannam
date Thu, 30 Jan 2014 17:33:55 +0000
parents ec196bd2f068
children ebcfb8dce020
line wrap: on
line diff
--- a/src/Analyser.h	Wed Jan 29 17:34:28 2014 +0000
+++ b/src/Analyser.h	Thu Jan 30 17:33:55 2014 +0000
@@ -22,6 +22,7 @@
 #include <vector>
 
 #include "framework/Document.h"
+#include "base/Selection.h"
 
 class WaveFileModel;
 class Pane;
@@ -82,6 +83,13 @@
 
     void getEnclosingSelectionScope(size_t f, size_t &f0, size_t &f1);
 
+    /**
+     * Analyse the selection and add candidates layers for the region
+     * it contains. Returns "" on success or a user-readable error
+     * string on failure.
+     */
+    QString reAnalyseSelection(Selection sel);
+
 signals:
     void layersChanged();
 
@@ -96,7 +104,7 @@
     QString addWaveform();
     QString addAnalyses();
 
-    QString addTestCandidates();
+    QString addTestCandidates(Selection sel);
 
     // Document::LayerCreationHandler method
     void layersCreated(std::vector<Layer *>, std::vector<Layer *>);