1
0
mirror of https://github.com/odrling/Aegisub synced 2025-04-11 22:56:02 +02:00

vapoursynth: Fix division by zero in aegisub_vs.py progress indicator

This commit is contained in:
arch1t3cht 2024-05-19 21:31:28 +02:00
parent 9683959f2e
commit 9b0fef1c38

View File

@ -236,7 +236,7 @@ def make_keyframes(clip: vs.VideoNode, use_scxvid: bool = False,
nonlocal done
keyframes[n] = f.props._SceneChangePrev if use_scxvid else f.props.Scenechange # type: ignore
done += 1
if done % (clip.num_frames // 200) == 0:
if done % max(1, clip.num_frames // 200) == 0:
progress_set_progress(100 * done / clip.num_frames)
return f