mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-26 19:01:44 +02:00
Set frame_size for AMR_NB in mov.
This copies the behaviour of the amr demuxer.
This commit is contained in:
parent
4eb86d348f
commit
a487378ef5
@ -1350,10 +1350,13 @@ int ff_mov_read_stsd_entries(MOVContext *c, AVIOContext *pb, int entries)
|
||||
st->codec->frame_size= sc->samples_per_frame;
|
||||
st->codec->channels= 1; /* really needed */
|
||||
/* force sample rate for amr, stsd in 3gp does not store sample rate */
|
||||
if (st->codec->codec_id == CODEC_ID_AMR_NB)
|
||||
if (st->codec->codec_id == CODEC_ID_AMR_NB) {
|
||||
st->codec->sample_rate = 8000;
|
||||
else if (st->codec->codec_id == CODEC_ID_AMR_WB)
|
||||
st->codec->frame_size = 160;
|
||||
} else if (st->codec->codec_id == CODEC_ID_AMR_WB) {
|
||||
st->codec->sample_rate = 16000;
|
||||
st->codec->frame_size = 320;
|
||||
}
|
||||
break;
|
||||
case CODEC_ID_MP2:
|
||||
case CODEC_ID_MP3:
|
||||
|
Loading…
Reference in New Issue
Block a user