()
| 130 | return motion_params |
| 131 | |
| 132 | def ffmpeg_exe(): |
| 133 | import shutil as _sh |
| 134 | ff = _sh.which("ffmpeg") |
| 135 | if ff: return ff |
| 136 | import imageio_ffmpeg |
| 137 | return imageio_ffmpeg.get_ffmpeg_exe() |
| 138 | |
| 139 | def encode_sequence(pattern_glob: str, out_mp4: Path, fps: int, lossless: bool = False): |
| 140 | out_mp4.parent.mkdir(parents=True, exist_ok=True) |