Changeset 175a218
- Timestamp:
- Dec 30, 2013, 9:50:29 PM (11 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
- Children:
- 158e031
- Parents:
- 413d4bf
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified src/lvec.c ¶
r413d4bf r175a218 37 37 } 38 38 39 void lvec_ write_sample(lvec_t *s, lsmp_t data, uint_t position) {39 void lvec_set_sample(lvec_t *s, lsmp_t data, uint_t position) { 40 40 s->data[position] = data; 41 41 } 42 42 43 lsmp_t lvec_get_sample(lvec_t *s, uint_t position) { 43 44 return s->data[position]; -
TabularUnified tests/src/test-lvec.c ¶
r413d4bf r175a218 1 1 #include <aubio.h> 2 #include "utils_tests.h" 2 3 3 4 int main() 4 5 { 5 uint_t win_s = 1024; // window size6 uint_t win_s = 32; // window size 6 7 lvec_t * sp = new_lvec (win_s); // input buffer 8 lvec_set_sample (sp, 2./3., 0); 9 PRINT_MSG("%lf\n", lvec_get_sample (sp, 0)); 10 lvec_print (sp); 11 lvec_ones (sp); 12 lvec_print (sp); 13 lvec_set_all (sp, 3./5.); 14 lvec_print (sp); 7 15 del_lvec(sp); 8 16 return 0;
Note: See TracChangeset
for help on using the changeset viewer.