Changeset 018e511


Ignore:
Timestamp:
Dec 8, 2013, 5:52:09 PM (7 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/constantq, feature/pitchshift, feature/pydocstrings, feature/timestretch, master, pitchshift, sampler, timestretch, yinfft+
Children:
969bbb2
Parents:
6bc52cc
Message:

src/io/source_{avcodec,sndfile}.c: add and improve warnings about upsampling

Location:
src/io
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/io/source_avcodec.c

    r6bc52cc r018e511  
    161161  }
    162162  s->samplerate = samplerate;
     163
     164  if (s->samplerate >  s->input_samplerate) {
     165    AUBIO_WRN("upsampling %s from %d to %d\n", s->path,
     166        s->input_samplerate, s->samplerate);
     167  }
    163168
    164169  AVFrame *avFrame = s->avFrame;
  • src/io/source_sndfile.c

    r6bc52cc r018e511  
    122122      // we would need to add a ring buffer for these
    123123      if ( (uint_t)(s->input_hop_size * s->ratio + .5)  != s->hop_size ) {
    124         AUBIO_ERR("can not upsample from %d to %d\n", s->input_samplerate, s->samplerate);
     124        AUBIO_ERR("can not upsample %s from %d to %d\n", s->path,
     125            s->input_samplerate, s->samplerate);
    125126        goto beach;
    126127      }
    127       AUBIO_WRN("upsampling %s from %d to % d\n", s->path, s->input_samplerate, s->samplerate);
     128      AUBIO_WRN("upsampling %s from %d to %d\n", s->path,
     129          s->input_samplerate, s->samplerate);
    128130    }
    129131  }
Note: See TracChangeset for help on using the changeset viewer.