aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-08-04 04:14:43 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-08-04 04:14:43 +0200
commit2aeeb3ba1f4fa54d0cd4cca672bc56dea07af133 (patch)
treed6afd3f7c7dd263345e625406f50cd3620b3ef23
parent66eacd55807c4b0c257d644d2ee3156a43f6ba5b (diff)
parentf89d76c10355242c39b08f253c1d1524f45ef778 (diff)
downloadffmpeg-2aeeb3ba1f4fa54d0cd4cca672bc56dea07af133.tar.gz
Merge commit 'f89d76c10355242c39b08f253c1d1524f45ef778'
* commit 'f89d76c10355242c39b08f253c1d1524f45ef778': mpeg4video: Initialize xvididct for all threads Conflicts: libavcodec/mpeg4videodec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/mpeg4videodec.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/mpeg4videodec.c b/libavcodec/mpeg4videodec.c
index 6ff9aaf361..f5eec3f2d1 100644
--- a/libavcodec/mpeg4videodec.c
+++ b/libavcodec/mpeg4videodec.c
@@ -2687,6 +2687,7 @@ static int mpeg4_update_thread_context(AVCodecContext *dst,
{
Mpeg4DecContext *s = dst->priv_data;
const Mpeg4DecContext *s1 = src->priv_data;
+ int init = s->m.context_initialized;
int ret = ff_mpeg_update_thread_context(dst, src);
@@ -2695,6 +2696,9 @@ static int mpeg4_update_thread_context(AVCodecContext *dst,
memcpy(((uint8_t*)s) + sizeof(MpegEncContext), ((uint8_t*)s1) + sizeof(MpegEncContext), sizeof(Mpeg4DecContext) - sizeof(MpegEncContext));
+ if (CONFIG_MPEG4_DECODER && !init && s1->xvid_build >= 0)
+ ff_xvididct_init(&s->m.idsp, dst);
+
return 0;
}