st/va: fix gop size for rate control
authorBoyuan Zhang <boyuan.zhang@amd.com>
Fri, 18 Nov 2016 20:29:56 +0000 (15:29 -0500)
committerLeo Liu <leo.liu@amd.com>
Mon, 5 Dec 2016 14:23:38 +0000 (09:23 -0500)
commit3949d7c6ead25e6191c6529a1805ba7ada6892cc
tree4e16c59ce56057397d280071f272a0144b435118
parent8206882392c9cc070e21d6fbc90368c94235d8cd
st/va: fix gop size for rate control

The gop_size in rate control is the budget window for internal rate
control calculation, and shouldn't always equal to idr period. Define
a coefficient to let budget window contains a number of idr period for
proper rate control calculation. Adjust the number of i/p frame remaining
accordingly.

Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=98005

Signed-off-by: Boyuan Zhang <boyuan.zhang@amd.com>
Acked-by: Christian König <christian.koenig@amd.com>
src/gallium/state_trackers/va/picture.c
src/gallium/state_trackers/va/va_private.h