mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-02-28 01:31:00 +00:00
cmdutils: dump supported hardware devices in print_codec()
dump the supported hardware devices for codec when use the command like ./ffmpeg -h decoder=h264. Signed-off-by: Jun Zhao <mypopydev@gmail.com>
This commit is contained in:
parent
90acf168a6
commit
81b77e7bf1
@ -1444,6 +1444,17 @@ static void print_codec(const AVCodec *c)
|
|||||||
printf("\n");
|
printf("\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (avcodec_get_hw_config(c, 0)) {
|
||||||
|
printf(" Supported hardware devices: ");
|
||||||
|
for (int i = 0;; i++) {
|
||||||
|
const AVCodecHWConfig *config = avcodec_get_hw_config(c, i);
|
||||||
|
if (!config)
|
||||||
|
break;
|
||||||
|
printf("%s ", av_hwdevice_get_type_name(config->device_type));
|
||||||
|
}
|
||||||
|
printf("\n");
|
||||||
|
}
|
||||||
|
|
||||||
if (c->supported_framerates) {
|
if (c->supported_framerates) {
|
||||||
const AVRational *fps = c->supported_framerates;
|
const AVRational *fps = c->supported_framerates;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user