summaryrefslogtreecommitdiff
path: root/libs/audiographer/tests/utils.h
diff options
context:
space:
mode:
authorSakari Bergen <sakari.bergen@beatwaves.net>2009-12-27 22:09:40 +0000
committerSakari Bergen <sakari.bergen@beatwaves.net>2009-12-27 22:09:40 +0000
commit8da27200d18fe4c471a759dde8e10d85ff29d277 (patch)
tree8a68123da7cb8539a9818704363e3fd98da4d385 /libs/audiographer/tests/utils.h
parentdde0848a984e06cbc1d4117d9cffa75c191f3b39 (diff)
- Fix process callbakc handling during export
- Fix filename handling when exporting multiple files - Some updates to audiographer git-svn-id: svn://localhost/ardour2/branches/3.0@6402 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/audiographer/tests/utils.h')
-rw-r--r--libs/audiographer/tests/utils.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/libs/audiographer/tests/utils.h b/libs/audiographer/tests/utils.h
index 6b6a1fea0f..b13a7b7f07 100644
--- a/libs/audiographer/tests/utils.h
+++ b/libs/audiographer/tests/utils.h
@@ -12,6 +12,7 @@
#include "audiographer/exception.h"
#include <vector>
+#include <list>
#include <cstring>
#include <cstdlib>
#include <ctime>
@@ -116,4 +117,19 @@ class ThrowingSink : public AudioGrapher::Sink<T>
using AudioGrapher::Sink<T>::process;
};
+template<typename T>
+class ProcessContextGrabber : public AudioGrapher::Sink<T>
+{
+ public:
+ void process (AudioGrapher::ProcessContext<T> const & c)
+ {
+ contexts.push_back (c);
+ }
+ using AudioGrapher::Sink<T>::process;
+
+ typedef std::list<AudioGrapher::ProcessContext<T> > ContextList;
+ ContextList contexts;
+
+};
+
#endif // AUDIOGRAPHER_TESTS_UTILS_H