ledwall.geometry

The geometry module includes some basic shapes that can be drawn to the display. The basic shapes are Point, Line, Rectangle.

Some sample code:

from ledwall.geometry import *

p1 = Point(2,4)
p2 = Point(7,12)

# Line between two points
l1 = Line(p1,p2)

# Line from values (x1,y1,x2,y2)
l1 = Line.fromTuple((0,0,5,10))

r1 = Rectangle(2,3,10,20)

Point

class ledwall.geometry.Point(x, y)

Rectangle

class ledwall.geometry.Rectangle(x, y, width, height)

Line

class ledwall.geometry.Line(p1, p2)