aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2013-01-29 19:10:04 +0200
committerMartin Storsjö <martin@martin.st>2013-01-30 13:45:45 +0200
commit61d36761efda663c5ce07a5ec13659431b08f3c2 (patch)
tree4e0d7a1b3d5414a3f47783f878dd92c2a0e37384
parent4e0bc996d9955a86c7949584bfbec386517ac795 (diff)
downloadffmpeg-61d36761efda663c5ce07a5ec13659431b08f3c2.tar.gz
movenc: Simplify code by using avio_wb24
Signed-off-by: Martin Storsjö <martin@martin.st>
-rw-r--r--libavformat/movenc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index 39495203df..496158c10a 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -305,8 +305,7 @@ static int mov_write_esds_tag(AVIOContext *pb, MOVTrack *track) // Basic
else
avio_w8(pb, 0x11); // flags (= Visualstream)
- avio_w8(pb, track->enc->rc_buffer_size>>(3+16)); // Buffersize DB (24 bits)
- avio_wb16(pb, (track->enc->rc_buffer_size>>3)&0xFFFF); // Buffersize DB
+ avio_wb24(pb, track->enc->rc_buffer_size >> 3); // Buffersize DB
avio_wb32(pb, FFMAX(track->enc->bit_rate, track->enc->rc_max_rate)); // maxbitrate (FIXME should be max rate in any 1 sec window)
if(track->enc->rc_max_rate != track->enc->rc_min_rate || track->enc->rc_min_rate==0)