From: Soft Works <softworkz-at-hotmail.com@ffmpeg.org> To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> Subject: Re: [FFmpeg-devel] [PATCH v2 0/8] [RFC] avtextformat: Transform text writing into an independent API Date: Fri, 28 Feb 2025 22:29:10 +0000 Message-ID: <DM8P223MB036500147431A75BEEFD9C6ABACC2@DM8P223MB0365.NAMP223.PROD.OUTLOOK.COM> (raw) In-Reply-To: <Z8G_dudzJZyG03Vg@phare.normalesup.org> > -----Original Message----- > From: ffmpeg-devel <ffmpeg-devel-bounces@ffmpeg.org> On Behalf Of > Nicolas George > Sent: Freitag, 28. Februar 2025 14:52 > To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> > Subject: Re: [FFmpeg-devel] [PATCH v2 0/8] [RFC] avtextformat: Transform > text writing into an independent API > > ffmpegagent (HE12025-02-28): > > This patchset doesn't aim to improve or change the API itself - that > would > > be a bit too much at once. > > So you asked for advice, got come counsel from me and did exactly the > opposite. Do not be surprised if the result is less than satisfactory. Hi Nicolas, I didn't do the opposite. I did what you mentioned in your last sentence as a future goal. Your immediate suggestion was to extract a "low-level writer" for JSON in avutil. This isn't reasonably possible, because the JSON writing code strongly depends on types only present in ffprobe, namely: Writer, WriterContext, Section, SECTION_ID_*, WRITER_FLAG_*, SECTION_FLAG_* A low-level writer that is independent from all of this would hardly contain much code anymore, because all of the implementation would have to remain in the ffprobe.c code which wraps it. In turn, nothing would have been won in doing so. That's why I opted for a larger step. > > * Public API isn't documented yet > > When designing a public API, the user documentation, and in particular a > quick-start guide with clear examples, should be the first thing you > show, and probably even one of the very first things you write. > > Without that, I can only repeat what I told you two days ago: > > The writers in ffprobe are an ad-hoc construction to turn the shallow > data structures produced by ffprobe into a common denominator of JSON, > XML, CSV and a few custom formats. It is not a good candidate to be > turned into an API. I have turned it into something that is generally usable in other places without being specific to ffprobe requirements. The reason why I haven't added documentation and examples yet (and marked it [RFC]) is because I'm not sure whether it's ready in this form to become a public API and that's what was asking about. If the answer would have been 'yes', then I would of course add all the things you mentioned. But from your comment I figure that it's not. I will update the patchset by moving the text format API files to fftools for local use only. Then we can refine the API there until it is in a shape for becoming a public API and you are of course welcome to join the work on it and bring in all the things that you are envisioning. Thanks sw _______________________________________________ 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".
prev parent reply other threads:[~2025-02-28 22:29 UTC|newest] Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top 2025-02-27 14:01 [FFmpeg-devel] [PATCH " ffmpegagent 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 1/8] ffprobe/avtextformat: Rename and move writer structs softworkz 2025-02-28 1:18 ` Michael Niedermayer 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 2/8] ffprobe/avtextformat: Rename and move writer functions and options softworkz 2025-02-28 1:23 ` Michael Niedermayer 2025-02-28 1:30 ` Soft Works 2025-02-28 1:47 ` Soft Works 2025-02-28 2:29 ` Michael Niedermayer 2025-02-28 2:43 ` Soft Works 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 3/8] ffprobe/avtextformat: Generalize ffprobe specifics softworkz 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 4/8] ffprobe/avtextformat: Rename flags and enums softworkz 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 5/8] ffprobe/avtextformat: Move flags softworkz 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 6/8] ffprobe/avtextformat: Rename writer to formatter softworkz 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 7/8] ffprobe/avtextformat: Move formatters to avutil softworkz 2025-02-27 14:01 ` [FFmpeg-devel] [PATCH 8/8] ffprobe/avtextformat: Split out text writers as independent classes softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 0/8] [RFC] avtextformat: Transform text writing into an independent API ffmpegagent 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 1/8] ffprobe/avtextformat: Rename and move writer structs softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 2/8] ffprobe/avtextformat: Rename and move writer functions and options softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 3/8] ffprobe/avtextformat: Generalize ffprobe specifics softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 4/8] ffprobe/avtextformat: Rename flags and enums softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 5/8] ffprobe/avtextformat: Move flags softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 6/8] ffprobe/avtextformat: Rename writer to formatter softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 7/8] ffprobe/avtextformat: Move formatters to avutil softworkz 2025-02-28 5:02 ` [FFmpeg-devel] [PATCH v2 8/8] ffprobe/avtextformat: Split out text writers as independent classes softworkz 2025-02-28 13:51 ` [FFmpeg-devel] [PATCH v2 0/8] [RFC] avtextformat: Transform text writing into an independent API Nicolas George 2025-02-28 22:29 ` Soft Works [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=DM8P223MB036500147431A75BEEFD9C6ABACC2@DM8P223MB0365.NAMP223.PROD.OUTLOOK.COM \ --to=softworkz-at-hotmail.com@ffmpeg.org \ --cc=ffmpeg-devel@ffmpeg.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git