summaryrefslogtreecommitdiff
path: root/avplay.c
diff options
context:
space:
mode:
Diffstat (limited to 'avplay.c')
-rw-r--r--avplay.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/avplay.c b/avplay.c
index 85e03770e5..432afc11b3 100644
--- a/avplay.c
+++ b/avplay.c
@@ -2194,6 +2194,8 @@ static int stream_component_open(VideoState *is, int stream_index)
if (lowres) avctx->flags |= CODEC_FLAG_EMU_EDGE;
if (fast) avctx->flags2 |= CODEC_FLAG2_FAST;
+ if (!av_dict_get(opts, "threads", NULL, 0))
+ av_dict_set(&opts, "threads", "auto", 0);
if (!codec ||
avcodec_open2(avctx, codec, &opts) < 0)
return -1;