diff options
author | Laszlo Ashin <kodest@gmail.com> | 2008-11-19 00:02:06 +0100 |
---|---|---|
committer | Laszlo Ashin <kodest@gmail.com> | 2008-11-19 00:02:06 +0100 |
commit | 05f4629fa3785b9596024d24eaea6f9f5afd75fa (patch) | |
tree | 5263e4157e83c3dc8d64e4e2f34a4447e251fde4 /src | |
parent | 362ca300d6daec137d0a5a2b639f0f74f2929221 (diff) | |
download | mpd-05f4629fa3785b9596024d24eaea6f9f5afd75fa.tar.gz mpd-05f4629fa3785b9596024d24eaea6f9f5afd75fa.tar.xz mpd-05f4629fa3785b9596024d24eaea6f9f5afd75fa.zip |
wavpack: redo using audio_format_frame_size()
Somehow we lost 600e1322 after renaming some variables in ed6f6046.
Diffstat (limited to '')
-rw-r--r-- | src/decoder/wavpack_plugin.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/decoder/wavpack_plugin.c b/src/decoder/wavpack_plugin.c index 224895f25..377174e51 100644 --- a/src/decoder/wavpack_plugin.c +++ b/src/decoder/wavpack_plugin.c @@ -157,12 +157,7 @@ wavpack_decode(struct decoder *decoder, WavpackContext *wpc, bool can_seek, total_time = WavpackGetNumSamples(wpc); total_time /= audio_format.sample_rate; bytes_per_sample = WavpackGetBytesPerSample(wpc); - - output_sample_size = bytes_per_sample; - if (output_sample_size == 3) { - output_sample_size = 4; - } - output_sample_size *= audio_format.channels; + output_sample_size = audio_format_frame_size(&audio_format); /* wavpack gives us all kind of samples in a 32-bit space */ samples_requested = sizeof(chunk) / (4 * audio_format.channels); |