summaryrefslogtreecommitdiff
path: root/libavformat/mov.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2011-11-06 02:18:50 +0100
committerMichael Niedermayer <michaelni@gmx.at>2011-11-06 02:23:34 +0100
commitd8cab5c26b0987f139830937e1f30b2a10822680 (patch)
tree1328facddcdaeac6881f32b7b3511806a68d2111 /libavformat/mov.c
parent3b4798a87375c6090215185a87d51358cbb5af84 (diff)
parent18ae3626405a8b3d6dbb7e5b848d354cd7bf9a47 (diff)
Merge remote-tracking branch 'qatar/master'
* qatar/master: http: Remove the custom function for disabling chunked posts rtsp: Disable chunked http post through AVOptions movdec: Set frame_size for AMR h264_weight: remove duplication functions. swscale: align vertical filtersize by 2 on x86. libavfilter: reindent. matroskadec: empty blocks are in fact valid. avfilter: don't abort() on zero-size allocations. h264: improve calculation of codec delay. movenc: Set a correct packet size for AMR-NB mode 15, "no data" avformat: Add functions for doing global network initialization avformat: Add the https protocol avformat: Add the tls protocol, using OpenSSL or gnutls avformat: Initialize gnutls in ff_tls_init() w32threads: Wrap the mutex functions in inline functions returning int configure: Allow linking to the gnutls library avformat: Add ff_tls_init()/deinit() that initialize OpenSSL configure: Allow linking to openssl avcodec: Allow locking and unlocking an avformat specific mutex avformat: Split out functions from network.h to a new file, network.c Conflicts: Changelog configure doc/APIchanges libavcodec/internal.h libavcodec/version.h libavfilter/formats.c libavformat/matroskadec.c libavformat/mov.c libavformat/version.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/mov.c')
-rw-r--r--libavformat/mov.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c
index c90004cbae..e6efe27195 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -1346,17 +1346,16 @@ int ff_mov_read_stsd_entries(MOVContext *c, AVIOContext *pb, int entries)
st->codec->channels= 1; /* really needed */
break;
case CODEC_ID_AMR_NB:
- case CODEC_ID_AMR_WB:
- 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) {
- st->codec->sample_rate = 8000;
- 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;
- }
+ st->codec->sample_rate = 8000;
+ /* force frame_size, too, samples_per_frame isn't always set properly */
+ st->codec->frame_size = 160;
+ break;
+ case CODEC_ID_AMR_WB:
+ st->codec->channels = 1;
+ st->codec->sample_rate = 16000;
+ st->codec->frame_size = 320;
break;
case CODEC_ID_MP2:
case CODEC_ID_MP3: