Skip to content

Commit 0d8fd5b

Browse files
committed
Merge pull request #145 from christianbrodbeck/ffmpeg
Ffmpeg
2 parents 22d55df + 6f1fb0a commit 0d8fd5b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

surfer/utils.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,8 @@ def ffmpeg(dst, frame_path, framerate=24, codec='mpeg4', bitrate='1M'):
699699
frame_dir, frame_fmt = os.path.split(frame_path)
700700

701701
# make the movie
702-
cmd = ['ffmpeg', '-i', frame_fmt, '-r', str(framerate), '-b', str(bitrate)]
702+
cmd = ['ffmpeg', '-i', frame_fmt, '-r', str(framerate),
703+
'-b:v', str(bitrate)]
703704
if codec is not None:
704705
cmd += ['-c', codec]
705706
cmd += [dst]
@@ -713,7 +714,8 @@ def ffmpeg(dst, frame_path, framerate=24, codec='mpeg4', bitrate='1M'):
713714
logger.info(std_info)
714715
if stderr.strip():
715716
err_info = os.linesep.join(("FFmpeg stderr", '=' * 27, stderr))
716-
logger.error(err_info)
717+
# FFmpeg prints to stderr in the absence of an error
718+
logger.info(err_info)
717719

718720
# check that movie file is created
719721
if not os.path.exists(dst):

0 commit comments

Comments
 (0)