wavpack: don't set sample format in init.

We don't know whether it will be float until we look at the data.
This commit is contained in:
Anton Khirnov 2013-05-26 11:02:51 +02:00
parent 35596bd4f4
commit 72dee5f40b

View File

@ -716,10 +716,7 @@ static av_cold int wavpack_decode_init(AVCodecContext *avctx)
WavpackContext *s = avctx->priv_data;
s->avctx = avctx;
if (avctx->bits_per_coded_sample <= 16)
avctx->sample_fmt = AV_SAMPLE_FMT_S16P;
else
avctx->sample_fmt = AV_SAMPLE_FMT_S32P;
if (avctx->channels <= 2 && !avctx->channel_layout)
avctx->channel_layout = (avctx->channels == 2) ? AV_CH_LAYOUT_STEREO
: AV_CH_LAYOUT_MONO;