Skip to content

Commit 175cb89

Browse files
yuan-xybehackl
andauthored
fix write_subcaption_file error when using opengl renderer (#3546)
* fix write_subcaption_file error when using opengl renderer * Update manim/scene/scene_file_writer.py --------- Co-authored-by: Benjamin Hackl <[email protected]>
1 parent 7006d6b commit 175cb89

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

manim/scene/scene_file_writer.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -725,6 +725,8 @@ def flush_cache_directory(self):
725725

726726
def write_subcaption_file(self):
727727
"""Writes the subcaption file."""
728+
if config.output_file is None:
729+
return
728730
subcaption_file = Path(config.output_file).with_suffix(".srt")
729731
subcaption_file.write_text(srt.compose(self.subcaptions), encoding="utf-8")
730732
logger.info(f"Subcaption file has been written as {subcaption_file}")

0 commit comments

Comments
 (0)