aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJanne Grunau <janne-libav@jannau.net>2012-02-21 16:34:08 +0100
committerReinhard Tartler <siretart@tauware.de>2012-02-26 10:03:16 +0100
commit62beae313a4f91e8ff4e8dc0b2ec78baaa804b32 (patch)
treeb3a1fb3e5cabfc909b68d0fd14b229935993d641
parent8011a29fa8875aa4de54199bdfcd4e5331d532dd (diff)
downloadffmpeg-62beae313a4f91e8ff4e8dc0b2ec78baaa804b32.tar.gz
avplay: fix -threads option
The AVOptions based default to threads auto in 2473a45c8 works only if avplay does not use custom option handling for -threads. CC: <libav-stable@libav.org> (cherry picked from commit e48a70e6da02cd5426b6340af70410bdfe27dfa7) Signed-off-by: Anton Khirnov <anton@khirnov.net>
-rw-r--r--avplay.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/avplay.c b/avplay.c
index 432afc11b3..57fb864ea8 100644
--- a/avplay.c
+++ b/avplay.c
@@ -242,7 +242,6 @@ static int64_t duration = AV_NOPTS_VALUE;
static int debug = 0;
static int debug_mv = 0;
static int step = 0;
-static int thread_count = 1;
static int workaround_bugs = 1;
static int fast = 0;
static int genpts = 0;
@@ -2189,7 +2188,6 @@ static int stream_component_open(VideoState *is, int stream_index)
avctx->skip_loop_filter = skip_loop_filter;
avctx->error_recognition = error_recognition;
avctx->error_concealment = error_concealment;
- avctx->thread_count = thread_count;
if (lowres) avctx->flags |= CODEC_FLAG_EMU_EDGE;
if (fast) avctx->flags2 |= CODEC_FLAG2_FAST;
@@ -2954,15 +2952,6 @@ static int opt_vismv(const char *opt, const char *arg)
return 0;
}
-static int opt_thread_count(const char *opt, const char *arg)
-{
- thread_count = parse_number_or_die(opt, arg, OPT_INT64, 0, INT_MAX);
-#if !HAVE_THREADS
- fprintf(stderr, "Warning: not compiled with thread support, using thread emulation\n");
-#endif
- return 0;
-}
-
static const OptionDef options[] = {
#include "cmdutils_common_opts.h"
{ "x", HAS_ARG, { (void*)opt_width }, "force displayed width", "width" },
@@ -2995,7 +2984,6 @@ static const OptionDef options[] = {
{ "er", OPT_INT | HAS_ARG | OPT_EXPERT, { (void*)&error_recognition }, "set error detection threshold (0-4)", "threshold" },
{ "ec", OPT_INT | HAS_ARG | OPT_EXPERT, { (void*)&error_concealment }, "set error concealment options", "bit_mask" },
{ "sync", HAS_ARG | OPT_EXPERT, { (void*)opt_sync }, "set audio-video sync. type (type=audio/video/ext)", "type" },
- { "threads", HAS_ARG | OPT_EXPERT, { (void*)opt_thread_count }, "thread count", "count" },
{ "autoexit", OPT_BOOL | OPT_EXPERT, { (void*)&autoexit }, "exit at the end", "" },
{ "exitonkeydown", OPT_BOOL | OPT_EXPERT, { (void*)&exit_on_keydown }, "exit on key down", "" },
{ "exitonmousedown", OPT_BOOL | OPT_EXPERT, { (void*)&exit_on_mousedown }, "exit on mouse down", "" },