comparison src/testApp.cpp @ 53:5274e3b5479d

Smoothed output, added tempo distribution variation to match the output
author Andrew N Robertson <andrew.robertson@eecs.qmul.ac.uk>
date Tue, 14 Aug 2012 21:45:12 +0100
parents e359b9bad811
children 2eca10a31ae2
comparison
equal deleted inserted replaced
52:e359b9bad811 53:5274e3b5479d
5 #include <cstring> 5 #include <cstring>
6 #include <string> 6 #include <string>
7 #include <cstdlib> 7 #include <cstdlib>
8 8
9 9
10 /*
11 L: load marker file
12 S: save markers
13
14 */
15
10 const double samplingFrequency = 44100.0; 16 const double samplingFrequency = 44100.0;
11 17
12 //-------------------------------------------------------------- 18 //--------------------------------------------------------------
13 void testApp::setup(){ 19 void testApp::setup(){
14 20
25 sampleRate = 44100; 31 sampleRate = 44100;
26 ofSoundStreamSetup(2,0,this, sampleRate,256, 4); 32 ofSoundStreamSetup(2,0,this, sampleRate,256, 4);
27 33
28 ofSetFrameRate(20); 34 ofSetFrameRate(20);
29 35
30
31 eventMatcher.loadAudioFiles(); 36 eventMatcher.loadAudioFiles();
32 37
33 eventMatcher.setWindowDimensions(); 38 eventMatcher.setWindowDimensions();
34 39
35 outputWriter.openFile("../../../data/output.txt"); 40 outputWriter.openFile("../../../data/output.txt");
212 if (key == 'j'){ 217 if (key == 'j'){
213 printf("dynamic vector scalar is %f\n", eventMatcher.bayesianStruct.posterior.scalar); 218 printf("dynamic vector scalar is %f\n", eventMatcher.bayesianStruct.posterior.scalar);
214 } 219 }
215 220
216 if (key == OF_KEY_RETURN){ 221 if (key == OF_KEY_RETURN){
217
218
219 eventMatcher.recordedTracks.stop(); 222 eventMatcher.recordedTracks.stop();
220 } 223 }
221 224
222 225
223 if (key == 'o'){ 226 if (key == 'o'){