ManimGL: Python Math Animation Library
ManimGL is Grant Sanderson's original Python engine for scripting precise math animation, the same code that renders 3Blue1Brown's own videos. Its README tells newcomers to use the community-maintained fork instead for a more stable, tested, friendlier start. Reach for ManimGL if you want the exact tool behind those videos and don't mind debugging your own setup; skip it for tested releases — go to Manim Community Edition.
What is ManimGL?
ManimGL is a Python library for building precise, programmatic animations, aimed specifically at explanatory math videos. Scenes are written as Python classes, rendered through OpenGL, and exported with FFmpeg, with optional LaTeX support for typesetting equations. The package installs as `manimgl` — not `manim` — and requires Python 3.10 or higher.
Key Features for Animation
- ✓Scenes are Python classes: you subclass Scene and script animations against real mathematical objects, as shown in example_scenes.py's OpeningManimExample.
- ✓OpenGL rendering: manimgl example_scenes.py OpeningManimExample pops up a live window playing the scene, per the README.
- ✓FFmpeg handles video export, and LaTeX (MiKTeX, MacTeX, or a texlive distribution) is an optional dependency for typesetting math notation.
- ✓custom_config.yml centralizes output directories, where manim looks for image and sound assets, and default style and video-quality settings.
- ✓CLI flags built for iteration: -w writes to file, -o writes and opens it, -s jumps to the final frame (-so saves that frame as an image), -n <number> skips to a specific animation, and -f runs playback fullscreen.
- ✓The 3b1b/videos repo holds the actual production code behind 3Blue1Brown's videos, so you can read real scenes instead of only toy examples — though the README notes older video code may not run on the current manim.
Installing ManimGL
Manim requires Python 3.10 or higher, plus FFmpeg and OpenGL; LaTeX is an optional system dependency only needed if you want typeset equations. The straightforward path is `pip install manimgl` followed by running `manimgl` to try it — note the package name is `manimgl`, not `manim` or `manimlib`, and installing the wrong one is a documented gotcha the README calls out directly. To hack on the library itself, clone the repo and run `pip install -e .`, then `manimgl example_scenes.py OpeningManimExample` or `manim-render example_scenes.py OpeningManimExample`. On Ubuntu/Debian you also need `libpango1.0-dev` for Pango, and the README recommends the lighter `texlive-science texlive-fonts-extra texlive-latex-extra` bundle over the much larger `texlive-full` if you want LaTeX. Windows installs FFmpeg separately and uses MiKTeX for LaTeX; macOS uses `brew install ffmpeg mactex` (or the smaller BasicTeX cask if you don't want the ~6GB MacTeX bundle), and Apple Silicon users additionally need Cairo via `arch -arm64 brew install pkg-config cairo`. An Anaconda path is also documented: create an environment with `conda create -n manim python=3.10`, activate it, then `pip install -e .`.
Creating Animations with ManimGL
Running `manimgl example_scenes.py OpeningManimExample` opens a window and plays that scene directly — that's the fastest way to confirm your setup works. From there, the example_scenes.py file and the example-scenes page in the docs show the library's animation and object vocabulary in context. The 3b1b/videos repo goes further, containing the code actually used to produce 3Blue1Brown videos, plus notes on a more interactive workflow (demoed in a linked video) for iterating on a scene as you build it. Day to day, the CLI flags matter more than they look: `-n <number>` jumps straight to one animation in a scene instead of replaying everything before it, and `-s`/`-so` skip to the final frame so you can check composition without waiting on a full render. `custom_config.yml` — either edited in place or dropped into your working directory — is where you set default output paths and video quality instead of retyping flags.
Strengths
- ✓It's the actual production engine behind 3Blue1Brown's own videos, not a simplified spinoff, per the README's link to 3b1b/videos.
- ✓OpenGL rendering gives you a live preview window instead of only writing to a file, so you can watch a scene play with `manimgl example_scenes.py OpeningManimExample`.
- ✓Fine-grained CLI control for iterating on a single scene without re-rendering everything: -n jumps to a specific animation, -s/-so jumps to the final frame.
- ✓custom_config.yml gives you one place to set output paths, asset locations, and default style/quality instead of passing flags on every run.
- ✓MIT license, so there are no restrictive terms layered on top of the code itself.
Considerations for ManimGL Users
- △The README is explicit that its install instructions are for ManimGL only — following them for Manim Community Edition, or vice versa, 'will cause problems,' so the two aren't interchangeable despite the shared name.
- △Documentation is described as still 'in progress' at 3b1b.github.io/manim, not a finished reference.
- △The README itself frames Manim Community Edition as the safer choice for newcomers — better tested, more actively maintained, and generally easier to onboard onto, with a CI and contributor pipeline this original repo doesn't run at the same scale. Pull requests are still accepted here, just against thinner supporting infrastructure.
- △Code from older 3b1b/videos productions may not run on the current version of manim, per the README, so example scenes you find there aren't guaranteed to work as-is.
- △LaTeX support adds real setup weight: full MacTeX runs about 6GB, and the lighter BasicTeX or texlive-science alternatives mean manually adding packages as you hit missing ones.
- △Installing the wrong package is easy — `pip install manim` is a different package from this repo's `manimgl`, and the README flags that mix-up directly.
ManimGL vs. Manim Community Edition
ManimGL Frequently Asked Questions
ManimGL is 3b1b's original animation engine, built by Grant Sanderson for his own 3Blue1Brown videos. Manim Community Edition split off from it in 2020 and, per this repo's README, aims to be more stable, better tested, and friendlier to get started with — the two use different package names and aren't interchangeable.
ManimGL needs Python 3.10 or higher, plus FFmpeg and OpenGL; LaTeX is an optional dependency only required for typeset math. Linux installs also need Pango with its development headers.
Yes — ManimGL is released under the MIT license, the license listed for this repo on GitHub, which permits commercial use, modification, and redistribution.
Yes, LaTeX support is built in but optional — you install a distribution like MiKTeX on Windows or MacTeX/BasicTeX on macOS, and ManimGL uses it to typeset equations in scenes.
Run something like `manimgl example_scenes.py OpeningManimExample` to play a scene in a window. Add `-w` to write it to a file, `-o` to write and open it, `-s` or `-so` to jump to the final frame, `-n <number>` to skip to a specific animation, or `-f` for fullscreen playback.
Documentation is in progress at 3b1b.github.io/manim, which includes an example-scenes page. The 3b1b/videos repo has the real code behind 3Blue1Brown's videos, and a Chinese-language docs site (docs.manim.org.cn) is maintained separately by the manim-kindergarten community.
The problem it solves
Explaining a proof or a transformation visually usually means hand-keyframing shapes in a motion-graphics tool that has no idea what a matrix or a limit is. ManimGL exists because Grant Sanderson needed to drive animations directly from mathematical objects in Python for his own 3Blue1Brown videos, so a scene is written as code against vectors, functions, and geometric primitives instead of dragged on a timeline. That workflow was personal and undocumented for years before other developers forked it into a project built to be usable by people who aren't Grant Sanderson.
Best use cases
- •Building the exact kind of precise, programmatic math animation 3Blue1Brown itself uses, since this is the engine behind those videos.
- •Prototyping a scene's timing and camera work locally by using -s/-so to jump straight to a frame instead of re-rendering from the start.
- •Learning the library's scene/animation vocabulary by reading through example_scenes.py and the example scenes page in the docs.
- •Hacking on manimlib itself (cloning the repo and installing with pip install -e .) for developers who want to extend or modify the engine's internals rather than just call it.
Who should try it — and who should skip
Try ManimGL if you specifically want the tool 3Blue1Brown's own videos are built with, you're comfortable resolving your own FFmpeg/LaTeX/OpenGL setup issues, and you'd rather script a scene in Python than click through a GUI. Skip it — and install Manim Community Edition instead — if you want tested releases, active CI, and documentation that's further along, since the README itself points newcomers there.
Related repositories
Curious whether manim is right for you?
Let ChatGPT, Claude, or Perplexity look into it — click below and see what AI actually says about manim.
