

You can pack all of these components into one process/thread which makes handling memory a little easier and reduces copying of large memory chunks. After you have muxed your streams you can then dump the final video into a file or stream it to a server. You will most likely have to do some timestamp-magic in this step. Each audio/video/subtitle track will be represented as stream in the FFmpeg-muxer.

