Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from manim import *
- class TTP(ThreeDScene):
- def construct(self):
- self.set_camera_orientation(
- phi = 75 * DEGREES,
- theta = -70 * DEGREES
- )
- area = Polygon(
- [-3.5, -3, -2],
- [3.5, -3, -2],
- [3.5, 3, -2],
- [-3.5, 3, -2],
- [-3.5, -3, -2]
- ).set_stroke('#a473e3', 2).set_fill('#a473e3', 0.04)
- A = np.array([-1.5, -1.5, -2])
- N = np.array([1.5, 1.5, -2])
- M = np.array([1.5, 1.5, 2])
- Line.set_default(stroke_width = 2.5, stroke_color = '#f29136')
- AN = Line(A, N)
- AM = Line(A, M)
- MN = Line(M, N)
- labels = MathTex("l", "p", color = BLACK).scale(0.8)
- labels[0].next_to(AM, UP, buff=0.5)
- labels[1].next_to(AN, RIGHT, buff = 0.1)
- self.add_fixed_orientation_mobjects(labels)
- self.add(area, AN, AM, MN, labels)
- self.wait()
- self.move_camera(
- phi = 75 * DEGREES,
- theta = -40 * DEGREES,
- run_time = 3
- )
- self.wait()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement