Mercurial > libavcodec.hg
comparison mlp_parser.c @ 8276:9149588e5cc9 libavcodec
mlp: support bit-depths greater than 16 by default.
| author | ramiro |
|---|---|
| date | Sun, 07 Dec 2008 00:57:26 +0000 |
| parents | 82dbfe8d2e0b |
| children | e9d9d946f213 |
comparison
equal
deleted
inserted
replaced
| 8275:e2ef97f0ab4b | 8276:9149588e5cc9 |
|---|---|
| 249 | 249 |
| 250 init_get_bits(&gb, buf + 4, (buf_size - 4) << 3); | 250 init_get_bits(&gb, buf + 4, (buf_size - 4) << 3); |
| 251 if (ff_mlp_read_major_sync(avctx, &mh, &gb) < 0) | 251 if (ff_mlp_read_major_sync(avctx, &mh, &gb) < 0) |
| 252 goto lost_sync; | 252 goto lost_sync; |
| 253 | 253 |
| 254 #ifdef CONFIG_AUDIO_NONSHORT | |
| 255 avctx->bits_per_raw_sample = mh.group1_bits; | 254 avctx->bits_per_raw_sample = mh.group1_bits; |
| 256 if (avctx->bits_per_raw_sample > 16) | 255 if (avctx->bits_per_raw_sample > 16) |
| 257 avctx->sample_fmt = SAMPLE_FMT_S32; | 256 avctx->sample_fmt = SAMPLE_FMT_S32; |
| 258 #endif | 257 else |
| 258 avctx->sample_fmt = SAMPLE_FMT_S16; | |
| 259 avctx->sample_rate = mh.group1_samplerate; | 259 avctx->sample_rate = mh.group1_samplerate; |
| 260 avctx->frame_size = mh.access_unit_size; | 260 avctx->frame_size = mh.access_unit_size; |
| 261 | 261 |
| 262 if (mh.stream_type == 0xbb) { | 262 if (mh.stream_type == 0xbb) { |
| 263 /* MLP stream */ | 263 /* MLP stream */ |
