aboutsummaryrefslogtreecommitdiffstats
path: root/ffmpeg.c
diff options
context:
space:
mode:
authorBaptiste Coudurier <baptiste.coudurier@gmail.com>2009-03-15 07:23:18 +0000
committerBaptiste Coudurier <baptiste.coudurier@gmail.com>2009-03-15 07:23:18 +0000
commit3d45a83a593eb8f88917db927ae97fdbf0895993 (patch)
treec680d304926b3c1153e77b3a88fa7a1bac83766d /ffmpeg.c
parentf0f2218dce194ff50d1fe7ed39011595660143ad (diff)
downloadffmpeg-3d45a83a593eb8f88917db927ae97fdbf0895993.tar.gz
add loglevel option to set libav* logging level, -v does not set it anymore
Originally committed as revision 17973 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'ffmpeg.c')
-rw-r--r--ffmpeg.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index c95549a8ca..57770e630d 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -2321,10 +2321,15 @@ static int opt_me_threshold(const char *opt, const char *arg)
return 0;
}
+static void opt_loglevel(const char *opt, const char *arg)
+{
+ int level = parse_number_or_die(opt, arg, OPT_INT, INT_MIN, INT_MAX);
+ av_log_set_level(level);
+}
+
static int opt_verbose(const char *opt, const char *arg)
{
verbose = parse_number_or_die(opt, arg, OPT_INT64, -10, 10);
- av_log_set_level(verbose);
return 0;
}
@@ -3806,7 +3811,8 @@ static const OptionDef options[] = {
{ "re", OPT_BOOL | OPT_EXPERT, {(void*)&rate_emu}, "read input at native frame rate", "" },
{ "loop_input", OPT_BOOL | OPT_EXPERT, {(void*)&loop_input}, "loop (current only works with images)" },
{ "loop_output", HAS_ARG | OPT_INT | OPT_EXPERT, {(void*)&loop_output}, "number of times to loop output in formats that support looping (0 loops forever)", "" },
- { "v", HAS_ARG | OPT_FUNC2, {(void*)opt_verbose}, "set the logging verbosity level", "number" },
+ { "v", HAS_ARG | OPT_FUNC2, {(void*)opt_verbose}, "set ffmpeg verbosity level", "number" },
+ { "loglevel", HAS_ARG | OPT_FUNC2, {(void*)opt_loglevel}, "set libav* logging level", "number" },
{ "target", HAS_ARG, {(void*)opt_target}, "specify target file type (\"vcd\", \"svcd\", \"dvd\", \"dv\", \"dv50\", \"pal-vcd\", \"ntsc-svcd\", ...)", "type" },
{ "threads", OPT_FUNC2 | HAS_ARG | OPT_EXPERT, {(void*)opt_thread_count}, "thread count", "count" },
{ "vsync", HAS_ARG | OPT_INT | OPT_EXPERT, {(void*)&video_sync_method}, "video sync method", "" },