[FFmpeg-user] Ignoring errors in transcoding

Alexander Borghgraef alexander.borghgraef.rma at gmail.com
Fri Jun 6 15:26:22 CEST 2014

Hi all,

 I'm stuck with a couple of really bad video files I need to process, junk
in packet and dropped frames all over the place, but I would like to
collect all the good frames into a video file playable in something less
forgiving than ffplay. At this point, the really clumsy solution I have is
transcoding everything into a directory of frame jpg files with

  ffmpeg -i crapfile.mpg -f image2 tmp/crapfileframes-%06d.jpg

and then transcoding everything back again into a video format and deleting
the intermediate jpg directory. I know this messes with correct timing of
the video, but at this time I don't really care. Other solution could be to
read and write everything with OpenCV, but I was wondering whether there's
a more elegant solution for this using ffmpeg, like for example sending the
jpg frames to a pipe and then re-encoding that stream from stdin with
ffmpeg. Any suggestions?

Alex Borghgraef

More information about the ffmpeg-user mailing list