Skip to main content

Create SVG files from VMobject and VGroup

Project description

manim-mobject-svg

Create SVG files from VMobject and VGroup.

Install: pip install manim-mobject-svg

Here's an example of how to use this plugin:

from manim import *
from manim_mobject_svg import *

a = Square(color=BLUE)
a.to_svg("square.svg")

This should create a file square.svg in the current directory and return the path to the file. The output should look like this:

svg square manim

It's also possible to create a SVG file for VGroup.

from manim import *
from manim_mobject_svg import *

a = Square(color=BLUE)
b = Circle(color=RED)
c = VGroup(a, b)
c.to_svg("group.svg")

It'll create a SVG file like this:

svg vgroup manim

Parameters for to_svg()

to_svg() takes the following parameters:

  • path: Path to the SVG file to be created. If not specified, it'll create a temporary file and return the path to the file.
  • crop: Crop the SVG file to the bounding box of the VMobject. Default: True
  • padding: Padding around the VMobject. Default: 0.5

This method returns the path to the SVG file.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

manim_mobject_svg-0.3.0.tar.gz (4.2 kB view details)

Uploaded Source

Built Distribution

manim_mobject_svg-0.3.0-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file manim_mobject_svg-0.3.0.tar.gz.

File metadata

  • Download URL: manim_mobject_svg-0.3.0.tar.gz
  • Upload date:
  • Size: 4.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.8.16 Linux/5.15.0-1038-azure

File hashes

Hashes for manim_mobject_svg-0.3.0.tar.gz
Algorithm Hash digest
SHA256 3dff3555b6eb60c51c32e53167c6a23237fdabc59622147b05620f231654f746
MD5 4b7707401038edf29307a0e4e48d7ae6
BLAKE2b-256 725e80a7fa54fadcbafa1df8521bd1804d1ec764ca5d2963dd5eaf9dcf200227

See more details on using hashes here.

File details

Details for the file manim_mobject_svg-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: manim_mobject_svg-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 5.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.8.16 Linux/5.15.0-1038-azure

File hashes

Hashes for manim_mobject_svg-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b217ba1f0205a2e8f6403587019784e1f64f0d1f3ea19f1c40091c8a21adbd05
MD5 27dca5cfe4ef319bb7fa5167cb39db93
BLAKE2b-256 3a2898e603fae1510db63cd51c0831b1b1c75176b1021aee89f1c11ca59f3d92

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page