Definition at line 186 of file SimilarityTimeLine.h. References OglGui::OglWindow::H(), mAverages, OglGui::ZoomShiftRuler::mAxisY, Impala::Visualization::TimeLineViewStrip::mFrameError, mMaxima, mShowClassify, mSimColors, PassTest(), and OglGui::ZoomShiftRuler::Unit2Pixel(). Referenced by DisplayFunc(). 00188 { 00189 if (!mAverages || (*mMaxima)[idx] < 0.20 || !mShowClassify) 00190 return; 00191 00192 FloatVector* avgVector = (*mAverages)[idx]; 00193 float maxim = (*mMaxima)[idx]; 00194 float means = (*mMeans)[idx]; 00195 float lineY = H()-(idx+1)*5; 00196 00197 if (startFrame > (*avgVector).size()-1) 00198 startFrame = (*avgVector).size()-1; 00199 00200 if (endFrame > (*avgVector).size()-1) 00201 endFrame = (*avgVector).size()-1; 00202 00203 int bInfo[3]; 00204 oglSys.StartBlend(bInfo); 00205 00206 ULONG col = mSimColors[idx%mSimColors.size()]; 00207 UCHAR r,g,b; 00208 COLOR2RGB(col,r,g,b); 00209 UCHAR aR = r, aG = g, aB = b, aA = 0; 00210 00211 glLineWidth(lineW); 00212 glBegin(GL_LINE_STRIP); 00213 for (float i=startFrame; i<endFrame; i+=inc) 00214 { 00215 double sim = (*avgVector)[(int)(i+mFrameError)]; 00216 aA = test ? 0 : opaq; 00217 if (test && PassTest(sim,maxim,means)) 00218 { 00219 if (norm) 00220 { 00221 float normSim = sim/maxim; 00222 aR = normSim * r; 00223 aG = normSim * g; 00224 aB = normSim * b; 00225 } 00226 aA = opaq; 00227 } 00228 glColor4ub(aR,aG,aB,aA); 00229 float x = (float) Unit2Pixel(i*40); 00230 if (hRange) 00231 lineY = (mAxisY + 2 + sim * hRange); 00232 glVertex2f(x,lineY); 00233 } 00234 glEnd(); 00235 oglSys.EndBlend(bInfo); 00236 glLineWidth(1); 00237 }
Here is the call graph for this function:
|