diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2021-03-25 14:52:56 +0300 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2021-03-30 13:36:32 +0300 |
commit | c81b8e04aa0952a7aec1e08940f29ae501fb6bfd (patch) | |
tree | 34c1d0dd6c2262ef83efa3ae77ea704580144050 /libavcodec/mpeg12enc.c | |
parent | 73fb1b8a9bd6a563a6b58ce8aa215f2f07e91f57 (diff) |
Avoid intermediate bitcount for number of bytes in PutBitContext
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec/mpeg12enc.c')
-rw-r--r-- | libavcodec/mpeg12enc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/mpeg12enc.c b/libavcodec/mpeg12enc.c index a05c2db6cb..5676caef87 100644 --- a/libavcodec/mpeg12enc.c +++ b/libavcodec/mpeg12enc.c @@ -439,7 +439,7 @@ void ff_mpeg1_encode_picture_header(MpegEncContext *s, int picture_number) (s->picture_number - s->gop_picture_number) & 0x3ff); put_bits(&s->pb, 3, s->pict_type); - s->vbv_delay_ptr = s->pb.buf + put_bits_count(&s->pb) / 8; + s->vbv_delay_ptr = s->pb.buf + put_bytes_count(&s->pb, 0); put_bits(&s->pb, 16, 0xFFFF); /* vbv_delay */ // RAL: Forward f_code also needed for B-frames |