diff options
author | Janne Grunau <janne-libav@jannau.net> | 2011-12-21 01:37:44 +0100 |
---|---|---|
committer | Janne Grunau <janne-libav@jannau.net> | 2011-12-22 21:50:07 +0100 |
commit | c32e4029d99fb1bff3df86f62a3ce61d2419aae0 (patch) | |
tree | 4891ea571f9ab05ef6b541731a6aff16c8ba39ce | |
parent | b9e2226972737ab202ac1f5a6e005af80072bb39 (diff) | |
download | ffmpeg-c32e4029d99fb1bff3df86f62a3ce61d2419aae0.tar.gz |
options: set minimum for "threads" to zero
A negative number of threads does not make sense and 0 is used for
autodetection. Adds a symbolic name for autodetection.
-rw-r--r-- | libavcodec/options.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/options.c b/libavcodec/options.c index a3a102c0c8..4ac9313f27 100644 --- a/libavcodec/options.c +++ b/libavcodec/options.c @@ -370,7 +370,8 @@ static const AVOption options[]={ {"float", NULL, 0, AV_OPT_TYPE_CONST, {.dbl = FF_AA_FLOAT }, INT_MIN, INT_MAX, V|D, "aa"}, #endif {"qns", "quantizer noise shaping", OFFSET(quantizer_noise_shaping), AV_OPT_TYPE_INT, {.dbl = DEFAULT }, INT_MIN, INT_MAX, V|E}, -{"threads", NULL, OFFSET(thread_count), AV_OPT_TYPE_INT, {.dbl = 1 }, INT_MIN, INT_MAX, V|E|D}, +{"threads", NULL, OFFSET(thread_count), AV_OPT_TYPE_INT, {.dbl = 1 }, 0, INT_MAX, V|E|D, "threads"}, +{"auto", "detect a good number of threads", 0, AV_OPT_TYPE_CONST, {.dbl = 0 }, INT_MIN, INT_MAX, V|E|D, "threads"}, {"me_threshold", "motion estimaton threshold", OFFSET(me_threshold), AV_OPT_TYPE_INT, {.dbl = DEFAULT }, INT_MIN, INT_MAX, V|E}, {"mb_threshold", "macroblock threshold", OFFSET(mb_threshold), AV_OPT_TYPE_INT, {.dbl = DEFAULT }, INT_MIN, INT_MAX, V|E}, {"dc", "intra_dc_precision", OFFSET(intra_dc_precision), AV_OPT_TYPE_INT, {.dbl = 0 }, INT_MIN, INT_MAX, V|E}, |