vaapi_h264: Scale log2_max_pic_order_cnt_lsb with max_b_frames
authorMark Thompson <sw@jkqxz.net>
Wed, 4 Jan 2017 23:05:10 +0000 (23:05 +0000)
committerMark Thompson <sw@jkqxz.net>
Wed, 11 Jan 2017 23:03:58 +0000 (23:03 +0000)
commit89725a8512721fffd190021ded2d3f5b42e20e2a
tree85a2924c63bbbcc39fec8eaa66880464e4c013a7
parenta3c3a5eac20a51d402c332cdf5220fff40a7943f
vaapi_h264: Scale log2_max_pic_order_cnt_lsb with max_b_frames

Before this change, it was possible to overflow pic_order_cnt_lsb and
generate a stream with invalid POC numbering.  This makes sure that
the field is large enough that a single IDR B* P sequence uses fewer
than half the available POC lsb values.
libavcodec/vaapi_encode_h264.c