From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id C5AE3460DE for ; Wed, 4 Oct 2023 12:30:10 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A130768CD2F; Wed, 4 Oct 2023 15:29:09 +0300 (EEST) Received: from mail-pl1-f176.google.com (mail-pl1-f176.google.com [209.85.214.176]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 52E1A68CCF7 for ; Wed, 4 Oct 2023 15:29:02 +0300 (EEST) Received: by mail-pl1-f176.google.com with SMTP id d9443c01a7336-1c61bde0b4bso17204075ad.3 for ; Wed, 04 Oct 2023 05:29:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1696422540; x=1697027340; darn=ffmpeg.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=/PV+L4lK5PLOmTx0ATbl7e6huaz6ZLuI8CiauDuAZOU=; b=mlDkD400kbM67Fk2v2T1hkKA8XvBu6gSMl0TxiSV7xE3CPjJ/4oaWqMHB5SvZ3F4Wf gBF4YmnN2i+bBW9IohoaDekXSksgSp5YXEp0A3n16pvQR+dc4IDPVkXN042DMNbtP3zj Skb0VojQASvRIFSrHN5bYm10naQozsPSM/DTc8RiSlom+5lZbfa0GUNw3qKcQHtR3LG/ unH+f3mKyqrrVJ1oBBIni3iaB2ek4bb9RvAL4ApbEY+6lyJDxGk1nTuNNf37os3+ShzI RA3Wq9feVwfRPHDRao4LWlp5d9jXpf5yW2V66bXEmX+ZJh4vjNZuT99dgXIHJd5POUBG dMKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696422540; x=1697027340; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/PV+L4lK5PLOmTx0ATbl7e6huaz6ZLuI8CiauDuAZOU=; b=on+rnxu3OI96F1ayknz2n8f2yl5io+2e+FNhgVhWQYVNWKZa+O5ur3+1FuHpdWvnGQ IB1iV+sJXuYKLoGd/dxP1/LGRT/OtZLYDlNHWlBfI/S5FFfNSylI+1FJ3V1DvyymHggM 3YqvmY8yBFeyiQIc782aBnfbxQccnfbwSGVs8iGaGQYMpbB0uxRIFE7y4Tgo5Rd9HFAo szY63l6z3njUs+T7bqskV9KKAVF9uOb9udrdXcbN+ivva/4Xkd7rKbDTjXgIEQJyNY+Z EGh02WoTSeXt75OBrNdy4TYfVUY7A6FXy5h8K9SA5f1AWOATK0XUsi/fR8ecTudZ9eRL R47Q== X-Gm-Message-State: AOJu0Yx780HW9Me6O/KDRQ6K16nMW5wiZTiNO2mDJUvbTK7x4grGulGD BFaotK6+StKypHJ13F25dyIjscGrxG4= X-Google-Smtp-Source: AGHT+IE37tDZgovDY39pLWAyWOEcdf6+H99BsOoXgNTIzMXb+NWfJQBpKQEZPKfPr1Fgk/kqRKl7Ng== X-Received: by 2002:a17:902:8343:b0:1c2:82e:32de with SMTP id z3-20020a170902834300b001c2082e32demr2184388pln.0.1696422540231; Wed, 04 Oct 2023 05:29:00 -0700 (PDT) Received: from localhost.localdomain (host197.190-225-105.telecom.net.ar. [190.225.105.197]) by smtp.gmail.com with ESMTPSA id h11-20020a170902748b00b001c57aac6e5esm3551831pll.23.2023.10.04.05.28.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Oct 2023 05:28:59 -0700 (PDT) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Wed, 4 Oct 2023 09:28:45 -0300 Message-ID: <20231004122849.56604-8-jamrial@gmail.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231004122849.56604-1-jamrial@gmail.com> References: <20231004122849.56604-1-jamrial@gmail.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 07/11] fftools/ffprobe: stop using AVStream.side_data X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Signed-off-by: James Almer --- fftools/ffprobe.c | 30 ++++++++++++++---------------- 1 file changed, 14 insertions(+), 16 deletions(-) diff --git a/fftools/ffprobe.c b/fftools/ffprobe.c index c20f464623..dc3250e3a2 100644 --- a/fftools/ffprobe.c +++ b/fftools/ffprobe.c @@ -2279,16 +2279,9 @@ static void print_ambient_viewing_environment(WriterContext *w, static void print_pkt_side_data(WriterContext *w, AVCodecParameters *par, - const AVPacketSideData *side_data, - int nb_side_data, - SectionID id_data_list, + const AVPacketSideData *sd, SectionID id_data) { - int i; - - writer_print_section_header(w, id_data_list); - for (i = 0; i < nb_side_data; i++) { - const AVPacketSideData *sd = &side_data[i]; const char *name = av_packet_side_data_name(sd->type); writer_print_section_header(w, id_data); @@ -2382,9 +2375,6 @@ static void print_pkt_side_data(WriterContext *w, } else if (sd->type == AV_PKT_DATA_AFD && sd->size > 0) { print_int("active_format", *sd->data); } - writer_print_section_footer(w); - } - writer_print_section_footer(w); } static void print_private_data(WriterContext *w, void *priv_data) @@ -2544,9 +2534,13 @@ static void show_packet(WriterContext *w, InputFile *ifile, AVPacket *pkt, int p av_dict_free(&dict); } - print_pkt_side_data(w, st->codecpar, pkt->side_data, pkt->side_data_elems, - SECTION_ID_PACKET_SIDE_DATA_LIST, + writer_print_section_header(w, SECTION_ID_PACKET_SIDE_DATA_LIST); + for (int i = 0; i < pkt->side_data_elems; i++) { + print_pkt_side_data(w, st->codecpar, &pkt->side_data[i], SECTION_ID_PACKET_SIDE_DATA); + writer_print_section_footer(w); + } + writer_print_section_footer(w); } writer_print_section_footer(w); @@ -3188,10 +3182,14 @@ static int show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_id if (do_show_stream_tags) ret = show_tags(w, stream->metadata, in_program ? SECTION_ID_PROGRAM_STREAM_TAGS : SECTION_ID_STREAM_TAGS); - if (stream->nb_side_data) { - print_pkt_side_data(w, stream->codecpar, stream->side_data, stream->nb_side_data, - SECTION_ID_STREAM_SIDE_DATA_LIST, + if (stream->codecpar->nb_coded_side_data) { + writer_print_section_header(w, SECTION_ID_STREAM_SIDE_DATA_LIST); + for (int i = 0; i < stream->codecpar->nb_coded_side_data; i++) { + print_pkt_side_data(w, stream->codecpar, &stream->codecpar->coded_side_data[i], SECTION_ID_STREAM_SIDE_DATA); + writer_print_section_footer(w); + } + writer_print_section_footer(w); } writer_print_section_footer(w); -- 2.42.0 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".