Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: Anton Khirnov <anton@khirnov.net>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Cc: Niklas Haas <git@haasn.dev>
Subject: Re: [FFmpeg-devel] [PATCH 1/4] fftools/ffmpeg_enc: strip DOVI config record for AV1
Date: Fri, 22 Mar 2024 10:41:13 +0100
Message-ID: <171110047375.7287.3672479821689972140@lain.khirnov.net> (raw)
In-Reply-To: <20240321131132.GB15980@haasn.xyz>

Quoting Niklas Haas (2024-03-21 13:11:32)
> On Thu, 21 Mar 2024 11:16:57 +0100 Anton Khirnov <anton@khirnov.net> wrote:
> > Quoting Niklas Haas (2024-03-19 20:16:39)
> > > From: Niklas Haas <git@haasn.dev>
> > > 
> > > AV1 streams don't use configuration records, so delete them when
> > > encoding to AV1. Ideally this would be, as the comment suggests, handled
> > > at the frame-level (and stripped by the av1 encoder), but given the
> > > status quo of copying the packet-level data here directly, we should
> > > definitely make an effort to strip it.
> > > ---
> > >  fftools/ffmpeg_enc.c | 25 ++++++++++++++-----------
> > >  1 file changed, 14 insertions(+), 11 deletions(-)
> > 
> > I'm very much not a fan of having codec-specific code in ffmpeg CLI. It
> > implies that every single caller must now be aware of this
> > (undocumented?) interaction of this specific side data with this
> > specific codec ID.
> 
> Note: This is an existing bug, not introduced by this series. This
> series just makes it obvious. The status quo is that, beacuse of this
> logic in ffmpeg_enc.c, we incorrectly forward dolby vision configuration
> records when transcoding to AV1.

I know pretty much nothing about dolby vision, so could you please
explain why precisely is this incorrect? And at what point in the
transcoding chain does the side data become invalid?

> Or, indeed, when transcoding to *any* format - since current FFmpeg also
> does not propagate dolby vision RPUs, we generate broken files pretty
> much always when transcoding dolby vision. So we definitely need to
> strip the metadata from the stream muxer *somewhere*. Where else comes
> to mind?
> 
> This also gets into another topic I wanted to touch on, which is that
> the presence of dynamic dolby vision metadata currently hinders the
> ability of libavfilter to treat the video primaries/gamma as
> a negotiable colorspace property (the way it is done currently for YUV
> matrix/range). This is because when interpreted as such, DV metadata
> fundamentally changes the colorspace of the incoming video stream.
> Ideally we would like some way to negotiate DV metadata on the
> query_formats() level.
> 
> Ideally, we'd want something like AVCOL_SPC_DOLBYVISION, but we can't
> easily introduce that without breaking ISO/IEC 23091 compatibility..

In principle it could be yet another negotiated field, could it not? You
just added a bunch of those recently, what's another one?

-- 
Anton Khirnov
_______________________________________________
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".

  reply	other threads:[~2024-03-22  9:41 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-19 19:16 Niklas Haas
2024-03-19 19:16 ` [FFmpeg-devel] [PATCH 2/4] avcodec/dovi_rpu: implement T.35 payload synthesis Niklas Haas
2024-03-19 19:16 ` [FFmpeg-devel] [PATCH 3/4] avcodec/libaomenc: encode dovi RPUs as T.35 metadata Niklas Haas
2024-03-19 19:16 ` [FFmpeg-devel] [PATCH 4/4] avcodec/libx265: encode dovi RPUs Niklas Haas
2024-03-19 21:39   ` Derek Buitenhuis
     [not found]     ` <9183F034-A7F5-4683-A932-273E15B9886C@cosmin.at>
2024-03-19 21:59       ` Cosmin Stejerean via ffmpeg-devel
2024-03-19 23:04         ` Niklas Haas
2024-03-19 23:19           ` Vittorio Giovara
2024-03-21 12:09             ` Niklas Haas
2024-03-20 19:30   ` Michael Niedermayer
2024-03-20 21:22     ` Jan Ekström
2024-03-21 12:02       ` Niklas Haas
2024-03-21 10:16 ` [FFmpeg-devel] [PATCH 1/4] fftools/ffmpeg_enc: strip DOVI config record for AV1 Anton Khirnov
2024-03-21 12:11   ` Niklas Haas
2024-03-22  9:41     ` Anton Khirnov [this message]
2024-03-22 13:08       ` Niklas Haas
2024-03-22 17:04         ` Niklas Haas
2024-03-23 17:45 ` Niklas Haas

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=171110047375.7287.3672479821689972140@lain.khirnov.net \
    --to=anton@khirnov.net \
    --cc=ffmpeg-devel@ffmpeg.org \
    --cc=git@haasn.dev \
    /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