Perpendicular¶
Qualified name: manimextra.geometry.Perpendicular
- class manimextra.geometry.Perpendicular(line, dot, length=1.0, rotate=False, **kwargs)¶
Bases:
Line
A class to represent a perpendicular line to another line.
- Parameters:
line (Line) – The line to which the perpendicular line is drawn.
dot (Point3DLike) – The point through which the perpendicular line passes.
length (float, optional) – The length of the perpendicular line, by default 1.0.
rotate (bool, optional) – Use if you want the perpendicular to be in the other direction, by default False.
Examples
Example: PerpendicularExample ¶
from manim import * from manimextra import * class PerpendicularExample(Scene): def construct(self): line = Line(2 * LEFT, 2 * RIGHT, color=YELLOW) dot = Dot(RIGHT + UP) perpendicular = Perpendicular(line, dot, color=RED) self.add(line, dot, perpendicular)
Methods
get_angles
get_foot
get_line
get_vertex
Attributes
animate
Used to animate the application of any method of
self
.animation_overrides
color
depth
The depth of the mobject.
fill_color
If there are multiple colors (for gradient) this returns the first one
height
The height of the mobject.
n_points_per_curve
sheen_factor
stroke_color
width
The width of the mobject.
- _original__init__(line, dot, length=1.0, rotate=False, **kwargs)¶
Initialize self. See help(type(self)) for accurate signature.