manim 0.18.1__tar.gz → 0.19.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of manim might be problematic. Click here for more details.
- {manim-0.18.1 → manim-0.19.0}/PKG-INFO +16 -9
- {manim-0.18.1 → manim-0.19.0}/README.md +4 -2
- manim-0.19.0/manim/__main__.py +101 -0
- {manim-0.18.1 → manim-0.19.0}/manim/_config/__init__.py +2 -2
- {manim-0.18.1 → manim-0.19.0}/manim/_config/cli_colors.py +8 -4
- {manim-0.18.1 → manim-0.19.0}/manim/_config/default.cfg +0 -2
- {manim-0.18.1 → manim-0.19.0}/manim/_config/logger_utils.py +5 -0
- {manim-0.18.1 → manim-0.19.0}/manim/_config/utils.py +29 -38
- {manim-0.18.1 → manim-0.19.0}/manim/animation/animation.py +148 -8
- {manim-0.18.1 → manim-0.19.0}/manim/animation/composition.py +16 -13
- {manim-0.18.1 → manim-0.19.0}/manim/animation/creation.py +184 -8
- {manim-0.18.1 → manim-0.19.0}/manim/animation/fading.py +5 -8
- {manim-0.18.1 → manim-0.19.0}/manim/animation/indication.py +93 -26
- {manim-0.18.1 → manim-0.19.0}/manim/animation/movement.py +21 -3
- {manim-0.18.1 → manim-0.19.0}/manim/animation/rotation.py +2 -1
- {manim-0.18.1 → manim-0.19.0}/manim/animation/specialized.py +3 -5
- {manim-0.18.1 → manim-0.19.0}/manim/animation/speedmodifier.py +3 -3
- {manim-0.18.1 → manim-0.19.0}/manim/animation/transform.py +4 -5
- {manim-0.18.1 → manim-0.19.0}/manim/animation/updaters/mobject_update_utils.py +17 -14
- {manim-0.18.1 → manim-0.19.0}/manim/camera/camera.py +2 -2
- manim-0.19.0/manim/cli/__init__.py +17 -0
- {manim-0.18.1 → manim-0.19.0}/manim/cli/cfg/group.py +52 -36
- {manim-0.18.1 → manim-0.19.0}/manim/cli/checkhealth/checks.py +92 -76
- {manim-0.18.1 → manim-0.19.0}/manim/cli/checkhealth/commands.py +12 -5
- manim-0.19.0/manim/cli/default_group.py +199 -0
- {manim-0.18.1 → manim-0.19.0}/manim/cli/init/commands.py +28 -23
- {manim-0.18.1 → manim-0.19.0}/manim/cli/plugins/commands.py +13 -3
- {manim-0.18.1 → manim-0.19.0}/manim/cli/render/commands.py +47 -42
- {manim-0.18.1 → manim-0.19.0}/manim/cli/render/global_options.py +43 -9
- {manim-0.18.1 → manim-0.19.0}/manim/cli/render/render_options.py +84 -19
- {manim-0.18.1 → manim-0.19.0}/manim/constants.py +11 -4
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/frame.py +0 -1
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/geometry/arc.py +109 -75
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/geometry/boolean_ops.py +20 -17
- manim-0.19.0/manim/mobject/geometry/labeled.py +378 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/geometry/line.py +120 -60
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/geometry/polygram.py +109 -25
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/geometry/shape_matchers.py +35 -15
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/geometry/tips.py +36 -27
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/graph.py +48 -40
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/graphing/coordinate_systems.py +110 -45
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/graphing/functions.py +16 -10
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/graphing/number_line.py +23 -9
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/graphing/probability.py +2 -10
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/graphing/scale.py +6 -5
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/matrix.py +17 -19
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/mobject.py +149 -103
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_geometry.py +4 -8
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_mobject.py +506 -343
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_point_cloud_mobject.py +3 -7
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_surface.py +1 -2
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_vectorized_mobject.py +27 -65
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/svg/brace.py +61 -13
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/svg/svg_mobject.py +2 -1
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/table.py +11 -12
- manim-0.19.0/manim/mobject/text/code_mobject.py +260 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/text/numbers.py +7 -7
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/text/tex_mobject.py +22 -13
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/text/text_mobject.py +29 -20
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/three_d/polyhedra.py +98 -1
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/three_d/three_dimensions.py +59 -31
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/types/image_mobject.py +37 -23
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/types/point_cloud_mobject.py +103 -67
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/types/vectorized_mobject.py +387 -214
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/value_tracker.py +2 -1
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/vector_field.py +2 -4
- {manim-0.18.1 → manim-0.19.0}/manim/opengl/__init__.py +3 -3
- {manim-0.18.1 → manim-0.19.0}/manim/plugins/__init__.py +2 -3
- {manim-0.18.1 → manim-0.19.0}/manim/plugins/plugins_flags.py +3 -3
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/cairo_renderer.py +11 -11
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/opengl_renderer.py +19 -20
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shader.py +2 -3
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shader_wrapper.py +3 -2
- {manim-0.18.1 → manim-0.19.0}/manim/scene/moving_camera_scene.py +23 -0
- {manim-0.18.1 → manim-0.19.0}/manim/scene/scene.py +72 -41
- {manim-0.18.1 → manim-0.19.0}/manim/scene/scene_file_writer.py +313 -164
- {manim-0.18.1 → manim-0.19.0}/manim/scene/section.py +15 -15
- {manim-0.18.1 → manim-0.19.0}/manim/scene/three_d_scene.py +8 -15
- {manim-0.18.1 → manim-0.19.0}/manim/scene/vector_space_scene.py +3 -6
- {manim-0.18.1 → manim-0.19.0}/manim/typing.py +326 -66
- manim-0.19.0/manim/utils/bezier.py +2079 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/caching.py +11 -5
- {manim-0.18.1 → manim-0.19.0}/manim/utils/color/AS2700.py +2 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/color/BS381.py +2 -0
- manim-0.19.0/manim/utils/color/DVIPSNAMES.py +96 -0
- manim-0.19.0/manim/utils/color/SVGNAMES.py +179 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/color/X11.py +3 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/color/XKCD.py +2 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/color/__init__.py +8 -5
- manim-0.19.0/manim/utils/color/core.py +1571 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/color/manim_colors.py +7 -9
- manim-0.19.0/manim/utils/commands.py +74 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/config_ops.py +18 -13
- {manim-0.18.1 → manim-0.19.0}/manim/utils/debug.py +8 -6
- {manim-0.18.1 → manim-0.19.0}/manim/utils/deprecation.py +92 -43
- {manim-0.18.1 → manim-0.19.0}/manim/utils/docbuild/autoaliasattr_directive.py +45 -8
- {manim-0.18.1 → manim-0.19.0}/manim/utils/docbuild/autocolor_directive.py +12 -13
- {manim-0.18.1 → manim-0.19.0}/manim/utils/docbuild/manim_directive.py +35 -29
- {manim-0.18.1 → manim-0.19.0}/manim/utils/docbuild/module_parsing.py +74 -27
- {manim-0.18.1 → manim-0.19.0}/manim/utils/family.py +3 -3
- {manim-0.18.1 → manim-0.19.0}/manim/utils/family_ops.py +12 -4
- {manim-0.18.1 → manim-0.19.0}/manim/utils/file_ops.py +22 -16
- {manim-0.18.1 → manim-0.19.0}/manim/utils/hashing.py +7 -7
- {manim-0.18.1 → manim-0.19.0}/manim/utils/images.py +10 -4
- {manim-0.18.1 → manim-0.19.0}/manim/utils/ipython_magic.py +12 -8
- {manim-0.18.1 → manim-0.19.0}/manim/utils/iterables.py +161 -119
- {manim-0.18.1 → manim-0.19.0}/manim/utils/module_ops.py +55 -19
- {manim-0.18.1 → manim-0.19.0}/manim/utils/opengl.py +68 -23
- {manim-0.18.1 → manim-0.19.0}/manim/utils/parameter_parsing.py +3 -2
- {manim-0.18.1 → manim-0.19.0}/manim/utils/paths.py +11 -5
- manim-0.19.0/manim/utils/polylabel.py +168 -0
- manim-0.19.0/manim/utils/qhull.py +218 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/rate_functions.py +69 -32
- {manim-0.18.1 → manim-0.19.0}/manim/utils/simple_functions.py +24 -15
- {manim-0.18.1 → manim-0.19.0}/manim/utils/sounds.py +7 -1
- {manim-0.18.1 → manim-0.19.0}/manim/utils/space_ops.py +48 -37
- {manim-0.18.1 → manim-0.19.0}/manim/utils/testing/_frames_testers.py +13 -8
- {manim-0.18.1 → manim-0.19.0}/manim/utils/testing/_show_diff.py +5 -3
- manim-0.19.0/manim/utils/testing/_test_class_makers.py +92 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/testing/frames_comparison.py +20 -14
- {manim-0.18.1 → manim-0.19.0}/manim/utils/tex.py +4 -2
- {manim-0.18.1 → manim-0.19.0}/manim/utils/tex_file_writing.py +45 -45
- {manim-0.18.1 → manim-0.19.0}/manim/utils/tex_templates.py +1 -1
- {manim-0.18.1 → manim-0.19.0}/manim/utils/unit.py +6 -5
- {manim-0.18.1 → manim-0.19.0}/pyproject.toml +117 -15
- manim-0.18.1/manim/__main__.py +0 -68
- manim-0.18.1/manim/cli/default_group.py +0 -75
- manim-0.18.1/manim/mobject/geometry/labeled.py +0 -155
- manim-0.18.1/manim/mobject/text/code_mobject.py +0 -624
- manim-0.18.1/manim/utils/__init__.py +0 -0
- manim-0.18.1/manim/utils/bezier.py +0 -802
- manim-0.18.1/manim/utils/color/core.py +0 -1054
- manim-0.18.1/manim/utils/commands.py +0 -53
- manim-0.18.1/manim/utils/testing/_test_class_makers.py +0 -77
- {manim-0.18.1 → manim-0.19.0}/LICENSE +0 -0
- {manim-0.18.1 → manim-0.19.0}/LICENSE.community +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/animation/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/animation/changing.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/animation/growing.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/animation/numbers.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/animation/transform_matching_parts.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/animation/updaters/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/animation/updaters/update.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/camera/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/camera/mapping_camera.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/camera/moving_camera.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/camera/multi_camera.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/camera/three_d_camera.py +0 -0
- {manim-0.18.1/manim/cli → manim-0.19.0/manim/cli/cfg}/__init__.py +0 -0
- {manim-0.18.1/manim/cli/cfg → manim-0.19.0/manim/cli/checkhealth}/__init__.py +0 -0
- {manim-0.18.1/manim/cli/checkhealth → manim-0.19.0/manim/cli/init}/__init__.py +0 -0
- {manim-0.18.1/manim/cli/init → manim-0.19.0/manim/cli/plugins}/__init__.py +0 -0
- {manim-0.18.1/manim/cli/plugins → manim-0.19.0/manim/cli/render}/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/cli/render/ease_of_access_options.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/cli/render/output_options.py +0 -0
- {manim-0.18.1/manim/cli/render → manim-0.19.0/manim/gui}/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/gui/gui.py +0 -0
- {manim-0.18.1/manim/gui → manim-0.19.0/manim/mobject}/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/geometry/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/graphing/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/logo.py +0 -0
- {manim-0.18.1/manim/mobject → manim-0.19.0/manim/mobject/opengl}/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/dot_cloud.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_compatibility.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_image_mobject.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/opengl/opengl_three_dimensions.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/svg/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/text/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/three_d/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/three_d/three_d_utils.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/types/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/mobject/utils.py +0 -0
- {manim-0.18.1/manim/mobject/opengl → manim-0.19.0/manim/renderer}/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/opengl_renderer_window.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/default/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/default/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/design.frag +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/design_2.frag +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/design_3.frag +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/image/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/image/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/NOTE.md +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/add_light.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/camera_uniform_declarations.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/finalize_color.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/get_gl_Position.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/get_rotated_surface_unit_normal_vector.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/get_unit_normal.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/position_point_into_frame.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/quadratic_bezier_distance.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/include/quadratic_bezier_geometry_functions.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/manim_coords/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/manim_coords/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/quadratic_bezier_fill/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/quadratic_bezier_fill/geom.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/quadratic_bezier_fill/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/quadratic_bezier_stroke/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/quadratic_bezier_stroke/geom.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/quadratic_bezier_stroke/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/simple_vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/surface/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/surface/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/test/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/test/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/textured_surface/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/textured_surface/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/true_dot/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/true_dot/geom.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/true_dot/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/vectorized_mobject_fill/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/vectorized_mobject_fill/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/vectorized_mobject_stroke/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/vectorized_mobject_stroke/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/vertex_colors/frag.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/shaders/vertex_colors/vert.glsl +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/renderer/vectorized_mobject_rendering.py +0 -0
- {manim-0.18.1/manim/renderer → manim-0.19.0/manim/scene}/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/scene/zoomed_scene.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/templates/Axes.mtp +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/templates/Default.mtp +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/templates/MovingCamera.mtp +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/templates/template.cfg +0 -0
- {manim-0.18.1/manim/scene → manim-0.19.0/manim/utils}/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/docbuild/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/exceptions.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/testing/__init__.py +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/testing/config_graphical_tests_monoframe.cfg +0 -0
- {manim-0.18.1 → manim-0.19.0}/manim/utils/testing/config_graphical_tests_multiframes.cfg +0 -0
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.3
|
|
2
2
|
Name: manim
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.19.0
|
|
4
4
|
Summary: Animation engine for explanatory math videos.
|
|
5
|
-
Home-page: https://www.manim.community/
|
|
6
5
|
License: MIT
|
|
7
6
|
Author: The Manim Community Developers
|
|
8
7
|
Author-email: contact@manim.community
|
|
9
|
-
Requires-Python: >=3.9
|
|
8
|
+
Requires-Python: >=3.9
|
|
10
9
|
Classifier: Development Status :: 4 - Beta
|
|
11
10
|
Classifier: License :: OSI Approved :: MIT License
|
|
12
11
|
Classifier: Natural Language :: English
|
|
@@ -15,7 +14,7 @@ Classifier: Programming Language :: Python :: 3.9
|
|
|
15
14
|
Classifier: Programming Language :: Python :: 3.10
|
|
16
15
|
Classifier: Programming Language :: Python :: 3.11
|
|
17
16
|
Classifier: Programming Language :: Python :: 3.12
|
|
18
|
-
Classifier: Programming Language :: Python :: 3.
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
19
18
|
Classifier: Topic :: Multimedia :: Graphics
|
|
20
19
|
Classifier: Topic :: Multimedia :: Video
|
|
21
20
|
Classifier: Topic :: Scientific/Engineering
|
|
@@ -23,6 +22,9 @@ Provides-Extra: gui
|
|
|
23
22
|
Provides-Extra: jupyterlab
|
|
24
23
|
Requires-Dist: Pillow (>=9.1)
|
|
25
24
|
Requires-Dist: Pygments (>=2.0.0)
|
|
25
|
+
Requires-Dist: audioop-lts (>=0.2.0) ; python_version >= "3.13"
|
|
26
|
+
Requires-Dist: av (>=9.0.0,<14.0.0)
|
|
27
|
+
Requires-Dist: beautifulsoup4 (>=4.12)
|
|
26
28
|
Requires-Dist: click (>=8.0)
|
|
27
29
|
Requires-Dist: cloup (>=2.0.0)
|
|
28
30
|
Requires-Dist: dearpygui (>=1.0.0) ; extra == "gui"
|
|
@@ -36,11 +38,13 @@ Requires-Dist: moderngl (>=5.0.0,<6.0.0)
|
|
|
36
38
|
Requires-Dist: moderngl-window (>=2.0.0)
|
|
37
39
|
Requires-Dist: networkx (>=2.6)
|
|
38
40
|
Requires-Dist: notebook (>=6.0.0) ; extra == "jupyterlab"
|
|
39
|
-
Requires-Dist: numpy (>=
|
|
41
|
+
Requires-Dist: numpy (>=2.0) ; python_version < "3.10"
|
|
42
|
+
Requires-Dist: numpy (>=2.1) ; python_version >= "3.10"
|
|
40
43
|
Requires-Dist: pycairo (>=1.13,<2.0.0)
|
|
41
44
|
Requires-Dist: pydub (>=0.20.0)
|
|
42
45
|
Requires-Dist: rich (>=12.0.0)
|
|
43
|
-
Requires-Dist: scipy (>=1.
|
|
46
|
+
Requires-Dist: scipy (>=1.13.0) ; python_version < "3.13"
|
|
47
|
+
Requires-Dist: scipy (>=1.14.0) ; python_version >= "3.13"
|
|
44
48
|
Requires-Dist: screeninfo (>=0.7)
|
|
45
49
|
Requires-Dist: skia-pathops (>=0.7.0)
|
|
46
50
|
Requires-Dist: srt (>=3.0.0)
|
|
@@ -52,6 +56,7 @@ Project-URL: Bug Tracker, https://github.com/ManimCommunity/manim/issues
|
|
|
52
56
|
Project-URL: Changelog, https://docs.manim.community/en/stable/changelog.html
|
|
53
57
|
Project-URL: Documentation, https://docs.manim.community/
|
|
54
58
|
Project-URL: Discord, https://www.manim.community/discord/
|
|
59
|
+
Project-URL: Homepage, https://www.manim.community/
|
|
55
60
|
Project-URL: Repository, https://github.com/manimcommunity/manim
|
|
56
61
|
Project-URL: Twitter, https://twitter.com/manim_community
|
|
57
62
|
Description-Content-Type: text/markdown
|
|
@@ -79,7 +84,8 @@ Description-Content-Type: text/markdown
|
|
|
79
84
|
|
|
80
85
|
Manim is an animation engine for explanatory math videos. It's used to create precise animations programmatically, as demonstrated in the videos of [3Blue1Brown](https://www.3blue1brown.com/).
|
|
81
86
|
|
|
82
|
-
> NOTE
|
|
87
|
+
> [!NOTE]
|
|
88
|
+
> The community edition of Manim has been forked from 3b1b/manim, a tool originally created and open-sourced by Grant Sanderson, also creator of the 3Blue1Brown educational math videos. While Grant Sanderson’s repository continues to be maintained separately by him, he is not among the maintainers of the community edition. We recommend this version for its continued development, improved features, enhanced documentation, and more active community-driven maintenance. If you would like to study how Grant makes his videos, head over to his repository ([3b1b/manim](https://github.com/3b1b/manim)).
|
|
83
89
|
|
|
84
90
|
## Table of Contents:
|
|
85
91
|
|
|
@@ -93,7 +99,8 @@ Manim is an animation engine for explanatory math videos. It's used to create pr
|
|
|
93
99
|
|
|
94
100
|
## Installation
|
|
95
101
|
|
|
96
|
-
>
|
|
102
|
+
> [!CAUTION]
|
|
103
|
+
> These instructions are for the community version _only_. Trying to use these instructions to install [3b1b/manim](https://github.com/3b1b/manim) or instructions there to install this version will cause problems. Read [this](https://docs.manim.community/en/stable/faq/installation.html#why-are-there-different-versions-of-manim) and decide which version you wish to install, then only follow the instructions for your desired version.
|
|
97
104
|
|
|
98
105
|
Manim requires a few dependencies that must be installed prior to using it. If you
|
|
99
106
|
want to try it out first before installing it locally, you can do so
|
|
@@ -21,7 +21,8 @@
|
|
|
21
21
|
|
|
22
22
|
Manim is an animation engine for explanatory math videos. It's used to create precise animations programmatically, as demonstrated in the videos of [3Blue1Brown](https://www.3blue1brown.com/).
|
|
23
23
|
|
|
24
|
-
> NOTE
|
|
24
|
+
> [!NOTE]
|
|
25
|
+
> The community edition of Manim has been forked from 3b1b/manim, a tool originally created and open-sourced by Grant Sanderson, also creator of the 3Blue1Brown educational math videos. While Grant Sanderson’s repository continues to be maintained separately by him, he is not among the maintainers of the community edition. We recommend this version for its continued development, improved features, enhanced documentation, and more active community-driven maintenance. If you would like to study how Grant makes his videos, head over to his repository ([3b1b/manim](https://github.com/3b1b/manim)).
|
|
25
26
|
|
|
26
27
|
## Table of Contents:
|
|
27
28
|
|
|
@@ -35,7 +36,8 @@ Manim is an animation engine for explanatory math videos. It's used to create pr
|
|
|
35
36
|
|
|
36
37
|
## Installation
|
|
37
38
|
|
|
38
|
-
>
|
|
39
|
+
> [!CAUTION]
|
|
40
|
+
> These instructions are for the community version _only_. Trying to use these instructions to install [3b1b/manim](https://github.com/3b1b/manim) or instructions there to install this version will cause problems. Read [this](https://docs.manim.community/en/stable/faq/installation.html#why-are-there-different-versions-of-manim) and decide which version you wish to install, then only follow the instructions for your desired version.
|
|
39
41
|
|
|
40
42
|
Manim requires a few dependencies that must be installed prior to using it. If you
|
|
41
43
|
want to try it out first before installing it locally, you can do so
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import click
|
|
4
|
+
import cloup
|
|
5
|
+
|
|
6
|
+
from manim import __version__
|
|
7
|
+
from manim._config import cli_ctx_settings, console
|
|
8
|
+
from manim.cli.cfg.group import cfg
|
|
9
|
+
from manim.cli.checkhealth.commands import checkhealth
|
|
10
|
+
from manim.cli.default_group import DefaultGroup
|
|
11
|
+
from manim.cli.init.commands import init
|
|
12
|
+
from manim.cli.plugins.commands import plugins
|
|
13
|
+
from manim.cli.render.commands import render
|
|
14
|
+
from manim.constants import EPILOG
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
def show_splash(ctx: click.Context, param: click.Option, value: str | None) -> None:
|
|
18
|
+
"""When giving a value by console, show an initial message with the Manim
|
|
19
|
+
version before executing any other command: ``Manim Community vA.B.C``.
|
|
20
|
+
|
|
21
|
+
Parameters
|
|
22
|
+
----------
|
|
23
|
+
ctx
|
|
24
|
+
The Click context.
|
|
25
|
+
param
|
|
26
|
+
A Click option.
|
|
27
|
+
value
|
|
28
|
+
A string value given by console, or None.
|
|
29
|
+
"""
|
|
30
|
+
if value:
|
|
31
|
+
console.print(f"Manim Community [green]v{__version__}[/green]\n")
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
def print_version_and_exit(
|
|
35
|
+
ctx: click.Context, param: click.Option, value: str | None
|
|
36
|
+
) -> None:
|
|
37
|
+
"""Same as :func:`show_splash`, but also exit when giving a value by
|
|
38
|
+
console.
|
|
39
|
+
|
|
40
|
+
Parameters
|
|
41
|
+
----------
|
|
42
|
+
ctx
|
|
43
|
+
The Click context.
|
|
44
|
+
param
|
|
45
|
+
A Click option.
|
|
46
|
+
value
|
|
47
|
+
A string value given by console, or None.
|
|
48
|
+
"""
|
|
49
|
+
show_splash(ctx, param, value)
|
|
50
|
+
if value:
|
|
51
|
+
ctx.exit()
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
@cloup.group(
|
|
55
|
+
context_settings=cli_ctx_settings,
|
|
56
|
+
cls=DefaultGroup,
|
|
57
|
+
default="render",
|
|
58
|
+
no_args_is_help=True,
|
|
59
|
+
help="Animation engine for explanatory math videos.",
|
|
60
|
+
epilog="See 'manim <command>' to read about a specific subcommand.\n\n"
|
|
61
|
+
"Note: the subcommand 'manim render' is called if no other subcommand "
|
|
62
|
+
"is specified. Run 'manim render --help' if you would like to know what the "
|
|
63
|
+
f"'-ql' or '-p' flags do, for example.\n\n{EPILOG}",
|
|
64
|
+
)
|
|
65
|
+
@cloup.option(
|
|
66
|
+
"--version",
|
|
67
|
+
is_flag=True,
|
|
68
|
+
help="Show version and exit.",
|
|
69
|
+
callback=print_version_and_exit,
|
|
70
|
+
is_eager=True,
|
|
71
|
+
expose_value=False,
|
|
72
|
+
)
|
|
73
|
+
@click.option(
|
|
74
|
+
"--show-splash/--hide-splash",
|
|
75
|
+
is_flag=True,
|
|
76
|
+
default=True,
|
|
77
|
+
help="Print splash message with version information.",
|
|
78
|
+
callback=show_splash,
|
|
79
|
+
is_eager=True,
|
|
80
|
+
expose_value=False,
|
|
81
|
+
)
|
|
82
|
+
@cloup.pass_context
|
|
83
|
+
def main(ctx: click.Context) -> None:
|
|
84
|
+
"""The entry point for Manim.
|
|
85
|
+
|
|
86
|
+
Parameters
|
|
87
|
+
----------
|
|
88
|
+
ctx
|
|
89
|
+
The Click context.
|
|
90
|
+
"""
|
|
91
|
+
pass
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
main.add_command(checkhealth)
|
|
95
|
+
main.add_command(cfg)
|
|
96
|
+
main.add_command(plugins)
|
|
97
|
+
main.add_command(init)
|
|
98
|
+
main.add_command(render)
|
|
99
|
+
|
|
100
|
+
if __name__ == "__main__":
|
|
101
|
+
main()
|
|
@@ -3,8 +3,9 @@
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
5
|
import logging
|
|
6
|
+
from collections.abc import Generator
|
|
6
7
|
from contextlib import contextmanager
|
|
7
|
-
from typing import Any
|
|
8
|
+
from typing import Any
|
|
8
9
|
|
|
9
10
|
from .cli_colors import parse_cli_ctx
|
|
10
11
|
from .logger_utils import make_logger
|
|
@@ -67,7 +68,6 @@ def tempconfig(temp: ManimConfig | dict[str, Any]) -> Generator[None, None, None
|
|
|
67
68
|
8.0
|
|
68
69
|
>>> with tempconfig({"frame_height": 100.0}):
|
|
69
70
|
... print(config["frame_height"])
|
|
70
|
-
...
|
|
71
71
|
100.0
|
|
72
72
|
>>> config["frame_height"]
|
|
73
73
|
8.0
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
from __future__ import annotations
|
|
2
2
|
|
|
3
3
|
import configparser
|
|
4
|
+
from typing import Any
|
|
4
5
|
|
|
5
6
|
from cloup import Context, HelpFormatter, HelpTheme, Style
|
|
6
7
|
|
|
7
8
|
__all__ = ["parse_cli_ctx"]
|
|
8
9
|
|
|
9
10
|
|
|
10
|
-
def parse_cli_ctx(parser: configparser.SectionProxy) ->
|
|
11
|
+
def parse_cli_ctx(parser: configparser.SectionProxy) -> dict[str, Any]:
|
|
11
12
|
formatter_settings: dict[str, str | int] = {
|
|
12
13
|
"indent_increment": int(parser["indent_increment"]),
|
|
13
14
|
"width": int(parser["width"]),
|
|
@@ -35,15 +36,18 @@ def parse_cli_ctx(parser: configparser.SectionProxy) -> Context:
|
|
|
35
36
|
theme = parser["theme"] if parser["theme"] else None
|
|
36
37
|
if theme is None:
|
|
37
38
|
formatter = HelpFormatter.settings(
|
|
38
|
-
theme=HelpTheme(**theme_settings),
|
|
39
|
+
theme=HelpTheme(**theme_settings),
|
|
40
|
+
**formatter_settings, # type: ignore[arg-type]
|
|
39
41
|
)
|
|
40
42
|
elif theme.lower() == "dark":
|
|
41
43
|
formatter = HelpFormatter.settings(
|
|
42
|
-
theme=HelpTheme.dark().with_(**theme_settings),
|
|
44
|
+
theme=HelpTheme.dark().with_(**theme_settings),
|
|
45
|
+
**formatter_settings, # type: ignore[arg-type]
|
|
43
46
|
)
|
|
44
47
|
elif theme.lower() == "light":
|
|
45
48
|
formatter = HelpFormatter.settings(
|
|
46
|
-
theme=HelpTheme.light().with_(**theme_settings),
|
|
49
|
+
theme=HelpTheme.light().with_(**theme_settings),
|
|
50
|
+
**formatter_settings, # type: ignore[arg-type]
|
|
47
51
|
)
|
|
48
52
|
|
|
49
53
|
return Context.settings(
|
|
@@ -221,8 +221,6 @@ repr_number = green
|
|
|
221
221
|
# Uncomment the following line to manually set the loglevel for ffmpeg. See
|
|
222
222
|
# ffmpeg manpage for accepted values
|
|
223
223
|
loglevel = ERROR
|
|
224
|
-
# defaults to the one present in path
|
|
225
|
-
ffmpeg_executable = ffmpeg
|
|
226
224
|
|
|
227
225
|
[jupyter]
|
|
228
226
|
media_embed = False
|
|
@@ -99,6 +99,11 @@ def make_logger(
|
|
|
99
99
|
logger = logging.getLogger("manim")
|
|
100
100
|
logger.addHandler(rich_handler)
|
|
101
101
|
logger.setLevel(verbosity)
|
|
102
|
+
logger.propagate = False
|
|
103
|
+
|
|
104
|
+
if not (libav_logger := logging.getLogger()).hasHandlers():
|
|
105
|
+
libav_logger.addHandler(rich_handler)
|
|
106
|
+
libav_logger.setLevel(verbosity)
|
|
102
107
|
|
|
103
108
|
return logger, console, error_console
|
|
104
109
|
|
|
@@ -20,9 +20,9 @@ import logging
|
|
|
20
20
|
import os
|
|
21
21
|
import re
|
|
22
22
|
import sys
|
|
23
|
-
from collections.abc import Mapping, MutableMapping
|
|
23
|
+
from collections.abc import Iterable, Iterator, Mapping, MutableMapping
|
|
24
24
|
from pathlib import Path
|
|
25
|
-
from typing import TYPE_CHECKING, Any, ClassVar,
|
|
25
|
+
from typing import TYPE_CHECKING, Any, ClassVar, NoReturn
|
|
26
26
|
|
|
27
27
|
import numpy as np
|
|
28
28
|
|
|
@@ -40,6 +40,8 @@ if TYPE_CHECKING:
|
|
|
40
40
|
|
|
41
41
|
__all__ = ["config_file_paths", "make_config_parser", "ManimConfig", "ManimFrame"]
|
|
42
42
|
|
|
43
|
+
logger = logging.getLogger("manim")
|
|
44
|
+
|
|
43
45
|
|
|
44
46
|
def config_file_paths() -> list[Path]:
|
|
45
47
|
"""The paths where ``.cfg`` files will be searched for.
|
|
@@ -263,7 +265,6 @@ class ManimConfig(MutableMapping):
|
|
|
263
265
|
"dry_run",
|
|
264
266
|
"enable_wireframe",
|
|
265
267
|
"ffmpeg_loglevel",
|
|
266
|
-
"ffmpeg_executable",
|
|
267
268
|
"format",
|
|
268
269
|
"flush_cache",
|
|
269
270
|
"frame_height",
|
|
@@ -322,7 +323,7 @@ class ManimConfig(MutableMapping):
|
|
|
322
323
|
}
|
|
323
324
|
|
|
324
325
|
def __init__(self) -> None:
|
|
325
|
-
self._d: dict[str, Any | None] =
|
|
326
|
+
self._d: dict[str, Any | None] = dict.fromkeys(self._OPTS)
|
|
326
327
|
|
|
327
328
|
# behave like a dict
|
|
328
329
|
def __iter__(self) -> Iterator[str]:
|
|
@@ -371,7 +372,6 @@ class ManimConfig(MutableMapping):
|
|
|
371
372
|
:meth:`~ManimConfig.digest_parser`
|
|
372
373
|
|
|
373
374
|
"""
|
|
374
|
-
|
|
375
375
|
if isinstance(obj, ManimConfig):
|
|
376
376
|
self._d.update(obj._d)
|
|
377
377
|
if obj.tex_template:
|
|
@@ -642,21 +642,18 @@ class ManimConfig(MutableMapping):
|
|
|
642
642
|
gui_location = tuple(
|
|
643
643
|
map(int, re.split(r"[;,\-]", parser["CLI"]["gui_location"])),
|
|
644
644
|
)
|
|
645
|
-
|
|
645
|
+
self.gui_location = gui_location
|
|
646
646
|
|
|
647
647
|
window_size = parser["CLI"][
|
|
648
648
|
"window_size"
|
|
649
649
|
] # if not "default", get a tuple of the position
|
|
650
650
|
if window_size != "default":
|
|
651
651
|
window_size = tuple(map(int, re.split(r"[;,\-]", window_size)))
|
|
652
|
-
|
|
652
|
+
self.window_size = window_size
|
|
653
653
|
|
|
654
654
|
# plugins
|
|
655
655
|
plugins = parser["CLI"].get("plugins", fallback="", raw=True)
|
|
656
|
-
if plugins == ""
|
|
657
|
-
plugins = []
|
|
658
|
-
else:
|
|
659
|
-
plugins = plugins.split(",")
|
|
656
|
+
plugins = [] if plugins == "" else plugins.split(",")
|
|
660
657
|
self.plugins = plugins
|
|
661
658
|
# the next two must be set AFTER digesting pixel_width and pixel_height
|
|
662
659
|
self["frame_height"] = parser["CLI"].getfloat("frame_height", 8.0)
|
|
@@ -673,25 +670,21 @@ class ManimConfig(MutableMapping):
|
|
|
673
670
|
|
|
674
671
|
val = parser["CLI"].get("progress_bar")
|
|
675
672
|
if val:
|
|
676
|
-
|
|
673
|
+
self.progress_bar = val
|
|
677
674
|
|
|
678
675
|
val = parser["ffmpeg"].get("loglevel")
|
|
679
676
|
if val:
|
|
680
677
|
self.ffmpeg_loglevel = val
|
|
681
678
|
|
|
682
|
-
# TODO: Fix the mess above and below
|
|
683
|
-
val = parser["ffmpeg"].get("ffmpeg_executable")
|
|
684
|
-
setattr(self, "ffmpeg_executable", val)
|
|
685
|
-
|
|
686
679
|
try:
|
|
687
680
|
val = parser["jupyter"].getboolean("media_embed")
|
|
688
681
|
except ValueError:
|
|
689
682
|
val = None
|
|
690
|
-
|
|
683
|
+
self.media_embed = val
|
|
691
684
|
|
|
692
685
|
val = parser["jupyter"].get("media_width")
|
|
693
686
|
if val:
|
|
694
|
-
|
|
687
|
+
self.media_width = val
|
|
695
688
|
|
|
696
689
|
val = parser["CLI"].get("quality", fallback="", raw=True)
|
|
697
690
|
if val:
|
|
@@ -804,7 +797,7 @@ class ManimConfig(MutableMapping):
|
|
|
804
797
|
try:
|
|
805
798
|
self.upto_animation_number = nflag[1]
|
|
806
799
|
except Exception:
|
|
807
|
-
|
|
800
|
+
logger.info(
|
|
808
801
|
f"No end scene number specified in -n option. Rendering from {nflag[0]} onwards...",
|
|
809
802
|
)
|
|
810
803
|
|
|
@@ -842,15 +835,12 @@ class ManimConfig(MutableMapping):
|
|
|
842
835
|
if args.tex_template:
|
|
843
836
|
self.tex_template = TexTemplate.from_file(args.tex_template)
|
|
844
837
|
|
|
845
|
-
if
|
|
846
|
-
self.renderer == RendererType.OPENGL
|
|
847
|
-
and getattr(args, "write_to_movie") is None
|
|
848
|
-
):
|
|
838
|
+
if self.renderer == RendererType.OPENGL and args.write_to_movie is None:
|
|
849
839
|
# --write_to_movie was not passed on the command line, so don't generate video.
|
|
850
840
|
self["write_to_movie"] = False
|
|
851
841
|
|
|
852
842
|
# Handle --gui_location flag.
|
|
853
|
-
if
|
|
843
|
+
if args.gui_location is not None:
|
|
854
844
|
self.gui_location = args.gui_location
|
|
855
845
|
|
|
856
846
|
return self
|
|
@@ -1043,7 +1033,7 @@ class ManimConfig(MutableMapping):
|
|
|
1043
1033
|
val,
|
|
1044
1034
|
["DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"],
|
|
1045
1035
|
)
|
|
1046
|
-
|
|
1036
|
+
logger.setLevel(val)
|
|
1047
1037
|
|
|
1048
1038
|
@property
|
|
1049
1039
|
def format(self) -> str:
|
|
@@ -1057,8 +1047,9 @@ class ManimConfig(MutableMapping):
|
|
|
1057
1047
|
val,
|
|
1058
1048
|
[None, "png", "gif", "mp4", "mov", "webm"],
|
|
1059
1049
|
)
|
|
1050
|
+
self.resolve_movie_file_extension(self.transparent)
|
|
1060
1051
|
if self.format == "webm":
|
|
1061
|
-
|
|
1052
|
+
logger.warning(
|
|
1062
1053
|
"Output format set as webm, this can be slower than other formats",
|
|
1063
1054
|
)
|
|
1064
1055
|
|
|
@@ -1074,15 +1065,7 @@ class ManimConfig(MutableMapping):
|
|
|
1074
1065
|
val,
|
|
1075
1066
|
["DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"],
|
|
1076
1067
|
)
|
|
1077
|
-
|
|
1078
|
-
@property
|
|
1079
|
-
def ffmpeg_executable(self) -> str:
|
|
1080
|
-
"""Custom path to the ffmpeg executable."""
|
|
1081
|
-
return self._d["ffmpeg_executable"]
|
|
1082
|
-
|
|
1083
|
-
@ffmpeg_executable.setter
|
|
1084
|
-
def ffmpeg_executable(self, value: str) -> None:
|
|
1085
|
-
self._set_str("ffmpeg_executable", value)
|
|
1068
|
+
logging.getLogger("libav").setLevel(self.ffmpeg_loglevel)
|
|
1086
1069
|
|
|
1087
1070
|
@property
|
|
1088
1071
|
def media_embed(self) -> bool:
|
|
@@ -1284,6 +1267,8 @@ class ManimConfig(MutableMapping):
|
|
|
1284
1267
|
@background_opacity.setter
|
|
1285
1268
|
def background_opacity(self, value: float) -> None:
|
|
1286
1269
|
self._set_between("background_opacity", value, 0, 1)
|
|
1270
|
+
if self.background_opacity < 1:
|
|
1271
|
+
self.resolve_movie_file_extension(is_transparent=True)
|
|
1287
1272
|
|
|
1288
1273
|
@property
|
|
1289
1274
|
def frame_size(self) -> tuple[int, int]:
|
|
@@ -1318,8 +1303,8 @@ class ManimConfig(MutableMapping):
|
|
|
1318
1303
|
|
|
1319
1304
|
@property
|
|
1320
1305
|
def transparent(self) -> bool:
|
|
1321
|
-
"""Whether the background opacity is
|
|
1322
|
-
return self._d["background_opacity"]
|
|
1306
|
+
"""Whether the background opacity is less than 1.0 (-t)."""
|
|
1307
|
+
return self._d["background_opacity"] < 1.0
|
|
1323
1308
|
|
|
1324
1309
|
@transparent.setter
|
|
1325
1310
|
def transparent(self, value: bool) -> None:
|
|
@@ -1437,6 +1422,7 @@ class ManimConfig(MutableMapping):
|
|
|
1437
1422
|
self._d.__setitem__("window_size", value)
|
|
1438
1423
|
|
|
1439
1424
|
def resolve_movie_file_extension(self, is_transparent: bool) -> None:
|
|
1425
|
+
prev_file_extension = self.movie_file_extension
|
|
1440
1426
|
if is_transparent:
|
|
1441
1427
|
self.movie_file_extension = ".webm" if self.format == "webm" else ".mov"
|
|
1442
1428
|
elif self.format == "webm":
|
|
@@ -1445,6 +1431,11 @@ class ManimConfig(MutableMapping):
|
|
|
1445
1431
|
self.movie_file_extension = ".mov"
|
|
1446
1432
|
else:
|
|
1447
1433
|
self.movie_file_extension = ".mp4"
|
|
1434
|
+
if self.movie_file_extension != prev_file_extension:
|
|
1435
|
+
logger.warning(
|
|
1436
|
+
f"Output format changed to '{self.movie_file_extension}' "
|
|
1437
|
+
"to support transparency",
|
|
1438
|
+
)
|
|
1448
1439
|
|
|
1449
1440
|
@property
|
|
1450
1441
|
def enable_gui(self) -> bool:
|
|
@@ -1790,7 +1781,7 @@ class ManimConfig(MutableMapping):
|
|
|
1790
1781
|
def tex_template_file(self, val: str) -> None:
|
|
1791
1782
|
if val:
|
|
1792
1783
|
if not os.access(val, os.R_OK):
|
|
1793
|
-
|
|
1784
|
+
logger.warning(
|
|
1794
1785
|
f"Custom TeX template {val} not found or not readable.",
|
|
1795
1786
|
)
|
|
1796
1787
|
else:
|