source: tests/src/test-fvec.c @ fa11ce0

feature/autosinkfeature/cnnfeature/cnn_orgfeature/constantqfeature/crepefeature/crepe_orgfeature/pitchshiftfeature/pydocstringsfeature/timestretchfix/ffmpeg5pitchshiftsamplertimestretchyinfft+
Last change on this file since fa11ce0 was c251b80, checked in by Paul Brossier <piem@piem.org>, 15 years ago

test-fvec.c: update

  • Property mode set to 100644
File size: 415 bytes
RevLine 
[4e9101e]1#include <aubio.h>
[c251b80]2#include <assert.h>
[4e9101e]3
4int main(){
[c251b80]5  uint_t buffer_size = 1024;
6  fvec_t * in = new_fvec (buffer_size);
[4e9101e]7
[c251b80]8  assert( in->length                == buffer_size);
9
10  assert( in->data[0]               == 0);
11  assert( in->data[buffer_size / 2] == 0);
12  assert( in->data[buffer_size - 1] == 0);
13
14  in->data[buffer_size -1 ] = 1;
15  assert( in->data[buffer_size - 1] == 1);
16
17  del_fvec(in);
18
19  return 0;
[4e9101e]20}
21
Note: See TracBrowser for help on using the repository browser.