comparison src/testApp.cpp @ 37:9806a4f22fd0

Fixed bugs in the likelohoods that caused some to zero when no events found.
author Andrew N Robertson <andrew.robertson@eecs.qmul.ac.uk>
date Tue, 24 Apr 2012 14:16:01 +0100
parents eb43b2a007ea
children f5de07b4d733
comparison
equal deleted inserted replaced
36:eb43b2a007ea 37:9806a4f22fd0
81 // check for mouse moved message 81 // check for mouse moved message
82 if ( m.getAddress() == "/elec" ){ 82 if ( m.getAddress() == "/elec" ){
83 int testChannel = m.getArgAsInt32(0); 83 int testChannel = m.getArgAsInt32(0);
84 double timeIn = m.getArgAsFloat(1); 84 double timeIn = m.getArgAsFloat(1);
85 float chromaIn[12]; 85 float chromaIn[12];
86
86 printf("CHROMA received at time %f\n", timeIn); 87 printf("CHROMA received at time %f\n", timeIn);
87 for (int i = 0;i < 12;i++){ 88 for (int i = 0;i < 12;i++){
88 chromaIn[i] = m.getArgAsFloat(i+2); 89 chromaIn[i] = m.getArgAsFloat(i+2);
89 printf("chroma[%i]: %f\n", i, chromaIn[i]); 90 // printf("chroma[%i]: %f\n", i, chromaIn[i]);
90 } 91 }
91 eventMatcher.newChromaEvent(testChannel, chromaIn, timeIn); 92 eventMatcher.newChromaEvent(testChannel, chromaIn, timeIn);
92 } 93 }
93 94
94 95