/ Compoly is a program for constructing and composing truncated pyramids included prisma and planar polygons. Two data structures are generated in the program, one for the actual model, and the other for the composition (a collection of the actual models made by "merge").

At starting Compoly, you have a cube on the sreen shown in front (above) and top (below) view. This is the actual model. The composition is empty at the beginning.

In the following construction we'll construct the composition of a truncated pyramid and a prism.

The actual model is always defined as a regular truncated pyramid standing on the xy plane.

Enter the numerical data you want to change (close each number with enter/return).

The number of sides can be 2,3,...,50. If 2, then a planar axial section is defined.

The radii ( > 0.2 ) around the two endfaces which are regular polygons.

The height of the solid >=0. If 0 then a regular polygon is defined with the bigger radius.

The color can be 1(yellow), 2(red) or 3(blue, transparent).

The pyramid has 4 sides, the radii are 3 and 7, the height is 10.

Press "def" when the data are correct. The definition of a new model will overwrite the actual model.

Do merge the pyramid to the composition!

The second solid is a prism. It has 4 sides, the radii are 4, the height is 25, the color is 1.

The prism has been transformed by the following commands.

All the transformations (rotations around the specified coordinate axis, translations and scaling along the specified axis), merge and clear have an effect only on the actual model, not on the composition.

Rotate the prism around the transformation axis y by pressing r-, then rotate it around z by pressing r+, than move it along z by pressing m+, move it along y by pressing m-, finally along x by pressing m+.

The lines of the intersection of the actual model and the composition are shown on the surface of the actual model.

If the actual model is properly situated, merge it to the composition. The composition may have at most 600 vertices.

You may cancel the actual model by "clear", otherwise it does not disappear.

The picture above shows the composition not in the default top/front views.

You may change the direction of projection by rotating it to the left or to the right and up or down, meanwhile the position of the models in the coordinate system does not change.

You may move the projections on the screen by pressing ^ and v or < and >. You may enlarge or shrink the projections by pressing + and -, respectively.

All these screen transformation have an effect on the projections of both, the actual model and the composition.

Changing the mode into "paint", the front view of the composition will be shown with colord faces. The actual model is not shown, even it is still existing.

You may switch into central projection, if you have red-green glasses.

The "write" mode doesn't work in an applet. The stand alone program generates an .obj file and also a .wrl file. You can load these files by the program system javaview (download from the website www.javaview.de) and by euler3d (download from the website www.euler3d.hu).

With "new comp" the composition is deleted.

For further constructions change into "draw" mode!

Have a lot of fun!

5.02.2008. M. Szilvasi-Nagy