aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/mpeg12enc.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-01-20 04:14:09 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-01-28 01:57:39 +0100
commit59f7d583a3e467843c57278ec320efddf28097d1 (patch)
tree13f32129e13fe3ecb9350e412dba3a7139c2ecb9 /libavcodec/mpeg12enc.c
parentfb876e457279ba5c9b3ca153955a3dec7e9030de (diff)
downloadffmpeg-59f7d583a3e467843c57278ec320efddf28097d1.tar.gz
mpeg1enc: Disable threads for resolutions too large for multi-threading
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit 0c6b0409af070a3bfb02b55fde8ba18219edc76b) Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/mpeg12enc.c')
-rw-r--r--libavcodec/mpeg12enc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/mpeg12enc.c b/libavcodec/mpeg12enc.c
index cda1464c86..f2b5c05f0d 100644
--- a/libavcodec/mpeg12enc.c
+++ b/libavcodec/mpeg12enc.c
@@ -145,6 +145,9 @@ static av_cold int encode_init(AVCodecContext *avctx)
{
MpegEncContext *s = avctx->priv_data;
+ if (avctx->codec_id == AV_CODEC_ID_MPEG1VIDEO && avctx->height > 2800)
+ avctx->thread_count = 1;
+
if(ff_MPV_encode_init(avctx) < 0)
return -1;