diff options
author | Max Kellermann <max@duempel.org> | 2011-10-08 12:40:03 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2011-10-08 13:32:29 +0200 |
commit | 14424281a0e1407ca04ef05a50541a4178f70e91 (patch) | |
tree | 1e499d063b925ac2dff0ef27db253ba42ba04367 /src/pcm_resample_libsamplerate.c | |
parent | 2b3fd0d4d34be365e44fd53b3bf3c72f8b0a69ea (diff) | |
download | mpd-14424281a0e1407ca04ef05a50541a4178f70e91.tar.gz mpd-14424281a0e1407ca04ef05a50541a4178f70e91.tar.xz mpd-14424281a0e1407ca04ef05a50541a4178f70e91.zip |
pcm_resample: add internal function _lsr_init()
Let the libsamplerate code initialize itself.
Diffstat (limited to '')
-rw-r--r-- | src/pcm_resample_libsamplerate.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/pcm_resample_libsamplerate.c b/src/pcm_resample_libsamplerate.c index 769f904c1..a71659d51 100644 --- a/src/pcm_resample_libsamplerate.c +++ b/src/pcm_resample_libsamplerate.c @@ -84,6 +84,16 @@ pcm_resample_lsr_global_init(const char *converter, GError **error_r) } void +pcm_resample_lsr_init(struct pcm_resample_state *state) +{ + memset(state, 0, sizeof(*state)); + + pcm_buffer_init(&state->in); + pcm_buffer_init(&state->out); + pcm_buffer_init(&state->buffer); +} + +void pcm_resample_lsr_deinit(struct pcm_resample_state *state) { if (state->state != NULL) |