aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJun Zhao <barryjzhao@tencent.com>2020-04-09 21:54:01 +0800
committerJun Zhao <barryjzhao@tencent.com>2020-04-14 11:42:29 +0800
commit5633f9a8a221f7511d5ec9b4c57a21c890271ad0 (patch)
treee1c98b4e38485fc9f6ae2623cf3d8e40d68226d7
parentf0d712d0f95ba757943cc6d49a8caa2e1adfb6e7 (diff)
downloadffmpeg-5633f9a8a221f7511d5ec9b4c57a21c890271ad0.tar.gz
fftools: fix hwaccels option dump redundancy
When QSV is enabled in FFmpeg, the command "ffmpeg -hwaccels" shows a duplicate entry in acceleration methods for QSV: Hardware acceleration methods: vaapi qsv drm opencl qsv Reviewed-by: Mark Thompson <sw@jkqxz.net> Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
-rw-r--r--fftools/ffmpeg_opt.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
index 95001a963f..93b3d96205 100644
--- a/fftools/ffmpeg_opt.c
+++ b/fftools/ffmpeg_opt.c
@@ -233,14 +233,11 @@ static void init_options(OptionsContext *o)
static int show_hwaccels(void *optctx, const char *opt, const char *arg)
{
enum AVHWDeviceType type = AV_HWDEVICE_TYPE_NONE;
- int i;
printf("Hardware acceleration methods:\n");
while ((type = av_hwdevice_iterate_types(type)) !=
AV_HWDEVICE_TYPE_NONE)
printf("%s\n", av_hwdevice_get_type_name(type));
- for (i = 0; hwaccels[i].name; i++)
- printf("%s\n", hwaccels[i].name);
printf("\n");
return 0;
}
@@ -936,8 +933,6 @@ static void add_input_streams(OptionsContext *o, AVFormatContext *ic)
AV_HWDEVICE_TYPE_NONE)
av_log(NULL, AV_LOG_FATAL, "%s ",
av_hwdevice_get_type_name(type));
- for (i = 0; hwaccels[i].name; i++)
- av_log(NULL, AV_LOG_FATAL, "%s ", hwaccels[i].name);
av_log(NULL, AV_LOG_FATAL, "\n");
exit_program(1);
}