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 9048046006 for ; Sat, 29 Apr 2023 17:12:02 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 4DEA068BFEC; Sat, 29 Apr 2023 20:11:59 +0300 (EEST) Received: from nef.ens.fr (nef2.ens.fr [129.199.96.40]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 11ED968BFB7 for ; Sat, 29 Apr 2023 20:11:53 +0300 (EEST) X-ENS-nef-client: 129.199.129.80 ( name = phare.normalesup.org ) Received: from phare.normalesup.org (phare.normalesup.org [129.199.129.80]) by nef.ens.fr (8.14.4/1.01.28121999) with ESMTP id 33THBqLJ002580 for ; Sat, 29 Apr 2023 19:11:52 +0200 Received: by phare.normalesup.org (Postfix, from userid 1001) id 4C740EB5BF; Sat, 29 Apr 2023 19:11:52 +0200 (CEST) Date: Sat, 29 Apr 2023 19:11:52 +0200 From: Nicolas George To: FFmpeg development discussions and patches Message-ID: References: <20230428095508.221826-1-george@nsup.org> <20230428095508.221826-5-george@nsup.org> <168276131126.3843.11789945625076765172@lain.khirnov.net> MIME-Version: 1.0 In-Reply-To: <168276131126.3843.11789945625076765172@lain.khirnov.net> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (nef.ens.fr [129.199.96.32]); Sat, 29 Apr 2023 19:11:52 +0200 (CEST) Subject: Re: [FFmpeg-devel] [PATCH 5/8] lavu: add a JSON writer API (WIP) 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="===============6146670649158730919==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============6146670649158730919== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="OXw6Fx4YyBqM2muY" Content-Disposition: inline --OXw6Fx4YyBqM2muY Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Anton Khirnov (12023-04-29): > As far as I can see, there are exactly two places in the codebase that > produce JSON: af_loudnorm and ffprobe. I think I remember finding a few other places, but it does not matter much. Users have been asking=C2=B9 for parse-friendly output from filters for yea= rs, and JSON is often the format they prefer. Therefore, all the filters that log useful information are candidates where a JSON writing API is useful. (See my answer to James for why =E2=80=9Cput it in frame metadata=E2=80=9D = is not a real solution.) > * IMO the filter should not be doing this at all and instead produce some > sort of a struct and let the users process it as they wish And to let users process it as they wish, it needs to be formatted into a parse-friendly syntax like JSON. > ffprobe: > * is not one of the libraries, but rather their caller > * we are not in business of providing random non-multimedia-related > services to callers, unless they are useful in our libraries; > if this code is only useful in ffprobe then it should live in fftools/ This is your opinion, not the project policy. My opinion is that anything that is useful for fftools and can be made to have a properly-defined API has its place in libavutil. Let us see which opinion has more support. > * it is not at all obvious that switching ffprobe to this code would > be an improvement; a patch actually demonstrating this would be most > useful I distinctly remember writing the changes to ffprobe and getting the same output except for the indentation level, but I do not find the code. 1: To be aware what would be useful to the project, reading the users mailing-lists helps. --=20 Nicolas George --OXw6Fx4YyBqM2muY Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEE6ooRQGBoNzw0KnwPcZVLI8pNxgwFAmRNT9YACgkQcZVLI8pN xgz49g/8DpyoPJLzXVAYXSsgkSAculD9BWTt3x4rDY7dWgMMWrLou2ZiY4vPm+QU oYzikVAJBsgdKGIqat3AMcOUf/VlMFViEd1LPNQJagB9gAMsIbfq2aRY/vKfddM9 SCWD+Bn69ugYPqZYdQVylODP1F9F+e0mgRclk+9yr3Wnnwx8kW4OkY6xN+x4AJC6 Um6+yGgk3iSKN+RMBC0t74AIxDfd+pQhC2uEsBj3hfeDji/W82RULd3FmNgXpSra Ust537BHhybrlnOTgmETPkTDePHxI2ct5e2pKonj26Fjk0lm6DFOLdyjkX8k9eHQ rpb19yrBH+QP3fQ2S+4zKBYj3OR0xbUYS+gwytZdOl7ORHtQ+30S4D+DZXtMKG7T 5svRNnwFSTx9dMLFzjWVQz3IrzLyWVC7lZAIKNEqxVeNWrvEmR/gJ01ZyLVRMgdC rmgYlUWAN2iGB+OweZ/lSuLefTQwsCg5ERbga0/s732g/0zegE0dB/Esn/8R72MN b8u7jHbrctHMkz1nWw6GQP7OFIRHGASbqq7l7V7pZMdSyDG+Wf2HT9zFdRTFNdT2 wgan89i6U/1a4N/lAW794g6WdRkH90bgngE/uNGHU3n4Mlwjtm2Nx09k/oWW6efs JYferH9OpcZduUSKc4zT5+u1CfSEcHHKzgJQb+WqG+E5vCJLavQ= =4+pm -----END PGP SIGNATURE----- --OXw6Fx4YyBqM2muY-- --===============6146670649158730919== 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". --===============6146670649158730919==--