From b7f1010c8fce09096057528f7cd29589ea1ae7df Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sat, 6 Oct 2012 13:29:37 +0200 Subject: tools: do not use av_pix_fmt_descriptors directly. --- avprobe.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'avprobe.c') diff --git a/avprobe.c b/avprobe.c index 16a5d29ebb..3a3ae0fa7d 100644 --- a/avprobe.c +++ b/avprobe.c @@ -584,6 +584,7 @@ static void show_stream(AVFormatContext *fmt_ctx, int stream_idx) const char *profile; char val_str[128]; AVRational display_aspect_ratio; + const AVPixFmtDescriptor *desc; probe_object_header("stream"); @@ -629,9 +630,8 @@ static void show_stream(AVFormatContext *fmt_ctx, int stream_idx) rational_string(val_str, sizeof(val_str), ":", &display_aspect_ratio)); } - probe_str("pix_fmt", - dec_ctx->pix_fmt != AV_PIX_FMT_NONE ? - av_pix_fmt_descriptors[dec_ctx->pix_fmt].name : "unknown"); + desc = av_pix_fmt_desc_get(dec_ctx->pix_fmt); + probe_str("pix_fmt", desc ? desc->name : "unknown"); probe_int("level", dec_ctx->level); break; -- cgit v1.2.3