From: Niklas Haas <ffmpeg@haasn.xyz> To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> Subject: Re: [FFmpeg-devel] Again pre-multiplied alpha Date: Tue, 29 Jul 2025 10:55:49 +0200 Message-ID: <20250729105549.GB5455@haasn.xyz> (raw) In-Reply-To: <aIeGtbYemy3IVu12@phare.normalesup.org> On Mon, 28 Jul 2025 16:18:29 +0200 Nicolas George <george@nsup.org> wrote: > Niklas Haas (HE12025-07-24): > > On what component are you missing an error here? > > Recently I wrote: “stacking images with different kind of alpha or > sending this kind of frames to a muxer with uncoded frames” > > So: at least filters and muxers with uncoded frames. The protection must > of course go in the framework, not in individual components, that the > ABC of proper design. > > And this is only what I can think of right away. Every place that uses > the alpha component for anything other than copying must be protected. I think this would involve more invasive changes (i.e. adding negotiation to the avfilter code for this and ideally other properties) that you and I both agreed is out of scope of this series. If it makes you feel better, I could add an error message to the stacking filters specifically, for now? I will reiterate, I am still not sure I follow why this is the straw that break's the camel's back in regards to miscellaneous image properties which are not important enough to be worth full negotiation on the link layer. You argue that premultiplied frames were an "anecdotal experimental feature" only up until this series, but this is flat out untrue; because this series does not change how files are decoded. In every scenario that you worry about now getting the wrong result, you would have gotten the wrong result even before my changes. aAide from an extra way to override the properties with `vf_setparams`, this series adds no *new* ways of accidentally getting the wrong result. Messing with vf_setparams without knowing what you're doing is already generally understood as a way to shoot yourself into the foot - that is the very purpose of the filter. (Ditto regarding intentionally mislabeling a file using the command line options on encode) I think that the burden falls on you to demonstrate how my changes regress the status quo in any meaningful way rather than "users may see a new option on vf_setparams and may start playing with it". Do you have a specific command line, which does not involve manually overriding image properties, that would previously give a correct result but will now give an incorrect result? > > Regards, > > -- > Nicolas George > _______________________________________________ > 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". _______________________________________________ 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".
next prev parent reply other threads:[~2025-07-29 8:55 UTC|newest] Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top 2025-07-23 13:47 [FFmpeg-devel] (no subject) Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 01/18] avutil/frame: add AVFrame.alpha_mode Niklas Haas 2025-07-23 16:00 ` Kacper Michajlow 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 02/18] fftools/ffprobe: add support for AVFrame.alpha_mode Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 03/18] avfilter/vf_showinfo: print alpha mode when relevant Niklas Haas 2025-07-23 16:11 ` Kacper Michajlow 2025-07-24 11:19 ` Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 04/18] avcodec/avcodec: add AVCodecContext.alpha_mode Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 05/18] avcodec/encode: enforce alpha mode compatibility at encode time Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 06/18] avcodec/png: set correct alpha mode Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 07/18] avcodec/exr: " Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 08/18] avcodec/libjxl: " Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 09/18] avcodec/libjxlenc: also attach extra channel info Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 10/18] avcodec/jpegxl: parse and signal correct alpha mode Niklas Haas 2025-07-23 16:19 ` Kacper Michajlow 2025-07-24 11:13 ` Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 11/18] avfilter/vf_scale: don't ignore incoming chroma location Niklas Haas 2025-07-24 11:16 ` Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 12/18] fftools/ffmpeg_enc: don't ignore user selected " Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 13/18] fftools/ffmpeg_enc: forward frame alpha mode to encoder Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 14/18] avfilter/vf_premultiply: tag correct alpha mode on result Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 15/18] avfilter/vf_alphamerge: tag correct alpha mode Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 16/18] avfilter/vf_overlay: respect alpha mode tagging by default Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 17/18] avfilter/vf_setparams: add alpha_mode parameter Niklas Haas 2025-07-23 13:47 ` [FFmpeg-devel] [PATCH v2 18/18] avfilter/vf_libplacebo: add an alpha_mode setting Niklas Haas 2025-07-23 14:11 ` [FFmpeg-devel] Again pre-multiplied alpha Nicolas George 2025-07-23 15:18 ` Niklas Haas 2025-07-23 17:02 ` Nicolas George 2025-07-24 11:11 ` Niklas Haas 2025-07-24 14:59 ` Nicolas George 2025-07-24 20:58 ` Niklas Haas 2025-07-28 14:18 ` Nicolas George 2025-07-29 8:55 ` Niklas Haas [this message] 2025-07-28 0:00 ` Michael Niedermayer 2025-07-28 14:15 ` Nicolas George
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=20250729105549.GB5455@haasn.xyz \ --to=ffmpeg@haasn.xyz \ --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