[FFmpeg-devel] [PATCH] Fix chroma height ratio for yuv410p

Hendrik Leppkes h.leppkes at gmail.com
Mon Apr 18 12:44:04 CEST 2016

On Mon, Apr 18, 2016 at 12:07 PM, Michael Niedermayer
<michael at niedermayer.cc> wrote:
> On Mon, Apr 18, 2016 at 09:49:40AM +0000, Isamu Mogi wrote:
>> Chroma height for yuv410p is luma/2. Same as yuv440p and yuv420p.
> no
> but why was the first thought i had "wikipedia" and why was i correct
> "4:1:0 This ratio is possible, and some codecs support it, but it is not widely used. This ratio uses half of the vertical ..."
> do NOT ever use wikipedia for important decissions, its great to
> look something up but its not accurate especially for things where
> the correct awnser is unintuitv
> also seems this one is known, check
> https://en.wikipedia.org/wiki/Talk%3AChroma_subsampling about 4:1:0

The problem with 4:1:0 is that its used wrong in many many places.
The 4:1:0 notation would say that its one chroma sample for a 4x2
block, and one sample for a 4x4 block would be impossible in this
notation - this variant is otherwise commonly called YUV9.

However, many formats and software treat 4:1:0 like a special case for
some reason, ignoring the J:a:b notation and handling it as the 4x4

So while its technically wrong, it appears to match what software
typically uses. To be fully accurate, we should rename yuv410p to
something more fitting, and introduce a new 4:1:0 format afterwards,
but this is a lot of effort with deprecation cycles and not colliding
the names etc for an obscure format..

- Hendrik

More information about the ffmpeg-devel mailing list