Changeset 4bc10e2 for examples


Ignore:
Timestamp:
Oct 30, 2018, 12:57:10 PM (5 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master
Children:
81abf91, 9b23815e, ed596f7
Parents:
357f81e (diff), cefa29d (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' into feature/earlynoteoff

Location:
examples
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • examples/parse_args.h

    r357f81e r4bc10e2  
    6666extern int blocks;
    6767
    68 extern fvec_t *ibuf;
    69 extern fvec_t *obuf;
     68extern fvec_t *input_buffer;
     69extern fvec_t *output_buffer;
    7070
    7171const char *prog_name;
     
    212212  };
    213213#endif /* HAVE_GETOPT_H */
    214   prog_name = argv[0];
     214  // better safe than sorry
    215215  if (argc < 1) {
    216216    usage (stderr, 1);
    217     return -1;
    218   }
     217  }
     218  prog_name = argv[0];
    219219#ifdef HAVE_GETOPT_H
    220220  do {
  • examples/utils.c

    r357f81e r4bc10e2  
    6464aubio_source_t *this_source = NULL;
    6565aubio_sink_t *this_sink = NULL;
    66 fvec_t *ibuf;
    67 fvec_t *obuf;
     66fvec_t *input_buffer;
     67fvec_t *output_buffer;
    6868
    6969smpl_t miditap_note = 69.;
     
    127127#endif /* HAVE_JACK */
    128128  }
    129   ibuf = new_fvec (hop_size);
    130   obuf = new_fvec (hop_size);
     129  input_buffer = new_fvec (hop_size);
     130  output_buffer = new_fvec (hop_size);
    131131
    132132}
     
    134134void examples_common_del (void)
    135135{
    136   del_fvec (ibuf);
    137   del_fvec (obuf);
     136  del_fvec (input_buffer);
     137  del_fvec (output_buffer);
    138138  aubio_cleanup ();
    139139  fflush(stderr);
     
    167167
    168168    do {
    169       aubio_source_do (this_source, ibuf, &read);
    170       process_func (ibuf, obuf);
     169      aubio_source_do (this_source, input_buffer, &read);
     170      process_func (input_buffer, output_buffer);
    171171      // print to console if verbose or no output given
    172172      if (verbose || sink_uri == NULL) {
     
    174174      }
    175175      if (this_sink) {
    176         aubio_sink_do (this_sink, obuf, hop_size);
     176        aubio_sink_do (this_sink, output_buffer, hop_size);
    177177      }
    178178      blocks++;
Note: See TracChangeset for help on using the changeset viewer.