[FFmpeg-user] Decoding Raw YUV Frames From MPEG2

Stu mario753 at yahoo.com
Sat Feb 2 13:59:44 CET 2013


Andy

> How far out are they?

Frequency analysis graph shows three spikes, at values 16, 128 and 234.
But the full range is present, 0 accounting for over 32,000 samples and 255 for over 8,000.

Is this what is usually passed to a hardware surface during playback?  If so, I would presume that these out of range values are clipped.  Can ffmpeg do this for me?

Regards

--------
Stu


--- On Sat, 2/2/13, Andy Furniss <andyqos at ukfsn.org> wrote:

> From: Andy Furniss <andyqos at ukfsn.org>
> Subject: Re: [FFmpeg-user] Decoding Raw YUV Frames From MPEG2
> To: "FFmpeg user questions" <ffmpeg-user at ffmpeg.org>
> Cc: "Stu" <mario753 at yahoo.com>
> Date: Saturday, 2 February, 2013, 12:43
> Stu wrote:
> > Hello,
> >
> > I know this sounds pretty obvious, but I'm having
> trouble getting accurate results when decoding a standard
> MPEG2 video file into its component raw YUV.
> >
> > My command line is simple (from the documentation
> page):-
> > ffmpeg -i F:\ak.m2v output.yuv
> >
> > Looking at the output file in a hex editor, a
> significant percentage of samples are out of range
> (16-235).
> 
> uv are 16-240 IIRC and this is deliberately not a hard limit
> to allow 
> for excursions during studio processing.
> 
>    MPEG2 can't physically store samples like
> this,
> 
> It can - eg. this is deliberately full range (it's up to you
> to set up 
> your player/hardware colour space conversion if you want to
> see it as 
> full range on your screen).
> 
> http://www.w6rz.net/ramp.zip
> 
> >so I'm curious as to where they are coming from and if
> they can be clipped.
> 
> How far out are they?
> 


More information about the ffmpeg-user mailing list