[FFmpeg-devel] Raw Decoding Bug
C Chatterjee
cchatterj at hotmail.com
Mon Jan 9 23:50:39 CET 2012
Copied a h.264 file to the link below.
http://www.mediafire.com/?0kwtdmeru4kshi1
I used FFMEG to decode to you with:
ffmpeg -y -i obx.264 -f rawvideo obff.yuv
The yuv file dropped one frame - the first frame.
I diagnosed the problem. The ist->pts is set to -8000 in init_input_streams().
The do_video_out() drops the first frame because vdelta=-2.
One way to fix this is to have a ist->first_pts set to ist->pts the very first time.
Then change get_sync_ipts() to return:
return (double)(ist->pts - ist->first_pts - of->start_time)/AV_TIME_BASE;
instead of
return (double)(ist->pts - of->start_time)/AV_TIME_BASE;
This fixes the problem of frame dropping but may break other encodings.
Ideas??
Chanchal
More information about the ffmpeg-devel
mailing list