[0m


ICO(1)		    UNIX Programmer's Manual		   ICO(1)



[1mNAME
     [0mico - animate an icosahedron or other polyhedron

[1mSYNOPSIS
     ico [0m[-display display] [-geometry geometry] [-r] [-d pat-
     tern] [-i] [-dbl | -softdbl] [-faces] [-noedges] [-size WxH]
     [-delta +X+Y] [-copy] [-lw n] [-sleep n] [-obj object] [-
     stellate number] [-dual] [-objhelp] [[-colors color-list] |
     [-p#]]

[1mDESCRIPTION
     [0m_I_c_o displays a wire-frame rotating polyhedron, with hidden
     lines removed, or a solid-fill polyhedron with hidden faces
     removed.  There are a number of different polyhedra avail-
     able.

[1mOPTIONS
     -r   [0mDisplay on the root window instead of creating a new
	  window.

     [1m-d pattern
	  [0mSpecify a bit pattern for drawing dashed lines for wire
	  frames.

     [1m-i   [0mUse inverted colors for wire frames.

     [1m-dbl [0mUse the double buffering extension if it exists.  If it
	  does not then double buffering will be emulated as with
	  -softdbl.  This works for either wire frame or solid
	  fill drawings.  For solid fill drawings, using this
	  switch results in substantially smoother movement.

     [1m-softdbl
	  [0mUse software double buffering on the display.  This
	  works for either wire frame or solid fill drawings.
	  For solid fill drawings, using this switch results in
	  substantially smoother movement.  For this to work a
	  display with a modifiable color map is required.  The
	  number of colors which may be used is restricted by the
	  size of the color map (the square root of the number of
	  entries minus one - only three colors on a display with
	  16 color map entries).  A new color map will be allo-
	  cated if required.  _I_c_o expects the window manager to
	  manage the color maps; normally when the _i_c_o -_s_o_f_t_d_b_l
	  window is displayed correctly other windows on the
	  display will be displayed in incorrect colors (and will
	  flicker horribly).

     [1m-faces
	  [0mDraw filled faces instead of wire frames.

     [1m-noedges



[0mPrinted 29/3/95             Release 4				1






ICO(1)		    UNIX Programmer's Manual		   ICO(1)



	  Don't draw the wire frames.  Typically used only when
	  -faces is used.

     [1m-size [0m_W_x_H
	  Specifies the size of the object to be drawn in pixels.

     [1m-delta [0m+_X+_Y
	  Specifies the distance in X and Y (in pixels) which the
	  object is to move for each step.

     [1m-copy
	  [0mWhen using the double buffering extension the object is
	  not erased before it is drawn in its next position.

     [1m-lw number
	  [0mSpecifies the line width to be used for drawing edges.

     [1m-sleep [0m_n
	  Sleep n seconds between each move of the object (n may
	  be a real number, not just an integral value).

     [1m-obj [0m_o_b_j_e_c_t
	  Specify what object to draw.	If no object is speci-
	  fied, an icosahedron is drawn.

     [1m-objhelp
	  [0mPrint out a list of the available objects, along with
	  information about each object.

     [1m-stellate [0m_n_u_m_b_e_r
	  Stellate the given object by putting a point on each
	  face.  The number is the amount by which the centre of
	  each face is stretched towards the bounding sphere of
	  the object - if the number is 0 the centre is not
	  stretched out at all.  Try numbers in the range 1.0 to
	  2.0.	The resultant object has triangular faces each
	  with one vertex at the (new, stretched) face centre and
	  the other two at the ends of one of the old edges.  The
	  option can be applied more than once, however the
	  resulting objects rapidly become too complicated.  The
	  option should be used with [1m-faces[0m; if faces are not
	  drawn the hidden line removal of the edges will be
	  incomplete.  The algorithm used is to move the centre
	  of the face outwards by the area of the face scaled by
	  the given number.  Negative numbers will move the cen-
	  tre inwards; if the resultant object has self inter-
	  secting faces it will not be drawn correctly.

     [1m-dual
	  [0mProduce the dual of the object.  The [1m-objhelp [0moption
	  can be used to find out what the dual is.  The algo-
	  rithm used is to convert each vertex into a face whose



Printed 29/3/95             Release 4				2






ICO(1)		    UNIX Programmer's Manual		   ICO(1)



	  vertices are the centres of the faces which share that
	  vertex.  Because of the way the _p_l_a_n_e object is
	  represented (two planes back-to-back) the dual is a
	  degenerate object which cannot be handled.  If the
	  plane is stellated first with [1m-stellate 0.0 [0mit can be
	  handled (the stellated object is a degenerate
	  octahedron, the dual is a degenerate cube).  The
	  options [1m-obj[0m, [1m-stellate[0m, and [1m-dual [0mare applied in the
	  order specified on the command line - thus the latter
	  two options must appear after the object to which they
	  are being applied.  Options can be combined in any way
	  up to the (relatively restricted) limits of the pro-
	  gram, however the resulting objects are not always well
	  behaved.  In particular the dualling algorithm can pro-
	  duce objects with non-planar faces, which will then be
	  impossible to display correctly - the dual of a stel-
	  lated non-regualar polyhedron will typically have non-
	  planar faces.

     [1m-colors [0m_c_o_l_o_r _c_o_l_o_r ...
	  Specify what colors should be used to draw the filled
	  faces of the object.	If less colors than faces are
	  given, the colors are reused.  The number of colors
	  that are possible depends on the number of planes which
	  the display supports.

     [1m-p#  [0mSpecifies that a number of primary colors should be
	  used to draw the faces of the object.  The first three
	  colors used are red, green and blue, then the secondary
	  colors are used (yellow, cyan, magenta), then white,
	  then various other colors.  The actual number of dis-
	  tinct colors that are possible depends on the color map
	  type which the display supports.

[1mSEE ALSO
     [0mX(1)

[1mCOPYRIGHT
     [0mCopyright 1988, Massachusetts Institute of Technology.
     See _X(_1) for a full statement of rights and permissions.















Printed 29/3/95             Release 4				3



[0m