Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'ffprobe.c')
-rw-r--r--ffprobe.c19
1 files changed, 12 insertions, 7 deletions
diff --git a/ffprobe.c b/ffprobe.c
index 3c23aa8715..84f7d82b9b 100644
--- a/ffprobe.c
+++ b/ffprobe.c
@@ -265,17 +265,21 @@ static inline void writer_print_chapter_footer(WriterContext *wctx,
static inline void writer_print_section_header(WriterContext *wctx,
const char *section)
{
- if (wctx->writer->print_section_header)
- wctx->writer->print_section_header(wctx, section);
- wctx->nb_item = 0;
+ if (!fmt_entries_to_show || (section && av_dict_get(fmt_entries_to_show, section, NULL, 0))) {
+ if (wctx->writer->print_section_header)
+ wctx->writer->print_section_header(wctx, section);
+ wctx->nb_item = 0;
+ }
}
static inline void writer_print_section_footer(WriterContext *wctx,
const char *section)
{
- if (wctx->writer->print_section_footer)
- wctx->writer->print_section_footer(wctx, section);
- wctx->nb_section++;
+ if (!fmt_entries_to_show || (section && av_dict_get(fmt_entries_to_show, section, NULL, 0))) {
+ if (wctx->writer->print_section_footer)
+ wctx->writer->print_section_footer(wctx, section);
+ wctx->nb_section++;
+ }
}
static inline void writer_print_integer(WriterContext *wctx,
@@ -448,7 +452,8 @@ static void default_show_tags(WriterContext *wctx, AVDictionary *dict)
{
AVDictionaryEntry *tag = NULL;
while ((tag = av_dict_get(dict, "", tag, AV_DICT_IGNORE_SUFFIX))) {
- printf("TAG:");
+ if (!fmt_entries_to_show || (tag->key && av_dict_get(fmt_entries_to_show, tag->key, NULL, 0)))
+ printf("TAG:");
writer_print_string(wctx, tag->key, tag->value, 0);
}
}