#include "utils_tests.h"
{
for (i = 0; i < vec->
length; i++) {
assert(vec->
data[i] == scalar);
}
}
int main (void)
{
assert(vec);
assert(vec->
length == length);
assert_lvec_all_equal(vec, 2.);
assert_lvec_all_equal(vec, 1.);
assert_lvec_all_equal(vec, 0.);
return 0;
}
Global aubio include file.
void lvec_ones(lvec_t *s)
set all elements to ones
void lvec_zeros(lvec_t *s)
set all elements to zero
void del_lvec(lvec_t *s)
lvec_t buffer deletion function
lsmp_t lvec_get_sample(lvec_t *s, uint_t position)
read sample value in a buffer
lvec_t * new_lvec(uint_t length)
lvec_t buffer creation function
void lvec_set_all(lvec_t *s, smpl_t val)
set all elements to a given value
void lvec_set_sample(lvec_t *s, lsmp_t data, uint_t position)
write sample value in a buffer
void lvec_print(const lvec_t *s)
print out lvec data
lsmp_t * lvec_get_data(const lvec_t *s)
read data from a buffer
Buffer for real data in double precision.
uint_t length
length of buffer
lsmp_t * data
data array of size [length]
#define AUBIO_LSMP_FMT
print format for sample in double precision
unsigned int uint_t
unsigned integer
double lsmp_t
long sample format (64 bits or more)