Commit 0d8fd5b1 authored by Eric Larson's avatar Eric Larson

Merge pull request #145 from christianbrodbeck/ffmpeg

Ffmpeg
parents 22d55dfe 6f1fb0a7
......@@ -699,7 +699,8 @@ def ffmpeg(dst, frame_path, framerate=24, codec='mpeg4', bitrate='1M'):
frame_dir, frame_fmt = os.path.split(frame_path)
# make the movie
cmd = ['ffmpeg', '-i', frame_fmt, '-r', str(framerate), '-b', str(bitrate)]
cmd = ['ffmpeg', '-i', frame_fmt, '-r', str(framerate),
'-b:v', str(bitrate)]
if codec is not None:
cmd += ['-c', codec]
cmd += [dst]
......@@ -713,7 +714,8 @@ def ffmpeg(dst, frame_path, framerate=24, codec='mpeg4', bitrate='1M'):
logger.info(std_info)
if stderr.strip():
err_info = os.linesep.join(("FFmpeg stderr", '=' * 27, stderr))
logger.error(err_info)
# FFmpeg prints to stderr in the absence of an error
logger.info(err_info)
# check that movie file is created
if not os.path.exists(dst):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment