New submission from ross <[email protected]>:
I am analysing codec's to determine how they perform. I am using ffmpeg and its
-vstats option to look at an encoded movie frame by frame. the process I use:
RAW YUV -> bar-code each frame with frame number -> Bar-coded YUV
Bar-coded YUV -> encoded (e.g. with libx264) -> MKV -> Decoded to YUV
I can compare the two outputs ('Bar-coded YUV' & 'Decoded to YUV') using the
bar-code in each frame. I can then compare, exactly, an original frame with an
encoded frame using PSNR etc.
When encoding using libx264 and libdirac, there are some frame information which
is missing. Other codecs don't have this problem, such as mpeg2video or even
libvpx.
I have found that libx264 vstats are missing for the first 40 to 50 frames. I
have since proved that the missing information is actually the last 40 to 50
frames.
It also looks like ffmpeg calculates average bitrate based on the information in
vstats. But as there is missing frames the average bitrate is less than what it
should be.
Attached is all the output.
Below are links to the average bitrate error example:
http://dl.dropbox.com/u/6743276/ffmpeg_probs/ffmpeg_av_bitrate_error.png
http://dl.dropbox.com/u/6743276/ffmpeg_probs/ffmpeg_av_bitrate_error.xlsx
Below is a link to the PSNR & f_size graph:
http://dl.dropbox.com/u/6743276/ffmpeg_probs/frame_mismatch.png
Below is a link to the output & command line options
http://dl.dropbox.com/u/6743276/ffmpeg_probs/stderr.txt
File 'stderr.txt' not attached - you can download it from
https://roundup.ffmpeg.org/file1099.
----------
files: stderr.txt
messages: 12052
priority: normal
status: new
substatus: new
title: vstats missing frames & misleading output - average bitrate is wrong
type: bug
________________________________________________
FFmpeg issue tracker <[email protected]>
<https://roundup.ffmpeg.org/issue2248>
________________________________________________