问题
Basically, I'm trying to create a stop-motion film making application, due to the absence of any decent free versions that work on the internet, by taking images (JPEG preferably, but any format will do) and encode them into a video (any format is good enough)
I've managed so far to decode a JPEG data into a string and save that to a .txt file, and I've re-encoded another JPEG using the bytes decrypted. I've tried PyMedia and Pyglet, neither of which installed due to having Python 3.3 >:(
So, what I'm asking is: How do I encode video in Python, using the JPEG bytes that I've just decrypted?
回答1:
I would suggest to leave image/video conversion to specialised tools like FFMPEG (there is a nice recipe for your task on that link) and call it from your script.
来源:https://stackoverflow.com/questions/17352023/how-to-decode-jpegs-and-encode-video-in-python