From: Michael Niedermayer <michael@niedermayer.cc>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: Re: [FFmpeg-devel] [PATCH 1/7] lavu/pixfmt: summarize yuv naming conventions
Date: Thu, 4 Aug 2022 15:49:24 +0200
Message-ID: <20220804134924.GJ2088045@pb2> (raw)
In-Reply-To: <20220802165421.137563-1-george@nsup.org>
[-- Attachment #1.1: Type: text/plain, Size: 2819 bytes --]
On Tue, Aug 02, 2022 at 06:54:15PM +0200, Nicolas George wrote:
> Signed-off-by: Nicolas George <george@nsup.org>
> ---
> libavutil/pixfmt.h | 17 +++++++++++++++++
> 1 file changed, 17 insertions(+)
>
>
> Identical to the one I posted last week.
>
>
> diff --git a/libavutil/pixfmt.h b/libavutil/pixfmt.h
> index 2d3927cc3f..3d0f92ed4d 100644
> --- a/libavutil/pixfmt.h
> +++ b/libavutil/pixfmt.h
> @@ -60,6 +60,23 @@
> * For all the 8 bits per pixel formats, an RGB32 palette is in data[1] like
> * for pal8. This palette is filled in automatically by the function
> * allocating the picture.
> + *
> + * @par
> + * Summary of the naming conventions for YUV formats:
> + * 444 422 440 420 411 410
> + * ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╋━┿━┿━┿━╋ ╋━┿━┿━┿━╋
> + * ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╂─╂─╂─╂─╂ ╂─┼─╂─┼─╂ ╋━┿━┿━┿━╋ ╂─┼─┼─┼─╂
> + * ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╋━┿━┿━┿━╋ ╂─┼─┼─┼─╂
> + * ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╂─╂─╂─╂─╂ ╂─┼─╂─┼─╂ ╋━┿━┿━┿━╋ ╂─┼─┼─┼─╂
> + * ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╋━╋━╋━╋━╋ ╋━┿━╋━┿━╋ ╋━┿━┿━┿━╋ ╋━┿━┿━┿━╋
> + * where
> + * ┼─┼ = luma pixel ╋━╋ = chroma pixel
> + * ┼─┼ ╋━╋
> + *
> + * yuv4ab →
> + * log2_chroma_w = log₂(4/a)
> + * log2_chroma_h = b == a ? 0 : b == 0 ? log2_chroma_w : unused
> + * i.e. a = horizontally, number of luma pixels for four chroma pixels
> */
You seem to describe samples as rectangular areas of constant value IIUC.
If you look at the ITU/ISO specs (mpeg2, h264 or others) they are described
by point samples. The desity of samples matches. While the default locations
do not.
What you list above are where probably most sane people would place the
samples. But ISO/ITU, probably because of historic TV standard reasons and
interlacing convertion reasons place the chroma samples in a more crooked way
I think either the ascii art should be adapted or the text should clarify
this difference
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
"Nothing to hide" only works if the folks in power share the values of
you and everyone you know entirely and always will -- Tom Scott
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
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:[~2022-08-04 13:49 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-02 16:54 Nicolas George
2022-08-02 16:54 ` [FFmpeg-devel] [PATCH 2/7] lavfi/graphdump: add plain listing output Nicolas George
2022-08-02 16:54 ` [FFmpeg-devel] [PATCH 3/7] fftools: add -lavfi_dump option Nicolas George
2022-08-02 16:54 ` [FFmpeg-devel] [PATCH 4/7] lavfi/(a)format: factor finding the delimiter Nicolas George
2022-08-02 16:54 ` [FFmpeg-devel] [PATCH 5/7] lavfi/(a)format: support slash as a delimiter Nicolas George
2022-08-02 16:54 ` [FFmpeg-devel] [PATCH 6/7] lavi/pixdesc: add comments about pixel format scoring Nicolas George
2022-08-04 13:52 ` Michael Niedermayer
2022-08-02 16:54 ` [FFmpeg-devel] [PATCH 7/7] tests: add coverage for libavfilter's format negotiation Nicolas George
2022-08-04 13:49 ` Michael Niedermayer [this message]
2022-08-04 13:57 ` [FFmpeg-devel] [PATCH 1/7] lavu/pixfmt: summarize yuv naming conventions Nicolas George
2022-08-04 15:04 ` Michael Niedermayer
2022-08-06 10:36 ` 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=20220804134924.GJ2088045@pb2 \
--to=michael@niedermayer.cc \
--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