Unified · Split
| @@ -2314,16 +2314,9 @@ static void print_ambient_viewing_environment(WriterContext *w, · 2313 unmodified lines | |||
| 2314 | 2314 | ||
| 2315 | static void print_pkt_side_data(WriterContext *w, | 2315 | static void print_pkt_side_data(WriterContext *w, |
| 2316 | AVCodecParameters *par, | 2316 | AVCodecParameters *par, |
| 2317 | const AVPacketSideData *side_data, | 2317 | const AVPacketSideData *sd, |
| 2318 | int nb_side_data, | ||
| 2319 | SectionID id_data_list, | ||
| 2320 | SectionID id_data) | 2318 | SectionID id_data) |
| 2321 | { | 2319 | { |
| 2322 | int i; | ||
| 2323 | |||
| 2324 | writer_print_section_header(w, NULL, id_data_list); | ||
| 2325 | for (i = 0; i < nb_side_data; i++) { | ||
| 2326 | const AVPacketSideData *sd = &side_data[i]; | ||
| 2327 | const char *name = av_packet_side_data_name(sd->type); | 2320 | const char *name = av_packet_side_data_name(sd->type); |
| 2328 | 2321 | ||
| 2329 | writer_print_section_header(w, (void *)sd, id_data); | 2322 | writer_print_section_header(w, (void *)sd, id_data); |
| @@ -2417,9 +2410,6 @@ static void print_pkt_side_data(WriterContext *w, · 87 unmodified lines | |||
| 2417 | } else if (sd->type == AV_PKT_DATA_AFD && sd->size > 0) { | 2410 | } else if (sd->type == AV_PKT_DATA_AFD && sd->size > 0) { |
| 2418 | print_int("active_format", *sd->data); | 2411 | print_int("active_format", *sd->data); |
| 2419 | } | 2412 | } |
| 2420 | writer_print_section_footer(w); | ||
| 2421 | } | ||
| 2422 | writer_print_section_footer(w); | ||
| 2423 | } | 2413 | } |
| 2424 | 2414 | ||
| 2425 | static void print_private_data(WriterContext *w, void *priv_data) | 2415 | static void print_private_data(WriterContext *w, void *priv_data) |
| @@ -2579,9 +2569,13 @@ static void show_packet(WriterContext *w, InputFile *ifile, AVPacket *pkt, int p · 153 unmodified lines | |||
| 2579 | av_dict_free(&dict); | 2569 | av_dict_free(&dict); |
| 2580 | } | 2570 | } |
| 2581 | 2571 | ||
| 2582 | print_pkt_side_data(w, st->codecpar, pkt->side_data, pkt->side_data_elems, | 2572 | writer_print_section_header(w, NULL, SECTION_ID_PACKET_SIDE_DATA_LIST); |
| 2583 | SECTION_ID_PACKET_SIDE_DATA_LIST, | 2573 | for (int i = 0; i < pkt->side_data_elems; i++) { |
| 2584 | SECTION_ID_PACKET_SIDE_DATA); | 2574 | print_pkt_side_data(w, st->codecpar, &pkt->side_data[i], |
| 2575 | SECTION_ID_PACKET_SIDE_DATA); | ||
| 2576 | writer_print_section_footer(w); | ||
| 2577 | } | ||
| 2578 | writer_print_section_footer(w); | ||
| 2585 | } | 2579 | } |
| 2586 | 2580 | ||
| 2587 | writer_print_section_footer(w); | 2581 | writer_print_section_footer(w); |
| @@ -3228,10 +3222,14 @@ static int show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_id · 640 unmodified lines | |||
| 3228 | if (do_show_stream_tags) | 3222 | if (do_show_stream_tags) |
| 3229 | ret = show_tags(w, stream->metadata, in_program ? SECTION_ID_PROGRAM_STREAM_TAGS : SECTION_ID_STREAM_TAGS); | 3223 | ret = show_tags(w, stream->metadata, in_program ? SECTION_ID_PROGRAM_STREAM_TAGS : SECTION_ID_STREAM_TAGS); |
| 3230 | 3224 | ||
| 3231 | if (stream->nb_side_data) { | 3225 | if (stream->codecpar->nb_coded_side_data) { |
| 3232 | print_pkt_side_data(w, stream->codecpar, stream->side_data, stream->nb_side_data, | 3226 | writer_print_section_header(w, NULL, SECTION_ID_STREAM_SIDE_DATA_LIST); |
| 3233 | SECTION_ID_STREAM_SIDE_DATA_LIST, | 3227 | for (int i = 0; i < stream->codecpar->nb_coded_side_data; i++) { |
| 3234 | SECTION_ID_STREAM_SIDE_DATA); | 3228 | print_pkt_side_data(w, stream->codecpar, &stream->codecpar->coded_side_data[i], |
| 3229 | SECTION_ID_STREAM_SIDE_DATA); | ||
| 3230 | writer_print_section_footer(w); | ||
| 3231 | } | ||
| 3232 | writer_print_section_footer(w); | ||
| 3235 | } | 3233 | } |
| 3236 | 3234 | ||
| 3237 | writer_print_section_footer(w); | 3235 | writer_print_section_footer(w); |