mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2025-10-28 03:13:08 +08:00
avconv: use new options parser.
This commit is contained in:
19
avconv.c
19
avconv.c
@@ -2345,22 +2345,13 @@ static int64_t getmaxrss(void)
|
||||
#endif
|
||||
}
|
||||
|
||||
static void parse_cpuflags(int argc, char **argv, const OptionDef *options)
|
||||
{
|
||||
int idx = locate_option(argc, argv, options, "cpuflags");
|
||||
if (idx && argv[idx + 1])
|
||||
opt_cpuflags(NULL, "cpuflags", argv[idx + 1]);
|
||||
}
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
OptionsContext o = { 0 };
|
||||
int ret;
|
||||
int64_t ti;
|
||||
|
||||
atexit(exit_program);
|
||||
|
||||
reset_options(&o);
|
||||
|
||||
av_log_set_flags(AV_LOG_SKIP_REPEATED);
|
||||
parse_loglevel(argc, argv, options);
|
||||
|
||||
@@ -2374,10 +2365,10 @@ int main(int argc, char **argv)
|
||||
|
||||
show_banner();
|
||||
|
||||
parse_cpuflags(argc, argv, options);
|
||||
|
||||
/* parse options */
|
||||
parse_options(&o, argc, argv, options, opt_output_file);
|
||||
/* parse options and open all input/output files */
|
||||
ret = avconv_parse_options(argc, argv);
|
||||
if (ret < 0)
|
||||
exit(1);
|
||||
|
||||
if (nb_output_files <= 0 && nb_input_files == 0) {
|
||||
show_usage();
|
||||
|
||||
Reference in New Issue
Block a user