[FFmpeg-devel] [PATCH v2 03/18] avfilter/vf_showinfo: print alpha mode when relevant
Kacper Michajlow
kasper93 at gmail.com
Wed Jul 23 19:11:23 EEST 2025
On Wed, 23 Jul 2025 at 15:57, Niklas Haas <ffmpeg at haasn.xyz> wrote:
>
> From: Niklas Haas <git at haasn.dev>
>
> ---
> libavfilter/vf_showinfo.c | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/libavfilter/vf_showinfo.c b/libavfilter/vf_showinfo.c
> index c706d00c96..b564d03a84 100644
> --- a/libavfilter/vf_showinfo.c
> +++ b/libavfilter/vf_showinfo.c
> @@ -887,6 +887,14 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
>
> dump_color_property(ctx, frame);
>
> + if (desc->flags & AV_PIX_FMT_FLAG_ALPHA) {
> + const char *alpha_mode_str = av_alpha_mode_name(frame->alpha_mode);
> + if (!alpha_mode_str || frame->alpha_mode == AVALPHA_MODE_UNSPECIFIED)
> + av_log(ctx, AV_LOG_INFO, "alpha_mode:unknown\n");
Looking at other patches you used `unspecified`, I don't know the
distinction, but should be consistent about one name.
> + else
> + av_log(ctx, AV_LOG_INFO, "alpha_mode:%s\n", alpha_mode_str);
> + }
> +
> return ff_filter_frame(inlink->dst->outputs[0], frame);
> }
>
> --
> 2.50.1
>
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".
More information about the ffmpeg-devel
mailing list