Log in

View Full Version : How to encode a H264 stream with FFMPEG with zerolatency encoded feedback?


genesys
11th May 2012, 12:02
I generate a video stream which i want to encode with FFMPEG in a H264 stream.

The frames are generated on the fly and saved as bitmaps to the disk.

After each frame is generated, I want FFMPEG to encode it into the H264 stream and I want to directly show an decoded result of the frame on screen, even before the next frame is generated and saved as bitmap to the disk.

setting

–tune zerolatency

i can force x264 to encode with zero frame latency.

But how can I use the FFMPEG tool to encode and directly decode each frame on the fly?

Adub
15th May 2012, 00:46
Why the middleman? Why not just feed whatever is creating the bitmaps directly into ffmpeg/x264? It will save on disk space and encoding difficulty.