summaryrefslogtreecommitdiff
path: root/libavcodec/mpegvideo_enc.c
diff options
context:
space:
mode:
authorSteinar H. Gunderson <steinar+ffmpeg@gunderson.no>2020-07-18 16:53:02 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2020-07-19 10:59:43 +0200
commitc63c303a1f2b58677d480505ec93a90f77dd25b5 (patch)
tree8a02ba722f893b29545a4446b5e92ad31cb3b76a /libavcodec/mpegvideo_enc.c
parente39490615fcae8e9399e907a63f07aa8d0f9148d (diff)
avcodec/put_bits: Parametrize bit buffer type
Preparatory patch for making the bit buffer different size on different platforms; make a typedef and make all the hardcoded sizes into expressions deriving from this size. No functional change; generated assembler is near-identical. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/mpegvideo_enc.c')
-rw-r--r--libavcodec/mpegvideo_enc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index c3ef40556a..21c30a9f8a 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -3914,7 +3914,7 @@ static int encode_picture(MpegEncContext *s, int picture_number)
s->avctx->execute(s->avctx, encode_thread, &s->thread_context[0], NULL, context_count, sizeof(void*));
for(i=1; i<context_count; i++){
if (s->pb.buf_end == s->thread_context[i]->pb.buf)
- set_put_bits_buffer_size(&s->pb, FFMIN(s->thread_context[i]->pb.buf_end - s->pb.buf, INT_MAX/8-32));
+ set_put_bits_buffer_size(&s->pb, FFMIN(s->thread_context[i]->pb.buf_end - s->pb.buf, INT_MAX/8-BUF_BITS));
merge_context_after_encode(s, s->thread_context[i]);
}
emms_c();