Metadata-Version: 2.3
Name: fmov
Version: 0.2.1
Summary: A simple, optimized way to programmatically create video with python. Includes interactive preview and animation debugging tools.
License: MIT
Author: Dylan DiBeneditto
Author-email: dibenedittod@gmail.com
Requires-Python: >=3.12
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Requires-Dist: PyQt5
Requires-Dist: ffmpeg-python
Requires-Dist: numpy
Requires-Dist: pillow
Requires-Dist: rich
Description-Content-Type: text/markdown

# fmov

![fmov logo](https://github.com/dylandibeneditto/fmov/blob/main/logo.png?raw=true)

![Pepy Total Downloads](https://img.shields.io/pepy/dt/fmov)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/fmov)
![PyPI - License](https://img.shields.io/pypi/l/fmov)
[![X (formerly Twitter) Follow](https://img.shields.io/twitter/follow/dylan_ditto)](https://x.com/intent/follow?screen_name=dylan_ditto)

A performant way to create rendered video with Python by leveraging `ffmpeg` and `PIL`.

[Documentation](https://dylandibeneditto.github.io/fmov/)

## Rough Benchmarks

| FPS | Resolution | Video Time | Render Time | Video Time / Render Time |
| --- | ---------- | ---------- | ----------- | --------------- |
| 1 | 1920x1080 | 30s | 0.381s | 78.74x |
| 12 | 1920x1080 | 30s | 1.995s | 15.00x |
| 24 | 1920x1080 | 30s | 3.751s | 8.00x |
| 30 | 1920x1080 | 30s | 4.541s | 6.60x |
| 60 | 1920x1080 | 30s | 8.990s | 3.34x |
| 100 | 1920x1080 | 30s | 14.492s | 2.07x |
| 120 | 1920x1080 | 30s | 17.960s | 1.67x |

---

https://github.com/user-attachments/assets/1bbe2acc-e563-4fa4-bbf0-b0e6f04f0016

> Here's an example use of fmov for automated chess analysis videos (trimmed to 1:30 to allow for embedding)

## Installing

Install fmov via pip:

```bash
pip install fmov
```

### Dependencies

Make sure to have ffmpeg installed on your system and executable from the terminal

```bash
sudo apt install ffmpeg     # Linux
brew install ffmpeg         # MacOS
choco install ffmpeg        # Windows
```

[Downloading FFmpeg](https://ffmpeg.org/download.html)

> [!NOTE]
> PIL will also be installed with fmov through pip as a dependency. (unless its already installed)

