Hello,

My problem is that av_read_frame(fmtContext, &packet) seems to return
AVERROR_EOF before the end of the file is reached. This is for a .ts file
with h264-compressed video. An interesting pattern is that it seems to
always return exactly 10 frames too early, no matter the length (#frames)
or size (resolution) of the video file.

I am creating the MPEG-TS file by running the ffmpeg command:

ffmpeg -f lavfi -i testsrc=s=640x480:r=30:d=2 -vframes 60 -vcodec libx264
FfmpegInputStreamTest.ts

E.g., this creates a 60-frame sequence at 640x480 resolution. av_read_frame
always returns EOF after 50 frames. If I do a 300-frame sequence at
320x240, it returns EOF after 290 frames.

Can anyone think of ideas what might be going on?

Thanks,
Gunner
_______________________________________________
libav-api mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-api

Reply via email to