Rectangular ShapesΒΆ

These classes provide the basic geometry functionality for drawing solid, rectangular shapes. All these shapes have attributes x and y identifying the center of the shape, and attributes width and height defining the size. To draw a shape, simply call draw method providing and instance of GView.

Since these shapes are all solid, they also provide primitive collision detection via the contains method. This method takes a Point2 object from the cornell module.

Return to top level