From 1ffdeed6aedb75809255050261af16849cad2258 Mon Sep 17 00:00:00 2001 From: Tim Date: Thu, 20 Jun 2013 18:25:10 +0100 Subject: very nearly good --- 06_performance/src/testApp.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to '06_performance/src/testApp.h') diff --git a/06_performance/src/testApp.h b/06_performance/src/testApp.h index 02ab1ec..bc0b8fb 100644 --- a/06_performance/src/testApp.h +++ b/06_performance/src/testApp.h @@ -33,6 +33,15 @@ average them on the fly? seems likely #define PICTURE 1 #define GRABBER 2 +template +int explode(const string &s, const char c, OutputIterator output) { + stringstream data(s); + string line; + int i=0; + while(std::getline(data,line,c)) { *output++ = line; i++; } + return i; +} + class testApp : public ofBaseApp, public ofxMidiListener{ -- cgit v1.2.3