Creating MPEG4 video file with Python from raw frames
I have a raw video frame source which I can access in Python. I'd like to create a MPEG4 video out of this, with MP3 background music. What kind of tools and libraries are available in Python for such a task? Preferably I'd like to have an API for which I can feed output filename and then individual frames as 24 bit raw images. With OpenCV and the corresponding Python binding, you could use something like the function cv.WriteFrame . You could also use pyffmpeg, but that is geared more towards accessing individual frames from a video file. One of these should be able to do what you requesting: