aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRonald S. Bultje <rsbultje@gmail.com>2013-12-23 21:41:35 -0500
committerMichael Niedermayer <michaelni@gmx.at>2013-12-24 11:43:08 +0100
commit4a55bffad32e266d96b72b40cf1a7d085e7fce93 (patch)
tree95af8cefd3baeec3a91cfcf7ff7a6b9dd9dd9868
parentb2597042e5a7776d5cf0350e9cac9dcbbd7d9268 (diff)
downloadffmpeg-4a55bffad32e266d96b72b40cf1a7d085e7fce93.tar.gz
vp9: fix bug in updating of coef probabilities with parallelmode=1.
Fixes trac ticket 3228. Reviewed-by: Clément Bœsch <u@pkh.me> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/vp9.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libavcodec/vp9.c b/libavcodec/vp9.c
index a52924c7c9..88c5bc61b0 100644
--- a/libavcodec/vp9.c
+++ b/libavcodec/vp9.c
@@ -3547,13 +3547,16 @@ static int vp9_decode_frame(AVCodecContext *ctx, void *frame,
if (s->refreshctx && s->parallelmode) {
int j, k, l, m;
- for (i = 0; i < 4; i++)
+ for (i = 0; i < 4; i++) {
for (j = 0; j < 2; j++)
for (k = 0; k < 2; k++)
for (l = 0; l < 6; l++)
for (m = 0; m < 6; m++)
memcpy(s->prob_ctx[s->framectxid].coef[i][j][k][l][m],
s->prob.coef[i][j][k][l][m], 3);
+ if (s->txfmmode == i)
+ break;
+ }
s->prob_ctx[s->framectxid].p = s->prob.p;
ff_thread_finish_setup(ctx);
}