From 32f5a0144bc8580b1d8337276294df8d55c5ef22 Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Sat, 12 Sep 2009 00:00:54 +0200 Subject: [PATCH] src/fvec.{c,h}: add simple fvec_print function --- src/fvec.c | 9 +++++++++ src/fvec.h | 7 +++++++ 2 files changed, 16 insertions(+) diff --git a/src/fvec.c b/src/fvec.c index 4b094f9c..49eda085 100644 --- a/src/fvec.c +++ b/src/fvec.c @@ -61,3 +61,12 @@ smpl_t ** fvec_get_data(fvec_t *s) { return s->data; } +void fvec_print(fvec_t *s) { + uint_t i,j; + for (i=0; i< s->channels; i++) { + for (j=0; j< s->length; j++) { + AUBIO_MSG("%f ", s->data[i][j]); + } + AUBIO_MSG("\n"); + } +} diff --git a/src/fvec.h b/src/fvec.h index 1d78852c..c3f99c14 100644 --- a/src/fvec.h +++ b/src/fvec.h @@ -113,6 +113,13 @@ void fvec_put_channel(fvec_t *s, smpl_t * data, uint_t channel); */ smpl_t ** fvec_get_data(fvec_t *s); +/** print out fvec data + + \param s vector to print out + +*/ +void fvec_print(fvec_t *s); + #ifdef __cplusplus } #endif -- 2.26.2