Skip to main content
ManimVTK Logo

What is ManimVTK?

ManimVTK is a powerful fork of Manim Community that combines the elegant animation syntax of Manim with VTK (Visualization Toolkit) for scientific visualization and export capabilities. Create stunning mathematical animations and export them as interactive 3D datasets for use in ParaView, PyVista, and vtk.js.

Key Features

Create elegant animations using Manim’s intuitive syntax. Animate geometric shapes, mathematical functions, graphs, and complex transformations with ease.
Export your scenes to VTK formats (.vtp, .vtm, .pvd) for visualization in ParaView and other scientific tools. Perfect for CFD, FEA, and research presentations.
Attach scalar fields (pressure, temperature) and vector fields (velocity, forces) to your exported VTK data for advanced scientific visualization.
Export frame-by-frame VTK files with ParaView Data (.pvd) collection files. Scrub through animations using ParaView’s native time slider.
Generate vtk.js compatible datasets for embedding interactive 3D visualizations in web applications and documentation.

Quick Example

Here’s a simple example that creates an animated surface and exports it to VTK format:
from manimvtk import *

class WaveSurface(Scene):
    def construct(self):
        # Create a parametric surface
        surface = Surface(
            lambda u, v: np.array([
                u,
                v,
                np.sin(u) * np.cos(v)
            ]),
            u_range=[-2, 2],
            v_range=[-2, 2],
            resolution=(50, 50),
        )
        surface.set_color(BLUE)

        # Animate the surface
        self.play(Create(surface))
        self.wait()
Render with VTK export:
manimvtk -pqh example.py WaveSurface --renderer vtk --vtk-export
Output:
  • media/videos/example/1080p60/WaveSurface.mp4 - Video animation
  • media/vtk/WaveSurface/WaveSurface_final.vtm - VTK MultiBlock file

Use Cases

Educational Content

Create engaging math and physics explanations with beautiful animations

CFD Visualization

Visualize computational fluid dynamics simulations with scalar and vector fields

Research Presentations

Generate publication-quality animations and interactive 3D datasets

Web Applications

Embed interactive 3D visualizations using vtk.js exports

Architecture

ManimVTK extends Manim’s renderer architecture with VTK support:
┌─────────────────────────────────────────────────────────┐
│                    Manim Core                           │
│  (Scene, Mobject, Animation, play, etc.)               │
└─────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────┐
│               Renderer Abstraction                       │
│  ┌─────────────┐ ┌─────────────┐ ┌─────────────────┐   │
│  │CairoRenderer│ │OpenGLRenderer│ │ VTKRenderer ✨  │   │
│  └─────────────┘ └─────────────┘ └─────────────────┘   │
└─────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────┐
│            VTK Export / Viewer Layer                    │
│  • File export (.vtp, .vtm, .pvd)                      │
│  • Manim → VTK conversion                              │
│  • Scalar/Vector field support                         │
└─────────────────────────────────────────────────────────┘

Getting Started

Ready to create your first animation? Follow our quick start guide:

Installation & Quick Start

Install ManimVTK and create your first scene

Community & Support