Changeset 6e6849d


Ignore:
Timestamp:
Sep 21, 2016, 5:10:56 PM (8 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/cnn, feature/crepe, feature/pitchshift, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch
Children:
25a19c2
Parents:
9953f09
Message:

tests/src/effects/test-pitchshift.c: add option for mode, shuffle options order

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/src/effects/test-pitchshift.c

    r9953f09 r6e6849d  
    1010    err = 2;
    1111    PRINT_ERR("not enough arguments\n");
    12     PRINT_MSG("usage: %s <input_path> <output_path> <transpose> [samplerate] [hop_size]\n", argv[0]);
     12    PRINT_MSG("usage: %s <input_path> <output_path> <transpose> [mode] [hop_size] [samplerate]\n", argv[0]);
    1313    PRINT_MSG(" with <transpose> a number of semi tones in the range [-24, 24]\n");
     14    PRINT_MSG(" and [mode] in 'default', 'crispness:0', ..., 'crispness:6'\n");
    1415    return err;
    1516  }
     
    2324  char_t *source_path = argv[1];
    2425  char_t *sink_path = argv[2];
     26  char_t *mode = "default";
    2527
    2628  transpose = atof(argv[3]);
    2729
    28   if ( argc >= 5 ) samplerate = atoi(argv[4]);
     30  if ( argc >= 5 ) mode = argv[4];
    2931  if ( argc >= 6 ) hop_size = atoi(argv[5]);
    30   if ( argc >= 7 ) {
     32  if ( argc >= 7 ) samplerate = atoi(argv[6]);
     33  if ( argc >= 8 ) {
    3134    err = 2;
    3235    PRINT_ERR("too many arguments\n");
     
    4649  if (!o) { err = 1; goto beach_sink; }
    4750
    48   aubio_pitchshift_t *ps = new_aubio_pitchshift("default", transpose, hop_size, samplerate);
     51  aubio_pitchshift_t *ps = new_aubio_pitchshift(mode, transpose, hop_size, samplerate);
    4952  if (!ps) { err = 1; goto beach_pitchshift; }
    5053
Note: See TracChangeset for help on using the changeset viewer.