diff options
author | sanine <sanine.not@pm.me> | 2022-08-26 12:17:51 -0500 |
---|---|---|
committer | sanine <sanine.not@pm.me> | 2022-08-26 12:17:51 -0500 |
commit | 8ec3f8e82acd70410515550fd1790ee5827aafdb (patch) | |
tree | 348e32b7fe2f0e765d3acf91fa857880d8f6c3f6 /src/mossrose-channel.h | |
parent | a20cdab55ba066301da138c4df945608524e741a (diff) |
make sound
Diffstat (limited to 'src/mossrose-channel.h')
-rw-r--r-- | src/mossrose-channel.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/mossrose-channel.h b/src/mossrose-channel.h new file mode 100644 index 0000000..e1db89d --- /dev/null +++ b/src/mossrose-channel.h @@ -0,0 +1,26 @@ +#ifndef MOSSROSE_CHANNEL_H +#define MOSSROSE_CHANNEL_H + +#include <stddef.h> +#include "mossrose-mutex.h" + +struct mossrose_channel_t { + mossrose_mutex_t mutex; + float *left; + float *right; + size_t n_samples; + size_t pos; +}; + + +void mossrose_channel_init(struct mossrose_channel_t *chan); + +int mossrose_channel_set(struct mossrose_channel_t *chan, float *left, float *right, size_t len, int force); + +void mossrose_channel_reset(struct mossrose_channel_t *chan); + +int mossrose_channel_advance(float *left, float *right, struct mossrose_channel_t *chan); + +void mossrose_channel_destroy(struct mossrose_channel_t *chan); + +#endif |