High-performance, browser-free, programmatic video rendering engine for Python.
Zero Chromium. Zero Puppeteer. Zero Node.js. 100% Pure Rust Native Speed.
pip install rust-motion(Prerequisite: ffmpeg installed on your system PATH)
import rust_motion
rust_motion.render(
composition="HelloWorld",
output="video.mp4",
props={"title": "Hello from Python", "subtitle": "Rendered in 0.3s"},
width=1920,
height=1080,
fps=30.0,
duration=90,
)import rust_motion
rust_motion.render_still(
composition="HelloWorld",
frame=30,
output="thumbnail.png"
)import rust_motion
rust_motion.render_script(
script_path="templates/shorts.rhai",
output="shorts.mp4",
props={
"headline": "Breaking AI News",
"caption": "Rendered natively without a browser.",
"tag": "TECH",
},
width=1080,
height=1920, # Vertical 9:16 Shorts / Reels
duration=90,
)import rust_motion
comp = rust_motion.Composition("HelloWorld", width=1920, height=1080, duration=180)
comp.render("output.mp4")
comp.render_still(frame=0, output="cover.png")| Metric | Remotion (Node.js + Chromium) | Rust Motion Python SDK | Advantage |
|---|---|---|---|
| Runtime Dependencies | Node.js, Chromium, X11, Mesa | Pure Rust Binary + FFmpeg | Zero Browser Overhead |
| Memory Footprint (RSS) | 1,800 ~ 2,500 MB | 400 ~ 900 MB | 4x ~ 6x Less RAM |
| 720p Render Time | 11.04 s | 0.35 s | 31x Faster |
| 1080p Shorts Render Time | ~12.0 s | 0.39 s (230 FPS) | 30x Faster |
| AWS Lambda 10k Cost | $4.60 | $0.15 | 96.8% Cost Savings |
MIT OR Apache-2.0