[FFmpeg-user] FFMPEG passthrough recording RTSP/H264 to MP4 container bad encoding

Cédric Verstraeten cedric at verstraeten.io
Sat Jan 26 14:58:52 EET 2019


Hello, I'm using the ffmpeg 3.4.2 to record a RTSP h264 steam from an IP camera and store it in a MP4 container. I have a working C++ example however at the beginning of the MP4 video I see some corrupted images, after a couple of seconds the video is shown properly. I was wondering if this is a timing issue?

Someone told me that I may have to wait for an IDR frame before I passthrough video packets to the MP4 writer.

Please find the original ticket in here.

https://stackoverflow.com/questions/54181462/ffmpeg-passthrough-recording-rtsp-h264-to-mp4-container-bad-encoding <https://stackoverflow.com/questions/54181462/ffmpeg-passthrough-recording-rtsp-h264-to-mp4-container-bad-encoding>

Anyone an idea?

Cédric


More information about the ffmpeg-user mailing list