~mixxxdevelopers/mixxx/mixxx-buildserver

« back to all changes in this revision

Viewing changes to mixxx/src/analyserwavesummary.cpp

  • Committer: Albert Santoni
  • Date: 2011-03-20 00:27:15 UTC
  • mfrom: (2607.1.162 mixxx-1.9)
  • Revision ID: alberts@mixxx.org-20110320002715-sa2d88zbuc5kkyya
MergedĀ fromĀ 1.9

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
    Q_UNUSED(sampleRate);
22
22
    // Check if the preview has already been generated
23
23
    const QByteArray* p = tio->getWaveSummary();
24
 
   if(p != NULL && p->size() > 0) {
 
24
    if(p != NULL && p->size() > 0) {
25
25
        return;
26
26
    }
27
27
 
47
47
 
48
48
    //qDebug() << "AnalyserWavesummary::process() processing " << iLen << " samples";
49
49
 
50
 
    for(int i=0; i<iLen; i++) {
 
50
    for(int i=0; i<iLen && m_iCurPos+2 < m_pData->size() ; i++) {
51
51
        if(m_iBufferPos >= m_iStrideLength) {
52
 
 
53
52
            (*m_pData)[m_iCurPos] = (char)(m_fMin*127);
54
53
            (*m_pData)[m_iCurPos+1] = (char)(m_fMax*127);
55
54
            (*m_pData)[m_iCurPos+2] = 0;