[FFmpeg-user] Levels and Primaries
adf.lists at gmail.com
Wed Feb 12 12:49:03 CET 2014
Carl Eugen Hoyos wrote:
> Rio Kierkels <riokierkels <at> gmail.com> writes:
>> Could be just my paranoia, but I always have the feeling that the
>> decoder does some magic on the numbers or something.
> (This may now be the terminology problem in the other direction.)
> Concerning the decoder, I suspect that there actually is a guarantee
> that an MPEG decoder in FFmpeg really only outputs MPEG levels
> (unless told otherwise). But is that really your question?
I don't think there is such a thing as MPEG levels - in my tests the
mpeg decoder will re-produce whatever levels were input - I believe this
is correct behavior.
>> Which is why right now I'm also not certain what I'm looking for in
>> the output.
> I thought you are looking for levels from 0 to 15 and 236 to 255 (but
> as said, I may just not understand the problem that you say don't
The reason I first ever looked at this (with the code I posted) was
after someone (retired BBC engineer, I think) said that broadcast mpeg
streams were not strictly 16 - 235. He was right - there are over/under
everywhere if you look. This does not mean the levels are wrong, eg.
there will be vastly more at 16 for dark scenes.
From a computer users point of view these will never normally be visible
as the default yuv (video level) - rgb (full range) conversion
clips/clamps them just as it should. Of course you can control the
conversion if you want to.
From a TV aspect - the hdmi spec has various modes including video level
yuv - but even if you use this it still allows (and expects) over under.
More information about the ffmpeg-user