RAIMAD

raimad.RectWire

class RectWire( raimad.compo.Compo, ):
A rectangle defined by two points and a thickness.

def _make(self, p1: raimad.types.Vec2, p2: raimad.types.Vec2, width: float | int | SupportsFloat) -> None:

Make RectWire betweent two points.
Parameters
p1
The first point
p2
The second point
width
Width of rectwire
Returns
Self
The newly construct RectWire object

@classmethod def from_points(cls, p1: raimad.types.Vec2, p2: raimad.types.Vec2, width: float | int | SupportsFloat) -> Self:

Make RectWire betweent two points.
Parameters
p1
The first point
p2
The second point
width
Width of rectwire
Returns
Self
The newly construct RectWire object

@classmethod def from_polar(cls, p1: raimad.types.Vec2, angle: float | int | SupportsFloat, length: float | int | SupportsFloat, width: float | int | SupportsFloat) -> Self:

Make RectWire from polar coordinates.
Parameters
p1
Point where the RectWire starts
angle
Angle of rectwire in [numpy convention](coords-transforms.md)
length
Length of rectwire
width
Width of rectwire
Returns
Self
The newly construct RectWire object