Polygon clip Applet

Sorry, your browser can't display applets.

This applet demonstraes the Sutherland-Hodgeman polygon clipping algorithm. The clipping widow is shown in blue. Draw a polygon by clicking on each vertex. Click on the start vertex to complete the polygon. Then click on Start to start the algorithm. You can repeatedly click on Step or uncheck "Step Mode" to have it run automatically.

The Java source for the algorithm is in PolyClipCanvas. Look at the clipPolygon and clipSide methods.

Other classes:

COMP3421 Computer Graphics home