Jeff Skrysak

Geometric Shape Recognition

The geometric shape recognition software has one overall function of being able to detect and differentiate between different geometric shapes. These shapes are a square, a rectangle, a circle, a hexagon, and a triangle.

The software is written in Java 2, so it will run on any platform that has a java virtual machine. It will need a mouse and a keyboard for input. The shapes can be any size no smaller than 20 pixels in diameter. The maximum image size will be 640 x 480 pixels, and will have a color depth up to 16 colors.

The software program is GUI driven, and utilizes the mouse and keyboard. An event handler accepts the user’s commands and runs the function that corresponds to the input. These functions include loading an image, and searching for geometric shapes. The load image functionality uses the image libraries that accompany the Java language. There are three main objects, the scanner object, the image object, and the analyze object. When a user requests to load an image, the scanner object method Load_Image() is called, which puts the image data within the image object. Once that is complete, the user may then analyze the image by using methods within the analyze object. These methods use the image object as input and internally store the locations of the patterns found. A fourth object, called draw, uses the location data from the analyze object to draw outlines of the shapes. These outlines overlap the locations where the patterns are presumed to be.

The purpose of this software is to explore the genre of pattern recognition in a graphical context. Algorithms developed for the detection of basic geometric shapes may be used to detect more complex shapes within an image. These complex shapes can often be dissected into segments that resemble more basic shapes. A tank turret may be regarded as a semi-circle with a rectangular cannon at the end of which is a circular projectile exit point.