manim
manim copied to clipboard
Why the axes and Line didn't show after rendering
Describe the error

I use the manimgl --hd OpeningManimExample.py -o, but the video's axes and plot curve didn't show? Why?
What should I do to display the axes and Curve?
Code and Error
Code:
class OpeningManimExample(Scene):
def construct(self):
intro_words = Text(
"""
The original motivation for manim was to
better illustrate mathematical functions
as transformations.
"""
)
intro_words.to_edge(UP)
self.play(Write(intro_words))
self.wait(2)
# Linear transform
grid = NumberPlane((-10, 10), (-5, 5))
matrix = [[1, 1], [0, 1]]
linear_transform_words = VGroup(
Text("This is what the matrix"),
IntegerMatrix(matrix, include_background_rectangle=True),
Text("looks like"),
)
linear_transform_words.arrange(RIGHT)
linear_transform_words.to_edge(UP)
linear_transform_words.set_stroke(BLACK, 10, background=True)
self.play(
ShowCreation(grid), FadeTransform(intro_words, linear_transform_words)
)
self.wait()
self.play(grid.animate.apply_matrix(matrix), run_time=3)
self.wait()
# Complex map
c_grid = ComplexPlane()
moving_c_grid = c_grid.copy()
moving_c_grid.prepare_for_nonlinear_transform()
c_grid.set_stroke(BLUE_E, 1)
c_grid.add_coordinate_labels(font_size=24)
complex_map_words = TexText(
"""
Or thinking of the plane as $\\mathds{C}$,\\\\
this is the map $z \\rightarrow z^2$
"""
)
complex_map_words.to_corner(UR)
complex_map_words.set_stroke(BLACK, 5, background=True)
self.play(
FadeOut(grid),
Write(c_grid, run_time=3),
FadeIn(moving_c_grid),
FadeTransform(linear_transform_words, complex_map_words),
)
self.wait()
self.play(
moving_c_grid.animate.apply_complex_function(lambda z: z**2),
run_time=6,
)
self.wait(2)
Error:
No Errow, but the video didn't show the axes and curve.
Environment
OS System: Windows manim version: v1.6.1 python version: 3.10
I encountered the same issue, but resolved by installing manim from git-hub repository.
https://github.com/3b1b/manim#directly-windows
Thank you. I will try.