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 D18254A93F for ; Mon, 6 May 2024 01:34:30 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 3812A68D5BF; Mon, 6 May 2024 04:34:27 +0300 (EEST) Received: from relay6-d.mail.gandi.net (relay6-d.mail.gandi.net [217.70.183.198]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 5FDA368D50B for ; Mon, 6 May 2024 04:34:20 +0300 (EEST) Received: by mail.gandi.net (Postfix) with ESMTPSA id 8C2A5C0002 for ; Mon, 6 May 2024 01:34:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niedermayer.cc; s=gm1; t=1714959259; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=ws+smrpWbnC7Tfk2ePAHccTs3LcnhhKwSD0Tc0r/uJw=; b=U7JNFpDnLMjevuOmrsvXO4G1Z0OcyHF6lfd+gWWAWjkKMRRG6cZaGt1VUXuQvq2HjUpTMj DbsNhCU1ahiXPR8E7wo+pwfAVHqeH5si0rl1psO05UkpthsZ7ePKNBMUjSXMK0et5rEBjy UmuWK97r2X9h0COoGBssG2nrQw8GRfbq6xAlGaYjyLrJ76qxSdQRZxdUInTw3kxrk7KO4j F9RF6fuRn1ByN/sSJvHTeWTPs800LzCEXN8eI45kCEb7NzR1gt4bYOgLjT1+0Stx5W2kaq nx0DY4FLbkhQLJoyxfulQb84e0jegu4wyKkboQELxUsIu22QQ0+4dgPyKOcYPw== Date: Mon, 6 May 2024 03:34:18 +0200 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20240506013418.GC6420@pb2> References: <20240430231926.2506728-1-michael@niedermayer.cc> <8aa7804e-ce52-48ff-8909-dc4ca98763da@gmail.com> <51cfa301-0a67-484b-a68b-0c2d5e5ea9e8@gmail.com> <20240504205857.GW6420@pb2> <83b46d22-7d4a-4b3b-a9eb-daa99a7599eb@gmail.com> <20240505014503.GA6420@pb2> <862a3032-917d-4c62-8825-d920945859ca@gmail.com> MIME-Version: 1.0 In-Reply-To: <862a3032-917d-4c62-8825-d920945859ca@gmail.com> X-GND-Sasl: michael@niedermayer.cc Subject: Re: [FFmpeg-devel] [PATCH v3] avformat/framecrcenc: compute the checksum for 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: multipart/mixed; boundary="===============5461482946995842696==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============5461482946995842696== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="OZMHtDY8m8dXRQqH" Content-Disposition: inline --OZMHtDY8m8dXRQqH Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, May 04, 2024 at 10:54:59PM -0300, James Almer wrote: > On 5/4/2024 10:45 PM, Michael Niedermayer wrote: > > On Sat, May 04, 2024 at 06:02:25PM -0300, James Almer wrote: > > >=20 > > >=20 > > > On 5/4/2024 5:58 PM, Michael Niedermayer wrote: > > > > On Sat, May 04, 2024 at 12:16:00PM -0300, James Almer wrote: > > > > > On 5/4/2024 5:34 AM, Marton Balint wrote: > > > > > >=20 > > > > > >=20 > > > > > > On Thu, 2 May 2024, James Almer wrote: > > > > > >=20 > > > > > > > On 5/2/2024 6:23 PM, Marton Balint wrote: > > > > > > > >=20 > > > > > > > >=20 > > > > > > > > =A0On Wed, 1 May 2024, Michael Niedermayer wrote: > > > > > > > >=20 > > > > > > > > > =A0This allows detecting issues in side data related co= de, same as what > > > > > > > > > =A0framecrc does for before already for packet data its= elf. > > > > > > > > >=20 > > > > > > > > > =A0This basically reverts c6ae560a18d67b9ddaa25a0338b7f= b55e3312e57. > > > > > > > >=20 > > > > > > > > =A0Can you at least add an option which allows disabling = dumping the side > > > > > > > > =A0data? Changing the format of framecrc output again and= again is > > > > > > > > not very > > > > > > >=20 > > > > > > > The framehash/framemd5 muxer is versioned, which is what you = should > > > > > > > use if you want parseable output. > > > > > >=20 > > > > > > Okay, but then the question is that why framecrc is using diffe= rent code > > > > > > and options? > > > > >=20 > > > > > Originally it was framecrc (using AVAdler) and framemd5 (using AV= MD5). The > > > > > latter was renamed/aliased to framehash and made to use the AVHas= h API, > > > > > which supports all lavu hashing algorithms, and is versioned. > > > > > If anyone cared, framecrc could be also made into an alias of fra= mehash that > > > > > defaults to adler32 output, but it would result in a massive chan= ge to > > > > > reference files, if anything because AVHash initializes adler32 w= ith a 1 > > > > > whereas framecrc does it with a 0. > > > >=20 > > > > normally starting adler32 at 0 is bad as one could prefix by a 0 by= te with > > > > no checksum change, but given we also show the size that spcific ca= se isnt > > > > an issue > > > >=20 > > > > can we make the initial value for adler32 configureable so as to im= prove long > > > > term stability of checksums ? (or add a adler32_1 to AVHash) > > >=20 > > > av_hash_init() already initializes adler32 with a 1. No need to do an= ything > > > there. It's the framecrc muxer that uses adler32 with 0 as init value. > >=20 > > i was thinking about av_hash_init() supporting a 0 init to avoid changi= ng every > > checksum. Which would > > increase git repository size > > and make long term comparissions harder because framecrc would not be c= omparable > > at all. not just some extra fields that occasionally appear >=20 > Adding AVOptions is not backwards compatible, as it would only work on > AVHashContext from the introductory commit onwards, so the only alternati= ve > is probably a new init function that takes an input seed argument. Just n= ot > an uint32_t, as that's not extensible. It would need to be an uint8_t arr= ay. or "adler320" in addition to "adler32" thx [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Its not that you shouldnt use gotos but rather that you should write readable code and code with gotos often but not always is less readable --OZMHtDY8m8dXRQqH Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEKAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCZjgzlAAKCRBhHseHBAsP qx//AJ4oaW7/yy23Sx2yQgQbTOx00YosnACdHdmHmm9rq4IzOF5/8Hi3cyAv2LM= =iBLH -----END PGP SIGNATURE----- --OZMHtDY8m8dXRQqH-- --===============5461482946995842696== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ 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". --===============5461482946995842696==--