1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-28 20:53:54 +02:00

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
This commit is contained in:
Baptiste Coudurier 2009-03-15 07:23:18 +00:00
parent f0f2218dce
commit 3d45a83a59

View File

@ -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", "" },