]> git.hungrycats.org Git - xscreensaver/commitdiff
http://se.aminet.net/pub/X11/ftp.x.org/contrib/applications/xlockmore-4.14.tar.gz xlockmore-4.14 github/xlockmore-4.14
authorZygo Blaxell <zblaxell@faye.furryterror.org>
Mon, 2 Mar 2009 00:25:39 +0000 (19:25 -0500)
committerZygo Blaxell <zblaxell@faye.furryterror.org>
Mon, 2 Mar 2009 00:25:39 +0000 (19:25 -0500)
-rw-r--r-- 1 zblaxell zblaxell 972496 Nov  3  1999 xlockmore-4.14.tar.gz
dbccab62784b62c4e3e5c1725d6894b4c5eda273  xlockmore-4.14.tar.gz

393 files changed:
xlockmore-4.14.tar.gz [new file with mode: 0644]
xlockmore-4.14/Imakefile [new file with mode: 0644]
xlockmore-4.14/Makefile.in [new file with mode: 0644]
xlockmore-4.14/README [new file with mode: 0644]
xlockmore-4.14/bitmaps/bad.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bat-0.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bat-1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bat-2.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bat-3.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bat-4.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bounce-0.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bounce-1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bounce-2.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bounce-3.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/bounce-mask.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/cooperat.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/cross_weave.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/defect.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/dimple1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/dimple3.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/donkey.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/elephant.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-0.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-2.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-3.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-4.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-5.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-6.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/fish-7.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/flipped_gray.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/good.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/gray1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/gray3.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/hlines2.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-bob.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-bsd.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-dec.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-hp.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-ibm.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-linux.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-linux1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-mot.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-sco.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-sgi.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-sun.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-x11.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/l-xlock.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/light_gray.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-bob.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-bsd.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-dec.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-ghost.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-grelb.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-hp.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-ibm.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-linux.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-linux1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-mot.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-sco.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-sgi.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-sun.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-x11.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/m-xlock.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/mailempty.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/mailfull.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-faced.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-facef.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-facel.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-facer.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-hat.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-hatd.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-shoef.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-shoel.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-shoer.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-stepl.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/nose-stepr.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/root_weave.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot00.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot01.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot02.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot03.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot04.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot05.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot06.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot07.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot08.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot09.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot10.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot11.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot12.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot13.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot14.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/rot15.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-bsd.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-dec.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-grelb.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-hp.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-ibm.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-linux.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-linux1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-mot.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-sco.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-sgi.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-sun.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/s-x11.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-0.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-2.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-3.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-4.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-5.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-6.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/shark-7.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/sickle.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/stipple.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/t-smilie.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/t-x11.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-00.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-01.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-02.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-03.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-04.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-05.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-06.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-07.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-08.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-09.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-10.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-11.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-12.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-13.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-14.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-15.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-16.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-17.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-18.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-19.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-20.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-21.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-22.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-23.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-24.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-25.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-26.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-27.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-28.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/terra-29.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/trek-0.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/trek-1.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/trek-2.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/vlines2.xbm [new file with mode: 0644]
xlockmore-4.14/bitmaps/vlines3.xbm [new file with mode: 0644]
xlockmore-4.14/confdefs.h [new file with mode: 0644]
xlockmore-4.14/config.guess [new file with mode: 0755]
xlockmore-4.14/config.h.in [new file with mode: 0644]
xlockmore-4.14/config.sub [new file with mode: 0755]
xlockmore-4.14/configure [new file with mode: 0755]
xlockmore-4.14/configure.in [new file with mode: 0644]
xlockmore-4.14/configure.tcl [new file with mode: 0755]
xlockmore-4.14/conftest.c [new file with mode: 0644]
xlockmore-4.14/docs/3d.howto [new file with mode: 0644]
xlockmore-4.14/docs/HACKERS.GUIDE [new file with mode: 0644]
xlockmore-4.14/docs/HACKERS.GUIDE.fr [new file with mode: 0644]
xlockmore-4.14/docs/Purify [new file with mode: 0644]
xlockmore-4.14/docs/Purify.solaris [new file with mode: 0644]
xlockmore-4.14/docs/Purify.sunos [new file with mode: 0644]
xlockmore-4.14/docs/Revisions [new file with mode: 0644]
xlockmore-4.14/docs/TODO [new file with mode: 0644]
xlockmore-4.14/docs/cell_automata [new file with mode: 0644]
xlockmore-4.14/docs/xlock.hlp [new file with mode: 0644]
xlockmore-4.14/docs/xlock.html [new file with mode: 0644]
xlockmore-4.14/etc/README.etc [new file with mode: 0644]
xlockmore-4.14/etc/chkmbox/Mail.xpm [new file with mode: 0644]
xlockmore-4.14/etc/chkmbox/Makefile [new file with mode: 0644]
xlockmore-4.14/etc/chkmbox/NoMail.xpm [new file with mode: 0644]
xlockmore-4.14/etc/chkmbox/chkmbox.c [new file with mode: 0644]
xlockmore-4.14/etc/chkmbox/chkmbox.cfg [new file with mode: 0644]
xlockmore-4.14/etc/chkmbox/imapsocket.c [new file with mode: 0644]
xlockmore-4.14/etc/chkmbox/imapsocket.h [new file with mode: 0644]
xlockmore-4.14/etc/descrip.mms [new file with mode: 0644]
xlockmore-4.14/etc/dtprofile [new file with mode: 0644]
xlockmore-4.14/etc/dtscreen.dt [new file with mode: 0644]
xlockmore-4.14/etc/ext.life [new file with mode: 0644]
xlockmore-4.14/etc/fortune.dat [new file with mode: 0644]
xlockmore-4.14/etc/genlauncher/README [new file with mode: 0644]
xlockmore-4.14/etc/genlauncher/etc.xlock.tcl [new file with mode: 0644]
xlockmore-4.14/etc/genlauncher/lex.yy.c [new file with mode: 0644]
xlockmore-4.14/etc/genlauncher/lmode.h [new file with mode: 0644]
xlockmore-4.14/etc/genlauncher/make.launcher [new file with mode: 0755]
xlockmore-4.14/etc/genlauncher/xalock.modes.tpl [new file with mode: 0644]
xlockmore-4.14/etc/genlauncher/xlockgen.lex [new file with mode: 0644]
xlockmore-4.14/etc/genlauncher/xmlock.modes.tpl [new file with mode: 0644]
xlockmore-4.14/etc/gif/README [new file with mode: 0644]
xlockmore-4.14/etc/gif/deflag.gif [new file with mode: 0644]
xlockmore-4.14/etc/gif/frflag.gif [new file with mode: 0644]
xlockmore-4.14/etc/gif/nlflag.gif [new file with mode: 0644]
xlockmore-4.14/etc/gif/ukflag.gif [new file with mode: 0644]
xlockmore-4.14/etc/glider.3dlife [new file with mode: 0644]
xlockmore-4.14/etc/glider.hlife [new file with mode: 0644]
xlockmore-4.14/etc/glider.life [new file with mode: 0644]
xlockmore-4.14/etc/play.sh [new file with mode: 0755]
xlockmore-4.14/etc/rplay.conf [new file with mode: 0644]
xlockmore-4.14/etc/rplay.hosts [new file with mode: 0644]
xlockmore-4.14/etc/rplay.servers [new file with mode: 0644]
xlockmore-4.14/etc/showmodes.sh [new file with mode: 0755]
xlockmore-4.14/etc/system.fvwm2rc.xlock [new file with mode: 0644]
xlockmore-4.14/etc/system.fvwmrc.xlock [new file with mode: 0644]
xlockmore-4.14/etc/system.mwmrc.xlock [new file with mode: 0644]
xlockmore-4.14/etc/system.olwmrc.xlock [new file with mode: 0644]
xlockmore-4.14/etc/system.wmrc.xlock [new file with mode: 0644]
xlockmore-4.14/etc/vtswitch.c [new file with mode: 0644]
xlockmore-4.14/etc/xlock.java [new file with mode: 0644]
xlockmore-4.14/etc/xlock.sh [new file with mode: 0755]
xlockmore-4.14/etc/xlock.staff [new file with mode: 0644]
xlockmore-4.14/etc/xlock.tcl [new file with mode: 0755]
xlockmore-4.14/etc/xlockFrame.java [new file with mode: 0644]
xlockmore-4.14/etc/xlockhexlife.pl [new file with mode: 0755]
xlockmore-4.14/etc/xlocklife.pl [new file with mode: 0755]
xlockmore-4.14/etc/xlockranddur.pl [new file with mode: 0755]
xlockmore-4.14/etc/xlockrandimage.pl [new file with mode: 0755]
xlockmore-4.14/etc/xlocksat.pl [new file with mode: 0755]
xlockmore-4.14/etc/xtermlock.sh [new file with mode: 0755]
xlockmore-4.14/etc/xwinlock.sh [new file with mode: 0755]
xlockmore-4.14/iconfig.h [new file with mode: 0644]
xlockmore-4.14/install-sh [new file with mode: 0755]
xlockmore-4.14/make.com [new file with mode: 0644]
xlockmore-4.14/mkinstalldirs [new file with mode: 0755]
xlockmore-4.14/modes/Imakefile [new file with mode: 0644]
xlockmore-4.14/modes/Makefile.in [new file with mode: 0644]
xlockmore-4.14/modes/Makefile.inxs [new file with mode: 0644]
xlockmore-4.14/modes/ant.c [new file with mode: 0644]
xlockmore-4.14/modes/ball.c [new file with mode: 0644]
xlockmore-4.14/modes/bat.c [new file with mode: 0644]
xlockmore-4.14/modes/blank.c [new file with mode: 0644]
xlockmore-4.14/modes/blot.c [new file with mode: 0644]
xlockmore-4.14/modes/bomb.c [new file with mode: 0644]
xlockmore-4.14/modes/bouboule.c [new file with mode: 0644]
xlockmore-4.14/modes/bounce.c [new file with mode: 0644]
xlockmore-4.14/modes/braid.c [new file with mode: 0644]
xlockmore-4.14/modes/bubble.c [new file with mode: 0644]
xlockmore-4.14/modes/bug.c [new file with mode: 0644]
xlockmore-4.14/modes/cartoon.c [new file with mode: 0644]
xlockmore-4.14/modes/clock.c [new file with mode: 0644]
xlockmore-4.14/modes/coral.c [new file with mode: 0644]
xlockmore-4.14/modes/crystal.c [new file with mode: 0644]
xlockmore-4.14/modes/daisy.c [new file with mode: 0644]
xlockmore-4.14/modes/dclock.c [new file with mode: 0644]
xlockmore-4.14/modes/decay.c [new file with mode: 0644]
xlockmore-4.14/modes/deco.c [new file with mode: 0644]
xlockmore-4.14/modes/demon.c [new file with mode: 0644]
xlockmore-4.14/modes/dilemma.c [new file with mode: 0644]
xlockmore-4.14/modes/discrete.c [new file with mode: 0644]
xlockmore-4.14/modes/drift.c [new file with mode: 0644]
xlockmore-4.14/modes/ext.life [new file with mode: 0644]
xlockmore-4.14/modes/eyes.c [new file with mode: 0644]
xlockmore-4.14/modes/fadeplot.c [new file with mode: 0644]
xlockmore-4.14/modes/flag.c [new file with mode: 0644]
xlockmore-4.14/modes/flame.c [new file with mode: 0644]
xlockmore-4.14/modes/flow.c [new file with mode: 0644]
xlockmore-4.14/modes/forest.c [new file with mode: 0644]
xlockmore-4.14/modes/galaxy.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/Imakefile [new file with mode: 0644]
xlockmore-4.14/modes/glx/Makefile.in [new file with mode: 0644]
xlockmore-4.14/modes/glx/atlantis.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/atlantis.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/b_draw.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/b_lockglue.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/b_sphere.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/bubble3d.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/bubble3d.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/buildlwo.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/buildlwo.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/cage.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/dolphin.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/e_textures.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/gears.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_evert.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_figureeight.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_figureeight.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_linkage.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_linkage.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_sphere.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_sphere.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_spline.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_spline.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_threejet.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_threejet.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_threejetvec.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_threejetvec.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_twojet.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_twojet.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_twojetvec.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/i_twojetvec.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/invert.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/lament.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/moebius.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/morph3d.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/pipeobjs.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/pipes.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/rubik.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/s1_1.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/s1_2.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/s1_3.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/s1_4.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/s1_5.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/s1_6.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/s1_b.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/shark.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/sproingies.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/sproingiewrap.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/stairs.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/superquadrics.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/swim.c [new file with mode: 0644]
xlockmore-4.14/modes/glx/text3d.cc [new file with mode: 0644]
xlockmore-4.14/modes/glx/text3d.h [new file with mode: 0644]
xlockmore-4.14/modes/glx/whale.c [new file with mode: 0644]
xlockmore-4.14/modes/goop.c [new file with mode: 0644]
xlockmore-4.14/modes/grav.c [new file with mode: 0644]
xlockmore-4.14/modes/helix.c [new file with mode: 0644]
xlockmore-4.14/modes/hop.c [new file with mode: 0644]
xlockmore-4.14/modes/hyper.c [new file with mode: 0644]
xlockmore-4.14/modes/ico.c [new file with mode: 0644]
xlockmore-4.14/modes/ifs.c [new file with mode: 0644]
xlockmore-4.14/modes/image.c [new file with mode: 0644]
xlockmore-4.14/modes/julia.c [new file with mode: 0644]
xlockmore-4.14/modes/kaleid.c [new file with mode: 0644]
xlockmore-4.14/modes/kumppa.c [new file with mode: 0644]
xlockmore-4.14/modes/laser.c [new file with mode: 0644]
xlockmore-4.14/modes/life.c [new file with mode: 0644]
xlockmore-4.14/modes/life1d.c [new file with mode: 0644]
xlockmore-4.14/modes/life3d.c [new file with mode: 0644]
xlockmore-4.14/modes/lightning.c [new file with mode: 0644]
xlockmore-4.14/modes/lisa.c [new file with mode: 0644]
xlockmore-4.14/modes/lissie.c [new file with mode: 0644]
xlockmore-4.14/modes/loop.c [new file with mode: 0644]
xlockmore-4.14/modes/lyapunov.c [new file with mode: 0644]
xlockmore-4.14/modes/mandelbrot.c [new file with mode: 0644]
xlockmore-4.14/modes/marquee.c [new file with mode: 0644]
xlockmore-4.14/modes/matrix.c [new file with mode: 0644]
xlockmore-4.14/modes/maze.c [new file with mode: 0644]
xlockmore-4.14/modes/mountain.c [new file with mode: 0644]
xlockmore-4.14/modes/munch.c [new file with mode: 0644]
xlockmore-4.14/modes/nose.c [new file with mode: 0644]
xlockmore-4.14/modes/pacman.c [new file with mode: 0644]
xlockmore-4.14/modes/penrose.c [new file with mode: 0644]
xlockmore-4.14/modes/petal.c [new file with mode: 0644]
xlockmore-4.14/modes/puzzle.c [new file with mode: 0644]
xlockmore-4.14/modes/pyro.c [new file with mode: 0644]
xlockmore-4.14/modes/qix.c [new file with mode: 0644]
xlockmore-4.14/modes/random.c [new file with mode: 0644]
xlockmore-4.14/modes/roll.c [new file with mode: 0644]
xlockmore-4.14/modes/rotor.c [new file with mode: 0644]
xlockmore-4.14/modes/shape.c [new file with mode: 0644]
xlockmore-4.14/modes/sierpinski.c [new file with mode: 0644]
xlockmore-4.14/modes/slip.c [new file with mode: 0644]
xlockmore-4.14/modes/space.c [new file with mode: 0644]
xlockmore-4.14/modes/sphere.c [new file with mode: 0644]
xlockmore-4.14/modes/spiral.c [new file with mode: 0644]
xlockmore-4.14/modes/spline.c [new file with mode: 0644]
xlockmore-4.14/modes/star.c [new file with mode: 0644]
xlockmore-4.14/modes/starfish.c [new file with mode: 0644]
xlockmore-4.14/modes/strange.c [new file with mode: 0644]
xlockmore-4.14/modes/swarm.c [new file with mode: 0644]
xlockmore-4.14/modes/swirl.c [new file with mode: 0644]
xlockmore-4.14/modes/tetris.c [new file with mode: 0644]
xlockmore-4.14/modes/thornbird.c [new file with mode: 0644]
xlockmore-4.14/modes/triangle.c [new file with mode: 0644]
xlockmore-4.14/modes/tube.c [new file with mode: 0644]
xlockmore-4.14/modes/turtle.c [new file with mode: 0644]
xlockmore-4.14/modes/vines.c [new file with mode: 0644]
xlockmore-4.14/modes/voters.c [new file with mode: 0644]
xlockmore-4.14/modes/wator.c [new file with mode: 0644]
xlockmore-4.14/modes/wire.c [new file with mode: 0644]
xlockmore-4.14/modes/world.c [new file with mode: 0644]
xlockmore-4.14/modes/worm.c [new file with mode: 0644]
xlockmore-4.14/modes/xjack.c [new file with mode: 0644]
xlockmore-4.14/pixmaps/bat-0.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/bat-1.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/bat-2.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/bat-3.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/bat-4.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-axp.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-blank.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-bsd.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-dec.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-hp.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-linux.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-sgi.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-sol.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-sun.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-x11.xpm [new file with mode: 0644]
xlockmore-4.14/pixmaps/m-xlock.xpm [new file with mode: 0644]

diff --git a/xlockmore-4.14.tar.gz b/xlockmore-4.14.tar.gz
new file mode 100644 (file)
index 0000000..45bc4bf
Binary files /dev/null and b/xlockmore-4.14.tar.gz differ
diff --git a/xlockmore-4.14/Imakefile b/xlockmore-4.14/Imakefile
new file mode 100644 (file)
index 0000000..60885ab
--- /dev/null
@@ -0,0 +1,64 @@
+#ifndef XCOMM
+#define XCOMM /**/#
+#endif
+XCOMM @(#)Imakefile    4.13 99/03/08 xlockmore
+XCOMM Many "ideas" taken from xscreensaver-1.34 by Jamie Zawinski.
+XCOMM
+
+VER = xlockmore
+DISTVER = xlockmore-4.13
+
+SUBDIRS = xlock modes/glx modes xmlock
+XCOMM Do not build by default, since it usually does not work
+XCOMM xalock
+
+MAKE_SUBDIR = for dir in $(SUBDIRS) ; do ( cd $$dir ; $(MAKE) $@ \
+CC="$(CC)" CCOPTIONS="$(CCOPTIONS)" CDEBUGFLAGS="$(CDEBUGFLAGS)" \
+BINDIR="$(BINDIR)" XAPPLOADDIR="$(XAPPLOADDIR)") ; done
+
+SUB_MAKEFILES = xlock/Makefile modes/glx/Makefile modes/Makefile xmlock/Makefile xalock/Makefile
+
+all::
+       @echo ""                  ; \
+       echo "        ==========================================================" ; \
+       echo ""                   ; \
+       echo "        Did you read and edit iconfig.h? " ; \
+       echo "           Otherwise it will assume a minimum configuration." ; \
+       echo "        Run \"make depend\" if you can not find \"decay.xbm\"." ; \
+       echo ""                   ; \
+       echo "        ==========================================================" ; \
+       echo ""
+
+
+all:: $(SUB_MAKEFILES)
+       @$(MAKE_SUBDIR)
+
+install:: all
+       @$(MAKE_SUBDIR)
+
+clean::
+       @$(MAKE_SUBDIR)
+
+depend::
+       @$(MAKE_SUBDIR)
+
+distclean : clean
+       @$(MAKE_SUBDIR)
+       -rm -f Makefile config.status config.cache config.log config.h
+Makefiles:: $(SUB_MAKEFILES)
+xlock/Makefile : Imakefile iconfig.h
+       cd xlock  ; $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)/xlock
+
+modes/glx/Makefile : modes/glx/Imakefile iconfig.h
+       cd modes/glx ; $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)/modes/glx
+
+modes/Makefile : modes/Imakefile iconfig.h
+       cd modes  ; $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)/modes
+
+xmlock/Makefile : xmlock/Imakefile iconfig.h
+       cd xmlock  ; $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)/xmlock
+
+xalock/Makefile : xalock/Imakefile iconfig.h
+       cd xalock  ; $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)/xalock
diff --git a/xlockmore-4.14/Makefile.in b/xlockmore-4.14/Makefile.in
new file mode 100644 (file)
index 0000000..09ea349
--- /dev/null
@@ -0,0 +1,116 @@
+############################################################
+#
+# $Id : Makefile.in 4.13 1999/03/08 $
+#
+# xlockmore Makefile.in for autoconf (UNIX/VMS X11 support)
+############################################################
+
+SUBDIRS = xlock modes/glx modes xmlock xglock
+# Do not build by default, since it usually does not work
+# xalock
+
+MAKE_SUBDIR = for dir in $(SUBDIRS) ; do ( cd $$dir ; $(MAKE) $@ ) ; done
+# convenient not to use configure just to clean
+MAKEIN_SUBDIR = for dir in $(SUBDIRS) ; do ( cd $$dir ; $(MAKE) -f Makefile.in $@ ) ; done
+
+all :
+       @$(MAKE_SUBDIR)
+
+# this tells GNU make not to export variables into the environment
+# But other makes do not understand its significance, so it must
+# not be the first target in the file. So it is here, before
+# any variables are created, but after the default target
+.NOEXPORT :
+
+SHELL = /bin/sh
+
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@/
+
+TAR = tar
+RM = rm -f
+
+VER = xlockmore
+DISTVER = xlockmore-4.13
+
+install :
+       @$(MAKE_SUBDIR)
+
+install-program :
+       @$(MAKE_SUBDIR)
+
+install-man :
+       @$(MAKE_SUBDIR)
+
+install-ad :
+       @$(MAKE_SUBDIR)
+
+uninstall :
+       @$(MAKE_SUBDIR)
+
+uninstall-program :
+       @$(MAKE_SUBDIR)
+
+uninstall-man :
+       @$(MAKE_SUBDIR)
+
+depend :
+       @$(MAKE_SUBDIR)
+
+distdepend :
+       @$(MAKE_SUBDIR)
+
+lint :
+       @$(MAKE_SUBDIR)
+
+xrdb :
+       @$(MAKE_SUBDIR)
+
+man :
+       @$(MAKE_SUBDIR)
+
+html :
+       @$(MAKE_SUBDIR)
+
+hlp :
+       @$(MAKE_SUBDIR)
+
+clean :
+       $(RM) core *~ *% *.bak *.orig *.rej make.log MakeOut *.patch
+       @$(MAKE_SUBDIR)
+
+distclean :
+       $(RM) core *~ *% *.bak *.orig *.rej make.log MakeOut
+       $(RM) Makefile config.status config.cache config.log config.h
+       @$(MAKEIN_SUBDIR)
+
+Makefile : Makefile.in config.status
+       $(SHELL) config.status
+config.status : configure
+       $(SHELL) config.status --recheck
+#configure : configure.in
+# enable this rule if you want autoconf to be executed automatically when
+# configure.in is changed. This is commented out, since patching might give
+# configure.in a newer timestamp than configure and not everybody has autoconf
+#      cd $(srcdir); autoconf
+
+clean.all : distclean
+
+tar : distclean
+       cd .. ; $(TAR) cvf $(VER).tar $(VER)/*
+
+compress : tar
+       cd .. ; compress -f $(VER).tar
+
+gzip : tar
+       cd .. ; gzip -best -f $(VER).tar
+
+dist : gzip
+
+tgz : tar
+       cd .. ; gzip -best -c $(VER).tar > `echo $(VER) | cut -c1-8`.tgz ; \
+$(RM) $(VER).tar
+
+read :
+       more README
diff --git a/xlockmore-4.14/README b/xlockmore-4.14/README
new file mode 100644 (file)
index 0000000..ff52327
--- /dev/null
@@ -0,0 +1,789 @@
+xlockmore-4.14: the maintained version of xlock
+see docs/Revisions for more version stuff
+see docs/TODO for stuff to do :)
+
+I have significantly less time to maintain this but I try.
+If someone has some free time and wants to take over... let me know.
+(Help is always appreciated too ;) ).
+
+Primary site: ftp://ftp.tux.org/pub/people/david-bagley/xlockmore
+Secondary site: ftp://ftp.x.org/contrib/applications
+Web page: http://www.tux.org/~bagleyd/xlockmore.html
+Maintainer: David A. Bagley <bagleyd@tux.org>
+
+Majordomos: Mail to majordomo@tux.org with just
+subscribe [choice] [your-email-address]
+  in the body.
+    choice                  brief description
+    ------                  -----------------
+    xlock-beta              Xlock beta and production announcements
+    xlock-alpha             Xlock alpha ("daily") release announcements
+    xlock                   Xlock/Xlockmore development discussion
+  If there is trailing signature junk, just put "end" as the last line to
+  be read.  If you need help just put "help" in the body.
+
+SECURITY WARNING:
+-----------------
+xlock using the MesaGL Libraries (<= 2.6) setuid root has a known method for
+users to obtain root privledges!
+
+Please send all bug reports to bagleyd@tux.org .
+Alpha versions may be available through web page or primary ftp site.
+Adapted from Patrick J. Naughton's original xlock, with lots of help
+ from others.
+
+
+How to build?
+-------------
+  An ANSI C compiler is required for build.
+  motif (and editres) are used to build xmlock and are not used in xlock.
+  athena and sxlib are used to build xalock and are not used in xlock.
+
+  Check below to see if your machine is one mentioned that causes
+  problems, otherwise it should be easy.  Just to be safe after installing 
+  test it with something like: `/usr/local/bin/xlock -debug -verbose`
+
+  If you installed this before you may want to back up your XLock.ad file
+  if you made changes, since `make install` will overwrite this.
+
+  There are 3 ways to build:
+
+  configure:
+    `configure --help` to see options.
+
+               configure ; make ; make install
+
+               For Linux and others you may want something like:
+    configure --prefix=/usr/X11R6 ; make ; make install
+    that way it will install it in /usr/X11R6 not /usr/local
+               For Suns you may want:
+    configure --prefix=/usr/openwin ; make ; make install
+
+  imake:
+    Sometimes this is not setup correctly by the distributer ... i.e. not
+    my fault.  You may want to do these quick edits to the iconfig.h so you
+    have more capabilities:
+
+    Do you have XPM?              If so, uncomment "#define XpmLibrary".
+    Do you have OpenGL or MesaGL? If so, uncomment "#define GLLibrary".
+    Do you have CDE?              If so, uncomment "#define DtSaverLibrary".
+    Do you have RPLAY?            If so, uncomment "#define RplayLibrary".
+    Do you have NAS?              If so, uncomment "#define NasLibrary".
+    Do you have Motif?            If so, uncomment "#define XmLibrary".
+
+    Examine iconfig.h for other optional capabilities.
+
+    xmkmf ; make Makefiles ; make depend ; make ; make install
+    or
+    xmkmf -a ; make ; make install
+
+  make.com:
+    See VMS below.
+
+
+Note to binary redistributers:
+-----------------------------
+  Probably should not distribute with any library requirements
+  (except possibly XPM, unless you statically link them in
+  and with USE_BOMB since it might not run right if you do not know
+  if your users will use xdm or not.  For example:
+    configure --without-xpm --without-opengl --without-mesagl
+      --without-dtsaver --without-rplay --without-nas --disable-bomb; make
+  You may want to distribute it with the xlock/XLock.ad file with "XLock."
+  instances replaced with "*".  On Sun's, I need it to override the system
+  XLock.ad  file.
+  Please let me know if there are other concerns.
+
+
+Likely Problems
+---------------
+  Make sure you use the new XLock.ad resource file (or at least remove the
+    old one) otherwise several modes will not be set up nicely.  This is
+    usually put as a file in $HOME/XLock and/or
+    $WHEREVER_X11_IS_LOADED/lib/X11/app-defaults/XLock .
+
+  "Key: " this usually means you should get your administrator to setuid
+    xlock to root or at least setgid xlock to shadow.  If you do not have
+    a friendly administrator it is asking for a key (password) that it will
+    save encrypted your $HOME/.xlockrc file.
+
+  AIX (IBM RS6000)
+    AIX's "make":
+      AIX's "make" can not handle "+=" so if you use the iconfig.h, you
+      have to group all your DEFINES into one long line and use "="
+      instead.  GNU's "make" solves this problem.
+    AIX 3.1 and less:
+      it SHOULD compile automatically with -DLESS_THAN_AIX3_2 using the
+      iconfig.h, since the passwd struct is not available.
+    AIX 3.2 and greater:
+      one must have setuid xlock to root if you want to use it
+      without being root.
+       su - root
+       chown root xlock
+       chmod u+s xlock
+       chmod og+rx xlock
+    AFS users:
+      See iconfig.h, grep on "AFS". 
+    Some machines have an alternate password shadowing method, if someone  
+      figures it out mail me the patch.
+    AIX with DCE you will need "-ls" among the XLOCKLIBS.
+
+  Alpha-OSF/1 (Digital Equipment Corp)
+
+    Enhanced security:
+      Compile with -DOSF1_ENH_SEC see iconfig.h
+        chown auth.auth xlock
+        chmod 2755 xlock
+      Unfortunately the following is reportedly broken since xlockmore-2.10
+      and needs a patch, I heard it produces the following at runtime.
+Unaligned access pid=1767 <xlock> va=140489e24 pc=3ff807d9978 ra=3ff807d9880
+type=ldq
+Segmentation fault (core dumped)
+
+  Apollo (HP)
+    Shift-Control-Break is caught.  See HP.
+
+  CDE (DT) Common Desktop Environment.
+    Go to the CDE DT CONFIG SECTION of the
+     iconfig.h and uncomment (should be autodetected if you use configure)
+XCOMM #define DtSaverLibrary
+    Here's what it does:
+      The DT screensaver is part of the dtwm window manager and what it does
+      is create a full-screen-sized window for each screen of your display.
+      This is different from other screen savers which use virtual roots.
+
+      What the DTSAVER option does is basically call a DT routine that
+      returns the id's of the windows it creates for the screensaver.  Then
+      xlockmore will use these windows to display its stuff.
+
+      DT has a program where you can select your screensaver modes (or
+      screen saver programs), ala xmlock, and set your screensaver settings.
+      It also creates a small window where if you select a particular mode
+      it will run the screen saver and display it on that small window.
+
+    Here's how to set it up on your home directory.
+      cp etc/dtprofile $HOME/.dtprofile
+        This uses a ksh syntax.  If your shell is csh or other change it
+        accordingly.
+      cp etc/dtscreen.dt $HOME/.dt/types
+        The actions points to /usr/remote so you may want to change this.
+      After this you need to completely logout from your CDE session and log 
+      back in so it will read the .dtprofile.  (If you just modify the actions
+      in dtscreen.dt you don't need to log out; you can simply restart your
+      dtwm.)
+    Here's how to set it up on your system.
+      edit /usr/dt/bin/Xsession DTSCREENSAVERLIST to contain the
+        DTSCREENSAVERLIST stuff in etc/dtprofile
+      cp etc/dtscreen.dt /usr/dt/appconfig/types/C/dtscreen.dt
+
+    The disadvantage to the above is some features of xlock are abscent,
+      in particular, the logout lab feature.  This version of xlock does not
+      hava a drop in replacement for the Screen Style Manager.  Here is a
+      work around on Solaris in 3 patches:
+      1. Take out Screen option.
+      2. Put in /usr/local/bin/xlock as the default locker.
+      3. Turn off the default DT locking mechanism.
+*** /usr/dt/app-defaults/C/Dtstyle.orig        Fri Apr 12 11:53:00 1996
+--- /usr/dt/app-defaults/C/Dtstyle     Thu Jul 24 09:47:34 1997
+***************
+*** 24,30 ****
+  !#   Do not translate the following
+  !###
+  !# componentList specifies the buttons that appear in the Style Manager.
+! Dtstyle*componentList:  Color Font Backdrop Keyboard Mouse Beep Screen Dtwm Startup
+  
+  !# The Style Manager may be oriented vertically by commenting out this line
+  Dtstyle*mainRC.orientation:         HORIZONTAL
+--- 24,31 ----
+  !#   Do not translate the following
+  !###
+  !# componentList specifies the buttons that appear in the Style Manager.
+! !#Dtstyle*componentList:  Color Font Backdrop Keyboard Mouse Beep Screen Dtwm Startup
+! Dtstyle*componentList:  Color Font Backdrop Keyboard Mouse Beep Dtwm Startup
+  
+  !# The Style Manager may be oriented vertically by commenting out this line
+  Dtstyle*mainRC.orientation:         HORIZONTAL
+*** /usr/dt/appconfig/types/C/dt.dt.orig       Fri Apr 12 11:53:28 1996
+--- /usr/dt/appconfig/types/C/dt.dt    Thu Jul 24 11:32:21 1997
+***************
+*** 226,235 ****
+  ACTION LockDisplay
+  {
+       LABEL           LockDisplay
+!         TYPE            TT_MSG
+!         TT_CLASS     TT_REQUEST
+!         TT_SCOPE     TT_SESSION
+!         TT_OPERATION Display_Lock
+          DESCRIPTION     The LockDisplay action locks the workstation. \
+                          You must know the user's or root password to \
+                          unlock the workstation.
+--- 226,239 ----
+  ACTION LockDisplay
+  {
+       LABEL           LockDisplay
+! #        TYPE            TT_MSG
+! #        TT_CLASS    TT_REQUEST
+! #        TT_SCOPE    TT_SESSION
+! #        TT_OPERATION        Display_Lock
+!         TYPE            COMMAND
+!         ARG_COUNT    0
+!         WINDOW_TYPE  NO_STDIO
+!         EXEC_STRING  /usr/local/bin/xlock
+          DESCRIPTION     The LockDisplay action locks the workstation. \
+                          You must know the user's or root password to \
+                          unlock the workstation.
+*** /usr/dt/config/C/sys.resources.orig        Fri Apr 12 11:53:15 1996
+--- /usr/dt/config/C/sys.resources     Thu Jul 24 11:33:57 1997
+***************
+*** 82,88 ****
+  
+  
+  dtsession*saverTimeout:  10 
+! dtsession*lockTimeout:   30
+  dtsession*cycleTimeout:  3 
+  dtsession*saverList: StartDtscreenBlank
+  
+--- 82,89 ----
+  
+  
+  dtsession*saverTimeout:  10 
+! !#dtsession*lockTimeout:   30
+! dtsession*lockTimeout:   0
+  dtsession*cycleTimeout:  3 
+  dtsession*saverList: StartDtscreenBlank
+  
+
+  DCE authentication (tested only on HP's)
+    See iconfig.h (xmkmf) or modes/Makefile.in (configure).
+
+  Digital Unix
+    Reported that 3.2D (8bpp) password screen color map gets messed up
+    sometimes when in random mode as it switches from one mode to another.
+    
+  ESIX
+    Similar to Solaris2.x.  You will need a -DSVR4 to compile.
+    chmod 440 /etc/shadow
+    if you get libX11.so.xxx not found
+      link with the static versions of the X libraries 
+    chmod 2755 xlock
+
+  FreeBSD
+    One may have to setuid xlock to root (are there any objections?).
+    Also see "XFree86" if applicable.
+
+  HP
+    Shift-Control-Break is caught.  This uses a library Xhp11 that may
+      not exist on some systems.  Comment out
+        XHPDisableReset(dsp);
+      and
+        XHPEnableReset(dsp);
+      in "xlock.c" if you do not have this library.
+      May have to setuid xlock to root.
+    The optimizer may break in xlock/ .
+    HP's "make":
+      HP's "make" can not handle "+=" so if you use the iconfig.h, you
+      have to group all your DEFINES into one long line and use "="
+      instead.  GNU's "make" solves this problem.
+    HP-UX with Secured Passwords:
+      Compile with -DHPUX_SECURE_PASSWD and setuid xlock to root.
+    HP-UX with Passwd Etc:
+      Compile with -DHP_PASSWDETC .
+      Link with -lrgy -lnck -lndbm .
+    Calls to XSetScreenSaver when using CDE (i.e. not called with -dtsaver)
+      is not supported.  This can cause a disruption in the rpc ttdbserver
+      system resulting in the CDE lock and exit buttons to fail, 5 to 50%
+      of the time.  I am told this will not be fixed by HP, only documented.
+      The only supported method of doing this stuff is via dtstyle.
+
+  IRIX (SGI)
+    OpenGL works but may be a little flaky.
+
+  KERBEROS
+    See iconfig.h (xmkmf) or modes/Makefile.in (configure).
+    
+  Linux (Intel 80386, 80486, & Pentium)
+    If you are using elf _or_ shadow passwords:
+      xlock should compile with -DHAVE_SHADOW
+      this is already forced if you have elf so do not worry, it should
+      work even if you do not have shadow passwording.
+    If you are _not_ using elf and are using shadow passwords:
+      (this old version of shadowing has a _MAJOR_ known security flaw)
+      link with -lshadow -lgdbm
+    Next if using shadow passwords:
+      chown root.root xlock  (or root.shadow if it exists)
+      chmod 4755 xlock
+      (chmod 2755 xlock may be better if shadow has group read for root group)
+      Also check that the following was done:
+        Your /usr/X11R6/lib/X11/config/linux.cf should have
+#define HasShadowPasswd         YES
+          This would let the iconfig.h work automatically for compile/link.
+        chown root.root /etc/shadow   (or root.shadow if it exists)
+        chmod 400 /etc/shadow
+        (chmod 440 /etc/shadow may be better).
+    So far, Slackware (a major Linux distribution) does NOT come with shadow
+      passwords standard.  If you want to install shadow passwords (be
+      careful, it can be tricky) it's on sunsite.unc.edu in
+      /pub/Linux/system/Admin .
+    Also see "XFree86" if applicable.
+
+  Linux (Alpha)
+    Change the order of XLIB and XPMLIB in the iconfig.h so the XPMLIB
+     comes first.  Intel stuff above probably applies as well.
+
+  MesaGL and OpenGL
+    I assume the Mesa 3-D Graphics Library for the Imakefile.  See below
+      on availability.  Follow its instructions and then go to MesaGL
+      section of the iconfig.h and uncomment
+XCOMM #define GLLibrary
+      MesaGL and sometimes OpenGL are autodetected if you use configure.
+
+  Rplay
+    Audio package.  See below on availability.  Follow its instructions and
+      then go to iconfig.h and uncomment (should be autodetected if you use
+      configure)
+XCOMM #define RplayLibrary
+      See config directory for example.  (Note: The example files are
+      concerned with getting it working ... not security).
+
+  Solaris2.x (Sun SPARC)
+    You could use MesaGL or OpenGL.  I found a developers version of OpenGL at
+      http://www.sun.com/solaris/opengl/
+    Solaris2.6 may not work with rplay.  configure --without-rplay
+    If you get something like:
+xlock.c:1584: `sigset_t' undeclared (first use this function)
+      try removing -I/usr/include from the Makefiles or get rid of -Xc
+      in the xlock/Makefile.  If someone figures out a way around this
+      in the code let me know.
+    To get xlock working with Sun's GL libraries and includes
+      If you get "macro `glNormal3f' used with just one arg" ... you need
+         -DSUN_OGL_NO_VERTEX_MACROS
+      If using Imakefile, see iconfig.h .
+      After a make, use on a display that supports GLX  `xdpyinfo | grep GLX`
+    Imake will compile with the -DHAVE_SHADOW switch.
+    With GNU's gcc, get rid of the "-ansi" during compilation, also
+      one may want to get rid of the -xF references in
+      /usr/openwin/lib/config/sun.cf and Imake.tmpl if you get a
+      cc: language F not recognized
+    Solaris2.x NIS+ or not using NIS (/etc/passwd):
+      If you use netgroup make sure there is a return at the end of file.
+
+  SunOS4.1.x (Sun Sparc & 680x0)
+    bubble may crash the xnews server if patch 100444-76 OpenWindows V3.0
+      Server patch is installed.  To test this
+      `strings /usr/openwin/bin/xnews | grep Patch`
+      It would then show Patch #3000-124 if 10044-76 is installed.
+    Put in a link from /usr/include/X11 to your ${OPENWINHOME}/include/X11
+      to use the xmkmf or use the configure file provided.
+    gcc -Wall gives a lot of silly warnings, its safe to disregard them.
+  Ultrix (DEC)
+    I heard that the logout button just kills xlock.
+    USE_XLOCKRC feature unimplemented, but may not be hard to do.
+    xlock must be either setuid root or setgid authread to validate the
+      password on an Ultrix system.
+
+  VMS (DEC)
+    You may want to set a few things like vroot, bomb, and sound (see audio
+      below) at the top of the file.
+    All you should need to do to build the executable is:
+        $ @make
+    To run xlock a symbol needs to be defined, for example:
+        XLOCK:==$H268SYSEXE:XLOCK
+      where H268SYSEXE is a logical name pointing to the directory where
+      XLOCK.EXE resides. The '$' after == means this is a foreign command
+      and VMS makes the command line available to the program.
+    If the link bombs out I recommend trying it again like the following:
+        $ @make clean
+        $ @make
+    -allowroot only works if you have SYSPRV enabled which is a bit limiting.
+      Unless one uses the privileged install by a system manager.  To do
+      this, the following command needs to be executed at system startup
+      (i.e. included in systartup_vms.com):
+         INSTALL ADD {dev}:[{dir}]XLOCK.EXE/PRIV=(SYSPRV)
+      where {dev}:[{dir}] is the full path of the executable.
+    The XLock file normally in /usr/lib/X11/app-defaults needs to be in the
+      directory DECW$SYSTEM_DEFAULTS on VMS systems and be called
+      'DECW$XLOCK.DAT'.
+    USE_XLOCKRC, USE_AUTO_LOGOUT, USE_BUTTON_LOGOUT, & USE_MULTIPLE_ROOT
+      features are not implemented.
+    To use audio:
+      Set "sound" to be 1 in the make.com file.  Only available on the Alpha.
+      To get it work on a VAX some editing of the make.com is needed
+        (scan for USE_VMSPLAY)
+      The default sound files are hard coded to be in the current directory
+        see line 128 or so of the resource.c file but can be overruled from
+        the command line or the resourcefile decw$xlock.dat.
+      Sounds did not work for me on the VAX.
+      It should work OK on an AXP. (Due to a bug in the SO driver on some
+        models running VMS7.0, sounds are only available on the headset).
+    To use new event loop:
+       For VMS7.0 and higher : new event loop is used by default.
+         You do not need to install extra software.
+       For VMS6.2 or lower :
+         You need some UNIX utilities installed (XVMSUTILS).  See where to get
+         it below.
+         Look at the make.com and xvmsutil stuff.
+
+  XFree86
+    Control-Alt-Backspace will defeat locking mechanism and return your
+      console back unless you put "DontZap" in your XF86Config file.
+      (In X11R5, that would be a "dontzap" in your Xconfig file).
+    Control-Alt-F1 (among others) will defeat locking mechanism with
+      virtual terminals. This is not too good, right?  If you are using
+      Linux, try vlock on tsx-11.mit.edu in /pub/linux/sources/usr.bin .
+      The current XFree86 (as far as I know) does not have a server
+      extension for catching or disabling VT switching.
+    Here is a work around, put this line in /etc/profile:
+        alias x='(startx >/dev/null &);clear;logout'
+      then use 'x' instead of 'startx' (with no other active VT's).
+    Try configuring with --enable-vtlock .  This is experimental and requires
+      xlock being setuid to root so there are security concerns with it.
+      See man pages for its runtime options.
+
+  XPM
+    Full color pixmap package.  See below on availability.  Follow its
+      instructions and then go to iconfig.h and uncomment (should be
+      autodetected if you use configure)
+XCOMM #define XpmLibrary
+
+  X-Terminal
+    (My heart bleeds for you.)
+    To get xlock to run, run with -remote option or set XLock.remote on
+    in XLock.ad .  You might have to use -allowaccess as well.
+        
+  tvtwm
+    One used to get following error when running xlock (+nolock) with
+      tvtwm.
+    X Error of failed request:  BadWindow (invalid Window parameter)
+    What happens is that RootWindow(dsp, screen) fails when tvtwm is
+      running.  There is a kludge fix, but multiscreens will not work
+      right with tvtwm and xlock. (grep on TVTWM in xlock.c).
+    Another option, don't compile with -DUSE_VROOT .  If you debug it
+      mail ME -OR- both the author of tvtwm and ME the patch. 
+    StickyAbove problems:
+      Windows in a tvtwm that have "StickyAbove" set to true are still
+      visible when xlock (+inroot) is running. If this bothers you,
+      don't compile with -DUSE_VROOT .  Is it possible to have xlock
+      set "StickyAbove" to true as well? 
+
+  fvwm
+    -install does not install colormaps.  fvwm will not allow an
+    application to install its own colormap.  You could always edit the
+    source if you have it, (fvwm-1.24r)colormaps.c, where it says 
+ if(ReInstall)
+   {
+     XInstallColormap(dpy,last_cmap);
+   }
+    make sure this does not happen.
+
+  swirl (and tube) mode
+    Use with -install to see colormap change.
+    See "fvwm" if applicable.
+    "swirl" cycles its colors, except black and white.
+    This is easily seen when on a color monitor one enters:
+       ./xlock -mode swirl -inwindow -install
+    now move the mouse in the window.
+    If you find this annoying compile swirl.c with -DFORCEFIXEDCOLORS.
+    I hear it LOCKS UP on i386BsdArchitecture and tvtwm.
+    With twm (and fvwm see above) the colormap does not change.
+
+  SafeWord
+    Edit config.h.in ... uncomment SAFEWORD line near bottom.
+    In modes/Makefile.in make sure SAFEWORD is linked in, comment out
+      similar link that does not contain safeword libraries.
+    Put the cust*.h files in the main xlock directory.
+    Use `configure; make`.
+    Get back to me if it works or does not work.
+     
+  Dynamic Linking
+    Hacked in but not currently working.
+    How to use elf on the sun with gcc and Gnu's make
+      Put this in iconfig.h
+#define Modules
+      xmkmf -a
+      Edit Makefile(s)
+        edit out all "-z text -M mapfile"
+        edit out change "ccs" to "local" so that the "make" path is to
+           Gnu's "make".
+        make
+        make install
+      Also added some stuff to configure but it is working less then xmkmf.
+    This patch was originally written for Linux.  Not all distributions
+    have "dlfcn.h" which is needed.  It may work better on Linux.
+      xlock core dumps right away... gdb gives 
+        Program received signal SIGSEGV, Segmentation fault.
+        0x40002d2b in _dl_debug_state ()
+
+
+Personal Use
+------------
+  You may want to compile with USE_XLOCKRC .  xlock will then prompt
+  you the first time you use it for a password.  It is then encrypted
+  and stored in your $HOME/.xlockrc file.  This is also good for
+  users who have an unrecognized shadow password environment.  See
+  iconfig.h file (xmkmf) or `configure --help` for an example.
+  Please note that it may be rude to use xlock in a lab environment.
+
+Lab Environment
+---------------
+  The auto logout feature, when enabled, will log out a user after
+  30 minutes (by default).  The timeout can be changed or disabled
+  with a command-line option (or x resource -- this is allowed because
+  the logout button can always be used; see below).  The time
+  remaining before auto-logout is displayed on the password entry
+  screen.
+  The logout button, when enabled, is a button that appears on the
+  password entry screen after 5 minutes (configurable at
+  compile-time) that, when clicked, logs out the user.  The rationale
+  for this thing is that in a lab environment, we wanted a way for
+  users to be able to reliably lock their display for short periods
+  of time, but still be allowed to have the display locked for longer
+  than that if the lab isn't busy.  If the lab IS busy, and there is
+  a need for workstations, the logout button can be used to logout
+  someone who's been gone for more than 5 minutes.
+  Of course, the auto-logout and the logout button are
+  enabled/disabled by compile-time defines.  All these are OFF by
+  default.  One can also force use these features with a local policy
+  of exemptions (e.g. username or group). See the iconfig.h file or
+  `configure --help` for an example.  Edit your /etc/xlock.staff
+  file to reflect your policy.  If using xdm, you may just want to use
+  -DCLOSEDOWN_LOGOUT (or -DSESSION_LOGOUT <- old way) in conjuction
+  with -DUSE_AUTO_LOGOUT or -DUSE_BUTTON_LOGOUT.  That way all
+  backgrounded processes owned by a user do not have to be killed.
+
+  Don't PANIC, the auto-logout and the logout button will not run if
+  you are root.  Otherwise, it will kill all of root's processes, not
+  a good idea.  As long as you do not lock the screen (using -nolock,
+  -inwindow, or -inroot) the policy of xlock users does not go into
+  effect.
+
+
+xlock still does not work:  :-(
+-------------------------------
+  If all that does not work you may need to adjust xlock.h, passwd.c
+  xlock.c, and resource.c since these files are highly implementation
+  dependent.  If you have to make this kind of change to get it working,
+  let me know.
+
+  You can try compiling with -g and running it with -debug and your
+  favorite debugger, so xlock will run in a more friendly way (i.e. it
+  does not lock the screen).  There are also may be compile time switches
+  that could be turned on with -DDEBUG depending on what is not working
+  correctly.
+
+  Here is a simple recipe:
+    Make sure the 12th line in the iconfig.h is a comment
+      (This is because the debug library for xpm is not usually installed)
+XCOMM #define XpmLibrary
+    xmkmf  <or configure --without-xpm>
+    edit Makefile  on the line with CC = gcc or or CC = cc change to
+               CC = gcc -g -DDEBUG
+    make depend <but not if using configure>
+    make
+    gdb xlock  (xdb or dbx xlock may work too.)
+    run -debug <other xlock options you want here>
+    where
+    print <relevant variables>
+      (you may have to use "up" to take you to xlockmore code)>
+    Mail me the results.
+
+  If xlock crashes for you when in random mode... try this and mail
+    me the results.  (If it runs for a long time partial result will do
+    (gut the middle part)).
+  xlock -mode random -modelist all +install -debug -verbose
+    -modelist all: all modes except blank
+    -debug: so it does not lock the screen.
+    -verbose: for maximum verbosity.
+    +install: so it does not keep changing the colormap
+
+
+Other things to try: (if you got it working :-) )
+-------------------------------------------------
+
+  Check out etc directory for menus and other goodies.
+
+  If you like to check out what xlock looks like on multiscreens and you
+    do not have them... but do have Linux and Xnest ... try:
+     Xnest -scrns 3 :1 &
+     xterm -display :1.0
+    And run xlock from the created xterm.  (For some reason I have to do
+    it as root).
+    If you are using MesaGL, it must be compiled without SHM extension do
+      to a bug in Xnest (even in XFree3.3 == X11R6.3) or you will get
+      "BadDrawable (invalid Pixmap or Window parameter)".
+
+  You may want to change the 1st line of XLock.ad "random" to "blank",
+  "life", or whatever your favorite is and copy it to
+  /usr/lib/X11/app-defaults or $HOME (or wherever your application
+  defaults files are) and rename to XLock .
+
+  You may want some of the modes never to come up in random.  This is
+  already hard coded for the blank mode.  See xlock man page on "modelist".
+  In mode.c you can hard code others by just putting the stuff that you do
+  not like in the LockProcs to the end of the static array and in
+  random.c increase NUMSPECIAL by the number of new screens that you do
+  not want displayed.
+
+  You may want to move xlock into /usr/bin/X11 (or wherever your X
+  binaries are). You may also want to move xlock.man to
+  /usr/man/man1/xlock.1 .
+
+  If you want to remove some unwanted modes just edit "mode.h" and
+  "mode.c" grep the for the unwanted modes.  You might want to edit
+  the man page and your favorite make file as well.
+
+  I am very interested in cellular automata.  I am always looking to
+  improve ant, life, life3d, and life1d.  If anyone knows any new
+  collections (I have lifep.zip (May 94) and xlife 3.0) let me know.  If
+  you would like further information let me know.  There are several
+  run-time options to check out, see docs/cell_automata.
+
+  Still like xscreensaver better?  (Obscenities omitted ;) ) Try
+  setting your apps-defaults file for xscreensaver like:
+*programs:      xlock -nolock +grabmouse -mode random
+
+  If you want to hack a new mode check out docs/HACKERS.GUIDE.  Then
+  when working, just mail it to me, grep on "Maintainer" for the
+  address.
+
+
+Other related stuff (all not maintained by me):
+--------------------------------------------------------------------
+  NAME
+   LOCATION (last seen at)
+   DESCRIPTION
+ =============
+  audio/VMS
+    http://axp616.gsi.de:8080/www/vms/mzsw.html
+  fortune
+    ftp://igor.girton.cam.ac.uk/pub/funny/cookie.tgz 
+    ftp://ftp.uu.net/systems/unix/BSD/games/fortune
+    ftp://ftp.sterling.com/usenet/alt.sources/index (grep for cookie)
+    Please note that my format is slightly different.  The number at the
+      top of the file should match `grep -c "^%%$" fortune.dat`
+  imake
+    ftp://hpux.csc.liv.ac.uk/hpux/X11/Core/imake-5.06/imake-5.06-ss-9.03.tar.gz
+    I had to worry about FIXUP_CPP_WHITESPACE.
+  Lesstif
+    ftp://ftp.hungry.com/pub/hungry/lesstif/lesstif-current.tar.gz
+    Lesstif Library (just like Motif)
+  Man2HTML
+    ftp://sunsite.unc.edu/pub/Linux/system/Manual-pagers/vh-man2html-1.4.tar.gz
+  MesaGL
+    ftp://iris.ssec.wisc.edu/pub/Mesa
+    Mesa 3-D Graphics Library (like GL) Mesa-2.3 or greater required.
+    Mesa-2.2 and below has some memory leaks.
+  NAS (audio package)
+    ftp://ftp.x.org/contrib/audio/nas
+  rplay (audio package)
+    ftp://ftp.x.org/contrib/audio/rplay
+  sx
+    Use with Athena.
+    ftp://sunsite.unc.edu/pub/Linux/X11/devel/librairies/clibs/libsx.tar.gz
+  UNIX/VMS
+    Unix-like routines XVMSUTILS can be found at
+      http://axp616.gsi.de:8080/www/vms/mzsw.html
+  xautolock (runs xlock after a idle time)
+    ftp://ftp.x.org/contrib/applications
+    ftp://sunsite.unc.edu/pub/Linux/X11/screensavers
+    (I use openwin and I put this in my $HOME/.openwin-init)
+    toolwait /usr/local/bin/xautolock -time 5 -locker "xlock -lockdelay 30"
+  XPM
+    ftp://ftp.x.org/contrib/libraries
+    color pixmaps
+  XPM/VMS
+    use the one above or xlock may bomb out,
+    compile with cc/standard=vaxc/define=(need_strcasecmp,need_strdup)
+      except when using XVMSUTILS.
+  xscreensaver
+    ftp://ftp.x.org/contrib/applications
+    http://www.jwz.org/xscreensaver
+
+
+Operation: (Blurb taken from Darren Senn's xlock)
+------------------------------------------------- 
+
+  Under X, run xlock.  The screen will clear, and some pretty animated
+  picture (exactly which depends on which module is active) will appear
+  on the screen.  If you hit a key, then the screen will clear, and
+  (unless you've changed the application defaults file that I packaged
+  with this) you'll get a black screen with some graphics in the top
+  center.  These graphics consist of a reduced size image of the module
+  you were viewing, the name of the user who executed xlock, and
+  password prompt field, and some short instructions.
+  At this point, you can either click on the graphic to return to xlock,
+  or you can type a password.  If the password is verifiable as the
+  root password, or the password of the user listed above, then xlock
+  will terminate.  THIS IS THE ONLY WAY TO STOP XLOCK WITHOUT SHUTTING
+  DOWN THE X SERVER.  That's what makes it a lock.
+
+Resources: (Also taken from Darren Senn's xlock)
+------------------------------------------------
+  There are two sets of resources for XLock.  The first set are (what I
+  call) global XLock resources, while the second set consists of
+  module-specific resources.
+  The global resources are:
+        XLock.mode: This sets the module.
+        XLock.font: This is the font used on the password entry screen.
+        XLock.background: The background color for the password entry screen.
+        XLock.foreground: The foreground color for the password entry screen.
+        XLock.username: The label for the field indicating the user name.
+        XLock.password: The label for the password prompt.
+        XLock.info: The "short instructions" to print.
+        XLock.validate: A message to display while checking the password
+        XLock.invalid: A message to display if the password is incorrect
+        XLock.nice: How much XLock should nice itself.
+        XLock.timeout: How long to wait idle at the password prompt.
+        XLock.timeelapsed: Message to see how long lock running (yes or no)
+        XLock.mono: Monochrome mode (yes or no)
+        XLock.nolock: disable the lock mechanism (yes or no)
+        XLock.remote: allow remote locking (meaningless under linux)
+        XLock.allowroot: allow the root password to unlock (yes or no)
+        XLock.enablesaver: allow the system screensaver to work (yes or no)
+        XLock.allowaccess: allow other clients to connect while active
+        XLock.echokeys: Echo "?" for each password keypress (yes or no)
+        XLock.usefirst: Ignore the first character typed (yes or no)
+        XLock.verbose: Verbose mode. (yes or no)
+        XLock.inwindow: allow the xlock to run in a window (yes or no)
+        XLock.inroot: allow the xlock to run in the root window (yes or no)
+        XLock.grabmouse: Grab the keyboard and mouse (yes or no)
+  XLock has a number of modules which it can display.  (See the man page
+  for a complete list).  It turns out that each module is characterized
+  by a number of initializations, separated by a number of "draws".
+  Each module has the following resources defined:
+
+        XLock.<module>.delay: How long to wait between draws (usec)
+        XLock.<module>.batchcount: May mean various things (see man page).
+        XLock.<module>.cycles: Controls the timeout of screen (see man page).
+        XLock.<module>.size: Controls size of objects on screen (see man page).
+        XLock.<module>.saturation: Saturation (as in HSV) of colors to use.
+
+
+Acknowledgments:
+----------------
+
+  I did not write the original algorithms in any of the lock screens
+  (except wator, bug, life1d, demon, ant, daisy, and voters), although I
+  did convert many of the new ones to run with xlock.  I tried to follow
+  the original style of Patrick Naughton.  Updates are made at
+  ftp.x.org in directory /contrib/applications.  Many of the additions
+  were "borrowed" from xscreensaver (Jamie Zawinski <jwz@jwz.org>).
+  Some of the others were "borrowed" from old demos from Sun.  Many more
+  are contributions.
+
+  I will consider putting new ones in if (1) they are more or less public
+  domain (i.e. BSD, sorry no GNU copyrights), (2) they are neat (I am
+  biased towards mathematically based programs (especially the Computer
+  Recreations of Scientific American)), and (3) I have the time.
+
+  Also many thanks to the people that helped me countless times with 
+  xlock mentioned in "Revisions", especially Jouk Jansen, Tom Schmidt,
+  David Hansen, Ed Mackey, Marcelo Vianna, Ron Hitchens, and Heath Kehoe.
+
diff --git a/xlockmore-4.14/bitmaps/bad.xbm b/xlockmore-4.14/bitmaps/bad.xbm
new file mode 100644 (file)
index 0000000..a778f5e
--- /dev/null
@@ -0,0 +1,9 @@
+#define bad_width 21
+#define bad_height 21
+static unsigned char bad_bits[] = {
+   0x80, 0x1f, 0x00, 0x60, 0x60, 0x00, 0x10, 0x80, 0x00, 0x08, 0x00, 0x01,
+   0x04, 0x00, 0x02, 0x82, 0x10, 0x04, 0x42, 0x29, 0x04, 0x81, 0x10, 0x08,
+   0x01, 0x00, 0x08, 0x01, 0x00, 0x08, 0x01, 0x00, 0x08, 0x01, 0x00, 0x08,
+   0xe1, 0x7f, 0x08, 0xe2, 0x7f, 0x04, 0x02, 0x00, 0x04, 0x04, 0x00, 0x02,
+   0x08, 0x00, 0x01, 0x10, 0x80, 0x00, 0x60, 0x60, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bat-0.xbm b/xlockmore-4.14/bitmaps/bat-0.xbm
new file mode 100644 (file)
index 0000000..f73886e
--- /dev/null
@@ -0,0 +1,174 @@
+#define bat0_width 147
+#define bat0_height 108
+static unsigned char bat0_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01,
+   0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x81, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xe1, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf3, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x11, 0x7e, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xc0, 0x03, 0xfd, 0x7f, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0xb6,
+   0xcf, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x76, 0xa7, 0x19, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18,
+   0x00, 0xc6, 0xb7, 0x31, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0xe0, 0xdd, 0x86, 0x61, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x06, 0xf8, 0x7f, 0x8c, 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x1c, 0x70, 0xfe,
+   0x86, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x01, 0x06, 0xf0, 0xfe, 0x0c, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x06,
+   0x60, 0x0e, 0x08, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x70, 0x0e, 0x18, 0x02, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40,
+   0x80, 0x06, 0x60, 0x06, 0x90, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xe0, 0x07, 0x70, 0x07, 0x30,
+   0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x30, 0x60, 0x0e, 0x30, 0x05, 0x30, 0x0c, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x20, 0x00, 0x30,
+   0x05, 0x30, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x10, 0x30, 0x00, 0x30, 0x05, 0x30, 0x18, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x30,
+   0x00, 0x30, 0x05, 0x30, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x30, 0x00, 0x30, 0x07, 0x10, 0x10,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x08, 0x30, 0x00, 0xb0, 0x02, 0x18, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x10, 0x00, 0xb0, 0x02,
+   0x0e, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0x10, 0x00, 0xb8, 0x02, 0x0f, 0x20, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x10, 0x00,
+   0x98, 0x02, 0x07, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x04, 0x30, 0x00, 0x98, 0x03, 0x06, 0x60, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04,
+   0x30, 0x00, 0x98, 0x03, 0x06, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x30, 0x00, 0x98, 0x01, 0x04,
+   0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x06, 0x20, 0x00, 0x98, 0x01, 0x0c, 0x40, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x20, 0x00, 0x98,
+   0x01, 0x0c, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x06, 0x60, 0x00, 0xc8, 0x01, 0x0c, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x60,
+   0x00, 0xc0, 0x00, 0x0c, 0xd0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x40, 0x00, 0x00, 0x00, 0x04, 0x80,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc6, 0xdf, 0x00, 0x00, 0x00, 0x04, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe2, 0xf8, 0x00, 0x00, 0x00,
+   0x06, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x76, 0xe0, 0x01, 0x00, 0x00, 0x06, 0xa0, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x32, 0xc0, 0x01,
+   0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x16, 0x80, 0x03, 0x00, 0x00, 0x02, 0xa0, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16,
+   0x00, 0x03, 0x00, 0x00, 0x03, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x07, 0x00, 0x00, 0x03,
+   0xa0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x1c, 0x00, 0x06, 0x00, 0x00, 0x01, 0x80, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00,
+   0x80, 0x01, 0xa0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x80, 0x01, 0x80, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00,
+   0x00, 0x00, 0x80, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x9c, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xa0,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xbc, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, 0x60,
+   0x00, 0x20, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xa8, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb8, 0x00, 0x00,
+   0x00, 0xf8, 0x7f, 0x60, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xf8, 0x08, 0x00, 0x00, 0x38, 0xe8, 0x43, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8,
+   0x08, 0x00, 0x00, 0x00, 0x00, 0x27, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x08, 0x00, 0x00, 0x00, 0x00,
+   0xac, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xf0, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x38, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x04, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03,
+   0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc0, 0x80, 0x01, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x00, 0x00, 0x00,
+   0x80, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x63, 0x00, 0x00, 0x00, 0x80, 0xf9, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00,
+   0x00, 0x00, 0x00, 0x8f, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6f, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bat-1.xbm b/xlockmore-4.14/bitmaps/bat-1.xbm
new file mode 100644 (file)
index 0000000..5c421d1
--- /dev/null
@@ -0,0 +1,174 @@
+#define bat1_width 147
+#define bat1_height 108
+static unsigned char bat1_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x0b,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x0a, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x38, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x0c, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x1f,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x7c, 0xce, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xdf,
+   0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x3f, 0x80, 0xc3, 0xff, 0x03, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00,
+   0x80, 0x81, 0xbf, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x80, 0x18, 0xcf, 0x03, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18,
+   0x00, 0x00, 0x90, 0x09, 0x07, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x1c, 0x83, 0x1f,
+   0xe2, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x38, 0x00, 0x00, 0x00, 0x06, 0xfe, 0x03, 0x03, 0x0e, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x05, 0x00, 0x00, 0x00, 0x03,
+   0xa0, 0xff, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x60, 0x00, 0x00, 0x00, 0x80, 0x00, 0x90, 0x7d, 0x00, 0x80, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00,
+   0xc0, 0x00, 0x90, 0x0d, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x60, 0x00, 0x88, 0x05, 0x00,
+   0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00,
+   0x00, 0x00, 0x30, 0x00, 0x88, 0x85, 0x07, 0x00, 0x20, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x0f, 0x10, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0xc8,
+   0x62, 0x1c, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x0c,
+   0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x84, 0x12, 0x30, 0x00, 0x00, 0x03,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x32, 0x00, 0x00, 0x00, 0x00, 0x08,
+   0x00, 0xa4, 0x03, 0xc0, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xe0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x0c, 0x00, 0xe4, 0x01, 0x80, 0x01,
+   0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x7c, 0x00, 0x00,
+   0x00, 0x04, 0x00, 0x54, 0x01, 0x00, 0x03, 0x00, 0x60, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x04, 0x00, 0xd2, 0x00,
+   0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00,
+   0x07, 0xf0, 0x03, 0x06, 0x00, 0xda, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x03,
+   0x00, 0x00, 0x00, 0x00, 0xd8, 0x00, 0x00, 0x1c, 0xbc, 0x2f, 0x02, 0x00,
+   0x68, 0x00, 0x00, 0x08, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x8c,
+   0x00, 0x00, 0x70, 0x0c, 0x18, 0x02, 0x00, 0x6d, 0x00, 0x00, 0x08, 0x00,
+   0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x04, 0x03, 0x00, 0xc0, 0x06, 0x10,
+   0x03, 0x00, 0x65, 0x00, 0x00, 0x08, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00,
+   0x00, 0x02, 0x0e, 0x00, 0x80, 0x03, 0x30, 0x02, 0x00, 0x35, 0x00, 0x00,
+   0x0c, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x02, 0x30, 0x00, 0x80,
+   0x03, 0x20, 0x03, 0x80, 0x32, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x03,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x20, 0x03, 0x80, 0x3a,
+   0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00,
+   0x00, 0x00, 0x03, 0x60, 0x01, 0x80, 0x1b, 0x00, 0x00, 0x06, 0x00, 0x00,
+   0x00, 0x08, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x60, 0x01,
+   0x80, 0x19, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x01, 0x80, 0x19, 0x00, 0x80, 0x03,
+   0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc0, 0x01, 0xc0, 0x0c, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0xc0, 0x0c, 0x00,
+   0x1f, 0x00, 0x00, 0x00, 0xf8, 0xc3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xc0, 0x01, 0xc0, 0x0c, 0x00, 0x3a, 0x00, 0x00, 0x00, 0x1f,
+   0x8f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0xc0,
+   0x04, 0x00, 0xe0, 0x00, 0x00, 0xe0, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x06, 0x00, 0x80, 0x03, 0x00,
+   0x18, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
+   0x01, 0x00, 0x02, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x0c, 0x00, 0x03, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0xc0, 0x00, 0x00, 0x00,
+   0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x18, 0x60, 0x00, 0x00, 0xf0, 0x67, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x10, 0x00,
+   0x00, 0x00, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x60, 0x08, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60,
+   0x0c, 0x00, 0x00, 0x00, 0x26, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x06, 0x00, 0x00, 0x00, 0x33,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x40, 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bat-2.xbm b/xlockmore-4.14/bitmaps/bat-2.xbm
new file mode 100644 (file)
index 0000000..c1ff4b4
--- /dev/null
@@ -0,0 +1,174 @@
+#define bat2_width 147
+#define bat2_height 108
+static unsigned char bat2_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x26, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0xfc, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x20, 0xf6, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xc3, 0x03, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x81, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81,
+   0x0d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x1f, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x73, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xce, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x8e, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c,
+   0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x0c, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x58, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd8, 0x30, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x90, 0xc0, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x81,
+   0x01, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x03, 0x00, 0x20, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x30, 0x02, 0x0e, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x36, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x38, 0x00, 0x00,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x62, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x20, 0x00, 0xe0, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80,
+   0x01, 0x00, 0x02, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x0f, 0x60, 0xf2, 0x03, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40,
+   0x00, 0x00, 0xfc, 0xfc, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x40, 0xff,
+   0xdf, 0x01, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0xc0, 0x8f, 0xff,
+   0x03, 0x00, 0x00, 0x00, 0x00, 0xff, 0xf7, 0x0f, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x23, 0x9f, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0x73, 0x38, 0x08, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00,
+   0xb3, 0x0f, 0x06, 0xd0, 0xaf, 0xa0, 0x0d, 0x00, 0x0e, 0x1a, 0x02, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x80, 0xc3, 0x2d, 0x06, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x03, 0x1b, 0x02, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00,
+   0x00, 0x80, 0xff, 0x7c, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x1b,
+   0x02, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0xc0, 0x7c, 0xfc, 0x3f,
+   0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x08, 0x06, 0x00, 0x00, 0x00, 0x00,
+   0x80, 0x00, 0x00, 0xc0, 0x70, 0xfc, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x18,
+   0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0xc0, 0x30,
+   0x1c, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x08, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x00, 0x00, 0xc0, 0x30, 0x1c, 0x00, 0x03, 0x00, 0x00,
+   0x00, 0x07, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00,
+   0xfc, 0x31, 0x14, 0x00, 0x06, 0x00, 0x00, 0x80, 0x01, 0x00, 0x0c, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0xfe, 0x33, 0x1c, 0x00, 0x1c,
+   0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
+   0x00, 0x00, 0x83, 0x37, 0x0c, 0x00, 0x18, 0x00, 0x00, 0x60, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x81, 0x2f, 0x0c,
+   0x00, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x40, 0x00, 0x00, 0x01, 0x2a, 0x0e, 0x00, 0x30, 0x00, 0x00, 0x30,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x7e, 0x80, 0x01,
+   0x20, 0x0c, 0x00, 0x30, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x40, 0xfe, 0x83, 0x01, 0x28, 0x0c, 0x00, 0x30, 0x00,
+   0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03,
+   0x8f, 0x01, 0x28, 0x0e, 0x00, 0x10, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0xb8, 0x01, 0x38, 0x0e, 0x00,
+   0x18, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc0, 0x00, 0xf0, 0x01, 0x18, 0x0e, 0x00, 0x0c, 0x00, 0x00, 0x04, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x30,
+   0x06, 0x00, 0xfe, 0x07, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x18, 0x06, 0xc0, 0x3f, 0xfe, 0x00,
+   0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x80,
+   0x01, 0x18, 0x06, 0xc0, 0x01, 0xc0, 0x03, 0x02, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x03, 0x18, 0x0e, 0x80, 0x00,
+   0x00, 0x0e, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20,
+   0x00, 0x00, 0x03, 0x18, 0x06, 0x00, 0x00, 0x00, 0x08, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x18, 0x06,
+   0x00, 0x00, 0x00, 0x18, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x30, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06,
+   0x0c, 0x06, 0x00, 0x00, 0x00, 0xa0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x07, 0x00, 0x00, 0x00,
+   0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x0c, 0x0c, 0x06, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bat-3.xbm b/xlockmore-4.14/bitmaps/bat-3.xbm
new file mode 100644 (file)
index 0000000..bfe7265
--- /dev/null
@@ -0,0 +1,174 @@
+#define bat3_width 147
+#define bat3_height 108
+static unsigned char bat3_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x20, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x66, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc3, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x87, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x06,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x38, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x27, 0x06, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x60, 0x34, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xdc, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x30, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd6, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x34,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x68, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xcc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x60, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x9c, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x64, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x03, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x10, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x14, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x42, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x0c, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x04, 0xc2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x04, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02,
+   0x86, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04,
+   0x70, 0x00, 0x80, 0x00, 0x00, 0x00, 0x01, 0x81, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0xe0, 0x00, 0x80, 0x00, 0x00,
+   0x80, 0x00, 0x89, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x02, 0x80, 0x03, 0x70, 0x01, 0x00, 0x40, 0x00, 0x09, 0x03, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x07, 0xc0,
+   0x01, 0x00, 0x20, 0x80, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x02, 0x00, 0x1c, 0x80, 0x01, 0x00, 0x18, 0x80, 0x10,
+   0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
+   0x70, 0x00, 0x01, 0x02, 0x0c, 0x00, 0x21, 0x0c, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0xe0, 0x00, 0x03, 0x03, 0x02,
+   0x40, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
+   0x01, 0x00, 0x80, 0x03, 0xe2, 0x03, 0x01, 0x00, 0x40, 0x10, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x06, 0xf3,
+   0xc0, 0x00, 0x00, 0x80, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x40, 0x00, 0x00, 0xf0, 0xff, 0x60, 0x00, 0xa0, 0x00, 0x60,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00,
+   0xf8, 0xbf, 0x19, 0x00, 0x20, 0x00, 0x82, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x70, 0x0c, 0x8f, 0x05, 0x00, 0x90,
+   0x00, 0x04, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00,
+   0x00, 0xfc, 0x6f, 0x9a, 0x01, 0x00, 0x10, 0x00, 0x08, 0x06, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x06, 0x6c, 0x93, 0x01,
+   0x00, 0x00, 0x00, 0x30, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x10, 0x00, 0x00, 0x06, 0xf8, 0xc7, 0x00, 0x00, 0x08, 0x00, 0x40, 0x38,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x02, 0xf8,
+   0x7f, 0x00, 0x00, 0x00, 0x00, 0x80, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x08, 0x00, 0x00, 0x02, 0xf0, 0x9e, 0x1f, 0x00, 0x44, 0x00,
+   0x00, 0x82, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0xe0,
+   0x06, 0x50, 0x1e, 0x38, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0xf8, 0x07, 0x50, 0x0a, 0x60, 0x00,
+   0x02, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03,
+   0x00, 0x4c, 0x07, 0x50, 0x0a, 0xc0, 0x00, 0x41, 0x00, 0x00, 0xfc, 0x0f,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x79, 0x00, 0x04, 0x0e, 0x50, 0x0a,
+   0x80, 0x00, 0x00, 0x00, 0x80, 0x17, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc0, 0xff, 0x01, 0x06, 0x00, 0x58, 0x0a, 0x80, 0x81, 0x40, 0x00, 0xe0,
+   0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x03, 0x06, 0x00,
+   0x50, 0x0a, 0x00, 0x81, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x40, 0x00, 0x06, 0x03, 0x00, 0x70, 0x0a, 0x00, 0x43, 0x00,
+   0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c,
+   0x03, 0x00, 0x28, 0x0a, 0x00, 0x23, 0x20, 0x80, 0x03, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x03, 0x00, 0x38, 0x0e, 0x00,
+   0x23, 0x20, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x30, 0x01, 0x00, 0x28, 0x06, 0x00, 0x03, 0x00, 0x60, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x01, 0x00, 0x38,
+   0x06, 0x00, 0x03, 0x20, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x40, 0x01, 0x00, 0x38, 0x06, 0x00, 0x03, 0x00, 0x18,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01,
+   0x00, 0x38, 0x06, 0x00, 0x01, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x38, 0x06, 0x00, 0x01,
+   0x10, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x03, 0x00, 0x18, 0x07, 0x80, 0xff, 0x00, 0x03, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x07,
+   0x00, 0xc3, 0x81, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x03, 0x00, 0x00, 0xd1, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00,
+   0x18, 0x03, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, 0x03, 0x00, 0x00, 0x66,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x06, 0x00, 0x18, 0x03, 0x00, 0x00, 0x26, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, 0x03, 0x00,
+   0x00, 0x34, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0x00, 0x08, 0x03, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bat-4.xbm b/xlockmore-4.14/bitmaps/bat-4.xbm
new file mode 100644 (file)
index 0000000..f8de033
--- /dev/null
@@ -0,0 +1,174 @@
+#define bat4_width 147
+#define bat4_height 108
+static unsigned char bat4_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60,
+   0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x7c, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xf8, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xcc, 0xc1, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x67, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x31,
+   0x8c, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x18, 0x98, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x60, 0x0c, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x06, 0x9c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x10, 0x06, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x83, 0xff,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x0c, 0x83, 0xfd, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x84,
+   0xc1, 0xc4, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x82, 0x41, 0x84, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x83, 0x80, 0x06, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc1, 0x80, 0x04, 0x36,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x41, 0x80, 0x04, 0x6c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x60, 0x80,
+   0x05, 0xd8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x40, 0x20, 0x00, 0x05, 0x90, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20,
+   0x30, 0x00, 0x08, 0x10, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x10, 0x00, 0x00, 0x30, 0x38,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x18, 0x10, 0x00, 0x00, 0x20, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x18, 0x00, 0x00,
+   0x60, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x04, 0x18, 0x00, 0x00, 0x40, 0x00, 0x1e, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0c,
+   0x00, 0x00, 0xc0, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x08, 0x00, 0x00, 0x80, 0x00, 0x00,
+   0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
+   0x01, 0x0c, 0x00, 0x00, 0x80, 0x00, 0x00, 0xc0, 0x1f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x0c, 0x00, 0x00, 0x80,
+   0x01, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x20, 0x00, 0x0c, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0xc0, 0x07,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x0c, 0x00,
+   0x00, 0x00, 0x01, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x0c, 0x00, 0x04, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00,
+   0x5f, 0x3d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00,
+   0x04, 0x00, 0x00, 0x00, 0x01, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x01,
+   0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x04, 0x00, 0x00,
+   0x80, 0x01, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x30, 0x00, 0x00, 0x08, 0x00, 0x00, 0x80, 0x01, 0x00, 0x03, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08,
+   0x00, 0x00, 0x80, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x08, 0x00, 0x00, 0x80, 0x00, 0x80,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00,
+   0x00, 0x08, 0x00, 0x00, 0x80, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x18, 0x00, 0x00, 0xc0,
+   0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0,
+   0xff, 0x07, 0x00, 0x18, 0x00, 0x00, 0x40, 0x00, 0x60, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x03, 0x1e, 0x00, 0x10, 0x00,
+   0x00, 0x60, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x38, 0x00, 0x70, 0x00, 0x10, 0x00, 0x00, 0x20, 0x00, 0x30, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00,
+   0x30, 0xc0, 0x00, 0x30, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x20, 0xa0, 0x01, 0x10, 0x02,
+   0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x80, 0x01, 0x20, 0x00, 0x01, 0x19, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x60, 0x00, 0x81,
+   0x0b, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x02, 0x40, 0x00, 0xc2, 0x0d, 0x00, 0x10, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xc0,
+   0x00, 0xf2, 0x06, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0xe1, 0x7f, 0x03, 0x00, 0x10,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x04, 0x00, 0xb3, 0xff, 0x01, 0xe0, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x3e, 0xff, 0x38,
+   0xfd, 0x37, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0x00, 0x6c, 0x87, 0xff, 0x0f, 0x3e, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x08,
+   0x97, 0x83, 0x07, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x08, 0xbb, 0x80, 0x03, 0x70, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18,
+   0xc0, 0x99, 0xe7, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0xf0, 0xf0, 0x7f, 0x00, 0x00,
+   0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x10, 0x18, 0xe0, 0x1c, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x0c, 0xa0, 0x1c,
+   0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x30, 0x0c, 0xe0, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x08,
+   0xc0, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x1f, 0xc0, 0x14, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xe0, 0x1f, 0xc0, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x30, 0xc0, 0x14, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x60, 0x30, 0xc0, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x30, 0xc0,
+   0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0xc0, 0x14, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20,
+   0x00, 0xc0, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0xc0, 0x14, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x60, 0x00, 0xc0, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0xc0, 0x1c,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x60, 0x00, 0xc0, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00,
+   0x80, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x80, 0x18, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x60, 0x00, 0x80, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x80, 0x18, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
+   0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bounce-0.xbm b/xlockmore-4.14/bitmaps/bounce-0.xbm
new file mode 100644 (file)
index 0000000..b20b404
--- /dev/null
@@ -0,0 +1,46 @@
+#define bounce0_width 64
+#define bounce0_height 64
+static unsigned char bounce0_bits[] = {
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07,
+   0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x70, 0x78, 0x1e, 0x0e, 0x00, 0x00,
+   0x00, 0x00, 0x8c, 0x7f, 0xfe, 0x31, 0x00, 0x00, 0x00, 0x00, 0xf3, 0x7f,
+   0xfe, 0xcf, 0x00, 0x00, 0x00, 0x80, 0xfc, 0x7f, 0xfe, 0x3f, 0x01, 0x00,
+   0x00, 0x60, 0xff, 0x3f, 0xfc, 0xff, 0x06, 0x00, 0x00, 0x90, 0xff, 0x1f,
+   0xf8, 0xff, 0x09, 0x00, 0x00, 0xc8, 0xff, 0x07, 0xe0, 0xff, 0x13, 0x00,
+   0x00, 0xe4, 0xff, 0x03, 0xc0, 0xff, 0x27, 0x00, 0x00, 0xf2, 0xff, 0x01,
+   0x80, 0xff, 0x4f, 0x00, 0x00, 0xe1, 0x7f, 0x00, 0x00, 0xfe, 0x87, 0x00,
+   0x80, 0xc0, 0x1f, 0x00, 0x00, 0xf8, 0x03, 0x01, 0x40, 0x80, 0x01, 0x00,
+   0x00, 0x80, 0x01, 0x02, 0x40, 0x00, 0x78, 0x00, 0x00, 0x1e, 0x00, 0x02,
+   0x20, 0x80, 0x7f, 0x00, 0x00, 0xfe, 0x01, 0x04, 0x10, 0xc0, 0xff, 0x00,
+   0x00, 0xff, 0x03, 0x08, 0x10, 0xe0, 0xff, 0x00, 0x00, 0xff, 0x07, 0x08,
+   0x08, 0xe0, 0xff, 0x00, 0x00, 0xff, 0x07, 0x10, 0x08, 0xf0, 0xff, 0x01,
+   0x80, 0xff, 0x0f, 0x10, 0x04, 0xf0, 0xff, 0x01, 0x80, 0xff, 0x0f, 0x20,
+   0x04, 0xf8, 0xff, 0x03, 0xc0, 0xff, 0x1f, 0x20, 0x04, 0xf8, 0xff, 0x03,
+   0xc0, 0xff, 0x1f, 0x20, 0x02, 0xfc, 0xff, 0xf9, 0x9f, 0xff, 0x3f, 0x40,
+   0x02, 0xfc, 0xff, 0xfc, 0x3f, 0xff, 0x3f, 0x40, 0xfa, 0xfc, 0xff, 0xfe,
+   0x7f, 0xff, 0x3f, 0x5f, 0xfa, 0xfc, 0x7f, 0xfe, 0x7f, 0xfe, 0x3f, 0x5f,
+   0xfd, 0xfd, 0x7f, 0xff, 0xff, 0xfe, 0xbf, 0xbf, 0xfd, 0xf9, 0x3f, 0xff,
+   0xff, 0xfc, 0x9f, 0xbf, 0xfd, 0xf9, 0xbf, 0xff, 0xff, 0xfd, 0x9f, 0xbf,
+   0xfd, 0xfb, 0x9f, 0xff, 0xff, 0xf9, 0xdf, 0xbf, 0xfd, 0xfb, 0x9f, 0xff,
+   0xff, 0xf9, 0xdf, 0xbf, 0xfd, 0x03, 0xc0, 0xff, 0xff, 0x03, 0xc0, 0xbf,
+   0xfd, 0x03, 0xc0, 0xff, 0xff, 0x03, 0xc0, 0xbf, 0xfd, 0x03, 0xc0, 0xff,
+   0xff, 0x03, 0xc0, 0xbf, 0xfd, 0x03, 0x80, 0xff, 0xff, 0x01, 0xc0, 0xbf,
+   0xfd, 0x03, 0x80, 0xff, 0xff, 0x01, 0xc0, 0xbf, 0xfa, 0x03, 0x80, 0xff,
+   0xff, 0x01, 0xc0, 0x5f, 0xfa, 0x03, 0x00, 0xff, 0xff, 0x00, 0xc0, 0x5f,
+   0xfa, 0x03, 0x00, 0xff, 0xff, 0x00, 0xc0, 0x5f, 0xfa, 0x03, 0x00, 0xfe,
+   0x7f, 0x00, 0xc0, 0x5f, 0xf4, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x80, 0x2f,
+   0xf4, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x2f, 0xf4, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x2f, 0xe8, 0x01, 0x00, 0xfc, 0x3f, 0x00, 0x80, 0x17,
+   0xe8, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x80, 0x17, 0xd0, 0x00, 0x00, 0xff,
+   0xff, 0x00, 0x00, 0x0b, 0x10, 0x3e, 0x80, 0xff, 0xff, 0x01, 0x7c, 0x08,
+   0x20, 0xff, 0x81, 0xff, 0xff, 0x81, 0xff, 0x04, 0x40, 0xff, 0xcf, 0xff,
+   0xff, 0xf3, 0xff, 0x02, 0x40, 0xfe, 0xcf, 0xff, 0xff, 0xf3, 0x7f, 0x02,
+   0x80, 0xfe, 0x9f, 0xff, 0xff, 0xf9, 0x7f, 0x01, 0x00, 0xfd, 0x3f, 0xff,
+   0xff, 0xfc, 0xbf, 0x00, 0x00, 0xfa, 0x7f, 0xfe, 0x7f, 0xfe, 0x5f, 0x00,
+   0x00, 0xf4, 0x7f, 0xfe, 0x7f, 0xfe, 0x2f, 0x00, 0x00, 0xc8, 0xff, 0xfc,
+   0x3f, 0xff, 0x13, 0x00, 0x00, 0x90, 0xff, 0x01, 0x80, 0xff, 0x09, 0x00,
+   0x00, 0x60, 0xff, 0x00, 0x00, 0xff, 0x06, 0x00, 0x00, 0x80, 0xfc, 0x00,
+   0x00, 0x3f, 0x01, 0x00, 0x00, 0x00, 0x73, 0x00, 0x00, 0xce, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00,
+   0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07, 0xe0, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bounce-1.xbm b/xlockmore-4.14/bitmaps/bounce-1.xbm
new file mode 100644 (file)
index 0000000..1a0ff30
--- /dev/null
@@ -0,0 +1,46 @@
+#define bounce1_width 64
+#define bounce1_height 64
+static unsigned char bounce1_bits[] = {
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07,
+   0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x70, 0xf8, 0x1f, 0x0e, 0x00, 0x00,
+   0x00, 0x00, 0x8c, 0xff, 0x7f, 0x30, 0x00, 0x00, 0x00, 0x00, 0xf3, 0xff,
+   0x7f, 0xc0, 0x00, 0x00, 0x00, 0x80, 0xfc, 0xff, 0x7f, 0x00, 0x01, 0x00,
+   0x00, 0x60, 0xfe, 0xff, 0x7f, 0x00, 0x06, 0x00, 0x00, 0x10, 0xfe, 0xff,
+   0x7f, 0x00, 0x08, 0x00, 0x00, 0xc8, 0xfc, 0xff, 0x1f, 0x00, 0x10, 0x00,
+   0x00, 0xf4, 0x81, 0xff, 0x03, 0x00, 0x20, 0x00, 0x00, 0xfa, 0x01, 0x00,
+   0xf0, 0x01, 0x40, 0x00, 0x00, 0xfd, 0x01, 0x00, 0xff, 0x07, 0x80, 0x00,
+   0x80, 0xfe, 0x01, 0x00, 0xff, 0x1f, 0x20, 0x01, 0x40, 0xfe, 0x01, 0x00,
+   0xff, 0x7f, 0x70, 0x02, 0x40, 0xff, 0x00, 0x00, 0xff, 0xff, 0xf8, 0x02,
+   0xa0, 0xff, 0x00, 0x00, 0xff, 0xff, 0xfd, 0x05, 0xd0, 0xff, 0x00, 0x00,
+   0xff, 0xff, 0xfd, 0x0b, 0xd0, 0x7f, 0x00, 0x00, 0xff, 0xff, 0xf9, 0x0b,
+   0xe8, 0x7f, 0x00, 0x00, 0xff, 0xff, 0xf9, 0x17, 0xe8, 0x7f, 0x00, 0x00,
+   0xff, 0xff, 0xfb, 0x17, 0xf4, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xfb, 0x2f,
+   0xf4, 0x0f, 0x00, 0x00, 0xfc, 0xff, 0xf3, 0x2f, 0xf4, 0x67, 0x00, 0xe0,
+   0xf0, 0xff, 0xf3, 0x2f, 0xe2, 0xf1, 0x01, 0xfc, 0xc7, 0xff, 0xe0, 0x5f,
+   0x82, 0xf8, 0x03, 0xff, 0x1f, 0x1f, 0xe0, 0x5f, 0x02, 0xfe, 0xc7, 0xff,
+   0x7f, 0x06, 0xc0, 0x5f, 0x02, 0xff, 0xcf, 0xff, 0xff, 0x00, 0x80, 0x5f,
+   0x01, 0xff, 0xcf, 0xff, 0xff, 0x01, 0x00, 0xbf, 0x01, 0xff, 0xcf, 0xff,
+   0xff, 0x01, 0x00, 0xbf, 0x01, 0xff, 0xcf, 0xff, 0xff, 0x01, 0x00, 0xbe,
+   0x01, 0xff, 0xcf, 0xff, 0xff, 0x01, 0x00, 0xbc, 0x01, 0xff, 0xcf, 0xff,
+   0xff, 0x01, 0x00, 0x80, 0x01, 0xff, 0xcf, 0xff, 0xff, 0x01, 0x00, 0x80,
+   0x01, 0xff, 0xcf, 0xff, 0xff, 0x01, 0x00, 0xbc, 0x01, 0xff, 0xcf, 0xff,
+   0xff, 0x01, 0x00, 0xbe, 0x01, 0xff, 0xcf, 0xff, 0xff, 0x01, 0x00, 0xbf,
+   0x01, 0xff, 0xcf, 0xff, 0xff, 0x01, 0x00, 0xbf, 0x02, 0xff, 0xcf, 0xff,
+   0xff, 0x00, 0x80, 0x5f, 0x02, 0xfe, 0xc7, 0xff, 0x7f, 0x06, 0xc0, 0x5f,
+   0x82, 0xf8, 0x03, 0xff, 0x1f, 0x1f, 0xe0, 0x5f, 0xe2, 0xf1, 0x01, 0xfc,
+   0xc7, 0xff, 0xe0, 0x5f, 0xf4, 0x67, 0x00, 0xe0, 0xf0, 0xff, 0xf3, 0x2f,
+   0xf4, 0x0f, 0x00, 0x00, 0xfc, 0xff, 0xf3, 0x2f, 0xf4, 0x1f, 0x00, 0x00,
+   0xff, 0xff, 0xfb, 0x2f, 0xe8, 0x7f, 0x00, 0x00, 0xff, 0xff, 0xfb, 0x17,
+   0xe8, 0x7f, 0x00, 0x00, 0xff, 0xff, 0xf9, 0x17, 0xd0, 0x7f, 0x00, 0x00,
+   0xff, 0xff, 0xf9, 0x0b, 0xd0, 0xff, 0x00, 0x00, 0xff, 0xff, 0xfd, 0x0b,
+   0xa0, 0xff, 0x00, 0x00, 0xff, 0xff, 0xfd, 0x05, 0x40, 0xff, 0x00, 0x00,
+   0xff, 0xff, 0xf8, 0x02, 0x40, 0xfe, 0x01, 0x00, 0xff, 0x7f, 0x70, 0x02,
+   0x80, 0xfe, 0x01, 0x00, 0xff, 0x1f, 0x20, 0x01, 0x00, 0xfd, 0x01, 0x00,
+   0xff, 0x07, 0x80, 0x00, 0x00, 0xfa, 0x01, 0x00, 0xf0, 0x01, 0x40, 0x00,
+   0x00, 0xf4, 0x81, 0xff, 0x03, 0x00, 0x20, 0x00, 0x00, 0xc8, 0xfc, 0xff,
+   0x1f, 0x00, 0x10, 0x00, 0x00, 0x10, 0xfe, 0xff, 0x7f, 0x00, 0x08, 0x00,
+   0x00, 0x60, 0xfe, 0xff, 0x7f, 0x00, 0x06, 0x00, 0x00, 0x80, 0xfc, 0xff,
+   0x7f, 0x00, 0x01, 0x00, 0x00, 0x00, 0xf3, 0xff, 0x7f, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x8c, 0xff, 0x7f, 0x30, 0x00, 0x00, 0x00, 0x00, 0x70, 0xf8,
+   0x1f, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07, 0xe0, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bounce-2.xbm b/xlockmore-4.14/bitmaps/bounce-2.xbm
new file mode 100644 (file)
index 0000000..9af0c72
--- /dev/null
@@ -0,0 +1,46 @@
+#define bounce2_width 64
+#define bounce2_height 64
+static unsigned char bounce2_bits[] = {
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07,
+   0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x0e, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x73, 0x00,
+   0x00, 0xce, 0x00, 0x00, 0x00, 0x80, 0xfc, 0x00, 0x00, 0x3f, 0x01, 0x00,
+   0x00, 0x60, 0xff, 0x00, 0x00, 0xff, 0x06, 0x00, 0x00, 0x90, 0xff, 0x01,
+   0x80, 0xff, 0x09, 0x00, 0x00, 0xc8, 0xff, 0xfc, 0x3f, 0xff, 0x13, 0x00,
+   0x00, 0xf4, 0x7f, 0xfe, 0x7f, 0xfe, 0x2f, 0x00, 0x00, 0xfa, 0x7f, 0xfe,
+   0x7f, 0xfe, 0x5f, 0x00, 0x00, 0xfd, 0x3f, 0xff, 0xff, 0xfc, 0xbf, 0x00,
+   0x80, 0xfe, 0x9f, 0xff, 0xff, 0xf9, 0x7f, 0x01, 0x40, 0xfe, 0xcf, 0xff,
+   0xff, 0xf3, 0x7f, 0x02, 0x40, 0xff, 0xcf, 0xff, 0xff, 0xf3, 0xff, 0x02,
+   0x20, 0xff, 0x81, 0xff, 0xff, 0x81, 0xff, 0x04, 0x10, 0x3e, 0x80, 0xff,
+   0xff, 0x01, 0x7c, 0x08, 0xd0, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, 0x0b,
+   0xe8, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x80, 0x17, 0xe8, 0x01, 0x00, 0xfc,
+   0x3f, 0x00, 0x80, 0x17, 0xf4, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x2f,
+   0xf4, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x2f, 0xf4, 0x01, 0x00, 0xfe,
+   0x7f, 0x00, 0x80, 0x2f, 0xfa, 0x03, 0x00, 0xfe, 0x7f, 0x00, 0xc0, 0x5f,
+   0xfa, 0x03, 0x00, 0xff, 0xff, 0x00, 0xc0, 0x5f, 0xfa, 0x03, 0x00, 0xff,
+   0xff, 0x00, 0xc0, 0x5f, 0xfa, 0x03, 0x80, 0xff, 0xff, 0x01, 0xc0, 0x5f,
+   0xfd, 0x03, 0x80, 0xff, 0xff, 0x01, 0xc0, 0xbf, 0xfd, 0x03, 0x80, 0xff,
+   0xff, 0x01, 0xc0, 0xbf, 0xfd, 0x03, 0xc0, 0xff, 0xff, 0x03, 0xc0, 0xbf,
+   0xfd, 0x03, 0xc0, 0xff, 0xff, 0x03, 0xc0, 0xbf, 0xfd, 0x03, 0xc0, 0xff,
+   0xff, 0x03, 0xc0, 0xbf, 0xfd, 0xfb, 0x9f, 0xff, 0xff, 0xf9, 0xdf, 0xbf,
+   0xfd, 0xfb, 0x9f, 0xff, 0xff, 0xf9, 0xdf, 0xbf, 0xfd, 0xf9, 0xbf, 0xff,
+   0xff, 0xfd, 0x9f, 0xbf, 0xfd, 0xf9, 0x3f, 0xff, 0xff, 0xfc, 0x9f, 0xbf,
+   0xfd, 0xfd, 0x7f, 0xff, 0xff, 0xfe, 0xbf, 0xbf, 0xfa, 0xfc, 0x7f, 0xfe,
+   0x7f, 0xfe, 0x3f, 0x5f, 0xfa, 0xfc, 0xff, 0xfe, 0x7f, 0xff, 0x3f, 0x5f,
+   0x02, 0xfc, 0xff, 0xfc, 0x3f, 0xff, 0x3f, 0x40, 0x02, 0xfc, 0xff, 0xf9,
+   0x9f, 0xff, 0x3f, 0x40, 0x04, 0xf8, 0xff, 0x03, 0xc0, 0xff, 0x1f, 0x20,
+   0x04, 0xf8, 0xff, 0x03, 0xc0, 0xff, 0x1f, 0x20, 0x04, 0xf0, 0xff, 0x01,
+   0x80, 0xff, 0x0f, 0x20, 0x08, 0xf0, 0xff, 0x01, 0x80, 0xff, 0x0f, 0x10,
+   0x08, 0xe0, 0xff, 0x00, 0x00, 0xff, 0x07, 0x10, 0x10, 0xe0, 0xff, 0x00,
+   0x00, 0xff, 0x07, 0x08, 0x10, 0xc0, 0xff, 0x00, 0x00, 0xff, 0x03, 0x08,
+   0x20, 0x80, 0x7f, 0x00, 0x00, 0xfe, 0x01, 0x04, 0x40, 0x00, 0x78, 0x00,
+   0x00, 0x1e, 0x00, 0x02, 0x40, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x02,
+   0x80, 0xc0, 0x1f, 0x00, 0x00, 0xf8, 0x03, 0x01, 0x00, 0xe1, 0x7f, 0x00,
+   0x00, 0xfe, 0x87, 0x00, 0x00, 0xf2, 0xff, 0x01, 0x80, 0xff, 0x4f, 0x00,
+   0x00, 0xe4, 0xff, 0x03, 0xc0, 0xff, 0x27, 0x00, 0x00, 0xc8, 0xff, 0x07,
+   0xe0, 0xff, 0x13, 0x00, 0x00, 0x90, 0xff, 0x1f, 0xf8, 0xff, 0x09, 0x00,
+   0x00, 0x60, 0xff, 0x3f, 0xfc, 0xff, 0x06, 0x00, 0x00, 0x80, 0xfc, 0x7f,
+   0xfe, 0x3f, 0x01, 0x00, 0x00, 0x00, 0xf3, 0x7f, 0xfe, 0xcf, 0x00, 0x00,
+   0x00, 0x00, 0x8c, 0x7f, 0xfe, 0x31, 0x00, 0x00, 0x00, 0x00, 0x70, 0x78,
+   0x1e, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07, 0xe0, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bounce-3.xbm b/xlockmore-4.14/bitmaps/bounce-3.xbm
new file mode 100644 (file)
index 0000000..59c0c7a
--- /dev/null
@@ -0,0 +1,46 @@
+#define bounce3_width 64
+#define bounce3_height 64
+static unsigned char bounce3_bits[] = {
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07,
+   0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x70, 0xf8, 0x1f, 0x0e, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0xfe, 0xff, 0x31, 0x00, 0x00, 0x00, 0x00, 0x03, 0xfe,
+   0xff, 0xcf, 0x00, 0x00, 0x00, 0x80, 0x00, 0xfe, 0xff, 0x3f, 0x01, 0x00,
+   0x00, 0x60, 0x00, 0xfe, 0xff, 0x7f, 0x06, 0x00, 0x00, 0x10, 0x00, 0xfe,
+   0xff, 0x7f, 0x08, 0x00, 0x00, 0x08, 0x00, 0xf8, 0xff, 0x3f, 0x13, 0x00,
+   0x00, 0x04, 0x00, 0xc0, 0xff, 0x81, 0x2f, 0x00, 0x00, 0x02, 0x80, 0x0f,
+   0x00, 0x80, 0x5f, 0x00, 0x00, 0x01, 0xe0, 0xff, 0x00, 0x80, 0xbf, 0x00,
+   0x80, 0x04, 0xf8, 0xff, 0x00, 0x80, 0x7f, 0x01, 0x40, 0x0e, 0xfe, 0xff,
+   0x00, 0x80, 0x7f, 0x02, 0x40, 0x1f, 0xff, 0xff, 0x00, 0x00, 0xff, 0x02,
+   0xa0, 0xbf, 0xff, 0xff, 0x00, 0x00, 0xff, 0x05, 0xd0, 0xbf, 0xff, 0xff,
+   0x00, 0x00, 0xff, 0x0b, 0xd0, 0x9f, 0xff, 0xff, 0x00, 0x00, 0xfe, 0x0b,
+   0xe8, 0x9f, 0xff, 0xff, 0x00, 0x00, 0xfe, 0x17, 0xe8, 0xdf, 0xff, 0xff,
+   0x00, 0x00, 0xfe, 0x17, 0xf4, 0xdf, 0xff, 0xff, 0x00, 0x00, 0xf8, 0x2f,
+   0xf4, 0xcf, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0x2f, 0xf4, 0xcf, 0xff, 0x0f,
+   0x07, 0x00, 0xe6, 0x2f, 0xfa, 0x07, 0xff, 0xe3, 0x3f, 0x80, 0x8f, 0x47,
+   0xfa, 0x07, 0xf8, 0xf8, 0xff, 0xc0, 0x1f, 0x41, 0xfa, 0x03, 0x60, 0xfe,
+   0xff, 0xe3, 0x7f, 0x40, 0xfa, 0x01, 0x00, 0xff, 0xff, 0xf3, 0xff, 0x40,
+   0xfd, 0x00, 0x80, 0xff, 0xff, 0xf3, 0xff, 0x80, 0xfd, 0x00, 0x80, 0xff,
+   0xff, 0xf3, 0xff, 0x80, 0x7d, 0x00, 0x80, 0xff, 0xff, 0xf3, 0xff, 0x80,
+   0x3d, 0x00, 0x80, 0xff, 0xff, 0xf3, 0xff, 0x80, 0x01, 0x00, 0x80, 0xff,
+   0xff, 0xf3, 0xff, 0x80, 0x01, 0x00, 0x80, 0xff, 0xff, 0xf3, 0xff, 0x80,
+   0x3d, 0x00, 0x80, 0xff, 0xff, 0xf3, 0xff, 0x80, 0x7d, 0x00, 0x80, 0xff,
+   0xff, 0xf3, 0xff, 0x80, 0xfd, 0x00, 0x80, 0xff, 0xff, 0xf3, 0xff, 0x80,
+   0xfd, 0x00, 0x80, 0xff, 0xff, 0xf3, 0xff, 0x80, 0xfa, 0x01, 0x00, 0xff,
+   0xff, 0xf3, 0xff, 0x40, 0xfa, 0x03, 0x60, 0xfe, 0xff, 0xe3, 0x7f, 0x40,
+   0xfa, 0x07, 0xf8, 0xf8, 0xff, 0xc0, 0x1f, 0x41, 0xfa, 0x07, 0xff, 0xe3,
+   0x3f, 0x80, 0x8f, 0x47, 0xf4, 0xcf, 0xff, 0x0f, 0x07, 0x00, 0xe6, 0x2f,
+   0xf4, 0xcf, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0x2f, 0xf4, 0xdf, 0xff, 0xff,
+   0x00, 0x00, 0xf8, 0x2f, 0xe8, 0xdf, 0xff, 0xff, 0x00, 0x00, 0xfe, 0x17,
+   0xe8, 0x9f, 0xff, 0xff, 0x00, 0x00, 0xfe, 0x17, 0xd0, 0x9f, 0xff, 0xff,
+   0x00, 0x00, 0xfe, 0x0b, 0xd0, 0xbf, 0xff, 0xff, 0x00, 0x00, 0xff, 0x0b,
+   0xa0, 0xbf, 0xff, 0xff, 0x00, 0x00, 0xff, 0x05, 0x40, 0x1f, 0xff, 0xff,
+   0x00, 0x00, 0xff, 0x02, 0x40, 0x0e, 0xfe, 0xff, 0x00, 0x80, 0x7f, 0x02,
+   0x80, 0x04, 0xf8, 0xff, 0x00, 0x80, 0x7f, 0x01, 0x00, 0x01, 0xe0, 0xff,
+   0x00, 0x80, 0xbf, 0x00, 0x00, 0x02, 0x80, 0x0f, 0x00, 0x80, 0x5f, 0x00,
+   0x00, 0x04, 0x00, 0xc0, 0xff, 0x81, 0x2f, 0x00, 0x00, 0x08, 0x00, 0xf8,
+   0xff, 0x3f, 0x13, 0x00, 0x00, 0x10, 0x00, 0xfe, 0xff, 0x7f, 0x08, 0x00,
+   0x00, 0x60, 0x00, 0xfe, 0xff, 0x7f, 0x06, 0x00, 0x00, 0x80, 0x00, 0xfe,
+   0xff, 0x3f, 0x01, 0x00, 0x00, 0x00, 0x03, 0xfe, 0xff, 0xcf, 0x00, 0x00,
+   0x00, 0x00, 0x0c, 0xfe, 0xff, 0x31, 0x00, 0x00, 0x00, 0x00, 0x70, 0xf8,
+   0x1f, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07, 0xe0, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/bounce-mask.xbm b/xlockmore-4.14/bitmaps/bounce-mask.xbm
new file mode 100644 (file)
index 0000000..73996f0
--- /dev/null
@@ -0,0 +1,46 @@
+#define bouncemask_width 64
+#define bouncemask_height 64
+static unsigned char bouncemask_bits[] = {
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff,
+   0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00,
+   0x00, 0x00, 0xfc, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff,
+   0xff, 0xff, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00,
+   0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0xf0, 0xff, 0xff,
+   0xff, 0xff, 0x0f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00,
+   0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xfe, 0xff, 0xff,
+   0xff, 0xff, 0x7f, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00,
+   0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x0f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f,
+   0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f,
+   0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfc, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f,
+   0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfc, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f,
+   0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x0f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f,
+   0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xc0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00,
+   0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf8, 0xff, 0xff,
+   0xff, 0xff, 0x1f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00,
+   0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x80, 0xff, 0xff,
+   0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00,
+   0x00, 0x00, 0xfc, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/cooperat.xbm b/xlockmore-4.14/bitmaps/cooperat.xbm
new file mode 100644 (file)
index 0000000..6f15e15
--- /dev/null
@@ -0,0 +1,9 @@
+#define cooperat_width 21
+#define cooperat_height 21
+static unsigned char cooperat_bits[] = {
+   0x80, 0x1f, 0x00, 0x60, 0x60, 0x00, 0x10, 0x80, 0x00, 0x08, 0x00, 0x01,
+   0x04, 0x00, 0x02, 0xc2, 0x30, 0x04, 0xc2, 0x30, 0x04, 0x01, 0x00, 0x08,
+   0x01, 0x00, 0x08, 0x01, 0x00, 0x08, 0x21, 0x40, 0x08, 0x21, 0x40, 0x08,
+   0x41, 0x20, 0x08, 0x82, 0x10, 0x04, 0x02, 0x0f, 0x04, 0x04, 0x00, 0x02,
+   0x08, 0x00, 0x01, 0x10, 0x80, 0x00, 0x60, 0x60, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/cross_weave.xbm b/xlockmore-4.14/bitmaps/cross_weave.xbm
new file mode 100644 (file)
index 0000000..45ffbb4
--- /dev/null
@@ -0,0 +1,6 @@
+#define cross_weave_width 16
+#define cross_weave_height 16
+static unsigned char cross_weave_bits[] = {
+   0x55, 0x55, 0x88, 0x88, 0x55, 0x55, 0x22, 0x22, 0x55, 0x55, 0x88, 0x88,
+   0x55, 0x55, 0x22, 0x22, 0x55, 0x55, 0x88, 0x88, 0x55, 0x55, 0x22, 0x22,
+   0x55, 0x55, 0x88, 0x88, 0x55, 0x55, 0x22, 0x22};
diff --git a/xlockmore-4.14/bitmaps/defect.xbm b/xlockmore-4.14/bitmaps/defect.xbm
new file mode 100644 (file)
index 0000000..3456772
--- /dev/null
@@ -0,0 +1,9 @@
+#define defect_width 21
+#define defect_height 21
+static unsigned char defect_bits[] = {
+   0x80, 0x1f, 0x00, 0x60, 0x60, 0x00, 0x10, 0x80, 0x00, 0x08, 0x00, 0x01,
+   0x04, 0x00, 0x02, 0x82, 0x10, 0x04, 0x42, 0x29, 0x04, 0x81, 0x10, 0x08,
+   0x01, 0x00, 0x08, 0x01, 0x00, 0x08, 0x01, 0x00, 0x08, 0x01, 0x00, 0x08,
+   0xe1, 0x7f, 0x08, 0xe2, 0x7f, 0x04, 0x02, 0x00, 0x04, 0x04, 0x00, 0x02,
+   0x08, 0x00, 0x01, 0x10, 0x80, 0x00, 0x60, 0x60, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/dimple1.xbm b/xlockmore-4.14/bitmaps/dimple1.xbm
new file mode 100644 (file)
index 0000000..c1a36e5
--- /dev/null
@@ -0,0 +1,6 @@
+#define dimple1_width 16
+#define dimple1_height 16
+static unsigned char dimple1_bits[] = {
+   0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00,
+   0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00,
+   0x55, 0x55, 0x00, 0x00, 0x55, 0x55, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/dimple3.xbm b/xlockmore-4.14/bitmaps/dimple3.xbm
new file mode 100644 (file)
index 0000000..25eb294
--- /dev/null
@@ -0,0 +1,6 @@
+#define dimple3_width 16
+#define dimple3_height 16
+static unsigned char dimple3_bits[] = {
+   0x11, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x11, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x11, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x11, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/donkey.xbm b/xlockmore-4.14/bitmaps/donkey.xbm
new file mode 100644 (file)
index 0000000..d2d40a6
--- /dev/null
@@ -0,0 +1,9 @@
+#define donkey_width 21
+#define donkey_height 21
+static unsigned char donkey_bits[] = {
+   0x44, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x6c, 0x00, 0x00,
+   0x28, 0x00, 0x00, 0x38, 0x00, 0x00, 0x74, 0x00, 0x00, 0xfe, 0x00, 0x00,
+   0xef, 0xff, 0x00, 0xc2, 0xff, 0x01, 0xc0, 0xff, 0x01, 0x80, 0xff, 0x02,
+   0x80, 0xff, 0x02, 0x80, 0xa2, 0x04, 0x80, 0x42, 0x05, 0x80, 0x42, 0x01,
+   0x80, 0xa2, 0x00, 0x80, 0xa2, 0x00, 0x80, 0xa2, 0x00, 0x80, 0x20, 0x00,
+   0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/elephant.xbm b/xlockmore-4.14/bitmaps/elephant.xbm
new file mode 100644 (file)
index 0000000..8f93397
--- /dev/null
@@ -0,0 +1,8 @@
+#define elephant_width 20
+#define elephant_height 20
+static unsigned char elephant_bits[] = {
+ 0xc0,0x07,0x00,0xc0,0x19,0x00,0xe0,0x76,0x00,0xe0,0xf6,0x00,0xf0,0xf7,0x01,
+ 0xf8,0xf7,0x03,0xd8,0xf7,0x07,0xfa,0xf7,0x07,0x7d,0xfb,0x07,0xfb,0xfc,0x0f,
+ 0xfe,0xff,0x0f,0xfc,0xff,0x0f,0xfe,0xff,0x0f,0xf6,0xff,0x0f,0xf2,0xff,0x06,
+ 0x72,0xe3,0x06,0x73,0xe3,0x06,0x71,0xe3,0x06,0x71,0xe3,0x06,0x70,0xe0,0x00
+ };
diff --git a/xlockmore-4.14/bitmaps/fish-0.xbm b/xlockmore-4.14/bitmaps/fish-0.xbm
new file mode 100644 (file)
index 0000000..a2bc1ed
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish0_width 20
+#define fish0_height 20
+static unsigned char fish0_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x80, 0x1f, 0x00, 0xc0, 0x3f, 0x00, 0x40, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x38, 0x00,
+   0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/fish-1.xbm b/xlockmore-4.14/bitmaps/fish-1.xbm
new file mode 100644 (file)
index 0000000..82f1818
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish1_width 20
+#define fish1_height 20
+static unsigned char fish1_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00,
+   0x80, 0x1f, 0x00, 0xc0, 0x7f, 0x00, 0xe0, 0x7f, 0x00, 0xb8, 0x1f, 0x00,
+   0x10, 0x06, 0x00, 0x10, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/fish-2.xbm b/xlockmore-4.14/bitmaps/fish-2.xbm
new file mode 100644 (file)
index 0000000..766845f
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish2_width 20
+#define fish2_height 20
+static unsigned char fish2_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
+   0xc0, 0x01, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x2f, 0x00, 0xc0, 0x3f, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/fish-3.xbm b/xlockmore-4.14/bitmaps/fish-3.xbm
new file mode 100644 (file)
index 0000000..15f1f00
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish3_width 20
+#define fish3_height 20
+static unsigned char fish3_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x86, 0x00,
+   0x80, 0xdf, 0x01, 0xe0, 0x7f, 0x00, 0xe0, 0x3f, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x06, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/fish-4.xbm b/xlockmore-4.14/bitmaps/fish-4.xbm
new file mode 100644 (file)
index 0000000..80405d8
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish4_width 20
+#define fish4_height 20
+static unsigned char fish4_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x80, 0x1f, 0x00, 0xc0, 0x3f, 0x00, 0x00, 0x2f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x01, 0x00,
+   0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/fish-5.xbm b/xlockmore-4.14/bitmaps/fish-5.xbm
new file mode 100644 (file)
index 0000000..580a265
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish5_width 20
+#define fish5_height 20
+static unsigned char fish5_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x02, 0x00, 0x10, 0x06, 0x00,
+   0xb8, 0x1f, 0x00, 0xe0, 0x7f, 0x00, 0xc0, 0x7f, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/fish-6.xbm b/xlockmore-4.14/bitmaps/fish-6.xbm
new file mode 100644 (file)
index 0000000..27057fc
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish6_width 20
+#define fish6_height 20
+static unsigned char fish6_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00,
+   0x00, 0x38, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00,
+   0x40, 0x0f, 0x00, 0xc0, 0x3f, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/fish-7.xbm b/xlockmore-4.14/bitmaps/fish-7.xbm
new file mode 100644 (file)
index 0000000..38671d0
--- /dev/null
@@ -0,0 +1,8 @@
+#define fish7_width 20
+#define fish7_height 20
+static unsigned char fish7_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x06, 0x00,
+   0x80, 0x1f, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0x7f, 0x00, 0x80, 0xdf, 0x01,
+   0x00, 0x86, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/flipped_gray.xbm b/xlockmore-4.14/bitmaps/flipped_gray.xbm
new file mode 100644 (file)
index 0000000..b24f5db
--- /dev/null
@@ -0,0 +1,4 @@
+#define flipped_gray_width 4
+#define flipped_gray_height 2
+static unsigned char flipped_gray_bits[] = {
+   0x07, 0x0d};
diff --git a/xlockmore-4.14/bitmaps/good.xbm b/xlockmore-4.14/bitmaps/good.xbm
new file mode 100644 (file)
index 0000000..60dabc5
--- /dev/null
@@ -0,0 +1,9 @@
+#define good_width 21
+#define good_height 21
+static unsigned char good_bits[] = {
+   0x80, 0x1f, 0x00, 0x60, 0x60, 0x00, 0x10, 0x80, 0x00, 0x08, 0x00, 0x01,
+   0x04, 0x00, 0x02, 0xc2, 0x30, 0x04, 0xc2, 0x30, 0x04, 0x01, 0x00, 0x08,
+   0x01, 0x00, 0x08, 0x01, 0x00, 0x08, 0x21, 0x40, 0x08, 0x21, 0x40, 0x08,
+   0x41, 0x20, 0x08, 0x82, 0x10, 0x04, 0x02, 0x0f, 0x04, 0x04, 0x00, 0x02,
+   0x08, 0x00, 0x01, 0x10, 0x80, 0x00, 0x60, 0x60, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/gray1.xbm b/xlockmore-4.14/bitmaps/gray1.xbm
new file mode 100644 (file)
index 0000000..186ea22
--- /dev/null
@@ -0,0 +1,4 @@
+#define gray1_width 2
+#define gray1_height 2
+static unsigned char gray1_bits[] = {
+   0x01, 0x02};
diff --git a/xlockmore-4.14/bitmaps/gray3.xbm b/xlockmore-4.14/bitmaps/gray3.xbm
new file mode 100644 (file)
index 0000000..0356c8d
--- /dev/null
@@ -0,0 +1,4 @@
+#define gray3_width 4
+#define gray3_height 4
+static unsigned char gray3_bits[] = {
+   0x01, 0x00, 0x04, 0x00};
diff --git a/xlockmore-4.14/bitmaps/hlines2.xbm b/xlockmore-4.14/bitmaps/hlines2.xbm
new file mode 100644 (file)
index 0000000..6b7e18e
--- /dev/null
@@ -0,0 +1,4 @@
+#define hlines2_width 1
+#define hlines2_height 2
+static unsigned char hlines2_bits[] = {
+   0x01, 0x00};
diff --git a/xlockmore-4.14/bitmaps/l-bob.xbm b/xlockmore-4.14/bitmaps/l-bob.xbm
new file mode 100644 (file)
index 0000000..ceea6da
--- /dev/null
@@ -0,0 +1,364 @@
+#define image_width 172
+#define image_height 246
+static unsigned char image_bits[] = {
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3a,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xa0,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0x07,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x07,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xdf,0xff,0xf3,0xff,0x1f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,
+ 0x00,0x00,0xfe,0xff,0xff,0xff,0xdf,0xff,0xff,0x9f,0xff,0xe3,0xff,0x3f,0x00,
+ 0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x9f,0xff,
+ 0xff,0x3f,0xff,0xc7,0xff,0x3f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,
+ 0x80,0xff,0xff,0xff,0xff,0x1f,0xf2,0x7f,0x7f,0xfe,0xc3,0xff,0x7f,0x00,0x00,
+ 0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0xff,0x3f,0xc0,0x7f,
+ 0x7e,0xfc,0xc1,0xff,0xff,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xe0,
+ 0xff,0xff,0xff,0xcf,0x7f,0x00,0xff,0x7c,0xfc,0xc1,0xff,0xff,0x01,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x0f,0xff,0x00,0xff,0x78,
+ 0xf0,0xc1,0xff,0xff,0x03,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0xff,
+ 0xff,0xfc,0x1f,0xfe,0x00,0xff,0x30,0xe0,0x81,0xff,0xff,0x03,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0x00,0xfc,0xff,0x7f,0x38,0x1f,0xfc,0x01,0xfe,0x01,0xe0,
+ 0x83,0xff,0xf9,0x07,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xff,0xff,0x3f,
+ 0x38,0x1e,0xf8,0x01,0xfc,0x01,0xe0,0x87,0xff,0xfb,0x07,0x00,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x80,0xff,0xff,0x7f,0x00,0x3c,0xf0,0x01,0xf8,0x01,0xe0,0x8f,
+ 0xff,0xf3,0x07,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0xc0,0xff,0xff,0x7f,0x00,
+ 0x3c,0xf0,0x03,0xf8,0x01,0xc0,0xff,0xff,0xf3,0x0f,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0x00,0xc0,0xff,0xff,0xff,0x00,0x7c,0xe0,0x03,0xf0,0x01,0xc0,0xff,0xff,
+ 0xf3,0x3f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0x81,0x7f,
+ 0xe0,0x03,0xf0,0x03,0xc0,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0x00,0xe0,0xff,0xff,0xff,0x83,0xff,0xe0,0x03,0xe0,0x03,0xc0,0xff,0xff,0xff,
+ 0xff,0x01,0x00,0x00,0xf0,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0x97,0xff,0xc0,
+ 0x07,0xe0,0x03,0x80,0xff,0xff,0xff,0xff,0x03,0x00,0x00,0xf0,0x00,0x00,0x00,
+ 0xf0,0xff,0xff,0xff,0xff,0xff,0xc1,0x07,0xc0,0x07,0x80,0xff,0xff,0xff,0xff,
+ 0x07,0x00,0x00,0xf0,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xc1,0x07,
+ 0xc0,0x03,0x80,0xff,0xff,0xff,0xff,0x1f,0x00,0x00,0xf0,0x00,0x00,0x00,0xf8,
+ 0xff,0xff,0xff,0xff,0xff,0x83,0x0f,0xc0,0x07,0xc0,0xff,0xff,0xff,0xff,0x3f,
+ 0x00,0x00,0xf0,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0xff,0xff,0xc7,0x0f,0xc0,
+ 0x1f,0xe0,0xff,0xff,0xff,0xff,0x7f,0x00,0x00,0xf0,0x00,0x00,0x00,0xfe,0xff,
+ 0xff,0xff,0xff,0xff,0xcf,0x1f,0xc0,0x7f,0xfc,0xff,0xff,0xff,0xff,0xff,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x1f,0xc0,0x7f,
+ 0xfe,0xff,0xff,0xff,0xff,0xff,0x00,0x00,0xf0,0x00,0x00,0x00,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0xc3,0x7f,0xfe,0xff,0xff,0xff,0xff,0xff,0x01,0x00,
+ 0xf0,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xc7,0x7f,0xfe,
+ 0xff,0xff,0xff,0xff,0xff,0x03,0x00,0xf0,0x00,0x00,0x80,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0x7f,0xfe,0xff,0xff,0xff,0xff,0xff,0x07,0x00,0xf0,
+ 0x00,0x00,0x80,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f,0xfe,0xff,
+ 0xff,0xff,0xff,0xff,0x0f,0x00,0xf0,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0x7f,0xfe,0xff,0xff,0x0f,0xff,0xff,0x1f,0x00,0xf0,0x00,
+ 0x00,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x3f,0xfe,0xff,0xff,
+ 0x07,0xff,0xff,0x1f,0x00,0xf0,0x00,0x00,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0x3f,0xff,0xff,0xbf,0x00,0xff,0xff,0x1f,0x00,0xf0,0x00,0x00,
+ 0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x3f,0xff,0xff,0x0f,0x00,
+ 0xff,0xff,0x1f,0x00,0xf0,0x00,0x00,0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0x03,0x00,0xfe,0xff,0x3f,0x00,0xf0,0x00,0x00,0xe0,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0x00,0xfe,
+ 0xff,0x3f,0x00,0xf0,0x00,0x00,0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0x1f,0x00,0x00,0xfe,0xff,0x3f,0x00,0xf0,0x00,0x00,0xf0,0xff,
+ 0xff,0xff,0xf8,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0x00,0x00,0xfc,0xff,
+ 0x3f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0x7f,0xf0,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0x0f,0x00,0x00,0x00,0xfc,0xff,0x3f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,
+ 0x7f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0xf8,0xff,0x3f,
+ 0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0x03,0xf0,0xff,0xff,0xff,0xff,0xff,0x7f,
+ 0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0x03,
+ 0xe0,0xff,0xff,0xe7,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0xf8,0xff,0x7f,0x00,
+ 0xf0,0x00,0x00,0xf0,0xff,0xff,0x01,0x00,0x00,0x80,0xc3,0xff,0xff,0x01,0x00,
+ 0x00,0x00,0x00,0xf8,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x01,0x00,
+ 0x00,0x00,0x00,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f,0x00,0xf0,
+ 0x00,0x00,0xf8,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0xf8,0x07,0x00,0x00,0x00,
+ 0x00,0x00,0xf0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f,0x00,0xf0,0x00,
+ 0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xe0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x07,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0x7f,0x00,0xf0,0x00,0x00,
+ 0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xc0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,
+ 0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,
+ 0xff,0xff,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,
+ 0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,
+ 0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,
+ 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0x7f,
+ 0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x80,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0x7f,0x00,
+ 0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x80,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0x7f,0x00,0xf0,
+ 0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xc0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0xc0,0xff,0x7f,0x00,0xf0,0x00,
+ 0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x70,0xc0,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xc0,0xff,0x7f,0x00,0xf0,0x00,0x00,
+ 0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,
+ 0xc1,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x03,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xc1,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,
+ 0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xc1,
+ 0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0xf8,0xc1,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,
+ 0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xc1,0xff,
+ 0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf8,0xc1,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,
+ 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xc1,0xff,0x7f,
+ 0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0xf0,0xc1,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0x03,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xc1,0xff,0x7f,0x00,
+ 0xf0,0x00,0x00,0xf0,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xf0,0xc1,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0x03,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xc1,0xff,0x7f,0x00,0xf0,
+ 0x00,0x00,0xf0,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xe0,0xc3,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0x03,0x40,0x91,
+ 0x00,0x00,0x00,0x00,0x00,0x80,0xff,0x00,0xe0,0xc3,0xff,0x7f,0x00,0xf0,0x00,
+ 0x00,0xf0,0xff,0xff,0x03,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0xf0,0xff,0x0f,
+ 0xe0,0xc3,0xff,0x7f,0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0xc3,0xff,0xff,0x0f,
+ 0x00,0x00,0x00,0x00,0xf8,0xff,0xff,0xf3,0xc3,0xff,0x7f,0x00,0xf0,0x00,0x00,
+ 0xfc,0xff,0xff,0xe3,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xf7,
+ 0x83,0xff,0xff,0x00,0xf0,0x00,0x00,0xfc,0xff,0xff,0xf3,0xff,0xff,0x7f,0x00,
+ 0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x83,0xff,0xff,0x00,0xf0,0x00,0x00,0xfc,
+ 0xff,0xff,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x03,
+ 0xff,0xff,0x00,0xf0,0x00,0x00,0xfc,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0x00,
+ 0x00,0x80,0xff,0xff,0xff,0xff,0x07,0xff,0xff,0x00,0xf0,0x00,0x00,0xfc,0xff,
+ 0xff,0xff,0x01,0xfc,0xff,0x01,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0x07,0xff,
+ 0xff,0x00,0xf0,0x00,0x00,0xfc,0xff,0xff,0x5f,0x00,0xf8,0xff,0x03,0x00,0x00,
+ 0xc0,0xff,0x3f,0x00,0xff,0x0f,0xff,0xff,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,
+ 0x1f,0x00,0xe0,0xff,0x07,0x00,0x00,0xe0,0xff,0x03,0x00,0xfc,0x0f,0xfe,0x7f,
+ 0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x1f,0x00,0xc0,0xff,0x0f,0x00,0x00,0xf0,
+ 0xff,0x00,0x00,0xf0,0x0f,0xfe,0x7f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0x1f,
+ 0xf0,0xff,0xff,0x1f,0x00,0x00,0xf8,0xff,0x23,0x00,0xe0,0x1f,0xfe,0x3f,0x00,
+ 0xf0,0x00,0x00,0xf8,0xff,0xff,0x1f,0xfe,0xff,0xff,0x3f,0x00,0x00,0xfc,0xff,
+ 0xff,0x07,0xe0,0x1f,0xfe,0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0x7f,0x00,0x00,0xfe,0xff,0xff,0x3f,0xc0,0x1f,0xfe,0x3f,0x00,0xf0,
+ 0x00,0x00,0xf8,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0x00,0xff,0xff,0xff,
+ 0x7f,0xc0,0x1f,0xfe,0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,0x3f,0xfe,0xff,0xff,
+ 0xff,0xff,0x01,0x80,0xff,0xff,0xff,0xff,0x81,0x1f,0xfc,0x3f,0x00,0xf0,0x00,
+ 0x00,0xf8,0xff,0x3f,0xfc,0xff,0xff,0xff,0xff,0x01,0xc0,0xff,0xff,0xff,0xff,
+ 0x83,0x1f,0xfc,0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,0x1f,0xf8,0xff,0xff,0xff,
+ 0xff,0x01,0xe0,0xff,0xff,0xff,0xff,0x83,0x1f,0xfc,0x3f,0x00,0xf0,0x00,0x00,
+ 0xf8,0xff,0x1f,0xf8,0xf7,0xff,0xf9,0xff,0x01,0xe0,0xff,0xff,0xff,0xfb,0x03,
+ 0x1f,0xfc,0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,0x0f,0xf8,0xc1,0xff,0xe0,0xff,
+ 0x03,0xf0,0xff,0x83,0xff,0xe1,0x07,0x1e,0xfe,0x3f,0x00,0xf0,0x00,0x00,0xf8,
+ 0xff,0x0f,0xf8,0xc1,0xff,0xe0,0xff,0x03,0xf0,0xff,0x83,0xff,0xe1,0x07,0x1e,
+ 0xfe,0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,0x0f,0xf8,0xc0,0xff,0xe0,0xff,0x03,
+ 0xe0,0xff,0x81,0xff,0xe1,0x07,0x1f,0xfe,0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,
+ 0x0f,0xf8,0xc0,0xff,0xe0,0xff,0x03,0xc0,0xff,0x80,0xff,0xe1,0x03,0x1e,0xfe,
+ 0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,0x1f,0x70,0xc0,0x7f,0xf0,0xff,0x03,0x00,
+ 0x00,0x80,0xff,0xe1,0x01,0x1e,0xfe,0x3f,0x00,0xf0,0x00,0x00,0xf8,0xff,0x1f,
+ 0x20,0x00,0x07,0xf8,0xff,0x03,0x00,0x00,0xf8,0xff,0xc0,0x00,0x1e,0xfe,0x1f,
+ 0x00,0xf0,0x00,0x00,0xf8,0xff,0x0f,0x00,0x00,0x00,0xfe,0xff,0x03,0x00,0x00,
+ 0xfe,0x07,0x00,0x00,0x1e,0xfe,0x1f,0x00,0xf0,0x00,0x00,0xf8,0xff,0x0f,0x00,
+ 0x00,0x80,0xff,0xfc,0x03,0x00,0x00,0xfe,0x03,0x00,0x00,0x1e,0xfe,0x1f,0x00,
+ 0xf0,0x00,0x00,0xf8,0xbf,0x0f,0x00,0x00,0xe0,0xff,0xfc,0x03,0x00,0x00,0xfe,
+ 0x03,0x00,0x00,0x08,0xfe,0x1f,0x00,0xf0,0x00,0x00,0xf0,0xbf,0x0f,0x00,0x00,
+ 0xf8,0x7f,0xfc,0x03,0x00,0x00,0xfc,0x0f,0x00,0x00,0x00,0xfe,0x1f,0x00,0xf0,
+ 0x00,0x00,0xf0,0x3f,0x0f,0x00,0xfc,0xff,0x3f,0xf8,0x03,0x00,0x00,0xf8,0xff,
+ 0x00,0x00,0x00,0xfe,0x0f,0x00,0xf0,0x00,0x00,0xf0,0x3f,0x0e,0x00,0xfc,0xff,
+ 0x0f,0xf8,0x01,0x00,0x00,0xf0,0xff,0x01,0x00,0x00,0xfe,0x1f,0x00,0xf0,0x00,
+ 0x00,0xf0,0x3f,0x0f,0x00,0xfc,0xff,0x07,0xf8,0x01,0x00,0x00,0xc0,0xff,0x01,
+ 0x00,0x00,0xfe,0x0f,0x00,0xf0,0x00,0x00,0xf0,0x7f,0x06,0x00,0xfc,0xff,0x01,
+ 0xf8,0x01,0x00,0x00,0x00,0xfe,0x00,0x00,0x00,0xfe,0x0f,0x00,0xf0,0x00,0x00,
+ 0xf0,0x7f,0x06,0x00,0xe0,0x3f,0x00,0xf8,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xfe,0x0f,0x00,0xf0,0x00,0x00,0xf0,0x7f,0x06,0x00,0x00,0x07,0x00,0xf8,
+ 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x07,0x00,0xf0,0x00,0x00,0xe0,
+ 0x7f,0x00,0x00,0x00,0x00,0x00,0xf8,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xfe,0x07,0x00,0xf0,0x00,0x00,0xe0,0x7f,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x07,0x00,0xf0,0x00,0x00,0xf0,0x7f,
+ 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,
+ 0x07,0x00,0xf0,0x00,0x00,0xe0,0x7f,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x0f,0x00,0xf0,0x00,0x00,0xe0,0x7f,0x1c,
+ 0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x0f,
+ 0x00,0xf0,0x00,0x00,0xe0,0x7f,0x3c,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x9e,0x0f,0x00,0xf0,0x00,0x00,0xe0,0xff,0x3c,0x00,
+ 0x00,0x00,0x00,0x7c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x9e,0x0f,0x00,
+ 0xf0,0x00,0x00,0xc0,0xfd,0x7c,0x00,0x00,0x00,0x00,0x7e,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x9e,0x0f,0x00,0xf0,0x00,0x00,0x80,0xfd,0x7c,0x00,0x00,
+ 0x00,0x00,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x07,0x00,0xf0,
+ 0x00,0x00,0x00,0xfc,0x7c,0x00,0x00,0x00,0x80,0x3f,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x9f,0x07,0x00,0xf0,0x00,0x00,0x00,0xfc,0xfc,0x00,0x00,0x00,
+ 0x80,0x3f,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x07,0x00,0xf0,0x00,
+ 0x00,0x80,0xff,0xfc,0x00,0x00,0x00,0xe0,0x3f,0x00,0x38,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xff,0x03,0x00,0xf0,0x00,0x00,0x80,0xff,0xf8,0x01,0x00,0x00,0xf0,
+ 0x3f,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x03,0x00,0xf0,0x00,0x00,
+ 0x00,0xff,0xf8,0x03,0x00,0x00,0xf8,0x3f,0x00,0x20,0x00,0x1e,0x00,0x00,0x00,
+ 0x04,0xef,0x01,0x00,0xf0,0x00,0x00,0x00,0xff,0xf8,0x03,0x00,0x00,0xff,0x1f,
+ 0x00,0x20,0xc0,0x7f,0x00,0x00,0x00,0x0e,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,
+ 0x7c,0xf8,0x07,0x00,0x80,0xff,0x1f,0x00,0x00,0xe0,0xff,0x01,0x00,0x00,0x0f,
+ 0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0x07,0x00,0xe0,0xff,0x1f,0x00,
+ 0x00,0xe0,0xff,0x03,0x00,0xc0,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,
+ 0xf8,0x07,0x00,0xf0,0xff,0x1f,0x00,0x00,0xf0,0xff,0x07,0x00,0xc0,0x1f,0x00,
+ 0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0x0f,0x00,0xf8,0xfe,0x1f,0x00,0x00,
+ 0xfc,0xf3,0x0f,0x00,0xf0,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,
+ 0x0f,0x00,0x7c,0xfc,0x3f,0x00,0x80,0xff,0xe1,0x3f,0x00,0xf8,0x0f,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0x1f,0x00,0x3e,0xfc,0xbf,0x00,0xe0,0xff,
+ 0xc0,0x3f,0x00,0xfe,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0x1f,
+ 0x00,0x1f,0xfc,0xff,0x03,0xf0,0x7f,0x80,0x7f,0x80,0xff,0x0f,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0x00,0xf8,0x1f,0x80,0x0f,0xfe,0xff,0x07,0xfe,0x3f,0x00,
+ 0x7f,0xf8,0xff,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0x7f,0xe0,
+ 0x07,0xff,0xff,0xff,0xff,0x1f,0x00,0xff,0xf9,0xff,0x0f,0x00,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0xf8,0xff,0xf0,0x83,0xff,0xff,0xff,0xff,0x03,0x00,0xfe,
+ 0xff,0xff,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0xff,0xff,0x83,
+ 0xff,0xff,0xff,0xff,0x00,0x00,0xfe,0xff,0xff,0x0f,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0x00,0x00,0xfc,0xff,0xff,0x80,0xff,0xff,0xff,0x7f,0x00,0x00,0xfc,0xff,
+ 0xff,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xe0,0xff,
+ 0xff,0xff,0x3f,0x00,0x00,0xf8,0xff,0xff,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0x00,0x00,0xfc,0xff,0x7f,0xe0,0xff,0xff,0xff,0x1f,0x00,0x00,0xf8,0xff,0xff,
+ 0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xfc,0xff,0x3f,0xf0,0xff,0xff,
+ 0xff,0x0f,0x00,0x00,0xf0,0xff,0xff,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,
+ 0x00,0xfe,0xff,0x1f,0xfc,0xff,0xff,0xff,0x07,0x00,0x00,0xf8,0xff,0xff,0x0f,
+ 0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xfc,0xff,0x07,0xff,0xff,0xff,0xff,
+ 0x03,0x00,0xf0,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,
+ 0xfc,0xff,0x83,0xff,0xff,0xff,0xff,0x01,0x00,0xff,0xff,0x1f,0xff,0x1f,0x00,
+ 0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xfc,0xff,0x81,0xff,0xff,0xff,0xff,0x00,
+ 0xe0,0xff,0xff,0x07,0xf8,0x1f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xfc,
+ 0xff,0x01,0xff,0xff,0xff,0x3f,0x80,0xff,0xff,0xff,0x01,0xf8,0x3f,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0x00,0xfc,0xff,0x01,0xfe,0xff,0xff,0x1f,0xc0,0xff,
+ 0xff,0xff,0x00,0xf8,0x1f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0xff,
+ 0x01,0xf8,0xff,0xff,0x1f,0xf8,0xff,0xff,0x7f,0x00,0xf8,0x1f,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0x00,0xf8,0xff,0x01,0xf8,0x8f,0xfc,0xff,0xff,0xff,0xff,
+ 0x3f,0x00,0xfc,0x1f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf8,0xff,0x01,
+ 0xf8,0x0f,0xe0,0xff,0xff,0x07,0xf8,0x0f,0x00,0xfc,0x1f,0x00,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0xf8,0xe7,0x03,0xf8,0x0f,0x00,0x04,0x00,0x00,0xf8,0x0f,
+ 0x00,0xfc,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf0,0xef,0x03,0xfc,
+ 0x0f,0x00,0x00,0x00,0x00,0xfe,0x07,0x00,0xfc,0x0f,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0x00,0x00,0xf0,0xef,0x07,0xfc,0x1f,0x00,0x00,0x00,0x00,0xff,0x03,0x00,
+ 0xfc,0x0f,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xf0,0xc7,0x07,0xf8,0x3f,
+ 0x00,0x00,0x00,0x00,0xff,0x01,0x00,0xfe,0x07,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0x00,0x00,0xe0,0xc7,0x07,0xf8,0xff,0x01,0x00,0x00,0x00,0xff,0x00,0x00,0xfe,
+ 0x07,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xe0,0xc7,0x07,0xf0,0xff,0x0f,
+ 0x00,0x00,0x00,0xff,0x00,0x00,0xff,0x07,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,
+ 0x00,0xe0,0xc7,0x07,0xf0,0xff,0x1f,0x00,0x00,0x80,0xff,0x00,0x00,0xff,0x03,
+ 0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xc0,0xcf,0x07,0xf0,0xff,0x3f,0x00,
+ 0x00,0xc0,0x7f,0x00,0x00,0xff,0x03,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,
+ 0xc0,0xdf,0x07,0xe0,0xff,0x3f,0x00,0x00,0xe0,0x07,0x00,0x80,0xff,0x01,0x00,
+ 0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x80,0x9f,0x0f,0xe0,0xff,0x7f,0x00,0x00,
+ 0xc6,0x00,0x00,0x80,0xff,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x80,
+ 0xbf,0x0f,0xe0,0xff,0x7f,0x00,0xfc,0x0f,0x00,0x00,0x80,0xff,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xff,0x0f,0xc0,0xff,0xff,0xff,0xff,0x0f,
+ 0x00,0x00,0xc0,0xff,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xff,
+ 0x0f,0x80,0xff,0xff,0xff,0xff,0x07,0x00,0x00,0xc0,0x7f,0x00,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0x00,0x00,0xfe,0x0f,0x80,0xff,0xff,0xff,0x7f,0x00,0x00,
+ 0x00,0xc0,0x7f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xfe,0x0f,
+ 0x80,0xff,0xff,0xf0,0x3f,0x00,0x00,0x00,0xe0,0x7f,0x00,0x00,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0xfc,0x1f,0xc0,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,
+ 0xe0,0x3f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xfc,0x1f,0xe0,
+ 0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0xe0,0x3f,0x00,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0x00,0x00,0x00,0xf8,0x3c,0xf0,0xff,0x7f,0x00,0x00,0x10,0x00,0x00,0xf0,
+ 0x1f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xf8,0x3c,0xf0,0xff,
+ 0xff,0x00,0xf0,0x7f,0x00,0x00,0xf8,0x1f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0x00,0x00,0x00,0xf0,0x18,0xfc,0xff,0xff,0x07,0xfe,0xff,0x00,0x00,0xf8,0x1f,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xe0,0x10,0xfe,0xff,0xff,
+ 0xff,0xff,0xff,0x01,0x00,0xf8,0x0f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,
+ 0x00,0x00,0xe0,0x00,0xff,0xcf,0xff,0xff,0xff,0xff,0x01,0x00,0xfc,0x0f,0x00,
+ 0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x40,0xc0,0xff,0x87,0xff,0xff,
+ 0xff,0xff,0x01,0x00,0xfc,0x07,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xe0,0xff,0x83,0xff,0xff,0xff,0xff,0x00,0x00,0xfc,0x03,0x00,0x00,
+ 0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0x81,0xff,0xff,0xff,
+ 0x7f,0x00,0x00,0xfe,0x03,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0xff,0x81,0xff,0xff,0xff,0x1f,0x00,0x00,0xfe,0x01,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0xc1,0xff,0xcf,0xff,0x0f,
+ 0x00,0x00,0xff,0x01,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xfc,0xff,0xf0,0xff,0x03,0x00,0x00,0x00,0x00,0xff,0x00,0x00,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xf0,0xff,0x00,0x00,0x00,0x00,
+ 0xc0,0xff,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,
+ 0x7f,0xf0,0x3f,0x00,0x00,0x00,0x00,0xc0,0xff,0x00,0x00,0x00,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x3f,0xf0,0x3f,0x00,0x00,0x00,0x00,0xc0,
+ 0x7f,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0xc0,0x00,0x00,0x00,0xff,0x3f,
+ 0xfc,0x1f,0x00,0x00,0x00,0x00,0xe0,0x3f,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0xf0,0x03,0x03,0xc0,0xff,0x1f,0xfc,0x0f,0x00,0x00,0x00,0x00,0xf0,0x1f,
+ 0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0xfc,0x83,0x07,0xe0,0xff,0x3f,0xfc,
+ 0x07,0x00,0x00,0x00,0x00,0xf8,0x0f,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0xfe,0x87,0x07,0xf0,0xff,0x3f,0xfe,0x07,0x00,0x00,0x00,0x00,0xfc,0x0f,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0xfe,0xc3,0x0f,0xf8,0xff,0xff,0xff,0x07,
+ 0x00,0x00,0x00,0x00,0xfe,0x0f,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x80,0xff,
+ 0xc3,0x1f,0xfc,0xff,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0xff,0x03,0x00,0x00,
+ 0x00,0x00,0x00,0xf0,0x00,0x80,0xff,0xe3,0x1f,0xfe,0xff,0xff,0xff,0x07,0x00,
+ 0x00,0x00,0x00,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xe0,0xff,0xf1,
+ 0x3f,0xff,0xff,0xff,0xff,0x07,0x00,0x00,0x00,0x80,0xff,0x01,0x00,0x00,0x00,
+ 0x00,0x00,0xf0,0x00,0xe0,0x1f,0xfc,0xff,0xff,0x3f,0xfc,0xff,0x03,0x00,0x00,
+ 0x00,0xe0,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xe0,0x1f,0xfc,0xff,
+ 0xff,0x3f,0xfc,0xff,0x03,0x00,0x00,0x00,0xe0,0x7f,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0xe0,0x0f,0xfc,0xff,0xff,0x1f,0xfc,0xff,0x03,0x00,0x00,0x00,
+ 0xf0,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xc0,0x01,0xfe,0xff,0xff,
+ 0x1f,0xf8,0xff,0x07,0x00,0x00,0x00,0xfc,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0xfe,0xff,0xff,0x0f,0xf8,0xff,0x0f,0x00,0x00,0x80,0xff,
+ 0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0xfe,0xff,0xff,0x07,
+ 0xf0,0xff,0xff,0x0f,0x08,0xfc,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,
+ 0x00,0x0f,0x1c,0xfc,0xff,0xff,0x07,0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x80,0xff,0x1f,0xf8,0xff,0xff,0x03,0xc0,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,
+ 0xff,0x3f,0xf8,0xff,0xff,0x01,0x80,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xff,0x3f,0xf0,0xff,0xff,0x00,0x80,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xff,
+ 0x7f,0xf0,0xff,0xff,0x00,0x00,0xfe,0xff,0xff,0xff,0xff,0xff,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0xff,0xff,0xe0,0xff,0x7f,0x00,0x00,0xf0,0xff,
+ 0xff,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xff,0xff,
+ 0xe0,0xff,0x7f,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0xf0,0x00,0xfe,0xff,0xc0,0xff,0x3f,0x00,0x00,0x00,0x00,0xf8,
+ 0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xfc,0xff,0xc1,
+ 0xff,0x1f,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xf0,0x00,0xfc,0xff,0xc1,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x0e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xfc,0xff,0xc1,0xff,
+ 0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0xfc,0xff,0xc1,0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xf8,0xff,0xc3,0xff,0x07,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xf0,0x00,0xf8,0xff,0xc3,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xf0,0xff,0xc3,0xff,0x01,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,
+ 0x00,0xf0,0xff,0xc7,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xe0,0xff,0xff,0xff,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,
+ 0xe0,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xc0,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x80,
+ 0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0xfe,
+ 0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0xf0,0x00,0x00,0xfc,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0xf8,0xff,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xf0,0x00,0x00,0xe0,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0};
diff --git a/xlockmore-4.14/bitmaps/l-bsd.xbm b/xlockmore-4.14/bitmaps/l-bsd.xbm
new file mode 100644 (file)
index 0000000..33e4f04
--- /dev/null
@@ -0,0 +1,52 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x60, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x90, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd0, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x50, 0x3c, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x48, 0xee,
+   0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0xe8, 0x81, 0x0f, 0x70, 0x00, 0x00,
+   0x00, 0x00, 0xa8, 0x00, 0x0a, 0xd0, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00,
+   0x38, 0xa0, 0x01, 0x00, 0x00, 0x00, 0x20, 0x00, 0x38, 0x90, 0x01, 0x00,
+   0x00, 0x00, 0x30, 0x07, 0x50, 0xdc, 0x01, 0x00, 0x00, 0x00, 0x90, 0x08,
+   0xc0, 0xe3, 0x00, 0x00, 0x00, 0x00, 0x90, 0xc8, 0x01, 0xd0, 0x00, 0x00,
+   0x00, 0x00, 0x48, 0x24, 0x02, 0x7c, 0x00, 0x00, 0x00, 0x00, 0xc8, 0x25,
+   0x02, 0x34, 0x00, 0x00, 0x00, 0x00, 0x44, 0x25, 0x82, 0x0f, 0x00, 0x00,
+   0x00, 0x00, 0xc4, 0x73, 0xc2, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc2, 0x53,
+   0xa2, 0x01, 0x00, 0x00, 0x00, 0x00, 0x81, 0xf1, 0x82, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x01, 0xf3, 0xe1, 0x01, 0x00, 0x00, 0x00, 0x06, 0x81, 0xe0,
+   0xa0, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x41, 0x00, 0x90, 0x00, 0x00, 0x00,
+   0x00, 0x1c, 0x96, 0x08, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x24, 0x0f,
+   0x70, 0x00, 0x00, 0x00, 0xc0, 0x18, 0xc8, 0x80, 0x58, 0x00, 0x00, 0x00,
+   0xc0, 0x11, 0x90, 0x73, 0x34, 0x00, 0x00, 0x00, 0x80, 0x13, 0x60, 0x0f,
+   0x1a, 0x00, 0x00, 0x00, 0x18, 0x1f, 0x80, 0x00, 0x07, 0x00, 0x00, 0x00,
+   0x38, 0x3c, 0x00, 0xd1, 0x06, 0x00, 0x00, 0x00, 0xf0, 0xfe, 0x0e, 0x01,
+   0x05, 0x00, 0x00, 0x00, 0xf0, 0xf3, 0x13, 0x01, 0x07, 0x00, 0x00, 0x00,
+   0x00, 0xe0, 0xa9, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x43, 0x80,
+   0x04, 0x00, 0x00, 0x00, 0x00, 0x80, 0x08, 0x00, 0x06, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x2c, 0x80, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x80, 0xa4, 0x3e,
+   0x0e, 0x00, 0x00, 0x00, 0x00, 0x80, 0xd2, 0xa1, 0x0e, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x59, 0x61, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x01,
+   0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0x00, 0x06, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x40, 0x80, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xe1,
+   0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0xff, 0x05, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x10, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x80,
+   0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x37, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x20, 0xc0, 0x6c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xc1,
+   0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x7b, 0xdc, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x60, 0x08, 0xf6, 0xff, 0x00, 0x00, 0x00, 0x00, 0x30, 0x99,
+   0x04, 0x57, 0x0f, 0x00, 0x00, 0x00, 0xd0, 0x28, 0x04, 0xfc, 0x17, 0x00,
+   0x00, 0x00, 0xc8, 0x5e, 0x08, 0x00, 0xfc, 0x00, 0x00, 0xc0, 0xb7, 0x27,
+   0x08, 0x00, 0xb0, 0x01, 0x00, 0x30, 0xf4, 0x19, 0x18, 0x00, 0xc0, 0x02,
+   0x00, 0x08, 0x5c, 0x0a, 0x1c, 0x00, 0xb4, 0x03, 0x00, 0x04, 0x04, 0x03,
+   0x0b, 0x80, 0xdb, 0x00, 0x00, 0x04, 0x06, 0xd1, 0x07, 0x80, 0x34, 0x00,
+   0x00, 0xf8, 0x01, 0xe2, 0x00, 0xe0, 0x09, 0x00, 0x00, 0x00, 0x06, 0x1f,
+   0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
+
+/*
+ * BSD daemon
+ * The original BSD daemon is Copyright (c) 1988 Marshall Kirk McKusick.
+ * All Rights Reserved.  Reproduced with permission.
+ */
diff --git a/xlockmore-4.14/bitmaps/l-dec.xbm b/xlockmore-4.14/bitmaps/l-dec.xbm
new file mode 100644 (file)
index 0000000..d737889
--- /dev/null
@@ -0,0 +1,27 @@
+#define image_width 82
+#define image_height 26
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe,
+   0xef, 0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef,
+   0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f,
+   0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0xff,
+   0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0xff, 0xf7,
+   0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xec, 0x79, 0xff, 0xf7, 0xbc,
+   0xff, 0xfb, 0xbf, 0xe7, 0x01, 0xfe, 0xec, 0x79, 0xff, 0xf7, 0xbc, 0xc7,
+   0xfb, 0xbf, 0xe7, 0x01, 0xfe, 0xec, 0x79, 0xff, 0xf7, 0xbc, 0xc7, 0xfb,
+   0xbf, 0xe7, 0x01, 0xfe, 0xec, 0x7f, 0xff, 0xf7, 0xbf, 0xc7, 0xfb, 0xbf,
+   0xe7, 0x01, 0x0e, 0xec, 0x79, 0x0f, 0xf6, 0xbc, 0x83, 0x3b, 0xb8, 0xe7,
+   0x01, 0x06, 0xec, 0x79, 0x07, 0xf6, 0xbc, 0x83, 0x1b, 0xb0, 0xe7, 0x01,
+   0x46, 0xec, 0x79, 0x23, 0xf6, 0xbc, 0xc7, 0xfb, 0xb1, 0xe7, 0x01, 0xe6,
+   0xec, 0x79, 0x73, 0xf6, 0xbc, 0xc7, 0x3b, 0xb0, 0xe7, 0x01, 0xe6, 0xec,
+   0x79, 0x73, 0xf6, 0xbc, 0xc7, 0x1b, 0xb0, 0xe7, 0x01, 0xe6, 0xec, 0x79,
+   0x73, 0xf6, 0xbc, 0xc7, 0x9b, 0xb1, 0xe7, 0x01, 0x46, 0xec, 0x79, 0x23,
+   0xf6, 0xbc, 0xc7, 0x9b, 0xb1, 0xe7, 0x01, 0x06, 0xec, 0x79, 0x07, 0xf6,
+   0xbc, 0x87, 0x1b, 0xb0, 0xe7, 0x01, 0x1e, 0xec, 0x79, 0x0f, 0xf6, 0xbc,
+   0x8f, 0x3b, 0xb0, 0xe7, 0x01, 0xfe, 0xef, 0x7f, 0x7f, 0xf6, 0xbf, 0xff,
+   0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0x23, 0xf6, 0xbf, 0xff, 0xfb,
+   0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0x07, 0xf7, 0xbf, 0xff, 0xfb, 0xbf,
+   0xff, 0x01, 0xfe, 0xef, 0x7f, 0x9f, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff,
+   0x01, 0xfe, 0xef, 0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01,
+   0xfe, 0xef, 0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/l-hp.xbm b/xlockmore-4.14/bitmaps/l-hp.xbm
new file mode 100644 (file)
index 0000000..1be3800
--- /dev/null
@@ -0,0 +1,20 @@
+#define image_width 46
+#define image_height 34
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xe0, 0xff, 0x79, 0xfe, 0xff, 0xc1,
+   0xf8, 0xff, 0x39, 0xfe, 0xff, 0xc7, 0xfc, 0xff, 0x3d, 0xfc, 0xff, 0xcf,
+   0xfc, 0xff, 0x3c, 0xe0, 0xff, 0xcf, 0xfe, 0x7f, 0x1c, 0x80, 0xff, 0xdf,
+   0xfe, 0x3f, 0x1c, 0x00, 0xff, 0xdf, 0xfe, 0x1f, 0x1e, 0x00, 0xfe, 0xdf,
+   0xfe, 0x0f, 0x1e, 0x00, 0xfc, 0xdf, 0xfe, 0x07, 0x0e, 0x00, 0xf8, 0xdf,
+   0xfe, 0x07, 0x0f, 0x00, 0xf8, 0xdf, 0xfe, 0x03, 0x7f, 0xfc, 0xf1, 0xdf,
+   0xfe, 0x03, 0xff, 0xfc, 0xf3, 0xdf, 0xfe, 0x03, 0xff, 0xfc, 0xf3, 0xdf,
+   0xfe, 0x81, 0xf7, 0xde, 0xe3, 0xdf, 0xfe, 0x81, 0x77, 0xde, 0xe1, 0xdf,
+   0xfe, 0x81, 0x73, 0xce, 0xe1, 0xdf, 0xfe, 0xc1, 0x7b, 0xee, 0xe1, 0xdf,
+   0xfe, 0xc1, 0x7b, 0xef, 0xe1, 0xdf, 0xfe, 0xc1, 0x3b, 0xe7, 0xe0, 0xdf,
+   0xfe, 0xc3, 0x39, 0xff, 0xf0, 0xdf, 0xfe, 0xe3, 0xbd, 0xff, 0xf0, 0xdf,
+   0xfe, 0xe3, 0xbd, 0x7f, 0xf0, 0xdf, 0xfe, 0x07, 0x80, 0x03, 0xf8, 0xdf,
+   0xfe, 0x07, 0x80, 0x03, 0xf8, 0xdf, 0xfe, 0x0f, 0xc0, 0x03, 0xfc, 0xdf,
+   0xfe, 0x1f, 0xc0, 0x03, 0xfe, 0xdf, 0xfe, 0x3f, 0xc0, 0x01, 0xff, 0xdf,
+   0xfe, 0x7f, 0xc0, 0x81, 0xff, 0xdf, 0xfc, 0xff, 0xe1, 0xe1, 0xff, 0xcf,
+   0xfc, 0xff, 0xe7, 0xfc, 0xff, 0xcf, 0xf8, 0xff, 0xe7, 0xfc, 0xff, 0xc7,
+   0xe0, 0xff, 0xf3, 0xfc, 0xff, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0};
diff --git a/xlockmore-4.14/bitmaps/l-ibm.xbm b/xlockmore-4.14/bitmaps/l-ibm.xbm
new file mode 100644 (file)
index 0000000..203c6de
--- /dev/null
@@ -0,0 +1,32 @@
+#define image_width 78
+#define image_height 34
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xfc, 0xff, 0xf8, 0xff,
+   0x3f, 0xf0, 0xff, 0x00, 0xff, 0xcf, 0xfc, 0xff, 0xf8, 0xff, 0x7f, 0xf0,
+   0xff, 0x00, 0xff, 0xcf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0xfc, 0xff, 0xf8, 0xff, 0xff, 0xf1, 0xff, 0xc1, 0xff, 0xcf, 0xfc, 0xff,
+   0xf8, 0xff, 0xff, 0xf1, 0xff, 0xc1, 0xff, 0xcf, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0xff, 0xe3,
+   0xff, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0xff, 0xe3, 0xff, 0xc0,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xc0, 0x0f, 0x80, 0xff,
+   0xff, 0x00, 0xff, 0xf7, 0xff, 0xc0, 0xc0, 0x0f, 0x80, 0xff, 0x7f, 0x00,
+   0xff, 0xff, 0xff, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0xc0, 0x0f, 0x80, 0xff, 0x7f, 0x00, 0xbf, 0xff, 0xfd, 0xc0, 0xc0, 0x0f,
+   0x80, 0xff, 0x7f, 0x00, 0xbf, 0xff, 0xfd, 0xc0, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0x3f, 0x7f,
+   0xfc, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0x3f, 0x7f, 0xfc, 0xc0,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xfc, 0xff, 0xf8, 0xff,
+   0xff, 0xf1, 0x3f, 0x3e, 0xfc, 0xcf, 0xfc, 0xff, 0xf8, 0xff, 0xff, 0xf1,
+   0x3f, 0x3e, 0xfc, 0xcf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0xfc, 0xff, 0xf8, 0xff, 0x7f, 0xf0, 0x3f, 0x1c, 0xfc, 0xcf, 0xfc, 0xff,
+   0xf8, 0xff, 0x3f, 0xf0, 0x3f, 0x1c, 0xfc, 0xcf, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0};
diff --git a/xlockmore-4.14/bitmaps/l-linux.xbm b/xlockmore-4.14/bitmaps/l-linux.xbm
new file mode 100644 (file)
index 0000000..7ceeaf9
--- /dev/null
@@ -0,0 +1,205 @@
+#define image_width 128
+#define image_height 151
+static unsigned char image_bits[] = {
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00,
+   0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0x1f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0xf0, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00,
+   0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00,
+   0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x1f, 0x00, 0x00, 0x00, 0x05, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x06, 0xf8, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00,
+   0x00, 0x09, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x0f, 0x00, 0x00, 0x00, 0x02, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x50, 0x00, 0x00, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x14, 0x00,
+   0xe8, 0x03, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x03, 0x2e, 0x00, 0x5c, 0x07, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x5f, 0x00, 0xf7, 0x0b, 0x00, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x83, 0x7d, 0x00,
+   0xfe, 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x83, 0x7f, 0x80, 0xff, 0x0b, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x83, 0xf1, 0x80, 0x0f, 0x1f, 0x00, 0xfe,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc3, 0xe0, 0x80,
+   0x87, 0x1e, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xc7, 0xc8, 0x81, 0x87, 0x1c, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xc7, 0xd0, 0x80, 0x03, 0x3c, 0x00, 0xfe,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc7, 0xd0, 0x81,
+   0x03, 0x3c, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xc7, 0xc0, 0x00, 0x03, 0x3c, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x87, 0xc0, 0x2a, 0x03, 0x3c, 0x00, 0xfe,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x87, 0x41, 0xff,
+   0x01, 0x3c, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x87, 0xa1, 0x2b, 0x0f, 0x1e, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xeb, 0xfe, 0x9f, 0x0f, 0x00, 0xfe,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf7, 0xfb,
+   0x76, 0x0d, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x07, 0xba, 0xdf, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xea, 0xfd, 0xdb, 0x1e, 0x00, 0xfc,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x7d, 0x6f,
+   0xff, 0x1b, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x87, 0xd6, 0xfd, 0x6d, 0x1b, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x47, 0xfb, 0xef, 0xf7, 0x15, 0x00, 0xfc,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x47, 0x6d, 0xff,
+   0x3e, 0x1d, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x87, 0xde, 0xbb, 0xcf, 0x16, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfa, 0xef, 0xb3, 0x0b, 0x04, 0xf8,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xd8, 0xbe,
+   0xe8, 0x05, 0x08, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x87, 0xf2, 0x37, 0x55, 0x1d, 0x54, 0xf0, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x8f, 0x01, 0x40, 0x7d, 0x3f, 0x28, 0xe0,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x8f, 0xd7, 0xbf,
+   0x8b, 0x3f, 0xa8, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x8f, 0x57, 0x65, 0xf5, 0x77, 0x50, 0xc0, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x8f, 0x4e, 0x5b, 0x75, 0x5f, 0x40, 0xc0,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x87, 0x3f, 0x2a,
+   0xfd, 0x7f, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x83, 0x77, 0x89, 0xee, 0xff, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x83, 0xdf, 0xf5, 0xff, 0xff, 0x00, 0x00,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x81, 0x7f, 0xff,
+   0xfe, 0xff, 0x01, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xc0, 0xff, 0xfd, 0xff, 0xff, 0x01, 0x00, 0xfe, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0x7f, 0xc0, 0xdf, 0xb7, 0xff, 0xff, 0x03, 0x00,
+   0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xe0, 0xff, 0xfe,
+   0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0x3f, 0xf0, 0xff, 0xfb, 0xff, 0xff, 0x07, 0x00, 0xf8, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0x1f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00,
+   0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xf8, 0xff, 0xff,
+   0xff, 0xff, 0x07, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0x0f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0xe0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00,
+   0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff,
+   0xff, 0xff, 0x0f, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0x03, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00,
+   0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0x1f, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xfc, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00,
+   0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0x7f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f,
+   0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xf0, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x1f, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00,
+   0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x80, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f,
+   0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0xe0, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x0f, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01,
+   0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xe0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07,
+   0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x80, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07,
+   0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x07, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f,
+   0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01,
+   0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xfe, 0xff,
+   0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f,
+   0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x00,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xfc, 0xff,
+   0xff, 0xff, 0x7f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f,
+   0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0x7f, 0x80,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xf8, 0xff,
+   0xff, 0xff, 0x3f, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f,
+   0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0x3f, 0x80, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0x1f, 0x80,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0xff, 0x0f, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f,
+   0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x0f, 0xc0, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x07, 0xc0,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f,
+   0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x03, 0xc0,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f,
+   0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x03, 0xc0,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f,
+   0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xc3, 0xc0, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xe3, 0xc3,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0xff, 0x5f, 0xc7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f,
+   0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xf7, 0x8f, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x36, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xbb, 0x1d,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xfc, 0xff,
+   0xff, 0xff, 0xf7, 0x37, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x36,
+   0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xda, 0x5e, 0xf8, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xbf, 0x7f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x7f, 0xbd, 0xfb,
+   0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x2d, 0x00, 0x80, 0xfb, 0xff,
+   0xff, 0xff, 0xeb, 0xbf, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x3f,
+   0x00, 0x80, 0xfe, 0xff, 0xff, 0x7f, 0xfd, 0xf5, 0x81, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xbf, 0x15, 0x00, 0xc0, 0xf7, 0xff, 0xff, 0x5f, 0xb7, 0xde,
+   0x02, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x6f, 0x00, 0xe0, 0xfe, 0xff,
+   0xff, 0xaf, 0xfd, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xbf, 0x3d,
+   0x00, 0xb0, 0xf7, 0xff, 0xff, 0x6a, 0xd7, 0xb6, 0x05, 0xfc, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x57, 0x01, 0xd4, 0xfd, 0xff, 0x6f, 0xb5, 0xbf, 0xff,
+   0x0f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xbb, 0x4a, 0x75, 0xff, 0xff,
+   0xf3, 0xef, 0xf5, 0xb6, 0x06, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xd6,
+   0xaa, 0xda, 0xf7, 0xff, 0x5f, 0x7d, 0xef, 0xff, 0x1f, 0xc0, 0xff, 0xff,
+   0xff, 0xff, 0x7f, 0xbf, 0xaa, 0xf6, 0xfd, 0xff, 0xf5, 0xdf, 0x7f, 0xb7,
+   0x2d, 0x00, 0xff, 0xff, 0xff, 0xff, 0xbf, 0xd5, 0x55, 0xbb, 0xde, 0xff,
+   0xdd, 0xf6, 0xd5, 0xfb, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xbf, 0xbe,
+   0xfe, 0xee, 0xf7, 0xff, 0xf7, 0x7b, 0x7f, 0x6f, 0x5b, 0x00, 0xfe, 0xff,
+   0xff, 0xff, 0x7f, 0xd5, 0xab, 0xfd, 0xbd, 0xff, 0x7b, 0xef, 0xfd, 0xdf,
+   0xbf, 0x00, 0xfe, 0xff, 0xff, 0xff, 0x7f, 0xfd, 0xda, 0xb7, 0xef, 0xff,
+   0xad, 0xbf, 0x57, 0xfb, 0xf6, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xbf, 0xaa,
+   0xf7, 0xfe, 0xfd, 0xfe, 0xfb, 0xf5, 0xff, 0xb7, 0x7f, 0x01, 0xfe, 0xff,
+   0xff, 0xff, 0x3f, 0xfd, 0x5e, 0xb7, 0xb7, 0xfb, 0x6d, 0x5f, 0xbd, 0xee,
+   0xeb, 0x02, 0xfe, 0xff, 0xff, 0xff, 0x5f, 0xab, 0xfb, 0xfd, 0xde, 0xff,
+   0xf7, 0xff, 0xef, 0xbd, 0xfe, 0x03, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfd,
+   0xef, 0xdf, 0xbd, 0xed, 0xdb, 0xea, 0xfb, 0xfb, 0xbb, 0xc5, 0xff, 0xff,
+   0xff, 0xff, 0x83, 0xb6, 0x7d, 0xf7, 0xf7, 0xff, 0xb5, 0xbf, 0x5e, 0xaf,
+   0xef, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfb, 0xdf, 0xdf, 0xfe, 0xad,
+   0xfb, 0xee, 0xf7, 0xff, 0xde, 0xea, 0xff, 0xff, 0xff, 0xff, 0x40, 0xad,
+   0xfb, 0xfa, 0xd7, 0xfe, 0xd7, 0xbb, 0xde, 0xf6, 0xfb, 0xff, 0xff, 0xff,
+   0xff, 0x7f, 0x00, 0xfd, 0xee, 0xbf, 0xfd, 0xb7, 0xfb, 0xff, 0xfb, 0xbf,
+   0xbf, 0xd6, 0xff, 0xff, 0xff, 0x1f, 0xc0, 0xee, 0xbf, 0xf7, 0x77, 0xdf,
+   0x55, 0xdb, 0x5f, 0xed, 0xd6, 0xaf, 0xff, 0xff, 0xff, 0x0f, 0x00, 0xbb,
+   0xf6, 0x5e, 0xdf, 0xf6, 0xfb, 0xfe, 0xf6, 0xff, 0xff, 0xb5, 0xff, 0xff,
+   0xff, 0x03, 0x40, 0xf5, 0xbf, 0xfb, 0xfb, 0xdf, 0xed, 0xab, 0xdf, 0x55,
+   0x5b, 0x1f, 0xff, 0xff, 0xff, 0x00, 0x80, 0xde, 0xfa, 0x5e, 0x6f, 0xf5,
+   0xb7, 0xff, 0xf6, 0xfe, 0xff, 0x6b, 0xfc, 0xff, 0x1f, 0x00, 0x40, 0xf7,
+   0xd7, 0xf7, 0xfb, 0xff, 0xdb, 0xed, 0xff, 0xbb, 0xed, 0x36, 0xe0, 0x7f,
+   0x00, 0x00, 0x80, 0x7a, 0x7f, 0xdd, 0xae, 0xfe, 0xed, 0xde, 0xb6, 0xff,
+   0x77, 0x5f, 0x00, 0x00, 0x00, 0x00, 0x40, 0xdd, 0xed, 0xfb, 0xdf, 0xff,
+   0x57, 0xbb, 0xfb, 0xdb, 0xde, 0xab, 0x00, 0x00, 0x00, 0x00, 0x40, 0xf7,
+   0xf7, 0xdf, 0xea, 0xff, 0xbb, 0xed, 0xae, 0xbe, 0x7f, 0x5d, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0xba, 0xbf, 0x76, 0xfb, 0xff, 0x4b, 0xb5, 0xf5, 0xf7,
+   0xf6, 0x57, 0x00, 0x00, 0x00, 0x00, 0x40, 0x6d, 0xdb, 0xaf, 0xfc, 0xff,
+   0xa7, 0xaa, 0x56, 0xdd, 0x5f, 0x95, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf5,
+   0xf7, 0x5a, 0xff, 0xff, 0x1f, 0xa9, 0x5a, 0xf5, 0xf6, 0x2b, 0x00, 0x00,
+   0x00, 0x00, 0xa0, 0x5a, 0x5d, 0x95, 0xff, 0xff, 0xff, 0xa7, 0x52, 0xab,
+   0x5d, 0x4a, 0x00, 0x00, 0x00, 0x00, 0x80, 0x6a, 0xd7, 0xca, 0xff, 0xff,
+   0xff, 0x1f, 0xa4, 0x54, 0xab, 0x09, 0x00, 0xfc, 0xff, 0xff, 0x00, 0xaa,
+   0xba, 0xf2, 0xff, 0xff, 0xff, 0xff, 0x41, 0xaa, 0x5a, 0x25, 0xf8, 0xff,
+   0xff, 0xff, 0x0f, 0xd5, 0x4a, 0xf9, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xa4,
+   0x4a, 0x02, 0xfc, 0xff, 0xff, 0xff, 0x4f, 0xa4, 0x2a, 0xfc, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x11, 0x29, 0x91, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x52,
+   0x95, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x8f, 0x44, 0xc4, 0xff, 0xff,
+   0xff, 0xff, 0x1f, 0x90, 0x04, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f,
+   0x12, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x08, 0x91, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff};
diff --git a/xlockmore-4.14/bitmaps/l-linux1.xbm b/xlockmore-4.14/bitmaps/l-linux1.xbm
new file mode 100644 (file)
index 0000000..4d155e5
--- /dev/null
@@ -0,0 +1,46 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x02, 0x00,
+   0x20, 0x00, 0x00, 0xc2, 0x12, 0x00, 0x00, 0x01, 0x00, 0x10, 0x00, 0x40,
+   0x46, 0x00, 0x01, 0x04, 0x10, 0x40, 0x00, 0x61, 0x04, 0x20, 0x80, 0x00,
+   0x02, 0x08, 0x20, 0x20, 0x2c, 0x84, 0x10, 0x42, 0x08, 0x21, 0x84, 0x30,
+   0x88, 0xf0, 0x7f, 0x08, 0x21, 0x84, 0x10, 0x12, 0x58, 0x22, 0x40, 0x21,
+   0x84, 0x10, 0x42, 0x18, 0x10, 0x28, 0x40, 0x84, 0x10, 0x42, 0x08, 0x09,
+   0x30, 0x61, 0xe0, 0x10, 0x42, 0x08, 0x21, 0x0c, 0x60, 0xc4, 0x30, 0x42,
+   0x08, 0x21, 0x84, 0x04, 0xe0, 0xd2, 0x50, 0x29, 0xa5, 0x94, 0x52, 0x06,
+   0x40, 0xa5, 0x90, 0x52, 0x4a, 0x29, 0xa5, 0x02, 0xc0, 0xca, 0x38, 0xa5,
+   0x94, 0x52, 0x4a, 0x03, 0x80, 0xb5, 0xf8, 0xff, 0xfb, 0xef, 0xff, 0x3f,
+   0x80, 0xdb, 0x28, 0x0c, 0x8d, 0x38, 0x0c, 0x21, 0x00, 0x77, 0x78, 0x1e,
+   0xcb, 0x69, 0x9e, 0x31, 0x00, 0x6f, 0x78, 0x16, 0xce, 0x79, 0x9e, 0x19,
+   0x00, 0x7a, 0x6c, 0x1e, 0xc6, 0x38, 0x9b, 0x0c, 0x00, 0x7e, 0x3c, 0x1e,
+   0xe6, 0x3c, 0x1f, 0x04, 0x00, 0x7c, 0x3c, 0x8e, 0xe4, 0x3c, 0x1f, 0x06,
+   0x00, 0x2c, 0x3c, 0x8f, 0xe4, 0x1c, 0x1f, 0x03, 0x00, 0x38, 0x3c, 0xcf,
+   0x64, 0x9c, 0x0f, 0x01, 0x00, 0x38, 0x1e, 0xc7, 0x70, 0x9e, 0x07, 0x01,
+   0x00, 0x30, 0x1e, 0xc7, 0x71, 0x9e, 0x27, 0x01, 0x00, 0x30, 0x9e, 0xe7,
+   0x71, 0x8e, 0x33, 0x01, 0x00, 0x10, 0x9e, 0xe7, 0x79, 0xc0, 0x31, 0x03,
+   0x00, 0x10, 0x0e, 0xc3, 0xf9, 0xe0, 0x10, 0x02, 0xff, 0x1f, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xf7, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x1f, 0xff, 0xf3, 0xff, 0xff, 0xff, 0xff, 0x00, 0x08, 0x01, 0x13,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0xff, 0xf1, 0xff, 0xff, 0x00, 0x00,
+   0x00, 0x0c, 0xfe, 0xf0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x06, 0x7e, 0xf8,
+   0xff, 0x7f, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf8, 0xff, 0x3f, 0x00, 0x00,
+   0x00, 0xfe, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff,
+   0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff,
+   0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff,
+   0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe,
+   0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc,
+   0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0,
+   0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0,
+   0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/l-mot.xbm b/xlockmore-4.14/bitmaps/l-mot.xbm
new file mode 100644 (file)
index 0000000..db0e78d
--- /dev/null
@@ -0,0 +1,67 @@
+#define image_width 76
+#define image_height 76
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x7f,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x01, 0xfc, 0x07, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x0f, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0x03, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x78, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00,
+   0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00,
+   0x00, 0x07, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x01, 0x1e,
+   0x00, 0x00, 0x00, 0xe0, 0x01, 0x0c, 0x00, 0x00, 0x01, 0x38, 0x00, 0x00,
+   0x00, 0x70, 0x00, 0x0c, 0x00, 0x80, 0x01, 0x70, 0x00, 0x00, 0x00, 0x38,
+   0x00, 0x0c, 0x00, 0x80, 0x03, 0xe0, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x1e,
+   0x00, 0x80, 0x03, 0xc0, 0x01, 0x00, 0x00, 0x0e, 0x00, 0x1e, 0x00, 0x80,
+   0x03, 0x80, 0x03, 0x00, 0x00, 0x0e, 0x00, 0x1e, 0x00, 0xc0, 0x03, 0x00,
+   0x03, 0x00, 0x00, 0x07, 0x00, 0x1e, 0x00, 0xc0, 0x07, 0x00, 0x07, 0x00,
+   0x80, 0x03, 0x00, 0x3f, 0x00, 0xc0, 0x07, 0x00, 0x0e, 0x00, 0x80, 0x01,
+   0x00, 0x3f, 0x00, 0xe0, 0x07, 0x00, 0x0c, 0x00, 0xc0, 0x01, 0x00, 0x3f,
+   0x00, 0xe0, 0x0f, 0x00, 0x18, 0x00, 0xc0, 0x00, 0x80, 0x7f, 0x00, 0xe0,
+   0x0f, 0x00, 0x38, 0x00, 0xe0, 0x00, 0x80, 0x7f, 0x00, 0xf0, 0x0f, 0x00,
+   0x30, 0x00, 0x60, 0x00, 0x80, 0x7f, 0x00, 0xf0, 0x1f, 0x00, 0x70, 0x00,
+   0x70, 0x00, 0xc0, 0xff, 0x00, 0xf0, 0x1f, 0x00, 0x60, 0x00, 0x30, 0x00,
+   0xc0, 0xff, 0x00, 0xf0, 0x1f, 0x00, 0x60, 0x00, 0x30, 0x00, 0xc0, 0xff,
+   0x00, 0xf8, 0x3f, 0x00, 0xe0, 0x00, 0x38, 0x00, 0xc0, 0xff, 0x01, 0xf8,
+   0x3f, 0x00, 0xc0, 0x00, 0x18, 0x00, 0xe0, 0xff, 0x01, 0xf8, 0x3f, 0x00,
+   0xc0, 0x00, 0x18, 0x00, 0xe0, 0xff, 0x01, 0xfc, 0x7f, 0x00, 0xc0, 0x01,
+   0x18, 0x00, 0xe0, 0xff, 0x03, 0xfc, 0x7f, 0x00, 0x80, 0x01, 0x1c, 0x00,
+   0xf0, 0xff, 0x03, 0xfc, 0x7f, 0x00, 0x80, 0x01, 0x0c, 0x00, 0xf0, 0xff,
+   0x03, 0xfc, 0x7f, 0x00, 0x80, 0x01, 0x0c, 0x00, 0xf0, 0xff, 0x03, 0xfe,
+   0xff, 0x00, 0x80, 0x01, 0x0c, 0x00, 0xf8, 0xff, 0x07, 0xfe, 0xff, 0x00,
+   0x80, 0x01, 0x0c, 0x00, 0xf8, 0xff, 0x07, 0xfe, 0xff, 0x00, 0x80, 0x03,
+   0x0c, 0x00, 0xf8, 0xff, 0x07, 0xff, 0xff, 0x01, 0x00, 0x03, 0x0c, 0x00,
+   0xf8, 0xff, 0x0f, 0xff, 0xff, 0x01, 0x00, 0x03, 0x0c, 0x00, 0xfc, 0xc1,
+   0x0f, 0x1f, 0xf8, 0x01, 0x00, 0x03, 0x0c, 0x00, 0x7c, 0x00, 0x8f, 0x0f,
+   0xe0, 0x03, 0x00, 0x03, 0x0c, 0x00, 0x3c, 0x00, 0x9e, 0x07, 0xc0, 0x03,
+   0x00, 0x03, 0x0c, 0x00, 0x1e, 0x00, 0x9c, 0x03, 0x80, 0x03, 0x80, 0x01,
+   0x0c, 0x00, 0x0e, 0x00, 0x9c, 0x01, 0x80, 0x07, 0x80, 0x01, 0x0c, 0x00,
+   0x0e, 0x00, 0xf8, 0x01, 0x00, 0x07, 0x80, 0x01, 0x1c, 0x00, 0x06, 0x00,
+   0xf0, 0x00, 0x00, 0x07, 0x80, 0x01, 0x18, 0x00, 0x07, 0x00, 0x70, 0x00,
+   0x00, 0x06, 0x80, 0x01, 0x18, 0x00, 0x07, 0x00, 0x60, 0x00, 0x00, 0x0e,
+   0xc0, 0x01, 0x18, 0x00, 0x03, 0x00, 0x60, 0x00, 0x00, 0x0c, 0xc0, 0x00,
+   0x38, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x0c, 0xc0, 0x00, 0x30, 0x80,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x1c, 0xc0, 0x00, 0x30, 0x80, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x18, 0xe0, 0x00, 0x70, 0xc0, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x18, 0x60, 0x00, 0x60, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x38,
+   0x70, 0x00, 0xe0, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x30, 0x00,
+   0xc0, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x38, 0x00, 0xc0, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x0e, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x06, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00,
+   0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x18,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x38, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x70, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x38,
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00,
+   0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x00,
+   0x1e, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00,
+   0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00,
+   0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x0f, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x01, 0xfc, 0x07, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/l-sco.xbm b/xlockmore-4.14/bitmaps/l-sco.xbm
new file mode 100644 (file)
index 0000000..e0c439d
--- /dev/null
@@ -0,0 +1,20 @@
+#define image_width 76
+#define image_height 25
+static char image_bits[] = {
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x07,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0x3f,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xfc,0x07,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x3f,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0xfe,0xff,0xff,0x1f,0xf0,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0xff,0xff,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x00,0x00,0xf0,0x00,0x00,0x00,0xf8,0xff,
+ 0xff,0xff,0xff,0xff,0xf7,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0xff,
+ 0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x07,0x00,0xf0,0x00,0x00,0xfc,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xf7,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x78,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x03,0xf0,0x00,0x00,0x00,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x07,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x9c,0x03,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xfc,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff};
diff --git a/xlockmore-4.14/bitmaps/l-sgi.xbm b/xlockmore-4.14/bitmaps/l-sgi.xbm
new file mode 100644 (file)
index 0000000..5f4c5e4
--- /dev/null
@@ -0,0 +1,46 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10,
+   0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x7c, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x7f, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f,
+   0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0xfc, 0x0f, 0x00, 0x00,
+   0x00, 0x00, 0xf8, 0x7f, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x7f,
+   0xfc, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xff, 0x7f, 0xfc, 0xff, 0x01, 0x00,
+   0x00, 0x80, 0xff, 0x7c, 0x7c, 0xfe, 0x03, 0x00, 0x00, 0xe0, 0x3f, 0x7c,
+   0x7c, 0xf8, 0x0f, 0x00, 0x00, 0xf8, 0x1f, 0x7c, 0x7c, 0xf0, 0x3f, 0x00,
+   0x00, 0xfc, 0x07, 0x7c, 0x7c, 0xc0, 0x7f, 0x00, 0x00, 0xff, 0x01, 0x7c,
+   0x7c, 0x00, 0xff, 0x01, 0x00, 0x7f, 0x00, 0x7c, 0x7c, 0x00, 0xfc, 0x01,
+   0x80, 0x3f, 0x00, 0x7c, 0x7c, 0x00, 0xf8, 0x03, 0x00, 0xff, 0x00, 0x7c,
+   0x7c, 0x00, 0xfe, 0x01, 0x00, 0xff, 0x03, 0x7c, 0x7c, 0x80, 0xff, 0x01,
+   0x00, 0xfc, 0x0f, 0x7c, 0x7c, 0xe0, 0x7f, 0x00, 0x40, 0xf0, 0x3f, 0x7c,
+   0x7c, 0xf8, 0x1f, 0x04, 0xf0, 0xe1, 0xff, 0x7c, 0x7c, 0xfe, 0x0f, 0x1f,
+   0xf8, 0x87, 0xff, 0x73, 0x9c, 0xff, 0xc3, 0x3f, 0xf8, 0x0f, 0xfe, 0x4f,
+   0xe4, 0xff, 0xe0, 0x3f, 0xfc, 0x3f, 0xf8, 0x3f, 0xf8, 0x3f, 0xf8, 0x7f,
+   0xfc, 0xff, 0xe0, 0xff, 0xff, 0x0f, 0xfe, 0x7f, 0xfc, 0xff, 0x83, 0xff,
+   0xff, 0x83, 0xff, 0x7f, 0xfc, 0xff, 0x07, 0xff, 0xff, 0xc1, 0xff, 0x7f,
+   0x7c, 0xfe, 0x1f, 0xfc, 0x7f, 0xf0, 0xff, 0x7c, 0x7c, 0xf8, 0x7f, 0xf2,
+   0x9f, 0xfc, 0x3f, 0x7c, 0x7c, 0xe0, 0xff, 0xcd, 0x67, 0xfe, 0x0f, 0x7c,
+   0x7c, 0xc0, 0xff, 0x33, 0x99, 0xff, 0x07, 0x7c, 0x7c, 0x00, 0xff, 0x0f,
+   0xe0, 0xff, 0x01, 0x7c, 0x7c, 0x00, 0xfc, 0x3f, 0xf8, 0x7f, 0x00, 0x7c,
+   0x7c, 0x00, 0xf2, 0x7f, 0xfc, 0x9f, 0x00, 0x7c, 0x7c, 0x80, 0xcf, 0x7f,
+   0xfd, 0xe7, 0x03, 0x7c, 0x7c, 0xe0, 0xbf, 0x7f, 0xfd, 0xf9, 0x0f, 0x7c,
+   0x7c, 0xf8, 0x7f, 0x7e, 0xfd, 0xfc, 0x3f, 0x7c, 0x7c, 0xfe, 0x0f, 0x7c,
+   0x7d, 0xe0, 0xff, 0x7c, 0xfc, 0xff, 0x83, 0x7d, 0x7d, 0x83, 0xff, 0x7f,
+   0xfc, 0xff, 0xe0, 0x7d, 0x7d, 0x0f, 0xfe, 0x7f, 0xfc, 0x3f, 0xf8, 0x7d,
+   0x7c, 0x3f, 0xf8, 0x7f, 0xfc, 0x0f, 0xfe, 0x7d, 0x7c, 0xff, 0xe0, 0x7f,
+   0xfc, 0x03, 0xff, 0x7d, 0x7c, 0xff, 0x81, 0x7f, 0xf8, 0xc0, 0xff, 0x7d,
+   0x7c, 0xff, 0x07, 0x3e, 0x30, 0xf0, 0xff, 0x7c, 0x7c, 0xfe, 0x1f, 0x18,
+   0x00, 0xfc, 0x3f, 0x7c, 0x7c, 0xf8, 0x7f, 0x00, 0x00, 0xff, 0x0f, 0x7c,
+   0x7c, 0xe0, 0xff, 0x01, 0x80, 0xff, 0x03, 0x7c, 0x7c, 0x80, 0xff, 0x03,
+   0x80, 0xff, 0x00, 0x7c, 0x7c, 0x00, 0xfe, 0x03, 0xc0, 0x3f, 0x00, 0x7c,
+   0x7c, 0x00, 0xf8, 0x07, 0xc0, 0x7f, 0x00, 0x7c, 0x7c, 0x00, 0xfc, 0x07,
+   0x80, 0xff, 0x01, 0x7c, 0x7c, 0x00, 0xff, 0x03, 0x80, 0xff, 0x07, 0x7c,
+   0x7c, 0xc0, 0xff, 0x03, 0x00, 0xfe, 0x1f, 0x7c, 0x7c, 0xf0, 0xff, 0x00,
+   0x00, 0xf8, 0x7f, 0x7c, 0x7c, 0xfc, 0x3f, 0x00, 0x00, 0xe0, 0xff, 0x7d,
+   0x7c, 0xff, 0x0f, 0x00, 0x00, 0x80, 0xff, 0x7f, 0xfc, 0xff, 0x03, 0x00,
+   0x00, 0x00, 0xfe, 0x7f, 0xfc, 0xff, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x7f,
+   0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0xfc, 0x0f, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x7f, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e,
+   0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x38, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/l-sun.xbm b/xlockmore-4.14/bitmaps/l-sun.xbm
new file mode 100644 (file)
index 0000000..681167f
--- /dev/null
@@ -0,0 +1,46 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0,
+   0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc,
+   0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x7e, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x40, 0xfe,
+   0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xfc, 0xfd, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0xfd, 0xfb, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xfb,
+   0xf7, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xf4, 0xf7, 0xef, 0x3f, 0x00, 0x00,
+   0x00, 0x00, 0xee, 0xef, 0xdf, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xdf, 0xdf,
+   0xbf, 0xff, 0x00, 0x00, 0x00, 0x80, 0xbf, 0xbf, 0x7f, 0xff, 0x00, 0x00,
+   0x00, 0x80, 0x7f, 0x7f, 0xff, 0x7e, 0x03, 0x00, 0x00, 0x60, 0xff, 0xfe,
+   0xfe, 0xbd, 0x07, 0x00, 0x00, 0xf0, 0xfe, 0xfd, 0xfd, 0xdb, 0x0f, 0x00,
+   0x00, 0xf8, 0xfd, 0xfb, 0xfb, 0xe7, 0x1f, 0x00, 0x00, 0xfc, 0xfb, 0xf7,
+   0xf7, 0xf7, 0x2f, 0x00, 0x00, 0xfe, 0xf5, 0xef, 0xef, 0xfb, 0x77, 0x00,
+   0x00, 0xff, 0xee, 0xdf, 0xcf, 0xfd, 0xfb, 0x00, 0x80, 0x7f, 0xdf, 0xbf,
+   0x9f, 0xfe, 0xfd, 0x01, 0xc0, 0xbf, 0xbf, 0xff, 0x1f, 0xff, 0xfe, 0x00,
+   0xe0, 0xdf, 0x1f, 0xff, 0x9f, 0x7f, 0x7f, 0x00, 0xf0, 0xef, 0x0f, 0xfe,
+   0xcf, 0xbf, 0x3f, 0x07, 0xf8, 0xf7, 0xe7, 0xfc, 0xef, 0xdf, 0xdf, 0x1f,
+   0xfc, 0xfb, 0xfb, 0xfb, 0xf7, 0xef, 0xef, 0x3f, 0xfe, 0xfd, 0xfd, 0xe7,
+   0xf9, 0xf7, 0xf7, 0x7f, 0xfe, 0xfe, 0xfe, 0x07, 0xf8, 0xfb, 0xfb, 0x7f,
+   0x7f, 0x7f, 0xff, 0x0f, 0xfc, 0xfd, 0xfd, 0xff, 0xbf, 0xbf, 0xff, 0x0f,
+   0xfc, 0xfe, 0xfe, 0xff, 0xff, 0xdf, 0xdf, 0x0f, 0xfc, 0x7f, 0xff, 0xfe,
+   0xff, 0xef, 0xef, 0x0f, 0xfc, 0xbf, 0x7f, 0xff, 0xfe, 0xf7, 0xf7, 0x07,
+   0xf8, 0xdf, 0xbf, 0x7f, 0xfe, 0xfb, 0xfb, 0xe7, 0xf9, 0xef, 0xdf, 0x7f,
+   0xfc, 0xfd, 0xfd, 0xfb, 0xf7, 0xf7, 0xef, 0x3f, 0x70, 0xfe, 0xfe, 0xfd,
+   0xcf, 0xf9, 0xf7, 0x1f, 0x00, 0x7f, 0xff, 0xfc, 0x1f, 0xfc, 0xfb, 0x0f,
+   0x80, 0xbf, 0x7f, 0xfe, 0x3f, 0xfe, 0xfd, 0x07, 0xc0, 0xdf, 0x3f, 0xfe,
+   0x7f, 0xff, 0xfe, 0x03, 0x80, 0xef, 0x5f, 0x7e, 0xff, 0x7e, 0xff, 0x01,
+   0x00, 0xf7, 0xef, 0xfc, 0xfe, 0xbd, 0xff, 0x00, 0x00, 0xfa, 0xf7, 0xfd,
+   0xfd, 0xdb, 0x7f, 0x00, 0x00, 0xfc, 0xfb, 0xfb, 0xfb, 0xe7, 0x3f, 0x00,
+   0x00, 0xf8, 0xf9, 0xf7, 0xf7, 0xef, 0x1f, 0x00, 0x00, 0xf0, 0xee, 0xef,
+   0xef, 0xdf, 0x0f, 0x00, 0x00, 0x60, 0xdf, 0xdf, 0xdf, 0xbf, 0x07, 0x00,
+   0x00, 0x80, 0xbf, 0xbf, 0xbf, 0x7f, 0x03, 0x00, 0x00, 0x80, 0x7f, 0x7f,
+   0x7f, 0xff, 0x00, 0x00, 0x00, 0x00, 0xff, 0xfe, 0xfe, 0xfe, 0x00, 0x00,
+   0x00, 0x00, 0xfe, 0xfd, 0xfd, 0x7d, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xfb,
+   0xfb, 0x3b, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xf7, 0xf7, 0x17, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0xef, 0xef, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xdf,
+   0xdf, 0x07, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xbf, 0x9f, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x7f, 0x3f, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff,
+   0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x3f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8,
+   0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/l-x11.xbm b/xlockmore-4.14/bitmaps/l-x11.xbm
new file mode 100644 (file)
index 0000000..96e306f
--- /dev/null
@@ -0,0 +1,46 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xfe, 0xff, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0xfc, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x7c,
+   0xf8, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x3e, 0xf8, 0xff, 0x07, 0x00,
+   0x00, 0x00, 0x00, 0x1f, 0xf0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x80, 0x0f,
+   0xe0, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x80, 0x0f, 0xc0, 0xff, 0x3f, 0x00,
+   0x00, 0x00, 0xc0, 0x07, 0xc0, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xe0, 0x03,
+   0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0xff, 0xff, 0x00,
+   0x00, 0x00, 0xf8, 0x00, 0x00, 0xfe, 0xff, 0x01, 0x00, 0x00, 0xf8, 0x00,
+   0x00, 0xfe, 0xff, 0x01, 0x00, 0x00, 0x7c, 0x00, 0x00, 0xfc, 0xff, 0x03,
+   0x00, 0x00, 0x3e, 0x00, 0x00, 0xf8, 0xff, 0x07, 0x00, 0x00, 0x1f, 0x00,
+   0x00, 0xf0, 0xff, 0x0f, 0x00, 0x80, 0x0f, 0x00, 0x00, 0xf0, 0xff, 0x0f,
+   0x00, 0xc0, 0x07, 0x00, 0x00, 0xe0, 0xff, 0x1f, 0x00, 0xc0, 0x07, 0x00,
+   0x00, 0xc0, 0xff, 0x3f, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x80, 0xff, 0x7f,
+   0x00, 0xf0, 0x01, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0xf8, 0x00, 0x00,
+   0x00, 0x00, 0xff, 0xff, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff,
+   0x01, 0x7c, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x03, 0x3e, 0x00, 0x00,
+   0x00, 0x00, 0xfc, 0xff, 0x03, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff,
+   0x87, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xcf, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0xe0, 0xff, 0xcf, 0x07, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff,
+   0xe7, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xf3, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0xff, 0xf9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff,
+   0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7f, 0xfe, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x7e, 0xfe, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3e,
+   0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9f, 0xff, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0xcf, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xe7,
+   0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xe7, 0xff, 0x1f, 0x00, 0x00,
+   0x00, 0x00, 0xe0, 0xc3, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xc1,
+   0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x80, 0xff, 0x7f, 0x00, 0x00,
+   0x00, 0x00, 0x7c, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00,
+   0xfe, 0xff, 0x01, 0x00, 0x00, 0x00, 0x3e, 0x00, 0xfe, 0xff, 0x01, 0x00,
+   0x00, 0x00, 0x1f, 0x00, 0xfc, 0xff, 0x03, 0x00, 0x00, 0x80, 0x0f, 0x00,
+   0xf8, 0xff, 0x07, 0x00, 0x00, 0xc0, 0x07, 0x00, 0xf0, 0xff, 0x0f, 0x00,
+   0x00, 0xe0, 0x03, 0x00, 0xf0, 0xff, 0x0f, 0x00, 0x00, 0xe0, 0x03, 0x00,
+   0xe0, 0xff, 0x1f, 0x00, 0x00, 0xf0, 0x01, 0x00, 0xc0, 0xff, 0x3f, 0x00,
+   0x00, 0xf8, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x7c, 0x00, 0x00,
+   0x80, 0xff, 0x7f, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00,
+   0x00, 0x3e, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x01, 0x00, 0x1f, 0x00, 0x00,
+   0x00, 0xfc, 0xff, 0x03, 0x80, 0x0f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x03,
+   0xc0, 0x07, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x07, 0xe0, 0x03, 0x00, 0x00,
+   0x00, 0xf0, 0xff, 0x0f, 0xe0, 0x03, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x1f,
+   0xf0, 0x01, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x1f, 0xf8, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0xff, 0x3f, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f,
+   0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff};
diff --git a/xlockmore-4.14/bitmaps/l-xlock.xbm b/xlockmore-4.14/bitmaps/l-xlock.xbm
new file mode 100644 (file)
index 0000000..696a608
--- /dev/null
@@ -0,0 +1,55 @@
+#define image_width 100
+#define image_height 48
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xfc, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x80, 0x0f, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xe0, 0x03,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x00, 0x00, 0x00, 0xf0,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, 0x00, 0x00,
+   0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00,
+   0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x07,
+   0x00, 0x00, 0x3e, 0x00, 0x00, 0xc0, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff,
+   0x0f, 0x00, 0x00, 0x1f, 0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0xfc,
+   0xff, 0x1f, 0x00, 0x80, 0x0f, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00,
+   0xf8, 0xff, 0x3f, 0x00, 0xc0, 0x07, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00,
+   0x00, 0xf0, 0xff, 0x7f, 0x00, 0xe0, 0x03, 0x00, 0x00, 0xfe, 0xff, 0x1f,
+   0x00, 0x00, 0xe0, 0xff, 0xff, 0x00, 0xf0, 0x01, 0x00, 0x00, 0xfe, 0xff,
+   0x1f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, 0xf8, 0x00, 0x00, 0x00, 0xff,
+   0xe1, 0x3f, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x7c, 0x00, 0x00, 0x00,
+   0xff, 0xc0, 0x3f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x07, 0x3e, 0x00, 0x00,
+   0x00, 0x7f, 0x80, 0x3f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x0f, 0x1f, 0x00,
+   0x00, 0x00, 0x3f, 0x00, 0x3f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x8f, 0x0f,
+   0x00, 0x00, 0x00, 0x3f, 0x00, 0x3f, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xc7,
+   0x07, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x3f, 0x00, 0x00, 0x00, 0xf0, 0xff,
+   0xe3, 0x03, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x3f, 0x00, 0x00, 0x00, 0xe0,
+   0xff, 0xf1, 0x01, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x3f, 0x00, 0x00, 0x00,
+   0xc0, 0xff, 0xf8, 0x01, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x3f, 0x00, 0x00,
+   0x00, 0x80, 0x7f, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x00,
+   0x00, 0x00, 0x00, 0x3f, 0xfe, 0x07, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff,
+   0x03, 0x00, 0x00, 0x00, 0x1f, 0xff, 0x0f, 0x00, 0x00, 0xf0, 0xff, 0xff,
+   0xff, 0x03, 0x00, 0x00, 0x80, 0x8f, 0xff, 0x1f, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0xff, 0x03, 0x00, 0x00, 0xc0, 0xc7, 0xff, 0x3f, 0x00, 0x00, 0xf0,
+   0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xe0, 0xe3, 0xff, 0x7f, 0x00, 0x00,
+   0xf0, 0x3f, 0x3f, 0xff, 0x03, 0x00, 0x00, 0xf0, 0xe1, 0xff, 0xff, 0x00,
+   0x00, 0xf0, 0x3f, 0x3f, 0xff, 0x03, 0x00, 0x00, 0xf8, 0xc0, 0xff, 0xff,
+   0x01, 0x00, 0xf0, 0x3c, 0x00, 0xcf, 0x03, 0x00, 0x00, 0x7c, 0x80, 0xff,
+   0xff, 0x03, 0x00, 0xf0, 0x3c, 0x00, 0xcf, 0x03, 0x00, 0x00, 0x3e, 0x00,
+   0xff, 0xff, 0x07, 0x00, 0xf0, 0x3c, 0x3f, 0xcf, 0x03, 0x00, 0x00, 0x1f,
+   0x00, 0xfe, 0xff, 0x0f, 0x00, 0xf0, 0x3c, 0x3f, 0xcf, 0x03, 0x00, 0x80,
+   0x0f, 0x00, 0xfc, 0xff, 0x1f, 0x00, 0xf0, 0x3c, 0x00, 0xcf, 0x03, 0x00,
+   0xc0, 0x07, 0x00, 0xf8, 0xff, 0x3f, 0x00, 0xf0, 0x3c, 0x00, 0xcf, 0x03,
+   0x00, 0xe0, 0x03, 0x00, 0xf0, 0xff, 0x7f, 0x00, 0xf0, 0x3c, 0x3f, 0xcf,
+   0x03, 0x00, 0xf0, 0x01, 0x00, 0xe0, 0xff, 0xff, 0x00, 0xf0, 0x3c, 0x3f,
+   0xcf, 0x03, 0x00, 0xf8, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, 0xf0, 0x3c,
+   0x00, 0xcf, 0x03, 0x00, 0x7c, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0xf0,
+   0x3c, 0x00, 0xcf, 0x03, 0x00, 0x3e, 0x00, 0x00, 0x00, 0xff, 0xff, 0x07,
+   0xf0, 0x3c, 0x3f, 0xcf, 0x03, 0x00, 0x1f, 0x00, 0x00, 0x00, 0xfe, 0xff,
+   0x0f, 0xf0, 0x3c, 0x3f, 0xcf, 0x03, 0x80, 0x0f, 0x00, 0x00, 0x00, 0xfc,
+   0xff, 0x1f, 0xf0, 0xff, 0xff, 0xff, 0x03, 0xc0, 0x07, 0x00, 0x00, 0x00,
+   0xf8, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0xff, 0x03, 0xe0, 0x03, 0x00, 0x00,
+   0x00, 0xf0, 0xff, 0x7f, 0xf0, 0xff, 0xff, 0xff, 0x03, 0xf0, 0x01, 0x00,
+   0x00, 0x00, 0xe0, 0xff, 0xff, 0xf0, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/light_gray.xbm b/xlockmore-4.14/bitmaps/light_gray.xbm
new file mode 100644 (file)
index 0000000..ed1e0be
--- /dev/null
@@ -0,0 +1,4 @@
+#define light_gray_width 4
+#define light_gray_height 2
+static unsigned char light_gray_bits[] = {
+   0x08, 0x02};
diff --git a/xlockmore-4.14/bitmaps/m-bob.xbm b/xlockmore-4.14/bitmaps/m-bob.xbm
new file mode 100644 (file)
index 0000000..f6ba484
--- /dev/null
@@ -0,0 +1,43 @@
+#define image_width 61
+#define image_height 75
+static unsigned char image_bits[] = {
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0x07,0x00,
+ 0x00,0x00,0x00,0xfe,0xff,0xff,0x1f,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0xfb,
+ 0x00,0x00,0x00,0xc0,0xff,0xcf,0x9f,0xd1,0x03,0x00,0x00,0xf0,0x7f,0x8c,0x33,
+ 0x91,0x07,0x00,0x00,0xf8,0xa7,0x18,0x27,0xb1,0x06,0x00,0x00,0xfc,0x47,0x31,
+ 0x4e,0xa6,0x0e,0x00,0x00,0xfe,0x4f,0x21,0x4c,0xae,0x3d,0x00,0x00,0xff,0xdf,
+ 0x23,0x8d,0xbe,0x7d,0x00,0x80,0xff,0xff,0x67,0xbd,0xfe,0xff,0x01,0x80,0xff,
+ 0xff,0x7f,0xbf,0xff,0xff,0x03,0xc0,0xff,0xff,0xff,0xbf,0xff,0xf8,0x07,0xc0,
+ 0xff,0xff,0xff,0xbf,0x3f,0xf8,0x07,0xc0,0xff,0xff,0xff,0xff,0x07,0xf8,0x0f,
+ 0xc0,0xff,0xff,0xff,0x3f,0x00,0xf8,0x0f,0xe0,0x7f,0x00,0xf8,0x07,0x00,0xf0,
+ 0x0f,0xe0,0x3f,0x00,0x00,0x00,0x00,0xf0,0x07,0xe0,0x3f,0x00,0x00,0x00,0x00,
+ 0xf0,0x07,0xe0,0x3f,0x00,0x00,0x00,0x00,0xf4,0x07,0xe0,0x3f,0x00,0x00,0x00,
+ 0x00,0xe4,0x07,0xe0,0x3f,0x00,0x00,0x00,0x00,0xe4,0x07,0xe0,0x3f,0x00,0x00,
+ 0x00,0x00,0xe6,0x07,0xe0,0x3f,0x00,0x00,0x00,0x00,0xe7,0x07,0xe0,0x3f,0x00,
+ 0x00,0x00,0x00,0xe6,0x07,0xe0,0x3f,0x00,0x00,0x00,0x00,0xe6,0x07,0xe0,0x3f,
+ 0x00,0x00,0x00,0x00,0xe6,0x07,0xc0,0x3f,0x00,0x00,0x00,0x78,0xf6,0x07,0xa0,
+ 0xbf,0xff,0x00,0x00,0xff,0xf7,0x07,0x70,0x9f,0xff,0x01,0x80,0xff,0xef,0x07,
+ 0xf0,0x1c,0x80,0x03,0xe0,0x01,0xef,0x07,0xf0,0x1f,0xbe,0x07,0xf0,0x3f,0xee,
+ 0x07,0xe0,0x9d,0x83,0x1f,0xf8,0xe1,0xdc,0x07,0xe0,0xc1,0x7f,0x1f,0xfc,0xff,
+ 0xc8,0x07,0xe0,0xc1,0x69,0x1e,0x7e,0xca,0xc0,0x03,0xe0,0x81,0xb8,0x1f,0xc0,
+ 0x0e,0xc0,0x03,0xe0,0x01,0xc0,0x1b,0xc0,0xcf,0xc1,0x03,0xc0,0x03,0xf7,0x11,
+ 0x00,0x7f,0xc0,0x03,0xc0,0x03,0x7c,0x18,0x00,0x1c,0xc0,0x02,0xc0,0x02,0x30,
+ 0x08,0x00,0x00,0x40,0x03,0x40,0x03,0x00,0x08,0x00,0x00,0x40,0x02,0x40,0x13,
+ 0x00,0x0c,0x00,0x00,0x60,0x02,0x40,0x12,0x00,0x0e,0x00,0x00,0xc0,0x03,0x80,
+ 0x33,0x80,0x0e,0x00,0x00,0xa8,0x01,0x00,0x33,0x40,0x0f,0xa0,0x03,0x2c,0x00,
+ 0x00,0x74,0x30,0x0f,0x38,0x07,0x2e,0x00,0x00,0x74,0x98,0x1f,0x1e,0x1e,0x2f,
+ 0x00,0x00,0xfc,0x8f,0xff,0x0f,0xfc,0x2f,0x00,0x00,0xf8,0xe3,0xff,0x03,0xf8,
+ 0x2f,0x00,0x00,0xf8,0xfd,0xff,0x81,0xff,0x3f,0x00,0x00,0xb8,0xf9,0x1f,0xf8,
+ 0x0f,0x1e,0x00,0x00,0x30,0xf1,0xf0,0x0f,0x03,0x0e,0x00,0x00,0x30,0xf1,0x01,
+ 0x80,0x01,0x0f,0x00,0x00,0x20,0xf1,0xf7,0xff,0x00,0x07,0x00,0x00,0x60,0xe3,
+ 0x01,0x60,0x80,0x07,0x00,0x00,0x60,0xc3,0xef,0x3f,0x80,0x03,0x00,0x00,0x40,
+ 0xc2,0xff,0x0f,0xc0,0x03,0x00,0x00,0xc0,0xe6,0x1f,0x00,0xc0,0x01,0x00,0x00,
+ 0x80,0xf4,0xfe,0x3f,0xe0,0x00,0x00,0x00,0x80,0x79,0xfe,0x1f,0xe0,0x00,0x00,
+ 0xc0,0x01,0x3d,0x3e,0x00,0x70,0x00,0x00,0x30,0x06,0x3e,0x0f,0x00,0x38,0x00,
+ 0x00,0xc8,0x8c,0x1f,0x07,0x00,0x38,0x00,0x00,0xf4,0xcc,0x8f,0x07,0x00,0x1c,
+ 0x00,0x00,0x72,0xee,0xf7,0x07,0x00,0x0e,0x00,0x00,0x02,0xff,0xe3,0x07,0x00,
+ 0x07,0x00,0x00,0x32,0xfe,0xc1,0xff,0x8f,0x03,0x00,0x00,0x3e,0xfe,0x80,0xff,
+ 0xff,0x01,0x00,0x00,0x7e,0x7c,0x00,0x00,0x7e,0x00,0x00,0x00,0x7c,0x3c,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0xfc,0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x1c,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,
+ 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};
diff --git a/xlockmore-4.14/bitmaps/m-bsd.xbm b/xlockmore-4.14/bitmaps/m-bsd.xbm
new file mode 100644 (file)
index 0000000..8cb527f
--- /dev/null
@@ -0,0 +1,39 @@
+#define image_width 50
+#define image_height 50
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xe3, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x80, 0x1e, 0x06, 0x14, 0x00,
+   0x00, 0x00, 0x80, 0x06, 0x1c, 0x3c, 0x00, 0x00, 0x00, 0x80, 0x03, 0x38,
+   0x28, 0x00, 0x00, 0x00, 0x00, 0x01, 0x70, 0x2c, 0x00, 0x00, 0x00, 0x00,
+   0x19, 0xe0, 0x27, 0x00, 0x00, 0x00, 0x00, 0x25, 0x03, 0x30, 0x00, 0x00,
+   0x00, 0x80, 0xa4, 0x04, 0x18, 0x00, 0x00, 0x00, 0x80, 0xbe, 0x04, 0x07,
+   0x00, 0x00, 0x00, 0x40, 0x9a, 0x45, 0x01, 0x00, 0x00, 0x00, 0x20, 0x5e,
+   0x85, 0x00, 0x00, 0x00, 0x00, 0x20, 0xcc, 0x87, 0x00, 0x00, 0x00, 0x80,
+   0x20, 0xc4, 0xc3, 0x00, 0x00, 0x00, 0x80, 0x23, 0x84, 0x81, 0x00, 0x00,
+   0x00, 0x00, 0x43, 0x3d, 0x60, 0x00, 0x00, 0x00, 0x20, 0x86, 0x02, 0x70,
+   0x00, 0x00, 0x00, 0xe0, 0x06, 0x8d, 0x39, 0x00, 0x00, 0x00, 0xc0, 0x06,
+   0x7a, 0x1c, 0x00, 0x00, 0x00, 0x88, 0x07, 0x06, 0x0e, 0x00, 0x00, 0x00,
+   0x18, 0xcf, 0xfa, 0x06, 0x00, 0x00, 0x00, 0xf0, 0x3f, 0x03, 0x06, 0x00,
+   0x00, 0x00, 0xc0, 0x38, 0x04, 0x04, 0x00, 0x00, 0x00, 0x00, 0x10, 0x03,
+   0x0c, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00,
+   0x50, 0x34, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x30, 0x7d, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0xa0, 0x02, 0x04, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x04,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc5, 0x05, 0x00, 0x00, 0x00, 0x00, 0x80, 0xe8, 0x07, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x10, 0x07, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x0e, 0x00,
+   0x00, 0x00, 0x00, 0x80, 0x00, 0x7a, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01,
+   0xc8, 0x01, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x74, 0x3f, 0x00, 0x00, 0x00,
+   0x00, 0x53, 0x88, 0xdf, 0x01, 0x00, 0x00, 0x80, 0x25, 0x09, 0xf0, 0x07,
+   0x00, 0x00, 0x70, 0x9d, 0x18, 0x00, 0x0e, 0x00, 0x00, 0x4c, 0x4f, 0x18,
+   0x00, 0x0c, 0x00, 0x00, 0x82, 0x3c, 0x0c, 0x80, 0x0e, 0x00, 0x00, 0x41,
+   0x48, 0x03, 0xc0, 0x07, 0x00, 0x00, 0x3e, 0xc0, 0x01, 0x60, 0x01, 0x00,
+   0x00, 0xc0, 0x3f, 0x00, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00};
+
+/*
+ * BSD daemon
+ * The original BSD daemon is Copyright (c) 1988 Marshall Kirk McKusick.
+ * All Rights Reserved.  Used by permission.
+ */
diff --git a/xlockmore-4.14/bitmaps/m-dec.xbm b/xlockmore-4.14/bitmaps/m-dec.xbm
new file mode 100644 (file)
index 0000000..d737889
--- /dev/null
@@ -0,0 +1,27 @@
+#define image_width 82
+#define image_height 26
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe,
+   0xef, 0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef,
+   0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f,
+   0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0xff,
+   0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0xff, 0xf7,
+   0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xec, 0x79, 0xff, 0xf7, 0xbc,
+   0xff, 0xfb, 0xbf, 0xe7, 0x01, 0xfe, 0xec, 0x79, 0xff, 0xf7, 0xbc, 0xc7,
+   0xfb, 0xbf, 0xe7, 0x01, 0xfe, 0xec, 0x79, 0xff, 0xf7, 0xbc, 0xc7, 0xfb,
+   0xbf, 0xe7, 0x01, 0xfe, 0xec, 0x7f, 0xff, 0xf7, 0xbf, 0xc7, 0xfb, 0xbf,
+   0xe7, 0x01, 0x0e, 0xec, 0x79, 0x0f, 0xf6, 0xbc, 0x83, 0x3b, 0xb8, 0xe7,
+   0x01, 0x06, 0xec, 0x79, 0x07, 0xf6, 0xbc, 0x83, 0x1b, 0xb0, 0xe7, 0x01,
+   0x46, 0xec, 0x79, 0x23, 0xf6, 0xbc, 0xc7, 0xfb, 0xb1, 0xe7, 0x01, 0xe6,
+   0xec, 0x79, 0x73, 0xf6, 0xbc, 0xc7, 0x3b, 0xb0, 0xe7, 0x01, 0xe6, 0xec,
+   0x79, 0x73, 0xf6, 0xbc, 0xc7, 0x1b, 0xb0, 0xe7, 0x01, 0xe6, 0xec, 0x79,
+   0x73, 0xf6, 0xbc, 0xc7, 0x9b, 0xb1, 0xe7, 0x01, 0x46, 0xec, 0x79, 0x23,
+   0xf6, 0xbc, 0xc7, 0x9b, 0xb1, 0xe7, 0x01, 0x06, 0xec, 0x79, 0x07, 0xf6,
+   0xbc, 0x87, 0x1b, 0xb0, 0xe7, 0x01, 0x1e, 0xec, 0x79, 0x0f, 0xf6, 0xbc,
+   0x8f, 0x3b, 0xb0, 0xe7, 0x01, 0xfe, 0xef, 0x7f, 0x7f, 0xf6, 0xbf, 0xff,
+   0xfb, 0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0x23, 0xf6, 0xbf, 0xff, 0xfb,
+   0xbf, 0xff, 0x01, 0xfe, 0xef, 0x7f, 0x07, 0xf7, 0xbf, 0xff, 0xfb, 0xbf,
+   0xff, 0x01, 0xfe, 0xef, 0x7f, 0x9f, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff,
+   0x01, 0xfe, 0xef, 0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01,
+   0xfe, 0xef, 0x7f, 0xff, 0xf7, 0xbf, 0xff, 0xfb, 0xbf, 0xff, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/m-ghost.xbm b/xlockmore-4.14/bitmaps/m-ghost.xbm
new file mode 100644 (file)
index 0000000..fa40be1
--- /dev/null
@@ -0,0 +1,41 @@
+#define image_width 58
+#define image_height 57
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0xf8, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff,
+   0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff,
+   0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00,
+   0x00, 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff,
+   0xff, 0xff, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00,
+   0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0x07, 0xff,
+   0xff, 0xc1, 0x07, 0x00, 0x00, 0xff, 0x03, 0xfe, 0xff, 0x80, 0x1f, 0x00,
+   0x80, 0xff, 0x01, 0xfc, 0x7f, 0x00, 0x1f, 0x00, 0x80, 0xff, 0x01, 0xfc,
+   0x7f, 0x00, 0x3f, 0x00, 0xc0, 0xff, 0x80, 0xf9, 0x3f, 0x40, 0x3e, 0x00,
+   0xe0, 0x7f, 0xc0, 0xfb, 0x1f, 0xf0, 0x7e, 0x00, 0xf0, 0x7f, 0xf0, 0xf3,
+   0x1f, 0xf8, 0x7c, 0x00, 0xf0, 0x3f, 0xf8, 0xf7, 0x0f, 0xfc, 0x7d, 0x00,
+   0xf8, 0x3f, 0xfc, 0xf3, 0x0f, 0xfe, 0x7c, 0x00, 0xf8, 0x3f, 0xfe, 0xfb,
+   0x0f, 0xff, 0xfe, 0x00, 0xf8, 0x3f, 0xfe, 0xfb, 0x0f, 0xff, 0xfe, 0x00,
+   0xfc, 0x3f, 0xfe, 0xf9, 0x0f, 0x7f, 0xfe, 0x00, 0xfc, 0x7f, 0xff, 0xf9,
+   0x9f, 0x7f, 0xfe, 0x00, 0xfe, 0x7f, 0xfe, 0xfc, 0x9f, 0x3f, 0xff, 0x01,
+   0xfe, 0xff, 0xfc, 0xfe, 0x3f, 0x9f, 0xff, 0x01, 0xfe, 0xff, 0x39, 0xff,
+   0x7f, 0xc0, 0xff, 0x01, 0xff, 0xff, 0x87, 0xff, 0xff, 0xe1, 0xff, 0x01,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x01, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0x3f, 0xde,
+   0xf3, 0xff, 0xff, 0x03, 0xff, 0xff, 0x07, 0xde, 0x83, 0xff, 0xff, 0x03,
+   0xff, 0xff, 0x03, 0xde, 0x03, 0xf8, 0xff, 0x03, 0xff, 0xff, 0x01, 0xde,
+   0x03, 0xe0, 0xff, 0x03, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x03,
+   0xff, 0x3f, 0x80, 0xff, 0x1f, 0x80, 0xff, 0x03, 0xff, 0x1f, 0xf0, 0xff,
+   0xff, 0x03, 0xff, 0x03, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0x0f, 0xfe, 0x03,
+   0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, 0xfe, 0x03, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x03, 0xff, 0xfd, 0xf7, 0xef, 0xef, 0xef, 0xdf, 0x03,
+   0x7f, 0xf8, 0xe1, 0xc7, 0xc7, 0xcf, 0x8f, 0x03, 0x3e, 0xf0, 0xc0, 0xc3,
+   0x83, 0x87, 0x07, 0x03, 0x1c, 0x60, 0x80, 0x01, 0x00, 0x03, 0x03, 0x00};
diff --git a/xlockmore-4.14/bitmaps/m-grelb.xbm b/xlockmore-4.14/bitmaps/m-grelb.xbm
new file mode 100644 (file)
index 0000000..acadb2d
--- /dev/null
@@ -0,0 +1,25 @@
+#define image_width 40
+#define image_height 44
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x1f, 0x00, 0xf0, 0x03, 0x40, 0x30, 0x00, 0x18, 0x04, 0x00,
+   0x20, 0xff, 0x09, 0x00, 0x00, 0xe0, 0xff, 0x0f, 0x00, 0x00, 0xf8, 0xff,
+   0x3f, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0xff, 0x01,
+   0x80, 0xff, 0xff, 0xff, 0x03, 0x80, 0xff, 0xff, 0xff, 0x03, 0xc0, 0x1f,
+   0xff, 0xf1, 0x07, 0xc0, 0x0f, 0xfe, 0xe0, 0x07, 0xc0, 0x0f, 0xfe, 0xe0,
+   0x07, 0xc0, 0x1f, 0xff, 0xf1, 0x07, 0xc0, 0xff, 0xff, 0xff, 0x07, 0x80,
+   0xff, 0xff, 0xff, 0x03, 0x80, 0xff, 0xff, 0xff, 0x03, 0x00, 0xff, 0xff,
+   0xff, 0x01, 0x00, 0xfe, 0xff, 0xff, 0x00, 0x00, 0xf8, 0xff, 0x3f, 0x00,
+   0x00, 0xe0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0xff, 0x01, 0x00, 0x00, 0x00,
+   0xc7, 0x01, 0x00, 0x00, 0x00, 0xc6, 0x00, 0x00, 0x00, 0x00, 0xc6, 0x00,
+   0x00, 0x00, 0x00, 0xc6, 0x00, 0x00, 0x00, 0x00, 0xc6, 0x00, 0x00, 0x00,
+   0x00, 0x82, 0x00, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, 0x00, 0x82,
+   0x00, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00,
+   0x00, 0xfe, 0x83, 0xff, 0x00, 0x00, 0xff, 0xc7, 0xff, 0x01, 0x00, 0xfe,
+   0x83, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00};
+/*
+ *      "Life.  Don't talk to me about life" -Marvin the Paranoid Android
+ */
diff --git a/xlockmore-4.14/bitmaps/m-hp.xbm b/xlockmore-4.14/bitmaps/m-hp.xbm
new file mode 100644 (file)
index 0000000..1be3800
--- /dev/null
@@ -0,0 +1,20 @@
+#define image_width 46
+#define image_height 34
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xe0, 0xff, 0x79, 0xfe, 0xff, 0xc1,
+   0xf8, 0xff, 0x39, 0xfe, 0xff, 0xc7, 0xfc, 0xff, 0x3d, 0xfc, 0xff, 0xcf,
+   0xfc, 0xff, 0x3c, 0xe0, 0xff, 0xcf, 0xfe, 0x7f, 0x1c, 0x80, 0xff, 0xdf,
+   0xfe, 0x3f, 0x1c, 0x00, 0xff, 0xdf, 0xfe, 0x1f, 0x1e, 0x00, 0xfe, 0xdf,
+   0xfe, 0x0f, 0x1e, 0x00, 0xfc, 0xdf, 0xfe, 0x07, 0x0e, 0x00, 0xf8, 0xdf,
+   0xfe, 0x07, 0x0f, 0x00, 0xf8, 0xdf, 0xfe, 0x03, 0x7f, 0xfc, 0xf1, 0xdf,
+   0xfe, 0x03, 0xff, 0xfc, 0xf3, 0xdf, 0xfe, 0x03, 0xff, 0xfc, 0xf3, 0xdf,
+   0xfe, 0x81, 0xf7, 0xde, 0xe3, 0xdf, 0xfe, 0x81, 0x77, 0xde, 0xe1, 0xdf,
+   0xfe, 0x81, 0x73, 0xce, 0xe1, 0xdf, 0xfe, 0xc1, 0x7b, 0xee, 0xe1, 0xdf,
+   0xfe, 0xc1, 0x7b, 0xef, 0xe1, 0xdf, 0xfe, 0xc1, 0x3b, 0xe7, 0xe0, 0xdf,
+   0xfe, 0xc3, 0x39, 0xff, 0xf0, 0xdf, 0xfe, 0xe3, 0xbd, 0xff, 0xf0, 0xdf,
+   0xfe, 0xe3, 0xbd, 0x7f, 0xf0, 0xdf, 0xfe, 0x07, 0x80, 0x03, 0xf8, 0xdf,
+   0xfe, 0x07, 0x80, 0x03, 0xf8, 0xdf, 0xfe, 0x0f, 0xc0, 0x03, 0xfc, 0xdf,
+   0xfe, 0x1f, 0xc0, 0x03, 0xfe, 0xdf, 0xfe, 0x3f, 0xc0, 0x01, 0xff, 0xdf,
+   0xfe, 0x7f, 0xc0, 0x81, 0xff, 0xdf, 0xfc, 0xff, 0xe1, 0xe1, 0xff, 0xcf,
+   0xfc, 0xff, 0xe7, 0xfc, 0xff, 0xcf, 0xf8, 0xff, 0xe7, 0xfc, 0xff, 0xc7,
+   0xe0, 0xff, 0xf3, 0xfc, 0xff, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0};
diff --git a/xlockmore-4.14/bitmaps/m-ibm.xbm b/xlockmore-4.14/bitmaps/m-ibm.xbm
new file mode 100644 (file)
index 0000000..203c6de
--- /dev/null
@@ -0,0 +1,32 @@
+#define image_width 78
+#define image_height 34
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xfc, 0xff, 0xf8, 0xff,
+   0x3f, 0xf0, 0xff, 0x00, 0xff, 0xcf, 0xfc, 0xff, 0xf8, 0xff, 0x7f, 0xf0,
+   0xff, 0x00, 0xff, 0xcf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0xfc, 0xff, 0xf8, 0xff, 0xff, 0xf1, 0xff, 0xc1, 0xff, 0xcf, 0xfc, 0xff,
+   0xf8, 0xff, 0xff, 0xf1, 0xff, 0xc1, 0xff, 0xcf, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0xff, 0xe3,
+   0xff, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0xff, 0xe3, 0xff, 0xc0,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xc0, 0x0f, 0x80, 0xff,
+   0xff, 0x00, 0xff, 0xf7, 0xff, 0xc0, 0xc0, 0x0f, 0x80, 0xff, 0x7f, 0x00,
+   0xff, 0xff, 0xff, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0xc0, 0x0f, 0x80, 0xff, 0x7f, 0x00, 0xbf, 0xff, 0xfd, 0xc0, 0xc0, 0x0f,
+   0x80, 0xff, 0x7f, 0x00, 0xbf, 0xff, 0xfd, 0xc0, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0x3f, 0x7f,
+   0xfc, 0xc0, 0xc0, 0x0f, 0x80, 0x1f, 0xf8, 0x01, 0x3f, 0x7f, 0xfc, 0xc0,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xfc, 0xff, 0xf8, 0xff,
+   0xff, 0xf1, 0x3f, 0x3e, 0xfc, 0xcf, 0xfc, 0xff, 0xf8, 0xff, 0xff, 0xf1,
+   0x3f, 0x3e, 0xfc, 0xcf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0xfc, 0xff, 0xf8, 0xff, 0x7f, 0xf0, 0x3f, 0x1c, 0xfc, 0xcf, 0xfc, 0xff,
+   0xf8, 0xff, 0x3f, 0xf0, 0x3f, 0x1c, 0xfc, 0xcf, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0};
diff --git a/xlockmore-4.14/bitmaps/m-linux.xbm b/xlockmore-4.14/bitmaps/m-linux.xbm
new file mode 100644 (file)
index 0000000..db3befe
--- /dev/null
@@ -0,0 +1,53 @@
+#define image_width 64
+#define image_height 75
+static unsigned char image_bits[] = {
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07,
+   0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x80, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00,
+   0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xfc, 0xff, 0xff,
+   0xff, 0xff, 0x3f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00,
+   0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xf0, 0xff, 0xff,
+   0xff, 0xff, 0x1f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00,
+   0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x04, 0x1c, 0xf0, 0xff, 0xff,
+   0xff, 0xff, 0x1f, 0x07, 0x3f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x0f,
+   0x7f, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x9f, 0x08, 0x63, 0xe0, 0xff, 0xff,
+   0xff, 0xff, 0xbf, 0x1c, 0x61, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xbf, 0x08,
+   0x61, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xf9, 0x61, 0xe0, 0xff, 0xff,
+   0xff, 0xff, 0x3f, 0x69, 0x37, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfe,
+   0x3d, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xba, 0x6f, 0xe0, 0xff, 0xff,
+   0xff, 0xff, 0x3f, 0xf7, 0x5b, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x7d,
+   0x6b, 0xc0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfc, 0x1c, 0xc0, 0xff, 0xff,
+   0xff, 0xff, 0x3f, 0x01, 0x77, 0x80, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xd7,
+   0xf9, 0x80, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x27, 0xfe, 0x00, 0xff, 0xff,
+   0xff, 0xff, 0x1f, 0xdf, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x8f, 0xff,
+   0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0x8f, 0xff, 0xff, 0x03, 0xfc, 0xff,
+   0xff, 0xff, 0xc7, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0xff, 0xe3, 0xff,
+   0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0xe1, 0xff, 0xff, 0x03, 0xf0, 0xff,
+   0xff, 0xff, 0xe1, 0xff, 0xff, 0x07, 0xe0, 0xff, 0xff, 0xff, 0xf0, 0xff,
+   0xff, 0x07, 0xe0, 0xff, 0xff, 0x7f, 0xe0, 0xff, 0xff, 0x0f, 0xc0, 0xff,
+   0xff, 0x7f, 0xf0, 0xff, 0xff, 0x0f, 0x80, 0xff, 0xff, 0x3f, 0xf8, 0xff,
+   0xff, 0x1f, 0x80, 0xff, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0xff,
+   0xff, 0x3f, 0xfc, 0xff, 0xff, 0x3f, 0x00, 0xff, 0xff, 0x1f, 0xfc, 0xff,
+   0xff, 0x3f, 0x00, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0x3f, 0x00, 0xfe,
+   0xff, 0x0f, 0xfe, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0x0f, 0xff, 0xff,
+   0xff, 0x7f, 0x00, 0xfe, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfc,
+   0xff, 0x07, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfc, 0xff, 0x07, 0xff, 0xff,
+   0xff, 0x7f, 0x00, 0xfc, 0xff, 0x83, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfc,
+   0xff, 0x81, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfc, 0xff, 0x81, 0xff, 0xff,
+   0xff, 0x7f, 0x00, 0xfc, 0xff, 0x81, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfc,
+   0xff, 0x89, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfc, 0xff, 0xbf, 0xff, 0xff,
+   0xff, 0x7f, 0x00, 0xfc, 0xff, 0x77, 0xfe, 0xff, 0xff, 0x7f, 0x00, 0xfe,
+   0xff, 0xdd, 0xfc, 0xff, 0xff, 0xf7, 0x00, 0xff, 0xff, 0xfe, 0xf9, 0xff,
+   0xff, 0x5f, 0x00, 0xff, 0x7f, 0x6b, 0xf1, 0xff, 0xff, 0x77, 0x80, 0xfd,
+   0x5f, 0xff, 0xe3, 0xff, 0xff, 0x6f, 0xc1, 0xff, 0xed, 0xb5, 0x82, 0xff,
+   0xff, 0xbf, 0xea, 0xfe, 0xbd, 0xff, 0x07, 0xff, 0xff, 0x6f, 0x5b, 0xff,
+   0xf7, 0xde, 0x0b, 0xfe, 0xff, 0xe7, 0xf5, 0xfb, 0xbf, 0xb7, 0x0e, 0xfe,
+   0xff, 0x57, 0xbf, 0xfd, 0x6b, 0xfb, 0x1b, 0xfe, 0xff, 0xef, 0xed, 0xee,
+   0xfd, 0x5f, 0xbf, 0xff, 0xff, 0xb1, 0xfb, 0xbd, 0xb7, 0xfd, 0xab, 0xff,
+   0xff, 0xd0, 0xef, 0xf7, 0xed, 0xaf, 0xfe, 0xff, 0x7f, 0x60, 0xbf, 0xff,
+   0xbb, 0xfb, 0x5b, 0xff, 0x1f, 0xf0, 0xfb, 0xad, 0xfd, 0xbe, 0x7f, 0xfe,
+   0x07, 0x50, 0x6f, 0xff, 0xd7, 0xf7, 0xaa, 0x00, 0x00, 0xf0, 0xdd, 0xf7,
+   0x6b, 0xdd, 0x7f, 0x00, 0x00, 0xd0, 0xff, 0xfc, 0xa9, 0x76, 0xaf, 0x00,
+   0x00, 0xa8, 0x56, 0xff, 0x5f, 0xa9, 0x35, 0x00, 0x00, 0x60, 0xab, 0xff,
+   0xff, 0xa5, 0x16, 0xfc, 0xff, 0x93, 0xca, 0xff, 0xff, 0x9f, 0x48, 0xff,
+   0xff, 0x47, 0xe5, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff};
diff --git a/xlockmore-4.14/bitmaps/m-linux1.xbm b/xlockmore-4.14/bitmaps/m-linux1.xbm
new file mode 100644 (file)
index 0000000..4d155e5
--- /dev/null
@@ -0,0 +1,46 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x02, 0x00,
+   0x20, 0x00, 0x00, 0xc2, 0x12, 0x00, 0x00, 0x01, 0x00, 0x10, 0x00, 0x40,
+   0x46, 0x00, 0x01, 0x04, 0x10, 0x40, 0x00, 0x61, 0x04, 0x20, 0x80, 0x00,
+   0x02, 0x08, 0x20, 0x20, 0x2c, 0x84, 0x10, 0x42, 0x08, 0x21, 0x84, 0x30,
+   0x88, 0xf0, 0x7f, 0x08, 0x21, 0x84, 0x10, 0x12, 0x58, 0x22, 0x40, 0x21,
+   0x84, 0x10, 0x42, 0x18, 0x10, 0x28, 0x40, 0x84, 0x10, 0x42, 0x08, 0x09,
+   0x30, 0x61, 0xe0, 0x10, 0x42, 0x08, 0x21, 0x0c, 0x60, 0xc4, 0x30, 0x42,
+   0x08, 0x21, 0x84, 0x04, 0xe0, 0xd2, 0x50, 0x29, 0xa5, 0x94, 0x52, 0x06,
+   0x40, 0xa5, 0x90, 0x52, 0x4a, 0x29, 0xa5, 0x02, 0xc0, 0xca, 0x38, 0xa5,
+   0x94, 0x52, 0x4a, 0x03, 0x80, 0xb5, 0xf8, 0xff, 0xfb, 0xef, 0xff, 0x3f,
+   0x80, 0xdb, 0x28, 0x0c, 0x8d, 0x38, 0x0c, 0x21, 0x00, 0x77, 0x78, 0x1e,
+   0xcb, 0x69, 0x9e, 0x31, 0x00, 0x6f, 0x78, 0x16, 0xce, 0x79, 0x9e, 0x19,
+   0x00, 0x7a, 0x6c, 0x1e, 0xc6, 0x38, 0x9b, 0x0c, 0x00, 0x7e, 0x3c, 0x1e,
+   0xe6, 0x3c, 0x1f, 0x04, 0x00, 0x7c, 0x3c, 0x8e, 0xe4, 0x3c, 0x1f, 0x06,
+   0x00, 0x2c, 0x3c, 0x8f, 0xe4, 0x1c, 0x1f, 0x03, 0x00, 0x38, 0x3c, 0xcf,
+   0x64, 0x9c, 0x0f, 0x01, 0x00, 0x38, 0x1e, 0xc7, 0x70, 0x9e, 0x07, 0x01,
+   0x00, 0x30, 0x1e, 0xc7, 0x71, 0x9e, 0x27, 0x01, 0x00, 0x30, 0x9e, 0xe7,
+   0x71, 0x8e, 0x33, 0x01, 0x00, 0x10, 0x9e, 0xe7, 0x79, 0xc0, 0x31, 0x03,
+   0x00, 0x10, 0x0e, 0xc3, 0xf9, 0xe0, 0x10, 0x02, 0xff, 0x1f, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xf7, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0x1f, 0xff, 0xf3, 0xff, 0xff, 0xff, 0xff, 0x00, 0x08, 0x01, 0x13,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0xff, 0xf1, 0xff, 0xff, 0x00, 0x00,
+   0x00, 0x0c, 0xfe, 0xf0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x06, 0x7e, 0xf8,
+   0xff, 0x7f, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf8, 0xff, 0x3f, 0x00, 0x00,
+   0x00, 0xfe, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff,
+   0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff,
+   0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff,
+   0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe,
+   0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc,
+   0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0,
+   0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0,
+   0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/m-mot.xbm b/xlockmore-4.14/bitmaps/m-mot.xbm
new file mode 100644 (file)
index 0000000..db0e78d
--- /dev/null
@@ -0,0 +1,67 @@
+#define image_width 76
+#define image_height 76
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x7f,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x01, 0xfc, 0x07, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x0f, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0x03, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x78, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00,
+   0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00,
+   0x00, 0x07, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x01, 0x1e,
+   0x00, 0x00, 0x00, 0xe0, 0x01, 0x0c, 0x00, 0x00, 0x01, 0x38, 0x00, 0x00,
+   0x00, 0x70, 0x00, 0x0c, 0x00, 0x80, 0x01, 0x70, 0x00, 0x00, 0x00, 0x38,
+   0x00, 0x0c, 0x00, 0x80, 0x03, 0xe0, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x1e,
+   0x00, 0x80, 0x03, 0xc0, 0x01, 0x00, 0x00, 0x0e, 0x00, 0x1e, 0x00, 0x80,
+   0x03, 0x80, 0x03, 0x00, 0x00, 0x0e, 0x00, 0x1e, 0x00, 0xc0, 0x03, 0x00,
+   0x03, 0x00, 0x00, 0x07, 0x00, 0x1e, 0x00, 0xc0, 0x07, 0x00, 0x07, 0x00,
+   0x80, 0x03, 0x00, 0x3f, 0x00, 0xc0, 0x07, 0x00, 0x0e, 0x00, 0x80, 0x01,
+   0x00, 0x3f, 0x00, 0xe0, 0x07, 0x00, 0x0c, 0x00, 0xc0, 0x01, 0x00, 0x3f,
+   0x00, 0xe0, 0x0f, 0x00, 0x18, 0x00, 0xc0, 0x00, 0x80, 0x7f, 0x00, 0xe0,
+   0x0f, 0x00, 0x38, 0x00, 0xe0, 0x00, 0x80, 0x7f, 0x00, 0xf0, 0x0f, 0x00,
+   0x30, 0x00, 0x60, 0x00, 0x80, 0x7f, 0x00, 0xf0, 0x1f, 0x00, 0x70, 0x00,
+   0x70, 0x00, 0xc0, 0xff, 0x00, 0xf0, 0x1f, 0x00, 0x60, 0x00, 0x30, 0x00,
+   0xc0, 0xff, 0x00, 0xf0, 0x1f, 0x00, 0x60, 0x00, 0x30, 0x00, 0xc0, 0xff,
+   0x00, 0xf8, 0x3f, 0x00, 0xe0, 0x00, 0x38, 0x00, 0xc0, 0xff, 0x01, 0xf8,
+   0x3f, 0x00, 0xc0, 0x00, 0x18, 0x00, 0xe0, 0xff, 0x01, 0xf8, 0x3f, 0x00,
+   0xc0, 0x00, 0x18, 0x00, 0xe0, 0xff, 0x01, 0xfc, 0x7f, 0x00, 0xc0, 0x01,
+   0x18, 0x00, 0xe0, 0xff, 0x03, 0xfc, 0x7f, 0x00, 0x80, 0x01, 0x1c, 0x00,
+   0xf0, 0xff, 0x03, 0xfc, 0x7f, 0x00, 0x80, 0x01, 0x0c, 0x00, 0xf0, 0xff,
+   0x03, 0xfc, 0x7f, 0x00, 0x80, 0x01, 0x0c, 0x00, 0xf0, 0xff, 0x03, 0xfe,
+   0xff, 0x00, 0x80, 0x01, 0x0c, 0x00, 0xf8, 0xff, 0x07, 0xfe, 0xff, 0x00,
+   0x80, 0x01, 0x0c, 0x00, 0xf8, 0xff, 0x07, 0xfe, 0xff, 0x00, 0x80, 0x03,
+   0x0c, 0x00, 0xf8, 0xff, 0x07, 0xff, 0xff, 0x01, 0x00, 0x03, 0x0c, 0x00,
+   0xf8, 0xff, 0x0f, 0xff, 0xff, 0x01, 0x00, 0x03, 0x0c, 0x00, 0xfc, 0xc1,
+   0x0f, 0x1f, 0xf8, 0x01, 0x00, 0x03, 0x0c, 0x00, 0x7c, 0x00, 0x8f, 0x0f,
+   0xe0, 0x03, 0x00, 0x03, 0x0c, 0x00, 0x3c, 0x00, 0x9e, 0x07, 0xc0, 0x03,
+   0x00, 0x03, 0x0c, 0x00, 0x1e, 0x00, 0x9c, 0x03, 0x80, 0x03, 0x80, 0x01,
+   0x0c, 0x00, 0x0e, 0x00, 0x9c, 0x01, 0x80, 0x07, 0x80, 0x01, 0x0c, 0x00,
+   0x0e, 0x00, 0xf8, 0x01, 0x00, 0x07, 0x80, 0x01, 0x1c, 0x00, 0x06, 0x00,
+   0xf0, 0x00, 0x00, 0x07, 0x80, 0x01, 0x18, 0x00, 0x07, 0x00, 0x70, 0x00,
+   0x00, 0x06, 0x80, 0x01, 0x18, 0x00, 0x07, 0x00, 0x60, 0x00, 0x00, 0x0e,
+   0xc0, 0x01, 0x18, 0x00, 0x03, 0x00, 0x60, 0x00, 0x00, 0x0c, 0xc0, 0x00,
+   0x38, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x0c, 0xc0, 0x00, 0x30, 0x80,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x1c, 0xc0, 0x00, 0x30, 0x80, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x18, 0xe0, 0x00, 0x70, 0xc0, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x18, 0x60, 0x00, 0x60, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x38,
+   0x70, 0x00, 0xe0, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x30, 0x00,
+   0xc0, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x38, 0x00, 0xc0, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x0e, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x06, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00,
+   0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x18,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x38, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x70, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x38,
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00,
+   0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x00,
+   0x1e, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00,
+   0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00,
+   0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x0f, 0x00, 0x80, 0x1f, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x01, 0xfc, 0x07, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/m-sco.xbm b/xlockmore-4.14/bitmaps/m-sco.xbm
new file mode 100644 (file)
index 0000000..e0c439d
--- /dev/null
@@ -0,0 +1,20 @@
+#define image_width 76
+#define image_height 25
+static char image_bits[] = {
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x07,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0x3f,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xfc,0x07,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x3f,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0xfe,0xff,0xff,0x1f,0xf0,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0xff,0xff,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x00,0x00,0xf0,0x00,0x00,0x00,0xf8,0xff,
+ 0xff,0xff,0xff,0xff,0xf7,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0xff,
+ 0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x07,0x00,0xf0,0x00,0x00,0xfc,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xf7,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x78,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x03,0xf0,0x00,0x00,0x00,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x07,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x9c,0x03,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xfc,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff};
diff --git a/xlockmore-4.14/bitmaps/m-sgi.xbm b/xlockmore-4.14/bitmaps/m-sgi.xbm
new file mode 100644 (file)
index 0000000..5f4c5e4
--- /dev/null
@@ -0,0 +1,46 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10,
+   0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x7c, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x7f, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f,
+   0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0xfc, 0x0f, 0x00, 0x00,
+   0x00, 0x00, 0xf8, 0x7f, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x7f,
+   0xfc, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xff, 0x7f, 0xfc, 0xff, 0x01, 0x00,
+   0x00, 0x80, 0xff, 0x7c, 0x7c, 0xfe, 0x03, 0x00, 0x00, 0xe0, 0x3f, 0x7c,
+   0x7c, 0xf8, 0x0f, 0x00, 0x00, 0xf8, 0x1f, 0x7c, 0x7c, 0xf0, 0x3f, 0x00,
+   0x00, 0xfc, 0x07, 0x7c, 0x7c, 0xc0, 0x7f, 0x00, 0x00, 0xff, 0x01, 0x7c,
+   0x7c, 0x00, 0xff, 0x01, 0x00, 0x7f, 0x00, 0x7c, 0x7c, 0x00, 0xfc, 0x01,
+   0x80, 0x3f, 0x00, 0x7c, 0x7c, 0x00, 0xf8, 0x03, 0x00, 0xff, 0x00, 0x7c,
+   0x7c, 0x00, 0xfe, 0x01, 0x00, 0xff, 0x03, 0x7c, 0x7c, 0x80, 0xff, 0x01,
+   0x00, 0xfc, 0x0f, 0x7c, 0x7c, 0xe0, 0x7f, 0x00, 0x40, 0xf0, 0x3f, 0x7c,
+   0x7c, 0xf8, 0x1f, 0x04, 0xf0, 0xe1, 0xff, 0x7c, 0x7c, 0xfe, 0x0f, 0x1f,
+   0xf8, 0x87, 0xff, 0x73, 0x9c, 0xff, 0xc3, 0x3f, 0xf8, 0x0f, 0xfe, 0x4f,
+   0xe4, 0xff, 0xe0, 0x3f, 0xfc, 0x3f, 0xf8, 0x3f, 0xf8, 0x3f, 0xf8, 0x7f,
+   0xfc, 0xff, 0xe0, 0xff, 0xff, 0x0f, 0xfe, 0x7f, 0xfc, 0xff, 0x83, 0xff,
+   0xff, 0x83, 0xff, 0x7f, 0xfc, 0xff, 0x07, 0xff, 0xff, 0xc1, 0xff, 0x7f,
+   0x7c, 0xfe, 0x1f, 0xfc, 0x7f, 0xf0, 0xff, 0x7c, 0x7c, 0xf8, 0x7f, 0xf2,
+   0x9f, 0xfc, 0x3f, 0x7c, 0x7c, 0xe0, 0xff, 0xcd, 0x67, 0xfe, 0x0f, 0x7c,
+   0x7c, 0xc0, 0xff, 0x33, 0x99, 0xff, 0x07, 0x7c, 0x7c, 0x00, 0xff, 0x0f,
+   0xe0, 0xff, 0x01, 0x7c, 0x7c, 0x00, 0xfc, 0x3f, 0xf8, 0x7f, 0x00, 0x7c,
+   0x7c, 0x00, 0xf2, 0x7f, 0xfc, 0x9f, 0x00, 0x7c, 0x7c, 0x80, 0xcf, 0x7f,
+   0xfd, 0xe7, 0x03, 0x7c, 0x7c, 0xe0, 0xbf, 0x7f, 0xfd, 0xf9, 0x0f, 0x7c,
+   0x7c, 0xf8, 0x7f, 0x7e, 0xfd, 0xfc, 0x3f, 0x7c, 0x7c, 0xfe, 0x0f, 0x7c,
+   0x7d, 0xe0, 0xff, 0x7c, 0xfc, 0xff, 0x83, 0x7d, 0x7d, 0x83, 0xff, 0x7f,
+   0xfc, 0xff, 0xe0, 0x7d, 0x7d, 0x0f, 0xfe, 0x7f, 0xfc, 0x3f, 0xf8, 0x7d,
+   0x7c, 0x3f, 0xf8, 0x7f, 0xfc, 0x0f, 0xfe, 0x7d, 0x7c, 0xff, 0xe0, 0x7f,
+   0xfc, 0x03, 0xff, 0x7d, 0x7c, 0xff, 0x81, 0x7f, 0xf8, 0xc0, 0xff, 0x7d,
+   0x7c, 0xff, 0x07, 0x3e, 0x30, 0xf0, 0xff, 0x7c, 0x7c, 0xfe, 0x1f, 0x18,
+   0x00, 0xfc, 0x3f, 0x7c, 0x7c, 0xf8, 0x7f, 0x00, 0x00, 0xff, 0x0f, 0x7c,
+   0x7c, 0xe0, 0xff, 0x01, 0x80, 0xff, 0x03, 0x7c, 0x7c, 0x80, 0xff, 0x03,
+   0x80, 0xff, 0x00, 0x7c, 0x7c, 0x00, 0xfe, 0x03, 0xc0, 0x3f, 0x00, 0x7c,
+   0x7c, 0x00, 0xf8, 0x07, 0xc0, 0x7f, 0x00, 0x7c, 0x7c, 0x00, 0xfc, 0x07,
+   0x80, 0xff, 0x01, 0x7c, 0x7c, 0x00, 0xff, 0x03, 0x80, 0xff, 0x07, 0x7c,
+   0x7c, 0xc0, 0xff, 0x03, 0x00, 0xfe, 0x1f, 0x7c, 0x7c, 0xf0, 0xff, 0x00,
+   0x00, 0xf8, 0x7f, 0x7c, 0x7c, 0xfc, 0x3f, 0x00, 0x00, 0xe0, 0xff, 0x7d,
+   0x7c, 0xff, 0x0f, 0x00, 0x00, 0x80, 0xff, 0x7f, 0xfc, 0xff, 0x03, 0x00,
+   0x00, 0x00, 0xfe, 0x7f, 0xfc, 0xff, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x7f,
+   0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0xfc, 0x0f, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x7f, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e,
+   0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x38, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/m-sun.xbm b/xlockmore-4.14/bitmaps/m-sun.xbm
new file mode 100644 (file)
index 0000000..681167f
--- /dev/null
@@ -0,0 +1,46 @@
+#define image_width 64
+#define image_height 64
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0,
+   0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc,
+   0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x7e, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x40, 0xfe,
+   0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xfc, 0xfd, 0x07, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0xfd, 0xfb, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xfb,
+   0xf7, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xf4, 0xf7, 0xef, 0x3f, 0x00, 0x00,
+   0x00, 0x00, 0xee, 0xef, 0xdf, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xdf, 0xdf,
+   0xbf, 0xff, 0x00, 0x00, 0x00, 0x80, 0xbf, 0xbf, 0x7f, 0xff, 0x00, 0x00,
+   0x00, 0x80, 0x7f, 0x7f, 0xff, 0x7e, 0x03, 0x00, 0x00, 0x60, 0xff, 0xfe,
+   0xfe, 0xbd, 0x07, 0x00, 0x00, 0xf0, 0xfe, 0xfd, 0xfd, 0xdb, 0x0f, 0x00,
+   0x00, 0xf8, 0xfd, 0xfb, 0xfb, 0xe7, 0x1f, 0x00, 0x00, 0xfc, 0xfb, 0xf7,
+   0xf7, 0xf7, 0x2f, 0x00, 0x00, 0xfe, 0xf5, 0xef, 0xef, 0xfb, 0x77, 0x00,
+   0x00, 0xff, 0xee, 0xdf, 0xcf, 0xfd, 0xfb, 0x00, 0x80, 0x7f, 0xdf, 0xbf,
+   0x9f, 0xfe, 0xfd, 0x01, 0xc0, 0xbf, 0xbf, 0xff, 0x1f, 0xff, 0xfe, 0x00,
+   0xe0, 0xdf, 0x1f, 0xff, 0x9f, 0x7f, 0x7f, 0x00, 0xf0, 0xef, 0x0f, 0xfe,
+   0xcf, 0xbf, 0x3f, 0x07, 0xf8, 0xf7, 0xe7, 0xfc, 0xef, 0xdf, 0xdf, 0x1f,
+   0xfc, 0xfb, 0xfb, 0xfb, 0xf7, 0xef, 0xef, 0x3f, 0xfe, 0xfd, 0xfd, 0xe7,
+   0xf9, 0xf7, 0xf7, 0x7f, 0xfe, 0xfe, 0xfe, 0x07, 0xf8, 0xfb, 0xfb, 0x7f,
+   0x7f, 0x7f, 0xff, 0x0f, 0xfc, 0xfd, 0xfd, 0xff, 0xbf, 0xbf, 0xff, 0x0f,
+   0xfc, 0xfe, 0xfe, 0xff, 0xff, 0xdf, 0xdf, 0x0f, 0xfc, 0x7f, 0xff, 0xfe,
+   0xff, 0xef, 0xef, 0x0f, 0xfc, 0xbf, 0x7f, 0xff, 0xfe, 0xf7, 0xf7, 0x07,
+   0xf8, 0xdf, 0xbf, 0x7f, 0xfe, 0xfb, 0xfb, 0xe7, 0xf9, 0xef, 0xdf, 0x7f,
+   0xfc, 0xfd, 0xfd, 0xfb, 0xf7, 0xf7, 0xef, 0x3f, 0x70, 0xfe, 0xfe, 0xfd,
+   0xcf, 0xf9, 0xf7, 0x1f, 0x00, 0x7f, 0xff, 0xfc, 0x1f, 0xfc, 0xfb, 0x0f,
+   0x80, 0xbf, 0x7f, 0xfe, 0x3f, 0xfe, 0xfd, 0x07, 0xc0, 0xdf, 0x3f, 0xfe,
+   0x7f, 0xff, 0xfe, 0x03, 0x80, 0xef, 0x5f, 0x7e, 0xff, 0x7e, 0xff, 0x01,
+   0x00, 0xf7, 0xef, 0xfc, 0xfe, 0xbd, 0xff, 0x00, 0x00, 0xfa, 0xf7, 0xfd,
+   0xfd, 0xdb, 0x7f, 0x00, 0x00, 0xfc, 0xfb, 0xfb, 0xfb, 0xe7, 0x3f, 0x00,
+   0x00, 0xf8, 0xf9, 0xf7, 0xf7, 0xef, 0x1f, 0x00, 0x00, 0xf0, 0xee, 0xef,
+   0xef, 0xdf, 0x0f, 0x00, 0x00, 0x60, 0xdf, 0xdf, 0xdf, 0xbf, 0x07, 0x00,
+   0x00, 0x80, 0xbf, 0xbf, 0xbf, 0x7f, 0x03, 0x00, 0x00, 0x80, 0x7f, 0x7f,
+   0x7f, 0xff, 0x00, 0x00, 0x00, 0x00, 0xff, 0xfe, 0xfe, 0xfe, 0x00, 0x00,
+   0x00, 0x00, 0xfe, 0xfd, 0xfd, 0x7d, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xfb,
+   0xfb, 0x3b, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xf7, 0xf7, 0x17, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0xef, 0xef, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xdf,
+   0xdf, 0x07, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xbf, 0x9f, 0x03, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x7f, 0x3f, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff,
+   0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x3f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8,
+   0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/m-x11.xbm b/xlockmore-4.14/bitmaps/m-x11.xbm
new file mode 100644 (file)
index 0000000..b725672
--- /dev/null
@@ -0,0 +1,14 @@
+#define image_width 32
+#define image_height 32
+static unsigned char image_bits[] = {
+   0xff, 0x00, 0x00, 0xc0, 0xfe, 0x01, 0x00, 0xc0, 0xfc, 0x03, 0x00, 0x60,
+   0xf8, 0x07, 0x00, 0x30, 0xf8, 0x07, 0x00, 0x18, 0xf0, 0x0f, 0x00, 0x0c,
+   0xe0, 0x1f, 0x00, 0x06, 0xc0, 0x3f, 0x00, 0x06, 0xc0, 0x3f, 0x00, 0x03,
+   0x80, 0x7f, 0x80, 0x01, 0x00, 0xff, 0xc0, 0x00, 0x00, 0xfe, 0x61, 0x00,
+   0x00, 0xfe, 0x31, 0x00, 0x00, 0xfc, 0x33, 0x00, 0x00, 0xf8, 0x1b, 0x00,
+   0x00, 0xf0, 0x0d, 0x00, 0x00, 0xf0, 0x0e, 0x00, 0x00, 0x60, 0x1f, 0x00,
+   0x00, 0xb0, 0x3f, 0x00, 0x00, 0x98, 0x7f, 0x00, 0x00, 0x98, 0x7f, 0x00,
+   0x00, 0x0c, 0xff, 0x00, 0x00, 0x06, 0xfe, 0x01, 0x00, 0x03, 0xfc, 0x03,
+   0x80, 0x01, 0xfc, 0x03, 0xc0, 0x00, 0xf8, 0x07, 0xc0, 0x00, 0xf0, 0x0f,
+   0x60, 0x00, 0xe0, 0x1f, 0x30, 0x00, 0xe0, 0x1f, 0x18, 0x00, 0xc0, 0x3f,
+   0x0c, 0x00, 0x80, 0x7f, 0x06, 0x00, 0x00, 0xff};
diff --git a/xlockmore-4.14/bitmaps/m-xlock.xbm b/xlockmore-4.14/bitmaps/m-xlock.xbm
new file mode 100644 (file)
index 0000000..3da6152
--- /dev/null
@@ -0,0 +1,17 @@
+#define image_width 50
+#define image_height 24
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x38, 0x00,
+   0x00, 0x00, 0xfc, 0x0f, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00,
+   0x0e, 0x00, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x07, 0x80, 0x0f, 0x00, 0xe0,
+   0x7f, 0x80, 0x03, 0xe0, 0x3f, 0x00, 0xc0, 0xff, 0xc0, 0x01, 0xe0, 0x3f,
+   0x00, 0x80, 0xff, 0xe1, 0x00, 0xf0, 0x78, 0x00, 0x00, 0xff, 0x73, 0x00,
+   0x70, 0x70, 0x00, 0x00, 0xfe, 0x3b, 0x00, 0x70, 0x70, 0x00, 0x00, 0xfc,
+   0x1d, 0x00, 0x70, 0x70, 0x00, 0x00, 0xf8, 0x1e, 0x00, 0x00, 0x70, 0x00,
+   0x00, 0x70, 0x3f, 0x00, 0xfc, 0xff, 0x01, 0x00, 0xb8, 0x7f, 0x00, 0xfc,
+   0xff, 0x01, 0x00, 0xdc, 0xff, 0x00, 0x7c, 0xf7, 0x01, 0x00, 0x8e, 0xff,
+   0x01, 0x6c, 0xb0, 0x01, 0x00, 0x07, 0xff, 0x03, 0x6c, 0xb7, 0x01, 0x80,
+   0x03, 0xfe, 0x07, 0x6c, 0xb0, 0x01, 0xc0, 0x01, 0xfc, 0x0f, 0x6c, 0xb7,
+   0x01, 0xe0, 0x00, 0xf8, 0x1f, 0x6c, 0xb0, 0x01, 0x70, 0x00, 0xf0, 0x3f,
+   0x6c, 0xb7, 0x01, 0x38, 0x00, 0xe0, 0x7f, 0xfc, 0xff, 0x01, 0x1c, 0x00,
+   0xc0, 0xff, 0xfc, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/mailempty.xbm b/xlockmore-4.14/bitmaps/mailempty.xbm
new file mode 100644 (file)
index 0000000..0642525
--- /dev/null
@@ -0,0 +1,27 @@
+#define mailempty_width 48
+#define mailempty_height 48
+static unsigned char mailempty_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x80, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0xc0, 0xaf, 0xaa, 0xaa, 0xaa, 0x7a, 0xe0, 0x57, 0x55, 0x55, 0x55, 0x7d,
+   0xf0, 0xaf, 0xaa, 0xaa, 0xaa, 0x7e, 0xf8, 0x57, 0x55, 0x55, 0x55, 0x7f,
+   0xfc, 0xaf, 0xaa, 0xaa, 0xaa, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xab, 0xaa, 0xaa, 0xea, 0x7f,
+   0xfe, 0x55, 0x55, 0x55, 0xf5, 0x6f, 0xfe, 0xaa, 0xaa, 0xaa, 0xea, 0x67,
+   0x7e, 0x55, 0x55, 0x55, 0xf5, 0x63, 0xbe, 0xaa, 0xaa, 0xaa, 0xea, 0x61,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0x60, 0xfe, 0xff, 0xff, 0xff, 0x7f, 0x60,
+   0x06, 0x06, 0x00, 0x00, 0x60, 0x60, 0x06, 0x06, 0x00, 0x00, 0x60, 0x60,
+   0x06, 0x06, 0x00, 0x00, 0x60, 0x60, 0x06, 0x06, 0x00, 0x00, 0x60, 0x60,
+   0x06, 0x06, 0x00, 0x00, 0x60, 0x60, 0x06, 0xfe, 0xff, 0xff, 0xff, 0x7f,
+   0x06, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x86, 0xaf, 0xaa, 0xaa, 0xea, 0x7a,
+   0xc6, 0x57, 0x55, 0x55, 0x75, 0x7d, 0xe6, 0xaf, 0xaa, 0xaa, 0xea, 0x7e,
+   0xf6, 0x57, 0x55, 0x55, 0x75, 0x7f, 0xfe, 0xaf, 0xaa, 0xaa, 0xea, 0x7f,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0xfe, 0xab, 0xaa, 0xaa, 0xea, 0x7f, 0xfe, 0x55, 0x55, 0x55, 0xf5, 0x6f,
+   0xfe, 0xaa, 0xaa, 0xaa, 0xea, 0x67, 0x7e, 0x55, 0x55, 0x55, 0xf5, 0x63,
+   0xbe, 0xaa, 0xaa, 0xaa, 0xea, 0x61, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x60,
+   0xfe, 0xff, 0xff, 0xff, 0x7f, 0x60, 0x06, 0x06, 0x00, 0x00, 0x60, 0x00,
+   0x06, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x60, 0x00,
+   0x06, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x60, 0x00,
+   0x06, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/mailfull.xbm b/xlockmore-4.14/bitmaps/mailfull.xbm
new file mode 100644 (file)
index 0000000..cc2f6f8
--- /dev/null
@@ -0,0 +1,27 @@
+#define mailfull_width 48
+#define mailfull_height 48
+static unsigned char mailfull_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x07,
+   0xc0, 0xff, 0xff, 0xff, 0x1f, 0x04, 0x40, 0x00, 0x00, 0x00, 0xd0, 0x05,
+   0x40, 0x00, 0x00, 0x00, 0x57, 0x7d, 0x40, 0x1e, 0x00, 0x00, 0x55, 0x7d,
+   0x40, 0x00, 0x00, 0x00, 0xd5, 0x7d, 0x60, 0x02, 0x00, 0x00, 0x17, 0x7c,
+   0x70, 0x00, 0x7e, 0x00, 0x10, 0x7c, 0x78, 0x00, 0x00, 0x00, 0x10, 0x7e,
+   0x7c, 0x00, 0x1e, 0x00, 0x10, 0x7f, 0x7e, 0x00, 0x00, 0x00, 0x90, 0x7f,
+   0x7e, 0x00, 0x3e, 0x07, 0xd0, 0x7f, 0x7e, 0x00, 0x00, 0x00, 0xf0, 0x7f,
+   0x7e, 0x00, 0x00, 0x00, 0xf0, 0x6f, 0x7e, 0x00, 0x00, 0x00, 0xf0, 0x67,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0x63, 0xbe, 0xaa, 0xaa, 0xaa, 0xea, 0x61,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0x60, 0xfe, 0xff, 0xff, 0xff, 0x7f, 0x60,
+   0x06, 0x06, 0x00, 0x00, 0x60, 0x60, 0x06, 0x06, 0x00, 0x00, 0x60, 0x60,
+   0x06, 0x06, 0x00, 0x00, 0x60, 0x60, 0x06, 0x06, 0x00, 0x00, 0x60, 0x60,
+   0x06, 0x06, 0x00, 0x00, 0x60, 0x60, 0x06, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0x86, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xc6, 0xaf, 0xaa, 0xaa, 0xea, 0x7a,
+   0xe6, 0x57, 0x55, 0x55, 0x75, 0x7d, 0xf6, 0xaf, 0xaa, 0xaa, 0xea, 0x7e,
+   0xfe, 0x57, 0x55, 0x55, 0x75, 0x7f, 0xfe, 0xaf, 0xaa, 0xaa, 0xea, 0x7f,
+   0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x7f,
+   0xfe, 0xab, 0xaa, 0xaa, 0xea, 0x7f, 0xfe, 0x55, 0x55, 0x55, 0xf5, 0x6f,
+   0xfe, 0xaa, 0xaa, 0xaa, 0xea, 0x67, 0x7e, 0x55, 0x55, 0x55, 0xf5, 0x63,
+   0xbe, 0xaa, 0xaa, 0xaa, 0xea, 0x61, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x60,
+   0xfe, 0xff, 0xff, 0xff, 0x7f, 0x60, 0x06, 0x06, 0x00, 0x00, 0x60, 0x60,
+   0x06, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0xee, 0x9c, 0x37, 0x60, 0x00,
+   0x06, 0xfe, 0x36, 0x33, 0x60, 0x00, 0x06, 0xd6, 0x3e, 0x33, 0x60, 0x00,
+   0x06, 0xc6, 0xb6, 0xf7, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/nose-faced.xbm b/xlockmore-4.14/bitmaps/nose-faced.xbm
new file mode 100644 (file)
index 0000000..fe57c02
--- /dev/null
@@ -0,0 +1,5 @@
+#define nose_face_down_width 18
+#define nose_face_down_height 7
+static unsigned char nose_face_down_bits[] = {
+ 0xff,0xff,0x03,0xff,0xff,0x03,0xfe,0xff,0x01,0xfe,0xff,0x01,0xfc,0xff,0x00,
+ 0xf8,0x7f,0x00,0xe0,0x1f,0x00};
diff --git a/xlockmore-4.14/bitmaps/nose-facef.xbm b/xlockmore-4.14/bitmaps/nose-facef.xbm
new file mode 100644 (file)
index 0000000..6044d94
--- /dev/null
@@ -0,0 +1,15 @@
+#define nose_face_front_width 41
+#define nose_face_front_height 28
+static unsigned char nose_face_front_bits[] = {
+ 0x00,0x00,0xff,0x01,0x00,0x00,0x00,0xc0,0xff,0x07,0x00,0x00,0x00,0xe0,0xff,
+ 0x0f,0x00,0x00,0xe0,0xf7,0xff,0xdf,0x0f,0x00,0xe0,0xf7,0xff,0xdf,0x0f,0x00,
+ 0xf0,0xfb,0xff,0xbf,0x1f,0x00,0xf8,0xfb,0xff,0xbf,0x3f,0x00,0xf8,0xfd,0xff,
+ 0x7f,0x3f,0x00,0xfc,0xfd,0xff,0x7f,0x7f,0x00,0xfc,0xfe,0xff,0xff,0x7e,0x00,
+ 0xfe,0xfe,0xff,0xff,0xfe,0x00,0xfe,0xfe,0xff,0xff,0xfe,0x00,0xfe,0xfe,0xff,
+ 0xff,0xfe,0x00,0xff,0xfe,0xff,0xff,0xfe,0x01,0xff,0xfe,0xff,0xff,0xfe,0x01,
+ 0xff,0xfe,0xff,0xff,0xfe,0x01,0xff,0xfd,0xff,0x7f,0xff,0x01,0xff,0xfd,0xff,
+ 0x7f,0xff,0x01,0xff,0xfb,0xff,0xbf,0xff,0x01,0xff,0xfb,0xff,0xbf,0xff,0x01,
+ 0xff,0xf7,0xff,0xdf,0xff,0x01,0xfe,0xef,0xff,0xef,0xff,0x00,0xfe,0x9f,0xff,
+ 0xf3,0xff,0x00,0xfe,0x7f,0xfe,0xfc,0xff,0x00,0xfc,0xff,0x01,0xff,0x7f,0x00,
+ 0xfc,0xff,0xff,0xff,0x7f,0x00,0xf8,0xff,0xff,0xff,0x3f,0x00,0xf0,0xff,0xff,
+ 0xff,0x1f,0x00};
diff --git a/xlockmore-4.14/bitmaps/nose-facel.xbm b/xlockmore-4.14/bitmaps/nose-facel.xbm
new file mode 100644 (file)
index 0000000..46633ac
--- /dev/null
@@ -0,0 +1,15 @@
+#define nose_face_left_width 50
+#define nose_face_left_height 25
+static unsigned char nose_face_left_bits[] = {
+ 0x00,0x7e,0xff,0xff,0xff,0x1f,0x00,0xc0,0xff,0xfc,0xff,0xff,0x3f,0x00,0xe0,
+ 0xff,0xfb,0xff,0xff,0x3f,0x00,0xf0,0xff,0xf7,0xff,0xff,0x7f,0x00,0xf8,0xff,
+ 0xef,0xff,0xff,0x7f,0x00,0xfc,0xff,0xff,0xff,0xff,0xff,0x00,0xfe,0xff,0xff,
+ 0xff,0xff,0xff,0x00,0xfe,0xff,0xff,0xff,0xff,0xff,0x01,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0x01,0xff,0xff,0xff,0xff,0xff,0xff,0x01,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0x03,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0x03,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0xff,0xff,0xff,0xff,0xff,0xff,0x03,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0x03,0xfe,0xff,0xff,0xff,0xff,0xff,0x03,0xfe,
+ 0xff,0xdf,0xff,0xff,0xff,0x03,0xfc,0xff,0xdf,0xff,0xff,0xff,0x01,0xf8,0xff,
+ 0xef,0xff,0xff,0xff,0x01,0xf0,0xff,0xf7,0xff,0xff,0xff,0x01,0xe0,0xff,0xfb,
+ 0xff,0xff,0xff,0x00,0xc0,0xff,0xfc,0xff,0xff,0xff,0x00,0x00,0x7f,0xff,0xff,
+ 0xff,0x7f,0x00,0x00,0x00,0xff,0xff,0xff,0x3f,0x00};
diff --git a/xlockmore-4.14/bitmaps/nose-facer.xbm b/xlockmore-4.14/bitmaps/nose-facer.xbm
new file mode 100644 (file)
index 0000000..e7dba81
--- /dev/null
@@ -0,0 +1,15 @@
+#define nose_face_right_width 50
+#define nose_face_right_height 25
+static unsigned char nose_face_right_bits[] = {
+ 0xe0,0xff,0xff,0xff,0xfb,0x01,0x00,0xf0,0xff,0xff,0xff,0xfc,0x0f,0x00,0xf0,
+ 0xff,0xff,0x7f,0xff,0x1f,0x00,0xf8,0xff,0xff,0xbf,0xff,0x3f,0x00,0xf8,0xff,
+ 0xff,0xdf,0xff,0x7f,0x00,0xfc,0xff,0xff,0xff,0xff,0xff,0x00,0xfc,0xff,0xff,
+ 0xff,0xff,0xff,0x01,0xfe,0xff,0xff,0xff,0xff,0xff,0x01,0xfe,0xff,0xff,0xff,
+ 0xff,0xff,0x03,0xfe,0xff,0xff,0xff,0xff,0xff,0x03,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0x03,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0x03,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0xff,0xff,0xff,0xff,0xff,0xff,0x03,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0x03,0xff,0xff,0xff,0xff,0xff,0xff,0x01,0xff,
+ 0xff,0xff,0xef,0xff,0xff,0x01,0xfe,0xff,0xff,0xef,0xff,0xff,0x00,0xfe,0xff,
+ 0xff,0xdf,0xff,0x7f,0x00,0xfe,0xff,0xff,0xbf,0xff,0x3f,0x00,0xfc,0xff,0xff,
+ 0x7f,0xff,0x1f,0x00,0xfc,0xff,0xff,0xff,0xfc,0x0f,0x00,0xf8,0xff,0xff,0xff,
+ 0xfb,0x03,0x00,0xf0,0xff,0xff,0xff,0x03,0x00,0x00};
diff --git a/xlockmore-4.14/bitmaps/nose-hat.xbm b/xlockmore-4.14/bitmaps/nose-hat.xbm
new file mode 100644 (file)
index 0000000..b03e41e
--- /dev/null
@@ -0,0 +1,8 @@
+#define nose_hat_width 43
+#define nose_hat_height 10
+static unsigned char nose_hat_bits[] = {
+ 0x00,0xf8,0xff,0xff,0x00,0x00,0x00,0xf8,0xff,0xff,0x00,0x00,0x00,0xf8,0xff,
+ 0xff,0x00,0x00,0x00,0xf8,0xff,0xff,0x00,0x00,0x00,0xf8,0xff,0xff,0x00,0x00,
+ 0x00,0xf8,0xff,0xff,0x00,0x00,0xff,0x0f,0x00,0x80,0xff,0x07,0xff,0xff,0xff,
+ 0xff,0xff,0x07,0xff,0xff,0xff,0xff,0xff,0x07,0xff,0xff,0xff,0xff,0xff,0x07
+ };
diff --git a/xlockmore-4.14/bitmaps/nose-hatd.xbm b/xlockmore-4.14/bitmaps/nose-hatd.xbm
new file mode 100644 (file)
index 0000000..8f27cee
--- /dev/null
@@ -0,0 +1,20 @@
+#define nose_hat_down_width 49
+#define nose_hat_down_height 28
+static unsigned char nose_hat_down_bits[] = {
+   0x00, 0x00, 0xfe, 0xff, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x0f,
+   0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff,
+   0xff, 0xff, 0x01, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0xe0,
+   0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x1f,
+   0x00, 0xf8, 0xff, 0x1f, 0xf0, 0xff, 0x3f, 0x00, 0xfc, 0xff, 0xe7, 0xcf,
+   0xff, 0x7f, 0x00, 0xfc, 0xff, 0xfb, 0xbf, 0xff, 0x7f, 0x00, 0xfe, 0xff,
+   0xfd, 0x7f, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xfd, 0x7f, 0xff, 0xff, 0x00,
+   0xff, 0xff, 0xf9, 0x3f, 0xff, 0xff, 0x01, 0xff, 0xff, 0xe5, 0x4f, 0xff,
+   0xff, 0x01, 0xff, 0xff, 0x1d, 0x70, 0xff, 0xff, 0x01, 0xff, 0xff, 0xfd,
+   0x7f, 0xff, 0xff, 0x01, 0xfd, 0xff, 0xfb, 0xbf, 0xff, 0x7f, 0x01, 0xfb,
+   0xff, 0xe7, 0xcf, 0xff, 0xbf, 0x01, 0xf6, 0xff, 0x1f, 0xf0, 0xff, 0xdf,
+   0x00, 0xec, 0xff, 0xff, 0xff, 0xff, 0x6f, 0x00, 0xdc, 0xff, 0xff, 0xff,
+   0xff, 0x77, 0x00, 0xb8, 0xff, 0xff, 0xff, 0xff, 0x3b, 0x00, 0x70, 0xfe,
+   0xff, 0xff, 0xff, 0x1c, 0x00, 0xe0, 0xf1, 0xff, 0xff, 0x1f, 0x0f, 0x00,
+   0x80, 0x0f, 0xff, 0xff, 0xe1, 0x03, 0x00, 0x00, 0xfe, 0x00, 0x00, 0xfe,
+   0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x80, 0xff,
+   0xff, 0x03, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/nose-shoef.xbm b/xlockmore-4.14/bitmaps/nose-shoef.xbm
new file mode 100644 (file)
index 0000000..1b3bbe3
--- /dev/null
@@ -0,0 +1,14 @@
+#define nose_shoe_front_width 61
+#define nose_shoe_front_height 20
+static unsigned char nose_shoe_front_bits[] = {
+ 0x00,0x00,0xf0,0x01,0xf0,0x01,0x00,0x00,0x00,0x00,0xf8,0x03,0xf8,0x03,0x00,
+ 0x00,0x00,0x00,0xfc,0x0f,0xfe,0x07,0x00,0x00,0x00,0x00,0xfc,0x1f,0xff,0x07,
+ 0x00,0x00,0xf0,0x0f,0xfe,0xbf,0xff,0x0f,0xfe,0x01,0xfc,0x1f,0xff,0xbf,0xff,
+ 0x1f,0xff,0x07,0xfc,0x3f,0xff,0xbf,0xff,0x9f,0xff,0x07,0xfe,0x3f,0xff,0xbf,
+ 0xff,0x9f,0xff,0x0f,0xfe,0xff,0xfc,0xbf,0xff,0xe7,0xff,0x0f,0xff,0xff,0xf9,
+ 0xbf,0xff,0xf3,0xff,0x1f,0xff,0xff,0xff,0x1f,0xff,0xff,0xff,0x1f,0xff,0xff,
+ 0xff,0x1f,0xff,0xff,0xff,0x1f,0xff,0xff,0xff,0x0f,0xfe,0xff,0xff,0x1f,0xf7,
+ 0xff,0xff,0x0f,0xfe,0xff,0xff,0x1d,0xf7,0xff,0xff,0x0f,0xfe,0xff,0xff,0x1d,
+ 0xcf,0xff,0xff,0x0f,0xfe,0xff,0x7f,0x1e,0x3f,0xff,0xff,0x1f,0xff,0xff,0x9f,
+ 0x1f,0xfe,0xff,0xff,0x1f,0xff,0xff,0xff,0x0f,0xfc,0xff,0xff,0x1f,0xff,0xff,
+ 0xff,0x07,0xf8,0xff,0xff,0x1f,0xff,0xff,0xff,0x03};
diff --git a/xlockmore-4.14/bitmaps/nose-shoel.xbm b/xlockmore-4.14/bitmaps/nose-shoel.xbm
new file mode 100644 (file)
index 0000000..072ee66
--- /dev/null
@@ -0,0 +1,10 @@
+#define nose_shoe_left_width 39
+#define nose_shoe_left_height 19
+static unsigned char nose_shoe_left_bits[] = {
+ 0x00,0x00,0x00,0xf8,0x0f,0x00,0xff,0x00,0xfc,0x1f,0xc0,0xff,0x03,0xff,0x1f,
+ 0xf0,0xff,0x0f,0xff,0x3f,0xf8,0xff,0x9f,0xff,0x3f,0xfc,0xfc,0xbf,0xff,0x3f,
+ 0x3e,0xff,0x3f,0xff,0x3f,0xbe,0xff,0x7f,0xff,0x3f,0xdf,0xff,0xff,0xfe,0x3f,
+ 0xdf,0xff,0xff,0xfe,0x3f,0xdf,0xff,0xff,0xff,0x3f,0xff,0xff,0xff,0xff,0x7f,
+ 0xff,0xff,0xff,0xff,0x7f,0xfe,0xff,0xff,0xff,0x7f,0xfe,0xff,0xff,0xff,0x7f,
+ 0xfc,0xff,0xff,0xff,0x3f,0xf8,0xff,0xff,0xff,0x3f,0xf0,0xff,0xff,0xff,0x1f,
+ 0xc0,0xff,0xff,0xff,0x0f};
diff --git a/xlockmore-4.14/bitmaps/nose-shoer.xbm b/xlockmore-4.14/bitmaps/nose-shoer.xbm
new file mode 100644 (file)
index 0000000..e375474
--- /dev/null
@@ -0,0 +1,10 @@
+#define nose_shoe_right_width 39
+#define nose_shoe_right_height 19
+static unsigned char nose_shoe_right_bits[] = {
+ 0xf8,0x0f,0x00,0x00,0x00,0xfc,0x1f,0x80,0x7f,0x00,0xfc,0x7f,0xe0,0xff,0x01,
+ 0xfe,0x7f,0xf8,0xff,0x07,0xfe,0xff,0xfc,0xff,0x0f,0xfe,0xff,0xfe,0x9f,0x1f,
+ 0xfe,0x7f,0xfe,0x7f,0x3e,0xfe,0x7f,0xff,0xff,0x3e,0xfe,0xbf,0xff,0xff,0x7d,
+ 0xfe,0xbf,0xff,0xff,0x7d,0xfe,0xff,0xff,0xff,0x7d,0xff,0xff,0xff,0xff,0x7f,
+ 0xff,0xff,0xff,0xff,0x7f,0xff,0xff,0xff,0xff,0x3f,0xff,0xff,0xff,0xff,0x3f,
+ 0xfe,0xff,0xff,0xff,0x1f,0xfe,0xff,0xff,0xff,0x0f,0xfc,0xff,0xff,0xff,0x07,
+ 0xf8,0xff,0xff,0xff,0x01};
diff --git a/xlockmore-4.14/bitmaps/nose-stepl.xbm b/xlockmore-4.14/bitmaps/nose-stepl.xbm
new file mode 100644 (file)
index 0000000..cf6c902
--- /dev/null
@@ -0,0 +1,16 @@
+#define nose_step_left_width 62
+#define nose_step_left_height 23
+static unsigned char nose_step_left_bits[] = {
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,
+ 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x07,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0xf8,0x0f,0xc0,0x0f,0x00,0x00,0x00,0x00,0xfc,0x1f,0xf0,0x3f,0xe0,0x03,0x00,
+ 0x00,0xfe,0x3f,0xf8,0x7f,0xf0,0x07,0x80,0x0f,0xff,0x3f,0xfc,0xff,0xf0,0x0f,
+ 0xe0,0x3f,0xff,0x3f,0xfe,0xff,0xf9,0x1f,0xf0,0x7f,0xff,0x1f,0x9f,0xff,0xfb,
+ 0x3f,0xfc,0x7f,0xff,0x1f,0xef,0xff,0xfb,0x7f,0x7e,0xfe,0xfe,0x0f,0xf7,0xff,
+ 0xfb,0x7f,0xbf,0xff,0xf9,0x0f,0xf7,0xff,0xf7,0x7f,0xdf,0xff,0xff,0x07,0xf7,
+ 0xff,0xf7,0x3f,0xdf,0xff,0xff,0x03,0xff,0xff,0xef,0x3f,0xdf,0xff,0xff,0x03,
+ 0xff,0xff,0xff,0x1f,0xdf,0xff,0xff,0x01,0xfe,0xff,0xff,0x1f,0xff,0xff,0xff,
+ 0x00,0xfe,0xff,0xff,0x1f,0xff,0xff,0xff,0x00,0xfc,0xff,0xff,0x1f,0xfe,0xff,
+ 0x7f,0x00,0xf8,0xff,0xff,0x1f,0xfe,0xff,0x7f,0x00,0xf0,0xff,0xff,0x0f,0xfc,
+ 0xff,0x3f,0x00,0xc0,0xff,0xff,0x07,0xf8,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,
+ 0xe0,0xff,0x07,0x00};
diff --git a/xlockmore-4.14/bitmaps/nose-stepr.xbm b/xlockmore-4.14/bitmaps/nose-stepr.xbm
new file mode 100644 (file)
index 0000000..98c838d
--- /dev/null
@@ -0,0 +1,16 @@
+#define nose_step_right_width 62
+#define nose_step_right_height 23
+static unsigned char nose_step_right_bits[] = {
+ 0x80,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x03,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf8,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x07,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0xfe,0x0f,0x00,0x00,0x00,0x00,0xfc,0x00,0xff,0x1f,0x00,0x00,0xf0,
+ 0x01,0xff,0x03,0xff,0x3f,0x7c,0x00,0xf8,0x83,0xff,0x07,0xff,0x3f,0xff,0x01,
+ 0xfc,0xc3,0xff,0x0f,0xfe,0xbf,0xff,0x03,0xfe,0xe7,0xff,0x1f,0xfe,0xbf,0xff,
+ 0x0f,0xff,0xf7,0x7f,0x3e,0xfc,0xdf,0x9f,0x9f,0xff,0xf7,0xff,0x3d,0xfc,0xe7,
+ 0x7f,0xbf,0xff,0xf7,0xff,0x3b,0xf8,0xff,0xff,0xbe,0xff,0xfb,0xff,0x3b,0xf0,
+ 0xff,0xff,0x3e,0xff,0xfb,0xff,0x3b,0xf0,0xff,0xff,0x3e,0xff,0xfd,0xff,0x3f,
+ 0xe0,0xff,0xff,0x3e,0xfe,0xff,0xff,0x3f,0xc0,0xff,0xff,0x3f,0xfe,0xff,0xff,
+ 0x1f,0xc0,0xff,0xff,0x3f,0xfe,0xff,0xff,0x1f,0x80,0xff,0xff,0x1f,0xfe,0xff,
+ 0xff,0x0f,0x80,0xff,0xff,0x1f,0xfe,0xff,0xff,0x07,0x00,0xff,0xff,0x0f,0xfc,
+ 0xff,0xff,0x03,0x00,0xfe,0xff,0x07,0xf8,0xff,0xff,0x00,0x00,0xf8,0xff,0x01,
+ 0x00,0x00,0x00,0x00};
diff --git a/xlockmore-4.14/bitmaps/root_weave.xbm b/xlockmore-4.14/bitmaps/root_weave.xbm
new file mode 100644 (file)
index 0000000..6e72323
--- /dev/null
@@ -0,0 +1,4 @@
+#define root_weave_width 4
+#define root_weave_height 4
+static unsigned char root_weave_bits[] = {
+   0x07, 0x0d, 0x0b, 0x0e};
diff --git a/xlockmore-4.14/bitmaps/rot00.xbm b/xlockmore-4.14/bitmaps/rot00.xbm
new file mode 100644 (file)
index 0000000..db6ed83
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot00_width 30
+#define rot00_height 30
+static unsigned char rot00_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0x07,
+   0x5c, 0x55, 0x55, 0x0f, 0xae, 0xaa, 0xaa, 0x1e, 0x56, 0x55, 0x55, 0x1f,
+   0xae, 0xaa, 0xaa, 0x1f, 0xd6, 0xff, 0xff, 0x1f, 0xae, 0xff, 0xbf, 0x1f,
+   0xd6, 0xff, 0xdf, 0x1f, 0xae, 0xff, 0xaf, 0x1f, 0xd6, 0xff, 0xd7, 0x1f,
+   0xae, 0xff, 0xab, 0x1f, 0xd6, 0xff, 0xd5, 0x1f, 0xae, 0xff, 0xaa, 0x1f,
+   0xd6, 0x7f, 0xd5, 0x1f, 0xae, 0xbf, 0xaa, 0x1f, 0xd6, 0x5f, 0xd5, 0x1f,
+   0xae, 0xaf, 0xaa, 0x1f, 0xd6, 0x57, 0xd5, 0x1f, 0xae, 0xab, 0xaa, 0x1f,
+   0xd6, 0x55, 0xd5, 0x1f, 0xae, 0xaa, 0xaa, 0x1f, 0xd6, 0xff, 0xff, 0x1f,
+   0xee, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0x0f,
+   0xf8, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot01.xbm b/xlockmore-4.14/bitmaps/rot01.xbm
new file mode 100644 (file)
index 0000000..3042081
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot01_width 30
+#define rot01_height 30
+static unsigned char rot01_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0x07,
+   0x55, 0x55, 0x55, 0x0f, 0xaa, 0xaa, 0xaa, 0x1e, 0x55, 0x55, 0x55, 0x1f,
+   0xaa, 0xaa, 0xaa, 0x1f, 0x55, 0x55, 0xd5, 0x1f, 0xaa, 0xaa, 0xea, 0x1f,
+   0x55, 0x55, 0xf5, 0x1f, 0xaa, 0xaa, 0xfa, 0x1f, 0x55, 0x55, 0xfd, 0x1f,
+   0xaa, 0xaa, 0xfe, 0x1f, 0x55, 0x55, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x0f,
+   0xff, 0xff, 0xff, 0x07, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot02.xbm b/xlockmore-4.14/bitmaps/rot02.xbm
new file mode 100644 (file)
index 0000000..2959a28
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot02_width 30
+#define rot02_height 30
+static unsigned char rot02_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0x07,
+   0x5c, 0x55, 0x55, 0x0f, 0xae, 0xaa, 0xaa, 0x1e, 0x56, 0x55, 0x55, 0x1f,
+   0xae, 0xaa, 0xaa, 0x1f, 0x56, 0x55, 0xd5, 0x1f, 0xae, 0xaa, 0xea, 0x1f,
+   0x56, 0x55, 0xf5, 0x1f, 0xae, 0xaa, 0xfa, 0x1f, 0x56, 0x55, 0xfd, 0x1f,
+   0xae, 0xaa, 0xfe, 0x1f, 0x56, 0x55, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f};
diff --git a/xlockmore-4.14/bitmaps/rot03.xbm b/xlockmore-4.14/bitmaps/rot03.xbm
new file mode 100644 (file)
index 0000000..677aa38
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot03_width 30
+#define rot03_height 30
+static unsigned char rot03_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff, 0x07,
+   0x55, 0x55, 0x55, 0x0f, 0xaa, 0xaa, 0xaa, 0x1e, 0x55, 0x55, 0x55, 0x1f,
+   0xaa, 0xaa, 0xaa, 0x1f, 0x55, 0x55, 0xd5, 0x1f, 0xaa, 0xaa, 0xea, 0x1f,
+   0x55, 0x55, 0xf5, 0x1f, 0xaa, 0xaa, 0xfa, 0x1f, 0x55, 0x55, 0xfd, 0x1f,
+   0xaa, 0xaa, 0xfe, 0x1f, 0x55, 0x55, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xbf, 0xff, 0x1f, 0xff, 0xdf, 0xff, 0x1f,
+   0xff, 0xaf, 0xff, 0x1f, 0xff, 0xd7, 0xff, 0x1f, 0xff, 0xab, 0xff, 0x1f,
+   0xff, 0xd5, 0xff, 0x1f, 0xff, 0xaa, 0xff, 0x1f, 0x7f, 0xd5, 0xff, 0x1f,
+   0xbf, 0xaa, 0xff, 0x1f, 0x5f, 0xd5, 0xff, 0x1f, 0xaf, 0xaa, 0xff, 0x1f,
+   0x57, 0xd5, 0xff, 0x1f, 0xab, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f};
diff --git a/xlockmore-4.14/bitmaps/rot04.xbm b/xlockmore-4.14/bitmaps/rot04.xbm
new file mode 100644 (file)
index 0000000..3df3292
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot04_width 30
+#define rot04_height 30
+static unsigned char rot04_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x3f,
+   0x5c, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15,
+   0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a,
+   0x56, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15,
+   0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xea, 0xff, 0x3f, 0x56, 0xf5, 0xff, 0x3f,
+   0xae, 0xfa, 0xff, 0x3f, 0x56, 0xfd, 0xff, 0x3f, 0xae, 0xfe, 0xff, 0x3f,
+   0x56, 0xff, 0xff, 0x3f, 0xae, 0xff, 0xff, 0x3f, 0xd6, 0xff, 0xff, 0x3f,
+   0xee, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x3f, 0xfc, 0xff, 0xff, 0x3f,
+   0xf8, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot05.xbm b/xlockmore-4.14/bitmaps/rot05.xbm
new file mode 100644 (file)
index 0000000..268552e
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot05_width 30
+#define rot05_height 30
+static unsigned char rot05_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15,
+   0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a,
+   0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15,
+   0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot06.xbm b/xlockmore-4.14/bitmaps/rot06.xbm
new file mode 100644 (file)
index 0000000..c5bd3f3
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot06_width 30
+#define rot06_height 30
+static unsigned char rot06_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x3f,
+   0x5c, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15,
+   0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a,
+   0x56, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15,
+   0xae, 0xaa, 0xaa, 0x2a, 0x56, 0x55, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f,
+   0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f,
+   0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f};
diff --git a/xlockmore-4.14/bitmaps/rot07.xbm b/xlockmore-4.14/bitmaps/rot07.xbm
new file mode 100644 (file)
index 0000000..5afbffe
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot07_width 30
+#define rot07_height 30
+static unsigned char rot07_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15,
+   0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a,
+   0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15,
+   0xaa, 0xaa, 0xaa, 0x2a, 0x55, 0x55, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xbf, 0xff, 0x3f, 0xff, 0xdf, 0xff, 0x3f,
+   0xff, 0xaf, 0xff, 0x3f, 0xff, 0xd7, 0xff, 0x3f, 0xff, 0xab, 0xff, 0x3f,
+   0xff, 0xd5, 0xff, 0x3f, 0xff, 0xaa, 0xff, 0x3f, 0x7f, 0xd5, 0xff, 0x3f,
+   0xbf, 0xaa, 0xff, 0x3f, 0x5f, 0xd5, 0xff, 0x3f, 0xaf, 0xaa, 0xff, 0x3f,
+   0x57, 0xd5, 0xff, 0x3f, 0xab, 0xaa, 0xff, 0x3f, 0x55, 0xd5, 0xff, 0x3f};
diff --git a/xlockmore-4.14/bitmaps/rot08.xbm b/xlockmore-4.14/bitmaps/rot08.xbm
new file mode 100644 (file)
index 0000000..a838cc8
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot08_width 30
+#define rot08_height 30
+static unsigned char rot08_bits[] = {
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xea, 0xff, 0x1f, 0x56, 0xf5, 0xff, 0x1f,
+   0xae, 0xfa, 0xff, 0x1f, 0x56, 0xfd, 0xff, 0x1f, 0xae, 0xfe, 0xff, 0x1f,
+   0x56, 0xff, 0xff, 0x1f, 0xae, 0xff, 0xff, 0x1f, 0xd6, 0xff, 0xff, 0x1f,
+   0xee, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0x0f,
+   0xf8, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot09.xbm b/xlockmore-4.14/bitmaps/rot09.xbm
new file mode 100644 (file)
index 0000000..eb102eb
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot09_width 30
+#define rot09_height 30
+static unsigned char rot09_bits[] = {
+   0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f,
+   0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f,
+   0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0xff, 0xff, 0xff, 0x0f,
+   0xff, 0xff, 0xff, 0x07, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot10.xbm b/xlockmore-4.14/bitmaps/rot10.xbm
new file mode 100644 (file)
index 0000000..50b9d56
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot10_width 30
+#define rot10_height 30
+static unsigned char rot10_bits[] = {
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f,
+   0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f,
+   0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x1f, 0x56, 0xd5, 0xff, 0x1f};
diff --git a/xlockmore-4.14/bitmaps/rot11.xbm b/xlockmore-4.14/bitmaps/rot11.xbm
new file mode 100644 (file)
index 0000000..20e9eaa
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot11_width 30
+#define rot11_height 30
+static unsigned char rot11_bits[] = {
+   0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f,
+   0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f,
+   0xaa, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x1f,
+   0xff, 0xff, 0xff, 0x1f, 0xff, 0xbf, 0xff, 0x1f, 0xff, 0xdf, 0xff, 0x1f,
+   0xff, 0xaf, 0xff, 0x1f, 0xff, 0xd7, 0xff, 0x1f, 0xff, 0xab, 0xff, 0x1f,
+   0xff, 0xd5, 0xff, 0x1f, 0xff, 0xaa, 0xff, 0x1f, 0x7f, 0xd5, 0xff, 0x1f,
+   0xbf, 0xaa, 0xff, 0x1f, 0x5f, 0xd5, 0xff, 0x1f, 0xaf, 0xaa, 0xff, 0x1f,
+   0x57, 0xd5, 0xff, 0x1f, 0xab, 0xaa, 0xff, 0x1f, 0x55, 0xd5, 0xff, 0x1f};
diff --git a/xlockmore-4.14/bitmaps/rot12.xbm b/xlockmore-4.14/bitmaps/rot12.xbm
new file mode 100644 (file)
index 0000000..d7511cd
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot12_width 30
+#define rot12_height 30
+static unsigned char rot12_bits[] = {
+   0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x2f,
+   0x56, 0xd5, 0xff, 0x17, 0xae, 0xaa, 0xff, 0x2b, 0x56, 0xd5, 0xff, 0x15,
+   0xae, 0xaa, 0xff, 0x2a, 0x56, 0xd5, 0x7f, 0x15, 0xae, 0xaa, 0xbf, 0x2a,
+   0x56, 0xd5, 0x5f, 0x15, 0xae, 0xaa, 0xaf, 0x2a, 0x56, 0xd5, 0x57, 0x15,
+   0xae, 0xaa, 0xab, 0x2a, 0x56, 0xd5, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xea, 0xff, 0x3f, 0x56, 0xf5, 0xff, 0x3f,
+   0xae, 0xfa, 0xff, 0x3f, 0x56, 0xfd, 0xff, 0x3f, 0xae, 0xfe, 0xff, 0x3f,
+   0x56, 0xff, 0xff, 0x3f, 0xae, 0xff, 0xff, 0x3f, 0xd6, 0xff, 0xff, 0x3f,
+   0xee, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x3f, 0xfc, 0xff, 0xff, 0x3f,
+   0xf8, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot13.xbm b/xlockmore-4.14/bitmaps/rot13.xbm
new file mode 100644 (file)
index 0000000..a5c8c2e
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot13_width 30
+#define rot13_height 30
+static unsigned char rot13_bits[] = {
+   0xaa, 0xaa, 0xff, 0x3f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x2f,
+   0x55, 0xd5, 0xff, 0x17, 0xaa, 0xaa, 0xff, 0x2b, 0x55, 0xd5, 0xff, 0x15,
+   0xaa, 0xaa, 0xff, 0x2a, 0x55, 0xd5, 0x7f, 0x15, 0xaa, 0xaa, 0xbf, 0x2a,
+   0x55, 0xd5, 0x5f, 0x15, 0xaa, 0xaa, 0xaf, 0x2a, 0x55, 0xd5, 0x57, 0x15,
+   0xaa, 0xaa, 0xab, 0x2a, 0x55, 0xd5, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/rot14.xbm b/xlockmore-4.14/bitmaps/rot14.xbm
new file mode 100644 (file)
index 0000000..a812ee2
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot14_width 30
+#define rot14_height 30
+static unsigned char rot14_bits[] = {
+   0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x1f, 0xae, 0xaa, 0xff, 0x2f,
+   0x56, 0xd5, 0xff, 0x17, 0xae, 0xaa, 0xff, 0x2b, 0x56, 0xd5, 0xff, 0x15,
+   0xae, 0xaa, 0xff, 0x2a, 0x56, 0xd5, 0x7f, 0x15, 0xae, 0xaa, 0xbf, 0x2a,
+   0x56, 0xd5, 0x5f, 0x15, 0xae, 0xaa, 0xaf, 0x2a, 0x56, 0xd5, 0x57, 0x15,
+   0xae, 0xaa, 0xab, 0x2a, 0x56, 0xd5, 0x55, 0x15, 0xae, 0xaa, 0xaa, 0x2a,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f,
+   0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f,
+   0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f,
+   0x56, 0xd5, 0xff, 0x3f, 0xae, 0xaa, 0xff, 0x3f, 0x56, 0xd5, 0xff, 0x3f};
diff --git a/xlockmore-4.14/bitmaps/rot15.xbm b/xlockmore-4.14/bitmaps/rot15.xbm
new file mode 100644 (file)
index 0000000..04a9581
--- /dev/null
@@ -0,0 +1,13 @@
+#define rot15_width 30
+#define rot15_height 30
+static unsigned char rot15_bits[] = {
+   0xaa, 0xaa, 0xff, 0x3f, 0x55, 0xd5, 0xff, 0x1f, 0xaa, 0xaa, 0xff, 0x2f,
+   0x55, 0xd5, 0xff, 0x17, 0xaa, 0xaa, 0xff, 0x2b, 0x55, 0xd5, 0xff, 0x15,
+   0xaa, 0xaa, 0xff, 0x2a, 0x55, 0xd5, 0x7f, 0x15, 0xaa, 0xaa, 0xbf, 0x2a,
+   0x55, 0xd5, 0x5f, 0x15, 0xaa, 0xaa, 0xaf, 0x2a, 0x55, 0xd5, 0x57, 0x15,
+   0xaa, 0xaa, 0xab, 0x2a, 0x55, 0xd5, 0x55, 0x15, 0xaa, 0xaa, 0xaa, 0x2a,
+   0xff, 0xff, 0xff, 0x3f, 0xff, 0xbf, 0xff, 0x3f, 0xff, 0xdf, 0xff, 0x3f,
+   0xff, 0xaf, 0xff, 0x3f, 0xff, 0xd7, 0xff, 0x3f, 0xff, 0xab, 0xff, 0x3f,
+   0xff, 0xd5, 0xff, 0x3f, 0xff, 0xaa, 0xff, 0x3f, 0x7f, 0xd5, 0xff, 0x3f,
+   0xbf, 0xaa, 0xff, 0x3f, 0x5f, 0xd5, 0xff, 0x3f, 0xaf, 0xaa, 0xff, 0x3f,
+   0x57, 0xd5, 0xff, 0x3f, 0xab, 0xaa, 0xff, 0x3f, 0x55, 0xd5, 0xff, 0x3f};
diff --git a/xlockmore-4.14/bitmaps/s-bsd.xbm b/xlockmore-4.14/bitmaps/s-bsd.xbm
new file mode 100644 (file)
index 0000000..2220bdd
--- /dev/null
@@ -0,0 +1,21 @@
+#define image_width 29
+#define image_height 35
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00,
+   0x00, 0x07, 0x40, 0x00, 0x00, 0xfb, 0xc1, 0x00, 0x00, 0xfd, 0xc3, 0x00,
+   0x00, 0xf6, 0xcf, 0x01, 0x00, 0x6a, 0xef, 0x01, 0x00, 0xb2, 0xfe, 0x00,
+   0x00, 0x33, 0x7f, 0x00, 0x00, 0x3f, 0x1f, 0x00, 0x80, 0xf7, 0x0f, 0x00,
+   0x98, 0xe7, 0x0f, 0x00, 0x90, 0xfd, 0x0f, 0x00, 0x36, 0xbb, 0x0f, 0x00,
+   0x3c, 0xc7, 0x07, 0x00, 0x39, 0xfc, 0x03, 0x00, 0x3f, 0xfc, 0x00, 0x00,
+   0xc0, 0x59, 0x01, 0x00, 0xc0, 0xfb, 0x01, 0x00, 0xc0, 0xf7, 0x01, 0x00,
+   0x80, 0xcd, 0x01, 0x00, 0x00, 0xfc, 0x01, 0x00, 0x00, 0xfc, 0x01, 0x00,
+   0x00, 0xfa, 0x01, 0x00, 0x00, 0x86, 0x01, 0x00, 0x00, 0xbe, 0x07, 0x00,
+   0x00, 0x7c, 0x1f, 0x00, 0x00, 0xfc, 0xff, 0x01, 0x00, 0xef, 0xc3, 0x0f,
+   0xc0, 0xef, 0x03, 0x1c, 0xf0, 0xf7, 0x03, 0x18, 0xf0, 0xfd, 0x01, 0x0b,
+   0xe0, 0xfe, 0x80, 0x07, 0x00, 0x38, 0x00, 0x00};
+
+/*
+ * BSD daemon
+ * The original BSD daemon is Copyright (c) 1988 Marshall Kirk McKusick.
+ * All rights reserved.  Reproduced with permission.
+ */
diff --git a/xlockmore-4.14/bitmaps/s-dec.xbm b/xlockmore-4.14/bitmaps/s-dec.xbm
new file mode 100644 (file)
index 0000000..8dcf7f7
--- /dev/null
@@ -0,0 +1,10 @@
+#define image_width 41
+#define image_height 13
+static unsigned char image_bits[] = {
+   0xdf, 0xfb, 0xbd, 0xef, 0xfb, 0x00, 0xdf, 0xfb, 0xbd, 0xef, 0xfb, 0x00,
+   0xd7, 0xfa, 0xb5, 0xef, 0xdb, 0x00, 0xd7, 0xfb, 0xbd, 0xed, 0xdb, 0x00,
+   0xd1, 0x1a, 0xb5, 0x28, 0xda, 0x00, 0xd5, 0x0a, 0xb5, 0xed, 0xda, 0x00,
+   0xd5, 0x6a, 0xb5, 0x2d, 0xda, 0x00, 0xd5, 0x0a, 0xb5, 0xad, 0xda, 0x00,
+   0xd3, 0x3a, 0xb5, 0x29, 0xda, 0x00, 0xdf, 0x0b, 0xbd, 0xef, 0xfb, 0x00,
+   0xdf, 0xbb, 0xbd, 0xef, 0xfb, 0x00, 0xdf, 0xfb, 0xbd, 0xef, 0xfb, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/s-grelb.xbm b/xlockmore-4.14/bitmaps/s-grelb.xbm
new file mode 100644 (file)
index 0000000..31202f6
--- /dev/null
@@ -0,0 +1,17 @@
+#define image_width 30
+#define image_height 33
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0xc0, 0x03, 0x20, 0xe4, 0x27, 0x04,
+   0x00, 0xfc, 0x3f, 0x00, 0x00, 0xff, 0xff, 0x00, 0x80, 0xff, 0xff, 0x01,
+   0xc0, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0x03, 0xe0, 0xe7, 0xe7, 0x07,
+   0xe0, 0xc3, 0xc3, 0x07, 0xe0, 0xe7, 0xe7, 0x07, 0xe0, 0xff, 0xff, 0x07,
+   0xc0, 0xff, 0xff, 0x03, 0x80, 0xff, 0xff, 0x01, 0x00, 0xff, 0xff, 0x00,
+   0x00, 0xfc, 0x3f, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x70, 0x0e, 0x00,
+   0x00, 0x60, 0x06, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x60, 0x06, 0x00,
+   0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x04, 0x00,
+   0x00, 0x3f, 0xfc, 0x00, 0x80, 0x7f, 0xfe, 0x01, 0x00, 0x3f, 0xfc, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
+/*
+ *      "Life.  Don't talk to me about life" -Marvin the Paranoid Android
+ */
diff --git a/xlockmore-4.14/bitmaps/s-hp.xbm b/xlockmore-4.14/bitmaps/s-hp.xbm
new file mode 100644 (file)
index 0000000..6e90251
--- /dev/null
@@ -0,0 +1,9 @@
+#define image_width 17
+#define image_height 23
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0xbe, 0xfe, 0x00, 0xbe, 0xfc, 0x00, 0xbf, 0xf8, 0x01,
+   0x9f, 0xf0, 0x01, 0xcf, 0xe0, 0x01, 0x4f, 0xe0, 0x01, 0x4f, 0xe0, 0x01,
+   0xcf, 0xec, 0x01, 0xe7, 0xce, 0x01, 0xe7, 0xca, 0x01, 0xa7, 0xca, 0x01,
+   0xa7, 0xca, 0x01, 0xa7, 0xca, 0x01, 0xaf, 0xee, 0x01, 0x0f, 0xe6, 0x01,
+   0x0f, 0xe2, 0x01, 0x0f, 0xe2, 0x01, 0x1f, 0xf3, 0x01, 0x3f, 0xf9, 0x01,
+   0x7e, 0xfd, 0x00, 0x7e, 0xfd, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/s-ibm.xbm b/xlockmore-4.14/bitmaps/s-ibm.xbm
new file mode 100644 (file)
index 0000000..4a9873d
--- /dev/null
@@ -0,0 +1,11 @@
+#define image_width 39
+#define image_height 17
+static unsigned char image_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xfc, 0xc7, 0x0f, 0x3f, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfe, 0xfc, 0xdf, 0x9f, 0x3f, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x38, 0x70, 0x1c, 0x9f, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38,
+   0xf0, 0x0f, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0xf0, 0x0f,
+   0xf7, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x70, 0x1c, 0x67, 0x0e,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xfc, 0xdf, 0x67, 0x3e, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xfe, 0xfc, 0xcf, 0x07, 0x3e, 0x00, 0x00, 0x00, 0x00,
+   0x00};
diff --git a/xlockmore-4.14/bitmaps/s-linux.xbm b/xlockmore-4.14/bitmaps/s-linux.xbm
new file mode 100644 (file)
index 0000000..f3604ee
--- /dev/null
@@ -0,0 +1,31 @@
+#define image_width 32
+#define image_height 37
+static unsigned char image_bits[] = {
+   0xff, 0x7f, 0xfe, 0xff, 0xff, 0x1f, 0xf0, 0xff, 0xff, 0x0f, 0xe0, 0xff,
+   0xff, 0x07, 0xc0, 0xff, 0xff, 0x07, 0xc0, 0xff, 0xff, 0x07, 0xc0, 0xff,
+   0xff, 0x37, 0xc7, 0xff, 0xff, 0x07, 0x89, 0xff, 0xff, 0x07, 0x89, 0xff,
+   0xff, 0xd7, 0x87, 0xff, 0xff, 0x77, 0x8f, 0xff, 0xff, 0xe7, 0x85, 0xff,
+   0xff, 0x57, 0x2d, 0xff, 0xff, 0xb7, 0x0e, 0xff, 0xff, 0xf3, 0x1f, 0xfe,
+   0xff, 0xf9, 0x1f, 0xfe, 0xff, 0xf9, 0x3f, 0xfc, 0xff, 0xfc, 0x3f, 0xf8,
+   0x7f, 0xfc, 0x7f, 0xf0, 0x7f, 0xfc, 0x7f, 0xf0, 0x7f, 0xfe, 0x7f, 0xf0,
+   0x3f, 0xfe, 0xff, 0xe0, 0x3f, 0xff, 0xff, 0xe0, 0x1f, 0xff, 0xff, 0xe0,
+   0x1f, 0xff, 0xff, 0xe0, 0x9f, 0xff, 0xff, 0xe0, 0x7f, 0xff, 0xff, 0xe0,
+   0xef, 0xfc, 0xbf, 0xf0, 0xbf, 0xf9, 0xff, 0xf0, 0xf7, 0xf3, 0xbf, 0xdd,
+   0xdd, 0xe2, 0xff, 0xfe, 0x7f, 0xf7, 0x9f, 0xdb, 0xdb, 0xfb, 0x8f, 0xff,
+   0xfd, 0xee, 0xc3, 0xbb, 0xab, 0x07, 0x80, 0xee, 0xa7, 0x0a, 0x80, 0xf5,
+   0x7f, 0xf2, 0x3f, 0xf9};
+
+/* Linux Penguin from logo.gif and logo.txt /usr/src/linux/Documentation
+This is the full-colour version of the currenly unofficial Linux logo
+("currently unofficial" just means that there has been no paperwork and
+that I haven't really announced it yet).  It was created by Larry Ewing,
+and is freely usable as long as you acknowledge Larry as the original
+artist.
+
+Note that there are black-and-white versions of this available that
+scale down to smaller sizes and are better for letterheads or whatever
+you want to use it for: for the full range of logos take a look at
+Larry's web-page:
+
+        http://www.isc.tamu.edu/~lewing/linux/
+ */
diff --git a/xlockmore-4.14/bitmaps/s-linux1.xbm b/xlockmore-4.14/bitmaps/s-linux1.xbm
new file mode 100644 (file)
index 0000000..3d543c1
--- /dev/null
@@ -0,0 +1,13 @@
+#define image_width 29
+#define image_height 29
+static unsigned char image_bits[] = {
+   0xff, 0xff, 0xff, 0x1f, 0x03, 0x00, 0x00, 0x18, 0x12, 0x10, 0x10, 0x08,
+   0xfe, 0x89, 0x88, 0x0c, 0x04, 0x11, 0x11, 0x05, 0x9c, 0xab, 0xaa, 0x06,
+   0x98, 0xff, 0xff, 0x0f, 0x98, 0x68, 0xad, 0x0b, 0x90, 0x4d, 0x2d, 0x09,
+   0x90, 0x4d, 0x6d, 0x0c, 0x90, 0x0d, 0x6d, 0x04, 0x90, 0x2d, 0x6d, 0x0c,
+   0x90, 0x2d, 0x21, 0x09, 0x90, 0x68, 0xa1, 0x0b, 0x9f, 0xff, 0xff, 0x1f,
+   0x9f, 0xef, 0xff, 0x1f, 0x98, 0xef, 0x3f, 0x00, 0x08, 0xe0, 0x1f, 0x00,
+   0xf8, 0xff, 0x0f, 0x00, 0x00, 0xfe, 0x0f, 0x00, 0x00, 0xfc, 0x07, 0x00,
+   0x00, 0xfc, 0x07, 0x00, 0x00, 0xf8, 0x03, 0x00, 0x00, 0xf8, 0x03, 0x00,
+   0x00, 0xf0, 0x01, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0xe0, 0x00, 0x00,
+   0x00, 0xe0, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/s-mot.xbm b/xlockmore-4.14/bitmaps/s-mot.xbm
new file mode 100644 (file)
index 0000000..11e43e7
--- /dev/null
@@ -0,0 +1,12 @@
+#define image_width 25
+#define image_height 25
+static unsigned char image_bits[] = {
+   0x1f, 0x00, 0xf0, 0x01, 0x0f, 0xfe, 0xe0, 0x01, 0x87, 0x01, 0xc3, 0x01,
+   0x63, 0x00, 0x8c, 0x01, 0x31, 0x01, 0x19, 0x01, 0x18, 0x01, 0x31, 0x00,
+   0x08, 0x83, 0x23, 0x00, 0x84, 0x83, 0x43, 0x00, 0x84, 0x83, 0x43, 0x00,
+   0x82, 0xc7, 0x83, 0x00, 0xc2, 0xc7, 0x87, 0x00, 0xc2, 0xc7, 0x87, 0x00,
+   0xc2, 0xef, 0x8f, 0x00, 0xc2, 0xee, 0x8e, 0x00, 0x62, 0x28, 0x88, 0x00,
+   0x22, 0x30, 0x88, 0x00, 0x24, 0x10, 0x58, 0x00, 0x14, 0x00, 0x50, 0x00,
+   0x18, 0x00, 0x30, 0x00, 0x18, 0x00, 0x30, 0x00, 0x31, 0x00, 0x18, 0x01,
+   0x63, 0x00, 0x8c, 0x01, 0x87, 0x01, 0xc3, 0x01, 0x0f, 0xfe, 0xe0, 0x01,
+   0x1f, 0x00, 0xf0, 0x01};
diff --git a/xlockmore-4.14/bitmaps/s-sco.xbm b/xlockmore-4.14/bitmaps/s-sco.xbm
new file mode 100644 (file)
index 0000000..e0c439d
--- /dev/null
@@ -0,0 +1,20 @@
+#define image_width 76
+#define image_height 25
+static char image_bits[] = {
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x07,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0x3f,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xfc,0x07,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x3f,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0xfe,0xff,0xff,0x1f,0xf0,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0xff,0xff,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x00,0x00,0xf0,0x00,0x00,0x00,0xf8,0xff,
+ 0xff,0xff,0xff,0xff,0xf7,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0xff,
+ 0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x07,0x00,0xf0,0x00,0x00,0xfc,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xf7,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x78,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x03,0xf0,0x00,0x00,0x00,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x07,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x9c,0x03,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xfc,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xf0,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0xf0,0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff};
diff --git a/xlockmore-4.14/bitmaps/s-sgi.xbm b/xlockmore-4.14/bitmaps/s-sgi.xbm
new file mode 100644 (file)
index 0000000..f9b8cd2
--- /dev/null
@@ -0,0 +1,14 @@
+#define image_width 32
+#define image_height 32
+static unsigned char image_bits[] = {
+  0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x0e, 0x00, 0x00, 0xf0, 0x1e, 0x00,
+  0x00, 0xfc, 0x7e, 0x00, 0x00, 0xff, 0xfe, 0x01, 0x80, 0xe7, 0xce, 0x03,
+  0xe0, 0xe3, 0x8e, 0x0f, 0xf0, 0xe0, 0x0e, 0x1e, 0xf0, 0xe0, 0x0e, 0x1e,
+  0xe0, 0xe3, 0x8e, 0x0f, 0x9c, 0xef, 0xee, 0x73, 0x3c, 0x1e, 0xf0, 0x78,
+  0xfe, 0xf8, 0x3f, 0xfe, 0xfe, 0xf3, 0x9f, 0xff, 0xce, 0xcf, 0xe7, 0xe7,
+  0x8e, 0x1f, 0xf0, 0xe3, 0x0e, 0x7e, 0xfc, 0xe0, 0x8e, 0xf9, 0x3e, 0xe3,
+  0xce, 0xe3, 0x8e, 0xe7, 0xfe, 0xe1, 0x0e, 0xff, 0x7e, 0xec, 0x6e, 0xfc,
+  0x1e, 0xef, 0xee, 0xf1, 0xc4, 0xef, 0xee, 0x47, 0xf0, 0xe3, 0x8e, 0x1f,
+  0xf0, 0xe0, 0x0e, 0x1e, 0xf8, 0xe0, 0x0e, 0x3e, 0xf0, 0xe3, 0x8e, 0x1f,
+  0xc0, 0xef, 0xee, 0x07, 0x00, 0xff, 0xfe, 0x01, 0x00, 0xfc, 0x7e, 0x00,
+  0x00, 0xf0, 0x1e, 0x00, 0x00, 0x40, 0x04, 0x00};
diff --git a/xlockmore-4.14/bitmaps/s-sun.xbm b/xlockmore-4.14/bitmaps/s-sun.xbm
new file mode 100644 (file)
index 0000000..2b0a295
--- /dev/null
@@ -0,0 +1,13 @@
+#define image_width 29
+#define image_height 29
+static unsigned char image_bits[] = {
+   0x00, 0xe0, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0xb8, 0x03, 0x00,
+   0x00, 0x74, 0x07, 0x00, 0x00, 0xee, 0x0e, 0x00, 0x00, 0xdd, 0x1d, 0x00,
+   0x80, 0xbb, 0x3b, 0x00, 0x40, 0x77, 0x57, 0x00, 0xe0, 0xee, 0xee, 0x00,
+   0x70, 0xdd, 0x75, 0x01, 0xb8, 0xbb, 0xb9, 0x03, 0xdc, 0xf1, 0xdd, 0x01,
+   0xee, 0xee, 0xee, 0x0e, 0x77, 0x1f, 0x77, 0x1f, 0xbb, 0x1b, 0xbb, 0x1b,
+   0xdf, 0x1d, 0xdf, 0x1d, 0xee, 0xee, 0xee, 0x0e, 0x70, 0xf7, 0x71, 0x07,
+   0xb8, 0xb3, 0xbb, 0x03, 0xd0, 0x75, 0xd7, 0x01, 0xe0, 0xee, 0xee, 0x00,
+   0x40, 0xdd, 0x5d, 0x00, 0x80, 0xbb, 0x3b, 0x00, 0x00, 0x77, 0x17, 0x00,
+   0x00, 0xee, 0x0e, 0x00, 0x00, 0xdc, 0x05, 0x00, 0x00, 0xb8, 0x01, 0x00,
+   0x00, 0xf0, 0x01, 0x00, 0x00, 0xe0, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/s-x11.xbm b/xlockmore-4.14/bitmaps/s-x11.xbm
new file mode 100644 (file)
index 0000000..7669c09
--- /dev/null
@@ -0,0 +1,6 @@
+#define image_width 16
+#define image_height 16
+static unsigned char image_bits[] = {
+   0x0f, 0x80, 0x1e, 0x80, 0x3c, 0x40, 0x78, 0x20, 0x78, 0x10, 0xf0, 0x08,
+   0xe0, 0x09, 0xc0, 0x05, 0xc0, 0x02, 0x40, 0x07, 0x20, 0x0f, 0x20, 0x1e,
+   0x10, 0x1e, 0x08, 0x3c, 0x04, 0x78, 0x02, 0xf0};
diff --git a/xlockmore-4.14/bitmaps/shark-0.xbm b/xlockmore-4.14/bitmaps/shark-0.xbm
new file mode 100644 (file)
index 0000000..fbfe999
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark0_width 20
+#define shark0_height 20
+static unsigned char shark0_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x80, 0x1f, 0x00,
+   0xc0, 0x3f, 0x00, 0x40, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00,
+   0x00, 0x06, 0x00, 0x00, 0x26, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x38, 0x00};
diff --git a/xlockmore-4.14/bitmaps/shark-1.xbm b/xlockmore-4.14/bitmaps/shark-1.xbm
new file mode 100644 (file)
index 0000000..d4d6027
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark1_width 20
+#define shark1_height 20
+static unsigned char shark1_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x18, 0x00,
+   0xc0, 0xff, 0x01, 0xfc, 0xff, 0x07, 0xfe, 0xff, 0x07, 0xc3, 0xff, 0x01,
+   0x01, 0x18, 0x00, 0x07, 0x08, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/shark-2.xbm b/xlockmore-4.14/bitmaps/shark-2.xbm
new file mode 100644 (file)
index 0000000..6ab9dac
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark2_width 20
+#define shark2_height 20
+static unsigned char shark2_bits[] = {
+   0xc0, 0x01, 0x00, 0x60, 0x03, 0x00, 0x40, 0x06, 0x00, 0x00, 0x06, 0x00,
+   0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x2f, 0x00, 0xc0, 0x3f, 0x00,
+   0x80, 0x1f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/shark-3.xbm b/xlockmore-4.14/bitmaps/shark-3.xbm
new file mode 100644 (file)
index 0000000..b1db4dc
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark3_width 20
+#define shark3_height 20
+static unsigned char shark3_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x01, 0x0e, 0x80, 0x01, 0x08,
+   0xf8, 0x3f, 0x0c, 0xfe, 0xff, 0x07, 0xfe, 0xff, 0x03, 0xf8, 0x3f, 0x00,
+   0x80, 0x01, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/shark-4.xbm b/xlockmore-4.14/bitmaps/shark-4.xbm
new file mode 100644 (file)
index 0000000..ec181a0
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark4_width 20
+#define shark4_height 20
+static unsigned char shark4_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x80, 0x1f, 0x00,
+   0xc0, 0x3f, 0x00, 0x00, 0x2f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00,
+   0x00, 0x06, 0x00, 0x40, 0x06, 0x00, 0x60, 0x03, 0x00, 0xc0, 0x01, 0x00};
diff --git a/xlockmore-4.14/bitmaps/shark-5.xbm b/xlockmore-4.14/bitmaps/shark-5.xbm
new file mode 100644 (file)
index 0000000..a31ab23
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark5_width 20
+#define shark5_height 20
+static unsigned char shark5_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x07, 0x08, 0x00, 0x01, 0x18, 0x00,
+   0xc3, 0xff, 0x01, 0xfe, 0xff, 0x07, 0xfc, 0xff, 0x07, 0xc0, 0xff, 0x01,
+   0x00, 0x18, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/shark-6.xbm b/xlockmore-4.14/bitmaps/shark-6.xbm
new file mode 100644 (file)
index 0000000..09e0182
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark6_width 20
+#define shark6_height 20
+static unsigned char shark6_bits[] = {
+   0x00, 0x38, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x26, 0x00, 0x00, 0x06, 0x00,
+   0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x40, 0x0f, 0x00, 0xc0, 0x3f, 0x00,
+   0x80, 0x1f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0f, 0x00,
+   0x00, 0x0f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/shark-7.xbm b/xlockmore-4.14/bitmaps/shark-7.xbm
new file mode 100644 (file)
index 0000000..b7c6821
--- /dev/null
@@ -0,0 +1,8 @@
+#define shark7_width 20
+#define shark7_height 20
+static unsigned char shark7_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x80, 0x01, 0x00,
+   0xf8, 0x3f, 0x00, 0xfe, 0xff, 0x03, 0xfe, 0xff, 0x07, 0xf8, 0x3f, 0x0c,
+   0x80, 0x01, 0x08, 0x00, 0x01, 0x0e, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/sickle.xbm b/xlockmore-4.14/bitmaps/sickle.xbm
new file mode 100644 (file)
index 0000000..91d7b4b
--- /dev/null
@@ -0,0 +1,9 @@
+#define sickle_width 21
+#define sickle_height 21
+static unsigned char sickle_bits[] = {
+   0x00, 0x1e, 0x00, 0x00, 0x38, 0x00, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00,
+   0xc0, 0x81, 0x01, 0xe0, 0x00, 0x03, 0xf0, 0x00, 0x03, 0xb8, 0x01, 0x07,
+   0x10, 0x03, 0x07, 0x00, 0x06, 0x07, 0x00, 0x0c, 0x07, 0x00, 0x18, 0x07,
+   0x00, 0x30, 0x07, 0x30, 0xe0, 0x03, 0x78, 0xc0, 0x03, 0xcc, 0xc0, 0x01,
+   0x86, 0xe3, 0x03, 0x07, 0x7f, 0x06, 0x07, 0x3c, 0x0c, 0x03, 0x00, 0x08,
+   0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/stipple.xbm b/xlockmore-4.14/bitmaps/stipple.xbm
new file mode 100644 (file)
index 0000000..2e5b941
--- /dev/null
@@ -0,0 +1,4 @@
+#define stipple_width 16
+#define stipple_height 4
+static unsigned char stipple_bits[] = {
+   0x55, 0x55, 0xee, 0xee, 0x55, 0x55, 0xba, 0xbb};
diff --git a/xlockmore-4.14/bitmaps/t-smilie.xbm b/xlockmore-4.14/bitmaps/t-smilie.xbm
new file mode 100644 (file)
index 0000000..7b8bd52
--- /dev/null
@@ -0,0 +1,4 @@
+#define image_width 8
+#define image_height 8
+static unsigned char image_bits[] = {
+   0x3c, 0x7e, 0xdb, 0xff, 0xdb, 0xe7, 0x7e, 0x3c};
diff --git a/xlockmore-4.14/bitmaps/t-x11.xbm b/xlockmore-4.14/bitmaps/t-x11.xbm
new file mode 100644 (file)
index 0000000..ef9bfda
--- /dev/null
@@ -0,0 +1,5 @@
+#define image_width 11
+#define image_height 11
+static unsigned char image_bits[] = {
+ 0x0f, 0x04, 0x0f, 0x02, 0x1e, 0x01, 0x3c, 0x01, 0xb8, 0x00, 0x58, 0x00,
+ 0xe8, 0x00, 0xe4, 0x01, 0xc4, 0x03, 0xc2, 0x03, 0x81, 0x07 };
diff --git a/xlockmore-4.14/bitmaps/terra-00.xbm b/xlockmore-4.14/bitmaps/terra-00.xbm
new file mode 100644 (file)
index 0000000..f27dc9f
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra00_width 64
+#define terra00_height 64
+#define terra00_x_hot 32
+#define terra00_y_hot 32
+static unsigned char terra00_bits[] = {
+0x00, 0x00, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1f, 
+0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0xd0, 0x01, 0xf8, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x20, 0x00, 0xdc, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 
+0xdc, 0xff, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0xd8, 0xff, 0x03, 0x00, 
+0x00, 0xe0, 0x00, 0xe0, 0xfc, 0xff, 0x07, 0x00, 0x00, 0x78, 0x00, 0x00, 
+0xff, 0xff, 0x1f, 0x00, 0x00, 0x1c, 0x00, 0x80, 0xff, 0xff, 0x3f, 0x00, 
+0x00, 0x0e, 0x00, 0x80, 0xf7, 0xff, 0x7f, 0x00, 0x00, 0x03, 0x00, 0xf0, 
+0x21, 0xff, 0xff, 0x00, 0x80, 0x00, 0x00, 0xf0, 0x80, 0xfb, 0xff, 0x01, 
+0x00, 0x00, 0x00, 0x60, 0x00, 0xf2, 0xff, 0x01, 0x40, 0x00, 0x00, 0xa0, 
+0x1f, 0x80, 0xff, 0x03, 0x20, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0xff, 0x07, 
+0x00, 0x00, 0x00, 0xf0, 0xff, 0xfe, 0xff, 0x07, 0x00, 0x00, 0x00, 0xf8, 
+0xff, 0xff, 0xdf, 0x0f, 0x08, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x3e, 0x1f, 
+0x08, 0x00, 0x00, 0xff, 0xff, 0xff, 0x7d, 0x18, 0x00, 0x00, 0x00, 0xff, 
+0xff, 0xff, 0xf9, 0x19, 0x04, 0x00, 0x80, 0xff, 0xff, 0xff, 0xfb, 0x31, 
+0x08, 0x00, 0x00, 0xff, 0xff, 0xff, 0xf7, 0x21, 0x00, 0x00, 0x00, 0xff, 
+0xff, 0xff, 0xe7, 0x21, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xef, 0x00, 
+0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x7f, 0x40, 0x04, 0x00, 0x80, 0xff, 
+0xff, 0xff, 0x1f, 0x40, 0x0e, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 
+0x1e, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0x00, 0x1e, 0x00, 0x00, 0xfc, 
+0xf8, 0xff, 0xff, 0x00, 0x7e, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x00, 
+0x7e, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x7f, 0x00, 0x7f, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0x3f, 0x00, 0xff, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x3f, 0x00, 
+0xff, 0x03, 0x00, 0x00, 0xe0, 0xff, 0x1f, 0x00, 0xff, 0x0f, 0x00, 0x00, 
+0xc0, 0xff, 0x0f, 0x00, 0xfe, 0x3f, 0x00, 0x00, 0x80, 0xff, 0x0f, 0x00, 
+0xfe, 0x3f, 0x00, 0x00, 0x80, 0xff, 0x0f, 0x00, 0xfe, 0x1f, 0x00, 0x00, 
+0x80, 0xff, 0x0f, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0x00, 0xff, 0x0f, 0x00, 
+0xfc, 0x0f, 0x00, 0x00, 0x80, 0xff, 0x8f, 0x00, 0xfc, 0x0f, 0x00, 0x00, 
+0x80, 0xff, 0xcf, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x80, 0xff, 0x67, 0x00, 
+0xf0, 0x0f, 0x00, 0x00, 0x80, 0xff, 0x63, 0x00, 0xf0, 0x0f, 0x00, 0x00, 
+0x80, 0xff, 0x21, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0xff, 0x21, 0x00, 
+0xe0, 0x07, 0x00, 0x00, 0x00, 0xff, 0x11, 0x00, 0xe0, 0x03, 0x00, 0x00, 
+0x00, 0x7f, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x00, 
+0xc0, 0x03, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 
+0x00, 0x1e, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-01.xbm b/xlockmore-4.14/bitmaps/terra-01.xbm
new file mode 100644 (file)
index 0000000..d6b309f
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra01_width 64
+#define terra01_height 64
+#define terra01_x_hot 32
+#define terra01_y_hot 32
+static unsigned char terra01_bits[] = {
+0x00, 0x00, 0x00, 0xf0, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3e, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x07, 0xe0, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x86, 0x01, 0x60, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 
+0xe0, 0xfe, 0x00, 0x00, 0x00, 0x40, 0x03, 0x00, 0xc6, 0xfc, 0x03, 0x00, 
+0x00, 0xe0, 0x03, 0x00, 0xce, 0xff, 0x07, 0x00, 0x00, 0xf8, 0x02, 0x00, 
+0xf0, 0xff, 0x1f, 0x00, 0x00, 0x7c, 0x00, 0x00, 0xf0, 0xff, 0x3f, 0x00, 
+0x00, 0x3c, 0x00, 0x00, 0xf0, 0xff, 0x7f, 0x00, 0x00, 0x0f, 0x00, 0x00, 
+0x3e, 0xf4, 0xff, 0x00, 0x80, 0x03, 0x00, 0x00, 0x1e, 0xa0, 0xff, 0x01, 
+0x80, 0x01, 0x00, 0x00, 0x1c, 0x48, 0xff, 0x01, 0xc0, 0x00, 0x00, 0x00, 
+0xf0, 0x03, 0xf0, 0x03, 0x60, 0x00, 0x00, 0x00, 0xfc, 0x07, 0xf0, 0x07, 
+0x20, 0x00, 0x00, 0x00, 0xfe, 0x9f, 0xfd, 0x07, 0x30, 0x00, 0x00, 0x00, 
+0xff, 0xff, 0xff, 0x0f, 0x38, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x19, 
+0x38, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xdf, 0x13, 0x38, 0x00, 0x00, 0xc0, 
+0xff, 0xff, 0xbf, 0x0f, 0x24, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x0f, 
+0x40, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x0f, 0x02, 0x00, 0x00, 0xc0, 
+0xff, 0xff, 0xff, 0x0e, 0x02, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0x0e, 
+0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x07, 0x20, 0x00, 0x00, 0xc0, 
+0xff, 0xff, 0xff, 0x03, 0xf0, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x0f, 
+0xfc, 0x01, 0x00, 0x00, 0xff, 0xff, 0xff, 0x0f, 0xf8, 0x01, 0x00, 0x00, 
+0x7e, 0xfe, 0xff, 0x0f, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x07, 
+0xf8, 0x0f, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x07, 0xfc, 0x0f, 0x00, 0x00, 
+0x00, 0xf0, 0xff, 0x07, 0xfc, 0x1f, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x03, 
+0xfc, 0x7f, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x01, 0xfc, 0xff, 0x03, 0x00, 
+0x00, 0xe0, 0xff, 0x01, 0xfc, 0xff, 0x07, 0x00, 0x00, 0xe0, 0xff, 0x01, 
+0xf8, 0xff, 0x07, 0x00, 0x00, 0xc0, 0xff, 0x01, 0xf8, 0xff, 0x07, 0x00, 
+0x00, 0xc0, 0xff, 0x01, 0xf0, 0xff, 0x03, 0x00, 0x00, 0xc0, 0xff, 0x01, 
+0xf0, 0xff, 0x03, 0x00, 0x00, 0xe0, 0xff, 0x01, 0xf0, 0xff, 0x03, 0x00, 
+0x00, 0xe0, 0xff, 0x04, 0xe0, 0xff, 0x03, 0x00, 0x00, 0xe0, 0xff, 0x04, 
+0xc0, 0xff, 0x03, 0x00, 0x00, 0xe0, 0x7f, 0x02, 0x80, 0xff, 0x01, 0x00, 
+0x00, 0xe0, 0x3f, 0x02, 0x80, 0xff, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x01, 
+0x80, 0x7f, 0x00, 0x00, 0x00, 0xe0, 0x1f, 0x01, 0x00, 0x7f, 0x00, 0x00, 
+0x00, 0xe0, 0x0f, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x00, 0xe0, 0x0f, 0x00, 
+0x00, 0x7f, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x3e, 0x00, 0x00, 
+0x00, 0xc0, 0x01, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0xfe, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-02.xbm b/xlockmore-4.14/bitmaps/terra-02.xbm
new file mode 100644 (file)
index 0000000..339f5c2
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra02_width 64
+#define terra02_height 64
+#define terra02_x_hot 32
+#define terra02_y_hot 32
+static unsigned char terra02_bits[] = {
+0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xf9, 
+0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x3c, 0x80, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x08, 0x0c, 0x00, 0x73, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 
+0x00, 0xf7, 0x00, 0x00, 0x00, 0xc0, 0x1e, 0x00, 0x60, 0xe4, 0x03, 0x00, 
+0x00, 0xe0, 0x3f, 0x00, 0xa0, 0xfe, 0x07, 0x00, 0x00, 0xf8, 0x07, 0x00, 
+0x00, 0xff, 0x1f, 0x00, 0x00, 0xfc, 0x03, 0x00, 0x00, 0xff, 0x3f, 0x00, 
+0x00, 0xfe, 0x01, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x7f, 0x00, 0x00, 
+0xc0, 0x07, 0xff, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x80, 0x03, 0xff, 0x01, 
+0x80, 0x0f, 0x00, 0x00, 0x80, 0x03, 0xf4, 0x01, 0xc0, 0x07, 0x00, 0x00, 
+0x00, 0x7d, 0xc0, 0x03, 0xe0, 0x03, 0x00, 0x00, 0x80, 0xff, 0x80, 0x07, 
+0xe0, 0x01, 0x00, 0x00, 0x80, 0xff, 0xfb, 0x07, 0x30, 0x00, 0x00, 0x00, 
+0xc0, 0xff, 0xff, 0x0f, 0x18, 0x01, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x1e, 
+0x08, 0x01, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x1f, 0x08, 0x00, 0x00, 0x00, 
+0xf0, 0xff, 0xff, 0x1f, 0x04, 0x01, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x3f, 
+0x14, 0x02, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x37, 0x0c, 0x00, 0x00, 0x00, 
+0xf0, 0xff, 0xff, 0x37, 0x18, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x2f, 
+0x18, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x1f, 0x10, 0x03, 0x00, 0x00, 
+0xf0, 0xff, 0xff, 0x1f, 0x90, 0x1f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x3f, 
+0xc0, 0x3f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x80, 0x7f, 0x00, 0x00, 
+0x80, 0x9f, 0xff, 0x3f, 0xc0, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0x3f, 
+0xc0, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0x3f, 0xc0, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0xfc, 0x3f, 0xe0, 0xff, 0x07, 0x00, 0x00, 0x00, 0xfc, 0x1f, 
+0xe0, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xfc, 0x1f, 0xe0, 0xff, 0xff, 0x00, 
+0x00, 0x00, 0xf8, 0x1f, 0xe0, 0xff, 0xff, 0x03, 0x00, 0x00, 0xf8, 0x0f, 
+0xc0, 0xff, 0xff, 0x03, 0x00, 0x00, 0xf8, 0x0f, 0xc0, 0xff, 0xff, 0x01, 
+0x00, 0x00, 0xf8, 0x0f, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00, 0xf8, 0x0f, 
+0x80, 0xff, 0xff, 0x00, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0xff, 0xff, 0x00, 
+0x00, 0x00, 0xfc, 0x2f, 0x00, 0xfe, 0xff, 0x00, 0x00, 0x00, 0xfc, 0x07, 
+0x00, 0xfc, 0xff, 0x00, 0x00, 0x00, 0xfc, 0x13, 0x00, 0xfc, 0x7f, 0x00, 
+0x00, 0x00, 0xf8, 0x01, 0x00, 0xf8, 0x3f, 0x00, 0x00, 0x00, 0xf8, 0x09, 
+0x00, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0xfc, 0x01, 0x00, 0xf8, 0x0f, 0x00, 
+0x00, 0x00, 0xfc, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0x7c, 0x00, 
+0x00, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0xf0, 0x07, 0x00, 
+0x00, 0x00, 0x1c, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0xf8, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x90, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-03.xbm b/xlockmore-4.14/bitmaps/terra-03.xbm
new file mode 100644 (file)
index 0000000..310ae6a
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra03_width 64
+#define terra03_height 64
+#define terra03_x_hot 32
+#define terra03_y_hot 32
+static unsigned char terra03_bits[] = {
+0x00, 0x00, 0x00, 0xf0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xe3, 
+0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xf3, 0x00, 0x0e, 0x00, 0x00, 
+0x00, 0x00, 0x2e, 0x70, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x63, 0x00, 
+0x00, 0xd8, 0x00, 0x00, 0x00, 0xc0, 0xf3, 0x01, 0x00, 0xa2, 0x03, 0x00, 
+0x00, 0xe0, 0xff, 0x01, 0x00, 0xec, 0x07, 0x00, 0x00, 0xf8, 0x3f, 0x01, 
+0x00, 0xf0, 0x1f, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0xf0, 0x3f, 0x00, 
+0x00, 0xfe, 0x0f, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0xff, 0x03, 0x00, 
+0x00, 0x78, 0xf8, 0x00, 0x80, 0xff, 0x01, 0x00, 0x00, 0x78, 0xe8, 0x01, 
+0xc0, 0xff, 0x00, 0x00, 0x00, 0x30, 0xe8, 0x01, 0xc0, 0x7f, 0x00, 0x00, 
+0x00, 0xe0, 0x07, 0x03, 0xe0, 0x1f, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x06, 
+0xe0, 0x0f, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x07, 0xe0, 0x08, 0x00, 0x00, 
+0x00, 0xf0, 0xff, 0x0f, 0x70, 0x08, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x1f, 
+0x30, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x1f, 0x30, 0x00, 0x00, 0x00, 
+0x00, 0xfc, 0xff, 0x1f, 0x30, 0x11, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x3f, 
+0xb0, 0x40, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x3f, 0xf0, 0x00, 0x00, 0x00, 
+0x00, 0xf8, 0xff, 0x3f, 0xc0, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x3f, 
+0x80, 0x01, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x7f, 0x00, 0x61, 0x00, 0x00, 
+0x00, 0xf8, 0xff, 0x7f, 0x00, 0xf1, 0x03, 0x00, 0x00, 0xf0, 0xff, 0x7f, 
+0x00, 0xfa, 0x07, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0xf8, 0x0f, 0x00, 
+0x00, 0xc0, 0xe7, 0xff, 0x00, 0xf8, 0x7f, 0x00, 0x00, 0x00, 0xc0, 0xff, 
+0x00, 0xfc, 0xff, 0x00, 0x00, 0x00, 0x80, 0xff, 0x00, 0xfc, 0xff, 0x00, 
+0x00, 0x00, 0x80, 0xff, 0x00, 0xfc, 0xff, 0x03, 0x00, 0x00, 0x80, 0x7f, 
+0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x80, 0x7f, 0x00, 0xfe, 0xff, 0x7f, 
+0x00, 0x00, 0x00, 0x7f, 0x00, 0xfc, 0xff, 0xff, 0x00, 0x00, 0x00, 0x7f, 
+0x00, 0xfc, 0xff, 0xff, 0x00, 0x00, 0x00, 0x3f, 0x00, 0xf8, 0xff, 0xff, 
+0x00, 0x00, 0x00, 0x3f, 0x00, 0xf8, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x3f, 
+0x00, 0xf0, 0xff, 0x3f, 0x00, 0x00, 0x80, 0x3f, 0x00, 0xf0, 0xff, 0x3f, 
+0x00, 0x00, 0x80, 0x3f, 0x00, 0xc0, 0xff, 0x3f, 0x00, 0x00, 0x80, 0x3f, 
+0x00, 0x80, 0xff, 0x3f, 0x00, 0x00, 0x80, 0x1f, 0x00, 0x80, 0xff, 0x3f, 
+0x00, 0x00, 0x80, 0x0f, 0x00, 0x80, 0xff, 0x0f, 0x00, 0x00, 0x80, 0x0f, 
+0x00, 0x00, 0xff, 0x03, 0x00, 0x00, 0x80, 0x0f, 0x00, 0x00, 0xff, 0x03, 
+0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0xff, 0x03, 0x00, 0x00, 0x80, 0x03, 
+0x00, 0x00, 0xff, 0x01, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0xff, 0x00, 
+0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0xe0, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x30, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-04.xbm b/xlockmore-4.14/bitmaps/terra-04.xbm
new file mode 100644 (file)
index 0000000..7adeff8
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra04_width 64
+#define terra04_height 64
+#define terra04_x_hot 32
+#define terra04_y_hot 32
+static unsigned char terra04_bits[] = {
+0x00, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x8f, 
+0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x9d, 0x07, 0x08, 0x00, 0x00, 
+0x00, 0x00, 0x3e, 0x81, 0x03, 0x70, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x0b, 
+0x00, 0xa0, 0x00, 0x00, 0x00, 0xc0, 0x9f, 0x0f, 0x00, 0x90, 0x02, 0x00, 
+0x00, 0xe0, 0xdf, 0x1f, 0x00, 0x70, 0x07, 0x00, 0x00, 0xf8, 0xff, 0x31, 
+0x00, 0x80, 0x1f, 0x00, 0x00, 0xf8, 0xff, 0x03, 0x00, 0x00, 0x3f, 0x00, 
+0x00, 0xfc, 0xff, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0xfe, 0x7f, 0x00, 
+0x00, 0x80, 0xf3, 0x00, 0x00, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xc3, 0x01, 
+0x00, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x02, 0x01, 0x80, 0xff, 0x07, 0x00, 
+0x00, 0x00, 0x38, 0x00, 0x80, 0xff, 0x03, 0x00, 0x00, 0x00, 0x7e, 0x00, 
+0x80, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0x07, 0xc0, 0x07, 0x01, 0x00, 
+0x00, 0x00, 0xfe, 0x0f, 0xc0, 0x03, 0x01, 0x00, 0x00, 0x00, 0xff, 0x1f, 
+0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0xff, 0x1f, 0x80, 0x01, 0x00, 0x00, 
+0x00, 0x00, 0xff, 0x1f, 0x80, 0x11, 0x02, 0x00, 0x00, 0x00, 0xff, 0x3f, 
+0x80, 0x1b, 0x18, 0x00, 0x00, 0x00, 0xff, 0x3f, 0x80, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xff, 0x3f, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0xff, 0x7f, 
+0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x10, 0x08, 0x00, 
+0x00, 0x00, 0xfe, 0x7f, 0x00, 0x20, 0xfe, 0x01, 0x00, 0x00, 0xfc, 0x7f, 
+0x00, 0x40, 0xff, 0x03, 0x00, 0x00, 0xfc, 0x7f, 0x00, 0x00, 0xff, 0x07, 
+0x00, 0x00, 0xf8, 0xfe, 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xfc, 
+0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x80, 0xff, 0x7f, 
+0x00, 0x00, 0x00, 0xf8, 0x00, 0x80, 0xff, 0xff, 0x00, 0x00, 0x00, 0xf8, 
+0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0xf8, 0x00, 0x80, 0xff, 0xff, 
+0x3f, 0x00, 0x00, 0xf0, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xf0, 
+0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x70, 0x00, 0x00, 0xff, 0xff, 
+0x7f, 0x00, 0x00, 0x70, 0x00, 0x00, 0xfe, 0xff, 0x3f, 0x00, 0x00, 0x70, 
+0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x78, 0x00, 0x00, 0xfc, 0xff, 
+0x1f, 0x00, 0x00, 0x78, 0x00, 0x00, 0xf8, 0xff, 0x1f, 0x00, 0x00, 0x38, 
+0x00, 0x00, 0xe0, 0xff, 0x0f, 0x00, 0x00, 0x38, 0x00, 0x00, 0xe0, 0xff, 
+0x0f, 0x00, 0x00, 0x38, 0x00, 0x00, 0xe0, 0xff, 0x03, 0x00, 0x00, 0x1c, 
+0x00, 0x00, 0xe0, 0xff, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0xe0, 0xff, 
+0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x0c, 
+0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0xe0, 0x3f, 
+0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x80, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x70, 0x1e, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-05.xbm b/xlockmore-4.14/bitmaps/terra-05.xbm
new file mode 100644 (file)
index 0000000..8805cdc
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra05_width 64
+#define terra05_height 64
+#define terra05_x_hot 32
+#define terra05_y_hot 32
+static unsigned char terra05_bits[] = {
+0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3f, 
+0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x67, 0x3c, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0x00, 0x0c, 0x20, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x78, 
+0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0xff, 0xf8, 0x00, 0x40, 0x02, 0x00, 
+0x00, 0xc0, 0xff, 0xfd, 0x01, 0x80, 0x06, 0x00, 0x00, 0xe0, 0xff, 0x7f, 
+0x02, 0x00, 0x1e, 0x00, 0x00, 0xf0, 0xff, 0x3f, 0x00, 0x00, 0x3c, 0x00, 
+0x00, 0xf8, 0xff, 0x2f, 0x00, 0x00, 0x70, 0x00, 0x00, 0xf8, 0xff, 0x07, 
+0x00, 0x00, 0xdc, 0x00, 0x00, 0xfc, 0xff, 0x03, 0x00, 0x00, 0x38, 0x01, 
+0x00, 0xfe, 0xff, 0x01, 0x00, 0x00, 0x30, 0x01, 0x00, 0xfe, 0xff, 0x00, 
+0x00, 0x00, 0xc0, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0xe0, 0x03, 
+0x00, 0xfe, 0x3f, 0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x7c, 0x20, 0x00, 
+0x00, 0x00, 0xe0, 0x0f, 0x00, 0x3c, 0x20, 0x00, 0x00, 0x00, 0xe0, 0x1f, 
+0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x1f, 0x00, 0x38, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0x1f, 0x00, 0x38, 0xc2, 0x00, 0x00, 0x00, 0xe0, 0x3f, 
+0x00, 0x38, 0x03, 0x06, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0xf0, 0x01, 0x00, 
+0x00, 0x00, 0xe0, 0x3f, 0x00, 0x80, 0x07, 0x00, 0x00, 0x00, 0xe0, 0x7f, 
+0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x04, 0x02, 
+0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x88, 0x7f, 0x00, 0x00, 0x80, 0x7f, 
+0x00, 0x00, 0xd0, 0xff, 0x00, 0x00, 0x80, 0x7f, 0x00, 0x00, 0x80, 0xff, 
+0x03, 0x00, 0x00, 0xef, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x00, 0x00, 0xe0, 
+0x00, 0x00, 0xc0, 0xff, 0x1f, 0x00, 0x00, 0xc0, 0x00, 0x00, 0xe0, 0xff, 
+0x1f, 0x00, 0x00, 0xc0, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x00, 0xc0, 
+0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0xc0, 0x00, 0x00, 0xe0, 0xff, 
+0xff, 0x0f, 0x00, 0x80, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x1f, 0x00, 0x80, 
+0x00, 0x00, 0xe0, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 
+0xff, 0x1f, 0x00, 0x40, 0x00, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, 0x40, 
+0x00, 0x00, 0x80, 0xff, 0xff, 0x07, 0x00, 0x40, 0x00, 0x00, 0x00, 0xff, 
+0xff, 0x07, 0x00, 0x40, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x07, 0x00, 0x20, 
+0x00, 0x00, 0x00, 0xf8, 0xff, 0x03, 0x00, 0x20, 0x00, 0x00, 0x00, 0xf8, 
+0xff, 0x03, 0x00, 0x20, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf8, 0x3f, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0xf8, 
+0x1f, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x08, 
+0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 
+0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x03, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x19, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-06.xbm b/xlockmore-4.14/bitmaps/terra-06.xbm
new file mode 100644 (file)
index 0000000..b9d0992
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra06_width 64
+#define terra06_height 64
+#define terra06_x_hot 32
+#define terra06_y_hot 32
+static unsigned char terra06_bits[] = {
+0x00, 0x00, 0x00, 0x60, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 
+0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x9f, 0xf3, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0x07, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xc3, 
+0x05, 0x80, 0x00, 0x00, 0x00, 0x00, 0xff, 0xc7, 0x0f, 0x00, 0x02, 0x00, 
+0x00, 0x80, 0xff, 0xdf, 0x1f, 0x00, 0x06, 0x00, 0x00, 0x80, 0xff, 0xff, 
+0x07, 0x00, 0x18, 0x00, 0x00, 0x80, 0xff, 0xff, 0x07, 0x00, 0x30, 0x00, 
+0x00, 0xc0, 0xff, 0xff, 0x01, 0x00, 0x40, 0x00, 0x00, 0xe0, 0xff, 0xff, 
+0x00, 0x00, 0xe0, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0x00, 
+0x00, 0xf0, 0xff, 0x3f, 0x00, 0x00, 0x80, 0x00, 0x00, 0xf0, 0xff, 0x3f, 
+0x00, 0x00, 0x00, 0x03, 0x00, 0xe0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x07, 
+0x00, 0xe0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x07, 0x00, 0xc0, 0x1f, 0x08, 
+0x00, 0x00, 0x00, 0x0e, 0x00, 0xc0, 0x0f, 0x08, 0x00, 0x00, 0x00, 0x1e, 
+0x00, 0x80, 0x07, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x80, 0x07, 0x00, 
+0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x87, 0x20, 0x00, 0x00, 0x00, 0x3e, 
+0x00, 0x00, 0xcf, 0x00, 0x03, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x7e, 0x00, 
+0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x7c, 
+0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x81, 
+0x01, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0xc2, 0x3f, 0x00, 0x00, 0x78, 
+0x00, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0xe0, 
+0xff, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x07, 0x00, 0x80, 
+0x00, 0x00, 0x00, 0xe0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 
+0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x1f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf8, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 
+0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x07, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xe0, 
+0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x01, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xfe, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x3f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xfe, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xfe, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x07, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x03, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-07.xbm b/xlockmore-4.14/bitmaps/terra-07.xbm
new file mode 100644 (file)
index 0000000..8e45e84
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra07_width 64
+#define terra07_height 64
+#define terra07_x_hot 32
+#define terra07_y_hot 32
+static unsigned char terra07_bits[] = {
+0x00, 0x00, 0x00, 0xc0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe4, 
+0xe1, 0x01, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xcc, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0x3f, 0x08, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf9, 0x1f, 
+0x2c, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x7f, 0x7c, 0x00, 0x02, 0x00, 
+0x00, 0x00, 0xfc, 0xff, 0xfd, 0x01, 0x08, 0x00, 0x00, 0x00, 0xfc, 0xff, 
+0xff, 0x02, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x7f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0xbf, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 
+0x1f, 0x00, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x01, 
+0x00, 0x00, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 
+0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x03, 0x00, 0x00, 0x04, 
+0x00, 0x00, 0xfe, 0xbf, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x03, 
+0x01, 0x00, 0x00, 0x08, 0x00, 0x00, 0xf8, 0x01, 0x02, 0x00, 0x00, 0x18, 
+0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0xe0, 0x01, 
+0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0xe0, 0x21, 0x08, 0x00, 0x00, 0x30, 
+0x00, 0x00, 0xe0, 0x33, 0xe0, 0x00, 0x00, 0x30, 0x00, 0x00, 0x80, 0x3f, 
+0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0x60, 
+0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x80, 
+0x40, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x80, 0xe1, 0x0f, 0x00, 0x40, 
+0x00, 0x00, 0x00, 0x00, 0xfa, 0x1f, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 
+0xf0, 0x3f, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x01, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xfc, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x07, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xfc, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x7f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x07, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xc0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-08.xbm b/xlockmore-4.14/bitmaps/terra-08.xbm
new file mode 100644 (file)
index 0000000..a155047
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra08_width 64
+#define terra08_height 64
+#define terra08_x_hot 32
+#define terra08_y_hot 32
+static unsigned char terra08_bits[] = {
+0x00, 0x00, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x90, 
+0x83, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x33, 0x06, 0x00, 0x00, 
+0x00, 0x00, 0xfc, 0xff, 0x61, 0x08, 0x00, 0x00, 0x00, 0x00, 0xe2, 0xff, 
+0xe1, 0x01, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xc7, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 
+0xff, 0x2f, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x07, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 
+0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 
+0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 
+0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7e, 0x80, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x18, 0x02, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x0c, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x40, 
+0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0xf8, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfd, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfc, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfc, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x07, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xf8, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xe0, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x01, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-09.xbm b/xlockmore-4.14/bitmaps/terra-09.xbm
new file mode 100644 (file)
index 0000000..01486ec
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra09_width 64
+#define terra09_height 64
+#define terra09_x_hot 32
+#define terra09_y_hot 32
+static unsigned char terra09_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 
+0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x9f, 0x0c, 0x00, 0x00, 
+0x00, 0x00, 0xf8, 0xff, 0x0f, 0x03, 0x00, 0x00, 0x00, 0x00, 0x88, 0xff, 
+0x0f, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, 0x1e, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 
+0xff, 0x7f, 0x01, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x7f, 0x01, 0x00, 
+0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 
+0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x3f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xfc, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 
+0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x1f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0x3f, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x1f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x40, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x86, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x3c, 0x02, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x10, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x7e, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x07, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x80, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x80, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x3f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-10.xbm b/xlockmore-4.14/bitmaps/terra-10.xbm
new file mode 100644 (file)
index 0000000..7578bdf
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra10_width 64
+#define terra10_height 64
+#define terra10_x_hot 32
+#define terra10_y_hot 32
+static unsigned char terra10_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0xbf, 0x01, 0x00, 0x00, 0x00, 0x00, 0xb0, 0xff, 0xff, 0x04, 0x00, 0x00, 
+0x00, 0x00, 0xc6, 0xff, 0x7f, 0x4c, 0x00, 0x00, 0x00, 0x00, 0x60, 0xf8, 
+0x7f, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x73, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf0, 0x0f, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe8, 0x07, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xd0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8f, 0x10, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xdf, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x82, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc4, 0x07, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xc0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x3f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xf0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x7f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x0f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-11.xbm b/xlockmore-4.14/bitmaps/terra-11.xbm
new file mode 100644 (file)
index 0000000..52681d2
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra11_width 64
+#define terra11_height 64
+#define terra11_x_hot 32
+#define terra11_y_hot 32
+static unsigned char terra11_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xfe, 0xff, 0x0b, 0x00, 0x00, 
+0x00, 0x00, 0x0e, 0xff, 0xff, 0x33, 0x00, 0x00, 0x00, 0x00, 0x01, 0xc3, 
+0xff, 0xc3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xdf, 0x01, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xfc, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfd, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfa, 0x40, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xf4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x11, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x13, 0x04, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x40, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3c, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 
+0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x04, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 
+0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x08, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x1e, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x20, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 
+0x40, 0x08, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x10, 0x00, 0x00, 
+0x00, 0x00, 0x60, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 
+0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-12.xbm b/xlockmore-4.14/bitmaps/terra-12.xbm
new file mode 100644 (file)
index 0000000..844e2fa
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra12_width 64
+#define terra12_height 64
+#define terra12_x_hot 32
+#define terra12_y_hot 32
+static unsigned char terra12_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xfb, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x3e, 0xf8, 0xff, 0x6f, 0x00, 0x00, 0x00, 0x00, 0x06, 0x38, 
+0xfc, 0x9f, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0xf8, 0x7f, 0x03, 0x00, 
+0x00, 0x20, 0x00, 0x00, 0xe0, 0xff, 0x07, 0x00, 0x00, 0x08, 0x00, 0x00, 
+0xc0, 0xff, 0x1f, 0x00, 0x00, 0x04, 0x00, 0x00, 0x80, 0xff, 0x3f, 0x00, 
+0x00, 0x02, 0x00, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, 0x01, 0x00, 0x00, 
+0x00, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x7f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 0x40, 0x00, 0x00, 0x00, 
+0x00, 0xfc, 0xff, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x80, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x01, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x48, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 
+0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 
+0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 
+0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x0c, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x20, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 
+0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x38, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x18, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 
+0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0xe0, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x04, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 
+0x80, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x01, 0x00, 0x82, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 
+0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xc0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-13.xbm b/xlockmore-4.14/bitmaps/terra-13.xbm
new file mode 100644 (file)
index 0000000..bbc96e1
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra13_width 64
+#define terra13_height 64
+#define terra13_x_hot 32
+#define terra13_y_hot 32
+static unsigned char terra13_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 
+0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xcf, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xc1, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x01, 0x80, 
+0xe1, 0x3f, 0x00, 0x00, 0x00, 0xc0, 0x0c, 0x00, 0x80, 0xff, 0x03, 0x00, 
+0x00, 0x60, 0x02, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x38, 0x00, 0x00, 
+0x00, 0xfc, 0x1f, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xf8, 0x3f, 0x00, 
+0x00, 0x06, 0x00, 0x00, 0x00, 0xf0, 0x7f, 0x00, 0x00, 0x01, 0x00, 0x00, 
+0x00, 0xe0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x01, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x01, 0xc0, 0x01, 0x00, 0x00, 
+0x00, 0x80, 0xff, 0x03, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x11, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x23, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x01, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1c, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x06, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-14.xbm b/xlockmore-4.14/bitmaps/terra-14.xbm
new file mode 100644 (file)
index 0000000..9a33968
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra14_width 64
+#define terra14_height 64
+#define terra14_x_hot 32
+#define terra14_y_hot 32
+static unsigned char terra14_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 
+0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x7f, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0x0f, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x87, 0x00, 
+0x1c, 0xfe, 0x00, 0x00, 0x00, 0xc0, 0x61, 0x00, 0x00, 0xfc, 0x03, 0x00, 
+0x00, 0xe0, 0x01, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0xf8, 0x01, 0x00, 
+0x00, 0xc0, 0x1f, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x80, 0x3f, 0x00, 
+0x00, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x07, 0x00, 0x00, 
+0x00, 0x00, 0xff, 0x00, 0x80, 0x13, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x01, 
+0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x01, 0x40, 0x05, 0x00, 0x00, 
+0x00, 0x00, 0xf8, 0x03, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 
+0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x30, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x07, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 
+0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x08, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x0c, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x28, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x63, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc1, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x30, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x01, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x3e, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x70, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x10, 0x1e, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-15.xbm b/xlockmore-4.14/bitmaps/terra-15.xbm
new file mode 100644 (file)
index 0000000..ecccd46
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra15_width 64
+#define terra15_height 64
+#define terra15_x_hot 32
+#define terra15_y_hot 32
+static unsigned char terra15_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x05, 
+0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xf9, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0x7f, 0xf0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x04, 
+0xc0, 0xf8, 0x00, 0x00, 0x00, 0xc0, 0x0f, 0x06, 0x00, 0xe0, 0x03, 0x00, 
+0x00, 0xe0, 0x0f, 0x01, 0x00, 0x80, 0x0f, 0x00, 0x00, 0xf8, 0x0f, 0x00, 
+0x00, 0x00, 0x1e, 0x00, 0x00, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x3c, 0x00, 
+0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x3f, 0x00, 0x00, 
+0x00, 0x00, 0xf0, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x01, 
+0x80, 0x8b, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0xc0, 0x41, 0x00, 0x00, 
+0x00, 0x00, 0xc0, 0x03, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 
+0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0xf0, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x0e, 0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 
+0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x10, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 
+0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x06, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x05, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x16, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x3c, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x27, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xc0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x07, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe3, 0x07, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x80, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x30, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x70, 0x1c, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-16.xbm b/xlockmore-4.14/bitmaps/terra-16.xbm
new file mode 100644 (file)
index 0000000..0bfbbb6
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra16_width 64
+#define terra16_height 64
+#define terra16_x_hot 32
+#define terra16_y_hot 32
+static unsigned char terra16_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1b, 
+0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xef, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0x83, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xff, 0x61, 
+0x00, 0xe6, 0x00, 0x00, 0x00, 0xc0, 0x7f, 0x30, 0x00, 0x00, 0x03, 0x00, 
+0x00, 0xe0, 0xff, 0x10, 0x00, 0x00, 0x06, 0x00, 0x00, 0xf8, 0x7f, 0x00, 
+0x00, 0x00, 0x18, 0x00, 0x00, 0xfc, 0x5f, 0x00, 0x00, 0x00, 0x30, 0x00, 
+0x00, 0xfe, 0x4f, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0xff, 0x01, 0x00, 
+0x00, 0x00, 0xc0, 0x00, 0x80, 0xbf, 0x10, 0x00, 0x00, 0x00, 0x80, 0x01, 
+0x80, 0x9f, 0x08, 0x00, 0x00, 0x00, 0x00, 0x01, 0xc0, 0x0f, 0x06, 0x00, 
+0x00, 0x00, 0x00, 0x02, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 
+0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x08, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 
+0xf8, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x02, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x18, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x64, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x64, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x64, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x68, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x8f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x40, 0x04, 0x16, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x60, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x0c, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x0d, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfc, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x3f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x01, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfc, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0xfe, 0x01, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xf0, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x06, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x18, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-17.xbm b/xlockmore-4.14/bitmaps/terra-17.xbm
new file mode 100644 (file)
index 0000000..8f28b27
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra17_width 64
+#define terra17_height 64
+#define terra17_x_hot 32
+#define terra17_y_hot 32
+static unsigned char terra17_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x6f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x3f, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0x1f, 0x7e, 0x00, 0x00, 0x00, 0x00, 0xff, 0x0f, 
+0x06, 0x90, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x03, 0x03, 0x10, 0x02, 0x00, 
+0x00, 0xe0, 0xff, 0x07, 0x01, 0x00, 0x04, 0x00, 0x00, 0xf8, 0xff, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfe, 0xff, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1b, 0x02, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0xff, 0x09, 0x01, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x81, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xec, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe4, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe6, 0x41, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc2, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xc2, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x81, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x10, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x20, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x0e, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x40, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x40, 0x26, 0x68, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x20, 0xe0, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x87, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x1c, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f, 0x07, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x80, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xf0, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x3f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xc0, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xc3, 0x3f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x1e, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0xc0, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb0, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x03, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-18.xbm b/xlockmore-4.14/bitmaps/terra-18.xbm
new file mode 100644 (file)
index 0000000..bc61989
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra18_width 64
+#define terra18_height 64
+#define terra18_x_hot 32
+#define terra18_y_hot 32
+static unsigned char terra18_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xbf, 
+0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0e, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0xff, 0x78, 0x00, 0x00, 0x00, 0x00, 0xff, 0x7f, 
+0x30, 0xc0, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x3f, 0x30, 0x00, 0x00, 0x00, 
+0x00, 0xe0, 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xbf, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfe, 0xff, 0x9f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x43, 
+0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x41, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0xff, 0x1f, 0x61, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x1f, 0x11, 
+0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x1f, 0x04, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x70, 0xbe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x38, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x1e, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x08, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x08, 0x3c, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x38, 0x30, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x08, 0x02, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x22, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x86, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc6, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xc4, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xcc, 0x09, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0xf0, 
+0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x40, 0xc0, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x8f, 
+0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xdf, 0x01, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 
+0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x07, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 
+0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xf8, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0xf8, 
+0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xc0, 0x03, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x02, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x0f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x03, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-19.xbm b/xlockmore-4.14/bitmaps/terra-19.xbm
new file mode 100644 (file)
index 0000000..4b45fb6
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra19_width 64
+#define terra19_height 64
+#define terra19_x_hot 32
+#define terra19_y_hot 32
+static unsigned char terra19_bits[] = {
+0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f, 
+0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0xff, 0x67, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 
+0x07, 0x81, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x83, 0x01, 0x00, 0x00, 
+0x00, 0xe0, 0xff, 0xff, 0x0f, 0x01, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 
+0x07, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 
+0x00, 0xfe, 0xff, 0xff, 0x13, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x7f, 
+0x08, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x23, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0xff, 0xff, 0x63, 0x08, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x03, 
+0x06, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x87, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x07, 
+0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0xe8, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0xc8, 0xff, 0x7f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc4, 0xe7, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xc4, 0xe3, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc2, 0xe1, 0x07, 0x04, 
+0x00, 0x00, 0x00, 0x00, 0xc0, 0x80, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x40, 0x80, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x0e, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x02, 0x08, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xc0, 0xe1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xf1, 0x08, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xf1, 0x02, 0x01, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x73, 0x02, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x06, 
+0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x80, 0x23, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 
+0x63, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x6f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xfc, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 
+0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 
+0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 
+0xfe, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x3f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-20.xbm b/xlockmore-4.14/bitmaps/terra-20.xbm
new file mode 100644 (file)
index 0000000..4c34ba9
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra20_width 64
+#define terra20_height 64
+#define terra20_x_hot 32
+#define terra20_y_hot 32
+static unsigned char terra20_bits[] = {
+0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 
+0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 
+0x3f, 0x08, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x1f, 0x08, 0x02, 0x00, 
+0x00, 0xe0, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 
+0x7f, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 
+0x00, 0xfe, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 
+0x0f, 0x01, 0x00, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x0d, 0x00, 0x00, 0x00, 
+0x80, 0xff, 0xff, 0xff, 0x08, 0x01, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 
+0x88, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0x20, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 
+0x01, 0x00, 0x00, 0x00, 0xd8, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 
+0x38, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x38, 0xfe, 0xff, 0x1f, 
+0x01, 0x00, 0x00, 0x00, 0x3c, 0xfe, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x1c, 0x7c, 0xf8, 0x04, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x3c, 0xf8, 0x01, 
+0x01, 0x00, 0x00, 0x00, 0x06, 0x0c, 0xe0, 0x03, 0x01, 0x00, 0x00, 0x00, 
+0x02, 0x0c, 0xe0, 0x03, 0x02, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x80, 0x03, 
+0x04, 0x00, 0x00, 0x00, 0x02, 0x04, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x03, 0x00, 0x10, 0x00, 0x06, 0x00, 0x00, 0x00, 0x03, 0x00, 0x20, 0x40, 
+0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x68, 0x60, 0x00, 0x00, 0x00, 0x00, 
+0x01, 0x00, 0x50, 0x70, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x60, 0x7c, 
+0x10, 0x00, 0x00, 0x00, 0x01, 0x00, 0x60, 0x3c, 0xc0, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xc0, 0x38, 0x81, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 
+0x02, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xc0, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x1b, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xfe, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0xff, 0x3f, 0x00, 0x00, 0x08, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 
+0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xc0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0x83, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x12, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-21.xbm b/xlockmore-4.14/bitmaps/terra-21.xbm
new file mode 100644 (file)
index 0000000..4067387
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra21_width 64
+#define terra21_height 64
+#define terra21_x_hot 32
+#define terra21_y_hot 32
+static unsigned char terra21_bits[] = {
+0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 
+0x37, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 
+0xff, 0x21, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x61, 0x00, 0x00, 
+0x00, 0xe0, 0xff, 0xff, 0xff, 0x47, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 
+0xff, 0x0f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 
+0x00, 0xfe, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 
+0xff, 0x21, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x9f, 0x21, 0x00, 0x00, 
+0xc0, 0xff, 0xff, 0xff, 0x1f, 0x21, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 
+0x1f, 0x30, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x3f, 0x04, 0x00, 0x00, 
+0xe0, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xf0, 0xfe, 0xff, 0xff, 
+0x7f, 0x00, 0x00, 0x00, 0xf8, 0xfe, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 
+0xf8, 0xe0, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xe8, 0xe3, 0xff, 0xff, 
+0x0f, 0x00, 0x00, 0x00, 0xfc, 0xc1, 0x1f, 0xff, 0x00, 0x00, 0x00, 0x00, 
+0xf4, 0x81, 0x0f, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x76, 0x80, 0x07, 0xfe, 
+0x00, 0x00, 0x00, 0x00, 0x36, 0x80, 0x03, 0xf8, 0x00, 0x00, 0x00, 0x00, 
+0x1e, 0x80, 0x01, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x01, 0xe0, 
+0x00, 0x00, 0x00, 0x00, 0x1e, 0x80, 0x01, 0x40, 0x00, 0x03, 0x00, 0x00, 
+0x1f, 0x00, 0x02, 0x08, 0x00, 0x03, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x10, 
+0x10, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x16, 0x38, 0x00, 0x00, 0x00, 
+0x0f, 0x00, 0x00, 0x2c, 0x1c, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x18, 
+0x3e, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x30, 0x1e, 0x20, 0x00, 0x00, 
+0x03, 0x00, 0x00, 0x70, 0xdc, 0xa0, 0x01, 0x00, 0x03, 0x00, 0x00, 0x60, 
+0x00, 0x80, 0x07, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 
+0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x06, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x06, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x26, 0x00, 0x00, 0x00, 
+0x00, 0x7e, 0x06, 0x00, 0x26, 0x00, 0x00, 0x00, 0x00, 0xff, 0x06, 0x00, 
+0x24, 0x00, 0x00, 0x00, 0x80, 0xff, 0x07, 0x00, 0x24, 0x00, 0x00, 0x00, 
+0xe0, 0xff, 0x0f, 0x00, 0x28, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x0f, 0x00, 
+0x08, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x0f, 0x00, 0x08, 0x00, 0x00, 0x00, 
+0xf8, 0xff, 0x0f, 0x00, 0x10, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x0f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf0, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x03, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x90, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-22.xbm b/xlockmore-4.14/bitmaps/terra-22.xbm
new file mode 100644 (file)
index 0000000..fabfb41
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra22_width 64
+#define terra22_height 64
+#define terra22_x_hot 32
+#define terra22_y_hot 32
+static unsigned char terra22_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xce, 
+0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd0, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xf8, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 
+0xff, 0x0f, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x8f, 0x01, 0x00, 
+0x00, 0xe0, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 
+0xff, 0x7f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 
+0x00, 0xfe, 0xff, 0xff, 0xff, 0x7f, 0x02, 0x00, 0x00, 0xff, 0xff, 0xff, 
+0xff, 0x3f, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0x13, 0x02, 0x00, 
+0x80, 0xff, 0xff, 0xff, 0xff, 0x23, 0x02, 0x00, 0x00, 0xfe, 0xff, 0xff, 
+0xff, 0x27, 0x03, 0x00, 0x20, 0xfe, 0xff, 0xff, 0xff, 0x87, 0x00, 0x00, 
+0xe0, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0xf0, 0xf7, 0xff, 0xff, 
+0xff, 0x0f, 0x00, 0x00, 0xf8, 0xe7, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0xb8, 0x0f, 0xfc, 0xff, 0xff, 0x07, 0x00, 0x00, 0xb8, 0x3f, 0xfc, 0xff, 
+0xff, 0x03, 0x00, 0x00, 0xbc, 0x3f, 0xf0, 0xc7, 0xbf, 0x00, 0x00, 0x00, 
+0xbc, 0x1f, 0xf0, 0x83, 0x9f, 0x00, 0x00, 0x00, 0xbe, 0x0f, 0xf0, 0x81, 
+0x3f, 0x00, 0x00, 0x00, 0xbe, 0x03, 0xf0, 0x00, 0x7e, 0x00, 0x00, 0x00, 
+0xfe, 0x00, 0x60, 0x00, 0x7e, 0x20, 0x00, 0x00, 0x7e, 0x00, 0x60, 0x00, 
+0x70, 0x00, 0x00, 0x00, 0xfe, 0x01, 0x60, 0x00, 0x20, 0xc0, 0x00, 0x00, 
+0xff, 0x01, 0x80, 0x00, 0x02, 0xc0, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 
+0x04, 0x88, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x09, 0x0c, 0x00, 0x00, 
+0xff, 0x00, 0x00, 0x00, 0x0a, 0x0e, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x00, 
+0x8c, 0x0f, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x1c, 0x0f, 0x08, 0x00, 
+0x1f, 0x00, 0x00, 0x00, 0x38, 0x27, 0x78, 0x00, 0x1f, 0x00, 0x00, 0x00, 
+0x10, 0x20, 0xe0, 0x00, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 
+0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x3e, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x02, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x3e, 0x03, 0x00, 0x00, 
+0x00, 0x80, 0x4f, 0x00, 0x3e, 0x03, 0x00, 0x00, 0x00, 0xc0, 0x7f, 0x00, 
+0x3c, 0x03, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x00, 0x3c, 0x02, 0x00, 0x00, 
+0x00, 0xf8, 0xff, 0x00, 0x38, 0x02, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 
+0x38, 0x02, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 0x30, 0x00, 0x00, 0x00, 
+0x00, 0xfe, 0xff, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x00, 
+0x60, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x40, 0x00, 0x00, 0x00, 
+0x00, 0x1e, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-23.xbm b/xlockmore-4.14/bitmaps/terra-23.xbm
new file mode 100644 (file)
index 0000000..ab8c6c7
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra23_width 64
+#define terra23_height 64
+#define terra23_x_hot 32
+#define terra23_y_hot 32
+static unsigned char terra23_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 
+0xdf, 0x01, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfc, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 
+0xff, 0x3f, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x7f, 0x02, 0x00, 
+0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0xf8, 0xff, 0xff, 
+0xff, 0xff, 0x03, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 
+0xff, 0xff, 0x01, 0x00, 0x00, 0xfa, 0xff, 0xff, 0xff, 0xbf, 0x01, 0x00, 
+0x40, 0xfc, 0xff, 0xff, 0xff, 0x7f, 0x02, 0x00, 0x40, 0xe0, 0xff, 0xff, 
+0xff, 0x7f, 0x30, 0x00, 0x20, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x08, 0x00, 
+0xe0, 0xfd, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0xf0, 0x7f, 0xfe, 0xff, 
+0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xfc, 0xff, 0xff, 0xff, 0x01, 0x00, 
+0xf8, 0xfb, 0x84, 0xff, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xfb, 0x0f, 0xff, 
+0xff, 0x7f, 0x00, 0x00, 0xfc, 0xfb, 0x07, 0xfc, 0xf3, 0x2f, 0x00, 0x00, 
+0xfc, 0xf3, 0x03, 0xfc, 0xe1, 0x27, 0x00, 0x00, 0xfe, 0xf3, 0x01, 0x7c, 
+0xc0, 0x0f, 0x04, 0x00, 0xfe, 0x73, 0x00, 0x38, 0x00, 0x1f, 0x04, 0x00, 
+0xfe, 0x1f, 0x00, 0x38, 0x00, 0x1f, 0x08, 0x00, 0xfe, 0x07, 0x00, 0x38, 
+0x00, 0x1c, 0x10, 0x00, 0xfe, 0x7f, 0x00, 0x10, 0x00, 0x08, 0x10, 0x00, 
+0xff, 0x3f, 0x00, 0x40, 0x00, 0x01, 0x10, 0x00, 0xff, 0x3f, 0x00, 0x00, 
+0x00, 0x02, 0x02, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x80, 0x02, 0x03, 0x00, 
+0xfe, 0x0f, 0x00, 0x00, 0x00, 0x87, 0x03, 0x00, 0xfe, 0x07, 0x00, 0x00, 
+0x00, 0xc7, 0x13, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x00, 0xc6, 0x03, 0x00, 
+0xfe, 0x03, 0x00, 0x00, 0x00, 0xcc, 0x09, 0x07, 0xfc, 0x01, 0x00, 0x00, 
+0x00, 0x0c, 0x08, 0x0e, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 
+0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x20, 0x0c, 0xfc, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x10, 0x10, 0xf8, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xf8, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xf8, 0x63, 0x00, 0x00, 
+0x00, 0x00, 0xf0, 0x05, 0xf8, 0x33, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 
+0xf8, 0x21, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0xf0, 0x21, 0x00, 0x00, 
+0x00, 0x00, 0xff, 0x07, 0xf0, 0x23, 0x00, 0x00, 0x00, 0x80, 0xff, 0x07, 
+0xe0, 0x23, 0x00, 0x00, 0x00, 0x80, 0xff, 0x07, 0xe0, 0x03, 0x00, 0x00, 
+0x00, 0xc0, 0xff, 0x07, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x80, 0xff, 0x03, 
+0x80, 0x03, 0x00, 0x00, 0x00, 0x80, 0xff, 0x03, 0x80, 0x03, 0x00, 0x00, 
+0x00, 0xc0, 0xe3, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-24.xbm b/xlockmore-4.14/bitmaps/terra-24.xbm
new file mode 100644 (file)
index 0000000..3de2659
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra24_width 64
+#define terra24_height 64
+#define terra24_x_hot 32
+#define terra24_y_hot 32
+static unsigned char terra24_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 
+0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 
+0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 
+0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xf8, 0xff, 0xff, 
+0xff, 0xff, 0x0f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 
+0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xe8, 0xff, 0xff, 
+0xff, 0xff, 0x0f, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x0b, 0x00, 
+0x00, 0xd4, 0xff, 0xff, 0xff, 0xff, 0x87, 0x00, 0xc0, 0x01, 0xff, 0xff, 
+0xff, 0xff, 0xa7, 0x00, 0xe0, 0x01, 0xff, 0xff, 0xff, 0xff, 0x8f, 0x00, 
+0xe0, 0xdf, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xf0, 0xff, 0xdf, 0xff, 
+0xff, 0xff, 0x1f, 0x00, 0xf8, 0xbf, 0x1f, 0xff, 0xff, 0xff, 0x1f, 0x00, 
+0xf8, 0x3f, 0xbf, 0xe0, 0xff, 0xff, 0x1f, 0x00, 0xf8, 0x7f, 0xff, 0xc1, 
+0xff, 0xff, 0x0f, 0x00, 0xfc, 0x7f, 0xff, 0x01, 0xff, 0xfc, 0x01, 0x00, 
+0xfc, 0x7f, 0xfe, 0x00, 0x7e, 0xf8, 0x05, 0x00, 0xfe, 0x7f, 0x7e, 0x00, 
+0x3e, 0xf0, 0x03, 0x00, 0xfe, 0xff, 0x1e, 0x00, 0x1e, 0xc0, 0x03, 0x00, 
+0xfe, 0xff, 0x03, 0x00, 0x0c, 0xc0, 0x07, 0x00, 0xfe, 0xff, 0x01, 0x00, 
+0x0c, 0x00, 0x07, 0x00, 0xfe, 0xff, 0x0f, 0x00, 0x0c, 0x00, 0x02, 0x00, 
+0xff, 0xff, 0x0f, 0x00, 0x00, 0x40, 0x00, 0x02, 0xff, 0xff, 0x07, 0x00, 
+0x00, 0x80, 0x40, 0x02, 0xf8, 0xff, 0x07, 0x00, 0x00, 0x20, 0x60, 0x00, 
+0xf0, 0xff, 0x03, 0x00, 0x00, 0x40, 0x61, 0x00, 0xf0, 0xff, 0x01, 0x00, 
+0x00, 0x80, 0x71, 0x00, 0xf0, 0xff, 0x00, 0x00, 0x00, 0x80, 0x71, 0x00, 
+0xf0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x33, 0x30, 0xf0, 0x7f, 0x00, 0x00, 
+0x00, 0x00, 0x02, 0x20, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 
+0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x20, 0x62, 0xe0, 0x7f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0x7f, 0x08, 0x00, 0x00, 0x00, 0x00, 0x08, 0xe0, 0xff, 0x08, 0x00, 
+0x00, 0x00, 0x00, 0x0e, 0xc0, 0x7f, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x1f, 
+0xc0, 0x3f, 0x0c, 0x00, 0x00, 0x00, 0x80, 0x1f, 0xc0, 0x3f, 0x0c, 0x00, 
+0x00, 0x00, 0xe0, 0x1f, 0x80, 0x3f, 0x0c, 0x00, 0x00, 0x00, 0xf0, 0x1f, 
+0x00, 0x3f, 0x0c, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x3f, 0x00, 0x00, 
+0x00, 0x00, 0xf8, 0x0f, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x0f, 
+0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x1c, 0x00, 0x00, 
+0x00, 0x00, 0x18, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x50, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-25.xbm b/xlockmore-4.14/bitmaps/terra-25.xbm
new file mode 100644 (file)
index 0000000..a966acb
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra25_width 64
+#define terra25_height 64
+#define terra25_x_hot 32
+#define terra25_y_hot 32
+static unsigned char terra25_bits[] = {
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0xf8, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xd8, 0xff, 
+0xff, 0xff, 0x00, 0x00, 0x00, 0x80, 0xf4, 0xff, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0xc0, 0xff, 0xff, 
+0xff, 0xff, 0x1f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 
+0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x4c, 0xff, 0xff, 
+0xff, 0xff, 0x3f, 0x00, 0x00, 0x06, 0xfd, 0xff, 0xff, 0xff, 0x7f, 0x00, 
+0x00, 0x03, 0xfd, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x0f, 0xe0, 0xff, 
+0xff, 0xff, 0x7f, 0x02, 0x80, 0x0f, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x02, 
+0xc0, 0xdf, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xe0, 0xff, 0xff, 0xf3, 
+0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xf7, 0xc7, 0xff, 0xff, 0xff, 0x01, 
+0xf0, 0xff, 0xef, 0x2f, 0xf8, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xef, 0xff, 
+0xf0, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xcf, 0x7f, 0xc0, 0x3f, 0x3f, 0x00, 
+0xf8, 0xff, 0xcf, 0x7f, 0x80, 0x1f, 0x3e, 0x00, 0xfc, 0xff, 0x9f, 0x1f, 
+0x80, 0x0f, 0x7c, 0x00, 0xfc, 0xff, 0x9f, 0x07, 0x80, 0x07, 0x78, 0x00, 
+0xfc, 0xff, 0xff, 0x01, 0x00, 0x07, 0x78, 0x08, 0xfc, 0xff, 0x7f, 0x00, 
+0x00, 0x07, 0xe0, 0x00, 0xfc, 0xff, 0xff, 0x07, 0x00, 0x02, 0x40, 0x10, 
+0xfc, 0xff, 0xff, 0x03, 0x00, 0x08, 0x10, 0x10, 0xdc, 0xff, 0xff, 0x03, 
+0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x28, 0x04, 
+0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x30, 0x06, 0x80, 0xff, 0x7f, 0x00, 
+0x00, 0x00, 0x30, 0x07, 0x80, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x20, 0x46, 
+0x80, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xe0, 0xc6, 0x00, 0xff, 0x1f, 0x00, 
+0x00, 0x00, 0x40, 0x80, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x80, 
+0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0xfe, 0x1f, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0xfe, 0x1f, 0x06, 
+0x00, 0x00, 0x00, 0x70, 0x00, 0xfe, 0x1f, 0x03, 0x00, 0x00, 0x00, 0x38, 
+0x00, 0xfc, 0x0f, 0x03, 0x00, 0x00, 0x00, 0x38, 0x00, 0xfc, 0x07, 0x03, 
+0x00, 0x00, 0x00, 0x3e, 0x00, 0xf8, 0x07, 0x03, 0x00, 0x00, 0x00, 0x1f, 
+0x00, 0xf8, 0x07, 0x01, 0x00, 0x00, 0x00, 0x1f, 0x00, 0xf0, 0x07, 0x00, 
+0x00, 0x00, 0x80, 0x1f, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x80, 0x0f, 
+0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x80, 0x07, 0x00, 0xc0, 0x03, 0x00, 
+0x00, 0x00, 0xc0, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-26.xbm b/xlockmore-4.14/bitmaps/terra-26.xbm
new file mode 100644 (file)
index 0000000..1c0b085
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra26_width 64
+#define terra26_height 64
+#define terra26_x_hot 32
+#define terra26_y_hot 32
+static unsigned char terra26_bits[] = {
+0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xfe, 
+0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x32, 0xff, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0xff, 0xff, 
+0xff, 0xff, 0x1f, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 
+0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x70, 0xf4, 0xff, 
+0xff, 0xff, 0xff, 0x00, 0x00, 0x38, 0xb1, 0xff, 0xff, 0xff, 0xff, 0x01, 
+0x00, 0x18, 0xa2, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0xf8, 0x00, 0xfc, 
+0xff, 0xff, 0xff, 0x01, 0x00, 0xfc, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x03, 
+0x00, 0xfe, 0xfb, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0xff, 0xff, 0xff, 
+0xfe, 0xff, 0xff, 0x07, 0x80, 0xff, 0xff, 0xfd, 0xf1, 0xff, 0xff, 0x07, 
+0xc0, 0xff, 0xff, 0xf9, 0x0b, 0xfe, 0xff, 0x0f, 0xe0, 0xff, 0xff, 0xfb, 
+0x3f, 0xfc, 0xff, 0x07, 0xe0, 0xff, 0xff, 0xf3, 0x3f, 0xf0, 0xe7, 0x03, 
+0xe0, 0xff, 0xff, 0xf3, 0x1f, 0xe0, 0xc3, 0x03, 0xf0, 0xff, 0xff, 0xe7, 
+0x07, 0xe0, 0xc3, 0x03, 0xf0, 0xff, 0xff, 0xef, 0x01, 0xc0, 0x01, 0x07, 
+0xf0, 0xff, 0xff, 0x5f, 0x00, 0xc0, 0x00, 0x07, 0xf0, 0xff, 0xff, 0x1f, 
+0x00, 0x80, 0x00, 0x04, 0xf0, 0xff, 0xff, 0xff, 0x01, 0x80, 0x00, 0x04, 
+0xf0, 0xff, 0xff, 0xff, 0x01, 0x00, 0x02, 0x00, 0xe0, 0xfd, 0xff, 0xff, 
+0x00, 0x00, 0x00, 0x02, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x00, 0x00, 0x21, 
+0x00, 0xf0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x22, 0x00, 0xf0, 0xff, 0x3f, 
+0x00, 0x00, 0x00, 0xf2, 0x00, 0xf0, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xf4, 
+0x00, 0xf0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x6c, 0x00, 0xe0, 0xff, 0x07, 
+0x00, 0x00, 0x00, 0x04, 0x00, 0xc0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x08, 
+0x00, 0xc0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x20, 0x00, 0xc0, 0xff, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xc0, 0xff, 0x0f, 0x01, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x8f, 
+0x01, 0x00, 0x00, 0x40, 0x00, 0xc0, 0xff, 0xc7, 0x01, 0x00, 0x00, 0x00, 
+0x00, 0xc0, 0xff, 0xc3, 0x00, 0x00, 0x00, 0x20, 0x00, 0x80, 0xff, 0xc1, 
+0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0xff, 0xc1, 0x00, 0x00, 0x00, 0x18, 
+0x00, 0x00, 0xff, 0x41, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0xff, 0x00, 
+0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x0c, 
+0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x78, 0x00, 
+0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-27.xbm b/xlockmore-4.14/bitmaps/terra-27.xbm
new file mode 100644 (file)
index 0000000..ef89c5d
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra27_width 64
+#define terra27_height 64
+#define terra27_x_hot 32
+#define terra27_y_hot 32
+static unsigned char terra27_bits[] = {
+0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x30, 0xf8, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf7, 
+0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x10, 0xfb, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0xdc, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0xf8, 0xff, 
+0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x3f, 0x00, 
+0x00, 0x00, 0x7c, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, 0xc7, 0xfe, 
+0xff, 0xff, 0xff, 0x00, 0x00, 0xc0, 0x83, 0xf6, 0xff, 0xff, 0xff, 0x01, 
+0x00, 0xc0, 0x41, 0xf0, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x1f, 0x00, 
+0xff, 0xff, 0xff, 0x03, 0x00, 0xe0, 0x1f, 0x00, 0xff, 0xff, 0xff, 0x07, 
+0x00, 0xf0, 0x7f, 0xef, 0xff, 0xff, 0xff, 0x07, 0x00, 0xf8, 0xff, 0xff, 
+0xbf, 0xff, 0xff, 0x0f, 0x00, 0xfc, 0xff, 0x7f, 0x7f, 0xfc, 0xff, 0x1f, 
+0x00, 0xfe, 0xff, 0xff, 0xfe, 0x82, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0xff, 
+0xfe, 0x0f, 0xff, 0x1f, 0x00, 0xff, 0xff, 0xff, 0xfc, 0x0f, 0x7c, 0x1e, 
+0x00, 0xff, 0xff, 0xff, 0xf9, 0x07, 0x7c, 0x1c, 0x00, 0xff, 0xff, 0xff, 
+0xf9, 0x03, 0x38, 0x1c, 0x80, 0xff, 0xff, 0xff, 0xf3, 0x00, 0x38, 0x18, 
+0x80, 0xff, 0xff, 0xff, 0x37, 0x00, 0x30, 0x30, 0x80, 0xff, 0xff, 0xff, 
+0x0f, 0x00, 0x30, 0x20, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0x20, 0x20, 
+0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0x40, 0x00, 0x00, 0xbe, 0xff, 0xff, 
+0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0x00, 0x90, 
+0x00, 0x00, 0xfc, 0xff, 0x3f, 0x00, 0x00, 0x90, 0x00, 0x00, 0xfc, 0xff, 
+0x0f, 0x00, 0x00, 0xb0, 0x00, 0x00, 0xfc, 0xff, 0x07, 0x00, 0x00, 0xa0, 
+0x01, 0x00, 0xfc, 0xff, 0x07, 0x00, 0x00, 0xe0, 0x01, 0x00, 0xf8, 0xff, 
+0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0xf8, 0xff, 0x03, 0x00, 0x00, 0x00, 
+0x03, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf0, 0xff, 
+0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 
+0x02, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf0, 0xff, 
+0x43, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf0, 0xff, 0x71, 0x00, 0x00, 0x00, 
+0x04, 0x00, 0xf0, 0xff, 0x60, 0x00, 0x00, 0x00, 0x04, 0x00, 0xe0, 0x7f, 
+0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x7f, 0x30, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xe0, 0x7f, 0x10, 0x00, 0x00, 0x10, 0x00, 0x00, 0xc0, 0x3f, 
+0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-28.xbm b/xlockmore-4.14/bitmaps/terra-28.xbm
new file mode 100644 (file)
index 0000000..2be7270
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra28_width 64
+#define terra28_height 64
+#define terra28_x_hot 32
+#define terra28_y_hot 32
+static unsigned char terra28_bits[] = {
+0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 
+0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x40, 0xc0, 0xff, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x04, 0xf0, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 
+0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x80, 0x98, 0xff, 0xff, 0x03, 0x00, 
+0x00, 0x00, 0xe0, 0xfc, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x80, 0xff, 
+0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x3f, 0x00, 
+0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x78, 0xc8, 
+0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x3c, 0xd0, 0xfe, 0xff, 0xff, 0x01, 
+0x00, 0x00, 0x1c, 0x88, 0xfe, 0xff, 0xff, 0x01, 0x00, 0x00, 0xf8, 0x03, 
+0xc0, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfc, 0x03, 0xe0, 0xff, 0xff, 0x07, 
+0x00, 0x00, 0xfe, 0xcf, 0xfb, 0xff, 0xff, 0x07, 0x00, 0x00, 0xff, 0xff, 
+0xff, 0xef, 0xff, 0x0f, 0x00, 0xc0, 0xff, 0xff, 0xdf, 0x9f, 0xff, 0x1f, 
+0x00, 0xc0, 0xff, 0xff, 0xbf, 0xbf, 0xf0, 0x1f, 0x00, 0xe0, 0xff, 0xff, 
+0x3f, 0xff, 0xe1, 0x1f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0xff, 0xc1, 0x37, 
+0x00, 0xe0, 0xff, 0xff, 0x7f, 0xfe, 0x81, 0x33, 0x00, 0xf0, 0xff, 0xff, 
+0xff, 0xfc, 0x80, 0x23, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x3d, 0x00, 0x63, 
+0x00, 0xf0, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x43, 0x00, 0xf0, 0xff, 0xff, 
+0xff, 0x03, 0x00, 0x02, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x02, 
+0x00, 0xe0, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x01, 0xc0, 0xe7, 0xff, 
+0xff, 0x1f, 0x00, 0x00, 0x01, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 
+0x01, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x00, 0x80, 0x01, 0x00, 0x00, 0xff, 
+0xff, 0x07, 0x00, 0x80, 0x03, 0x00, 0x00, 0xff, 0xff, 0x03, 0x00, 0x80, 
+0x07, 0x00, 0x00, 0xff, 0xff, 0x01, 0x00, 0x80, 0x0f, 0x00, 0x00, 0xfe, 
+0xff, 0x01, 0x00, 0x00, 0x0f, 0x00, 0x00, 0xfc, 0xff, 0x00, 0x00, 0x00, 
+0x1f, 0x00, 0x00, 0xfc, 0xff, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0xfc, 
+0xff, 0x01, 0x00, 0x00, 0x0e, 0x00, 0x00, 0xf8, 0xff, 0x01, 0x00, 0x00, 
+0x0e, 0x00, 0x00, 0xfc, 0xff, 0x21, 0x00, 0x00, 0x0e, 0x00, 0x00, 0xfc, 
+0xff, 0x31, 0x00, 0x00, 0x0e, 0x00, 0x00, 0xfc, 0x7f, 0x18, 0x00, 0x00, 
+0x1c, 0x00, 0x00, 0xfc, 0x3f, 0x18, 0x00, 0x00, 0x1c, 0x00, 0x00, 0xf8, 
+0x3f, 0x0c, 0x00, 0x00, 0x18, 0x00, 0x00, 0xf8, 0x3f, 0x0c, 0x00, 0x00, 
+0x08, 0x00, 0x00, 0xf8, 0x1f, 0x04, 0x00, 0x00, 0x18, 0x00, 0x00, 0xf0, 
+0x0f, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0xe0, 
+0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/terra-29.xbm b/xlockmore-4.14/bitmaps/terra-29.xbm
new file mode 100644 (file)
index 0000000..ba9bc5c
--- /dev/null
@@ -0,0 +1,48 @@
+#define terra29_width 64
+#define terra29_height 64
+#define terra29_x_hot 32
+#define terra29_y_hot 32
+static unsigned char terra29_bits[] = {
+0x00, 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x07, 
+0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0xdf, 0x0f, 0x00, 0x00, 
+0x00, 0x00, 0x08, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 
+0xfb, 0xff, 0x00, 0x00, 0x00, 0x40, 0x00, 0x8c, 0xf9, 0xff, 0x03, 0x00, 
+0x00, 0x20, 0x00, 0xce, 0xff, 0xff, 0x07, 0x00, 0x00, 0x18, 0x00, 0xf8, 
+0xff, 0xff, 0x1f, 0x00, 0x00, 0x04, 0x00, 0xfc, 0xff, 0xff, 0x3f, 0x00, 
+0x00, 0x00, 0x00, 0xf8, 0xfe, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x0f, 
+0xf9, 0xff, 0xff, 0x00, 0x00, 0x00, 0x80, 0x07, 0xda, 0xff, 0xff, 0x01, 
+0x00, 0x00, 0x80, 0x03, 0x90, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x7d, 
+0x00, 0xf8, 0xff, 0x03, 0x00, 0x00, 0xc0, 0xff, 0x00, 0xf8, 0xff, 0x07, 
+0x00, 0x00, 0xc0, 0xff, 0xf3, 0xff, 0xff, 0x07, 0x00, 0x00, 0xe0, 0xff, 
+0xff, 0xff, 0xfd, 0x0f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xf7, 0xf3, 0x1f, 
+0x00, 0x00, 0xf8, 0xff, 0xff, 0xef, 0x07, 0x1f, 0x00, 0x00, 0xfc, 0xff, 
+0xff, 0xef, 0x3f, 0x1e, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xdf, 0x3f, 0x1c, 
+0x00, 0x00, 0xfc, 0xff, 0xff, 0x9f, 0x3f, 0x18, 0x00, 0x00, 0xfc, 0xff, 
+0xff, 0xbf, 0x1f, 0x18, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0x0f, 0x18, 
+0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0x03, 0x10, 0x00, 0x00, 0xfe, 0xff, 
+0xff, 0xff, 0x00, 0x10, 0x02, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x0f, 0x00, 
+0x03, 0x00, 0xf8, 0xff, 0xff, 0xff, 0x07, 0x00, 0x03, 0x00, 0xf0, 0xf3, 
+0xff, 0xff, 0x07, 0x00, 0x07, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x07, 0x00, 
+0x07, 0x00, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x07, 0x00, 0x00, 0x80, 
+0xff, 0xff, 0x01, 0x00, 0x1f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 
+0x3f, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 
+0xff, 0x7f, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, 
+0xff, 0x01, 0x00, 0x00, 0xfe, 0x3f, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 
+0xfe, 0x7f, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 
+0xfe, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x04, 0x00, 0xfe, 0x00, 0x00, 0x00, 
+0xff, 0x7f, 0x06, 0x00, 0xfe, 0x00, 0x00, 0x00, 0xff, 0x1f, 0x07, 0x00, 
+0xfc, 0x00, 0x00, 0x00, 0xff, 0x0f, 0x03, 0x00, 0xfc, 0x00, 0x00, 0x00, 
+0xfe, 0x0f, 0x03, 0x00, 0xf8, 0x00, 0x00, 0x00, 0xfe, 0x0f, 0x01, 0x00, 
+0x78, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x01, 0x00, 0x70, 0x00, 0x00, 0x00, 
+0xfc, 0x03, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xfc, 0x03, 0x00, 0x00, 
+0x60, 0x00, 0x00, 0x00, 0xf8, 0x01, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 
+0x78, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x03, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/trek-0.xbm b/xlockmore-4.14/bitmaps/trek-0.xbm
new file mode 100644 (file)
index 0000000..251cb42
--- /dev/null
@@ -0,0 +1,267 @@
+#define trek0_width 241
+#define trek0_height 102
+static unsigned char trek0_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xe0, 0x4f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xc7, 0xff, 0x85, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff,
+   0xff, 0x3f, 0x00, 0x29, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xf8, 0xc1, 0xff, 0x00, 0x00, 0x00, 0xc5, 0x14,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8,
+   0x7b, 0x00, 0x00, 0xff, 0xbf, 0xb2, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x80,
+   0x92, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xf0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x40, 0x05, 0x78, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x20, 0x39, 0x68, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x09, 0x30, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x5f, 0x33, 0x68, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f,
+   0xf0, 0x89, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x24,
+   0x34, 0x00, 0x00, 0x00, 0x00, 0x78, 0xfe, 0x4f, 0x16, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0x1f, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xd4, 0x12, 0x00, 0x00, 0x00, 0x00,
+   0xfa, 0x01, 0xc0, 0xfa, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0xe0, 0xff, 0xff, 0xff, 0x01,
+   0x40, 0x52, 0x1d, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0xa0, 0x22, 0x13,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc0, 0x01, 0x00, 0x00, 0x10, 0xfb, 0xbf, 0x10, 0x09, 0x00, 0x00,
+   0x00, 0x00, 0x01, 0x00, 0x50, 0x22, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfd, 0xfd, 0x0f,
+   0x88, 0x04, 0x80, 0xc2, 0x06, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f,
+   0xe2, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0xf4, 0x67, 0x78, 0x00, 0x95, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x68, 0x19, 0x1b, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x13, 0x70, 0x00, 0x2a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x28, 0x0b, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x08, 0x00,
+   0xdc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0xa8, 0x04, 0x24, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x1b, 0xf8, 0x6b, 0x07, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x82,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x94, 0x00,
+   0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x1d, 0x00, 0x24, 0x05, 0x1a, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x88, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x01,
+   0x28, 0x1b, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x44, 0x10, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x1f, 0xa8, 0xf0, 0x2b, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xfe, 0x33, 0x56, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x12, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x8d, 0x48, 0x74,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xaa, 0x00, 0x09, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x6e, 0x5b, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x94, 0x80, 0x04,
+   0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70,
+   0xa0, 0x08, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf0, 0xab, 0x43, 0x82, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x0a, 0x18, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x56,
+   0xee, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x60, 0x14, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x4a, 0xc6, 0x12, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x68, 0x40,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40,
+   0x2b, 0x71, 0xa7, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x90, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0e, 0x25, 0x07, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x60, 0x03, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x40, 0x25, 0x11, 0x45, 0x03, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x04, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x25, 0x11, 0x49,
+   0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x1b, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x22, 0x11, 0x88, 0xfe, 0x87, 0x80, 0xff, 0x01,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2c, 0x20,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xef, 0x22,
+   0x81, 0x0b, 0x3d, 0x78, 0xbf, 0xff, 0xff, 0xff, 0x03, 0x80, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x50, 0x40, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xfe, 0x36, 0xec, 0xef, 0xb9, 0xde, 0x3f, 0xc0,
+   0xff, 0xf9, 0xff, 0xfb, 0xff, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x40, 0x02, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x5b, 0x7e,
+   0x8f, 0x81, 0x20, 0x00, 0x03, 0xf8, 0xc0, 0x7f, 0x00, 0x80, 0xff, 0x07,
+   0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x0d, 0x0c, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x6f, 0xdb, 0xc7, 0x60, 0x40, 0x40, 0x00, 0x1c,
+   0x00, 0x0f, 0x80, 0x7f, 0x00, 0x00, 0xf8, 0x6f, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x32, 0x10, 0x00, 0x00, 0x00, 0x00, 0x80, 0x9f, 0x7f,
+   0x7b, 0x3c, 0x18, 0x20, 0x40, 0x00, 0x60, 0x00, 0xf0, 0x03, 0x80, 0x7f,
+   0x00, 0x00, 0x9e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x60,
+   0x00, 0x00, 0x00, 0x00, 0x7f, 0x7e, 0xdf, 0xc7, 0x03, 0x07, 0x10, 0x80,
+   0x00, 0x80, 0x03, 0x00, 0x7c, 0x00, 0x80, 0xff, 0xf0, 0x91, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x98,
+   0xf9, 0x3c, 0x38, 0xc0, 0x00, 0x08, 0x00, 0x01, 0x00, 0x0c, 0x00, 0x80,
+   0x0f, 0x00, 0xc0, 0x0c, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x81, 0x01, 0x00, 0xe0, 0x73, 0xa4, 0xc7, 0x03, 0x07, 0x30, 0x00,
+   0x06, 0x00, 0x01, 0x00, 0x30, 0x00, 0x00, 0xf0, 0x81, 0x3f, 0x04, 0x48,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x06, 0x02, 0x00, 0xde,
+   0x8b, 0x3d, 0x3c, 0xe0, 0x00, 0x0c, 0x00, 0x01, 0x00, 0x00, 0x00, 0xc0,
+   0x01, 0x00, 0x00, 0x7a, 0x00, 0x04, 0x48, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x19, 0x0c, 0xc0, 0x07, 0xfc, 0xe1, 0x03, 0x1e, 0x80,
+   0x03, 0x80, 0x00, 0x00, 0x02, 0x00, 0x00, 0x0e, 0x00, 0xf0, 0x07, 0x00,
+   0x02, 0x68, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x26, 0x10,
+   0xde, 0xb9, 0x07, 0x1e, 0xc0, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x02,
+   0x00, 0x00, 0x10, 0xf0, 0x0f, 0x04, 0x00, 0x02, 0x2c, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xb0, 0x00, 0xe7, 0x01, 0x0e, 0x80, 0x07,
+   0x00, 0x06, 0x00, 0x20, 0x00, 0x00, 0x88, 0xff, 0xff, 0xff, 0x1f, 0x00,
+   0x02, 0x00, 0x01, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x40, 0x13, 0x1f, 0xf0, 0x01, 0x78, 0x00, 0xc0, 0x01, 0x00, 0x10, 0x00,
+   0xf8, 0x67, 0x00, 0x00, 0x10, 0x00, 0x00, 0x02, 0x00, 0xb9, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7c, 0x00, 0x0f, 0x00,
+   0x06, 0x00, 0x20, 0x00, 0x00, 0x88, 0xff, 0x07, 0x10, 0x00, 0x00, 0x10,
+   0x00, 0x00, 0x02, 0x80, 0x76, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x73, 0xbf, 0x00, 0xc0, 0x01, 0x00, 0x18, 0x00, 0xe0,
+   0x7f, 0x00, 0x00, 0x10, 0x00, 0x00, 0x10, 0x00, 0x00, 0x02, 0x9c, 0x0f,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc4, 0x80,
+   0xff, 0xff, 0xff, 0xff, 0xfb, 0xff, 0x1f, 0x04, 0x00, 0x00, 0x10, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xe1, 0xdc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xd8, 0x80, 0x00, 0x20, 0x00, 0x00, 0x04,
+   0x00, 0x00, 0x04, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x78, 0xe2,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x60, 0x80, 0x00, 0x20, 0x00, 0x00, 0x04, 0x00, 0x00, 0x04, 0x00, 0x00,
+   0x10, 0x00, 0x00, 0x00, 0xfc, 0x87, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x01, 0x40, 0x00,
+   0x00, 0x08, 0x00, 0x00, 0x04, 0x00, 0x00, 0x10, 0x00, 0xf8, 0xff, 0x03,
+   0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x01, 0x01, 0x40, 0x00, 0x00, 0x08, 0x00, 0x00, 0x04,
+   0x00, 0x00, 0x10, 0xff, 0x07, 0x08, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00,
+   0x80, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0xff, 0x1f, 0xf2, 0x7f,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xf9, 0x7f, 0x01, 0x00, 0x10, 0x00,
+   0xc0, 0xf7, 0xff, 0xff, 0xdd, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xd0, 0x39, 0x80, 0xfd, 0xff, 0xff, 0xff, 0xff, 0xb7, 0xdf, 0x41, 0x92,
+   0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0xdc, 0xfd, 0xfb, 0xff,
+   0xff, 0xff, 0x3e, 0xc0, 0x22, 0x42, 0xd0, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x0d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0xe0, 0x44,
+   0x22, 0xe8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x32, 0x0c,
+   0x00, 0x00, 0x00, 0x00, 0x01, 0xd0, 0x89, 0x22, 0x75, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x44, 0x10, 0x00, 0x00, 0x00, 0x80, 0x00,
+   0x30, 0x12, 0x24, 0x2b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x98, 0x61, 0x00, 0x00, 0x00, 0x80, 0x00, 0x30, 0x2c, 0xa4, 0x04, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x82, 0x01, 0x00, 0x00,
+   0x80, 0x00, 0x30, 0x50, 0xa5, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x19, 0x04, 0x00, 0x00, 0x80, 0x00, 0x18, 0x80, 0x4d,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x22, 0x08,
+   0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc4, 0x30, 0x00, 0x00, 0x60, 0x00, 0x0c,
+   0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x18, 0x41, 0x00, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x86, 0xf1, 0xff, 0xff,
+   0x17, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x80, 0x08, 0xf2, 0xff, 0x3f, 0x6c, 0x0e, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x04,
+   0x00, 0x20, 0x8c, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x64, 0x00, 0x00, 0x00, 0xd0, 0x4c, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x88, 0x60, 0x0b, 0x18, 0x10, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x0c, 0xf0, 0x03, 0x06,
+   0xac, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x08, 0x00, 0x0c, 0x41, 0x0a, 0x3d, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x00,
+   0x91, 0x00, 0x05, 0x71, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x61, 0xa1, 0x84, 0x41, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40,
+   0x0c, 0x80, 0x80, 0x5a, 0xcc, 0xc7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x10, 0x80, 0x40, 0x20, 0x32,
+   0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x40, 0xe0, 0x40, 0x40, 0x2c, 0x0d, 0x70, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x43, 0x20,
+   0xd2, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x40, 0x01, 0x3c, 0x20, 0x4a, 0x01, 0xc0, 0x02, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09,
+   0x20, 0x03, 0x65, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x20, 0xbc, 0x64, 0x00, 0x00,
+   0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x20, 0x20, 0xd0, 0x12, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x50, 0x20, 0x10, 0x09,
+   0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xa0, 0x21, 0x90, 0x04, 0x00, 0x00, 0x05, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x22,
+   0x90, 0x34, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2d, 0x90, 0x34, 0x00, 0x00, 0x05,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x32, 0x90, 0x34, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x90, 0x34, 0x00,
+   0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x58, 0x7c, 0x0d, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x10,
+   0x23, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x20, 0x6a, 0x00, 0x40, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x80, 0x21, 0x92, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x21, 0x54, 0x02, 0xb0,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x47, 0xa8, 0x0d, 0x98, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9c, 0x0c,
+   0xd6, 0x4b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x42, 0xf8, 0x22, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xe0, 0x4c, 0x11, 0x1a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x31, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/trek-1.xbm b/xlockmore-4.14/bitmaps/trek-1.xbm
new file mode 100644 (file)
index 0000000..6c812a4
--- /dev/null
@@ -0,0 +1,177 @@
+#define trek1_width 241
+#define trek1_height 67
+static unsigned char trek1_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xf8, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe5, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff,
+   0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x2f,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x05, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xc0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xfd, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xc0, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x05,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0x2f, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xdc, 0xff, 0x3f, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0xc0, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x40, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x20, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x78, 0x00, 0x00, 0x80, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xe0,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x56, 0x00, 0x00, 0x80, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xf8, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf2, 0xff, 0xff,
+   0x7f, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x1f, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x5e, 0x00, 0x00, 0x40, 0xe0, 0xff, 0xff, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x54,
+   0x00, 0x00, 0x7e, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2c,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x43, 0xc0, 0xff,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x4c, 0x00, 0x00, 0x42, 0x60, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff,
+   0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff,
+   0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x42,
+   0xe0, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xf0, 0xff, 0x07, 0x08, 0x00, 0x02, 0x80, 0xf8, 0xff, 0xff,
+   0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0x43, 0x20, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x4c, 0x80, 0x00,
+   0x08, 0x00, 0x02, 0x80, 0x00, 0x00, 0x00, 0xc2, 0xc0, 0x1f, 0x00, 0x00,
+   0x00, 0x42, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x83, 0x00, 0x01, 0x00, 0x00, 0x02, 0x80, 0x00,
+   0x00, 0x00, 0x02, 0x00, 0x30, 0x00, 0x00, 0x00, 0x42, 0x20, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85,
+   0x00, 0x01, 0xf0, 0xff, 0xff, 0x7f, 0xff, 0x3f, 0x80, 0x03, 0x00, 0x20,
+   0x00, 0x00, 0x00, 0x26, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x80, 0xff, 0x1f, 0x00, 0x02,
+   0x80, 0x00, 0xe0, 0xff, 0xdf, 0x81, 0x30, 0x00, 0x00, 0x00, 0x26, 0x30,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x3a, 0x00, 0xfe, 0x3f, 0x1f, 0x08, 0xc0, 0xff, 0x7f, 0x80, 0xf0,
+   0xff, 0x1f, 0x00, 0x00, 0x00, 0x24, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x34, 0xfe, 0x07, 0xff,
+   0xe0, 0x39, 0x20, 0xf0, 0x81, 0xff, 0x1f, 0x40, 0x06, 0x00, 0x00, 0x00,
+   0x24, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x44, 0x10, 0xe1, 0xff,
+   0xff, 0xff, 0x2f, 0x03, 0x00, 0x00, 0x00, 0x24, 0x10, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc,
+   0xff, 0xff, 0x3f, 0xd2, 0x09, 0x68, 0xbe, 0x00, 0x00, 0xc0, 0x01, 0x00,
+   0x00, 0x00, 0x24, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xfd, 0x3f, 0xfe, 0x24, 0x49,
+   0xd4, 0x7f, 0x01, 0x00, 0x40, 0x01, 0x00, 0x00, 0x00, 0x24, 0x10, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xf0, 0x5f, 0x4b, 0xef, 0xf7, 0x03, 0x00, 0x80,
+   0x03, 0x00, 0x00, 0x00, 0x24, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x06, 0x2a, 0x1c, 0x00, 0x04, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x24,
+   0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb8, 0x8a, 0x06, 0x00, 0x0c,
+   0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x24, 0x08, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x58, 0x8b, 0x03, 0x00, 0x10, 0x00, 0x00, 0x0c, 0x00, 0x00,
+   0x00, 0x24, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xf4, 0x00,
+   0x00, 0x30, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x24, 0x08, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xc0, 0x75, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38,
+   0x00, 0x00, 0x00, 0x24, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x3f, 0x00, 0x00, 0x40, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x24, 0x08,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03,
+   0x00, 0x60, 0x00, 0x00, 0x00, 0x24, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0xc0, 0x00, 0x00, 0x00,
+   0x28, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x0c, 0x00, 0x80, 0x01, 0x00, 0x00, 0x28, 0x08, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x03,
+   0x00, 0x00, 0x38, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0xe0, 0xff, 0x1f, 0x06, 0x00, 0x00, 0x18, 0x04, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f,
+   0xff, 0x1d, 0x00, 0x00, 0x18, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xe0, 0x17, 0x00, 0x02, 0xe0, 0x3f, 0x00, 0x18,
+   0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xf4, 0xff, 0xff, 0x07, 0xc0, 0xff, 0x1b, 0x04, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x01, 0xf8, 0xfe,
+   0x9f, 0x1f, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x10, 0x02, 0x00, 0x01, 0x00, 0x01, 0xe0, 0x7f, 0x04, 0x2f, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x02, 0x00, 0x01,
+   0x00, 0x00, 0x00, 0x60, 0xfe, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x08, 0xfe, 0xff, 0xff, 0xff, 0x0b, 0x00, 0xc0, 0x01,
+   0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x03,
+   0x00, 0x01, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x08, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x02, 0x00, 0x01, 0x00,
+   0x00, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0xe8, 0x03, 0x00, 0xf9, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x20,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0xfe, 0xff,
+   0x07, 0x00, 0x00, 0x00, 0x00, 0x80, 0x23, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x08, 0x12, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x78, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08,
+   0x12, 0x00, 0x01, 0x00, 0x00, 0xff, 0xff, 0x07, 0x06, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe8, 0xfb, 0x3f, 0x01, 0xff, 0xff,
+   0x00, 0x80, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xd0, 0x12, 0xc0, 0xff, 0x00, 0x00, 0xf0, 0x7f, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x12, 0x00, 0x01,
+   0x80, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00};
diff --git a/xlockmore-4.14/bitmaps/trek-2.xbm b/xlockmore-4.14/bitmaps/trek-2.xbm
new file mode 100644 (file)
index 0000000..259ef71
--- /dev/null
@@ -0,0 +1,249 @@
+#define trek2_width 281
+#define trek2_height 82
+static unsigned char trek2_bits[] = {
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0,
+   0x01, 0x3e, 0x80, 0x40, 0x03, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x02,
+   0x08, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x80, 0x70, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x81, 0x01, 0x00,
+   0x00, 0x10, 0x00, 0x04, 0x00, 0x00, 0x00, 0x08, 0x82, 0x80, 0x03, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x10, 0x00, 0x00, 0x00,
+   0x00, 0x02, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x80, 0x00, 0x0c,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x33, 0x00, 0x00, 0x00, 0x00,
+   0x0c, 0x00, 0xe1, 0x25, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00,
+   0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0e, 0x00, 0x00, 0x00, 0x01,
+   0x00, 0x80, 0x43, 0x4a, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x81, 0x01, 0xe0,
+   0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x82, 0x80, 0x41, 0x12, 0x52, 0x06, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x0c,
+   0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x03, 0x22, 0x25, 0x0d, 0x69, 0x81, 0x0f, 0x00, 0x00, 0x00, 0x80,
+   0x0f, 0xf0, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x08, 0x00, 0x74, 0x00,
+   0x00, 0x02, 0x02, 0x60, 0x29, 0x89, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff,
+   0x07, 0x00, 0x0c, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x20, 0x00, 0x30, 0x06, 0x20,
+   0x00, 0x04, 0x04, 0x10, 0x23, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x66, 0xd0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x02, 0x20, 0x80, 0x00, 0xc0, 0x18, 0x0d, 0x40,
+   0x02, 0x08, 0x20, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xf5,
+   0x37, 0x7f, 0x00, 0xe0, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x80, 0x07, 0x08, 0x01, 0x80, 0x51, 0x08, 0x02, 0x40,
+   0x00, 0x20, 0x20, 0xb0, 0x00, 0x00, 0x00, 0x08, 0x1b, 0x00, 0x00, 0x00,
+   0x40, 0x08, 0x21, 0xb0, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x02, 0x20, 0x04, 0x00, 0x46, 0x25, 0x08, 0x0b, 0x40,
+   0x00, 0x08, 0x00, 0x43, 0x1e, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x91,
+   0x31, 0x62, 0x4c, 0x02, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x20, 0x00, 0x88, 0x00, 0x8c, 0xd2, 0x14, 0x84, 0x41, 0x00,
+   0x00, 0x00, 0x01, 0x30, 0x32, 0x18, 0x00, 0x00, 0x81, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x04, 0x00, 0x00, 0x30, 0x8a, 0xd2, 0x14, 0x02, 0x01, 0x04,
+   0x00, 0x80, 0x00, 0x4c, 0xb0, 0x04, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x80, 0x00, 0x00, 0x3a, 0x16, 0xd1, 0x14, 0x06, 0x40, 0x00,
+   0x00, 0x02, 0x81, 0x02, 0x26, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00,
+   0x07, 0x00, 0x00, 0x40, 0x06, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x00, 0x00, 0x28, 0x1a, 0x82, 0xb0, 0x0c, 0x00, 0x03, 0x00,
+   0x20, 0x20, 0x30, 0x01, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x40, 0x10, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x03, 0x00, 0x00, 0x1a, 0x92, 0x30, 0x00, 0x18, 0xf0, 0xdf,
+   0x5f, 0x02, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00,
+   0x38, 0x00, 0x00, 0x40, 0x00, 0x04, 0x18, 0x00, 0x20, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x40, 0x00, 0x22, 0x96, 0x62, 0x00, 0x40, 0x00, 0x00, 0x00,
+   0x38, 0x00, 0x00, 0x20, 0x00, 0x32, 0x00, 0x00, 0x20, 0xa5, 0x02, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x08, 0x80, 0x00, 0x18, 0x00, 0x08, 0x00, 0x00,
+   0x00, 0x00, 0x40, 0x20, 0x06, 0x16, 0x01, 0x00, 0x02, 0x00, 0x00, 0x00,
+   0x24, 0xc8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x85, 0x52, 0x03, 0x00,
+   0x00, 0x00, 0x80, 0x00, 0x80, 0x00, 0x00, 0x00, 0x04, 0x80, 0x00, 0x00,
+   0x00, 0x00, 0x40, 0x40, 0x24, 0x06, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
+   0x02, 0x02, 0x40, 0x00, 0x00, 0x00, 0x00, 0x42, 0x28, 0xa5, 0x0c, 0x00,
+   0x00, 0x00, 0x00, 0x02, 0x00, 0x08, 0x40, 0x00, 0x00, 0x00, 0x06, 0x00,
+   0x00, 0x00, 0x40, 0x08, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0xc0,
+   0x00, 0x08, 0x04, 0x00, 0x00, 0x00, 0x08, 0x10, 0x4a, 0x29, 0x14, 0x00,
+   0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x01, 0x04, 0x00, 0x19, 0x22, 0x00,
+   0x00, 0x00, 0x40, 0x00, 0x80, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10,
+   0x00, 0x40, 0x10, 0x00, 0x00, 0x03, 0x00, 0x20, 0x85, 0x50, 0x2b, 0x01,
+   0x00, 0x00, 0x80, 0x82, 0x08, 0x00, 0x10, 0x20, 0x20, 0x00, 0x20, 0x00,
+   0x00, 0x00, 0x13, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00,
+   0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x28, 0xb4, 0xd0, 0x90,
+   0x01, 0x00, 0x00, 0x40, 0x88, 0x00, 0x00, 0x00, 0x08, 0x00, 0x80, 0x00,
+   0x00, 0x40, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
+   0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x10, 0x0a, 0x21, 0x10,
+   0x24, 0x00, 0x00, 0x04, 0x01, 0x08, 0x80, 0xa0, 0x04, 0x00, 0x63, 0x00,
+   0x00, 0xe0, 0x3d, 0x00, 0x10, 0x04, 0x00, 0x00, 0x24, 0x06, 0x00, 0x20,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x20, 0x94, 0x92, 0x00,
+   0x02, 0x09, 0x48, 0x40, 0x28, 0x44, 0x40, 0x00, 0x09, 0x80, 0x40, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x40, 0x40, 0x00, 0x80, 0x00, 0x01, 0x20, 0x00,
+   0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0xad, 0x14, 0x00,
+   0x40, 0x40, 0x26, 0x08, 0x85, 0x02, 0x20, 0x06, 0x10, 0x00, 0x61, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x04, 0x03, 0x00, 0x40, 0x00, 0x60,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x20, 0x02, 0x02, 0x42, 0x09, 0x40,
+   0x00, 0x04, 0x00, 0x82, 0x08, 0x10, 0x12, 0x14, 0x20, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x03, 0x00, 0x80, 0x04, 0x40, 0x4a,
+   0x00, 0x0c, 0x00, 0x00, 0x80, 0x00, 0x04, 0x04, 0x00, 0x82, 0x02, 0x00,
+   0x00, 0x40, 0x00, 0x41, 0x88, 0x02, 0x80, 0x08, 0x20, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x80, 0x80, 0x60, 0x20,
+   0x04, 0x00, 0x00, 0xe0, 0x03, 0x10, 0x20, 0x08, 0x0c, 0x08, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x10, 0x84, 0x10, 0x06, 0x22, 0x20, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x80, 0x02, 0x01, 0x20, 0x04,
+   0x00, 0x70, 0x00, 0x00, 0x18, 0x10, 0x01, 0x01, 0x10, 0x10, 0x00, 0x00,
+   0x00, 0x00, 0x10, 0x00, 0x41, 0x44, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0x04, 0x00,
+   0x0c, 0x00, 0x00, 0x18, 0x00, 0x00, 0x02, 0x08, 0x11, 0x00, 0x00, 0x04,
+   0x01, 0x08, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x18, 0x04, 0x00, 0x08, 0x00, 0x08,
+   0x00, 0x00, 0x10, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x00, 0x00, 0x10,
+   0x04, 0x40, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x06, 0x30, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x10, 0x00, 0x08, 0x00, 0x0c, 0x00,
+   0x00, 0x0c, 0x10, 0x04, 0x00, 0x00, 0x00, 0x02, 0x21, 0x00, 0x00, 0x40,
+   0x10, 0x08, 0x02, 0x40, 0x00, 0x08, 0x02, 0x20, 0x00, 0x02, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00, 0x20, 0x00, 0x18, 0x00, 0x00,
+   0x18, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x04, 0x80, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x08, 0x00, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x22, 0x20, 0x00, 0x00, 0x30,
+   0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00,
+   0x02, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x09, 0x50, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x04, 0x00, 0x00, 0x10, 0x00,
+   0x00, 0x00, 0x00, 0x01, 0x00, 0x02, 0x00, 0x80, 0x01, 0x08, 0x00, 0x04,
+   0x00, 0x01, 0x00, 0x01, 0x20, 0x00, 0x08, 0x04, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x3a, 0x40, 0x30, 0x00, 0x20, 0x20, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x06, 0x20, 0x00, 0x08,
+   0x08, 0x04, 0x00, 0x00, 0x80, 0x40, 0x00, 0x81, 0x02, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x20, 0x01, 0x01, 0x02, 0x20, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x03, 0x14, 0x80, 0x00, 0x40,
+   0x08, 0x10, 0x00, 0x28, 0x00, 0x02, 0x00, 0x94, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x48, 0x00, 0x00, 0x03, 0x08,
+   0x00, 0x00, 0x00, 0x00, 0x02, 0x01, 0x08, 0x40, 0x4c, 0x00, 0x00, 0x00,
+   0x00, 0x40, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x82, 0x10, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x40, 0x04, 0x03, 0x80, 0x00, 0x04, 0x00,
+   0xc0, 0x00, 0x04, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x40, 0x00, 0x20, 0x00, 0x00, 0x00, 0x02, 0x02, 0x00, 0x80, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x22, 0x92, 0x00, 0x02, 0x10, 0x00,
+   0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x20, 0x00, 0x02, 0x00, 0x00, 0x02, 0x01, 0xc0, 0x00, 0x00, 0x02,
+   0x00, 0x00, 0x00, 0x00, 0x01, 0x04, 0x00, 0x01, 0x04, 0x08, 0x00, 0x00,
+   0x00, 0x02, 0x08, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x10, 0xc0, 0x80, 0x00, 0x00, 0x08,
+   0x00, 0x32, 0x00, 0x00, 0x20, 0x02, 0x01, 0x04, 0x10, 0x26, 0x00, 0x00,
+   0x00, 0x08, 0x80, 0x00, 0x50, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x32, 0x01, 0x00, 0x04, 0x00,
+   0x79, 0x92, 0x00, 0x08, 0x81, 0x06, 0x10, 0x20, 0x08, 0x80, 0x00, 0x00,
+   0x00, 0x10, 0x40, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x30, 0x00, 0x00, 0x00, 0x20, 0x00, 0x32, 0x23, 0x00, 0x20, 0x00,
+   0x01, 0x92, 0x06, 0x00, 0x02, 0x20, 0x40, 0x10, 0x00, 0x02, 0x00, 0x04,
+   0x08, 0x20, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x3c, 0x01, 0x00, 0x00, 0x08, 0x00, 0x02, 0x05, 0x00, 0x40, 0x01,
+   0x29, 0x0f, 0xc2, 0x00, 0x0c, 0x41, 0x10, 0x00, 0x03, 0x06, 0x06, 0x00,
+   0x00, 0x60, 0x00, 0x01, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x5a, 0x06, 0x00, 0x00, 0x84, 0x00, 0x88, 0x10, 0x00, 0x00, 0x05,
+   0x2c, 0xb0, 0x19, 0x08, 0xe0, 0x01, 0x00, 0x04, 0x08, 0x00, 0x00, 0x00,
+   0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0xc8, 0x03, 0x00, 0x00, 0x84, 0x00, 0x30, 0x00, 0x00, 0x00, 0x80,
+   0x14, 0x04, 0x01, 0x80, 0x08, 0x00, 0x04, 0x28, 0x90, 0x20, 0x01, 0x08,
+   0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x14, 0x00, 0x00, 0x00, 0x50, 0x00, 0x04, 0x0c, 0x00, 0x00, 0x30,
+   0x98, 0x02, 0x00, 0x40, 0xa0, 0x80, 0x10, 0x00, 0x00, 0x00, 0x20, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x04, 0x00, 0x00, 0x00, 0x18, 0xc8, 0x18, 0x00, 0x00, 0x00, 0x22,
+   0x20, 0x44, 0x80, 0x01, 0x10, 0x80, 0x80, 0x30, 0x00, 0x00, 0x25, 0x01,
+   0x40, 0x00, 0x80, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x40, 0x00, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x1a, 0x00, 0x00, 0x80, 0x00,
+   0x01, 0xa4, 0x00, 0xb0, 0x01, 0x12, 0x00, 0xa0, 0x05, 0x01, 0x0c, 0x00,
+   0x00, 0x80, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x40, 0x00, 0x00, 0x00, 0x80, 0x80, 0x00, 0x18, 0x00, 0x00, 0xc0, 0x00,
+   0x00, 0x00, 0x10, 0x90, 0x12, 0x80, 0x00, 0x98, 0x02, 0x00, 0x08, 0x00,
+   0x01, 0x08, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x01, 0x04, 0x01, 0x01, 0x00, 0xc0, 0x00, 0x08,
+   0x00, 0x40, 0x00, 0x80, 0x40, 0x00, 0x00, 0x02, 0x00, 0x80, 0x80, 0x10,
+   0x02, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x80, 0x00, 0x60, 0x02, 0x10, 0x10, 0x80, 0x02, 0x00, 0x01, 0x00, 0x20,
+   0x10, 0x00, 0x00, 0x30, 0x22, 0x03, 0x00, 0x00, 0x00, 0x01, 0x20, 0x20,
+   0x00, 0x00, 0x20, 0x00, 0x30, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x40, 0x00, 0x40, 0x40, 0x80, 0x02, 0x04, 0x00, 0x06, 0x00, 0x00, 0x70,
+   0x00, 0x00, 0x00, 0x04, 0x48, 0x18, 0x00, 0x00, 0x02, 0x00, 0x10, 0x00,
+   0x08, 0x00, 0x00, 0x00, 0x02, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x03, 0x40, 0x00, 0x05, 0x08, 0x02, 0x05, 0x00, 0x00, 0x20, 0x46,
+   0x00, 0x00, 0x40, 0x20, 0x04, 0x28, 0x00, 0x00, 0x00, 0x20, 0x00, 0x01,
+   0x10, 0x00, 0x00, 0x02, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x50, 0x60, 0x00, 0x02, 0x00, 0x01, 0x80, 0x00, 0x00, 0x00, 0x00, 0x4a,
+   0x00, 0x00, 0x00, 0x00, 0x02, 0x23, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0xa0, 0x00, 0x00, 0x10, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x80, 0x04, 0x00, 0x04, 0x20, 0x40, 0x00, 0x80, 0x00, 0x00, 0x44,
+   0xc0, 0x33, 0x0a, 0x80, 0x52, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40,
+   0x00, 0x00, 0x00, 0x00, 0xf8, 0x03, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x80, 0x01, 0x00, 0x10, 0x04, 0x00, 0x20, 0x00, 0x03, 0x80, 0x31, 0x08,
+   0x00, 0x00, 0x50, 0x00, 0x0a, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x04, 0x00, 0x30, 0x00, 0x06, 0x02, 0x10, 0x04, 0x00, 0x01, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x01, 0x0c, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x08, 0x02, 0x00, 0x00, 0x00, 0x40, 0x06, 0x01, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x20, 0x00, 0xc0, 0x01, 0x01, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x50, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x02, 0x01, 0x00, 0x00, 0x00, 0x20, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x24, 0x48, 0x00, 0x40, 0x02, 0x04, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x20, 0x00,
+   0x00, 0x04, 0x00, 0x00, 0x00, 0x02, 0x00, 0x26, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x43, 0x08, 0x30, 0x10, 0x88, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x18, 0x00, 0x00, 0x00, 0x00, 0x20,
+   0x20, 0x02, 0x00, 0x00, 0x08, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x38, 0x00, 0x02, 0x01, 0x88, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02,
+   0x00, 0x02, 0x00, 0x00, 0x04, 0x10, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00,
+   0x02, 0x80, 0x00, 0x08, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x40, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x20, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x00,
+   0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x04, 0x02, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x01, 0x10, 0x08, 0x00, 0x01, 0x08,
+   0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00,
+   0x80, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x01, 0x08, 0x01,
+   0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x10, 0x00, 0x00, 0xf1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x10, 0x00, 0x00,
+   0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00,
+   0x01, 0x20, 0x15, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x01, 0x08,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+   0x3d, 0x4c, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x20, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
+   0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x80,
+   0x0b, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00,
+   0x48, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x01, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0xc0,
+   0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x10,
+   0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00,
+   0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x32, 0x00,
+   0x20, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x30,
+   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/xlockmore-4.14/bitmaps/vlines2.xbm b/xlockmore-4.14/bitmaps/vlines2.xbm
new file mode 100644 (file)
index 0000000..dc73864
--- /dev/null
@@ -0,0 +1,4 @@
+#define vlines2_width 2
+#define vlines2_height 1
+static unsigned char vlines2_bits[] = {
+   0x01};
diff --git a/xlockmore-4.14/bitmaps/vlines3.xbm b/xlockmore-4.14/bitmaps/vlines3.xbm
new file mode 100644 (file)
index 0000000..a9b3073
--- /dev/null
@@ -0,0 +1,4 @@
+#define vlines3_width 3
+#define vlines3_height 1
+static unsigned char vlines3_bits[] = {
+   0x02};
diff --git a/xlockmore-4.14/confdefs.h b/xlockmore-4.14/confdefs.h
new file mode 100644 (file)
index 0000000..8b13789
--- /dev/null
@@ -0,0 +1 @@
+
diff --git a/xlockmore-4.14/config.guess b/xlockmore-4.14/config.guess
new file mode 100755 (executable)
index 0000000..e9e4455
--- /dev/null
@@ -0,0 +1,693 @@
+#! /bin/sh
+# Attempt to guess a canonical system name.
+#   Copyright (C) 1992, 93, 94, 95, 1996 Free Software Foundation, Inc.
+#
+# This file is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
+# Written by Per Bothner <bothner@cygnus.com>.
+# The master version of this file is at the FSF in /home/gd/gnu/lib.
+#
+# This script attempts to guess a canonical system name similar to
+# config.sub.  If it succeeds, it prints the system name on stdout, and
+# exits with 0.  Otherwise, it exits with 1.
+#
+# The plan is that this can be called by configure scripts if you
+# don't specify an explicit system type (host/target name).
+#
+# Only a few systems have been added to this list; please add others
+# (but try to keep the structure clean).
+#
+
+# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
+# (ghazi@noc.rutgers.edu 8/24/94.)
+if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
+       PATH=$PATH:/.attbin ; export PATH
+fi
+
+UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
+UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
+UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
+UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
+
+trap 'rm -f dummy.c dummy.o dummy; exit 1' 1 2 15
+
+# Note: order is significant - the case branches are not exclusive.
+
+case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
+    alpha:OSF1:*:*)
+       # A Vn.n version is a released version.
+       # A Tn.n version is a released field test version.
+       # A Xn.n version is an unreleased experimental baselevel.
+       # 1.2 uses "1.2" for uname -r.
+       echo alpha-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//'`
+       exit 0 ;;
+    21064:Windows_NT:50:3)
+       echo alpha-dec-winnt3.5
+       exit 0 ;;
+    Amiga*:UNIX_System_V:4.0:*)
+       echo m68k-cbm-sysv4
+       exit 0;;
+    amiga:NetBSD:*:*)
+      echo m68k-cbm-netbsd${UNAME_RELEASE}
+      exit 0 ;;
+    amiga:OpenBSD:*:*)
+      echo m68k-cbm-openbsd${UNAME_RELEASE}
+      exit 0 ;;
+    arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
+       echo arm-acorn-riscix${UNAME_RELEASE}
+       exit 0;;
+    Pyramid*:OSx*:*:*|MIS*:OSx*:*:*)
+       # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
+       if test "`(/bin/universe) 2>/dev/null`" = att ; then
+               echo pyramid-pyramid-sysv3
+       else
+               echo pyramid-pyramid-bsd
+       fi
+       exit 0 ;;
+    NILE:*:*:dcosx)
+       echo pyramid-pyramid-svr4
+       exit 0 ;;
+    sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
+       echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
+       exit 0 ;;
+    i86pc:SunOS:5.*:*)
+       echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
+       exit 0 ;;
+    sun4*:SunOS:6*:*)
+       # According to config.sub, this is the proper way to canonicalize
+       # SunOS6.  Hard to guess exactly what SunOS6 will be like, but
+       # it's likely to be more like Solaris than SunOS4.
+       echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
+       exit 0 ;;
+    sun4*:SunOS:*:*)
+       case "`/usr/bin/arch -k`" in
+           Series*|S4*)
+               UNAME_RELEASE=`uname -v`
+               ;;
+       esac
+       # Japanese Language versions have a version number like `4.1.3-JL'.
+       echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
+       exit 0 ;;
+    sun3*:SunOS:*:*)
+       echo m68k-sun-sunos${UNAME_RELEASE}
+       exit 0 ;;
+    aushp:SunOS:*:*)
+       echo sparc-auspex-sunos${UNAME_RELEASE}
+       exit 0 ;;
+    atari*:NetBSD:*:*)
+       echo m68k-atari-netbsd${UNAME_RELEASE}
+       exit 0 ;;
+    atari*:OpenBSD:*:*)
+       echo m68k-atari-openbsd${UNAME_RELEASE}
+       exit 0 ;;
+    sun3*:NetBSD:*:*)
+       echo m68k-sun-netbsd${UNAME_RELEASE}
+       exit 0 ;;
+    sun3*:OpenBSD:*:*)
+       echo m68k-sun-openbsd${UNAME_RELEASE}
+       exit 0 ;;
+    mac68k:NetBSD:*:*)
+       echo m68k-apple-netbsd${UNAME_RELEASE}
+       exit 0 ;;
+    mac68k:OpenBSD:*:*)
+       echo m68k-apple-openbsd${UNAME_RELEASE}
+       exit 0 ;;
+    powerpc:machten:*:*)
+       echo powerpc-apple-machten${UNAME_RELEASE}
+       exit 0 ;;
+    RISC*:Mach:*:*)
+       echo mips-dec-mach_bsd4.3
+       exit 0 ;;
+    RISC*:ULTRIX:*:*)
+       echo mips-dec-ultrix${UNAME_RELEASE}
+       exit 0 ;;
+    VAX*:ULTRIX*:*:*)
+       echo vax-dec-ultrix${UNAME_RELEASE}
+       exit 0 ;;
+    mips:*:*:UMIPS | mips:*:*:RISCos)
+       sed 's/^        //' << EOF >dummy.c
+       int main (argc, argv) int argc; char **argv; {
+       #if defined (host_mips) && defined (MIPSEB)
+       #if defined (SYSTYPE_SYSV)
+         printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0);
+       #endif
+       #if defined (SYSTYPE_SVR4)
+         printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0);
+       #endif
+       #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
+         printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0);
+       #endif
+       #endif
+         exit (-1);
+       }
+EOF
+       ${CC-cc} dummy.c -o dummy \
+         && ./dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
+         && rm dummy.c dummy && exit 0
+       rm -f dummy.c dummy
+       echo mips-mips-riscos${UNAME_RELEASE}
+       exit 0 ;;
+    Night_Hawk:Power_UNIX:*:*)
+       echo powerpc-harris-powerunix
+       exit 0 ;;
+    m88k:CX/UX:7*:*)
+       echo m88k-harris-cxux7
+       exit 0 ;;
+    m88k:*:4*:R4*)
+       echo m88k-motorola-sysv4
+       exit 0 ;;
+    m88k:*:3*:R3*)
+       echo m88k-motorola-sysv3
+       exit 0 ;;
+    AViiON:dgux:*:*)
+        # DG/UX returns AViiON for all architectures
+        UNAME_PROCESSOR=`/usr/bin/uname -p`
+        if [ $UNAME_PROCESSOR = mc88100 -o $UNAME_PROCESSOR = mc88110 ] ; then
+       if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx \
+            -o ${TARGET_BINARY_INTERFACE}x = x ] ; then
+               echo m88k-dg-dgux${UNAME_RELEASE}
+       else
+               echo m88k-dg-dguxbcs${UNAME_RELEASE}
+       fi
+        else echo i586-dg-dgux${UNAME_RELEASE}
+        fi
+       exit 0 ;;
+    M88*:DolphinOS:*:*)        # DolphinOS (SVR3)
+       echo m88k-dolphin-sysv3
+       exit 0 ;;
+    M88*:*:R3*:*)
+       # Delta 88k system running SVR3
+       echo m88k-motorola-sysv3
+       exit 0 ;;
+    XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
+       echo m88k-tektronix-sysv3
+       exit 0 ;;
+    Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
+       echo m68k-tektronix-bsd
+       exit 0 ;;
+    *:IRIX*:*:*)
+       echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
+       exit 0 ;;
+    ????????:AIX?:[12].1:2)   # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
+       echo romp-ibm-aix      # uname -m gives an 8 hex-code CPU id
+       exit 0 ;;              # Note that: echo "'`uname -s`'" gives 'AIX '
+    i?86:AIX:*:*)
+       echo i386-ibm-aix
+       exit 0 ;;
+    *:AIX:2:3)
+       if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
+               sed 's/^                //' << EOF >dummy.c
+               #include <sys/systemcfg.h>
+
+               main()
+                       {
+                       if (!__power_pc())
+                               exit(1);
+                       puts("powerpc-ibm-aix3.2.5");
+                       exit(0);
+                       }
+EOF
+               ${CC-cc} dummy.c -o dummy && ./dummy && rm dummy.c dummy && exit 0
+               rm -f dummy.c dummy
+               echo rs6000-ibm-aix3.2.5
+       elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
+               echo rs6000-ibm-aix3.2.4
+       else
+               echo rs6000-ibm-aix3.2
+       fi
+       exit 0 ;;
+    *:AIX:*:4)
+       if /usr/sbin/lsattr -EHl proc0 | grep POWER >/dev/null 2>&1; then
+               IBM_ARCH=rs6000
+       else
+               IBM_ARCH=powerpc
+       fi
+       if [ -x /usr/bin/oslevel ] ; then
+               IBM_REV=`/usr/bin/oslevel`
+       else
+               IBM_REV=4.${UNAME_RELEASE}
+       fi
+       echo ${IBM_ARCH}-ibm-aix${IBM_REV}
+       exit 0 ;;
+    *:AIX:*:*)
+       echo rs6000-ibm-aix
+       exit 0 ;;
+    ibmrt:4.4BSD:*|romp-ibm:BSD:*)
+       echo romp-ibm-bsd4.4
+       exit 0 ;;
+    ibmrt:*BSD:*|romp-ibm:BSD:*)            # covers RT/PC NetBSD and
+       echo romp-ibm-bsd${UNAME_RELEASE}   # 4.3 with uname added to
+       exit 0 ;;                           # report: romp-ibm BSD 4.3
+    *:BOSX:*:*)
+       echo rs6000-bull-bosx
+       exit 0 ;;
+    DPX/2?00:B.O.S.:*:*)
+       echo m68k-bull-sysv3
+       exit 0 ;;
+    9000/[34]??:4.3bsd:1.*:*)
+       echo m68k-hp-bsd
+       exit 0 ;;
+    hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
+       echo m68k-hp-bsd4.4
+       exit 0 ;;
+    9000/[3478]??:HP-UX:*:*)
+       case "${UNAME_MACHINE}" in
+           9000/31? )            HP_ARCH=m68000 ;;
+           9000/[34]?? )         HP_ARCH=m68k ;;
+           9000/7?? | 9000/8?[1679] ) HP_ARCH=hppa1.1 ;;
+           9000/8?? )            HP_ARCH=hppa1.0 ;;
+       esac
+       HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
+       echo ${HP_ARCH}-hp-hpux${HPUX_REV}
+       exit 0 ;;
+    3050*:HI-UX:*:*)
+       sed 's/^        //' << EOF >dummy.c
+       #include <unistd.h>
+       int
+       main ()
+       {
+         long cpu = sysconf (_SC_CPU_VERSION);
+         /* The order matters, because CPU_IS_HP_MC68K erroneously returns
+            true for CPU_PA_RISC1_0.  CPU_IS_PA_RISC returns correct
+            results, however.  */
+         if (CPU_IS_PA_RISC (cpu))
+           {
+             switch (cpu)
+               {
+                 case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break;
+                 case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break;
+                 case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break;
+                 default: puts ("hppa-hitachi-hiuxwe2"); break;
+               }
+           }
+         else if (CPU_IS_HP_MC68K (cpu))
+           puts ("m68k-hitachi-hiuxwe2");
+         else puts ("unknown-hitachi-hiuxwe2");
+         exit (0);
+       }
+EOF
+       ${CC-cc} dummy.c -o dummy && ./dummy && rm dummy.c dummy && exit 0
+       rm -f dummy.c dummy
+       echo unknown-hitachi-hiuxwe2
+       exit 0 ;;
+    9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
+       echo hppa1.1-hp-bsd
+       exit 0 ;;
+    9000/8??:4.3bsd:*:*)
+       echo hppa1.0-hp-bsd
+       exit 0 ;;
+    hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
+       echo hppa1.1-hp-osf
+       exit 0 ;;
+    hp8??:OSF1:*:*)
+       echo hppa1.0-hp-osf
+       exit 0 ;;
+    i?86:OSF1:*:*)
+       if [ -x /usr/sbin/sysversion ] ; then
+           echo ${UNAME_MACHINE}-unknown-osf1mk
+       else
+           echo ${UNAME_MACHINE}-unknown-osf1
+       fi
+       exit 0 ;;
+    parisc*:Lites*:*:*)
+       echo hppa1.1-hp-lites
+       exit 0 ;;
+    C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
+       echo c1-convex-bsd
+        exit 0 ;;
+    C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
+       if getsysinfo -f scalar_acc
+       then echo c32-convex-bsd
+       else echo c2-convex-bsd
+       fi
+        exit 0 ;;
+    C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
+       echo c34-convex-bsd
+        exit 0 ;;
+    C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
+       echo c38-convex-bsd
+        exit 0 ;;
+    C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
+       echo c4-convex-bsd
+        exit 0 ;;
+    CRAY*X-MP:*:*:*)
+       echo xmp-cray-unicos
+        exit 0 ;;
+    CRAY*Y-MP:*:*:*)
+       echo ymp-cray-unicos${UNAME_RELEASE}
+       exit 0 ;;
+    CRAY*[A-Z]90:*:*:*)
+       echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
+       | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
+             -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/
+       exit 0 ;;
+    CRAY*TS:*:*:*)
+       echo t90-cray-unicos${UNAME_RELEASE}
+       exit 0 ;;
+    CRAY-2:*:*:*)
+       echo cray2-cray-unicos
+        exit 0 ;;
+    F300:UNIX_System_V:*:*)
+        FUJITSU_SYS=`uname -p | tr [A-Z] [a-z] | sed -e 's/\///'`
+        FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
+        echo "f300-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
+        exit 0 ;;
+    F301:UNIX_System_V:*:*)
+       echo f301-fujitsu-uxpv`echo $UNAME_RELEASE | sed 's/ .*//'`
+       exit 0 ;;
+    hp3[0-9][05]:NetBSD:*:*)
+       echo m68k-hp-netbsd${UNAME_RELEASE}
+       exit 0 ;;
+    hp3[0-9][05]:OpenBSD:*:*)
+       echo m68k-hp-openbsd${UNAME_RELEASE}
+       exit 0 ;;
+    i?86:BSD/386:*:* | *:BSD/OS:*:*)
+       echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
+       exit 0 ;;
+    *:FreeBSD:*:*)
+       echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
+       exit 0 ;;
+    *:NetBSD:*:*)
+       echo ${UNAME_MACHINE}-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
+       exit 0 ;;
+    *:OpenBSD:*:*)
+       echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
+       exit 0 ;;
+    i*:CYGWIN*:*)
+       echo i386-pc-cygwin32
+       exit 0 ;;
+    p*:CYGWIN*:*)
+       echo powerpcle-unknown-cygwin32
+       exit 0 ;;
+    prep*:SunOS:5.*:*)
+       echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
+       exit 0 ;;
+    *:GNU:*:*)
+       echo `echo ${UNAME_MACHINE}|sed -e 's,/.*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
+       exit 0 ;;
+    *:Linux:*:*)
+       # The BFD linker knows what the default object file format is, so
+       # first see if it will tell us.
+       ld_help_string=`ld --help 2>&1`
+       if echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: elf_i.86"; then
+         echo "${UNAME_MACHINE}-pc-linux-gnu" ; exit 0
+       elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: i.86linux"; then
+         echo "${UNAME_MACHINE}-pc-linux-gnuaout" ; exit 0
+       elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: i.86coff"; then
+         echo "${UNAME_MACHINE}-pc-linux-gnucoff" ; exit 0
+       elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: m68kelf"; then
+         echo "${UNAME_MACHINE}-unknown-linux-gnu" ; exit 0
+       elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: m68klinux"; then
+         echo "${UNAME_MACHINE}-unknown-linux-gnuaout" ; exit 0
+       elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: elf32ppc"; then
+         echo "powerpc-unknown-linux-gnu" ; exit 0
+       elif test "${UNAME_MACHINE}" = "alpha" ; then
+         echo alpha-unknown-linux-gnu ; exit 0
+       elif test "${UNAME_MACHINE}" = "sparc" ; then
+         echo sparc-unknown-linux-gnu ; exit 0
+       else
+         # Either a pre-BFD a.out linker (linux-gnuoldld) or one that does not give us
+         # useful --help.  Gcc wants to distinguish between linux-gnuoldld and linux-gnuaout.
+         test ! -d /usr/lib/ldscripts/. \
+           && echo "${UNAME_MACHINE}-pc-linux-gnuoldld" && exit 0
+         # Determine whether the default compiler is a.out or elf
+         cat >dummy.c <<EOF
+main(argc, argv)
+int argc;
+char *argv[];
+{
+#ifdef __ELF__
+  printf ("%s-pc-linux-gnu\n", argv[1]);
+#else
+  printf ("%s-pc-linux-gnuaout\n", argv[1]);
+#endif
+  return 0;
+}
+EOF
+         ${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy "${UNAME_MACHINE}" && rm dummy.c dummy && exit 0
+         rm -f dummy.c dummy
+       fi ;;
+# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.  earlier versions
+# are messed up and put the nodename in both sysname and nodename.
+    i?86:DYNIX/ptx:4*:*)
+       echo i386-sequent-sysv4
+       exit 0 ;;
+    i?86:*:4.*:* | i?86:SYSTEM_V:4.*:*)
+       if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
+               echo ${UNAME_MACHINE}-univel-sysv${UNAME_RELEASE}
+       else
+               echo ${UNAME_MACHINE}-pc-sysv${UNAME_RELEASE}
+       fi
+       exit 0 ;;
+    i?86:*:3.2:*)
+       if test -f /usr/options/cb.name; then
+               UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
+               echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
+       elif /bin/uname -X 2>/dev/null >/dev/null ; then
+               UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
+               (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
+               (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \
+                       && UNAME_MACHINE=i586
+               echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
+       else
+               echo ${UNAME_MACHINE}-pc-sysv32
+       fi
+       exit 0 ;;
+    Intel:Mach:3*:*)
+       echo i386-pc-mach3
+       exit 0 ;;
+    paragon:*:*:*)
+       echo i860-intel-osf1
+       exit 0 ;;
+    i860:*:4.*:*) # i860-SVR4
+       if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
+         echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
+       else # Add other i860-SVR4 vendors below as they are discovered.
+         echo i860-unknown-sysv${UNAME_RELEASE}  # Unknown i860-SVR4
+       fi
+       exit 0 ;;
+    mini*:CTIX:SYS*5:*)
+       # "miniframe"
+       echo m68010-convergent-sysv
+       exit 0 ;;
+    M68*:*:R3V[567]*:*)
+       test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
+    3[34]??:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 4850:*:4.0:3.0)
+       OS_REL=''
+       test -r /etc/.relid \
+       && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
+       /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
+         && echo i486-ncr-sysv4.3${OS_REL} && exit 0
+       /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
+         && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;;
+    3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
+        /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
+          && echo i486-ncr-sysv4 && exit 0 ;;
+    m68*:LynxOS:2.*:*)
+       echo m68k-unknown-lynxos${UNAME_RELEASE}
+       exit 0 ;;
+    mc68030:UNIX_System_V:4.*:*)
+       echo m68k-atari-sysv4
+       exit 0 ;;
+    i?86:LynxOS:2.*:*)
+       echo i386-unknown-lynxos${UNAME_RELEASE}
+       exit 0 ;;
+    TSUNAMI:LynxOS:2.*:*)
+       echo sparc-unknown-lynxos${UNAME_RELEASE}
+       exit 0 ;;
+    rs6000:LynxOS:2.*:* | PowerPC:LynxOS:2.*:*)
+       echo rs6000-unknown-lynxos${UNAME_RELEASE}
+       exit 0 ;;
+    SM[BE]S:UNIX_SV:*:*)
+       echo mips-dde-sysv${UNAME_RELEASE}
+       exit 0 ;;
+    RM*:SINIX-*:*:*)
+       echo mips-sni-sysv4
+       exit 0 ;;
+    *:SINIX-*:*:*)
+       if uname -p 2>/dev/null >/dev/null ; then
+               UNAME_MACHINE=`(uname -p) 2>/dev/null`
+               echo ${UNAME_MACHINE}-sni-sysv4
+       else
+               echo ns32k-sni-sysv
+       fi
+       exit 0 ;;
+    *:UNIX_System_V:4*:FTX*)
+       # From Gerald Hewes <hewes@openmarket.com>.
+       # How about differentiating between stratus architectures? -djm
+       echo hppa1.1-stratus-sysv4
+       exit 0 ;;
+    *:*:*:FTX*)
+       # From seanf@swdc.stratus.com.
+       echo i860-stratus-sysv4
+       exit 0 ;;
+    mc68*:A/UX:*:*)
+       echo m68k-apple-aux${UNAME_RELEASE}
+       exit 0 ;;
+    R3000:*System_V*:*:* | R4000:UNIX_SYSV:*:*)
+       if [ -d /usr/nec ]; then
+               echo mips-nec-sysv${UNAME_RELEASE}
+       else
+               echo mips-unknown-sysv${UNAME_RELEASE}
+       fi
+        exit 0 ;;
+    PENTIUM:CPunix:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
+                           # says <Richard.M.Bartel@ccMail.Census.GOV>
+        echo i586-unisys-sysv4
+        exit 0 ;;
+esac
+
+#echo '(No uname command or uname output not recognized.)' 1>&2
+#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
+
+cat >dummy.c <<EOF
+#ifdef _SEQUENT_
+# include <sys/types.h>
+# include <sys/utsname.h>
+#endif
+main ()
+{
+#if defined (sony)
+#if defined (MIPSEB)
+  /* BFD wants "bsd" instead of "newsos".  Perhaps BFD should be changed,
+     I don't know....  */
+  printf ("mips-sony-bsd\n"); exit (0);
+#else
+#include <sys/param.h>
+  printf ("m68k-sony-newsos%s\n",
+#ifdef NEWSOS4
+          "4"
+#else
+         ""
+#endif
+         ); exit (0);
+#endif
+#endif
+
+#if defined (__arm) && defined (__acorn) && defined (__unix)
+  printf ("arm-acorn-riscix"); exit (0);
+#endif
+
+#if defined (hp300) && !defined (hpux)
+  printf ("m68k-hp-bsd\n"); exit (0);
+#endif
+
+#if defined (NeXT)
+#if !defined (__ARCHITECTURE__)
+#define __ARCHITECTURE__ "m68k"
+#endif
+  int version;
+  version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
+  printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
+  exit (0);
+#endif
+
+#if defined (MULTIMAX) || defined (n16)
+#if defined (UMAXV)
+  printf ("ns32k-encore-sysv\n"); exit (0);
+#else
+#if defined (CMU)
+  printf ("ns32k-encore-mach\n"); exit (0);
+#else
+  printf ("ns32k-encore-bsd\n"); exit (0);
+#endif
+#endif
+#endif
+
+#if defined (__386BSD__)
+  printf ("i386-pc-bsd\n"); exit (0);
+#endif
+
+#if defined (sequent)
+#if defined (i386)
+  printf ("i386-sequent-dynix\n"); exit (0);
+#endif
+#if defined (ns32000)
+  printf ("ns32k-sequent-dynix\n"); exit (0);
+#endif
+#endif
+
+#if defined (_SEQUENT_)
+    struct utsname un;
+
+    uname(&un);
+
+    if (strncmp(un.version, "V2", 2) == 0) {
+       printf ("i386-sequent-ptx2\n"); exit (0);
+    }
+    if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
+       printf ("i386-sequent-ptx1\n"); exit (0);
+    }
+    printf ("i386-sequent-ptx\n"); exit (0);
+
+#endif
+
+#if defined (vax)
+#if !defined (ultrix)
+  printf ("vax-dec-bsd\n"); exit (0);
+#else
+  printf ("vax-dec-ultrix\n"); exit (0);
+#endif
+#endif
+
+#if defined (alliant) && defined (i860)
+  printf ("i860-alliant-bsd\n"); exit (0);
+#endif
+
+  exit (1);
+}
+EOF
+
+${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy && rm dummy.c dummy && exit 0
+rm -f dummy.c dummy
+
+# Apollos put the system type in the environment.
+
+test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; }
+
+# Convex versions that predate uname can use getsysinfo(1)
+
+if [ -x /usr/convex/getsysinfo ]
+then
+    case `getsysinfo -f cpu_type` in
+    c1*)
+       echo c1-convex-bsd
+       exit 0 ;;
+    c2*)
+       if getsysinfo -f scalar_acc
+       then echo c32-convex-bsd
+       else echo c2-convex-bsd
+       fi
+       exit 0 ;;
+    c34*)
+       echo c34-convex-bsd
+       exit 0 ;;
+    c38*)
+       echo c38-convex-bsd
+       exit 0 ;;
+    c4*)
+       echo c4-convex-bsd
+       exit 0 ;;
+    esac
+fi
+
+#echo '(Unable to guess system type)' 1>&2
+
+exit 1
diff --git a/xlockmore-4.14/config.h.in b/xlockmore-4.14/config.h.in
new file mode 100644 (file)
index 0000000..11db13d
--- /dev/null
@@ -0,0 +1,319 @@
+/*-
+ * config.h.in --- xlockmore
+ *
+ *  The best way to set these parameters is by running the included `configure'
+ *  script.  That examines your system, and generates `config.h' from
+ *  `config.h.in'.
+ *
+ *  If something goes very wrong, you can edit `config.h' directly, but beware
+ *  that your changes will be lost if you ever run `configure' again.
+ *
+ *  At the bottom, there are a few things commented out that are not
+ *  automatically detected (past "NOT AUTOMATICALLY DETECTED YET").
+ * 
+ */
+
+/* Define to empty if the keyword does not work.  */
+#undef const
+
+/* Define to empty if the keyword does not work.  */
+#undef inline
+
+/* Define to the type of elements in the array set by `getgroups'. Usually
+   this is either `int' or `gid_t'.  */
+#undef GETGROUPS_T
+
+/* Define to `int' if <sys/types.h> doesn't define.  */
+#undef gid_t
+
+/* Define if you have <sys/wait.h> that is POSIX.1 compatible.  */
+#undef HAVE_SYS_WAIT_H
+
+/* Define to `int' if <sys/types.h> doesn't define.  */
+#undef pid_t
+
+/* Define as the return type of signal handlers (int or void).  */
+#undef RETSIGTYPE
+
+/* Define to `unsigned' if <sys/types.h> doesn't define.  */
+#undef size_t
+
+/* Define if you have the ANSI C header files.  */
+#undef STDC_HEADERS
+
+/* Define if you can safely include both <sys/time.h> and <time.h>.  */
+#undef TIME_WITH_SYS_TIME
+
+/* Define if your <sys/time.h> declares struct tm.  */
+#undef TM_IN_SYS_TIME
+
+/* Define if you have the gettimeofday function.  */
+#undef HAVE_GETTIMEOFDAY
+
+/* Define if gettimeofday requires two arguments.  */
+#undef GETTIMEOFDAY_TWO_ARGS
+
+/* Define if you have the tzset function.  */
+#undef HAVE_TZSET
+
+/* Define if you have the timelocal function.  */
+#undef HAVE_TIMELOCAL
+
+/* Define to `int' if <sys/types.h> doesn't define.  */
+#undef uid_t
+
+/* Define if you have the gethostname function.  */
+#undef HAVE_GETHOSTNAME
+
+/* Define if you have the select function.  */
+#undef HAVE_SELECT
+
+/* Define if you have the strdup function.  */
+#undef HAVE_STRDUP
+
+/* Define if you have the seteuid function.  */
+#undef HAVE_SETEUID
+
+/* Define if you have the setreuid function.  */
+#undef HAVE_SETREUID
+
+/* Define one of these if they exist, usleep prefered.  */
+#undef HAVE_USLEEP
+#undef HAVE_NANOSLEEP
+
+/* If left undefined will default to internal Random Number Generator */
+#undef SRAND
+#undef LRAND
+#undef MAXRAND
+
+/* Enable use of matherr function */
+#undef USE_MATHERR
+
+/* Define if you have the <dirent.h> header file.  */
+#undef HAVE_DIRENT_H
+
+/* Define if you have the <fcntl.h> header file.  */
+#undef HAVE_FCNTL_H
+
+/* Define if you have the <limits.h> header file.  */
+#undef HAVE_LIMITS_H
+
+/* Define if you have the <ndir.h> header file.  */
+#undef HAVE_NDIR_H
+
+/* Define if you have the <sys/dir.h> header file.  */
+#undef HAVE_SYS_DIR_H
+
+/* Define if you have the <sys/ndir.h> header file.  */
+#undef HAVE_SYS_NDIR_H
+
+/* Define if you have the <sys/time.h> header file.  */
+#undef HAVE_SYS_TIME_H
+
+/* Define if you have the <sys/select.h> header file.  */
+#undef HAVE_SYS_SELECT_H
+
+/* Define if you have the <syslog.h> header file.  */
+#undef HAVE_SYSLOG_H
+
+/* Define if you have the <unistd.h> header file.  */
+#undef HAVE_UNISTD_H
+
+/* Define if you have the <sys/param.h> header file.  */
+#undef HAVE_SYS_PARAM_H
+
+/* Define if you have the shadow passwords (or elf).  */
+#undef HAVE_SHADOW
+
+/* Define if you have the sigset_t structure.  */
+#undef HAVE_STRUCT_SIGSET_T
+
+/* Various system defines.  */
+#undef SYSV
+#undef SVR4
+#undef linux
+#undef SOLARIS2
+#undef LESS_THAN_SOLARIS2_5
+#undef SUNOS4
+#undef _POSIX_SOURCE
+#undef _BSD_SOURCE
+#undef _GNU_SOURCE
+#undef AIXV3
+#undef LESS_THAN_AIX3_2
+#undef SUN_OGL_NO_VERTEX_MACROS
+
+/* Define this if your version of OpenGL has the glBindTexture() routine.
+   This is the case for OpenGL 1.1, but not for OpenGL 1.0.
+ */
+#undef HAVE_GLBINDTEXTURE
+
+/* Define if you have XPM (look for it under a X11 dir).  */
+#undef USE_XPM
+
+/* Define if you have XPM (when its not under a X11 dir, not the norm).  */
+#undef USE_XPMINC
+
+/* Define if you have c++ */
+#undef HAVE_CXX
+
+/* Define if you have FreeType (libttf.a)  */
+#undef HAVE_TTF
+
+/* Define if you have GLTT (libgltt.a)  */
+#undef HAVE_GLTT
+
+/* Define if you have XMU (Editres).  */
+#undef USE_XMU
+
+/* Define if you have GL (MesaGL).  */
+#undef USE_GL
+
+/* Define if you have DtSaver.  */
+#undef USE_DTSAVER
+
+/* Define if you have DPMS (Display Power Management Signaling).  */
+#undef USE_DPMS
+
+/* Define one of these for sounds.  */
+#undef USE_RPLAY
+#undef USE_NAS
+#undef USE_VMSPLAY
+#undef DEF_PLAY
+
+/* Allows xlock to run in root window (some window managers have problems) */
+#undef USE_VROOT
+
+/* Users can not turn off allowroot */
+#undef ALWAYS_ALLOW_ROOT
+
+/* Paranoid administrator option (a check is also done to see if you have it) */
+#undef USE_SYSLOG
+
+/* Multiple users ... security? */
+#undef USE_MULTIPLE_USER
+
+/* Multiple root users ... security? */
+#undef USE_MULTIPLE_ROOT
+
+/* Allow a window to be placed over xlock */
+#undef USE_WINDOW_VISIBILITY
+
+/* Some machines may still need this (fd_set errors may be a sign) */
+#undef USE_OLD_EVENT_LOOP
+
+/* This patches up old __VMS_VER < 70000000 */
+#undef USE_VMSUTILS
+
+/* For personal use you may want to consider: */
+/* Unfriendly paranoid admininistrator or unknown shadow passwd algorithm */
+#undef USE_XLOCKRC
+
+/* For labs you may want to consider: */
+
+/* Enable auto-logout code, minutes until auto-logout */
+#undef USE_AUTO_LOGOUT
+
+/* Set default for auto-logout code, hard limit is USE_AUTO_LOGOUT */
+#undef DEF_AUTO_LOGOUT
+
+/* Enable logout button, minutes until button appears */
+#undef USE_BUTTON_LOGOUT
+
+/* Set default for logout button code, hard limit is USE_LOGOUT_BUTTON */
+#undef DEF_BUTTON_LOGOUT
+
+/* Enable automatic logout mode (does not come up in random mode) */
+#undef USE_BOMB
+
+/* Enable unstable modes */
+#undef USE_UNSTABLE
+
+/* Define one of these with USE_AUTO_LOGOUT, USE_LOGOUT_BUTTON, and/or
+   USE_BOMB, if using xdm */
+#undef CLOSEDOWN_LOGOUT
+#undef SESSION_LOGOUT
+
+/* File of staff who are exempt */
+#undef STAFF_FILE
+
+/* Netgroup that is exempt */
+#undef STAFF_NETGROUP
+
+/* Digital Unix Enhanced Security */
+#undef OSF1_ENH_SEC
+
+/* Kerberos 4 */
+#undef HAVE_KRB4
+
+/* Kerberos 5 */
+#undef HAVE_KRB5
+
+/* DCE Passwording */
+#undef DCE_PASSWD
+
+/* Define to use and link against PAM */
+#undef PAM
+
+/* AIX AFS Passwording */
+#undef AFS
+
+/* SUNOS Adjunct Passwording */
+#undef SUNOS_ADJUNCT_PASSWD
+
+/* USE Xmb function series */
+#undef USE_MB
+
+/* XResource customization, drawback -display option may not work  */
+#undef CUSTOMIZATION
+
+/* reporting language customization */
+#undef NL
+#undef FR
+#undef DE
+
+/* enabling original mail icon xpm patch */
+#undef ORIGINAL_XPM_PATCH
+
+/* Virtual Terminal Lock for XFree86 users  */
+#undef USE_VTLOCK
+
+/* Gtk Fontsel Widget */
+#undef HAVE_GTK_FONTSEL_WIDGET
+
+/* The FOLLOWING are NOT AUTOMATICALLY DETECTED YET */
+
+/* Force NON-MESA GL using MESA includes, uncomment next line */
+/* #define OPENGL_MESA_INCLUDES */
+
+/* EXTRA SOUND STUFF if you do not have RPLAY or NAS */
+/* SUNOS 4.1.3 */
+/* #define DEF_PLAY "/usr/demo/SOUND/play /usr/local/share/sounds/xlock/" */
+/* IRIX 5.3 */
+/* #define DEF_PLAY "/usr/sbin/sfplay /usr/local/share/sounds/xlock/" */
+/* Digital Unix with Multimedia Services installed */
+/* #define DEF_PLAY "/usr/bin/mme/decsound -play
+   /usr/local/share/sounds/xlock/" */
+/* LINUX and others (see config directory) */
+/* #define DEF_PLAY "/usr/local/bin/play.sh /usr/local/share/sounds/xlock/" */
+
+/* EXTRA SYSLOG STUFF if you want to override defaults for SYSLOG */
+/* You may want to set all -DSYSLOG_* to LOG_WARNING to maximize messages */
+/* #define SYSLOG_FACILITY LOG_AUTH */
+/* #define SYSLOG_WARNING LOG_WARNING */
+/* #define SYSLOG_NOTICE LOG_NOTICE */
+/* #define SYSLOG_INFO LOG_INFO */
+
+/* #define SAFEWORD */
+/* #define FX */
+
+/* Full screen colormaps are not allowed on compliant window managers
+   like FVWM, TVWM, SCWM, and DEC WINDOWS and tricks xlock, this fix does
+   not work on TrueColor
+ */
+/* #define COMPLIANT_COLORMAP */
+
+/* Gtk Fontsel Widget */
+#undef HAVE_GTK_FONTSEL_WIDGET
+
+/* Gtk Fontsel Widget */
+#undef HAVE_GTK_FONTSEL_WIDGET
diff --git a/xlockmore-4.14/config.sub b/xlockmore-4.14/config.sub
new file mode 100755 (executable)
index 0000000..0432524
--- /dev/null
@@ -0,0 +1,927 @@
+#! /bin/sh
+# Configuration validation subroutine script, version 1.1.
+#   Copyright (C) 1991, 92, 93, 94, 95, 1996 Free Software Foundation, Inc.
+# This file is (in principle) common to ALL GNU software.
+# The presence of a machine in this file suggests that SOME GNU software
+# can handle that machine.  It does not imply ALL GNU software can.
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
+
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
+# Configuration subroutine to validate and canonicalize a configuration type.
+# Supply the specified configuration type as an argument.
+# If it is invalid, we print an error message on stderr and exit with code 1.
+# Otherwise, we print the canonical config type on stdout and succeed.
+
+# This file is supposed to be the same for all GNU packages
+# and recognize all the CPU types, system types and aliases
+# that are meaningful with *any* GNU software.
+# Each package is responsible for reporting which valid configurations
+# it does not support.  The user should be able to distinguish
+# a failure to support a valid configuration from a meaningless
+# configuration.
+
+# The goal of this file is to map all the various variations of a given
+# machine specification into a single specification in the form:
+#      CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
+# or in some cases, the newer four-part form:
+#      CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
+# It is wrong to echo any other type of specification.
+
+if [ x$1 = x ]
+then
+       echo Configuration name missing. 1>&2
+       echo "Usage: $0 CPU-MFR-OPSYS" 1>&2
+       echo "or     $0 ALIAS" 1>&2
+       echo where ALIAS is a recognized configuration type. 1>&2
+       exit 1
+fi
+
+# First pass through any local machine types.
+case $1 in
+       *local*)
+               echo $1
+               exit 0
+               ;;
+       *)
+       ;;
+esac
+
+# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any).
+# Here we must recognize all the valid KERNEL-OS combinations.
+maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
+case $maybe_os in
+  linux-gnu*)
+    os=-$maybe_os
+    basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
+    ;;
+  *)
+    basic_machine=`echo $1 | sed 's/-[^-]*$//'`
+    if [ $basic_machine != $1 ]
+    then os=`echo $1 | sed 's/.*-/-/'`
+    else os=; fi
+    ;;
+esac
+
+### Let's recognize common machines as not being operating systems so
+### that things like config.sub decstation-3100 work.  We also
+### recognize some manufacturers as not being operating systems, so we
+### can provide default operating systems below.
+case $os in
+       -sun*os*)
+               # Prevent following clause from handling this invalid input.
+               ;;
+       -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
+       -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
+       -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
+       -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
+       -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
+       -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
+       -apple)
+               os=
+               basic_machine=$1
+               ;;
+       -hiux*)
+               os=-hiuxwe2
+               ;;
+       -sco5)
+               os=sco3.2v5
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+               ;;
+       -sco4)
+               os=-sco3.2v4
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+               ;;
+       -sco3.2.[4-9]*)
+               os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+               ;;
+       -sco3.2v[4-9]*)
+               # Don't forget version if it is 3.2v4 or newer.
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+               ;;
+       -sco*)
+               os=-sco3.2v2
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+               ;;
+       -isc)
+               os=-isc2.2
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+               ;;
+       -clix*)
+               basic_machine=clipper-intergraph
+               ;;
+       -isc*)
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+               ;;
+       -lynx*)
+               os=-lynxos
+               ;;
+       -ptx*)
+               basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
+               ;;
+       -windowsnt*)
+               os=`echo $os | sed -e 's/windowsnt/winnt/'`
+               ;;
+       -psos*)
+               os=-psos
+               ;;
+esac
+
+# Decode aliases for certain CPU-COMPANY combinations.
+case $basic_machine in
+       # Recognize the basic CPU types without company name.
+       # Some are omitted here because they have special meanings below.
+       tahoe | i860 | m68k | m68000 | m88k | ns32k | arm \
+               | arme[lb] | pyramid \
+               | tron | a29k | 580 | i960 | h8300 | hppa | hppa1.0 | hppa1.1 \
+               | alpha | we32k | ns16k | clipper | i370 | sh \
+               | powerpc | powerpcle | 1750a | dsp16xx | mips64 | mipsel \
+               | pdp11 | mips64el | mips64orion | mips64orionel \
+               | sparc | sparclet | sparclite | sparc64)
+               basic_machine=$basic_machine-unknown
+               ;;
+       # We use `pc' rather than `unknown'
+       # because (1) that's what they normally are, and
+       # (2) the word "unknown" tends to confuse beginning users.
+       i[3456]86)
+         basic_machine=$basic_machine-pc
+         ;;
+       # Object if more than one company name word.
+       *-*-*)
+               echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
+               exit 1
+               ;;
+       # Recognize the basic CPU types with company name.
+       vax-* | tahoe-* | i[3456]86-* | i860-* | m68k-* | m68000-* | m88k-* \
+             | sparc-* | ns32k-* | fx80-* | arm-* | c[123]* \
+             | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* | power-* \
+             | none-* | 580-* | cray2-* | h8300-* | i960-* | xmp-* | ymp-* \
+             | hppa-* | hppa1.0-* | hppa1.1-* | alpha-* | we32k-* | cydra-* | ns16k-* \
+             | pn-* | np1-* | xps100-* | clipper-* | orion-* | sparclite-* \
+             | pdp11-* | sh-* | powerpc-* | powerpcle-* | sparc64-* | mips64-* | mipsel-* \
+             | mips64el-* | mips64orion-* | mips64orionel-* | f301-*)
+               ;;
+       # Recognize the various machine names and aliases which stand
+       # for a CPU type and a company and sometimes even an OS.
+       3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
+               basic_machine=m68000-att
+               ;;
+       3b*)
+               basic_machine=we32k-att
+               ;;
+       alliant | fx80)
+               basic_machine=fx80-alliant
+               ;;
+       altos | altos3068)
+               basic_machine=m68k-altos
+               ;;
+       am29k)
+               basic_machine=a29k-none
+               os=-bsd
+               ;;
+       amdahl)
+               basic_machine=580-amdahl
+               os=-sysv
+               ;;
+       amiga | amiga-*)
+               basic_machine=m68k-cbm
+               ;;
+       amigados)
+               basic_machine=m68k-cbm
+               os=-amigados
+               ;;
+       amigaunix | amix)
+               basic_machine=m68k-cbm
+               os=-sysv4
+               ;;
+       apollo68)
+               basic_machine=m68k-apollo
+               os=-sysv
+               ;;
+       aux)
+               basic_machine=m68k-apple
+               os=-aux
+               ;;
+       balance)
+               basic_machine=ns32k-sequent
+               os=-dynix
+               ;;
+       convex-c1)
+               basic_machine=c1-convex
+               os=-bsd
+               ;;
+       convex-c2)
+               basic_machine=c2-convex
+               os=-bsd
+               ;;
+       convex-c32)
+               basic_machine=c32-convex
+               os=-bsd
+               ;;
+       convex-c34)
+               basic_machine=c34-convex
+               os=-bsd
+               ;;
+       convex-c38)
+               basic_machine=c38-convex
+               os=-bsd
+               ;;
+       cray | ymp)
+               basic_machine=ymp-cray
+               os=-unicos
+               ;;
+       cray2)
+               basic_machine=cray2-cray
+               os=-unicos
+               ;;
+       [ctj]90-cray)
+               basic_machine=c90-cray
+               os=-unicos
+               ;;
+       crds | unos)
+               basic_machine=m68k-crds
+               ;;
+       da30 | da30-*)
+               basic_machine=m68k-da30
+               ;;
+       decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
+               basic_machine=mips-dec
+               ;;
+       delta | 3300 | motorola-3300 | motorola-delta \
+             | 3300-motorola | delta-motorola)
+               basic_machine=m68k-motorola
+               ;;
+       delta88)
+               basic_machine=m88k-motorola
+               os=-sysv3
+               ;;
+       dpx20 | dpx20-*)
+               basic_machine=rs6000-bull
+               os=-bosx
+               ;;
+       dpx2* | dpx2*-bull)
+               basic_machine=m68k-bull
+               os=-sysv3
+               ;;
+       ebmon29k)
+               basic_machine=a29k-amd
+               os=-ebmon
+               ;;
+       elxsi)
+               basic_machine=elxsi-elxsi
+               os=-bsd
+               ;;
+       encore | umax | mmax)
+               basic_machine=ns32k-encore
+               ;;
+       fx2800)
+               basic_machine=i860-alliant
+               ;;
+       genix)
+               basic_machine=ns32k-ns
+               ;;
+       gmicro)
+               basic_machine=tron-gmicro
+               os=-sysv
+               ;;
+       h3050r* | hiux*)
+               basic_machine=hppa1.1-hitachi
+               os=-hiuxwe2
+               ;;
+       h8300hms)
+               basic_machine=h8300-hitachi
+               os=-hms
+               ;;
+       harris)
+               basic_machine=m88k-harris
+               os=-sysv3
+               ;;
+       hp300-*)
+               basic_machine=m68k-hp
+               ;;
+       hp300bsd)
+               basic_machine=m68k-hp
+               os=-bsd
+               ;;
+       hp300hpux)
+               basic_machine=m68k-hp
+               os=-hpux
+               ;;
+       hp9k2[0-9][0-9] | hp9k31[0-9])
+               basic_machine=m68000-hp
+               ;;
+       hp9k3[2-9][0-9])
+               basic_machine=m68k-hp
+               ;;
+       hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7)
+               basic_machine=hppa1.1-hp
+               ;;
+       hp9k8[0-9][0-9] | hp8[0-9][0-9])
+               basic_machine=hppa1.0-hp
+               ;;
+       hppa-next)
+               os=-nextstep3
+               ;;
+       i370-ibm* | ibm*)
+               basic_machine=i370-ibm
+               os=-mvs
+               ;;
+# I'm not sure what "Sysv32" means.  Should this be sysv3.2?
+       i[3456]86v32)
+               basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
+               os=-sysv32
+               ;;
+       i[3456]86v4*)
+               basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
+               os=-sysv4
+               ;;
+       i[3456]86v)
+               basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
+               os=-sysv
+               ;;
+       i[3456]86sol2)
+               basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
+               os=-solaris2
+               ;;
+       iris | iris4d)
+               basic_machine=mips-sgi
+               case $os in
+                   -irix*)
+                       ;;
+                   *)
+                       os=-irix4
+                       ;;
+               esac
+               ;;
+       isi68 | isi)
+               basic_machine=m68k-isi
+               os=-sysv
+               ;;
+       m88k-omron*)
+               basic_machine=m88k-omron
+               ;;
+       magnum | m3230)
+               basic_machine=mips-mips
+               os=-sysv
+               ;;
+       merlin)
+               basic_machine=ns32k-utek
+               os=-sysv
+               ;;
+       miniframe)
+               basic_machine=m68000-convergent
+               ;;
+       mips3*-*)
+               basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
+               ;;
+       mips3*)
+               basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
+               ;;
+       ncr3000)
+               basic_machine=i486-ncr
+               os=-sysv4
+               ;;
+       news | news700 | news800 | news900)
+               basic_machine=m68k-sony
+               os=-newsos
+               ;;
+       news1000)
+               basic_machine=m68030-sony
+               os=-newsos
+               ;;
+       news-3600 | risc-news)
+               basic_machine=mips-sony
+               os=-newsos
+               ;;
+       next | m*-next )
+               basic_machine=m68k-next
+               case $os in
+                   -nextstep* )
+                       ;;
+                   -ns2*)
+                     os=-nextstep2
+                       ;;
+                   *)
+                     os=-nextstep3
+                       ;;
+               esac
+               ;;
+       nh3000)
+               basic_machine=m68k-harris
+               os=-cxux
+               ;;
+       nh[45]000)
+               basic_machine=m88k-harris
+               os=-cxux
+               ;;
+       nindy960)
+               basic_machine=i960-intel
+               os=-nindy
+               ;;
+       np1)
+               basic_machine=np1-gould
+               ;;
+       pa-hitachi)
+               basic_machine=hppa1.1-hitachi
+               os=-hiuxwe2
+               ;;
+       paragon)
+               basic_machine=i860-intel
+               os=-osf
+               ;;
+       pbd)
+               basic_machine=sparc-tti
+               ;;
+       pbb)
+               basic_machine=m68k-tti
+               ;;
+        pc532 | pc532-*)
+               basic_machine=ns32k-pc532
+               ;;
+       pentium | p5)
+               basic_machine=i586-intel
+               ;;
+       pentiumpro | p6)
+               basic_machine=i686-intel
+               ;;
+       pentium-* | p5-*)
+               basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
+               ;;
+       pentiumpro-* | p6-*)
+               basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
+               ;;
+       k5)
+               # We don't have specific support for AMD's K5 yet, so just call it a Pentium
+               basic_machine=i586-amd
+               ;;
+       nexen)
+               # We don't have specific support for Nexgen yet, so just call it a Pentium
+               basic_machine=i586-nexgen
+               ;;
+       pn)
+               basic_machine=pn-gould
+               ;;
+       power)  basic_machine=rs6000-ibm
+               ;;
+       ppc)    basic_machine=powerpc-unknown
+               ;;
+       ppc-*)  basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
+               ;;
+       ppcle | powerpclittle | ppc-le | powerpc-little)
+               basic_machine=powerpcle-unknown
+               ;;
+       ppcle-* | powerpclittle-*)
+               basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
+               ;;
+       ps2)
+               basic_machine=i386-ibm
+               ;;
+       rm[46]00)
+               basic_machine=mips-siemens
+               ;;
+       rtpc | rtpc-*)
+               basic_machine=romp-ibm
+               ;;
+       sequent)
+               basic_machine=i386-sequent
+               ;;
+       sh)
+               basic_machine=sh-hitachi
+               os=-hms
+               ;;
+       sps7)
+               basic_machine=m68k-bull
+               os=-sysv2
+               ;;
+       spur)
+               basic_machine=spur-unknown
+               ;;
+       sun2)
+               basic_machine=m68000-sun
+               ;;
+       sun2os3)
+               basic_machine=m68000-sun
+               os=-sunos3
+               ;;
+       sun2os4)
+               basic_machine=m68000-sun
+               os=-sunos4
+               ;;
+       sun3os3)
+               basic_machine=m68k-sun
+               os=-sunos3
+               ;;
+       sun3os4)
+               basic_machine=m68k-sun
+               os=-sunos4
+               ;;
+       sun4os3)
+               basic_machine=sparc-sun
+               os=-sunos3
+               ;;
+       sun4os4)
+               basic_machine=sparc-sun
+               os=-sunos4
+               ;;
+       sun4sol2)
+               basic_machine=sparc-sun
+               os=-solaris2
+               ;;
+       sun3 | sun3-*)
+               basic_machine=m68k-sun
+               ;;
+       sun4)
+               basic_machine=sparc-sun
+               ;;
+       sun386 | sun386i | roadrunner)
+               basic_machine=i386-sun
+               ;;
+       symmetry)
+               basic_machine=i386-sequent
+               os=-dynix
+               ;;
+       tower | tower-32)
+               basic_machine=m68k-ncr
+               ;;
+       udi29k)
+               basic_machine=a29k-amd
+               os=-udi
+               ;;
+       ultra3)
+               basic_machine=a29k-nyu
+               os=-sym1
+               ;;
+       vaxv)
+               basic_machine=vax-dec
+               os=-sysv
+               ;;
+       vms)
+               basic_machine=vax-dec
+               os=-vms
+               ;;
+       vpp*|vx|vx-*)
+               basic_machine=f301-fujitsu
+               ;;
+       vxworks960)
+               basic_machine=i960-wrs
+               os=-vxworks
+               ;;
+       vxworks68)
+               basic_machine=m68k-wrs
+               os=-vxworks
+               ;;
+       vxworks29k)
+               basic_machine=a29k-wrs
+               os=-vxworks
+               ;;
+       xmp)
+               basic_machine=xmp-cray
+               os=-unicos
+               ;;
+        xps | xps100)
+               basic_machine=xps100-honeywell
+               ;;
+       none)
+               basic_machine=none-none
+               os=-none
+               ;;
+
+# Here we handle the default manufacturer of certain CPU types.  It is in
+# some cases the only manufacturer, in others, it is the most popular.
+       mips)
+               basic_machine=mips-mips
+               ;;
+       romp)
+               basic_machine=romp-ibm
+               ;;
+       rs6000)
+               basic_machine=rs6000-ibm
+               ;;
+       vax)
+               basic_machine=vax-dec
+               ;;
+       pdp11)
+               basic_machine=pdp11-dec
+               ;;
+       we32k)
+               basic_machine=we32k-att
+               ;;
+       sparc)
+               basic_machine=sparc-sun
+               ;;
+        cydra)
+               basic_machine=cydra-cydrome
+               ;;
+       orion)
+               basic_machine=orion-highlevel
+               ;;
+       orion105)
+               basic_machine=clipper-highlevel
+               ;;
+       *)
+               echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
+               exit 1
+               ;;
+esac
+
+# Here we canonicalize certain aliases for manufacturers.
+case $basic_machine in
+       *-digital*)
+               basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
+               ;;
+       *-commodore*)
+               basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
+               ;;
+       *)
+               ;;
+esac
+
+# Decode manufacturer-specific aliases for certain operating systems.
+
+if [ x"$os" != x"" ]
+then
+case $os in
+        # First match some system type aliases
+        # that might get confused with valid system types.
+       # -solaris* is a basic system type, with this one exception.
+       -solaris1 | -solaris1.*)
+               os=`echo $os | sed -e 's|solaris1|sunos4|'`
+               ;;
+       -solaris)
+               os=-solaris2
+               ;;
+       -unixware* | svr4*)
+               os=-sysv4
+               ;;
+       -gnu/linux*)
+               os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
+               ;;
+       # First accept the basic system types.
+       # The portable systems comes first.
+       # Each alternative MUST END IN A *, to match a version number.
+       # -sysv* is not here because it comes later, after sysvr4.
+       -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
+             | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
+             | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
+             | -amigados* | -msdos* | -newsos* | -unicos* | -aof* | -aos* \
+             | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
+             | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
+             | -hiux* | -386bsd* | -netbsd* | -openbsd* | -freebsd* | -riscix* \
+             | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
+             | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
+             | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
+             | -cygwin32* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
+             | -linux-gnu* | -uxpv*)
+       # Remember, each alternative MUST END IN *, to match a version number.
+               ;;
+       -linux*)
+               os=`echo $os | sed -e 's|linux|linux-gnu|'`
+               ;;
+       -sunos5*)
+               os=`echo $os | sed -e 's|sunos5|solaris2|'`
+               ;;
+       -sunos6*)
+               os=`echo $os | sed -e 's|sunos6|solaris3|'`
+               ;;
+       -osfrose*)
+               os=-osfrose
+               ;;
+       -osf*)
+               os=-osf
+               ;;
+       -utek*)
+               os=-bsd
+               ;;
+       -dynix*)
+               os=-bsd
+               ;;
+       -acis*)
+               os=-aos
+               ;;
+       -ctix* | -uts*)
+               os=-sysv
+               ;;
+       -ns2 )
+               os=-nextstep2
+               ;;
+       # Preserve the version number of sinix5.
+       -sinix5.*)
+               os=`echo $os | sed -e 's|sinix|sysv|'`
+               ;;
+       -sinix*)
+               os=-sysv4
+               ;;
+       -triton*)
+               os=-sysv3
+               ;;
+       -oss*)
+               os=-sysv3
+               ;;
+       -svr4)
+               os=-sysv4
+               ;;
+       -svr3)
+               os=-sysv3
+               ;;
+       -sysvr4)
+               os=-sysv4
+               ;;
+       # This must come after -sysvr4.
+       -sysv*)
+               ;;
+       -xenix)
+               os=-xenix
+               ;;
+       -none)
+               ;;
+       *)
+               # Get rid of the `-' at the beginning of $os.
+               os=`echo $os | sed 's/[^-]*-//'`
+               echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
+               exit 1
+               ;;
+esac
+else
+
+# Here we handle the default operating systems that come with various machines.
+# The value should be what the vendor currently ships out the door with their
+# machine or put another way, the most popular os provided with the machine.
+
+# Note that if you're going to try to match "-MANUFACTURER" here (say,
+# "-sun"), then you have to tell the case statement up towards the top
+# that MANUFACTURER isn't an operating system.  Otherwise, code above
+# will signal an error saying that MANUFACTURER isn't an operating
+# system, and we'll never get to this point.
+
+case $basic_machine in
+       *-acorn)
+               os=-riscix1.2
+               ;;
+       arm*-semi)
+               os=-aout
+               ;;
+        pdp11-*)
+               os=-none
+               ;;
+       *-dec | vax-*)
+               os=-ultrix4.2
+               ;;
+       m68*-apollo)
+               os=-domain
+               ;;
+       i386-sun)
+               os=-sunos4.0.2
+               ;;
+       m68000-sun)
+               os=-sunos3
+               # This also exists in the configure program, but was not the
+               # default.
+               # os=-sunos4
+               ;;
+       *-tti)  # must be before sparc entry or we get the wrong os.
+               os=-sysv3
+               ;;
+       sparc-* | *-sun)
+               os=-sunos4.1.1
+               ;;
+       *-ibm)
+               os=-aix
+               ;;
+       *-hp)
+               os=-hpux
+               ;;
+       *-hitachi)
+               os=-hiux
+               ;;
+       i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
+               os=-sysv
+               ;;
+       *-cbm)
+               os=-amigados
+               ;;
+       *-dg)
+               os=-dgux
+               ;;
+       *-dolphin)
+               os=-sysv3
+               ;;
+       m68k-ccur)
+               os=-rtu
+               ;;
+       m88k-omron*)
+               os=-luna
+               ;;
+       *-next )
+               os=-nextstep
+               ;;
+       *-sequent)
+               os=-ptx
+               ;;
+       *-crds)
+               os=-unos
+               ;;
+       *-ns)
+               os=-genix
+               ;;
+       i370-*)
+               os=-mvs
+               ;;
+       *-next)
+               os=-nextstep3
+               ;;
+        *-gould)
+               os=-sysv
+               ;;
+        *-highlevel)
+               os=-bsd
+               ;;
+       *-encore)
+               os=-bsd
+               ;;
+        *-sgi)
+               os=-irix
+               ;;
+        *-siemens)
+               os=-sysv4
+               ;;
+       *-masscomp)
+               os=-rtu
+               ;;
+       f301-fujitsu)
+               os=-uxpv
+               ;;
+       *)
+               os=-none
+               ;;
+esac
+fi
+
+# Here we handle the case where we know the os, and the CPU type, but not the
+# manufacturer.  We pick the logical manufacturer.
+vendor=unknown
+case $basic_machine in
+       *-unknown)
+               case $os in
+                       -riscix*)
+                               vendor=acorn
+                               ;;
+                       -sunos*)
+                               vendor=sun
+                               ;;
+                       -aix*)
+                               vendor=ibm
+                               ;;
+                       -hpux*)
+                               vendor=hp
+                               ;;
+                       -hiux*)
+                               vendor=hitachi
+                               ;;
+                       -unos*)
+                               vendor=crds
+                               ;;
+                       -dgux*)
+                               vendor=dg
+                               ;;
+                       -luna*)
+                               vendor=omron
+                               ;;
+                       -genix*)
+                               vendor=ns
+                               ;;
+                       -mvs*)
+                               vendor=ibm
+                               ;;
+                       -ptx*)
+                               vendor=sequent
+                               ;;
+                       -vxsim* | -vxworks*)
+                               vendor=wrs
+                               ;;
+                       -aux*)
+                               vendor=apple
+                               ;;
+               esac
+               basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
+               ;;
+esac
+
+echo $basic_machine$os
diff --git a/xlockmore-4.14/configure b/xlockmore-4.14/configure
new file mode 100755 (executable)
index 0000000..89d8608
--- /dev/null
@@ -0,0 +1,7993 @@
+#! /bin/sh
+
+# Guess values for system-dependent variables and create Makefiles.
+# Generated automatically using autoconf version 2.12 
+# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
+#
+# This configure script is free software; the Free Software Foundation
+# gives unlimited permission to copy, distribute and modify it.
+
+# Defaults:
+ac_help=
+ac_default_prefix=/usr/local
+# Any additions from configure.in:
+ac_help="$ac_help
+  --with-purify           configure to postprocess with purify"
+ac_help="$ac_help
+  --with-x                use the X Window System"
+ac_help="$ac_help
+  --with-includes=DIR     search include DIR for optional packages below"
+ac_help="$ac_help
+  --with-libraries=DIR    search library DIR for optional packages below"
+ac_help="$ac_help
+  --without-motif         disable Motif (for xmlock)"
+ac_help="$ac_help
+  --without-athena        disable Athena (for xalock)"
+ac_help="$ac_help
+  --without-sx            disable sx (for xalock)"
+ac_help="$ac_help
+  --without-editres       disable debugger (for x?lock)"
+ac_help="$ac_help
+  --without-xpm           enable color pixmap XPM mode(s)"
+ac_help="$ac_help
+  --without-gltt          disable GL True text library"
+ac_help="$ac_help
+  --without-ttf           enable color pixmap TTF mode(s)"
+ac_help="$ac_help
+  --without-opengl        disable 3D OpenGL (for GL modes)"
+ac_help="$ac_help
+  --without-mesagl        disable 3D MesaGL (for GL modes)"
+ac_help="$ac_help
+  --without-dtsaver       disable -dtsaver option"
+ac_help="$ac_help
+  --without-dpms          disable DPMS"
+ac_help="$ac_help
+  --without-rplay         disable RPLAY sounds"
+ac_help="$ac_help
+  --without-nas           disable NAS sounds"
+ac_help="$ac_help
+  --without-crypt         disable CRYPT"
+ac_help="$ac_help
+  --without-gtk           disable GTK (no xglock build)"
+ac_help="$ac_help
+  --with-gtk-prefix=DIR   Prefix where GTK is installed (optional)"
+ac_help="$ac_help
+  --with-gtk-exec-prefix=DIR 
+                          Exec prefix where GTK is installed (optional)"
+ac_help="$ac_help
+  --disable-gtktest       Do not try to compile and run a test GTK program"
+ac_help="$ac_help
+  --without-gtkfontsel    disable gtkfontsel widget (for xglock)"
+ac_help="$ac_help
+  --enable-bitmapdir=DIR  set directory for bitmaps, default is ./bitmaps"
+ac_help="$ac_help
+  --enable-bitmaptype=name
+                          set name for bitmap type"
+ac_help="$ac_help
+  --enable-pixmapdir=DIR  set directory for pixmaps, default is ./pixmaps"
+ac_help="$ac_help
+  --enable-pixmaptype=name
+                          set name for pixmap type"
+ac_help="$ac_help
+  --enable-mapdir=DIR     set directory for bitmaps and pixmaps"
+ac_help="$ac_help
+  --enable-maptype=name   set name for bitmap and pixmap type"
+ac_help="$ac_help
+  --enable-def-play=program
+                          set def-play to program that plays sounds"
+ac_help="$ac_help
+  --disable-vroot         disables xlock from being able to run in root window
+                          (some window managers have problems)"
+ac_help="$ac_help
+  --disable-allow-root    allows users to turn off allowroot (default is to
+                          always allow root to be able to unlock xlock)"
+ac_help="$ac_help
+  --enable-vtlock         allows to turn on VT switch lock (default is to be
+                          able to switch to another VT)"
+ac_help="$ac_help
+  --enable-syslog         enable syslog logging"
+ac_help="$ac_help
+  --enable-multiple-user  enable multiple users"
+ac_help="$ac_help
+  --enable-multiple-root  enable multiple root users"
+ac_help="$ac_help
+  --enable-window-visibility
+                          allow a window to be displayed over xlock"
+ac_help="$ac_help
+  --enable-old-event-loop some machines may still need this
+                          (fd_set errors may be a sign)"
+ac_help="$ac_help
+  --enable-xlockrc        for unknown shadow passwd algorithm"
+ac_help="$ac_help
+  --enable-auto-logout=time
+                          enable auto-logout code for lab use (time in minutes)"
+ac_help="$ac_help
+  --enable-default-auto-logout=time
+                          set default-auto-logout (time in minutes)"
+ac_help="$ac_help
+  --enable-button-logout=time
+                          enable button logout for lab use (time in minutes)"
+ac_help="$ac_help
+  --enable-default-button-logout=time
+                          set default-button-logout (time in minutes)"
+ac_help="$ac_help
+  --disable-bomb          disable automatic logout mode"
+ac_help="$ac_help
+  --enable-unstable       enables starfish and bubble3d GL mode"
+ac_help="$ac_help
+  --enable-closedown-logout
+                          define this one or next, with enable-auto-logout,"
+ac_help="$ac_help
+  --enable-session-logout enable-button-logout, and/or enable-bomb, for xdm"
+ac_help="$ac_help
+  --enable-staff-file=filename
+                          set file of staff who are exempt from auto-logout"
+ac_help="$ac_help
+  --enable-staff-netgroup=netgroup
+                          set netgroup of staff who are exempt from auto-logout"
+ac_help="$ac_help
+  --enable-kerberos4      enable Kerberos 4"
+ac_help="$ac_help
+  --enable-kerberos5      enable Kerberos 5"
+ac_help="$ac_help
+  --enable-dce-passwd     enable DCE passwording"
+ac_help="$ac_help
+  --enable-pam            enable PAM"
+ac_help="$ac_help
+  --enable-afs            enable AIX AFS"
+ac_help="$ac_help
+  --enable-sunos-adjunct-passwd
+                          enable SUNOS Adjunct passwording"
+ac_help="$ac_help
+  --enable-use-mb         enable Xmb function series (new)"
+ac_help="$ac_help
+  --enable-customization  enable customization of XResource"
+ac_help="$ac_help
+  --enable-modules        enable modules (new and experimental)"
+ac_help="$ac_help
+  --enable-check          enable check (new and experimental)"
+ac_help="$ac_help
+  --with-lang=lang        use a foreign language (nl/fr/de)"
+ac_help="$ac_help
+  --enable-orig-xpm-patch use the original pixmap patch for mail icon
+                          (have colormap problems in 8 bits depth visuals)"
+ac_help="$ac_help
+  --disable-setuid        disables setuid installation if automatically chosen"
+
+# Initialize some variables set by options.
+# The variables have the same names as the options, with
+# dashes changed to underlines.
+build=NONE
+cache_file=./config.cache
+exec_prefix=NONE
+host=NONE
+no_create=
+nonopt=NONE
+no_recursion=
+prefix=NONE
+program_prefix=NONE
+program_suffix=NONE
+program_transform_name=s,x,x,
+silent=
+site=
+srcdir=
+target=NONE
+verbose=
+x_includes=NONE
+x_libraries=NONE
+bindir='${exec_prefix}/bin'
+sbindir='${exec_prefix}/sbin'
+libexecdir='${exec_prefix}/libexec'
+datadir='${prefix}/share'
+sysconfdir='${prefix}/etc'
+sharedstatedir='${prefix}/com'
+localstatedir='${prefix}/var'
+libdir='${exec_prefix}/lib'
+includedir='${prefix}/include'
+oldincludedir='/usr/include'
+infodir='${prefix}/info'
+mandir='${prefix}/man'
+
+# Initialize some other variables.
+subdirs=
+MFLAGS= MAKEFLAGS=
+# Maximum number of lines to put in a shell here document.
+ac_max_here_lines=12
+
+ac_prev=
+for ac_option
+do
+
+  # If the previous option needs an argument, assign it.
+  if test -n "$ac_prev"; then
+    eval "$ac_prev=\$ac_option"
+    ac_prev=
+    continue
+  fi
+
+  case "$ac_option" in
+  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
+  *) ac_optarg= ;;
+  esac
+
+  # Accept the important Cygnus configure options, so we can diagnose typos.
+
+  case "$ac_option" in
+
+  -bindir | --bindir | --bindi | --bind | --bin | --bi)
+    ac_prev=bindir ;;
+  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
+    bindir="$ac_optarg" ;;
+
+  -build | --build | --buil | --bui | --bu)
+    ac_prev=build ;;
+  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
+    build="$ac_optarg" ;;
+
+  -cache-file | --cache-file | --cache-fil | --cache-fi \
+  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
+    ac_prev=cache_file ;;
+  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
+  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
+    cache_file="$ac_optarg" ;;
+
+  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
+    ac_prev=datadir ;;
+  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
+  | --da=*)
+    datadir="$ac_optarg" ;;
+
+  -disable-* | --disable-*)
+    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
+    # Reject names that are not valid shell variable names.
+    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
+      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
+    fi
+    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
+    eval "enable_${ac_feature}=no" ;;
+
+  -enable-* | --enable-*)
+    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
+    # Reject names that are not valid shell variable names.
+    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
+      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
+    fi
+    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
+    case "$ac_option" in
+      *=*) ;;
+      *) ac_optarg=yes ;;
+    esac
+    eval "enable_${ac_feature}='$ac_optarg'" ;;
+
+  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
+  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
+  | --exec | --exe | --ex)
+    ac_prev=exec_prefix ;;
+  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
+  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
+  | --exec=* | --exe=* | --ex=*)
+    exec_prefix="$ac_optarg" ;;
+
+  -gas | --gas | --ga | --g)
+    # Obsolete; use --with-gas.
+    with_gas=yes ;;
+
+  -help | --help | --hel | --he)
+    # Omit some internal or obsolete options to make the list less imposing.
+    # This message is too long to be a string in the A/UX 3.1 sh.
+    cat << EOF
+Usage: configure [options] [host]
+Options: [defaults in brackets after descriptions]
+Configuration:
+  --cache-file=FILE       cache test results in FILE
+  --help                  print this message
+  --no-create             do not create output files
+  --quiet, --silent       do not print \`checking...' messages
+  --version               print the version of autoconf that created configure
+Directory and file names:
+  --prefix=PREFIX         install architecture-independent files in PREFIX
+                          [$ac_default_prefix]
+  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
+                          [same as prefix]
+  --bindir=DIR            user executables in DIR [EPREFIX/bin]
+  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
+  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
+  --datadir=DIR           read-only architecture-independent data in DIR
+                          [PREFIX/share]
+  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
+  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
+                          [PREFIX/com]
+  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
+  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
+  --includedir=DIR        C header files in DIR [PREFIX/include]
+  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
+  --infodir=DIR           info documentation in DIR [PREFIX/info]
+  --mandir=DIR            man documentation in DIR [PREFIX/man]
+  --srcdir=DIR            find the sources in DIR [configure dir or ..]
+  --program-prefix=PREFIX prepend PREFIX to installed program names
+  --program-suffix=SUFFIX append SUFFIX to installed program names
+  --program-transform-name=PROGRAM
+                          run sed PROGRAM on installed program names
+EOF
+    cat << EOF
+Host type:
+  --build=BUILD           configure for building on BUILD [BUILD=HOST]
+  --host=HOST             configure for HOST [guessed]
+  --target=TARGET         configure for TARGET [TARGET=HOST]
+Features and packages:
+  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
+  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
+  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
+  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
+  --x-includes=DIR        X include files are in DIR
+  --x-libraries=DIR       X library files are in DIR
+EOF
+    if test -n "$ac_help"; then
+      echo "--enable and --with options recognized:$ac_help"
+    fi
+    exit 0 ;;
+
+  -host | --host | --hos | --ho)
+    ac_prev=host ;;
+  -host=* | --host=* | --hos=* | --ho=*)
+    host="$ac_optarg" ;;
+
+  -includedir | --includedir | --includedi | --included | --include \
+  | --includ | --inclu | --incl | --inc)
+    ac_prev=includedir ;;
+  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
+  | --includ=* | --inclu=* | --incl=* | --inc=*)
+    includedir="$ac_optarg" ;;
+
+  -infodir | --infodir | --infodi | --infod | --info | --inf)
+    ac_prev=infodir ;;
+  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
+    infodir="$ac_optarg" ;;
+
+  -libdir | --libdir | --libdi | --libd)
+    ac_prev=libdir ;;
+  -libdir=* | --libdir=* | --libdi=* | --libd=*)
+    libdir="$ac_optarg" ;;
+
+  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
+  | --libexe | --libex | --libe)
+    ac_prev=libexecdir ;;
+  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
+  | --libexe=* | --libex=* | --libe=*)
+    libexecdir="$ac_optarg" ;;
+
+  -localstatedir | --localstatedir | --localstatedi | --localstated \
+  | --localstate | --localstat | --localsta | --localst \
+  | --locals | --local | --loca | --loc | --lo)
+    ac_prev=localstatedir ;;
+  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
+  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
+  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
+    localstatedir="$ac_optarg" ;;
+
+  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
+    ac_prev=mandir ;;
+  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
+    mandir="$ac_optarg" ;;
+
+  -nfp | --nfp | --nf)
+    # Obsolete; use --without-fp.
+    with_fp=no ;;
+
+  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
+  | --no-cr | --no-c)
+    no_create=yes ;;
+
+  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
+  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
+    no_recursion=yes ;;
+
+  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
+  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
+  | --oldin | --oldi | --old | --ol | --o)
+    ac_prev=oldincludedir ;;
+  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
+  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
+  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
+    oldincludedir="$ac_optarg" ;;
+
+  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
+    ac_prev=prefix ;;
+  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
+    prefix="$ac_optarg" ;;
+
+  -program-prefix | --program-prefix | --program-prefi | --program-pref \
+  | --program-pre | --program-pr | --program-p)
+    ac_prev=program_prefix ;;
+  -program-prefix=* | --program-prefix=* | --program-prefi=* \
+  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
+    program_prefix="$ac_optarg" ;;
+
+  -program-suffix | --program-suffix | --program-suffi | --program-suff \
+  | --program-suf | --program-su | --program-s)
+    ac_prev=program_suffix ;;
+  -program-suffix=* | --program-suffix=* | --program-suffi=* \
+  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
+    program_suffix="$ac_optarg" ;;
+
+  -program-transform-name | --program-transform-name \
+  | --program-transform-nam | --program-transform-na \
+  | --program-transform-n | --program-transform- \
+  | --program-transform | --program-transfor \
+  | --program-transfo | --program-transf \
+  | --program-trans | --program-tran \
+  | --progr-tra | --program-tr | --program-t)
+    ac_prev=program_transform_name ;;
+  -program-transform-name=* | --program-transform-name=* \
+  | --program-transform-nam=* | --program-transform-na=* \
+  | --program-transform-n=* | --program-transform-=* \
+  | --program-transform=* | --program-transfor=* \
+  | --program-transfo=* | --program-transf=* \
+  | --program-trans=* | --program-tran=* \
+  | --progr-tra=* | --program-tr=* | --program-t=*)
+    program_transform_name="$ac_optarg" ;;
+
+  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
+  | -silent | --silent | --silen | --sile | --sil)
+    silent=yes ;;
+
+  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
+    ac_prev=sbindir ;;
+  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
+  | --sbi=* | --sb=*)
+    sbindir="$ac_optarg" ;;
+
+  -sharedstatedir | --sharedstatedir | --sharedstatedi \
+  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
+  | --sharedst | --shareds | --shared | --share | --shar \
+  | --sha | --sh)
+    ac_prev=sharedstatedir ;;
+  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
+  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
+  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
+  | --sha=* | --sh=*)
+    sharedstatedir="$ac_optarg" ;;
+
+  -site | --site | --sit)
+    ac_prev=site ;;
+  -site=* | --site=* | --sit=*)
+    site="$ac_optarg" ;;
+
+  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
+    ac_prev=srcdir ;;
+  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
+    srcdir="$ac_optarg" ;;
+
+  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
+  | --syscon | --sysco | --sysc | --sys | --sy)
+    ac_prev=sysconfdir ;;
+  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
+  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
+    sysconfdir="$ac_optarg" ;;
+
+  -target | --target | --targe | --targ | --tar | --ta | --t)
+    ac_prev=target ;;
+  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
+    target="$ac_optarg" ;;
+
+  -v | -verbose | --verbose | --verbos | --verbo | --verb)
+    verbose=yes ;;
+
+  -version | --version | --versio | --versi | --vers)
+    echo "configure generated by autoconf version 2.12"
+    exit 0 ;;
+
+  -with-* | --with-*)
+    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
+    # Reject names that are not valid shell variable names.
+    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
+      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
+    fi
+    ac_package=`echo $ac_package| sed 's/-/_/g'`
+    case "$ac_option" in
+      *=*) ;;
+      *) ac_optarg=yes ;;
+    esac
+    eval "with_${ac_package}='$ac_optarg'" ;;
+
+  -without-* | --without-*)
+    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
+    # Reject names that are not valid shell variable names.
+    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
+      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
+    fi
+    ac_package=`echo $ac_package| sed 's/-/_/g'`
+    eval "with_${ac_package}=no" ;;
+
+  --x)
+    # Obsolete; use --with-x.
+    with_x=yes ;;
+
+  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
+  | --x-incl | --x-inc | --x-in | --x-i)
+    ac_prev=x_includes ;;
+  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
+  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
+    x_includes="$ac_optarg" ;;
+
+  -x-libraries | --x-libraries | --x-librarie | --x-librari \
+  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
+    ac_prev=x_libraries ;;
+  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
+  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
+    x_libraries="$ac_optarg" ;;
+
+  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
+    ;;
+
+  *)
+    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
+      echo "configure: warning: $ac_option: invalid host type" 1>&2
+    fi
+    if test "x$nonopt" != xNONE; then
+      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
+    fi
+    nonopt="$ac_option"
+    ;;
+
+  esac
+done
+
+if test -n "$ac_prev"; then
+  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
+fi
+
+trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
+
+# File descriptor usage:
+# 0 standard input
+# 1 file creation
+# 2 errors and warnings
+# 3 some systems may open it to /dev/tty
+# 4 used on the Kubota Titan
+# 6 checking for... messages and results
+# 5 compiler messages saved in config.log
+if test "$silent" = yes; then
+  exec 6>/dev/null
+else
+  exec 6>&1
+fi
+exec 5>./config.log
+
+echo "\
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+" 1>&5
+
+# Strip out --no-create and --no-recursion so they do not pile up.
+# Also quote any args containing shell metacharacters.
+ac_configure_args=
+for ac_arg
+do
+  case "$ac_arg" in
+  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
+  | --no-cr | --no-c) ;;
+  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
+  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
+  *" "*|*"     "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
+  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
+  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
+  esac
+done
+
+# NLS nuisances.
+# Only set these to C if already set.  These must not be set unconditionally
+# because not all systems understand e.g. LANG=C (notably SCO).
+# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
+# Non-C LC_CTYPE values break the ctype check.
+if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
+if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
+if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
+if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
+
+# confdefs.h avoids OS command line length limits that DEFS can exceed.
+rm -rf conftest* confdefs.h
+# AIX cpp loses on an empty file, so make sure it contains at least a newline.
+echo > confdefs.h
+
+# A filename unique to this package, relative to the directory that
+# configure is in, which we can look for to find out if srcdir is correct.
+ac_unique_file=config.h.in
+
+# Find the source files, if location was not specified.
+if test -z "$srcdir"; then
+  ac_srcdir_defaulted=yes
+  # Try the directory containing this script, then its parent.
+  ac_prog=$0
+  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
+  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
+  srcdir=$ac_confdir
+  if test ! -r $srcdir/$ac_unique_file; then
+    srcdir=..
+  fi
+else
+  ac_srcdir_defaulted=no
+fi
+if test ! -r $srcdir/$ac_unique_file; then
+  if test "$ac_srcdir_defaulted" = yes; then
+    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
+  else
+    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
+  fi
+fi
+srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
+
+# Prefer explicitly selected file to automatically selected ones.
+if test -z "$CONFIG_SITE"; then
+  if test "x$prefix" != xNONE; then
+    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+  else
+    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+  fi
+fi
+for ac_site_file in $CONFIG_SITE; do
+  if test -r "$ac_site_file"; then
+    echo "loading site script $ac_site_file"
+    . "$ac_site_file"
+  fi
+done
+
+if test -r "$cache_file"; then
+  echo "loading cache $cache_file"
+  . $cache_file
+else
+  echo "creating cache $cache_file"
+  > $cache_file
+fi
+
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
+  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
+  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
+    ac_n= ac_c='
+' ac_t='       '
+  else
+    ac_n=-n ac_c= ac_t=
+  fi
+else
+  ac_n= ac_c='\c' ac_t=
+fi
+
+
+
+ac_aux_dir=
+for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
+  if test -f $ac_dir/install-sh; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install-sh -c"
+    break
+  elif test -f $ac_dir/install.sh; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install.sh -c"
+    break
+  fi
+done
+if test -z "$ac_aux_dir"; then
+  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
+# Make sure we can run config.sub.
+if $ac_config_sub sun4 >/dev/null 2>&1; then :
+else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking host system type""... $ac_c" 1>&6
+echo "configure:691: checking host system type" >&5
+
+host_alias=$host
+case "$host_alias" in
+NONE)
+  case $nonopt in
+  NONE)
+    if host_alias=`$ac_config_guess`; then :
+    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
+    fi ;;
+  *) host_alias=$nonopt ;;
+  esac ;;
+esac
+
+host=`$ac_config_sub $host_alias`
+host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$host" 1>&6
+
+canonical=$host
+
+# Extract the first word of "gcc", so it can be a program name with args.
+set dummy gcc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:716: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$CC"; then
+  ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
+  for ac_dir in $PATH; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_CC="gcc"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+  echo "$ac_t""$CC" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+if test -z "$CC"; then
+  # Extract the first word of "cc", so it can be a program name with args.
+set dummy cc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:745: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$CC"; then
+  ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
+  ac_prog_rejected=no
+  for ac_dir in $PATH; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
+        ac_prog_rejected=yes
+       continue
+      fi
+      ac_cv_prog_CC="cc"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+if test $ac_prog_rejected = yes; then
+  # We found a bogon in the path, so make sure we never use it.
+  set dummy $ac_cv_prog_CC
+  shift
+  if test $# -gt 0; then
+    # We chose a different compiler from the bogus one.
+    # However, it has the same basename, so the bogon will be chosen
+    # first if we set CC to just the basename; use the full file name.
+    shift
+    set dummy "$ac_dir/$ac_word" "$@"
+    shift
+    ac_cv_prog_CC="$@"
+  fi
+fi
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+  echo "$ac_t""$CC" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
+echo "configure:793: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+cat > conftest.$ac_ext <<EOF
+#line 803 "configure"
+#include "confdefs.h"
+main(){return(0);}
+EOF
+if { (eval echo configure:807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  ac_cv_prog_cc_works=yes
+  # If we can't run a trivial program, we are probably using a cross compiler.
+  if (./conftest; exit) 2>/dev/null; then
+    ac_cv_prog_cc_cross=no
+  else
+    ac_cv_prog_cc_cross=yes
+  fi
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  ac_cv_prog_cc_works=no
+fi
+rm -fr conftest*
+
+echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
+if test $ac_cv_prog_cc_works = no; then
+  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
+fi
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
+echo "configure:827: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
+echo "configure:832: checking whether we are using GNU C" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.c <<EOF
+#ifdef __GNUC__
+  yes;
+#endif
+EOF
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:841: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+  ac_cv_prog_gcc=yes
+else
+  ac_cv_prog_gcc=no
+fi
+fi
+
+echo "$ac_t""$ac_cv_prog_gcc" 1>&6
+
+if test $ac_cv_prog_gcc = yes; then
+  GCC=yes
+  ac_test_CFLAGS="${CFLAGS+set}"
+  ac_save_CFLAGS="$CFLAGS"
+  CFLAGS=
+  echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
+echo "configure:856: checking whether ${CC-cc} accepts -g" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  echo 'void f(){}' > conftest.c
+if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
+  ac_cv_prog_cc_g=yes
+else
+  ac_cv_prog_cc_g=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
+  if test "$ac_test_CFLAGS" = set; then
+    CFLAGS="$ac_save_CFLAGS"
+  elif test $ac_cv_prog_cc_g = yes; then
+    CFLAGS="-g -O2"
+  else
+    CFLAGS="-O2"
+  fi
+else
+  GCC=
+  test "${CFLAGS+set}" = set || CFLAGS="-g"
+fi
+
+for ac_prog in $CCC g++ c++ CC cxx cc++ xlC $CC
+do
+# Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:888: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$CXX"; then
+  ac_cv_prog_CXX="$CXX" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
+  for ac_dir in $PATH; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_CXX="$ac_prog"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+CXX="$ac_cv_prog_CXX"
+if test -n "$CXX"; then
+  echo "$ac_t""$CXX" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+test -n "$CXX" && break
+done
+test -n "$CXX" || CXX="gcc"
+
+for ac_prog in $CCC c++ g++ gcc CC cxx cc++
+do
+# Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:922: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$CXX"; then
+  ac_cv_prog_CXX="$CXX" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
+  for ac_dir in $PATH; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_CXX="$ac_prog"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+CXX="$ac_cv_prog_CXX"
+if test -n "$CXX"; then
+  echo "$ac_t""$CXX" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+test -n "$CXX" && break
+done
+test -n "$CXX" || CXX="gcc"
+
+
+echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
+echo "configure:953: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+
+ac_ext=C
+# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CXXCPP $CPPFLAGS'
+ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CXX-g++} -o conftest $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cxx_cross
+
+cat > conftest.$ac_ext <<EOF
+#line 963 "configure"
+#include "confdefs.h"
+main(){return(0);}
+EOF
+if { (eval echo configure:967: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  ac_cv_prog_cxx_works=yes
+  # If we can't run a trivial program, we are probably using a cross compiler.
+  if (./conftest; exit) 2>/dev/null; then
+    ac_cv_prog_cxx_cross=no
+  else
+    ac_cv_prog_cxx_cross=yes
+  fi
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  ac_cv_prog_cxx_works=no
+fi
+rm -fr conftest*
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
+if test $ac_cv_prog_cxx_works = no; then
+  { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
+fi
+echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
+echo "configure:993: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
+cross_compiling=$ac_cv_prog_cxx_cross
+
+echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
+echo "configure:998: checking whether we are using GNU C++" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.C <<EOF
+#ifdef __GNUC__
+  yes;
+#endif
+EOF
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1007: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+  ac_cv_prog_gxx=yes
+else
+  ac_cv_prog_gxx=no
+fi
+fi
+
+echo "$ac_t""$ac_cv_prog_gxx" 1>&6
+
+if test $ac_cv_prog_gxx = yes; then
+  GXX=yes
+  ac_test_CXXFLAGS="${CXXFLAGS+set}"
+  ac_save_CXXFLAGS="$CXXFLAGS"
+  CXXFLAGS=
+  echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
+echo "configure:1022: checking whether ${CXX-g++} accepts -g" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  echo 'void f(){}' > conftest.cc
+if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
+  ac_cv_prog_cxx_g=yes
+else
+  ac_cv_prog_cxx_g=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
+  if test "$ac_test_CXXFLAGS" = set; then
+    CXXFLAGS="$ac_save_CXXFLAGS"
+  elif test $ac_cv_prog_cxx_g = yes; then
+    CXXFLAGS="-g -O2"
+  else
+    CXXFLAGS="-O2"
+  fi
+else
+  GXX=
+  test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
+fi
+
+if test "${CXX}" = "xlC" ; then
+  CXXFLAGS="${CXXFLAGS} -+"
+fi
+
+cat >> confdefs.h <<\EOF
+#define HAVE_CXX 1
+EOF
+
+CCC=
+
+PACKAGE=xlockmore
+
+cat >> confdefs.h <<EOF
+#define PACKAGE "$PACKAGE"
+EOF
+
+VERSION=4.13
+
+cat >> confdefs.h <<EOF
+#define VERSION "$VERSION"
+EOF
+
+
+
+
+
+opt_purify=no
+# Check whether --with-purify or --without-purify was given.
+if test "${with_purify+set}" = set; then
+  withval="$with_purify"
+  opt_purify=$withval
+fi
+
+if test "$opt_purify" = yes; then
+  echo "$ac_t""enabling purify" 1>&6
+  PURIFY="purify"
+else
+  PURIFY=
+fi
+
+echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
+echo "configure:1090: checking whether ln -s works" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  rm -f conftestdata
+if ln -s X conftestdata 2>/dev/null
+then
+  rm -f conftestdata
+  ac_cv_prog_LN_S="ln -s"
+else
+  ac_cv_prog_LN_S=ln
+fi
+fi
+LN_S="$ac_cv_prog_LN_S"
+if test "$ac_cv_prog_LN_S" = "ln -s"; then
+  echo "$ac_t""yes" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
+echo "configure:1111: checking how to run the C preprocessor" >&5
+# On Suns, sometimes $CPP names a directory.
+if test -n "$CPP" && test -d "$CPP"; then
+  CPP=
+fi
+if test -z "$CPP"; then
+if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+    # This must be in double quotes, not single quotes, because CPP may get
+  # substituted into the Makefile and "${CC-cc}" will confuse make.
+  CPP="${CC-cc} -E"
+  # On the NeXT, cc -E runs the code through the compiler's parser,
+  # not just through cpp.
+  cat > conftest.$ac_ext <<EOF
+#line 1126 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1132: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP="${CC-cc} -E -traditional-cpp"
+  cat > conftest.$ac_ext <<EOF
+#line 1143 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1149: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP=/lib/cpp
+fi
+rm -f conftest*
+fi
+rm -f conftest*
+  ac_cv_prog_CPP="$CPP"
+fi
+  CPP="$ac_cv_prog_CPP"
+else
+  ac_cv_prog_CPP="$CPP"
+fi
+echo "$ac_t""$CPP" 1>&6
+
+echo $ac_n "checking for AIX""... $ac_c" 1>&6
+echo "configure:1172: checking for AIX" >&5
+cat > conftest.$ac_ext <<EOF
+#line 1174 "configure"
+#include "confdefs.h"
+#ifdef _AIX
+  yes
+#endif
+
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "yes" >/dev/null 2>&1; then
+  rm -rf conftest*
+  echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
+#define _ALL_SOURCE 1
+EOF
+
+else
+  rm -rf conftest*
+  echo "$ac_t""no" 1>&6
+fi
+rm -f conftest*
+
+
+# Find a good install program.  We prefer a C program (faster),
+# so one script is as good as another.  But avoid the broken or
+# incompatible versions:
+# SysV /etc/install, /usr/sbin/install
+# SunOS /usr/etc/install
+# IRIX /sbin/install
+# AIX /bin/install
+# AFS /usr/afsws/bin/install, which mishandles nonexistent args
+# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
+# ./install, which can be erroneously created by make from ./install.sh.
+echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
+echo "configure:1206: checking for a BSD compatible install" >&5
+if test -z "$INSTALL"; then
+if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+    IFS="${IFS=        }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
+  for ac_dir in $PATH; do
+    # Account for people who put trailing slashes in PATH elements.
+    case "$ac_dir/" in
+    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
+    *)
+      # OSF1 and SCO ODT 3.0 have their own names for install.
+      for ac_prog in ginstall installbsd scoinst install; do
+        if test -f $ac_dir/$ac_prog; then
+         if test $ac_prog = install &&
+            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
+           # AIX install.  It has an incompatible calling convention.
+           # OSF/1 installbsd also uses dspmsg, but is usable.
+           :
+         else
+           ac_cv_path_install="$ac_dir/$ac_prog -c"
+           break 2
+         fi
+       fi
+      done
+      ;;
+    esac
+  done
+  IFS="$ac_save_IFS"
+
+fi
+  if test "${ac_cv_path_install+set}" = set; then
+    INSTALL="$ac_cv_path_install"
+  else
+    # As a last resort, use the slow shell script.  We don't cache a
+    # path for INSTALL within a source directory, because that will
+    # break other packages using the cache if that directory is
+    # removed, or if the path is relative.
+    INSTALL="$ac_install_sh"
+  fi
+fi
+echo "$ac_t""$INSTALL" 1>&6
+
+# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
+# It thinks the first close brace ends the variable substitution.
+test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
+
+test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
+echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
+echo "configure:1256: checking whether ${MAKE-make} sets \${MAKE}" >&5
+set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftestmake <<\EOF
+all:
+       @echo 'ac_maketemp="${MAKE}"'
+EOF
+# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
+if test -n "$ac_maketemp"; then
+  eval ac_cv_prog_make_${ac_make}_set=yes
+else
+  eval ac_cv_prog_make_${ac_make}_set=no
+fi
+rm -f conftestmake
+fi
+if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  SET_MAKE=
+else
+  echo "$ac_t""no" 1>&6
+  SET_MAKE="MAKE=${MAKE-make}"
+fi
+
+ac_link_test="-L"
+# test test
+echo $ac_n "checking test -h""... $ac_c" 1>&6
+echo "configure:1285: checking test -h" >&5
+if (test \! -h /) >/dev/null 2>/dev/null ; then
+  ac_link_test="-h"
+  echo "$ac_t""$ac_link_test" 1>&6
+else
+  echo "$ac_t""$ac_link_test" 1>&6
+fi
+
+
+echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
+echo "configure:1295: checking for POSIXized ISC" >&5
+if test -d /etc/conf/kconfig.d &&
+  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
+then
+  echo "$ac_t""yes" 1>&6
+  ISC=yes # If later tests want to check for ISC.
+  cat >> confdefs.h <<\EOF
+#define _POSIX_SOURCE 1
+EOF
+
+  if test "$GCC" = yes; then
+    CC="$CC -posix"
+  else
+    CC="$CC -Xp"
+  fi
+else
+  echo "$ac_t""no" 1>&6
+  ISC=
+fi
+
+for ac_hdr in fcntl.h limits.h sys/select.h sys/time.h syslog.h unistd.h memory.h sys/param.h
+do
+ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+echo "configure:1319: checking for $ac_hdr" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1324 "configure"
+#include "confdefs.h"
+#include <$ac_hdr>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1329: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=yes"
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_hdr 1
+EOF
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+
+
+echo $ac_n "checking for working const""... $ac_c" 1>&6
+echo "configure:1357: checking for working const" >&5
+if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1362 "configure"
+#include "confdefs.h"
+
+int main() {
+
+/* Ultrix mips cc rejects this.  */
+typedef int charset[2]; const charset x;
+/* SunOS 4.1.1 cc rejects this.  */
+char const *const *ccp;
+char **p;
+/* NEC SVR4.0.2 mips cc rejects this.  */
+struct point {int x, y;};
+static struct point const zero = {0,0};
+/* AIX XL C 1.02.0.0 rejects this.
+   It does not let you subtract one const X* pointer from another in an arm
+   of an if-expression whose if-part is not a constant expression */
+const char *g = "string";
+ccp = &g + (g ? g-g : 0);
+/* HPUX 7.0 cc rejects these. */
+++ccp;
+p = (char**) ccp;
+ccp = (char const *const *) p;
+{ /* SCO 3.2v4 cc rejects this.  */
+  char *t;
+  char const *s = 0 ? (char *) 0 : (char const *) 0;
+
+  *t++ = 0;
+}
+{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
+  int x[] = {25, 17};
+  const int *foo = &x[0];
+  ++foo;
+}
+{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
+  typedef const int *iptr;
+  iptr p = 0;
+  ++p;
+}
+{ /* AIX XL C 1.02.0.0 rejects this saying
+     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
+  struct s { int j; const int *ap[3]; };
+  struct s *b; b->j = 5;
+}
+{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
+  const int foo = 10;
+}
+
+; return 0; }
+EOF
+if { (eval echo configure:1411: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_c_const=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_c_const=no
+fi
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_c_const" 1>&6
+if test $ac_cv_c_const = no; then
+  cat >> confdefs.h <<\EOF
+#define const 
+EOF
+
+fi
+
+echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
+echo "configure:1432: checking for ANSI C header files" >&5
+if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1437 "configure"
+#include "confdefs.h"
+#include <stdlib.h>
+#include <stdarg.h>
+#include <string.h>
+#include <float.h>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1445: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  ac_cv_header_stdc=yes
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_header_stdc=no
+fi
+rm -f conftest*
+
+if test $ac_cv_header_stdc = yes; then
+  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
+cat > conftest.$ac_ext <<EOF
+#line 1462 "configure"
+#include "confdefs.h"
+#include <string.h>
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "memchr" >/dev/null 2>&1; then
+  :
+else
+  rm -rf conftest*
+  ac_cv_header_stdc=no
+fi
+rm -f conftest*
+
+fi
+
+if test $ac_cv_header_stdc = yes; then
+  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
+cat > conftest.$ac_ext <<EOF
+#line 1480 "configure"
+#include "confdefs.h"
+#include <stdlib.h>
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "free" >/dev/null 2>&1; then
+  :
+else
+  rm -rf conftest*
+  ac_cv_header_stdc=no
+fi
+rm -f conftest*
+
+fi
+
+if test $ac_cv_header_stdc = yes; then
+  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
+if test "$cross_compiling" = yes; then
+  :
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1501 "configure"
+#include "confdefs.h"
+#include <ctype.h>
+#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
+#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
+int main () { int i; for (i = 0; i < 256; i++)
+if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
+exit (0); }
+
+EOF
+if { (eval echo configure:1512: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+then
+  :
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -fr conftest*
+  ac_cv_header_stdc=no
+fi
+rm -fr conftest*
+fi
+
+fi
+fi
+
+echo "$ac_t""$ac_cv_header_stdc" 1>&6
+if test $ac_cv_header_stdc = yes; then
+  cat >> confdefs.h <<\EOF
+#define STDC_HEADERS 1
+EOF
+
+fi
+
+echo $ac_n "checking for mode_t""... $ac_c" 1>&6
+echo "configure:1536: checking for mode_t" >&5
+if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1541 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+#if STDC_HEADERS
+#include <stdlib.h>
+#include <stddef.h>
+#endif
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
+  rm -rf conftest*
+  ac_cv_type_mode_t=yes
+else
+  rm -rf conftest*
+  ac_cv_type_mode_t=no
+fi
+rm -f conftest*
+
+fi
+echo "$ac_t""$ac_cv_type_mode_t" 1>&6
+if test $ac_cv_type_mode_t = no; then
+  cat >> confdefs.h <<\EOF
+#define mode_t int
+EOF
+
+fi
+
+echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
+echo "configure:1569: checking for uid_t in sys/types.h" >&5
+if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1574 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "uid_t" >/dev/null 2>&1; then
+  rm -rf conftest*
+  ac_cv_type_uid_t=yes
+else
+  rm -rf conftest*
+  ac_cv_type_uid_t=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_type_uid_t" 1>&6
+if test $ac_cv_type_uid_t = no; then
+  cat >> confdefs.h <<\EOF
+#define uid_t int
+EOF
+
+  cat >> confdefs.h <<\EOF
+#define gid_t int
+EOF
+
+fi
+
+echo $ac_n "checking for pid_t""... $ac_c" 1>&6
+echo "configure:1603: checking for pid_t" >&5
+if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1608 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+#if STDC_HEADERS
+#include <stdlib.h>
+#include <stddef.h>
+#endif
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
+  rm -rf conftest*
+  ac_cv_type_pid_t=yes
+else
+  rm -rf conftest*
+  ac_cv_type_pid_t=no
+fi
+rm -f conftest*
+
+fi
+echo "$ac_t""$ac_cv_type_pid_t" 1>&6
+if test $ac_cv_type_pid_t = no; then
+  cat >> confdefs.h <<\EOF
+#define pid_t int
+EOF
+
+fi
+
+echo $ac_n "checking for size_t""... $ac_c" 1>&6
+echo "configure:1636: checking for size_t" >&5
+if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1641 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+#if STDC_HEADERS
+#include <stdlib.h>
+#include <stddef.h>
+#endif
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
+  rm -rf conftest*
+  ac_cv_type_size_t=yes
+else
+  rm -rf conftest*
+  ac_cv_type_size_t=no
+fi
+rm -f conftest*
+
+fi
+echo "$ac_t""$ac_cv_type_size_t" 1>&6
+if test $ac_cv_type_size_t = no; then
+  cat >> confdefs.h <<\EOF
+#define size_t unsigned
+EOF
+
+fi
+
+echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
+echo "configure:1669: checking whether time.h and sys/time.h may both be included" >&5
+if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1674 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+#include <sys/time.h>
+#include <time.h>
+int main() {
+struct tm *tp;
+; return 0; }
+EOF
+if { (eval echo configure:1683: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_header_time=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_header_time=no
+fi
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_header_time" 1>&6
+if test $ac_cv_header_time = yes; then
+  cat >> confdefs.h <<\EOF
+#define TIME_WITH_SYS_TIME 1
+EOF
+
+fi
+
+echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
+echo "configure:1704: checking whether struct tm is in sys/time.h or time.h" >&5
+if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1709 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+#include <time.h>
+int main() {
+struct tm *tp; tp->tm_sec;
+; return 0; }
+EOF
+if { (eval echo configure:1717: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_struct_tm=time.h
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_struct_tm=sys/time.h
+fi
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_struct_tm" 1>&6
+if test $ac_cv_struct_tm = sys/time.h; then
+  cat >> confdefs.h <<\EOF
+#define TM_IN_SYS_TIME 1
+EOF
+
+fi
+
+
+for ac_func in gethostname select strdup
+do
+echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
+echo "configure:1741: checking for $ac_func" >&5
+if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1746 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char $ac_func();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+$ac_func();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:1769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_func 1
+EOF
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+
+
+echo $ac_n "checking for vfork""... $ac_c" 1>&6
+echo "configure:1795: checking for vfork" >&5
+if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1800 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char vfork(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char vfork();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_vfork) || defined (__stub___vfork)
+choke me
+#else
+vfork();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:1823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_vfork=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_vfork=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'vfork`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_VFORK 1
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+echo $ac_n "checking for seteuid""... $ac_c" 1>&6
+echo "configure:1846: checking for seteuid" >&5
+if eval "test \"`echo '$''{'ac_cv_func_seteuid'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1851 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char seteuid(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char seteuid();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_seteuid) || defined (__stub___seteuid)
+choke me
+#else
+seteuid();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:1874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_seteuid=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_seteuid=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'seteuid`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_SETEUID 1
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+echo $ac_n "checking for setreuid""... $ac_c" 1>&6
+echo "configure:1895: checking for setreuid" >&5
+if eval "test \"`echo '$''{'ac_cv_func_setreuid'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1900 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char setreuid(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char setreuid();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_setreuid) || defined (__stub___setreuid)
+choke me
+#else
+setreuid();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:1923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_setreuid=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_setreuid=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'setreuid`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_SETREUID 1
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+fi
+
+
+
+# Configure paths for GTK+
+# Owen Taylor     97-11-3
+
+
+
+# If we find X, set shell vars x_includes and x_libraries to the
+# paths, otherwise set no_x=yes.
+# Uses ac_ vars as temps to allow command line to override cache and checks.
+# --without-x overrides everything else, but does not touch the cache.
+echo $ac_n "checking for X""... $ac_c" 1>&6
+echo "configure:1959: checking for X" >&5
+
+# Check whether --with-x or --without-x was given.
+if test "${with_x+set}" = set; then
+  withval="$with_x"
+  :
+fi
+
+# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
+if test "x$with_x" = xno; then
+  # The user explicitly disabled X.
+  have_x=disabled
+else
+  if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
+    # Both variables are already set.
+    have_x=yes
+  else
+if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of the vars are not set, and there is no cached value.
+ac_x_includes=NO ac_x_libraries=NO
+rm -fr conftestdir
+if mkdir conftestdir; then
+  cd conftestdir
+  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
+  cat > Imakefile <<'EOF'
+acfindx:
+       @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
+EOF
+  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
+    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+    eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
+    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
+    for ac_extension in a so sl; do
+      if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
+        test -f $ac_im_libdir/libX11.$ac_extension; then
+        ac_im_usrlibdir=$ac_im_libdir; break
+      fi
+    done
+    # Screen out bogus values from the imake configuration.  They are
+    # bogus both because they are the default anyway, and because
+    # using them would break gcc on systems where it needs fixed includes.
+    case "$ac_im_incroot" in
+       /usr/include) ;;
+       *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
+    esac
+    case "$ac_im_usrlibdir" in
+       /usr/lib | /lib) ;;
+       *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
+    esac
+  fi
+  cd ..
+  rm -fr conftestdir
+fi
+
+if test "$ac_x_includes" = NO; then
+  # Guess where to find include files, by looking for this one X11 .h file.
+  test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
+
+  # First, try using that file with no special directory specified.
+cat > conftest.$ac_ext <<EOF
+#line 2021 "configure"
+#include "confdefs.h"
+#include <$x_direct_test_include>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:2026: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  # We can compile using X headers with no special include directory.
+ac_x_includes=
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  # Look for the header file in a standard set of common directories.
+# Check X11 before X11Rn because it is often a symlink to the current release.
+  for ac_dir in               \
+    /usr/X11/include          \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/include              \
+    /usr/local/include        \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    ; \
+  do
+    if test -r "$ac_dir/$x_direct_test_include"; then
+      ac_x_includes=$ac_dir
+      break
+    fi
+  done
+fi
+rm -f conftest*
+fi # $ac_x_includes = NO
+
+if test "$ac_x_libraries" = NO; then
+  # Check for the libraries.
+
+  test -z "$x_direct_test_library" && x_direct_test_library=Xt
+  test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
+
+  # See if we find them without any special options.
+  # Don't add to $LIBS permanently.
+  ac_save_LIBS="$LIBS"
+  LIBS="-l$x_direct_test_library $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2095 "configure"
+#include "confdefs.h"
+
+int main() {
+${x_direct_test_function}()
+; return 0; }
+EOF
+if { (eval echo configure:2102: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  LIBS="$ac_save_LIBS"
+# We can link X programs with no special library path.
+ac_x_libraries=
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  LIBS="$ac_save_LIBS"
+# First see if replacing the include by lib works.
+# Check X11 before X11Rn because it is often a symlink to the current release.
+for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
+    /usr/X11/lib          \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11     \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
+      ac_x_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+fi
+rm -f conftest*
+fi # $ac_x_libraries = NO
+
+if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
+  # Didn't find X anywhere.  Cache the known absence of X.
+  ac_cv_have_x="have_x=no"
+else
+  # Record where we found X for the cache.
+  ac_cv_have_x="have_x=yes \
+               ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_have_x"
+fi # $with_x != no
+
+if test "$have_x" != yes; then
+  echo "$ac_t""$have_x" 1>&6
+  no_x=yes
+else
+  # If each of the values was on the command line, it overrides each guess.
+  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
+  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
+  # Update the cache value to reflect the command line values.
+  ac_cv_have_x="have_x=yes \
+               ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
+  echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
+fi
+
+if test "$no_x" = yes; then
+  # Not all programs may use this symbol, but it does not hurt to define it.
+  cat >> confdefs.h <<\EOF
+#define X_DISPLAY_MISSING 1
+EOF
+
+  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
+else
+  if test -n "$x_includes"; then
+    X_CFLAGS="$X_CFLAGS -I$x_includes"
+  fi
+
+  # It would also be nice to do this for all -L options, not just this one.
+  if test -n "$x_libraries"; then
+    X_LIBS="$X_LIBS -L$x_libraries"
+    # For Solaris; some versions of Sun CC require a space after -R and
+    # others require no space.  Words are not sufficient . . . .
+    case "`(uname -sr) 2>/dev/null`" in
+    "SunOS 5"*)
+      echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
+echo "configure:2208: checking whether -R must be followed by a space" >&5
+      ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
+      cat > conftest.$ac_ext <<EOF
+#line 2211 "configure"
+#include "confdefs.h"
+
+int main() {
+
+; return 0; }
+EOF
+if { (eval echo configure:2218: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  ac_R_nospace=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_R_nospace=no
+fi
+rm -f conftest*
+      if test $ac_R_nospace = yes; then
+       echo "$ac_t""no" 1>&6
+       X_LIBS="$X_LIBS -R$x_libraries"
+      else
+       LIBS="$ac_xsave_LIBS -R $x_libraries"
+       cat > conftest.$ac_ext <<EOF
+#line 2234 "configure"
+#include "confdefs.h"
+
+int main() {
+
+; return 0; }
+EOF
+if { (eval echo configure:2241: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  ac_R_space=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_R_space=no
+fi
+rm -f conftest*
+       if test $ac_R_space = yes; then
+         echo "$ac_t""yes" 1>&6
+         X_LIBS="$X_LIBS -R $x_libraries"
+       else
+         echo "$ac_t""neither works" 1>&6
+       fi
+      fi
+      LIBS="$ac_xsave_LIBS"
+    esac
+  fi
+
+  # Check for system-dependent libraries X programs must link with.
+  # Do this before checking for the system-independent R6 libraries
+  # (-lICE), since we may need -lsocket or whatever for X linking.
+
+  if test "$ISC" = yes; then
+    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
+  else
+    # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
+    # libraries were built with DECnet support.  And karl@cs.umb.edu says
+    # the Alpha needs dnet_stub (dnet does not exist).
+    echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
+echo "configure:2273: checking for dnet_ntoa in -ldnet" >&5
+ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-ldnet  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2281 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char dnet_ntoa();
+
+int main() {
+dnet_ntoa()
+; return 0; }
+EOF
+if { (eval echo configure:2292: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
+      echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
+echo "configure:2314: checking for dnet_ntoa in -ldnet_stub" >&5
+ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-ldnet_stub  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2322 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char dnet_ntoa();
+
+int main() {
+dnet_ntoa()
+; return 0; }
+EOF
+if { (eval echo configure:2333: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    fi
+
+    # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
+    # to get the SysV transport functions.
+    # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4)
+    # needs -lnsl.
+    # The nsl library prevents programs from opening the X display
+    # on Irix 5.2, according to dickey@clark.net.
+    echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
+echo "configure:2362: checking for gethostbyname" >&5
+if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2367 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char gethostbyname(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char gethostbyname();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
+choke me
+#else
+gethostbyname();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:2390: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_gethostbyname=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_gethostbyname=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  :
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    if test $ac_cv_func_gethostbyname = no; then
+      echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
+echo "configure:2411: checking for gethostbyname in -lnsl" >&5
+ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lnsl  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2419 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char gethostbyname();
+
+int main() {
+gethostbyname()
+; return 0; }
+EOF
+if { (eval echo configure:2430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    fi
+
+    # lieder@skyler.mavd.honeywell.com says without -lsocket,
+    # socket/setsockopt and other routines are undefined under SCO ODT
+    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
+    # on later versions), says simon@lia.di.epfl.ch: it contains
+    # gethostby* variants that don't use the nameserver (or something).
+    # -lsocket must be given before -lnsl if both are needed.
+    # We assume that if connect needs -lnsl, so does gethostbyname.
+    echo $ac_n "checking for connect""... $ac_c" 1>&6
+echo "configure:2460: checking for connect" >&5
+if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2465 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char connect(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char connect();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_connect) || defined (__stub___connect)
+choke me
+#else
+connect();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:2488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_connect=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_connect=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  :
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    if test $ac_cv_func_connect = no; then
+      echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
+echo "configure:2509: checking for connect in -lsocket" >&5
+ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2517 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char connect();
+
+int main() {
+connect()
+; return 0; }
+EOF
+if { (eval echo configure:2528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    fi
+
+    # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
+    echo $ac_n "checking for remove""... $ac_c" 1>&6
+echo "configure:2552: checking for remove" >&5
+if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2557 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char remove(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char remove();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_remove) || defined (__stub___remove)
+choke me
+#else
+remove();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:2580: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_remove=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_remove=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  :
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    if test $ac_cv_func_remove = no; then
+      echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
+echo "configure:2601: checking for remove in -lposix" >&5
+ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lposix  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2609 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char remove();
+
+int main() {
+remove()
+; return 0; }
+EOF
+if { (eval echo configure:2620: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    fi
+
+    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
+    echo $ac_n "checking for shmat""... $ac_c" 1>&6
+echo "configure:2644: checking for shmat" >&5
+if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2649 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char shmat(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char shmat();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_shmat) || defined (__stub___shmat)
+choke me
+#else
+shmat();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:2672: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_shmat=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_shmat=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  :
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    if test $ac_cv_func_shmat = no; then
+      echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
+echo "configure:2693: checking for shmat in -lipc" >&5
+ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lipc  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2701 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char shmat();
+
+int main() {
+shmat()
+; return 0; }
+EOF
+if { (eval echo configure:2712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    fi
+  fi
+
+  # Check for libraries that X11R6 Xt/Xaw programs need.
+  ac_save_LDFLAGS="$LDFLAGS"
+  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
+  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
+  # check for ICE first), but we must link in the order -lSM -lICE or
+  # we get undefined symbols.  So assume we have SM if we have ICE.
+  # These have to be linked with before -lX11, unlike the other
+  # libraries we check for below, so use a different variable.
+  #  --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
+  echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
+echo "configure:2745: checking for IceConnectionNumber in -lICE" >&5
+ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lICE  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2753 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char IceConnectionNumber();
+
+int main() {
+IceConnectionNumber()
+; return 0; }
+EOF
+if { (eval echo configure:2764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+  LDFLAGS="$ac_save_LDFLAGS"
+
+fi
+
+if test "$no_x" = yes; then
+  XLIBS=NONE
+else
+  if test -n "${x_includes}"; then
+    XLOCKINC="-I${x_includes} ${XLOCKINC}"
+    XMLOCKINC="-I${x_includes} ${XMLOCKINC}"
+    XALOCKINC="-I${x_includes} ${XALOCKINC}"
+  fi
+  XLIBS="${x_libraries}"
+  if test -n "${x_libraries}"; then
+    XLOCK_LDFLAGS="/usr/lib:${x_libraries}"
+    XMLOCK_LDFLAGS="/usr/lib:${x_libraries}"
+    XALOCK_LDFLAGS="/usr/lib:${x_libraries}"
+    XLOCKLIBPATHS="-L${x_libraries} ${XLOCKLIBPATHS}"
+    XMLOCKLIBPATHS="-L${x_libraries} ${XMLOCKLIBPATHS}"
+    XALOCKLIBPATHS="-L${x_libraries} ${XALOCKLIBPATHS}"
+  fi
+  XLOCKLIBS="${X_PRE_LIBS} ${X_EXTRA_LIBS} ${XLOCKLIBS}"
+  XMLOCKLIBS="-lXt ${XMLOCKLIBS}"
+#  if you need regex and regcmp
+#  XMLOCKLIBS="-lXt ${XMLOCKLIBS} -lgen"
+  XALOCKLIBS="-lXt ${XALOCKLIBS}"
+fi
+
+# Try and find the app-defaults directory.
+
+
+
+
+
+
+
+
+    echo $ac_n "checking for X app-defaults directory""... $ac_c" 1>&6
+echo "configure:2822: checking for X app-defaults directory" >&5
+if eval "test \"`echo '$''{'ac_cv_x_app_defaults'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+  rm -fr conftestdir
+  if mkdir conftestdir; then
+    cd conftestdir
+    # Make sure to not put "make" in the Imakefile rules, since we grep it out.
+    cat > Imakefile <<'EOF'
+acfindx:
+  @echo 'ac_x_app_defaults="${XAPPLOADDIR}"'
+EOF
+    if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
+      # GNU make sometimes prints "make[1]: Entering...", which'd confuse us.
+      eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
+    fi
+    cd ..
+    rm -fr conftestdir
+  fi
+        # Look for the directory under a standard set of common directories.
+  # Check X11 before X11Rn because it's often a symlink to the current release.
+  for ac_dir in         \
+    /lib/X11/app-defaults \
+    /lib/app-defaults \
+    /lib/X11R6.3/app-defaults \
+    /lib/X11R6.3/X11/app-defaults \
+    /lib/X11R6.2/app-defaults \
+    /lib/X11R6.2/X11/app-defaults \
+    /lib/X11R6.1/app-defaults \
+    /lib/X11R6.1/X11/app-defaults \
+    /lib/X11R6/app-defaults \
+    /lib/X11R6/X11/app-defaults \
+    /lib/X11R5/app-defaults \
+    /lib/X11R5/X11/app-defaults \
+    /lib/X11R4/app-defaults \
+    /lib/X11R4/X11/app-defaults \
+    ; \
+  do
+    found=""
+    if test -d "${prefix}$ac_dir"; then
+      ac_x_app_defaults=\\\$\\\{prefix\\\}$ac_dir
+    found="1"
+      break
+    fi
+  done
+  if test -z "$found"; then
+  for ac_dir in         \
+    /usr/X11/lib/app-defaults     \
+    /usr/X11R6.3/lib/app-defaults     \
+    /usr/X11R6.3/lib/X11/app-defaults   \
+    /usr/X11R6.2/lib/app-defaults     \
+    /usr/X11R6.2/lib/X11/app-defaults   \
+    /usr/X11R6.1/lib/app-defaults     \
+    /usr/X11R6.1/lib/X11/app-defaults   \
+    /usr/X11R6/lib/app-defaults     \
+    /usr/X11R6/lib/X11/app-defaults   \
+    /usr/X11R5/lib/app-defaults     \
+    /usr/X11R5/lib/X11/app-defaults   \
+    /usr/X11R4/lib/app-defaults     \
+    /usr/X11R4/lib/X11/app-defaults   \
+            \
+    /usr/lib/X11/app-defaults     \
+    /usr/lib/X11R6.3/app-defaults     \
+    /usr/lib/X11R6.2/app-defaults     \
+    /usr/lib/X11R6.1/app-defaults     \
+    /usr/lib/X11R6/app-defaults     \
+    /usr/lib/X11R5/app-defaults     \
+    /usr/lib/X11R4/app-defaults     \
+            \
+    /usr/local/X11/lib/app-defaults   \
+    /usr/remote/X11/lib/app-defaults   \
+    /usr/local/X11R6.3/lib/app-defaults   \
+    /usr/local/X11R6.3/lib/X11/app-defaults   \
+    /usr/local/X11R6.2/lib/app-defaults   \
+    /usr/local/X11R6.2/lib/X11/app-defaults   \
+    /usr/local/X11R6.1/lib/app-defaults   \
+    /usr/local/X11R6.1/lib/X11/app-defaults   \
+    /usr/local/X11R6/lib/app-defaults   \
+    /usr/local/X11R6/lib/X11/app-defaults   \
+    /usr/local/X11R5/lib/app-defaults   \
+    /usr/local/X11R5/lib/X11/app-defaults   \
+    /usr/local/X11R4/lib/app-defaults   \
+    /usr/local/X11R4/lib/X11/app-defaults   \
+            \
+    /usr/local/lib/X11/app-defaults   \
+    /usr/remote/lib/X11/app-defaults   \
+    /usr/local/lib/X11R6.3/app-defaults   \
+    /usr/local/lib/X11R6.3/X11/app-defaults \
+    /usr/local/lib/X11R6.2/app-defaults   \
+    /usr/local/lib/X11R6.2/X11/app-defaults \
+    /usr/local/lib/X11R6.1/app-defaults   \
+    /usr/local/lib/X11R6.1/X11/app-defaults \
+    /usr/local/lib/X11R6/app-defaults   \
+    /usr/local/lib/X11R6/X11/app-defaults \
+    /usr/local/lib/X11R5/app-defaults   \
+    /usr/local/lib/X11R5/X11/app-defaults \
+    /usr/local/lib/X11R4/app-defaults   \
+    /usr/local/lib/X11R4/X11/app-defaults \
+            \
+    /usr/X386/lib/X11/app-defaults    \
+    /usr/x386/lib/X11/app-defaults    \
+    /usr/XFree86/lib/X11/app-defaults   \
+            \
+    /usr/lib/X11/app-defaults     \
+    /usr/unsupported/lib/X11/app-defaults \
+    /usr/athena/lib/X11/app-defaults    \
+    /usr/local/x11r5/lib/X11/app-defaults \
+    /usr/lpp/Xamples/lib/X11/app-defaults \
+    /lib/usr/lib/X11/app-defaults   \
+    /usr/local/lib/app-defaults   \
+    /usr/remote/lib/app-defaults   \
+            \
+    /usr/openwin/lib/app-defaults   \
+    /usr/openwin/lib/X11/app-defaults   \
+    /usr/openwin/share/lib/app-defaults   \
+    /usr/openwin/share/lib/X11/app-defaults \
+            \
+    /X11R6.3/lib/app-defaults     \
+    /X11R6.2/lib/app-defaults     \
+    /X11R6.1/lib/app-defaults     \
+    /X11R6/lib/app-defaults     \
+    /X11R5/lib/app-defaults     \
+    /X11R4/lib/app-defaults     \
+    ; \
+  do
+    if test -d "$ac_dir"; then
+      ac_x_app_defaults=$ac_dir
+      break
+    fi
+  done
+    fi
+
+      if test x"$ac_x_app_defaults" = x; then
+        ac_cv_x_app_defaults="/usr/lib/X11/app-defaults"
+      else
+        # Record where we found app-defaults for the cache.
+        ac_cv_x_app_defaults="$ac_x_app_defaults"
+      fi
+fi
+
+echo "$ac_t""$ac_cv_x_app_defaults" 1>&6
+    eval ac_x_app_defaults="$ac_cv_x_app_defaults"
+
+APPDEFAULTS=$ac_x_app_defaults
+
+# Check whether --with-includes or --without-includes was given.
+if test "${with_includes+set}" = set; then
+  withval="$with_includes"
+  :
+fi
+
+case "x$withval" in
+x/*|x.*)
+  extra_include=$withval
+  echo "$ac_t""adding $extra_include to include search path for following packages" 1>&6
+  if test ! -d $extra_include; then
+    echo "$ac_t""Warning: Directory $extra_include does not exist" 1>&6
+  fi
+  ;;
+*)
+  extra_include=""
+  ;;
+esac
+
+# Check whether --with-libraries or --without-libraries was given.
+if test "${with_libraries+set}" = set; then
+  withval="$with_libraries"
+  :
+fi
+
+case "x$withval" in
+x/*|x.*)
+  extra_lib=$withval
+  echo "$ac_t""adding $extra_lib to library search path for following packages" 1>&6
+  if test ! -d $extra_lib; then
+    echo "$ac_t""Warning: Directory $extra_lib does not exist" 1>&6
+  fi
+  ;;
+*)
+  extra_lib=""
+  ;;
+esac
+
+
+
+
+
+
+motif_includes=NONE
+motif_libraries=NONE
+
+echo $ac_n "checking for Motif""... $ac_c" 1>&6
+echo "configure:3015: checking for Motif" >&5
+# Check whether --with-motif or --without-motif was given.
+if test "${with_motif+set}" = set; then
+  withval="$with_motif"
+  :
+fi
+
+if test "x$with_motif" = xno; then
+  no_motif=yes
+else
+  if test "x$motif_includes" != xNONE && test "x$motif_libraries" != xNONE; then
+    no_motif=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_motif'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_motif=yes
+test -z "$motif_direct_test_library" && motif_direct_test_library=Xm
+test -z "$motif_direct_test_function" && motif_direct_test_function=XmCreatePushButton
+test -z "$motif_direct_test_include" && motif_direct_test_include=Xm/Xm.h
+  for ac_dir in               \
+    /usr/include/Motif1.2     \
+    /usr/Motif1.2/include     \
+                              \
+    /usr/motif/include        \
+                              \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$motif_direct_test_include"; then
+      no_motif= ac_motif_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$motif_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_motif_includes" | sed s/include/lib/` \
+    /usr/lib/Motif1.2     \
+    /usr/Motif1.2/lib     \
+                          \
+    /usr/motif/lib        \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${motif_direct_test_library}.$ac_extension; then
+      no_motif= ac_motif_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_motif" = yes; then
+  ac_cv_path_motif="no_motif=yes"
+else
+  ac_cv_path_motif="no_motif= ac_motif_includes=$ac_motif_includes ac_motif_libraries=$ac_motif_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_motif"
+fi # with_motif != no
+
+if test "$no_motif" = yes; then
+  echo "$ac_t""no" 1>&6
+  XMLOCK=""
+  INSTALL_XMLOCK=""
+  UNINSTALL_XMLOCK=""
+else
+  XMLOCKLIBS="-lXm ${XMLOCKLIBS}"
+  XMLOCK="xmlock"
+  INSTALL_XMLOCK="install_xmlock"
+  UNINSTALL_XMLOCK="uninstall_xmlock"
+  test "x$motif_includes" = xNONE && motif_includes=$ac_motif_includes
+  test "x$motif_libraries" = xNONE && motif_libraries=$ac_motif_libraries
+  ac_cv_path_motif="no_motif= ac_motif_includes=$motif_includes ac_motif_libraries=$motif_libraries"
+  echo "$ac_t""libraries $motif_libraries, headers $motif_includes" 1>&6
+fi
+
+
+if test "x$motif_libraries" != x && test "x$motif_libraries" != xNONE ; then
+  XMLOCK_LDFLAGS="${XMLOCK_LDFLAGS}:$motif_libraries"
+  XMLOCKLIBPATHS="${XMLOCKLIBPATHS} -L$motif_libraries"
+fi
+if test "x$motif_includes" != x && test "x$motif_includes" != xNONE ; then
+  XMLOCKINC="${XMLOCKINC} -I$motif_includes"
+fi
+
+
+
+
+
+
+athena_includes=NONE
+athena_libraries=NONE
+
+echo $ac_n "checking for Athena""... $ac_c" 1>&6
+echo "configure:3208: checking for Athena" >&5
+# Check whether --with-athena or --without-athena was given.
+if test "${with_athena+set}" = set; then
+  withval="$with_athena"
+  :
+fi
+
+if test "x$with_athena" = xno; then
+  no_athena=yes
+else
+  if test "x$athena_includes" != xNONE && test "x$athena_libraries" != xNONE; then
+    no_athena=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_athena'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_athena=yes
+test -z "$athena_direct_test_library" && athena_direct_test_library=Xaw
+test -z "$athena_direct_test_function" && athena_direct_test_function=XawInitializeWidgetSet
+test -z "$athena_direct_test_include" && athena_direct_test_include=X11/Xaw/XawInit.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$athena_direct_test_include"; then
+      no_athena= ac_athena_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$athena_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_athena_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${athena_direct_test_library}.$ac_extension; then
+      no_athena= ac_athena_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_athena" = yes; then
+  ac_cv_path_athena="no_athena=yes"
+else
+  ac_cv_path_athena="no_athena= ac_athena_includes=$ac_athena_includes ac_athena_libraries=$ac_athena_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_athena"
+fi # with_athena != no
+
+if test "$no_athena" = yes; then
+  echo "$ac_t""no" 1>&6
+  XALOCK=""
+  INSTALL_XALOCK=""
+  UNINSTALL_XALOCK=""
+else
+  XALOCKLIBS="-lXaw ${XALOCKLIBS}"
+  XALOCK="xalock"
+  INSTALL_XALOCK="install_xalock"
+  UNINSTALL_XALOCK="uninstall_xalock"
+  test "x$athena_includes" = xNONE && athena_includes=$ac_athena_includes
+  test "x$athena_libraries" = xNONE && athena_libraries=$ac_athena_libraries
+  ac_cv_path_athena="no_athena= ac_athena_includes=$athena_includes ac_athena_libraries=$athena_libraries"
+  echo "$ac_t""libraries $athena_libraries, headers $athena_includes" 1>&6
+fi
+
+
+if test "x$athena_libraries" != x && test "x$athena_libraries" != xNONE ; then
+  XALOCK_LDFLAGS="${XALOCK_LDFLAGS}:$athena_libraries"
+  XALOCKLIBPATHS="${XALOCKLIBPATHS} -L$athena_libraries"
+fi
+if test "x$athena_includes" != x && test "x$athena_includes" != xNONE ; then
+  XALOCKINC="${XALOCKINC} -I$athena_includes"
+fi
+
+
+
+
+
+
+sx_includes=NONE
+sx_libraries=NONE
+
+echo $ac_n "checking for sx""... $ac_c" 1>&6
+echo "configure:3398: checking for sx" >&5
+# Check whether --with-sx or --without-sx was given.
+if test "${with_sx+set}" = set; then
+  withval="$with_sx"
+  :
+fi
+
+if test "x$with_sx" = xno; then
+  no_sx=yes
+else
+  if test "x$sx_includes" != xNONE && test "x$sx_libraries" != xNONE; then
+    no_sx=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_sx'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_sx=yes
+test -z "$sx_direct_test_library" && sx_direct_test_library=sx
+test -z "$sx_direct_test_function" && sx_direct_test_function=OpenWindow
+test -z "$sx_direct_test_include" && sx_direct_test_include=X11/libsx.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$sx_direct_test_include"; then
+      no_sx= ac_sx_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$sx_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_sx_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${sx_direct_test_library}.$ac_extension; then
+      no_sx= ac_sx_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_sx" = yes; then
+  ac_cv_path_sx="no_sx=yes"
+else
+  ac_cv_path_sx="no_sx= ac_sx_includes=$ac_sx_includes ac_sx_libraries=$ac_sx_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_sx"
+fi # with_sx != no
+
+if test "$no_sx" = yes; then
+  echo "$ac_t""no" 1>&6
+  XALOCK=""
+  INSTALL_XALOCK=""
+  UNINSTALL_XALOCK=""
+else
+  XALOCKLIBS="-lsx ${XALOCKLIBS}"
+  XALOCK="xalock"
+  INSTALL_XALOCK="install_xalock"
+  UNINSTALL_XALOCK="uninstall_xalock"
+  test "x$sx_includes" = xNONE && sx_includes=$ac_sx_includes
+  test "x$sx_libraries" = xNONE && sx_libraries=$ac_sx_libraries
+  ac_cv_path_sx="no_sx= ac_sx_includes=$sx_includes ac_sx_libraries=$sx_libraries"
+  echo "$ac_t""libraries $sx_libraries, headers $sx_includes" 1>&6
+fi
+
+
+if test "x$sx_libraries" != x && test "x$sx_libraries" != xNONE ; then
+  XALOCK_LDFLAGS="$sx_libraries:${XALOCK_LDFLAGS}"
+  XALOCKLIBPATHS="-L$sx_libraries ${XALOCKLIBPATHS}"
+fi
+if test "x$sx_includes" != x && test "x$sx_includes" != xNONE ; then
+  XALOCKINC="${XALOCKINC} -I$sx_includes"
+fi
+
+
+
+
+
+
+editres_includes=NONE
+editres_libraries=NONE
+
+echo $ac_n "checking for Editres""... $ac_c" 1>&6
+echo "configure:3579: checking for Editres" >&5
+# Check whether --with-editres or --without-editres was given.
+if test "${with_editres+set}" = set; then
+  withval="$with_editres"
+  :
+fi
+
+if test "x$with_editres" = xno; then
+  no_editres=yes
+else
+  if test "x$editres_includes" != xNONE && test "x$editres_libraries" != xNONE; then
+    no_editres=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_editres'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_editres=yes
+test -z "$editres_direct_test_library" && editres_direct_test_library=Xmu
+test -z "$editres_direct_test_function" && editres_direct_test_function=_XEditResCheckMessages
+test -z "$editres_direct_test_include" && editres_direct_test_include=X11/Xmu/Editres.h
+  for ac_dir in               \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include      \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$editres_direct_test_include"; then
+      no_editres= ac_editres_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$editres_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_editres_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${editres_direct_test_library}.$ac_extension; then
+      no_editres= ac_editres_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_editres" = yes; then
+  ac_cv_path_editres="no_editres=yes"
+else
+  ac_cv_path_editres="no_editres= ac_editres_includes=$ac_editres_includes ac_editres_libraries=$ac_editres_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_editres"
+fi # with_editres != no
+
+if test "$no_editres" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+  cat >> confdefs.h <<\EOF
+#define USE_XMU 1
+EOF
+
+  XMLOCKLIBS="-lXmu ${XMLOCKLIBS}"
+  XALOCKLIBS="-lXmu ${XALOCKLIBS}"
+  test "x$editres_includes" = xNONE && editres_includes=$ac_editres_includes
+  test "x$editres_libraries" = xNONE && editres_libraries=$ac_editres_libraries
+  ac_cv_path_editres="no_editres= ac_editres_includes=$editres_includes ac_editres_libraries=$editres_libraries"
+  echo "$ac_t""libraries $editres_libraries, headers $editres_includes" 1>&6
+fi
+
+
+if test "x$editres_libraries" != x && test "x$editres_libraries" != xNONE ; then
+  XMLOCK_LDFLAGS="${XMLOCK_LDFLAGS}:$editres_libraries"
+  XALOCK_LDFLAGS="${XALOCK_LDFLAGS}:$editres_libraries"
+  XMLOCKLIBPATHS="${XMLOCKLIBPATHS} -L$editres_libraries"
+  XALOCKLIBPATHS="${XALOCKLIBPATHS} -L$editres_libraries"
+fi
+if test "x$editres_includes" != x && test "x$editres_includes" != xNONE ; then
+  XMLOCKINC="${XMLOCKINC} -I$editres_includes"
+  XALOCKINC="${XALOCKINC} -I$editres_includes"
+fi
+
+xpm=no
+
+
+
+
+
+xpm_includes=NONE
+xpm_libraries=NONE
+
+echo $ac_n "checking for XPM""... $ac_c" 1>&6
+echo "configure:3770: checking for XPM" >&5
+# Check whether --with-xpm or --without-xpm was given.
+if test "${with_xpm+set}" = set; then
+  withval="$with_xpm"
+  :
+fi
+
+if test "x$with_xpm" = xno; then
+  no_xpm=yes
+else
+  if test "x$xpm_includes" != xNONE && test "x$xpm_libraries" != xNONE; then
+    no_xpm=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_xpm'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_xpm=yes
+test -z "$xpm_direct_test_library" && xpm_direct_test_library=Xpm
+test -z "$xpm_direct_test_function" && xpm_direct_test_function=XpmCreateImageFromData
+test -z "$xpm_direct_test_include" && xpm_direct_test_include=xpm.h
+  for ac_dir in                   \
+    /usr/X11R6.3/include/X11      \
+    /usr/X11R6.2/include/X11      \
+    /usr/X11R6.1/include/X11      \
+    /usr/X11R6/include/X11        \
+    /usr/X11R5/include/X11        \
+    /usr/X11R4/include/X11        \
+    /usr/X11/include/X11          \
+                                  \
+    /usr/include/X11/X11          \
+    /usr/include/X11R6.3/X11      \
+    /usr/include/X11R6.2/X11      \
+    /usr/include/X11R6.1/X11      \
+    /usr/include/X11R6/X11        \
+    /usr/include/X11R5/X11        \
+    /usr/include/X11R4/X11        \
+                                  \
+    /usr/local/X11/include/X11    \
+    /usr/local/X11R6.3/include/X11  \
+    /usr/local/X11R6.2/include/X11  \
+    /usr/local/X11R6.1/include/X11  \
+    /usr/local/X11R6/include/X11  \
+    /usr/local/X11R5/include/X11  \
+    /usr/local/X11R4/include/X11  \
+                                  \
+    /usr/local/include/X11/X11    \
+    /usr/local/include/X11R6.3/X11  \
+    /usr/local/include/X11R6.2/X11  \
+    /usr/local/include/X11R6.1/X11  \
+    /usr/local/include/X11R6/X11  \
+    /usr/local/include/X11R5/X11  \
+    /usr/local/include/X11R4/X11  \
+                                  \
+    /usr/X386/include/X11         \
+    /usr/x386/include/X11         \
+    /usr/XFree86/include/X11/X11  \
+                                  \
+    /usr/local/include/X11        \
+    /usr/remote/include/X11       \
+    /usr/include/X11              \
+    /usr/unsupported/include/X11  \
+    /usr/athena/include/X11       \
+    /usr/local/x11r5/include/X11  \
+    /usr/lpp/Xamples/include/X11  \
+                                  \
+    /usr/openwin/include/X11      \
+    /usr/openwin/share/include/X11 \
+    /usr/openwin/include          \
+                                  \
+    /usr/include/Vk               \
+    $extra_include                \
+    $extra_include/X11            \
+    ; \
+  do
+    if test -r "$ac_dir/$xpm_direct_test_include"; then
+      no_xpm= ac_xpm_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$xpm_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_xpm_includes" | sed s%/X11$%% | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${xpm_direct_test_library}.$ac_extension; then
+      no_xpm= ac_xpm_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_xpm" = yes; then
+  ac_cv_path_xpm="no_xpm=yes"
+else
+  ac_cv_path_xpm="no_xpm= ac_xpm_includes=$ac_xpm_includes ac_xpm_libraries=$ac_xpm_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_xpm"
+fi # with_xpm != no
+
+if test "$no_xpm" = yes; then
+  echo "$ac_t""no" 1>&6
+  XPM="#"
+else
+  xpm=yes
+  cat >> confdefs.h <<\EOF
+#define USE_XPMINC 1
+EOF
+
+  XLOCKLIBS="${XLOCKLIBS} -lXpm"
+  XMLOCKLIBS="-lXpm ${XMLOCKLIBS}"
+  test "x$xpm_includes" = xNONE && xpm_includes=$ac_xpm_includes
+  test "x$xpm_libraries" = xNONE && xpm_libraries=$ac_xpm_libraries
+  ac_cv_path_xpm="no_xpm= ac_xpm_includes=$xpm_includes ac_xpm_libraries=$xpm_libraries"
+  echo "$ac_t""libraries $xpm_libraries, headers $xpm_includes" 1>&6
+  XPM=""
+fi
+
+
+if test "x$xpm_libraries" != x && test "x$xpm_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$xpm_libraries"
+  XMLOCK_LDFLAGS="${XMLOCK_LDFLAGS}:$xpm_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$xpm_libraries"
+  XMLOCKLIBPATHS="${XMLOCKLIBPATHS} -L$xpm_libraries"
+fi
+if test "x$xpm_includes" != x && test "x$xpm_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$xpm_includes"
+fi
+
+gltt=no
+
+
+
+
+
+gltt_includes=NONE
+gltt_libraries=NONE
+
+echo $ac_n "checking for GLTT""... $ac_c" 1>&6
+echo "configure:3964: checking for GLTT" >&5
+# Check whether --with-gltt or --without-gltt was given.
+if test "${with_gltt+set}" = set; then
+  withval="$with_gltt"
+  :
+fi
+
+if test "x$with_gltt" = xno; then
+  no_gltt=yes
+else
+  if test "x$gltt_includes" != xNONE && test "x$gltt_libraries" != xNONE; then
+    no_gltt=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_gltt'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_gltt=yes
+test -z "$gltt_direct_test_library" && gltt_direct_test_library=gltt
+# test -z "$gltt_direct_test_function" && gltt_direct_test_function=glttCreateImageFromData
+test -z "$gltt_direct_test_include" && gltt_direct_test_include=FTFace.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    /usr/openwin/include      \
+                              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$gltt_direct_test_include"; then
+      no_gltt= ac_gltt_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$gltt_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_gltt_includes" | sed s%/X11$%% | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${gltt_direct_test_library}.$ac_extension; then
+      no_gltt= ac_gltt_libraries=$ac_dir
+      break 2
+   fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_gltt" = yes; then
+  ac_cv_path_gltt="no_gltt=yes"
+else
+  ac_cv_path_gltt="no_gltt= ac_gltt_includes=$ac_gltt_includes ac_gltt_libraries=$ac_gltt_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_gltt"
+fi # with_gltt != no
+
+if test "$no_gltt" = yes; then
+  echo "$ac_t""no" 1>&6
+  GLTT="#"
+else
+  gltt=yes
+  cat >> confdefs.h <<\EOF
+#define HAVE_GLTT 1
+EOF
+
+  XLOCKLIBS="${XLOCKLIBS} -lgltt"
+  test "x$gltt_includes" = xNONE && gltt_includes=$ac_gltt_includes
+  test "x$gltt_libraries" = xNONE && gltt_libraries=$ac_gltt_libraries
+  ac_cv_path_gltt="no_gltt= ac_gltt_includes=$gltt_includes ac_gltt_libraries=$gltt_libraries"
+  echo "$ac_t""libraries $gltt_libraries, headers $gltt_includes" 1>&6
+  GLTT=""
+fi
+
+
+if test "x$gltt_libraries" != x && test "x$gltt_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$gltt_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$gltt_libraries"
+fi
+if test "x$gltt_includes" != x && test "x$gltt_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$gltt_includes"
+fi
+
+ttf=no
+
+
+
+
+
+ttf_includes=NONE
+ttf_libraries=NONE
+
+echo $ac_n "checking for TTF""... $ac_c" 1>&6
+echo "configure:4153: checking for TTF" >&5
+# Check whether --with-ttf or --without-ttf was given.
+if test "${with_ttf+set}" = set; then
+  withval="$with_ttf"
+  :
+fi
+
+if test "x$with_ttf" = xno; then
+  no_ttf=yes
+else
+  if test "x$ttf_includes" != xNONE && test "x$ttf_libraries" != xNONE; then
+    no_ttf=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_ttf'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_ttf=yes
+test -z "$ttf_direct_test_library" && ttf_direct_test_library=ttf
+test -z "$ttf_direct_test_function" && ttf_direct_test_function=TT_Init_FreeType
+test -z "$ttf_direct_test_include" && ttf_direct_test_include=freetype.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include/X11          \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    /usr/openwin/include      \
+                              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$ttf_direct_test_include"; then
+      no_ttf= ac_ttf_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$ttf_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_ttf_includes" | sed s%/X11$%% | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${ttf_direct_test_library}.$ac_extension; then
+      no_ttf= ac_ttf_libraries=$ac_dir
+      break 2
+   fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_ttf" = yes; then
+  ac_cv_path_ttf="no_ttf=yes"
+else
+  ac_cv_path_ttf="no_ttf= ac_ttf_includes=$ac_ttf_includes ac_ttf_libraries=$ac_ttf_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_ttf"
+fi # with_ttf != no
+
+if test "$no_ttf" = yes; then
+  echo "$ac_t""no" 1>&6
+  TTF="#"
+else
+  ttf=yes
+  cat >> confdefs.h <<\EOF
+#define HAVE_TTF 1
+EOF
+
+  XLOCKLIBS="${XLOCKLIBS} -lttf"
+  test "x$ttf_includes" = xNONE && ttf_includes=$ac_ttf_includes
+  test "x$ttf_libraries" = xNONE && ttf_libraries=$ac_ttf_libraries
+  ac_cv_path_ttf="no_ttf= ac_ttf_includes=$ttf_includes ac_ttf_libraries=$ttf_libraries"
+  echo "$ac_t""libraries $ttf_libraries, headers $ttf_includes" 1>&6
+  TTF=""
+fi
+
+
+if test "x$ttf_libraries" != x && test "x$ttf_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$ttf_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$ttf_libraries"
+fi
+if test "x$ttf_includes" != x && test "x$ttf_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$ttf_includes"
+fi
+
+gl=no
+
+
+
+
+
+opengl_includes=NONE
+opengl_libraries=NONE
+
+echo $ac_n "checking for OpenGL""... $ac_c" 1>&6
+echo "configure:4342: checking for OpenGL" >&5
+# Check whether --with-opengl or --without-opengl was given.
+if test "${with_opengl+set}" = set; then
+  withval="$with_opengl"
+  :
+fi
+
+if test "x$with_opengl" = xno; then
+  no_opengl=yes
+else
+  if test "x$opengl_includes" != xNONE && test "x$opengl_libraries" != xNONE; then
+    no_opengl=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_opengl'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_opengl=yes
+test -z "$opengl_direct_test_library" && opengl_direct_test_library=GL
+test -z "$opengl_direct_test_library" && opengl_direct_test_library=GLU
+test -z "$opengl_direct_test_function" && opengl_direct_test_function=glXCreateContext
+test -z "$opengl_direct_test_include" && opengl_direct_test_include=GL/gl.h
+  for ac_dir in               \
+    /usr/include              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+# Make sure this is not MesaGL
+    if test -r "$ac_dir/$opengl_direct_test_include" && test ! -r "$ac_dir/GL/xmesa.h"; then
+      no_opengl= ac_opengl_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$opengl_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_opengl_includes" | sed s/include/lib/` \
+                          \
+    /usr/lib              \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+# Make sure its not a symbolic link to MesaGL library
+
+    if test -r $ac_dir/lib${opengl_direct_test_library}.$ac_extension && test ! $ac_link_test $ac_dir/lib${opengl_direct_test_library}.$ac_extension && test ! -r $ac_dir/libMesa${opengl_direct_test_library}.$ac_extension; then
+      no_opengl= ac_opengl_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_opengl" = yes; then
+  ac_cv_path_opengl="no_opengl=yes"
+else
+  ac_cv_path_opengl="no_opengl= ac_opengl_includes=$ac_opengl_includes ac_opengl_libraries=$ac_opengl_libraries"
+
+fi
+fi
+  fi
+  eval "$ac_cv_path_opengl"
+fi # with_opengl != no
+
+if test "$no_opengl" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+  gl=yes
+  cat >> confdefs.h <<\EOF
+#define USE_GL 1
+EOF
+
+  XLOCKLIBS="${XLOCKLIBS} -lGL -lGLU"
+  test "x$opengl_includes" = xNONE && opengl_includes=$ac_opengl_includes
+  test "x$opengl_libraries" = xNONE && opengl_libraries=$ac_opengl_libraries
+  case "${canonical}" in
+    *-*-solaris2* )
+      cat >> confdefs.h <<\EOF
+#define SUN_OGL_NO_VERTEX_MACROS 1
+EOF
+
+      if test "x$opengl_includes" = "x/usr/include"; then
+        opengl_includes=""
+      fi
+    ;;
+    *-*-irix5* | *-*-irix6* )
+      XLOCKLIBS="${XLOCKLIBS} -lgl"
+    ;;
+  esac
+  ac_cv_path_opengl="no_opengl= ac_opengl_includes=$opengl_includes ac_opengl_libraries=$opengl_libraries"
+  echo "$ac_t""libraries $opengl_libraries, headers $opengl_includes" 1>&6
+  GL=""
+fi
+
+
+if test "x$opengl_libraries" != x && test "x$opengl_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$opengl_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$opengl_libraries"
+fi
+if test "x$opengl_includes" != x && test "x$opengl_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$opengl_includes"
+fi
+
+
+
+
+
+
+mesagl_includes=NONE
+mesagl_libraries=NONE
+
+echo $ac_n "checking for MesaGL""... $ac_c" 1>&6
+echo "configure:4462: checking for MesaGL" >&5
+# Check whether --with-mesagl or --without-mesagl was given.
+if test "${with_mesagl+set}" = set; then
+  withval="$with_mesagl"
+  :
+fi
+
+if test "x$with_mesagl" = xno; then
+  no_mesagl=yes
+else
+  if test "x$mesagl_includes" != xNONE && test "x$mesagl_libraries" != xNONE; then
+    no_mesagl=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_mesagl'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_mesagl=yes
+test -z "$mesagl_direct_test_library" && mesagl_direct_test_library=MesaGL
+test -z "$mesagl_direct_test_library" && mesagl_direct_test_library=MesaGLU
+test -z "$mesagl_direct_test_function" && mesagl_direct_test_function=glXCreateContext
+test -z "$mesagl_direct_test_include" && mesagl_direct_test_include=GL/gl.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$mesagl_direct_test_include"; then
+      no_mesagl= ac_mesagl_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$mesagl_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_mesagl_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${mesagl_direct_test_library}.$ac_extension; then
+      no_mesagl= ac_mesagl_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_mesagl" = yes; then
+  ac_cv_path_mesagl="no_mesagl=yes"
+else
+  ac_cv_path_mesagl="no_mesagl= ac_mesagl_includes=$ac_mesagl_includes ac_mesagl_libraries=$ac_mesagl_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_mesagl"
+fi # with_mesagl != no
+
+if test "$no_mesagl" = yes; then
+  echo "$ac_t""no" 1>&6
+  GL="#"
+else
+  if test "$gl" = no; then
+    gl=yes
+    cat >> confdefs.h <<\EOF
+#define USE_GL 1
+EOF
+
+    XLOCKLIBS="${XLOCKLIBS} -lMesaGL -lMesaGLU"
+    test "x$mesagl_includes" = xNONE && mesagl_includes=$ac_mesagl_includes
+    test "x$mesagl_libraries" = xNONE && mesagl_libraries=$ac_mesagl_libraries
+    case "${canonical}" in
+      *-*-solaris2* )
+        if test "x$mesagl_includes" = "x/usr/include"; then
+          mesagl_includes=""
+        fi
+      ;;
+    esac
+    ac_cv_path_mesagl="no_mesagl= ac_mesagl_includes=$mesagl_includes ac_mesagl_libraries=$mesagl_libraries"
+    echo "$ac_t""libraries $mesagl_libraries, headers $mesagl_includes" 1>&6
+    echo "$ac_t""!!!WARNING!!! Known security hole with MesaGL <= 2.6 if setuid root" 1>&6
+    case "${canonical}" in
+      *-*-linux* )
+        # Testing if MesaGL was compiled against VGA
+        if test -f $mesagl_libraries/libMesaGL.so; then
+          have_mesagl_svga=`nm $mesagl_libraries/libMesaGL.so | grep SVGAMesa | wc -l`
+        else
+          have_mesagl_svga=0
+        fi
+        if eval "test $have_mesagl_svga -ge 1"; then
+          echo "$ac_t""MesaGL library is linked against SVGA: adding -lvga" 1>&6
+          XLOCKLIBS="${XLOCKLIBS} -lvga"
+        fi
+        # Testing if MesaGL was compiled against glide
+        if test -f $mesagl_libraries/libglide.so; then
+          have_mesagl_glide=`nm $mesagl_libraries/libglide.so | grep grGlideInit | wc -l`
+        else
+          have_mesagl_glide=0
+        fi
+        if eval "test $have_mesagl_glide -ge 1"; then
+          echo "$ac_t""MesaGL library is linked against GLIDE: adding -lglide2x" 1>&6
+          XLOCKLIBS="${XLOCKLIBS} -lglide2x"
+        fi
+#  Causes major errors for maintainer.  xlock refuses to run.
+#        # Testing if MesaGL was compiled against pthread
+#        if test -f $mesagl_libraries/libpthread.so; then
+#          have_mesagl_pthread=`nm $mesagl_libraries/libpthread.so | grep pthread_once | wc -l`
+#        else
+#          have_mesagl_pthread=0
+#        fi
+#        if eval "test $have_mesagl_pthread -ge 1"; then
+#          AC_MSG_RESULT([MesaGL library is linked against GLIDE: adding -lpthread])
+#          XLOCKLIBS="${XLOCKLIBS} -lpthread"
+#        fi
+       
+        ;;
+    esac
+    GL=""
+  else  
+    echo "$ac_t""ignored - using OpenGL" 1>&6
+  fi
+
+fi
+
+
+if test "x$mesagl_libraries" != x && test "x$mesagl_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="$mesagl_libraries:${XLOCK_LDFLAGS}"
+  XLOCKLIBPATHS="-L$mesagl_libraries ${XLOCKLIBPATHS}"
+fi
+if test "x$mesagl_includes" != x && test "x$mesagl_includes" != xNONE ; then
+  XLOCKINC="-I$mesagl_includes ${XLOCKINC}"
+fi
+
+# Test if (Mesa)GL has GL1.1 features
+# (Should this test be performed only if (Mesa)GL is used? In that case
+# it fails anyway.)
+echo $ac_n "checking Checking for GL >=1.1""... $ac_c" 1>&6
+echo "configure:4687: checking Checking for GL >=1.1" >&5
+ac_save_CFLAGS="$CFLAGS"
+ac_save_LIBS="$LIBS"
+CFLAGS="${CFLAGS} ${XLOCKINC}"
+LIBS="${XLOCKLIBPATHS} ${XLOCKLIBS} -lX11 -lXext -lm"
+if eval "test \"`echo '$''{'ac_cv_c_gl1_1'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+     
+cat > conftest.$ac_ext <<EOF
+#line 4697 "configure"
+#include "confdefs.h"
+#define _XOPEN_SOURCE 1
+#include <GL/gl.h>
+int main() {
+
+GLint texture;
+glBindTexture(GL_TEXTURE_2D, texture);
+
+; return 0; }
+EOF
+if { (eval echo configure:4708: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  ac_cv_c_gl1_1=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_c_gl1_1=no
+fi
+rm -f conftest*
+fi
+
+    cat >> confdefs.h <<\EOF
+#define HAVE_GLBINDTEXTURE 1
+EOF
+
+    echo "$ac_t""yes" 1>&6
+CFLAGS="$ac_save_CFLAGS"
+LIBS="$ac_save_LIBS"
+
+
+
+
+
+
+dtsaver_includes=NONE
+dtsaver_libraries=NONE
+
+echo $ac_n "checking for DtSaver""... $ac_c" 1>&6
+echo "configure:4737: checking for DtSaver" >&5
+# Check whether --with-dtsaver or --without-dtsaver was given.
+if test "${with_dtsaver+set}" = set; then
+  withval="$with_dtsaver"
+  :
+fi
+
+if test "x$with_dtsaver" = xno; then
+  no_dtsaver=yes
+else
+  if test "x$dtsaver_includes" != xNONE && test "x$dtsaver_libraries" != xNONE; then
+    no_dtsaver=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_dtsaver'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_dtsaver=yes
+test -z "$dtsaver_direct_test_library" && dtsaver_direct_test_library=DtSvc
+test -z "$dtsaver_direct_test_function" && dtsaver_direct_test_function=DtSaverGetWindows
+test -z "$dtsaver_direct_test_include" && dtsaver_direct_test_include=Dt/Saver.h
+  for ac_dir in            \
+    /usr/dt/include        \
+    $extra_include         \
+    ; \
+  do
+    if test -r "$ac_dir/$dtsaver_direct_test_include"; then
+      no_dtsaver= ac_dtsaver_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$dtsaver_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_dtsaver_includes" | sed s/include/lib/` \
+    $extra_lib         \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${dtsaver_direct_test_library}.$ac_extension; then
+      no_dtsaver= ac_dtsaver_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_dtsaver" = yes; then
+  ac_cv_path_dtsaver="no_dtsaver=yes"
+else
+  ac_cv_path_dtsaver="no_dtsaver= ac_dtsaver_includes=$ac_dtsaver_includes ac_dtsaver_libraries=$ac_dtsaver_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_dtsaver"
+fi # with_dtsaver != no
+
+if test "$no_dtsaver" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+  cat >> confdefs.h <<\EOF
+#define USE_DTSAVER 1
+EOF
+
+  XLOCKLIBS="${XLOCKLIBS} -lDtSvc"
+  test "x$dtsaver_includes" = xNONE && dtsaver_includes=$ac_dtsaver_includes
+  test "x$dtsaver_libraries" = xNONE && dtsaver_libraries=$ac_dtsaver_libraries
+  ac_cv_path_dtsaver="no_dtsaver= ac_dtsaver_includes=$dtsaver_includes ac_dtsaver_libraries=$dtsaver_libraries"
+  echo "$ac_t""libraries $dtsaver_libraries, headers $dtsaver_includes" 1>&6
+fi
+
+
+if test "x$dtsaver_libraries" != x && test "x$dtsaver_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$dtsaver_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$dtsaver_libraries"
+fi
+if test "x$dtsaver_includes" != x && test "x$dtsaver_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$dtsaver_includes"
+fi
+
+
+
+
+
+
+dpms_includes=NONE
+dpms_libraries=NONE
+
+echo $ac_n "checking for DPMS""... $ac_c" 1>&6
+echo "configure:4830: checking for DPMS" >&5
+# Check whether --with-dpms or --without-dpms was given.
+if test "${with_dpms+set}" = set; then
+  withval="$with_dpms"
+  :
+fi
+
+dpmslib=no
+if test "x$with_dpms" = xno; then
+  no_dpms=yes
+else
+  if test "x$dpms_includes" != xNONE && test "x$dpms_libraries" != xNONE; then
+    no_dpms=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_dpms'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_dpms=yes
+test -z "$dpms_direct_test_library" && dpms_direct_test_library=Xdpms
+test -z "$dpms_direct_test_function" && dpms_direct_test_function=DPMSSetTimeouts
+test -z "$dpms_direct_test_include" && dpms_direct_test_include=X11/extensions/dpms.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/dpms/include         \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$dpms_direct_test_include"; then
+      no_dpms= ac_dpms_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$dpms_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_dpms_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/dpms/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    /shlib                \
+    /usr/shlib            \
+    /usr/shlib/X11        \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${dpms_direct_test_library}.$ac_extension; then
+      no_dpms= ac_dpms_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_dpms" = yes; then
+  ac_cv_path_dpms="no_dpms=yes"
+else
+  ac_cv_path_dpms="no_dpms= ac_dpms_includes=$ac_dpms_includes ac_dpms_libraries=$ac_dpms_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_dpms"
+fi # with_dpms != no
+
+if test "$no_dpms" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+  cat >> confdefs.h <<\EOF
+#define USE_DPMS 1
+EOF
+
+  if test "x$ac_dpms_libraries" != xNONE; then
+    XLOCKLIBS="${XLOCKLIBS} -lXdpms"
+  fi
+  test "x$dpms_includes" = xNONE && dpms_includes=$ac_dpms_includes
+  test "x$dpms_libraries" = xNONE && dpms_libraries=$ac_dpms_libraries
+  ac_cv_path_dpms="no_dpms= ac_dpms_includes=$dpms_includes ac_dpms_libraries=$dpms_libraries"
+  echo "$ac_t""libraries $dpms_libraries, headers $dpms_includes" 1>&6
+fi
+
+
+if test "x$dpms_libraries" != x && test "x$dpms_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$dpms_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$dpms_libraries"
+fi
+if test "x$dpms_includes" != x && test "x$dpms_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$dpms_includes"
+fi
+
+sound=no
+
+
+
+
+
+rplay_includes=NONE
+rplay_libraries=NONE
+
+echo $ac_n "checking for RPLAY""... $ac_c" 1>&6
+echo "configure:5025: checking for RPLAY" >&5
+# Check whether --with-rplay or --without-rplay was given.
+if test "${with_rplay+set}" = set; then
+  withval="$with_rplay"
+  :
+fi
+
+if test "x$with_rplay" = xno; then
+  no_rplay=yes
+else
+  if test "x$rplay_includes" != xNONE && test "x$rplay_libraries" != xNONE; then
+    no_rplay=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_rplay'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_rplay=yes
+test -z "$rplay_direct_test_library" && rplay_direct_test_library=rplay
+test -z "$rplay_direct_test_function" && rplay_direct_test_function=rplay_open_default
+test -z "$rplay_direct_test_include" && rplay_direct_test_include=rplay.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11/include          \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$rplay_direct_test_include"; then
+      no_rplay= ac_rplay_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$rplay_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_rplay_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11/lib          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${rplay_direct_test_library}.$ac_extension; then
+      no_rplay= ac_rplay_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_rplay" = yes; then
+  ac_cv_path_rplay="no_rplay=yes"
+else
+  ac_cv_path_rplay="no_rplay= ac_rplay_includes=$ac_rplay_includes ac_rplay_libraries=$ac_rplay_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_rplay"
+fi # with_rplay != no
+
+if test "$no_rplay" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+    sound=yes
+    cat >> confdefs.h <<\EOF
+#define USE_RPLAY 1
+EOF
+
+    XLOCKLIBS="${XLOCKLIBS} -lrplay"
+    test "x$rplay_includes" = xNONE && rplay_includes=$ac_rplay_includes
+    test "x$rplay_libraries" = xNONE && rplay_libraries=$ac_rplay_libraries
+    ac_cv_path_rplay="no_rplay= ac_rplay_includes=$rplay_includes ac_rplay_libraries=$rplay_libraries"
+    echo "$ac_t""libraries $rplay_libraries, headers $rplay_includes" 1>&6
+fi
+
+
+if test "x$rplay_libraries" != x && test "x$rplay_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$rplay_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$rplay_libraries"
+fi
+if test "x$rplay_includes" != x && test "x$rplay_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$rplay_includes"
+fi
+
+
+
+
+
+
+nas_includes=NONE
+nas_libraries=NONE
+
+echo $ac_n "checking for NAS""... $ac_c" 1>&6
+echo "configure:5137: checking for NAS" >&5
+# Check whether --with-nas or --without-nas was given.
+if test "${with_nas+set}" = set; then
+  withval="$with_nas"
+  :
+fi
+
+if test "x$with_nas" = xno; then
+  no_nas=yes
+else
+  if test "x$nas_includes" != xNONE && test "x$nas_libraries" != xNONE; then
+    no_nas=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_nas'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_nas=yes
+test -z "$nas_direct_test_library" && nas_direct_test_library=audio
+test -z "$nas_direct_test_function" && nas_direct_test_function=AuOpenServer
+test -z "$nas_direct_test_include" && nas_direct_test_include=audio/audio.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11/include          \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$nas_direct_test_include"; then
+      no_nas= ac_nas_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$nas_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_nas_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11/lib          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${nas_direct_test_library}.$ac_extension; then
+      no_nas= ac_nas_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_nas" = yes; then
+  ac_cv_path_nas="no_nas=yes"
+else
+  ac_cv_path_nas="no_nas= ac_nas_includes=$ac_nas_includes ac_nas_libraries=$ac_nas_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_nas"
+fi # with_nas != no
+
+if test "$no_nas" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+  if test "$sound" = no; then
+    sgi=no
+    case "${canonical}" in
+      *-*-irix5* | *-*-irix6* )
+        sgi=yes
+      ;;
+    esac
+    if test "$sgi" = yes; then
+      echo "$ac_t""ignored - problems here with audio and nas" 1>&6
+    else
+      sound=yes
+      cat >> confdefs.h <<\EOF
+#define USE_NAS 1
+EOF
+
+      XLOCKLIBS="${XLOCKLIBS} -laudio"
+      test "x$nas_includes" = xNONE && nas_includes=$ac_nas_includes
+      test "x$nas_libraries" = xNONE && nas_libraries=$ac_nas_libraries
+      ac_cv_path_nas="no_nas= ac_nas_includes=$nas_includes ac_nas_libraries=$nas_libraries"
+      echo "$ac_t""libraries $nas_libraries, headers $nas_includes" 1>&6
+    fi
+  else
+      echo "$ac_t""ignored - using rplay" 1>&6
+  fi
+fi
+
+
+if test "x$nas_libraries" != x && test "x$nas_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$nas_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$nas_libraries"
+fi
+if test "x$nas_includes" != x && test "x$nas_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$nas_includes"
+fi
+
+
+
+
+
+
+crypt_libraries=NONE
+
+echo $ac_n "checking for CRYPT""... $ac_c" 1>&6
+echo "configure:5262: checking for CRYPT" >&5
+# Check whether --with-crypt or --without-crypt was given.
+if test "${with_crypt+set}" = set; then
+  withval="$with_crypt"
+  :
+fi
+
+if test "x$with_crypt" = xno; then
+  no_crypt=yes
+else
+  if test "x$crypt_libraries" != xNONE; then
+    no_crypt=
+  else
+if eval "test \"`echo '$''{'ac_cv_path_crypt'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  # One or both of these vars are not set, and there is no cached value.
+no_crypt=yes
+test -z "$crypt_direct_test_library" && crypt_direct_test_library=crypt
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$crypt_direct_test_library $LIBS"
+for ac_dir in \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${crypt_direct_test_library}.$ac_extension; then
+      no_crypt= ac_crypt_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+
+if test "$no_crypt" = yes; then
+  ac_cv_path_crypt="no_crypt=yes"
+else
+  ac_cv_path_crypt="no_crypt= ac_crypt_libraries=$ac_crypt_libraries"
+fi
+fi
+  fi
+  eval "$ac_cv_path_crypt"
+fi # with_crypt != no
+
+if test "$no_crypt" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+  XLOCKLIBS="${XLOCKLIBS} -lcrypt"
+  test "x$crypt_libraries" = xNONE && crypt_libraries=$ac_crypt_libraries
+  ac_cv_path_crypt="no_crypt= ac_crypt_libraries=$crypt_libraries"
+  echo "$ac_t""libraries $crypt_libraries" 1>&6
+fi
+
+
+if test "x$crypt_libraries" != x && test "x$crypt_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$crypt_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$crypt_libraries"
+fi
+
+
+XGLOCK=""
+XGLOCKDIR=""
+INSTALL_XGLOCK=""
+UNINSTALL_XGLOCK=""
+XGLOCK_MAKEFILE=""
+# Check whether --with-gtk or --without-gtk was given.
+if test "${with_gtk+set}" = set; then
+  withval="$with_gtk"
+  :
+fi
+
+if test "x$with_gtk" != "xno" ; then
+   # Check whether --with-gtk-prefix or --without-gtk-prefix was given.
+if test "${with_gtk_prefix+set}" = set; then
+  withval="$with_gtk_prefix"
+  gtk_config_prefix="$withval"
+else
+  gtk_config_prefix=""
+fi
+
+# Check whether --with-gtk-exec-prefix or --without-gtk-exec-prefix was given.
+if test "${with_gtk_exec_prefix+set}" = set; then
+  withval="$with_gtk_exec_prefix"
+  gtk_config_exec_prefix="$withval"
+else
+  gtk_config_exec_prefix=""
+fi
+
+# Check whether --enable-gtktest or --disable-gtktest was given.
+if test "${enable_gtktest+set}" = set; then
+  enableval="$enable_gtktest"
+  :
+else
+  enable_gtktest=yes
+fi
+
+
+  if test x$gtk_config_exec_prefix != x ; then
+     gtk_config_args="$gtk_config_args --exec-prefix=$gtk_config_exec_prefix"
+     if test x${GTK_CONFIG+set} != xset ; then
+        GTK_CONFIG=$gtk_config_exec_prefix/bin/gtk-config
+     fi
+  fi
+  if test x$gtk_config_prefix != x ; then
+     gtk_config_args="$gtk_config_args --prefix=$gtk_config_prefix"
+     if test x${GTK_CONFIG+set} != xset ; then
+        GTK_CONFIG=$gtk_config_prefix/bin/gtk-config
+     fi
+  fi
+
+  # Extract the first word of "gtk-config", so it can be a program name with args.
+set dummy gtk-config; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:5382: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  case "$GTK_CONFIG" in
+  /*)
+  ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a path.
+  ;;
+  *)
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
+  for ac_dir in $PATH; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_path_GTK_CONFIG="$ac_dir/$ac_word"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_path_GTK_CONFIG" && ac_cv_path_GTK_CONFIG="no"
+  ;;
+esac
+fi
+GTK_CONFIG="$ac_cv_path_GTK_CONFIG"
+if test -n "$GTK_CONFIG"; then
+  echo "$ac_t""$GTK_CONFIG" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+  min_gtk_version=1.0.4
+  echo $ac_n "checking for GTK - version >= $min_gtk_version""... $ac_c" 1>&6
+echo "configure:5413: checking for GTK - version >= $min_gtk_version" >&5
+  no_gtk=""
+  if test "$GTK_CONFIG" = "no" ; then
+    no_gtk=yes
+  else
+    GTK_CFLAGS=`$GTK_CONFIG $gtk_config_args --cflags`
+    GTK_LIBS=`$GTK_CONFIG $gtk_config_args --libs`
+    gtk_config_major_version=`$GTK_CONFIG $gtk_config_args --version | \
+           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
+    gtk_config_minor_version=`$GTK_CONFIG $gtk_config_args --version | \
+           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
+    gtk_config_micro_version=`$GTK_CONFIG $gtk_config_args --version | \
+           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
+    if test "x$enable_gtktest" = "xyes" ; then
+      ac_save_CFLAGS="$CFLAGS"
+      ac_save_LIBS="$LIBS"
+      CFLAGS="$CFLAGS $GTK_CFLAGS"
+      LIBS="$LIBS $GTK_LIBS"
+      rm -f conf.gtktest
+      if test "$cross_compiling" = yes; then
+  echo $ac_n "cross compiling; assumed OK... $ac_c"
+else
+  cat > conftest.$ac_ext <<EOF
+#line 5436 "configure"
+#include "confdefs.h"
+
+#include <gtk/gtk.h>
+#include <stdio.h>
+
+int 
+main ()
+{
+  int major, minor, micro;
+  char *tmp_version;
+
+  system ("touch conf.gtktest");
+
+  /* HP/UX 9 (%@#!) writes to sscanf strings */
+  tmp_version = g_strdup("$min_gtk_version");
+  if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
+     printf("%s, bad version string\n", "$min_gtk_version");
+     exit(1);
+   }
+
+  if ((gtk_major_version != $gtk_config_major_version) ||
+      (gtk_minor_version != $gtk_config_minor_version) ||
+      (gtk_micro_version != $gtk_config_micro_version))
+    {
+      printf("\n*** 'gtk-config --version' returned %d.%d.%d, but GTK+ (%d.%d.%d)\n", 
+             $gtk_config_major_version, $gtk_config_minor_version, $gtk_config_micro_version,
+             gtk_major_version, gtk_minor_version, gtk_micro_version);
+      printf ("*** was found! If gtk-config was correct, then it is best\n");
+      printf ("*** to remove the old version of GTK+. You may also be able to fix the error\n");
+      printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
+      printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
+      printf("*** required on your system.\n");
+      printf("*** If gtk-config was wrong, set the environment variable GTK_CONFIG\n");
+      printf("*** to point to the correct copy of gtk-config, and remove the file config.cache\n");
+      printf("*** before re-running configure\n");
+    } 
+  else
+    {
+      if ((gtk_major_version > major) ||
+        ((gtk_major_version == major) && (gtk_minor_version > minor)) ||
+        ((gtk_major_version == major) && (gtk_minor_version == minor) && (gtk_micro_version >= micro)))
+      {
+        return 0;
+       }
+     else
+      {
+        printf("\n*** An old version of GTK+ (%d.%d.%d) was found.\n",
+               gtk_major_version, gtk_minor_version, gtk_micro_version);
+        printf("*** You need a version of GTK+ newer than %d.%d.%d. The latest version of\n",
+              major, minor, micro);
+        printf("*** GTK+ is always available from ftp://ftp.gtk.org.\n");
+        printf("***\n");
+        printf("*** If you have already installed a sufficiently new version, this error\n");
+        printf("*** probably means that the wrong copy of the gtk-config shell script is\n");
+        printf("*** being found. The easiest way to fix this is to remove the old version\n");
+        printf("*** of GTK+, but you can also set the GTK_CONFIG environment to point to the\n");
+        printf("*** correct copy of gtk-config. (In this case, you will have to\n");
+        printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
+        printf("*** so that the correct libraries are found at run-time))\n");
+      }
+    }
+  return 1;
+}
+
+EOF
+if { (eval echo configure:5502: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+then
+  :
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -fr conftest*
+  no_gtk=yes
+fi
+rm -fr conftest*
+fi
+
+       CFLAGS="$ac_save_CFLAGS"
+       LIBS="$ac_save_LIBS"
+     fi
+  fi
+  if test "x$no_gtk" = x ; then
+     echo "$ac_t""yes" 1>&6
+     have_gtk="yes"     
+  else
+     echo "$ac_t""no" 1>&6
+     if test "$GTK_CONFIG" = "no" ; then
+       echo "*** The gtk-config script installed by GTK could not be found"
+       echo "*** If GTK was installed in PREFIX, make sure PREFIX/bin is in"
+       echo "*** your path, or set the GTK_CONFIG environment variable to the"
+       echo "*** full path to gtk-config."
+     else
+       if test -f conf.gtktest ; then
+        :
+       else
+          echo "*** Could not run GTK test program, checking why..."
+          CFLAGS="$CFLAGS $GTK_CFLAGS"
+          LIBS="$LIBS $GTK_LIBS"
+          cat > conftest.$ac_ext <<EOF
+#line 5536 "configure"
+#include "confdefs.h"
+
+#include <gtk/gtk.h>
+#include <stdio.h>
+
+int main() {
+ return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version)); 
+; return 0; }
+EOF
+if { (eval echo configure:5546: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+   echo "*** The test program compiled, but did not run. This usually means"
+          echo "*** that the run-time linker is not finding GTK or finding the wrong"
+          echo "*** version of GTK. If it is not finding GTK, you'll need to set your"
+          echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
+          echo "*** to the installed location  Also, make sure you have run ldconfig if that"
+          echo "*** is required on your system"
+         echo "***"
+          echo "*** If you have an old version installed, it is best to remove it, although"
+          echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
+          echo "***"
+          echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that"
+          echo "*** came with the system with the command"
+          echo "***"
+          echo "***    rpm --erase --nodeps gtk gtk-devel" 
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+   echo "*** The test program failed to compile or link. See the file config.log for the"
+          echo "*** exact error that occured. This usually means GTK was incorrectly installed"
+          echo "*** or that you have moved GTK since it was installed. In the latter case, you"
+          echo "*** may want to edit the gtk-config script: $GTK_CONFIG" 
+fi
+rm -f conftest*
+          CFLAGS="$ac_save_CFLAGS"
+          LIBS="$ac_save_LIBS"
+       fi
+     fi
+     GTK_CFLAGS=""
+     GTK_LIBS=""
+     have_gtk="no"
+  fi
+  
+  
+  rm -f conf.gtktest
+
+fi
+
+
+
+
+
+
+if test "x$have_gtk" = "xyes"; then
+
+  
+gtkfontsel_includes=NONE
+gtkfontsel_libraries=NONE
+
+echo $ac_n "checking for GTK FontSelection widget""... $ac_c" 1>&6
+echo "configure:5598: checking for GTK FontSelection widget" >&5
+# Check whether --with-gtkfontsel or --without-gtkfontsel was given.
+if test "${with_gtkfontsel+set}" = set; then
+  withval="$with_gtkfontsel"
+  :
+fi
+
+if test "x$with_gtkfontsel" = xno; then
+  no_gtkfontsel=yes
+else
+  if test "x$gtkfontsel_includes" != xNONE && test "x$gtkfontsel_libraries" != xNONE; then
+    no_gtkfontsel=
+  else
+    test -z "$gtkfontsel_direct_test_library" && gtkfontsel_direct_test_library="gtkfontsel"
+test -z "$gtkfontsel_direct_test_function" && gtkfontsel_direct_test_function="gtk_font_selection_new"
+test -z "$gtkfontsel_direct_test_include" && gtkfontsel_direct_test_include="gtkfontsel.h"
+  for ac_dir in                      \
+    /usr/include                     \
+    /usr/include/fontsel             \
+    /usr/include/gtkfontsel          \
+    /usr/gtk/include                 \
+    /usr/gtk/fontsel                 \
+    /usr/gtk/gtkfontsel              \
+    /usr/gtk/fontsel/include         \
+    /usr/gtk/gtkfontsel/include      \
+    /usr/local/include               \
+    /usr/local/include/fontsel       \
+    /usr/local/include/gtkfontsel    \
+    /usr/local/gtk/include           \
+    /usr/X11R6.3/include             \
+    /usr/X11R6.3/include/gtk         \
+    /usr/X11R6.2/include             \
+    /usr/X11R6.2/include/gtk         \
+    /usr/X11R6.1/include             \
+    /usr/X11R6.1/include/gtk         \
+    /usr/X11R6/include               \
+    /usr/X11R6/include/gtk           \
+    /usr/X11R5/include               \
+    /usr/X11R5/include/gtk           \
+    /usr/X11R4/include               \
+    /usr/X11R4/include/gtk           \
+    /usr/X11/include                 \
+    /usr/X11/include/gtk             \
+    /usr/X386/include                \
+    /usr/X386/include/gtk            \
+    /usr/x386/include                \
+    /usr/x386/include/gtk            \
+    /usr/XFree86/include             \
+    /usr/XFree86/include/gtk         \
+    /usr/local/X11R6.3/include       \
+    /usr/local/X11R6.3/include/gtk   \
+    /usr/local/X11R6.2/include       \
+    /usr/local/X11R6.2/include/gtk   \
+    /usr/local/X11R6.1/include       \
+    /usr/local/X11R6.1/include/gtk   \
+    /usr/local/X11R6/include         \
+    /usr/local/X11R6/include/gtk     \
+    /usr/local/X11R5/include         \
+    /usr/local/X11R5/include/gtk     \
+    /usr/local/X11R4/include         \
+    /usr/local/X11R4/include/gtk     \
+    /usr/local/X11/include           \
+    /usr/local/X11/include/gtk       \
+    /usr/local/X386/include          \
+    /usr/local/X386/include/gtk      \
+    /usr/local/x386/include          \
+    /usr/local/x386/include/gtk      \
+    /usr/local/XFree86/include       \
+    /usr/local/XFree86/include/gtk   \
+    /usr/local/include/X11R6.3       \
+    /usr/local/include/X11R6.3/gtk   \
+    /usr/local/include/X11R6.2       \
+    /usr/local/include/X11R6.2/gtk   \
+    /usr/local/include/X11R6.1       \
+    /usr/local/include/X11R6.1/gtk   \
+    /usr/local/include/X11R6         \
+    /usr/local/include/X11R6/gtk     \
+    /usr/local/include/X11R5         \
+    /usr/local/include/X11R5/gtk     \
+    /usr/local/include/X11R4         \
+    /usr/local/include/X11R4/gtk     \
+    /usr/local/include/X11           \
+    /usr/local/include/X11/gtk       \
+    /usr/local/include/X386          \
+    /usr/local/include/X386/gtk      \
+    /usr/local/include/x386          \
+    /usr/local/include/x386/gtk      \
+    /usr/local/include/XFree86       \
+    /usr/local/include/XFree86/gtk   \
+    /usr/local/dt/include            \
+    /usr/local/dt/include/gtk        \
+    /usr/dt/include                  \
+    /usr/dt/include/gtk              \
+    /usr/unsupported/include         \
+    /usr/unsupported/include/gtk     \
+    /usr/athena/include              \
+    /usr/athena/include/gtk          \
+    /usr/local/x11r5/include         \
+    /usr/local/x11r5/include/gtk     \
+    /usr/lpp/Xamples/include         \
+    /usr/lpp/Xamples/include/gtk     \
+    $extra_include                   \
+    ; \
+  do
+    if test -r "$ac_dir/$gtkfontsel_direct_test_include"; then
+      no_gtkfontsel= ac_gtkfontsel_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$gtkfontsel_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_gtkfontsel_includes" | sed s/include/lib/` \
+                                     \
+    /usr/X11R6.3/lib                 \
+    /usr/X11R6.2/lib                 \
+    /usr/X11R6.1/lib                 \
+    /usr/X11R6/lib                   \
+    /usr/lib/X11                     \
+    /usr/lib/X11/gtk                 \
+    /usr/gtk/lib                     \
+    /usr/X11/gtk/lib                 \
+    /usr/local/lib                   \
+    /usr/local/lib/X11               \
+    /usr/X11/local/lib               \
+    /usr/X11/local/lib/X11           \
+    /usr/X11/local/X11/lib           \
+    /usr/local/lib/gtk               \
+    /usr/local/lib/X11/gtk           \
+    /usr/X11/local/lib/gtk           \
+    /usr/X11/local/lib/X11/gtk       \
+    /usr/X11/local/X11/lib/gtk       \
+    /usr/local/gtk/lib               \
+    /usr/local/X11/gtk/lib           \
+    $extra_lib                       \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${gtkfontsel_direct_test_library}.$ac_extension; then
+      no_gtkfontsel= ac_gtkfontsel_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"
+  fi
+fi # with_gtkfontsel != no
+
+if test "$no_gtkfontsel" = yes; then
+  echo "$ac_t""no" 1>&6
+else
+  XGLOCKLIBS="-lgtkfontsel ${XGLOCKLIBS}"
+  test "x$gtkfontsel_includes" = xNONE && gtkfontsel_includes=$ac_gtkfontsel_includes
+  test "x$gtkfontsel_libraries" = xNONE && gtkfontsel_libraries=$ac_gtkfontsel_libraries
+  echo "$ac_t""libraries $gtkfontsel_libraries, headers $gtkfontsel_includes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_GTK_FONTSEL_WIDGET 1
+EOF
+
+fi
+
+
+  if test "x$gtkfontsel_libraries" != x && test "x$gtkfontsel_libraries" != xNONE ; then
+    XGLOCK_LDFLAGS="${XGLOCK_LDFLAGS}:$gtkfontsel_libraries"
+    XGLOCKLIBPATHS="${XGLOCKLIBPATHS} -L$gtkfontsel_libraries"
+  fi
+  if test "x$gtkfontsel_includes" != x && test "x$gtkfontsel_includes" != xNONE ; then
+    XGLOCKINC="${XGLOCKINC} -I$gtkfontsel_includes"
+  fi
+
+  if test -n "${x_includes}"; then
+    XGLOCKINC="-I${x_includes} ${XGLOCKINC}"
+    XGLOCK="xglock"
+    XGLOCKDIR="xglock"
+    INSTALL_XGLOCK="install_xglock"
+    UNINSTALL_XGLOCK="uninstall_xglock"
+    XGLOCK_MAKEFILE="xglock/Makefile"
+  fi
+  if test -n "${x_libraries}"; then
+    XGLOCK_LDFLAGS="${XGLOCK_LDFLAGS}:/usr/lib:${x_libraries}"
+    XGLOCKLIBPATHS="${XGLOCKLIBPATHS} -L${x_libraries}"
+    XGLOCKLIBS="${XGLOCKLIBS} -lXt"
+  fi
+fi
+
+
+
+aixv3=no
+dirent=yes
+
+case "${canonical}" in
+
+  *-*-aix* )
+    BITMAPTYPE="ibm"
+    PIXMAPTYPE="ibm"
+    cat >> confdefs.h <<\EOF
+#define AIXV3 1
+EOF
+
+    aixv3=yes
+    case "${canonical}" in
+      *-*-aix2* | *-*-aix3.0* | *-*-aix3.1* )
+        cat >> confdefs.h <<\EOF
+#define LESS_THAN_AIX3_2 1
+EOF
+
+      ;;
+    esac
+  ;;
+
+  *-*-freebsd* | *-*-openbsd* | *-*-netbsd*  )
+    BITMAPTYPE="bsd"
+    PIXMAPTYPE="bsd"
+    INSTPGMFLAGS="-s -o root -m 4111"
+    XLOCKLDFLAGS="-Wl,-R${XLOCK_LDFLAGS}"
+    XMLOCKLDFLAGS="-Wl,-R${XMLOCK_LDFLAGS}"
+    XALOCKLDFLAGS="-Wl,-R${XALOCK_LDFLAGS}"
+  ;;
+
+  *-*-dgux5* )
+    BITMAPTYPE="x11"
+    PIXMAPTYPE="x11"
+  ;;
+
+  *-*-hpux* )
+    if test "${CC}" = "cc" ; then
+      CFLAGS="${CFLAGS} -O -Aa -z -D_HPUX_SOURCE"
+      GPROF_CFLAGS="${GPROF_CFLAGS} -Aa -z -D_HPUX_SOURCE"
+    fi
+    XLOCKLIBS="-lXhp11 ${XLOCKLIBS}"
+    cat >> confdefs.h <<\EOF
+#define SYSV 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define SVR4 1
+EOF
+
+    BITMAPTYPE="hp"
+    PIXMAPTYPE="hp"
+  ;;
+
+  *-*-irix5* | *-*-irix6* )
+    if test "${CC}" = "cc" ; then
+      CFLAGS="${CFLAGS} -fullwarn"
+    fi
+    BITMAPTYPE="sgi"
+    PIXMAPTYPE="sgi"
+  ;;
+
+  *-*-linux* )
+    ac_safe=`echo "elf.h" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for elf.h""... $ac_c" 1>&6
+echo "configure:5855: checking for elf.h" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 5860 "configure"
+#include "confdefs.h"
+#include <elf.h>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:5865: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=yes"
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_SHADOW 1
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    cat >> confdefs.h <<\EOF
+#define linux 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define _POSIX_SOURCE 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define _BSD_SOURCE 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define _GNU_SOURCE 1
+EOF
+
+    if test -e /etc/shadow ; then
+      INSTPGMFLAGS="-g shadow -m 2111"
+      case `ls -l /etc/shadow` in
+        -???r?????\ *\ shadow\ *\ /etc/shadow)  # group shadow can read it
+          INSTPGMFLAGS="-g shadow -m 2111"
+          ;;
+        *)
+          INSTPGMFLAGS="-o root -m 4111"
+          ;;
+      esac
+    fi
+    INSTPGMFLAGS="-s $INSTPGMFLAGS"
+    BITMAPTYPE="linux"
+    PIXMAPTYPE="linux"
+  ;;
+
+  *-*-osf* )
+    BITMAPTYPE="dec"
+    PIXMAPTYPE="dec"
+    echo $ac_n "checking for Digital Unix Enhanced Security""... $ac_c" 1>&6
+echo "configure:5925: checking for Digital Unix Enhanced Security" >&5
+    if test -f /usr/sbin/rcmgr && test -f /etc/rc.config ; then
+      if test X`/usr/sbin/rcmgr get SECURITY` = XENHANCED ; then
+        echo "$ac_t""yes" 1>&6
+        cat >> confdefs.h <<\EOF
+#define OSF1_ENH_SEC 1
+EOF
+
+        
+        XLOCKLIBS="${XLOCKLIBS} -lsecurity"
+        INSTPGMFLAGS="-s -g auth -m 2111"
+      else
+        echo "$ac_t""no" 1>&6
+      fi
+    fi
+  ;;
+
+  *-*-sco* )
+    BITMAPTYPE="sco"
+    PIXMAPTYPE="sco"
+    cat >> confdefs.h <<\EOF
+#define HAVE_SHADOW 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define SYSV 1
+EOF
+
+  ;;
+
+  *-*-solaris2* )
+    cat >> confdefs.h <<\EOF
+#define SOLARIS2 1
+EOF
+
+    case "${canonical}" in
+      *-*-solaris2.0* | *-*-solaris2.1* | *-*-solaris2.2* | *-*-solaris2.3* | *-*-solaris2.4* )
+        cat >> confdefs.h <<\EOF
+#define LESS_THAN_SOLARIS2_5 1
+EOF
+
+      ;;
+    esac
+    INSTPGMFLAGS="-s -o root -m 4111"
+    cat >> confdefs.h <<\EOF
+#define HAVE_SHADOW 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define SYSV 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define SVR4 1
+EOF
+
+    BITMAPTYPE="sun"
+    PIXMAPTYPE="sol"
+    XLOCKLIBS="${XLOCKLIBS} -lposix4"
+    LIBS="${LIBS} -lsocket -lnsl -lposix4"
+    XLOCKLDFLAGS="-R${XLOCK_LDFLAGS}"
+    XMLOCKLDFLAGS="-R${XMLOCK_LDFLAGS}"
+    XALOCKLDFLAGS="-R${XALOCK_LDFLAGS}"
+  ;;
+
+  *-*-sunos4* )
+    cat >> confdefs.h <<\EOF
+#define SUNOS4 1
+EOF
+
+    BITMAPTYPE="sun"
+    PIXMAPTYPE="sun"
+  ;;
+
+  *-*-sysv5* )
+    BITMAPTYPE="x11"
+    PIXMAPTYPE="x11"
+  ;;
+
+  *)
+    BITMAPTYPE="x11"
+    PIXMAPTYPE="x11"
+  ;;
+esac
+
+
+if test "$dirent" = yes; then
+  ac_header_dirent=no
+for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
+do
+ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
+echo "configure:6017: checking for $ac_hdr that defines DIR" >&5
+if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6022 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+#include <$ac_hdr>
+int main() {
+DIR *dirp = 0;
+; return 0; }
+EOF
+if { (eval echo configure:6030: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  eval "ac_cv_header_dirent_$ac_safe=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_dirent_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_hdr 1
+EOF
+ ac_header_dirent=$ac_hdr; break
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
+if test $ac_header_dirent = dirent.h; then
+echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
+echo "configure:6055: checking for opendir in -ldir" >&5
+ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-ldir  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 6063 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char opendir();
+
+int main() {
+opendir()
+; return 0; }
+EOF
+if { (eval echo configure:6074: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  LIBS="$LIBS -ldir"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+else
+echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
+echo "configure:6096: checking for opendir in -lx" >&5
+ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lx  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 6104 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char opendir();
+
+int main() {
+opendir()
+; return 0; }
+EOF
+if { (eval echo configure:6115: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  LIBS="$LIBS -lx"
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+fi
+
+fi
+
+echo $ac_n "checking for usleep""... $ac_c" 1>&6
+echo "configure:6140: checking for usleep" >&5
+if eval "test \"`echo '$''{'ac_cv_func_usleep'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6145 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char usleep(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char usleep();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_usleep) || defined (__stub___usleep)
+choke me
+#else
+usleep();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:6168: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_usleep=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_usleep=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'usleep`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_USLEEP 1
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+echo $ac_n "checking for nanosleep""... $ac_c" 1>&6
+echo "configure:6189: checking for nanosleep" >&5
+if eval "test \"`echo '$''{'ac_cv_func_nanosleep'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6194 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char nanosleep(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char nanosleep();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_nanosleep) || defined (__stub___nanosleep)
+choke me
+#else
+nanosleep();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:6217: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_nanosleep=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_nanosleep=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'nanosleep`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_NANOSLEEP 1
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+fi
+
+
+echo $ac_n "checking how to call gettimeofday""... $ac_c" 1>&6
+echo "configure:6243: checking how to call gettimeofday" >&5
+if eval "test \"`echo '$''{'ac_cv_gettimeofday_args'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6248 "configure"
+#include "confdefs.h"
+#include <stdlib.h>
+#include <sys/time.h>
+int main() {
+struct timeval tv; struct timezone tzp;
+      gettimeofday(&tv, &tzp);
+; return 0; }
+EOF
+if { (eval echo configure:6257: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_gettimeofday_args=2
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  cat > conftest.$ac_ext <<EOF
+#line 6265 "configure"
+#include "confdefs.h"
+#include <stdlib.h>
+#include <sys/time.h>
+int main() {
+struct timeval tv; gettimeofday(&tv);
+; return 0; }
+EOF
+if { (eval echo configure:6273: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_gettimeofday_args=1
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_gettimeofday_args=0
+fi
+rm -f conftest*
+fi
+rm -f conftest*
+  ac_cv_gettimeofday_args=$ac_gettimeofday_args
+fi
+
+ac_gettimeofday_args=$ac_cv_gettimeofday_args
+if test $ac_gettimeofday_args = 2 ; then
+  cat >> confdefs.h <<\EOF
+#define HAVE_GETTIMEOFDAY 1
+EOF
+
+  cat >> confdefs.h <<\EOF
+#define GETTIMEOFDAY_TWO_ARGS 1
+EOF
+
+  echo "$ac_t""two arguments" 1>&6
+elif test $ac_gettimeofday_args = 1 ; then
+  cat >> confdefs.h <<\EOF
+#define HAVE_GETTIMEOFDAY 1
+EOF
+
+  echo "$ac_t""one argument" 1>&6
+else
+  echo "$ac_t""unknown" 1>&6
+fi
+for ac_func in tzset timelocal
+do
+echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
+echo "configure:6312: checking for $ac_func" >&5
+if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6317 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char $ac_func();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+$ac_func();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:6340: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_func 1
+EOF
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+
+
+echo $ac_n "checking for inline""... $ac_c" 1>&6
+echo "configure:6366: checking for inline" >&5
+if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_cv_c_inline=no
+for ac_kw in inline __inline__ __inline; do
+  cat > conftest.$ac_ext <<EOF
+#line 6373 "configure"
+#include "confdefs.h"
+
+int main() {
+} $ac_kw foo() {
+; return 0; }
+EOF
+if { (eval echo configure:6380: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_c_inline=$ac_kw; break
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+fi
+rm -f conftest*
+done
+
+fi
+
+echo "$ac_t""$ac_cv_c_inline" 1>&6
+case "$ac_cv_c_inline" in
+  inline | yes) ;;
+  no) cat >> confdefs.h <<\EOF
+#define inline 
+EOF
+ ;;
+  *)  cat >> confdefs.h <<EOF
+#define inline $ac_cv_c_inline
+EOF
+ ;;
+esac
+
+
+srand=no
+echo $ac_n "checking for srand48""... $ac_c" 1>&6
+echo "configure:6408: checking for srand48" >&5
+if eval "test \"`echo '$''{'ac_cv_func_srand48'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6413 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char srand48(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char srand48();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_srand48) || defined (__stub___srand48)
+choke me
+#else
+srand48();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:6436: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_srand48=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_srand48=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'srand48`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define SRAND srand48
+EOF
+ cat >> confdefs.h <<\EOF
+#define LRAND lrand48
+EOF
+
+  cat >> confdefs.h <<\EOF
+#define MAXRAND 2147483648.0
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+echo $ac_n "checking for srandom""... $ac_c" 1>&6
+echo "configure:6464: checking for srandom" >&5
+if eval "test \"`echo '$''{'ac_cv_func_srandom'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6469 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char srandom(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char srandom();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_srandom) || defined (__stub___srandom)
+choke me
+#else
+srandom();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:6492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_srandom=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_srandom=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'srandom`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define SRAND srandom
+EOF
+ cat >> confdefs.h <<\EOF
+#define LRAND random
+EOF
+
+  cat >> confdefs.h <<\EOF
+#define MAXRAND 2147483648.0
+EOF
+
+else
+  echo "$ac_t""no" 1>&6
+echo $ac_n "checking for srand""... $ac_c" 1>&6
+echo "configure:6520: checking for srand" >&5
+if eval "test \"`echo '$''{'ac_cv_func_srand'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 6525 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char srand(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char srand();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_srand) || defined (__stub___srand)
+choke me
+#else
+srand();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:6548: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_srand=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_srand=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'srand`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define SRAND srand
+EOF
+ cat >> confdefs.h <<\EOF
+#define LRAND rand
+EOF
+ srand=yes
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+fi
+
+fi
+
+
+if test "$srand" = yes; then
+  if test "$aixv3" = yes; then
+    cat >> confdefs.h <<\EOF
+#define MAXRAND 2147483648.0
+EOF
+
+  else
+    cat >> confdefs.h <<\EOF
+#define MAXRAND 32768.0
+EOF
+
+  fi
+fi
+
+echo $ac_n "checking matherr support""... $ac_c" 1>&6
+echo "configure:6593: checking matherr support" >&5
+if eval "test \"`echo '$''{'ac_cv_c_matherr'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+     
+cat > conftest.$ac_ext <<EOF
+#line 6599 "configure"
+#include "confdefs.h"
+#define _XOPEN_SOURCE 1
+#include <math.h>
+int main() {
+
+struct exception x;
+x.type = DOMAIN;  
+x.type = SING; 
+
+; return 0; }
+EOF
+if { (eval echo configure:6611: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_c_matherr=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_c_matherr=no
+fi
+rm -f conftest*
+fi
+
+if test x"$ac_cv_c_matherr" = xyes; then    
+    cat >> confdefs.h <<\EOF
+#define USE_MATHERR 1
+EOF
+
+    echo "$ac_t""yes" 1>&6
+else
+    echo "$ac_t""no" 1>&6
+fi
+
+echo $ac_n "checking struct sigset_t""... $ac_c" 1>&6
+echo "configure:6634: checking struct sigset_t" >&5
+if eval "test \"`echo '$''{'ac_cv_c_sigset_t'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+     
+cat > conftest.$ac_ext <<EOF
+#line 6640 "configure"
+#include "confdefs.h"
+/*#define _XOPEN_SOURCE 1*/
+#include <signal.h>
+int main() {
+
+typedef struct {unsigned long __sigbits[4];} sigset_t;
+sigset_t sigmask;
+
+; return 0; }
+EOF
+if { (eval echo configure:6651: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_c_sigset_t=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_c_sigset_t=no
+fi
+rm -f conftest*
+fi
+
+if test x"$ac_cv_c_sigset_t" = xyes; then    
+  cat >> confdefs.h <<\EOF
+#define HAVE_STRUCT_SIGSET_T 1
+EOF
+
+  echo "$ac_t""yes" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+# Check whether --enable-bitmapdir or --disable-bitmapdir was given.
+if test "${enable_bitmapdir+set}" = set; then
+  enableval="$enable_bitmapdir"
+  bitmap_dir=$enableval
+else
+  bitmap_dir=no
+fi
+
+case "x$bitmap_dir" in
+x/*|x.*)
+  echo "$ac_t""setting BITMAPDIR = $enableval" 1>&6
+  BITMAPDIR=$enableval
+  if test ! -d $bitmap_dir; then
+    echo "$ac_t""Warning: Directory $enableval does not exist" 1>&6
+  fi
+  ;;
+*)
+  BITMAPDIR='$(top_srcdir)/bitmaps'
+  bitmap_dir='$top_srcdir/bitmaps'
+  ;;
+esac
+
+# Check whether --enable-bitmaptype or --disable-bitmaptype was given.
+if test "${enable_bitmaptype+set}" = set; then
+  enableval="$enable_bitmaptype"
+  bitmap_type=$enableval
+else
+  bitmap_type=no
+fi
+
+case "x$bitmap_type" in
+xyes*|xno*)
+  ;;
+*)
+  echo "$ac_t""setting BITMAPTYPE = $enableval" 1>&6
+  BITMAPTYPE=$enableval
+  if test ! -f $bitmap_dir/l-$BITMAPTYPE.xbm; then
+    echo "$ac_t""Warning: Bitmap $BITMAPDIR/l-$BITMAPTYPE.xbm does not exist" 1>&6
+  fi
+  ;;
+esac
+
+# Check whether --enable-pixmapdir or --disable-pixmapdir was given.
+if test "${enable_pixmapdir+set}" = set; then
+  enableval="$enable_pixmapdir"
+  pixmap_dir=$enableval
+else
+  pixmap_dir=no
+fi
+
+case "x$pixmap_dir" in
+x/*|x.*)
+  echo "$ac_t""setting PIXMAPDIR = $enableval" 1>&6
+  PIXMAPDIR=$enableval
+  if test ! -d $pixmap_dir; then
+    echo "$ac_t""Warning: Directory $enableval does not exist" 1>&6
+  fi
+  ;;
+*)
+  PIXMAPDIR='$(top_srcdir)/pixmaps'
+  pixmap_dir='$top_srcdir/pixmaps'
+  ;;
+esac
+
+# Check whether --enable-pixmaptype or --disable-pixmaptype was given.
+if test "${enable_pixmaptype+set}" = set; then
+  enableval="$enable_pixmaptype"
+  pixmap_type=$enableval
+else
+  pixmap_type=no
+fi
+
+case "x$pixmap_type" in
+xyes*|xno*)
+  ;;
+*)
+  echo "$ac_t""setting PIXMAPTYPE = $enableval" 1>&6
+  PIXMAPTYPE=$enableval
+  if test ! -f $pixmap_dir/m-$PIXMAPTYPE.xpm; then
+    echo "$ac_t""Warning: Pixmap $PIXMAPDIR/m-$PIXMAPTYPE.xpm does not exist" 1>&6
+  fi
+  ;;
+esac
+
+# Check whether --enable-mapdir or --disable-mapdir was given.
+if test "${enable_mapdir+set}" = set; then
+  enableval="$enable_mapdir"
+  map_dir=$enableval
+else
+  map_dir=no
+fi
+
+case "x$map_dir" in
+x/*|x.*)
+  echo "$ac_t""setting BITMAPDIR = $enableval" 1>&6
+  BITMAPDIR=$enableval
+  echo "$ac_t""setting PIXMAPDIR = $enableval" 1>&6
+  PIXMAPDIR=$enableval
+  if test ! -d $map_dir; then
+    echo "$ac_t""Warning: Directory $enableval does not exist" 1>&6
+  fi
+  ;;
+*)
+  BITMAPDIR='$(top_srcdir)/bitmaps'
+  bitmap_dir='$top_srcdir/bitmaps'
+  PIXMAPDIR='$(top_srcdir)/pixmaps'
+  pixmap_dir='$top_srcdir/pixmaps'
+  ;;
+esac
+
+# Check whether --enable-maptype or --disable-maptype was given.
+if test "${enable_maptype+set}" = set; then
+  enableval="$enable_maptype"
+  map_type=$enableval
+else
+  map_type=no
+fi
+
+case "x$map_type" in
+xyes*|xno*)
+  ;;
+*)
+  echo "$ac_t""setting BITMAPTYPE = $enableval" 1>&6
+  BITMAPTYPE=$enableval
+  if test ! -f $map_dir/l-$BITMAPTYPE.xbm; then
+    echo "$ac_t""Warning: Bitmap $BITMAPDIR/l-$BITMAPTYPE.xbm does not exist" 1>&6
+  fi
+  echo "$ac_t""setting PIXMAPTYPE = $enableval" 1>&6
+  PIXMAPTYPE=$enableval
+  if test ! -f $map_dir/m-$PIXMAPTYPE.xpm; then
+    echo "$ac_t""Warning: Pixmap $PIXMAPDIR/m-$PIXMAPTYPE.xpm does not exist" 1>&6
+  fi
+  ;;
+esac
+
+if test "$sound" = no; then
+  # Check whether --enable-def_play or --disable-def_play was given.
+if test "${enable_def_play+set}" = set; then
+  enableval="$enable_def_play"
+  def_play=$enableval
+else
+  def_play=no
+fi
+
+  if test "$def_play" != no; then
+    echo "$ac_t""defining option DEF_PLAY = "$enableval"" 1>&6
+    cat >> confdefs.h <<EOF
+#define DEF_PLAY "$enableval"
+EOF
+
+  fi
+fi
+
+# Check whether --enable-vroot or --disable-vroot was given.
+if test "${enable_vroot+set}" = set; then
+  enableval="$enable_vroot"
+  use_vroot=$enableval
+else
+  use_vroot=yes
+fi
+
+if test "$use_vroot" = yes; then
+  echo "$ac_t""defining option USE_VROOT" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_VROOT 1
+EOF
+
+fi
+
+# Check whether --enable-allow-root or --disable-allow-root was given.
+if test "${enable_allow_root+set}" = set; then
+  enableval="$enable_allow_root"
+  allow_root=$enableval
+else
+  allow_root=yes
+fi
+
+if test "$allow_root" = yes; then
+  echo "$ac_t""defining option ALWAYS_ALLOW_ROOT" 1>&6
+  cat >> confdefs.h <<\EOF
+#define ALWAYS_ALLOW_ROOT 1
+EOF
+
+fi
+
+case ${canonical} in
+    *-*-linux* | *-*-freebsd* | *-*-openbsd* | *-*-netbsd*  )
+      # Check whether --enable-vtlock or --disable-vtlock was given.
+if test "${enable_vtlock+set}" = set; then
+  enableval="$enable_vtlock"
+  vtlock=$enableval
+else
+  vtlock=no
+fi
+
+      if test "$vtlock" = yes; then
+        echo "$ac_t""defining option USE_VTLOCK" 1>&6
+        cat >> confdefs.h <<\EOF
+#define USE_VTLOCK 1
+EOF
+
+      fi
+      ;;
+    *)
+      ;;
+esac
+
+# Check whether --enable-syslog or --disable-syslog was given.
+if test "${enable_syslog+set}" = set; then
+  enableval="$enable_syslog"
+  use_syslog=$enableval
+else
+  use_syslog=no
+fi
+
+if test "$use_syslog" = yes; then
+  echo "$ac_t""defining option USE_SYSLOG" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_SYSLOG 1
+EOF
+
+fi
+# Check whether --enable-multiple-user or --disable-multiple-user was given.
+if test "${enable_multiple_user+set}" = set; then
+  enableval="$enable_multiple_user"
+  use_multiple_user=$enableval
+else
+  use_multiple_user=no
+fi
+
+if test "$use_multiple_user" = yes; then
+  echo "$ac_t""defining option USE_MULTIPLE_USER" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_MULTIPLE_USER 1
+EOF
+
+fi
+# Check whether --enable-multiple-root or --disable-multiple-root was given.
+if test "${enable_multiple_root+set}" = set; then
+  enableval="$enable_multiple_root"
+  use_multiple_root=$enableval
+else
+  use_multiple_root=no
+fi
+
+if test "$use_multiple_root" = yes; then
+  echo "$ac_t""defining option USE_MULTIPLE_ROOT" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_MULTIPLE_ROOT 1
+EOF
+
+fi
+# Check whether --enable-window-visibility or --disable-window-visibility was given.
+if test "${enable_window_visibility+set}" = set; then
+  enableval="$enable_window_visibility"
+  use_window_visiblity=$enableval
+else
+  use_window_visibility=no
+fi
+
+if test "$use_window_visibility" = yes; then
+  echo "$ac_t""defining option USE_WINDOW_VISIBILITY" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_WINDOW_VISIBLITY 1
+EOF
+
+fi
+# Check whether --enable-old-event-loop or --disable-old-event-loop was given.
+if test "${enable_old_event_loop+set}" = set; then
+  enableval="$enable_old_event_loop"
+  use_old_event_loop=$enableval
+else
+  use_old_event_loop=no
+fi
+
+if test "$use_old_event_loop" = yes; then
+  echo "$ac_t""defining option USE_OLD_EVENT_LOOP" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_OLD_EVENT_LOOP 1
+EOF
+
+fi
+
+# Check whether --enable-xlockrc or --disable-xlockrc was given.
+if test "${enable_xlockrc+set}" = set; then
+  enableval="$enable_xlockrc"
+  use_xlockrc=$enableval
+else
+  use_xlockrc=no
+fi
+
+if test "$use_xlockrc" = yes; then
+  echo "$ac_t""defining option USE_XLOCKRC" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_XLOCKRC 1
+EOF
+
+fi
+# Check whether --enable-auto-logout or --disable-auto-logout was given.
+if test "${enable_auto_logout+set}" = set; then
+  enableval="$enable_auto_logout"
+  use_auto_logout=$enableval
+else
+  use_auto_logout=no
+fi
+
+case "x$use_auto_logout" in
+x|xyes*)
+  echo "$ac_t""defining option USE_AUTO_LOGOUT = 240 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_AUTO_LOGOUT 240
+EOF
+
+  ;;
+x[0-9]*)
+  echo "$ac_t""defining option USE_AUTO_LOGOUT = $enableval minutes" 1>&6
+  cat >> confdefs.h <<EOF
+#define USE_AUTO_LOGOUT $enableval
+EOF
+
+  ;;
+xno*)
+  ;;
+*)
+  echo "$ac_t""Warning: Illegal time value "$use_auto_logout" given" 1>&6
+  echo "$ac_t""defining option USE_AUTO_LOGOUT = 240 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_AUTO_LOGOUT 240
+EOF
+
+  ;;
+esac
+# Check whether --enable-default-auto-logout or --disable-default-auto-logout was given.
+if test "${enable_default_auto_logout+set}" = set; then
+  enableval="$enable_default_auto_logout"
+  def_auto_logout=$enableval
+else
+  def_auto_logout=no
+fi
+
+case "x$def_auto_logout" in
+x|xyes*)
+  echo "$ac_t""defining option DEF_AUTO_LOGOUT = 120 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define DEF_AUTO_LOGOUT "120"
+EOF
+
+  ;;
+x[0-9]*)
+  echo "$ac_t""defining option DEF_AUTO_LOGOUT = $enableval minutes" 1>&6
+  cat >> confdefs.h <<EOF
+#define DEF_AUTO_LOGOUT "$enableval"
+EOF
+
+  ;;
+xno*)
+  ;;
+*)
+  echo "$ac_t""Warning: Illegal time value "$def_auto_logout" given" 1>&6
+  echo "$ac_t""defining option DEF_AUTO_LOGOUT = 120 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define DEF_AUTO_LOGOUT "120"
+EOF
+
+  ;;
+esac
+# Check whether --enable-button-logout or --disable-button-logout was given.
+if test "${enable_button_logout+set}" = set; then
+  enableval="$enable_button_logout"
+  use_button_logout=$enableval
+else
+  use_button_logout=no
+fi
+
+case "x$use_button_logout" in
+x|xyes*)
+  echo "$ac_t""defining option USE_BUTTON_LOGOUT = 10 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_BUTTON_LOGOUT 10
+EOF
+
+  ;;
+x[0-9]*)
+  echo "$ac_t""defining option USE_BUTTON_LOGOUT = $enableval minutes" 1>&6
+  cat >> confdefs.h <<EOF
+#define USE_BUTTON_LOGOUT $enableval
+EOF
+
+  ;;
+xno*)
+  ;;
+*)
+  echo "$ac_t""Warning: Illegal time value "$use_button_logout" given" 1>&6
+  echo "$ac_t""defining option USE_BUTTON_LOGOUT = 10 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_BUTTON_LOGOUT 10
+EOF
+
+  ;;
+esac
+# Check whether --enable-default-button-logout or --disable-default-button-logout was given.
+if test "${enable_default_button_logout+set}" = set; then
+  enableval="$enable_default_button_logout"
+  def_button_logout=$enableval
+else
+  def_button_logout=no
+fi
+
+case "x$def_button_logout" in
+x|xyes*)
+  echo "$ac_t""defining option DEF_BUTTON_LOGOUT = 5 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define DEF_BUTTON_LOGOUT "5"
+EOF
+
+  ;;
+x[0-9]*)
+  echo "$ac_t""defining option DEF_BUTTON_LOGOUT = $enableval minutes" 1>&6
+  cat >> confdefs.h <<EOF
+#define DEF_BUTTON_LOGOUT "$enableval"
+EOF
+
+  ;;
+xno*)
+  ;;
+*)
+  echo "$ac_t""Warning: Illegal time value "$def_button_logout" given" 1>&6
+  echo "$ac_t""defining option DEF_BUTTON_LOGOUT = 5 minutes" 1>&6
+  cat >> confdefs.h <<\EOF
+#define DEF_BUTTON_LOGOUT "5"
+EOF
+
+  ;;
+esac
+
+# Check whether --enable-bomb or --disable-bomb was given.
+if test "${enable_bomb+set}" = set; then
+  enableval="$enable_bomb"
+  use_bomb=$enableval
+else
+  use_bomb=yes
+fi
+
+if test "$use_bomb" = yes; then
+  echo "$ac_t""defining option USE_BOMB" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_BOMB 1
+EOF
+
+  BOMB=""
+else
+  BOMB="#"
+fi
+
+# Check whether --enable-unstable or --disable-unstable was given.
+if test "${enable_unstable+set}" = set; then
+  enableval="$enable_unstable"
+  use_unstable=$enableval
+else
+  use_unstable=no
+fi
+
+if test "$use_unstable" = yes; then
+  echo "$ac_t""defining option USE_UNSTABLE" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_UNSTABLE 1
+EOF
+
+  UNSTABLE=""
+else
+  UNSTABLE="#"
+fi
+
+# Check whether --enable-closedown-logout or --disable-closedown-logout was given.
+if test "${enable_closedown_logout+set}" = set; then
+  enableval="$enable_closedown_logout"
+  closedown_logout=$enableval
+else
+  closedown_logout=no
+fi
+
+if test "$closedown_logout" = yes; then
+  echo "$ac_t""defining option CLOSEDOWN_LOGOUT" 1>&6
+  cat >> confdefs.h <<\EOF
+#define CLOSEDOWN_LOGOUT 1
+EOF
+
+fi
+# Check whether --enable-session-logout or --disable-session-logout was given.
+if test "${enable_session_logout+set}" = set; then
+  enableval="$enable_session_logout"
+  session_logout=$enableval
+else
+  session_logout=no
+fi
+
+if test "$session_logout" = yes; then
+  echo "$ac_t""defining option SESSION_LOGOUT" 1>&6
+  cat >> confdefs.h <<\EOF
+#define SESSION_LOGOUT 1
+EOF
+
+fi
+# Check whether --enable-staff-file or --disable-staff-file was given.
+if test "${enable_staff_file+set}" = set; then
+  enableval="$enable_staff_file"
+  use_staff_file=$enableval
+else
+  use_staff_file=no
+fi
+
+case "x$use_staff_file" in
+x|xyes*)
+  echo "$ac_t""defining option STAFF_FILE = "/usr/remote/etc/xlock.staff"" 1>&6
+  cat >> confdefs.h <<EOF
+#define STAFF_FILE "/usr/remote/etc/xlock.staff"
+EOF
+
+  if test ! -f /usr/remote/etc/xlock.staff; then
+    echo "$ac_t""Warning: File /usr/remote/etc/xlock.staff does not exist" 1>&6
+  fi
+  ;;
+x/*)
+  echo "$ac_t""defining option STAFF_FILE = "$enableval"" 1>&6
+  cat >> confdefs.h <<EOF
+#define STAFF_FILE "$enableval"
+EOF
+
+  if test ! -f $use_staff_file; then
+    echo "$ac_t""Warning: File $enableval does not exist" 1>&6
+  fi
+  ;;
+esac
+# Check whether --enable-staff-netgroup or --disable-staff-netgroup was given.
+if test "${enable_staff_netgroup+set}" = set; then
+  enableval="$enable_staff_netgroup"
+  use_staff_netgroup=$enableval
+else
+  use_staff_netgroup=no
+fi
+
+if test "$use_staff_netgroup" != no; then
+  echo "$ac_t""defining option STAFF_NETGROUP = "$enableval"" 1>&6
+  cat >> confdefs.h <<EOF
+#define STAFF_NETGROUP "$enableval"
+EOF
+
+fi
+# Check whether --enable-kerberos4 or --disable-kerberos4 was given.
+if test "${enable_kerberos4+set}" = set; then
+  enableval="$enable_kerberos4"
+  kerberos4=$enableval
+else
+  kerberos4=no
+fi
+
+if test "$kerberos4" = yes; then
+  echo "$ac_t""defining option HAVE_KRB4" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_KRB4 1
+EOF
+
+  XLOCKINC="${XLOCKINC} -I/usr/athena/include"
+  XLOCKLIBS="${XLOCKLIBS} -L/usr/athena/lib -lkrb -ldes"
+fi
+
+# Check whether --enable-kerberos5 or --disable-kerberos5 was given.
+if test "${enable_kerberos5+set}" = set; then
+  enableval="$enable_kerberos5"
+  kerberos5=$enableval
+else
+  kerberos5=no
+fi
+
+if test "$kerberos5" = yes; then
+  echo "$ac_t""defining option HAVE_KRB5" 1>&6
+  cat >> confdefs.h <<\EOF
+#define HAVE_KRB5 1
+EOF
+
+  XLOCKINC="${XLOCKINC} -I/usr/local/include"
+  XLOCKLIBS="${XLOCKLIBS} -L/usr/local/lib -lkrb5 -lcrypto -lcom_err"
+fi
+
+# Check whether --enable-dce_passwd or --disable-dce_passwd was given.
+if test "${enable_dce_passwd+set}" = set; then
+  enableval="$enable_dce_passwd"
+  dce_passwd=$enableval
+else
+  dce_passwd=no
+fi
+
+if test "$dce_passwd" = yes; then
+  echo "$ac_t""defining option DCE_PASSWD" 1>&6
+  cat >> confdefs.h <<\EOF
+#define DCE_PASSWD 1
+EOF
+
+  XLOCKINC="${XLOCKINC} -I/usr/include/reentrant"
+  XLOCKLIBS="${XLOCKLIBS} -ldce -lc_r"
+fi
+
+# Check whether --enable-pam or --disable-pam was given.
+if test "${enable_pam+set}" = set; then
+  enableval="$enable_pam"
+  pam=$enableval
+else
+  pam=no
+fi
+
+if test "$pam" = yes; then
+  echo "$ac_t""defining option PAM" 1>&6
+  cat >> confdefs.h <<\EOF
+#define PAM 1
+EOF
+
+  XLOCKLIBS="${XLOCKLIBS} -lpam -ldl"
+fi
+
+# Check whether --enable-afs or --disable-afs was given.
+if test "${enable_afs+set}" = set; then
+  enableval="$enable_afs"
+  afs=$enableval
+else
+  afs=no
+fi
+
+if test "$afs" = yes; then
+  echo "$ac_t""defining option AFS" 1>&6
+  cat >> confdefs.h <<\EOF
+#define AFS 1
+EOF
+
+  XLOCKINC="${XLOCKINC} -I/usr/afsws/include"
+  case "${canonical}" in
+    *-*-solaris2.* )
+      XLOCKLIBS="${XLOCKLIBS} -lucb -L/usr/afsws/lib -L/usr/afsws/lib/afs -lkauth.krb -lprot -lubik -lauth.krb -lrxkad -lsys -ldes -lrx -llwp -lcom_err -lcmd /usr/afsws/lib/afs/util.a -laudit -lsys"
+    ;;
+    * )
+      XLOCKLIBS="${XLOCKLIBS} -L/usr/afsws/lib -L/usr/afsws/lib/afs -lkauth -lubik -lprot -lrxkad -lrx -llwp -lauth -lsys -ldes -lcmd -lcom_err /usr/afsws/lib/afs/util.a -laudit"
+    ;;
+  esac
+fi
+
+# Check whether --enable-sunos_adjunct_passwd or --disable-sunos_adjunct_passwd was given.
+if test "${enable_sunos_adjunct_passwd+set}" = set; then
+  enableval="$enable_sunos_adjunct_passwd"
+  sunos_adjunct_passwd=$enableval
+else
+  sunos_adjunct_passwd=no
+fi
+
+if test "$sunos_adjunct_passwd" = yes; then
+  echo "$ac_t""defining option SUNOS_ADJUNCT_PASSWD" 1>&6
+  cat >> confdefs.h <<\EOF
+#define SUNOS_ADJUNCT_PASSWD 1
+EOF
+
+fi
+
+# Check whether --enable-use_mb or --disable-use_mb was given.
+if test "${enable_use_mb+set}" = set; then
+  enableval="$enable_use_mb"
+  use_mb=$enableval
+else
+  use_mb=no
+fi
+
+if test "$use_mb" = yes; then
+  echo "$ac_t""defining option USE_MB" 1>&6
+  cat >> confdefs.h <<\EOF
+#define USE_MB 1
+EOF
+
+fi
+
+# Check whether --enable-customization or --disable-customization was given.
+if test "${enable_customization+set}" = set; then
+  enableval="$enable_customization"
+  customization=$enableval
+else
+  customization=no
+fi
+
+if test "$customization" = yes; then
+  echo "$ac_t""defining option CUSTOMIZATION" 1>&6
+  cat >> confdefs.h <<\EOF
+#define CUSTOMIZATION 1
+EOF
+
+fi
+
+# Check whether --enable-modules or --disable-modules was given.
+if test "${enable_modules+set}" = set; then
+  enableval="$enable_modules"
+  modules=$enableval
+else
+  modules=no
+fi
+
+if test "$modules" = yes; then
+  echo "$ac_t""enabling xlk modules" 1>&6
+  MODULES=""
+else
+  MODULES="#"
+fi
+
+# Check whether --enable-check or --disable-check was given.
+if test "${enable_check+set}" = set; then
+  enableval="$enable_check"
+  check=$enableval
+else
+  check=no
+fi
+
+if test "$check" = yes; then
+  echo "$ac_t""enabling memory debug checking" 1>&6
+  CHECK=""
+else
+  CHECK="#"
+fi
+
+# Check whether --with-lang or --without-lang was given.
+if test "${with_lang+set}" = set; then
+  withval="$with_lang"
+  lang=$withval
+else
+  lang=none
+fi
+
+case "$lang" in
+  nl|NL|Nl)
+    echo "$ac_t""enabling some reporting in Dutch" 1>&6
+    cat >> confdefs.h <<\EOF
+#define NL 1
+EOF
+
+    ;;
+  fr|FR|Fr)
+    echo "$ac_t""enabling some reporting in French" 1>&6
+    cat >> confdefs.h <<\EOF
+#define FR 1
+EOF
+
+    ;;
+  de|DE|De)
+    echo "$ac_t""enabling some reporting in German" 1>&6
+    cat >> confdefs.h <<\EOF
+#define DE 1
+EOF
+
+    ;;
+  none)
+    echo "$ac_t""using default language (English)" 1>&6
+    ;;
+  *)
+    echo "$ac_t""unknown language $lang. using default language (English)" 1>&6
+    ;;
+esac
+
+# Check whether --enable-orig_xpm_patch or --disable-orig_xpm_patch was given.
+if test "${enable_orig_xpm_patch+set}" = set; then
+  enableval="$enable_orig_xpm_patch"
+  orig_xpm_patch=$enableval
+else
+  orig_xpm_patch=no
+fi
+
+if test "$orig_xpm_patch" = "yes"; then
+  echo "$ac_t""enabling original mail icon xpm patch" 1>&6
+  cat >> confdefs.h <<\EOF
+#define ORIGINAL_XPM_PATCH 1
+EOF
+
+fi
+
+if test "x$INSTPGMFLAGS" != x; then
+# Check whether --enable-setuid or --disable-setuid was given.
+if test "${enable_setuid+set}" = set; then
+  enableval="$enable_setuid"
+  setuid=$enableval
+else
+  setuid=yes
+fi
+
+case "x$setuid" in
+xno*)
+  case ${canonical} in
+  *-*-linux*)
+    if test "$vtlock" = "yes"; then
+      INSTPGMFLAGS="-s -o root -g bin -m 4111"
+      echo "$ac_t""defining install options (setuid/setgid) = "$INSTPGMFLAGS" for vtlock" 1>&6
+       echo "experimental: Big buffer overrun security risk"
+    else
+  INSTPGMFLAGS=""
+  echo "$ac_t""no setuid/setgid install" 1>&6
+    fi
+    ;;
+  *)
+  INSTPGMFLAGS=""
+  echo "$ac_t""no setuid/setgid install" 1>&6
+  ;;
+  esac
+  ;;
+x|xyes*)
+  case ${canonical} in
+  *-*-linux*)
+    if test "$vtlock" = "yes"; then
+      INSTPGMFLAGS="-s -o root -g bin -m 4111"
+      echo "$ac_t""defining install options (setuid/setgid) = "$INSTPGMFLAGS" for vtlock" 1>&6
+    else
+  echo "$ac_t""defining install options (setuid/setgid) = "$INSTPGMFLAGS"" 1>&6
+    fi
+    ;;
+  *)
+  echo "$ac_t""defining install options (setuid/setgid) = "$INSTPGMFLAGS"" 1>&6
+  ;;
+  esac
+  ;;
+x*)
+  INSTPGMFLAGS=$enableval
+  echo "$ac_t""defining install options (setuid/setgid) = "$enableval"" 1>&6
+  ;;
+esac
+else
+  echo "$ac_t""no setuid/setgid install" 1>&6
+fi
+
+DEPEND=makedepend
+DEPEND_FLAGS=
+DEPEND_DEFINES=
+
+XLOCKLIBS="${XLOCKLIBPATHS} ${XLOCKLIBS} -lX11 -lXext -lm"
+XMLOCKLIBS="${XMLOCKLIBPATHS} ${XMLOCKLIBS} -lX11"
+XALOCKLIBS="${XALOCKLIBPATHS} ${XALOCKLIBS} -lX11"
+XGLOCKLIBS="${XGLOCKLIBPATHS} ${XGLOCKLIBS} ${GTK_LIBS}"
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+trap '' 1 2 15
+cat > confcache <<\EOF
+# This file is a shell script that caches the results of configure
+# tests run on this system so they can be shared between configure
+# scripts and configure runs.  It is not useful on other systems.
+# If it contains results you don't want to keep, you may remove or edit it.
+#
+# By default, configure uses ./config.cache as the cache file,
+# creating it if it does not exist already.  You can give configure
+# the --cache-file=FILE option to use a different cache file; that is
+# what configure does when it calls configure scripts in
+# subdirectories, so they share the cache.
+# Giving --cache-file=/dev/null disables caching, for debugging configure.
+# config.status only pays attention to the cache file if you give it the
+# --recheck option to rerun configure.
+#
+EOF
+# The following way of writing the cache mishandles newlines in values,
+# but we know of no workaround that is simple, portable, and efficient.
+# So, don't put newlines in cache variables' values.
+# Ultrix sh set writes to stderr and can't be redirected directly,
+# and sets the high bit in the cache file unless we assign to the vars.
+(set) 2>&1 |
+  case `(ac_space=' '; set) 2>&1` in
+  *ac_space=\ *)
+    # `set' does not quote correctly, so add quotes (double-quote substitution
+    # turns \\\\ into \\, and sed turns \\ into \).
+    sed -n \
+      -e "s/'/'\\\\''/g" \
+      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
+    ;;
+  *)
+    # `set' quotes correctly as required by POSIX, so do not add quotes.
+    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
+    ;;
+  esac >> confcache
+if cmp -s $cache_file confcache; then
+  :
+else
+  if test -w $cache_file; then
+    echo "updating cache $cache_file"
+    cat confcache > $cache_file
+  else
+    echo "not updating unwritable cache $cache_file"
+  fi
+fi
+rm -f confcache
+
+trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
+
+test "x$prefix" = xNONE && prefix=$ac_default_prefix
+# Let make expand exec_prefix.
+test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
+
+# Any assignment to VPATH causes Sun make to only execute
+# the first set of double-colon rules, so remove it if not needed.
+# If there is a colon in the path, we need to keep it.
+if test "x$srcdir" = x.; then
+  ac_vpsub='/^[        ]*VPATH[        ]*=[^:]*$/d'
+fi
+
+trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
+
+DEFS=-DHAVE_CONFIG_H
+
+# Without the "./", some shells look in PATH for config.status.
+: ${CONFIG_STATUS=./config.status}
+
+echo creating $CONFIG_STATUS
+rm -f $CONFIG_STATUS
+cat > $CONFIG_STATUS <<EOF
+#! /bin/sh
+# Generated automatically by configure.
+# Run this file to recreate the current configuration.
+# This directory was configured as follows,
+# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
+#
+# $0 $ac_configure_args
+#
+# Compiler output produced by configure, useful for debugging
+# configure, is in ./config.log if it exists.
+
+ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
+for ac_option
+do
+  case "\$ac_option" in
+  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
+    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
+    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
+  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
+    echo "$CONFIG_STATUS generated by autoconf version 2.12"
+    exit 0 ;;
+  -help | --help | --hel | --he | --h)
+    echo "\$ac_cs_usage"; exit 0 ;;
+  *) echo "\$ac_cs_usage"; exit 1 ;;
+  esac
+done
+
+ac_given_srcdir=$srcdir
+ac_given_INSTALL="$INSTALL"
+
+trap 'rm -fr `echo "Makefile
+    xlock/Makefile
+    modes/Makefile
+    modes/glx/Makefile
+    xmlock/Makefile
+    xalock/Makefile
+    xglock/Makefile
+   config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+EOF
+cat >> $CONFIG_STATUS <<EOF
+
+# Protect against being on the right side of a sed subst in config.status.
+sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
+ s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
+$ac_vpsub
+$extrasub
+s%@CFLAGS@%$CFLAGS%g
+s%@CPPFLAGS@%$CPPFLAGS%g
+s%@CXXFLAGS@%$CXXFLAGS%g
+s%@DEFS@%$DEFS%g
+s%@LDFLAGS@%$LDFLAGS%g
+s%@LIBS@%$LIBS%g
+s%@exec_prefix@%$exec_prefix%g
+s%@prefix@%$prefix%g
+s%@program_transform_name@%$program_transform_name%g
+s%@bindir@%$bindir%g
+s%@sbindir@%$sbindir%g
+s%@libexecdir@%$libexecdir%g
+s%@datadir@%$datadir%g
+s%@sysconfdir@%$sysconfdir%g
+s%@sharedstatedir@%$sharedstatedir%g
+s%@localstatedir@%$localstatedir%g
+s%@libdir@%$libdir%g
+s%@includedir@%$includedir%g
+s%@oldincludedir@%$oldincludedir%g
+s%@infodir@%$infodir%g
+s%@mandir@%$mandir%g
+s%@host@%$host%g
+s%@host_alias@%$host_alias%g
+s%@host_cpu@%$host_cpu%g
+s%@host_vendor@%$host_vendor%g
+s%@host_os@%$host_os%g
+s%@CC@%$CC%g
+s%@CXX@%$CXX%g
+s%@PACKAGE@%$PACKAGE%g
+s%@VERSION@%$VERSION%g
+s%@LN_S@%$LN_S%g
+s%@CPP@%$CPP%g
+s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
+s%@INSTALL_DATA@%$INSTALL_DATA%g
+s%@SET_MAKE@%$SET_MAKE%g
+s%@X_CFLAGS@%$X_CFLAGS%g
+s%@X_PRE_LIBS@%$X_PRE_LIBS%g
+s%@X_LIBS@%$X_LIBS%g
+s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
+s%@GTK_CONFIG@%$GTK_CONFIG%g
+s%@GTK_CFLAGS@%$GTK_CFLAGS%g
+s%@GTK_LIBS@%$GTK_LIBS%g
+s%@OSF1_ENH_SEC@%$OSF1_ENH_SEC%g
+s%@XLOCKLDFLAGS@%$XLOCKLDFLAGS%g
+s%@XMLOCKLDFLAGS@%$XMLOCKLDFLAGS%g
+s%@XALOCKLDFLAGS@%$XALOCKLDFLAGS%g
+s%@XGLOCKLDFLAGS@%$XGLOCKLDFLAGS%g
+s%@INSTPGMFLAGS@%$INSTPGMFLAGS%g
+s%@XLOCKINC@%$XLOCKINC%g
+s%@XMLOCKINC@%$XMLOCKINC%g
+s%@XALOCKINC@%$XALOCKINC%g
+s%@XGLOCKINC@%$XGLOCKINC%g
+s%@XLIBS@%$XLIBS%g
+s%@BITMAPTYPE@%$BITMAPTYPE%g
+s%@PIXMAPTYPE@%$PIXMAPTYPE%g
+s%@BITMAPDIR@%$BITMAPDIR%g
+s%@PIXMAPDIR@%$PIXMAPDIR%g
+s%@XLOCKLIBS@%$XLOCKLIBS%g
+s%@XMLOCKLIBS@%$XMLOCKLIBS%g
+s%@XALOCKLIBS@%$XALOCKLIBS%g
+s%@XGLOCKLIBS@%$XGLOCKLIBS%g
+s%@XMLOCK@%$XMLOCK%g
+s%@XALOCK@%$XALOCK%g
+s%@XGLOCK@%$XGLOCK%g
+s%@XGLOCKDIR@%$XGLOCKDIR%g
+s%@INSTALL_XMLOCK@%$INSTALL_XMLOCK%g
+s%@INSTALL_XALOCK@%$INSTALL_XALOCK%g
+s%@INSTALL_XGLOCK@%$INSTALL_XGLOCK%g
+s%@UNINSTALL_XMLOCK@%$UNINSTALL_XMLOCK%g
+s%@UNINSTALL_XALOCK@%$UNINSTALL_XALOCK%g
+s%@UNINSTALL_XGLOCK@%$UNINSTALL_XGLOCK%g
+s%@APPDEFAULTS@%$APPDEFAULTS%g
+s%@LINT@%$LINT%g
+s%@CHECK@%$CHECK%g
+s%@PURIFY@%$PURIFY%g
+s%@XPM@%$XPM%g
+s%@GL@%$GL%g
+s%@GLTT@%$GLTT%g
+s%@BOMB@%$BOMB%g
+s%@UNSTABLE@%$UNSTABLE%g
+s%@DEPEND@%$DEPEND%g
+s%@DEPEND_FLAGS@%$DEPEND_FLAGS%g
+s%@DEPEND_DEFINES@%$DEPEND_DEFINES%g
+s%@CCC@%$CCC%g
+
+CEOF
+EOF
+
+cat >> $CONFIG_STATUS <<\EOF
+
+# Split the substitutions into bite-sized pieces for seds with
+# small command number limits, like on Digital OSF/1 and HP-UX.
+ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
+ac_file=1 # Number of current file.
+ac_beg=1 # First line for current file.
+ac_end=$ac_max_sed_cmds # Line after last line for current file.
+ac_more_lines=:
+ac_sed_cmds=""
+while $ac_more_lines; do
+  if test $ac_beg -gt 1; then
+    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
+  else
+    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
+  fi
+  if test ! -s conftest.s$ac_file; then
+    ac_more_lines=false
+    rm -f conftest.s$ac_file
+  else
+    if test -z "$ac_sed_cmds"; then
+      ac_sed_cmds="sed -f conftest.s$ac_file"
+    else
+      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
+    fi
+    ac_file=`expr $ac_file + 1`
+    ac_beg=$ac_end
+    ac_end=`expr $ac_end + $ac_max_sed_cmds`
+  fi
+done
+if test -z "$ac_sed_cmds"; then
+  ac_sed_cmds=cat
+fi
+EOF
+
+cat >> $CONFIG_STATUS <<EOF
+
+CONFIG_FILES=\${CONFIG_FILES-"Makefile
+    xlock/Makefile
+    modes/Makefile
+    modes/glx/Makefile
+    xmlock/Makefile
+    xalock/Makefile
+    xglock/Makefile
+  "}
+EOF
+cat >> $CONFIG_STATUS <<\EOF
+for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
+  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
+  case "$ac_file" in
+  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
+       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
+  *) ac_file_in="${ac_file}.in" ;;
+  esac
+
+  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
+
+  # Remove last slash and all that follows it.  Not all systems have dirname.
+  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
+  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
+    # The file is in a subdirectory.
+    test ! -d "$ac_dir" && mkdir "$ac_dir"
+    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
+    # A "../" for each directory in $ac_dir_suffix.
+    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
+  else
+    ac_dir_suffix= ac_dots=
+  fi
+
+  case "$ac_given_srcdir" in
+  .)  srcdir=.
+      if test -z "$ac_dots"; then top_srcdir=.
+      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
+  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
+  *) # Relative path.
+    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
+    top_srcdir="$ac_dots$ac_given_srcdir" ;;
+  esac
+
+  case "$ac_given_INSTALL" in
+  [/$]*) INSTALL="$ac_given_INSTALL" ;;
+  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
+  esac
+
+  echo creating "$ac_file"
+  rm -f "$ac_file"
+  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
+  case "$ac_file" in
+  *Makefile*) ac_comsub="1i\\
+# $configure_input" ;;
+  *) ac_comsub= ;;
+  esac
+
+  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
+  sed -e "$ac_comsub
+s%@configure_input@%$configure_input%g
+s%@srcdir@%$srcdir%g
+s%@top_srcdir@%$top_srcdir%g
+s%@INSTALL@%$INSTALL%g
+" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
+fi; done
+rm -f conftest.s*
+
+# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
+# NAME is the cpp macro being defined and VALUE is the value it is being given.
+#
+# ac_d sets the value in "#define NAME VALUE" lines.
+ac_dA='s%^\([  ]*\)#\([        ]*define[       ][      ]*\)'
+ac_dB='\([     ][      ]*\)[^  ]*%\1#\2'
+ac_dC='\3'
+ac_dD='%g'
+# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
+ac_uA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
+ac_uB='\([     ]\)%\1#\2define\3'
+ac_uC=' '
+ac_uD='\4%g'
+# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
+ac_eA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
+ac_eB='$%\1#\2define\3'
+ac_eC=' '
+ac_eD='%g'
+
+if test "${CONFIG_HEADERS+set}" != set; then
+EOF
+cat >> $CONFIG_STATUS <<EOF
+  CONFIG_HEADERS="config.h"
+EOF
+cat >> $CONFIG_STATUS <<\EOF
+fi
+for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
+  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
+  case "$ac_file" in
+  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
+       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
+  *) ac_file_in="${ac_file}.in" ;;
+  esac
+
+  echo creating $ac_file
+
+  rm -f conftest.frag conftest.in conftest.out
+  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
+  cat $ac_file_inputs > conftest.in
+
+EOF
+
+# Transform confdefs.h into a sed script conftest.vals that substitutes
+# the proper values into config.h.in to produce config.h.  And first:
+# Protect against being on the right side of a sed subst in config.status.
+# Protect against being in an unquoted here document in config.status.
+rm -f conftest.vals
+cat > conftest.hdr <<\EOF
+s/[\\&%]/\\&/g
+s%[\\$`]%\\&%g
+s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
+s%ac_d%ac_u%gp
+s%ac_u%ac_e%gp
+EOF
+sed -n -f conftest.hdr confdefs.h > conftest.vals
+rm -f conftest.hdr
+
+# This sed command replaces #undef with comments.  This is necessary, for
+# example, in the case of _POSIX_SOURCE, which is predefined and required
+# on some systems where configure will not decide to define it.
+cat >> conftest.vals <<\EOF
+s%^[   ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
+EOF
+
+# Break up conftest.vals because some shells have a limit on
+# the size of here documents, and old seds have small limits too.
+
+rm -f conftest.tail
+while :
+do
+  ac_lines=`grep -c . conftest.vals`
+  # grep -c gives empty output for an empty file on some AIX systems.
+  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
+  # Write a limited-size here document to conftest.frag.
+  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
+  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
+  echo 'CEOF
+  sed -f conftest.frag conftest.in > conftest.out
+  rm -f conftest.in
+  mv conftest.out conftest.in
+' >> $CONFIG_STATUS
+  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
+  rm -f conftest.vals
+  mv conftest.tail conftest.vals
+done
+rm -f conftest.vals
+
+cat >> $CONFIG_STATUS <<\EOF
+  rm -f conftest.frag conftest.h
+  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
+  cat conftest.in >> conftest.h
+  rm -f conftest.in
+  if cmp -s $ac_file conftest.h 2>/dev/null; then
+    echo "$ac_file is unchanged"
+    rm -f conftest.h
+  else
+    # Remove last slash and all that follows it.  Not all systems have dirname.
+      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
+      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
+      # The file is in a subdirectory.
+      test ! -d "$ac_dir" && mkdir "$ac_dir"
+    fi
+    rm -f $ac_file
+    mv conftest.h $ac_file
+  fi
+fi; done
+
+EOF
+cat >> $CONFIG_STATUS <<EOF
+
+EOF
+cat >> $CONFIG_STATUS <<\EOF
+
+exit 0
+EOF
+chmod +x $CONFIG_STATUS
+rm -fr confdefs* $ac_clean_files
+test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
+
diff --git a/xlockmore-4.14/configure.in b/xlockmore-4.14/configure.in
new file mode 100644 (file)
index 0000000..722f5b4
--- /dev/null
@@ -0,0 +1,3687 @@
+dnl Process this file with autoconf to produce a configure script.
+dnl configure.in for xlockmore.  Various things were taken from xscreensaver's
+dnl configure.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski.
+dnl
+
+AC_INIT(config.h.in)
+AC_CONFIG_HEADER(config.h)
+AC_CANONICAL_HOST
+canonical=$host
+
+AC_PROG_CC
+dnl Check if C++ compiler is present. If not set CXX to the C-compiler used
+dnl for the other compilations. Check for g++ before c++ so that Purify works.
+AC_CHECK_PROGS(CXX, $CCC g++ c++ CC cxx cc++ xlC $CC, gcc)
+AC_PROG_CXX
+if test "${CXX}" = "xlC" ; then
+  CXXFLAGS="${CXXFLAGS} -+"
+fi
+
+dnl These 2 assume for now c++ exists....
+AC_DEFINE(HAVE_CXX)
+CCC=
+
+PACKAGE=xlockmore
+AC_SUBST(PACKAGE)
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
+VERSION=4.13
+AC_SUBST(VERSION)
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
+
+dnl Checks for programs.
+dnl AC_ARG_WITH(gcc,
+dnl[  --without-gcc           use CC to compile])
+
+dnl test -n "$CC" && cc_specified=yes
+dnl case ${with_gcc} in
+dnl   yes ) CC=gcc ;;
+dnl dnl yes ) CC=g++ ;;
+dnl  no  ) CC=cc ;;
+dnl  *   ) AC_PROG_CC;;
+dnl  *   ) AC_PROG_CXX ;;
+dnl esac
+
+dnl This creates a lot of noise.
+dnl if test "${CC}" = "gcc" ; then
+dnl   CFLAGS="${CFLAGS} -Wall -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wwrite-strings -Wmissing-prototypes -Wstrict-prototypes"
+dnl -Waggregate-return
+dnl fi
+
+opt_purify=no
+AC_ARG_WITH(purify, [  --with-purify           configure to postprocess with purify], opt_purify=$withval)
+if test "$opt_purify" = yes; then
+  AC_MSG_RESULT([enabling purify])
+  PURIFY="purify"
+else
+  PURIFY=
+fi
+
+AC_PROG_LN_S
+AC_PROG_CPP
+AC_AIX
+AC_PROG_INSTALL
+AC_PROG_MAKE_SET
+ac_link_test="-L"
+# test test
+AC_MSG_CHECKING([test -h])
+if (test \! -h /) >/dev/null 2>/dev/null ; then
+  ac_link_test="-h"
+  AC_MSG_RESULT($ac_link_test)
+else
+  AC_MSG_RESULT($ac_link_test)
+fi
+
+dnl Optional features.
+dnl add copious amounts of debugging with gcc
+
+dnl Checks for header files.
+dnl AC_HEADER_STDC /* If its not ansi, its not going to go */
+AC_ISC_POSIX
+dnl AC_HEADER_SYS_WAIT
+dnl AC_CHECK_HEADERS(poll.h sys/poll.h)
+AC_CHECK_HEADERS(fcntl.h limits.h sys/select.h sys/time.h syslog.h unistd.h memory.h sys/param.h)
+
+dnl Checks for typedefs, structures, and compiler characteristics.
+AC_C_CONST
+dnl AC_HEADER_SYS_WAIT
+AC_TYPE_MODE_T
+AC_TYPE_UID_T
+AC_TYPE_PID_T
+AC_TYPE_SIZE_T
+AC_HEADER_TIME
+AC_STRUCT_TM
+
+dnl Checks for library functions.
+dnl AC_TYPE_GETGROUPS
+dnl AC_TYPE_SIGNAL
+dnl AC_CHECK_FUNCS(poll)
+dnl AC_CHECK_FUNCS(signal)
+AC_CHECK_FUNCS(gethostname select strdup)
+
+AC_CHECK_FUNC(vfork, AC_DEFINE(HAVE_VFORK))
+AC_CHECK_FUNC(seteuid, AC_DEFINE(HAVE_SETEUID),
+AC_CHECK_FUNC(setreuid, AC_DEFINE(HAVE_SETREUID)))
+
+
+# Configure paths for GTK+
+# Owen Taylor     97-11-3
+
+dnl AC_PATH_GTK([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
+dnl Test for GTK, and define GTK_CFLAGS and GTK_LIBS
+dnl
+AC_DEFUN(AC_PATH_GTK,
+[dnl 
+dnl Get the cflags and libraries from the gtk-config script
+dnl
+AC_ARG_WITH(gtk-prefix,[  --with-gtk-prefix=DIR   Prefix where GTK is installed (optional)],
+            gtk_config_prefix="$withval", gtk_config_prefix="")
+AC_ARG_WITH(gtk-exec-prefix,[  --with-gtk-exec-prefix=DIR 
+                          Exec prefix where GTK is installed (optional)],
+            gtk_config_exec_prefix="$withval", gtk_config_exec_prefix="")
+AC_ARG_ENABLE(gtktest, [  --disable-gtktest       Do not try to compile and run a test GTK program],
+                   , enable_gtktest=yes)
+
+  if test x$gtk_config_exec_prefix != x ; then
+     gtk_config_args="$gtk_config_args --exec-prefix=$gtk_config_exec_prefix"
+     if test x${GTK_CONFIG+set} != xset ; then
+        GTK_CONFIG=$gtk_config_exec_prefix/bin/gtk-config
+     fi
+  fi
+  if test x$gtk_config_prefix != x ; then
+     gtk_config_args="$gtk_config_args --prefix=$gtk_config_prefix"
+     if test x${GTK_CONFIG+set} != xset ; then
+        GTK_CONFIG=$gtk_config_prefix/bin/gtk-config
+     fi
+  fi
+
+  AC_PATH_PROG(GTK_CONFIG, gtk-config, no)
+  min_gtk_version=ifelse([$1], ,0.99.7,$1)
+  AC_MSG_CHECKING(for GTK - version >= $min_gtk_version)
+  no_gtk=""
+  if test "$GTK_CONFIG" = "no" ; then
+    no_gtk=yes
+  else
+    GTK_CFLAGS=`$GTK_CONFIG $gtk_config_args --cflags`
+    GTK_LIBS=`$GTK_CONFIG $gtk_config_args --libs`
+    gtk_config_major_version=`$GTK_CONFIG $gtk_config_args --version | \
+           sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
+    gtk_config_minor_version=`$GTK_CONFIG $gtk_config_args --version | \
+           sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
+    gtk_config_micro_version=`$GTK_CONFIG $gtk_config_args --version | \
+           sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
+    if test "x$enable_gtktest" = "xyes" ; then
+      ac_save_CFLAGS="$CFLAGS"
+      ac_save_LIBS="$LIBS"
+      CFLAGS="$CFLAGS $GTK_CFLAGS"
+      LIBS="$LIBS $GTK_LIBS"
+dnl
+dnl Now check if the installed GTK is sufficiently new. (Also sanity
+dnl checks the results of gtk-config to some extent
+dnl
+      rm -f conf.gtktest
+      AC_TRY_RUN([
+#include <gtk/gtk.h>
+#include <stdio.h>
+
+int 
+main ()
+{
+  int major, minor, micro;
+  char *tmp_version;
+
+  system ("touch conf.gtktest");
+
+  /* HP/UX 9 (%@#!) writes to sscanf strings */
+  tmp_version = g_strdup("$min_gtk_version");
+  if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
+     printf("%s, bad version string\n", "$min_gtk_version");
+     exit(1);
+   }
+
+  if ((gtk_major_version != $gtk_config_major_version) ||
+      (gtk_minor_version != $gtk_config_minor_version) ||
+      (gtk_micro_version != $gtk_config_micro_version))
+    {
+      printf("\n*** 'gtk-config --version' returned %d.%d.%d, but GTK+ (%d.%d.%d)\n", 
+             $gtk_config_major_version, $gtk_config_minor_version, $gtk_config_micro_version,
+             gtk_major_version, gtk_minor_version, gtk_micro_version);
+      printf ("*** was found! If gtk-config was correct, then it is best\n");
+      printf ("*** to remove the old version of GTK+. You may also be able to fix the error\n");
+      printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
+      printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
+      printf("*** required on your system.\n");
+      printf("*** If gtk-config was wrong, set the environment variable GTK_CONFIG\n");
+      printf("*** to point to the correct copy of gtk-config, and remove the file config.cache\n");
+      printf("*** before re-running configure\n");
+    } 
+  else
+    {
+      if ((gtk_major_version > major) ||
+        ((gtk_major_version == major) && (gtk_minor_version > minor)) ||
+        ((gtk_major_version == major) && (gtk_minor_version == minor) && (gtk_micro_version >= micro)))
+      {
+        return 0;
+       }
+     else
+      {
+        printf("\n*** An old version of GTK+ (%d.%d.%d) was found.\n",
+               gtk_major_version, gtk_minor_version, gtk_micro_version);
+        printf("*** You need a version of GTK+ newer than %d.%d.%d. The latest version of\n",
+              major, minor, micro);
+        printf("*** GTK+ is always available from ftp://ftp.gtk.org.\n");
+        printf("***\n");
+        printf("*** If you have already installed a sufficiently new version, this error\n");
+        printf("*** probably means that the wrong copy of the gtk-config shell script is\n");
+        printf("*** being found. The easiest way to fix this is to remove the old version\n");
+        printf("*** of GTK+, but you can also set the GTK_CONFIG environment to point to the\n");
+        printf("*** correct copy of gtk-config. (In this case, you will have to\n");
+        printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
+        printf("*** so that the correct libraries are found at run-time))\n");
+      }
+    }
+  return 1;
+}
+],, no_gtk=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
+       CFLAGS="$ac_save_CFLAGS"
+       LIBS="$ac_save_LIBS"
+     fi
+  fi
+  if test "x$no_gtk" = x ; then
+     AC_MSG_RESULT(yes)
+     ifelse([$2], , :, [$2])     
+  else
+     AC_MSG_RESULT(no)
+     if test "$GTK_CONFIG" = "no" ; then
+       echo "*** The gtk-config script installed by GTK could not be found"
+       echo "*** If GTK was installed in PREFIX, make sure PREFIX/bin is in"
+       echo "*** your path, or set the GTK_CONFIG environment variable to the"
+       echo "*** full path to gtk-config."
+     else
+       if test -f conf.gtktest ; then
+        :
+       else
+          echo "*** Could not run GTK test program, checking why..."
+          CFLAGS="$CFLAGS $GTK_CFLAGS"
+          LIBS="$LIBS $GTK_LIBS"
+          AC_TRY_LINK([
+#include <gtk/gtk.h>
+#include <stdio.h>
+],      [ return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version)); ],
+        [ echo "*** The test program compiled, but did not run. This usually means"
+          echo "*** that the run-time linker is not finding GTK or finding the wrong"
+          echo "*** version of GTK. If it is not finding GTK, you'll need to set your"
+          echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
+          echo "*** to the installed location  Also, make sure you have run ldconfig if that"
+          echo "*** is required on your system"
+         echo "***"
+          echo "*** If you have an old version installed, it is best to remove it, although"
+          echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
+          echo "***"
+          echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that"
+          echo "*** came with the system with the command"
+          echo "***"
+          echo "***    rpm --erase --nodeps gtk gtk-devel" ],
+        [ echo "*** The test program failed to compile or link. See the file config.log for the"
+          echo "*** exact error that occured. This usually means GTK was incorrectly installed"
+          echo "*** or that you have moved GTK since it was installed. In the latter case, you"
+          echo "*** may want to edit the gtk-config script: $GTK_CONFIG" ])
+          CFLAGS="$ac_save_CFLAGS"
+          LIBS="$ac_save_LIBS"
+       fi
+     fi
+     GTK_CFLAGS=""
+     GTK_LIBS=""
+     ifelse([$3], , :, [$3])
+  fi
+  AC_SUBST(GTK_CFLAGS)
+  AC_SUBST(GTK_LIBS)
+  rm -f conf.gtktest
+])
+
+dnl X Window System files.
+AC_PATH_XTRA
+if test "$no_x" = yes; then
+  XLIBS=NONE
+else
+  if test -n "${x_includes}"; then
+    XLOCKINC="-I${x_includes} ${XLOCKINC}"
+    XMLOCKINC="-I${x_includes} ${XMLOCKINC}"
+    XALOCKINC="-I${x_includes} ${XALOCKINC}"
+  fi
+  XLIBS="${x_libraries}"
+  if test -n "${x_libraries}"; then
+    XLOCK_LDFLAGS="/usr/lib:${x_libraries}"
+    XMLOCK_LDFLAGS="/usr/lib:${x_libraries}"
+    XALOCK_LDFLAGS="/usr/lib:${x_libraries}"
+    XLOCKLIBPATHS="-L${x_libraries} ${XLOCKLIBPATHS}"
+    XMLOCKLIBPATHS="-L${x_libraries} ${XMLOCKLIBPATHS}"
+    XALOCKLIBPATHS="-L${x_libraries} ${XALOCKLIBPATHS}"
+  fi
+  XLOCKLIBS="${X_PRE_LIBS} ${X_EXTRA_LIBS} ${XLOCKLIBS}"
+  XMLOCKLIBS="-lXt ${XMLOCKLIBS}"
+#  if you need regex and regcmp
+#  XMLOCKLIBS="-lXt ${XMLOCKLIBS} -lgen"
+  XALOCKLIBS="-lXt ${XALOCKLIBS}"
+dnl AC_DEFINE(X11) /* If there is no X, its not going to go */
+fi
+
+# Try and find the app-defaults directory.
+AC_DEFUN(AC_PATH_X_APP_DEFAULTS_XMKMF,
+  [
+  rm -fr conftestdir
+  if mkdir conftestdir; then
+    cd conftestdir
+    # Make sure to not put "make" in the Imakefile rules, since we grep it out.
+    cat > Imakefile <<'EOF'
+acfindx:
+  @echo 'ac_x_app_defaults="${XAPPLOADDIR}"'
+EOF
+    if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
+      # GNU make sometimes prints "make[1]: Entering...", which'd confuse us.
+      eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
+    fi
+    cd ..
+    rm -fr conftestdir
+  fi])
+
+AC_DEFUN(AC_PATH_X_APP_DEFAULTS_DIRECT,
+[  # Look for the directory under a standard set of common directories.
+  # Check X11 before X11Rn because it's often a symlink to the current release.
+  for ac_dir in         \
+    /lib/X11/app-defaults \
+    /lib/app-defaults \
+    /lib/X11R6.3/app-defaults \
+    /lib/X11R6.3/X11/app-defaults \
+    /lib/X11R6.2/app-defaults \
+    /lib/X11R6.2/X11/app-defaults \
+    /lib/X11R6.1/app-defaults \
+    /lib/X11R6.1/X11/app-defaults \
+    /lib/X11R6/app-defaults \
+    /lib/X11R6/X11/app-defaults \
+    /lib/X11R5/app-defaults \
+    /lib/X11R5/X11/app-defaults \
+    /lib/X11R4/app-defaults \
+    /lib/X11R4/X11/app-defaults \
+    ; \
+  do
+    found=""
+    if test -d "${prefix}$ac_dir"; then
+      ac_x_app_defaults=\\\$\\\{prefix\\\}$ac_dir
+    found="1"
+      break
+    fi
+  done
+  if test -z "$found"; then
+  for ac_dir in         \
+    /usr/X11/lib/app-defaults     \
+    /usr/X11R6.3/lib/app-defaults     \
+    /usr/X11R6.3/lib/X11/app-defaults   \
+    /usr/X11R6.2/lib/app-defaults     \
+    /usr/X11R6.2/lib/X11/app-defaults   \
+    /usr/X11R6.1/lib/app-defaults     \
+    /usr/X11R6.1/lib/X11/app-defaults   \
+    /usr/X11R6/lib/app-defaults     \
+    /usr/X11R6/lib/X11/app-defaults   \
+    /usr/X11R5/lib/app-defaults     \
+    /usr/X11R5/lib/X11/app-defaults   \
+    /usr/X11R4/lib/app-defaults     \
+    /usr/X11R4/lib/X11/app-defaults   \
+            \
+    /usr/lib/X11/app-defaults     \
+    /usr/lib/X11R6.3/app-defaults     \
+    /usr/lib/X11R6.2/app-defaults     \
+    /usr/lib/X11R6.1/app-defaults     \
+    /usr/lib/X11R6/app-defaults     \
+    /usr/lib/X11R5/app-defaults     \
+    /usr/lib/X11R4/app-defaults     \
+            \
+    /usr/local/X11/lib/app-defaults   \
+    /usr/remote/X11/lib/app-defaults   \
+    /usr/local/X11R6.3/lib/app-defaults   \
+    /usr/local/X11R6.3/lib/X11/app-defaults   \
+    /usr/local/X11R6.2/lib/app-defaults   \
+    /usr/local/X11R6.2/lib/X11/app-defaults   \
+    /usr/local/X11R6.1/lib/app-defaults   \
+    /usr/local/X11R6.1/lib/X11/app-defaults   \
+    /usr/local/X11R6/lib/app-defaults   \
+    /usr/local/X11R6/lib/X11/app-defaults   \
+    /usr/local/X11R5/lib/app-defaults   \
+    /usr/local/X11R5/lib/X11/app-defaults   \
+    /usr/local/X11R4/lib/app-defaults   \
+    /usr/local/X11R4/lib/X11/app-defaults   \
+            \
+    /usr/local/lib/X11/app-defaults   \
+    /usr/remote/lib/X11/app-defaults   \
+    /usr/local/lib/X11R6.3/app-defaults   \
+    /usr/local/lib/X11R6.3/X11/app-defaults \
+    /usr/local/lib/X11R6.2/app-defaults   \
+    /usr/local/lib/X11R6.2/X11/app-defaults \
+    /usr/local/lib/X11R6.1/app-defaults   \
+    /usr/local/lib/X11R6.1/X11/app-defaults \
+    /usr/local/lib/X11R6/app-defaults   \
+    /usr/local/lib/X11R6/X11/app-defaults \
+    /usr/local/lib/X11R5/app-defaults   \
+    /usr/local/lib/X11R5/X11/app-defaults \
+    /usr/local/lib/X11R4/app-defaults   \
+    /usr/local/lib/X11R4/X11/app-defaults \
+            \
+    /usr/X386/lib/X11/app-defaults    \
+    /usr/x386/lib/X11/app-defaults    \
+    /usr/XFree86/lib/X11/app-defaults   \
+            \
+    /usr/lib/X11/app-defaults     \
+    /usr/unsupported/lib/X11/app-defaults \
+    /usr/athena/lib/X11/app-defaults    \
+    /usr/local/x11r5/lib/X11/app-defaults \
+    /usr/lpp/Xamples/lib/X11/app-defaults \
+    /lib/usr/lib/X11/app-defaults   \
+    /usr/local/lib/app-defaults   \
+    /usr/remote/lib/app-defaults   \
+            \
+    /usr/openwin/lib/app-defaults   \
+    /usr/openwin/lib/X11/app-defaults   \
+    /usr/openwin/share/lib/app-defaults   \
+    /usr/openwin/share/lib/X11/app-defaults \
+            \
+    /X11R6.3/lib/app-defaults     \
+    /X11R6.2/lib/app-defaults     \
+    /X11R6.1/lib/app-defaults     \
+    /X11R6/lib/app-defaults     \
+    /X11R5/lib/app-defaults     \
+    /X11R4/lib/app-defaults     \
+    ; \
+  do
+    if test -d "$ac_dir"; then
+      ac_x_app_defaults=$ac_dir
+      break
+    fi
+  done
+    fi
+])
+
+
+AC_DEFUN(AC_PATH_X_APP_DEFAULTS,
+  [AC_REQUIRE_CPP()
+    AC_CACHE_CHECK([for X app-defaults directory], ac_cv_x_app_defaults,
+     [AC_PATH_X_APP_DEFAULTS_XMKMF
+      AC_PATH_X_APP_DEFAULTS_DIRECT
+      if test x"$ac_x_app_defaults" = x; then
+        ac_cv_x_app_defaults="/usr/lib/X11/app-defaults"
+      else
+        # Record where we found app-defaults for the cache.
+        ac_cv_x_app_defaults="$ac_x_app_defaults"
+      fi])
+    eval ac_x_app_defaults="$ac_cv_x_app_defaults"])
+
+AC_PATH_X_APP_DEFAULTS
+
+APPDEFAULTS=$ac_x_app_defaults
+
+AC_ARG_WITH(includes, [  --with-includes=DIR     search include DIR for optional packages below])
+case "x$withval" in
+x/*|x.*)
+  extra_include=$withval
+  AC_MSG_RESULT([adding $extra_include to include search path for following packages])
+  if test ! -d $extra_include; then
+    AC_MSG_RESULT([Warning: Directory $extra_include does not exist])
+  fi
+  ;;
+*)
+  extra_include=""
+  ;;
+esac
+
+AC_ARG_WITH(libraries, [  --with-libraries=DIR    search library DIR for optional packages below])
+case "x$withval" in
+x/*|x.*)
+  extra_lib=$withval
+  AC_MSG_RESULT([adding $extra_lib to library search path for following packages])
+  if test ! -d $extra_lib; then
+    AC_MSG_RESULT([Warning: Directory $extra_lib does not exist])
+  fi
+  ;;
+*)
+  extra_lib=""
+  ;;
+esac
+
+dnl Xm MOTIF Motif motif
+
+AC_DEFUN(AC_PATH_MOTIF_DIRECT,
+[test -z "$motif_direct_test_library" && motif_direct_test_library=Xm
+test -z "$motif_direct_test_function" && motif_direct_test_function=XmCreatePushButton
+test -z "$motif_direct_test_include" && motif_direct_test_include=Xm/Xm.h
+  for ac_dir in               \
+    /usr/include/Motif1.2     \
+    /usr/Motif1.2/include     \
+                              \
+    /usr/motif/include        \
+                              \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$motif_direct_test_include"; then
+      no_motif= ac_motif_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$motif_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_motif_includes" | sed s/include/lib/` \
+    /usr/lib/Motif1.2     \
+    /usr/Motif1.2/lib     \
+                          \
+    /usr/motif/lib        \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${motif_direct_test_library}.$ac_extension; then
+      no_motif= ac_motif_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_MOTIF,
+[AC_REQUIRE_CPP()dnl
+
+motif_includes=NONE
+motif_libraries=NONE
+
+AC_MSG_CHECKING(for Motif)
+AC_ARG_WITH(motif, [  --without-motif         disable Motif (for xmlock)])
+if test "x$with_motif" = xno; then
+  no_motif=yes
+else
+  if test "x$motif_includes" != xNONE && test "x$motif_libraries" != xNONE; then
+    no_motif=
+  else
+AC_CACHE_VAL(ac_cv_path_motif,
+[# One or both of these vars are not set, and there is no cached value.
+no_motif=yes
+AC_PATH_MOTIF_DIRECT
+
+if test "$no_motif" = yes; then
+  ac_cv_path_motif="no_motif=yes"
+else
+  ac_cv_path_motif="no_motif= ac_motif_includes=$ac_motif_includes ac_motif_libraries=$ac_motif_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_motif"
+fi # with_motif != no
+
+if test "$no_motif" = yes; then
+  AC_MSG_RESULT(no)
+  XMLOCK=""
+  INSTALL_XMLOCK=""
+  UNINSTALL_XMLOCK=""
+else
+  XMLOCKLIBS="-lXm ${XMLOCKLIBS}"
+  XMLOCK="xmlock"
+  INSTALL_XMLOCK="install_xmlock"
+  UNINSTALL_XMLOCK="uninstall_xmlock"
+  test "x$motif_includes" = xNONE && motif_includes=$ac_motif_includes
+  test "x$motif_libraries" = xNONE && motif_libraries=$ac_motif_libraries
+  ac_cv_path_motif="no_motif= ac_motif_includes=$motif_includes ac_motif_libraries=$motif_libraries"
+  AC_MSG_RESULT([libraries $motif_libraries, headers $motif_includes])
+fi
+])
+
+AC_PATH_MOTIF
+
+if test "x$motif_libraries" != x && test "x$motif_libraries" != xNONE ; then
+  XMLOCK_LDFLAGS="${XMLOCK_LDFLAGS}:$motif_libraries"
+  XMLOCKLIBPATHS="${XMLOCKLIBPATHS} -L$motif_libraries"
+fi
+if test "x$motif_includes" != x && test "x$motif_includes" != xNONE ; then
+  XMLOCKINC="${XMLOCKINC} -I$motif_includes"
+fi
+
+dnl Xaw ATHENA Athena athena
+
+AC_DEFUN(AC_PATH_ATHENA_DIRECT,
+[test -z "$athena_direct_test_library" && athena_direct_test_library=Xaw
+test -z "$athena_direct_test_function" && athena_direct_test_function=XawInitializeWidgetSet
+test -z "$athena_direct_test_include" && athena_direct_test_include=X11/Xaw/XawInit.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$athena_direct_test_include"; then
+      no_athena= ac_athena_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$athena_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_athena_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${athena_direct_test_library}.$ac_extension; then
+      no_athena= ac_athena_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_ATHENA,
+[AC_REQUIRE_CPP()dnl
+
+athena_includes=NONE
+athena_libraries=NONE
+
+AC_MSG_CHECKING(for Athena)
+AC_ARG_WITH(athena, [  --without-athena        disable Athena (for xalock)])
+if test "x$with_athena" = xno; then
+  no_athena=yes
+else
+  if test "x$athena_includes" != xNONE && test "x$athena_libraries" != xNONE; then
+    no_athena=
+  else
+AC_CACHE_VAL(ac_cv_path_athena,
+[# One or both of these vars are not set, and there is no cached value.
+no_athena=yes
+AC_PATH_ATHENA_DIRECT
+
+if test "$no_athena" = yes; then
+  ac_cv_path_athena="no_athena=yes"
+else
+  ac_cv_path_athena="no_athena= ac_athena_includes=$ac_athena_includes ac_athena_libraries=$ac_athena_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_athena"
+fi # with_athena != no
+
+if test "$no_athena" = yes; then
+  AC_MSG_RESULT(no)
+  XALOCK=""
+  INSTALL_XALOCK=""
+  UNINSTALL_XALOCK=""
+else
+  XALOCKLIBS="-lXaw ${XALOCKLIBS}"
+  XALOCK="xalock"
+  INSTALL_XALOCK="install_xalock"
+  UNINSTALL_XALOCK="uninstall_xalock"
+  test "x$athena_includes" = xNONE && athena_includes=$ac_athena_includes
+  test "x$athena_libraries" = xNONE && athena_libraries=$ac_athena_libraries
+  ac_cv_path_athena="no_athena= ac_athena_includes=$athena_includes ac_athena_libraries=$athena_libraries"
+  AC_MSG_RESULT([libraries $athena_libraries, headers $athena_includes])
+fi
+])
+
+AC_PATH_ATHENA
+
+if test "x$athena_libraries" != x && test "x$athena_libraries" != xNONE ; then
+  XALOCK_LDFLAGS="${XALOCK_LDFLAGS}:$athena_libraries"
+  XALOCKLIBPATHS="${XALOCKLIBPATHS} -L$athena_libraries"
+fi
+if test "x$athena_includes" != x && test "x$athena_includes" != xNONE ; then
+  XALOCKINC="${XALOCKINC} -I$athena_includes"
+fi
+
+dnl sx
+
+AC_DEFUN(AC_PATH_SX_DIRECT,
+[test -z "$sx_direct_test_library" && sx_direct_test_library=sx
+test -z "$sx_direct_test_function" && sx_direct_test_function=OpenWindow
+test -z "$sx_direct_test_include" && sx_direct_test_include=X11/libsx.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$sx_direct_test_include"; then
+      no_sx= ac_sx_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$sx_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_sx_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${sx_direct_test_library}.$ac_extension; then
+      no_sx= ac_sx_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_SX,
+[AC_REQUIRE_CPP()dnl
+
+sx_includes=NONE
+sx_libraries=NONE
+
+AC_MSG_CHECKING(for sx)
+AC_ARG_WITH(sx, [  --without-sx            disable sx (for xalock)])
+if test "x$with_sx" = xno; then
+  no_sx=yes
+else
+  if test "x$sx_includes" != xNONE && test "x$sx_libraries" != xNONE; then
+    no_sx=
+  else
+AC_CACHE_VAL(ac_cv_path_sx,
+[# One or both of these vars are not set, and there is no cached value.
+no_sx=yes
+AC_PATH_SX_DIRECT
+
+if test "$no_sx" = yes; then
+  ac_cv_path_sx="no_sx=yes"
+else
+  ac_cv_path_sx="no_sx= ac_sx_includes=$ac_sx_includes ac_sx_libraries=$ac_sx_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_sx"
+fi # with_sx != no
+
+if test "$no_sx" = yes; then
+  AC_MSG_RESULT(no)
+  XALOCK=""
+  INSTALL_XALOCK=""
+  UNINSTALL_XALOCK=""
+else
+  XALOCKLIBS="-lsx ${XALOCKLIBS}"
+  XALOCK="xalock"
+  INSTALL_XALOCK="install_xalock"
+  UNINSTALL_XALOCK="uninstall_xalock"
+  test "x$sx_includes" = xNONE && sx_includes=$ac_sx_includes
+  test "x$sx_libraries" = xNONE && sx_libraries=$ac_sx_libraries
+  ac_cv_path_sx="no_sx= ac_sx_includes=$sx_includes ac_sx_libraries=$sx_libraries"
+  AC_MSG_RESULT([libraries $sx_libraries, headers $sx_includes])
+fi
+])
+
+AC_PATH_SX
+
+if test "x$sx_libraries" != x && test "x$sx_libraries" != xNONE ; then
+dnl In front because we do not want to pick up the internal Solaris lib
+  XALOCK_LDFLAGS="$sx_libraries:${XALOCK_LDFLAGS}"
+  XALOCKLIBPATHS="-L$sx_libraries ${XALOCKLIBPATHS}"
+fi
+if test "x$sx_includes" != x && test "x$sx_includes" != xNONE ; then
+  XALOCKINC="${XALOCKINC} -I$sx_includes"
+fi
+
+dnl Xmu EDITRES Editres editres
+
+AC_DEFUN(AC_PATH_EDITRES_DIRECT,
+[test -z "$editres_direct_test_library" && editres_direct_test_library=Xmu
+test -z "$editres_direct_test_function" && editres_direct_test_function=_XEditResCheckMessages
+test -z "$editres_direct_test_include" && editres_direct_test_include=X11/Xmu/Editres.h
+  for ac_dir in               \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include      \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$editres_direct_test_include"; then
+      no_editres= ac_editres_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$editres_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_editres_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${editres_direct_test_library}.$ac_extension; then
+      no_editres= ac_editres_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_EDITRES,
+[AC_REQUIRE_CPP()dnl
+
+editres_includes=NONE
+editres_libraries=NONE
+
+AC_MSG_CHECKING(for Editres)
+AC_ARG_WITH(editres, [  --without-editres       disable debugger (for x?lock)])
+if test "x$with_editres" = xno; then
+  no_editres=yes
+else
+  if test "x$editres_includes" != xNONE && test "x$editres_libraries" != xNONE; then
+    no_editres=
+  else
+AC_CACHE_VAL(ac_cv_path_editres,
+[# One or both of these vars are not set, and there is no cached value.
+no_editres=yes
+AC_PATH_EDITRES_DIRECT
+
+if test "$no_editres" = yes; then
+  ac_cv_path_editres="no_editres=yes"
+else
+  ac_cv_path_editres="no_editres= ac_editres_includes=$ac_editres_includes ac_editres_libraries=$ac_editres_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_editres"
+fi # with_editres != no
+
+if test "$no_editres" = yes; then
+  AC_MSG_RESULT(no)
+else
+  AC_DEFINE(USE_XMU)
+  XMLOCKLIBS="-lXmu ${XMLOCKLIBS}"
+  XALOCKLIBS="-lXmu ${XALOCKLIBS}"
+  test "x$editres_includes" = xNONE && editres_includes=$ac_editres_includes
+  test "x$editres_libraries" = xNONE && editres_libraries=$ac_editres_libraries
+  ac_cv_path_editres="no_editres= ac_editres_includes=$editres_includes ac_editres_libraries=$editres_libraries"
+  AC_MSG_RESULT([libraries $editres_libraries, headers $editres_includes])
+fi
+])
+
+AC_PATH_EDITRES
+
+if test "x$editres_libraries" != x && test "x$editres_libraries" != xNONE ; then
+  XMLOCK_LDFLAGS="${XMLOCK_LDFLAGS}:$editres_libraries"
+  XALOCK_LDFLAGS="${XALOCK_LDFLAGS}:$editres_libraries"
+  XMLOCKLIBPATHS="${XMLOCKLIBPATHS} -L$editres_libraries"
+  XALOCKLIBPATHS="${XALOCKLIBPATHS} -L$editres_libraries"
+fi
+if test "x$editres_includes" != x && test "x$editres_includes" != xNONE ; then
+  XMLOCKINC="${XMLOCKINC} -I$editres_includes"
+  XALOCKINC="${XALOCKINC} -I$editres_includes"
+fi
+
+xpm=no
+dnl Xpm XPM xpm
+
+AC_DEFUN(AC_PATH_XPM_DIRECT,
+[test -z "$xpm_direct_test_library" && xpm_direct_test_library=Xpm
+test -z "$xpm_direct_test_function" && xpm_direct_test_function=XpmCreateImageFromData
+test -z "$xpm_direct_test_include" && xpm_direct_test_include=xpm.h
+  for ac_dir in                   \
+    /usr/X11R6.3/include/X11      \
+    /usr/X11R6.2/include/X11      \
+    /usr/X11R6.1/include/X11      \
+    /usr/X11R6/include/X11        \
+    /usr/X11R5/include/X11        \
+    /usr/X11R4/include/X11        \
+    /usr/X11/include/X11          \
+                                  \
+    /usr/include/X11/X11          \
+    /usr/include/X11R6.3/X11      \
+    /usr/include/X11R6.2/X11      \
+    /usr/include/X11R6.1/X11      \
+    /usr/include/X11R6/X11        \
+    /usr/include/X11R5/X11        \
+    /usr/include/X11R4/X11        \
+                                  \
+    /usr/local/X11/include/X11    \
+    /usr/local/X11R6.3/include/X11  \
+    /usr/local/X11R6.2/include/X11  \
+    /usr/local/X11R6.1/include/X11  \
+    /usr/local/X11R6/include/X11  \
+    /usr/local/X11R5/include/X11  \
+    /usr/local/X11R4/include/X11  \
+                                  \
+    /usr/local/include/X11/X11    \
+    /usr/local/include/X11R6.3/X11  \
+    /usr/local/include/X11R6.2/X11  \
+    /usr/local/include/X11R6.1/X11  \
+    /usr/local/include/X11R6/X11  \
+    /usr/local/include/X11R5/X11  \
+    /usr/local/include/X11R4/X11  \
+                                  \
+    /usr/X386/include/X11         \
+    /usr/x386/include/X11         \
+    /usr/XFree86/include/X11/X11  \
+                                  \
+    /usr/local/include/X11        \
+    /usr/remote/include/X11       \
+    /usr/include/X11              \
+    /usr/unsupported/include/X11  \
+    /usr/athena/include/X11       \
+    /usr/local/x11r5/include/X11  \
+    /usr/lpp/Xamples/include/X11  \
+                                  \
+    /usr/openwin/include/X11      \
+    /usr/openwin/share/include/X11 \
+    /usr/openwin/include          \
+                                  \
+    /usr/include/Vk               \
+    $extra_include                \
+    $extra_include/X11            \
+    ; \
+  do
+    if test -r "$ac_dir/$xpm_direct_test_include"; then
+      no_xpm= ac_xpm_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$xpm_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_xpm_includes" | sed s%/X11$%% | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${xpm_direct_test_library}.$ac_extension; then
+      no_xpm= ac_xpm_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_XPM,
+[AC_REQUIRE_CPP()dnl
+
+xpm_includes=NONE
+xpm_libraries=NONE
+
+AC_MSG_CHECKING(for XPM)
+AC_ARG_WITH(xpm, [  --without-xpm           enable color pixmap XPM mode(s)])
+if test "x$with_xpm" = xno; then
+  no_xpm=yes
+else
+  if test "x$xpm_includes" != xNONE && test "x$xpm_libraries" != xNONE; then
+    no_xpm=
+  else
+AC_CACHE_VAL(ac_cv_path_xpm,
+[# One or both of these vars are not set, and there is no cached value.
+no_xpm=yes
+AC_PATH_XPM_DIRECT
+
+if test "$no_xpm" = yes; then
+  ac_cv_path_xpm="no_xpm=yes"
+else
+  ac_cv_path_xpm="no_xpm= ac_xpm_includes=$ac_xpm_includes ac_xpm_libraries=$ac_xpm_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_xpm"
+fi # with_xpm != no
+
+if test "$no_xpm" = yes; then
+  AC_MSG_RESULT(no)
+  XPM="#"
+else
+  xpm=yes
+  AC_DEFINE(USE_XPMINC)
+  XLOCKLIBS="${XLOCKLIBS} -lXpm"
+  XMLOCKLIBS="-lXpm ${XMLOCKLIBS}"
+  test "x$xpm_includes" = xNONE && xpm_includes=$ac_xpm_includes
+  test "x$xpm_libraries" = xNONE && xpm_libraries=$ac_xpm_libraries
+  ac_cv_path_xpm="no_xpm= ac_xpm_includes=$xpm_includes ac_xpm_libraries=$xpm_libraries"
+  AC_MSG_RESULT([libraries $xpm_libraries, headers $xpm_includes])
+  XPM=""
+fi
+])
+
+AC_PATH_XPM
+
+if test "x$xpm_libraries" != x && test "x$xpm_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$xpm_libraries"
+  XMLOCK_LDFLAGS="${XMLOCK_LDFLAGS}:$xpm_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$xpm_libraries"
+  XMLOCKLIBPATHS="${XMLOCKLIBPATHS} -L$xpm_libraries"
+fi
+if test "x$xpm_includes" != x && test "x$xpm_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$xpm_includes"
+fi
+
+gltt=no
+dnl gltt GLTT
+
+AC_DEFUN(AC_PATH_GLTT_DIRECT,
+[test -z "$gltt_direct_test_library" && gltt_direct_test_library=gltt
+# test -z "$gltt_direct_test_function" && gltt_direct_test_function=glttCreateImageFromData
+test -z "$gltt_direct_test_include" && gltt_direct_test_include=FTFace.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    /usr/openwin/include      \
+                              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$gltt_direct_test_include"; then
+      no_gltt= ac_gltt_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$gltt_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_gltt_includes" | sed s%/X11$%% | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${gltt_direct_test_library}.$ac_extension; then
+      no_gltt= ac_gltt_libraries=$ac_dir
+      break 2
+   fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_GLTT,
+[AC_REQUIRE_CPP()dnl
+
+gltt_includes=NONE
+gltt_libraries=NONE
+
+AC_MSG_CHECKING(for GLTT)
+AC_ARG_WITH(gltt, [  --without-gltt          disable GL True text library])
+if test "x$with_gltt" = xno; then
+  no_gltt=yes
+else
+  if test "x$gltt_includes" != xNONE && test "x$gltt_libraries" != xNONE; then
+    no_gltt=
+  else
+AC_CACHE_VAL(ac_cv_path_gltt,
+[# One or both of these vars are not set, and there is no cached value.
+no_gltt=yes
+AC_PATH_GLTT_DIRECT
+
+if test "$no_gltt" = yes; then
+  ac_cv_path_gltt="no_gltt=yes"
+else
+  ac_cv_path_gltt="no_gltt= ac_gltt_includes=$ac_gltt_includes ac_gltt_libraries=$ac_gltt_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_gltt"
+fi # with_gltt != no
+
+if test "$no_gltt" = yes; then
+  AC_MSG_RESULT(no)
+  GLTT="#"
+else
+  gltt=yes
+  AC_DEFINE(HAVE_GLTT)
+  XLOCKLIBS="${XLOCKLIBS} -lgltt"
+  test "x$gltt_includes" = xNONE && gltt_includes=$ac_gltt_includes
+  test "x$gltt_libraries" = xNONE && gltt_libraries=$ac_gltt_libraries
+  ac_cv_path_gltt="no_gltt= ac_gltt_includes=$gltt_includes ac_gltt_libraries=$gltt_libraries"
+  AC_MSG_RESULT([libraries $gltt_libraries, headers $gltt_includes])
+  GLTT=""
+fi
+])
+
+AC_PATH_GLTT
+
+if test "x$gltt_libraries" != x && test "x$gltt_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$gltt_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$gltt_libraries"
+fi
+if test "x$gltt_includes" != x && test "x$gltt_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$gltt_includes"
+fi
+
+ttf=no
+dnl ttf TTF
+
+AC_DEFUN(AC_PATH_TTF_DIRECT,
+[test -z "$ttf_direct_test_library" && ttf_direct_test_library=ttf
+test -z "$ttf_direct_test_function" && ttf_direct_test_function=TT_Init_FreeType
+test -z "$ttf_direct_test_include" && ttf_direct_test_include=freetype.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include/X11          \
+    /usr/unsupported/include  \
+    /usr/athena/include       \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    /usr/openwin/include      \
+                              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$ttf_direct_test_include"; then
+      no_ttf= ac_ttf_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$ttf_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_ttf_includes" | sed s%/X11$%% | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib        \
+    /usr/X11R6.2/lib        \
+    /usr/X11R6.1/lib        \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3        \
+    /usr/lib/X11R6.2        \
+    /usr/lib/X11R6.1        \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${ttf_direct_test_library}.$ac_extension; then
+      no_ttf= ac_ttf_libraries=$ac_dir
+      break 2
+   fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_TTF,
+[AC_REQUIRE_CPP()dnl
+
+ttf_includes=NONE
+ttf_libraries=NONE
+
+AC_MSG_CHECKING(for TTF)
+AC_ARG_WITH(ttf, [  --without-ttf           enable color pixmap TTF mode(s)])
+if test "x$with_ttf" = xno; then
+  no_ttf=yes
+else
+  if test "x$ttf_includes" != xNONE && test "x$ttf_libraries" != xNONE; then
+    no_ttf=
+  else
+AC_CACHE_VAL(ac_cv_path_ttf,
+[# One or both of these vars are not set, and there is no cached value.
+no_ttf=yes
+AC_PATH_TTF_DIRECT
+
+if test "$no_ttf" = yes; then
+  ac_cv_path_ttf="no_ttf=yes"
+else
+  ac_cv_path_ttf="no_ttf= ac_ttf_includes=$ac_ttf_includes ac_ttf_libraries=$ac_ttf_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_ttf"
+fi # with_ttf != no
+
+if test "$no_ttf" = yes; then
+  AC_MSG_RESULT(no)
+  TTF="#"
+else
+  ttf=yes
+  AC_DEFINE(HAVE_TTF)
+  XLOCKLIBS="${XLOCKLIBS} -lttf"
+  test "x$ttf_includes" = xNONE && ttf_includes=$ac_ttf_includes
+  test "x$ttf_libraries" = xNONE && ttf_libraries=$ac_ttf_libraries
+  ac_cv_path_ttf="no_ttf= ac_ttf_includes=$ttf_includes ac_ttf_libraries=$ttf_libraries"
+  AC_MSG_RESULT([libraries $ttf_libraries, headers $ttf_includes])
+  TTF=""
+fi
+])
+
+AC_PATH_TTF
+
+if test "x$ttf_libraries" != x && test "x$ttf_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$ttf_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$ttf_libraries"
+fi
+if test "x$ttf_includes" != x && test "x$ttf_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$ttf_includes"
+fi
+
+gl=no
+dnl OpenGL opengl
+
+dnl test -z "$opengl_direct_test_library" && opengl_direct_test_library=opengl
+AC_DEFUN(AC_PATH_OPENGL_DIRECT,
+[test -z "$opengl_direct_test_library" && opengl_direct_test_library=GL
+test -z "$opengl_direct_test_library" && opengl_direct_test_library=GLU
+test -z "$opengl_direct_test_function" && opengl_direct_test_function=glXCreateContext
+test -z "$opengl_direct_test_include" && opengl_direct_test_include=GL/gl.h
+  for ac_dir in               \
+    /usr/include              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+# Make sure this is not MesaGL
+    if test -r "$ac_dir/$opengl_direct_test_include" && test ! -r "$ac_dir/GL/xmesa.h"; then
+      no_opengl= ac_opengl_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$opengl_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_opengl_includes" | sed s/include/lib/` \
+                          \
+    /usr/lib              \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+# Make sure its not a symbolic link to MesaGL library
+
+    if test -r $ac_dir/lib${opengl_direct_test_library}.$ac_extension && test ! $ac_link_test $ac_dir/lib${opengl_direct_test_library}.$ac_extension && test ! -r $ac_dir/libMesa${opengl_direct_test_library}.$ac_extension; then
+      no_opengl= ac_opengl_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_OPENGL,
+[AC_REQUIRE_CPP()dnl
+
+opengl_includes=NONE
+opengl_libraries=NONE
+
+AC_MSG_CHECKING(for OpenGL)
+AC_ARG_WITH(opengl, [  --without-opengl        disable 3D OpenGL (for GL modes)])
+if test "x$with_opengl" = xno; then
+  no_opengl=yes
+else
+  if test "x$opengl_includes" != xNONE && test "x$opengl_libraries" != xNONE; then
+    no_opengl=
+  else
+AC_CACHE_VAL(ac_cv_path_opengl,
+[# One or both of these vars are not set, and there is no cached value.
+no_opengl=yes
+AC_PATH_OPENGL_DIRECT
+
+if test "$no_opengl" = yes; then
+  ac_cv_path_opengl="no_opengl=yes"
+else
+  ac_cv_path_opengl="no_opengl= ac_opengl_includes=$ac_opengl_includes ac_opengl_libraries=$ac_opengl_libraries"
+
+fi])dnl
+  fi
+  eval "$ac_cv_path_opengl"
+fi # with_opengl != no
+
+if test "$no_opengl" = yes; then
+  AC_MSG_RESULT(no)
+else
+  gl=yes
+  AC_DEFINE(USE_GL)
+  XLOCKLIBS="${XLOCKLIBS} -lGL -lGLU"
+  test "x$opengl_includes" = xNONE && opengl_includes=$ac_opengl_includes
+  test "x$opengl_libraries" = xNONE && opengl_libraries=$ac_opengl_libraries
+  case "${canonical}" in
+    *-*-solaris2* )
+      AC_DEFINE(SUN_OGL_NO_VERTEX_MACROS)
+      if test "x$opengl_includes" = "x/usr/include"; then
+        opengl_includes=""
+      fi
+    ;;
+    *-*-irix5* | *-*-irix6* )
+      XLOCKLIBS="${XLOCKLIBS} -lgl"
+    ;;
+  esac
+  ac_cv_path_opengl="no_opengl= ac_opengl_includes=$opengl_includes ac_opengl_libraries=$opengl_libraries"
+  AC_MSG_RESULT([libraries $opengl_libraries, headers $opengl_includes])
+  GL=""
+fi
+])
+
+AC_PATH_OPENGL
+
+if test "x$opengl_libraries" != x && test "x$opengl_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$opengl_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$opengl_libraries"
+fi
+if test "x$opengl_includes" != x && test "x$opengl_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$opengl_includes"
+fi
+
+dnl MesaGL mesagl
+
+dnl test -z "$mesagl_direct_test_library" && mesagl_direct_test_library=MesaGLU
+AC_DEFUN(AC_PATH_MESAGL_DIRECT,
+[test -z "$mesagl_direct_test_library" && mesagl_direct_test_library=MesaGL
+test -z "$mesagl_direct_test_library" && mesagl_direct_test_library=MesaGLU
+test -z "$mesagl_direct_test_function" && mesagl_direct_test_function=glXCreateContext
+test -z "$mesagl_direct_test_include" && mesagl_direct_test_include=GL/gl.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11/include          \
+                              \
+    /usr/include/X11          \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+                              \
+    /usr/local/X11/include    \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+                              \
+    /usr/local/include/X11    \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$mesagl_direct_test_include"; then
+      no_mesagl= ac_mesagl_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$mesagl_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_mesagl_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11/lib          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+                          \
+    /usr/lib/X11          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+                          \
+    /usr/local/X11/lib    \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+                          \
+    /usr/local/lib/X11    \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/athena/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+    /lib/usr/lib/X11      \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${mesagl_direct_test_library}.$ac_extension; then
+      no_mesagl= ac_mesagl_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_MESAGL,
+[AC_REQUIRE_CPP()dnl
+
+mesagl_includes=NONE
+mesagl_libraries=NONE
+
+AC_MSG_CHECKING(for MesaGL)
+AC_ARG_WITH(mesagl, [  --without-mesagl        disable 3D MesaGL (for GL modes)])
+if test "x$with_mesagl" = xno; then
+  no_mesagl=yes
+else
+  if test "x$mesagl_includes" != xNONE && test "x$mesagl_libraries" != xNONE; then
+    no_mesagl=
+  else
+AC_CACHE_VAL(ac_cv_path_mesagl,
+[# One or both of these vars are not set, and there is no cached value.
+no_mesagl=yes
+AC_PATH_MESAGL_DIRECT
+
+if test "$no_mesagl" = yes; then
+  ac_cv_path_mesagl="no_mesagl=yes"
+else
+  ac_cv_path_mesagl="no_mesagl= ac_mesagl_includes=$ac_mesagl_includes ac_mesagl_libraries=$ac_mesagl_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_mesagl"
+fi # with_mesagl != no
+
+if test "$no_mesagl" = yes; then
+  AC_MSG_RESULT(no)
+  GL="#"
+else
+  if test "$gl" = no; then
+    gl=yes
+    AC_DEFINE(USE_GL)
+    XLOCKLIBS="${XLOCKLIBS} -lMesaGL -lMesaGLU"
+    test "x$mesagl_includes" = xNONE && mesagl_includes=$ac_mesagl_includes
+    test "x$mesagl_libraries" = xNONE && mesagl_libraries=$ac_mesagl_libraries
+    case "${canonical}" in
+      *-*-solaris2* )
+        if test "x$mesagl_includes" = "x/usr/include"; then
+          mesagl_includes=""
+        fi
+      ;;
+    esac
+    ac_cv_path_mesagl="no_mesagl= ac_mesagl_includes=$mesagl_includes ac_mesagl_libraries=$mesagl_libraries"
+    AC_MSG_RESULT([libraries $mesagl_libraries, headers $mesagl_includes])
+    AC_MSG_RESULT(!!!WARNING!!! Known security hole with MesaGL <= 2.6 if setuid root)
+    case "${canonical}" in
+      *-*-linux* )
+        # Testing if MesaGL was compiled against VGA
+        if test -f $mesagl_libraries/libMesaGL.so; then
+          have_mesagl_svga=`nm $mesagl_libraries/libMesaGL.so | grep SVGAMesa | wc -l`
+        else
+          have_mesagl_svga=0
+        fi
+        if eval "test $have_mesagl_svga -ge 1"; then
+          AC_MSG_RESULT([MesaGL library is linked against SVGA: adding -lvga])
+          XLOCKLIBS="${XLOCKLIBS} -lvga"
+        fi
+        # Testing if MesaGL was compiled against glide
+        if test -f $mesagl_libraries/libglide.so; then
+          have_mesagl_glide=`nm $mesagl_libraries/libglide.so | grep grGlideInit | wc -l`
+        else
+          have_mesagl_glide=0
+        fi
+        if eval "test $have_mesagl_glide -ge 1"; then
+          AC_MSG_RESULT([MesaGL library is linked against GLIDE: adding -lglide2x])
+          XLOCKLIBS="${XLOCKLIBS} -lglide2x"
+        fi
+#  Causes major errors for maintainer.  xlock refuses to run.
+#        # Testing if MesaGL was compiled against pthread
+#        if test -f $mesagl_libraries/libpthread.so; then
+#          have_mesagl_pthread=`nm $mesagl_libraries/libpthread.so | grep pthread_once | wc -l`
+#        else
+#          have_mesagl_pthread=0
+#        fi
+#        if eval "test $have_mesagl_pthread -ge 1"; then
+#          AC_MSG_RESULT([MesaGL library is linked against GLIDE: adding -lpthread])
+#          XLOCKLIBS="${XLOCKLIBS} -lpthread"
+#        fi
+       
+        ;;
+    esac
+    GL=""
+  else  
+    AC_MSG_RESULT(ignored - using OpenGL)
+  fi
+
+fi
+])
+
+AC_PATH_MESAGL
+
+if test "x$mesagl_libraries" != x && test "x$mesagl_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="$mesagl_libraries:${XLOCK_LDFLAGS}"
+  XLOCKLIBPATHS="-L$mesagl_libraries ${XLOCKLIBPATHS}"
+fi
+if test "x$mesagl_includes" != x && test "x$mesagl_includes" != xNONE ; then
+  XLOCKINC="-I$mesagl_includes ${XLOCKINC}"
+fi
+
+# Test if (Mesa)GL has GL1.1 features
+# (Should this test be performed only if (Mesa)GL is used? In that case
+# it fails anyway.)
+AC_MSG_CHECKING([Checking for GL >=1.1])
+ac_save_CFLAGS="$CFLAGS"
+ac_save_LIBS="$LIBS"
+CFLAGS="${CFLAGS} ${XLOCKINC}"
+LIBS="${XLOCKLIBPATHS} ${XLOCKLIBS} -lX11 -lXext -lm"
+AC_CACHE_VAL(ac_cv_c_gl1_1,[   
+AC_TRY_LINK([#define _XOPEN_SOURCE 1
+#include <GL/gl.h>], [
+GLint texture;
+glBindTexture(GL_TEXTURE_2D, texture);
+], ac_cv_c_gl1_1=yes, ac_cv_c_gl1_1=no)])
+dnl This does not seem to work on Sun's OpenGL
+dnl if test x"$ac_cv_c_gl1_1" = xyes; then    
+    AC_DEFINE(HAVE_GLBINDTEXTURE)
+    AC_MSG_RESULT(yes)
+dnl else
+dnl    AC_MSG_RESULT(no)
+dnl fi
+CFLAGS="$ac_save_CFLAGS"
+LIBS="$ac_save_LIBS"
+
+dnl DTSAVER DtSaver dtsaver DtSvc
+
+AC_DEFUN(AC_PATH_DTSAVER_DIRECT,
+[test -z "$dtsaver_direct_test_library" && dtsaver_direct_test_library=DtSvc
+test -z "$dtsaver_direct_test_function" && dtsaver_direct_test_function=DtSaverGetWindows
+test -z "$dtsaver_direct_test_include" && dtsaver_direct_test_include=Dt/Saver.h
+  for ac_dir in            \
+    /usr/dt/include        \
+    $extra_include         \
+    ; \
+  do
+    if test -r "$ac_dir/$dtsaver_direct_test_include"; then
+      no_dtsaver= ac_dtsaver_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$dtsaver_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_dtsaver_includes" | sed s/include/lib/` \
+    $extra_lib         \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${dtsaver_direct_test_library}.$ac_extension; then
+      no_dtsaver= ac_dtsaver_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_DTSAVER,
+[AC_REQUIRE_CPP()dnl
+
+dtsaver_includes=NONE
+dtsaver_libraries=NONE
+
+AC_MSG_CHECKING(for DtSaver)
+AC_ARG_WITH(dtsaver, [  --without-dtsaver       disable -dtsaver option])
+if test "x$with_dtsaver" = xno; then
+  no_dtsaver=yes
+else
+  if test "x$dtsaver_includes" != xNONE && test "x$dtsaver_libraries" != xNONE; then
+    no_dtsaver=
+  else
+AC_CACHE_VAL(ac_cv_path_dtsaver,
+[# One or both of these vars are not set, and there is no cached value.
+no_dtsaver=yes
+AC_PATH_DTSAVER_DIRECT
+
+if test "$no_dtsaver" = yes; then
+  ac_cv_path_dtsaver="no_dtsaver=yes"
+else
+  ac_cv_path_dtsaver="no_dtsaver= ac_dtsaver_includes=$ac_dtsaver_includes ac_dtsaver_libraries=$ac_dtsaver_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_dtsaver"
+fi # with_dtsaver != no
+
+if test "$no_dtsaver" = yes; then
+  AC_MSG_RESULT(no)
+else
+  AC_DEFINE(USE_DTSAVER)
+  XLOCKLIBS="${XLOCKLIBS} -lDtSvc"
+  test "x$dtsaver_includes" = xNONE && dtsaver_includes=$ac_dtsaver_includes
+  test "x$dtsaver_libraries" = xNONE && dtsaver_libraries=$ac_dtsaver_libraries
+  ac_cv_path_dtsaver="no_dtsaver= ac_dtsaver_includes=$dtsaver_includes ac_dtsaver_libraries=$dtsaver_libraries"
+  AC_MSG_RESULT([libraries $dtsaver_libraries, headers $dtsaver_includes])
+fi
+])
+
+AC_PATH_DTSAVER
+
+if test "x$dtsaver_libraries" != x && test "x$dtsaver_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$dtsaver_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$dtsaver_libraries"
+fi
+if test "x$dtsaver_includes" != x && test "x$dtsaver_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$dtsaver_includes"
+fi
+
+dnl Xdpms DPMS
+
+AC_DEFUN(AC_PATH_DPMS_DIRECT,
+[test -z "$dpms_direct_test_library" && dpms_direct_test_library=Xdpms
+test -z "$dpms_direct_test_function" && dpms_direct_test_function=DPMSSetTimeouts
+test -z "$dpms_direct_test_include" && dpms_direct_test_include=X11/extensions/dpms.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11R4/include        \
+                              \
+    /usr/include/X11R6.3      \
+    /usr/include/X11R6.2      \
+    /usr/include/X11R6.1      \
+    /usr/include/X11R6        \
+    /usr/include/X11R5        \
+    /usr/include/X11R4        \
+                              \
+    /usr/local/X11R6.3/include  \
+    /usr/local/X11R6.2/include  \
+    /usr/local/X11R6.1/include  \
+    /usr/local/X11R6/include  \
+    /usr/local/X11R5/include  \
+    /usr/local/X11R4/include  \
+                              \
+    /usr/local/include/X11R6.3  \
+    /usr/local/include/X11R6.2  \
+    /usr/local/include/X11R6.1  \
+    /usr/local/include/X11R6  \
+    /usr/local/include/X11R5  \
+    /usr/local/include/X11R4  \
+                              \
+    /usr/X11/include          \
+    /usr/include/X11          \
+    /usr/local/X11/include    \
+    /usr/local/include/X11    \
+                              \
+    /usr/X386/include         \
+    /usr/x386/include         \
+    /usr/XFree86/include/X11  \
+                              \
+    /usr/dt/include           \
+                              \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    /usr/unsupported/include  \
+    /usr/dpms/include         \
+    /usr/local/x11r5/include  \
+    /usr/lpp/Xamples/include  \
+                              \
+    /usr/openwin/include      \
+    /usr/openwin/share/include \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$dpms_direct_test_include"; then
+      no_dpms= ac_dpms_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$dpms_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_dpms_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11R4/lib        \
+                          \
+    /usr/lib/X11R6.3      \
+    /usr/lib/X11R6.2      \
+    /usr/lib/X11R6.1      \
+    /usr/lib/X11R6        \
+    /usr/lib/X11R5        \
+    /usr/lib/X11R4        \
+                          \
+    /usr/local/X11R6.3/lib  \
+    /usr/local/X11R6.2/lib  \
+    /usr/local/X11R6.1/lib  \
+    /usr/local/X11R6/lib  \
+    /usr/local/X11R5/lib  \
+    /usr/local/X11R4/lib  \
+                          \
+    /usr/local/lib/X11R6.3  \
+    /usr/local/lib/X11R6.2  \
+    /usr/local/lib/X11R6.1  \
+    /usr/local/lib/X11R6  \
+    /usr/local/lib/X11R5  \
+    /usr/local/lib/X11R4  \
+                          \
+    /usr/X11/lib          \
+    /usr/lib/X11          \
+    /usr/local/X11/lib    \
+                          \
+    /usr/X386/lib         \
+    /usr/x386/lib         \
+    /usr/XFree86/lib/X11  \
+                          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    /usr/unsupported/lib  \
+    /usr/dpms/lib       \
+    /usr/local/x11r5/lib  \
+    /usr/lpp/Xamples/lib  \
+                          \
+    /usr/openwin/lib      \
+    /usr/openwin/share/lib \
+    /shlib                \
+    /usr/shlib            \
+    /usr/shlib/X11        \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${dpms_direct_test_library}.$ac_extension; then
+      no_dpms= ac_dpms_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_DPMS,
+[AC_REQUIRE_CPP()dnl
+
+dpms_includes=NONE
+dpms_libraries=NONE
+
+AC_MSG_CHECKING(for DPMS)
+AC_ARG_WITH(dpms, [  --without-dpms          disable DPMS])
+dpmslib=no
+if test "x$with_dpms" = xno; then
+  no_dpms=yes
+else
+  if test "x$dpms_includes" != xNONE && test "x$dpms_libraries" != xNONE; then
+    no_dpms=
+  else
+AC_CACHE_VAL(ac_cv_path_dpms,
+[# One or both of these vars are not set, and there is no cached value.
+no_dpms=yes
+AC_PATH_DPMS_DIRECT
+
+if test "$no_dpms" = yes; then
+  ac_cv_path_dpms="no_dpms=yes"
+else
+  ac_cv_path_dpms="no_dpms= ac_dpms_includes=$ac_dpms_includes ac_dpms_libraries=$ac_dpms_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_dpms"
+fi # with_dpms != no
+
+if test "$no_dpms" = yes; then
+  AC_MSG_RESULT(no)
+else
+  AC_DEFINE(USE_DPMS)
+dnl test needed for Digital Unix machines
+  if test "x$ac_dpms_libraries" != xNONE; then
+    XLOCKLIBS="${XLOCKLIBS} -lXdpms"
+  fi
+  test "x$dpms_includes" = xNONE && dpms_includes=$ac_dpms_includes
+  test "x$dpms_libraries" = xNONE && dpms_libraries=$ac_dpms_libraries
+  ac_cv_path_dpms="no_dpms= ac_dpms_includes=$dpms_includes ac_dpms_libraries=$dpms_libraries"
+  AC_MSG_RESULT([libraries $dpms_libraries, headers $dpms_includes])
+fi
+])
+
+AC_PATH_DPMS
+
+if test "x$dpms_libraries" != x && test "x$dpms_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$dpms_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$dpms_libraries"
+fi
+if test "x$dpms_includes" != x && test "x$dpms_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$dpms_includes"
+fi
+
+sound=no
+dnl RPLAY RPlay rplay
+
+AC_DEFUN(AC_PATH_RPLAY_DIRECT,
+[test -z "$rplay_direct_test_library" && rplay_direct_test_library=rplay
+test -z "$rplay_direct_test_function" && rplay_direct_test_function=rplay_open_default
+test -z "$rplay_direct_test_include" && rplay_direct_test_include=rplay.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11/include          \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$rplay_direct_test_include"; then
+      no_rplay= ac_rplay_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$rplay_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_rplay_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11/lib          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${rplay_direct_test_library}.$ac_extension; then
+      no_rplay= ac_rplay_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_RPLAY,
+[AC_REQUIRE_CPP()dnl
+
+rplay_includes=NONE
+rplay_libraries=NONE
+
+AC_MSG_CHECKING(for RPLAY)
+AC_ARG_WITH(rplay, [  --without-rplay         disable RPLAY sounds])
+if test "x$with_rplay" = xno; then
+  no_rplay=yes
+else
+  if test "x$rplay_includes" != xNONE && test "x$rplay_libraries" != xNONE; then
+    no_rplay=
+  else
+AC_CACHE_VAL(ac_cv_path_rplay,
+[# One or both of these vars are not set, and there is no cached value.
+no_rplay=yes
+AC_PATH_RPLAY_DIRECT
+
+if test "$no_rplay" = yes; then
+  ac_cv_path_rplay="no_rplay=yes"
+else
+  ac_cv_path_rplay="no_rplay= ac_rplay_includes=$ac_rplay_includes ac_rplay_libraries=$ac_rplay_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_rplay"
+fi # with_rplay != no
+
+if test "$no_rplay" = yes; then
+  AC_MSG_RESULT(no)
+else
+dnl  solaris26=no
+dnl  case "${canonical}" in
+dnl    *-*-solaris2.6 )
+dnl    solaris26=yes
+dnl    ;;
+dnl  esac
+dnl  if test "$CC" = gcc && test "$solaris26" = yes; then
+dnl    AC_MSG_RESULT(ignored - problems here with gcc and solaris2.6)
+dnl  else
+    sound=yes
+    AC_DEFINE(USE_RPLAY)
+    XLOCKLIBS="${XLOCKLIBS} -lrplay"
+    test "x$rplay_includes" = xNONE && rplay_includes=$ac_rplay_includes
+    test "x$rplay_libraries" = xNONE && rplay_libraries=$ac_rplay_libraries
+    ac_cv_path_rplay="no_rplay= ac_rplay_includes=$rplay_includes ac_rplay_libraries=$rplay_libraries"
+    AC_MSG_RESULT([libraries $rplay_libraries, headers $rplay_includes])
+dnl  fi
+fi
+])
+
+AC_PATH_RPLAY
+
+if test "x$rplay_libraries" != x && test "x$rplay_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$rplay_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$rplay_libraries"
+fi
+if test "x$rplay_includes" != x && test "x$rplay_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$rplay_includes"
+fi
+
+dnl NAS audio
+
+AC_DEFUN(AC_PATH_NAS_DIRECT,
+[test -z "$nas_direct_test_library" && nas_direct_test_library=audio
+test -z "$nas_direct_test_function" && nas_direct_test_function=AuOpenServer
+test -z "$nas_direct_test_include" && nas_direct_test_include=audio/audio.h
+  for ac_dir in               \
+    /usr/X11R6.3/include      \
+    /usr/X11R6.2/include      \
+    /usr/X11R6.1/include      \
+    /usr/X11R6/include        \
+    /usr/X11R5/include        \
+    /usr/X11/include          \
+    /usr/local/include        \
+    /usr/remote/include       \
+    /usr/include              \
+    $extra_include            \
+    ; \
+  do
+    if test -r "$ac_dir/$nas_direct_test_include"; then
+      no_nas= ac_nas_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$nas_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_nas_includes" | sed s/include/lib/` \
+                          \
+    /usr/X11R6.3/lib      \
+    /usr/X11R6.2/lib      \
+    /usr/X11R6.1/lib      \
+    /usr/X11R6/lib        \
+    /usr/X11R5/lib        \
+    /usr/X11/lib          \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${nas_direct_test_library}.$ac_extension; then
+      no_nas= ac_nas_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_NAS,
+[AC_REQUIRE_CPP()dnl
+
+nas_includes=NONE
+nas_libraries=NONE
+
+AC_MSG_CHECKING(for NAS)
+AC_ARG_WITH(nas, [  --without-nas           disable NAS sounds])
+if test "x$with_nas" = xno; then
+  no_nas=yes
+else
+  if test "x$nas_includes" != xNONE && test "x$nas_libraries" != xNONE; then
+    no_nas=
+  else
+AC_CACHE_VAL(ac_cv_path_nas,
+[# One or both of these vars are not set, and there is no cached value.
+no_nas=yes
+AC_PATH_NAS_DIRECT
+
+if test "$no_nas" = yes; then
+  ac_cv_path_nas="no_nas=yes"
+else
+  ac_cv_path_nas="no_nas= ac_nas_includes=$ac_nas_includes ac_nas_libraries=$ac_nas_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_nas"
+fi # with_nas != no
+
+if test "$no_nas" = yes; then
+  AC_MSG_RESULT(no)
+else
+  if test "$sound" = no; then
+    sgi=no
+    case "${canonical}" in
+      *-*-irix5* | *-*-irix6* )
+        sgi=yes
+      ;;
+    esac
+    if test "$sgi" = yes; then
+      AC_MSG_RESULT(ignored - problems here with audio and nas)
+    else
+      sound=yes
+      AC_DEFINE(USE_NAS)
+      XLOCKLIBS="${XLOCKLIBS} -laudio"
+dnl    XLOCKLIBS="${XLOCKLIBS} -lnas"
+      test "x$nas_includes" = xNONE && nas_includes=$ac_nas_includes
+      test "x$nas_libraries" = xNONE && nas_libraries=$ac_nas_libraries
+      ac_cv_path_nas="no_nas= ac_nas_includes=$nas_includes ac_nas_libraries=$nas_libraries"
+      AC_MSG_RESULT([libraries $nas_libraries, headers $nas_includes])
+    fi
+  else
+      AC_MSG_RESULT(ignored - using rplay)
+  fi
+fi
+])
+
+AC_PATH_NAS
+
+if test "x$nas_libraries" != x && test "x$nas_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$nas_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$nas_libraries"
+fi
+if test "x$nas_includes" != x && test "x$nas_includes" != xNONE ; then
+  XLOCKINC="${XLOCKINC} -I$nas_includes"
+fi
+
+dnl crypt CRYPT
+
+AC_DEFUN(AC_PATH_CRYPT_DIRECT,
+[test -z "$crypt_direct_test_library" && crypt_direct_test_library=crypt
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$crypt_direct_test_library $LIBS"
+for ac_dir in \
+    /usr/lib              \
+    /usr/local/lib        \
+    /usr/remote/lib       \
+    $extra_lib            \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${crypt_direct_test_library}.$ac_extension; then
+      no_crypt= ac_crypt_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+AC_DEFUN(AC_PATH_CRYPT,
+[AC_REQUIRE_CPP()dnl
+
+crypt_libraries=NONE
+
+AC_MSG_CHECKING(for CRYPT)
+AC_ARG_WITH(crypt, [  --without-crypt         disable CRYPT])
+if test "x$with_crypt" = xno; then
+  no_crypt=yes
+else
+  if test "x$crypt_libraries" != xNONE; then
+    no_crypt=
+  else
+AC_CACHE_VAL(ac_cv_path_crypt,
+[# One or both of these vars are not set, and there is no cached value.
+no_crypt=yes
+AC_PATH_CRYPT_DIRECT
+
+if test "$no_crypt" = yes; then
+  ac_cv_path_crypt="no_crypt=yes"
+else
+  ac_cv_path_crypt="no_crypt= ac_crypt_libraries=$ac_crypt_libraries"
+fi])dnl
+  fi
+  eval "$ac_cv_path_crypt"
+fi # with_crypt != no
+
+if test "$no_crypt" = yes; then
+  AC_MSG_RESULT(no)
+else
+  XLOCKLIBS="${XLOCKLIBS} -lcrypt"
+  test "x$crypt_libraries" = xNONE && crypt_libraries=$ac_crypt_libraries
+  ac_cv_path_crypt="no_crypt= ac_crypt_libraries=$crypt_libraries"
+  AC_MSG_RESULT([libraries $crypt_libraries])
+fi
+])
+
+AC_PATH_CRYPT
+
+if test "x$crypt_libraries" != x && test "x$crypt_libraries" != xNONE ; then
+  XLOCK_LDFLAGS="${XLOCK_LDFLAGS}:$crypt_libraries"
+  XLOCKLIBPATHS="${XLOCKLIBPATHS} -L$crypt_libraries"
+fi
+
+
+XGLOCK=""
+XGLOCKDIR=""
+INSTALL_XGLOCK=""
+UNINSTALL_XGLOCK=""
+XGLOCK_MAKEFILE=""
+AC_ARG_WITH(gtk, [  --without-gtk           disable GTK (no xglock build)],)
+if test "x$with_gtk" != "xno" ; then
+   AC_PATH_GTK(1.0.4, 
+               have_gtk="yes",
+               have_gtk="no")
+fi
+
+dnl GtkFontSel gtk font selection widget
+
+AC_DEFUN(AC_PATH_GTKFONTSEL_DIRECT,
+[test -z "$gtkfontsel_direct_test_library" && gtkfontsel_direct_test_library="gtkfontsel"
+test -z "$gtkfontsel_direct_test_function" && gtkfontsel_direct_test_function="gtk_font_selection_new"
+test -z "$gtkfontsel_direct_test_include" && gtkfontsel_direct_test_include="gtkfontsel.h"
+  for ac_dir in                      \
+    /usr/include                     \
+    /usr/include/fontsel             \
+    /usr/include/gtkfontsel          \
+    /usr/gtk/include                 \
+    /usr/gtk/fontsel                 \
+    /usr/gtk/gtkfontsel              \
+    /usr/gtk/fontsel/include         \
+    /usr/gtk/gtkfontsel/include      \
+    /usr/local/include               \
+    /usr/local/include/fontsel       \
+    /usr/local/include/gtkfontsel    \
+    /usr/local/gtk/include           \
+    /usr/X11R6.3/include             \
+    /usr/X11R6.3/include/gtk         \
+    /usr/X11R6.2/include             \
+    /usr/X11R6.2/include/gtk         \
+    /usr/X11R6.1/include             \
+    /usr/X11R6.1/include/gtk         \
+    /usr/X11R6/include               \
+    /usr/X11R6/include/gtk           \
+    /usr/X11R5/include               \
+    /usr/X11R5/include/gtk           \
+    /usr/X11R4/include               \
+    /usr/X11R4/include/gtk           \
+    /usr/X11/include                 \
+    /usr/X11/include/gtk             \
+    /usr/X386/include                \
+    /usr/X386/include/gtk            \
+    /usr/x386/include                \
+    /usr/x386/include/gtk            \
+    /usr/XFree86/include             \
+    /usr/XFree86/include/gtk         \
+    /usr/local/X11R6.3/include       \
+    /usr/local/X11R6.3/include/gtk   \
+    /usr/local/X11R6.2/include       \
+    /usr/local/X11R6.2/include/gtk   \
+    /usr/local/X11R6.1/include       \
+    /usr/local/X11R6.1/include/gtk   \
+    /usr/local/X11R6/include         \
+    /usr/local/X11R6/include/gtk     \
+    /usr/local/X11R5/include         \
+    /usr/local/X11R5/include/gtk     \
+    /usr/local/X11R4/include         \
+    /usr/local/X11R4/include/gtk     \
+    /usr/local/X11/include           \
+    /usr/local/X11/include/gtk       \
+    /usr/local/X386/include          \
+    /usr/local/X386/include/gtk      \
+    /usr/local/x386/include          \
+    /usr/local/x386/include/gtk      \
+    /usr/local/XFree86/include       \
+    /usr/local/XFree86/include/gtk   \
+    /usr/local/include/X11R6.3       \
+    /usr/local/include/X11R6.3/gtk   \
+    /usr/local/include/X11R6.2       \
+    /usr/local/include/X11R6.2/gtk   \
+    /usr/local/include/X11R6.1       \
+    /usr/local/include/X11R6.1/gtk   \
+    /usr/local/include/X11R6         \
+    /usr/local/include/X11R6/gtk     \
+    /usr/local/include/X11R5         \
+    /usr/local/include/X11R5/gtk     \
+    /usr/local/include/X11R4         \
+    /usr/local/include/X11R4/gtk     \
+    /usr/local/include/X11           \
+    /usr/local/include/X11/gtk       \
+    /usr/local/include/X386          \
+    /usr/local/include/X386/gtk      \
+    /usr/local/include/x386          \
+    /usr/local/include/x386/gtk      \
+    /usr/local/include/XFree86       \
+    /usr/local/include/XFree86/gtk   \
+    /usr/local/dt/include            \
+    /usr/local/dt/include/gtk        \
+    /usr/dt/include                  \
+    /usr/dt/include/gtk              \
+    /usr/unsupported/include         \
+    /usr/unsupported/include/gtk     \
+    /usr/athena/include              \
+    /usr/athena/include/gtk          \
+    /usr/local/x11r5/include         \
+    /usr/local/x11r5/include/gtk     \
+    /usr/lpp/Xamples/include         \
+    /usr/lpp/Xamples/include/gtk     \
+    $extra_include                   \
+    ; \
+  do
+    if test -r "$ac_dir/$gtkfontsel_direct_test_include"; then
+      no_gtkfontsel= ac_gtkfontsel_includes=$ac_dir
+      break
+    fi
+  done
+
+# Check for the libraries.
+# See if we find them without any special options.
+# Do not add to $LIBS permanently.
+ac_save_LIBS="$LIBS"
+LIBS="-l$gtkfontsel_direct_test_library $LIBS"
+# First see if replacing the include by lib works.
+for ac_dir in `echo "$ac_gtkfontsel_includes" | sed s/include/lib/` \
+                                     \
+    /usr/X11R6.3/lib                 \
+    /usr/X11R6.2/lib                 \
+    /usr/X11R6.1/lib                 \
+    /usr/X11R6/lib                   \
+    /usr/lib/X11                     \
+    /usr/lib/X11/gtk                 \
+    /usr/gtk/lib                     \
+    /usr/X11/gtk/lib                 \
+    /usr/local/lib                   \
+    /usr/local/lib/X11               \
+    /usr/X11/local/lib               \
+    /usr/X11/local/lib/X11           \
+    /usr/X11/local/X11/lib           \
+    /usr/local/lib/gtk               \
+    /usr/local/lib/X11/gtk           \
+    /usr/X11/local/lib/gtk           \
+    /usr/X11/local/lib/X11/gtk       \
+    /usr/X11/local/X11/lib/gtk       \
+    /usr/local/gtk/lib               \
+    /usr/local/X11/gtk/lib           \
+    $extra_lib                       \
+    ; \
+do
+  for ac_extension in a so sl; do
+    if test -r $ac_dir/lib${gtkfontsel_direct_test_library}.$ac_extension; then
+      no_gtkfontsel= ac_gtkfontsel_libraries=$ac_dir
+      break 2
+    fi
+  done
+done
+LIBS="$ac_save_LIBS"])
+
+AC_DEFUN(AC_PATH_GTKFONTSEL,
+[AC_REQUIRE_CPP()dnl
+
+gtkfontsel_includes=NONE
+gtkfontsel_libraries=NONE
+
+AC_MSG_CHECKING(for GTK FontSelection widget)
+AC_ARG_WITH(gtkfontsel, [  --without-gtkfontsel    disable gtkfontsel widget (for xglock)])
+if test "x$with_gtkfontsel" = xno; then
+  no_gtkfontsel=yes
+else
+  if test "x$gtkfontsel_includes" != xNONE && test "x$gtkfontsel_libraries" != xNONE; then
+    no_gtkfontsel=
+  else
+    AC_PATH_GTKFONTSEL_DIRECT
+  fi
+fi # with_gtkfontsel != no
+
+if test "$no_gtkfontsel" = yes; then
+  AC_MSG_RESULT(no)
+else
+  XGLOCKLIBS="-lgtkfontsel ${XGLOCKLIBS}"
+  test "x$gtkfontsel_includes" = xNONE && gtkfontsel_includes=$ac_gtkfontsel_includes
+  test "x$gtkfontsel_libraries" = xNONE && gtkfontsel_libraries=$ac_gtkfontsel_libraries
+  AC_MSG_RESULT([libraries $gtkfontsel_libraries, headers $gtkfontsel_includes])
+  AC_DEFINE(HAVE_GTK_FONTSEL_WIDGET)
+fi
+])
+
+if test "x$have_gtk" = "xyes"; then
+
+  AC_PATH_GTKFONTSEL
+
+  if test "x$gtkfontsel_libraries" != x && test "x$gtkfontsel_libraries" != xNONE ; then
+    XGLOCK_LDFLAGS="${XGLOCK_LDFLAGS}:$gtkfontsel_libraries"
+    XGLOCKLIBPATHS="${XGLOCKLIBPATHS} -L$gtkfontsel_libraries"
+  fi
+  if test "x$gtkfontsel_includes" != x && test "x$gtkfontsel_includes" != xNONE ; then
+    XGLOCKINC="${XGLOCKINC} -I$gtkfontsel_includes"
+  fi
+
+  if test -n "${x_includes}"; then
+    XGLOCKINC="-I${x_includes} ${XGLOCKINC}"
+    XGLOCK="xglock"
+    XGLOCKDIR="xglock"
+    INSTALL_XGLOCK="install_xglock"
+    UNINSTALL_XGLOCK="uninstall_xglock"
+    XGLOCK_MAKEFILE="xglock/Makefile"
+  fi
+  if test -n "${x_libraries}"; then
+    XGLOCK_LDFLAGS="${XGLOCK_LDFLAGS}:/usr/lib:${x_libraries}"
+    XGLOCKLIBPATHS="${XGLOCKLIBPATHS} -L${x_libraries}"
+    XGLOCKLIBS="${XGLOCKLIBS} -lXt"
+  fi
+fi
+
+dnl Should have a tester for XHPUX Xhp
+
+dnl Now we handle the various system dependant problems
+dnl that are not addressed in the X header files, or things dealing
+dnl with utility quirks on some systems.
+
+aixv3=no
+dirent=yes
+
+case "${canonical}" in
+
+  *-*-aix* )
+    BITMAPTYPE="ibm"
+    PIXMAPTYPE="ibm"
+    AC_DEFINE(AIXV3)
+    aixv3=yes
+    case "${canonical}" in
+      *-*-aix2* | *-*-aix3.0* | *-*-aix3.1* )
+        AC_DEFINE(LESS_THAN_AIX3_2)
+      ;;
+    esac
+  ;;
+
+  *-*-freebsd* | *-*-openbsd* | *-*-netbsd*  )
+    BITMAPTYPE="bsd"
+    PIXMAPTYPE="bsd"
+    INSTPGMFLAGS="-s -o root -m 4111"
+    XLOCKLDFLAGS="-Wl,-R${XLOCK_LDFLAGS}"
+    XMLOCKLDFLAGS="-Wl,-R${XMLOCK_LDFLAGS}"
+    XALOCKLDFLAGS="-Wl,-R${XALOCK_LDFLAGS}"
+  ;;
+
+  *-*-dgux5* )
+    BITMAPTYPE="x11"
+    PIXMAPTYPE="x11"
+  ;;
+
+  *-*-hpux* )
+    if test "${CC}" = "cc" ; then
+      CFLAGS="${CFLAGS} -O -Aa -z -D_HPUX_SOURCE"
+      GPROF_CFLAGS="${GPROF_CFLAGS} -Aa -z -D_HPUX_SOURCE"
+    fi
+dnl    LDFLAGS=-Wl,-B,immediate
+    XLOCKLIBS="-lXhp11 ${XLOCKLIBS}"
+    AC_DEFINE(SYSV)
+    AC_DEFINE(SVR4)
+    BITMAPTYPE="hp"
+    PIXMAPTYPE="hp"
+  ;;
+
+  *-*-irix5* | *-*-irix6* )
+    if test "${CC}" = "cc" ; then
+      CFLAGS="${CFLAGS} -fullwarn"
+    fi
+    BITMAPTYPE="sgi"
+    PIXMAPTYPE="sgi"
+  ;;
+
+  *-*-linux* )
+    AC_CHECK_HEADER(elf.h, AC_DEFINE(HAVE_SHADOW))
+dnl    CFLAGS="${CFLAGS} -ansi -pedantic"
+    AC_DEFINE(linux)
+dnl    AC_DEFINE(__i386__)
+    AC_DEFINE(_POSIX_SOURCE)
+    AC_DEFINE(_BSD_SOURCE)
+    AC_DEFINE(_GNU_SOURCE)
+dnl    AC_DEFINE(DX_LOCALE)
+    if test -e /etc/shadow ; then
+      INSTPGMFLAGS="-g shadow -m 2111"
+      case `ls -l /etc/shadow` in
+        -???r?????\ *\ shadow\ *\ /etc/shadow)  # group shadow can read it
+          INSTPGMFLAGS="-g shadow -m 2111"
+          ;;
+        *)
+          INSTPGMFLAGS="-o root -m 4111"
+          ;;
+      esac
+    fi
+    INSTPGMFLAGS="-s $INSTPGMFLAGS"
+    BITMAPTYPE="linux"
+    PIXMAPTYPE="linux"
+dnl if Shadow and not elf
+dnl XLOCKLIBS="${XLOCKLIBS} -lgdbm"
+  ;;
+
+  *-*-osf* )
+    BITMAPTYPE="dec"
+    PIXMAPTYPE="dec"
+    AC_MSG_CHECKING(for Digital Unix Enhanced Security)
+    if test -f /usr/sbin/rcmgr && test -f /etc/rc.config ; then
+      if test X`/usr/sbin/rcmgr get SECURITY` = XENHANCED ; then
+        AC_MSG_RESULT(yes)
+        AC_DEFINE(OSF1_ENH_SEC)
+        AC_SUBST(OSF1_ENH_SEC)
+        XLOCKLIBS="${XLOCKLIBS} -lsecurity"
+        INSTPGMFLAGS="-s -g auth -m 2111"
+      else
+        AC_MSG_RESULT(no)
+      fi
+    fi
+  ;;
+
+  *-*-sco* )
+    BITMAPTYPE="sco"
+    PIXMAPTYPE="sco"
+    AC_DEFINE(HAVE_SHADOW)
+    AC_DEFINE(SYSV)
+  ;;
+
+  *-*-solaris2* )
+    AC_DEFINE(SOLARIS2)
+    case "${canonical}" in
+      *-*-solaris2.0* | *-*-solaris2.1* | *-*-solaris2.2* | *-*-solaris2.3* | *-*-solaris2.4* )
+        AC_DEFINE(LESS_THAN_SOLARIS2_5)
+      ;;
+    esac
+    INSTPGMFLAGS="-s -o root -m 4111"
+    AC_DEFINE(HAVE_SHADOW)
+    AC_DEFINE(SYSV)
+    AC_DEFINE(SVR4)
+    BITMAPTYPE="sun"
+    PIXMAPTYPE="sol"
+dnl    XLOCKLIBS="${XLOCKLIBS} -lsocket -lnsl -lposix4"
+    XLOCKLIBS="${XLOCKLIBS} -lposix4"
+    LIBS="${LIBS} -lsocket -lnsl -lposix4"
+    XLOCKLDFLAGS="-R${XLOCK_LDFLAGS}"
+    XMLOCKLDFLAGS="-R${XMLOCK_LDFLAGS}"
+    XALOCKLDFLAGS="-R${XALOCK_LDFLAGS}"
+  ;;
+
+  *-*-sunos4* )
+    AC_DEFINE(SUNOS4)
+    BITMAPTYPE="sun"
+    PIXMAPTYPE="sun"
+  ;;
+
+  *-*-sysv5* )
+    BITMAPTYPE="x11"
+    PIXMAPTYPE="x11"
+  ;;
+
+  *)
+    BITMAPTYPE="x11"
+    PIXMAPTYPE="x11"
+  ;;
+esac
+
+
+if test "$dirent" = yes; then
+  AC_HEADER_DIRENT
+fi
+
+dnl Rather have a usleep
+AC_CHECK_FUNC(usleep, AC_DEFINE(HAVE_USLEEP),
+AC_CHECK_FUNC(nanosleep, AC_DEFINE(HAVE_NANOSLEEP)))
+
+dnl AC_CHECK_FUNCS(gettimeofday) 
+AC_MSG_CHECKING(how to call gettimeofday)
+AC_CACHE_VAL(ac_cv_gettimeofday_args,
+ [AC_TRY_COMPILE([#include <stdlib.h>
+#include <sys/time.h>],
+     [struct timeval tv; struct timezone tzp;
+      gettimeofday(&tv, &tzp);],
+     [ac_gettimeofday_args=2],
+     [AC_TRY_COMPILE([#include <stdlib.h>
+#include <sys/time.h>],
+         [struct timeval tv; gettimeofday(&tv);],
+         [ac_gettimeofday_args=1],
+         [ac_gettimeofday_args=0])])
+  ac_cv_gettimeofday_args=$ac_gettimeofday_args])
+ac_gettimeofday_args=$ac_cv_gettimeofday_args
+if test $ac_gettimeofday_args = 2 ; then
+  AC_DEFINE(HAVE_GETTIMEOFDAY)
+  AC_DEFINE(GETTIMEOFDAY_TWO_ARGS)
+  AC_MSG_RESULT(two arguments)
+elif test $ac_gettimeofday_args = 1 ; then
+  AC_DEFINE(HAVE_GETTIMEOFDAY)
+  AC_MSG_RESULT(one argument)
+else
+  AC_MSG_RESULT(unknown)
+fi
+AC_CHECK_FUNCS(tzset timelocal)
+
+AC_C_INLINE
+
+srand=no
+AC_CHECK_FUNC(srand48, AC_DEFINE(SRAND,srand48) AC_DEFINE(LRAND,lrand48)
+  AC_DEFINE(MAXRAND,2147483648.0),
+[AC_CHECK_FUNC(srandom, AC_DEFINE(SRAND,srandom) AC_DEFINE(LRAND,random)
+  AC_DEFINE(MAXRAND,2147483648.0),
+AC_CHECK_FUNC(srand, AC_DEFINE(SRAND,srand) AC_DEFINE(LRAND,rand) srand=yes))])
+
+if test "$srand" = yes; then
+  if test "$aixv3" = yes; then
+    AC_DEFINE(MAXRAND,2147483648.0)
+  else
+    AC_DEFINE(MAXRAND,32768.0)
+  fi
+fi
+
+AC_MSG_CHECKING([matherr support])
+AC_CACHE_VAL(ac_cv_c_matherr,[   
+AC_TRY_COMPILE([#define _XOPEN_SOURCE 1
+#include <math.h>], [
+struct exception x;
+x.type = DOMAIN;  
+x.type = SING; 
+], ac_cv_c_matherr=yes, ac_cv_c_matherr=no)])
+if test x"$ac_cv_c_matherr" = xyes; then    
+    AC_DEFINE(USE_MATHERR)
+    AC_MSG_RESULT(yes)
+else
+    AC_MSG_RESULT(no)
+fi
+
+dnl Problems here if -I/usr/include used with gcc on Solaris
+AC_MSG_CHECKING([struct sigset_t])
+AC_CACHE_VAL(ac_cv_c_sigset_t,[   
+AC_TRY_COMPILE([/*#define _XOPEN_SOURCE 1*/
+#include <signal.h>], [
+typedef struct {unsigned long __sigbits[4];} sigset_t;
+sigset_t sigmask;
+], ac_cv_c_sigset_t=yes, ac_cv_c_sigset_t=no)])
+if test x"$ac_cv_c_sigset_t" = xyes; then    
+  AC_DEFINE(HAVE_STRUCT_SIGSET_T)
+  AC_MSG_RESULT(yes)
+else
+  AC_MSG_RESULT(no)
+fi
+
+AC_ARG_ENABLE(bitmapdir, [  --enable-bitmapdir=DIR  set directory for bitmaps, default is ./bitmaps],bitmap_dir=$enableval,bitmap_dir=no)
+case "x$bitmap_dir" in
+x/*|x.*)
+  AC_MSG_RESULT([setting BITMAPDIR = $enableval])
+  BITMAPDIR=$enableval
+  if test ! -d $bitmap_dir; then
+    AC_MSG_RESULT([Warning: Directory $enableval does not exist])
+  fi
+  ;;
+*)
+  BITMAPDIR='$(top_srcdir)/bitmaps'
+  bitmap_dir='$top_srcdir/bitmaps'
+  ;;
+esac
+
+AC_ARG_ENABLE(bitmaptype, [  --enable-bitmaptype=name
+                          set name for bitmap type],bitmap_type=$enableval,bitmap_type=no)
+case "x$bitmap_type" in
+xyes*|xno*)
+  ;;
+*)
+  AC_MSG_RESULT([setting BITMAPTYPE = $enableval])
+  BITMAPTYPE=$enableval
+  if test ! -f $bitmap_dir/l-$BITMAPTYPE.xbm; then
+    AC_MSG_RESULT([Warning: Bitmap $BITMAPDIR/l-$BITMAPTYPE.xbm does not exist])
+  fi
+  ;;
+esac
+
+AC_ARG_ENABLE(pixmapdir, [  --enable-pixmapdir=DIR  set directory for pixmaps, default is ./pixmaps],pixmap_dir=$enableval,pixmap_dir=no)
+case "x$pixmap_dir" in
+x/*|x.*)
+  AC_MSG_RESULT([setting PIXMAPDIR = $enableval])
+  PIXMAPDIR=$enableval
+  if test ! -d $pixmap_dir; then
+    AC_MSG_RESULT([Warning: Directory $enableval does not exist])
+  fi
+  ;;
+*)
+  PIXMAPDIR='$(top_srcdir)/pixmaps'
+  pixmap_dir='$top_srcdir/pixmaps'
+  ;;
+esac
+
+AC_ARG_ENABLE(pixmaptype, [  --enable-pixmaptype=name
+                          set name for pixmap type],pixmap_type=$enableval,pixmap_type=no)
+case "x$pixmap_type" in
+xyes*|xno*)
+  ;;
+*)
+  AC_MSG_RESULT([setting PIXMAPTYPE = $enableval])
+  PIXMAPTYPE=$enableval
+  if test ! -f $pixmap_dir/m-$PIXMAPTYPE.xpm; then
+    AC_MSG_RESULT([Warning: Pixmap $PIXMAPDIR/m-$PIXMAPTYPE.xpm does not exist])
+  fi
+  ;;
+esac
+
+AC_ARG_ENABLE(mapdir, [  --enable-mapdir=DIR     set directory for bitmaps and pixmaps],map_dir=$enableval,map_dir=no)
+case "x$map_dir" in
+x/*|x.*)
+  AC_MSG_RESULT([setting BITMAPDIR = $enableval])
+  BITMAPDIR=$enableval
+  AC_MSG_RESULT([setting PIXMAPDIR = $enableval])
+  PIXMAPDIR=$enableval
+  if test ! -d $map_dir; then
+    AC_MSG_RESULT([Warning: Directory $enableval does not exist])
+  fi
+  ;;
+*)
+  BITMAPDIR='$(top_srcdir)/bitmaps'
+  bitmap_dir='$top_srcdir/bitmaps'
+  PIXMAPDIR='$(top_srcdir)/pixmaps'
+  pixmap_dir='$top_srcdir/pixmaps'
+  ;;
+esac
+
+AC_ARG_ENABLE(maptype, [  --enable-maptype=name   set name for bitmap and pixmap type],map_type=$enableval,map_type=no)
+case "x$map_type" in
+xyes*|xno*)
+  ;;
+*)
+  AC_MSG_RESULT([setting BITMAPTYPE = $enableval])
+  BITMAPTYPE=$enableval
+  if test ! -f $map_dir/l-$BITMAPTYPE.xbm; then
+    AC_MSG_RESULT([Warning: Bitmap $BITMAPDIR/l-$BITMAPTYPE.xbm does not exist])
+  fi
+  AC_MSG_RESULT([setting PIXMAPTYPE = $enableval])
+  PIXMAPTYPE=$enableval
+  if test ! -f $map_dir/m-$PIXMAPTYPE.xpm; then
+    AC_MSG_RESULT([Warning: Pixmap $PIXMAPDIR/m-$PIXMAPTYPE.xpm does not exist])
+  fi
+  ;;
+esac
+
+if test "$sound" = no; then
+  AC_ARG_ENABLE(def_play, [  --enable-def-play=program
+                          set def-play to program that plays sounds],def_play=$enableval,def_play=no)
+  if test "$def_play" != no; then
+    AC_MSG_RESULT([defining option DEF_PLAY = "$enableval"])
+    AC_DEFINE_UNQUOTED(DEF_PLAY,"$enableval")
+  fi
+fi
+
+AC_ARG_ENABLE(vroot, [  --disable-vroot         disables xlock from being able to run in root window
+                          (some window managers have problems)],use_vroot=$enableval,use_vroot=yes)
+if test "$use_vroot" = yes; then
+  AC_MSG_RESULT([defining option USE_VROOT])
+  AC_DEFINE(USE_VROOT)
+fi
+
+AC_ARG_ENABLE(allow-root, [  --disable-allow-root    allows users to turn off allowroot (default is to
+                          always allow root to be able to unlock xlock)],allow_root=$enableval,allow_root=yes)
+if test "$allow_root" = yes; then
+  AC_MSG_RESULT([defining option ALWAYS_ALLOW_ROOT])
+  AC_DEFINE(ALWAYS_ALLOW_ROOT)
+fi
+
+case ${canonical} in
+    *-*-linux* | *-*-freebsd* | *-*-openbsd* | *-*-netbsd*  )
+      AC_ARG_ENABLE(vtlock, [  --enable-vtlock         allows to turn on VT switch lock (default is to be
+                          able to switch to another VT)],vtlock=$enableval,vtlock=no)
+      if test "$vtlock" = yes; then
+        AC_MSG_RESULT([defining option USE_VTLOCK])
+        AC_DEFINE(USE_VTLOCK)
+      fi
+      ;;
+    *)
+      ;;
+esac
+
+AC_ARG_ENABLE(syslog, [  --enable-syslog         enable syslog logging],use_syslog=$enableval,use_syslog=no)
+if test "$use_syslog" = yes; then
+  AC_MSG_RESULT([defining option USE_SYSLOG])
+  AC_DEFINE(USE_SYSLOG)
+fi
+AC_ARG_ENABLE(multiple-user, [  --enable-multiple-user  enable multiple users],use_multiple_user=$enableval,use_multiple_user=no)
+if test "$use_multiple_user" = yes; then
+  AC_MSG_RESULT([defining option USE_MULTIPLE_USER])
+  AC_DEFINE(USE_MULTIPLE_USER)
+fi
+AC_ARG_ENABLE(multiple-root, [  --enable-multiple-root  enable multiple root users],use_multiple_root=$enableval,use_multiple_root=no)
+if test "$use_multiple_root" = yes; then
+  AC_MSG_RESULT([defining option USE_MULTIPLE_ROOT])
+  AC_DEFINE(USE_MULTIPLE_ROOT)
+fi
+AC_ARG_ENABLE(window-visibility, [  --enable-window-visibility
+                          allow a window to be displayed over xlock],use_window_visiblity=$enableval,use_window_visibility=no)
+if test "$use_window_visibility" = yes; then
+  AC_MSG_RESULT([defining option USE_WINDOW_VISIBILITY])
+  AC_DEFINE(USE_WINDOW_VISIBLITY)
+fi
+AC_ARG_ENABLE(old-event-loop, [  --enable-old-event-loop some machines may still need this
+                          (fd_set errors may be a sign)],use_old_event_loop=$enableval,use_old_event_loop=no)
+if test "$use_old_event_loop" = yes; then
+  AC_MSG_RESULT([defining option USE_OLD_EVENT_LOOP])
+  AC_DEFINE(USE_OLD_EVENT_LOOP)
+fi
+
+dnl AC_ARG_ENABLE(vmsutils, [  --enable-vmsutils       patches up old __VMS_VER < 70000000],use_vmsutils=$enableval,use_vmsutils=no)
+dnl if test "$use_vmsutils" = yes; then
+dnl   AC_MSG_RESULT([defining option USE_VMSUTILS])
+dnl   AC_DEFINE(USE_VMSUTILS)
+dnl fi
+AC_ARG_ENABLE(xlockrc, [  --enable-xlockrc        for unknown shadow passwd algorithm],use_xlockrc=$enableval,use_xlockrc=no)
+if test "$use_xlockrc" = yes; then
+  AC_MSG_RESULT([defining option USE_XLOCKRC])
+  AC_DEFINE(USE_XLOCKRC)
+fi
+AC_ARG_ENABLE(auto-logout, [  --enable-auto-logout=time
+                          enable auto-logout code for lab use (time in minutes)],use_auto_logout=$enableval,use_auto_logout=no)
+case "x$use_auto_logout" in
+x|xyes*)
+  AC_MSG_RESULT([defining option USE_AUTO_LOGOUT = 240 minutes])
+  AC_DEFINE(USE_AUTO_LOGOUT,240)
+  ;;
+x[[0-9]]*)
+  AC_MSG_RESULT([defining option USE_AUTO_LOGOUT = $enableval minutes])
+  AC_DEFINE_UNQUOTED(USE_AUTO_LOGOUT,$enableval)
+  ;;
+xno*)
+  ;;
+*)
+  AC_MSG_RESULT([Warning: Illegal time value "$use_auto_logout" given])
+  AC_MSG_RESULT([defining option USE_AUTO_LOGOUT = 240 minutes])
+  AC_DEFINE(USE_AUTO_LOGOUT,240)
+  ;;
+esac
+AC_ARG_ENABLE(default-auto-logout, [  --enable-default-auto-logout=time
+                          set default-auto-logout (time in minutes)],
+              def_auto_logout=$enableval,
+              def_auto_logout=no)
+case "x$def_auto_logout" in
+x|xyes*)
+  AC_MSG_RESULT([defining option DEF_AUTO_LOGOUT = 120 minutes])
+  AC_DEFINE(DEF_AUTO_LOGOUT,"120")
+  ;;
+x[[0-9]]*)
+  AC_MSG_RESULT([defining option DEF_AUTO_LOGOUT = $enableval minutes])
+  AC_DEFINE_UNQUOTED(DEF_AUTO_LOGOUT,"$enableval")
+  ;;
+xno*)
+  ;;
+*)
+  AC_MSG_RESULT([Warning: Illegal time value "$def_auto_logout" given])
+  AC_MSG_RESULT([defining option DEF_AUTO_LOGOUT = 120 minutes])
+  AC_DEFINE(DEF_AUTO_LOGOUT,"120")
+  ;;
+esac
+AC_ARG_ENABLE(button-logout, [  --enable-button-logout=time
+                          enable button logout for lab use (time in minutes)],
+              use_button_logout=$enableval,
+              use_button_logout=no)
+case "x$use_button_logout" in
+x|xyes*)
+  AC_MSG_RESULT([defining option USE_BUTTON_LOGOUT = 10 minutes])
+  AC_DEFINE(USE_BUTTON_LOGOUT,10)
+  ;;
+x[[0-9]]*)
+  AC_MSG_RESULT([defining option USE_BUTTON_LOGOUT = $enableval minutes])
+  AC_DEFINE_UNQUOTED(USE_BUTTON_LOGOUT,$enableval)
+  ;;
+xno*)
+  ;;
+*)
+  AC_MSG_RESULT([Warning: Illegal time value "$use_button_logout" given])
+  AC_MSG_RESULT([defining option USE_BUTTON_LOGOUT = 10 minutes])
+  AC_DEFINE(USE_BUTTON_LOGOUT,10)
+  ;;
+esac
+AC_ARG_ENABLE(default-button-logout, [  --enable-default-button-logout=time
+                          set default-button-logout (time in minutes)],
+              def_button_logout=$enableval,
+              def_button_logout=no)
+case "x$def_button_logout" in
+x|xyes*)
+  AC_MSG_RESULT([defining option DEF_BUTTON_LOGOUT = 5 minutes])
+  AC_DEFINE(DEF_BUTTON_LOGOUT,"5")
+  ;;
+x[[0-9]]*)
+  AC_MSG_RESULT([defining option DEF_BUTTON_LOGOUT = $enableval minutes])
+  AC_DEFINE_UNQUOTED(DEF_BUTTON_LOGOUT,"$enableval")
+  ;;
+xno*)
+  ;;
+*)
+  AC_MSG_RESULT([Warning: Illegal time value "$def_button_logout" given])
+  AC_MSG_RESULT([defining option DEF_BUTTON_LOGOUT = 5 minutes])
+  AC_DEFINE(DEF_BUTTON_LOGOUT,"5")
+  ;;
+esac
+
+AC_ARG_ENABLE(bomb, [  --disable-bomb          disable automatic logout mode],
+              use_bomb=$enableval,
+              use_bomb=yes)
+if test "$use_bomb" = yes; then
+  AC_MSG_RESULT([defining option USE_BOMB])
+  AC_DEFINE(USE_BOMB)
+  BOMB=""
+else
+  BOMB="#"
+fi
+
+AC_ARG_ENABLE(unstable, [  --enable-unstable       enables starfish and bubble3d GL mode],
+              use_unstable=$enableval,
+              use_unstable=no)
+if test "$use_unstable" = yes; then
+  AC_MSG_RESULT([defining option USE_UNSTABLE])
+  AC_DEFINE(USE_UNSTABLE)
+  UNSTABLE=""
+else
+  UNSTABLE="#"
+fi
+
+AC_ARG_ENABLE(closedown-logout, [  --enable-closedown-logout
+                          define this one or next, with enable-auto-logout,],
+              closedown_logout=$enableval,
+              closedown_logout=no)
+if test "$closedown_logout" = yes; then
+  AC_MSG_RESULT([defining option CLOSEDOWN_LOGOUT])
+  AC_DEFINE(CLOSEDOWN_LOGOUT)
+fi
+AC_ARG_ENABLE(session-logout, [  --enable-session-logout enable-button-logout, and/or enable-bomb, for xdm],
+              session_logout=$enableval,
+              session_logout=no)
+if test "$session_logout" = yes; then
+  AC_MSG_RESULT([defining option SESSION_LOGOUT])
+  AC_DEFINE(SESSION_LOGOUT)
+fi
+AC_ARG_ENABLE(staff-file, [  --enable-staff-file=filename
+                          set file of staff who are exempt from auto-logout],
+              use_staff_file=$enableval,
+              use_staff_file=no)
+case "x$use_staff_file" in
+x|xyes*)
+  AC_MSG_RESULT([defining option STAFF_FILE = "/usr/remote/etc/xlock.staff"])
+  AC_DEFINE_UNQUOTED(STAFF_FILE,"/usr/remote/etc/xlock.staff")
+  if test ! -f /usr/remote/etc/xlock.staff; then
+    AC_MSG_RESULT([Warning: File /usr/remote/etc/xlock.staff does not exist])
+  fi
+  ;;
+x/*)
+  AC_MSG_RESULT([defining option STAFF_FILE = "$enableval"])
+  AC_DEFINE_UNQUOTED(STAFF_FILE,"$enableval")
+  if test ! -f $use_staff_file; then
+    AC_MSG_RESULT([Warning: File $enableval does not exist])
+  fi
+  ;;
+esac
+AC_ARG_ENABLE(staff-netgroup, [  --enable-staff-netgroup=netgroup
+                          set netgroup of staff who are exempt from auto-logout],use_staff_netgroup=$enableval,use_staff_netgroup=no)
+if test "$use_staff_netgroup" != no; then
+  AC_MSG_RESULT([defining option STAFF_NETGROUP = "$enableval"])
+  AC_DEFINE_UNQUOTED(STAFF_NETGROUP,"$enableval")
+fi
+AC_ARG_ENABLE(kerberos4, [  --enable-kerberos4      enable Kerberos 4],kerberos4=$enableval,kerberos4=no)
+if test "$kerberos4" = yes; then
+  AC_MSG_RESULT([defining option HAVE_KRB4])
+  AC_DEFINE(HAVE_KRB4)
+  XLOCKINC="${XLOCKINC} -I/usr/athena/include"
+  XLOCKLIBS="${XLOCKLIBS} -L/usr/athena/lib -lkrb -ldes"
+fi
+
+AC_ARG_ENABLE(kerberos5, [  --enable-kerberos5      enable Kerberos 5],kerberos5=$enableval,kerberos5=no)
+if test "$kerberos5" = yes; then
+  AC_MSG_RESULT([defining option HAVE_KRB5])
+  AC_DEFINE(HAVE_KRB5)
+  XLOCKINC="${XLOCKINC} -I/usr/local/include"
+  XLOCKLIBS="${XLOCKLIBS} -L/usr/local/lib -lkrb5 -lcrypto -lcom_err"
+fi
+
+AC_ARG_ENABLE(dce_passwd, [  --enable-dce-passwd     enable DCE passwording],dce_passwd=$enableval,dce_passwd=no)
+if test "$dce_passwd" = yes; then
+  AC_MSG_RESULT([defining option DCE_PASSWD])
+  AC_DEFINE(DCE_PASSWD)
+  XLOCKINC="${XLOCKINC} -I/usr/include/reentrant"
+  XLOCKLIBS="${XLOCKLIBS} -ldce -lc_r"
+fi
+
+AC_ARG_ENABLE(pam, [  --enable-pam            enable PAM], pam=$enableval,pam=no)
+if test "$pam" = yes; then
+  AC_MSG_RESULT([defining option PAM])
+  AC_DEFINE(PAM)
+  XLOCKLIBS="${XLOCKLIBS} -lpam -ldl"
+fi
+
+AC_ARG_ENABLE(afs, [  --enable-afs            enable AIX AFS],afs=$enableval,afs=no)
+if test "$afs" = yes; then
+  AC_MSG_RESULT([defining option AFS])
+  AC_DEFINE(AFS)
+  XLOCKINC="${XLOCKINC} -I/usr/afsws/include"
+  case "${canonical}" in
+    *-*-solaris2.* )
+      XLOCKLIBS="${XLOCKLIBS} -lucb -L/usr/afsws/lib -L/usr/afsws/lib/afs -lkauth.krb -lprot -lubik -lauth.krb -lrxkad -lsys -ldes -lrx -llwp -lcom_err -lcmd /usr/afsws/lib/afs/util.a -laudit -lsys"
+    ;;
+    * )
+      XLOCKLIBS="${XLOCKLIBS} -L/usr/afsws/lib -L/usr/afsws/lib/afs -lkauth -lubik -lprot -lrxkad -lrx -llwp -lauth -lsys -ldes -lcmd -lcom_err /usr/afsws/lib/afs/util.a -laudit"
+    ;;
+  esac
+fi
+
+AC_ARG_ENABLE(sunos_adjunct_passwd, [  --enable-sunos-adjunct-passwd
+                          enable SUNOS Adjunct passwording],sunos_adjunct_passwd=$enableval,sunos_adjunct_passwd=no)
+if test "$sunos_adjunct_passwd" = yes; then
+  AC_MSG_RESULT([defining option SUNOS_ADJUNCT_PASSWD])
+  AC_DEFINE(SUNOS_ADJUNCT_PASSWD)
+fi
+
+AC_ARG_ENABLE(use_mb, [  --enable-use-mb         enable Xmb function series (new)],use_mb=$enableval,use_mb=no)
+if test "$use_mb" = yes; then
+  AC_MSG_RESULT([defining option USE_MB])
+  AC_DEFINE(USE_MB)
+fi
+
+AC_ARG_ENABLE(customization, [  --enable-customization  enable customization of XResource],customization=$enableval,customization=no)
+if test "$customization" = yes; then
+  AC_MSG_RESULT([defining option CUSTOMIZATION])
+  AC_DEFINE(CUSTOMIZATION)
+fi
+
+AC_ARG_ENABLE(modules, [  --enable-modules        enable modules (new and experimental)],modules=$enableval,modules=no)
+if test "$modules" = yes; then
+  AC_MSG_RESULT([enabling xlk modules])
+  MODULES=""
+else
+  MODULES="#"
+fi
+
+AC_ARG_ENABLE(check, [  --enable-check          enable check (new and experimental)],check=$enableval,check=no)
+if test "$check" = yes; then
+  AC_MSG_RESULT([enabling memory debug checking])
+  CHECK=""
+else
+  CHECK="#"
+fi
+
+AC_ARG_WITH(lang, [  --with-lang=lang        use a foreign language (nl/fr/de)],lang=$withval,lang=none)
+case "$lang" in
+  nl|NL|Nl)
+    AC_MSG_RESULT([enabling some reporting in Dutch])
+    AC_DEFINE(NL)
+    ;;
+  fr|FR|Fr)
+    AC_MSG_RESULT([enabling some reporting in French])
+    AC_DEFINE(FR)
+    ;;
+  de|DE|De)
+    AC_MSG_RESULT([enabling some reporting in German])
+    AC_DEFINE(DE)
+    ;;
+  none)
+    AC_MSG_RESULT([using default language (English)])
+    ;;
+  *)
+    AC_MSG_RESULT([unknown language $lang. using default language (English)])
+    ;;
+esac
+
+AC_ARG_ENABLE(orig_xpm_patch, [  --enable-orig-xpm-patch use the original pixmap patch for mail icon
+                          (have colormap problems in 8 bits depth visuals)],
+              orig_xpm_patch=$enableval,
+              orig_xpm_patch=no)
+if test "$orig_xpm_patch" = "yes"; then
+  AC_MSG_RESULT([enabling original mail icon xpm patch])
+  AC_DEFINE(ORIGINAL_XPM_PATCH)
+fi
+
+if test "x$INSTPGMFLAGS" != x; then
+AC_ARG_ENABLE(setuid, [  --disable-setuid        disables setuid installation if automatically chosen],setuid=$enableval,setuid=yes)
+case "x$setuid" in
+xno*)
+  case ${canonical} in
+  *-*-linux*)
+    if test "$vtlock" = "yes"; then
+      INSTPGMFLAGS="-s -o root -g bin -m 4111"
+      AC_MSG_RESULT([defining install options (setuid/setgid) = "$INSTPGMFLAGS" for vtlock])
+       echo "experimental: Big buffer overrun security risk"
+    else
+  INSTPGMFLAGS=""
+  AC_MSG_RESULT([no setuid/setgid install])
+    fi
+    ;;
+  *)
+  INSTPGMFLAGS=""
+  AC_MSG_RESULT([no setuid/setgid install])
+  ;;
+  esac
+  ;;
+x|xyes*)
+  case ${canonical} in
+  *-*-linux*)
+    if test "$vtlock" = "yes"; then
+      INSTPGMFLAGS="-s -o root -g bin -m 4111"
+      AC_MSG_RESULT([defining install options (setuid/setgid) = "$INSTPGMFLAGS" for vtlock])
+    else
+  AC_MSG_RESULT([defining install options (setuid/setgid) = "$INSTPGMFLAGS"])
+    fi
+    ;;
+  *)
+  AC_MSG_RESULT([defining install options (setuid/setgid) = "$INSTPGMFLAGS"])
+  ;;
+  esac
+  ;;
+x*)
+  INSTPGMFLAGS=$enableval
+  AC_MSG_RESULT([defining install options (setuid/setgid) = "$enableval"])
+  ;;
+esac
+else
+  AC_MSG_RESULT([no setuid/setgid install])
+fi
+
+DEPEND=makedepend
+DEPEND_FLAGS=
+DEPEND_DEFINES=
+
+XLOCKLIBS="${XLOCKLIBPATHS} ${XLOCKLIBS} -lX11 -lXext -lm"
+XMLOCKLIBS="${XMLOCKLIBPATHS} ${XMLOCKLIBS} -lX11"
+XALOCKLIBS="${XALOCKLIBPATHS} ${XALOCKLIBS} -lX11"
+XGLOCKLIBS="${XGLOCKLIBPATHS} ${XGLOCKLIBS} ${GTK_LIBS}"
+AC_SUBST(XLOCKLDFLAGS)
+AC_SUBST(XMLOCKLDFLAGS)
+AC_SUBST(XALOCKLDFLAGS)
+AC_SUBST(XGLOCKLDFLAGS)
+AC_SUBST(INSTPGMFLAGS)
+AC_SUBST(GTK_CFLAGS)
+AC_SUBST(XLOCKINC)
+AC_SUBST(XMLOCKINC)
+AC_SUBST(XALOCKINC)
+AC_SUBST(XGLOCKINC)
+AC_SUBST(GTK_LIBS)
+AC_SUBST(XLIBS)
+AC_SUBST(BITMAPTYPE)
+AC_SUBST(PIXMAPTYPE)
+AC_SUBST(BITMAPDIR)
+AC_SUBST(PIXMAPDIR)
+AC_SUBST(XLOCKLIBS)
+AC_SUBST(XMLOCKLIBS)
+AC_SUBST(XALOCKLIBS)
+AC_SUBST(XGLOCKLIBS)
+AC_SUBST(XMLOCK)
+AC_SUBST(XALOCK)
+AC_SUBST(XGLOCK)
+AC_SUBST(XGLOCKDIR)
+AC_SUBST(INSTALL_XMLOCK)
+AC_SUBST(INSTALL_XALOCK)
+AC_SUBST(INSTALL_XGLOCK)
+AC_SUBST(UNINSTALL_XMLOCK)
+AC_SUBST(UNINSTALL_XALOCK)
+AC_SUBST(UNINSTALL_XGLOCK)
+AC_SUBST(APPDEFAULTS)
+AC_SUBST(LINT)
+AC_SUBST(CHECK)
+AC_SUBST(PURIFY)
+AC_SUBST(XPM)
+AC_SUBST(GL)
+AC_SUBST(GLTT)
+AC_SUBST(BOMB)
+AC_SUBST(UNSTABLE)
+AC_SUBST(DEPEND)
+AC_SUBST(DEPEND_FLAGS)
+AC_SUBST(DEPEND_DEFINES)
+AC_SUBST(CXX)
+AC_SUBST(CCC)
+
+AC_CONFIG_HEADER(config.h)
+AC_OUTPUT(Makefile
+    xlock/Makefile
+    modes/Makefile
+    modes/glx/Makefile
+    xmlock/Makefile
+    xalock/Makefile
+    xglock/Makefile
+  )
diff --git a/xlockmore-4.14/configure.tcl b/xlockmore-4.14/configure.tcl
new file mode 100755 (executable)
index 0000000..9d26738
--- /dev/null
@@ -0,0 +1,430 @@
+#!/usr/X11/bin/wish -f
+#charles vidal 1998 <vidalc@club-internet.fr>
+# Thu Jul 30 06:21:57 MET DST 1998
+#Projet Wizard in french Assistant
+#http://www.chez.com/vidalc/assist/
+#
+
+set nbtotalecran 4
+
+# titre de l'assistant
+set titleassist "Wizard configure"
+
+# nombre total d'ecran
+#set nbtotalecran 6
+
+# Declaration des variables globales
+set nbwidget 0
+
+# numero de l'ecran courant
+set nb_ecran 0
+
+set lang " "
+
+
+proc read_pipe { command } {
+set data ""
+set fileid [open |$command r]
+if  { $fileid != "" } {
+       set data [read $fileid]
+       close $fileid
+       }
+       return $data
+}
+
+proc action { } {
+global bitmapdir
+global pixmapdir 
+global incdir
+global libdir
+global soundprog
+global wgcc
+global wmotif
+global weditres
+global wpurify
+global wxpm
+global wopengl
+global wmesagl
+global wdtsaver
+global wdpms
+global esyslog
+global emulroot
+global emuluser
+global eunstable
+global nb_ecran
+global nbtotalecran
+global lang
+if { $nb_ecran == [expr $nbtotalecran -1 ]}  {
+       set commandline "./configure"
+       append commandline $wgcc $wpurify $wmotif $weditres $wxpm $wopengl $wmesagl $wdtsaver $esyslog $emuluser $emulroot $eunstable
+       if {$bitmapdir!=""} { append commandline " --enable-bitmapdir=$bitmapdir" } 
+       if {$pixmapdir!=""} { append commandline " --enable-pixmapdir=$pixmapdir" } 
+       if {$incdir!=""} {append commandline " --x-includes=$incdir" } 
+       if {$libdir!=""} {append commandline " --x-libraries=$libdir" } 
+       if {$soundprog!=""} {append commandline " --enable-def-play=$soundprog" } 
+       append commandline " $lang" 
+       if { [getyesno "Do you really want to launch configure"] == "yes" } {
+               puts $commandline
+               wm withdraw .
+               toplevel .config
+               frame .config.f 
+               frame .config.f2 
+               button .config.f2.make -text "Make" -command { set commandline "make"
+                                       .config.f configure -cursor watch
+                                       .config.f2 configure -cursor watch
+                                       .config.f2.exit configure -cursor watch
+                                       .config.f.t configure -cursor watch
+                               .config.f.t insert insert "Please wait..."
+                                       update
+                                       set toto [read_pipe $commandline]
+                                       .config.f configure -cursor arrow
+                                       .config.f.t configure -cursor xterm
+                       .config.f.t insert insert $toto
+                                       .config.f2 configure -cursor arrow
+                                       .config.f2.exit configure -cursor arrow
+                       }
+                       button .config.f2.install -text "Make Install" -command { set commandline "make install"
+                                       .config.f configure -cursor watch
+                                       .config.f2 configure -cursor watch
+                                       .config.f2.exit configure -cursor watch
+                                       .config.f.t configure -cursor watch
+                               .config.f.t insert insert "Please wait..."
+                                       update
+                                       set toto [read_pipe $commandline]
+                                       .config.f configure -cursor arrow
+                                       .config.f.t configure -cursor xterm
+                       .config.f.t insert insert $toto
+                                       .config.f2 configure -cursor arrow
+                                       .config.f2.exit configure -cursor arrow
+                       }
+               button .config.f2.exit -text "Exit" -command exit
+               scrollbar .config.f.s -orient vertical -command {.config.f.t yview}
+               pack .config.f -side left  -expand yes  -fill y
+               pack .config.f.s -side right  -fill y
+               text .config.f.t -yscrollcommand {.config.f.s set} -wrap word -width 50 -height 10 \
+               -setgrid 1
+               pack .config.f.t 
+               pack .config.f.t -expand yes -side right -fill both
+               pack .config.f -side top -expand yes -fill both
+               pack .config.f2 -side bottom
+       #       pack .config.f2.make  .config.f2.install  .config.f2.exit -side left
+               pack .config.f2.exit 
+               .config.f configure -cursor watch
+               .config.f2 configure -cursor watch
+               .config.f2.exit configure -cursor watch
+               .config.f.t configure -cursor watch
+               .config.f.t insert insert "Please wait..."
+               update
+               set toto [read_pipe $commandline]
+               .config.f configure -cursor arrow
+               .config.f.t configure -cursor xterm
+               .config.f.t insert insert $toto
+               .config.f2 configure -cursor arrow
+               .config.f2.exit configure -cursor arrow
+       }
+   } else  exit
+}
+#
+# get a dialog yes ok
+#
+proc getyesno { text  } {
+return [ tk_messageBox -parent . -title {Launch Configure} -type yesno\
+       -icon warning \
+       -message $text ] 
+}
+
+proc OutputEcran { n } { 
+global nomuser 
+global nomreel 
+global homedir 
+ switch  $n { 
+       }
+}
+
+proc InputEcran { n } {
+global nomuser 
+global homedir
+ switch  $n {
+       }
+}
+# titre de l'assistant
+set titleassist "Assistant xxxx"
+
+set tmpfnt ""
+
+global tmpfnt
+
+# nombre total d'ecran
+#set nbtotalecran 6
+
+# Declaration des variables globales
+set nbwidget 0
+
+# numero de l'ecran courant
+set nb_ecran 0
+
+
+proc openfont { var } {
+upvar $var toto
+global tmpfnt
+     toplevel .font 
+     set Fnt .font
+       wm title $Fnt "Font Options"
+       label  $Fnt.label -text "ABCDEFGH\nIJKabedfg\nhijkmnopq" 
+
+    frame $Fnt.frame -borderwidth 10 
+    frame $Fnt.frame2 -borderwidth 10
+    set w $Fnt.frame
+    label $w.msg0   -text "Font Options" 
+    pack $w.msg0 -side top
+    eval exec "xlsfonts \> /tmp/xlsfont.tmp"
+    set f [open "/tmp/xlsfont.tmp"]
+    listbox $Fnt.frame.names -yscrollcommand ".font.frame.scroll set" \
+       -xscrollcommand "$Fnt.scroll2 set"  -setgrid 1 \
+         -exportselection false 
+    bind $Fnt.frame.names <Double-1> {
+            .font.test configure -font [.font.frame.names get [.font.frame.names curselection]]
+    set tmpfnt  [.font.frame.names get [.font.frame.names curselection]]
+    }
+    scrollbar $Fnt.frame.scroll -orient vertical -command ".font.frame.names 
+yview" \
+            -relief sunken -borderwidth 2
+    scrollbar $Fnt.scroll2 -orient horizontal -command "$Fnt.frame.names xview" \
+            -relief sunken -borderwidth 2
+    while {[gets $f line] >= 0} {
+            $Fnt.frame.names insert end $line 
+    }
+    close $f
+
+    eval exec "/bin/rm -f /tmp/xlsfont.tmp"
+    pack $Fnt.frame.names  -side left -expand y -fill both
+    pack $Fnt.frame.scroll -side right -fill both
+    pack $Fnt.frame  -fill x
+    pack $Fnt.scroll2 -fill both
+       label  $Fnt.test -text "ABCDEFGHIJKabedfghijkmnopq12345" 
+        pack $Fnt.test
+
+    button $Fnt.frame2.cancel -text Cancel -command "destroy $Fnt"
+    button $Fnt.frame2.ok -text OK -command "set $var $tmpfnt; destroy $Fnt"
+       pack $Fnt.frame2.ok $Fnt.frame2.cancel  -side left -fill both
+       pack $Fnt.frame2 -fill both
+}
+proc opencolorsel {titre  var wf } {
+upvar $var toto
+set toto [tk_chooseColor -title $titre]
+ $wf.label configure -foreground $toto
+}
+proc openfilesel { var  } {
+upvar $var toto
+set toto [ tk_getOpenFile -parent .]
+}
+
+proc OutputEcran { n } { 
+global nomuser 
+global nomreel 
+global homedir 
+ switch  $n { 
+       }
+}
+
+proc InputEcran { n } {
+global nomuser 
+global homedir
+ switch  $n {
+       }
+}
+
+# Callback pour revenir a l'ecran precedent
+proc prec_ecran { } {
+global nbtotalecran
+global nb_ecran
+set tmp [expr $nb_ecran - 1]
+if { $tmp > -1} {
+               OutputEcran $nb_ecran
+               pack forget .f$nb_ecran
+               set nb_ecran [expr $nb_ecran - 1]
+               InputEcran $nb_ecran
+               pack .f$nb_ecran 
+               }
+if { $nb_ecran != [expr $nbtotalecran - 1 ]}  {
+               .f.b3 configure -text "Cancel"
+               }
+}
+
+# Callback pour aller a l'ecran suivant
+proc next_ecran { } {
+global nb_ecran
+global nbtotalecran
+if { $nb_ecran == [expr $nbtotalecran - 1 ]}  {
+               .f.b3 configure -text "Finish"
+               }
+if { $nb_ecran != [expr $nbtotalecran - 1 ]}  {
+               .f.b3 configure -text "Cancel"
+               }
+set tmp [expr $nb_ecran + 1]
+if { $tmp < $nbtotalecran} {
+               OutputEcran $nb_ecran
+               pack forget .f$nb_ecran
+               set nb_ecran [expr $nb_ecran + 1]
+               InputEcran $nb_ecran
+               pack .f$nb_ecran 
+               }
+}
+
+# Creation du label titre et du texte explicatif
+# Argument n:numero de l'ecran title:titre desc description
+
+proc creationscreennb { n title desc icon} {
+set currentarg 0
+frame .f$n -height 10 -width 10
+image create bitmap  image$n -file bitmaps/$icon
+label .f$n.lt$n -text $title -font -Adobe-Courier-Bold-R-Normal-*-140-*
+label .f$n.li$n -image image$n
+pack .f$n.lt$n  .f$n.li$n
+frame .f$n.fdesc 
+message  .f$n.mesg -text $desc -width 25c
+pack .f$n.mesg -fill x
+pack .f$n.fdesc
+}
+
+# Creation de deux label + entry avec variable texte
+# Argument n:numero de l'ecran label1:label devant texte vtext1:variable text
+# De meme pour les xxxx2
+
+proc creationentry { n nbf  text variable value} {
+       frame .f$n.fr$nbf
+       label .f$n.fr$nbf.lab1 -text $text
+       entry .f$n.fr$nbf.e1 -textvariable  $variable
+       .f$n.fr$nbf.e1 insert 0 $value
+       pack .f$n.fr$nbf 
+       pack .f$n.fr$nbf.e1  -side right
+       pack .f$n.fr$nbf.lab1  -side left
+}
+
+proc mkecran { n args } {
+  global nbwidget
+  set nbf 0
+  set w  .f$n
+  foreach i $args {
+               switch -regexp  [lindex $i 0] {
+                               LIST { listbox  $w.list$nbwidget 
+                                       pack  $w.list$nbwidget 
+                                       }
+                               ENTRY { 
+                                       creationentry  $n $nbwidget [lindex $i 1] [lindex $i 2] [lindex $i 3] 
+                                       }
+                               LABEL { label  $w.label$nbwidget -text  [lindex $i 1]
+                                       pack  $w.label$nbwidget
+                                       }
+                               CHECK { checkbutton  $w.check$nbwidget -text  [lindex $i 1] -variable  [lindex $i 2] -onvalue  [lindex $i 3] \
+-offvalue [lindex $i 4]
+                                       pack  $w.check$nbwidget 
+                                       }
+                               RADIO { 
+                                               frame $w.fr$nbwidget 
+                                               image create photo   [lindex $i 4] -file [lindex $i 5] 
+                                               label  $w.fr$nbwidget.labrad  -image [lindex $i 4]
+                                               radiobutton  $w.fr$nbwidget.radio$nbwidget -text  [lindex $i 1] -variable  [lindex $i 2] -value [lindex $i 3] 
+                                       pack   $w.fr$nbwidget.labrad  $w.fr$nbwidget.radio$nbwidget -side left
+                                       pack   $w.fr$nbwidget
+                                       }
+                               BUTTON { button  $w.button$nbwidget -text  [lindex $i 1]
+                                       pack  $w.button$nbwidget 
+                                       }
+                               SCALE { scale  $w.scale$nbwidget -from [lindex $i 1] -to [lindex $i 2]  -orient 
+horizontal 
+                                       pack  $w.scale$nbwidget 
+                                       }
+                               FILE { 
+                                       frame   $w.frame$nbwidget
+                                       set  wf $w.frame$nbwidget
+                                       label   $wf.label  -text [lindex $i 1]
+                                       entry   $wf.entry  -textvariable [lindex $i 2 ]
+                                       $wf.entry insert 0 [lindex $i 3] 
+                                       button $wf.button -text "File" -command 
+"openfilesel [lindex $i 2]"
+                                       pack $wf
+                                       pack  $wf.label $wf.entry $wf.button  
+-side left
+                                       }
+                               COLOR { 
+                                       frame   $w.frame$nbwidget
+                                       set  wf $w.frame$nbwidget
+                                       if { [lindex $i 4] !="" } then { label $wf.label  -text [lindex $i 1] -foreground [lindex 
+$i 4] 
+                                       } else { label $wf.label  -text [lindex $i 1] }
+                                       entry   $wf.entry  -textvariable [lindex $i 2 ]
+                                       $wf.entry insert 0 [lindex $i 4] 
+                                       button $wf.button -text "Color" -command "opencolorsel [lindex $i 3] [lindex $i 
+2] $wf"
+                                       pack $wf
+                                       pack  $wf.label $wf.entry $wf.button  -side left
+                                       }
+                               FONT { 
+                                       frame   $w.frame$nbwidget
+                                       set  wf $w.frame$nbwidget
+                                       label   $wf.label  -text [lindex $i 1]
+                                       entry   $wf.entry  -textvariable [lindex $i 2 ]
+                                       $wf.entry insert 0 [lindex $i 3] 
+                                       button $wf.button -text "Font" -command 
+"openfont [lindex $i 2] "
+                                       pack $wf
+                                       pack  $wf.label $wf.entry $wf.button  
+-side left
+                                       }
+                               }
+       set nbwidget [expr $nbwidget + 1]
+               }
+}
+# 
+# 
+# --with-lang=lang        use a foreign language (de/fr/nl)
+creationscreennb  0 "wizard configure xlockmore" "This should help you to 
+build xlockmore" m-xlock.xbm
+mkecran 0 \
+{CHECK "without gcc    " wgcc     " --without-gcc" "" }\
+{CHECK "with-purify    " wpurify  " --with-purify" "" }\
+{CHECK "without motif  " wmotif   " --without-motif" ""}\
+{CHECK "without editres" weditres " --without-editres" ""}\
+{CHECK "without xpm    " wxpm     " --without-xpm" ""}\
+{CHECK "without opengl " wopengl  " --without-opengl" "" }\
+{CHECK "without mesagl " wmesagl  " --without-mesagl" "" }\
+{CHECK "without dtsaver" wdtsaver " --without-dtsaver" "" }\
+{CHECK "without dpms   " wdpms    " --without-dpms" "" }\
+ { }  
+creationscreennb  1 "Wizard configure image path" "please enter the image path"  m-xlock.xbm
+mkecran 1 \
+{ENTRY  "Bitmap dir" bitmapdir }\
+{ENTRY "Pixmaps dir" pixmapdir }\
+{ENTRY "sound player program" soundprog    }\
+{CHECK "enable syslog logging      " esyslog   " --enable-syslog" "" }\
+{CHECK "enable multiple users      " emuluser  " --enable-multiple-user" "" }\
+{CHECK "enable multiple root users " emulroot  " --enable-multiple-root" "" }\
+{CHECK "enable unstable            " eunstable " --enable-unstable" "" }\
+ { }  
+creationscreennb  2 "Wizard configure include and library path" "Please enter the path"  m-x11.xbm
+mkecran 2 \
+{ENTRY "path of X include          " incdir   }\
+{ENTRY "path of X library          " libdir }\
+{ENTRY "user executables in        " bindir }\
+{ENTRY "system admin executables in" bindir }\
+{ENTRY "system admin executables in" sbindir }\
+{ENTRY "program executables in     " libexecdir }\
+{ENTRY "info documentation in      " infodir }\
+{ENTRY "man documentation in       " mandir }\
+{ENTRY "find the sources in        " srcdir }\
+ { }  
+creationscreennb  3 "Wizard configure language" "Please choice your language "  m-xlock.xbm
+mkecran 3 \
+{RADIO "Dutch   " lang  " --with-lang=nl" fdutch etc/gif/nlflag.gif}\
+{RADIO "English " lang " " fenglish etc/gif/ukflag.gif}\
+{RADIO "French  " lang  " --with-lang=fr" ffrench etc/gif/frflag.gif}\
+{RADIO "German  " lang  " --with-lang=de" fgerman etc/gif/deflag.gif}\
+{}
+frame .f
+button .f.b1 -text "Previous" -command "prec_ecran"
+button .f.b2 -text "Next" -command "next_ecran"
+button .f.b3 -text "Cancel" -command "action"
+pack .f.b1 .f.b2 .f.b3 -side left
+pack .f -side bottom
+pack .f0
diff --git a/xlockmore-4.14/conftest.c b/xlockmore-4.14/conftest.c
new file mode 100644 (file)
index 0000000..1cced3d
--- /dev/null
@@ -0,0 +1,3 @@
+#line 803 "configure"
+#include "confdefs.h"
+main(){return(0);}
diff --git a/xlockmore-4.14/docs/3d.howto b/xlockmore-4.14/docs/3d.howto
new file mode 100644 (file)
index 0000000..536fb22
--- /dev/null
@@ -0,0 +1,43 @@
+
+              Introduction to 3d modes
+                  Henrik Theiling
+
+
+This is a short introduction to how you could try to see the 3d effects
+in xlock:
+
+- You will need glasses with one lens red and the other blue (or green).
+  The blue (or green) one needs to be in front of the left eye, the red one
+  in front of the right one.  If you have got differently coloured lenses
+  (like green) you can try to adjust the colours by using the switches
+  -right3d <colour> and -left3d <colour> .
+
+ If you do not see any 3d effect, try to change the -delta3d value.
+
+- Adjust the colour of your screen (or use -right3d/-left3d instead).  Most
+  likely if you use the green colours will be too bright so you can see them
+  through the red lens, too.
+
+- Let the program display in blue for the green lens.  You should still be
+  able to see blue through your green lens, but less likely through your
+  red lens.
+
+- Try to zoom in from a completely dark screen.
+
+- Try different 3d modes.  Some people see `rock' more easily, others `worm'.
+  It depends.
+
+I hope you enjoy it.
+
+Currently the following modes are implemented for 3d view:
+  rock, worm, bouboule, pyro.
+
+BUGS:
+  Some of the 3d modes are not implemented with real 3d.  They try to
+  use a close approach.
+  Rock, pyro and bouboule use real 3d calculations.
+  In the worm mode, worms can not just creep to the bottom or the top.  That
+  means they do not have a real 3d direction but one 2d direction (the same
+  as in 2d mode) and an additional 1d direction for the z-axis.  This could
+  be fixed.
+
diff --git a/xlockmore-4.14/docs/HACKERS.GUIDE b/xlockmore-4.14/docs/HACKERS.GUIDE
new file mode 100644 (file)
index 0000000..32032bd
--- /dev/null
@@ -0,0 +1,576 @@
+
+
+                       The xlock Hacker's Guide
+                             Ron Hitchens
+
+
+INTRODUCTION
+
+   This document is meant to serve as a guide for those who wish to hack
+xlock; to make changes, add new modes, fix bugs, etc.  The intent is to
+explain non-obvious things about how the various pieces of xlock
+are organized, to help the casual hacker avoid common coding mistakes
+and to stay away from "off limits" parts of xlock.
+
+
+What Is Xlock?
+
+   Xlock is an application for the X Window system which will cover up
+one or more X screens to prevent access.  It may be run manually by a
+user to lock the display or, more commonly, xlock may be run automatically
+by a daemon utility after a period of inactivity.
+
+   Xlock creates a "blanket" window to cover the entire screen, and also
+grabs the X server to prevent access by external clients.  When the
+user presses a key or clicks a mouse button, xlock will prompt for a
+password.  When the proper password is provided, xlock releases the
+server and removes its blanket window.
+
+   While xlock has the display locked, it runs one or more "modes" which
+are code modules that draw various things on the xlock window.  These
+modes act as screen savers.  They attempt to provide amusing and/or
+entertaining displays, while avoiding static imagery which could lead
+to screen phosphor "burn-in".
+
+   The xlock application began life at Sun Microsystems many years
+ago.  It was written by Patrick J. Naughton and was much simpler then.
+That original xlock is almost ubiquitous in the X Windows world.  This
+distribution, known as xlockmore, is maintained by David Bagley and
+is not officially connected with the original xlock, (although it
+received Patrick's blessing).  Major enhancements have been made to
+xlock - many, many new modes have been added and significant structural
+changes have been made.  This document will attempt to inform you of
+how xlock is structured and how the pieces fit together.
+
+
+ORGANIZATION
+
+   Xlock is organized into two basic parts: the "mainline" code, which
+handles startup, window creation, passwords, etc, and the modes,
+which are self-contained modules that draw things on the window(s)
+provided by the mainline code.
+
+   The code which makes up an xlock mode is accessed through a few
+well-defined callback functions, or "hooks".  The mode should not
+concern itself with anything not provided to it via these hooks.
+As of the xlockmore-3.8 release, these hooks have been restructured
+to provide all the environmental information a mode needs to do its
+task.  Prior to this, it was necessary for the modes to access global
+variables.  This is no longer condoned, it is now strongly suggested
+that modes only trust the passed-in information.  These globals will
+probably go away once all the naive modes have been updated.
+
+
+MAINLINE CODE
+
+   The mainline xlock code is concerned with preventing unauthorized
+access to the X server and creating the environment in which the modes
+run.  It also calls the hooks for the current mode in response to
+external events and timing intervals.  The mainline code keeps track
+of the clock and determines when to make calls to a mode.
+
+        < unfinished >
+
+MODES
+
+   The primary focus of this document is writing and maintaining
+modes.  The remainder will be concerned with how to write a mode,
+how a mode accesses the display, what a mode should not do, etc.
+
+
+HOOKS
+
+   Xlock modes are driven entirely through their externally visible
+hook functions.  There are currently five hooks defined, with a sixth
+reserved for future expansion.  The first two, init and callback, are
+the same as in older versions of xlock.  The release, refresh and
+change hooks are new to xlockmore-3.8:
+
+       o init   This hook will be called to prepare a mode for running.
+               The mode should allocate resources, establish its
+               initial state, etc.  This hook may be called
+               multiple times, and the window and/or screen
+               values may be different each time.
+
+       o callback  This is the main driver hook for a mode.  It
+               is called repeatedly, at a time interval determined
+               by defaults or command line arguments.  A mode sees
+               each call as one "tick", it may chose to do something
+               on every tick, or count the calls and only update
+               the screen periodically.  A mode should not spend a
+               lot of time executing the callback function.  If it
+               has a lot of screen updating to do, it should spread
+               the work across multiple calls.  A mode can depend
+               on the init hook being called at least once before
+               the callback hook is called.  But it should not depend
+               on the callback hook ever being called following an init.
+
+       o release  This hook will be called when some other mode is
+               about to be initialized, or when xlock is shutting
+               down.  This hook should free up any long-lived, 
+               dynamically allocated resources the mode has acquired.
+               This would include memory and X resources, such as
+               Pixmaps and GCs.
+
+       o refresh  This hook is called when the drawing window may have
+               been damaged.   It should take steps to repaint the
+               window.  No information about which part(s) of the
+               window have been damaged is provided.  The mode should
+               repaint the entire window.  If no refresh hook is
+               provided, the init hook will be called when a refresh
+               is needed.
+
+       o change  This hook is called when the user requests a change.
+               In the current implementation, this is when the user
+               clicks the middle mouse button.  This hook is currently
+               only used by the random mode, it means to move on to
+               the next mode (random mode runs other modes as slaves).
+               A mode is free to interpret a change request in any
+               way it likes.  The logical thing is to start over,
+               change colors, etc.
+
+
+Calling Conventions
+
+   The prototype for a mode hook is defined in mode.h, and looks like
+this:
+
+       void mode_hook (ModeInfo *mode_info)
+
+   The argument, a pointer to a ModeInfo structure, contains
+all the context information a mode needs to run.  Writers of new modes
+are strongly encouraged to acquire all information they need through
+this handle.
+
+   A ModeInfo handle is provided to every hook type.  The information
+in this structure is current ONLY AT THE TIME THE HOOK IS CALLED.  The
+structure it points to is volatile and the pointer should not be cached
+by the mode.  It is also important to note that xlock may be locking
+several screens simultaneously.  The window information may not be the
+same across subsequent calls to the same callback function.  Use the
+information provided, do not look at globals, and do not stash the pointer.
+
+
+The Init Hook
+
+   A mode's init hook will be called whenever the mainline code wants
+to inform a mode it is about to run on a particular window.  The mainline
+xlock code will only run one mode at a time, but it may be running that
+mode on several screens at once.  It is therefore possible for the init
+hook to be called several times, each with a different window context,
+before its callback hook is run.  An init hook should not assume the
+window provided is the window to be used by the next call to the
+callback hook.  Depending on the nature of the mode, it may be
+necessary to maintain several sets of state information, one for each
+screen.
+
+   The number of active screens, and the maximum possible number of
+screens are provided in the ModeInfo struct.  Modes are encouraged
+to look at this information and allocate data structures dynamically.
+The number of active screens will not change during an xlock run.
+A global symbol, MAXSCREENS, is defined in xlock.h but programmers
+are strongly urged not to use this or any other fixed value.  If
+you use only the information passed to the hooks, your code will
+always be correct.
+
+   An init hook should also be prepared to be called at any time.  The
+mainline xlock code changes window configuration in response to user
+input, and may call the init hook in place of a missing refresh hook.
+An init hook should therefore not expect to be balanced with a call
+to the release hook.  The init hook should not allocate resources on
+each call, it should track its allocations to make sure they are only
+done once.
+
+   Neither should an init hook depend on the callback hook ever being
+called.  It's possible a call to the init hook may be followed by another
+call to the init hook, or a call to the release hook without an intervening
+call to the callback hook.
+
+   An init hook may be called twice in a row, and will be if more than
+one screen is being locked.  To avoid unexpected glitches on-screen,
+it is recommended that you do not draw anything to the screen during
+the init hook.  Save the drawing for the callback hook, with appropriate
+status information if an initial screen paint is needed.
+
+   Be careful not to blindly do dynamic allocations in your init hook,
+keep track of your allocations and only do the necessary state reset
+each time.  Track your allocations so they can be undone by the release
+hook at a later time.
+
+   The init hook will be called for each screen before the callback
+hook is called for any screen.
+
+
+The Callback Hook
+
+   The callback hook is the method by which a mode runs.  The mainline
+code calls a mode's callback hook periodically, usually on a fixed time
+schedule, and checks for user input between each call.
+
+   The time interval between calls to the callback hook is set by a
+field in the LockStruct entry for the mode (see mode.h and mode.c).
+This value may also be set by the user on the command line, or via
+an X resource.  The mainline code attempts to keep the time interval
+between the *beginning* of each call constant.  The time spent executing
+the mode's callback hook is subtracted from the interval to keep the
+ticks as constant as possible.  This is hardly perfect, but an effort
+is made to remain as accurate as is possible on a multi-tasking system.
+
+   A mode should therefore not spend a large amount of time executing 
+in the callback hook.  While in the callback, the mainline code cannot
+respond to external events from the user.  It is preferable for a
+callback hook to do a little bit of the work on each call, rather than
+a complete update each time.
+
+   A callback should pay attention to the context information passed
+to it.  On multi-headed displays, the callback may be called successively
+for each screen on the display.  It may be necessary to maintain
+state information which is indexed by the given screen number, rather
+than simply using local static variables.
+
+   The screen number is provided by the ModeInfo argument and will
+range from 0 to n, where n is the number of active screens minus one.
+There will always be a screen 0.  A mode wishing to paint the same
+imagery one each screen should do the same thing each time the callback
+is called, and advance its state when the screen number is 0.  However,
+the window may not be the same size on every screen.  Do not assume it is.
+
+   A call to the callback hook is not guaranteed following an init call
+for a given screen, but at least one init call is guaranteed before the
+first callback call.  If the window size changes, as when the icon
+window is presented to prompt for the password, an init call
+will be made with the new window information.  A mode should
+always use the window information passed to it rather than caching
+information passed to the init hook, but it can use the information
+passed to the init hook to setup its own data structures and rely
+on the information matching the next callback call, *for that screen*.
+
+
+The Release Hook
+
+   This hook is new to release 3.8.  The release hook will be called by
+the mainline code when it is about to call the init hook of another mode,
+and your init hook has been called at least once since the last call
+to your release hook.
+
+   The release hook should undo any dynamic allocations done by the
+init hook, or anything else that needs to be done to make the mode
+inactive.  Once the release hook returns, the mode is marked as not
+initialized.  If your mode is never initialized again, no further
+calls to any of its hooks will be made.  The release hook is where
+you must surrender any resources that only your mode knows about.
+
+   The release hook is called ONLY ONCE.  It will not be called
+for each screen like most of the other hooks.  A mode should not
+access any of the window information, other that the display handle
+and number of active screens.
+
+   Once the release hook has been called the mode is considered
+to be inactive, the same as if it had never been run at all.
+
+  < Final call at shutdown?? >
+
+
+The Refresh Hook
+
+   This hook is new to release 3.8.  The refresh hook is called when
+the mainline suspects the window may have been damaged.
+
+   When running in "inwindow" mode (xlock runs in a plain window, not locking)
+this may happen when windows are shuffled by the user.  It may also happen
+when in normal full-screen mode and some new window appears on the display.
+In this case, xlock immediately pushes itself to the top, to cover the
+new window.  However, the temporary appearance of the new window may
+have left a "hole" on the display.  The refresh hook should take steps
+to repaint the entire display whenever it is called.
+
+   It will also be called when the window is first mapped.  However,
+a mode should not depend on a refresh call to do its initial screen
+paint.  When running random mode, other modes will be stopped and started
+on the same window, with no intervening refresh call.  A mode should
+usually do a full paint on the first callback following an init call.
+It is a good strategy to have the refresh hook simply set a status flag
+(or whatever) to cause the next callback call to do a full repaint.  This
+would be similar to an init, but internal state would not be reset.
+
+   If no refresh hook is provided for your mode (configured in mode.c),
+then your init hook will be called in place of the refresh hook.  The
+refresh hook is provided so your mode can repair window damage
+without losing the internal state of the mode.
+
+   As of this writing, there is a hack in place which will prevent a
+second call to the init hook (in place of a refresh) if the callback
+hook has not been called since the last init call for that screen.
+This causes undesirable behavior in some naive modes.  It is expected
+this hack will be removed.  Modes should be prepared for their init
+hooks to be called at any time, even repeatedly.
+
+
+The Change Hook
+
+   This hook is new to release 3.8.  It is called when the user requests
+a change.  This is currently in response to a click on the middle mouse
+button.
+
+   In the case of random mode, which runs other modes, it means to
+move on to the next mode without waiting for the time to expire.  Other
+modes are free to interpret this call in way they choose.  If no change
+hook is provided for a mode, no action will be taken when the middle mouse
+button is clicked.
+
+   This hook will be called once for each active screen when a change
+request is made.
+
+
+Hook Calling Sequence
+
+   A typical sequence of calls when running on two screens would be:
+
+       init [screen 0]
+       init [screen 1]
+       refresh [screen 0]      (caused by first mapping the window)
+       refresh [screen 1]
+       callback [screen 0]
+       callback [screen 1]
+       callback [screen 0]
+       callback [screen 1]
+       ...
+       refresh [screen 0]      (caused by window damage)
+       refresh [screen 1]
+       callback [screen 0]
+       callback [screen 1]
+       ...
+       init [screen 0]         (switch to icon screen)
+       callback [screen 0]
+       callback [screen 1]
+       ...
+
+
+HANDS OFF THOSE GLOBALS
+
+   All the environmental information a mode needs is provided to the
+hook functions via the ModeInfo passed as an argument.  But prior to
+the restructuring done in xlockmore-3.8, much of this information
+had to be accessed directly from global variables.  Listed here are
+the globals which correspond to the information passed in ModeInfo.
+You should not access these variables directly (they will go away),
+nor should you use these names for local variables.  The first column
+is the global name, the second column is the macro to use to get
+the same information from the ModeInfo argument (see mode.h):
+
+   These variables pertain to the X screen
+       dsp             MI_DISPLAY      handle to the X server display.
+       screen          MI_SCREEN       Current screen number
+       Scr             MI_PERSCREEN    perscreen struct ptr for curr screen
+       Scr[n].gc       MI_GC           gc handle for current screen
+       Scr[n].npixels  MI_NPIXELS      num available pixels for curr screen
+       Scr[n].cmap     MI_CMAP         colormap handle for current screen
+       Scr[n].pixels   MI_PIXELS       pixel array for current screen
+       Scr[n].pixels[i] MI_PIXEL       a given pixel in the pixel array
+
+   These variables control execution, set by cmd line or resources
+       delay           MI_DELAY        time (microsecs) between callbacks
+       batchcount      MI_BATCHCOUNT   batchcount value
+       cycles          MI_CYCLES       cycles value
+       saturation      MI_SATURATION   colormap saturation value
+
+   These variables are booleans, usually set by cmd line:
+       mono            MI_IS_MONO      use only B&W (can be set for color)
+       inwindow        MI_IS_INWINDOW  running in regular window
+       inroot          MI_IS_INROOT  running in the root window
+
+   The MI_IS_MONO flag will be true if the global "mono" is set
+(which can be specified on the command line for color displays) or
+if the screen is a monochrome device.  It IS possible to have both
+color and monochrome screens at the same time.  Use the passed-in
+information on a screen-by-screen basis, do not assume they are all
+the same.
+
+   There are several other global booleans in resource.c.  These will
+probably be eliminated in future releases.  Do not access them directly.
+They should not be of interest to a mode anyway, but be careful not to
+use those names in your own code.
+
+
+PLUGGING A NEW MODE INTO XLOCK
+
+   The code making up a mode should be self-contained.  A mode should
+hide all of its internal variables and functions.  Only the hook functions
+and one configuration variable should be visible outside the module
+the mode is defined in.  Because there are some many code modules
+compiled into xlock, written by many different people, the chance
+of naming conflicts is quite high.  Keep all your local stuff local.
+
+   The nexus where the mainline xlock code connects to the individual
+modes is in the file mode.c.  It contains an array of pre-initialized
+LockStruct structures named LockProcs.  This struct is currently
+defined as:
+
+       typedef struct LockStruct_s {
+               char       *cmdline_arg;        /* mode name */
+               ModeHook   *init_hook;          /* func to init a mode */
+               ModeHook   *callback_hook;      /* func to run (tick) a mode */
+               ModeHook   *release_hook;       /* func to shutdown a mode */
+               ModeHook   *refresh_hook;       /* tells mode to repaint */
+               ModeHook   *change_hook;        /* user wants mode to change */
+               ModeHook   *unused_hook;        /* for future expansion */
+               ModeSpecOpt *msopt;             /* this mode's def resources */
+               int         def_delay;          /* default delay for mode */
+               int         def_batchcount;
+               int         def_cycles;
+               float       def_saturation;
+               char       *desc;               /* text description of mode */
+               int         flags;              /* state flags for this mode */
+               void       *userdata;           /* for use by the mode */
+       } LockStruct;
+
+   Of these fields, the hooks and msopt are defined in the mode itself.
+The hooks are names of functions which are called as previously described.
+Init and callback hooks are required, all others are optional.
+Any hooks not provided are specified as NULL.  The field "msopt" is
+a pointer to a ModeSpecOpt struct (xlock.h).  Every mode must define
+one of these structures and make it globally visible to mode.c.  This
+structure provides a handle to X resource information that allows
+for parsing command line arguments unique to your mode and setting
+static variables private to your mode.
+       << unfinished, see random.c for an example >>
+
+   The remaining fields of the LockStruct struct are defined directly
+in the array in mode.c.  The fields with the names def_* are the default
+values to be used when running this mode, if not overridden by command
+line arguments of resources.
+
+   The field def_delay controls how often the callback hook is called
+(specified in microseconds).
+
+   The floating point number def_saturation controls the saturation of
+the colormap to allocate.  This controls how the color ramp is 
+populated (<<unfinished: how?>>)
+
+   The other two default values, def_batchcount and def_cycles, are
+for use by the mode.  They can be used to control how many thingys
+to draw at once, how often to restart, etc.  These values can be
+specified at run time which allows the user to affect how a mode runs.
+
+   The text pointers cmdline_arg and desc are used when printing
+command line help.  They provide the simple name and a more verbose
+short description.
+
+   The flags field should always be set to zero, it is used internally
+to keep track of state information.
+
+   The last field, userdata, is for use by the mode.  The mode may use
+this generic pointer for any purpose it likes.  The mainline code will
+never touch it and it will be available to all subsequent hook calls.
+This value will survive init - release - init cycles.
+
+
+GETTING INFORMATION FROM ModeInfo
+
+   The ModeInfo structure is defined in mode.h.  It contains several
+types of information and is actually made up of several other structs.
+This structure is likely to undergo major revision in future releases,
+so macros are provided to access all the fields.  Use the macros,
+things are guaranteed to change.
+
+   Of the fields available in ModeInfo, most are copies of the same
+information available in the globals described above.  But some are new.
+Most notably, the window dimensions and black/white pixel values are
+now provided, so there is no need to make direct X library calls to
+get this information yourself.
+
+   There is also some provision for a future debugging facility to
+fake multiple screens by using multiple regular windows.  This
+code is not yet implemented.  When it is, the number returned by
+the MI_SCREEN macro may not correspond to a real X screen.  As of
+this writing, MI_SCREEN and MI_REAL_SCREEN always contain the same
+value.  Use MI_SCREEN as an index to track which window you are
+drawing to, use MI_REAL_SCREEN when calling X Windows functions
+which require actual screen numbers.  The MI_SCREENPTR pointer
+will always be valid, but identical for all faked screens.
+
+   The ModeInfo structure also provides a pointer to the LockStruct
+record that corresponds to the mode.  DO NOT MODIFY THIS STRUCTURE.
+This is provided so that you can see what your compiled in defaults
+where for delay, batchcount, cycles and saturation.  You can also
+get your own name and description and access the userdata field (it's
+ok to modify userdata, do not change anything else, use the macros).
+
+   All fields should be considered read-only, except MI_USERDATA
+and MI_PAUSE.  MI_USERDATA is not used by the mainline code, you
+can use any way you like and its value will be preserved.  However,
+the MI_PAUSE field is special.  MI_PAUSE is examined up upon return
+from your callback hook.  If it is not zero (it will be set zero
+before the call) it is interpreted as a time, in microseconds, to
+delay before making the next callback.
+
+   The MI_PAUSE mechanism is somewhat of a hack, and it is expected
+to change in future revisions of xlock.  Most probably it will be
+moved out of the ModeInfo struct and the callback return value will
+specify the delay value.  This one-time pause mechanism is also
+broken for multiple screens.  It is only noticed on the highest
+numbered screen.   Future revisions of xlock will (hopefully) fix this,
+but for now you can see how it works by looking at the code for maze
+or triangle.
+
+
+EXAMPLE
+
+   <<unfinished>>
+
+   The eyes mode (eyes.c) was written by the same author that did
+the majority of the restructuring for the new mode interface.  It
+should (hopefully) serve as a good example of a properly written
+mode.  It makes use of the new refresh and release hooks.  The
+random mode (random.c) will also illustrate the change hook and
+private resources.  The triangle mode (triangle.c) has also been
+updated to use the new scheme.  It uses the MI_PAUSE mechanism to
+sleep between scenes.
+
+------------------------
+
+   The official xlockmore maintainer is David Bagley.  He can be
+reached at bagleyd@tux.org.  The current release of xlockmore
+is available by anonymous ftp at ftp.x.org in /contrib/applications.
+Alpha versions are available at
+ftp://ftp.tux.org/pub/X-Windows/xlockmore/index.html
+
+   The restructuring of the calling mechanism for mode hooks was
+done by Ron Hitchens <ron@idiom.com>.
+
+------------------------
+
+   This document written by Ron Hitchens <ron@idiom.com>
+It is still very rough and incomplete.  What you see here is
+basically the first draft, brain-dump version.  It needs to be
+polished to make it more readable, condensed to make it less
+redundant and organized to make it more cogent.  But it's a start.
+Hopefully, this will eventually be converted to LaTeX.  When
+I get some time...
+
+
+Last Update:
+Mon Mar 18 03:46:16 MST 1996
+
+
+OK now you got a working mode $file.  What auxiliary files are there to change?
+$file.c mode.c mode.h                       You must have changed already
+modes/random.c                              If its a special mode or gl mode
+modes/Makefile.in make.com modes/Imakefile  Makefiles
+modes/glx/Imakefile                         If it is a gl mode
+xlock/XLock.ad                              Resource file
+xlock/xlock.man                             The manual
+xmlock/modes.h                              Motif launcher file (description)
+xalock/modes.h                              Athena launcher file
+etc/xlock.tcl                               TCL lanuncher file
+etc/xlockFrame.java                         Java lanuncher file
+etc/system.fvwm2rc.xlock                    fvwm2 menu
+etc/system.fvwmrc.xlock                     fvwm menu
+etc/system.olwmrc.xlock                     Openwin menu
+etc/system.mwmrc.xlock                      Motif menu
+etc/system.wmrc.xlock                       GNU WindowMaker menu
+etc/dtscreen.dt                             Screensaver actions for CDE (descr)
+etc/dtprofile                               CDE profile
+docs/Revisions                              Give credit
+docs/xlock.html                             Web reformat of manual (generated)
+docs/xlock.hlp                              VMS reformat of manual (generated)
diff --git a/xlockmore-4.14/docs/HACKERS.GUIDE.fr b/xlockmore-4.14/docs/HACKERS.GUIDE.fr
new file mode 100644 (file)
index 0000000..8cc4206
--- /dev/null
@@ -0,0 +1,286 @@
+I translate a part of the HACKER.DOC in french 
+first in text
+second in html
+bye
+-- 
+charles /  \
+vidal  / ..|\
+      (_\  |_)vidalc@club-internet.fr
+      /  \@'
+     /     \  http://www.chez.com/vidalc
+ _  /  `   |
+\\/  \  | _\
+ \   /_ || \\
+  \____)|_) \_)
+-----------------------------------------
+LA DOC DU BIDOUILLEUR
+
+INTRODUCTION
+________________________________________________________________________________
+
+Ce document est pour tous ceux qui veulent modifier xlock (more), ajouter de 
+nouveaux modes, debugger , etc....
+
+xlock kesako ?
+
+xlock est une application pour X-windows qui emp\88che l'acc\8as d'un ou plusieurs 
+\82crans. Il peut \88tre envoy\82 manuellement ou plus commun\82ment envoy\82 
+automatiquement par un d\82mon apr\8as une p\82riodes d'inactivit\82
+Xlock cr\82\82 une fen\88tre couvrant enti\8arement l'\82cran, et capte tous \82v\82nements 
+pr\82venant ainsi l'acc\8as ext\82rieur. 
+Quand une touche est press\82e alors xlock affiche un message mais aussi le mode 
+dans une icone 
+(MODE_ICONIQUE) et demande votre mot de passe.
+Lorsque l'\82cran est lock\82 ( ferm\82 ), des images, des dessins, ou des animations 
+sont affich\82es servant de screen-saver \82vitant la d\82gradation du phosphore.
+Xlock fut d\82velopp\82 chez Sun Micro System par Pack J Naughton.David Bagley l'a 
+repris et maintenu sous le nom de Xlockmore dans lequel d'innombrable mode ont 
+\82t\82 ajout\82, ainsi que la possibilit\82 d'afficher un mode dans une fen\88tre et 
+aussi sur la root window.
+
+________________________________________________________________________________
+ORGANISATION GENERALE
+
+xlock est organiser en deux partie.
+
+1. le traitement de la ligne de commande, la cr\82ation de fen\88tre, le mot de 
+passe, etc ...
+
+2 les modes: ils peuvent \88tre coder de tel mani\8are qu'il n'y a pas besoin de 
+faire appel \85 X pour la taille de la fen\88tre, les couleurs ... 
+Une API est comprise dans xlock pour avoir tout les renseignements en ce qui 
+concerne l'\82cran.
+C'est dans cette partie que vous allez pouvoir ajouter d'autres modes.
+
+L'architecture logiciel d'un mode est structur\82 en 4 sortes de fonctions:
+
+-init:
+celle-ci devra \88tre appelle pour pr\82parer le d\82roulement d'un mode. Le mode 
+devra initialiser des tables de sinus 
+par exemple, allouer des ressources, m\82moire entre autre, \82tablir l'\82tat initial
+par des variables etc. ...
+Cette fonction peut \88tre appel\82 plusieurs fois et la fen\88tre ou l'\82cran peuvent avoir des taille diff\82rentes.
+
+-callback:
+C'est la principale fonction, c'est la que est implement\82 le corps du mode.
+ Elle est appel\82 p\82riodiquement.
+ Cette fonction ne doit pas occuper beaucoup de temps a s'ex\82cuter.
+Cette fonction peut etre appele dans deux contextes diff\82rents:
+ plein \82cran ou en version icon. La fonction MI_IS_ICONIC vous dira dans 
+quelle contexte on se trouve.
+
+-release: 
+Ici, cette fonction sera appel\82 si un autre mode est appel\82 ( random , et bouton
+droit ), ou si xlock se termine. 
+Dans cette fonction, il faut d\82sallouer la m\82moire, X ressource, Pixmaps et 
+graphics context.
+
+-refresh:
+ Celle ci est appel\82 lorsque le dessin peut \88tre abim\82. Le mode doit repeindre 
+l'ensemble de la fen\88tre.
+
+-change: ???? <A FINIR>
+
+
+
+________________________________________________________________________________
+CONVERSION:
+Le prototype de ces fonctions est d\82fini dans mode.h et ressemble \85:
+       void typefonction _mode( ModeInfo *mode_info)
+La structure mode_info est en lecture seule, et contient l'ensemble des 
+informations sur l'\82cran. 
+Ne regardez pas les variables globales, n'\82crasez pas ce pointeur. 
+Au lieu de faire des requetes pour conna\8ctre le num\82ro de la couleur blanche 
+etc... , il y a des fonctions propres a xlock: utilisez les.
+
+
+
+
+________________________________________________________________________________
+L'AJOUT D'UN NOUVEAU MODE:
+
+Ajoutons un nouveau mode appel\82 fadeplot:
+Pour ce faire il faut d'abords ajouter dans mode.h
+® extern ModeHook init_fadeplot;
+extern ModeHook draw_fadeplot;
+extern ModeHook release_fadeplot;
+extern ModeHook refresh_fadeplot; Â¯
+les fonctions qui vont \88tre cr\82\82s.
+
+® extern ModeSpecOpt fadeplot_opts; Â¯
+une structure qui ne m'a pas r\82v\82l\82 tous ces secrets.
+
+mais aussi dans mode.c \85 cot\82 des autres fonctions , dans ce que j'appelle la
+ tableau des modes:
+ {"fadeplot", init_fadeplot, draw_fadeplot, release_fadeplot,
+ refresh_fadeplot, init_fadeplot, NULL, &blank_opts, 17000, 1, 20, 1.0,
+  "fadeplot", 0, NULL},
+
+On passe ensuite \85 l'impl\82mentation des fonctions proprement dit dans un fichier
+que l'on appellera fadeplot.c.
+Il est \82vident qu'il faudra modifier le Makefile ( Pour cela je vous laisse 
+faire :).
+
+Dans ces fonctions, \85 partir de la structure ModeInfo, on va obtenir des 
+informations sur l'\82cran qui sont indispensables pour la suite
+
+MI_WIDTH(mi) et MI_HEIGHT(mi)  vont nous donn\82 la taille de l'\82cran.
+Display    *display    = MI_DISPLAY(mi);       d\82livre le display
+Window      window = MI_WINDOW(mi);      d\82livre l'identificateur de la fen\88tre
+GC          gc               = MI_GC(mi);    donne le graphics context courant
+XSetForeground(display, gc, MI_BLACK_PIXEL(mi)); 
+                               Mettre la couleur du trac\82 en noir
+XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                                Mettre la couleur du trac\82 en blanc
+
+MI_IS_ICONIC(mi)               permet de savoir si on est pass\82 en phase
+                                                               password.
+NUMCOLORS                      Donne le nombre de couleur
+
+
+Oubliez pas apr\8as avoir dessin\82 l'ensemble de faire Xflush(display), 
+ce qui permettra d'afficher r\82ellement votre graphisme sur l'\82cran.
+La cr\82ation d'un nouveau mode s'\82ffectue souvent en r\82cup\82rant le squelette 
+d'un autre et de le modifier \85 sa volont\82.
+N'h\82sitez pas a \85 regarder le code des autres modes, c'est souvent tr\82
+instructifs.
+Dernierement on peut utiliser la librairie mesa (la libraire GNU OpenGL de 
+silicon Graphics) dans xlock.
+Voila j'espere que vous prendrez plaisir a ajouter des nouveaux modes \85 xlock,
+ un petit conseil le mainteneur de xlock est un fan de casse t\88te et compagnie.
+Bon Xlock.
+
+Charles VIDAL: vidalc@club-internet.fr
+mode flag, fadeplot, circle
+createur de xmxlock : GUI launcher de xlockmore.
+
+------------------------------------------------------
+
+<HTML>
+<HEAD>
+<TITLE>Xlock french hacker</TITLE>
+</HEAD>
+<BODY>
+<Center><H1>XLOCK FRENCH HACKER</H1></Center>
+<BR>
+<H2>INTRODUCTION</H2>
+<HR>
+Ce document est pour tous ceux qui veulent modifier xlock (more), ajouter de nouveaux modes, debugger , etc....
+
+<H2>xlock kesako ?</H2>
+
+xlock est une application pour X-windows qui empêche l\92accès d\92un ou plusieurs Ã©crans. Il peut Ãªtre envoyé manuellement ou plus communément envoyé automatiquement par un démon après une périodes d\92inactivité.
+ Xlock créé une fenêtre couvrant entièrement l\92écran, et capte tous Ã©vénements prévenant ainsi l\92accès extérieur. 
+Quand une touche est pressée alors xlock affiche un message mais aussi le mode dans une icone (MODE_ICONIQUE) et demande votre mot de passe.<p>
+Lorsque l\92écran est locké ( fermé ), des images, des dessins, ou des animations sont affichées servant de screen-saver Ã©vitant la dégradation du phosphore.
+Xlock fut développé chez Sun Micro System par Pack J Naughton.David Bagley l\92a repris et maintenu sous le nom de Xlockmore dans lequel d\92innombrable mode ont Ã©té ajouté, ainsi que la possibilité d\92afficher un mode dans une fenêtre et aussi sur la root window ou d\92afficher sequentiellement plusieur mode par l\92option random et par l\92appuis du bouton du millieu.<p>
+Il existe des terminaux X avec plusieur ecrans gere par un seul terminal, alors le même mode s\92affichera sur plusieur ecran. On peut toutefois faire des effets, comme une balle passant de lui a l\92autre.
+
+<HR>
+<H2>ORGANISATION GENERALE</H2>
+
+xlock est organiser en deux partie.<p>
+
+<OL>
+<LI> le traitement de la ligne de commande, la création de fenêtre(s), le mot de passe, etc ...
+<LI> les modes: ils peuvent Ãªtre coder de tel manière qu\92il n\92y a pas besoin de faire appel Ã  X pour la taille de la fenêtre, les couleurs ... Une API est comprise dans xlock pour avoir tout les renseignements en ce qui concerne l\92écran.C\92est dans cette 
+</OL>
+<HR>
+<B>L\92architecture logiciel d\92un mode est structuré en 4 sortes de fonctions:</B>
+<UL>
+<LI><U><B>-init:</B></U>
+celle-ci devra Ãªtre appelle pour préparer le déroulement d\92un mode. Le mode devra initialiser des tables de sinus par exemple, allouer des ressources, mémoire entre autre, Ã©tablir l\92état initial par des variables etc. ...
+Cette fonction peut Ãªtre appelé plusieurs fois et la fenêtre ou l\92écran peuvent avoir des taille différentes.<p>
+
+<LI><U><B>-callback:</B></U>
+C\92est la principale fonction, c\92est la que est implementé le corps du mode. Elle est appelé périodiquement. Cette fonction ne doit pas occuper beaucoup de temps a s\92exécuter surtout si elle a plusieur ecran s\92occuper.
+Cette fonction peut etre appele dans deux contextes différents:
+ plein Ã©cran ou en version icon. La fonction MI_IS_ICONIC vous dira dans quelle contexte on se trouve.
+la fonction init_mode est toujours appelle avant la fonction callback.
+On peut choisir de faire quelque chose a chaque appelle, ou de compter le nombre d\92appelle, et puis de modifier l\92ecran periodiquement.<p>
+
+<LI><U><B>-release: </B></U>
+Ici, cette fonction sera appelé si un autre mode est appelé ( random , et bouton droit ), ou si xlock se termine. Dans cette fonction, il faut désallouer la mémoire, X ressource, Pixmaps et graphics context.
+<p>
+<LI><U><B>-refresh:</B></U>
+ Celle ci est appelé lorsque le dessin peut Ãªtre abimé. Le mode doit repeindre l\92ensemble de la fenêtre.
+Aucun information sur la partie de l\92ecran endomage n\92est delivre.
+<p>
+<LI><U><B>-change:</B></U> Dans la version courante, seule le mode random utilise cette fonctionnalite. Cet fonction est appele lorsque que l\92on change de mode par l\92appuie du boutton du millieu. Il est laisse a l\92imagination de chacun en ce qui conserne 
+</UL>
+
+
+<HR>
+<H2>CONVENTION:</H2>
+Le prototype de ces fonctions est défini dans mode.h et ressemble Ã :<p>
+<Center>       void typefonction _mode( ModeInfo *mode_info)</Center>
+La structure mode_info est en lecture seule, et contient l\92ensemble des informations sur l\92écran. Ne regardez pas les variables globales, n\92écrasez pas ce pointeur. Au lieu de faire des requetes pour connaître le numéro de la couleur blanche etc... , il y a des fonctions propres a xlock: utilisez les. Si vous utilisez les informations passe en parametre des fonctions du modes ( voir ci dessus ), votre code sera toujours correcte.
+Le temps entre chaque appelle  de fonctions est en milliseconde.
+
+<HR>
+<H2>L\92AJOUT D\92UN NOUVEAU MODE:</H2>
+
+Ajoutons un nouveau mode appelé <A HREF="file:fadeplot.txt">fadeplot</A>:<p>
+Pour ce faire il faut d\92abords ajouter dans mode.h<p>
+« extern ModeHook init_fadeplot;<p>
+extern ModeHook draw_fadeplot;<p>
+extern ModeHook release_fadeplot;<p>
+extern ModeHook refresh_fadeplot; Â»<p>
+les fonctions qui vont Ãªtre créés.
+<p>
+« extern ModeSpecOpt fadeplot_opts; Â»<p>
+une structure qui ne m\92a pas révélé tous ces secrets.<p>
+
+mais aussi dans mode.c Ã  coté des autres fonctions , dans ce que j\92appelle le tableau des modes:<p>
+ {"fadeplot", init_fadeplot, draw_fadeplot, release_fadeplot,
+ refresh_fadeplot, init_fadeplot, NULL, &blank_opts, 17000, 1, 20, 1.0,
+  "fadeplot", 0, NULL},<p>
+
+On passe ensuite Ã  l\92implémentation des fonctions proprement dit dans un fichier que l\92on appellera fadeplot.c.<p>
+Il est Ã©vident qu\92il faudra modifier le Makefile ( Pour cela je vous laisse faire :).<p>
+Dans ces fonctions, Ã  partir de la structure ModeInfo ( mode.h ) , on va obtenir des informations sur l\92écran qui sont indispensables pour la suite.<p>
+
+<TABLE Border=1>
+<CAPTION><B>fonction</B></CAPTION>
+<TR><TD>MI_WIDTH(mi) et MI_HEIGHT(mi)</TD>     <TD>vont nous donné la taille de l\92écran</TD></TR>.
+<TR><TD>Display    *display    = MI_DISPLAY(mi);</TD>  <TD>délivre le display</TD></TR>
+<TR>   <TD>             MI_SCREEN      </TD>   <TD>délivre le screen</TD></TR>
+<TR><TD>Window      window = MI_WINDOW(mi)</TD>;       <TD>délivre l\92identificateur de la fenêtre</TD></TR>
+<TR><TD>GC          gc               = MI_GC(mi);</TD> <TD>donne le graphics context courant</TD></TR>
+<TR>           <TD>MI_DELAY</TD>               <TD>    donne le delai (microsec.) entre callbacks</TD></TR>
+<TR>        <TD>MI_CMAP</TD>           <TD>donne la table des couleurs</TD></TR>
+<TR><TD>XSetForeground(display, gc, MI_BLACK_PIXEL(mi));</TD>  <TD>Mettre la couleur du tracé en noir</TD></TR>
+<TR><TD>XSetForeground(display, gc, MI_WHITE_PIXEL(mi));</TD> <TD>Mettre la couleur du tracé en blanc</TD></TR>
+<TR><TD>MI_IS_ICONIC(mi)       </TD>   <TD>permet de savoir si on est passé en phase password. </TD></TR>
+</TABLE>
+
+<TABLE Border=1>
+<CAPTION><B>variable</B></CAPTION>
+<TR><TD>MI_IS_MONO     </TD>           <TD>l\92ecran est monochrome</TD></TR>
+<TR><TD>MI_IS_INWINDOW</TD>            <TD>le mode s\92affiche dans un fenetre reguliere</TD></TR>
+<TR><TD>MI_IS_INROOT   </TD>           <TD>le mode s\92affiche sur la root windows</TD></TR>
+<TR><TD>NUMCOLORS</TD>                 <TD>Donne le nombre de couleur</TD></TR>
+</TABLE>
+
+
+Oubliez pas après avoir dessiné l\92ensemble de faire Xflush(display), ce qui permettra d\92afficher réellement votre graphisme sur l\92écran.
+La création d\92un nouveau mode s\92éffectue souvent en récupérant le squelette d\92un autre et de le modifier Ã  sa volonté.
+N\92hésitez pas a Ã  regarder le code des autres modes, c\92est souvent trés instructifs.
+<HR>
+<H2>Perspective:</H2>
+Dernierement on peut utiliser la librairie mesa (la libraire OpenGL de silicon GNU) dans xlock, quelqu\92un s\92est propose de faire le screen-saver tube de Win NT.
+Je pense qu\92il serait interressant de joindre a xlock un langage simple ( genre logo un peu plus evolue).
+<HR>
+<H2>Reference: </H2>
+HACKERS.GUIDE qui se trouve dans le repertoire docs ( j\92ai essaye de le traduire :)<p>
+           X_Window programmation avec les Xt-Intrinsics Douglas A YOUNG MASSON PARIS.<p>
+<HR>
+Voila j\92espere que vous prendrez plaisir a ajouter des nouveaux modes Ã  xlock; c\92est une maniere de programmer facilement des graphismes sous X11. Un petit conseil le mainteneur de xlock est un fan de casse tête et compagnie.
+Bon Xlock.
+<p>
+Charles VIDAL: vidalc@club-internet.fr<p>
+mode flag, fadeplot, bubble<p>
+createur de xmxlock : GUI launcher de xlockmore.<p>
+
+</BODY>
+</HTML>
diff --git a/xlockmore-4.14/docs/Purify b/xlockmore-4.14/docs/Purify
new file mode 100644 (file)
index 0000000..d3cc9b8
--- /dev/null
@@ -0,0 +1,46 @@
+New Purify problems
+
+Solved?
+starfish line 208, 209, 517      4  (65 spline)
+  make_starfish  [starfish.c:208]     make_spline    [spline.c:69]
+  make_starfish  [starfish.c:209]
+  init_starfish  [starfish.c:517]
+kumppa solved?
+
+Unsolved
+  draw1_starfish [starfish.c:365]  compute_closed_spline [spline.c:260]
+    ...  grow_spline_points [spline.c:97]
+
+bubble3d  create_new_bubbles b_draw 167
+  glb_bubble_new [bubble3d.c:103]
+  glb_draw_init  [b_draw.c:53]
+
+------------------------------------------
+
+
+Old Purify Problems (problems are now marked in code with "PURIFY")
+
+---
+Summary of unresolved memory problems with xlockmore-4.03
+cartoon - Possible 29756 byte memory leak from XPutImage
+swirl - Possible 256 byte memory leak from XPutImage
+life - Possible 132 byte memory leak from XPutImage
+There are also some uninitialized memory reads that appear to be internal
+to X11.
+---
+
+
+SOLVED since xlockmore-4.08
+resource.c - 1 byte memory leak (Fixed since the Purify reports)
+
+SOLVED since xlockmore-4.02
+memory leaks:               galaxy.c, life3d.c
+
+MesaGL 2.3 fixes many cumulative leaks and uninitialized memory reads that
+existed in MesaGL 2.2.  This affected all GL modes.  MesaGL 2.3 or newer is
+recommended since it fixes these memory leaks and runs faster.  Cumulative
+means that the memory leaks occur each time the mode is run when in random
+mode, which is why after some time it may crash xlock since it runs out of
+available memory.
+
+Thanks to Tom Schmidt for the solaris and sunos purify logs.
diff --git a/xlockmore-4.14/docs/Purify.solaris b/xlockmore-4.14/docs/Purify.solaris
new file mode 100644 (file)
index 0000000..b976932
--- /dev/null
@@ -0,0 +1,617 @@
+Content-Type: text/plain; charset=us-ascii; name="xlock.plog.sun4os5"
+Content-Transfer-Encoding: 7bit
+Content-Disposition: inline; filename="xlock.plog.sun4os5"
+
+****  Purify instrumented xlock/xlock (pid 24202 at Thu Feb 26 08:05:25 1998)
+  * Purify 4.0.1 Solaris 2, Copyright (C) 1992-1996 Pure Atria Corp. All rights reserved. 
+  * For contact information type: "purify -help"
+  * For TTY output, use the option "-windows=no"
+  * Command-line: xlock/xlock -sequential -duration 15 
+  * Options settings: -chain-length=25 -windows=yes -purify \
+    -purify-home=/vol/pure/purify-4.0.1-solaris2 
+  * Purify checking enabled.
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       GetDatabase    [Xrm.c]
+       XrmGetFileDatabase [Xrm.c]
+       parsefilepath  [resource.c:1092]
+       getResources   [resource.c:1390]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 4 bytes from 0x3c109c in the heap.
+  * Address 0x3c109c is 4 bytes into a malloc'd block at 0x3c1098 of 16 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       NewDatabase    [Xrm.c]
+       XrmGetFileDatabase [Xrm.c]
+       parsefilepath  [resource.c:1092]
+       getResources   [resource.c:1390]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       GetDatabase    [Xrm.c]
+       XrmGetFileDatabase [Xrm.c]
+       parsefilepath  [resource.c:1092]
+       getResources   [resource.c:1390]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 4 bytes from 0x3c109c in the heap.
+  * Address 0x3c109c is 4 bytes into a malloc'd block at 0x3c1098 of 16 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       NewDatabase    [Xrm.c]
+       XrmGetFileDatabase [Xrm.c]
+       parsefilepath  [resource.c:1092]
+       getResources   [resource.c:1390]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       _XReply        [XlibInt.c]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 68 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0aa9 uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       GetDatabase    [Xrm.c]
+       XrmGetStringDatabase [Xrm.c]
+       getResources   [resource.c:1463]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 4 bytes from 0x3e4c04 in the heap.
+  * Address 0x3e4c04 is 4 bytes into a malloc'd block at 0x3e4c00 of 16 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       NewDatabase    [Xrm.c]
+       XrmGetStringDatabase [Xrm.c]
+       getResources   [resource.c:1463]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       GetDatabase    [Xrm.c]
+       XrmGetStringDatabase [Xrm.c]
+       getResources   [resource.c:1463]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 4 bytes from 0x3e4c04 in the heap.
+  * Address 0x3e4c04 is 4 bytes into a malloc'd block at 0x3e4c00 of 16 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       NewDatabase    [Xrm.c]
+       XrmGetStringDatabase [Xrm.c]
+       getResources   [resource.c:1463]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       XrmCombineDatabase [Xrm.c]
+       getResources   [resource.c:1466]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 4 bytes from 0x3e4c04 in the heap.
+  * Address 0x3e4c04 is 4 bytes into a malloc'd block at 0x3e4c00 of 16 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       NewDatabase    [Xrm.c]
+       XrmGetStringDatabase [Xrm.c]
+       getResources   [resource.c:1463]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       XrmCombineDatabase [Xrm.c]
+       getResources   [resource.c:1525]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 4 bytes from 0x3c4064 in the heap.
+  * Address 0x3c4064 is 4 bytes into a malloc'd block at 0x3c4060 of 16 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       NewDatabase    [Xrm.c]
+       XrmQPutStringResource [Xrm.c]
+       XrmParseCommand [ParseCmd.c]
+       getResources   [resource.c:1521]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       XrmDestroyDatabase [Xrm.c]
+       getResources   [resource.c:1598]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+  * Reading 4 bytes from 0x3c109c in the heap.
+  * Address 0x3c109c is 4 bytes into a malloc'd block at 0x3c1098 of 16 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       NewDatabase    [Xrm.c]
+       XrmGetFileDatabase [Xrm.c]
+       parsefilepath  [resource.c:1092]
+       getResources   [resource.c:1390]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       _XReply        [XlibInt.c]
+       _XQueryFont    [XFont.c]
+       XLoadQueryFont [XFont.c]
+       main           [xlock.c:2140]
+       _start         [crt1.o]
+  * Reading 92 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0afb uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       _XReply        [XlibInt.c]
+       XGrabKeyboard  [XGrKeybd.c]
+       GrabKeyboardAndMouse [xlock.c:518]
+       main           [xlock.c:2501]
+       _start         [crt1.o]
+  * Reading 428 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0b21 uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       _XReply        [XlibInt.c]
+       XParseColor    [XParseCol.c]
+       allocPixel     [color.c:116]
+       fixColormap    [color.c:182]
+       init_random    [random.c:496]
+       call_init_hook [mode.c:813]
+       justDisplay    [xlock.c:1681]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 428 bytes from 0x3e0aa8 in the heap (2 bytes at 0x3e0c52 uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read (6059 times):
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       _XReply        [XlibInt.c]
+       XSync          [XSync.c]
+       runMainLoop    [xlock.c:1111]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 476 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0c5d uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       XFlush         [XFlush.c]
+       getPassword    [xlock.c:1508]
+       lockDisplay    [xlock.c:1878]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 816 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0c81 uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       XFlush         [XFlush.c]
+       draw_ball      [ball.c:471]
+       call_callback_hook [mode.c:842]
+       draw_random    [random.c:536]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 1008 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0df9 uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read (1008 times):
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       PutImageRequest [XPutImage.c]
+       PutSubImage    [XPutImage.c]
+       XPutImage      [XPutImage.c]
+       draw_point     [swirl.c:1128]
+       draw_swirl     [swirl.c:1361]
+       call_callback_hook [mode.c:842]
+       draw_random    [random.c:536]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 2040 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0b0f uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read (412 times):
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       XDrawPoint     [XDrPoint.c]
+       draw_mandelbrot [mandelbrot.c:420]
+       call_callback_hook [mode.c:842]
+       draw_random    [random.c:536]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 2048 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0acb uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read (4 times):
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       _XReply        [XlibInt.c]
+       XParseColor    [XParseCol.c]
+       allocPixel     [color.c:116]
+       fixColormap    [color.c:182]
+       draw_random    [random.c:528]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 412 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0c3b uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read:
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       _XFlushGCCache [XCrGC.c]
+       XDrawPoint     [XDrPoint.c]
+       draw_mandelbrot [mandelbrot.c:419]
+       call_callback_hook [mode.c:842]
+       draw_random    [random.c:536]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 2044 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0abb uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+UMR: Uninitialized memory read (7 times):
+  * This is occurring while in:
+       _libc_write    [libc.so.1]
+       _XFlushInt     [XlibInt.c]
+       XDrawPoint     [XDrPoint.c]
+       draw_mandelbrot [mandelbrot.c:419]
+       call_callback_hook [mode.c:842]
+       draw_random    [random.c:536]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Reading 2036 bytes from 0x3e0aa8 in the heap (1 byte at 0x3e0abb uninit).
+  * Address 0x3e0aa8 is at the beginning of a malloc'd block of 2048 bytes.
+  * This block was allocated from:
+       malloc         [rtlib.o]
+       XOpenDisplay   [XOpenDis.c]
+       open_display   [resource.c:1211]
+       getResources   [resource.c:1457]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+Current file descriptors in use: 9
+FIU: file descriptor 0: <stdin>
+FIU: file descriptor 1: <stdout>
+FIU: file descriptor 2: <stderr>
+FIU: file descriptor 4: "/etc/.name_service_door", O_RDONLY
+   * File info: ?r--r--r--  1 root     root             0 Nov 10 10:53
+   * This file descriptor was allocated from:
+       _libc_open     [libc.so.1]
+       _nsc_trydoorcall [libc.so.1]
+       getpwuid_r     [libc.so.1]
+       fullLock       [logout.c:467]
+       getResources   [resource.c:1615]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+FIU: file descriptor 5: "/usr/local/xlock.staff", O_RDONLY
+   * File info: -rw-r--r--  1 root     other           18 Feb 26 08:04
+   * File position: 18
+   * This file descriptor was allocated from:
+       _libc_open     [libc.so.1]
+       _endopen       [fopen.c]
+       fopen          [libc.so.1]
+       my_fopen       [utils.c:182]
+       fullLock       [logout.c:476]
+       getResources   [resource.c:1615]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+FIU: file descriptor 6: "/dev/udp", O_RDWR
+   * File info: c---------  0 root     root             0 Feb 26 08:05
+   * File position: 0
+   * This file descriptor was allocated from:
+       _libc_open     [libc.so.1]
+       t_open         [t_open.c]
+       clnt_tli_create [clnt_generic.c]
+       load_dom_binding [yp_bind.c]
+       check_binding  [yp_bind.c]
+       __yp_dobind    [yp_bind.c]
+       yp_match       [yp_match.c]
+       _nss_nis_ypmatch [nss_nis.so.1]
+       _nss_nis_lookup [nss_nis.so.1]
+       getbyname      [getspent.c]
+       nss_search     [libc.so.1]
+       getspnam_r     [libc.so.1]
+       my_passwd_entry [passwd.c:378]
+       getUserName    [passwd.c:502]
+       initPasswd     [passwd.c:1796]
+       main           [xlock.c:2101]
+       _start         [crt1.o]
+FIU: file descriptor 7: "/usr/openwin/lib/X11/Xcms.txt", O_RDONLY
+   * File info: -rw-rw-r--  1 root     bin           2528 Mar 21  1996
+   * File position: 2528
+   * This file descriptor was allocated from:
+       _libc_open     [libc.so.1]
+       _endopen       [fopen.c]
+       fopen          [libc.so.1]
+       LoadColornameDB [XcmsColNm.c]
+       _XcmsLookupColorName [XcmsColNm.c]
+       _XcmsResolveColorString [XcmsColNm.c]
+       XParseColor    [XParseCol.c]
+       allocPixel     [color.c:116]
+       fixColormap    [color.c:182]
+       main           [xlock.c:2402]
+       _start         [crt1.o]
+FIU: file descriptor 26: <reserved for Purify internal use>
+FIU: file descriptor 27: <reserved for Purify internal use>
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+Purify: Searching for all memory leaks...
+
+Memory leaked: 3618 bytes (0.0225%); potentially leaked: 0 bytes (0%)
+
+MLK: 1024 bytes leaked at 0x3e85c8
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       _nss_files_XY_all [nss_files.so.1]
+       nss_search     [libc.so.1]
+       getspnam_r     [libc.so.1]
+       my_passwd_entry [passwd.c:378]
+       getUserName    [passwd.c:502]
+       initPasswd     [passwd.c:1796]
+       main           [xlock.c:2101]
+       _start         [crt1.o]
+
+MLK: 1024 bytes leaked at 0x3ed3f0
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       _nss_files_XY_all [nss_files.so.1]
+       nss_search     [libc.so.1]
+       getspnam_r     [libc.so.1]
+       my_passwd_entry [passwd.c:378]
+       getCryptedUserPasswd [passwd.c:724]
+       initPasswd     [passwd.c:1809]
+       main           [xlock.c:2101]
+       _start         [crt1.o]
+
+MLK: 1024 bytes leaked at 0x404148
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       _nss_files_XY_all [nss_files.so.1]
+       nss_search     [libc.so.1]
+       getspnam_r     [libc.so.1]
+       getCryptedRootPasswd [passwd.c:874]
+       initPasswd     [passwd.c:1812]
+       main           [xlock.c:2101]
+       _start         [crt1.o]
+
+MLK: 528 bytes leaked in 6 blocks
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       calloc         [rtlib.o]
+       XCreateImage   [XImUtil.c]
+       init_flag      [flag.c:419]
+       call_init_hook [mode.c:813]
+       draw_random    [random.c:534]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+  * Block of 88 bytes (6 times); last block at 0x3ee5c0
+
+MLK: 16 bytes leaked at 0x3f3d60
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       _get_iobuf     [des_crypt.c]
+       des_crypt      [libcrypt_i.a]
+       checkPasswd    [passwd.c:1103]
+       getPassword    [xlock.c:1580]
+       lockDisplay    [xlock.c:1878]
+       main           [xlock.c:2522]
+       _start         [crt1.o]
+
+MLK: 1 byte leaked at 0x3bd890
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       GetResource    [resource.c:982]
+       getResources   [resource.c:1431]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+MLK: 1 byte leaked at 0x400208
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       GetResource    [resource.c:982]
+       getResources   [resource.c:1577]
+       main           [xlock.c:2086]
+       _start         [crt1.o]
+
+Purify Heap Analysis (combining suppressed and unsuppressed blocks)
+                         Blocks      Bytes
+              Leaked         12       3618
+  Potentially Leaked          2      16400
+              In-Use        313   16025182
+  ----------------------------------------
+     Total Allocated        327   16045200
+
+****  Purify instrumented xlock/xlock (pid 24202)  ****
+  * Program exited with status code 0.
+  * 19 access errors, 7504 total occurrences.
+  * 3618 bytes leaked.
+  * 0 bytes potentially leaked.
+  * Basic memory usage (including Purify overhead):
+     3258076 code
+      520628 data/bss
+    25788416 heap (peak use)
+        4192 stack
+  * Shared library memory usage (including Purify overhead):
+       75078 libsocket.so.1_pure_p3_c0_401_551 (shared code)
+        4096 libsocket.so.1_pure_p3_c0_401_551 (private data)
+      617030 libnsl.so.1_pure_p3_c0_401_551 (shared code)
+       65176 libnsl.so.1_pure_p3_c0_401_551 (private data)
+        7628 libposix4.so.1_pure_p3_c0_401_551 (shared code)
+         432 libposix4.so.1_pure_p3_c0_401_551 (private data)
+      654898 libX11.so.4_pure_p3_c0_401_551 (shared code)
+       14112 libX11.so.4_pure_p3_c0_401_551 (private data)
+       97156 libXext.so.0_pure_p3_c0_401_551 (shared code)
+        2140 libXext.so.0_pure_p3_c0_401_551 (private data)
+      135721 libm.so.1_pure_p3_c0_401_551 (shared code)
+        5872 libm.so.1_pure_p3_c0_401_551 (private data)
+      802689 libc.so.1_pure_p3_c0_401_551 (shared code)
+       34804 libc.so.1_pure_p3_c0_401_551 (private data)
+        1200 libdl.so.1_pure_p3_c0_401_551 (shared code)
+           0 libdl.so.1_pure_p3_c0_401_551 (private data)
+        2729 libinternal_stubs.so.1 (shared code)
+         208 libinternal_stubs.so.1 (private data)
+       15141 libintl.so.1_pure_p3_c0_401_551 (shared code)
+        1304 libintl.so.1_pure_p3_c0_401_551 (private data)
+       16092 libmp.so.1_pure_p3_c0_401_551 (shared code)
+         828 libmp.so.1_pure_p3_c0_401_551 (private data)
+       37917 libw.so.1_pure_p3_c0_401_551 (shared code)
+        1628 libw.so.1_pure_p3_c0_401_551 (private data)
diff --git a/xlockmore-4.14/docs/Purify.sunos b/xlockmore-4.14/docs/Purify.sunos
new file mode 100644 (file)
index 0000000..feea43c
--- /dev/null
@@ -0,0 +1,133 @@
+Content-Type: text/plain; charset=us-ascii; name="xlock.plog.sun4os4"
+Content-Transfer-Encoding: 7bit
+Content-Disposition: inline; filename="xlock.plog.sun4os4"
+
+****  Purify instrumented xlock/xlock (pid 25527 at Wed Feb 25 17:02:40 1998)
+  * Purify 4.0.1 SunOS 4.1, Copyright (C) 1992-1996 Pure Atria Corp. All rights reserved. 
+  * For contact information type: "purify -help"
+  * For TTY output, use the option "-windows=no"
+  * Command-line: xlock/xlock -sequential 
+  * Options settings: -chain-length=25 -windows=yes -purify \
+    -purify-home=/vol/pure/purify-4.0.1-sunos4 
+  * Purify checking enabled.
+
+****  Purify instrumented xlock/xlock (pid 25527)  ****
+Current file descriptors in use: 7
+FIU: file descriptor 0: <stdin>
+FIU: file descriptor 1: <stdout>
+FIU: file descriptor 2: <stderr>
+FIU: file descriptor 4: "/usr/local/xlock.staff", O_RDONLY
+   * File info: -rw-r--r--  1 root     staff           15 Apr 18  1997
+   * File position: 15
+   * This file descriptor was allocated from:
+       open           [rtlib.o]
+       _endopen       [libc.so.1.8]
+       fopen          [libc.so.1.8]
+       my_fopen       [utils.c:182]
+       fullLock       [logout.c:476]
+       getResources   [resource.c:1615]
+       main           [xlock.c:2086]
+       start          [crt0.o]
+FIU: file descriptor 5: <unnamed socket>, O_RDWR
+   * This file descriptor was allocated from:
+       socket         [rtlib.o]
+       clntudp_bufcreate [libc.so.1.8]
+       load_dom_binding [libc.so.1.8]
+       _yp_dobind_soft [libc.so.1.8]
+       _yp_dobind     [libc.so.1.8]
+       yp_match       [libc.so.1.8]
+       getnamefromyellow [libc.so.1.8]
+       matchuid       [libc.so.1.8]
+       getpwuid       [libc.so.1.8]
+       fullLock       [logout.c:467]
+       getResources   [resource.c:1615]
+       main           [xlock.c:2086]
+       start          [crt0.o]
+FIU: file descriptor 26: <reserved for Purify internal use>
+FIU: file descriptor 27: <reserved for Purify internal use>
+
+****  Purify instrumented xlock/xlock (pid 25527)  ****
+Purify: Searching for all memory leaks...
+
+Memory leaked: 442 bytes (0.00378%); potentially leaked: 29756 bytes (0.255%)
+
+MLK: 440 bytes leaked in 5 blocks
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       calloc         [rtlib.o]
+       XCreateImage   [libX11.so.4.3]
+       init_flag      [flag.c:419]
+       call_init_hook [mode.c:813]
+       draw_random    [random.c:534]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       start          [crt0.o]
+  * Block of 88 bytes (5 times); last block at 0x123b008
+
+MLK: 1 byte leaked at 0x39e6e0
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       GetResource    [resource.c:982]
+       getResources   [resource.c:1431]
+       main           [xlock.c:2086]
+       start          [crt0.o]
+
+MLK: 1 byte leaked at 0x400540
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       GetResource    [resource.c:982]
+       getResources   [resource.c:1577]
+       main           [xlock.c:2086]
+       start          [crt0.o]
+
+PLK: 29756 bytes potentially leaked at 0x3cc610
+  * This memory was allocated from:
+       malloc         [rtlib.o]
+       _XAllocScratch [libX11.so.4.3]
+       dX__SendZImage [libX11.so.4.3]
+       dX__PutImageRequest [libX11.so.4.3]
+       dX__PutSubImage [libX11.so.4.3]
+       XPutImage      [libX11.so.4.3]
+       put_cartoon    [cartoon.c:232]
+       draw_cartoon   [cartoon.c:374]
+       call_callback_hook [mode.c:842]
+       draw_random    [random.c:536]
+       call_callback_hook [mode.c:842]
+       runMainLoop    [xlock.c:1107]
+       justDisplay    [xlock.c:1698]
+       lockDisplay    [xlock.c:1875]
+       main           [xlock.c:2522]
+       start          [crt0.o]
+
+Purify Heap Analysis (combining suppressed and unsuppressed blocks)
+                         Blocks      Bytes
+              Leaked          8        454
+  Potentially Leaked          1      29756
+              In-Use        299   11660442
+  ----------------------------------------
+     Total Allocated        308   11690652
+
+****  Purify instrumented xlock/xlock (pid 25527)  ****
+  * Program exited with status code 0.
+  * 0 access errors, 0 total occurrences.
+  * 442 bytes leaked.
+  * 29756 bytes potentially leaked.
+  * Basic memory usage (including Purify overhead):
+     3233296 code
+      531096 data/bss
+    23630080 heap (peak use)
+        2224 stack
+  * Shared library memory usage (including Purify overhead):
+      335872 libX11_pure_p3_c0_401_413V.so.4.3 (shared code)
+       40960 libX11_pure_p3_c0_401_413V.so.4.3 (private data)
+      688128 libc_pure_p3_c0_401_413V.so.1.8 (shared code)
+       16384 libc_pure_p3_c0_401_413V.so.1.8 (private data)
+        8192 libdl.so.1.0 (shared code)
+        8192 libdl.so.1.0 (private data)
+        8192 libinternal_stubs.so.1.0 (shared code)
+        8192 libinternal_stubs.so.1.0 (private data)
+  * Memory mapped usage:
+        4096 mmap'd at 0xef298000
diff --git a/xlockmore-4.14/docs/Revisions b/xlockmore-4.14/docs/Revisions
new file mode 100644 (file)
index 0000000..4e7cb8f
--- /dev/null
@@ -0,0 +1,1808 @@
+xlockmore-4.14 as of 23 June 1999, the maintained version of xlock
+Adapted from Patrick J. Naughton's original xlock
+
+Primary site: ftp://ftp.tux.org/pub/tux/bagleyd/xlockmore
+Secondary site: ftp://ftp.x.org/contrib/applications
+Web page: http://www.tux.org/~bagleyd/xlockmore.html
+Maintainer: David A. Bagley <bagleyd@tux.org>
+
+Majordomos: Mail to majordomo@tux.org with just
+subscribe [choice] [your-email-address]
+  in the body.
+    choice                  brief description
+    ------                  -----------------
+    xlock-beta              Xlock beta and production announcements
+    xlock-alpha             Xlock alpha ("daily") release announcements
+    xlock                   Xlock/Xlockmore development discussion
+  If there is trailing signature junk, just put "end" as the last line to
+  be read.  If you need help just put "help" in the body.
+
+Please send all bug reports to bagleyd@tux.org .
+Alpha versions may be available through web page or ftp site.
+Adapted from Patrick J. Naughton's original xlock, with lots of help
+ from others.
+
+BUGS to fix and other stuff to do see docs/TODO.
+
+4.14
+  Peter Munster <peter@gmv.spm.univ-rennes1.fr> found a bug with -lockdelay
+    and +mousemotion.  Moving the mouse after the delay brought up the
+    password window.
+  For 4.15 I will probably add "#ident" stuff for all .h files.
+    Started but commented out for now since it should be tested more.
+  Update matrix in menus, man page XLock.ad, and gui programs.
+  matrix: update to make it look more like the movie thanks to Joan Touzet
+    <joant@cadence.com>.
+  life: added a P88 oscillator to life.c from Paul Callahan
+    http://www.cs.jhu.edu/~callahan/patterns/p1/p1.html and a diagonal
+    sparker from Tim Coe
+    http://www.cs.jhu.edu/~callahan/patterns/dspark/dspark.html
+  thornbird: upgraded from author <Tim.Auckland@corp.sun.com>.
+  xjack: fix for little window thanks to Jouk Jansen.
+  text3d: -message "text" updates from Eric Lassauge and Jouk Jansen.
+    Purify errors noted in text3d.cc thanks to Tom Schmidt.
+    updates for fortunes from Jouk Jansen
+    initialization errors of GLTT library.  Thanks to Jouk Jansen and Scott
+    <mcmillan@cambridge.com>.
+  dclock: options y2k and millennium from Tom Schmidt <tschmidt@micron.com>.
+    It uses local timezone and description was cleaned up.  French
+    translations by Eric Lassauge <lassauge@sagem.fr> and Dutch translations
+    from Jouk Jansen.  Also Tom patched dclock up for NetBSD.
+  flag: descriptions and purify errors from Tom Schmidt <tschmidt@micron.com>.
+  -neighbors now a mode option.   -mouse changed to -trackmouse
+    -mousemotion was getting picked up instead.  -shift, tshift and -cycle
+    combined to -cycle for crystal, tetris, and starfish.
+  Multiple options use in modes now possible.  Set up only for -eyes for
+    ant and bug.  (Also another major test would be an option that passed
+    an integer in).  Code stolen from ParseCmd.c from X11R6.4 source and then
+    made so argc and argv are NOT updated.  Jouk Jansen fixed if for VMS.
+  Jouk Jansen cleaned up the erase modes.  New option -erasetime added which
+    will cause the erase to come to an abrupt end on a slow machine.  Default
+    set at 2 seconds.  Also made the erasing smoother...   Also fixed a
+    problem on starfish when size became 0.
+  Resurrected some old code in ant.c so now ant and bug have an -eyes switch.
+    (In the case of bug, it does not let the bug see any better, it just
+    shows the direction its facing).  So far its for neighbors = 4 or 8 only
+    in ant  ... (and bug also has neighbor = 6 setup).  The graphics leaves
+    some room for improvement.
+  bug now can have 4 or 8 neighbors and restarts if all bugs die (this did
+    not always work before).
+  -cpasswd will now work if system uses shadow passwords even if not
+    configured with --enable-xlockrc .
+  matrix mode thanks to Erik O'Shaughness <eriko@austin.ibm.com>.
+    Miscellaneous patches to this mode (less warnings, unexpected events,
+    leaks thanks to Tom Schmidt, Jouk Jansen and myself).  The font seems
+    is from X11.
+  rubik.c now supports LxMxN cubes where non-square faces turn 180 degrees.
+    (nx2n 90 degree turns or known more generally as "banded cubes" is yet
+    another level of complication which I will not attempt... yet).
+  fizzle and spiral erase modes ported from xscreensaver thanks to
+    Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+  showmodes.sh fixed... need nawk or gawk not awk
+  loop now has a mechanism to realize when the lifeforms are dead.
+    Still some futile life is not caught (i.e life that will eventually
+    repeat itself).
+  A way for users to unlock each others display.  Kind of defeats
+    the lock but the unlocked user is mailed and and entry is
+    written to syslogd.  Thanks to Mark Kirk <mkirk@pdi.com> for
+    his vizlock-1.0 patch.  Compile-time switch for this is GLOBAL_UNLOCK.
+    This is probably full of security holes when enabled... :)
+  decay update.  Now does not show user screen by default.  +hide will
+    decay the screen.  Also want to update it so that it randomizes the
+    position of the screen in the little password window when +hide is used.
+  bug mode bugfix (fixed a rare segmentation fault) thanks to
+    Mike Coleman <mkc@kc.net>.
+  Cleaned up a warning in invert mode and some extra files.
+  mandelbrot update by Tim AuckLand <tim.auckland@corp.sun.com>
+    -binary  Modulates the colours to indicate the "Binary Decomposition"
+       of the exterior of the mandelbrot set.
+    -dem  Instead of displaying 'escape times', display an estimate of the
+        distance between the point to be coloured and the set.
+  xpm modes should refresh better now when the colormap changes.
+  decay and lyapunov taken out of unstable category.
+  lament changed for latest MesaGL version, text3d updates for fortunes
+    thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl>
+  Red and Blue swapped for -use3d to conform with my glasses from Sun,
+    National Geographic, and Insight.
+  Colormap problems fixed when two xlock (with -install) run (this can
+    happen if xautolock is running and you lock the machine manually)
+    thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl>
+  New space mode from <Vincent.Caron@ecl1999.ec-lyon.fr>.  Probably will
+    combine the best features of star and space for a new star mode.
+    You must compile it in with --enable-unstable even though it seems
+    to be stable...
+  Changed my e-mail address to bagleyd@tux.org... the old one will still
+    work (as long as the new one does).
+
+4.13
+  kumppa patch (kumppa wrote only to the right quarter of the screen) and
+    make.com fix thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl>
+  lyapunov array bounds read error fixed.
+  New option "-/+description" on by default.  Now can turn off description
+    of mode above password window.
+  crystal and tetris more xscreensaver more compatible (did not test it
+    using xscreensaver).
+  PAM ignored allowroot option, fixed by Sven Paas <Sven.Paas@t-online.de>.
+  Bernd 'Bing' Leibing <bernd.leibing@rz.uni-ulm.de> fixed a compile bug
+    for logout.c that I introduced in 4.12.
+  I got a patch from Andrew Sumner <asumner@netmap.com.au>.  This provides a
+    a way (simple edits to mode.h) to excluding unwanted modes.  This is a
+    global change to all modes (especially random) except the blank mode.
+    Also affected are mode.c and mode.h.
+  Lost bees now caught in flow thanks to original author Tim Auckland
+    <Tim.Auckland@Sun.COM>.  This caused problems on VMS and probably
+    would happen on BSD systems.
+  lypapunov mode added.  It is really slow.  The way it is now -count is
+    set at 600 (4000 is recommended for a high quality picture but this
+    takes a real long time).  So far its only available as a unstable mode.
+    Needs a way to speed it up (Sci Am recommends a table of logarithms).
+    Now with random forcing strings.  (Hexadecimal representation shown with
+    -verbose).
+  Fixes for invert for pgcc compiler thanks to Tomasz Sulej
+    <tay@inferno.mikrus.pw.edu.pl>.
+  Thanks to Dan Stromberg <strombrg@nis.acs.uci.edu> for his update to
+    mandelbrot.  It now does subregions.
+  lament problems with multiscreens fixed and kumppa problems fixed by
+    David Hansen <dhansen@metapath.com>.  He also noticed problems with
+    life1d.c (SEGV'd in a malloc from XCreateGC), I have not been able to
+    duplicate the problem).
+  Found bug in xjack.  When in small window a divide by zero would occur.
+    Taken out of unstable. 
+  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> his new tetris mode.
+    It now extensively remodeled after altris.  Taken out of unstable.
+  Thanks to Tom Schmidt <tschmidt@micron.com> various fixes and leaks to
+    rubik, lament, invert, text3d, flow, decay, and tetris.
+    Also found problems with gltt which hopefully will be handled by the
+    gltt maintainters.
+  Thanks to Kenneth Stailey <kstailey@disclosure.com> for his "hiv" add-on
+    to dclock.  I also added my personal hang-ups "lab" (research animals)
+    and "veg" (consumed animals).  Upgraded the last 2 to work off current
+    year to get rid of arbitrary start year of 1970.
+  decay mode from xscreensaver thanks to Peter D. Gray
+    <pdg@draci.its.uow.edu.au> but it does not work yet.
+    Proabably will add a nondefault uption where it will use your current
+    image on screen to play around with.  New compile-time option to
+    activate: "CHANGEME".  Have not tried it yet my machine is real slow. 
+  Fixed -fullrandom for multiscreens.
+  Cool flow update by author Tim AuckLand <tim.auckland@corp.sun.com> .
+    A camera is attached to one of the trained bees and Duffing's forced
+    oscillator added.  And multiscreen fix for tetris.
+  Configure updates
+    Various warnings about shadowing and prototyping removed.  Removed -Wall
+    on gcc since it creates too much noise.  Will use it privately though.
+    configure now assumes latest version of GL for lament.  configure switch
+    does not seem to work on my Sun.  Also added a switch for conditional
+    compile and link C++ code but not sure how to get it to work in configure
+    (see top of configure.in).  (This introduces problems in make.com which
+    will soon be addressed.)  I fixed the compile without --enable-unstable :).
+    Took out lament and invert from unstable and put in xjack (partially
+    put in before) and tetris (not that its unstable but it needs a lot of
+    work).  Put it a warning if your using --enable-vtlock that it is a
+    pretty big security hole.
+    Update for bsd from Thorsten Frueauf <frueauf@ira.uka.de> 
+  New lifeform for loop.  I am not sure if its ever been done on a
+    hexagonal grid (Nov 02 1998).  The hexagonal grid to be is slightly
+    more life-like since it maximzes a cell's area while minimizing its
+    perimeter.  (Currently working on a triangular version in a hex grid).
+    Run xlock with the following "-mode loop -neighbors 6".  Its cells use
+    6 states.  Beware, this option is very liberal about declaring memory.
+    Its not clear whether this lifeform for will survive on the infinite
+    plane forever or choke on its own waste.  loop made them more bomb
+    proof similar to wire.
+  Thanks to <rastlin@rast.lodz.pdi.net> for pointing out that if DEF_PLAY
+    is used it could be made to overflow.  Fixed, not a security issue though.
+    Another possible overflow in iostuff.c fixed (Jouk also fixed it too).
+  Thanks to <tim.auckland@corp.sun.com> for his fix for multiheaded bug
+    for starfish and link now uses thc CFLAG settings.  There should not
+    be calls to release_starfish in draw_starfish.
+  Thanks to  Tim Rowley <tor@cs.brown.edu> for his new mode "invert", a 
+    demonstration of turning a sphere inside out without  creating  any kinks
+    (two surfaces can occupy the same space at the same time).
+  wire upgrades made more bomb proof... possibly an issue on a multihead
+    monochrome.
+  make clean should now work if ../configure is run in say xlockmore/linux.
+  Thanks to Kevin Vajk <kvajk@ricochet.net> for his fix if Xresources
+    contains "xlock.mode: Something_really_long..." xlock would memory fault.
+  Thanks to Remi Cohen-Scali <remi.cohenscali@pobox.com> and Eric Lassauge
+    <lassauge@sagem.fr> and Jouk Jansen <joukj@hrem.stm.tudelft.nl>  for
+    updates to text3d and configure for text3d.  Also "*.h" files upgraded
+    to handle C++ better.
+  Thanks to Remi Cohen-Scali <remi.cohenscali@pobox.com> and Eric Lassauge
+    <lassauge@sagem.fr> for vtlock upgrade.
+  Thanks to <todd.miller@courtesan.com> for his signature patch if
+    a file has a NUL without a newline.
+  Added -showplanes for hyper.  Option looks real bad now but it may be
+    improved upon later.  All the planes that include the origin are shown.
+  Port of xjack.c from xscreensaver by request.  Most of the delays removed.
+  configure change, added afs for Solaris
+  configure change, removed --without-gcc, now just set CC before running
+    configure.
+  configure changes for app-defaults and X11R6.3
+  configure and util.c change for usleep for Ultrix.
+  text3d updates for AIX from Jouk Jansen.
+
+4.12
+  crypt(3) requires strings to be null-terminated.  The 3rd character
+    should be null.  Does not matter for most implementations.  Thanks to
+    Bill Fenner <fenner@parc.xerox.com>.
+  configure fix for afs thanks to Charles Hines <chuck_hines@vnet.ibm.com>.
+  configure fix for group shadow on linux.
+  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> for the port of starfish
+    and kumppa.  starfish must be enabled (using configure --enable-unstable)
+    to use... found unstable on multiscreens and possibly TrueColor.
+    Multiscreen error (seen on Xnest and real multiscreens):
+      X Error of failed request:  BadMatch (invalid parameter attributes)
+        Major opcode of failed request: 2 (X_ChangedWindowAttributes)
+    On TrueColor it sometimes says it can not get all the colors.
+    Also did the dclock Dutch translation.
+  -fullrandom in 4.11 is confusing so I made it a special option under the
+    random mode.
+  Now can use g++ on Linux.  Working on SunC++.  Many stupid warnings
+    removed.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for his genlauncher.
+    This tool (in etc) should help me maintain xlock.  Still needs some work.
+    (java, dt stuff)  also in xalock and xmlock the #ifdef stuff gets
+    stripped.  Also created a new configure.tcl .  Also did the French
+    translation for dclock (accents were not available at the time).
+  goop -count now has some effect.
+  kaleid option for qix.
+  Allow customization of .Xresources.  If using configure uncomment
+    CUSTOMIZATION  part after running configure in config.h .  Thanks to
+    Robert Bihlmeyer <robbe@orcus.priv.at> .  I personally would rather
+    "xlock -display whatever:0" to work as it does in the original.  If
+    someone else thinks this default should change ... let me know.
+  Thanks to Tom Schmidt <tschmidt@micron.com> various fixes and purify report.
+    Patch for root with no password... not allowed to unlock... could this
+    be a problem?  Added verbose fix to color.c stuff.
+    Also several fixes for bubble3d on SunOS, now considered stable.
+  kumppa leak fixes and starfish leak fixes  (one starfish leak remains?)
+    Thanks to Jouk Jansen and Tom Schmidt for finding -bitmap leaks.
+  Thanks to Remi Cohen-Scali <remi.cohenscali@pobox.com> and Eric Lassauge
+     <lassauge@sagem.fr> for:
+    vtlock: xlock now VT lock switch when using -vtlock option. This is
+          enabled for linux with the --enable-vtlock option of configure.
+          This may or may not work on some versions of Linux, for example
+          it does not work on the maintainers machine. :(   (His latest
+          did not make it in this release but tries to take care of the
+          potential problem of "locking" a vt while another one is active
+          (if using xautolock and two X servers for example).)
+          I recently changed this option from lockvt to vtlock so I would
+          not be confused.
+    configure: add autodetection of MesaGL links (pthread/glide/vga)
+          Autodetection of pthread caused xlock not to run for the maintainer
+          so it was commented out. 
+    language: configure can select the lang used for elapsed time display.  A
+          grammar/syntax problem have been fixed in French language.
+          The option selecting the language is --with-lang in configure.
+    xglock: configure can search for GTK+. Makefiles are now generated in
+          xglock if GTK+ is found. xglock have been adapted to gtk+-1.0.4.
+          It is under development.
+    ORIGINAL_XPM_PATCH:
+          the ORIGINAL_XPM_PATCH define enabling the pixmap icon mail can
+          be activated in configure with --enable-orig-xpm-patch option.
+    bubble3d: this mode now has now randomly colored bubbles.
+    text3d: compile with -DUSE_TEXT and GL but need g++ and the gltt lib.
+          configure not set up for this so edit the generated Makefiles.
+          This version works better but the Animate function needs still
+          some work.
+  More language stuff added in resource.c .  It needs a few more German
+    translations and other languages too (besides French and Dutch).
+    To do more, each mode description would need to be translated.  I
+    currently think that would be hard to maintain, but I will not turn
+    down a patch (to mode.c) on this if someone really wants to have this.
+  atlantis should no longer flash.
+  Fix for shadow passwords if the user no longer exists.
+  popex (population explosion) and forest (tropical deforestation) options
+    for dclock... really depressing.  See dclock.c for where I get my
+    numbers.
+  Fade out converted from xscreensaver by Jouk Jansen.  Still to do:
+    -fade out the session at xlock startup
+    fixed one, squaretate to draw with more granualarity so it would
+    not be so slow on my slow machine.
+  Update to crystal by  Jouk Jansen to cycle colors like starfish.  (Name of
+    option changed from -cycle to -shift so +cycle would still work on
+    starfish.  Next version the maintainer hopes to have time to fix this...)
+  hyper -use3d.  Too bad humans only have 2 eyes...  otherwise I would add a
+    -use4d option and have it default to use green cellophane
+  -popcorn option on hop works but the output seems different then a picture
+     from my copy of Scientific American.
+  mandelbrot update by Tim AuckLand <tim.auckland@corp.sun.com>
+     changed from cut-off radius from 2 to sqrt(13) to improve resolution.
+  Fix for julia has some initialize errors... pixels in upper left corner.
+  Fix off by one error in triple_wipe.
+  Fix for -fg red -bg green ... fading does not work here.
+  starfish taken out of unstable since it is fixed for multiscreens.
+    Similar changes for kumppa and crystal.
+  Fix for the following:
+    xlock -mode random -modelist image -bitmap /nonexistant/ 
+      xlock: caught signal 11 while running image mode (uid 561).
+    xlock -mode random -modelist image -bitmap /nonexistant
+      could not read file "gublety-gook"
+  Converted Jamie Zawinski <jwz@jwz.org> lament to xlockmore.
+    This mode I just got working, so you need to configure with
+    --enable-unstable .  Needs OpenGL1.1 ... configure and Imakefile assume
+    it for now.  Beware of opening doors...
+  Also stole Jamie Zawinski's neat depend/distdepend stuff.  This gives
+    errors if setup on linux.  If setup on Sun (make distdepend after a
+    normal configure) it seems fine.
+      makedepend: warning:  ../xlock/xlock.c: 13:
+        # error architecture not supported by the Linux C library
+  Took out xalock from building by default.  configure gets tripped up
+    by a Sun include file of the same name.
+  kumppa now changes direction by -cycles 1000 .
+  Fixed up distdepend and reorganized dependencies to be the minimum necessary.
+  crystal, starfish, kumppa fixes for -mono and +install .
+  automata modes to have borders when -neighbors 4 or 8 since the others have
+    them.  ant's squares should really be square now.
+  Thanks to Marcelo F. Vianna <m-vianna@usa.net> for his new version of
+    rubik.c .
+
+4.11
+  atlantis mode thanks to Eric Lassauge <lassauge@sagem.fr> ported from
+    Mark J. Kilgard of Silicon Graphics.
+  kaleid thanks to Robert Adam, II  <raii@comm.net>.  -fullrandom
+    capability added thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+    kaleid is a totally new version.  Make sure you reinstall XLock.ad.
+    May resurrect the old kaleid in qix?
+  bubble3d mode thanks to Richard Jones <rjones@orchestream.com>.
+    Not sure about the name... bubble is taken and bubbles is taken in
+    screensaver ... original name was glbubble.  Seems to give problems
+    on SunOS so it must be enabled (using configure --enable-unstable)
+    to use.
+  hyper mode thanks to John Heidemann <johnh@isi.edu>.  This was built
+    independently from hyper.  I did not understand some of the color stuff
+    and through it away in the name of speed (quick coding and quick exec).
+    Took move_line from the xscreensaver port.
+  -fullrandom added to mountain, triangle, and petal for wireframe the first
+    2 include a joke... mixed wireframe/solid
+  Yet another try to solve the  colormap problems with fvwm and tvwm.
+    New compile-time option for this COMPLIANT_COLORMAP.  Currently this
+    is off by default since this fails on TrueColor.  (See config.h[.in]
+    for more info).
+  Fixed white background on goop with +install.  Also some day I have to add
+    back some of its xscreensaver options.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for his improved
+    xlock.tcl .  He is also starting a configure.tcl... do not expect it to
+    work yet. ;)
+  Thanks to Tom Schmidt <tschmidt@micron.com> for fixing up the mailCmd to a
+    later point in the password screen since it could take several seconds
+    to run with the mail automounted.
+  Thanks to Jamie Zawinski <jwz@jwz.org> ansi and mono fixes for flow.c.
+    Jamie also fixed global -no- options in xlock when compiled under
+    xscreensaver.
+    Fixed some compilation problems when compiling in xscreensaver.
+    glx stuff is now in sync with xscreensaver-2.17.
+  multiscreen fix for DT.  Sometimes it uses the DefaultScreen and sometimes
+    it uses all its screens.
+  Bug fix, food for bugs not updated.
+  configure fix for Linux and shadow thanks to Robert Bihlmeyer
+     <robbe@orcus.priv.at> .
+  new ant.  Size does not get too small except if the user wants it or there
+     is only a small space (iconified).  -sharpturn option mainly for
+     neighbors = 6 but also works for 12.  This new option easily degenerates
+     bees/ants to create highways.  Also worked on getting the truchet
+     lines better... still not perfect.
+  fullrandom option now defaults on... this will probably cause confusion
+    when certain options are selected but most users probably do not run it
+    with options anyway.
+  batchcount depreciated ... it still works but not as a resource.  Use
+    count.
+  xscreensaver/xautolock problem found.  If using a xlock executable with
+     xscreensaver see xlock/vroot.h .
+  lisa looks a little better.  I messed up the refreshing... oops.
+  If saturation not 1.0 it will run out of colors frequently if the colormap
+    is constant... I now retry it as 1.0.  (No COMPLIANT_COLORMAP).
+  Fix for BSD_AUTH thanks to Douglas Berry <doug@monk.cancom.net>.
+
+4.10
+  goop mode added from xscreensaver.
+  color background stuff changed around... did I get it right yet?
+    I think the biggest outstanding problem is fvwm[2] and that I may not
+    have much control over since it does not let me install the colormap for
+    the whole screen. 
+  color background reset for shape so it does not screw up other modes.
+  Solaris configure fixes by Tom Schmidt and David Bagley (Imakefile may
+    need some work)
+  xlock.c and random.c modified to allow -inwindow to pop up only once in
+    a multiscreen and work from :0.1.
+  Release code patches for bug, life, life3d, triangle, voters, and wator
+    to get it to work with the new -inwindow.
+  Thanks to Eduardo Santiago <esm@lanl.gov> for his -enablesaver fix broken
+    probably in 4.06.
+  -inroot refresh problems, clear window was added to refresh
+    ant bat bouboule bounce braid bug clock dclock deco fadeplot flag forest
+    galaxy grav helix ico image julia laser life life3d lisa lissie loop
+    marquee maze mountain nose pacman petal pyro qix roll rotor
+    shape sierpinski spiral star swarm swirl triangle
+    vines voters wator wire world worm
+    Also debounced some modes since they now need a "painted" variable.
+    ant, ball, bug, crystal, helix, life, life3d, lissie,
+    petal, voters, and wator.
+      deco, marquee, nose could be better too.
+  debounced puzzle.
+  bug more interruptable.
+  xmlock and xalock patched to display black screens.
+  "xlock -sound -lockdelay 1" fixed so there is no overlapping sounds.
+  Thanks to Michael Duane <mduane@metapath.com> for his check mail patch.
+    New options added -mailCmd,  -mailIcon, -nomailIcon.  A sample
+    check mail is supplied (by Michael) in etc .
+    Original patch used XPM.  The code is still there under
+    ORIGINAL_XPM_PATCH, uncomment in xlock/mode.h.  This has some colormap
+    problems.
+  Thanks to David Leigh <dleigh@us.ibm.com> for his AIX DCE password patch.
+    Suggestions in README for compiling.
+  Replaced MI_WIN_* with MI_* .
+  Changed many references from batchcount to count.  -batchcount is still
+    used... could not figure out how to have them both work.
+  xlockmore can now be is dropped into the main xscreensaver directory and
+    have its modes compile for xscreensaver.
+    Sync'ed up these modes from xscreensaver-2.16:
+      ant bouboule braid drift fadeplot forest galaxy grav
+      hop[along] ifs julia laser lightning lisa lissie mountain
+      penrose rotor sierpinski slip sphere spiral strange swirl
+      triangle vines worm (flag has diverged)
+    Various new line width improvements from jwz:  braid size option,
+    rotor size option, and lisa randomized linewidth.
+    Currently all xlock modes (but random) will compile in xscreensaver.
+    mandelbrot and tube will NOT run yet.  The xpm stuff and program
+    option of marquee and tube still need to be improved too.
+    Could not figure out how to get -no-fullrandom to work if
+    "*fullrandom: True \n" is set in the mode.
+    xlockmore is dropped into the main xscreensaver directory.  See README
+    in xlockmore/xscreensaver for more info.
+  Split out utils.c stuff to util.c random.c automata.c iostuff.c.
+    Also changed  visual.c to vis.c .  This is all in the name of
+    more xscreensaver compatibility.
+  Name changes
+    -imagefile -> -bitmap  xscreensaver capability...
+    -messagefont -> -planfont  probably not used too much anyway
+    -mfont -> -messagefont  goes along with -message...
+    (This is not compatible with xscreensaver but true compatibility required
+    too many changes...)
+  Thanks to Tim Auckland <Tim.Auckland@Sun.COM> for 3 new fractal modes
+    discrete, flow, and thornbird.  Also wrote a wrapper script that
+    may give better performance when using java or netscape... set
+    etc/xlock.sh .  Also -name fix.
+  Problem with bomb on 24 bit screen on Solaris 2, same as deco problem,
+    "fixed".
+  Multiscreen error when -geometry is used.  Password screen size would be
+    set to the last screen, fixed.
+  Thanks to Yoav Yerushalmi <yoav@mit.edu> for Kerberos fix.
+  -wireframe options added for mountain, petal, and triangle.
+  bad memory reads fixes on ant and thornbird thanks to Tom Schmidt
+    <tschmidt@micron.com> and Purify.
+  Fixed a bug with penrose where it would stop drawing if clicked a few
+    times.
+  DPMS (Display Power Management Signaling) Monitor patch thanks to
+    Matthew D. Rench <mdrench@mtu.edu>.  I guess it would make sense to
+    run xlock with +enablesaver when your using these new options.
+    Info for man pages obtained from http://www.randomc.com/~dperr/dpms.htm .
+  Fixed program default message bug for marquee and nose when compiled in
+    xscreensaver.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for his improved
+    xlock.tcl .
+
+4.09
+  Fixed some white background problems.
+  Fixed flag free bug.  Showed up on Linux and possibly to a lesser degree on
+    all BSD varieties.
+  shape "fix" on 15/16 bit displays on Linux.  Took away stippling on Linux.
+    It will be back when it does not crash.  Also added borders and shadowing
+    on shape.
+  Thanks to Yoav Yerushalmi <yoav@mit.edu> for adding new resources:
+    logoutCmd, startCmd, and endCmd.  Also patched up the .xlockrc stuff
+    as a fallback when using Kerberos.
+  Thanks to Alexander Knoll <alexander.knoll@hl.siemens.de> for adding a patch
+    for xlock to switch to blank mode if a SIGUSR1 is detected and back if
+    SIGUSR2 is detected.  This is useful if one wants to used a load sharing
+    facility and does not want xlock gobling up precious CPU time.
+  qix modified to handle polygons.  geometry.c merged in with a -complete
+    option (and with -fullrandom).  geometry.c removed.
+  resource.c changed.  Null strings are no longer malloc'd.  life, life3d,
+    getText (used in marquee & nose) fixed to compensate for this.  This
+    fixed an annoying but tiny (1 byte) leak.
+  ncolors on all modes should now be 64.  There may be a problem on linux
+    (involving libc6?) BadValue on X_PolyPoint.
+  Added LESS_THAN_SOLARIS2_5 switch so that gcc could compile xlock.c.
+  xlock -help should not need -remote option if running xlock remotely.
+    This was moved for the modules stuff that I have not got working.  This
+    bug is still present for modules, if it works.
+  Implemented USE_MULTIPLE_USER for acceptance of multiple passwords to unlock
+    similar to USE_MULTIPLE_ROOT. 
+  +install now works again... broken in 4.08.  I recommend -saturation 1.0
+    when running in random mode so you get less mono modes.
+  Weeding out of ".", ".." `files' fixed for imagefile in UNIX.
+  -sequential now goes more alphabetically.
+  SYSV patches for VMS thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+  Image directories no longer need a final slash for -imagefile.
+  Fix when compiled with logout button and used in dtsaver on a 24 bit display. 
+  Finally fixed puzzle mode when moved off screen as in -debug or -inwindow.
+
+4.08
+  Patched up imagefile
+  Took out MAXSCREENS.  No multiscreen limit now.
+  Took out NUMCOLORS.  Put in ncolors as a mode option, range 2-200
+  Took out inital point in qix in the top left corner. 
+  Fixed closedown logout.  Display was shutdown before logout was running.
+  New crystal.c thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> and fixes
+    for AIX and VMS.
+  Fixes for TrueColor.  Major bug fix for writable modes and TrueColor.
+  -imagefile for pacman and eyes.  So far there is no xpm or ras.
+  Fixed up configure/Imakefile for Motif2.0.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for his improved
+    xalock and xmlock.  His new improvements use the -parent option.
+    That option does not appear to work for multiscreens, but I think
+    the fix should be on the xlock side.
+  Removed some gcc-2.8.0 warnings and a static variable in draw_flame
+    (usually not multi-screen friendly).
+  Fixed white screens on mono.
+  make.com fix for clean thanks to to Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+  bouboule.c and rotor minor initialize fix
+  coral, swirl, flag, braid, and strange leak and bad memory reads fixes
+    thanks to Tom Schmidt <tschmidt@micron.com> and Purify.
+  Thanks to Hiroshi Kawaguchi <hirosi-k@is.aist-nara.ac.jp> for his
+    multi-byte character patches for password prompt and marquee mode.
+    Set up using configure --enable-use-mb.
+  Lint warnings removed.
+  Flag patched yet again.  Default set back to xbm for image to get rid of
+    the annoying bad colors on the message part.
+
+4.07
+  Added ELF patch I received from Adam P. Jenkins <apj@twain.oit.umass.edu>
+    in January 96.  At the time it seemed like a lot of work to add and
+    maintain since I could not test it.  It needs more work to get it running.
+  Changed back some code in resource.c to allow for machines that have
+    dynamically allocated IP addresses.  Not sure if this was necessary now...
+  Added patch for SafeWord, not tested.
+  took out warnings about strdup in flag.c
+  removed g++ warnings in cartoon, crystal, mandelbrot, tube, and random.
+  Added hexlife rules to life, they both have known glider lifeforms...
+    (-callahan and -andreen options).  The callahan option is more developed.
+    May yet add gliders coming from top and bottom.
+  Changed around sigset_t on the Sun.  It may give lots of warnings on the
+    Sun but I think it will always compile this now.
+  -imagefile for each mode like batchcount.
+  Fixed swirl, tube, and mandelbrot with BadValue in X_QueryColors on
+    Solaris2.6.  tube and mandelbrot fixed when static colormap.
+    This "fix" probably caused swirl to error out with -forground gray (or
+    -background) -install, this was then fixed..
+  Changed default for -usefirst .  The default is now on.  I am amazed that
+    I have never done this before.
+  configure sometimes mistakenly sets up to use matherr then utils.c errors
+    out.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for his improved
+    xlock.tcl and a more wavy flag.
+  fadeplot was blank on TrueColor and there was a dot in the upper left.
+    This no longer happens but it no longer fades either.  Added more
+    variablity and release code.
+  deco fixed some round-off errors (if width or height odd).
+  ant's truchet mode turned off if size is small.
+  GL modes are not be compiled in at all if there is no GL, same for
+    cartoon and xpm.
+  sproingies, pipes, and gears caused a Bad match on X_GLXMakeCurrent
+    after their release code is run and am running it remotely.
+  deco was weird on TrueColor (Ultra2).  Strange repeated rectangles appear
+    in the first square (ie. top left) about 1/4 of the time.
+    gl modes are not always cleared when completed.  XClearWindow does not
+    work all the time. This led to MI_CLEARWINDOW* macros defined in mode.h
+    and used in all modes. 
+    (Fixed flame, turtle, and petal are blank on mono and with -mono ).
+  MI_PAUSE removed from all modes since it does not work on multiscreens
+    especially with above patch.
+  Modified xlock to give a blank screen the glx modes when GLX is not
+    supported by the screen.  This is good for multiheaded machines with
+    a monochrome and OpenGL.
+  Separate LDFLAGS in configure for xlock, xmlock and xalock.
+  -mode ant,bug is an error but should not Segmentation Fault.  Related to
+    the new -imagefile mode option.  Fixed thanks to David Hansen
+    <dhansen@metapath.com>.
+  Interrupts for short delays thanks to William Shubert <wms@hevanet.com>.
+    Delay for bouboule and swarm changed to compensate for this.
+    Currently backed out since it causes problems with random mode,
+    (USE_NEW_EVENT_LOOP). 
+  If -duration is fast, password screen now gets the text info about the
+    mode updated.
+  -neighbors option for wire mode.
+  Stippling for demon mode on mono.
+  Use of union for neighbors info.
+  Thanks to Tom Schmidt <tschmidt@micron.com> for adding "default" as a
+    visual name.
+  Separated escher into cage and moebius.
+  Changed the compile-time option USE_MOUSE_MOTION to a run-time option
+    -mousemotion.  Added a new compile-time option -DUSE_WINDOW_VISIBILITY,
+    which was suggested a while back (Heath Rice <rice@asl.dl.nec.com>),
+    allows one to have a window that sits on top of xlock. (This window must
+    pop itself in front if it gets a visibility event).
+  If xlock fails to get the encrypted shadow password it now attempts to use
+    the -cpasswd option, failing that $HOME/.xlockrc, failing that it queries
+    the user.  This way, you do not need to choose between to have it
+    as a compile-time option.  This is only used as a fallback.  -DUSE_XLOCKRC
+    still remains in case that default is prefered.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for his new mode, bubble.
+  Solved a bug in flag involving raster files.
+  -garden mode for daisy.
+  Thanks to Marcelo F. Vianna <m-vianna@usa.net> for his early version of
+    the stairs mode, ala Infinite Stairs.  It needs a bouncing ball on the
+    steps.... work in progress.
+  Configure changes for xalock, rplay, and nas.
+  fullrandom stuff for ant, bubble, daisy, and penrose.
+  AIXV3 fix for flag.
+  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> for his patches to utils.c
+    that allow imagefile to work with the random mode and can now use
+    wild cards to choose specific files in a directory. 
+  Thanks to Leonid V. Kalmankin <leonid@cs.msu.su> for his patch for the
+    3Dfx card.  It is not autodetected so FX must be uncommented in
+    config.h.in before running configure (or iconfig.h before running
+    xmkmf -a ).
+  -mode life -rule and -mode life3d -rule3d format changed.  It now
+    allows greater flexibility.  Groupings of symmetric neighbor patterns
+    are also possible in life.  So far this is only available for hexagonal
+    life.  Add -lifefile and life3dfile for the life and life3d.
+    They pretty much follow the simple #P format of xlife.
+file: glider.life (-rule S23/B3 -neighbors 8)
+#P -1 -1
+***
+..*
+.*.
+file: glider.hlife  (-rule S2b34/B2a -neighbors 6 (-callahan))
+#P -2 -2
+    . . O .
+   . . . O
+  O . . O
+ . . . O
+. . . O
+file: glider.3dlife (-rule S45/B5)
+#P -2 -2 -1
+.**.
+*..*
+*..*
+
+....
+.**.
+.**.
+  Added a bit more color to pyro.
+  Fixed MesaGL on TrueColor for modes with MI_WIN_DEPTH in them. 
+  KRB fixes thanks to Robert L. Sink <sinkr@cbl.umces.edu>.
+  PAM support thanks to Michael K. Johnson <johnsonm@redhat.com>
+   and Marc Ewing <marc@redhat.com>, use --enable-pam .
+  Obscure multiscreen bug fix
+     xautolock -time 1 -locker "xlock" &
+     xlock/xlock -mode qix -saturation 0.4
+    Caused a bad window because of a bad property.  This was traced back
+    to vroot.h... this stuff does not need to run unless inroot is true.
+  Fixed Makefile.in for BSD... hopefully.
+  Visual fix if GL is not installed.  Still not exactly right for xpm stuff.
+  tube and mandelbrot sometimes did not call XStoreColors correctly.
+  star fixes for multiscreens.
+  Will not exit out if someone did not set up /etc/hosts file correctly.
+
+4.06
+  Fix for floating point error in cartoon for DEC UNIX.
+  Assorted minor fixes.  Imakefile and Makefile.in fixes.
+  Thanks to Mike Kelly <tfsmiles@ecst.csuchico.edu> for fixing xlock on
+    xterminals (caused a buffer overrun ... not enough memory malloc'd).
+  In bug, bugs are now stippled on monochrome.
+  -modelist allxpm and -modelist allwrite for writeable colormap modes
+    added.   I kept it mutually exclusive... even though allxpm modes use
+    a writeable colormap (I'll change this if anyone thinks that it is
+    confusing).
+  Added a feature to my_fopen that allows creation of a new file.  Needed
+    for .xlockrc .
+  Added DEC, IBM, and SCO bitmaps and pixmaps.
+  Writeable colormap conflict should not bomb out xlock.  There will be
+    no graphics.  Not sure if the problem is in MesaGL but there is no
+    problem in OpenGL.  -debug will print out the error when hit.
+    This is fixed in MesaGL2.5 when its released.
+  Rearranged XVisualInfo and context stuff.  Should work the same...
+    May cause leaks if using < MesaGL2.5.  Hoped that it would fix above
+    problem... it did not.
+  Thanks to Dan Stromberg <strombrg@nis.acs.uci.edu> for mandelbrot.
+    Thanks to Tom Schmidt <tschmidt@micron.com> leak fix.
+  RAS and XPM added for flag, maze, life, and life1d.  Probably opened flood
+    gate for leaks...  flag and scream.ras does not work well yet...
+    probably some padding problem...  life and life1d still default to
+    bitmaps.
+  +resetsaver option added.  If using DPMS, XResetScreenSaver resets
+    power timeouts, which may not be desirable.  -resetsaver is on by
+    default.  Thanks to Michel Eyckmans <eyckmans@imec.be>.
+  New Prisoner's Dilemma automata mode, "dilemma".  Thanks to Tom Schmidt for
+    his leak fix.
+  New deco and coral modes stolen from xscreensaver. 
+  Hopefully fixed font bomb on bomb. 
+  New Purify logs from Tom Schmidt.
+  Fixed exposures on dclock, ifs, nose, and strange.  It could still be a
+    problem on coral if your machine is slow.  If you use -lockdelay it may
+    have to be lengthened.
+  Fixed some flashing on multiscreens for ifs and strange.
+
+4.05
+  Fixes for bat and ifs leaks.  Thanks to Tom Schmidt <tschmidt@micron.com>
+    for his purify report.
+  Fix for galaxy (floating point error on FreeBSD) with help from Bruce
+    Evans <bde@zeta.org.au>.
+  Changed configure so that -lgl is only for IRIX.
+  sierpinski in 3D thanks to Antti Kuntsi <kuntsi@iki.fi>.  -size 3 it will
+    have 3 corners and -size 4 it will have 4 corners... all others cause it
+    to pick 3 and 4 randomly.
+  Thanks to Tim Mooney <mooney@dogbert.cc.ndsu.NoDak.edu> for his patch to
+    configure for Digital Unix and using prefix to set the app-defaults
+    directory. 
+  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> for his new crystal.c.
+    Now all orthogonal unit cell crystals are represented (quasicrystals
+    are not).  Fix for bad memory access and refresh.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for his improved
+    xlock.tcl.
+  Modified Makefiles.in used by configure.  A make can be made in xlock and
+    modes/gl directories.  Should be OK now with BSD make but I have not
+    tested it.  Also added setuid and password stuff. 
+  XPM MesaGL conflict lock pick solved by having the iconified window to have
+    fixed colors.  This was added to fixedColors in utils.c .  Other writable
+    colormap modes were updated to handle this.  This also solves the problem
+    of the "black" password screen not being black.  This probably does not
+    fix the real cause of the problem...
+  Better color handling of OpenGL.  Still not perfect.  GL modes may look
+    bad in PseudoColor and tube and swirl (and bat, image, puzzle, and
+    cartoon with XPM) may look bad in TrueColor at least on a 8 bit display.
+  Many thanks to Jongki Suwandi <Jongki.Suwandi@eng.Sun.COM> who figured out
+    what -dtsaver does and how to use it.  See README.
+  Fix so that when DT changes the modes on xlock it does not cause errors in
+    the errorlog.
+  Pipes in the pipe mode going towards "near" and "far" should no longer be
+    invisible in OpenGL.
+  Put more shapes in tube.
+4.04
+  Thanks to Marcelo F. Vianna <m-vianna@usa.net> for speed ups in morph3d
+    Created the great new rubik gl mode.  D. Bagley made it a lot more
+    unreadable but also made it NxNxN.
+  fract name changed to vines. If batchcount is zero then each iteration
+    will produce a complete vine, otherwise it will produce a portion of
+    the vine.  Nice values for growing the vines to be -batchcount 100
+     and -delay 50000.  Thanks to David Hansen <dhansen@metapath.com>
+  Thanks to Tom Schmidt <tschmidt@micron.com> for his password window
+    patches for server name and mode descriptions.
+  Thanks to Christian von Roques <roques@pond.sub.org> for his galaxy speed
+    ups.
+  Thanks to John Gotts <jgotts@engin.umich.edu> for his syslog display patch.
+  Changed flag to allow it to change between image and message.
+  New directory structure.  configure still needs some more work to get
+    it to make from any internal directory.  configure should now get the
+    correct xapp directory.  Many "ideas" were taken from Jamie Zawinski's
+    xscreensaver.  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> for his
+    new make.com.
+  puzzle should no longer bomb out with BadMatch if in a window.
+    Thanks to David Hansen <dhansen@metapath.com> for handling the -inroot
+    case.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for starting 2 more gui
+    interfaces xalock, this time using Athena and libsx, and etc/xlock.java.
+  -parent <window id> patch to be used with -inwindow option.  This option
+    will be used on the GNOME project (http://www.gnome.org).  Thanks to
+    Radek Doulik <doulik@karlin.mff.cuni.cz>.
+  Added 12 and 6 bit for defaultVisualInfo.
+  Moved config directory to etc... imake could get confused.
+  Fixed color.c so that it could handle the case when all colors are used up.
+  sphere.c now can have the shadow in 4 different locations... it is randomly
+    chosen when init_sphere is run.  Fixed a bug if sphere was restarted. 
+  Fixed sierpinski and wire if there are only a few colors.
+  Fixed escher.c it had FALSE instead of "False" in 2 places and was
+    causing problems on 64 bit Digital Unix.
+  Fall throughs in case statements found on hop and ant.
+  hop would sometimes give a blank screen for a nonexisting hop.
+  hop now centered and scaled better.
+  ifs and strange are now reinitialized when refreshed... the size
+    of the window could have changed.
+  Ideas in DT workaround in README from Wade Wegner
+    <wwegner@surveyor.aae.uiuc.edu>
+  munch lifted from xscreensaver.
+  Thanks to Eric McDonald <e@aw.sgi.com> for his help on the SGI 12 bit
+    display.
+  Imakefile patch for SCO and Sun with OGL.
+  Configure patch for Purify.
+  Dave Prosser <dfp@sco.com> SVR4 random image patch.
+  allautomata, allspace, allgeometry add.  allstandard taken away.
+    This also puts stuff back in alphabetical order except the special
+    modes.
+  Password window username now displays host and display info.  Display info
+    only displayed if significant.
+  puzzle patched to handle bomb when batchcount was negative.
+  inline patch if set -ansi -pedantic .
+  More xscreensaver compatibility.  flag and others need a bit more work.
+  Added eyes and swarm mouse options, very similar to the julia code.
+  Patch for Solaris2.6 .
+  Fix, sometimes flags would have enough room to fly.
+
+4.03
+  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> for VMS GL patches and
+    new mode, crystal.
+  Thanks to Ed Mackey <emackey@early.com> for taking out some common code
+    to all GL modes and placed it in utils.c.  Also found BIG leak in
+    gears.c, rewrote sproingies (now handles more sproingies and have
+    better explosions and not have 2 sproingies generated from the same
+    spot at the same time).  Added many neat things to pipes.
+  Thanks to Tom Schmidt <tschmidt@micron.com> for his memory leak fixes
+    to xmlock.c and option.c.  More unresolved leaks and uninitialized memory
+    reads are noted in the source.  Handle matherr in utils.c.
+    Fixed uninitialized memory reads in pyro and worm for -use3d.
+  Thanks to Marcelo F. Vianna <m-vianna@usa.net> for speed ups in all gl
+    modes.  Removed conflict between pipes and superquadrics & sproingies.
+    Pipes to handle -inwindow better.  Created the great new escher gl mode.
+  Thanks to Jamie Zawinski <jwz@jwz.org> for
+    VMS hlp capability make -f Makefile.in hlp
+    braid spin can go the other way, flag font and image capability,
+    ifs and strange less flashy, julia mouse option, sphere draws all 4 ways
+    swirl debugged on 24 bit sgi... it needs 32 bits
+  Thanks to Curtis Larsen <larsen@rtp3.med.utah.edu> for a new improved
+    bounce mode when run in -inroot.
+  Thanks to Jeff Epler <jepler@inetnebr.com> for less tight turns in pipes.
+  Thanks to Scott Carter <scarter@sdsc.edu> for check that only regular files
+    are read in the .xlockmessage, .plan, .signature.  (Tom Schmidt did this
+    for all fopen calls except one :) ).
+    Tabs here are now interpreted.
+  Jason Larke <jlarke@psc.lsa.umich.edu> for his AFS patch so nonsence lines
+    in passwd or shadow do not cause the xlock to barf.
+  release code now called in finish originally written by Ron Hitchens
+    <ron@idiom.com>.
+  XSetScreensaver now only called if locking the screen.  Also able to turn
+    it off now in blank mode.
+  starting to remove the dependencies on MAXSCREENS and NUMCOLORS
+  bigcrypt added for HP secure passwords.
+  `xlock -mode spline -cycles 1 -erase` fixed.
+  boubloule bug solve using -use3d.  all3d modelist option added.
+  New mode added, voters.
+  life3d.c leak fix.
+  Lifeforms added P3 Question, P8 Asym, and P8 Smiley added from 
+    http://www.halcyon.com/hkoenig/LifeInfo/LifeInfo.html
+    life.c can now handle -neighbors 3, 4, 6, 8, 9 and 12.  New pointer
+    algorithm.  Hexagons for life, demon, & ant now look better.
+    wator.c can now handle -neighbors 3, 4, 6, 8, 9 and 12.
+  hop fix for multiscreens.  Most of xmartin2.2 algorithms stolen.  xmartin
+    was written by Ed Kubaitis <ejk@ux2.cso.uiuc.edu>.
+  a swirl fix for multisceens... one screen if larger than the other would
+     not reach its maximum size.
+  xmlock string options are now all in quotes.
+  bitmaps, pixmap and flag links are now no longer destroyed with a make
+    clean.
+  stderr is used for the VERBOSE stuff unless its informational stuff about
+    the mode as in ant and life*.
+  tube no longer changes fg and bg.  Should no longer bomb out on TrueColor.
+  Can now use Makefile to adjust SYSLOG stuff.
+  Found a bug in ant and galaxy fixed on the HP-UX 9.0.
+  Got rid of some flashing of the grelb on eyes.
+  Reinitialize qix lines on each init_qix call.  This gets rid of old lines
+    reappearing.
+  Added -imagefile option for bitmaps in life, life1d, and maze.   eyes and
+    pacman will require more thought.  flag now can have a runtime message or
+    use bitmaps.  Thanks to Jamie Zawinski.
+       Put random colors on the nose guy.
+       Added -grabserver option for unsecure SGI.
+  Bug in strcat_firstword fixed thanks to <Jeffrey_Doggett@caradon.com>
+    Fix for ":not found" text that appears after about 40 minutes.
+4.02
+  Logout patch for SUNOS4, galaxy and life3d leak fix thanks to Tom Schmidt.
+    inline and seteuid patches for configure and xlock.h.
+  flag-freebsd.h added.
+  First mode was not being released in random mode.  Fixed.
+  new ellipse code from Dan Stromberg <strombrg@nis.acs.uci.edu> (formerly
+    named trig) added to helix  (xlock -mode helix -ellipse).
+  -fullrandom option added to make xlock more random.  Thanks to Jouk
+    Jansen <joukj@hrem.stm.tudelft.nl>.  So far only drift, helix, hop, &
+    spline are set up.  Spline in -erase mode has cycles divided by 64
+    so it is compatible with +erase.  New options added to hop (-jong
+    and -sine).
+  Got SunC++, GnuC++, DECC++ errors and warnings out of xlock.c, passwd.c,
+    utils.c, logout.c, cartoon.c, clock.c, galaxy.c, life1d.c, turtle.c,
+    worm.c, bomb.c, fract.c, tube.c .  It still does not link.
+    GnuC++ was tested on Linux and Solaris.  Thanks to Jouk Jansen
+    <joukj@hrem.stm.tudelft.nl> for the DECC++ patches.
+  Thanks to Tom Schmidt <tschmidt@micron.com> for his memory leak fixes
+    to gears.c, mode.c, & resource.c.  MesaGL 2.1 has some leaks that were
+    reported to the MesaGL maintainer and fixed in 2.2.  Also fixed swirl,
+    and GL modes so they always default to the best visual.  Also added
+    -visual (available with hackers code).  gears and morph3d fixed to be
+    more random at start.
+       gears and morph3d multiscreen bug fixed by Brian Paul
+    <brianp@ra.avid.com> MesaGL creator.
+  Thanks to Massimino Pascal <Pascal.Massimon@ens.fr> for ifs and strange.
+  Thanks to Marcelo F. Vianna <m-vianna@usa.net> for morph3d and pipes.
+  Thanks to Dan Stromberg <strombrg@nis.acs.uci.edu> for tube.
+  Thanks to Caleb Cullen <CCullen@hal-pc.org> for lisa.
+       On Solaris, initial random mode was not random.  This was fixed by a
+    cast for SRAND.  Also updated references for seconds() from long or
+    int to unsigned long.  time(NULL) will exceed maximum signed int in
+    2038.
+  flag jumpiness and gears -mono fixed thanks to Ed Mackey
+    <emackey@early.com>  http://www.early.com/~emackey/sproingies/.
+    Sproingies and superquadrics GL modes and -wireframe option added.
+    "configure --enable-sproingies"    sproingies is not compiled in by
+    default since it may run VERY slow on some machines.  Also the -size
+    option may help you here (thanks to Tom Schmidt for this option).
+  Thanks to Tracy Camp <campt@hurrah.com> for fract with improvements by
+    David Hansen <dhansen@metapath.com>.
+  "Minor" security hole noticed by David Hedley <hedley@cs.bris.ac.uk>.
+    Minor in that the array is in the heap and not the stack, so it would
+    be tricky to write an exploit.  Patched up by David Hansen
+    <dhansen@metapath.com>.
+  Debian bug report fix Bug#8276: xlockmore: xlock -help should output
+    to stdout rather stderr, thanks to Heiko Schlittermann
+    <heiko@lotte.sax.de> for pointing it out.  xlock -version fixed too.
+  Debian bug report fix Bug#8406: app file was not being read when configure
+    was used.  Fixed.  Thanks to Herbert Xu <herbert@greathan.apana.org.au>
+    and Dirk Eddelbuettel <edd@rosebud.sps.queensu.ca> for pointing it out.
+  added allnice, allstandard, allstable to modelist choices for the
+    random mode.  Any mode that runs slower than star mode is considered
+    not nice.  If gl modes are compiled in, these are considered
+    nonstandard modes.  If hackers modes are compiled in, these are
+    considered unstable modes.  To get only GL modes try:
+      xlock -mode random -modelist allstable-allstandard
+    allgl works too if you do not want to type that much. :)
+  X11 ico added added dodecahedron, tetrahedron, and the star octahedron.
+    -face and other options were removed to ease port.
+  -resources now prints out the resources for mode options.
+  button-logout and auto-logout rearranged.  Also the logout button should
+    no longer overwrite your plan.  See "configure --help".  Note: 0 is a
+    special case and handled as infinity.
+  -icongeometry 1x1 fixes for bug, hop, and triangle .
+  fvwm2 menus thanks to James G. Feeney <james@albion.glarp.com>
+  Changed pause on multiscreens so that if pausing the second screen will
+    not override it.  Its not exactly right but I am happy with it for now.
+  Thanks to Charles K. Hines <chuck_hines@vnet.ibm.com> for fixing grav.c
+    bug, casts to unsigned int.
+  LDFLAGS used if using cc on Solaris.  There could be library problems if
+    setuid to root.
+       -neighbors 8 & 3 added to ant and  8, 3, 9, & 12 added for demon.
+  Fix on FreeBSD with xlock setuid and xdm for $HOME/.Xauthority thanks to
+    Thomas Gellekum <thomas@ghpc6.ihf.rwth-aachen.de>.
+  -sequential option for random.  Since the random mode is the most easily
+    broken... its good to have repeatability.
+
+4.01
+  Fix in xlock.c if the HOME variable is not set.  Fix in demon.c for
+    multiscreens thanks to David Hansen <dhansen@metapath.com>.
+  Security hole when xlock is setuid to root found by Richard Jones
+    <richard@a42.deep-thought.org> (this affects all previous releases).
+               Similar problem found by David Hansen <dhansen@metapath.com>.
+    Thanks to David Hansen for his solution of mallocing userfile,
+    appdefaults, modname, modeclassname, fullname, fullclassname, buf
+    variables.  Also the memory leak on line 831 of GetResources variable
+    classname is believed solved (David Hansen again).  In utils.c get_dir
+    "dir" and "filename" are forced to remain within the sizes of DIRBUF
+    and MAXNAMLEN respectively.
+  Thanks to Tom Schmidt <tschmidt@micron.com> for adding --enable-hackers
+    --with-includes and --with-libraries and patching up the handling of
+    Editres in configure.in .  A gears and tube bug patched.  Also
+    contributed new Purify report showing many problems with the GL modes
+    (gears and morph3d).
+  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> for the DECC patches.
+
+4.00
+  xlock.html thanks to vh-man2html .
+       Patch for SGI to kill the Xsgi process when using 4Dwm thanks to
+    Martin Ebert <hi17@iss.mach.uni-karlsruhe.de> and Phillip Moore
+    <phil@ERC.MsState.Edu>.
+  Fix for colormap stuff, swirl in random mode could crash xlock, error
+    made in ALPHA version.
+  Thanks to Alexander Jolk <jolk@ap-pc513b.physik.uni-karlsruhe.de> for a
+               update to lissie to handle -size .
+  Thanks to Sergio Gelato <gelato@spacenet.tn.cornell.edu> for a bug fix
+    for galaxy.
+  Fixed a "Bad Match" generated with random mode for multi-headed color
+    monitors using -install.
+  Thanks to Rick Ohnemus <rick@ecompcon.com> for patches to NAS sound
+    stuff. Typos were my fault.
+  I noticed a problem with Solaris2 and dirent.h .
+    xlock -mode image -imagefile ./bitmaps/
+    is supposed to pick a random file.  This mechanism does not seem to
+    work too well and may corrupt the filename when you give it a specific
+    file name.  Therefore for Solaris2, I compile without dirent.h.
+    Check out utils.c and grep on Solaris2 to see more...
+    One must give a specific filename on Solaris...  here
+    config/xlockrandimage.pl may help you.
+  Thanks to Charles Vidal <vidalc@club-internet.fr> for starting another gui
+    interface to xlock, xlock.tcl, in config directory.  Moved xmlock, the
+    Motif gui for xlock (also written by Charles Vidal), from hackers
+    directory.
+  Robert Duff <duffrd@aud.alcatel.com> patch to randomize the starting
+    color of marquee.  Same patch applied to blot, bouboule, braid, dclock,
+    geometry, flag, helix, hop, kaleid, julia, qix, roll, rotor, spiral,
+    spline, swarm, worm.  On bomb, life, triangle this was not done on
+    purpose and on others...  flame and lissie it was done already.
+  Leaks fixed in gears.c and bomb.c.  Purify was not used so there could be
+    others there.
+  dclock should work correctly in password window... i.e. it should not get
+    stuck, and randomized initial direction.
+  penrose.c  run with -verbose and it will tell you when it hits some
+    weirdness (about once an hour) "Dislocation occurred!"
+    If it says "Weirdness...." it would have terminated previously.
+  Updated make.com to use links instead of copies.  Thanks to Jouk Jansen
+    <joukj@hrem.stm.tudelft.nl>.
+  Thanks to Tom Schmidt <tschmidt@micron.com> for fixing the formatting
+    on the "hours elapsed since locked." message and logout patches.
+    Also for adding several options to configure.
+  Thanks to Tim Mooney <mooney@dogbert.cc.ndsu.NoDak.edu> for Digital Unix
+    (aka OSF1) for patches to the Imakefile.
+  Middle button fix and monochrome random mode fix for multiscreens.
+    Multiscreen patch for marquee and nose.
+  Updated xlock.h not to have a \ at the end a line with a #if.  VAXC chokes.
+  Updated size and batchcount in ball and size in pyro.
+  Updated mode.c for maze.  Incorrect if XLock.ad was not installed.
+  Updated turtle.c.  Incorrect HARTER_HEIGHTWAY mode and float casts to int
+    to please the VMS god.
+  Updated ant.c to handle more kinds of ants.  Thanks to J Austin David
+    <Austin.David@tlogic.com>.  Check out http://havoc.gtf.gatech.edu/austin
+  Hackers modes moved to main directory.  cartoon.c may be kind of flashy
+    with -install and without it you might not get any cartoons.  Looks OK
+    on monochrome.
+  audio stuff for VMS is in config directory.
+  Updated grav compile-time options now runtime options-> -decay and -trail.
+  New "-version" option now pulls the version from version.h.  Also added a
+    more verbose option "-verbose" for maximum verbosity.  -v now gets
+    version instead.
+  New "-sound" option added.  It is off by default.  If on it will only work
+    if RPLAY, NAS, VMS_PLAY, or DEF_PLAY are used at compile-time.
+  "Feature" where truncated mode names were accepted, such as "-mode s" now
+    give an error.  It did not work well anyway (above example ran shapes in
+    monochrome).
+  Thanks to Alexander Lehmann <lehmann@mathematik.th-darmstadt.de> for adding
+    backspace capability Control-H for marquee (but not with -message).
+  configure is now used.  At this stage the Imakefile is still probably
+    more reliable.  The Makefile.[acc hp std sun] are no longer supported.
+    (But are in config for reference).  The Imakefile and make.com are still
+    supported.  imake has fallen out of favor with me.  imake is sometimes
+    not configured well, its make depend is confusing (some systems it is not
+    required), and cumbersome (and ugly) "@@\"'s are used to do more
+    complicated things.  And it is not installed on some HP's.
+    A few things have been added for configure, but NOT used with Imakefile
+    or make.com:
+      config.h.in -> config.h  when "configure" is run.
+        This file is where the users options are stored.  These may depend
+        more on the administrator/user than on the system, but some options
+        are not available on some machines.  See "configure --help".
+        If this file is modified... a "make clean" should be done unless you
+        know what your doing.
+      Makefile.in -> Makefile  when "configure" is run.
+      configure.in -> configure  when "autoconf" is run.  Note: autoconf is
+        a GNU product that may not be installed.  This is need only if you
+        update configure.in .
+     Although there is some VMS support features in Makefile.in... full
+       support for MMS, MMK, or VMS-GNU-MAKE is not there yet.
+
+3.13
+  loop.c added, it is not exactly a screen saver, but it demonstrates
+    self-production.
+  turtle.c added.  Recursive turtle graphics.  The only one that works
+    at present is the Hilbert curve (which is may not exactly be
+    a turtle curve... but close enough).
+  Thanks to M G Berberich <berberic@forwiss.uni-passau.de> for .plan and
+    .signature stuff and purify log.
+  bomb and signature updates for VMS thanks to Jouk Jansen
+    <joukj@hrem.stm.tudelft.nl>.
+  flag fix for negative size thanks to <Mark_Buglewicz@itd.sterling.com>.
+  MULTIPLE_ROOT & passwd in compat mode bug fix and NAS sound patch bug
+    fix thanks to Dave Smith <drs@aeolians.bt.co.uk>.
+  Thanks to Tom L. Schmidt <tschmidt@micron.com> for purify logs.
+  Many leaks patched thanks to Purify!  grep on "PURIFY" to find
+    unresolved leaks.  Purify file is in the docs directory.
+  2 problems in the Imakefile cleaned up thanks to Simon Josefsson
+    <jas@pdc.kth.se>.
+  Patch to allow marquee to handle extended character set >=128
+    Alexander Lehmann <lehmann@mathematik.th-darmstadt.de>.
+  XPM files now work with -install (thanks to XPM maintainer Arnaud
+    Le Hors for pointing me in the right direction).  Managed to reserve
+    black and white, but not fg and bg does not work.  Sometimes in random
+    mode the colors are not mapped correctly.
+  -geometry should now work again without excessive refreshing.
+  Refresh update on image.c.
+  ball, julia, roll in the hackers directory are probably ready for
+    prime-time but have not been BETA tested.
+
+3.12
+  swirl will cause xlock to dump core or CRASH OS within 50 repetitions
+    when run in random mode, fixed.
+  xlock -mode tri -mono  dies, fixed.
+  xlock -mode swirl +install  with netscape (stealing colors) running
+    is even less reliable, fixed.
+  daisy and slip are sometimes in red when there are no colors left, fixed.
+  After the delay has expired the first button click only redraws the
+    current mode.  It then takes a second click to activate the
+    password display.  Fixed thanks to David Hansen <dhansen@metapath.com>.
+  Individual -size option added (like batchcount).  -gridsize removed.
+    If 0 it will use the bitmap if available.  If negative it will be
+    random from 1 to -size inclusive (like batchcount).
+  Combined star mode with rock mode.  rock mode removed.
+    -trek, -rock, -straight options.  Star Trek features by Heath Rice
+    <rice@asl.dl.nec.com>.
+  dclock updated offscreen so there is no annoying flashing.  Originally
+    submitted by Michael Stembera <mrbig@fc.net>.
+  bomb mode back... but its essentials are NOT compiled in by default.
+  Patches for SUNOS_ADJUNCT_PASSWD thanks to Mark Buglewicz
+    <mark@itd.sterling.com>.
+  Many modes patched that did not initialize the redrawing variable.
+  Demon bug solved when alternating between iconified window and normal
+    window.
+  mountain patched so it would not be so slow.
+  life1d much improved.  It now has a fade out if it is found repeating.  
+    Now can break without it completing a whole screen.  -totalistic
+    option added (+totalistic -> LCAU collection instead).
+  Updated clock to use batchcount  (i.e. many clocks) .. if there are too
+    many collisions it will draw less clocks.
+  Thanks to Rene' Driessen <rdr@crys.chem.uva.nl>
+    xlock -mode puzzle -mono ( -inwindow | -debug )
+    will get a Bad Match if obscured (but still errors out if moved off
+    screen).
+  Updated modes to use size instead of batchcount... clock, flag,
+    maze, penrose.
+  Updated modes to use size instead of cycles... bouboule, star.
+  Updated modes to use size instead of worm's CIRCSIZE, and galaxy's STARSIZE.
+  Updated other modes to use size bat, bounce, ant, demon, life1d, life,
+    wator, wire.
+  galaxy bug on VAX now gone... not sure why...  Disappeared when I added
+    temporary sin and cos calculations for efficiency.
+  Thanks to Dr. George D M Ross <gdmr@dcs.ed.ac.uk> for SYSLOG (xlock.c)
+    and NETGROUP patches (logout.c).
+  Thanks to Gabor Herr <herr@iti.informatik.th-darmstadt.de> for pointing
+    out that uid and gid privileges should be taken away unconditionally
+    after the encrypted password is grabbed.  Otherwise, it may lead to a
+    major security hole depending on how it is installed.
+  xmlock.c added to hackers directory.  Thanks to Charles Vidal
+    <vidalc@club-internet.fr> for starting a gui interface to xlock.  Feel
+    free to improve upon it, but mail me your diffs.
+  -DUSE_HACKERS compile-time option added (cartoon.c took a step back,
+    nobody's fault but mine).
+  ant mode with -truchet memory leak found.  Refreshing improved.
+
+3.11
+  Ron Hitchens <ron@idiom.com> Updated xlock so it would refresh more
+    reliably and handle window resizing and -inroot
+  -neighbors is now randomly 4 or 6 if not 4 or 6.  This affects the ant and
+    demon mode.  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+  -help now displays help messages of each mode if there is one.
+  Changed _opts to include a separate counter for opts and vars & desc
+    since they do not have to be the same if there are boolean switches.
+  Added a -truchet option to ant, this leaves a trail of the ant.
+    One should probably change -gridsize to see it more clearly.
+  Added a -erase option to spline, if used one should make -cycles low,
+    say 20.
+  My long request for a penrose algorithm has been answered :) ,
+    penrose.c added thanks to Timo Korvola <tkorvola@dopey.hut.fi> .
+    -ammann will show ammann lines.  These were useful for debugging
+    penrose.c .  It is currently my favorite mode.  Once I saw it do
+    a dislocation, I think.
+  tri.c added thanks to Desmond Daignault <tekdd@dtol.datatimes.com> .
+    I would like to see other fractals added to this like fern.
+  daisy.c added.  I modeled it after some slow PC lockscreen in the office.
+  More 3d options besides rock: bouboule, pyro, & worms.  Rock patched up.
+    Now includes overlap color if colormap is installed.  Thanks to
+    Henrik Theiling <theiling@coli.uni-sb.de> .
+    There is a bug on some machines with rock mode.  A border of red can
+    be seen around the magenta rock (which should be blue).  This happens
+    on my Sun with the colormap installed but not on Linux.
+  Password code mallocs fixed up and BSD_AUTH code added thanks to
+    Paul Borman <prb@bsdi.com> .
+  2 problems in Kerberos code and 2 in the Imakefile cleaned up thanks
+    to Simon Josefsson <jas@pdc.kth.se> .
+  Kerberos 5 added thanks to Dale Harris <rodmur@ecst.csuchico.edu> .
+  Multi user per uid patch thanks to der Mouse
+    <mouse@collatz.mcrcim.mcgill.edu> .
+  Now should compile under C++, but it complains about signaling, pclose,
+    crypt, and gethostname when linking.
+  All modes now have refresh hooks, but some just call the init_ hook.
+    lissie, bug, rotor, spline -erase and worm hooks thanks to Alexander
+    Jolk <jolk@ap-pc513b.physik.uni-karlsruhe.de> .
+    On slip, penrose, and puzzle, I made no attempt.
+  All modes now have change hooks.  All except random call the init_ hook.
+    So when running a mode you can get it to restart by pressing the middle
+    button on your mouse.  This does not work with the password window up
+    but probably should.
+  Added -debug runtime switch.  Formerly accessed only by -DDEBUG.  Some
+    debug switches are still only accessed in this way.
+  -rule for life and -rule3d for life3d runtime switches.  Also a real
+    change hooks for these modes.  For -rule3d if set to 0 all rules that
+    have known patterns will randomly selected.  If set to 1 all rules that
+    have known gliders will be randomly selected.
+  "xlock -inwindow -lockdelay 10" now should work.
+  Sped up sphere by not drawing off screen.
+  Added a hackers directory for hackers.
+  Added hooks to Imakefile for MesaGL.  No mode uses this yet see the
+    hackers directory.
+
+3.10
+  Reorganized bitmaps.  All single bitmaps use "image_" inside the bitmap
+    file.  They are now organized t-tiny, s-small, m-medium, and l-large.
+    That way one can, if one wished, one can use one bitmap file for eyes,
+    image, life, life1d, maze, and puzzle at compile-time.
+  Removed all references to Scr, screen, and dsp in the modes.
+  Release mode stuff added to all modes (except random).  Rewrote image
+    initialization for bat, image, and puzzle to make it safe for
+    multiscreens (image and puzzle are still not correct for multiscreens).
+  Negative batchcounts now allowed, if negative it will be random from
+    the smallest allowed positive batchcount to ABS(batchcount), inclusive.
+    It is available on
+      ant, bat, bounce, bug, eyes, flag, galaxy, geometry, grav, image, laser,
+      lissie, maze, mountain, petal, puzzle, rock, spiral, spline, swarm,
+      world, worm.
+  More mallocing (and freeing) done for bat, bounce, bug, eyes, galaxy,
+    geometry, image, lissie, maze, puzzle, rock, rotor, spline, wator, world,
+    worm, so there are less predefined limits.  In the case of eyes and rock,
+    some limits were imposed where a dynamic number of pixmaps were
+    dynamically declared, so that xlock would not easily slow down to a crawl
+    and run out of memory.
+  bug now uses gridsize.  And to some degree life, life1d, and wator.
+    It would be neat if you could choose not to use the bitmaps for big
+    windows.
+  worm now uses cycles for length of worm and galaxy uses cycles now too.
+    rock uses cycles for max rock size.
+  One no longer has to hit return twice to unlock using lockdelay.
+  flag now uses batchcount for "point" size.
+  XClearWindow is used instead of filling screen with a big black rectangle.
+  Added -icongeometry option. It has a range of 1x1 to 256x256 .  Position
+    information is ignored.  Updated modes to handle weird geometry's bat,
+    bounce, braid, bug, eyes, kaleid, life, life1d, maze, nose, puzzle,
+    wator, world.
+  mountain changed to allow it to be interrupted quicker, (braid and slip
+    are harder :) ).
+  bounce changed to get rid of drawing errors.  I could not figure out how
+    easily remove more without the balls flashing.
+  wire mode added based on code from Kevin Dahlhausen <ap096@po.cwru.edu>
+    and Stefan Strack <stst@vuse.vanderbilt.edu>.
+  lightning mode added thanks to Keith Romberg <kromberg@saxe.com>.
+  in xlock.c, in function runMainLoop, reads should be declared not as
+    struct fd_set.  This causes compilation errors with Linux kernels 2.0
+    and higher.  Thanks to Brian R. Doherty <doherty@rice.edu>.
+  "nice" patch for xlock to so that xlock is "not so nice" when a password
+    window is being presented.  Thanks to Jouk Jansen
+    <joukj@hrem.stm.tudelft.nl>.
+  lightning, eyes, maze, shape patched for multiscreens.  XPM stuff patched
+    for multiscreens (thanks to XPM maintainer Arnaud Le Hors).
+    Tested on a machine where 0.0 is black/white, 0.1 is 8 bit color.
+    Also random mode does not use the correct initial values of modes on
+    multiscreens.  Testing on multiscreen thanks to Mark Wedel
+    <mwedel@pyramid.com>.
+  Long standing bug fixed (>= before MAXBATCH) for flame.c thanks to Ron
+    Charlton <crc@ornl.gov>.
+  puzzle when in -inwindow or compiled with -DDEBUG and moved off screen
+    will not bomb out unless it is using an xbm image.  This should be
+    completely fixed in 3.11.
+  New defaults: grelb substituted for life icon, -install for 
+    installation of the colormap, some modes slowed down so they would look
+    correct on fast machines.
+3.9
+  All modes (except eyes.c) have been updated to use less global variables.
+    Also updated xlockmore to ANSI C by GNU's protoize.
+  demon.c updated to be faster.  Although it is now significantly more
+    complicated.
+  ant.c and demon now have runtime options.   -neighbors 6 or 4 (default = 4)
+    -gridsize (170 default)  (In ant, when neighbors = 6 it is called bees.
+    Not much is known about these critters.  They do not seem to exhibit the
+    highway building activity found in normal ants, but otherwise they
+    behave pretty similar.)
+  flag mode thanks to Charles Vidal <vidalc@club-internet.fr>.
+  The Lissajous worm (lissie mode) thanks to Alexander Jolk
+    <ub9x@rz.uni-karlsruhe.de>.
+  Shape mode now has triangles.  Also now looks better when minimized.
+    From an idea in REC (Recreational & Educational Computing).
+  Random mode now tells you which mode is running when run with -verbose
+    [formerly -v].
+    Added VERBOSE stuff to life, life3d, life1d, and ant.
+  Changed rock.c to use blue by default for the left eye.  All 3D glasses
+    I have seen use blue.
+  Fixed swirl so it would not swirl "white".  Even if it is not a bg or fg
+    color.  This made the border around the little window change color.
+  From Ron Hitchens <ron@idiom.com>:
+    patch for middle button so that it will change locks even if duration
+      is 0 in random mode.
+    patch for window title noticeable when used with the -inwindow option.
+    fixed up demon.c
+  Random access to raster files by giving a directory thanks to Jouk
+    Jansen <joukj@alpha.chem.uva.nl>.  If UNIX, give directory followed by
+    a "/", also it may try to put "." as an image file.
+  When xlock is compiled with shadow passwords it will still work on non
+    shadowed systems that use elf, thanks to Marek Michalkiewicz
+    <marekm@i17linuxb.ists.pwr.wroc.pl>  Compilation with HAS_SHADOW is
+    forced on Linux with ELF (even if shadow passwording is not used).
+    This will facilitate a migration towards shadow passwording.
+  For the sake of completeness, xbm files can now be read in at run-time.
+    Courtesy of John Bradley's xv(xvbm.c), used by permission.
+  "xlock -nolock -lockdelay 1" should no longer crash
+
+3.8
+  system call for sounds using DEF_PLAY thanks to Milco Numan
+    <milcon@krim.chem.uva.nl>
+  Used GNU's indent to reformat all *.c and *.h files.  It may have
+    screwed up some comments. I used:
+    -bap -nbacc -bad -nbc -br -bs -c33 -cd33 -ncdb -ce
+    -d0 -di12 -neei -fc1 -i8 -ip8 -l79 -lp -npcs -psl -nsc -nsob
+    -cli8 -cs -cp1
+  Multiple root accounts for allowroot.  Thanks to Lewis Muhlenkamp
+    <lewism@tt.comm.mot.com>.
+  Better make.com file for for VMS thanks to Jouk Jansen and the
+    author of XVMSUTILS, Trevor Taylor <taylort@decus.com.au>.
+  -display fix for VAX thanks to Jouk Jansen.
+  eyes mode, revamp to eliminate need for global variables in modes,
+    new hooks (release and refresh), and middle button for "Next" in
+    random mode, thanks to Ron Hitchens <ron@idiom.com>.
+    This now allows for many things to be cleaned up.  Due to the number
+    of modes, it will take a few releases.  See HACKERS.GUIDE.
+  puzzle mode thanks to Heath Rice <hrice@netcom.com> & Jouk Jansen
+    <joukj@alpha.chem.uva.nl>.
+  Raster files (for puzzle.c and image.c) thanks to Tobias Gloth
+    <gloth@math.uni-muenster.de> & Jouk Jansen <joukj@alpha.chem.uva.nl>.
+    Background is now black when used with -install.
+  swirl for 16 bytes per pixel patch <davidm@azstarnet.com>
+  bouboule mode memory leaks fixed thanks to Jeremie Petit <jpetit@essi.fr>.
+  maze's dead ends are now filled in.
+  More syslog stuff for notifying failures in unlocking xlock Andrew Sammut
+    <sammut@dstc.qut.edu.au>.
+  blank now uses the power-down sleep mode if available, thanks to Ron
+    Hitchens <ron@idiom.com>.
+
+3.7
+  HP bug timing bug fixed thanks to Ron Hitchens <ron@idiom.com>.
+  3D mode for rock thanks to <theiling@coli.uni-sb.de>.
+    Get out your 3D glasses, Red on right and Green on left.
+  added compile time option for spline, FOLLOW to erase old splines
+    like Qix thanks to Richard Duran <rduran@cs.utep.edu>
+  petal now works with -inroot .
+  CDE DT saver thanks to Trevor Bourget <trevor@thomsoft.com>
+    see Imakefile and README.
+  bouboule mode added, thanks to Jeremie Petit <jpetit@essi.fr>.
+    bouboule fixed for VMS and TrueColor.
+
+3.6
+  Many patches, thanks to Ron Hitchens <ron@idiom.com>.
+    xlock now appears over the screensaver, passwd.c reorganized,
+    new event loop in xlock.c, new icons in bitmaps, updated clock
+    and triangle, and resource parsing fixed for "xlock".
+  pedal renamed to petal.
+  Clock mode updated to change in size thanks to original author
+    Petit Jeremie <jpetit@essi.fr>.
+  More context handling stuff for DCE thanks to Terje Marthinussen
+    <terjem@cc.uit.no>.
+  slip mode added thanks to Scott Draves <spot@cs.cmu.edu>
+    with a patch from <joukj@alpha.chem.uva.nl>.
+  patch for -messagesfile code favored early quotes and new event loop
+    compatibility thanks to <joukj@alpha.chem.uva.nl>.
+  XLock.ad and xlock.man updated to be more consistent.
+  ultrix fix for strdup thanks to Erik Bertelsen <erik@sockdev.uni-c.dk>.
+  invalid sound added thanks to <J.M.Box@dcs.warwick.ac.uk>
+  Thanks to <mccomb@interport.net> for helping to debug marquee and nose
+    on multiheaded machines.
+3.5
+  Fixed my goof on worm.c.
+  vms_play fixed for nonexisting sound files and -messagesfile code
+    updated thanks to <joukj@alpha.chem.uva.nl>.
+  marquee now more random and memmove no longer used.
+  marquee fixed for multiheaded machines thanks to Caleb Epstein
+    <epstein_caleb@jpmorgan.com>.
+  Random number generator fixed for 64 bit "long" thanks to Scott McCoy
+    <smccoy@dr3w.ess.harris.com>.
+
+3.4
+  rplay patch thanks to Simon Banks <sbanks@cellnet.co.uk>.  xlock now
+    has sound where available.  Edit your favorite makefile.
+  2 new modes thanks to Tobias Gloth <gloth@math.uni-muenster.de>.
+    marquee (I changed a lot) shows text on the screen, similar to nose
+    triangle, (colormaping removed) similar to mountain
+  nose text functions removed to utils.c
+  image.c now with -imagefile option (only with XPM).
+  rect.c name changed to shape.c.
+  swirl.c and world.c fixed for multiscreens, thanks to Grant McDorman
+    <grant@isgtec.com>.
+  A better way of handling fortunes from a file, thanks to Jouk Jansen
+    <joukj@alpha.chem.uva.nl>.  To try use -messagesfile fortune.dat.
+    Also contributed vms_play.c and a new make.com file.
+  KERBEROS patch thanks to Omar Siddique <omar@gl.umbc.edu> for sending
+    and testing it (patch author unknown).
+
+3.3
+  LIFE_5655 and LIFE_6767 compile time options for life3d.
+  ultrix passwd bug fix thanks to Erik Bertelsen <erik@sockdev.uni-c.dk>.
+  nose now has a font option and is fixed for multiscreens.
+  Stupid memory leak in ant fixed.  Now random colors.
+  swirl now needs to be used with -install to look right,
+    thanks to Heath A. Kehoe <hakehoe@icaen.uiowa.edu>.
+  Patch for AIX thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+  Color pixmaps for bat from <patol@info.isbiel.ch>.
+  image pixmaps now default to bitmaps if xpm fails, thanks to
+    <Markus.Zellner@anu.edu.au>.
+  flame crashed xlock when using random mode on Linux, fixed.
+  Numerous fixes for multiscreens incl: bat, bounce, rect, hyper, life1d,
+    forest, laser, mountain, and braid.  Also xlock.c patched or second
+    screen would have a black and white display.
+    Purify found memory leaks in swirl, mountain, laser, hyper, maze.
+    Thanks to <mccomb@interport.net>.
+  New option -lockdelay #, for those who were bothered by xautolock
+    locking the screen when you you did not want it, now just hit
+    return (within a specified number of seconds) to get the screen back.
+    This option is intended to be used with xautolock.
+  worm now has no limit on the number of worms.
+  pyro bug fixed for large batchcount (500-2000), thanks to
+    Minoura Makoto <minoura@flab.fujitsu.co.jp>.
+
+3.2
+  Doug McLaren <dougmc@comco.com> noticed a big security hole in
+    nose.c when xlock is setuid to root.  Now, after the password is
+    read, it gives up root, thanks to Heath A. Kehoe
+    <hakehoe@icaen.uiowa.edu>.
+  DCE Authentication patch added.
+  Thanks to Jouk Jansen <joukj@hrem.stm.tudelft.nl> for clearing up
+    a timing problem using -DOLD_EVENT_LOOP .
+
+3.1
+  Multipatch by Heath A. Kehoe <hakehoe@icaen.uiowa.edu> it includes
+    speed up in helix, random mode now switches modes, input to mode
+    is now customizable (see random.c), and a DCE authentication patch
+    (based on work by Phil O'Connell <philo@icaen.uiowa.edu>).  Also
+    usleep was dropped in favor of a new timing mechanism.  It is still
+    available using -DOLD_EVENT_LOOP (VMS still uses it by default).
+  braid.c thanks to John Neil <neil@math.idbsu.edu>.
+  helix now looks even better.  I found a bug in the translation from
+    xscreensaver.
+  nose.c may still need a little work (its a bit slow).  Taken from 2
+    sources xnlock and xscreensaver's noseguy.  It no longer leaves
+    dust on the screen as well (the bitmaps are shifted up by one pixel).
+  pedal.c taken from xscreensaver.
+  Patches for OSF1_ENH_SEC but it unfortunately seems to need more work.
+  Idea to have the mode.h defaults used thanks to Roland Bock
+    <exp120@physik.uni-kiel.d400.de>.
+  closedown patch for xdm use from Janet Carson's xclosedown
+    with modifications from Anthony Thyssen <anthony@cit.gu.edu.au>.
+  image.c updated to use xbm if using a monochrome monitor or using -mono.
+  life1d, bug.c, ant.c, and demon.c added from Scientific American's
+    Computer Recreations.
+  hop.c now has Peter de Jong's hop.  Half the time its boring but
+    the other half of the time its great.
+  A better patch from Peter Schmitzberger <schmitz@coma.sbg.ac.at> for
+    spiral (a bug that I introduced).
+
+3.0
+  Patch from Peter Schmitzberger <schmitz@coma.sbg.ac.at> for maze and image.
+  Thanks to Shane Watts <shane@phobes.mlckew.edu.au> for helping me with
+    Linux shadowing.
+  world.c backward spinning jump fixed by Neale Pickett <zephyr@nmt.edu>.
+  laser.c bug (that I introduced) solved by Heath A. Kehoe
+    <hakehoe@icaen.uiowa.edu>.
+  Edited rect so that it does ellipses as well, like After Dark.
+    I should of renamed it right?
+  Got rid of "+=" in Imakefile because HP, AIX, and Ultrix have
+    trouble with it.  Still used by some systems where there seems to
+    be no trouble.
+  passwd.c extracted from xlock.c and xlock.h .  May have cured some
+    bugs (like a BIG network security bug) but most likely broke some
+    systems.  Thanks for the many people who gave feedback during
+    the BETA test.
+  
+2.10
+  xlockrc password for more user control of xlock.  Author unknown.
+    It is a compile-time option, see Imakefile and README.
+    Moved usleep.c and hsbramp.c to utils.c and logout.c to opt.c .
+    Split out mode.h from resource.c .
+  Changes of Skip_Burrell@sterling.com were incorporated into image.c .
+    Not sure how to get pixmaps to randomize color and -mono does
+    not work for pixmaps.  See Imakefile and README.
+  -allowroot now works on Solaris2.x.
+  Clock mode added, thanks to Jeremie Petit <petit@simula.unice.fr>.
+  laser and mountain modes added, similar to After Dark's version, and
+    also forest mode thanks to Pascal Pensa <pensa@aurora.unice.fr>.
+  Updated maze and helix after seeing mountain mode.  Do not have to
+    wait a second to enter password. :)
+  Now provide random number generator.  Thanks to Mike Arras
+    <arras@intertv.com>.  I changed RAND to LRAND.
+  Due to overwhelming demand, the old flame is back... well OK its
+    slightly modified.
+  Patch for SUNOS_ADJUNCT_PASSWD, thanks to Dale A. Harris
+    <rodmur@ecst.csuchico.edu>.
+  Imakefile reorganized for AIX.
+
+2.9
+  "make install.man" should now work for imake users (if you would like
+   it to work for Makefile.hp ...  mail me the patch).  
+  Unbundled SunC warnings removed in bitmap files, maze, grav, life,
+    and swirl.
+  Swirl patched to work sensibly with TrueColor displays, thanks to
+    Steve Early <sde1000@cam.ac.uk>
+  Rock mode made much better by Jeremie Petit <petit@simula.unice.fr>.
+  Imakefile reorganized by <mjacob@feral.COM> for Solaris2.x .
+  Reorganized the README and the screens are now (mostly) alphabetical
+    throughout.
+  Updated life3d to include compile-time options LIFE_5766 and LIFE_4555.
+    5766 is more like life, but 4555 (default) seems to be better.
+  I went through the lifep.zip (May 94) collection and pulled out some
+    small and interesting life forms.
+  I added another control to the screens.  "-cycles num" influences the
+    time out (it applies to about a 1/3 of the screens, see man pages).
+    For consistency, the meaning of batchcount for qix, life, life3d,
+    and rect was changed.  References to "seconds()" in the screens were
+    removed.  The length of a "cycle" depends on "delay".
+  Multidisplay bug fix for maze, thanks to <epstein_caleb@jpmorgan.com>.
+  AIXV3 with AFS, thanks to <chuck_hines@VNET.IBM.COM>.
+
+2.8
+  No more bomb.c, if you think xlock needs it, let the maintainer know.
+  full_lock rewritten by Dale A. Harris <rodmur@ecst.csuchico.edu> to
+    handle non-login groups as well.
+  fixed a bug in wator, introduced in 2.7.
+  fixed nanosleep bug for delays of 1 second or more.  Nanosleep is now
+    used by default on Solaris.  The Imakefile will have to be modified
+    if using Solaris 2.0-2.2, since nanosleep is not available.
+  I do not know why, but the logout out feature now works on Solaris.
+  Various warnings and errors fixed in make.com, resource.c, logout.c,
+    and galaxy.c for VMS.  Also fixed random generator for VMS not to
+    toggle the least significant bit.  This made worm.c look funny.
+  xlock now works on VMS/AXP thanks to <JOUKJ@CRYS.CHEM.UVA.NL>.  One
+    will have to uncomment sections in make.com .  Also fixed some
+    AIX problems.
+  Modes spiral and geometry thanks to Darrick Brown <dbrown@cs.hope.edu>.
+    Batchcount in maze and spline were changed to behave similarly.
+  A patch from Heath Rice <hrice@netcom.com> for a better way to handle
+    batchcount, delay, and saturation.
+  I went through xlife3.0 huge collection and added "suitable" lifeforms.
+
+2.7
+  sgi patches and logos from Dave Truesdell <truesdel@nas.nasa.gov>.
+  flame bug fixed thanks to <spot@cs.cmu.edu> and
+    <M.R.Dobie@ecs.soton.ac.uk>.
+  MANY patches from Heath A. Kehoe <hakehoe@icaen.uiowa.edu> include:
+    The long awaited HP patch.  It appears there was a bug in HP's XFlush
+    function.  So XSync was substituted.  HP_PASSWDETC patch.
+    maze, swarm, and worm -mono now look better.
+    Many changes to the Imakefile, new compile time features ...
+    including a logout button for labs (this appears to be better
+    implementation than the bomb mode (much of the bomb code has been
+    reused)) -install option to allow xlock to install its own colormap
+    if it runs out of colors.
+  Thanks to <slouken@virtbrew.water.ca.gov> for yet another option:
+    grabmouse for compatibility with xscreensaver.  So you would set
+    your apps-defaults file for xscreensaver like:
+
+*programs:      xlock -nolock +grabmouse -mode random
+
+  Updated life3d to include shooting gliders.
+  BSD and Linux icons slightly modified.  Also new ships for life.
+  Compile time options HAS_RAND, HAS_RANDOM, and HAS_RAND48, and
+    updated the sccsid so `what` will give you something meaningful.
+
+2.6
+  Created a HAS_USLEEP and a USE_VROOT switch.
+    There were numerous reports of the incompatibility with tvtwm,
+    (also problems with windows with StickyAbove set to true and
+    swirl), read the README section on that.
+  Thanks to Chris Ross <cross@va.pubnix.com>, maintainer of tvtwm, for
+    fixing various bugs; make depend for R5 and less, life3d should not
+    have malloc.h, and a time-elapsed patch. 
+  A few new life forms for life.c.  Anyone know what SMILEY is really
+    supposed to look like?  :)
+  Revised -inroot does not lock screen, as this is done better with the
+    following patch, and as someone pointed out, its not intuitive.
+  Thanks to Tim Medley for sending the -geometry patch of Mike Peercy
+    <peercy@crhc.uiuc.edu>.  Many of the modes will fail if the windows
+    are far from square or are too small.  You can place Xlock off the
+    screen, for example,
+      xlock -enablesaver -mode blank -geometry +1152+0
+    puts the window off the visible screen on a Sun.
+  A new version of flame.c from the original author Scott Draves
+    <spot@cs.cmu.edu>.
+  Something really devilish for BSD (new icons) thanks to J Wunsch
+    <j@uriah.sax.de>, but they have been modified.  I also created a
+    Linux icon.
+  A patch for Ultrix systems (at least DECstations) running enhanced     
+    security thanks to Chris Fuhrman <cfuhrman@vt.edu> and friend.
+  Multidisplay bug fix for life3d and wator, thanks to
+    <epstein_caleb@jpmorgan.com>.
+  Life3d on a monochrome monitor looks a little better. -mono was
+    working right.
+
+2.5
+  A patch for swirl for fixed color maps (more colorful) and the
+    image now spirals outwards from the center with a fixed number of
+    points drawn every iteration, thanks to <M.R.Dobie@ecs.soton.ac.uk>.
+  A patch for blot on dual-headed machines and nanosleep, thanks to
+    Greg Onufer <Greg.Onufer@Eng.Sun.COM>. Use nanosleep on Solaris2.3
+    and greater, examine the Imakefile and/or README for details.
+  A long needed patch for X11R5+ for -delay, -batchcount, and
+    -saturation to work thanks to Patrick D Sullivan <pds@bss.com>.
+  bomb mode patch for more flexibility thanks to Dave Shield
+    <D.T.Shield@csc.liv.ac.uk>.
+  bomb mode patch for Sun10 thanks to Nicolas Pioch <pioch@Email.ENST.Fr>.
+  modes wator and life3d added.
+  life now has a random soup pattern stolen from life3d.
+  -inroot option added, thanks to Bill Woodward <wpwood@pencom.com>.
+    Now more compatible with xscreensaver if run as
+    "xlock -mode kaleid -inroot -nolock".
+
+2.4
+  hopalong now includes a sine hop (but less likely to come up).
+  life now has new organisms. They are now better centered.  Some of
+   the nonperiodic forms were removed.
+   life's gliders now come from the edge of the screen, usually.
+  image now centers icons, for example, the hp icon is now centered.
+  blot now randomly has xsym, ysym, or both.
+  Solaris should now compile out of the box to handle shadow passwords.
+    Thanks to Alain Brossard <brossard@siisun.epfl.ch>.
+  rock, grav, rect, bat, world, bounce and swirl fix for 24 bit colors.
+  Patch for building under HP-UX with Secured Passwords, thanks to
+    Dale Harris <rodmur@ecst.csuchico.edu>.
+
+2.3
+  Now the X Logo displays if not Sun or HP.
+  "bat" mode disastrous bug fixed.  Thanks to R.K.Lloyd@csc.liv.ac.uk
+    for pointing it out.
+  -DMOUSE_MOTION switch added for those who want the Password window to
+    come up if you just moved the mouse. (Not recommended).
+  "swirl" mode was modified to check background, foreground, and black
+    so as not to cycle these colors, special thanks to Mark Dobie
+    <mrd@ecs.soton.ac.uk>.
+  -DFORCEFIXEDCOLORS switch for those who are annoyed by swirl cycling
+    its colors.
+
+2.2
+  Made more consistent with the slackware release.  XLock.ad changes
+    to rock, rotor, and foreground and background colors.
+  Fixed bug in life.c, evident in the Slackware release.
+  Minor patch for swirl on HP's due to R.K.Lloyd@csc.liv.ac.uk.
+  "bat" put back with minor changes.
+
+2.1
+  Large modifications to README.
+  Patch for building under QNX 4.2 w/ Metrolink X server, thanks to
+    Brian Campbell <brianc@qnx.com>.
+
+2.0
+  "swirl" mode was added, thanks to Mark Dobie <mrd@ecs.soton.ac.uk>.
+    WOW, but not-so-neat on monochrome monitors.
+  Patch for Solaris 2.3 for local, NIS, and NIS+ passwords, thanks to
+    <Christian.Iseli@di.epfl.ch>.
+  "image" mode was put back but random will not run it, too boring.
+  "bomb" mode was added, thanks to <D.T.Shield@compsci.liverpool.ac.uk>.
+  In order to use extra-long passwords with the Linux, changed
+    PASSLENGTH from 20 to 64.  Thanks to <slouken@virtbrew.water.ca.gov>.
+
+1.14
+  Multidisplay bug fix for rect, thanks to <epstein_caleb@jpmorgan.com>.
+  Now works on IRIX on the SGI. Thanks to <reggers@julian.uwo.ca>.
+  Now works on NetBSD. Thanks to Greg Earle <earle@isolar.Tujunga.CA.US>.
+  Now works on a Alpha 3000/400 OSF/1 V2.0. Thanks to Udo Linauer
+    <ul@eacpc4.tuwien.ac.at>.
+  "galaxy" mode was added, thanks to Hubert Feyrer
+    <hubert.feyrer@rz.uni-regensburg.de>.
+  "kaleid" mode was added, taken from the Linux version of xkaleid.
+  
+1.13
+  "timeelapsed" option was added.  Allows you to find out how long a
+    machine is locked so you can complain to an administrator.
+  Now may work on IRIX on the SGI. Thanks to Thomas Runge
+    <runge@egd.igd.fhg.de>
+  "bat" mode was added, thanks to Lorenzo Patocchi <patol@info.isbiel.ch>.
+
+1.12
+  xlock now works on Linux with shadow passwords.  Special thanks to
+    H. J. Dihu <macgyver@mcs.com>
+
+1.11
+  Shadow passwords and DES encryption are now detected by the Imakefile.
+    Victor Langeveld <vic@mbfys.kun.nl> reorganized the Imakefile for 
+    shadow passwords and crypt.  Now should compile "right out of the
+    box" (although there are still problems on Solaris 2.3).
+  Patch to fix sudden rotation changes in rock from Yoshiaki Kasahara
+    <kasahara@csce.kyushu-u.ac.jp>.
+
+1.10
+  R.K.Lloyd@csc.liv.ac.uk reorganized the Imakefile yet again.
+  Fixed a bug in rect.c thanks to <epstein_caleb@jpmorgan.com>.
+  Ditched bzero and bcopy since both are more generally available as
+    memset and memcpy.  Also removed some lint warnings.
+
+1.9
+  "rect" mode was added from xscreensaver's greynetic.
+  "helix" bug fixed.  It is now more interesting.
+  bounce.c divide by zero fixed and grav.c improvements.  Thanks to Greg
+    Bowering <greg@cs.adelaide.edu.au>.
+  grav.c, rock.c, world.c fixed so no black objects.
+
+1.8
+  Imakefile did not work with R6.  Also Solaris2.3 may use SVR4
+    instead of SYSV.  Thanks to Chris P. Ross <cross@eng.umd.edu>
+  "grav" mode was added.  Its a simplistic gravitational simulation,
+    with (currently a constant 16) solid spheres (non-rendered) of equal
+    size and mass orbiting a fixed central mass.  The sphere's orbit in
+    3 dimensions, their position and size being projected with simple
+    perspective.  Thanks to Greg Bowering <greg@cs.adelaide.edu.au>.
+  "inwindow" option was added.  Allows you to do what xlock already
+    did when DEBUG was defined.  It no longer locks your screen, but
+    allows you to run xlock as a (somewhat distracting) decoration.
+    Thanks to Greg Bowering <greg@cs.adelaide.edu.au>.
+  "bounce" mode (football) is back.
+  "world" mode was added.  Thanks to Matthew Moyle-Croft
+    <mmc@cs.adelaide.edu.au>
+  "image" mode was removed. It was very similar to world anyway.
+
+1.7
+  cuserid() is needed by Solaris2.3 with shadow passwords in xlock.c.
+    Thanks to Bill <benedett@gentire.com>.
+
+1.6
+  R.K.Lloyd@csc.liv.ac.uk pointed out again that gray_bits in maze.c needs
+    a type cast.
+  xlock.c defaults to "blank" to minimize cpu usage on a network.
+
+1.5
+  xlock works again on VMS (see README.VMS) thanks to Anthony Clarke
+    <Anthony.D.Clarke@Support.Hatfield.Raytheon.bae.eurokom.ie>.
+  memcpy and memset definitions for SYSV. Also there now is a switch
+    for shadow passwords thanks to <reggers@julian.uwo.ca>.
+
+1.4
+  Now works on BSD. Thanks to Victor Langeveld <vic@mbfys.kun.nl>
+  Both Victor and Alexandre Miguel <miguel@natacha.ens-cachan.fr>
+    suggested taking out the cuserid() call in xlock.c.  For FreeBSD its
+    a necessity and the old way is is a security hole in SunOS.
+
+1.3
+  Linux port from Darren Senn's (sinster@scintilla.capitola.ca.us) xlock.
+  Fixed drand to random in helix.c
+  Fixed a memory leak in rock.c.
+
+1.2
+  SHIFT - CONTROL - BREAK on the HP is trapped. Thanks to
+  R.K.Lloyd@csc.liv.ac.uk who pointed out that this was done in xscreensaver.
+  AIXV3 and HP bugs fixed, again due to R. K. Lloyd.
+
+1.1 & 1.0
+  took out "rint" from "worm.c" since HP's have trouble with it
+  added spline, maze, sphere, hyper, helix, rock, & blot modes.
+  fixed "xlock.h" and "usleep" for the HP.
+  changed border so it varies with size of screen on "swarm" so the
+    wasp would not be stuck in a corner when the password is entered.
+
+-------------------------------------------------------------------------------
+
+Original author: Patrick J. Naughton
+Site: ftp.x.org in /R5contrib
+The changes in the original xlock
+
+Changes of xlock (sccs version 23.21) patchlevel = 2.3
+    o added worm mode.
+    o old -name and .name changed to -username and .username.
+    o lint cast.
+    o change color allocation to allow "#ffaabb" style color names.
+    o portability bug in flame mode fixed plus some other nits.
+    o white on black on monochrome screens fixed.
+Changes of xlock (sccs version 23.19) patchlevel = 2.2
+    o added -name to allow different resource files to be used.
+    o added -usefirst to allow first keystroke to be used in password.
+    o made changes to life mode to allow wrap around.
+    o made old life cells stay blue.
+    o added -resources to get default resource file.
+    o added random mode
+    o added pyro mode
+    o added flame mode.
+    o made passwords a little more secure.
+    o use effective uid to find current user.
+    o make main window managed by the wm in debug mode.
+    o some more SVR4 portability changes.
+    o resource code now looks at XUSERFILESEARCHPATH and XAPPLRESDIR.
+    o removed verbose copyright info from each file.
+
+-------------------------------------------------------------------------------
+
+ Copyright (c) 1988-91 by Patrick J. Naughton.
+
+ Permission to use, copy, modify, and distribute this software and its
+ documentation for any purpose and without fee is hereby granted,
+ provided that the above copyright notice appear in all copies and that
+ both that copyright notice and this permission notice appear in
+ supporting documentation.
+
+ This file is provided AS IS with no warranties of any kind.  The author
+ shall have no liability with respect to the infringement of copyrights,
+ trade secrets or any patents by this file or any part thereof.  In no
+ event will the author be liable for any lost revenue or profits or
+ other special, indirect and consequential damages.
+
+    ______________________________________________________________________
+    Patrick J. Naughton                                   email: naughton@sun.com
+    Sun Microsystems Laboratories, Inc.                   voice: (415) 336 - 1080
+
+Maintainer: David A. Bagley <bagleyd@tux.org>
diff --git a/xlockmore-4.14/docs/TODO b/xlockmore-4.14/docs/TODO
new file mode 100644 (file)
index 0000000..a693567
--- /dev/null
@@ -0,0 +1,304 @@
+General problems:
+
+  o It would be nice to have an option -idletime time.  Where xlock would
+   run after a certain idle time.  (Here xautolock may help you, see
+   above).
+
+  o xscreensaver compatibility
+    2 of the writable modes: mandelbrot, tube-> get them to RUN (compile OK)
+    XPM  capability needs to be improved.
+
+  o Add a way to get xlock to switch to "blank" mode after X minutes
+    of (keyboard) inactivity, and to switch back to whatever mode list was
+    being used when activity is detected.  This would be good for
+    users using DPMS to power down the monitor without using precious cpu
+    when the modes are not visible.
+
+  o configure.in should be condensed.  Its getting out of hand.
+
+  o Look into any way of not clearing the screen if cant get control of it
+     (2nd xlock running).
+
+  o gentlerandom mode option.  Switching to next mode when mode completed
+      what it was working on.
+
+  o On a PsuedoColor display
+      xlock -mode life -install &
+      sleep 5 ; xlock -mode life -install
+    Colors will all be messed up after the second one tries to run.
+    This can easily happen if you are using xautolock and decide to lock
+    the display manually.
+
+  o -wireframe should be a mode option (i.e. you should be able to turn it
+    on and off for a particular mode).  Also a linewidth mode option would be
+    nice
+
+  o I got an error with moebius running it on opengl on a 24 bit TrueColor like:
+    xlock -mode moebius -visual PseudoColor
+    (all the gl modes are messed up anyway... all mono)
+
+  o some configurations of linux: swarm has noise when bees go beyond screen
+    Sun Ultra5 PCI Bus 24 bit display: flow has some noise (usually red)
+
+  o A few uninitialized memory reads and memory leaks were detected in some
+   of the code.  grep for "PURIFY" in the source files to see where the
+   remaining problems are.  Also see docs/Purify for more details. 
+
+  o -mono does not work for XPM, especially cartoon (others use XBM when
+   mono), also cage and stairs.
+
+  o Options within a mode can not be duplicated in other modes.  Temporary
+   solution is to have xlock modes like "-neighbor" that only a few of the
+   modes use.
+
+  o -use3d -install is messed up on Sun's PseudoColor.  Magenta boxes are
+   seen on the star mode.  In worm mode, worms might be red and magenta
+   instead of red blue (and depending on SunCC or SunOS).
+
+  o Not all resources are listed in "xlock -resources", e.g. nolock.
+   If xlock is renamed these resources are not picked up.
+
+  o Without any programs stealing your colors, like netscape
+   xlock -modelist all -sequential -install -verbose
+   Hit the middle button a hundred times (not to bad on an ultra actually)
+   or try -duration 1 and let it sit for a while.
+   The second time it runs the GL modes they have all lost some colors.
+   This was only noticed on Solaris with pseudocolor.  Also noticed on an
+   ancient HP9000/380 HPUX9.0 with 6 bit depth (without netscape).
+
+  o On a German keyboard and Linux if the password contains special
+   characters (`|' vertical bar, `@' at-sign) while in debug mode
+   everything works fine. This probably has something to do with the
+   X11-keymapping, as these characters are composed with the right Alt-key
+   on a German keyboard. 
+
+  o neighbors option for wator and voters... sometimes circles are not
+   drawn in the correct spot.  A -/+ wrap option would be nice also.
+
+  o OpenGL and DT may be incompatible on PseudoColor.  (MesaGL should be
+   OK.)  OpenGL frequently causes xlock to error out on non-default visuals.
+
+  o -visual DirectColor if used with any of the with the writable modes
+   (mandelbrot, swirl, or tube) may corrupt the dynamic allocation of memory.
+
+  o Errors in modes, if any, should not break lock.
+
+  o Compile-time option to allow running of separate processes.
+
+  o Fallback font if screen is small for marquee and nose... like bomb
+
+  o make -n install prefix=/foo/bar does not work.
+  
+  o "xlock -mode random -modelist image -bitmap ./bitmaps/"
+   It should change images when middle mouse is pushed or when
+   -duration time runs out.
+
+  o some sort of completion is used which may be confusing on UNIX
+   Say if a ../bitmaps directory exists and ../bitmap does not
+   xlock -mode random -modelist image -bitmap ../bitmap
+   will try to load ../bitmaps as a file...
+
+  o kill -HUP to change modes as well as middle mouse button.  Needed when
+   using -inroot .
+
+  o jpeg/gif/animated gif support  Fix ras for > 8 bit TrueColor
+
+  o "-visual" commandline argument should accept "best" as well as
+   PseudoColor, TrueColor, default, etc.
+
+  o Is there any chance the "visual" selection code could be made
+   mode-dependent?  Most Xservers that support TrueColor, etc, visuals also
+   support PseudoColor visuals and it would be nice to have color-cycling
+   modes like "starfish" and "swirl" pick a PseudoColor visual if available,
+   while modes like "cartoon" could prevent colormap flashing by picking a
+   TrueColor visual.
+   I heard that VisualDepthMask taken out of vis.c it seems to work better
+   to get a PseudoColor visual one a root window of 24 bits.
+
+  o modes from xscreensaver :) : bubbles, moire, LMorph, halo, ImsMap, BlitSpin
+
+
+Mode specific problems:
+----------------------
+  Various modes need better refresh capability.
+  Various modes need more mouse capability like pacman and worm.
+
+  ant:
+    round ants.  This would involve masking and images to do efficiently.
+    eyes on hexagonal and triangular ants.
+
+  ball: can it be updated to use a pixmap instead of a slow circle fill?
+
+  braid: should be made so that it can be interrupted quicker.
+
+  bouboule: always starts at the bottom right
+
+  bounce:
+    sometimes a ball does not roll off another ball.
+    momentum seems to be created.
+    A -wall option, multiscreens should have balls bouncing between
+      screens.
+    -mode bounce -inroot may give BadWindow in X_GetWindowAttributes
+      if run for a while, but the screen is not locked :)
+    allow a background picture to be seen behind the bouncing football
+      (soccer ball) in "bounce" mode.  Thus a picture of your favorite
+      team, etc. can be seen behind the bouncing balls.
+    football version of "bounce" using a pigskin instead of a soccer ball for
+      Americans/Canadians/etc.
+    Different balls with different mass and size.
+
+  bug: triangular bugs
+
+  dclock: needs a -led [LED] option
+
+  ico:
+    should have all the features of the original.
+    triangular face objects do not look good when rotated.
+
+  image: middle button should do something when called like
+     "-bitmap ./bitmap/"
+
+  flag:
+    sometimes a refresh causes a white background rectangle 
+
+  hop: center and size many of the hops.
+
+  kaleid: needs to be triangular.
+
+  life:
+    -find option to find new lifeforms.  (mail the results out :) ).
+    When the bitmap is big it is rejected.  Probably could be handled
+      better but if accepted then the screen could be blank because there
+      are bitmaps that are off screen.
+
+  life3d: draws invisible cubes when it does not have to.  The original
+    MS DOS code weeded this out, but it did not seem to port to X.
+    Also see life.
+
+  lyapunov: needs to be speeded up
+
+  marquee:
+    "-messagefile filename" truncates a large file.
+    "-message string" does not handle Control-H correctly.
+
+  mountain: -size # for mountain should do something.
+
+  nose: should handle Control-H better for underlining and accents.
+
+  pyro: needs XDrawSegments code similar to swarm to give it depth.
+
+  slip:
+    should be less jarring
+    get rid of single color blotch.
+    should be made so that it can be interrupted quicker.
+
+  star:
+    fractal cracks when hit by rocks (with sound?)
+    user defined ships (user defined pixmaps like eyes and pacman).
+    stars should look more star-like "*"'s
+    combine space and star for a backwards and sideways motion
+
+  swirl:
+    needs to be refreshed quicker
+    does not refresh well when colormap changes
+
+  text3d:
+     time stuff in text3d
+     maybe dclock and marquee could be combined too?
+     a separate -message3d for text3d
+
+
+  wire:  it needs a better circuit generator.
+
+  xglock:  Needs a lot of work.
+  
+  kscreensaver:  port xlock to KDE.
+
+
+New mode ideas... (some may be very hard :) ):
+---------------------------------------------
+  o "dead" a Grateful Dead mode with dancing bears/skeletons/turtles.
+      (Or maybe "nose" in a tie die?)
+  o "floyd" a Pink Floyd mode from the cover of "Dark Side of the Moon"
+      with a turning prism and rainbow effect.
+  o "graph" a random planar graph drawn ... filled in by a 5 (or 4 :) )
+      coloring algorithm.
+  o "minimal" a random minimal surface generator.
+  o "snow" mode with a nice Winter scene picture background and snowflakes
+      falling
+  o "squig" mode from squig/xsquig (xsquig is too slow)
+  o A NT-like GL 3D Maze, where you are inside the maze
+  o NT-like GL FlowerBox spring and Flying Objects
+  o A GL 4D ico where the 6 4D "platonic" objects "roll" around in 3D space.
+  o GL modes based on demos: isosurf, reflect, bounce, stex3d
+  o KitCat (R) clock mode (based on X11 catclock, a version of xclock) where
+     the cat clock floats around the screen like "dclock" mode does.  Colors
+     of cat clock could be picked like nose-guy in "nose" mode.
+  o Lottery with bouncing numbered balls like PowerBall.
+  o A simple set of 2D geometric shapes that morph into one another whilst
+     colour cycling. So say you start with a rectangle that morphs into a
+     circle (leaving a small trail like Qix) that morphs into a triangle
+     that morphs into a polygon that morphs into a rectangle, etc.  All the
+     while you have movement and colour cycling like Qix.  If the trail is to
+     large then things could become messy, but if too short then you loose the
+     history element.
+  o A simple bouncing ball on a chess board. The ball is a silver
+     ray-traced/rendered globe. The chess board is a series of black and
+     white squares. Each black square is gold veined marble with the gold
+     glinting. Each white square is a textured surface (like little bumps, or
+     ridges). The whole screen is lit from two light sources (either fixed or
+     moving). As the ball bounces it reflects like a mirror what is around it.
+  o A variant of the above would be to hold that ball still in the centre of
+     the screen and move a randomly chosen bitmap around the ball.
+  o The above could also have embossed on standout lettering added (say a
+     single word like Linux). The lettering could either be stationary or
+     float around the ball in orbit a bit like the the Universal studios logo
+     where the Universal name revolves around a picture of the earth.
+  o Take pipes and add the constantly moving view point that you get with
+     rock so the mass of pipes seems to revolve and rotate around a moving
+     point in space.
+  o Make the little man in Nose seem to carve the letters of the message into
+     rock, or paint them on the screen.
+  o Make marquee use 3D extruded text that can be texture mapped and seem to
+     zoom into and out of the screen with the zoom source point drifting
+     around the screen at random
+  o Make puzzle take the present desktop image, invert it and shuffle the
+     pieces then put the whole things back. Once it has reassembled the
+     desktop you could have the image flip top over bottom as it reseeds into
+     the screen, only to have a new randomly shuffled version of the desktop
+     flip back out.
+  o Use the spheres generated in sphere to draw molecules on the screen,
+     colour coding for the various types of atom present. A limit on the size
+     of each sphere would be needed. The spheres could be joined by simple
+     white lines. If you are feeling adventurous you could make it seem to
+     rotate in space so all parts of the molecule could be seen.
+  o In shape change things so that the shapes appear to be extruded from a
+     random point on the screen. You could also have a number of shapes be
+     extruded, each from its own origin, only to shrink back into the screen
+     again.  Each time a shape shrinks back into the screen the origin would
+     move and a new shape would be chosen.
+  o When the screensaver is started have curtains drawn across the desktop
+     at a medium pace, a second or twos pause then the curtain a pulled open
+     quickly to reveal a bitmaped image in place of the desktop. This cycles
+     with a different image each time.
+  o In pyro have the fireworks appear to zoom from a randomly choose point on
+     the screen. This would give the effect of the display being seen from
+     above.
+
+PLEASE NOTE:
+-----------
+  I _REALLY_ hate to turn down contributions...  I will try to consider
+   all submissions.  Some things on new modes that bother me are:
+   Did not black out the screen when they start.  I do not like people
+     to see what I am doing. :^|  (This could be a non-default option...
+     see decay mode).
+   Did not work in the little window or buggy.  (I usually try to clean
+     it up).
+   Is too similar mode to a mode that already exists. (Maybe an option could
+     be added on an existing mode?).
+   Many people complained about the mode.
+   Just not enough randomness or is not interesting enough.
+   No multiscreen support (I usually try to clean this up too).
+  But I labor over them (in a haphazard fashion) and they usually are
+   released eventually.  (If they are in assembler I would definitely need
+   a working example and all the binaries and libraries to get it to run.)
diff --git a/xlockmore-4.14/docs/cell_automata b/xlockmore-4.14/docs/cell_automata
new file mode 100644 (file)
index 0000000..71c43be
--- /dev/null
@@ -0,0 +1,161 @@
+There are a few modes devoted to cellular automata.
+I also added a bunch of options.  So I am providing a little explanation
+so it is not overwhelming.  I also say a little something at the top of the
+C file of each.  If your favorite little automaton is not here (or you think
+it should be enhanced)... let me know.
+The modes are ant, bug, demon, dilemma, life, life1d, life3d, loop, voters,
+wator and wire.
+use -install if netscape is stealing all your colors... :)
+"xlock -help" may be helpful too.
+
+ant: Turing Machines where the tape is the screen.
+ Special options:
+  -truchet: this shows the path (good to use with -size at
+    least 10)  Truchet option turned off if its not Turk's ants.
+
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: number of ants
+  -cycles <int>: how many cycles before a new ant
+  -size <int>: size of ant in pixels
+  
+  -neighbors <int>: 0 random, 4 ants, 3 & 6 bees, (8, 9, and 12
+    are also available, but in my opinion, produces nonsence)
+  -verbose: verbose help identify ant  (good to use with -inwindow or -debug)
+
+bug: Evolving bugs learn to walk straight (except in the garden) unlike
+   other modes there is no wrapping
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: number of bugs
+  -cycles <int>: how many cycles before a new world
+  -size <int>: size of bug in pixels
+
+  -neighbor <int>: option has no effect.  Currently supports only a hexagonal
+    arrangement (6)  (other neighborhoods currently in development)
+
+demon: A simple modulo automata
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: number of states
+  -cycles <int>: how many cycles before a new screen
+  -size <int>: size of cell in pixels
+
+  -neighbors <int>: 0 random, 4 & 8 rectangular, 6 hexagonal, 3, 9 & 12
+    triangular
+
+dilemma: Happy (good) and Mean (bad) cells compete for domination
+ Special options:
+  -conscious: (default) uses its own state in calculation of payoff
+  +conscious: does not use its own state in calculation of payoff
+  -bonus <flt>: payoff for defecting
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: number of bad or defecting initial cells
+  -cycles <int>: how many cycles before a new screen
+  -size <int>: size of cell in pixels (mean faces and happy faces become
+    polygons and circles if not 0)
+
+  -neighbors <int>: 0 random, 4 & 8 rectangular, 6 hexagonal, 3, 9 & 12
+    triangular (mean faces and happy faces become polygons and circles if
+    not 4 or 8)
+
+life:
+ Special options:
+  -rule <string>: survival and birth parameters formated
+    S<neighborhood>/B<neighborhood>, so Conways rule is S23/B3.
+    Two format exceptions:
+      -rule P:  Picks a random rule from all rules that have known patterns
+      -rule G:  Picks a random rule from all rules that have known gliders
+  -callahan: Paul Callahan's B2a/S2b34 hexagonal life
+  -andreen: Bob Andreen's B2a3a4b/S2a2b4a hexagonal life
+  -lifefile <filename>: only the #P format of xlife
+    There is a limit of 128 initial live cells set by NUMFILEPTS in life.c.
+
+ Mode options:
+  -cycles <int>: how many cycles before a new lifeform
+  -batchcount <int>: number of cycles before glider (if one exists)
+  -delay <int>: controls the length of a cycle in microsec
+  -size <int>: size of cell in pixels, if 0 may default to bitmap
+
+  -neighbors <int>: 0 random, 4 & 8 rectangular, 6 hexagonal, 3, 9 & 12
+    triangular
+  -verbose: verbose help identify life (to be referenced with the source code)
+    (good to use with -inwindow or -debug)
+
+life1d: 1 dimensional life
+ Special options:
+  -totalistic: (default) totalistic 1d life
+  +totalistic: LCAU collection  These rules may not be symmetric and are
+    more general (totalistic is a subset).
+
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -cycles <int>: how many pages before a new lifeform
+  -size <int>: size of cell in pixels, if 0 may default to bitmap
+
+  -verbose: verbose to help identify life (to be referenced with the source
+    code) (good to use with -inwindow or -debug)
+
+life3d: 3 dimensional life
+ Special options:
+  -rule3d <string>: survival and birth parameters formated
+    S<neighborhood>/B<neighborhood>, so Bays' rules are S45/B5, S567/B6,
+    S56/B5, and S67/B67.  There is currently no way of accessing the
+    neighborhoods 10 to 27.
+    Two format exceptions:
+      -rule3d P:  Picks a random rule from all rules that have known patterns
+      -rule3d G:  Picks a random rule from all rules that have known gliders
+  -life3dfile <filename>: similar to the #P format of xlife, 3 integers are
+    required to center, sequential linefeeds imply a depth change
+    There is a limit of 84 initial live cells set by NUMFILEPTS in life3d.c.
+
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: number of cycles before glider (if one exists)
+  -cycles <int>: how many cycles before a new lifeform
+
+  -verbose: verbose to help identify life (to be referenced with the source
+    code) (good to use with -inwindow or -debug)
+
+loop: Chris Langton's loops, its always the same but oriented 4 ways
+    this is far as I know is the best example of a self-generating life form.
+    Caution: this may cause you to question G-d's existence. :)
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -cycles <int>: how many cycles before it starts over
+  -size <int>: size of cell in pixels
+
+voters: your political belief is influenced by your neighbor
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: number of parties 2 or 3 (3 may not be available)
+  -cycles <int>: how many cycles before a new world starts
+  -size <int>: size of cell in pixels (elephants and donkeys become
+    squares and circles if not 0, hammer/sickle unavailable)
+
+  -neighbors <int>: 0 random, 4 & 8 rectangular, 6 hexagonal, 3, 9 & 12
+    triangular (elephants and donkeys become squares and circles if
+    not 4 or 8, hammer/sickle unavailable)
+
+wator: sharks and fish on a water torus planet
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: breed time for the fish
+  -cycles <int>: how many cycles before a new world starts
+  -size <int>: size of cell in pixels (sharks and fish become polygons
+    and circles if not 0)
+
+  -neighbors <int>: 0 random, 4 & 8 rectangular, 6 hexagonal, 3, 9 & 12
+    triangular (sharks and fish become polygons and circles if not 4 or 8)
+
+wire: (this mode lacks a good circuit generator)  unlike other modes there
+   is no wrapping
+ Mode options:
+  -delay <int>: controls the length of a cycle in microsec
+  -batchcount <int>: length of random circuit
+  -cycles <int>: how many cycles before a circuit
+  -size <int>: size of cell in pixels
+
+  -neighbors <int>: 0 random, 4 & 8 rectangular, 6 hexagonal, 3, 9 & 12
+    triangular
diff --git a/xlockmore-4.14/docs/xlock.hlp b/xlockmore-4.14/docs/xlock.hlp
new file mode 100644 (file)
index 0000000..ac8c3d3
--- /dev/null
@@ -0,0 +1,1783 @@
+1 XLOCK
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+2 N\bN\bN\bNA\bA\bA\bAM\bM\bM\bME\bE\bE\bE
+xlock - Locks the  local  X  display  until  a  password  is
+entered.
+
+
+2 S\bS\bS\bSY\bY\bY\bYN\bN\bN\bNO\bO\bO\bOP\bP\bP\bPS\bS\bS\bSI\bI\bI\bIS\bS\bS\bS
+x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk [ -h\bh\bh\bhe\be\be\bel\bl\bl\blp\bp\bp\bp ] [ -v\bv\bv\bve\be\be\ber\br\br\brs\bs\bs\bsi\bi\bi\bio\bo\bo\bon\bn\bn\bn  ]  [  -r\br\br\bre\be\be\bes\bs\bs\bso\bo\bo\bou\bu\bu\bur\br\br\brc\bc\bc\bce\be\be\bes\bs\bs\bs  ]  [  -d\bd\bd\bdi\bi\bi\bis\bs\bs\bsp\bp\bp\bpl\bl\bl\bla\ba\ba\bay\by\by\by
+_\bd_\bi_\bs_\bp_\bl_\ba_\by_\bn_\ba_\bm_\be  ] [ -v\bv\bv\bvi\bi\bi\bis\bs\bs\bsu\bu\bu\bua\ba\ba\bal\bl\bl\bl _\bv_\bi_\bs_\bu_\ba_\bl_\bn_\ba_\bm_\be ] [ -n\bn\bn\bna\ba\ba\bam\bm\bm\bme\be\be\be _\br_\be_\bs_\bo_\bu_\br_\bc_\be_\bn_\ba_\bm_\be ]
+[ -m\bm\bm\bmo\bo\bo\bod\bd\bd\bde\be\be\be _\bm_\bo_\bd_\be_\bn_\ba_\bm_\be ] [ -d\bd\bd\bde\be\be\bel\bl\bl\bla\ba\ba\bay\by\by\by _\bu_\bs_\be_\bc_\bs ] [ -b\bb\bb\bba\ba\ba\bat\bt\bt\btc\bc\bc\bch\bh\bh\bhc\bc\bc\bco\bo\bo\bou\bu\bu\bun\bn\bn\bnt\bt\bt\bt  _\bn_\bu_\bm  ]  [
+-c\bc\bc\bco\bo\bo\bou\bu\bu\bun\bn\bn\bnt\bt\bt\bt  _\bn_\bu_\bm ] [ -c\bc\bc\bcy\by\by\byc\bc\bc\bcl\bl\bl\ble\be\be\bes\bs\bs\bs _\bn_\bu_\bm ] [ -n\bn\bn\bnc\bc\bc\bco\bo\bo\bol\bl\bl\blo\bo\bo\bor\br\br\brs\bs\bs\bs _\bn_\bu_\bm ] [ -s\bs\bs\bsi\bi\bi\biz\bz\bz\bze\be\be\be _\bn_\bu_\bm ]
+[ -s\bs\bs\bsa\ba\ba\bat\bt\bt\btu\bu\bu\bur\br\br\bra\ba\ba\bat\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn _\bv_\ba_\bl_\bu_\be ] [ -e\be\be\ber\br\br\bra\ba\ba\bas\bs\bs\bse\be\be\bem\bm\bm\bmo\bo\bo\bod\bd\bd\bde\be\be\be _\bm_\bo_\bd_\be_\bn_\ba_\bm_\be ] [  -e\be\be\ber\br\br\bra\ba\ba\bas\bs\bs\bse\be\be\bed\bd\bd\bde\be\be\bel\bl\bl\bla\ba\ba\bay\by\by\by
+_\bu_\bs_\be_\bc_\bs  ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\bal\bl\bl\bll\bl\bl\blo\bo\bo\bow\bw\bw\bwa\ba\ba\bac\bc\bc\bcc\bc\bc\bce\be\be\bes\bs\bs\bss\bs\bs\bs ] [ -v\bv\bv\bvt\bt\bt\btl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk _\bm_\bo_\bd_\be_\bn_\ba_\bm_\be ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+n\bn\bn\bno\bo\bo\bol\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk
+] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+i\bi\bi\bin\bn\bn\bnw\bw\bw\bwi\bi\bi\bin\bn\bn\bnd\bd\bd\bdo\bo\bo\bow\bw\bw\bw ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+i\bi\bi\bin\bn\bn\bnr\br\br\bro\bo\bo\boo\bo\bo\bot\bt\bt\bt ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\bre\be\be\bem\bm\bm\bmo\bo\bo\bot\bt\bt\bte\be\be\be ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+m\bm\bm\bmo\bo\bo\bon\bn\bn\bno\bo\bo\bo ]  [
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\bal\bl\bl\bll\bl\bl\blo\bo\bo\bow\bw\bw\bwr\br\br\bro\bo\bo\boo\bo\bo\bot\bt\bt\bt ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bde\be\be\beb\bb\bb\bbu\bu\bu\bug\bg\bg\bg ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bde\be\be\bes\bs\bs\bsc\bc\bc\bcr\br\br\bri\bi\bi\bip\bp\bp\bpt\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\bec\bc\bc\bch\bh\bh\bho\bo\bo\bok\bk\bk\bke\be\be\bey\by\by\bys\bs\bs\bs
+] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\ben\bn\bn\bna\ba\ba\bab\bb\bb\bbl\bl\bl\ble\be\be\bes\bs\bs\bsa\ba\ba\bav\bv\bv\bve\be\be\ber\br\br\br ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\bre\be\be\bes\bs\bs\bse\be\be\bet\bt\bt\bts\bs\bs\bsa\ba\ba\bav\bv\bv\bve\be\be\ber\br\br\br ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+g\bg\bg\bgr\br\br\bra\ba\ba\bab\bb\bb\bbm\bm\bm\bmo\bo\bo\bou\bu\bu\bus\bs\bs\bse\be\be\be ] [  -\b-\b-\b-
+/\b/\b/\b/+\b+\b+\b+g\bg\bg\bgr\br\br\bra\ba\ba\bab\bb\bb\bbs\bs\bs\bse\be\be\ber\br\br\brv\bv\bv\bve\be\be\ber\br\br\br  ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+i\bi\bi\bin\bn\bn\bns\bs\bs\bst\bt\bt\bta\ba\ba\bal\bl\bl\bll\bl\bl\bl ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+m\bm\bm\bmo\bo\bo\bou\bu\bu\bus\bs\bs\bse\be\be\bem\bm\bm\bmo\bo\bo\bot\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+s\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd
+] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\bti\bi\bi\bim\bm\bm\bme\be\be\bee\be\be\bel\bl\bl\bla\ba\ba\bap\bp\bp\bps\bs\bs\bse\be\be\bed\bd\bd\bd ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+u\bu\bu\bus\bs\bs\bse\be\be\bef\bf\bf\bfi\bi\bi\bir\br\br\brs\bs\bs\bst\bt\bt\bt ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+v\bv\bv\bve\be\be\ber\br\br\brb\bb\bb\bbo\bo\bo\bos\bs\bs\bse\be\be\be ] [  -n\bn\bn\bni\bi\bi\bic\bc\bc\bce\be\be\be
+_\bl_\be_\bv_\be_\bl  ] [ -l\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bkd\bd\bd\bde\be\be\bel\bl\bl\bla\ba\ba\bay\by\by\by _\bs_\be_\bc_\bo_\bn_\bd_\bs ] [ -t\bt\bt\bti\bi\bi\bim\bm\bm\bme\be\be\beo\bo\bo\bou\bu\bu\but\bt\bt\bt _\bs_\be_\bc_\bo_\bn_\bd_\bs ] [ -f\bf\bf\bfo\bo\bo\bon\bn\bn\bnt\bt\bt\bt
+_\bf_\bo_\bn_\bt_\bn_\ba_\bm_\be ] [ -p\bp\bp\bpl\bl\bl\bla\ba\ba\ban\bn\bn\bnf\bf\bf\bfo\bo\bo\bon\bn\bn\bnt\bt\bt\bt _\bf_\bo_\bn_\bt_\bn_\ba_\bm_\be ] [ -b\bb\bb\bbg\bg\bg\bg _\bc_\bo_\bl_\bo_\br ] [ -f\bf\bf\bfg\bg\bg\bg  _\bc_\bo_\bl_\bo_\br
+]  [  -b\bb\bb\bba\ba\ba\bac\bc\bc\bck\bk\bk\bkg\bg\bg\bgr\br\br\bro\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd  _\bc_\bo_\bl_\bo_\br ] [ -f\bf\bf\bfo\bo\bo\bor\br\br\bre\be\be\beg\bg\bg\bgr\br\br\bro\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bc_\bo_\bl_\bo_\br ] [ -u\bu\bu\bus\bs\bs\bse\be\be\ber\br\br\brn\bn\bn\bna\ba\ba\bam\bm\bm\bme\be\be\be
+_\bs_\bt_\br_\bi_\bn_\bg ] [ -p\bp\bp\bpa\ba\ba\bas\bs\bs\bss\bs\bs\bsw\bw\bw\bwo\bo\bo\bor\br\br\brd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg ] [ -i\bi\bi\bin\bn\bn\bnf\bf\bf\bfo\bo\bo\bo _\bs_\bt_\br_\bi_\bn_\bg ]  [  -v\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bda\ba\ba\bat\bt\bt\bte\be\be\be
+_\bs_\bt_\br_\bi_\bn_\bg   ]  [  -i\bi\bi\bin\bn\bn\bnv\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bd  _\bs_\bt_\br_\bi_\bn_\bg  ]  [  -g\bg\bg\bge\be\be\beo\bo\bo\bom\bm\bm\bme\be\be\bet\bt\bt\btr\br\br\bry\by\by\by  _\bg_\be_\bo_\bm  ]  [
+-i\bi\bi\bic\bc\bc\bco\bo\bo\bon\bn\bn\bng\bg\bg\bge\be\be\beo\bo\bo\bom\bm\bm\bme\be\be\bet\bt\bt\btr\br\br\bry\by\by\by _\bg_\be_\bo_\bm ] [ -g\bg\bg\bgl\bl\bl\blg\bg\bg\bge\be\be\beo\bo\bo\bom\bm\bm\bme\be\be\bet\bt\bt\btr\br\br\bry\by\by\by _\bg_\be_\bo_\bm ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+w\bw\bw\bwi\bi\bi\bir\br\br\bre\be\be\bef\bf\bf\bfr\br\br\bra\ba\ba\bam\bm\bm\bme\be\be\be ] [
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+u\bu\bu\bus\bs\bs\bse\be\be\be3\b3\b3\b3d\bd\bd\bd  ]  [ -d\bd\bd\bde\be\be\bel\bl\bl\blt\bt\bt\bta\ba\ba\ba3\b3\b3\b3d\bd\bd\bd _\bv_\ba_\bl_\bu_\be ] [ -n\bn\bn\bno\bo\bo\bon\bn\bn\bne\be\be\be3\b3\b3\b3d\bd\bd\bd _\bc_\bo_\bl_\bo_\br ] [ -r\br\br\bri\bi\bi\big\bg\bg\bgh\bh\bh\bht\bt\bt\bt3\b3\b3\b3d\bd\bd\bd
+_\bc_\bo_\bl_\bo_\br ] [ -l\bl\bl\ble\be\be\bef\bf\bf\bft\bt\bt\bt3\b3\b3\b3d\bd\bd\bd _\bc_\bo_\bl_\bo_\br ] [ -b\bb\bb\bbo\bo\bo\bot\bt\bt\bth\bh\bh\bh3\b3\b3\b3d\bd\bd\bd _\bc_\bo_\bl_\bo_\br ] [ -p\bp\bp\bpr\br\br\bro\bo\bo\bog\bg\bg\bgr\br\br\bra\ba\ba\bam\bm\bm\bm  _\bp_\br_\bo_\b-
+_\bg_\br_\ba_\bm_\bn_\ba_\bm_\be  ] [ -m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\bes\bs\bs\bsf\bf\bf\bfi\bi\bi\bil\bl\bl\ble\be\be\be _\bf_\bo_\br_\bm_\ba_\bt_\bt_\be_\bd-_\bf_\bi_\bl_\be_\bn_\ba_\bm_\be ] [ -m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\be-\b-\b-\b-
+f\bf\bf\bfi\bi\bi\bil\bl\bl\ble\be\be\be _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be ] [ -m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\be _\bs_\bt_\br_\bi_\bn_\bg ] [ -m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\bef\bf\bf\bfo\bo\bo\bon\bn\bn\bnt\bt\bt\bt  _\bf_\bo_\bn_\bt_\bn_\ba_\bm_\be
+] [ -b\bb\bb\bbi\bi\bi\bit\bt\bt\btm\bm\bm\bma\ba\ba\bap\bp\bp\bp _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be ] [ -c\bc\bc\bcp\bp\bp\bpa\ba\ba\bas\bs\bs\bss\bs\bs\bsw\bw\bw\bwd\bd\bd\bd _\bc_\br_\by_\bp_\bt_\be_\bd-_\bp_\ba_\bs_\bs_\bw_\bo_\br_\bd ] [ -f\bf\bf\bfo\bo\bo\bor\br\br\br-\b-\b-\b-
+c\bc\bc\bce\be\be\beL\bL\bL\bLo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\bt _\bm_\bi_\bn_\bu_\bt_\be_\bs  ]  [  -l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btB\bB\bB\bBu\bu\bu\but\bt\bt\btt\bt\bt\bto\bo\bo\bon\bn\bn\bnL\bL\bL\bLa\ba\ba\bab\bb\bb\bbe\be\be\bel\bl\bl\bl  _\bt_\be_\bx_\bt_\bs_\bt_\br_\bi_\bn_\bg  ]  [
+-l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btB\bB\bB\bBu\bu\bu\but\bt\bt\btt\bt\bt\bto\bo\bo\bon\bn\bn\bnH\bH\bH\bHe\be\be\bel\bl\bl\blp\bp\bp\bp  _\bt_\be_\bx_\bt_\bs_\bt_\br_\bi_\bn_\bg  ] [ -l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btF\bF\bF\bFa\ba\ba\bai\bi\bi\bil\bl\bl\ble\be\be\bed\bd\bd\bdS\bS\bS\bSt\bt\bt\btr\br\br\bri\bi\bi\bin\bn\bn\bng\bg\bg\bg _\bt_\be_\bx_\bt_\b-
+_\bs_\bt_\br_\bi_\bn_\bg ] [ -\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bdt\bt\bt\bts\bs\bs\bsa\ba\ba\bav\bv\bv\bve\be\be\ber\br\br\br ] [ -m\bm\bm\bmo\bo\bo\bod\bd\bd\bdu\bu\bu\bul\bl\bl\ble\be\be\bep\bp\bp\bpa\ba\ba\bat\bt\bt\bth\bh\bh\bh _\bp_\ba_\bt_\bh  ]  [  -l\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bks\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd
+_\bs_\bt_\br_\bi_\bn_\bg  ]  [  -i\bi\bi\bin\bn\bn\bnf\bf\bf\bfo\bo\bo\bos\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd  _\bs_\bt_\br_\bi_\bn_\bg  ] [ -v\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bds\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg ] [
+-i\bi\bi\bin\bn\bn\bnv\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bds\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg ] [ -s\bs\bs\bst\bt\bt\bta\ba\ba\bar\br\br\brt\bt\bt\btC\bC\bC\bCm\bm\bm\bmd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg ] [ -e\be\be\ben\bn\bn\bnd\bd\bd\bdC\bC\bC\bCm\bm\bm\bmd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+] [ -l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btC\bC\bC\bCm\bm\bm\bmd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg ]
+
+
+2 D\bD\bD\bDE\bE\bE\bES\bS\bS\bSC\bC\bC\bCR\bR\bR\bRI\bI\bI\bIP\bP\bP\bPT\bT\bT\bTI\bI\bI\bIO\bO\bO\bON\bN\bN\bN
+x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk locks the X server till the user enters their password
+at  the  keyboard.   While  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk is running, all new server
+connections are refused.  The screen saver is disabled.  The
+mouse  cursor  is  turned  off.  The screen is blanked and a
+changing pattern is put on the screen.  If a key or a  mouse
+button is pressed then the user is prompted for the password
+of the user who started x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk.
+
+2 If the  correct  password  is  typed,  then  the  screen  is
+unlocked  and  the  X  server  is restored.  When typing the
+password Control-U and Control-H  are  active  as  kill  and
+erase  respectively.   To return to the locked screen, click
+in the small icon version of the changing pattern.
+
+2 In  the  lower  part  of  the  password  screen  a  text  is
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    1
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+displayed.  This message is taken from the first file of the
+following that exists:   $HOME/.xlocktext,  $HOME/.plan,  or
+$HOME/.signature.
+
+2 On systems which support new BSD style  authentication,  the
+password may be prefixed by an authentication style followed
+by a colon (i.e. "style:password").  See  the  login.conf(5)
+for more information on authentication styles.
+
+
+2 N\bN\bN\bNO\bO\bO\bOT\bT\bT\bTE\bE\bE\bE O\bO\bO\bON\bN\bN\bN E\bE\bE\bET\bT\bT\bTI\bI\bI\bIQ\bQ\bQ\bQU\bU\bU\bUE\bE\bE\bET\bT\bT\bTT\bT\bT\bTE\bE\bE\bE
+_\bX_\bl_\bo_\bc_\bk should not be used on public terminals when there is a
+high demand for them.
+
+2 If you find a  public  terminal  that  has  been  locked  by
+another user and there are no other terminals available, and
+the terminal appears to have been  left  idle  for  a  while
+(normally  more than 15 minutes), it is fair to try to reset
+the session in some manner.
+
+
+2 O\bO\bO\bOP\bP\bP\bPT\bT\bT\bTI\bI\bI\bIO\bO\bO\bON\bN\bN\bNS\bS\bS\bS
+-h\bh\bh\bhe\be\be\bel\bl\bl\blp\bp\bp\bp
+     Print options and a brief description to standard  out-
+     put.
+
+-v\bv\bv\bve\be\be\ber\br\br\brs\bs\bs\bsi\bi\bi\bio\bo\bo\bon\bn\bn\bn
+     Print version number (if >= 4.00) to standard output.
+
+-r\br\br\bre\be\be\bes\bs\bs\bso\bo\bo\bou\bu\bu\bur\br\br\brc\bc\bc\bce\be\be\bes\bs\bs\bs
+     Print default resource file to standard output.
+
+-d\bd\bd\bdi\bi\bi\bis\bs\bs\bsp\bp\bp\bpl\bl\bl\bla\ba\ba\bay\by\by\by _\bd_\bi_\bs_\bp_\bl_\ba_\by_\bn_\ba_\bm_\be
+     The _\bd_\bi_\bs_\bp_\bl_\ba_\by option sets the X11 display to lock.  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk
+     locks all available screens on a given server, and res-
+     tricts you to locking  only  a  local  server  such  as
+     u\bu\bu\bun\bn\bn\bni\bi\bi\bix\bx\bx\bx:\b:\b:\b:0\b0\b0\b0,\b,\b,\b,  l\bl\bl\blo\bo\bo\boc\bc\bc\bca\ba\ba\bal\bl\bl\blh\bh\bh\bho\bo\bo\bos\bs\bs\bst\bt\bt\bt:\b:\b:\b:0\b0\b0\b0,\b,\b,\b,  or :\b:\b:\b:0\b0\b0\b0 unless you set the -r\br\br\bre\be\be\bem\bm\bm\bmo\bo\bo\bot\bt\bt\bte\be\be\be
+     option.
+
+-v\bv\bv\bvi\bi\bi\bis\bs\bs\bsu\bu\bu\bua\ba\ba\bal\bl\bl\bl _\bv_\bi_\bs_\bu_\ba_\bl_\bn_\ba_\bm_\be
+     _\bv_\bi_\bs_\bu_\ba_\bl_\bn_\ba_\bm_\be which is one of  "StaticGray",  "GrayScale",
+     "StaticColor",        "PseudoColor",       "TrueColor",
+     "DirectColor", or "default".  default used to  set  the
+     screen's  default  visual  (the visual of the root win-
+     dow).
+
+-n\bn\bn\bna\ba\ba\bam\bm\bm\bme\be\be\be _\br_\be_\bs_\bo_\bu_\br_\bc_\be_\bn_\ba_\bm_\be
+     _\br_\be_\bs_\bo_\bu_\br_\bc_\be_\bn_\ba_\bm_\be is used instead of X\bX\bX\bXL\bL\bL\bLo\bo\bo\boc\bc\bc\bck\bk\bk\bk when looking  for
+     resources to configure x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk.
+
+-m\bm\bm\bmo\bo\bo\bod\bd\bd\bde\be\be\be _\bm_\bo_\bd_\be_\bn_\ba_\bm_\be
+     As of this writing there  are  over  90  display  modes
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    2
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     supported (plus one more for random selection of one of
+     these).
+
+a\ba\ba\ban\bn\bn\bnt\bt\bt\bt     Shows Langton's and Turk's generalized ants.
+
+a\ba\ba\bat\bt\bt\btl\bl\bl\bla\ba\ba\ban\bn\bn\bnt\bt\bt\bti\bi\bi\bis\bs\bs\bs
+        Shows  moving  sharks/whales/dolphin.   May  not  be
+        available depending on how it was configured.
+
+b\bb\bb\bba\ba\ba\bal\bl\bl\bll\bl\bl\bl    Shows bouncing balls.
+
+b\bb\bb\bba\ba\ba\bat\bt\bt\bt     Shows bouncing flying bats.
+
+b\bb\bb\bbl\bl\bl\blo\bo\bo\bot\bt\bt\bt    Shows Rorschach's ink blot test.
+
+b\bb\bb\bbo\bo\bo\bou\bu\bu\bub\bb\bb\bbo\bo\bo\bou\bu\bu\bul\bl\bl\ble\be\be\be
+        Shows Mimi's bouboule of moving stars.
+
+b\bb\bb\bbo\bo\bo\bou\bu\bu\bun\bn\bn\bnc\bc\bc\bce\be\be\be  Shows bouncing footballs.
+
+b\bb\bb\bbr\br\br\bra\ba\ba\bai\bi\bi\bid\bd\bd\bd   Shows random braids and knots.
+
+b\bb\bb\bbu\bu\bu\bub\bb\bb\bbb\bb\bb\bbl\bl\bl\ble\be\be\be  Shows popping bubbles.
+
+b\bb\bb\bbu\bu\bu\bub\bb\bb\bbb\bb\bb\bbl\bl\bl\ble\be\be\be3\b3\b3\b3d\bd\bd\bd
+        Shows Richard Jones's GL bubbles.  May not be avail-
+        able depending on how it was configured.
+
+b\bb\bb\bbu\bu\bu\bug\bg\bg\bg     Shows Palmiter's bug evolution and a garden of Eden.
+
+c\bc\bc\bca\ba\ba\bar\br\br\brt\bt\bt\bto\bo\bo\boo\bo\bo\bon\bn\bn\bn Shows  bouncing  cartoons.   May  not  be  available
+        depending on how it was configured.
+
+c\bc\bc\bcl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk   Shows Packard's oclock.
+
+c\bc\bc\bco\bo\bo\bor\br\br\bra\ba\ba\bal\bl\bl\bl   Shows a coral reef.
+
+c\bc\bc\bcr\br\br\bry\by\by\bys\bs\bs\bst\bt\bt\bta\ba\ba\bal\bl\bl\bl Shows polygons in 2D plane groups.
+
+d\bd\bd\bda\ba\ba\bai\bi\bi\bis\bs\bs\bsy\by\by\by   Shows a meadow of daisies.
+
+d\bd\bd\bdc\bc\bc\bcl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk  Shows a floating digital clock or message.
+
+d\bd\bd\bde\be\be\bec\bc\bc\bco\bo\bo\bo    Shows art as ugly as sin.
+
+d\bd\bd\bde\be\be\bem\bm\bm\bmo\bo\bo\bon\bn\bn\bn   Shows Griffeath's cellular automata.
+
+d\bd\bd\bdi\bi\bi\bil\bl\bl\ble\be\be\bem\bm\bm\bmm\bm\bm\bma\ba\ba\ba Shows Lloyd's Prisoner's Dilemma simulation.
+
+d\bd\bd\bdi\bi\bi\bis\bs\bs\bsc\bc\bc\bcr\br\br\bre\be\be\bet\bt\bt\bte\be\be\be
+        Shows various discrete maps.
+
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    3
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+d\bd\bd\bdr\br\br\bri\bi\bi\bif\bf\bf\bft\bt\bt\bt   Shows cosmic drifting flame fractals.
+
+c\bc\bc\bca\ba\ba\bag\bg\bg\bge\be\be\be    Shows the Impossible Cage, an Escher-like GL  scene.
+        May not be available depending on how it was config-
+        ured.
+
+e\be\be\bey\by\by\bye\be\be\bes\bs\bs\bs    Shows eyes following a bouncing grelb.
+
+f\bf\bf\bfa\ba\ba\bad\bd\bd\bde\be\be\bep\bp\bp\bpl\bl\bl\blo\bo\bo\bot\bt\bt\bt
+        Shows a fading plot of sine squared.
+
+f\bf\bf\bfl\bl\bl\bla\ba\ba\bag\bg\bg\bg    Shows a waving flag image.  This may be  text  or  a
+        graphic  image.   Default  text  is the hostname and
+        operating system.
+
+f\bf\bf\bfl\bl\bl\bla\ba\ba\bam\bm\bm\bme\be\be\be   Shows cosmic flame fractals.
+
+f\bf\bf\bfl\bl\bl\blo\bo\bo\bow\bw\bw\bw    Shows dynamic strange attractors.
+
+f\bf\bf\bfo\bo\bo\bor\br\br\bre\be\be\bes\bs\bs\bst\bt\bt\bt  Shows binary trees of a fractal forest.
+
+g\bg\bg\bga\ba\ba\bal\bl\bl\bla\ba\ba\bax\bx\bx\bxy\by\by\by  Shows crashing spiral galaxies.
+
+g\bg\bg\bge\be\be\bea\ba\ba\bar\br\br\brs\bs\bs\bs   Shows GL's gears.  May not be available depending on
+        how it was configured.
+
+g\bg\bg\bgo\bo\bo\boo\bo\bo\bop\bp\bp\bp    Shows goop from a lava lamp.
+
+g\bg\bg\bgr\br\br\bra\ba\ba\bav\bv\bv\bv    Shows orbiting planets.
+
+h\bh\bh\bhe\be\be\bel\bl\bl\bli\bi\bi\bix\bx\bx\bx   Shows string art.
+
+h\bh\bh\bho\bo\bo\bop\bp\bp\bp     Shows real plane iterated fractals.
+
+h\bh\bh\bhy\by\by\byp\bp\bp\bpe\be\be\ber\br\br\br   Shows spinning n-dimensional hypercubes.
+
+i\bi\bi\bic\bc\bc\bco\bo\bo\bo     Shows a bouncing polyhedron.
+
+i\bi\bi\bif\bf\bf\bfs\bs\bs\bs     Shows a modified iterated function system.
+
+i\bi\bi\bim\bm\bm\bma\ba\ba\bag\bg\bg\bge\be\be\be   Shows randomly appearing logos.
+
+j\bj\bj\bju\bu\bu\bul\bl\bl\bli\bi\bi\bia\ba\ba\ba   Shows the Julia set.
+
+k\bk\bk\bka\ba\ba\bal\bl\bl\ble\be\be\bei\bi\bi\bid\bd\bd\bd  Shows Brewster's Kaleidoscope.
+
+k\bk\bk\bku\bu\bu\bum\bm\bm\bmm\bm\bm\bmp\bp\bp\bpa\ba\ba\ba  Shows kumppa.
+
+l\bl\bl\bla\ba\ba\bas\bs\bs\bse\be\be\ber\br\br\br   Shows spinning lasers.
+
+l\bl\bl\bli\bi\bi\bif\bf\bf\bfe\be\be\be    Shows Conway's game of life.
+
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    4
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+l\bl\bl\bli\bi\bi\bif\bf\bf\bfe\be\be\be1\b1\b1\b1d\bd\bd\bd  Shows Wolfram's game of 1D life.
+
+l\bl\bl\bli\bi\bi\bif\bf\bf\bfe\be\be\be3\b3\b3\b3d\bd\bd\bd  Shows Bays' game of 3D life.
+
+l\bl\bl\bli\bi\bi\big\bg\bg\bgh\bh\bh\bht\bt\bt\btn\bn\bn\bni\bi\bi\bin\bn\bn\bng\bg\bg\bg
+        Shows Keith's fractal lightning bolts.
+
+l\bl\bl\bli\bi\bi\bis\bs\bs\bsa\ba\ba\ba    Shows animated lissajous loops.
+
+l\bl\bl\bli\bi\bi\bis\bs\bs\bss\bs\bs\bsi\bi\bi\bie\be\be\be  Shows lissajous worms.
+
+l\bl\bl\blo\bo\bo\boo\bo\bo\bop\bp\bp\bp    Shows Langton's self-producing loops.
+
+m\bm\bm\bma\ba\ba\ban\bn\bn\bnd\bd\bd\bde\be\be\bel\bl\bl\blb\bb\bb\bbr\br\br\bro\bo\bo\bot\bt\bt\bt
+        Shows mandelbrot sets.
+
+m\bm\bm\bma\ba\ba\bar\br\br\brq\bq\bq\bqu\bu\bu\bue\be\be\bee\be\be\be Shows text.
+
+m\bm\bm\bma\ba\ba\bat\bt\bt\btr\br\br\bri\bi\bi\bix\bx\bx\bx  Shows the matrix.
+
+m\bm\bm\bma\ba\ba\baz\bz\bz\bze\be\be\be    Shows a random maze and a depth first  search  solu-
+        tion.
+
+m\bm\bm\bmo\bo\bo\boe\be\be\beb\bb\bb\bbi\bi\bi\biu\bu\bu\bus\bs\bs\bs Shows the Moebius Strip II, an Escher-like GL  scene
+        with ants.  May not be available depending on how it
+        was configured.
+
+m\bm\bm\bmo\bo\bo\bor\br\br\brp\bp\bp\bph\bh\bh\bh3\b3\b3\b3d\bd\bd\bd Shows GL morphing polyhedra.  May not  be  available
+        depending on how it was configured.
+
+m\bm\bm\bmo\bo\bo\bou\bu\bu\bun\bn\bn\bnt\bt\bt\bta\ba\ba\bai\bi\bi\bin\bn\bn\bn
+        Shows Papo's mountain range.
+
+m\bm\bm\bmu\bu\bu\bun\bn\bn\bnc\bc\bc\bch\bh\bh\bh   Shows munching squares.
+
+n\bn\bn\bno\bo\bo\bos\bs\bs\bse\be\be\be    Shows a man with a big nose runs around spewing  out
+        text.
+
+p\bp\bp\bpa\ba\ba\bac\bc\bc\bcm\bm\bm\bma\ba\ba\ban\bn\bn\bn  Shows Pacman(tm).
+
+p\bp\bp\bpi\bi\bi\bip\bp\bp\bpe\be\be\bes\bs\bs\bs   Shows a  self-building  pipe  system.   May  not  be
+        available depending on how it was configured.
+
+p\bp\bp\bpe\be\be\ben\bn\bn\bnr\br\br\bro\bo\bo\bos\bs\bs\bse\be\be\be Shows Penrose's quasiperiodic tilings.
+
+p\bp\bp\bpe\be\be\bet\bt\bt\bta\ba\ba\bal\bl\bl\bl   Shows various GCD Flowers.
+
+p\bp\bp\bpu\bu\bu\buz\bz\bz\bzz\bz\bz\bzl\bl\bl\ble\be\be\be  Shows a puzzle being scrambled and then solved.
+
+p\bp\bp\bpy\by\by\byr\br\br\bro\bo\bo\bo    Shows fireworks.
+
+q\bq\bq\bqi\bi\bi\bix\bx\bx\bx     Shows spinning lines a la Qix(tm).
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    5
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+r\br\br\bro\bo\bo\bol\bl\bl\bll\bl\bl\bl    Shows a rolling ball.
+
+r\br\br\bro\bo\bo\bot\bt\bt\bto\bo\bo\bor\br\br\br   Shows Tom's Roto-Rooter.
+
+r\br\br\bru\bu\bu\bub\bb\bb\bbi\bi\bi\bik\bk\bk\bk   Shows an auto-solving  Rubik's  Cube.   May  not  be
+        available depending on how it was configured.
+
+s\bs\bs\bsh\bh\bh\bha\ba\ba\bap\bp\bp\bpe\be\be\be   Shows stippled rectangles, ellipses, and triangles.
+
+s\bs\bs\bsi\bi\bi\bie\be\be\ber\br\br\brp\bp\bp\bpi\bi\bi\bin\bn\bn\bns\bs\bs\bsk\bk\bk\bki\bi\bi\bi
+        Shows a Sierpinski's triangle.
+
+s\bs\bs\bsl\bl\bl\bli\bi\bi\bip\bp\bp\bp    Shows slipping blits.
+
+s\bs\bs\bsp\bp\bp\bph\bh\bh\bhe\be\be\ber\br\br\bre\be\be\be  Shows a bunch of shaded spheres.
+
+s\bs\bs\bsp\bp\bp\bpi\bi\bi\bir\br\br\bra\ba\ba\bal\bl\bl\bl  Shows a helical locus of points.
+
+s\bs\bs\bsp\bp\bp\bpl\bl\bl\bli\bi\bi\bin\bn\bn\bne\be\be\be  Shows colorful moving splines.
+
+s\bs\bs\bsp\bp\bp\bpr\br\br\bro\bo\bo\boi\bi\bi\bin\bn\bn\bng\bg\bg\bgi\bi\bi\bie\be\be\bes\bs\bs\bs
+        Shows Sproingies!   Nontoxic.   Safe  for  pets  and
+        small  children.   May not be available depending on
+        how it was configured.
+
+s\bs\bs\bst\bt\bt\bta\ba\ba\bai\bi\bi\bir\br\br\brs\bs\bs\bs  Shows Infinite Stairs, an Escher-like GL scene.  May
+        not be available depending on how it was configured.
+
+s\bs\bs\bst\bt\bt\bta\ba\ba\bar\br\br\br    Shows a star field with a twist.
+
+s\bs\bs\bst\bt\bt\bta\ba\ba\bar\br\br\brf\bf\bf\bfi\bi\bi\bis\bs\bs\bsh\bh\bh\bh
+        Shows starfish.
+
+s\bs\bs\bst\bt\bt\btr\br\br\bra\ba\ba\ban\bn\bn\bng\bg\bg\bge\be\be\be Shows strange attractors.
+
+s\bs\bs\bsu\bu\bu\bup\bp\bp\bpe\be\be\ber\br\br\brq\bq\bq\bqu\bu\bu\bua\ba\ba\bad\bd\bd\bdr\br\br\bri\bi\bi\bic\bc\bc\bcs\bs\bs\bs
+        Shows 3D mathematical shapes.  May not be  available
+        depending on how it was configured.
+
+s\bs\bs\bsw\bw\bw\bwa\ba\ba\bar\br\br\brm\bm\bm\bm   Shows a swarm of bees following a wasp.
+
+s\bs\bs\bsw\bw\bw\bwi\bi\bi\bir\br\br\brl\bl\bl\bl   Shows animated swirling patterns.
+
+t\bt\bt\bte\be\be\bet\bt\bt\btr\br\br\bri\bi\bi\bis\bs\bs\bs  Shows tetris.
+
+t\bt\bt\bth\bh\bh\bho\bo\bo\bor\br\br\brn\bn\bn\bnb\bb\bb\bbi\bi\bi\bir\br\br\brd\bd\bd\bd
+        Shows an animated Bird in a Thorn Bush fractal map.
+
+t\bt\bt\btr\br\br\bri\bi\bi\bia\ba\ba\ban\bn\bn\bng\bg\bg\bgl\bl\bl\ble\be\be\be
+        Shows a triangular mountain range.
+
+t\bt\bt\btu\bu\bu\bub\bb\bb\bbe\be\be\be    Shows an animated tube.
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    6
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+t\bt\bt\btu\bu\bu\bur\br\br\brt\bt\bt\btl\bl\bl\ble\be\be\be  Shows turtle fractals.
+
+v\bv\bv\bvi\bi\bi\bin\bn\bn\bne\be\be\bes\bs\bs\bs   Shows fractal-like vines.
+
+v\bv\bv\bvo\bo\bo\bot\bt\bt\bte\be\be\ber\br\br\brs\bs\bs\bs  Shows Dewdney's Voters.
+
+w\bw\bw\bwa\ba\ba\bat\bt\bt\bto\bo\bo\bor\br\br\br   Shows  Dewdney's  Water-Torus  planet  of  fish  and
+        sharks.
+
+w\bw\bw\bwi\bi\bi\bir\br\br\bre\be\be\be    Shows a random circuit with 2 electrons.
+
+w\bw\bw\bwo\bo\bo\bor\br\br\brl\bl\bl\bld\bd\bd\bd   Shows spinning Earths.
+
+w\bw\bw\bwo\bo\bo\bor\br\br\brm\bm\bm\bm    Shows wiggly worms.
+
+x\bx\bx\bxj\bj\bj\bja\ba\ba\bac\bc\bc\bck\bk\bk\bk   Shows Jack having one of those days.
+
+b\bb\bb\bbl\bl\bl\bla\ba\ba\ban\bn\bn\bnk\bk\bk\bk   Shows nothing but a black screen.  Does not show  up
+        in random mode.
+
+b\bb\bb\bbo\bo\bo\bom\bm\bm\bmb\bb\bb\bb    Shows a bomb and will autologout after a time.  Does
+        not  show  up  in  random  mode and may be available
+        depending on how it was configured.
+
+r\br\br\bra\ba\ba\ban\bn\bn\bnd\bd\bd\bdo\bo\bo\bom\bm\bm\bm  Shows a random mode from  above  except  blank  (and
+        bomb).
+
+
+-d\bd\bd\bde\be\be\bel\bl\bl\bla\ba\ba\bay\by\by\by _\bu_\bs_\be_\bc_\bs
+     The _\bd_\be_\bl_\ba_\by option sets the speed at which  a  mode  will
+     operate.   It simply sets the number of microseconds to
+     delay between batches of animations.  In blank mode, it
+     is  important  to  set  this  to  some  small number of
+     seconds,  because  the  keyboard  and  mouse  are  only
+     checked  after  each delay, so you cannot set the delay
+     too high, but a delay of zero would needlessly  consume
+     cpu  checking  for  mouse and keyboard input in a tight
+     loop, since blank mode has no work to do.
+
+-c\bc\bc\bco\bo\bo\bou\bu\bu\bun\bn\bn\bnt\bt\bt\bt _\bn_\bu_\bm
+     The _\bb_\ba_\bt_\bc_\bh_\bc_\bo_\bu_\bn_\bt option sets number of _\bt_\bh_\bi_\bn_\bg_\bs to  do  per
+     batch to _\bn_\bu_\bm .
+
+     In ant mode this refers the number of ants.
+
+     In atlantis mode it is the number of sharks.
+
+     In ball mode it is the number of balls.
+
+     In bat mode it is the number of  bats,  could  be  less
+     because of conflicts.
+
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    7
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     In blot mode this refers to the number of  pixels  ren-
+     dered in the same color.
+
+     In bouboule mode it is the number of stars.
+
+     In bounce mode it is the number of balls, could be less
+     because of conflicts.
+
+     In braid mode it is the upper bound number of strands.
+
+     In bubble mode it is the number of bubbles.
+
+     In bubble3d mode it is the number of bubbles.
+
+     In bug mode it is the number of  bugs,  could  be  less
+     because of conflicts.
+
+     In cage mode it is means nothing.
+
+     In cartoon mode it means nothing.
+
+     In clock mode it is the percentage of the  screen,  but
+     less than 100%.
+
+     In coral mode it is the number of seeds.
+
+     In crystal mode it is the number of polygons.
+
+     In daisy mode it is the  number  flowers  that  make  a
+     meadow.
+
+     In dclock mode it means nothing.
+
+     In deco mode it is the depth.
+
+     In demon mode this refers the number of colors.
+
+     In dilemma mode  this  refers  the  number  of  initial
+     defectors.
+
+     In discrete mode it is the number of points.
+
+     In drift mode it is the number  of  levels  to  recurse
+     (larger = more complex).
+
+     In eyes mode it is the number of eyes.
+
+     In fadeplot mode it is the number of steps.
+
+     In flag mode it means nothing.
+
+     In flame mode it is the number  of  levels  to  recurse
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    8
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     (larger = more complex).
+
+     In flow mode it is the number of bees.
+
+     In forest mode it is  the  number  trees  that  make  a
+     forest.
+
+     In galaxy mode it means the number of galaxies.
+
+     In gears mode it is the number of degrees to rotate the
+     set of gears by.
+
+     In goop mode it is the number of blobs per plane.
+
+     In grav mode it is the number of planets.
+
+     In helix mode it means nothing.
+
+     In hop mode this refers to the number  of  pixels  ren-
+     dered in the same color.
+
+     In hyper mode it the number of dimensions.
+
+     In ico mode it is the ith platonic solid.
+
+     In ifs mode it means nothing.
+
+     In image mode it means it is the  number  of  logos  on
+     screen at once.
+
+     In julia mode it is the depth of recursion.
+
+     In kaleid mode it is the number of pens.
+
+     In kumppa mode it means nothing.
+
+     In laser mode it is the number lasers.
+
+     In life mode it is the number of generations  before  a
+     glider is introduced.
+
+     In life1d mode it means nothing.
+
+     In life3d mode it is the number of generations before a
+     glider is introduced.
+
+     In lisa mode it is the number of loops.
+
+     In lissie mode it is the number of worms.
+
+     In loop mode it means nothing.
+
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                    9
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     In mandelbrot mode it is the order.
+
+     In marquee mode it means nothing.
+
+     In matrix mode it means nothing.
+
+     In maze mode it means nothing.
+
+     In moebius mode it is means nothing.
+
+     In morph3d mode it is the ith platonic solid.
+
+     In mountain mode it is the number of mountains.
+
+     In munch mode it means nothing.
+
+     In nose mode it means nothing.
+
+     In qix mode it is the number of points.
+
+     In pacman mode it means the number of ghosts.
+
+     In penrose mode it means nothing.
+
+     In petal mode it the greatest random number of petals.
+
+     In pipes mode it shows different joints,  0  random,  1
+     spherical, 2 bolted elbow, 3 elbow, and 4 alternating.
+
+     In puzzle mode it the number of moves.
+
+     In pyro mode it is the maximum number flying rockets at
+     one time.
+
+     In roll mode it is the number of points.
+
+     In rotor mode it is the number of rotor  thingys  which
+     whirr...
+
+     In rubik mode it is the number of moves.
+
+     In shape mode it means nothing.
+
+     In sierpinski mode it is the number of points.
+
+     In slip mode it means nothing.
+
+     In sphere mode it means nothing.
+
+     In spiral mode it is the number of spirals.
+
+     In spline mode it is the number of points "splined".
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   10
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     In sproingies mode it is the number of sproingies.
+
+     In stairs mode it is means nothing.
+
+     In star mode it is the number of stars on the screen at
+     once.
+
+     In starfish mode it means nothing.
+
+     In strange mode it means nothing.
+
+     In superquadrics mode its the number of horizontal  and
+     vertical lines in the superquadric.
+
+     In swirl mode it means the number of "knots".
+
+     In swarm mode it is the number of bees.
+
+     In thornbird mode it is the number of points.
+
+     In triangular mode it is the number of mountains.
+
+     In tube mode it is a rectangle (= 1), an ellipse (= 2),
+     or a polygon if greater.
+
+     In turtle mode it means nothing.
+
+     In vines mode it is draw a complete vine  (=  0)  or  a
+     portion (= 1).
+
+     In voters mode it means the number of parties, 2 or 3.
+
+     In wator mode it means the breed time for the fish.
+
+     In wire mode it means the length of the circuit.
+
+     In world mode it is the number of worlds.
+
+     In worm mode it is the number of worms.
+
+     In blank mode it means nothing.
+
+     In bomb mode it means the number of minutes to  autolo-
+     gout.
+
+     A negative _\bc_\bo_\bu_\bn_\bt allows for randomness.  The range from
+     the  minimum allowed nonnegative _\bc_\bo_\bu_\bn_\bt for a particular
+     mode to the ABS( _\bc_\bo_\bu_\bn_\bt ) (or maximum  allowed  _\bc_\bo_\bu_\bn_\bt  ,
+     whichever is less).
+
+-b\bb\bb\bba\ba\ba\bat\bt\bt\btc\bc\bc\bch\bh\bh\bhc\bc\bc\bco\bo\bo\bou\bu\bu\bun\bn\bn\bnt\bt\bt\bt _\bn_\bu_\bm
+     The _\bb_\ba_\bt_\bc_\bh_\bc_\bo_\bu_\bn_\bt option is depreciated but  should  still
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   11
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     work as _\bc_\bo_\bu_\bn_\bt.
+
+-c\bc\bc\bcy\by\by\byc\bc\bc\bcl\bl\bl\ble\be\be\bes\bs\bs\bs _\bn_\bu_\bm
+     The _\bc_\by_\bc_\bl_\be_\bs option sets the number of cycles until  time
+     out  for  ant, blot, braid, bug, clock, crystal, daisy,
+     deco,  demon,  dilemma,  discrete,  eyes,  flag,  flow,
+     forest,  galaxy,  helix,  hop, hyper, ico, laser, life,
+     life1d, life3d, lisa, lissie, loop,  mandelbrot,  moun-
+     tain,  petal,  sierpinski, shape, spline +erase, thorn-
+     bird, triangle, tube, voters,  wator,  and  wire.   For
+     worm  it is the length of the lines, for atlantis it is
+     the shark speed, for fadeplot, julia and spiral  it  is
+     the  length  of  the  trail  of  dots,  munch it is the
+     minimum size of the squares, for kaleid it is the %  of
+     black,  for  qix  it is the number of lines, for spline
+     -erase it means the number of splines * 64 (for  compa-
+     tibility  with  +erase),  for gears it is the number of
+     degrees to increment the spin  of  each  gear  by,  for
+     pipes it is the number of systems to draw before clear-
+     ing the screen, for rubik it is the number of steps  to
+     complete  a 90 move, for superquadrics it is the number
+     of frames it takes to morph from one shape to  another.
+     For others it means nothing.
+
+-s\bs\bs\bsi\bi\bi\biz\bz\bz\bze\be\be\be _\bn_\bu_\bm
+     The _\bs_\bi_\bz_\be option sets the size maximum size of a star in
+     bouboule,  pyro  and  star,  size  of  ball in ball and
+     bounce, size of bat in bat, maximum size of  bubble  in
+     bubble, size of clock in clock, minimum size of rectan-
+     gles in deco, size of the polygon in crystal,  size  of
+     polyhedron  in  ico,  size of lissie in lissie, size of
+     dots of flag, for kaleid it is the symmetry,  width  of
+     maze  hallway,  size of side of penrose tile, radius of
+     loop in lisa, radius of ball in roll, number of corners
+     in  sierpinski,  size of tube in tube, width of worm in
+     worm, line width in rotor, size of cells in  ant,  bug,
+     dilemma,  life,  life1d, pacman, tetris, voters, wator,
+     and wire.  In pipes it is the maximum length of a  sys-
+     tem.   In atlantis it is the shark size.  In sproingies
+     it is the size of the screen.  A negative number allows
+     for randomness, similar to _\bc_\bo_\bu_\bn_\bt.
+
+-n\bn\bn\bnc\bc\bc\bco\bo\bo\bol\bl\bl\blo\bo\bo\bor\br\br\brs\bs\bs\bs _\bn_\bu_\bm
+     The _\bn_\bc_\bo_\bl_\bo_\br_\bs option sets the maximum number of colors to
+     be used.
+
+-s\bs\bs\bsa\ba\ba\bat\bt\bt\btu\bu\bu\bur\br\br\bra\ba\ba\bat\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn _\bv_\ba_\bl_\bu_\be
+     The _\bs_\ba_\bt_\bu_\br_\ba_\bt_\bi_\bo_\bn option sets saturation of the color ramp
+     used  to  _\bv_\ba_\bl_\bu_\be  .  0  is  grayscale and 1 is very rich
+     color.  0.4 is a nice pastel.
+
+-e\be\be\ber\br\br\bra\ba\ba\bas\bs\bs\bse\be\be\bem\bm\bm\bmo\bo\bo\bod\bd\bd\bde\be\be\be _\bm_\bo_\bd_\be_\bn_\ba_\bm_\be
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   12
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     As of this writing there are over 9  erase  modes  sup-
+     ported  (if  its  not  chosen its assumed random).  The
+     erase modes are random_lines, random_squares, venetian,
+     triple_wipe, quad_wipe, circle_wipe, three_circle_wipe,
+     squaretate, no_fade.
+
+-e\be\be\ber\br\br\bra\ba\ba\bas\bs\bs\bse\be\be\bed\bd\bd\bde\be\be\bel\bl\bl\bla\ba\ba\bay\by\by\by _\bu_\bs_\be_\bc_\bs
+     The _\be_\br_\ba_\bs_\be_\bd_\be_\bl_\ba_\by option sets the number  of  microseconds
+     for  steps  of  the  e\be\be\ber\br\br\bra\ba\ba\bas\bs\bs\bse\be\be\bem\bm\bm\bmo\bo\bo\bod\bd\bd\bde\be\be\be  (a setting of 0 and the
+     e\be\be\ber\br\br\bra\ba\ba\bas\bs\bs\bse\be\be\bem\bm\bm\bmo\bo\bo\bod\bd\bd\bde\be\be\be is bypassed).
+
++\b+\b+\b+/\b/\b/\b/-\b-\b-\b-n\bn\bn\bno\bo\bo\bol\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk
+     The _\bn_\bo_\bl_\bo_\bc_\bk option causes x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk to only  draw  the  pat-
+     terns and not lock the display.  A key press or a mouse
+     click will terminate the screen saver.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+i\bi\bi\bin\bn\bn\bnw\bw\bw\bwi\bi\bi\bin\bn\bn\bnd\bd\bd\bdo\bo\bo\bow\bw\bw\bw
+     Runs x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk in a window, so that you can iconify,  move,
+     or resize it and still use your screen for other stuff.
+     When running in a window, x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk no  longer  locks  your
+     screen, it just looks good.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+i\bi\bi\bin\bn\bn\bnr\br\br\bro\bo\bo\boo\bo\bo\bot\bt\bt\bt
+     Runs x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk in your  root  window.   Like  the  _\bi_\bn_\bw_\bi_\bn_\bd_\bo_\bw
+     option  it  no  longer  locks the screen, it just looks
+     good.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\bre\be\be\bem\bm\bm\bmo\bo\bo\bot\bt\bt\bte\be\be\be
+     The _\br_\be_\bm_\bo_\bt_\be option tells x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk  to  not  stop  you  from
+     locking remote X11 servers.  This option should be used
+     with care and is intended mainly to lock X11  terminals
+     which  cannot  run  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk locally.  If you lock someone
+     else's workstation, they will have to know  y\by\by\byo\bo\bo\bou\bu\bu\bur\br\br\br  pass-
+     word   to  unlock  it.   Using  +_\br_\be_\bm_\bo_\bt_\be  overrides  any
+     resource derived values for _\br_\be_\bm_\bo_\bt_\be and  prevents  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk
+     from  being  used  to lock other X11 servers.  (Use `+'
+     instead of `-' to override resources for other  options
+     that can take the `+' modifier similarly.)
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+m\bm\bm\bmo\bo\bo\bon\bn\bn\bno\bo\bo\bo
+     The _\bm_\bo_\bn_\bo option causes  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk  to  display  monochrome,
+     (black  and  white)  pixels  rather  than  the  default
+     colored ones on color displays.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\bal\bl\bl\bll\bl\bl\blo\bo\bo\bow\bw\bw\bwa\ba\ba\bac\bc\bc\bcc\bc\bc\bce\be\be\bes\bs\bs\bss\bs\bs\bs
+     This option is required for servers which do not  allow
+     clients  to modify the host access control list.  It is
+     also useful if you need to run x clients  on  a  server
+     which is locked for some reason...  When _\ba_\bl_\bl_\bo_\bw_\ba_\bc_\bc_\be_\bs_\bs is
+     true, the X11 server is left open for clients to attach
+     and  thus  lowers  the  inherent  security of this lock
+     screen.  A side effect of using this option is that  if
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   13
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk  is  killed -KILL, the access control list is not
+     lost.
+
+-v\bv\bv\bvt\bt\bt\btl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk _\bm_\bo_\bd_\be_\bn_\ba_\bm_\be
+     This option is used on a XFree86 system  to  manage  VT
+     switching in [off|noswitch|switch|restore] mode.
+
+_\bo_\bf_\bf       means no VT switch locking.
+
+_\bs_\bw_\bi_\bt_\bc_\bh    means VT switch locking + switching  to  xlock  VT
+          when activated.
+
+_\br_\be_\bs_\bt_\bo_\br_\be   means VT switch locking + switching  to  xlock  VT
+          when  activated  +  switching  back to previous VT
+          when desactivated.
+
+_\bn_\bo_\bs_\bw_\bi_\bt_\bc_\bh  means VT switch locking  only  when  xlock  VT  is
+          active.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\bal\bl\bl\bll\bl\bl\blo\bo\bo\bow\bw\bw\bwr\br\br\bro\bo\bo\boo\bo\bo\bot\bt\bt\bt
+     The _\ba_\bl_\bl_\bo_\bw_\br_\bo_\bo_\bt option allows the root password to unlock
+     the  server as well as the user who started x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk.  May
+     not be able to turn this on and off depending  on  your
+     system and how x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk was configured.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bde\be\be\beb\bb\bb\bbu\bu\bu\bug\bg\bg\bg
+     Allows x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk to be debugged by doing  all  but  locking
+     the screen.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bde\be\be\bes\bs\bs\bsc\bc\bc\bcr\br\br\bri\bi\bi\bip\bp\bp\bpt\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn
+     The  _\bd_\be_\bs_\bc_\br_\bi_\bp_\bt_\bi_\bo_\bn  option  causes  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk  shows  a  mode
+     description  above  password window.  The default is to
+     show this description.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\bec\bc\bc\bch\bh\bh\bho\bo\bo\bok\bk\bk\bke\be\be\bey\by\by\bys\bs\bs\bs
+     The _\be_\bc_\bh_\bo_\bk_\be_\by_\bs option causes x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk to echo '?' characters
+     for each key typed into the password prompt.  Some con-
+     sider this a security risk, so the default  is  to  not
+     echo anything.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\ben\bn\bn\bna\ba\ba\bab\bb\bb\bbl\bl\bl\ble\be\be\bes\bs\bs\bsa\ba\ba\bav\bv\bv\bve\be\be\ber\br\br\br
+     By default x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk will disable  the  normal  X  server's
+     screen  saver  since  it is in effect a replacement for
+     it.  Since it is possible to set delay parameters  long
+     enough  to  cause  phosphor burn on some displays, this
+     option will turn back on the default screen saver which
+     is very careful to keep most of the screen black.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\bre\be\be\bes\bs\bs\bse\be\be\bet\bt\bt\bts\bs\bs\bsa\ba\ba\bav\bv\bv\bve\be\be\ber\br\br\br
+     By default x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk will call XResetScreenSaver.  This may
+     be undesirable with DPMS monitors.
+
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   14
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+g\bg\bg\bgr\br\br\bra\ba\ba\bab\bb\bb\bbm\bm\bm\bmo\bo\bo\bou\bu\bu\bus\bs\bs\bse\be\be\be
+     The _\bg_\br_\ba_\bb_\bm_\bo_\bu_\bs_\be option causes x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk to grab the mouse and
+     keyboard,  this is the default.  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk can not lock the
+     screen without this.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+g\bg\bg\bgr\br\br\bra\ba\ba\bab\bb\bb\bbs\bs\bs\bse\be\be\ber\br\br\brv\bv\bv\bve\be\be\ber\br\br\br
+     The _\bg_\br_\ba_\bb_\bs_\be_\br_\bv_\be_\br option causes x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk to grab the  server.
+     This  is not usually needed but some unsecure X servers
+     can be defeated without this.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+i\bi\bi\bin\bn\bn\bns\bs\bs\bst\bt\bt\bta\ba\ba\bal\bl\bl\bll\bl\bl\bl
+     Allows x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk to install its own colormap if x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk  runs
+     out  of  colors.   May  not  work  on  with some window
+     managers (fvwm) and does  not  work  with  the  -inroot
+     option.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+m\bm\bm\bmo\bo\bo\bou\bu\bu\bus\bs\bs\bse\be\be\bem\bm\bm\bmo\bo\bo\bot\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn
+     Allows you to turn on and off the  sensitivity  to  the
+     mouse to bring up the password window.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+s\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd
+     Allows you to turn on and off sound if  installed  with
+     the capability.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\bti\bi\bi\bim\bm\bm\bme\be\be\bee\be\be\bel\bl\bl\bla\ba\ba\bap\bp\bp\bps\bs\bs\bse\be\be\bed\bd\bd\bd
+     Allows you to find out how long a machine is locked  so
+     you  can  complain  to an administrator that someone is
+     hogging a machine.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+u\bu\bu\bus\bs\bs\bse\be\be\bef\bf\bf\bfi\bi\bi\bir\br\br\brs\bs\bs\bst\bt\bt\bt
+     The _\bu_\bs_\be_\bf_\bi_\br_\bs_\bt option causes x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk to use  the  keystroke
+     which got you to the password screen as the first char-
+     acter in the password.  The default is  to  ignore  the
+     first key pressed.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+v\bv\bv\bve\be\be\ber\br\br\brb\bb\bb\bbo\bo\bo\bos\bs\bs\bse\be\be\be
+     Verbose mode, tells what options it is going to use.
+
+-n\bn\bn\bni\bi\bi\bic\bc\bc\bce\be\be\be _\bn_\bi_\bc_\be_\bl_\be_\bv_\be_\bl
+     The _\bn_\bi_\bc_\be option sets system nicelevel of the x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk pro-
+     cess to _\bn_\bi_\bc_\be_\bl_\be_\bv_\be_\bl .
+
+-l\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bkd\bd\bd\bde\be\be\bel\bl\bl\bla\ba\ba\bay\by\by\by _\bs_\be_\bc_\bo_\bn_\bd_\bs
+     The _\bl_\bo_\bc_\bk_\bd_\be_\bl_\ba_\by option sets the number of _\bs_\be_\bc_\bo_\bn_\bd_\bs  before
+     the  screen  needs a password to be unlocked.  Good for
+     use with an autolocking mechanism like xautolock(1).
+
+-t\bt\bt\bti\bi\bi\bim\bm\bm\bme\be\be\beo\bo\bo\bou\bu\bu\but\bt\bt\bt _\bs_\be_\bc_\bo_\bn_\bd_\bs
+     The _\bt_\bi_\bm_\be_\bo_\bu_\bt option sets the number  of  _\bs_\be_\bc_\bo_\bn_\bd_\bs  before
+     the password screen will time out.
+
+-f\bf\bf\bfo\bo\bo\bon\bn\bn\bnt\bt\bt\bt _\bf_\bo_\bn_\bt_\bn_\ba_\bm_\be
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   15
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     The _\bf_\bo_\bn_\bt option sets the font to be used on the  prompt
+     screen.
+
+-p\bp\bp\bpl\bl\bl\bla\ba\ba\ban\bn\bn\bnf\bf\bf\bfo\bo\bo\bon\bn\bn\bnt\bt\bt\bt _\bf_\bo_\bn_\bt_\bn_\ba_\bm_\be
+     option sets the font to be used for the  text  that  is
+     displayed in the lower part of the password screen.
+
+-f\bf\bf\bfg\bg\bg\bg _\bc_\bo_\bl_\bo_\br
+     The _\bf_\bg option sets the color of the text on  the  pass-
+     word screen to _\bc_\bo_\bl_\bo_\br .
+
+-b\bb\bb\bbg\bg\bg\bg _\bc_\bo_\bl_\bo_\br
+     The _\bb_\bg option sets the color of the background  on  the
+     password screen to _\bc_\bo_\bl_\bo_\br .
+
+-f\bf\bf\bfo\bo\bo\bor\br\br\bre\be\be\beg\bg\bg\bgr\br\br\bro\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bc_\bo_\bl_\bo_\br
+     The _\bf_\bo_\br_\be_\bg_\br_\bo_\bu_\bn_\bd option sets the color of the text on the
+     password screen to _\bc_\bo_\bl_\bo_\br .
+
+-b\bb\bb\bba\ba\ba\bac\bc\bc\bck\bk\bk\bkg\bg\bg\bgr\br\br\bro\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bc_\bo_\bl_\bo_\br
+     The _\bb_\ba_\bc_\bk_\bg_\br_\bo_\bu_\bn_\bd option sets the color of the  background
+     on the password screen to _\bc_\bo_\bl_\bo_\br .
+
+-u\bu\bu\bus\bs\bs\bse\be\be\ber\br\br\brn\bn\bn\bna\ba\ba\bam\bm\bm\bme\be\be\be _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg is shown in front of user name, defaults to
+     "Name: ".
+
+-p\bp\bp\bpa\ba\ba\bas\bs\bs\bss\bs\bs\bsw\bw\bw\bwo\bo\bo\bor\br\br\brd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg is the password prompt string, defaults  to
+     "Password: ".
+
+-i\bi\bi\bin\bn\bn\bnf\bf\bf\bfo\bo\bo\bo _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg is an informational  message  to  tell  the
+     user what to do, defaults to "Enter password to unlock;
+     select icon to lock.".
+
+-v\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bda\ba\ba\bat\bt\bt\bte\be\be\be _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg is a message  shown  while  validating  the
+     password, defaults to "Validating login..."
+
+-i\bi\bi\bin\bn\bn\bnv\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text  _\bs_\bt_\br_\bi_\bn_\bg  is  a  message  shown  when  password  is
+     invalid, defaults to "Invalid login."
+
+-g\bg\bg\bge\be\be\beo\bo\bo\bom\bm\bm\bme\be\be\bet\bt\bt\btr\br\br\bry\by\by\by _\bg_\be_\bo_\bm
+     The _\bg_\be_\bo_\bm_\be_\bt_\br_\by option sets _\bg_\be_\bo_\bm the size  and  offset  of
+     the  lock  window  (normally  the  entire screen).  The
+     entire screen format is still  used  for  entering  the
+     password.  The purpose is to see the screen even though
+     it is locked.  This should be used with  caution  since
+     many of the modes will fail if the windows are far from
+     square or are too small  (size  must  be  greater  than
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   16
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     0x0).   This  should  also be used with -enablesaver to
+     protect screen from phosphor burn.
+
+-i\bi\bi\bic\bc\bc\bco\bo\bo\bon\bn\bn\bng\bg\bg\bge\be\be\beo\bo\bo\bom\bm\bm\bme\be\be\bet\bt\bt\btr\br\br\bry\by\by\by _\bg_\be_\bo_\bm
+     The _\bi_\bc_\bo_\bn_\bg_\be_\bo_\bm_\be_\bt_\br_\by option  sets  _\bg_\be_\bo_\bm  the  size  of  the
+     iconic  screen  (normally 64x64) seen when entering the
+     password.  This should be used with caution since  many
+     of  the  modes  will  fail  if the windows are far from
+     square or are too small  (size  must  be  greater  than
+     0x0).   The  greatest size is 256x256.  There should be
+     some limit so  users  could  see  who  has  locked  the
+     screen.  Position information of icon is ignored.
+
+-g\bg\bg\bgl\bl\bl\blg\bg\bg\bge\be\be\beo\bo\bo\bom\bm\bm\bme\be\be\bet\bt\bt\btr\br\br\bry\by\by\by _\bg_\be_\bo_\bm
+     The _\bg_\bl_\bg_\be_\bo_\bm_\be_\bt_\br_\by option sets _\bg_\be_\bo_\bm the size of the  screen
+     for gl modes.  Not normally available or needed.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+w\bw\bw\bwi\bi\bi\bir\br\br\bre\be\be\bef\bf\bf\bfr\br\br\bra\ba\ba\bam\bm\bm\bme\be\be\be
+     Turn on/off wireframe, available  on  atlantis,  daisy,
+     gears, life3d, mountain, sproingies, superquadrics, and
+     triangle.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+u\bu\bu\bus\bs\bs\bse\be\be\be3\b3\b3\b3d\bd\bd\bd
+     Turn on/off 3d view, available on bouboule, pyro, star,
+     and worm.
+
+-d\bd\bd\bde\be\be\bel\bl\bl\blt\bt\bt\bta\ba\ba\ba3\b3\b3\b3d\bd\bd\bd _\bv_\ba_\bl_\bu_\be
+     Space between the center of your 2 eyes for 3d mode.
+
+-n\bn\bn\bno\bo\bo\bon\bn\bn\bne\be\be\be3\b3\b3\b3d\bd\bd\bd _\bc_\bo_\bl_\bo_\br
+     Color used for empty size in 3d mode.
+
+-r\br\br\bri\bi\bi\big\bg\bg\bgh\bh\bh\bht\bt\bt\bt3\b3\b3\b3d\bd\bd\bd _\bc_\bo_\bl_\bo_\br
+     Color used for right eye in 3d mode.
+
+-l\bl\bl\ble\be\be\bef\bf\bf\bft\bt\bt\bt3\b3\b3\b3d\bd\bd\bd _\bc_\bo_\bl_\bo_\br
+     Color used for left eye in 3d mode.
+
+-b\bb\bb\bbo\bo\bo\bot\bt\bt\bth\bh\bh\bh3\b3\b3\b3d\bd\bd\bd _\bc_\bo_\bl_\bo_\br
+     Color used for overlapping images for  left  and  right
+     eye in 3d mode.
+
+-p\bp\bp\bpr\br\br\bro\bo\bo\bog\bg\bg\bgr\br\br\bra\ba\ba\bam\bm\bm\bm _\bp_\br_\bo_\bg_\br_\ba_\bm_\bn_\ba_\bm_\be
+     The _\bp_\br_\bo_\bg_\br_\ba_\bm option sets the program to be used  as  the
+     fortune generator.  Currently used only for marquee and
+     nose modes.
+
+-m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\bes\bs\bs\bsf\bf\bf\bfi\bi\bi\bil\bl\bl\ble\be\be\be _\bf_\bo_\br_\bm_\ba_\bt_\bt_\be_\bd-_\bf_\bi_\bl_\be_\bn_\ba_\bm_\be
+     The _\bm_\be_\bs_\bs_\ba_\bg_\be_\bs_\bf_\bi_\bl_\be option sets the file to be used as the
+     fortune  generator.   The  first entry is the number of
+     fortunes, the next line  contains  the  first  fortune.
+     Fortunes  begin  with  a  "%%"  on  a  line  by itself.
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   17
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     Currently used only for marquee and nose modes.  If one
+     exists, it takes precedence over the fortune program.
+
+-m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\bef\bf\bf\bfi\bi\bi\bil\bl\bl\ble\be\be\be _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be
+     The _\bm_\be_\bs_\bs_\ba_\bg_\be_\bf_\bi_\bl_\be option sets the file whose contents are
+     displayed.   Currently  used  only for marquee and nose
+     modes.  If one exists, it  takes  precedence  over  the
+     fortune program and messagesfile.
+
+-m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\be _\bt_\be_\bx_\bt_\bs_\bt_\br_\bi_\bn_\bg
+     The _\bm_\be_\bs_\bs_\ba_\bg_\be option sets the text to be displayed  in  a
+     mode.   Currently  used only for flag, marquee and nose
+     modes.  If one exists, it  takes  precedence  over  the
+     fortune program, messagesfile and message.
+
+-m\bm\bm\bme\be\be\bes\bs\bs\bss\bs\bs\bsa\ba\ba\bag\bg\bg\bge\be\be\bef\bf\bf\bfo\bo\bo\bon\bn\bn\bnt\bt\bt\bt _\bf_\bo_\bn_\bt_\bn_\ba_\bm_\be
+     The _\bm_\be_\bs_\bs_\ba_\bg_\be_\bf_\bo_\bn_\bt option sets the font to be used in  the
+     mode.   Currently used only for flag, marquee, and nose
+     modes.
+
+-b\bb\bb\bbi\bi\bi\bit\bt\bt\btm\bm\bm\bma\ba\ba\bap\bp\bp\bp _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be
+     The _\bb_\bi_\bt_\bm_\ba_\bp option sets the xbm, xpm, or ras file to  be
+     displayed with flag, image, life, life1d, maze, or puz-
+     zle mode.  For eyes and  pacman  only  a  xbm  file  is
+     accepted.   Certain modes reject the bitmap if too big.
+     /
+
+
+2 M\bM\bM\bMO\bO\bO\bOR\bR\bR\bRE\bE\bE\bE O\bO\bO\bOP\bP\bP\bPT\bT\bT\bTI\bI\bI\bIO\bO\bO\bON\bN\bN\bNS\bS\bS\bS (\b(\b(\b(t\bt\bt\bth\bh\bh\bhe\be\be\bes\bs\bs\bse\be\be\be m\bm\bm\bma\ba\ba\bay\by\by\by n\bn\bn\bno\bo\bo\bot\bt\bt\bt b\bb\bb\bbe\be\be\be a\ba\ba\bav\bv\bv\bva\ba\ba\bai\bi\bi\bil\bl\bl\bla\ba\ba\bab\bb\bb\bbl\bl\bl\ble\be\be\be)\b)\b)\b)
+-c\bc\bc\bcp\bp\bp\bpa\ba\ba\bas\bs\bs\bss\bs\bs\bsw\bw\bw\bwd\bd\bd\bd _\bc_\br_\by_\bp_\bt_\be_\bd-_\bp_\ba_\bs_\bs_\bw_\bo_\br_\bd
+     The _\bc_\bp_\ba_\bs_\bs_\bw_\bd option sets the key to be this text  string
+     to unlock x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk instead of password file.
+
+-f\bf\bf\bfo\bo\bo\bor\br\br\brc\bc\bc\bce\be\be\beL\bL\bL\bLo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\bt _\bm_\bi_\bn_\bu_\bt_\be_\bs
+     The _\bf_\bo_\br_\bc_\be_\bL_\bo_\bg_\bo_\bu_\bt option sets _\bm_\bi_\bn_\bu_\bt_\be_\bs to auto-logout.
+
+-l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btB\bB\bB\bBu\bu\bu\but\bt\bt\btt\bt\bt\bto\bo\bo\bon\bn\bn\bnL\bL\bL\bLa\ba\ba\bab\bb\bb\bbe\be\be\bel\bl\bl\bl _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg is a message  shown  inside  logout  button
+     when logout button is displayed.  Defaults to "Logout".
+
+-l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btB\bB\bB\bBu\bu\bu\but\bt\bt\btt\bt\bt\bto\bo\bo\bon\bn\bn\bnH\bH\bH\bHe\be\be\bel\bl\bl\blp\bp\bp\bp _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg is a message shown  outside  logout  button
+     when  logout  button  is displayed.  Defaults to "Click
+     the \"Logout\" button to log  out  current\n  user  and
+     make workstation available."
+
+-l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btF\bF\bF\bFa\ba\ba\bai\bi\bi\bil\bl\bl\ble\be\be\bed\bd\bd\bdS\bS\bS\bSt\bt\bt\btr\br\br\bri\bi\bi\bin\bn\bn\bng\bg\bg\bg _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg  is  a  message  shown  when  a  logout  is
+     attempted  and  fails.   Defaults  to  "Logout  attempt
+     FAILED.\n  Current  user  could  not  be  automatically
+     logged out."
+
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   18
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bdt\bt\bt\bts\bs\bs\bsa\ba\ba\bav\bv\bv\bve\be\be\ber\br\br\br
+     Turn on/off CDE Saver Mode.  This option is only avail-
+     able if CDE support was compiled in.
+
+-m\bm\bm\bmo\bo\bo\bod\bd\bd\bdu\bu\bu\bul\bl\bl\ble\be\be\bep\bp\bp\bpa\ba\ba\bat\bt\bt\bth\bh\bh\bh _\bp_\ba_\bt_\bh
+     The _\bm_\bo_\bd_\bu_\bl_\be_\bp_\ba_\bt_\bh option sets the _\bd_\bi_\br_\be_\bc_\bt_\bo_\br_\bi_\be_\bs  that  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk
+     searches  for  mode  modules  to  load.   It is a colon
+     separated list of directories to  search.  If  "%S"  is
+     included  in  the  path,  it is replaced by the default
+     modulepath.  To add a private module directory  to  the
+     default  path, use something like '%S:~/mymoduledir' as
+     the path.  This option is only available if module sup-
+     port was compiled in.
+
+-l\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bks\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg references  sound  to  use  at  lock  time.
+     Default  sound,  male  voice:   "Thank  you,  for  your
+     cooperation."
+
+-i\bi\bi\bin\bn\bn\bnf\bf\bf\bfo\bo\bo\bos\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg references sound to  use  for  information.
+     Default sound, male voice:  "Identify please."
+
+-v\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bds\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg references sound  to  when  a  password  is
+     valid.  Default sound, female voice:  "Complete."
+
+-i\bi\bi\bin\bn\bn\bnv\bv\bv\bva\ba\ba\bal\bl\bl\bli\bi\bi\bid\bd\bd\bds\bs\bs\bso\bo\bo\bou\bu\bu\bun\bn\bn\bnd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg references sound  to  when  a  password  is
+     invalid.   Default  sound, female voice: "I am not pro-
+     grammed to give you that information."
+
+-s\bs\bs\bst\bt\bt\bta\ba\ba\bar\br\br\brt\bt\bt\btC\bC\bC\bCm\bm\bm\bmd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg command  to  execute  when  the  screen  is
+     locked.  Commonly  used instructions include:  "zaway".
+     This command, if still  running  when  the  screensaver
+     exist, will be killed.
+
+-e\be\be\ben\bn\bn\bnd\bd\bd\bdC\bC\bC\bCm\bm\bm\bmd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg command  to  execute  when  the  screen  is
+     unlocked.
+
+-l\bl\bl\blo\bo\bo\bog\bg\bg\bgo\bo\bo\bou\bu\bu\but\bt\bt\btC\bC\bC\bCm\bm\bm\bmd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg command to execute when  the  program  logs
+     the  user out (either via the autologout or by pressing
+     the logout button).
+
+-m\bm\bm\bma\ba\ba\bai\bi\bi\bil\bl\bl\blC\bC\bC\bCm\bm\bm\bmd\bd\bd\bd _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg command to  execute  when  the  program  to
+     check mail.
+
+-m\bm\bm\bma\ba\ba\bai\bi\bi\bil\bl\bl\blI\bI\bI\bIc\bc\bc\bco\bo\bo\bon\bn\bn\bn _\bs_\bt_\br_\bi_\bn_\bg
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   19
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     Text _\bs_\bt_\br_\bi_\bn_\bg of file for the "mail arrived" bitmap.
+
+-n\bn\bn\bno\bo\bo\bom\bm\bm\bma\ba\ba\bai\bi\bi\bil\bl\bl\blI\bI\bI\bIc\bc\bc\bco\bo\bo\bon\bn\bn\bn _\bs_\bt_\br_\bi_\bn_\bg
+     Text _\bs_\bt_\br_\bi_\bn_\bg of file for the "no mail" bitmap.
+
+-\b-\b-\b-d\bd\bd\bdp\bp\bp\bpm\bm\bm\bms\bs\bs\bss\bs\bs\bst\bt\bt\bta\ba\ba\ban\bn\bn\bnd\bd\bd\bdb\bb\bb\bby\by\by\by  s\bs\bs\bse\be\be\bec\bc\bc\bco\bo\bo\bon\bn\bn\bnd\bd\bd\bds\bs\bs\bs
+     Allows one to  set  DPMS  Standby  for  monitor  (0  is
+     defined  as  infinite).   (Horizontal sync on, Vertical
+     sync off, RGB guns off, power supply on, tube filaments
+     energized,   (screen  saver  mode).   Typical  17  inch
+     screen...  110 out of 120 watts with a 3  sec  recovery
+     time.)   This  option is only available if DPMS support
+     was compiled in.
+
+-\b-\b-\b-d\bd\bd\bdp\bp\bp\bpm\bm\bm\bms\bs\bs\bss\bs\bs\bsu\bu\bu\bus\bs\bs\bsp\bp\bp\bpe\be\be\ben\bn\bn\bnd\bd\bd\bd  s\bs\bs\bse\be\be\bec\bc\bc\bco\bo\bo\bon\bn\bn\bnd\bd\bd\bds\bs\bs\bs
+     Allows one to  set  DPMS  Suspend  for  monitor  (0  is
+     defined  as  infinite).  (Horizontal sync off, Vertical
+     sync on, RGB guns off, power supply off, tube filaments
+     energized.   Typical  17 inch screen ...  15 out of 120
+     watts with a 3 sec recovery time.)  This option is only
+     available if DPMS support was compiled in.
+
+-\b-\b-\b-d\bd\bd\bdp\bp\bp\bpm\bm\bm\bms\bs\bs\bso\bo\bo\bof\bf\bf\bff\bf\bf\bf  s\bs\bs\bse\be\be\bec\bc\bc\bco\bo\bo\bon\bn\bn\bnd\bd\bd\bds\bs\bs\bs
+     Allows one to set DPMS Power  Off  for  monitor  (0  is
+     defined  as  infinite).  (Horizontal sync off, Vertical
+     sync off, Small auxiliary circuit stays on  to  monitor
+     the HS/VS signals to enable power on when data needs to
+     be displayed on the screen.  Typical 17 inch screen ...
+     5  out of 120 watts with a 10 sec recovery time.)  This
+     option is only available if DPMS support  was  compiled
+     in.
+
+
+2 S\bS\bS\bSP\bP\bP\bPE\bE\bE\bEC\bC\bC\bCI\bI\bI\bIA\bA\bA\bAL\bL\bL\bL M\bM\bM\bMO\bO\bO\bOD\bD\bD\bDE\bE\bE\bE D\bD\bD\bDE\bE\bE\bEP\bP\bP\bPE\bE\bE\bEN\bN\bN\bND\bD\bD\bDE\bE\bE\bEN\bN\bN\bNT\bT\bT\bT O\bO\bO\bOP\bP\bP\bPT\bT\bT\bTI\bI\bI\bIO\bO\bO\bON\bN\bN\bNS\bS\bS\bS
+-n\bn\bn\bne\be\be\bei\bi\bi\big\bg\bg\bgh\bh\bh\bhb\bb\bb\bbo\bo\bo\bor\br\br\brs\bs\bs\bs _\bn_\bu_\bm
+     The _\bn_\be_\bi_\bg_\bh_\bb_\bo_\br_\bs option sets the number of neighbors of  a
+     cell  to  3,  4,  6,  9 (may not have real mathematical
+     meaning), or 12 for several automata modes  (_\ba_\bn_\bt,  _\bb_\bu_\bg,
+     _\bd_\be_\bm_\bo_\bn,  _\bd_\bi_\bl_\be_\bm_\bm_\ba, _\bl_\bi_\bf_\be, _\bl_\bo_\bo_\bp, and _\bw_\bi_\br_\be) (_\bb_\bu_\bg _\ba_\bn_\bd _\bl_\bo_\bo_\bp do
+     not span this full range).  Setting it to  0  typically
+     randomizes   this,   except   where  bitmaps  are  used
+     (_\bd_\bi_\bl_\be_\bm_\bm_\ba, _\bl_\bi_\bf_\be, _\bv_\bo_\bt_\be_\br_\bs, and _\bw_\ba_\bt_\bo_\br).
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\bey\by\by\bye\be\be\bes\bs\bs\bs
+     Turn on and off eyes for _\ba_\bn_\bt and _\bb_\bu_\bg.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+c\bc\bc\bcy\by\by\byc\bc\bc\bcl\bl\bl\ble\be\be\be
+     Turn on and off colour cycling  in  _\bc_\br_\by_\bs_\bt_\ba_\bl,  _\bs_\bt_\ba_\br_\bf_\bi_\bs_\bh,
+     and _\bt_\be_\bt_\br_\bi_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\btr\br\br\bra\ba\ba\bac\bc\bc\bck\bk\bk\bkm\bm\bm\bmo\bo\bo\bou\bu\bu\bus\bs\bs\bse\be\be\be
+     Turn on and off mouse interaction in _\be_\by_\be_\bs,  _\bj_\bu_\bl_\bi_\ba,  and
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   20
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     _\bs_\bw_\ba_\br_\bm.
+
+-r\br\br\bru\bu\bu\bul\bl\bl\ble\be\be\be _\bS<_\bn_\be_\bi_\bg_\bh_\bb_\bo_\br_\bh_\bo_\bo_\bd>/_\bB<_\bn_\be_\bi_\bg_\bh_\bb_\bo_\br_\bh_\bo_\bo_\bd>
+     Allows one to set the rule for _\bl_\bi_\bf_\be and _\bl_\bi_\bf_\be_\b3_\bd. Special
+     parameters:  P, picks a random rule from all rules that
+     have known patterns; G, picks a random  rule  from  all
+     rules that have known gliders.  For _\bl_\bi_\bf_\be a good example
+     is Conway's rule which  is  S23/B3.   For  _\bl_\bi_\bf_\be_\b3_\bd  good
+     examples  are  Bay's  rules  which are S45/B5, S567/B6,
+     S56/B5, and S67/B67.
+
+-l\bl\bl\bli\bi\bi\bif\bf\bf\bfe\be\be\bef\bf\bf\bfi\bi\bi\bil\bl\bl\ble\be\be\be _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be
+     The _\bl_\bi_\bf_\be_\bf_\bi_\bl_\be option sets the _\bl_\bi_\bf_\be and _\bl_\bi_\bf_\be_\b3_\bd  lifeform.
+     Only  one format is currently supported, similar to the
+     #P xlife format.  For _\bl_\bi_\bf_\be_\b3_\bd, 2 linefeeds in a row  are
+     assumed to advance the depth.
+
+-w\bw\bw\bwh\bh\bh\bha\ba\ba\bal\bl\bl\ble\be\be\bes\bs\bs\bsp\bp\bp\bpe\be\be\bee\be\be\bed\bd\bd\bd _\bn_\bu_\bm
+     Allows one to set the speed of the whales  and  dolphin
+     in _\ba_\bt_\bl_\ba_\bn_\bt_\bi_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\btr\br\br\bru\bu\bu\buc\bc\bc\bch\bh\bh\bhe\be\be\bet\bt\bt\bt
+     Turn on and off Truchet lines (trail) in _\ba_\bn_\bt.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+b\bb\bb\bbo\bo\bo\boi\bi\bi\bil\bl\bl\bl
+     Turn on and off having the bubbles bubble up in _\bb_\bu_\bb_\bb_\bl_\be.
+
+-n\bn\bn\bnx\bx\bx\bx _\bn_\bu_\bm
+     Allows one to set  the  number  of  unit  cells  in  x-
+     direction in _\bc_\br_\by_\bs_\bt_\ba_\bl.
+
+-n\bn\bn\bny\by\by\by _\bn_\bu_\bm
+     Allows one to set  the  number  of  unit  cells  in  y-
+     direction in _\bc_\br_\by_\bs_\bt_\ba_\bl.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+c\bc\bc\bce\be\be\ben\bn\bn\bnt\bt\bt\btr\br\br\bre\be\be\be
+     Turn on and off the centering on screen in _\bc_\br_\by_\bs_\bt_\ba_\bl.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+m\bm\bm\bma\ba\ba\bax\bx\bx\bxs\bs\bs\bsi\bi\bi\biz\bz\bz\bze\be\be\be
+     Turn on and off the centering on screen in _\bc_\br_\by_\bs_\bt_\ba_\bl.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+c\bc\bc\bce\be\be\bel\bl\bl\bll\bl\bl\bl
+     Turn on and off the drawing of unit cell in _\bc_\br_\by_\bs_\bt_\ba_\bl.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+g\bg\bg\bgr\br\br\bri\bi\bi\bid\bd\bd\bd
+     Turn on and off the drwing of grid of  unit  cells  (if
+     -cell is on) in _\bc_\br_\by_\bs_\bt_\ba_\bl.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+g\bg\bg\bga\ba\ba\bar\br\br\brd\bd\bd\bde\be\be\ben\bn\bn\bn
+     Turn off and on garden look in _\bd_\ba_\bi_\bs_\by.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+p\bp\bp\bpo\bo\bo\bop\bp\bp\bpe\be\be\bex\bx\bx\bx
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   21
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     Turn on and off the  population  explosion  counter  in
+     _\bd_\bc_\bl_\bo_\bc_\bk.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+f\bf\bf\bfo\bo\bo\bor\br\br\bre\be\be\bes\bs\bs\bst\bt\bt\bt
+     Turn on and off the tropical deforest  (hectares/acres)
+     counter in _\bd_\bc_\bl_\bo_\bc_\bk.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+h\bh\bh\bhi\bi\bi\biv\bv\bv\bv
+     Turn on and off the HIV infection counter in _\bd_\bc_\bl_\bo_\bc_\bk.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+l\bl\bl\bla\ba\ba\bab\bb\bb\bb
+     Turn on and off the Animal Research counter in _\bd_\bc_\bl_\bo_\bc_\bk.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+v\bv\bv\bve\be\be\beg\bg\bg\bg
+     Turn on and  off  the  Animal  Consumation  counter  in
+     _\bd_\bc_\bl_\bo_\bc_\bk.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+y\by\by\by2\b2\b2\b2k\bk\bk\bk
+     Turn on and off the Year 2000 countdown in _\bd_\bc_\bl_\bo_\bc_\bk.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+m\bm\bm\bmi\bi\bi\bil\bl\bl\bll\bl\bl\ble\be\be\ben\bn\bn\bnn\bn\bn\bni\bi\bi\biu\bu\bu\bum\bm\bm\bm
+     Turn on and off the Second Millennium (January 1, 2001)
+     countdown in _\bd_\bc_\bl_\bo_\bc_\bk.
+
+-b\bb\bb\bbo\bo\bo\bon\bn\bn\bnu\bu\bu\bus\bs\bs\bs _\bv_\ba_\bl_\bu_\be
+     Allows one to set the bonus for cheating... between 1.0
+     and 4.0 in _\bd_\bi_\bl_\be_\bm_\bm_\ba.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+c\bc\bc\bco\bo\bo\bon\bn\bn\bns\bs\bs\bsc\bc\bc\bci\bi\bi\bio\bo\bo\bou\bu\bu\bus\bs\bs\bs
+     Turn off and on self-awareness in _\bd_\bi_\bl_\be_\bm_\bm_\ba.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+g\bg\bg\bgr\br\br\bro\bo\bo\bow\bw\bw\bw
+     Turn  on  and  off  growing  fractals  (else  they  are
+     animated) for _\bd_\br_\bi_\bf_\bt.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+l\bl\bl\bli\bi\bi\bis\bs\bs\bss\bs\bs\bs
+     Turn on and off using lissajous figures to  get  points
+     for _\bd_\br_\bi_\bf_\bt.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+n\bn\bn\bno\bo\bo\boa\ba\ba\ban\bn\bn\bnt\bt\bt\bts\bs\bs\bs
+     Turn off and on ants in _\bm_\bo_\be_\bb_\bi_\bu_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+s\bs\bs\bso\bo\bo\bol\bl\bl\bli\bi\bi\bid\bd\bd\bdm\bm\bm\bmo\bo\bo\boe\be\be\beb\bb\bb\bbi\bi\bi\biu\bu\bu\bus\bs\bs\bs
+     Turn on and off solid Mobius strip in _\bm_\bo_\be_\bb_\bi_\bu_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+i\bi\bi\bin\bn\bn\bnv\bv\bv\bve\be\be\ber\br\br\brt\bt\bt\bt
+     Turn on and off inverting of the _\bf_\bl_\ba_\bg.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\btr\br\br\bra\ba\ba\bac\bc\bc\bck\bk\bk\bks\bs\bs\bs
+     Turn on and off star tracks in _\bg_\ba_\bl_\ba_\bx_\by.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bde\be\be\bec\bc\bc\bca\ba\ba\bay\by\by\by
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   22
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     Turn on and off decaying orbits for _\bg_\br_\ba_\bv.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\btr\br\br\bra\ba\ba\bai\bi\bi\bil\bl\bl\bl
+     Turn on and off decaying trail of dots for _\bg_\br_\ba_\bv.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\bel\bl\bl\bll\bl\bl\bli\bi\bi\bip\bp\bp\bps\bs\bs\bse\be\be\be
+     Turn on and off ellipse format in _\bh_\be_\bl_\bi_\bx.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+m\bm\bm\bma\ba\ba\bar\br\br\brt\bt\bt\bti\bi\bi\bin\bn\bn\bn
+     Turn on and off  Barry  Martin's  square  root  _\bh_\bo_\bp.  -\b-\b-\b-
+     /\b/\b/\b/+\b+\b+\b+p\bp\bp\bpo\bo\bo\bop\bp\bp\bpc\bc\bc\bco\bo\bo\bor\br\br\brn\bn\bn\bn  Turn  on and off Clifford A. Pickover's pop-
+     corn _\bh_\bo_\bp.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\bej\bj\bj\bjk\bk\bk\bk1\b1\b1\b1.\b.\b.\b..\b.\b.\b..\b.\b.\b.e\be\be\bej\bj\bj\bjk\bk\bk\bk6\b6\b6\b6
+     Turn on and off Ed J. Kubaitis' _\bh_\bo_\bp_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\brr\br\br\br
+     Turn on and off Renaldo Recuerdo's _\bh_\bo_\bp.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+j\bj\bj\bjo\bo\bo\bon\bn\bn\bng\bg\bg\bg
+     Turn on and off Jong's _\bh_\bo_\bp.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+s\bs\bs\bsi\bi\bi\bin\bn\bn\bne\be\be\be
+     Turn on and off Barry Martin's sine _\bh_\bo_\bp.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+d\bd\bd\bdi\bi\bi\bis\bs\bs\bsc\bc\bc\bco\bo\bo\bon\bn\bn\bnn\bn\bn\bne\be\be\bec\bc\bc\bct\bt\bt\bte\be\be\bed\bd\bd\bd
+     Turn on and off disconnected pen movement in _\bk_\ba_\bl_\be_\bi_\bd.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+s\bs\bs\bse\be\be\ber\br\br\bri\bi\bi\bia\ba\ba\bal\bl\bl\bl
+     Turn on and off  sequential  allocation  of  colors  in
+     _\bk_\ba_\bl_\be_\bi_\bd.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\bal\bl\bl\blt\bt\bt\bte\be\be\ber\br\br\brn\bn\bn\bna\ba\ba\bat\bt\bt\bte\be\be\be
+     Turn on and off alternate rotated display mode _\bk_\ba_\bl_\be_\bi_\bd.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+q\bq\bq\bqu\bu\bu\bua\ba\ba\bad\bd\bd\bd
+     Turn on and off quad mirrored/rotated mode  similar  to
+     size 4 in _\bk_\ba_\bl_\be_\bi_\bd.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+o\bo\bo\boc\bc\bc\bct\bt\bt\bt
+     Turn on and off oct mirrored/rotated  mode  similar  to
+     size 8 in _\bk_\ba_\bl_\be_\bi_\bd.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+l\bl\bl\bli\bi\bi\bin\bn\bn\bne\be\be\bea\ba\ba\bar\br\br\br
+     Turn on and  off  Cartesian/Polar  coordinate  mode  in
+     _\bk_\ba_\bl_\be_\bi_\bd.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+c\bc\bc\bca\ba\ba\bal\bl\bl\bll\bl\bl\bla\ba\ba\bah\bh\bh\bha\ba\ba\ban\bn\bn\bn
+     Turn on and off  Paul  Callahan's  S2b34/B2a  hexagonal
+     _\bl_\bi_\bf_\be.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\ban\bn\bn\bnd\bd\bd\bdr\br\br\bre\be\be\bee\be\be\ben\bn\bn\bn
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   23
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     Turn on and off Bob Andreen's S2a2b4a/B2a3a4b hexagonal
+     _\bl_\bi_\bf_\be.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\bto\bo\bo\bot\bt\bt\bta\ba\ba\bal\bl\bl\bli\bi\bi\bis\bs\bs\bst\bt\bt\bti\bi\bi\bic\bc\bc\bc
+     Turn on and off totalistic rules for _\bl_\bi_\bf_\be_\b1_\bd. If this is
+     off  then  it  follows  rules  of  the LCAU collection.
+     These rules may not be symmetric and are more general.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\bad\bd\bd\bdd\bd\bd\bdi\bi\bi\bit\bt\bt\bti\bi\bi\biv\bv\bv\bve\be\be\be
+     Turn on and off additive functions mode in _\bl_\bi_\bs_\ba.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+a\ba\ba\bam\bm\bm\bmm\bm\bm\bma\ba\ba\ban\bn\bn\bnn\bn\bn\bn
+     Turn on and off lines for _\bp_\be_\bn_\br_\bo_\bs_\be.
+
+-i\bi\bi\bin\bn\bn\bnc\bc\bc\bcr\br\br\bre\be\be\bem\bm\bm\bme\be\be\ben\bn\bn\bnt\bt\bt\bt _\bv_\ba_\bl_\bu_\be
+     Allows fine adjustments to order in _\bm_\ba_\bn_\bd_\be_\bl_\bb_\br_\bo_\bt.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+e\be\be\ber\br\br\bra\ba\ba\bas\bs\bs\bse\be\be\be
+     Turn on and off erasing for _\bs_\bp_\bl_\bi_\bn_\be. If this  option  is
+     on,  _\bc_\by_\bc_\bl_\be_\bs  is  divided by 64 to compute the number of
+     lines, so as to be compatible when using -fullrandom.
+
+-f\bf\bf\bfa\ba\ba\bac\bc\bc\bct\bt\bt\bto\bo\bo\bor\br\br\bry\by\by\by _\bn_\bu_\bm
+     Number of extra factory parts in _\bp_\bi_\bp_\be_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+f\bf\bf\bfi\bi\bi\bis\bs\bs\bsh\bh\bh\bhe\be\be\bey\by\by\bye\be\be\be
+     Turn on if you want a zoomed-in view of _\bp_\bi_\bp_\be_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+t\bt\bt\bti\bi\bi\big\bg\bg\bgh\bh\bh\bht\bt\bt\btt\bt\bt\btu\bu\bu\bur\br\br\brn\bn\bn\bns\bs\bs\bs
+     Turn on if you want the _\bp_\bi_\bp_\be_\bs to bend more often.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\bro\bo\bo\bot\bt\bt\bta\ba\ba\bat\bt\bt\bte\be\be\bep\bp\bp\bpi\bi\bi\bip\bp\bp\bpe\be\be\bes\bs\bs\bs
+     Turn on if you want the pipe system rotated in _\bp_\bi_\bp_\be_\bs.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+c\bc\bc\bco\bo\bo\bom\bm\bm\bmp\bp\bp\bpl\bl\bl\ble\be\be\bet\bt\bt\bte\be\be\be
+     Turn on or off complete graph morphing in _\bq_\bi_\bx.
+
+-s\bs\bs\bsi\bi\bi\biz\bz\bz\bze\be\be\be[\b[\b[\b[x\bx\bx\bxy\by\by\byz\bz\bz\bz]\b]\b]\b] _\bn_\bu_\bm
+     Number represents the number of cubies on the x, y,  or
+     z  axis.   Negative  numbers offer randomness from 2 to
+     the absolute value of the number.  _\bs_\bt_\ba_\br.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+h\bh\bh\bhi\bi\bi\bid\bd\bd\bde\be\be\bes\bs\bs\bsh\bh\bh\bhu\bu\bu\buf\bf\bf\bff\bf\bf\bfl\bl\bl\bli\bi\bi\bin\bn\bn\bng\bg\bg\bg
+     Turn on or off hidden shuffle phase for _\br_\bu_\bb_\bi_\bk.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+b\bb\bb\bbo\bo\bo\bor\br\br\brd\bd\bd\bde\be\be\ber\br\br\br
+     Turn on or off borders in _\bs_\bh_\ba_\bp_\be.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+_\bs_\bh_\ba_\bp_\be
+     Turn on or off shadowing in _\bs_\bh_\ba_\bp_\be.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+_\bs_\bh_\ba_\bp_\be
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   24
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     Turn on or off stippling in _\bs_\bh_\ba_\bp_\be.
+
+-t\bt\bt\btr\br\br\bre\be\be\bek\bk\bk\bk _\bn_\bu_\bm
+     If its a high number you will see the  space  ship  all
+     the time in _\bs_\bt_\ba_\br.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\bro\bo\bo\boc\bc\bc\bck\bk\bk\bk
+     Turn on and off rocks for _\bs_\bt_\ba_\br. If this is  off,  stars
+     will be seen instead.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+s\bs\bs\bst\bt\bt\btr\br\br\bra\ba\ba\bai\bi\bi\big\bg\bg\bgh\bh\bh\bht\bt\bt\bt
+     Turn on if _\bs_\bt_\ba_\br gets you motion sick.
+
+-c\bc\bc\bcy\by\by\byc\bc\bc\bcl\bl\bl\ble\be\be\bep\bp\bp\bpe\be\be\bee\be\be\bed\bd\bd\bd _\bn_\bu_\bm
+     Set speed of cycling in _\bs_\bt_\ba_\br_\bf_\bi_\bs_\bh.
+
+-r\br\br\bro\bo\bo\bot\bt\bt\bta\ba\ba\bat\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn _\bn_\bu_\bm
+     Set rotation velocity in _\bs_\bt_\ba_\br_\bf_\bi_\bs_\bh.
+
+-t\bt\bt\bth\bh\bh\bhi\bi\bi\bic\bc\bc\bck\bk\bk\bkn\bn\bn\bne\be\be\bes\bs\bs\bss\bs\bs\bs _\bn_\bu_\bm
+     Set thickness in _\bs_\bt_\ba_\br_\bf_\bi_\bs_\bh.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+r\br\br\bro\bo\bo\boc\bc\bc\bck\bk\bk\bk
+     Turn on and off blob for _\bs_\bt_\ba_\br_\bf_\bi_\bs_\bh.
+
+-s\bs\bs\bsp\bp\bp\bpi\bi\bi\bin\bn\bn\bns\bs\bs\bsp\bp\bp\bpe\be\be\bee\be\be\bed\bd\bd\bd _\bn_\bu_\bm
+     Set speed of rotation, in degrees per frame for  _\bs_\bu_\bp_\be_\br_\b-
+     _\bq_\bu_\ba_\bd_\br_\bi_\bc_\bs.
+
+-d\bd\bd\bdu\bu\bu\bur\br\br\bra\ba\ba\bat\bt\bt\bti\bi\bi\bio\bo\bo\bon\bn\bn\bn _\bs_\be_\bc_\bo_\bn_\bd_\bs
+     Allows one to set a duration  for  a  mode  in  _\br_\ba_\bn_\bd_\bo_\bm.
+     Duration of 0 is defined as infinite.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+f\bf\bf\bfu\bu\bu\bul\bl\bl\bll\bl\bl\blr\br\br\bra\ba\ba\ban\bn\bn\bnd\bd\bd\bdo\bo\bo\bom\bm\bm\bm
+     Turn on/off randomness options within modes in  _\br_\ba_\bn_\bd_\bo_\bm.
+     Not implemented for all mode options.
+
+-m\bm\bm\bmo\bo\bo\bod\bd\bd\bde\be\be\bel\bl\bl\bli\bi\bi\bis\bs\bs\bst\bt\bt\bt _\bt_\be_\bx_\bt_\bs_\bt_\br_\bi_\bn_\bg
+     Allows one to pass a list of files to randomly  display
+     to _\br_\ba_\bn_\bd_\bo_\bm. "all" will get all files but blank (and bomb
+     if  compiled  in).  "all,blank"  will  get  all  modes.
+     "all,-image bounce,+blank" will get all modes but image
+     and bounce.  "bug wator" will get only bug  and  wator.
+     "allgl"  will  get  only  the  GL modes if compiled in,
+     all-allgl will get all but the GL modes, "allnice" will
+     weed  out  high cpu usage modes (as well as hackers and
+     gl modes).  "allxpm" will get all modes that  use  xpm.
+     "allwrite"  will  get  all modes that take advantage of
+     writable colormaps (not including xpm).   "all3d"  will
+     get all the modes that support this option.  "allmouse"
+     will get all the modes that support mouse  interaction.
+     Similarly,    "allautomata"    for    automata   modes,
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   25
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+     "allfractal"  for  fractal  modes,  "allgeometry"   for
+     geometry modes, "allspace" for space modes.  The random
+     mode itself can not be referenced.
+
+-\b-\b-\b-/\b/\b/\b/+\b+\b+\b+s\bs\bs\bse\be\be\beq\bq\bq\bqu\bu\bu\bue\be\be\ben\bn\bn\bnt\bt\bt\bti\bi\bi\bia\ba\ba\bal\bl\bl\bl
+     Turn on non-random _\br_\ba_\bn_\bd_\bo_\bm option.
+
+
+*\b*\b*\b**\b*\b*\b*W\bW\bW\bWA\bA\bA\bAR\bR\bR\bRN\bN\bN\bNI\bI\bI\bIN\bN\bN\bNG\bG\bG\bG*\b*\b*\b**\b*\b*\b*
+x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk can appear to hang if it is  competing  with  a  high-
+priority  process  for  the  CPU.  For  example, if x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk is
+started after a process with  'nice  -20'  (high  priority),
+x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk will take  considerable amount of time to respond.
+
+
+2 S\bS\bS\bSH\bH\bH\bHA\bA\bA\bAD\bD\bD\bDO\bO\bO\bOW\bW\bW\bW P\bP\bP\bPA\bA\bA\bAS\bS\bS\bSS\bS\bS\bSW\bW\bW\bWO\bO\bO\bOR\bR\bR\bRD\bD\bD\bDS\bS\bS\bS
+2 If the machine is using a shadow password system, then x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk
+may  not  be  set up to get the real password and so must be
+given one of its own. This can  be  either  on  the  command
+line,   via   the   -\b-\b-\b-c\bc\bc\bcp\bp\bp\bpa\ba\ba\bas\bs\bs\bss\bs\bs\bsw\bw\bw\bwd\bd\bd\bd   option,   or   in   the  file
+$\b$\b$\b$H\bH\bH\bHO\bO\bO\bOM\bM\bM\bME\bE\bE\bE/\b/\b/\b/.\b.\b.\b.x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bkr\br\br\brc\bc\bc\bc, with the first taking precedence.   In  both
+cases  an  encrypted  password is expected (see makekey(8)).
+2 If neither is given, then x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk will prompt for  a  password
+and  will  use that, also storing an encrypted version of it
+in $\b$\b$\b$H\bH\bH\bHO\bO\bO\bOM\bM\bM\bME\bE\bE\bE/\b/\b/\b/.\b.\b.\b.x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bkr\br\br\brc\bc\bc\bc for future use.
+
+
+2 B\bB\bB\bBU\bU\bU\bUG\bG\bG\bGS\bS\bS\bS
+"kill -KILL x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk " causes the server that was locked to  be
+unusable, since all hosts (including localhost) were removed
+from the access control list to lock out new X clients,  and
+since  x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk  could  not catch SIGKILL, it terminated before
+restoring the access control list.  This will  leave  the  X
+server  in  a state where "_\by_\bo_\bu _\bc_\ba_\bn _\bn_\bo _\bl_\bo_\bn_\bg_\be_\br _\bc_\bo_\bn_\bn_\be_\bc_\bt _\bt_\bo _\bt_\bh_\ba_\bt
+_\bs_\be_\br_\bv_\be_\br, _\ba_\bn_\bd _\bt_\bh_\bi_\bs _\bo_\bp_\be_\br_\ba_\bt_\bi_\bo_\bn _\bc_\ba_\bn_\bn_\bo_\bt  _\bb_\be  _\br_\be_\bv_\be_\br_\bs_\be_\bd  _\bu_\bn_\bl_\be_\bs_\bs  _\by_\bo_\bu
+_\br_\be_\bs_\be_\bt  _\bt_\bh_\be _\bs_\be_\br_\bv_\be_\br."            -From the X11R4 Xlib Documen-
+tation, Chapter 7.
+2 NCD terminals do not allow xlock to  remove  all  the  hosts
+from  the  access  control list.  Therefore you will need to
+use the "-remote" and "-allowaccess" switches.  If you  hap-
+pen  to run without "-allowaccess" on an NCD terminal, x\bx\bx\bxl\bl\bl\blo\bo\bo\boc\bc\bc\bck\bk\bk\bk
+will not work and you will need to reboot the  terminal,  or
+simply  go into the SETUP menus, under 'Network Parameters',
+and turn off TCP/IP access control.
+
+2 S\bS\bS\bSE\bE\bE\bEE\bE\bE\bE A\bA\bA\bAL\bL\bL\bLS\bS\bS\bSO\bO\bO\bO
+2 X(1), Xlib Documentation.
+
+
+2 A\bA\bA\bAU\bU\bU\bUT\bT\bT\bTH\bH\bH\bHO\bO\bO\bOR\bR\bR\bR
+2 Maintained by:
+     David Albert Bagley, <_\bb_\ba_\bg_\bl_\be_\by_\bd@_\bt_\bu_\bx._\bo_\br_\bg>
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   26
+
+
+
+
+
+
+2 User Commands                                            XLOCK(1)
+
+
+
+2 The latest version is currently at:
+     _\bf_\bt_\bp://_\bf_\bt_\bp._\bt_\bu_\bx._\bo_\br_\bg/_\bp_\bu_\bb/_\bt_\bu_\bx/_\bb_\ba_\bg_\bl_\be_\by_\bd/_\bx_\bl_\bo_\bc_\bk_\bm_\bo_\br_\be
+     _\bf_\bt_\bp://_\bf_\bt_\bp._\bx._\bo_\br_\bg/_\bc_\bo_\bn_\bt_\br_\bi_\bb/_\ba_\bp_\bp_\bl_\bi_\bc_\ba_\bt_\bi_\bo_\bn_\bs
+
+2 Original Author:
+     Patrick J. Naughton, <_\bn_\ba_\bu_\bg_\bh_\bt_\bo_\bn@_\be_\bn_\bg._\bs_\bu_\bn._\bc_\bo_\bm>
+     Mailstop 21-14
+     Sun Microsystems Laboratories, Inc.
+     Mountain View, CA  94043
+     415/336-1080
+
+with many additional contributors.
+
+
+2 C\bC\bC\bCO\bO\bO\bOP\bP\bP\bPY\bY\bY\bYR\bR\bR\bRI\bI\bI\bIG\bG\bG\bGH\bH\bH\bHT\bT\bT\bT
+2 Copyright (C) 1988-91 by Patrick J. Naughton
+2 Copyright (C) 1993-98 by David A. Bagley
+
+2 Permission  to  use,  copy,  modify,  and  distribute   this
+software  and  its documentation for any purpose and without
+fee is hereby granted, provided  that  the  above  copyright
+notice  appear  in  all  copies and that both that copyright
+notice and this permission notice appear in supporting docu-
+mentation.
+2 The original BSD daemon is Copyright (C) 1988 Marshall  Kirk
+2 McKusick.  All Rights Reserved.
+2 DEC, HP, IBM, Linux, SCO, SGI,  and  Sun  icons  have  their
+respective copyrights.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2 X11R6 Contrib        Last change: 8 Mar 1999                   27
+
+
+
diff --git a/xlockmore-4.14/docs/xlock.html b/xlockmore-4.14/docs/xlock.html
new file mode 100644 (file)
index 0000000..169f7da
--- /dev/null
@@ -0,0 +1,1437 @@
+<HTML>
+<BODY>
+<PRE>
+
+</PRE>
+<H2>NAME</H2><PRE>
+     xlock - Locks the  local  X  display  until  a  password  is
+     entered.
+
+
+
+</PRE>
+<H2>SYNOPSIS</H2><PRE>
+     <STRONG>xlock</STRONG> [ -<STRONG>help</STRONG> ] [ -<STRONG>version</STRONG>  ]  [  -<STRONG>resources</STRONG>  ]  [  -<STRONG>display</STRONG>
+     <EM>displayname</EM>  ] [ -<STRONG>visual</STRONG> <EM>visualname</EM> ] [ -<STRONG>name</STRONG> <EM>resourcename</EM> ]
+     [ -<STRONG>mode</STRONG> <EM>modename</EM> ] [ -<STRONG>delay</STRONG> <EM>usecs</EM> ] [ -<STRONG>batchcount</STRONG>  <EM>num</EM>  ]  [
+     -<STRONG>count</STRONG>  <EM>num</EM> ] [ -<STRONG>cycles</STRONG> <EM>num</EM> ] [ -<STRONG>ncolors</STRONG> <EM>num</EM> ] [ -<STRONG>size</STRONG> <EM>num</EM> ]
+     [ -<STRONG>saturation</STRONG> <EM>value</EM> ] [ -<STRONG>erasemode</STRONG> <EM>modename</EM> ] [  -<STRONG>erasedelay</STRONG>
+     <EM>usecs</EM>  ] [ <STRONG>-/+allowaccess</STRONG> ] [ -<STRONG>vtlock</STRONG> <EM>modename</EM> ] [ <STRONG>-/+nolock</STRONG>
+     ] [ <STRONG>-/+inwindow</STRONG> ] [ <STRONG>-/+inroot</STRONG> ] [ <STRONG>-/+remote</STRONG> ] [ <STRONG>-/+mono</STRONG> ]  [
+     <STRONG>-/+allowroot</STRONG> ] [ <STRONG>-/+debug</STRONG> ] [ <STRONG>-/+description</STRONG> ] [ <STRONG>-/+echokeys</STRONG>
+     ] [ <STRONG>-/+enablesaver</STRONG> ] [ <STRONG>-/+resetsaver</STRONG> ] [ <STRONG>-/+grabmouse</STRONG> ] [  <STRONG>-</STRONG>
+     <STRONG>/+grabserver</STRONG>  ] [ <STRONG>-/+install</STRONG> ] [ <STRONG>-/+mousemotion</STRONG> ] [ <STRONG>-/+sound</STRONG>
+     ] [ <STRONG>-/+timeelapsed</STRONG> ] [ <STRONG>-/+usefirst</STRONG> ] [ <STRONG>-/+verbose</STRONG> ] [  -<STRONG>nice</STRONG>
+     <EM>level</EM>  ] [ -<STRONG>lockdelay</STRONG> <EM>seconds</EM> ] [ -<STRONG>timeout</STRONG> <EM>seconds</EM> ] [ -<STRONG>font</STRONG>
+     <EM>fontname</EM> ] [ -<STRONG>planfont</STRONG> <EM>fontname</EM> ] [ -<STRONG>bg</STRONG> <EM>color</EM> ] [ -<STRONG>fg</STRONG>  <EM>color</EM>
+     ]  [  -<STRONG>background</STRONG>  <EM>color</EM> ] [ -<STRONG>foreground</STRONG> <EM>color</EM> ] [ -<STRONG>username</STRONG>
+     <EM>string</EM> ] [ -<STRONG>password</STRONG> <EM>string</EM> ] [ -<STRONG>info</STRONG> <EM>string</EM> ]  [  -<STRONG>validate</STRONG>
+     <EM>string</EM>   ]  [  -<STRONG>invalid</STRONG>  <EM>string</EM>  ]  [  -<STRONG>geometry</STRONG>  <EM>geom</EM>  ]  [
+     -<STRONG>icongeometry</STRONG> <EM>geom</EM> ] [ -<STRONG>glgeometry</STRONG> <EM>geom</EM> ] [ <STRONG>-/+wireframe</STRONG> ] [
+     <STRONG>-/+use3d</STRONG>  ]  [ -<STRONG>delta3d</STRONG> <EM>value</EM> ] [ -<STRONG>none3d</STRONG> <EM>color</EM> ] [ -<STRONG>right3d</STRONG>
+     <EM>color</EM> ] [ -<STRONG>left3d</STRONG> <EM>color</EM> ] [ -<STRONG>both3d</STRONG> <EM>color</EM> ] [ -<STRONG>program</STRONG>  <EM>pro-</EM>
+     <EM>gramname</EM>  ] [ -<STRONG>messagesfile</STRONG> <EM>formatted</EM>-<EM>filename</EM> ] [ -<STRONG>message-</STRONG>
+     <STRONG>file</STRONG> <EM>filename</EM> ] [ -<STRONG>message</STRONG> <EM>string</EM> ] [ -<STRONG>messagefont</STRONG>  <EM>fontname</EM>
+     ] [ -<STRONG>bitmap</STRONG> <EM>filename</EM> ] [ -<STRONG>cpasswd</STRONG> <EM>crypted</EM>-<EM>password</EM> ] [ -<STRONG>for-</STRONG>
+     <STRONG>ceLogout</STRONG> <EM>minutes</EM>  ]  [  -<STRONG>logoutButtonLabel</STRONG>  <EM>textstring</EM>  ]  [
+     -<STRONG>logoutButtonHelp</STRONG>  <EM>textstring</EM>  ] [ -<STRONG>logoutFailedString</STRONG> <EM>text-</EM>
+     <EM>string</EM> ] [ <STRONG>-/+dtsaver</STRONG> ] [ -<STRONG>modulepath</STRONG> <EM>path</EM>  ]  [  -<STRONG>locksound</STRONG>
+     <EM>string</EM>  ]  [  -<STRONG>infosound</STRONG>  <EM>string</EM>  ] [ -<STRONG>validsound</STRONG> <EM>string</EM> ] [
+     -<STRONG>invalidsound</STRONG> <EM>string</EM> ] [ -<STRONG>startCmd</STRONG> <EM>string</EM> ] [ -<STRONG>endCmd</STRONG> <EM>string</EM>
+     ] [ -<STRONG>logoutCmd</STRONG> <EM>string</EM> ]
+
+
+
+</PRE>
+<H2>DESCRIPTION</H2><PRE>
+     <STRONG>xlock</STRONG> locks the X server till the user enters their password
+     at  the  keyboard.   While  <STRONG>xlock</STRONG> is running, all new server
+     connections are refused.  The screen saver is disabled.  The
+     mouse  cursor  is  turned  off.  The screen is blanked and a
+     changing pattern is put on the screen.  If a key or a  mouse
+     button is pressed then the user is prompted for the password
+     of the user who started <STRONG>xlock</STRONG>.
+
+     If the  correct  password  is  typed,  then  the  screen  is
+     unlocked  and  the  X  server  is restored.  When typing the
+     password Control-U and Control-H  are  active  as  kill  and
+     erase  respectively.   To return to the locked screen, click
+     in the small icon version of the changing pattern.
+
+     In  the  lower  part  of  the  password  screen  a  text  is
+     displayed.  This message is taken from the first file of the
+     following that exists:   $HOME/.xlocktext,  $HOME/.plan,  or
+     $HOME/.signature.
+
+     On systems which support new BSD style  authentication,  the
+     password may be prefixed by an authentication style followed
+     by a colon (i.e. "style:password").  See  the  login.conf(5)
+     for more information on authentication styles.
+
+
+
+</PRE>
+<H2>NOTE ON ETIQUETTE</H2><PRE>
+     <EM>Xlock</EM> should not be used on public terminals when there is a
+     high demand for them.
+
+     If you find a  public  terminal  that  has  been  locked  by
+     another user and there are no other terminals available, and
+     the terminal appears to have been  left  idle  for  a  while
+     (normally  more than 15 minutes), it is fair to try to reset
+     the session in some manner.
+
+
+
+</PRE>
+<H2>OPTIONS</H2><PRE>
+     -<STRONG>help</STRONG>
+          Print options and a brief description to standard  out-
+          put.
+
+     -<STRONG>version</STRONG>
+          Print version number (if &gt;= 4.00) to standard output.
+
+     -<STRONG>resources</STRONG>
+          Print default resource file to standard output.
+
+     -<STRONG>display</STRONG> <EM>displayname</EM>
+          The <EM>display</EM> option sets the X11 display to lock.  <STRONG>xlock</STRONG>
+          locks all available screens on a given server, and res-
+          tricts you to locking  only  a  local  server  such  as
+          <STRONG>unix:0,</STRONG>  <STRONG>localhost:0,</STRONG>  or <STRONG>:0</STRONG> unless you set the -<STRONG>remote</STRONG>
+          option.
+
+     -<STRONG>visual</STRONG> <EM>visualname</EM>
+          <EM>visualname</EM> which is one of  "StaticGray",  "GrayScale",
+          "StaticColor",        "PseudoColor",       "TrueColor",
+          "DirectColor", or "default".  default used to  set  the
+          screen's  default  visual  (the visual of the root win-
+          dow).
+
+     -<STRONG>name</STRONG> <EM>resourcename</EM>
+          <EM>resourcename</EM> is used instead of <STRONG>XLock</STRONG> when looking  for
+          resources to configure <STRONG>xlock</STRONG>.
+
+     -<STRONG>mode</STRONG> <EM>modename</EM>
+          As of this writing there  are  over  90  display  modes
+          supported (plus one more for random selection of one of
+          these).
+
+     <STRONG>ant</STRONG>     Shows Langton's and Turk's generalized ants.
+
+     <STRONG>atlantis</STRONG>
+             Shows  moving  sharks/whales/dolphin.   May  not  be
+             available depending on how it was configured.
+
+     <STRONG>ball</STRONG>    Shows bouncing balls.
+
+     <STRONG>bat</STRONG>     Shows bouncing flying bats.
+
+     <STRONG>blot</STRONG>    Shows Rorschach's ink blot test.
+
+     <STRONG>bouboule</STRONG>
+             Shows Mimi's bouboule of moving stars.
+
+     <STRONG>bounce</STRONG>  Shows bouncing footballs.
+
+     <STRONG>braid</STRONG>   Shows random braids and knots.
+
+     <STRONG>bubble</STRONG>  Shows popping bubbles.
+
+     <STRONG>bubble3d</STRONG>
+             Shows Richard Jones's GL bubbles.  May not be avail-
+             able depending on how it was configured.
+
+     <STRONG>bug</STRONG>     Shows Palmiter's bug evolution and a garden of Eden.
+
+     <STRONG>cartoon</STRONG> Shows  bouncing  cartoons.   May  not  be  available
+             depending on how it was configured.
+
+     <STRONG>clock</STRONG>   Shows Packard's oclock.
+
+     <STRONG>coral</STRONG>   Shows a coral reef.
+
+     <STRONG>crystal</STRONG> Shows polygons in 2D plane groups.
+
+     <STRONG>daisy</STRONG>   Shows a meadow of daisies.
+
+     <STRONG>dclock</STRONG>  Shows a floating digital clock or message.
+
+     <STRONG>deco</STRONG>    Shows art as ugly as sin.
+
+     <STRONG>demon</STRONG>   Shows Griffeath's cellular automata.
+
+     <STRONG>dilemma</STRONG> Shows Lloyd's Prisoner's Dilemma simulation.
+
+     <STRONG>discrete</STRONG>
+             Shows various discrete maps.
+
+     <STRONG>drift</STRONG>   Shows cosmic drifting flame fractals.
+
+     <STRONG>cage</STRONG>    Shows the Impossible Cage, an Escher-like GL  scene.
+             May not be available depending on how it was config-
+             ured.
+
+     <STRONG>eyes</STRONG>    Shows eyes following a bouncing grelb.
+
+     <STRONG>fadeplot</STRONG>
+             Shows a fading plot of sine squared.
+
+     <STRONG>flag</STRONG>    Shows a waving flag image.  This may be  text  or  a
+             graphic  image.   Default  text  is the hostname and
+             operating system.
+
+     <STRONG>flame</STRONG>   Shows cosmic flame fractals.
+
+     <STRONG>flow</STRONG>    Shows dynamic strange attractors.
+
+     <STRONG>forest</STRONG>  Shows binary trees of a fractal forest.
+
+     <STRONG>galaxy</STRONG>  Shows crashing spiral galaxies.
+
+     <STRONG>gears</STRONG>   Shows GL's gears.  May not be available depending on
+             how it was configured.
+
+     <STRONG>goop</STRONG>    Shows goop from a lava lamp.
+
+     <STRONG>grav</STRONG>    Shows orbiting planets.
+
+     <STRONG>helix</STRONG>   Shows string art.
+
+     <STRONG>hop</STRONG>     Shows real plane iterated fractals.
+
+     <STRONG>hyper</STRONG>   Shows spinning n-dimensional hypercubes.
+
+     <STRONG>ico</STRONG>     Shows a bouncing polyhedron.
+
+     <STRONG>ifs</STRONG>     Shows a modified iterated function system.
+
+     <STRONG>image</STRONG>   Shows randomly appearing logos.
+
+     <STRONG>julia</STRONG>   Shows the Julia set.
+
+     <STRONG>kaleid</STRONG>  Shows Brewster's Kaleidoscope.
+
+     <STRONG>kummpa</STRONG>  Shows kumppa.
+
+     <STRONG>laser</STRONG>   Shows spinning lasers.
+
+     <STRONG>life</STRONG>    Shows Conway's game of life.
+
+     <STRONG>life1d</STRONG>  Shows Wolfram's game of 1D life.
+
+     <STRONG>life3d</STRONG>  Shows Bays' game of 3D life.
+
+     <STRONG>lightning</STRONG>
+             Shows Keith's fractal lightning bolts.
+
+     <STRONG>lisa</STRONG>    Shows animated lissajous loops.
+
+     <STRONG>lissie</STRONG>  Shows lissajous worms.
+
+     <STRONG>loop</STRONG>    Shows Langton's self-producing loops.
+
+     <STRONG>mandelbrot</STRONG>
+             Shows mandelbrot sets.
+
+     <STRONG>marquee</STRONG> Shows text.
+
+     <STRONG>matrix</STRONG>  Shows the matrix.
+
+     <STRONG>maze</STRONG>    Shows a random maze and a depth first  search  solu-
+             tion.
+
+     <STRONG>moebius</STRONG> Shows the Moebius Strip II, an Escher-like GL  scene
+             with ants.  May not be available depending on how it
+             was configured.
+
+     <STRONG>morph3d</STRONG> Shows GL morphing polyhedra.  May not  be  available
+             depending on how it was configured.
+
+     <STRONG>mountain</STRONG>
+             Shows Papo's mountain range.
+
+     <STRONG>munch</STRONG>   Shows munching squares.
+
+     <STRONG>nose</STRONG>    Shows a man with a big nose runs around spewing  out
+             text.
+
+     <STRONG>pacman</STRONG>  Shows Pacman(tm).
+
+     <STRONG>pipes</STRONG>   Shows a  self-building  pipe  system.   May  not  be
+             available depending on how it was configured.
+
+     <STRONG>penrose</STRONG> Shows Penrose's quasiperiodic tilings.
+
+     <STRONG>petal</STRONG>   Shows various GCD Flowers.
+
+     <STRONG>puzzle</STRONG>  Shows a puzzle being scrambled and then solved.
+
+     <STRONG>pyro</STRONG>    Shows fireworks.
+
+     <STRONG>qix</STRONG>     Shows spinning lines a la Qix(tm).
+     <STRONG>roll</STRONG>    Shows a rolling ball.
+
+     <STRONG>rotor</STRONG>   Shows Tom's Roto-Rooter.
+
+     <STRONG>rubik</STRONG>   Shows an auto-solving  Rubik's  Cube.   May  not  be
+             available depending on how it was configured.
+
+     <STRONG>shape</STRONG>   Shows stippled rectangles, ellipses, and triangles.
+
+     <STRONG>sierpinski</STRONG>
+             Shows a Sierpinski's triangle.
+
+     <STRONG>slip</STRONG>    Shows slipping blits.
+
+     <STRONG>sphere</STRONG>  Shows a bunch of shaded spheres.
+
+     <STRONG>spiral</STRONG>  Shows a helical locus of points.
+
+     <STRONG>spline</STRONG>  Shows colorful moving splines.
+
+     <STRONG>sproingies</STRONG>
+             Shows Sproingies!   Nontoxic.   Safe  for  pets  and
+             small  children.   May not be available depending on
+             how it was configured.
+
+     <STRONG>stairs</STRONG>  Shows Infinite Stairs, an Escher-like GL scene.  May
+             not be available depending on how it was configured.
+
+     <STRONG>star</STRONG>    Shows a star field with a twist.
+
+     <STRONG>starfish</STRONG>
+             Shows starfish.
+
+     <STRONG>strange</STRONG> Shows strange attractors.
+
+     <STRONG>superquadrics</STRONG>
+             Shows 3D mathematical shapes.  May not be  available
+             depending on how it was configured.
+
+     <STRONG>swarm</STRONG>   Shows a swarm of bees following a wasp.
+
+     <STRONG>swirl</STRONG>   Shows animated swirling patterns.
+
+     <STRONG>tetris</STRONG>  Shows tetris.
+
+     <STRONG>thornbird</STRONG>
+             Shows an animated Bird in a Thorn Bush fractal map.
+
+     <STRONG>triangle</STRONG>
+             Shows a triangular mountain range.
+
+     <STRONG>tube</STRONG>    Shows an animated tube.
+     <STRONG>turtle</STRONG>  Shows turtle fractals.
+
+     <STRONG>vines</STRONG>   Shows fractal-like vines.
+
+     <STRONG>voters</STRONG>  Shows Dewdney's Voters.
+
+     <STRONG>wator</STRONG>   Shows  Dewdney's  Water-Torus  planet  of  fish  and
+             sharks.
+
+     <STRONG>wire</STRONG>    Shows a random circuit with 2 electrons.
+
+     <STRONG>world</STRONG>   Shows spinning Earths.
+
+     <STRONG>worm</STRONG>    Shows wiggly worms.
+
+     <STRONG>xjack</STRONG>   Shows Jack having one of those days.
+
+     <STRONG>blank</STRONG>   Shows nothing but a black screen.  Does not show  up
+             in random mode.
+
+     <STRONG>bomb</STRONG>    Shows a bomb and will autologout after a time.  Does
+             not  show  up  in  random  mode and may be available
+             depending on how it was configured.
+
+     <STRONG>random</STRONG>  Shows a random mode from  above  except  blank  (and
+             bomb).
+
+
+     -<STRONG>delay</STRONG> <EM>usecs</EM>
+          The <EM>delay</EM> option sets the speed at which  a  mode  will
+          operate.   It simply sets the number of microseconds to
+          delay between batches of animations.  In blank mode, it
+          is  important  to  set  this  to  some  small number of
+          seconds,  because  the  keyboard  and  mouse  are  only
+          checked  after  each delay, so you cannot set the delay
+          too high, but a delay of zero would needlessly  consume
+          cpu  checking  for  mouse and keyboard input in a tight
+          loop, since blank mode has no work to do.
+
+     -<STRONG>count</STRONG> <EM>num</EM>
+          The <EM>batchcount</EM> option sets number of <EM>things</EM> to  do  per
+          batch to <EM>num</EM> .
+
+          In ant mode this refers the number of ants.
+
+          In atlantis mode it is the number of sharks.
+
+          In ball mode it is the number of balls.
+
+          In bat mode it is the number of  bats,  could  be  less
+          because of conflicts.
+
+          In blot mode this refers to the number of  pixels  ren-
+          dered in the same color.
+
+          In bouboule mode it is the number of stars.
+
+          In bounce mode it is the number of balls, could be less
+          because of conflicts.
+
+          In braid mode it is the upper bound number of strands.
+
+          In bubble mode it is the number of bubbles.
+
+          In bubble3d mode it is the number of bubbles.
+
+          In bug mode it is the number of  bugs,  could  be  less
+          because of conflicts.
+
+          In cage mode it is means nothing.
+
+          In cartoon mode it means nothing.
+
+          In clock mode it is the percentage of the  screen,  but
+          less than 100%.
+
+          In coral mode it is the number of seeds.
+
+          In crystal mode it is the number of polygons.
+
+          In daisy mode it is the  number  flowers  that  make  a
+          meadow.
+
+          In dclock mode it means nothing.
+
+          In deco mode it is the depth.
+
+          In demon mode this refers the number of colors.
+
+          In dilemma mode  this  refers  the  number  of  initial
+          defectors.
+
+          In discrete mode it is the number of points.
+
+          In drift mode it is the number  of  levels  to  recurse
+          (larger = more complex).
+
+          In eyes mode it is the number of eyes.
+
+          In fadeplot mode it is the number of steps.
+
+          In flag mode it means nothing.
+
+          In flame mode it is the number  of  levels  to  recurse
+          (larger = more complex).
+
+          In flow mode it is the number of bees.
+
+          In forest mode it is  the  number  trees  that  make  a
+          forest.
+
+          In galaxy mode it means the number of galaxies.
+
+          In gears mode it is the number of degrees to rotate the
+          set of gears by.
+
+          In goop mode it is the number of blobs per plane.
+
+          In grav mode it is the number of planets.
+
+          In helix mode it means nothing.
+
+          In hop mode this refers to the number  of  pixels  ren-
+          dered in the same color.
+
+          In hyper mode it the number of dimensions.
+
+          In ico mode it is the ith platonic solid.
+
+          In ifs mode it means nothing.
+
+          In image mode it means it is the  number  of  logos  on
+          screen at once.
+
+          In julia mode it is the depth of recursion.
+
+          In kaleid mode it is the number of pens.
+
+          In kumppa mode it means nothing.
+
+          In laser mode it is the number lasers.
+
+          In life mode it is the number of generations  before  a
+          glider is introduced.
+
+          In life1d mode it means nothing.
+
+          In life3d mode it is the number of generations before a
+          glider is introduced.
+
+          In lisa mode it is the number of loops.
+
+          In lissie mode it is the number of worms.
+
+          In loop mode it means nothing.
+
+          In mandelbrot mode it is the order.
+
+          In marquee mode it means nothing.
+
+          In matrix mode it means nothing.
+
+          In maze mode it means nothing.
+
+          In moebius mode it is means nothing.
+
+          In morph3d mode it is the ith platonic solid.
+
+          In mountain mode it is the number of mountains.
+
+          In munch mode it means nothing.
+
+          In nose mode it means nothing.
+
+          In qix mode it is the number of points.
+
+          In pacman mode it means the number of ghosts.
+
+          In penrose mode it means nothing.
+
+          In petal mode it the greatest random number of petals.
+
+          In pipes mode it shows different joints,  0  random,  1
+          spherical, 2 bolted elbow, 3 elbow, and 4 alternating.
+
+          In puzzle mode it the number of moves.
+
+          In pyro mode it is the maximum number flying rockets at
+          one time.
+
+          In roll mode it is the number of points.
+
+          In rotor mode it is the number of rotor  thingys  which
+          whirr...
+
+          In rubik mode it is the number of moves.
+
+          In shape mode it means nothing.
+
+          In sierpinski mode it is the number of points.
+
+          In slip mode it means nothing.
+
+          In sphere mode it means nothing.
+
+          In spiral mode it is the number of spirals.
+
+          In spline mode it is the number of points "splined".
+          In sproingies mode it is the number of sproingies.
+
+          In stairs mode it is means nothing.
+
+          In star mode it is the number of stars on the screen at
+          once.
+
+          In starfish mode it means nothing.
+
+          In strange mode it means nothing.
+
+          In superquadrics mode its the number of horizontal  and
+          vertical lines in the superquadric.
+
+          In swirl mode it means the number of "knots".
+
+          In swarm mode it is the number of bees.
+
+          In thornbird mode it is the number of points.
+
+          In triangular mode it is the number of mountains.
+
+          In tube mode it is a rectangle (= 1), an ellipse (= 2),
+          or a polygon if greater.
+
+          In turtle mode it means nothing.
+
+          In vines mode it is draw a complete vine  (=  0)  or  a
+          portion (= 1).
+
+          In voters mode it means the number of parties, 2 or 3.
+
+          In wator mode it means the breed time for the fish.
+
+          In wire mode it means the length of the circuit.
+
+          In world mode it is the number of worlds.
+
+          In worm mode it is the number of worms.
+
+          In blank mode it means nothing.
+
+          In bomb mode it means the number of minutes to  autolo-
+          gout.
+
+          A negative <EM>count</EM> allows for randomness.  The range from
+          the  minimum allowed nonnegative <EM>count</EM> for a particular
+          mode to the ABS( <EM>count</EM> ) (or maximum  allowed  <EM>count</EM>  ,
+          whichever is less).
+
+     -<STRONG>batchcount</STRONG> <EM>num</EM>
+          The <EM>batchcount</EM> option is depreciated but  should  still
+          work as <EM>count</EM>.
+
+     -<STRONG>cycles</STRONG> <EM>num</EM>
+          The <EM>cycles</EM> option sets the number of cycles until  time
+          out  for  ant, blot, braid, bug, clock, crystal, daisy,
+          deco,  demon,  dilemma,  discrete,  eyes,  flag,  flow,
+          forest,  galaxy,  helix,  hop, hyper, ico, laser, life,
+          life1d, life3d, lisa, lissie, loop,  mandelbrot,  moun-
+          tain,  petal,  sierpinski, shape, spline +erase, thorn-
+          bird, triangle, tube, voters,  wator,  and  wire.   For
+          worm  it is the length of the lines, for atlantis it is
+          the shark speed, for fadeplot, julia and spiral  it  is
+          the  length  of  the  trail  of  dots,  munch it is the
+          minimum size of the squares, for kaleid it is the %  of
+          black,  for  qix  it is the number of lines, for spline
+          -erase it means the number of splines * 64 (for  compa-
+          tibility  with  +erase),  for gears it is the number of
+          degrees to increment the spin  of  each  gear  by,  for
+          pipes it is the number of systems to draw before clear-
+          ing the screen, for rubik it is the number of steps  to
+          complete  a 90 move, for superquadrics it is the number
+          of frames it takes to morph from one shape to  another.
+          For others it means nothing.
+
+     -<STRONG>size</STRONG> <EM>num</EM>
+          The <EM>size</EM> option sets the size maximum size of a star in
+          bouboule,  pyro  and  star,  size  of  ball in ball and
+          bounce, size of bat in bat, maximum size of  bubble  in
+          bubble, size of clock in clock, minimum size of rectan-
+          gles in deco, size of the polygon in crystal,  size  of
+          polyhedron  in  ico,  size of lissie in lissie, size of
+          dots of flag, for kaleid it is the symmetry,  width  of
+          maze  hallway,  size of side of penrose tile, radius of
+          loop in lisa, radius of ball in roll, number of corners
+          in  sierpinski,  size of tube in tube, width of worm in
+          worm, line width in rotor, size of cells in  ant,  bug,
+          dilemma,  life,  life1d, pacman, tetris, voters, wator,
+          and wire.  In pipes it is the maximum length of a  sys-
+          tem.   In atlantis it is the shark size.  In sproingies
+          it is the size of the screen.  A negative number allows
+          for randomness, similar to <EM>count</EM>.
+
+     -<STRONG>ncolors</STRONG> <EM>num</EM>
+          The <EM>ncolors</EM> option sets the maximum number of colors to
+          be used.
+
+     -<STRONG>saturation</STRONG> <EM>value</EM>
+          The <EM>saturation</EM> option sets saturation of the color ramp
+          used  to  <EM>value</EM>  .  0  is  grayscale and 1 is very rich
+          color.  0.4 is a nice pastel.
+
+     -<STRONG>erasemode</STRONG> <EM>modename</EM>
+          As of this writing there are over 9  erase  modes  sup-
+          ported  (if  its  not  chosen its assumed random).  The
+          erase modes are random_lines, random_squares, venetian,
+          triple_wipe, quad_wipe, circle_wipe, three_circle_wipe,
+          squaretate, no_fade.
+
+     -<STRONG>erasedelay</STRONG> <EM>usecs</EM>
+          The <EM>erasedelay</EM> option sets the number  of  microseconds
+          for  steps  of  the  <STRONG>erasemode</STRONG>  (a setting of 0 and the
+          <STRONG>erasemode</STRONG> is bypassed).
+
+     <STRONG>+/-nolock</STRONG>
+          The <EM>nolock</EM> option causes <STRONG>xlock</STRONG> to only  draw  the  pat-
+          terns and not lock the display.  A key press or a mouse
+          click will terminate the screen saver.
+
+     <STRONG>-/+inwindow</STRONG>
+          Runs <STRONG>xlock</STRONG> in a window, so that you can iconify,  move,
+          or resize it and still use your screen for other stuff.
+          When running in a window, <STRONG>xlock</STRONG> no  longer  locks  your
+          screen, it just looks good.
+
+     <STRONG>-/+inroot</STRONG>
+          Runs <STRONG>xlock</STRONG> in your  root  window.   Like  the  <EM>inwindow</EM>
+          option  it  no  longer  locks the screen, it just looks
+          good.
+
+     <STRONG>-/+remote</STRONG>
+          The <EM>remote</EM> option tells <STRONG>xlock</STRONG>  to  not  stop  you  from
+          locking remote X11 servers.  This option should be used
+          with care and is intended mainly to lock X11  terminals
+          which  cannot  run  <STRONG>xlock</STRONG> locally.  If you lock someone
+          else's workstation, they will have to know  <STRONG>your</STRONG>  pass-
+          word   to  unlock  it.   Using  +<EM>remote</EM>  overrides  any
+          resource derived values for <EM>remote</EM> and  prevents  <STRONG>xlock</STRONG>
+          from  being  used  to lock other X11 servers.  (Use `+'
+          instead of `-' to override resources for other  options
+          that can take the `+' modifier similarly.)
+
+     <STRONG>-/+mono</STRONG>
+          The <EM>mono</EM> option causes  <STRONG>xlock</STRONG>  to  display  monochrome,
+          (black  and  white)  pixels  rather  than  the  default
+          colored ones on color displays.
+
+     <STRONG>-/+allowaccess</STRONG>
+          This option is required for servers which do not  allow
+          clients  to modify the host access control list.  It is
+          also useful if you need to run x clients  on  a  server
+          which is locked for some reason...  When <EM>allowaccess</EM> is
+          true, the X11 server is left open for clients to attach
+          and  thus  lowers  the  inherent  security of this lock
+          screen.  A side effect of using this option is that  if
+          <STRONG>xlock</STRONG>  is  killed -KILL, the access control list is not
+          lost.
+
+     -<STRONG>vtlock</STRONG> <EM>modename</EM>
+          This option is used on a XFree86 system  to  manage  VT
+          switching in [off|noswitch|switch|restore] mode.
+
+     <EM>off</EM>       means no VT switch locking.
+
+     <EM>switch</EM>    means VT switch locking + switching  to  xlock  VT
+               when activated.
+
+     <EM>restore</EM>   means VT switch locking + switching  to  xlock  VT
+               when  activated  +  switching  back to previous VT
+               when desactivated.
+
+     <EM>noswitch</EM>  means VT switch locking  only  when  xlock  VT  is
+               active.
+
+     <STRONG>-/+allowroot</STRONG>
+          The <EM>allowroot</EM> option allows the root password to unlock
+          the  server as well as the user who started <STRONG>xlock</STRONG>.  May
+          not be able to turn this on and off depending  on  your
+          system and how <STRONG>xlock</STRONG> was configured.
+
+     <STRONG>-/+debug</STRONG>
+          Allows <STRONG>xlock</STRONG> to be debugged by doing  all  but  locking
+          the screen.
+
+     <STRONG>-/+description</STRONG>
+          The  <EM>description</EM>  option  causes  <STRONG>xlock</STRONG>  shows  a  mode
+          description  above  password window.  The default is to
+          show this description.
+
+     <STRONG>-/+echokeys</STRONG>
+          The <EM>echokeys</EM> option causes <STRONG>xlock</STRONG> to echo '?' characters
+          for each key typed into the password prompt.  Some con-
+          sider this a security risk, so the default  is  to  not
+          echo anything.
+
+     <STRONG>-/+enablesaver</STRONG>
+          By default <STRONG>xlock</STRONG> will disable  the  normal  X  server's
+          screen  saver  since  it is in effect a replacement for
+          it.  Since it is possible to set delay parameters  long
+          enough  to  cause  phosphor burn on some displays, this
+          option will turn back on the default screen saver which
+          is very careful to keep most of the screen black.
+
+     <STRONG>-/+resetsaver</STRONG>
+          By default <STRONG>xlock</STRONG> will call XResetScreenSaver.  This may
+          be undesirable with DPMS monitors.
+
+     <STRONG>-/+grabmouse</STRONG>
+          The <EM>grabmouse</EM> option causes <STRONG>xlock</STRONG> to grab the mouse and
+          keyboard,  this is the default.  <STRONG>xlock</STRONG> can not lock the
+          screen without this.
+
+     <STRONG>-/+grabserver</STRONG>
+          The <EM>grabserver</EM> option causes <STRONG>xlock</STRONG> to grab the  server.
+          This  is not usually needed but some unsecure X servers
+          can be defeated without this.
+
+     <STRONG>-/+install</STRONG>
+          Allows <STRONG>xlock</STRONG> to install its own colormap if <STRONG>xlock</STRONG>  runs
+          out  of  colors.   May  not  work  on  with some window
+          managers (fvwm) and does  not  work  with  the  -inroot
+          option.
+
+     <STRONG>-/+mousemotion</STRONG>
+          Allows you to turn on and off the  sensitivity  to  the
+          mouse to bring up the password window.
+
+     <STRONG>-/+sound</STRONG>
+          Allows you to turn on and off sound if  installed  with
+          the capability.
+
+     <STRONG>-/+timeelapsed</STRONG>
+          Allows you to find out how long a machine is locked  so
+          you  can  complain  to an administrator that someone is
+          hogging a machine.
+
+     <STRONG>-/+usefirst</STRONG>
+          The <EM>usefirst</EM> option causes <STRONG>xlock</STRONG> to use  the  keystroke
+          which got you to the password screen as the first char-
+          acter in the password.  The default is  to  ignore  the
+          first key pressed.
+
+     <STRONG>-/+verbose</STRONG>
+          Verbose mode, tells what options it is going to use.
+
+     -<STRONG>nice</STRONG> <EM>nicelevel</EM>
+          The <EM>nice</EM> option sets system nicelevel of the <STRONG>xlock</STRONG> pro-
+          cess to <EM>nicelevel</EM> .
+
+     -<STRONG>lockdelay</STRONG> <EM>seconds</EM>
+          The <EM>lockdelay</EM> option sets the number of <EM>seconds</EM>  before
+          the  screen  needs a password to be unlocked.  Good for
+          use with an autolocking mechanism like xautolock(1).
+
+     -<STRONG>timeout</STRONG> <EM>seconds</EM>
+          The <EM>timeout</EM> option sets the number  of  <EM>seconds</EM>  before
+          the password screen will time out.
+
+     -<STRONG>font</STRONG> <EM>fontname</EM>
+          The <EM>font</EM> option sets the font to be used on the  prompt
+          screen.
+
+     -<STRONG>planfont</STRONG> <EM>fontname</EM>
+          option sets the font to be used for the  text  that  is
+          displayed in the lower part of the password screen.
+
+     -<STRONG>fg</STRONG> <EM>color</EM>
+          The <EM>fg</EM> option sets the color of the text on  the  pass-
+          word screen to <EM>color</EM> .
+
+     -<STRONG>bg</STRONG> <EM>color</EM>
+          The <EM>bg</EM> option sets the color of the background  on  the
+          password screen to <EM>color</EM> .
+
+     -<STRONG>foreground</STRONG> <EM>color</EM>
+          The <EM>foreground</EM> option sets the color of the text on the
+          password screen to <EM>color</EM> .
+
+     -<STRONG>background</STRONG> <EM>color</EM>
+          The <EM>background</EM> option sets the color of the  background
+          on the password screen to <EM>color</EM> .
+
+     -<STRONG>username</STRONG> <EM>string</EM>
+          Text <EM>string</EM> is shown in front of user name, defaults to
+          "Name: ".
+
+     -<STRONG>password</STRONG> <EM>string</EM>
+          Text <EM>string</EM> is the password prompt string, defaults  to
+          "Password: ".
+
+     -<STRONG>info</STRONG> <EM>string</EM>
+          Text <EM>string</EM> is an informational  message  to  tell  the
+          user what to do, defaults to "Enter password to unlock;
+          select icon to lock.".
+
+     -<STRONG>validate</STRONG> <EM>string</EM>
+          Text <EM>string</EM> is a message  shown  while  validating  the
+          password, defaults to "Validating login..."
+
+     -<STRONG>invalid</STRONG> <EM>string</EM>
+          Text  <EM>string</EM>  is  a  message  shown  when  password  is
+          invalid, defaults to "Invalid login."
+
+     -<STRONG>geometry</STRONG> <EM>geom</EM>
+          The <EM>geometry</EM> option sets <EM>geom</EM> the size  and  offset  of
+          the  lock  window  (normally  the  entire screen).  The
+          entire screen format is still  used  for  entering  the
+          password.  The purpose is to see the screen even though
+          it is locked.  This should be used with  caution  since
+          many of the modes will fail if the windows are far from
+          square or are too small  (size  must  be  greater  than
+          0x0).   This  should  also be used with -enablesaver to
+          protect screen from phosphor burn.
+
+     -<STRONG>icongeometry</STRONG> <EM>geom</EM>
+          The <EM>icongeometry</EM> option  sets  <EM>geom</EM>  the  size  of  the
+          iconic  screen  (normally 64x64) seen when entering the
+          password.  This should be used with caution since  many
+          of  the  modes  will  fail  if the windows are far from
+          square or are too small  (size  must  be  greater  than
+          0x0).   The  greatest size is 256x256.  There should be
+          some limit so  users  could  see  who  has  locked  the
+          screen.  Position information of icon is ignored.
+
+     -<STRONG>glgeometry</STRONG> <EM>geom</EM>
+          The <EM>glgeometry</EM> option sets <EM>geom</EM> the size of the  screen
+          for gl modes.  Not normally available or needed.
+
+     <STRONG>-/+wireframe</STRONG>
+          Turn on/off wireframe, available  on  atlantis,  daisy,
+          gears, life3d, mountain, sproingies, superquadrics, and
+          triangle.
+
+     <STRONG>-/+use3d</STRONG>
+          Turn on/off 3d view, available on bouboule, pyro, star,
+          and worm.
+
+     -<STRONG>delta3d</STRONG> <EM>value</EM>
+          Space between the center of your 2 eyes for 3d mode.
+
+     -<STRONG>none3d</STRONG> <EM>color</EM>
+          Color used for empty size in 3d mode.
+
+     -<STRONG>right3d</STRONG> <EM>color</EM>
+          Color used for right eye in 3d mode.
+
+     -<STRONG>left3d</STRONG> <EM>color</EM>
+          Color used for left eye in 3d mode.
+
+     -<STRONG>both3d</STRONG> <EM>color</EM>
+          Color used for overlapping images for  left  and  right
+          eye in 3d mode.
+
+     -<STRONG>program</STRONG> <EM>programname</EM>
+          The <EM>program</EM> option sets the program to be used  as  the
+          fortune generator.  Currently used only for marquee and
+          nose modes.
+
+     -<STRONG>messagesfile</STRONG> <EM>formatted</EM>-<EM>filename</EM>
+          The <EM>messagesfile</EM> option sets the file to be used as the
+          fortune  generator.   The  first entry is the number of
+          fortunes, the next line  contains  the  first  fortune.
+          Fortunes  begin  with  a  "%%"  on  a  line  by itself.
+          Currently used only for marquee and nose modes.  If one
+          exists, it takes precedence over the fortune program.
+
+     -<STRONG>messagefile</STRONG> <EM>filename</EM>
+          The <EM>messagefile</EM> option sets the file whose contents are
+          displayed.   Currently  used  only for marquee and nose
+          modes.  If one exists, it  takes  precedence  over  the
+          fortune program and messagesfile.
+
+     -<STRONG>message</STRONG> <EM>textstring</EM>
+          The <EM>message</EM> option sets the text to be displayed  in  a
+          mode.   Currently  used only for flag, marquee and nose
+          modes.  If one exists, it  takes  precedence  over  the
+          fortune program, messagesfile and message.
+
+     -<STRONG>messagefont</STRONG> <EM>fontname</EM>
+          The <EM>messagefont</EM> option sets the font to be used in  the
+          mode.   Currently used only for flag, marquee, and nose
+          modes.
+
+     -<STRONG>bitmap</STRONG> <EM>filename</EM>
+          The <EM>bitmap</EM> option sets the xbm, xpm, or ras file to  be
+          displayed with flag, image, life, life1d, maze, or puz-
+          zle mode.  For eyes and  pacman  only  a  xbm  file  is
+          accepted.   Certain modes reject the bitmap if too big.
+          /
+
+
+
+</PRE>
+<H2>MORE OPTIONS (these may not be available)</H2><PRE>
+     -<STRONG>cpasswd</STRONG> <EM>crypted</EM>-<EM>password</EM>
+          The <EM>cpasswd</EM> option sets the key to be this text  string
+          to unlock <STRONG>xlock</STRONG> instead of password file.
+
+     -<STRONG>forceLogout</STRONG> <EM>minutes</EM>
+          The <EM>forceLogout</EM> option sets <EM>minutes</EM> to auto-logout.
+
+     -<STRONG>logoutButtonLabel</STRONG> <EM>string</EM>
+          Text <EM>string</EM> is a message  shown  inside  logout  button
+          when logout button is displayed.  Defaults to "Logout".
+
+     -<STRONG>logoutButtonHelp</STRONG> <EM>string</EM>
+          Text <EM>string</EM> is a message shown  outside  logout  button
+          when  logout  button  is displayed.  Defaults to "Click
+          the \"Logout\" button to log  out  current\n  user  and
+          make workstation available."
+
+     -<STRONG>logoutFailedString</STRONG> <EM>string</EM>
+          Text <EM>string</EM>  is  a  message  shown  when  a  logout  is
+          attempted  and  fails.   Defaults  to  "Logout  attempt
+          FAILED.\n  Current  user  could  not  be  automatically
+          logged out."
+
+     <STRONG>-/+dtsaver</STRONG>
+          Turn on/off CDE Saver Mode.  This option is only avail-
+          able if CDE support was compiled in.
+
+     -<STRONG>modulepath</STRONG> <EM>path</EM>
+          The <EM>modulepath</EM> option sets the <EM>directories</EM>  that  <STRONG>xlock</STRONG>
+          searches  for  mode  modules  to  load.   It is a colon
+          separated list of directories to  search.  If  "%S"  is
+          included  in  the  path,  it is replaced by the default
+          modulepath.  To add a private module directory  to  the
+          default  path, use something like '%S:~/mymoduledir' as
+          the path.  This option is only available if module sup-
+          port was compiled in.
+
+     -<STRONG>locksound</STRONG> <EM>string</EM>
+          Text <EM>string</EM> references  sound  to  use  at  lock  time.
+          Default  sound,  male  voice:   "Thank  you,  for  your
+          cooperation."
+
+     -<STRONG>infosound</STRONG> <EM>string</EM>
+          Text <EM>string</EM> references sound to  use  for  information.
+          Default sound, male voice:  "Identify please."
+
+     -<STRONG>validsound</STRONG> <EM>string</EM>
+          Text <EM>string</EM> references sound  to  when  a  password  is
+          valid.  Default sound, female voice:  "Complete."
+
+     -<STRONG>invalidsound</STRONG> <EM>string</EM>
+          Text <EM>string</EM> references sound  to  when  a  password  is
+          invalid.   Default  sound, female voice: "I am not pro-
+          grammed to give you that information."
+
+     -<STRONG>startCmd</STRONG> <EM>string</EM>
+          Text <EM>string</EM> command  to  execute  when  the  screen  is
+          locked.  Commonly  used instructions include:  "zaway".
+          This command, if still  running  when  the  screensaver
+          exist, will be killed.
+
+     -<STRONG>endCmd</STRONG> <EM>string</EM>
+          Text <EM>string</EM> command  to  execute  when  the  screen  is
+          unlocked.
+
+     -<STRONG>logoutCmd</STRONG> <EM>string</EM>
+          Text <EM>string</EM> command to execute when  the  program  logs
+          the  user out (either via the autologout or by pressing
+          the logout button).
+
+     -<STRONG>mailCmd</STRONG> <EM>string</EM>
+          Text <EM>string</EM> command to  execute  when  the  program  to
+          check mail.
+
+     -<STRONG>mailIcon</STRONG> <EM>string</EM>
+          Text <EM>string</EM> of file for the "mail arrived" bitmap.
+
+     -<STRONG>nomailIcon</STRONG> <EM>string</EM>
+          Text <EM>string</EM> of file for the "no mail" bitmap.
+
+     <STRONG>-dpmsstandby</STRONG>  <STRONG>seconds</STRONG>
+          Allows one to  set  DPMS  Standby  for  monitor  (0  is
+          defined  as  infinite).   (Horizontal sync on, Vertical
+          sync off, RGB guns off, power supply on, tube filaments
+          energized,   (screen  saver  mode).   Typical  17  inch
+          screen...  110 out of 120 watts with a 3  sec  recovery
+          time.)   This  option is only available if DPMS support
+          was compiled in.
+
+     <STRONG>-dpmssuspend</STRONG>  <STRONG>seconds</STRONG>
+          Allows one to  set  DPMS  Suspend  for  monitor  (0  is
+          defined  as  infinite).  (Horizontal sync off, Vertical
+          sync on, RGB guns off, power supply off, tube filaments
+          energized.   Typical  17 inch screen ...  15 out of 120
+          watts with a 3 sec recovery time.)  This option is only
+          available if DPMS support was compiled in.
+
+     <STRONG>-dpmsoff</STRONG>  <STRONG>seconds</STRONG>
+          Allows one to set DPMS Power  Off  for  monitor  (0  is
+          defined  as  infinite).  (Horizontal sync off, Vertical
+          sync off, Small auxiliary circuit stays on  to  monitor
+          the HS/VS signals to enable power on when data needs to
+          be displayed on the screen.  Typical 17 inch screen ...
+          5  out of 120 watts with a 10 sec recovery time.)  This
+          option is only available if DPMS support  was  compiled
+          in.
+
+
+
+</PRE>
+<H2>SPECIAL MODE DEPENDENT OPTIONS</H2><PRE>
+     -<STRONG>neighbors</STRONG> <EM>num</EM>
+          The <EM>neighbors</EM> option sets the number of neighbors of  a
+          cell  to  3,  4,  6,  9 (may not have real mathematical
+          meaning), or 12 for several automata modes  (<EM>ant</EM>,  <EM>bug</EM>,
+          <EM>demon</EM>,  <EM>dilemma</EM>, <EM>life</EM>, <EM>loop</EM>, and <EM>wire</EM>) (<EM>bug</EM> <EM>and</EM> <EM>loop</EM> do
+          not span this full range).  Setting it to  0  typically
+          randomizes   this,   except   where  bitmaps  are  used
+          (<EM>dilemma</EM>, <EM>life</EM>, <EM>voters</EM>, and <EM>wator</EM>).
+
+     <STRONG>-/+eyes</STRONG>
+          Turn on and off eyes for <EM>ant</EM> and <EM>bug</EM>.
+
+     <STRONG>-/+cycle</STRONG>
+          Turn on and off colour cycling  in  <EM>crystal</EM>,  <EM>starfish</EM>,
+          and <EM>tetris</EM>.
+
+     <STRONG>-/+trackmouse</STRONG>
+          Turn on and off mouse interaction in <EM>eyes</EM>,  <EM>julia</EM>,  and
+          <EM>swarm</EM>.
+
+     -<STRONG>rule</STRONG> <EM>S</EM>&lt;<EM>neighborhood</EM>&gt;/<EM>B</EM>&lt;<EM>neighborhood</EM>&gt;
+          Allows one to set the rule for <EM>life</EM> and <EM>life3d</EM>. Special
+          parameters:  P, picks a random rule from all rules that
+          have known patterns; G, picks a random  rule  from  all
+          rules that have known gliders.  For <EM>life</EM> a good example
+          is Conway's rule which  is  S23/B3.   For  <EM>life3d</EM>  good
+          examples  are  Bay's  rules  which are S45/B5, S567/B6,
+          S56/B5, and S67/B67.
+
+     -<STRONG>lifefile</STRONG> <EM>filename</EM>
+          The <EM>lifefile</EM> option sets the <EM>life</EM> and <EM>life3d</EM>  lifeform.
+          Only  one format is currently supported, similar to the
+          #P xlife format.  For <EM>life3d</EM>, 2 linefeeds in a row  are
+          assumed to advance the depth.
+
+     -<STRONG>whalespeed</STRONG> <EM>num</EM>
+          Allows one to set the speed of the whales  and  dolphin
+          in <EM>atlantis</EM>.
+
+     <STRONG>-/+truchet</STRONG>
+          Turn on and off Truchet lines (trail) in <EM>ant</EM>.
+
+     <STRONG>-/+boil</STRONG>
+          Turn on and off having the bubbles bubble up in <EM>bubble</EM>.
+
+     -<STRONG>nx</STRONG> <EM>num</EM>
+          Allows one to set  the  number  of  unit  cells  in  x-
+          direction in <EM>crystal</EM>.
+
+     -<STRONG>ny</STRONG> <EM>num</EM>
+          Allows one to set  the  number  of  unit  cells  in  y-
+          direction in <EM>crystal</EM>.
+
+     <STRONG>-/+centre</STRONG>
+          Turn on and off the centering on screen in <EM>crystal</EM>.
+
+     <STRONG>-/+maxsize</STRONG>
+          Turn on and off the centering on screen in <EM>crystal</EM>.
+
+     <STRONG>-/+cell</STRONG>
+          Turn on and off the drawing of unit cell in <EM>crystal</EM>.
+
+     <STRONG>-/+grid</STRONG>
+          Turn on and off the drwing of grid of  unit  cells  (if
+          -cell is on) in <EM>crystal</EM>.
+
+     <STRONG>-/+garden</STRONG>
+          Turn off and on garden look in <EM>daisy</EM>.
+
+     <STRONG>-/+popex</STRONG>
+          Turn on and off the  population  explosion  counter  in
+          <EM>dclock</EM>.
+
+     <STRONG>-/+forest</STRONG>
+          Turn on and off the tropical deforest  (hectares/acres)
+          counter in <EM>dclock</EM>.
+
+     <STRONG>-/+hiv</STRONG>
+          Turn on and off the HIV infection counter in <EM>dclock</EM>.
+
+     <STRONG>-/+lab</STRONG>
+          Turn on and off the Animal Research counter in <EM>dclock</EM>.
+
+     <STRONG>-/+veg</STRONG>
+          Turn on and  off  the  Animal  Consumation  counter  in
+          <EM>dclock</EM>.
+
+     <STRONG>-/+y2k</STRONG>
+          Turn on and off the Year 2000 countdown in <EM>dclock</EM>.
+
+     <STRONG>-/+millennium</STRONG>
+          Turn on and off the Second Millennium (January 1, 2001)
+          countdown in <EM>dclock</EM>.
+
+     -<STRONG>bonus</STRONG> <EM>value</EM>
+          Allows one to set the bonus for cheating... between 1.0
+          and 4.0 in <EM>dilemma</EM>.
+
+     <STRONG>-/+conscious</STRONG>
+          Turn off and on self-awareness in <EM>dilemma</EM>.
+
+     <STRONG>-/+grow</STRONG>
+          Turn  on  and  off  growing  fractals  (else  they  are
+          animated) for <EM>drift</EM>.
+
+     <STRONG>-/+liss</STRONG>
+          Turn on and off using lissajous figures to  get  points
+          for <EM>drift</EM>.
+
+     <STRONG>-/+noants</STRONG>
+          Turn off and on ants in <EM>moebius</EM>.
+
+     <STRONG>-/+solidmoebius</STRONG>
+          Turn on and off solid Mobius strip in <EM>moebius</EM>.
+
+     <STRONG>-/+invert</STRONG>
+          Turn on and off inverting of the <EM>flag</EM>.
+
+     <STRONG>-/+tracks</STRONG>
+          Turn on and off star tracks in <EM>galaxy</EM>.
+
+     <STRONG>-/+decay</STRONG>
+          Turn on and off decaying orbits for <EM>grav</EM>.
+
+     <STRONG>-/+trail</STRONG>
+          Turn on and off decaying trail of dots for <EM>grav</EM>.
+
+     <STRONG>-/+ellipse</STRONG>
+          Turn on and off ellipse format in <EM>helix</EM>.
+
+     <STRONG>-/+martin</STRONG>
+          Turn on and off  Barry  Martin's  square  root  <EM>hop</EM>.  <STRONG>-</STRONG>
+          <STRONG>/+popcorn</STRONG>  Turn  on and off Clifford A. Pickover's pop-
+          corn <EM>hop</EM>.
+
+     <STRONG>-/+ejk1...ejk6</STRONG>
+          Turn on and off Ed J. Kubaitis' <EM>hops</EM>.
+
+     <STRONG>-/+rr</STRONG>
+          Turn on and off Renaldo Recuerdo's <EM>hop</EM>.
+
+     <STRONG>-/+jong</STRONG>
+          Turn on and off Jong's <EM>hop</EM>.
+
+     <STRONG>-/+sine</STRONG>
+          Turn on and off Barry Martin's sine <EM>hop</EM>.
+
+     <STRONG>-/+disconnected</STRONG>
+          Turn on and off disconnected pen movement in <EM>kaleid</EM>.
+
+     <STRONG>-/+serial</STRONG>
+          Turn on and off  sequential  allocation  of  colors  in
+          <EM>kaleid</EM>.
+
+     <STRONG>-/+alternate</STRONG>
+          Turn on and off alternate rotated display mode <EM>kaleid</EM>.
+
+     <STRONG>-/+quad</STRONG>
+          Turn on and off quad mirrored/rotated mode  similar  to
+          size 4 in <EM>kaleid</EM>.
+
+     <STRONG>-/+oct</STRONG>
+          Turn on and off oct mirrored/rotated  mode  similar  to
+          size 8 in <EM>kaleid</EM>.
+
+     <STRONG>-/+linear</STRONG>
+          Turn on and  off  Cartesian/Polar  coordinate  mode  in
+          <EM>kaleid</EM>.
+
+     <STRONG>-/+callahan</STRONG>
+          Turn on and off  Paul  Callahan's  S2b34/B2a  hexagonal
+          <EM>life</EM>.
+
+     <STRONG>-/+andreen</STRONG>
+          Turn on and off Bob Andreen's S2a2b4a/B2a3a4b hexagonal
+          <EM>life</EM>.
+
+     <STRONG>-/+totalistic</STRONG>
+          Turn on and off totalistic rules for <EM>life1d</EM>. If this is
+          off  then  it  follows  rules  of  the LCAU collection.
+          These rules may not be symmetric and are more general.
+
+     <STRONG>-/+additive</STRONG>
+          Turn on and off additive functions mode in <EM>lisa</EM>.
+
+     <STRONG>-/+ammann</STRONG>
+          Turn on and off lines for <EM>penrose</EM>.
+
+     -<STRONG>increment</STRONG> <EM>value</EM>
+          Allows fine adjustments to order in <EM>mandelbrot</EM>.
+
+     <STRONG>-/+erase</STRONG>
+          Turn on and off erasing for <EM>spline</EM>. If this  option  is
+          on,  <EM>cycles</EM>  is  divided by 64 to compute the number of
+          lines, so as to be compatible when using -fullrandom.
+
+     -<STRONG>factory</STRONG> <EM>num</EM>
+          Number of extra factory parts in <EM>pipes</EM>.
+
+     <STRONG>-/+fisheye</STRONG>
+          Turn on if you want a zoomed-in view of <EM>pipes</EM>.
+
+     <STRONG>-/+tightturns</STRONG>
+          Turn on if you want the <EM>pipes</EM> to bend more often.
+
+     <STRONG>-/+rotatepipes</STRONG>
+          Turn on if you want the pipe system rotated in <EM>pipes</EM>.
+
+     <STRONG>-/+complete</STRONG>
+          Turn on or off complete graph morphing in <EM>qix</EM>.
+
+     -<STRONG>size[xyz]</STRONG> <EM>num</EM>
+          Number represents the number of cubies on the x, y,  or
+          z  axis.   Negative  numbers offer randomness from 2 to
+          the absolute value of the number.  <EM>star</EM>.
+
+     <STRONG>-/+hideshuffling</STRONG>
+          Turn on or off hidden shuffle phase for <EM>rubik</EM>.
+
+     <STRONG>-/+border</STRONG>
+          Turn on or off borders in <EM>shape</EM>.
+
+     <STRONG>-/+</STRONG><EM>shape</EM>
+          Turn on or off shadowing in <EM>shape</EM>.
+
+     <STRONG>-/+</STRONG><EM>shape</EM>
+          Turn on or off stippling in <EM>shape</EM>.
+
+     -<STRONG>trek</STRONG> <EM>num</EM>
+          If its a high number you will see the  space  ship  all
+          the time in <EM>star</EM>.
+
+     <STRONG>-/+rock</STRONG>
+          Turn on and off rocks for <EM>star</EM>. If this is  off,  stars
+          will be seen instead.
+
+     <STRONG>-/+straight</STRONG>
+          Turn on if <EM>star</EM> gets you motion sick.
+
+     -<STRONG>cyclepeed</STRONG> <EM>num</EM>
+          Set speed of cycling in <EM>starfish</EM>.
+
+     -<STRONG>rotation</STRONG> <EM>num</EM>
+          Set rotation velocity in <EM>starfish</EM>.
+
+     -<STRONG>thickness</STRONG> <EM>num</EM>
+          Set thickness in <EM>starfish</EM>.
+
+     <STRONG>-/+rock</STRONG>
+          Turn on and off blob for <EM>starfish</EM>.
+
+     -<STRONG>spinspeed</STRONG> <EM>num</EM>
+          Set speed of rotation, in degrees per frame for  <EM>super-</EM>
+          <EM>quadrics</EM>.
+
+     -<STRONG>duration</STRONG> <EM>seconds</EM>
+          Allows one to set a duration  for  a  mode  in  <EM>random</EM>.
+          Duration of 0 is defined as infinite.
+
+     <STRONG>-/+fullrandom</STRONG>
+          Turn on/off randomness options within modes in  <EM>random</EM>.
+          Not implemented for all mode options.
+
+     -<STRONG>modelist</STRONG> <EM>textstring</EM>
+          Allows one to pass a list of files to randomly  display
+          to <EM>random</EM>. "all" will get all files but blank (and bomb
+          if  compiled  in).  "all,blank"  will  get  all  modes.
+          "all,-image bounce,+blank" will get all modes but image
+          and bounce.  "bug wator" will get only bug  and  wator.
+          "allgl"  will  get  only  the  GL modes if compiled in,
+          all-allgl will get all but the GL modes, "allnice" will
+          weed  out  high cpu usage modes (as well as hackers and
+          gl modes).  "allxpm" will get all modes that  use  xpm.
+          "allwrite"  will  get  all modes that take advantage of
+          writable colormaps (not including xpm).   "all3d"  will
+          get all the modes that support this option.  "allmouse"
+          will get all the modes that support mouse  interaction.
+          Similarly,    "allautomata"    for    automata   modes,
+          "allfractal"  for  fractal  modes,  "allgeometry"   for
+          geometry modes, "allspace" for space modes.  The random
+          mode itself can not be referenced.
+
+     <STRONG>-/+sequential</STRONG>
+          Turn on non-random <EM>random</EM> option.
+
+
+
+</PRE>
+<H2>**WARNING**</H2><PRE>
+     <STRONG>xlock</STRONG> can appear to hang if it is  competing  with  a  high-
+     priority  process  for  the  CPU.  For  example, if <STRONG>xlock</STRONG> is
+     started after a process with  'nice  -20'  (high  priority),
+     <STRONG>xlock</STRONG> will take  considerable amount of time to respond.
+
+
+
+</PRE>
+<H2>SHADOW PASSWORDS</H2><PRE>
+     If the machine is using a shadow password system, then <STRONG>xlock</STRONG>
+     may  not  be  set up to get the real password and so must be
+     given one of its own. This can  be  either  on  the  command
+     line,   via   the   <STRONG>-cpasswd</STRONG>   option,   or   in   the  file
+     <STRONG>$HOME/.xlockrc</STRONG>, with the first taking precedence.   In  both
+     cases  an  encrypted  password is expected (see makekey(8)).
+     If neither is given, then <STRONG>xlock</STRONG> will prompt for  a  password
+     and  will  use that, also storing an encrypted version of it
+     in <STRONG>$HOME/.xlockrc</STRONG> for future use.
+
+
+
+</PRE>
+<H2>BUGS</H2><PRE>
+     "kill -KILL <STRONG>xlock</STRONG> " causes the server that was locked to  be
+     unusable, since all hosts (including localhost) were removed
+     from the access control list to lock out new X clients,  and
+     since  <STRONG>xlock</STRONG>  could  not catch SIGKILL, it terminated before
+     restoring the access control list.  This will  leave  the  X
+     server  in  a state where "<EM>you</EM> <EM>can</EM> <EM>no</EM> <EM>longer</EM> <EM>connect</EM> <EM>to</EM> <EM>that</EM>
+     <EM>server</EM>, <EM>and</EM> <EM>this</EM> <EM>operation</EM> <EM>cannot</EM>  <EM>be</EM>  <EM>reversed</EM>  <EM>unless</EM>  <EM>you</EM>
+     <EM>reset</EM>  <EM>the</EM> <EM>server</EM>."            -From the X11R4 Xlib Documen-
+     tation, Chapter 7.
+     NCD terminals do not allow xlock to  remove  all  the  hosts
+     from  the  access  control list.  Therefore you will need to
+     use the "-remote" and "-allowaccess" switches.  If you  hap-
+     pen  to run without "-allowaccess" on an NCD terminal, <STRONG>xlock</STRONG>
+     will not work and you will need to reboot the  terminal,  or
+     simply  go into the SETUP menus, under 'Network Parameters',
+     and turn off TCP/IP access control.
+
+
+</PRE>
+<H2>SEE ALSO</H2><PRE>
+     X(1), Xlib Documentation.
+
+
+
+</PRE>
+<H2>AUTHOR</H2><PRE>
+     Maintained by:
+          David Albert Bagley, &lt;<EM>bagleyd</EM>@<EM>tux</EM>.<EM>org</EM>&gt;
+
+     The latest version is currently at:
+          <EM>ftp</EM>://<EM>ftp</EM>.<EM>tux</EM>.<EM>org</EM>/<EM>pub</EM>/<EM>tux</EM>/<EM>bagleyd</EM>/<EM>xlockmore</EM>
+          <EM>ftp</EM>://<EM>ftp</EM>.<EM>x</EM>.<EM>org</EM>/<EM>contrib</EM>/<EM>applications</EM>
+
+     Original Author:
+          Patrick J. Naughton, &lt;<EM>naughton</EM>@<EM>eng</EM>.<EM>sun</EM>.<EM>com</EM>&gt;
+          Mailstop 21-14
+          Sun Microsystems Laboratories, Inc.
+          Mountain View, CA  94043
+          415/336-1080
+
+     with many additional contributors.
+
+
+
+</PRE>
+<H2>COPYRIGHT</H2><PRE>
+     Copyright (c) 1988-91 by Patrick J. Naughton
+     Copyright (c) 1993-98 by David A. Bagley
+
+     Permission  to  use,  copy,  modify,  and  distribute   this
+     software  and  its documentation for any purpose and without
+     fee is hereby granted, provided  that  the  above  copyright
+     notice  appear  in  all  copies and that both that copyright
+     notice and this permission notice appear in supporting docu-
+     mentation.
+     The original BSD daemon is Copyright (c) 1988 Marshall  Kirk
+     McKusick.  All Rights Reserved.
+     DEC, HP, IBM, Linux, SCO, SGI,  and  Sun  icons  have  their
+     respective copyrights.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+</PRE>
+</BODY>
+</HTML>
diff --git a/xlockmore-4.14/etc/README.etc b/xlockmore-4.14/etc/README.etc
new file mode 100644 (file)
index 0000000..61551a2
--- /dev/null
@@ -0,0 +1,48 @@
+These files are just examples of configuration files for xlock and
+other tools which I use.  They are not normally required.
+
+descrip.mms is no longer maintained since I can no longer check it on my
+  VMS system.  make.com should work fine.
+fortune.dat is for those who do not have fortune.
+play.sh is a hack to get sound.
+rplay* are ideas for setting up a more sophisticated sound package.
+system.*wm*rc.xlock files are for fvwm2, fvwm, WindowMaker, openwin 
+  (olwm & olvwm) and motif (mwm and dtwm) window managers.  
+  By default they include all modes which may not be available depending 
+  on your system.  The openwin file can be referenced directly, the others 
+  need to be placed in menu files.
+xlock*life.pl stuff is for adding life patterns to life.c not all formats
+  are handled.  However, the major format that is not handled here is close
+  to the format I use already in life.c.
+glider.life and glider.hlife are simple examples of files that can be read
+  into the life mode like:
+     "-lifefile glider.life" (which works with "-neighbors 8 -rule S23/B3") 
+     "-lifefile glider.hlife" (which works with "-callahan" or
+             "-neighbors 6 -rule S2b34/B2a")
+  There is a limit of 128 initial live cells set by NUMFILEPTS in life.c.
+glider.3dlife is a simple example of a files that can be read into the
+  life3d mode like:
+     "-life3dfile glider.3dlife" (which works with "-rule3d S45/B5")
+  There is a limit of 84 initial live cells set by NUMFILEPTS in life3d.c.
+xlockrandimage.pl picks a random image.  Does not have to be used since
+  it is built in, one can just give a directory name.  Some really old UNIX
+  systems might not have dirent.h.
+
+Contributed by Charles Vidal <vidalc@club-internet.fr>
+xlock.tcl is another xlock launcher similar to xmlock and xalock but using
+  tcl.
+xlock.java and xlockFrame.java is yet another xlock launcher similar to
+  xmlock and xalock but this time using java.  Seems to require JDK 1.1.1,
+  on my 1.0 it can not spawn xlock.
+
+Contributed by Igor Markov <imarkov@math.ucla.edu>
+xlocksat.pl  use like "xlock -saturation `xlocksat.pl`"  The idea is that
+  high saturation looks weird at night and low saturation looks weird
+  during the day.  Unfortuantely, as the day progresses the saturation does
+  not change.
+xlockranddur.pl  use like "xlock random -duration `xlockranddur.pl`"
+  This gives a random duration of a mode (providing you have fortune!).
+
+Contributed by R. Cohen-Scali <remi.cohenscali@pobox.com>
+vtswitch       is a command line tool to disable/enable VT switching for Linux.
+               Do "chown root.bin vtswitch; chmod 4755 vtswitch"
diff --git a/xlockmore-4.14/etc/chkmbox/Mail.xpm b/xlockmore-4.14/etc/chkmbox/Mail.xpm
new file mode 100644 (file)
index 0000000..b901658
--- /dev/null
@@ -0,0 +1,88 @@
+/* XPM */
+static char * image_name[] = {
+"56 46 39 1",
+"      c #FFFFFBEEFFFF",
+".     c #B6DAAEBAB6DA",
+"X     c #082004100820",
+"o     c #9E799A699E79",
+"O     c #8E388A288E38",
+"+     c #38E36DB6A699",
+"@     c #BEFBB6DABEFB",
+"#     c #000000001861",
+"$     c #A69979E78E38",
+"%     c #79E786179E79",
+"&     c #A699A289A699",
+"*     c #AEBAAEBAB6DA",
+"=     c #000008200820",
+"-     c #000000001040",
+";     c #8E38861779E7",
+":     c #A6999E79A699",
+">     c #71C679E78617",
+",     c #AEBA9E795965",
+"<     c #AEBAB2CACF3C",
+"1     c #96589658AEBA",
+"2     c #514471C68E38",
+"3     c #FFFFF3CEFFFF",
+"4     c #C71BBAEAC71B",
+"5     c #CF3CC71BCF3C",
+"6     c #EFBEF3CEF7DE",
+"7     c #69A669A671C6",
+"8     c #FFFFFFFFFFFF",
+"9     c #AEBAA69971C6",
+"0     c #AEBA61856185",
+"q     c #AEBAA699AEBA",
+"w     c #71C675D671C6",
+"e     c #5144A2894924",
+"r     c #861779E78617",
+"t     c #BEFBC30BCF3C",
+"y     c #69A68617BEFB",
+"u     c #A699A699A699",
+"i     c #965896589658",
+"p     c #F7DEB2CAAEBA",
+"a     c #51445555FFFF",
+"                                                       .",
+" ......................................................X",
+" ...............oOO+O+O+O+OOoo.........................X",
+" ........@....OO++++++++++X+X++o...@....@....@....@....X",
+" o@..o@..o.@O++XoOo+#+#+@$%+OXXX+&...o@..o@..o..@o...o@X",
+" ...@.*....O=+X+X+X.O-+=;%$OX+XXXXo*@....*...*@....*@..X",
+" o.o.o@o@o+X+X+:oX+$+++$++.>,#+X+XXo.o@o@o@o@o.o@o@o.o.X",
+" @*@..o.*+X+#+o.O@<*@+$*$*,1>$X+X+XXo.o*...*..o.*.*...oX",
+" o.o.o@o+X+X++@2++O@.*<%@%1%-+>X+-+XXo@o@o@o@1.o@o@o@o@X",
+" @..:*.+X+-+-++++$%..<..O<>,OO#+X+X+XX1.o*..o...o...o*.X",
+" o.o.oOX+X+++++$%. .3..O.O.24O+XXXOX+X+o<o.1.o.o.1@1.o.X",
+" .o.@.X+-+-+-++@  .......*1$O+X+OX++XXX+o.o...o.o.o...oX",
+" o.o.++X++++$56@ . . ..O.O.7<X+XOXX+OXXX.:.o@1.o<o.o@1.X",
+"3@1.o+#+-++O*     . ......O@O%$+X+-+X+XX+.o.o.:.o.o<o.oX",
+" o.1OX+o:O+$3. . . . ....O<;.O+X+X+X+-+XXo.1.o.o.o.o.o.X",
+"3oo.++Xo:*5+  8   . ......>9>$X+X+-+X+X+X+o.:o:.o:o.:ooX",
+" o@%OX+O++3* .8@8. . ..O.O.%.-+-+-+-+-XXX+.o.o.o.o.:.o.X",
+" o10O.X+<++ .8.8. .....@..O.O+-+X+X+X+X+XXoo:oo1oooooooX",
+" o.+OOqX+q3+ .8.8.8.8.@O.O.O.X+X+-+-+XXOXX.1.o.o.1.o.1.X",
+" oo%%*O.X@*@...*......*...%$O+X+X+-+XX XOXoo:oo:ooo1oooX",
+" oq+;O@OO-+$%.. . .....O.O@w<O+-+X+-X   XOoo.e+r<o:o4ooX",
+"3oo+O1O..OX+X+=........<$eOOOOo+-+XX     -%>++3#e$:ooooX",
+" o:+>:.O.X+X+-+X+O.O.O.O.$<O0+2+o+X   .   X+4  @+*:ooo:X",
+" :o+2,ooO+X+X+X+=+@..@O%$;O12o+;+X   . . ..     #e1:$:oX",
+" O1+:O>o:X+-+X+-+X$X.O.O*>O+O+>+X   . ...    .  t+1o1e1X",
+"3oo+O$O%:+X+-+-+X+X+=+%$OO1>,1+X   . ..    ..    #eo::oX",
+" oo0+%+;$%+-+X+-+-+X+X++%+,+2+#   ...    ..  ..  @+$oeqX",
+"3ooy+;1>%O++X+-+X+X+X+#>9>+$+X   ..    ..  ..     ->::oX",
+" eqe$+$+%$>O+X+X+-+-+XO++++++@@..@................@.O0<X",
+" ::q1=0%>,O>u+X+X+X+X+O#36 3 3   888                +>iX",
+" $oOo+++O+2+OX+-+-+-++$X  .. . .  888          upu  X+:X",
+" o%ooo#++>+O>+-+X+XoO%+X  . . .                ;u,  -,OX",
+" ,O%o%;+++$+O-+-+-o+$+>X                       +pp  X+oX",
+" :>o;:$+#++O++X+X++>+++X                       ppp  ->OX",
+" %1Oo%oO++++$#+Xu+;+$++#           O%...            X+:X",
+" >,o$OOo$+#+++-++++++++X                            XOOX",
+" O1Oo%o%qO+++++-++++++-X           O;.O..O...       X+1X",
+" ;$e%;$,2$$++-+++++a+++X                            XOOX",
+" $1$*%OO:%o1q++-+-+X+-+-           $%..O.O;@8       X+oX",
+" %O%O21O%%Oi2$$+-+-+-+-X                88 8        X$OX",
+" ;,>o,$O1%>O:O%;&++X+X+X                 88 8       X+>-",
+"6%$%%>%O>,O0OO%$>O>$$OOX                88 8        X2,X",
+" %o%$%OO%$:%%,>%1,1%;>OO++=X=XX=X=XX=XXXXXXXXX=XX=XXX+>-",
+" i;$e%$%>O%;12OO%$;%1>92$O+O+O+O+O+O+O+O+O+O+O+O+O+O+OOX",
+" $>9$>OOe$>OO01O%%$>,2>1;$>OO$>,>O$>,>O$>,2OO$>,>O$>9>1X",
+".XXX--XX#--X-XXXXXXXX--XXX-X-X-X--X-X--X-X-X-X-X--X-XXXX"};
diff --git a/xlockmore-4.14/etc/chkmbox/Makefile b/xlockmore-4.14/etc/chkmbox/Makefile
new file mode 100644 (file)
index 0000000..e310776
--- /dev/null
@@ -0,0 +1,21 @@
+#
+# Makefile for chkmbox
+#
+
+CC=    gcc
+LN=    gcc
+
+CFLAGS=        -c -O2 -Wall
+
+XMBOX_OBJS=    chkmbox.o imapsocket.o
+
+all:   chkmbox
+
+.c.o:
+       $(CC) $(CFLAGS) $<
+
+chkmbox.o:     imapsocket.h
+
+chkmbox:       $(XMBOX_OBJS)
+       $(LN) -o $@ $(XMBOX_OBJS)
+
diff --git a/xlockmore-4.14/etc/chkmbox/NoMail.xpm b/xlockmore-4.14/etc/chkmbox/NoMail.xpm
new file mode 100644 (file)
index 0000000..21c69d5
--- /dev/null
@@ -0,0 +1,88 @@
+/* XPM */
+static char * image_name[] = {
+"56 46 39 1",
+"      c #FFFFFBEEFFFF",
+".     c #B6DAAEBAB6DA",
+"X     c #082004100820",
+"o     c #9E799A699E79",
+"O     c #8E388A288E38",
+"+     c #38E36DB6A699",
+"@     c #BEFBB6DABEFB",
+"#     c #000000001861",
+"$     c #A69979E78E38",
+"%     c #79E786179E79",
+"&     c #A699A289A699",
+"*     c #AEBAAEBAB6DA",
+"=     c #000008200820",
+"-     c #000000001040",
+";     c #8E38861779E7",
+":     c #A6999E79A699",
+">     c #71C679E78617",
+",     c #AEBA9E795965",
+"<     c #AEBAB2CACF3C",
+"1     c #96589658AEBA",
+"2     c #514471C68E38",
+"3     c #FFFFF3CEFFFF",
+"4     c #C71BBAEAC71B",
+"5     c #CF3CC71BCF3C",
+"6     c #EFBEF3CEF7DE",
+"7     c #69A669A671C6",
+"8     c #FFFFFFFFFFFF",
+"9     c #AEBAA69971C6",
+"0     c #AEBA61856185",
+"q     c #AEBAA699AEBA",
+"w     c #71C675D671C6",
+"e     c #5144A2894924",
+"r     c #861779E78617",
+"t     c #BEFBC30BCF3C",
+"y     c #69A68617BEFB",
+"u     c #A699A699A699",
+"i     c #965896589658",
+"p     c #F7DEB2CAAEBA",
+"a     c #51445555FFFF",
+"                                                       .",
+" ......................................................X",
+" ...............oOO+O+O+O+OOoo.........................X",
+" ........@....OO++++++++++X+X++o...@....@....@....@....X",
+" o@..o@..o.@O++XoOo+#+#+@$%+OXXX+&...o@..o@..o..@o...o@X",
+" ...@.*....O=+X+X+X.O-+=;%$OX+XXXXo*@....*...*@....*@..X",
+" o.o.o@o@o+X+X+:oX+$+++$++.>,#+X+XXo.o@o@o@o@o.o@o@o.o.X",
+" @*@..o.*+X+#+o.O@<*@+$*$*,1>$X+X+XXo.o*...*..o.*.*...oX",
+" o.o.o@o+X+X++@2++O@.*<%@%1%-+>X+-+XXo@o@o@o@1.o@o@o@o@X",
+" @..:*.+X+-+-++++$%..<..O<>,OO#+X+X+XX1.o*..o...o...o*.X",
+" o.o.oOX+X+++++$%. .3..O.O.24O+XXXOX+X+o<o.1.o.o.1@1.o.X",
+" .o.@.X+-+-+-++@  .......*1$O+X+OX++XXX+o.o...o.o.o...oX",
+" o.o.++X++++$56@ . . ..O.O.7<X+XOXX+OXXX.:.o@1.o<o.o@1.X",
+"3@1.o+#+-++O*     . ......O@O%$+X+-+X+XX+.o.o.:.o.o<o.oX",
+" o.1OX+o:O+$3. . . . ....O<;.O+X+X+X+-+XXo.1.o.o.o.o.o.X",
+"3oo.++Xo:*5+  8   . ......>9>$X+X+-+X+X+Xeo.:o:.o:o.:ooX",
+" o@%OX+O++3* .8@8. . ..O.O.%.-+-+-+-+-XXXi.o.o.o.o.:.o.X",
+" o10O.X+<++ .8.8. .....@..O.O+-+X+X+X+X+XXeo:oo1oooooooX",
+" o.+OOqX+q3+ .8.8.8.8.@O.O.O.X+X+-+-+XXOX+.1.o.o.1.o.1.X",
+" oo%%*O.X@*@...*......*...%$O+X+X+-+XXOX+Xiooo:2ooo:oooX",
+" oq+;O@OO-+$%.. . .....O.O@w<O+-+X+-+-+XX+oo.oo:.@o@4ooX",
+"3oo+O1O..OX+X+=........<$eOOOOo+-+XX-+-+X-o:io:o@::ooooX",
+" o:+>:.O.X+X+-+X+O.O.O.O.$<O0+2+o+$+-XX+Xiqoo:o$q%<oi:oX",
+" :o+2,ooO+X+X+X+=+@..@O%$;O12o+;+++X+X+XX-o:$o*>::oo:@oX",
+" O1+:O>o:X+-+X+-+X$X.O.O*>O+O+>+%++++-X-:eoi:e::oe::oei-",
+"3oo+O$O%:+X+-+-+X+X+=+%$OO1>,1++++++-++X-o:e:oreO$io:iqX",
+" oo0+%+;$%+-+X+-+-+X+X++%+,+2+%++a+-a-++Xoq>>io:+>iOr>o-",
+"3ooy+;1>%O++X+-+X+X+X+#>9>+$+i++++++i++->oeioqoo:eoqoioX",
+" eqe$+$+%$>O+X+X+-+-+XO++++++@++++++++X.e<eoi<@oO.@.O0<X",
+" ::q1=0%>,O>u+X+X+X+X+O#36 3 3   888                +>iX",
+" $oOo+++O+2+OX+-+-+-++$X  .. . .  888          upu  X+:X",
+" o%ooo#++>+O>+-+X+XoO%+X  . . .                ;u,  -,OX",
+" ,O%o%;+++$+O-+-+-o+$+>X                       +pp  X+oX",
+" :>o;:$+#++O++X+X++>+++X                       ppp  ->OX",
+" %1Oo%oO++++$#+Xu+;+$++#           O%...            X+:X",
+" >,o$OOo$+#+++-++++++++X                            XOOX",
+" O1Oo%o%qO+++++-++++++-X           O;.O..O...       X+1X",
+" ;$e%;$,2$$++-+++++a+++X                            XOOX",
+" $1$*%OO:%o1q++-+-+X+-+-           $%..O.O;@8       X+oX",
+" %O%O21O%%Oi2$$+-+-+-+-X                88 8        X$OX",
+" ;,>o,$O1%>O:O%;&++X+X+X                 88 8       X+>-",
+"6%$%%>%O>,O0OO%$>O>$$OOX                88 8        X2,X",
+" %o%$%OO%$:%%,>%1,1%;>OO++=X=XX=X=XX=XXXXXXXXX=XX=XXX+>-",
+" i;$e%$%>O%;12OO%$;%1>92$O+O+O+O+O+O+O+O+O+O+O+O+O+O+OOX",
+" $>9$>OOe$>OO01O%%$>,2>1;$>OO$>,>O$>,>O$>,2OO$>,>O$>9>1X",
+".XXX--XX#--X-XXXXXXXX--XXX-X-X-X--X-X--X-X-X-X-X--X-XXXX"};
diff --git a/xlockmore-4.14/etc/chkmbox/chkmbox.c b/xlockmore-4.14/etc/chkmbox/chkmbox.c
new file mode 100644 (file)
index 0000000..ea5f519
--- /dev/null
@@ -0,0 +1,63 @@
+/****************************************************************************/
+/*
+ * xmbox.c  -- Module to check for mail using an IMAP socket
+ *
+ *  Logon to an IMAP server and check for unread messages.  Return 0 if
+ *  no RECENT or UNSEEN mail exists in the user's INBOX or > 0 if messages
+ *  exist.
+ *
+ *  Author: Michael P. Duane    mduane@seanet.com
+ *  Date:   August 12, 1997
+ *
+ * Copyright (c) 1997-98 by Michael P. Duane
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ *
+ ****************************************************************************/
+
+#include <stdio.h>
+#include <fcntl.h>
+#include <string.h>
+#include <stdarg.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+#include "imapsocket.h"
+
+char   dftname         []      = "chkmbox.cfg";
+
+/*************************************************************************/
+int main( int argc, char **argv )
+{
+char   *cfgname;
+int            msgnbr          = -1;
+
+       my_name = GetProgramName( *argv );
+
+       if ( argc >= 2 )
+               cfgname = *(argv+1);
+       else
+               cfgname = dftname;
+
+       RedirectErrLog();
+       GetImapCfgInfo( cfgname );
+       if ( !InitSocketAddr() )
+               if ( !ServerLogin() ) /* Any errors here it will behave as "no mail" */
+                       msgnbr = CheckInbox();
+       ServerLogout();
+
+       return( msgnbr );
+
+} /* main */
diff --git a/xlockmore-4.14/etc/chkmbox/chkmbox.cfg b/xlockmore-4.14/etc/chkmbox/chkmbox.cfg
new file mode 100644 (file)
index 0000000..439f209
--- /dev/null
@@ -0,0 +1,7 @@
+# Configuration file for chkmbox
+
+Hostname       = <mail host name>
+port           = 143
+User           = <mail user name>
+password       = <mail user password>
+
diff --git a/xlockmore-4.14/etc/chkmbox/imapsocket.c b/xlockmore-4.14/etc/chkmbox/imapsocket.c
new file mode 100644 (file)
index 0000000..5e5e800
--- /dev/null
@@ -0,0 +1,553 @@
+/****************************************************************************/
+/*
+ * imapsocket.c  -- Module to check for mail using an IMAP socket
+ *
+ *     Functions to logon to an IMAP server and check the user's INBOX for
+ *     RECENT or UNSEEN mail.  Errors may be logged to ~/.xsession-errors if
+ *     stderr is redirected by a call to RedirectErrLog(), otherwise they are
+ *     written to stderr.
+ *
+ *     It is intended to be used as a set of library functions by a program
+ *     that displays and icon, lights a keyboard LED or otherwise notifies
+ *     a user that mail is waiting to be read.
+ *
+ *     Author: Michael P. Duane        mduane@seanet.com
+ *     Date:   August 12, 1997
+ *
+ * Copyright (c) 1997-98 by Michael P. Duane
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ *
+ ****************************************************************************/
+
+#include <stdio.h>
+#include <errno.h>
+#include <ctype.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+#include <netdb.h>
+#include <fcntl.h>
+#include <string.h>
+#include <stdarg.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+#ifndef        FALSE
+#define        FALSE   0
+#define        TRUE    ~FALSE
+#endif
+
+#define        MAX_BUFFER_SIZE                 8192
+#define        MAX_BUFFER_LINES                  32
+
+#define        SOCKET_ERROR                    (-1)
+
+char   *my_name        = "";
+
+int                                    fdImap          = (-1);
+struct sockaddr_in     addrImap;
+
+int            seq_num                         = 0;
+char   tag                     [ 8];
+
+char   hostname        [64]    = "";
+short  port                            = 0;
+
+char   user            [64]    = "";
+char   passwd          [64]    = "";
+
+char   recv_buf        [MAX_BUFFER_SIZE];
+char   *line           [MAX_BUFFER_LINES];
+
+/****************************************************************************/
+/*
+ * GetProgramName()
+ *
+ * Extract just the basename from argv[0].  'basename()' doesn't exist
+ * on all systems.
+ */
+char *GetProgramName( char *fullname )
+{
+char    *name;
+
+    return( name = ( (name = strrchr( fullname, '/' )) ? ++name : fullname ) );
+
+} /* GetProgramName */
+
+/****************************************************************************/
+/*
+ * RedirectErrLog()
+ *
+ * Redirect stderr to $HOME/.xsesson-errors.  Create it if it doesn't
+ * exist, append to it if it does.
+ *
+ */
+int RedirectErrLog( void )
+{
+char   *home;
+char   xsesserr        [255];
+int            mode    = (O_CREAT | O_APPEND | O_WRONLY);
+int            fderr;
+
+       if ( (home = getenv( "HOME" )) != NULL ) {
+               strcat( strcpy( xsesserr, home ), "/.xsession-errors" );
+               if ( (fderr = open( xsesserr, mode, 0600 )) > 0 ) {
+                       close( STDERR_FILENO );
+                       if ( dup( fderr ) == STDERR_FILENO )
+                               close( fderr );
+                       }
+               return( 0 );
+               }
+
+       return( -1 );
+
+}/* RedirectErrLog */
+
+/****************************************************************************/
+/*
+ * LogMessage()
+ *
+ * Prepend all error messages with my program name and log the corresponding
+ * errno description string where appropriate.
+ */
+void LogMessage( char *msg, int errval )
+{
+
+       if ( errval )
+               fprintf( stderr, "%s:  %s, %s\n", my_name, msg, strerror( errval ) );
+       else
+               fprintf( stderr, "%s:  %s\n", my_name, msg );
+
+} /* LogMessage */
+
+/****************************************************************************/
+/*
+ * ParseToken()
+ *
+ * Validate the "token = value" sequence to include a known token and
+ * a valid assignment operator.  Store the value in a global on success.
+ */
+static void ParseToken( char *token, char *assign, char *value )
+{
+char   errmsg  [255];
+int            i;
+
+       for ( i=0; i< strlen( token ); i++ )
+               *(token+i) = toupper( *(token+i) );
+
+       if ( strcmp( assign, "=" ) ) {
+               sprintf( errmsg, "\"%s\" missing assignment", token );
+               LogMessage( errmsg, 0 );
+               return;
+               }
+
+       if ( !strcmp( token, "HOSTNAME" ) )
+               strcpy( hostname, value );
+       else if ( !strcmp( token, "PORT" ) )
+               port = (short)strtol( value, (char **)NULL, 0 );
+       else if ( !strcmp( token, "USER" ) )
+               strcpy( user, value );
+       else if ( !strcmp( token, "PASSWORD" ) )
+               strcpy( passwd, value );
+       else {
+               sprintf( errmsg, "Unexpected configuration token: \"%s\"", token );
+               LogMessage( errmsg, 0 );
+               }
+
+} /* ParseToken */
+
+/****************************************************************************/
+static char *GetNextToken( char *str )
+{
+
+       return( strtok( str, " \t\n\r" ) );
+
+} /* GetNextToken */
+
+/****************************************************************************/
+/*
+ * GetImapCfgInfo()
+ *
+ * Reads the program configuration file looking for assignments of the
+ * form "token = value".  '#' begins a comment that contiues to EOL.
+ */
+int GetImapCfgInfo( char *cfgfile )
+{
+FILE   *cfg;
+char   txtbuf          [512];
+char   *txt;
+char   *tok;
+char   *assign;
+char   *val;
+
+       if ( (cfg = fopen( cfgfile, "r" )) != NULL ) {
+               do      {
+                       if ( (txt = fgets( txtbuf, sizeof( txtbuf ), cfg )) != NULL) {
+                               if ( (tok = GetNextToken( txt )) ) {
+                                       assign = val = NULL;
+                                       if ( strlen( tok ) ) {
+                                               if ( strchr( tok, '#' ) )
+                                                       continue;
+                                               assign  = GetNextToken( NULL );
+                                               val             = GetNextToken( NULL );
+                                               GetNextToken( NULL );   /* strip to eol */
+                                               }
+                                       if ( assign && val )
+                                               ParseToken( tok, assign, val );
+                                       }
+                               }
+                       } while( !feof( cfg ) );
+               fclose( cfg );
+               }
+       else {
+               LogMessage( cfgfile, errno );
+               return( -1 );
+               }
+
+       return( 0 );
+
+} /* GetImapCfgInfo */
+
+/****************************************************************************/
+/*
+ * InitSocketAddr()
+ *
+ * Setup and validate the host/port address for the IMAP socket
+ */
+
+int InitSocketAddr( void )
+{
+struct hostent *host_info;
+char                   addr_str        [ 32];
+
+       if ( (host_info = gethostbyname( hostname )) == NULL ) {
+               LogMessage( "Host name error", errno );
+               return( -1 );
+               }
+
+       sprintf( addr_str,"%u.%u.%u.%u",
+                        (unsigned char)host_info->h_addr_list[0][0],
+                        (unsigned char)host_info->h_addr_list[0][1],
+                        (unsigned char)host_info->h_addr_list[0][2],
+                        (unsigned char)host_info->h_addr_list[0][3]
+                        );
+
+       addrImap.sin_family                     = PF_INET;
+       addrImap.sin_addr.s_addr        = inet_addr( addr_str );
+       addrImap.sin_port                       = htons( port );
+
+       if ( addrImap.sin_addr.s_addr == INADDR_NONE ) {
+               LogMessage( "Socket Address Error", errno );
+               return( -1 );
+               }
+
+       return( 0 );
+
+} /* InitSocketAddr */
+
+/****************************************************************************/
+/*
+ * ConnectSocket()
+ *
+ * Open and connect to the IMAP socket
+ */
+
+static int ConnectSocket( struct sockaddr_in *addrImap )
+{
+
+       if ( addrImap->sin_addr.s_addr == INADDR_NONE ) {
+               LogMessage( "Socket Address Error", errno );
+               return( -1 );
+               }
+
+       if ( (fdImap = socket( AF_INET, SOCK_STREAM, 0 )) == SOCKET_ERROR ) {                 
+               LogMessage( "Error opening socket", errno );
+               return( -1 );
+               }
+
+       if ( connect( fdImap, (struct sockaddr *)addrImap,
+                 sizeof( struct sockaddr )) == SOCKET_ERROR ) {
+               close( fdImap );
+               fdImap = (-1);
+               LogMessage( "Socket Connection error", errno );
+               return( -1 );
+               }
+
+       return( 0 );
+
+} /* ConnectSocket */
+
+/****************************************************************************/
+/*
+ * OpenImapSocket()
+ *
+ * Connect to the IMAP socket and make sure the IMAP service responds.
+ */
+
+static int OpenImapSocket( struct sockaddr_in *addrImap )
+{
+int    i;
+
+       if ( ConnectSocket( addrImap ) )
+               return( -1 );
+
+       seq_num = 0;
+       memset( recv_buf, 0, sizeof( recv_buf ) );
+
+       for( i=0; i<MAX_BUFFER_LINES; i++ )
+               line[i] = NULL;
+
+       if ( recv(  fdImap, (char *)recv_buf,
+                               sizeof( recv_buf ), 0 ) == SOCKET_ERROR ) {
+               close( fdImap );
+               fdImap = (-1);
+               LogMessage( "Socket revc error", errno );
+               return( -1 );
+               }
+
+       if ( strncmp( "* OK", recv_buf, 4 ) == 0 ) {
+               return( 0 );
+               }
+       else {  
+               close( fdImap );
+               LogMessage( "IMAP service timeout", 0 );
+               return( -1 );
+               }
+
+} /* OpenImapSocket */
+
+/****************************************************************************/
+/*
+ * ImapCmd()
+ *
+ * Send an IMAP command to the socket. The "tag" is used by the IMAP
+ * protocol to match responses to commands.
+ */
+
+static int ImapCmd( char *fmt, ... )
+{
+char   cmd_buf [128];
+va_list        argp;
+
+       sprintf( tag, "A%3.3d", ++seq_num );
+    sprintf( cmd_buf, "%s ", tag );
+
+    va_start( argp, fmt );
+       vsprintf( &cmd_buf[ strlen( cmd_buf ) ], fmt, argp );
+       va_end( argp );
+
+       if ( send( fdImap, cmd_buf, strlen( cmd_buf ), 0 ) == SOCKET_ERROR ) {
+               close( fdImap );
+               fdImap = (-1);
+               LogMessage( "IMAP send error", errno );
+               return( -1 );
+               }
+
+       return( 0 );
+        
+} /* ImapCmd */
+
+/****************************************************************************/
+/*
+ * GetImapMsg()
+ *
+ * Get an IMAP response and check for the tag and for the "OK".
+ */
+
+static int GetImapMsg( char *buf, int size )
+{
+char   tmp     [16];
+
+       memset( buf, 0, size );
+
+       if ( recv( fdImap, (char *)buf, size, 0 ) == SOCKET_ERROR ) {
+               close( fdImap );
+               fdImap = (-1);
+               LogMessage( "IMAP read error", errno );
+               return( -1 );
+               }
+
+       sprintf( tmp, "%s OK", tag );
+
+       if ( strstr( buf, tmp ) != NULL )
+               return( 0 );
+       else {
+               LogMessage( "IMAP command error", 0 );
+               return( -1 );
+       }
+
+} /* GetImapMsg */
+
+/****************************************************************************/
+/*
+ * ServerLogin( void )
+ *
+ * Start the IMAP session to check for new mail
+ * RETURN: 0 for success or -1 for failure
+ */
+
+int ServerLogin( void )
+{
+int status = -1;
+
+       if ( !OpenImapSocket( &addrImap ) ) {
+               if ( !ImapCmd( "LOGIN %s %s\n", user, passwd ) ) {
+                       if ( GetImapMsg( recv_buf, sizeof( recv_buf ) ) )
+                               LogMessage( "IMAP LOGIN error", 0 );
+                       else
+                               status = 0;
+                       }
+               }
+
+       return( status );
+
+} /* ServerLogin */
+
+/****************************************************************************/
+/*
+ * ServerLogout()
+ *
+ * Close the IMAP session
+ * RETURN: none
+ */
+
+void ServerLogout( void )
+{
+
+       if ( !ImapCmd( "LOGOUT\n" ) )
+               GetImapMsg( recv_buf, sizeof( recv_buf ) );
+
+       close( fdImap );
+
+} /* ServerLogout */
+
+/****************************************************************************/
+/*
+ * ParseBufLines()
+ *
+ * Parse the response into single lines.
+ *
+ * ARGS:       b - raw response buffer
+ *                     l - an array char * for the individual lines
+ *
+ * RETURN:     the number of lines
+ *
+ */
+
+static int ParseBufLines( char *b, char *l[] )
+{
+int    i;
+               
+       for ( i=0; i<MAX_BUFFER_LINES; i++ )
+               l[i] = NULL;
+
+       if ( (l[0] = strtok( b, "\n" )) == NULL )
+               return( 0 );
+
+       for ( i=1; i<MAX_BUFFER_LINES; i++ ) {
+               if ( (l[i] = strtok( NULL, "\n" )) == NULL )
+               return( i );
+               }
+
+       return( MAX_BUFFER_LINES );
+
+} /* ParseBufLines */
+
+/****************************************************************************/
+/*
+ * CheckRecent()
+ *
+ * This routine looks through an array of lines for the "RECENT" response
+ * and returns the number of "RECENT" message.  If there are no "RECENT"
+ * messages it then checks for any "UNSEEN" messages.
+ *
+ * ARGS:       b - raw response buffer
+ *                     l - an array char * for the individual lines
+ *
+ * RETURN:     number.  0 is no messages.  For messages found with the
+ *          RECENT command number is the count of RECENT messages.  For
+ *          messages found with the UNSEEN command 'number' is the
+ *          message number of an UNSEEN message.
+ */
+
+static int CheckRecent( char *b, char *l[] )
+{
+int    i;
+int    num_msg = -1;
+
+/*
+ *     Check for new messages that have arrived since the last time we looked
+ */
+       if ( !GetImapMsg( recv_buf, sizeof( recv_buf ) ) ) {
+               if ( ParseBufLines( b, l ) > 0 ) {
+                       for( i=0; i<MAX_BUFFER_LINES; i++ ) {
+                               if ( strstr( l[i], "RECENT" ) != NULL )
+                                       break;  
+                               }
+                       sscanf( l[i], "%*s %d %*s", &num_msg );
+                       }
+               }
+/*
+ *     If nothing new has arrived check for any messages that may still be
+ *     in the mailbox but have not been read
+ */
+       if ( num_msg <= 0 ) {
+               if ( !ImapCmd( "SEARCH UNSEEN\n" ) ) {
+                       if ( !GetImapMsg( recv_buf, sizeof( recv_buf ) ) ) {
+                               if ( ParseBufLines( b, l ) > 0 ) {
+                                       for( i=0; i<MAX_BUFFER_LINES; i++ ) {
+                                               if ( strstr( l[i], "SEARCH" ) != NULL )
+                                                       break;  
+                                               }
+                                       sscanf( l[i], "%*s %*s %d", &num_msg );
+                                       }
+                               }
+                       }
+               }
+/*
+ *     Any non-zero value means there are messages that have not been read.
+ *     This is not a count or an index to the newest message
+ */
+       return( num_msg );
+
+} /* CheckRecent */
+
+/****************************************************************************/
+/*
+ * CheckInbox()
+ *
+ * This is the IMAP session to check for new mail
+ *
+ * RETURN: 1 for no messages, 0 if messages exist. /* Inverted by DAB */
+ */
+
+int CheckInbox( void )
+{
+int status = -1;
+
+       if ( fdImap < 0 ) {
+               if ( ServerLogin() )
+                       return( !status );  /* Inverted by DAB */
+               }
+
+       if ( !ImapCmd( "EXAMINE INBOX\n" ) )
+               status = CheckRecent( recv_buf, line );
+
+       return( !status ); /* Inverted by DAB */
+
+} /* CheckInbox */
+
+/****************************************************************************/
+/* end of imapsocket.c */
diff --git a/xlockmore-4.14/etc/chkmbox/imapsocket.h b/xlockmore-4.14/etc/chkmbox/imapsocket.h
new file mode 100644 (file)
index 0000000..506eb76
--- /dev/null
@@ -0,0 +1,48 @@
+/****************************************************************************/
+/*
+ * imapsocket.h  -- Module to check for mail using an IMAP socket
+ *
+ *  Functions to logon to an IMAP server and check the user's INBOX for
+ *  RECENT or UNSEEN mail.  Errors may be logged to ~/.xsession-errors if
+ *  stderr is redirected by a call to RedirectErrLog(), otherwise they are
+ *  written to stderr.
+ *
+ *  It is intended to be used as a set of library functions by a program
+ *  that displays and icon, lights a keyboard LED or otherwise notifies
+ *  a user that mail is waiting to be read.
+ *
+ *  Author: Michael P. Duane    mduane@seanet.com
+ *  Date:   August 12, 1997
+ *
+ * Copyright (c) 1997-98 by Michael P. Duane
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ *
+ ****************************************************************************/
+
+#ifndef IMAPSOCKET_H
+#define IMAPSOCKET_H
+
+extern char *my_name;
+
+int            RedirectErrLog( void );
+char   *GetProgramName( char *fullname );
+int            GetImapCfgInfo( char *cfgfile );
+int            InitSocketAddr( void );
+int            ServerLogin( void );
+void   ServerLogout( void );
+int            CheckInbox( void );
+
+#endif /* IMAPSOCKET_H */
diff --git a/xlockmore-4.14/etc/descrip.mms b/xlockmore-4.14/etc/descrip.mms
new file mode 100644 (file)
index 0000000..0b1c41a
--- /dev/null
@@ -0,0 +1,334 @@
+# This is no longer maintained since I can not test it.
+############################################################
+# Make file to makexlock.exe on a VMS system.
+#
+# Created By J.Jansen         12 February 1996
+#
+# Usage : type MMS in the directory containing the source
+#
+# It automatically detects the existance of the XPM-library and the XVMSUTILS
+# library to use the new (better) features of the program. It is assumed that
+# both libraries if exist are in the directory with logical symbol X11.
+#
+#
+############################################################
+
+# default target
+
+C = .c
+#C++
+#C = .cc
+
+#VMS
+O = .obj
+S = ,
+E = .exe
+A = ;*
+
+all : macro xmlock$(E)
+       @ $(ECHO) ""
+
+macro :
+       @ xvms = f$search("X11:XVMSUTILS.OLB").nes.""
+       @ xpm = f$search("X11:LIBXPM.OLB").nes.""
+       @ axp = f$getsyi("HW_MODEL").ge.1024
+       @ macro = ""
+       @ if axp.or.xvms.or.xpm then macro = "/MACRO=("
+       @ if axp then macro = macro + "__ALPHA__=1,"
+       @ if xpm then macro = macro + "__XPM__=1,"
+       @ if xvms then macro = macro + "__XVMSUTILS__=1,"
+       @ if macro.nes."" then macro = f$extract(0,f$length(macro)-1,macro)+ ")"
+       $(MMS)$(MMSQUALIFIERS)'macro' xlock$(E)
+
+BITMAPDIR = [.bitmaps]
+PIXMAPDIR = [.pixmaps]
+CONFIGDIR = [.config]
+GLDIR = [.glx]
+HACKERDIR = [.hackers]
+
+#CC = gcc -g -Wall -ansi -pedantic
+#CC = gcc -g -Wall
+#CC = g++ -g -Wall
+CC = cc
+#CC = cxx
+
+BITMAPTYPE = x11
+PIXMAPTYPE = x11
+
+# Here is your chance to override the default icon:
+TINYBITMAP = $(BITMAPTYPE)
+TINYBITMAP = t-x11
+SMALLBITMAP = s-$(BITMAPTYPE)
+MEDIUMBITMAP = m-$(BITMAPTYPE)
+LARGEBITMAP = l-$(BITMAPTYPE)
+MEDIUMPIXMAP = m-$(PIXMAPTYPE)
+LARGEPIXMAP = l-$(PIXMAPTYPE)
+
+#EYESBITMAP = $(MEDIUMBITMAP)
+EYESBITMAP = m-grelb
+IMAGEBITMAP = $(MEDIUMBITMAP)
+#IMAGEBITMAP = m-xlock
+#LIFEBITMAP = $(SMALLBITMAP)
+LIFEBITMAP = s-grelb
+LIFE1DBITMAP = $(TINYBITMAP)
+MAZEBITMAP = $(LARGEBITMAP)
+#MAZEBITMAP = m-xlock
+#PACMANBITMAP = $(MEDIUMBITMAP)
+PACMANBITMAP = m-ghost
+#PUZZLEBITMAP = $(LARGEBITMAP)
+PUZZLEBITMAP = l-xlock
+IMAGEPIXMAP = $(MEDIUMPIXMAP)
+#IMAGEPIXMAP = m-xlock
+#PUZZLEPIXMAP = $(LARGEPIXMAP)
+PUZZLEPIXMAP = l-xlock
+
+RM = delete/noconfirm
+RM_S = set file/remove
+ECHO = write sys$output
+BLN_S = set file/enter=[]
+
+.IFDEF __ALPHA__
+#SYSTEMDEF = /standard=vaxc
+SOUNDOBJS = $(S)amd$(O)
+SOUNDSRCS = amd$(C)
+SOUNDDEF = ,VMS_PLAY
+.ENDIF
+.IFDEF __XPM__
+XPMDEF = ,HAVE_XPM
+.ENDIF
+.IFDEF __XVMSUTILS__
+XVMSUTILSDEF = ,HAVE_XVMSUTILS
+.ENDIF
+
+# Add hackers modes as you like.  It may make your xlock unstable.
+# Please do not uncomment for precompiled distributions.
+#HACKERDEF = ,USE_HACKERS
+#XLOCKHACKEROBJS =
+
+
+CFLAGS = /define = (VMS,USE_VROOT,USE_BOMB$(SOUNDDEF)$(XPMDEF)$(XVMSUTILSDEF)$(GLDEF)$(HACKERDEF))$(SYSTEMDEF)
+LDFLAGS =
+
+VER = xlockmore
+DISTVER = xlockmore-4.00
+
+
+####################################################################
+# List of object files
+
+
+XLOCKCOREOBJS =
+XLOCKMODEOBJS =
+XLOCKGLOBJS =
+XLOCKCOREMODEOBJS = blank$(O)$(S)bomb$(O)$(S)random$(O)
+XLOCKOBJS = $(XLOCKCOREOBJS)$(S)$(XLOCKMODEOBJS)$(S)\
+$(XLOCKGLOBJS)$(XLOCKHACKEROBJS)$(S)$(XLOCKCOREMODEOBJS)
+XMLOCKOBJS = option$(O)$(S)xmlock$(O)
+
+####################################################################
+# List of source files
+# Used for lint, and some dependencies.
+
+BITMAPS = eyes.xbm ghost.xbm image.xbm life.xbm life1d.xbm \
+maze.xbm puzzle.xbm
+PIXMAPS = image.xpm puzzle.xpm
+XLOCKHDRS = xlock.h mode.h vroot.h ras.h version.h config.h
+XLOCKCORESRCS =
+XLOCKMODESRCS =
+XLOCKGLSRCS =
+XLOCKCOREMODESRCS = blank$(C) bomb$(C) random$(C)
+XLOCKHACKERSRCS =
+XLOCKSRCS = $(XLOCKCORESRCS) $(XLOCKMODESRCS) $(XLOCKCOREMODESRCS) \
+$(XLOCKGLSRCS) $(XLOCKHACKERSRCS)
+XMLOCKSRCS = option$(C) xmlock$(C)
+
+
+#########################################################################
+
+xlock$(E) : $(XLOCKOBJS)$(S)xlock.opt
+       link/map $(XLOCKOBJS)$(S)xlock.opt/opt
+       @ $(ECHO) "$@ BUILD COMPLETE"
+       @ $(ECHO) ""
+
+xmlock$(E) : $(XMLOCKOBJS)$(S)xmlock.opt
+       link/map $(XMLOCKOBJS)$(S)xmlock.opt/opt
+       @ $(ECHO) "$@ BUILD COMPLETE"
+       @ $(ECHO) ""
+
+xlock.opt :
+       @ close/nolog optf
+       @ open/write optf xlock.opt
+#      @ if .not. axp then write optf "sys$library:vaxcrtl/lib"
+       @ write optf "sys$library:vaxcrtl/lib"
+       @ if axp then write optf "sys$library:ucx$ipc_shr/share"
+       @ if axp then write optf "sys$share:decw$xextlibshr/share"
+       @ if axp then write optf "sys$share:decw$xtlibshrr5/share"
+       @ if .not. axp then write optf "sys$library:ucx$ipc/lib"
+#      @ write optf "sys$share:decw$dxmlibshr/share"
+       @ write optf "sys$share:decw$xmlibshr12/share"
+       @ write optf "sys$share:decw$xlibshr/share"
+       @ close optf
+
+xmlock.opt :
+       @ close/nolog optf
+       @ open/write optf xmlock.opt
+#      @ if .not. axp then write optf "sys$library:vaxcrtl/lib"
+       @ write optf "sys$library:vaxcrtl/lib"
+       @ if axp then write optf "sys$library:ucx$ipc_shr/share"
+       @ if axp then write optf "sys$share:decw$xextlibshr/share"
+       @ if axp then write optf "sys$share:decw$xtlibshrr5/share"
+       @ if .not. axp then write optf "sys$library:ucx$ipc/lib"
+#      @ write optf "sys$share:decw$dxmlibshr/share"
+       @ write optf "sys$share:decw$xmlibshr12/share"
+       @ write optf "sys$share:decw$xlibshr/share"
+       @ close optf
+
+eyes$(O) : eyes$(C) eyes.xbm
+flag$(O) : flag$(C) flag.xbm
+life$(O) : life$(C) life.xbm
+life1d$(O) : life1d$(C) life1d.xbm
+maze$(O) : maze$(C) maze.xbm
+pacman$(O) : pacman$(C) ghost.xbm
+# Do not need xpm files if not using them but not worth figuring out
+image$(O) : image$(C) image.xbm image.xpm
+puzzle$(O) : puzzle$(C) puzzle.xbm puzzle.xpm
+
+eyes.xbm : $(BITMAPDIR)$(EYESBITMAP).xbm
+       $(BLN_S)eyes.xbm $(BITMAPDIR)$(EYESBITMAP).xbm
+
+flag.xbm : $(BITMAPDIR)$(FLAGBITMAP).xbm
+       $(BLN_S)flag.xbm $(FLAGDIR)$(FLAGBITMAP).xbm
+image.xbm : $(BITMAPDIR)$(IMAGEBITMAP).xbm
+       $(BLN_S)image.xbm $(BITMAPDIR)$(IMAGEBITMAP).xbm
+
+ghost.xbm : $(BITMAPDIR)$(PACMANBITMAP).xbm
+       $(BLN_S)ghost.xbm $(BITMAPDIR)$(PACMANBITMAP).xbm
+
+life.xbm : $(BITMAPDIR)$(LIFEBITMAP).xbm
+       $(BLN_S)life.xbm $(BITMAPDIR)$(LIFEBITMAP).xbm
+
+life1d.xbm : $(BITMAPDIR)$(LIFE1DBITMAP).xbm
+       $(BLN_S)life1d.xbm $(BITMAPDIR)$(LIFE1DBITMAP).xbm
+
+maze.xbm : $(BITMAPDIR)$(MAZEBITMAP).xbm
+       $(BLN_S)maze.xbm $(BITMAPDIR)$(MAZEBITMAP).xbm
+
+puzzle.xbm : $(BITMAPDIR)$(IMAGEBITMAP).xbm
+       $(BLN_S)puzzle.xbm $(BITMAPDIR)$(IMAGEBITMAP).xbm
+
+image.xpm : $(PIXMAPDIR)$(IMAGEPIXMAP).xpm
+       $(BLN_S)image.xpm $(PIXMAPDIR)$(IMAGEPIXMAP).xpm
+
+puzzle.xpm : $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm
+       $(BLN_S)puzzle.xpm $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm
+
+amd$(C) : $(CONFIGDIR)amd$(C)
+       $(BLN_S)amd$(C) $(CONFIGDIR)amd$(C)
+
+amd.h : $(CONFIGDIR)amd.h
+       $(BLN_S)amd.h $(CONFIGDIR)amd.h
+
+amd$(O) : amd$(C) amd.h
+
+atlantis$(C) : $(GLDIR)atlantis$(C)
+       $(BLN_S) atlantis$(C) $(GLDIR)atlantis$(C)
+
+dolphin$(C) : $(GLDIR)dolphin$(C)
+       $(BLN_S) dolphin$(C) $(GLDIR)dolphin$(C)
+
+shark$(C) : $(GLDIR)shark$(C)
+       $(BLN_S) shark$(C) $(GLDIR)shark$(C)
+
+swim$(C) : $(GLDIR)swim$(C)
+       $(BLN_S) swim$(C) $(GLDIR)swim$(C)
+
+whale$(C) : $(GLDIR)whale$(C)
+       $(BLN_S) whale$(C) $(GLDIR)whale$(C)
+
+cage$(C) : $(GLDIR)cage$(C)
+       $(BLN_S) cage$(C) $(GLDIR)cage$(C)
+
+gears$(C) : $(GLDIR)gears$(C)
+       $(BLN_S) gears$(C) $(GLDIR)gears$(C)
+
+moebius$(C) : $(GLDIR)moebius$(C)
+       $(BLN_S) moebius$(C) $(GLDIR)moebius$(C)
+
+morph3d$(C) : $(GLDIR)morph3d$(C)
+       $(BLN_S) morph3d$(C) $(GLDIR)morph3d$(C)
+
+superquadrics$(C) : $(GLDIR)superquadrics$(C)
+       $(BLN_S) superquadrics$(C) $(GLDIR)superquadrics$(C)
+
+buildlwo$(C) : $(GLDIR)buildlwo$(C)
+       $(BLN_S) buildlwo$(C) $(GLDIR)buildlwo$(C)
+
+pipes$(C) : $(GLDIR)pipes$(C)
+       $(BLN_S) pipes$(C) $(GLDIR)pipes$(C)
+
+pipeobjs$(C) : $(GLDIR)pipeobjs$(C)
+       $(BLN_S) pipeobjs$(C) $(GLDIR)pipeobjs$(C)
+
+sproingies$(C) : $(GLDIR)sproingies$(C)
+       $(BLN_S)sproingies$(C) $(GLDIR)sproingies$(C)
+
+sproingiewrap$(C) : $(GLDIR)sproingiewrap$(C)
+       $(BLN_S)sproingiewrap$(C) $(GLDIR)sproingiewrap$(C)
+
+s1_b$(C) : $(GLDIR)s1_b$(C)
+       $(BLN_S)s1_b$(C) $(GLDIR)s1_b$(C)
+
+s1_1$(C) : $(GLDIR)s1_1$(C)
+       $(BLN_S)s1_1$(C) $(GLDIR)s1_1$(C)
+
+s1_2$(C) : $(GLDIR)s1_2$(C)
+       $(BLN_S)s1_2$(C) $(GLDIR)s1_2$(C)
+
+s1_3$(C) : $(GLDIR)s1_3$(C)
+       $(BLN_S)s1_3$(C) $(GLDIR)s1_3$(C)
+
+s1_4$(C) : $(GLDIR)s1_4$(C)
+       $(BLN_S)s1_4$(C) $(GLDIR)s1_4$(C)
+
+s1_5$(C) : $(GLDIR)s1_5$(C)
+       $(BLN_S)s1_5$(C) $(GLDIR)s1_6$(C)
+
+s1_6$(C) : $(GLDIR)s1_6$(C)
+       $(BLN_S)s1_6$(C) $(GLDIR)s1_6$(C)
+
+################################################################
+
+install :
+
+uninstall :
+
+################################################################
+# Miscellaneous targets
+
+clean :
+       @ close/nolog optf
+       @ purge
+       @ $(RM) *.lis$(A)
+       @ $(RM) *.obj$(A)
+       @ $(RM) *.opt$(A)
+       @ $(RM) *.map$(A)
+       @ $(RM_S) eyes.xbm$(A)
+       @ $(RM_S) flag.xbm$(A)
+       @ $(RM_S) image.xbm$(A)
+       @ $(RM_S) ghost.xbm$(A)
+       @ $(RM_S) life.xbm$(A)
+       @ $(RM_S) life1d.xbm$(A)
+       @ $(RM_S) maze.xbm$(A)
+       @ $(RM_S) puzzle.xbm$(A)
+       @ $(RM_S) image.xpm$(A)
+       @ $(RM_S) puzzle.xpm$(A)
+       @ $(RM_S) amd.h$(A)
+       @ $(RM_S) amd.c$(A)
+
+distclean : clean
+       @ $(RM) xlock$(E)$(A)
+       @ $(RM) xmlock$(E)$(A)
+
+read :
+       more README
diff --git a/xlockmore-4.14/etc/dtprofile b/xlockmore-4.14/etc/dtprofile
new file mode 100644 (file)
index 0000000..aa67194
--- /dev/null
@@ -0,0 +1,260 @@
+#############################################################################
+###
+###   .dtprofile
+###
+###   user personal environment variables
+###
+###   Common Desktop Environment (CDE)
+###
+###   (c) Copyright 1993, 1994 Hewlett-Packard Company
+###   (c) Copyright 1993, 1994 International Business Machines Corp.
+###   (c) Copyright 1993, 1994, 1995 Sun Microsystems, Inc.
+###   (c) Copyright 1993, 1994 Novell, Inc.
+###
+### 
+###   $Revision: 1.7 $
+###
+#############################################################################
+
+
+#############################################################################
+### 
+###   Your $HOME/.dtprofile is read each time you login to the Common Desktop
+###   Environment (CDE) and is the place to set or override desktop 
+###   environment variables for your session. Environment variables set in
+###   $HOME/.dtprofile are made available to all applications on the desktop.
+###   The desktop will accept either sh or ksh syntax for the commands in 
+###   $HOME/.dtprofile.
+### 
+#############################################################################
+
+
+#############################################################################
+###   
+###   Random stdout and stderr output from apps started by Session Mgr or
+###   by actions via front panel or workspace menu can be directed into 
+###   the user's $HOME/.dt/sessionlogs directory.  By default this output
+###   is not recorded.  Instead it is sent off to /dev/null (Unix's "nothing"
+###   device).
+###   
+###   If this random application output is wanted (usually only wanted for
+###   debugging purposes), commenting out following "dtstart_sessionlogfile"
+###   lines will send output to your $HOME/.dt/sessionlogs directory.
+###   
+###   Alternatively, can change "/dev/null" to "/dev/console" to see this
+###   debugging output on your console device.  Can start a console via the
+###   Workspace programs menu or via Application Mgr's Desktop Tools 
+###   "Terminal Console" icon. 
+###   
+#############################################################################
+
+export dtstart_sessionlogfile="/dev/null"
+
+
+#############################################################################
+###
+###   By default, the desktop does not read your standard $HOME/.profile
+###   or $HOME/.login files. This can be changed by uncommenting the
+###   DTSOURCEPROFILE variable assignment at the end of this file. The
+###   desktop reads .profile if your $SHELL is "sh" or "ksh", or .login
+###   if your $SHELL is "csh".
+###
+###   The desktop reads the .dtprofile and .profile/.login without an 
+###   associated terminal emulator such as xterm or dtterm. This means
+###   there is no available command line for interaction with the user.
+###   This being the case, these scripts must avoid using commands that
+###   depend on having an associated terminal emulator or that interact
+###   with the user. Any messages printed in these scripts will not be
+###   seen when you log in and any prompts such as by the 'read' command
+###   will return an empty string to the script. Commands that set a
+###   terminal state, such as "tset" or "stty" should be avoided.
+###
+###   With minor editing, it is possible to adapt your .profile or .login
+###   for use both with and without the desktop.  Group the statements not
+###   appropriate for your desktop session into one section and enclose them
+###   with an "if" statement that checks for the setting of the "DT"
+###   environment variable. When the desktop reads your .profile or .login
+###   file, it will set "DT" to a non-empty value for which your .profile or
+###   .login can test. 
+###   
+###   example for sh/ksh
+###   
+###     if [ ! "$DT" ]; then
+###       #
+###       # commands and environment variables not appropriate for desktop
+###       #
+###       stty ...
+###       tset ...
+###       DISPLAY=mydisplay:0
+###       ...
+###     fi         
+###
+###     #
+###     # environment variables common to both desktop and non-desktop
+###     #
+###     PATH=$HOME/bin:$PATH
+###     MYVAR=value
+###     export MYVAR
+###     ...
+###      
+###   example for csh
+###
+###     if ( ! ${?DT} ) then
+###       #
+###       # commands and environment variables not appropriate for desktop
+###       #
+###       stty ...
+###       tset ...
+###       setenv DISPLAY mydisplay:0
+###       ...
+###     endif
+###
+###     #
+###     # environment variables common to both desktop and non-desktop
+###     #
+###     setenv PATH $HOME/bin:$PATH
+###     setenv MYVAR value
+###     ...
+###  
+###   Errors in .dtprofile or .profile (.login) may prevent a successful
+###   login. If after you login, your session startup terminates and you
+###   are presented with the login screen, this might be the cause. If this
+###   happens, select the Options->Sessions->Failsafe Session item on the
+###   login screen, login and correct the error. The $HOME/.dt/startlog and
+###   $HOME/.dt/errorlog files may be helpful in identifying errors.
+###
+##############################################################################
+
+#
+#  If $HOME/.profile (.login) has been edited as described above, uncomment
+#  the following line.
+#
+DTSOURCEPROFILE=true
+
+#
+# Screen savers.
+#
+#DTSCREENSAVERLIST="\
+#StartDtscreenSwarm \
+#StartDtscreenQix \
+#StartDtscreenFlame \
+#StartDtscreenHop \
+#StartDtscreenImage \
+#StartDtscreenLife \
+#StartDtscreenRotor \
+#StartDtscreenPyro \
+#StartDtscreenWorm \
+#StartDtscreenBlank"
+
+#export DTSCREENSAVERLIST="\
+#$DTSCREENSAVERLIST \
+
+#DTSCREEN="/usr/dt/bin/dtscreen"
+DTSCREEN="/usr/local/bin/xlock -dtsaver"
+export DTSCREEN
+
+DTSCREENSAVERLIST="\
+StartDtscreenAnt \
+StartDtscreenAtlantis \
+StartDtscreenBall \
+StartDtscreenBat \
+StartDtscreenBlot \
+StartDtscreenBouboule \
+StartDtscreenBounce \
+StartDtscreenBraid \
+StartDtscreenBubble \
+StartDtscreenBubble3d \
+StartDtscreenBug \
+StartDtscreenCage \
+StartDtscreenCartoon \
+StartDtscreenClock \
+StartDtscreenCoral \
+StartDtscreenCrystal \
+StartDtscreenDaisy \
+StartDtscreenDclock \
+StartDtscreenDecay \
+StartDtscreenDeco \
+StartDtscreenDemon \
+StartDtscreenDilemma \
+StartDtscreenDiscrete \
+StartDtscreenDrift \
+StartDtscreenEyes \
+StartDtscreenFadeplot \
+StartDtscreenFlag \
+StartDtscreenFlame \
+StartDtscreenFlow \
+StartDtscreenForest \
+StartDtscreenGalaxy \
+StartDtscreenGears \
+StartDtscreenGeometry \
+StartDtscreenGoop \
+StartDtscreenGrav \
+StartDtscreenHelix \
+StartDtscreenHop \
+StartDtscreenHyper \
+StartDtscreenIco \
+StartDtscreenIfs \
+StartDtscreenImage \
+StartDtscreenInvert \
+StartDtscreenJulia \
+StartDtscreenKaleid \
+StartDtscreenKumppa \
+StartDtscreenLament \
+StartDtscreenLaser \
+StartDtscreenLife \
+StartDtscreenLife1d \
+StartDtscreenLife3d \
+StartDtscreenLightning \
+StartDtscreenLisa \
+StartDtscreenLissie \
+StartDtscreenLoop \
+StartDtscreenLyapunov \
+StartDtscreenMandelbrot \
+StartDtscreenMarquee \
+StartDtscreenMatrix \
+StartDtscreenMaze \
+StartDtscreenMoebius \
+StartDtscreenMorph3d \
+StartDtscreenMountain \
+StartDtscreenMunch \
+StartDtscreenNose \
+StartDtscreenQix \
+StartDtscreenPacman \
+StartDtscreenPenrose \
+StartDtscreenPetal \
+StartDtscreenPipes \
+StartDtscreenPuzzle \
+StartDtscreenPyro \
+StartDtscreenRoll \
+StartDtscreenRotor \
+StartDtscreenRubik \
+StartDtscreenShape \
+StartDtscreenSierpinski \
+StartDtscreenSlip \
+StartDtscreenSphere \
+StartDtscreenSpiral \
+StartDtscreenSpline \
+StartDtscreenSproingies \
+StartDtscreenStairs \
+StartDtscreenStar \
+StartDtscreenStarfish \
+StartDtscreenStrange \
+StartDtscreenSuperquadrics \
+StartDtscreenSwarm \
+StartDtscreenSwirl \
+StartDtscreenTetris \
+StartDtscreenThornbird \
+StartDtscreenTriangle \
+StartDtscreenTube \
+StartDtscreenTurtle \
+StartDtscreenVines \
+StartDtscreenVoters \
+StartDtscreenWator \
+StartDtscreenWire \
+StartDtscreenWorld \
+StartDtscreenWorm \
+StartDtscreenXjack \
+StartDtscreenBlank \
+StartDtscreenBomb \
+StartDtscreenRandom"
+export DTSCREENSAVERLIST
diff --git a/xlockmore-4.14/etc/dtscreen.dt b/xlockmore-4.14/etc/dtscreen.dt
new file mode 100644 (file)
index 0000000..48852c5
--- /dev/null
@@ -0,0 +1,970 @@
+###############################################################################
+#
+#     dtscreen.dt
+#
+#     Actions for defining screen savers to the Common Desktop Environment.
+#
+#    (c) Copyright 1993, 1994, 1995 Hewlett-Packard Company
+#    (c) Copyright 1993, 1994, 1995 International Business Machines Corp.
+#    (c) Copyright 1993, 1994, 1995 Sun Microsystems, Inc.
+#    (c) Copyright 1993, 1994, 1995 Novell, Inc.
+#
+#     $XConsortium: dtscreen.dt.src /main/cde1_maint/1 1995/07/15 03:07:30 drk $
+#
+###############################################################################
+set DtDbVersion=1.0
+
+###############################################################################
+#
+# WARNING:  This file may be overwritten in subsequent installations of
+#     the Common Desktop Environment (CDE).  Consequently, any system wide
+#     changes should be made to an equivalent database file in
+#     /etc/dt/types and not in this file.
+#
+###############################################################################
+
+###################################################################
+#
+# Actions
+#
+# Note: the following are dtscreen's original action changed to use xlock
+###################################################################
+ACTION StartDtscreenHop
+{
+       LABEL           StartDtscreenHop
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode hop
+       DESCRIPTION     hop: Real plane iterated fractals
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode hop
+#      DESCRIPTION     hop: Hopalong iterated fractals
+
+ACTION StartDtscreenQix
+{
+       LABEL           StartDtscreenQix
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode qix
+       DESCRIPTION     qix: Spinning lines a la Qix(tm)
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode qix
+#      DESCRIPTION     qix: Spinning lines
+
+ACTION StartDtscreenImage
+{
+       LABEL           StartDtscreenImage
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode image
+       DESCRIPTION     image: Randomly appearing logos
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode image
+#      DESCRIPTION     image: Random bouncing image
+
+ACTION StartDtscreenLife
+{
+       LABEL           StartDtscreenLife
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode life
+       DESCRIPTION     life: Conway's game of Life
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode life
+
+ACTION StartDtscreenSwarm
+{
+       LABEL           StartDtscreenSwarm
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode swarm
+       DESCRIPTION     swarm: A swarm of bees following a wasp
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode swarm
+#      DESCRIPTION     swarm: Swarm of bees
+
+ACTION StartDtscreenRotor
+{
+       LABEL           StartDtscreenRotor
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode rotor
+       DESCRIPTION     rotor: Tom's Roto-Rotor
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode rotor
+#      DESCRIPTION     rotor: Rotor
+
+ACTION StartDtscreenPyro
+{
+       LABEL           StartDtscreenPyro
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode pyro
+       DESCRIPTION     pyro: Fireworks
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode pyro
+
+ACTION StartDtscreenFlame
+{
+       LABEL           StartDtscreenFlame
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode flame
+       DESCRIPTION     flame: Cosmic flame fractals
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode flame
+#      DESCRIPTION     flame: Cosmic Flame Fractals
+
+ACTION StartDtscreenWorm
+{
+       LABEL           StartDtscreenWorm
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode worm
+       DESCRIPTION     worm: Wiggly worms
+}
+#      EXEC_STRING     /usr/dt/bin/dtscreen -mode worm
+#      DESCRIPTION     worm: Wiggly Worms
+
+ACTION StartDtscreenBlank
+{
+       LABEL           StartDtscreenBlank
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode blank
+       DESCRIPTION     blank: Nothing but a blank screen
+}
+#      DESCRIPTION     blank: Blank Screen
+
+###################################################################
+#
+# xlock's modes that dtscreen doesn't have.
+#
+###################################################################
+ACTION StartDtscreenAnt
+{
+       LABEL           StartDtscreenAnt
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode ant
+       DESCRIPTION     ant: Langton's and Turk's generalized ants
+}
+
+ACTION StartDtscreenAtlantis
+{
+       LABEL           StartDtscreenAtlantis
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode atlantis
+       DESCRIPTION     atlantis: Moving sharks/whales/dolphin
+}
+
+ACTION StartDtscreenBall
+{
+       LABEL           StartDtscreenBall
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode ball
+       DESCRIPTION     ball: Bouncing balls
+}
+
+ACTION StartDtscreenBat
+{
+       LABEL           StartDtscreenBat
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode bat
+       DESCRIPTION     bat: Bouncing flying bats
+}
+
+ACTION StartDtscreenBlot
+{
+       LABEL           StartDtscreenBlot
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode blot
+       DESCRIPTION     blot: Rorschach's ink blot test
+}
+
+ACTION StartDtscreenBouboule
+{
+       LABEL           StartDtscreenBouboule
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode bouboule
+       DESCRIPTION     bouboule: Mimi's bouboule of moving stars
+}
+
+ACTION StartDtscreenBounce
+{
+       LABEL           StartDtscreenBounce
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode bounce
+       DESCRIPTION     bounce: Bouncing footballs
+}
+
+ACTION StartDtscreenBraid
+{
+       LABEL           StartDtscreenBraid
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode braid
+       DESCRIPTION     braid: Random braids and knots
+}
+
+ACTION StartDtscreenBubble
+{
+       LABEL           StartDtscreenBubble
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode bubble
+       DESCRIPTION     bubble: Popping bubbles
+}
+
+ACTION StartDtscreenBubble3d
+{
+       LABEL           StartDtscreenBubble3d
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode bubble3d
+       DESCRIPTION     bubble3d: Richard Jones's GL bubbles
+}
+ACTION StartDtscreenBug
+{
+       LABEL           StartDtscreenBug
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode bug
+       DESCRIPTION     bug: Palmiter's bug evolution and garden of Eden
+}
+
+ACTION StartDtscreenCage
+{
+       LABEL           StartDtscreenCage
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode cage
+       DESCRIPTION     cage: The Impossible Cage, an Escher-like GL scene
+}
+
+ACTION StartDtscreenCartoon
+{
+       LABEL           StartDtscreenCartoon
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode cartoon
+       DESCRIPTION     cartoon: Bouncing cartoons
+}
+
+ACTION StartDtscreenClock
+{
+       LABEL           StartDtscreenClock
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode clock
+       DESCRIPTION     clock: Packard's clock
+}
+
+ACTION StartDtscreenCoral
+{
+       LABEL           StartDtscreenCoral
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode coral
+       DESCRIPTION     coral: A coral reef
+}
+
+ACTION StartDtscreenCrystal
+{
+       LABEL           StartDtscreenCrystal
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode crystal +install
+       DESCRIPTION     crystal: Polygons in 2D plane groups
+}
+
+ACTION StartDtscreenDaisy
+{
+       LABEL           StartDtscreenDaisy
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode daisy
+       DESCRIPTION     daisy: A meadow of daisies
+}
+
+ACTION StartDtscreenDclock
+{
+       LABEL           StartDtscreenDclock
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode dclock
+       DESCRIPTION     dclock: A floating digital clock or message
+}
+
+ACTION StartDtscreenDecay
+{
+       LABEL           StartDtscreenDecay
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode decay
+       DESCRIPTION     decay: A decaying screen
+}
+
+ACTION StartDtscreenDeco
+{
+       LABEL           StartDtscreenDeco
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode deco
+       DESCRIPTION     deco: Art as ugly as sin
+}
+
+ACTION StartDtscreenDemon
+{
+       LABEL           StartDtscreenDemon
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode demon
+       DESCRIPTION     demon: Griffeath's cellular automata
+}
+
+ACTION StartDtscreenDilemma
+{
+       LABEL           StartDtscreenDilemma
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode dilemma
+       DESCRIPTION     dilemma: Lloyd's Prisoner's Dilemma simulation
+}
+
+ACTION StartDtscreenDiscrete
+{
+       LABEL           StartDtscreenDiscrete
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode discrete
+       DESCRIPTION     discrete: Various discrete maps
+}
+
+ACTION StartDtscreenDrift
+{
+       LABEL           StartDtscreenDrift
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode drift
+       DESCRIPTION     drift: Cosmic drifting flame fractals
+}
+
+ACTION StartDtscreenEyes
+{
+       LABEL           StartDtscreenEyes
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode eyes
+       DESCRIPTION     eyes: Eyes following a bouncing grelb
+}
+
+ACTION StartDtscreenFadeplot
+{
+       LABEL           StartDtscreenFadeplot
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode fadeplot
+       DESCRIPTION     fadeplot: A fading plot of sine squared
+}
+
+ACTION StartDtscreenFlag
+{
+       LABEL           StartDtscreenFlag
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode flag
+       DESCRIPTION     flag: A waving flag image
+}
+
+ACTION StartDtscreenFlow
+{
+       LABEL           StartDtscreenFlow
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode flow
+       DESCRIPTION     flow: Dynamic strange attractors
+}
+
+ACTION StartDtscreenForest
+{
+       LABEL           StartDtscreenForest
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode forest
+       DESCRIPTION     forest: Binary trees of a fractal forest
+}
+
+ACTION StartDtscreenGalaxy
+{
+       LABEL           StartDtscreenGalaxy
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode galaxy
+       DESCRIPTION     galaxy: Crashing spiral galaxies
+}
+
+ACTION StartDtscreenGears
+{
+       LABEL           StartDtscreenGears
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode gears
+       DESCRIPTION     gears: GL's gears
+}
+
+ACTION StartDtscreenGoop
+{
+       LABEL           StartDtscreenGoop
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode goop
+       DESCRIPTION     goop: Goop from a lava lamp
+}
+
+ACTION StartDtscreenGrav
+{
+       LABEL           StartDtscreenGrav
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode grav
+       DESCRIPTION     grav: Orbiting planets
+}
+
+ACTION StartDtscreenHelix
+{
+       LABEL           StartDtscreenHelix
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode helix
+       DESCRIPTION     helix: String art
+}
+
+ACTION StartDtscreenHyper
+{
+       LABEL           StartDtscreenHyper
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode hyper
+       DESCRIPTION     hyper: Spinning n-dimensional hypercubes
+}
+
+ACTION StartDtscreenIco
+{
+       LABEL           StartDtscreenIco
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode ico
+       DESCRIPTION     ico: A bouncing polyhedra
+}
+
+ACTION StartDtscreenIfs
+{
+       LABEL           StartDtscreenIfs
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode ifs
+       DESCRIPTION     ifs: A modified iterated function system
+}
+
+ACTION StartDtscreenInvert
+{
+       LABEL           StartDtscreenInvert
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode invert
+       DESCRIPTION     invert: A sphere inverted without wrinkles
+}
+
+ACTION StartDtscreenJulia
+{
+       LABEL           StartDtscreenJulia
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode julia
+       DESCRIPTION     julia: The Julia set
+}
+
+ACTION StartDtscreenKaleid
+{
+       LABEL           StartDtscreenKaleid
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode kaleid
+       DESCRIPTION     kaleid: Brewster's Kaleidoscope
+}
+
+ACTION StartDtscreenKumppa
+{
+       LABEL           StartDtscreenKumppa
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode kumppa +install
+       DESCRIPTION     kumppa: Kumppa
+}
+
+ACTION StartDtscreenLament
+{
+       LABEL           StartDtscreenLament
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode lament
+       DESCRIPTION     lament: Lemarchand's Box
+}
+
+ACTION StartDtscreenLaser
+{
+       LABEL           StartDtscreenLaser
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode laser
+       DESCRIPTION     laser: Spinning lasers
+}
+
+ACTION StartDtscreenLife1d
+{
+       LABEL           StartDtscreenLife1d
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode life1d
+       DESCRIPTION     life1d: Wolfram's game of 1D Life
+}
+
+ACTION StartDtscreenLife3d
+{
+       LABEL           StartDtscreenLife3d
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode life3d
+       DESCRIPTION     life3d: Bays' game of 3D Life
+}
+
+ACTION StartDtscreenLightning
+{
+       LABEL           StartDtscreenLightning
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode lightning
+       DESCRIPTION     lightning: Keith's fractal lightning bolts
+}
+
+ACTION StartDtscreenLisa
+{
+       LABEL           StartDtscreenLisa
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode lisa
+       DESCRIPTION     lisa: Animated lisajous loops
+}
+
+ACTION StartDtscreenLissie
+{
+       LABEL           StartDtscreenLissie
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode lissie
+       DESCRIPTION     lissie: Lissajous worms
+}
+
+ACTION StartDtscreenLoop
+{
+       LABEL           StartDtscreenLoop
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode loop
+       DESCRIPTION     loop: Langton's self-producing loops
+}
+
+ACTION StartDtscreenLyapunov
+{
+       LABEL           StartDtscreenLyapunov
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode lyapunov
+       DESCRIPTION     lyapunov: lyapunov space
+}
+
+ACTION StartDtscreenMandelbrot
+{
+       LABEL           StartDtscreenMandelbrot
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode mandelbrot
+       DESCRIPTION     mandelbrot: Mandelbrot sets
+}
+
+ACTION StartDtscreenMarquee
+{
+       LABEL           StartDtscreenMarquee
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode marquee
+       DESCRIPTION     marquee: Messages
+}
+
+ACTION StartDtscreenMatrix
+{
+       LABEL           StartDtscreenMatrix
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode matrix
+       DESCRIPTION     maze: The matrix
+}
+
+ACTION StartDtscreenMaze
+{
+       LABEL           StartDtscreenMaze
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode maze
+       DESCRIPTION     maze: A random maze and a depth first search solution
+}
+
+ACTION StartDtscreenMoebius
+{
+       LABEL           StartDtscreenMoebius
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode moebius
+       DESCRIPTION     moebius: Moebius Strip II, an Escher-like GL scene with ants
+}
+
+ACTION StartDtscreenMorph3d
+{
+       LABEL           StartDtscreenMorph3d
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode morph3d
+       DESCRIPTION     morph3d: GL morphing polyhedra
+}
+
+ACTION StartDtscreenMountain
+{
+       LABEL           StartDtscreenMountain
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode mountain
+       DESCRIPTION     mountain: Papo's mountain range
+}
+
+ACTION StartDtscreenMunch
+{
+       LABEL           StartDtscreenMunch
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode munch
+       DESCRIPTION     munch: Munching squares
+}
+
+ACTION StartDtscreenNose
+{
+       LABEL           StartDtscreenNose
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode nose
+       DESCRIPTION     nose: A man with a big nose runs around spewing out messages
+}
+
+ACTION StartDtscreenPacman
+{
+       LABEL           StartDtscreenPacman
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode pacman
+       DESCRIPTION     pacman: Pacman(tm)
+}
+
+ACTION StartDtscreenPenrose
+{
+       LABEL           StartDtscreenPenrose
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode penrose
+       DESCRIPTION     penrose: Penrose's quasiperiodic tilings
+}
+
+ACTION StartDtscreenPetal
+{
+       LABEL           StartDtscreenPetal
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode petal
+       DESCRIPTION     petal: Various GCD Flowers
+}
+
+ACTION StartDtscreenPipes
+{
+       LABEL           StartDtscreenPipes
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode pipes
+       DESCRIPTION     pipes: A selfbuilding pipe system
+}
+
+ACTION StartDtscreenPuzzle
+{
+       LABEL           StartDtscreenPuzzle
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode puzzle
+       DESCRIPTION     puzzle: A puzzle being scrambled and then solved
+}
+
+ACTION StartDtscreenRoll
+{
+       LABEL           StartDtscreenRoll
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode roll
+       DESCRIPTION     roll: A rolling ball
+}
+
+ACTION StartDtscreenRubik
+{
+       LABEL           StartDtscreenRubik
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode rubik
+       DESCRIPTION     rubik: An auto-solving Rubik's cube
+}
+
+ACTION StartDtscreenShape
+{
+       LABEL           StartDtscreenShape
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode shape
+       DESCRIPTION     shape: Stippled rectangles, ellipses, and triangles
+}
+
+ACTION StartDtscreenSierpinski
+{
+       LABEL           StartDtscreenSierpinski
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode sierpinski
+       DESCRIPTION     sierpinski: Sierpinski's triangle
+}
+
+ACTION StartDtscreenSlip
+{
+       LABEL           StartDtscreenSlip
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode slip
+       DESCRIPTION     slip: Slipping blits
+}
+
+ACTION StartDtscreenSphere
+{
+       LABEL           StartDtscreenSphere
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode sphere
+       DESCRIPTION     sphere: A bunch of shaded spheres
+}
+
+ACTION StartDtscreenSpiral
+{
+       LABEL           StartDtscreenSpiral
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode spiral
+       DESCRIPTION     spiral: Helixes of dots
+}
+
+ACTION StartDtscreenSpline
+{
+       LABEL           StartDtscreenSpline
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode spline
+       DESCRIPTION     spline: Colorful moving splines
+}
+
+ACTION StartDtscreenSproingies
+{
+       LABEL           StartDtscreenSproingies
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode sproingies
+       DESCRIPTION     sproingies: Sproingies! Nontoxic. Safe for pets and small children
+}
+
+ACTION StartDtscreenStairs
+{
+       LABEL           StartDtscreenStairs
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode stairs
+       DESCRIPTION     stairs: Infinite Stairs, an Escher-like GL scene
+}
+
+ACTION StartDtscreenStar
+{
+       LABEL           StartDtscreenStar
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode star
+       DESCRIPTION     star: A star field with a twist
+}
+
+ACTION StartDtscreenStarfish
+{
+       LABEL           StartDtscreenStarfish
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode starfish +install
+       DESCRIPTION     starfish: Starfish
+}
+
+ACTION StartDtscreenStrange
+{
+       LABEL           StartDtscreenStrange
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode strange
+       DESCRIPTION     strange: Strange attractors
+}
+
+ACTION StartDtscreenSuperquadrics
+{
+       LABEL           StartDtscreenSuperquadrics
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode superquadrics
+       DESCRIPTION     superquadrics: 3D mathematical shapes
+}
+
+ACTION StartDtscreenSwirl
+{
+       LABEL           StartDtscreenSwirl
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode swirl
+       DESCRIPTION     swirl: Animated swirling patterns
+}
+
+ACTION StartDtscreenTetris
+{
+       LABEL           StartDtscreenTetris
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode tetris +install
+       DESCRIPTION     tetris: Tetris
+}
+
+ACTION StartDtscreenThornbird
+{
+       LABEL           StartDtscreenThornbird
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode thornbird
+       DESCRIPTION     thornbird: An animated Bird in a Thorn Bush fractal map
+}
+
+ACTION StartDtscreenTriangle
+{
+       LABEL           StartDtscreenTriangle
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode triangle
+       DESCRIPTION     triangle: A triangle mountain range
+}
+
+ACTION StartDtscreenTube
+{
+       LABEL           StartDtscreenTube
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode tube
+       DESCRIPTION     tube: An animated tube
+}
+
+ACTION StartDtscreenTurtle
+{
+       LABEL           StartDtscreenTurtle
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode turtle
+       DESCRIPTION     turtle: Turtle fractals
+}
+
+ACTION StartDtscreenVines
+{
+       LABEL           StartDtscreenVines
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode vines
+       DESCRIPTION     vines: Fractals
+}
+
+ACTION StartDtscreenVoters
+{
+       LABEL           StartDtscreenVoters
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode voters
+       DESCRIPTION     voters: Dewdney's Voters
+}
+
+ACTION StartDtscreenWator
+{
+       LABEL           StartDtscreenWator
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode wator
+       DESCRIPTION     wator: Dewdney's Water-Torus planet of fish and sharks
+}
+
+ACTION StartDtscreenWire
+{
+       LABEL           StartDtscreenWire
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode wire
+       DESCRIPTION     wire: A random circuit with 2 electrons
+}
+
+ACTION StartDtscreenWorld
+{
+       LABEL           StartDtscreenWorld
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode world
+       DESCRIPTION     world: Spinning Earths
+}
+
+ACTION StartDtscreenXjack
+{
+       LABEL           StartDtscreenXjack
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode xjack
+       DESCRIPTION     xjack: Jack having one of those days
+}
+
+ACTION StartDtscreenBomb
+{
+       LABEL           StartDtscreenBomb
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode bomb
+       DESCRIPTION     bomb: A bomb and will autologout after a time
+}
+
+ACTION StartDtscreenRandom
+{
+       LABEL           StartDtscreenRandom
+       TYPE            COMMAND
+       WINDOW_TYPE     NO_STDIO
+       EXEC_STRING     $DTSCREEN -mode random
+       DESCRIPTION     random: A random mode except blank and bomb
+}
+
diff --git a/xlockmore-4.14/etc/ext.life b/xlockmore-4.14/etc/ext.life
new file mode 100644 (file)
index 0000000..1b320c7
--- /dev/null
@@ -0,0 +1,24 @@
+#P 0 0
+...........*
+..........**
+..........
+........***
+........***
+.........
+.........
+.......***
+.......**
+......*..***.*
+......**.*...*
+......**.**.**
+......***
+......**
+......*
+......**
+.......*.*
+...........*
+.........*..*
+..........*..*
+..........*
+.............*
+...........***
diff --git a/xlockmore-4.14/etc/fortune.dat b/xlockmore-4.14/etc/fortune.dat
new file mode 100644 (file)
index 0000000..9d8b067
--- /dev/null
@@ -0,0 +1,4052 @@
+1420
+%%
+(She is loud and stubborn; her feet abide not in her house: 
+Now is she without, now in the streets, and lieth in wait at every corner.) 
+So she caught him, and kissed him, and 
+with an impudent face said unto him, 
+I have peace offerings with me; this day have I payed my vows.
+%%
+* UNIX is a trademark of AT&T Bell Laboratories.
+%%
+1 bulls, 3 cows.
+%%
+10.0 times 0.1 is hardly ever 1.0.
+%%
+A GOOD name is rather to be chosen than great riches, and 
+loving favour rather than silver and gold.
+%%
+A Puritan is someone who is deathly afraid that someone 
+somewhere is having fun.
+%%
+A bad compromise is better than a good battle. -- Russian 
+proverb
+%%
+A bird in hand is worth two in the bush. -- Cervantes
+%%
+A bird in the bush can't relieve itself in your hand.
+%%
+A brother offended is harder to be won than a strong city: 
+and their contentions are like the bars of a castle.
+%%
+A clash of doctrine is not a disaster -- it is an 
+opportunity.
+%%
+A conservative is one who is too cowardly to fight and too 
+fat to run.
+%%
+A continual dropping in a very rainy day and a contentious 
+woman are alike.
+%%
+A divine sentence is in the lips of the king: his mouth 
+transgresseth not in judgment.
+%%
+A faithful man shall abound with blessings: but he that 
+maketh haste to be rich shall not be innocent.
+%%
+A faithful witness will not lie: but a false witness will 
+utter lies.
+%%
+A false balance is abomination to the LORD: but a just 
+weight is his delight.
+%%
+A false witness shall not be unpunished, and he that 
+speaketh lies shall not escape.
+%%
+A false witness shall not be unpunished, and he that 
+speaketh lies shall perish.
+%%
+A fanatic is one who can't change his mind and won't change 
+the subject.
+%%
+A fool despiseth his father's instruction: but he that 
+regardeth reproof is prudent.
+%%
+A fool hath no delight in understanding, but that his heart 
+may discover itself.
+%%
+A fool uttereth all his mind: but a wise man keepeth it in 
+till afterwards.
+%%
+A fool's lips enter into contention, and his mouth calleth 
+for strokes.
+%%
+A fool's mouth is his destruction, and his lips are the 
+snare of his soul.
+%%
+A fool's wrath is presently known: but a prudent man 
+covereth shame.
+%%
+A foolish consistency is the hobgoblin of little minds.
+%%
+A foolish son is a grief to his father, and bitterness to 
+her that bare him.
+%%
+A foolish son is the calamity of his father: and the 
+contentions of a wife are a continual dropping.
+%%
+A foolish woman is clamorous: she is simple, and knoweth 
+nothing.
+%%
+A froward man soweth strife: and a whisperer separateth 
+chief friends.
+%%
+A gift in secret pacifieth anger: and a reward in the bosom 
+strong wrath.
+%%
+A gift is as a precious stone in the eyes of him that hath 
+it: whithersoever it turneth, it prospereth.
+%%
+A gift of flowers will soon be made to you.
+%%
+A good man leaveth an inheritance to his children's 
+children: and the wealth of the sinner is laid up for the just.
+%%
+A good man obtaineth favour of the LORD: but a man of 
+wicked devices will he condemn.
+%%
+A good memory does not equal pale ink.
+%%
+A gracious woman retaineth honour: and strong men retain 
+riches.
+%%
+A great empire, like a great cake, is most easily 
+diminished at the edges.
+%%
+A hammer sometimes misses its mark -- a bouquet never.
+%%
+A handful of friends is worth more than a wagon of gold.
+%%
+A hen is only an egg's way of making another egg.
+%%
+A hermit is a deserter from the army of humanity.
+%%
+A journey of a thousand miles begins with a cash advance.
+%%
+A just weight and balance are the LORD's: all the weights 
+of the bag are his work.
+%%
+A king that sitteth in the throne of judgment scattereth 
+away all evil with his eyes.
+%%
+A king's castle is his home.
+%%
+A lack of leadership is no substitute for inaction.
+%%
+A liberal is someone too poor to be a capitalist and too 
+rich to be a communist.
+%%
+A lying tongue hateth those that are afflicted by it; and a 
+flattering mouth worketh ruin.
+%%
+A man forgives only when he is in the wrong.
+%%
+A man hath joy by the answer of his mouth: and a word 
+spoken in due season, how good is it! The way of life is above 
+to the wise, that he may depart from hell beneath.
+%%
+A man of genius makes no mistakes.  His errors are 
+volitional and are the portals of discovery.
+%%
+A man of great wrath shall suffer punishment: for if thou 
+deliver him, yet thou must do it again.
+%%
+A man paints with his brains and not with his hands.
+%%
+A man shall be commended according to his wisdom: but he 
+that is of a perverse heart shall be despised.
+%%
+A man shall be satisfied with good by the fruit of his 
+mouth: and the recompence of a man's hands shall be rendered 
+unto him.
+%%
+A man shall eat good by the fruit of his mouth: but the 
+soul of the transgressors shall eat violence.
+%%
+A man shall not be established by wickedness: but the root 
+of the righteous shall not be moved.
+%%
+A man that beareth false witness against his neighbour is a 
+maul, and a sword, and a sharp arrow.
+%%
+A man that doeth violence to the blood of any person shall 
+flee to the pit; let no man stay him.
+%%
+A man that flattereth his neighbour spreadeth a net for his 
+feet.
+%%
+A man that hath friends must shew himself friendly: and 
+there is a friend that sticketh closer than a brother.
+%%
+A man void of understanding striketh hands, and becometh 
+surety in the presence of his friend.
+%%
+A man who fishes for marlin in ponds will put his money in 
+Etruscan bonds.
+%%
+A man who turns green has eschewed protein.
+%%
+A man's belly shall be satisfied with the fruit of his 
+mouth; and with the increase of his lips shall he be filled.
+%%
+A man's gift maketh room for him, and bringeth him before 
+great men.
+%%
+A man's heart deviseth his way: but the LORD directeth his 
+steps.
+%%
+A man's pride shall bring him low: but honour shall uphold 
+the humble in spirit.
+%%
+A merry heart doeth good like a medicine: but a broken 
+spirit drieth the bones.
+%%
+A merry heart maketh a cheerful countenance: but by sorrow 
+of the heart the spirit is broken.
+%%
+A naughty person, a wicked man, walketh with a froward 
+mouth.
+%%
+A plucked goose doesn't lay golden eggs.
+%%
+A poor man that oppresseth the poor is like a sweeping rain 
+which leaveth no food.
+%%
+A professor is one who talks in someone else's sleep.
+%%
+A programming language is low-level when its programs 
+require attention to the irrelevant.
+%%
+A programming language that does not affect the way you 
+think about programming is not worth knowing.
+%%
+A prudent man concealeth knowledge: but the heart of fools 
+proclaimeth foolishness.
+%%
+A prudent man foreseeth the evil, and hideth himself: but 
+the simple pass on, and are punished.
+%%
+A prudent man foreseeth the evil, and hideth himself; but 
+the simple pass on, and are punished.
+%%
+A reproof entereth more into a wise man than an hundred 
+stripes into a fool.
+%%
+A righteous man falling down before the wicked is as a 
+troubled fountain, and a corrupt spring.
+%%
+A righteous man hateth lying: but a wicked man is 
+loathsome, and cometh to shame.
+%%
+A righteous man regardeth the life of his beast: but the 
+tender mercies of the wicked are cruel.
+%%
+A scorner seeketh wisdom, and findeth it not: but knowledge 
+is easy unto him that understandeth.
+%%
+A servant will not be corrected by words: for though he 
+understand he will not answer.
+%%
+A slothful man hideth his hand in his bosom, and will not 
+so much as bring it to his mouth again.
+%%
+A soft answer turneth away wrath: but grievous words stir 
+up anger.
+%%
+A soft drink turneth away company.
+%%
+A sound heart is the life of the flesh: but envy the 
+rottenness of the bones.
+%%
+A stone is heavy, and the sand weighty; but a fool's wrath 
+is heavier than them both.
+%%
+A straw vote only shows which way the hot air blows.
+%%
+A talebearer revealeth secrets: but he that is of a 
+faithful spirit concealeth the matter.
+%%
+A thing not worth doing is worth not doing well.
+%%
+A thing worth doing is worth the trouble of asking somebody 
+else to do.
+%%
+A true witness delivereth souls: but a deceitful witness 
+speaketh lies.
+%%
+A truly wise man never plays leapfrog with a Unicorn.
+%%
+A violent man enticeth his neighbour, and leadeth him into 
+the way that is not good.
+%%
+A virtuous woman is a crown to her husband: but she that 
+maketh ashamed is as rottenness in his bones.
+%%
+A visit to a fresh place will bring strange work.
+%%
+A visit to a strange place will bring fresh work.
+%%
+A whip for the horse, a bridle for the ass, and a rod for 
+the fool's back.
+%%
+A wholesome tongue is a tree of life: but perverseness 
+therein is a breach in the spirit.
+%%
+A wicked doer giveth heed to false lips; and a liar giveth 
+ear to a naughty tongue.
+%%
+A wicked man hardeneth his face: but as for the upright, he 
+directeth his way.
+%%
+A wicked man taketh a gift out of the bosom to pervert the 
+ways of judgment.
+%%
+A wicked messenger falleth into mischief: but a faithful 
+ambassador is health.
+%%
+A wise king scattereth the wicked, and bringeth the wheel 
+over them.
+%%
+A wise man feareth, and departeth from evil: but the fool 
+rageth, and is confident.
+%%
+A wise man is strong; yea, a man of knowledge increaseth 
+strength.
+%%
+A wise man scaleth the city of the mighty, and casteth down 
+the strength of the confidence thereof.
+%%
+A wise man will hear, and will increase learning; and a man 
+of understanding shall attain unto wise counsels: To 
+understand a proverb, and the interpretation; the words of the 
+wise, and their dark sayings.
+%%
+A wise servant shall have rule over a son that causeth 
+shame, and shall have part of the inheritance among the 
+brethren.
+%%
+A wise son heareth his father's instruction: but a scorner 
+heareth not rebuke.
+%%
+A wise son maketh a glad father: but a foolish man 
+despiseth his mother.
+%%
+A woman without a man is like a fish without a bicycle.
+%%
+A word fitly spoken is like apples of gold in pictures of 
+silver.
+%%
+A wound and dishonour shall he get; and his reproach shall 
+not be wiped away.
+%%
+A wrathful man stirreth up strife: but he that is slow to 
+anger appeaseth strife.
+%%
+About all some men accomplish in life is to send a son to 
+Harvard.
+%%
+About the only thing on a farm that has an easy time is the 
+dog.
+%%
+Above all things, reverence yourself.
+%%
+Absence makes the heart grow fonder. -- Sextus Aurelius
+%%
+Absolute power corrupts absolutely.
+%%
+Academy: A modern school where football is taught.
+%%
+Accuse not a servant unto his master, lest he curse thee, 
+and thou be found guilty.
+%%
+Actors will happen in the best-regulated families.
+%%
+Add thou not unto his words, lest he reprove thee, and thou 
+be found a liar.
+%%
+Admiration: Our polite recognition of another's resemblance 
+to ourselves.
+%%
+After a number of decimal places, nobody gives a darn.
+%%
+Age and treachery will always overcome youth and skill.
+%%
+Alimony and bribes will engage a large share of your wealth.
+%%
+All great ideas are controversial, or have been at one time.
+%%
+All heiresses are beautiful. -- John Dryden
+%%
+All in all, it's just another brick in the wall ...
+%%
+All that glitters has a high refractive index.
+%%
+All that trembles doesn't fall. -- Russian proverb
+%%
+All the brave men are in prison. -- Russian proverb
+%%
+All the brethren of the poor do hate him: how much more do 
+his friends go far from him? he pursueth them with words, 
+yet they are wanting to him.
+%%
+All the days of the afflicted are evil: but he that is of a 
+merry heart hath a continual feast.
+%%
+All the ways of a man are clean in his own eyes; but the 
+LORD weigheth the spirits.
+%%
+All the words of my mouth are in righteousness; there is 
+nothing froward or perverse in them.
+%%
+All this wheeling and dealing around, why, it isn't for 
+money, it's for fun.  Money's just the way we keep score.
+%%
+Also to punish the just is not good, nor to strike princes 
+for equity.
+%%
+Also, that the soul be without knowledge, it is not good; 
+and he that hasteth with his feet sinneth.
+%%
+Always do right.  This will gratify some people, and 
+astonish the rest.
+%%
+America's best buy for a dime is a telephone call to the 
+right person.
+%%
+An angry man stirreth up strife, and a furious man 
+aboundeth in transgression.
+%%
+An evil man seeketh only rebellion: therefore a cruel 
+messenger shall be sent against him.
+%%
+An expert is a person who avoids the small errors as he 
+sweeps on to the grand fallacy.
+%%
+An eye for an eye, a tooth for a tooth.
+%%
+An high look, and a proud heart, and the plowing of the 
+wicked, is sin.
+%%
+An hypocrite with his mouth destroyeth his neighbour: but 
+through knowledge shall the just be delivered.
+%%
+An idle mind is worth two in the bush.
+%%
+An inheritance may be gotten hastily at the beginning; but 
+the end thereof shall not be blessed.
+%%
+An optimist believes this to be the best of all possible 
+worlds.  A pessimist fears this to be true.
+%%
+An ungodly man diggeth up evil: and in his lips there is as 
+a burning fire.
+%%
+An ungodly witness scorneth judgment: and the mouth of the 
+wicked devoureth iniquity.
+%%
+An unjust man is an abomination to the just: and he that is 
+upright in the way is abomination to the wicked.
+%%
+And they lay wait for their own blood; they lurk privily 
+for their own lives.
+%%
+And thou shalt have goats' milk enough for thy food, for 
+the food of thy household, and for the maintenance for thy 
+maidens.
+%%
+And why wilt thou, my son, be ravished with a strange 
+woman, and embrace the bosom of a stranger? For the ways of man 
+are before the eyes of the LORD, and he pondereth all his goings.
+%%
+Answer a fool according to his folly, lest he be wise in 
+his own conceit.
+%%
+Answer not a fool according to his folly, lest thou also be 
+like unto him.
+%%
+Anticipated events never live up to expectations.
+%%
+Any fool can paint a picture, but it takes a wise man to be 
+able to sell it.
+%%
+Anybody can win, unless there happens to be a second entry.
+%%
+Apply thine heart unto instruction, and thine ears to the 
+words of knowledge.
+%%
+As a bird that wandereth from her nest, so is a man that 
+wandereth from his place.
+%%
+As a dog returneth to his vomit, so a fool returneth to his 
+folly.
+%%
+As a jewel of gold in a swine's snout, so is a fair woman 
+which is without discretion.
+%%
+As a mad man who casteth firebrands, arrows, and death, So 
+is the man that deceiveth his neighbour, and saith, Am not 
+I in sport? Where no wood is, there the fire goeth out: so 
+where there is no talebearer, the strife ceaseth.
+%%
+As a roaring lion, and a ranging bear; so is a wicked ruler 
+over the poor people.
+%%
+As a thorn goeth up into the hand of a drunkard, so is a 
+parable in the mouths of fools.
+%%
+As an earring of gold, and an ornament of fine gold, so is 
+a wise reprover upon an obedient ear.
+%%
+As coals are to burning coals, and wood to fire; so is a 
+contentious man to kindle strife.
+%%
+As cold waters to a thirsty soul, so is good news from a 
+far country.
+%%
+As goatherd learns his trade by goat, so writer learns his 
+trade by wrote.
+%%
+As he that bindeth a stone in a sling, so is he that giveth 
+honour to a fool.
+%%
+As he that taketh away a garment in cold weather, and as 
+vinegar upon nitre, so is he that singeth songs to an heavy 
+heart.
+%%
+As in water face answereth to face, so the heart of man to 
+man.
+%%
+As long as the answer is right, who cares if the question 
+is wrong?
+%%
+As of next week, passwords will be entered in Morse code.
+%%
+As righteousness tendeth to life: so he that pursueth evil 
+pursueth it to his own death.
+%%
+As snow in summer, and as rain in harvest, so honour is not 
+seemly for a fool.
+%%
+As the bird by wandering, as the swallow by flying, so the 
+curse causeless shall not come.
+%%
+As the cold of snow in the time of harvest, so is a 
+faithful messenger to them that send him: for he refresheth the 
+soul of his masters.
+%%
+As the door turneth upon his hinges, so doth the slothful 
+upon his bed.
+%%
+As the fining pot for silver, and the furnace for gold; so 
+is a man to his praise.
+%%
+As the whirlwind passeth, so is the wicked no more: but the 
+righteous is an everlasting foundation.
+%%
+As vinegar to the teeth, and as smoke to the eyes, so is 
+the sluggard to them that send him.
+%%
+At the last it biteth like a serpent, and stingeth like an adder.
+%%
+Audacity, and again audacity, and always audacity.
+-- Georges Jacques Danton
+%%
+Avoid GOTOs completely if you can keep the program readable.
+%%
+Avoid it, pass not by it, turn from it, and pass away.
+%%
+Avoid temporary variables.
+%%
+Avoid the Fortran arithmetic IF.
+%%
+Avoid unnecessary branches.
+%%
+Be careful when a loop exits to the same place from side 
+and bottom.
+%%
+Be careful!  Is it classified?
+%%
+Be friends with the wolf, but keep one hand on your ax. -- 
+Russian proverb
+%%
+Be not a witness against thy neighbour without cause; and 
+deceive not with thy lips.
+%%
+Be not afraid of sudden fear, neither of the desolation of 
+the wicked, when it cometh.
+%%
+Be not among winebibbers; among riotous eaters of flesh: 
+For the drunkard and the glutton shall come to poverty: and 
+drowsiness shall clothe a man with rags.
+%%
+Be not desirous of his dainties: for they are deceitful meat.
+%%
+Be not thou envious against evil men, neither desire to be 
+with them.
+%%
+Be not thou one of them that strike hands, or of them that 
+are sureties for debts.
+%%
+Be not wise in thine own eyes: fear the LORD, and depart 
+from evil.
+%%
+Be prepared to go mad with fixed rule and method. -- Horace
+%%
+Be security conscious -- National Defense is at stake.
+%%
+Be thou diligent to know the state of thy flocks, and look 
+well to thy herds.
+%%
+Because I have called, and ye refused; I have stretched out 
+my hand, and no man regarded; But ye have set at nought 
+all my counsel, and would none of my reproof: I also will 
+laugh at your calamity; I will mock when your fear cometh; 
+When your fear cometh as desolation, and your destruction 
+cometh as a whirlwind; when distress and anguish cometh upon you.
+%%
+Before a fight, two men are boasting; after the fight, only 
+one. -- Russian proverb
+%%
+Before destruction the heart of man is haughty, and before 
+honour is humility.
+%%
+Before the mountains were settled, before the hills was I 
+brought forth: While as yet he had not made the earth, nor 
+the fields, nor the highest part of the dust of the world.
+%%
+Begin in the beginning and go on till you come to the end; 
+then stop. -- Lewis Carroll
+%%
+Behold, the righteous shall be recompensed in the earth: 
+much more the wicked and the sinner.
+%%
+Better is a dinner of herbs where love is, than a stalled 
+ox and hatred therewith.
+%%
+Better is a dry morsel, and quietness therewith, than an 
+house full of sacrifices with strife.
+%%
+Better is a little with righteousness than great revenues 
+without right.
+%%
+Better is little with the fear of the LORD than great 
+treasure and trouble therewith.
+%%
+Better is the poor that walketh in his integrity, than he 
+that is perverse in his lips, and is a fool.
+%%
+Better is the poor that walketh in his uprightness, than he 
+that is perverse in his ways, though he be rich.
+%%
+Better it is to be of an humble spirit with the lowly, than 
+to divide the spoil with the proud.
+%%
+Better living a beggar than buried an emperor.
+%%
+Better the first quarrel than the last. -- Russian proverb
+%%
+Better to light one candle than to curse the darkness.
+%%
+Better turn back than lose your way. -- Russian proverb
+%%
+Beware of Greeks bearing gifts. -- Virgil
+%%
+Beware of a dark-haired man with a loud tie.
+%%
+Beware of a tall dark man with a spoon up his nose.
+%%
+Beware of all enterprises that require new clothes.
+%%
+Beware the new TTY code!
+%%
+Bind them upon thy fingers, write them upon the table of 
+thine heart.
+%%
+Blessed are they that run around in circles, for they shall 
+be known as wheels.
+%%
+Blessed is the man that heareth me, watching daily at my 
+gates, waiting at the posts of my doors.
+%%
+Blessings are upon the head of the just: but violence 
+covereth the mouth of the wicked.
+%%
+Boast not thyself of to morrow; for thou knowest not what a 
+day may bring forth.
+%%
+Bow down thine ear, and hear the words of the wise, and 
+apply thine heart unto my knowledge.
+%%
+Brain fried --
+core dumped
+%%
+Bread of deceit is sweet to a man; but afterwards his mouth 
+shall be filled with gravel.
+%%
+Bullets don't respect uniforms.
+-- Russian proverb
+%%
+Burning lips and a wicked heart are like a potsherd covered 
+with silver dross.
+%%
+Business will be either better or worse. -- Calvin Coolidge
+%%
+But he knoweth not that the dead are there; and that her 
+guests are in the depths of hell.
+%%
+But he that sinneth against me wrongeth his own soul: all 
+they that hate me love death.
+%%
+But the path of the just is as the shining light, that 
+shineth more and more unto the perfect day.
+%%
+But the wicked shall be cut off from the earth, and the 
+transgressors shall be rooted out of it.
+%%
+But whoso committeth adultery with a woman lacketh 
+understanding: he that doeth it destroyeth his own soul.
+%%
+But whoso hearkeneth unto me shall dwell safely, and shall 
+be quiet from fear of evil.
+%%
+Buy the truth, and sell it not; also wisdom, and 
+instruction, and understanding.
+%%
+By failing to prepare, you are preparing to fail.
+%%
+By his knowledge the depths are broken up, and the clouds 
+drop down the dew.
+%%
+By humility and the fear of the LORD are riches, and 
+honour, and life.
+%%
+By long forbearing is a prince persuaded, and a soft tongue 
+breaketh the bone.
+%%
+By me kings reign, and princes decree justice.
+%%
+By me princes rule, and nobles, even all the judges of the 
+earth.
+%%
+By mercy and truth iniquity is purged: and by the fear of 
+the LORD men depart from evil.
+%%
+By the blessing of the upright the city is exalted: but it 
+is overthrown by the mouth of the wicked.
+%%
+Can a man take fire in his bosom, and his clothes not be 
+burned? Can one go upon hot coals, and his feet not be 
+burned? So he that goeth in to his neighbour's wife; whosoever 
+toucheth her shall not be innocent.
+%%
+Can anyone remember when the times were not hard, and money 
+not scarce?
+%%
+Can anything be sadder than work left unfinished?  Yes, 
+work never begun.
+%%
+Cannot open /usr/games/lib/fortunes.
+%%
+Cast out the scorner, and contention shall go out; yea, 
+strife and reproach shall cease.
+%%
+Cease, my son, to hear the instruction that causeth to err 
+from the words of knowledge.
+%%
+Change your thoughts and you change your world.
+%%
+Charity: A thing that begins at home and usually stays 
+there.
+%%
+Chasten thy son while there is hope, and let not thy soul 
+spare for his crying.
+%%
+Children's children are the crown of old men; and the glory 
+of children are their fathers.
+%%
+Chinese saying: He who speak with forked tongue, not need 
+chopsticks.
+%%
+Choose variable names that won't be confused.
+%%
+Civilization is the limitless multiplication of unnecessary 
+necessities.
+%%
+Classified material requires proper storage.
+%%
+Colorless green ideas sleep furiously.
+%%
+Come, let us take our fill of love until the morning: let 
+us solace ourselves with loves.
+%%
+Commit thy works unto the LORD, and thy thoughts shall be 
+established.
+%%
+Common sense is not so common.
+%%
+Complaint is the largest tribute heaven receives, and the 
+sincerest part of our devotion.
+%%
+Confidence in an unfaithful man in time of trouble is like 
+a broken tooth, and a foot out of joint.
+%%
+Conscience doth make cowards of us all. -- William 
+Shakespeare
+%%
+Continental Life.  Why do you ask?
+%%
+Correct thy son, and he shall give thee rest; yea, he shall 
+give delight unto thy soul.
+%%
+Correction is grievous unto him that forsaketh the way: and 
+he that hateth reproof shall die.
+%%
+Could John Wayne have ever taken Normandy, Iwo Jima, Korea, 
+the Gulf of Tonkin, and the entire Wild West on a diet of 
+quiche and salad?
+%%
+Counsel in the heart of man is like deep water; but a man 
+of understanding will draw it out.
+%%
+Counsel is mine, and sound wisdom: I am understanding; I 
+have strength.
+%%
+Courage is grace under pressure.
+%%
+Courage is your greatest present need.
+%%
+Creditors have much better memories than debtors.
+%%
+Culture is the habit of being pleased with the best and 
+knowing why.
+%%
+Death and life are in the power of the tongue: and they 
+that love it shall eat the fruit thereof.
+%%
+Death: To stop sinning suddenly.
+%%
+Debate thy cause with thy neighbour himself; and discover 
+not a secret to another: Lest he that heareth it put thee to 
+shame, and thine infamy turn not away.
+%%
+Deceit is in the heart of them that imagine evil: but to 
+the counsellors of peace is joy.
+%%
+Delight is not seemly for a fool; much less for a servant 
+to have rule over princes.
+%%
+Deliver thyself as a roe from the hand of the hunter, and 
+as a bird from the hand of the fowler.
+%%
+Democracy is the recurrent suspicion that more than half of 
+the people are right more than half of the time.
+%%
+Depression is merely anger without the enthusiasm.
+%%
+Deprive a mirror of its silver and even the Czar won't see 
+his face.
+%%
+Devise not evil against thy neighbour, seeing he dwelleth 
+securely by thee.
+%%
+Disclose classified information only when a NEED TO KNOW 
+exists.
+%%
+Discretion is the better part of valor. -- William 
+Shakespeare
+%%
+Disk crunch -- please clean up.
+%%
+Divers weights are an abomination unto the LORD; and a 
+false balance is not good.
+%%
+Do not clog intellect's sluices with bits of knowledge of 
+questionable uses.
+%%
+Do not merely believe in miracles, rely on them.
+%%
+Do not take life too seriously: you will never get out of 
+it alive.
+%%
+Do not underestimate the power of the Force.
+%%
+Do they not err that devise evil? but mercy and truth shall 
+be to them that devise good.
+%%
+Do this now, my son, and deliver thyself, when thou art 
+come into the hand of thy friend; go, humble thyself, and make 
+sure thy friend.
+%%
+Do you always believe what a computer tells you?
+%%
+Do you really want to know what I think of you?
+%%
+Dogs do not dislike poor families.
+%%
+Don't be humble, you're not that great.
+%%
+Don't comment bad code -- rewrite it.
+%%
+Don't compare floating point numbers solely for equality.
+%%
+Don't despair -- your ideal lover is waiting for you around 
+the corner.
+%%
+Don't diddle code to make it faster -- find a better 
+algorithm.
+%%
+Don't drive your horse with a whip -- use the oat bag. -- 
+Russian proverb
+%%
+Don't force it, use a bigger hammer.
+%%
+Don't get stuck in a closet -- wear yourself out.
+%%
+Don't hit the keys so hard, it hurts.
+%%
+Don't look now, but the man in the moon is laughing at you.
+%%
+Don't look now, but there is a multi-legged creature on 
+your shoulder.
+%%
+Don't patch bad code -- rewrite it.
+%%
+Don't quit now, we might just as well lock the door and 
+throw away the key.
+%%
+Don't stop at one bug.
+%%
+Don't tell me what you dreamt last night for I've been 
+reading Freud.
+%%
+Doth not wisdom cry? and understanding put forth her voice? 
+She standeth in the top of high places, by the way in the 
+places of the paths.
+%%
+Drawing on my fine command of language, I said nothing.
+%%
+Drink waters out of thine own cistern, and running waters 
+out of thine own well.
+%%
+Drugs are for people who can't handle reality.
+%%
+Due to lack of interest, today has been cancelled.
+%%
+Due to popular demand, you have been awarded the day off.
+%%
+Eat thou not the bread of him that hath an evil eye, 
+neither desire thou his dainty meats: For as he thinketh in his 
+heart, so is he: Eat and drink, saith he to thee; but his 
+heart is not with thee.
+%%
+Education helps earning capacity.  Ask any college 
+professor.
+%%
+Enter not into the path of the wicked, and go not in the 
+way of evil men.
+%%
+Envy thou not the oppressor, and choose none of his ways.
+%%
+Eternal nothingness is fine if you're dressed for it.
+%%
+Even a cabbage may look at a king.
+%%
+Even a child is known by his doings, whether his work be 
+pure, and whether it be right.
+%%
+Even a fool, when he holdeth his peace, is counted wise: 
+and he that shutteth his lips is esteemed a man of 
+understanding.
+%%
+Even a hawk is an eagle among crows.
+%%
+Even in laughter the heart is sorrowful; and the end of 
+that mirth is heaviness.
+%%
+Even the boldest zebra fears the hungry lion.
+%%
+Even the smallest candle burns brighter in the dark.
+%%
+Every absurdity has a champion to defend it.
+%%
+Every creature has within itself the wild, uncontrollable 
+urge to punt.
+%%
+Every generation laughs at old fashions, but follows 
+religiously the new.
+%%
+Every man shall kiss his lips that giveth a right answer.
+%%
+Every nation has the government it deserves.
+%%
+Every one that is proud in heart is an abomination to the 
+LORD: though hand join in hand, he shall not be unpunished.
+%%
+Every program has (at least) two purposes: the one for 
+which it was built, and another for which it wasn't.
+%%
+Every program is a part of some other program and rarely 
+fits.
+%%
+Every prudent man dealeth with knowledge: but a fool layeth 
+open his folly.
+%%
+Every purchase has its price.
+%%
+Every purpose is established by counsel: and with good 
+advice make war.
+%%
+Every silver lining has a cloud inside it.
+%%
+Every way of a man is right in his own eyes: but the LORD 
+pondereth the hearts.
+%%
+Every wise woman buildeth her house: but the foolish 
+plucketh it down with her hands.
+%%
+Everybody needs a little love sometime; stop hacking and 
+fall in love!
+%%
+Everybody ought to have a friend.
+%%
+Everyone is enthusiastic about your work.
+%%
+Everyone needs to believe in something; I believe I'll have 
+another beer.
+%%
+Everything should be built top-down, except the first time.
+%%
+Everything should be made as simple as possible, but no 
+simpler.
+%%
+Everything you know is wrong!
+%%
+Evil men understand not judgment: but they that seek the 
+LORD understand all things.
+%%
+Evil pursueth sinners: but to the righteous good shall be 
+repayed.
+%%
+Exalt her, and she shall promote thee: she shall bring thee 
+to honour, when thou dost embrace her.
+%%
+Excellent speech becometh not a fool: much less do lying 
+lips a prince.
+%%
+Facts do not cease to exist because they are ignored.
+%%
+Failure is more frequently from want of energy than want of 
+capital.
+%%
+Faithful are the wounds of a friend; but the kisses of an 
+enemy are deceitful.
+%%
+Far duller than a serpent's tooth it is to spend a quiet 
+youth.
+%%
+Favour is deceitful, and beauty is vain: but a woman that 
+feareth the LORD, she shall be praised.
+%%
+Fear has big eyes. -- Russian proverb
+%%
+Fidelity: A virtue peculiar to those who are about to be 
+betrayed.
+%%
+Finagle's Law: The perversity of the universe tends toward 
+a maximum.
+%%
+Flee at once, all is discovered.
+%%
+Folly is joy to him that is destitute of wisdom: but a man 
+of understanding walketh uprightly.
+%%
+Foolishness is bound in the heart of a child; but the rod 
+of correction shall drive it far from him.
+%%
+Fools ignore complexity.  Pragmatists suffer it.  Geniuses 
+remove it.
+%%
+Fools make a mock at sin: but among the righteous there is 
+favour.
+%%
+Fools rush in where angels fear to tread. -- Alexander Pope
+%%
+Fools shoot, but God directs the bullets. -- Russian 
+proverb
+%%
+For I give you good doctrine, forsake ye not my law.
+%%
+For I was my father's son, tender and only beloved in the 
+sight of my mother.
+%%
+For a whore is a deep ditch; and a strange woman is a 
+narrow pit.
+%%
+For at the window of my house I looked through my casement, 
+And beheld among the simple ones, I discerned among the 
+youths, a young man void of understanding, Passing through 
+the street near her corner; and he went the way to her house, 
+In the twilight, in the evening, in the black and dark 
+night: And, behold, there met him a woman with the attire of 
+an harlot, and subtil of heart.
+%%
+For by me thy days shall be multiplied, and the years of 
+thy life shall be increased.
+%%
+For by means of a whorish woman a man is brought to a piece 
+of bread: and the adultress will hunt for the precious 
+life.
+%%
+For by wise counsel thou shalt make thy war: and in 
+multitude of counsellors there is safety.
+%%
+For her house inclineth unto death, and her paths unto the 
+dead.
+%%
+For it is a pleasant thing if thou keep them within thee; 
+they shall withal be fitted in thy lips.
+%%
+For jealousy is the rage of a man: therefore he will not 
+spare in the day of vengeance.
+%%
+For my mouth shall speak truth; and wickedness is an 
+abomination to my lips.
+%%
+For riches are not for ever: and doth the crown endure to 
+every generation? The hay appeareth, and the tender grass 
+sheweth itself, and herbs of the mountains are gathered.
+%%
+For she hath cast down many wounded: yea, many strong men 
+have been slain by her.
+%%
+For she sitteth at the door of her house, on a seat in the 
+high places of the city, To call passengers who go right on 
+their ways: Whoso is simple, let him turn in hither: and 
+as for him that wanteth understanding, she saith to him, 
+Stolen waters are sweet, and bread eaten in secret is pleasant.
+%%
+For surely there is an end; and thine expectation shall not 
+be cut off.
+%%
+For the LORD giveth wisdom: out of his mouth cometh 
+knowledge and understanding.
+%%
+For the LORD shall be thy confidence, and shall keep thy 
+foot from being taken.
+%%
+For the commandment is a lamp; and the law is light; and 
+reproofs of instruction are the way of life: To keep thee 
+from the evil woman, from the flattery of the tongue of a 
+strange woman.
+%%
+For the froward is abomination to the LORD: but his secret 
+is with the righteous.
+%%
+For the goodman is not at home, he is gone a long journey: 
+He hath taken a bag of money with him, and will come home 
+at the day appointed.
+%%
+For the lips of a strange woman drop as an honeycomb, and 
+her mouth is smoother than oil: But her end is bitter as 
+wormwood, sharp as a two-edged sword.
+%%
+For the merchandise of it is better than the merchandise of 
+silver, and the gain thereof than fine gold.
+%%
+For the transgression of a land many are the princes 
+thereof: but by a man of understanding and knowledge the state 
+thereof shall be prolonged.
+%%
+For the turning away of the simple shall slay them, and the 
+prosperity of fools shall destroy them.
+%%
+For the upright shall dwell in the land, and the perfect 
+shall remain in it.
+%%
+For their heart studieth destruction, and their lips talk 
+of mischief.
+%%
+For they are life unto those that find them, and health to 
+all their flesh.
+%%
+For they eat the bread of wickedness, and drink the wine of 
+violence.
+%%
+For they sleep not, except they have done mischief; and 
+their sleep is taken away, unless they cause some to fall.
+%%
+For three things the earth is disquieted, and for four 
+which it cannot bear: For a servant when he reigneth; and a 
+fool when he is filled with meat; For an odious woman when she 
+is married; and an handmaid that is heir to her mistress.
+%%
+For whoso findeth me findeth life, and shall obtain favour 
+of the LORD.
+%%
+For wisdom is better than rubies; and all the things that 
+may be desired are not to be compared to it.
+%%
+Forgive and forget. -- Cervantes
+%%
+Forsake her not, and she shall preserve thee: love her, and 
+she shall keep thee.
+%%
+Forsake the foolish, and live; and go in the way of 
+understanding.
+%%
+Fret not thyself because of evil men, neither be thou 
+envious at the wicked: For there shall be no reward to the evil 
+man; the candle of the wicked shall be put out.
+%%
+Friends: People who borrow my books and set wet glasses on 
+them.
+%%
+General notions are generally wrong.
+%%
+Genius is the talent of a man who is dead.
+%%
+Get wisdom, get understanding: forget it not; neither 
+decline from the words of my mouth.
+%%
+Give her of the fruit of her hands; and let her own works 
+praise her in the gates.
+%%
+Give instruction to a wise man, and he will be yet wiser: 
+teach a just man, and he will increase in learning.
+%%
+Give not sleep to thine eyes, nor slumber to thine eyelids.
+%%
+Give strong drink unto him that is ready to perish, and 
+wine unto those that be of heavy hearts.
+%%
+Go directly to jail.  Do not pass Go, do not collect $200.
+%%
+Go from the presence of a foolish man, when thou perceivest 
+not in him the lips of knowledge.
+%%
+Go not forth hastily to strive, lest thou know not what to 
+do in the end thereof, when thy neighbour hath put thee to 
+shame.
+%%
+Go to the ant, thou sluggard; consider her ways, and be 
+wise: Which having no guide, overseer, or ruler, Provideth her 
+meat in the summer, and gathereth her food in the harvest.
+%%
+God does not play dice.
+%%
+God gave us two ears and one tongue so that we may listen 
+twice as much as we speak.
+%%
+God helps them that help themselves. -- Benjamin Franklin
+%%
+God is not dead; He is only swapped out.
+%%
+God made the integers; all else is the work of Man.
+%%
+God may be subtle, but He isn't plain mean.
+%%
+God must love the common man: He made so many of them.
+%%
+Good intentions are far more difficult to cope with than 
+malicious behavior.
+%%
+Good intentions randomize behavior.
+%%
+Good understanding giveth favour: but the way of 
+transgressors is hard.
+%%
+Great is Holy Russia, but the sun shines elsewhere, too. -- 
+Old Russian proverb
+%%
+Great spirits have always encountered violent opposition 
+from mediocre minds.
+%%
+Greatness is a transitory experience.  It is never 
+consistent.
+%%
+Hackers of the world, unite!
+%%
+Happiness adds and multiplies as we divide it with others.
+%%
+Happy is the man that feareth alway: but he that hardeneth 
+his heart shall fall into mischief.
+%%
+Happy is the man that findeth wisdom, and the man that 
+getteth understanding.
+%%
+Hast thou found honey? eat so much as is sufficient for 
+thee, lest thou be filled therewith, and vomit it.
+%%
+Haste makes waste.
+%%
+Hatred stirreth up strifes: but love covereth all sins.
+%%
+Have not I written to thee excellent things in counsels and 
+knowledge, That I might make thee know the certainty of 
+the words of truth; that thou mightest answer the words of 
+truth to them that send unto thee? Rob not the poor, because 
+he is poor: neither oppress the afflicted in the gate: For 
+the LORD will plead their cause, and spoil the soul of 
+those that spoiled them.
+%%
+Have you locked your file cabinet?
+%%
+He also that is slothful in his work is brother to him that 
+is a great waster.
+%%
+He becometh poor that dealeth with a slack hand: but the 
+hand of the diligent maketh rich.
+%%
+He coveteth greedily all the day long: but the righteous 
+giveth and spareth not.
+%%
+He goeth after her straightway, as an ox goeth to the 
+slaughter, or as a fool to the correction of the stocks; Till a 
+dart strike through his liver; as a bird hasteth to the 
+snare, and knoweth not that it is for his life.
+%%
+He is considered the most graceful speaker who can say 
+nothing in most words.
+%%
+He is in the way of life that keepeth instruction: but he 
+that refuseth reproof erreth.
+%%
+He is truly wise who gains wisdom from another's mishap.
+%%
+He keepeth the paths of judgment, and preserveth the way of 
+his saints.
+%%
+He layeth up sound wisdom for the righteous: he is a 
+buckler to them that walk uprightly.
+%%
+He looked at me as if I was a side dish he hadn't ordered.
+%%
+He loveth transgression that loveth strife: and he that 
+exalteth his gate seeketh destruction.
+%%
+He shall die without instruction; and in the greatness of 
+his folly he shall go astray.
+%%
+He shutteth his eyes to devise froward things: moving his 
+lips he bringeth evil to pass.
+%%
+He taught me also, and said unto me, Let thine heart retain 
+my words: keep my commandments, and live.
+%%
+He that answereth a matter before he heareth it, it is 
+folly and shame unto him.
+%%
+He that begetteth a fool doeth it to his sorrow: and the 
+father of a fool hath no joy.
+%%
+He that blesseth his friend with a loud voice, rising early 
+in the morning, it shall be counted a curse to him.
+%%
+He that by usury and unjust gain increaseth his substance, 
+he shall gather it for him that will pity the poor.
+%%
+He that covereth a transgression seeketh love; but he that 
+repeateth a matter separateth very friends.
+%%
+He that covereth his sins shall not prosper: but whoso 
+confesseth and forsaketh them shall have mercy.
+%%
+He that delicately bringeth up his servant from a child 
+shall have him become his son at the length.
+%%
+He that despiseth his neighbour sinneth: but he that hath 
+mercy on the poor, happy is he.
+%%
+He that deviseth to do evil shall be called a mischievous 
+person.
+%%
+He that diligently seeketh good procureth favour: but he 
+that seeketh mischief, it shall come unto him.
+%%
+He that followeth after righteousness and mercy findeth 
+life, righteousness, and honour.
+%%
+He that gathereth in summer is a wise son: but he that 
+sleepeth in harvest is a son that causeth shame.
+%%
+He that getteth wisdom loveth his own soul: he that keepeth 
+understanding shall find good.
+%%
+He that giveth unto the poor shall not lack: but he that 
+hideth his eyes shall have many a curse.
+%%
+He that goeth about as a talebearer revealeth secrets: 
+therefore meddle not with him that flattereth with his lips.
+%%
+He that handleth a matter wisely shall find good: and whoso 
+trusteth in the LORD, happy is he.
+%%
+He that hasteth to be rich hath an evil eye, and 
+considereth not that poverty shall come upon him.
+%%
+He that hateth dissembleth with his lips, and layeth up 
+deceit within him; When he speaketh fair, believe him not: for 
+there are seven abominations in his heart.
+%%
+He that hath a bountiful eye shall be blessed; for he 
+giveth of his bread to the poor.
+%%
+He that hath a froward heart findeth no good: and he that 
+hath a perverse tongue falleth into mischief.
+%%
+He that hath knowledge spareth his words: and a man of 
+understanding is of an excellent spirit.
+%%
+He that hath no rule over his own spirit is like a city 
+that is broken down, and without walls.
+%%
+He that hath pity upon the poor lendeth unto the LORD; and 
+that which he hath given will he pay him again.
+%%
+He that hideth hatred with lying lips, and he that uttereth 
+a slander, is a fool.
+%%
+He that is despised, and hath a servant, is better than he 
+that honoureth himself, and lacketh bread.
+%%
+He that is first in his own cause seemeth just; but his 
+neighbour cometh and searcheth him.
+%%
+He that is greedy of gain troubleth his own house; but he 
+that hateth gifts shall live.
+%%
+He that is of a proud heart stirreth up strife: but he that 
+putteth his trust in the LORD shall be made fat.
+%%
+He that is slow to anger is better than the mighty; and he 
+that ruleth his spirit than he that taketh a city.
+%%
+He that is slow to wrath is of great understanding: but he 
+that is hasty of spirit exalteth folly.
+%%
+He that is soon angry dealeth foolishly: and a man of 
+wicked devices is hated.
+%%
+He that is surety for a stranger shall smart for it: and he 
+that hateth suretiship is sure.
+%%
+He that is void of wisdom despiseth his neighbour: but a 
+man of understanding holdeth his peace.
+%%
+He that justifieth the wicked, and he that condemneth the 
+just, even they both are abomination to the LORD.
+%%
+He that keepeth his mouth keepeth his life: but he that 
+openeth wide his lips shall have destruction.
+%%
+He that keepeth the commandment keepeth his own soul; but 
+he that despiseth his ways shall die.
+%%
+He that laboureth laboureth for himself; for his mouth 
+craveth it of him.
+%%
+He that loveth pleasure shall be a poor man: he that loveth 
+wine and oil shall not be rich.
+%%
+He that loveth pureness of heart, for the grace of his lips 
+the king shall be his friend.
+%%
+He that oppresseth the poor reproacheth his Maker: but he 
+that honoureth him hath mercy on the poor.
+%%
+He that oppresseth the poor to increase his riches, and he 
+that giveth to the rich, shall surely come to want.
+%%
+He that passeth by, and meddleth with strife belonging not 
+to him, is like one that taketh a dog by the ears.
+%%
+He that rebuketh a man afterwards shall find more favour 
+than he that flattereth with the tongue.
+%%
+He that refuseth instruction despiseth his own soul: but he 
+that heareth reproof getteth understanding.
+%%
+He that reproveth a scorner getteth to himself shame: and 
+he that rebuketh a wicked man getteth himself a blot.
+%%
+He that saith unto the wicked, Thou are righteous; him 
+shall the people curse, nations shall abhor him: But to them 
+that rebuke him shall be delight, and a good blessing shall 
+come upon them.
+%%
+He that sendeth a message by the hand of a fool cutteth off 
+the feet, and drinketh damage.
+%%
+He that soweth iniquity shall reap vanity: and the rod of 
+his anger shall fail.
+%%
+He that spareth his rod hateth his son: but he that loveth 
+him chasteneth him betimes.
+%%
+He that speaketh truth sheweth forth righteousness: but a 
+false witness deceit.
+%%
+He that tilleth his land shall be satisfied with bread: but 
+he that followeth vain persons is void of understanding.
+%%
+He that tilleth his land shall have plenty of bread: but he 
+that followeth after vain persons shall have poverty 
+enough.
+%%
+He that troubleth his own house shall inherit the wind: and 
+the fool shall be servant to the wise of heart.
+%%
+He that trusteth in his own heart is a fool: but whoso 
+walketh wisely, he shall be delivered.
+%%
+He that trusteth in his riches shall fall; but the 
+righteous shall flourish as a branch.
+%%
+He that turneth away his ear from hearing the law, even his 
+prayer shall be abomination.
+%%
+He that walketh in his uprightness feareth the LORD: but he 
+that is perverse in his ways despiseth him.
+%%
+He that walketh uprightly walketh surely: but he that 
+perverteth his ways shall be known.
+%%
+He that walketh with wise men shall be wise: but a 
+companion of fools shall be destroyed.
+%%
+He that wasteth his father, and chaseth away his mother, is 
+a son that causeth shame, and bringeth reproach.
+%%
+He that winketh with the eye causeth sorrow: but a prating 
+fool shall fall.
+%%
+He that withholdeth corn, the people shall curse him: but 
+blessing shall be upon the head of him that selleth it.
+%%
+He that would govern others, first should be the master of 
+himself.
+%%
+He thinks by infection, catching an opinion like a cold.
+%%
+He walks as if balancing the family tree on his nose.
+%%
+He was so narrow-minded he could see through a keyhole with 
+both eyes.
+%%
+He who has imagination without learning has wings but no 
+feet.
+%%
+He who hates vices hates mankind.
+%%
+He who hesitates is lost.
+%%
+He who hesitates is sometimes saved.
+%%
+He who invents adages for others to peruse takes along 
+rowboat when going on cruise.
+%%
+He who laughs, lasts.
+%%
+He who lives without folly is less wise than he believes.
+%%
+He who spends a storm beneath a tree, takes life with a 
+grain of TNT.
+%%
+He will not regard any ransom; neither will he rest 
+content, though thou givest many gifts.
+%%
+He winketh with his eyes, he speaketh with his feet, he 
+teacheth with his fingers; Frowardness is in his heart, he 
+deviseth mischief continually; he soweth discord.
+%%
+He, that being often reproved hardeneth his neck, shall 
+suddenly be destroyed, and that without remedy.
+%%
+Hear counsel, and receive instruction, that thou mayest be 
+wise in thy latter end.
+%%
+Hear instruction, and be wise, and refuse it not.
+%%
+Hear me now therefore, O ye children, and depart not from 
+the words of my mouth.
+%%
+Hear thou, my son, and be wise, and guide thine heart in 
+the way.
+%%
+Hear, O my son, and receive my sayings; and the years of 
+thy life shall be many.
+%%
+Hear, ye children, the instruction of a father, and attend 
+to know understanding.
+%%
+Hear; for I will speak of excellent things; and the opening 
+of my lips shall be right things.
+%%
+Hearken unto me now therefore, O ye children, and attend to 
+the words of my mouth.
+%%
+Hearken unto thy father that begat thee, and despise not 
+thy mother when she is old.
+%%
+Heaviness in the heart of man maketh it stoop: but a good 
+word maketh it glad.
+%%
+Hell and destruction are before the LORD: how much more 
+then the hearts of the children of men? A scorner loveth not 
+one that reproveth him: neither will he go unto the wise.
+%%
+Hell and destruction are never full; so the eyes of man are 
+never satisfied.
+%%
+Hell is empty and all the devils are here.  [The Tempest]
+%%
+Her children arise up, and call her blessed; her husband 
+also, and he praiseth her.
+%%
+Her feet go down to death; her steps take hold on hell.
+%%
+Her house is the way to hell, going down to the chambers of 
+death.
+%%
+Her husband is known in the gates, when he sitteth among 
+the elders of the land.
+%%
+Her ways are ways of pleasantness, and all her paths are 
+peace.
+%%
+His heart was yours from the first moment that you met.
+%%
+His own iniquities shall take the wicked himself, and he 
+shall be holden with the cords of his sins.
+%%
+Histories are fuller of examples of the fidelity of dogs 
+than of friends.
+%%
+Honi soit la vache qui rit.
+%%
+Honour the LORD with thy substance, and with the 
+firstfruits of all thine increase: So shall thy barns be filled with 
+plenty, and thy presses shall burst out with new wine.
+%%
+Hope deferred maketh the heart sick: but when the desire 
+cometh, it is a tree of life.
+%%
+Houdini's escaping from New Jersey!
+%%
+House and riches are the inheritance of fathers: and a 
+prudent wife is from the LORD.
+%%
+How can you work when the system's so crowded?
+%%
+How long wilt thou sleep, O sluggard? when wilt thou arise 
+out of thy sleep? Yet a little sleep, a little slumber, a 
+little folding of the hands to sleep: So shall thy poverty 
+come as one that travelleth, and thy want as an armed man.
+%%
+How many weeks are there in a light year?
+%%
+How much better is it to get wisdom than gold! and to get 
+understanding rather to be chosen than silver! The highway 
+of the upright is to depart from evil: he that keepeth his 
+way preserveth his soul.
+%%
+How sharper than a hound's tooth it is to have a thankless 
+serpent.
+%%
+How wonderful opera would be if there were no singers.
+%%
+How you look depends on where you go.
+%%
+Humility is the first of the virtues -- for other people. 
+-- Oliver W. Holmes
+%%
+I GOTTA GET OUTTA HERE!
+%%
+I am not arguing with you -- I am telling you.
+%%
+I came to MIT to get an education for myself and a diploma 
+for my mother.
+%%
+I hate quotations. -- Ralph Waldo Emerson
+%%
+I have decked my bed with coverings of tapestry, with 
+carved works, with fine linen of Egypt.
+%%
+I have perfumed my bed with myrrh, aloes, and cinnamon.
+%%
+I have taught thee in the way of wisdom; I have led thee in 
+right paths.
+%%
+I lead in the way of righteousness, in the midst of the 
+paths of judgment: That I may cause those that love me to 
+inherit substance; and I will fill their treasures.
+%%
+I like work; it fascinates me; I can sit and look at it for 
+hours.
+%%
+I love them that love me; and those that seek me early 
+shall find me.
+%%
+I must have slipped a disk; my pack hurts.
+%%
+I neither learned wisdom, nor have the knowledge of the 
+holy.
+%%
+I think we're all Bozos on this bus.
+%%
+I was set up from everlasting, from the beginning, or ever 
+the earth was.
+%%
+I went by the field of the slothful, and by the vineyard of 
+the man void of understanding; And, lo, it was all grown 
+over with thorns, and nettles had covered the face thereof, 
+and the stone wall thereof was broken down.
+%%
+I will never lie to you.
+%%
+I wisdom dwell with prudence, and find out knowledge of 
+witty inventions.
+%%
+I wish you humans would leave me alone.
+%%
+I'm a Hollywood writer; so I put on a sports jacket and 
+take off my brain.
+%%
+I'm not sure how to fly this thing, but I'll give it that 
+old college try!
+%%
+I've done so much with so little for so long that I can do 
+anything with nothing.
+%%
+IKM006 4050303293 CHECK/NOCHECK PREFIX NOT PERMITTED IN 
+THIS CONTEXT.
+%%
+IOT trap -- core dumped
+%%
+IOT trap -- mos dumped
+%%
+If God had wanted you to go around nude, He would have 
+given you bigger hands.
+%%
+If a group of N persons implements a COBOL compiler, there 
+will be N-1 passes: Someone in the group has to be the 
+manager.
+%%
+If a listener nods his head when you are explaining your 
+program, wake him up.
+%%
+If a program manipulates large amounts of data, it does so 
+in a small number of ways.
+%%
+If a ruler hearken to lies, all his servants are wicked.
+%%
+If a wise man contendeth with a foolish man, whether he 
+rage or laugh, there is no rest.
+%%
+If at first you don't succeed, get new batteries.
+%%
+If at first you don't succeed, quit; don't be a nut about 
+success.
+%%
+If at first you don't succeed, try, try again.
+%%
+If it doesn't feel good, don't do it.
+%%
+If the auto industry had done what the computer industry 
+has done in the past 30 years, a Rolls Royce would cost $2.50 
+and would get 2,000,000 miles per gallon.
+%%
+If the path be beautiful, let us not ask where it leads. -- 
+Anatole France
+%%
+If they say, Come with us, let us lay wait for blood, let 
+us lurk privily for the innocent without cause: Let us 
+swallow them up alive as the grave; and whole, as those that go 
+down into the pit: We shall find all precious substance, we 
+shall fill our houses with spoil: Cast in thy lot among 
+us; let us all have one purse: My son, walk not thou in the 
+way with them; refrain thy foot from their path: For their 
+feet run to evil, and make haste to shed blood.
+%%
+If thine enemy be hungry, give him bread to eat; and if he 
+be thirsty, give him water to drink: For thou shalt heap 
+coals of fire upon his head, and the LORD shall reward thee.
+%%
+If thou be wise, thou shalt be wise for thyself: but if 
+thou scornest, thou alone shalt bear it.
+%%
+If thou faint in the day of adversity, thy strength is 
+small.
+%%
+If thou forbear to deliver them that are drawn unto death, 
+and those that are ready to be slain; If thou sayest, 
+Behold, we knew it not; doth not he that pondereth the heart 
+consider it? and he that keepeth thy soul, doth not he know 
+it? and shall not he render to every man according to his 
+works? My son, eat thou honey, because it is good; and the 
+honeycomb, which is sweet to thy taste: So shall the knowledge 
+of wisdom be unto thy soul: when thou hast found it, then 
+there shall be a reward, and thy expectation shall not be cut off.
+%%
+If thou hast done foolishly in lifting up thyself, or if 
+thou hast thought evil, lay thine hand upon thy mouth.
+%%
+If thou hast nothing to pay, why should he take away thy 
+bed from under thee? Remove not the ancient landmark, which 
+thy fathers have set.
+%%
+If we knew where we were going to fall, we could have 
+spread a carpet there. -- Russian proverb
+%%
+If you are a rooster, crow; if you are a hen, shut up and 
+lay eggs. -- Russian proverb
+%%
+If you are tired of a friend, lend him money. -- Russian 
+proverb
+%%
+If you ask how much it is, you can't afford it.
+%%
+If you pick up a starving dog and make him prosperous, he 
+will not bite you.  This is the principal difference between 
+a dog and a man. -- Mark Twain
+%%
+If you suspect a man, don't employ him.
+%%
+If you think before you speak the other guy gets his joke 
+in first.
+%%
+If you tickle yourself, you can laugh when you please. -- 
+Russian proverb
+%%
+If you want a fortune, go to a Chinese restaurant.
+%%
+If you want to know how old a man is, ask his 
+brother-in-law.
+%%
+Ignorance is a lack of knowledge.  Stupidity is ignorance 
+with pride.
+%%
+Ignorance is bliss. -- Thomas Gray
+%%
+Ignorance is when you don't know anything and somebody 
+finds it out.
+%%
+Ignore previous fortune.
+%%
+In all labour there is profit: but the talk of the lips 
+tendeth only to penury.
+%%
+In all thy ways acknowledge him, and he shall direct thy 
+paths.
+%%
+In marriage, as in war, it is permitted to take every 
+advantage of the enemy.
+%%
+In the fear of the LORD is strong confidence: and his 
+children shall have a place of refuge.
+%%
+In the first place, God made idiots; this was for practice; 
+then He made school boards. -- Mark Twain
+%%
+In the house of the righteous is much treasure: but in the 
+revenues of the wicked is trouble.
+%%
+In the light of the king's countenance is life; and his 
+favour is as a cloud of the latter rain.
+%%
+In the lips of him that hath understanding wisdom is found: 
+but a rod is for the back of him that is void of 
+understanding.
+%%
+In the mouth of the foolish is a rod of pride: but the lips 
+of the wise shall preserve them.
+%%
+In the multitude of people is the king's honour: but in the 
+want of people is the destruction of the prince.
+%%
+In the multitude of words there wanteth not sin: but he 
+that refraineth his lips is wise.
+%%
+In the transgression of an evil man there is a snare: but 
+the righteous doth sing and rejoice.
+%%
+In the way of righteousness is life: and in the pathway 
+thereof there is no death.
+%%
+In this world, not everyone with a long knife is a cook. -- 
+Russian proverb
+%%
+In this world, truth can wait; she's used to it.
+%%
+In unanimity there is cowardice and uncritical thinking.
+%%
+In wickedness there is a strong strain toward rationality.
+%%
+Institute: An archaic school where football in not taught.
+%%
+Integrity has no need for rules.
+%%
+Iron sharpeneth iron; so a man sharpeneth the countenance 
+of his friend.
+%%
+Is this really happening?
+%%
+It is a bad plan that admits of no modification. -- 
+Publilius Syrus
+%%
+It is a poor judge who cannot award a prize.
+%%
+It is an abomination to kings to commit wickedness: for the 
+throne is established by righteousness.
+%%
+It is an honour for a man to cease from strife: but every 
+fool will be meddling.
+%%
+It is as sport to a fool to do mischief: but a man of 
+understanding hath wisdom.
+%%
+It is better to die on your feet than to live on your 
+knees.
+%%
+It is better to dwell in a corner of the housetop, than 
+with a brawling woman in a wide house.
+%%
+It is better to dwell in the corner of the housetop, than 
+with a brawling woman and in a wide house.
+%%
+It is better to dwell in the wilderness, than with a 
+contentious and an angry woman.
+%%
+It is better to have loved and lost -- much better.
+%%
+It is better to have loved and lost than just to have lost.
+%%
+It is better to wear out than to rust out.
+%%
+It is easier to change the specification to fit the program 
+than vice versa.
+%%
+It is easier to fight for one's principles than to live up 
+to them.
+%%
+It is easier to run down a hill than up one.
+%%
+It is easier to write an incorrect program than to 
+understand a correct one.
+%%
+It is joy to the just to do judgment: but destruction shall 
+be to the workers of iniquity.
+%%
+It is naught, it is naught, saith the buyer: but when he is 
+gone his way, then he boasteth.
+%%
+It is not for kings, O Lemuel, it is not for kings to drink 
+wine; nor for princes strong drink: Lest they drink, and 
+forget the law, and pervert the judgment of any of the 
+afflicted.
+%%
+It is not good to accept the person of the wicked, to 
+overthrow the righteous in judgment.
+%%
+It is not good to eat much honey: so for men to search 
+their own glory is not glory.
+%%
+It is one thing to praise discipline, and another to submit 
+to it.
+%%
+It is the glory of God to conceal a thing: but the honour 
+of kings is to search out a matter.
+%%
+It is the wise bird who builds his nest in a tree.
+%%
+It seems to make an auto driver mad if he misses you.
+%%
+It shall be health to thy navel, and marrow to thy bones.
+%%
+It was a book to kill time for those who liked it better 
+dead.
+%%
+It's a good thing we don't get all the government we pay 
+for.
+%%
+It's a poor workman who blames his tools.
+%%
+It's all in the mind, ya know.
+%%
+It's better to burn out than to fade away.
+%%
+It's later than you think.
+%%
+It's not reality that's important, but how you perceive 
+things.
+%%
+It's not whether you win or lose, but how you play the 
+game. -- Grantland Rice
+%%
+It's pretty hard to tell what does bring happiness; poverty 
+and wealth have both failed.
+%%
+Journalism will kill you, but it will keep you alive while 
+you're at it.
+%%
+Judgments are prepared for scorners, and stripes for the 
+back of fools.
+%%
+Just because the bells are ringing, it is not necessarily 
+dinner time. -- Russian proverb
+%%
+Keep my commandments, and live; and my law as the apple of 
+thine eye.
+%%
+Keep thy heart with all diligence; for out of it are the 
+issues of life.
+%%
+Kiss your keyboard good-bye!
+%%
+LISP: To call a spade a thpade.
+%%
+Labour not to be rich: cease from thine own wisdom.
+%%
+Large numbers of things are determined, and therefore not 
+subject to change.
+%%
+Last guys don't finish nice.
+%%
+Laugh, and the world ignores you.  Crying doesn't help 
+either.
+%%
+Lay not wait, O wicked man, against the dwelling of the 
+righteous; spoil not his resting place: For a just man falleth 
+seven times, and riseth up again: but the wicked shall 
+fall into mischief.
+%%
+Learn good things -- the bad ones will teach you by 
+themselves. -- Russian proverb
+%%
+Learned men are the cisterns of knowledge, not the 
+fountainheads.
+%%
+Lend money to a bad debtor and he will hate you.
+%%
+Length of days is in her right hand; and in her left hand 
+riches and honour.
+%%
+Lest thou shouldest ponder the path of life, her ways are 
+moveable, that thou canst not know them.
+%%
+Let a bear robbed of her whelps meet a man, rather than a 
+fool in his folly.
+%%
+Let a fool hold his tongue and he will pass for a sage.
+%%
+Let another man praise thee, and not thine own mouth; a 
+stranger, and not thine own lips.
+%%
+Let her be as the loving hind and pleasant roe; let her 
+breasts satisfy thee at all times; and be thou ravished always 
+with her love.
+%%
+Let him drink, and forget his poverty, and remember his 
+misery no more.
+%%
+Let him who takes the Plunge remember to return it by 
+Tuesday.
+%%
+Let not mercy and truth forsake thee: bind them about thy 
+neck; write them upon the table of thine heart: So shalt 
+thou find favour and good understanding in the sight of God 
+and man.
+%%
+Let not the sands of time get in your lunch.
+%%
+Let not thine heart decline to her ways, go not astray in 
+her paths.
+%%
+Let not thine heart envy sinners: but be thou in the fear 
+of the LORD all the day long.
+%%
+Let sleeping dogs lie. -- Charles Dickens
+%%
+Let the machine do the dirty work.
+%%
+Let them be only thine own, and not strangers' with thee.
+%%
+Let them not depart from thine eyes; keep them in the midst 
+of thine heart.
+%%
+Let thine eyes look right on, and let thine eyelids look 
+straight before thee.
+%%
+Let thy fountain be blessed: and rejoice with the wife of 
+thy youth.
+%%
+Let thy fountains be dispersed abroad, and rivers of waters 
+in the streets.
+%%
+Let your conscience be your guide. -- Alexander Pope
+%%
+Liar: One who tells an unpleasant truth.
+%%
+Life as we know it doesn't exist.
+%%
+Life is a game of bridge -- and you've just been finessed.
+%%
+Life is full of little surprises, and you are one of them.
+%%
+Life is like a sewer, what you get out of it depends on 
+what you put into it.
+%%
+Life is like an analogy.
+%%
+Life is unbearable, but death is not so pleasant either. -- 
+Russian proverb
+%%
+Like punning, programming is a play on words.
+%%
+Like winter snow on summer lawn, time past is time gone.
+%%
+Live a clean, healthy life and you will soon die of 
+boredom.
+%%
+Live a hundred years, learn a hundred years, and you'll 
+still die a fool. -- Russian proverb
+%%
+Live and scratch -- when you're dead, the itching will 
+stop. -- Russian proverb
+%%
+Logic is a little bird, sitting in a tree, that smells 
+AWFUL.
+%%
+Long computations that yield zero are probably all for 
+naught.
+%%
+Long life is in store for you.
+%%
+Look before you leap. -- Samuel Butler
+%%
+Look not thou upon the wine when it is red, when it giveth 
+his colour in the cup, when it moveth itself aright.
+%%
+Losing your driver's license is just God's way of saying 
+"BOOGA, BOOGA!"
+%%
+Love and scandal are the best sweeteners of tea.
+%%
+Love conquers all things. -- Virgil
+%%
+Love is in the offing, said the homicidal maniac.
+%%
+Love is in the offing.  Be affectionate to one who adores 
+you.
+%%
+Love is the triumph of imagination over intelligence.
+%%
+Love not sleep, lest thou come to poverty; open thine eyes, 
+and thou shalt be satisfied with bread.
+%%
+Love the sea?  I dote upon it -- from the beach.
+%%
+Lust not after her beauty in thine heart; neither let her 
+take thee with her eyelids.
+%%
+Lying lips are abomination to the LORD: but they that deal 
+truly are his delight.
+%%
+Make input easy to proofread.
+%%
+Make it right before you make it faster.
+%%
+Make no friendship with an angry man; and with a furious 
+man thou shalt not go: Lest thou learn his ways, and get a 
+snare to thy soul.
+%%
+Make sure all variables are initialized before use.
+%%
+Make sure comments and code agree.
+%%
+Make sure your code "does nothing" gracefully.
+%%
+Make yourself into a sheep, and you'll meet a wolf nearby. 
+-- Russian proverb
+%%
+Man alone suffers so excruciatingly in the world that he 
+was compelled to invent laughter.
+%%
+Man who falls in blast furnace is certain to feel 
+overwrought.
+%%
+Man who falls in vat of molten optical glass makes 
+spectacle of self.
+%%
+Man's goings are of the LORD; how can a man then understand 
+his own way? It is a snare to the man who devoureth that 
+which is holy, and after vows to make enquiry.
+%%
+Man's horizons are bounded by his vision.
+%%
+Many are called, few are chosen.  Fewer still get to do the 
+choosing.
+%%
+Many are called, few volunteer.
+%%
+Many are cold, but few are frozen.
+%%
+Many daughters have done virtuously, but thou excellest 
+them all.
+%%
+Many pages make a thick book.
+%%
+Many receive advice, few profit from it.
+%%
+Many seek the ruler's favour; but every man's judgment 
+cometh from the LORD.
+%%
+Many will intreat the favour of the prince: and every man 
+is a friend to him that giveth gifts.
+%%
+Marriage -- a three ring circus: engagement ring, wedding 
+ring, and suffering.
+%%
+Marriage is like sneezing: even when you feel it coming on, 
+you can't stop. -- Russian proverb
+%%
+Mathematics deals exclusively with the relations of 
+concepts to each other without consideration of their relation to 
+experience. -- Albert Einstein
+%%
+Memory should be the starting point of the present.
+%%
+Men do not despise a thief, if he steal to satisfy his soul 
+when he is hungry; But if he be found, he shall restore 
+sevenfold; he shall give all the substance of his house.
+%%
+Men have a much better time of it than women; for one 
+thing, they marry later; for another thing, they die earlier.
+%%
+Men love to wonder, and that is the seed of science.
+%%
+Men use thought only to justify their wrong doings, and 
+speech only to conceal their thoughts.
+%%
+Mercy and truth preserve the king: and his throne is 
+upholden by mercy.
+%%
+Might as well be frank, Monsieur.  It would take a miracle 
+to get you out of Casablanca.
+%%
+Mind your own business, Spock.  I'm sick of your half-breed 
+interference.
+%%
+Mistakes are oft the stepping stones to failure.
+%%
+Moderation is a fatal thing.  Nothing succeeds like excess.
+%%
+Modesty is a vastly overrated virtue.
+%%
+Money may buy friendship but money can not buy love.
+%%
+Money will say more in one moment than the most eloquent 
+lover can in years.
+%%
+Most men will proclaim every one his own goodness: but a 
+faithful man who can find? The just man walketh in his 
+integrity: his children are blessed after him.
+%%
+Most people eat as though they were fattening themselves 
+for market.
+%%
+Most people find the concept of programming obvious, but 
+the doing impossible.
+%%
+Much food is in the tillage of the poor: but there is that 
+is destroyed for want of judgment.
+%%
+My fruit is better than gold, yea, than fine gold; and my 
+revenue than choice silver.
+%%
+My opponent's best move is my best move.
+%%
+My son, attend to my words; incline thine ear unto my 
+sayings.
+%%
+My son, attend unto my wisdom, and bow thine ear to my 
+understanding: That thou mayest regard discretion, and that thy 
+lips may keep knowledge.
+%%
+My son, be wise, and make my heart glad, that I may answer 
+him that reproacheth me.
+%%
+My son, despise not the chastening of the LORD; neither be 
+weary of his correction: For whom the LORD loveth he 
+correcteth; even as a father the son in whom he delighteth.
+%%
+My son, fear thou the LORD and the king: and meddle not 
+with them that are given to change: For their calamity shall 
+rise suddenly; and who knoweth the ruin of them both? These 
+things also belong to the wise. It is not good to have 
+respect of persons in judgment.
+%%
+My son, forget not my law; but let thine heart keep my 
+commandments: For length of days, and long life, and peace, 
+shall they add to thee.
+%%
+My son, give me thine heart, and let thine eyes observe my 
+ways.
+%%
+My son, hear the instruction of thy father, and forsake not 
+the law of thy mother: For they shall be an ornament of 
+grace unto thy head, and chains about thy neck.
+%%
+My son, if sinners entice thee, consent thou not.
+%%
+My son, if thine heart be wise, my heart shall rejoice, 
+even mine.
+%%
+My son, if thou be surety for thy friend, if thou hast 
+stricken thy hand with a stranger, Thou art snared with the 
+words of thy mouth, thou art taken with the words of thy mouth.
+%%
+My son, if thou wilt receive my words, and hide my 
+commandments with thee; So that thou incline thine ear unto wisdom, 
+and apply thine heart to understanding; Yea, if thou 
+criest after knowledge, and liftest up thy voice for 
+understanding; If thou seekest her as silver, and searchest for her as 
+for hid treasures; Then shalt thou understand the fear of 
+the LORD, and find the knowledge of God.
+%%
+My son, keep my words, and lay up my commandments with 
+thee.
+%%
+My son, keep thy father's commandment, and forsake not the 
+law of thy mother: Bind them continually upon thine heart, 
+and tie them about thy neck.
+%%
+My son, let not them depart from thine eyes: keep sound 
+wisdom and discretion: So shall they be life unto thy soul, 
+and grace to thy neck.
+%%
+National security is in your hands -- guard it well.
+%%
+Nature teaches beasts to know their friends.
+%%
+Never give an inch!
+%%
+Never insult an alligator until you have crossed the river.
+%%
+Never look a gift horse in the mouth. -- Saint Jerome
+%%
+Never settle with words what you can accomplish with a 
+flame thrower.
+%%
+Never try to teach a pig to sing: it wastes your time and 
+annoys the pig.
+%%
+Nice guys finish last. -- Leo Durocher
+%%
+No amount of genius can overcome a preoccupation with 
+detail.
+%%
+No civilized person ever goes to bed the same day he gets 
+up.
+%%
+No directory.
+%%
+No evil can happen to a good man. -- Plato
+%%
+No one can feel as helpless as the owner of a sick 
+goldfish.
+%%
+No problem is insoluble in all conceivable circumstances.
+%%
+No use beating a dead horse.
+%%
+Noblemen make promises, but peasants have to keep them. -- 
+Russian proverb
+%%
+Nobody can be as agreeable as an uninvited guest.
+%%
+Nobody expects the Spanish Inquisition!
+%%
+None that go unto her return again, neither take they hold 
+of the paths of life.
+%%
+Nothing astonishes men so much as common sense and plain 
+dealing.
+%%
+Nothing endures like change. -- Heraclitus
+%%
+Nothing in life is to be feared.  It is only to be 
+understood.
+%%
+Nothing so needs reforming as other people's habits.
+%%
+Nothing ventured, nothing gained.
+%%
+Nothing will dispel enthusiasm like a small admission fee.
+%%
+Now and then an innocent man is sent to the Legislature.
+%%
+Now therefore hearken unto me, O ye children: for blessed 
+are they that keep my ways.
+%%
+O ye simple, understand wisdom: and, ye fools, be ye of an 
+understanding heart.
+%%
+O'Toole's dictum: "Murphy was an optimist."
+%%
+Observation, not old age, brings wisdom.
+%%
+Of all forms of caution, caution in love is the most fatal.
+%%
+Oh, Aunty Em, it's so good to be home!
+%%
+Oh, what a tangled web we weave when first we practice to 
+conceive.
+%%
+Ointment and perfume rejoice the heart: so doth the 
+sweetness of a man's friend by hearty counsel.
+%%
+Old MacDonald had an agricultural real estate tax 
+abatement.
+%%
+Old soldiers never die.  Young ones do.
+%%
+Once the word is out of your mouth, you can't swallow it 
+back. -- Russian proverb
+%%
+Once you understand how to write a program, get someone 
+else to write it.
+%%
+One Bell System -- it sometimes works.
+%%
+One Bell System -- it works.
+%%
+One man tells a falsehood, a hundred repeat it as true.
+%%
+One man's constant is another man's variable.
+%%
+Only by pride cometh contention: but with the well advised 
+is wisdom.
+%%
+Only presidents, editors, and people with tapeworms have 
+the right to use the editorial "we."
+%%
+Only those who attempt the absurd achieve the impossible.
+%%
+Open thy mouth for the dumb in the cause of all such as are 
+appointed to destruction.
+%%
+Open thy mouth, judge righteously, and plead the cause of 
+the poor and needy.
+%%
+Opportunity knocks but once.
+%%
+Optimization hinders evolution.
+%%
+Out of sight is out of mind.
+%%
+Paranoia doesn't mean the whole world really isn't out to 
+get you.
+%%
+Password:
+%%
+Passwords are implemented as a result of insecurity.
+%%
+People have declaimed against luxury for 2,000 years ... 
+and people have always delighted in it.
+%%
+People who take cat naps don't usually sleep in a cat's 
+cradle.
+%%
+People will buy anything that's one to a customer.
+%%
+Philosophy: Unintelligible answers to insoluble problems.
+%%
+Pleasant words are as an honeycomb, sweet to the soul, and 
+health to the bones.
+%%
+Please go away.
+%%
+Please update your programs.
+%%
+Ponder the path of thy feet, and let all thy ways be 
+established.
+%%
+Poverty and shame shall be to him that refuseth 
+instruction: but he that regardeth reproof shall be honoured.
+%%
+Power is poison.
+%%
+Pray to God, but keep rowing to shore. -- Russian proverb
+%%
+Prepare thy work without, and make it fit for thyself in 
+the field; and afterwards build thine house.
+%%
+Pride goeth before destruction, and an haughty spirit 
+before a fall.
+%%
+Promptness is its own reward, if one lives by the clock 
+instead of the sword.
+%%
+Proud and haughty scorner is his name, who dealeth in proud 
+wrath.
+%%
+Put away from thee a froward mouth, and perverse lips put 
+far from thee.
+%%
+Put not forth thyself in the presence of the king, and 
+stand not in the place of great men: For better it is that it 
+be said unto thee, Come up hither; than that thou shouldest 
+be put lower in the presence of the prince whom thine eyes 
+have seen.
+%%
+Put not your trust in money, but put your money in trust.
+%%
+Quack!
+%%
+Quantity is no substitute for quality, but it's the only 
+one we've got.
+%%
+Quit work and play for once!
+%%
+Rainy days and Mondays always get me down.
+%%
+Reading is thinking with someone else's head instead of 
+one's own.
+%%
+Reality is for people who can't handle drugs.
+%%
+Receive my instruction, and not silver; and knowledge 
+rather than choice gold.
+%%
+Recursion is the root of computation since it trades 
+description for time.
+%%
+Rejoice not when thine enemy falleth, and let not thine 
+heart be glad when he stumbleth: Lest the LORD see it, and it 
+displease him, and he turn away his wrath from him.
+%%
+Religions revolve madly around sexual questions.
+%%
+Remove not the old landmark; and enter not into the fields 
+of the fatherless: For their redeemer is mighty; he shall 
+plead their cause with thee.
+%%
+Remove thy way far from her, and come not nigh the door of 
+her house: Lest thou give thine honour unto others, and thy 
+years unto the cruel: Lest strangers be filled with thy 
+wealth; and thy labours be in the house of a stranger; And 
+thou mourn at the last, when thy flesh and thy body are 
+consumed, And say, How have I hated instruction, and my heart 
+despised reproof; And have not obeyed the voice of my 
+teachers, nor inclined mine ear to them that instructed me! I was 
+almost in all evil in the midst of the congregation and assembly.
+%%
+Replace repetitive expressions by calls to a common 
+function.
+%%
+Reprove not a scorner, lest he hate thee: rebuke a wise 
+man, and he will love thee.
+%%
+Riches and honour are with me; yea, durable riches and 
+righteousness.
+%%
+Riches profit not in the day of wrath: but righteousness 
+delivereth from death.
+%%
+Righteous lips are the delight of kings; and they love him 
+that speaketh right.
+%%
+Righteousness exalteth a nation: but sin is a reproach to 
+any people.
+%%
+Righteousness keepeth him that is upright in the way: but 
+wickedness overthroweth the sinner.
+%%
+Rotten wood can not be carved. -- Confucius
+%%
+Satire does not look pretty upon a tombstone.
+%%
+Save yourself!  Reboot in 5 seconds!
+%%
+Say not thou, I will recompense evil; but wait on the LORD, 
+and he shall save thee.
+%%
+Say not unto thy neighbour, Go, and come again, and to 
+morrow I will give; when thou hast it by thee.
+%%
+Say not, I will do so to him as he hath done to me: I will 
+render to the man according to his work.
+%%
+Say unto wisdom, Thou art my sister; and call understanding 
+thy kinswoman: That they may keep thee from the strange 
+woman, from the stranger which flattereth with her words.
+%%
+Scornful men bring a city into a snare: but wise men turn 
+away wrath.
+%%
+Security is the individual's responsibility.
+%%
+Security is your responsibility.
+%%
+Seest thou a man diligent in his business? he shall stand 
+before kings; he shall not stand before mean men.
+%%
+Seest thou a man that is hasty in his words? there is more 
+hope of a fool than of him.
+%%
+Seest thou a man wise in his own conceit? there is more 
+hope of a fool than of him.
+%%
+She also lieth in wait as for a prey, and increaseth the 
+transgressors among men.
+%%
+She considereth a field, and buyeth it: with the fruit of 
+her hands she planteth a vineyard.
+%%
+She crieth at the gates, at the entry of the city, at the 
+coming in at the doors.
+%%
+She girdeth her loins with strength, and strengtheneth her 
+arms.
+%%
+She hath sent forth her maidens: she crieth upon the 
+highest places of the city, Whoso is simple, let him turn in 
+hither: as for him that wanteth understanding, she saith to 
+him, Come, eat of my bread, and drink of the wine which I have 
+mingled.
+%%
+She is a tree of life to them that lay hold upon her: and 
+happy is every one that retaineth her.
+%%
+She is like the merchants' ships; she bringeth her food 
+from afar.
+%%
+She is more precious than rubies: and all the things thou 
+canst desire are not to be compared unto her.
+%%
+She is not afraid of the snow for her household: for all 
+her household are clothed with scarlet.
+%%
+She layeth her hands to the spindle, and her hands hold the 
+distaff.
+%%
+She looketh well to the ways of her household, and eateth 
+not the bread of idleness.
+%%
+She maketh fine linen, and selleth it; and delivereth 
+girdles unto the merchant.
+%%
+She maketh herself coverings of tapestry; her clothing is 
+silk and purple.
+%%
+She openeth her mouth with wisdom; and in her tongue is the 
+law of kindness.
+%%
+She perceiveth that her merchandise is good: her candle 
+goeth not out by night.
+%%
+She riseth also while it is yet night, and giveth meat to 
+her household, and a portion to her maidens.
+%%
+She seeketh wool, and flax, and worketh willingly with her 
+hands.
+%%
+She shall give to thine head an ornament of grace: a crown 
+of glory shall she deliver to thee.
+%%
+She stretcheth out her hand to the poor; yea, she reacheth 
+forth her hands to the needy.
+%%
+She will do him good and not evil all the days of her life.
+%%
+Simplicity does not precede complexity, but follows it.
+%%
+Sin has many tools, but a lie is the handle that fits them 
+all.
+%%
+Slang is language that takes off its coat, spits on its 
+hands, and goes to work.
+%%
+Slothfulness casteth into a deep sleep; and an idle soul 
+shall suffer hunger.
+%%
+Smile, it makes the world wonder what you are up to.
+%%
+Smite a scorner, and the simple will beware: and reprove 
+one that hath understanding, and he will understand knowledge.
+%%
+Snow Day -- stay home.
+%%
+So are the ways of every one that is greedy of gain; which 
+taketh away the life of the owners thereof.
+%%
+Soap and education are not as sudden as a massacre, but 
+they are more deadly in the long run.
+%%
+Some men are discovered; others are found out.
+%%
+Some programming languages manage to absorb change but 
+withstand progress.
+%%
+Someone is unenthusiastic about your work.
+%%
+Sooner will men hold fire in their mouths than keep a 
+secret.
+%%
+Speak not in the ears of a fool: for he will despise the 
+wisdom of thy words.
+%%
+Stability itself is nothing else than a more sluggish 
+motion.
+%%
+Standing on head makes smile of frown, but rest of face 
+also upside down.
+%%
+Stop searching forever: happiness is just next to you.
+%%
+Stop searching forever: happiness is unattainable.
+%%
+Strength and honour are her clothing; and she shall rejoice 
+in time to come.
+%%
+Strive not with a man without cause, if he have done thee 
+no harm.
+%%
+Sturgeon's Law: Ninety percent of everything is crud.
+%%
+Success is a journey, not a destination.
+%%
+Such is the way of an adulterous woman; she eateth, and 
+wipeth her mouth, and saith, I have done no wickedness.
+%%
+Surely he scorneth the scorners: but he giveth grace unto 
+the lowly.
+%%
+Surely in vain the net is spread in the sight of any bird.
+%%
+Surely the churning of milk bringeth forth butter, and the 
+wringing of the nose bringeth forth blood: so the forcing 
+of wrath bringeth forth strife.
+%%
+System going down at 1:45 this afternoon for disk crashing.
+%%
+System going down indefinitely, please log off!
+%%
+Tact is the art of making a point without making an enemy.
+%%
+Take away the dross from the silver, and there shall come 
+forth a vessel for the finer.
+%%
+Take away the wicked from before the king, and his throne 
+shall be established in righteousness.
+%%
+Take care of the luxuries and the necessities will take 
+care of themselves.
+%%
+Take fast hold of instruction; let her not go: keep her; 
+for she is thy life.
+%%
+Take his garment that is surety for a stranger, and take a 
+pledge of him for a strange woman.
+%%
+Take his garment that is surety for a stranger: and take a 
+pledge of him for a strange woman.
+%%
+That must be wonderful!  I don't understand it at all.
+%%
+That thou mayest walk in the way of good men, and keep the 
+paths of the righteous.
+%%
+That thy trust may be in the LORD, I have made known to 
+thee this day, even to thee.
+%%
+That which is not good for the swarm, neither is it good 
+for the bee.
+%%
+The LORD by wisdom hath founded the earth; by understanding 
+hath he established the heavens.
+%%
+The LORD hath made all things for himself: yea, even the 
+wicked for the day of evil.
+%%
+The LORD is far from the wicked: but he heareth the prayer 
+of the righteous.
+%%
+The LORD possessed me in the beginning of his way, before 
+his works of old.
+%%
+The LORD will destroy the house of the proud: but he will 
+establish the border of the widow.
+%%
+The LORD will not suffer the soul of the righteous to 
+famish: but he casteth away the substance of the wicked.
+%%
+The Tree of Learning bears the noblest fruit, but noble 
+fruit tastes bad.
+%%
+The attacker must vanquish; the defender need only survive.
+%%
+The backslider in heart shall be filled with his own ways: 
+and a good man shall be satisfied from himself.
+%%
+The beginning of strife is as when one letteth out water: 
+therefore leave off contention, before it be meddled with.
+%%
+The best prophet of the future is the past.
+%%
+The blessing of the LORD, it maketh rich, and he addeth no 
+sorrow with it.
+%%
+The bloodthirsty hate the upright: but the just seek his 
+soul.
+%%
+The blueness of a wound cleanseth away evil: so do stripes 
+the inward parts of the belly.
+%%
+The cow may be black, but the milk comes out white. -- 
+Russian proverb
+%%
+The crown of the wise is their riches: but the foolishness 
+of fools is folly.
+%%
+The curse of the LORD is in the house of the wicked: but he 
+blesseth the habitation of the just.
+%%
+The decision doesn't have to be logical, it was unanimous.
+%%
+The degree of civilization in a society can be judged by 
+entering its prisons.
+%%
+The desire accomplished is sweet to the soul: but it is 
+abomination to fools to depart from evil.
+%%
+The desire of a man is his kindness: and a poor man is 
+better than a liar.
+%%
+The desire of the righteous is only good: but the 
+expectation of the wicked is wrath.
+%%
+The desire of the slothful killeth him; for his hands 
+refuse to labour.
+%%
+The discretion of a man deferreth his anger; and it is his 
+glory to pass over a transgression.
+%%
+The door is the key.
+%%
+The ear that heareth the reproof of life abideth among the 
+wise.
+%%
+The early worm gets the bird.
+%%
+The end of labor is to gain leisure.
+%%
+The ends justify the means.
+%%
+The evil bow before the good; and the wicked at the gates 
+of the righteous.
+%%
+The eye that mocketh at his father, and despiseth to obey 
+his mother, the ravens of the valley shall pick it out, and 
+the young eagles shall eat it.
+%%
+The eyes of the LORD are in every place, beholding the evil 
+and the good.
+%%
+The eyes of the LORD preserve knowledge, and he 
+overthroweth the words of the transgressor.
+%%
+The famous politician was trying to save both his faces.
+%%
+The father of the righteous shall greatly rejoice: and he 
+that begetteth a wise child shall have joy of him.
+%%
+The fear of a king is as the roaring of a lion: whoso 
+provoketh him to anger sinneth against his own soul.
+%%
+The fear of man bringeth a snare: but whoso putteth his 
+trust in the LORD shall be safe.
+%%
+The fear of the LORD is a fountain of life, to depart from 
+the snares of death.
+%%
+The fear of the LORD is the beginning of knowledge: but 
+fools despise wisdom and instruction.
+%%
+The fear of the LORD is the beginning of wisdom: and the 
+knowledge of the holy is understanding.
+%%
+The fear of the LORD is the instruction of wisdom; and 
+before honour is humility.
+%%
+The fear of the LORD is to hate evil: pride, and arrogancy, 
+and the evil way, and the froward mouth, do I hate.
+%%
+The fear of the LORD prolongeth days: but the years of the 
+wicked shall be shortened.
+%%
+The fear of the LORD tendeth to life: and he that hath it 
+shall abide satisfied; he shall not be visited with evil.
+%%
+The fear of the wicked, it shall come upon him: but the 
+desire of the righteous shall be granted.
+%%
+The finest eloquence is that which gets things done.
+%%
+The fining pot is for silver, and the furnace for gold: but 
+the LORD trieth the hearts.
+%%
+The following statement is not true:
+%%
+The foolishness of man perverteth his way: and his heart 
+fretteth against the LORD.
+%%
+The fruit of the righteous is a tree of life; and he that 
+winneth souls is wise.
+%%
+The full soul loatheth an honeycomb; but to the hungry soul 
+every bitter thing is sweet.
+%%
+The future is his who knows how to wait. -- Russian proverb
+%%
+The future isn't what it used to be.  It never was.
+%%
+The gentlemen looked one another over with microscopic 
+carelessness.
+%%
+The getting of treasures by a lying tongue is a vanity 
+tossed to and fro of them that seek death.
+%%
+The glory of young men is their strength: and the beauty of 
+old men is the grey head.
+%%
+The great God that formed all things both rewardeth the 
+fool, and rewardeth transgressors.
+%%
+The greatest of faults is to be conscious of none.
+%%
+The hand of the diligent shall bear rule: but the slothful 
+shall be under tribute.
+%%
+The hearing ear, and the seeing eye, the LORD hath made 
+even both of them.
+%%
+The heart knoweth his own bitterness; and a stranger doth 
+not intermeddle with his joy.
+%%
+The heart of her husband doth safely trust in her, so that 
+he shall have no need of spoil.
+%%
+The heart of him that hath understanding seeketh knowledge: 
+but the mouth of fools feedeth on foolishness.
+%%
+The heart of the righteous studieth to answer: but the 
+mouth of the wicked poureth out evil things.
+%%
+The heart of the wise teacheth his mouth, and addeth 
+learning to his lips.
+%%
+The heaven for height, and the earth for depth, and the 
+heart of kings is unsearchable.
+%%
+The hoary head is a crown of glory, if it be found in the 
+way of righteousness.
+%%
+The hope of the righteous shall be gladness: but the 
+expectation of the wicked shall perish.
+%%
+The horse is prepared against the day of battle: but safety 
+is of the LORD.
+%%
+The horseleach hath two daughters, crying, Give, give. 
+There are three things that are never satisfied, yea, four 
+things say not, It is enough: The grave; and the barren womb; 
+the earth that is not filled with water; and the fire that 
+saith not, It is enough.
+%%
+The house of the wicked shall be overthrown: but the 
+tabernacle of the upright shall flourish.
+%%
+The important thing is not to stop questioning.
+%%
+The integrity of the upright shall guide them: but the 
+perverseness of transgressors shall destroy them.
+%%
+The king by judgment establisheth the land: but he that 
+receiveth gifts overthroweth it.
+%%
+The king that faithfully judgeth the poor, his throne shall 
+be established for ever.
+%%
+The king's favour is toward a wise servant: but his wrath 
+is against him that causeth shame.
+%%
+The king's heart is in the hand of the LORD, as the rivers 
+of water: he turneth it whithersoever he will.
+%%
+The king's wrath is as the roaring of a lion; but his 
+favour is as dew upon the grass.
+%%
+The labour of the righteous tendeth to life: the fruit of 
+the wicked to sin.
+%%
+The lambs are for thy clothing, and the goats are the price 
+of the field.
+%%
+The law of the wise is a fountain of life, to depart from 
+the snares of death.
+%%
+The legs of the lame are not equal: so is a parable in the 
+mouth of fools.
+%%
+The liberal soul shall be made fat: and he that watereth 
+shall be watered also himself.
+%%
+The life that is unexamined is not worth living.
+%%
+The light of the eyes rejoiceth the heart: and a good 
+report maketh the bones fat.
+%%
+The light of the righteous rejoiceth: but the lamp of the 
+wicked shall be put out.
+%%
+The lip of truth shall be established for ever: but a lying 
+tongue is but for a moment.
+%%
+The lips of the righteous feed many: but fools die for want 
+of wisdom.
+%%
+The lips of the righteous know what is acceptable: but the 
+mouth of the wicked speaketh frowardness.
+%%
+The lips of the wise disperse knowledge: but the heart of 
+the foolish doeth not so.
+%%
+The lot causeth contentions to cease, and parteth between 
+the mighty.
+%%
+The lot is cast into the lap; but the whole disposing 
+thereof is of the LORD.
+%%
+The man that wandereth out of the way of understanding 
+shall remain in the congregation of the dead.
+%%
+The man who makes no mistakes does not usually make 
+anything.
+%%
+The memory of the just is blessed: but the name of the 
+wicked shall rot.
+%%
+The merciful man doeth good to his own soul: but he that is 
+cruel troubleth his own flesh.
+%%
+The more things change, the more they remain the same.
+%%
+The morsel which thou hast eaten shalt thou vomit up, and 
+lose thy sweet words.
+%%
+The mouth of a righteous man is a well of life: but 
+violence covereth the mouth of the wicked.
+%%
+The mouth of strange women is a deep pit: he that is 
+abhorred of the LORD shall fall therein.
+%%
+The mouth of the just bringeth forth wisdom: but the 
+froward tongue shall be cut out.
+%%
+The name of the LORD is a strong tower: the righteous 
+runneth into it, and is safe.
+%%
+The north wind driveth away rain: so doth an angry 
+countenance a backbiting tongue.
+%%
+The only difference between a rut and a grave is their 
+size.
+%%
+The only thing to do with good advice is pass it on.  It is 
+never any use to oneself.
+%%
+The only way to amuse some people is to slip and fall on an 
+icy pavement.
+%%
+The plural of spouse is spice.
+%%
+The poor and the deceitful man meet together: the LORD 
+lighteneth both their eyes.
+%%
+The poor is hated even of his own neighbour: but the rich 
+hath many friends.
+%%
+The poor useth intreaties; but the rich answereth roughly.
+%%
+The preparations of the heart in man, and the answer of the 
+tongue, is from the LORD.
+%%
+The price of greatness is responsibility.
+%%
+The prince that wanteth understanding is also a great 
+oppressor: but he that hateth covetousness shall prolong his 
+days.
+%%
+The program is absolutely right; therefore the computer 
+must be wrong.
+%%
+The proverbs of Solomon the son of David, king of Israel; 
+To know wisdom and instruction; to perceive the words of 
+understanding; To receive the instruction of wisdom, justice, 
+and judgment, and equity; To give subtilty to the simple, 
+to the young man knowledge and discretion.
+%%
+The proverbs of Solomon. A wise son maketh a glad father: 
+but a foolish son is the heaviness of his mother.
+%%
+The ransom of a man's life are his riches: but the poor 
+heareth not rebuke.
+%%
+The rich and poor meet together: the LORD is the maker of 
+them all.
+%%
+The rich man is wise in his own conceit; but the poor that 
+hath understanding searcheth him out.
+%%
+The rich man's wealth is his strong city, and as an high 
+wall in his own conceit.
+%%
+The rich man's wealth is his strong city: the destruction 
+of the poor is their poverty.
+%%
+The rich ruleth over the poor, and the borrower is servant 
+to the lender.
+%%
+The righteous considereth the cause of the poor: but the 
+wicked regardeth not to know it.
+%%
+The righteous eateth to the satisfying of his soul: but the 
+belly of the wicked shall want.
+%%
+The righteous is delivered out of trouble, and the wicked 
+cometh in his stead.
+%%
+The righteous is more excellent than his neighbour: but the 
+way of the wicked seduceth them.
+%%
+The righteous man wisely considereth the house of the 
+wicked: but God overthroweth the wicked for their wickedness.
+%%
+The righteous shall never be removed: but the wicked shall 
+not inhabit the earth.
+%%
+The righteousness of the perfect shall direct his way: but 
+the wicked shall fall by his own wickedness.
+%%
+The righteousness of the upright shall deliver them: but 
+transgressors shall be taken in their own naughtiness.
+%%
+The road to ruin is always in good repair, and the 
+travelers pay the expense of it.
+%%
+The robbery of the wicked shall destroy them; because they 
+refuse to do judgment.
+%%
+The rod and reproof give wisdom: but a child left to 
+himself bringeth his mother to shame.
+%%
+The sacrifice of the wicked is abomination: how much more, 
+when he bringeth it with a wicked mind? A false witness 
+shall perish: but the man that heareth speaketh constantly.
+%%
+The sacrifice of the wicked is an abomination to the LORD: 
+but the prayer of the upright is his delight.
+%%
+The shortage will be divided among the poor. -- Russian 
+proverb
+%%
+The simple believeth every word: but the prudent man 
+looketh well to his going.
+%%
+The simple inherit folly: but the prudent are crowned with 
+knowledge.
+%%
+The slothful hideth his hand in his bosom; it grieveth him 
+to bring it again to his mouth.
+%%
+The slothful man roasteth not that which he took in 
+hunting: but the substance of a diligent man is precious.
+%%
+The slothful man saith, There is a lion in the way; a lion 
+is in the streets.
+%%
+The slothful man saith, There is a lion without, I shall be 
+slain in the streets.
+%%
+The slower you drive, the farther you get. -- Russian 
+proverb
+%%
+The sluggard is wiser in his own conceit than seven men 
+that can render a reason.
+%%
+The sluggard will not plow by reason of the cold; therefore 
+shall he beg in harvest, and have nothing.
+%%
+The soul of the sluggard desireth, and hath nothing: but 
+the soul of the diligent shall be made fat.
+%%
+The soul of the wicked desireth evil: his neighbour findeth 
+no favour in his eyes.
+%%
+The soul would have no rainbow had the eyes no tears.
+%%
+The spirit of a man will sustain his infirmity; but a 
+wounded spirit who can bear? The heart of the prudent getteth 
+knowledge; and the ear of the wise seeketh knowledge.
+%%
+The spirit of man is the candle of the LORD, searching all 
+the inward parts of the belly.
+%%
+The sun never sets on the British Empire because the 
+British are scared of the dark.
+%%
+The thought of foolishness is sin: and the scorner is an 
+abomination to men.
+%%
+The thoughts of the diligent tend only to plenteousness; 
+but of every one that is hasty only to want.
+%%
+The thoughts of the righteous are right: but the counsels 
+of the wicked are deceit.
+%%
+The thoughts of the wicked are an abomination to the LORD: 
+but the words of the pure are pleasant words.
+%%
+The time is right to make new friends.
+%%
+The tongue of the just is as choice silver: the heart of 
+the wicked is little worth.
+%%
+The tongue of the wise useth knowledge aright: but the 
+mouth of fools poureth out foolishness.
+%%
+The universe is laughing behind your back.
+%%
+The way of a fool is right in his own eyes: but he that 
+hearkeneth unto counsel is wise.
+%%
+The way of man is froward and strange: but as for the pure, 
+his work is right.
+%%
+The way of the LORD is strength to the upright: but 
+destruction shall be to the workers of iniquity.
+%%
+The way of the slothful man is as an hedge of thorns: but 
+the way of the righteous is made plain.
+%%
+The way of the wicked is an abomination unto the LORD: but 
+he loveth him that followeth after righteousness.
+%%
+The way of the wicked is as darkness: they know not at what 
+they stumble.
+%%
+The wicked are overthrown, and are not: but the house of 
+the righteous shall stand.
+%%
+The wicked desireth the net of evil men: but the root of 
+the righteous yieldeth fruit.
+%%
+The wicked flee when no man pursueth: but the righteous are 
+bold as a lion.
+%%
+The wicked is driven away in his wickedness: but the 
+righteous hath hope in his death.
+%%
+The wicked is snared by the transgression of his lips: but 
+the just shall come out of trouble.
+%%
+The wicked shall be a ransom for the righteous, and the 
+transgressor for the upright.
+%%
+The wicked worketh a deceitful work: but to him that soweth 
+righteousness shall be a sure reward.
+%%
+The wisdom of the prudent is to understand his way: but the 
+folly of fools is deceit.
+%%
+The wise in heart shall be called prudent: and the 
+sweetness of the lips increaseth learning.
+%%
+The wise in heart will receive commandments: but a prating 
+fool shall fall.
+%%
+The wise shall inherit glory: but shame shall be the 
+promotion of fools.
+%%
+The wise shepherd never trusts his flock to a smiling wolf.
+%%
+The words of Agur the son of Jakeh, even the prophecy: the 
+man spake unto Ithiel, even unto Ithiel and Ucal, Surely I 
+am more brutish than any man, and have not the 
+understanding of a man.
+%%
+The words of a man's mouth are as deep waters, and the 
+wellspring of wisdom as a flowing brook.
+%%
+The words of a talebearer are as wounds, and they go down 
+into the innermost parts of the belly.
+%%
+The words of a talebearer are as wounds, and they go down 
+into the innermost parts of the belly.
+%%
+The words of king Lemuel, the prophecy that his mother 
+taught him.
+%%
+The words of the wicked are to lie in wait for blood: but 
+the mouth of the upright shall deliver them.
+%%
+The world is coming to an end ...  SAVE YOUR BUFFERS!!!
+%%
+The wrath of a king is as messengers of death: but a wise 
+man will pacify it.
+%%
+Then I saw, and considered it well: I looked upon it, and 
+received instruction.
+%%
+Then shall they call upon me, but I will not answer; they 
+shall seek me early, but they shall not find me: For that 
+they hated knowledge, and did not choose the fear of the 
+LORD: They would none of my counsel: they despised all my reproof.
+%%
+Then shalt thou understand righteousness, and judgment, and 
+equity; yea, every good path.
+%%
+Then shalt thou walk in thy way safely, and thy foot shall 
+not stumble.
+%%
+There are many devices in a man's heart; nevertheless the 
+counsel of the LORD, that shall stand.
+%%
+There are more old drunkards than old doctors.
+%%
+There are more things in heaven and earth than are dreamt 
+of ... in either.
+%%
+There are people so addicted to exaggeration that they 
+can't tell the truth without lying.
+%%
+There be four things which are little upon the earth, but 
+they are exceeding wise: The ants are a people not strong, 
+yet they prepare their meat in the summer; The conies are 
+but a feeble folk, yet make they their houses in the rocks; 
+The locusts have no king, yet go they forth all of them by 
+bands; The spider taketh hold with her hands, and is in 
+kings' palaces.
+%%
+There be three things which are too wonderful for me, yea, 
+four which I know not: The way of an eagle in the air; the 
+way of a serpent upon a rock; the way of a ship in the 
+midst of the sea; and the way of a man with a maid.
+%%
+There be three things which go well, yea, four are comely 
+in going: A lion which is strongest among beasts, and 
+turneth not away for any; A greyhound; an he goat also; and a 
+king, against whom there is no rising up.
+%%
+There is a generation that are pure in their own eyes, and 
+yet is not washed from their filthiness.
+%%
+There is a generation that curseth their father, and doth 
+not bless their mother.
+%%
+There is a generation, O how lofty are their eyes! and 
+their eyelids are lifted up.
+%%
+There is a generation, whose teeth are as swords, and their 
+jaw teeth as knives, to devour the poor from off the 
+earth, and the needy from among men.
+%%
+There is a way that seemeth right unto a man, but the end 
+thereof are the ways of death.
+%%
+There is a way which seemeth right unto a man, but the end 
+thereof are the ways of death.
+%%
+There is gold, and a multitude of rubies: but the lips of 
+knowledge are a precious jewel.
+%%
+There is no distinctly native American criminal class 
+except Congress. -- Mark Twain
+%%
+There is no heavier burden than a great potential.
+%%
+There is no proverb that is not true. -- Cervantes
+%%
+There is no sadder sight than a young pessimist.
+%%
+There is no sin but ignorance. -- Christopher Marlowe
+%%
+There is no such thing as pure pleasure; some anxiety 
+always goes with it.
+%%
+There is no time like the pleasant.
+%%
+There is no wisdom nor understanding nor counsel against 
+the LORD.
+%%
+There is that maketh himself rich, yet hath nothing: there 
+is that maketh himself poor, yet hath great riches.
+%%
+There is that scattereth, and yet increaseth; and there is 
+that withholdeth more than is meet, but it tendeth to 
+poverty.
+%%
+There is that speaketh like the piercings of a sword: but 
+the tongue of the wise is health.
+%%
+There is treasure to be desired and oil in the dwelling of 
+the wise; but a foolish man spendeth it up.
+%%
+There never was a good war or a bad peace.
+%%
+There shall no evil happen to the just: but the wicked 
+shall be filled with mischief.
+%%
+There's got to be more to life than compile-and-go.
+%%
+There's never time to do the job right, so we must find 
+time to do it again.
+%%
+There's no room in the drug world for amateurs.
+%%
+There's so much to say but your eyes keep interrupting me.
+%%
+Therefore came I forth to meet thee, diligently to seek thy 
+face, and I have found thee.
+%%
+Therefore shall his calamity come suddenly; suddenly shall 
+he be broken without remedy.
+%%
+Therefore shall they eat of the fruit of their own way, and 
+be filled with their own devices.
+%%
+These are also proverbs of Solomon, which the men of 
+Hezekiah king of Judah copied out.
+%%
+These six things doth the LORD hate: yea, seven are an 
+abomination unto him: A proud look, a lying tongue, and hands 
+that shed innocent blood, An heart that deviseth wicked 
+imaginations, feet that be swift in running to mischief, A 
+false witness that speaketh lies, and he that soweth discord 
+among brethren.
+%%
+They are all plain to him that understandeth, and right to 
+them that find knowledge.
+%%
+They have stricken me, shalt thou say, and I was not sick; 
+they have beaten me, and I felt it not: when shall I awake? 
+I will seek it yet again.
+%%
+They that are of a froward heart are abomination to the 
+LORD: but such as are upright in their way are his delight.
+%%
+They that forsake the law praise the wicked: but such as 
+keep the law contend with them.
+%%
+Thine eyes shall behold strange women, and thine heart 
+shall utter perverse things.
+%%
+Thine own friend, and thy father's friend, forsake not; 
+neither go into thy brother's house in the day of thy 
+calamity: for better is a neighbour that is near than a brother far 
+off.
+%%
+This fortune is inoperative.  Please try another.
+%%
+This is a good time to punt work.
+%%
+This login session: $13.99
+%%
+This screen intentionally left blank.
+%%
+Thorns and snares are in the way of the froward: he that 
+doth keep his soul shall be far from them.
+%%
+Those of you who think you know everything are very 
+annoying to us who do.
+%%
+Those who can, do.  Those who can't, program.
+%%
+Those who can, do.  Those who can't, simulate.
+%%
+Those who can, do.  Those who can't, teach.  Those who 
+can't teach, HACK!
+%%
+Those who in quarrels interpose must often wipe a bloody 
+nose.
+%%
+Those who talk, don't know.  Those who don't talk, know.
+%%
+Thou shalt beat him with the rod, and shalt deliver his 
+soul from hell.
+%%
+Though hand join in hand, the wicked shall not be 
+unpunished: but the seed of the righteous shall be delivered.
+%%
+Though this be madness, yet there is method in 't. -- 
+William Shakespeare
+%%
+Though thou shouldest bray a fool in a mortar among wheat 
+with a pestle, yet will not his foolishness depart from him.
+%%
+Through desire a man, having separated himself, seeketh and 
+intermeddleth with all wisdom.
+%%
+Through wisdom is an house builded; and by understanding it 
+is established: And by knowledge shall the chambers be 
+filled with all precious and pleasant riches.
+%%
+Thy father and thy mother shall be glad, and she that bare 
+thee shall rejoice.
+%%
+Time and tide wait for no man.
+%%
+Time flies when you don't know what you're doing.
+%%
+Time for lunch!
+%%
+Time is but the stream I go a-fishing in.
+%%
+Time is nature's way of making sure that everything doesn't 
+happen at once.
+%%
+To be great is to be misunderstood.
+%%
+To criticize the incompetent is easy; it is more difficult 
+to criticize the competent.
+%%
+To do justice and judgment is more acceptable to the LORD 
+than sacrifice.
+%%
+To each his own and to you so long.
+%%
+To have a sense of humor is to be a tragic figure.
+%%
+To have respect of persons is not good: for for a piece of 
+bread that man will transgress.
+%%
+To iterate is human, to recurse, divine.
+%%
+To know thyself is the ultimate form of aggression.
+%%
+To laugh at men of sense is the privilege of fools.
+%%
+To teach is to learn.
+%%
+To understand a program you must become both the machine 
+and the program.
+%%
+Today is a good day to bribe a high-ranking public 
+official.
+%%
+Today is the last day of your life so far.
+%%
+Too clever is dumb. -- Ogden Nash
+%%
+Toto, I have a feeling we're not in Kansas any more!
+%%
+Train up a child in the way he should go: and when he is 
+old, he will not depart from it.
+%%
+Treasures of wickedness profit nothing: but righteousness 
+delivereth from death.
+%%
+Troubles are like babies; they only grow by nursing.
+%%
+Trust in Allah, but tie your camel anyway.
+%%
+Trust in the LORD with all thine heart; and lean not unto 
+thine own understanding.
+%%
+Truthful: Dumb and illiterate.
+%%
+Try "stty 0" -- it works much better.
+%%
+Try the Moo Shu Pork.  It is especially good today.
+%%
+Try to divide your time evenly to keep others happy.
+%%
+Trying to get an education here is like trying to take a 
+drink from a fire hose.
+%%
+Turn not to the right hand nor to the left: remove thy foot 
+from evil.
+%%
+Turn the other cheek. -- Jesus Christ
+%%
+Two men look out through the same bars; one sees mud, and 
+one the stars.
+%%
+Two things have I required of thee; deny me them not before 
+I die: Remove far from me vanity and lies: give me neither 
+poverty nor riches; feed me with food convenient for me: 
+Lest I be full, and deny thee, and say, Who is the LORD? or 
+lest I be poor, and steal, and take the name of my God in vain.
+%%
+Understanding is a wellspring of life unto him that hath 
+it: but the instruction of fools is folly.
+%%
+Unix soit qui mal y pense.
+%%
+Unquestionably, there is progress.  The average American 
+now pays out twice as much in taxes as he formerly got in 
+wages.
+%%
+Unto you, O men, I call; and my voice is to the sons of 
+man.
+%%
+Use GOTOs only to implement a fundamental structure.
+%%
+Use IF...ELSE  IF...ELSE  IF...ELSE... to implement 
+multi-way branches.
+%%
+Use debugging compilers.
+%%
+Use free-form input where possible.
+%%
+Use library functions.
+%%
+Vests are to suits as seat-belts are to cars.
+%%
+Volcano -- a mountain with hiccups.
+%%
+Wag your tongue as much as you please, but don't wave your 
+gun. -- Russian proverb
+%%
+Walk softly and carry a big stick. -- Theodore Roosevelt
+%%
+Wash a pig as much as you like, it'll go right back into 
+the mud puddle. -- Russian proverb
+%%
+Waste not, get your budget cut next year.
+%%
+Watch out for off-by-one errors.
+%%
+We all know that no one understands anything that isn't 
+funny.
+%%
+We always might win ... because the others might lose.
+%%
+We are all related: the same sun dries our rags. -- Russian 
+proverb
+%%
+We are always the same age inside.
+%%
+We could do that, but it would be wrong, that's for sure.
+%%
+We give advice, but we cannot give the wisdom to profit by 
+it.
+%%
+We learn from history that we do not learn anything from 
+history.
+%%
+We must remember the First Amendment which protects any 
+shrill jackass no matter how self-seeking.
+%%
+Wealth gotten by vanity shall be diminished: but he that 
+gathereth by labour shall increase.
+%%
+Wealth maketh many friends; but the poor is separated from 
+his neighbour.
+%%
+What garlic is to salad, insanity is to art.
+%%
+What good is honor on an empty stomach? -- Russian proverb
+%%
+What is wanted is not the will-to-believe, but the 
+wish-to-find-out, which are exact opposites.
+%%
+What sin has not been committed in the name of efficiency?
+%%
+What this country needs is a good five cent microcomputer.
+%%
+What you don't know can't hurt you.
+%%
+What, my son? and what, the son of my womb? and what, the 
+son of my vows? Give not thy strength unto women, nor thy 
+ways to that which destroyeth kings.
+%%
+When a man assumes a public trust, he should consider 
+himself as public property. -- Thomas Jefferson
+%%
+When a man's ways please the LORD, he maketh even his 
+enemies to be at peace with him.
+%%
+When a wicked man dieth, his expectation shall perish: and 
+the hope of unjust men perisheth.
+%%
+When choosing between two evils, always try the one you 
+have never tried before.
+%%
+When he prepared the heavens, I was there: when he set a 
+compass upon the face of the depth: When he established the 
+clouds above: when he strengthened the fountains of the 
+deep: When he gave to the sea his decree, that the waters 
+should not pass his commandment: when he appointed the 
+foundations of the earth: Then I was by him, as one brought up with 
+him: and I was daily his delight, rejoicing always before 
+him; Rejoicing in the habitable part of his earth; and my 
+delights were with the sons of men.
+%%
+When in charge, ponder; when in doubt, mumble; when in 
+trouble, delegate.
+%%
+When in doubt, lead trump.
+%%
+When it goeth well with the righteous, the city rejoiceth: 
+and when the wicked perish, there is shouting.
+%%
+When pride cometh, then cometh shame: but with the lowly is 
+wisdom.
+%%
+When righteous men do rejoice, there is great glory: but 
+when the wicked rise, a man is hidden.
+%%
+When the righteous are in authority, the people rejoice: 
+but when the wicked beareth rule, the people mourn.
+%%
+When the scorner is punished, the simple is made wise: and 
+when the wise is instructed, he receiveth knowledge.
+%%
+When the sheath is broken, you can't hide the sword. -- 
+Russian proverb
+%%
+When the wicked are multiplied, transgression increaseth: 
+but the righteous shall see their fall.
+%%
+When the wicked cometh, then cometh also contempt, and with 
+ignominy reproach.
+%%
+When the wicked rise, men hide themselves: but when they 
+perish, the righteous increase.
+%%
+When the wind is great, bow before it; when the wind is 
+heavy, yield to it.
+%%
+When there were no depths, I was brought forth; when there 
+were no fountains abounding with water.
+%%
+When thou goest, it shall lead thee; when thou sleepest, it 
+shall keep thee; and when thou awakest, it shall talk with 
+thee.
+%%
+When thou goest, thy steps shall not be straitened; and 
+when thou runnest, thou shalt not stumble.
+%%
+When thou liest down, thou shalt not be afraid: yea, thou 
+shalt lie down, and thy sleep shall be sweet.
+%%
+When thou sittest to eat with a ruler, consider diligently 
+what is before thee: And put a knife to thy throat, if thou 
+be a man given to appetite.
+%%
+When we write programs that "learn," it turns out that we 
+do and they don't.
+%%
+When wisdom entereth into thine heart, and knowledge is 
+pleasant unto thy soul; Discretion shall preserve thee, 
+understanding shall keep thee: To deliver thee from the way of 
+the evil man, from the man that speaketh froward things; Who 
+leave the paths of uprightness, to walk in the ways of 
+darkness; Who rejoice to do evil, and delight in the 
+frowardness of the wicked; Whose ways are crooked, and they froward 
+in their paths: To deliver thee from the strange woman, even 
+from the stranger which flattereth with her words; Which 
+forsaketh the guide of her youth, and forgetteth the 
+covenant of her God.
+%%
+When you live close to the graveyard, you can't weep for 
+every funeral. -- Russian proverb
+%%
+When your only tool is a hammer, you tend to treat 
+everything you find like a nail.
+%%
+Where no counsel is, the people fall: but in the multitude 
+of counsellors there is safety.
+%%
+Where no oxen are, the crib is clean: but much increase is 
+by the strength of the ox.
+%%
+Where the system is concerned, you're not allowed to ask 
+"Why?".
+%%
+Where there is no vision, the people perish: but he that 
+keepeth the law, happy is he.
+%%
+Wherefore is there a price in the hand of a fool to get 
+wisdom, seeing he hath no heart to it? A friend loveth at all 
+times, and a brother is born for adversity.
+%%
+Who are you?
+%%
+Who can find a virtuous woman? for her price is far above 
+rubies.
+%%
+Who can say, I have made my heart clean, I am pure from my 
+sin? Divers weights, and divers measures, both of them are 
+alike abomination to the LORD.
+%%
+Who hath ascended up into heaven, or descended? who hath 
+gathered the wind in his fists? who hath bound the waters in 
+a garment? who hath established all the ends of the earth? 
+what is his name, and what is his son's name, if thou canst 
+tell? Every word of God is pure: he is a shield unto them 
+that put their trust in him.
+%%
+Who hath woe? who hath sorrow? who hath contentions? who 
+hath babbling? who hath wounds without cause? who hath 
+redness of eyes? They that tarry long at the wine; they that go 
+to seek mixed wine.
+%%
+Whose hatred is covered by deceit, his wickedness shall be 
+shewed before the whole congregation.
+%%
+Whoso boasteth himself of a false gift is like clouds and 
+wind without rain.
+%%
+Whoso causeth the righteous to go astray in an evil way, he 
+shall fall himself into his own pit: but the upright shall 
+have good things in possession.
+%%
+Whoso curseth his father or his mother, his lamp shall be 
+put out in obscure darkness.
+%%
+Whoso despiseth the word shall be destroyed: but he that 
+feareth the commandment shall be rewarded.
+%%
+Whoso diggeth a pit shall fall therein: and he that rolleth 
+a stone, it will return upon him.
+%%
+Whoso findeth a wife findeth a good thing, and obtaineth 
+favour of the LORD.
+%%
+Whoso is partner with a thief hateth his own soul: he 
+heareth cursing, and bewrayeth it not.
+%%
+Whoso keepeth his mouth and his tongue keepeth his soul 
+from troubles.
+%%
+Whoso keepeth the fig tree shall eat the fruit thereof: so 
+he that waiteth on his master shall be honoured.
+%%
+Whoso keepeth the law is a wise son: but he that is a 
+companion of riotous men shameth his father.
+%%
+Whoso loveth instruction loveth knowledge: but he that 
+hateth reproof is brutish.
+%%
+Whoso loveth wisdom rejoiceth his father: but he that 
+keepeth company with harlots spendeth his substance.
+%%
+Whoso mocketh the poor reproacheth his Maker: and he that 
+is glad at calamities shall not be unpunished.
+%%
+Whoso rewardeth evil for good, evil shall not depart from 
+his house.
+%%
+Whoso robbeth his father or his mother, and saith, It is no 
+transgression; the same is the companion of a destroyer.
+%%
+Whoso stoppeth his ears at the cry of the poor, he also 
+shall cry himself, but shall not be heard.
+%%
+Whoso walketh uprightly shall be saved: but he that is 
+perverse in his ways shall fall at once.
+%%
+Whosoever hideth her hideth the wind, and the ointment of 
+his right hand, which bewrayeth itself.
+%%
+Wilt thou set thine eyes upon that which is not? for riches 
+certainly make themselves wings; they fly away as an eagle 
+toward heaven.
+%%
+Wine is a mocker, strong drink is raging: and whosoever is 
+deceived thereby is not wise.
+%%
+Wisdom crieth without; she uttereth her voice in the 
+streets: She crieth in the chief place of concourse, in the 
+openings of the gates: in the city she uttereth her words, 
+saying, How long, ye simple ones, will ye love simplicity? and 
+the scorners delight in their scorning, and fools hate 
+knowledge? Turn you at my reproof: behold, I will pour out my 
+spirit unto you, I will make known my words unto you.
+%%
+Wisdom hath builded her house, she hath hewn out her seven 
+pillars: She hath killed her beasts; she hath mingled her 
+wine; she hath also furnished her table.
+%%
+Wisdom is before him that hath understanding; but the eyes 
+of a fool are in the ends of the earth.
+%%
+Wisdom is the principal thing; therefore get wisdom: and 
+with all thy getting get understanding.
+%%
+Wisdom is too high for a fool: he openeth not his mouth in 
+the gate.
+%%
+Wisdom resteth in the heart of him that hath understanding: 
+but that which is in the midst of fools is made known.
+%%
+Wise men lay up knowledge: but the mouth of the foolish is 
+near destruction.
+%%
+With clothes the new are best, with friends the old are 
+best.
+%%
+With her much fair speech she caused him to yield, with the 
+flattering of her lips she forced him.
+%%
+Withdraw thy foot from thy neighbour's house; lest he be 
+weary of thee, and so hate thee.
+%%
+Withhold not correction from the child: for if thou beatest 
+him with the rod, he shall not die.
+%%
+Withhold not good from them to whom it is due, when it is 
+in the power of thine hand to do it.
+%%
+Within a computer, natural language is unnatural.
+%%
+Without adventure, civilization is in full decay.
+%%
+Without counsel purposes are disappointed: but in the 
+multitude of counsellors they are established.
+%%
+Words are the voice of the heart.
+%%
+Words must be weighed, not counted.
+%%
+Work is the curse of the drinking class.
+%%
+Wrath is cruel, and anger is outrageous; but who is able to 
+stand before envy? Open rebuke is better than secret love.
+%%
+Writing free verse is like playing tennis with the net 
+down.
+%%
+Yea, my reins shall rejoice, when thy lips speak right 
+things.
+%%
+Yea, thou shalt be as he that lieth down in the midst of 
+the sea, or as he that lieth upon the top of a mast.
+%%
+Yet a little sleep, a little slumber, a little folding of 
+the hands to sleep: So shall thy poverty come as one that 
+travelleth; and thy want as an armed man.
+%%
+You are being paged.
+%%
+You are being swapped.
+%%
+You are clever, but it comes slowly -- all the way from the 
+back of your head. -- Russian proverb
+%%
+You are going to have a new love affair.
+%%
+You are in a maze of twisty little passages, all alike.
+%%
+You attempt things that you do not even plan because of 
+your extreme stupidity.
+%%
+You can do more with a kind word and a gun than you can 
+with only a kind word.
+%%
+You can't depend on the man who made the mess to clean it 
+up. -- Richard Nixon [1952]
+%%
+You can't drive straight on a twisting road. -- Russian 
+proverb
+%%
+You can't go home again, unless you set $HOME.
+%%
+You can't pick a mushroom without bowing. -- Russian 
+proverb
+%%
+You cannot kill time without injuring eternity.
+%%
+You do not have mail.
+%%
+You don't have to rehearse to be yourself.
+%%
+You don't want to know what I know.
+%%
+You fill a much-needed gap.
+%%
+You have a deep interest in all that is artistic.
+%%
+You have a tendency to feel you are superior to most 
+computers.
+%%
+You have an ambitious nature and may make a name for 
+yourself.
+%%
+You have been selected for a secret mission.
+%%
+You have been swapped out.
+%%
+You have mail.
+%%
+You look tired.
+%%
+You never get a hangover from other people's vodka. -- 
+Russian proverb
+%%
+You now have Asian Flu.
+%%
+You should go home.
+%%
+You will attract cultured and artistic people to your home.
+%%
+You will be advanced socially, without any special effort 
+on your part.
+%%
+You will be recognized and honored as a community leader.
+%%
+You will be surprised by a loud noise.
+%%
+You will feel hungry again in another hour.
+%%
+You will live a long, healthy, happy life and make bags of 
+money.
+%%
+You will never know hunger.
+%%
+You will reach the highest possible point in your business 
+or profession.
+%%
+You will step on the night soil of many countries.
+%%
+You'll be called to a post requiring high ability in 
+handling groups of people.
+%%
+You'll be sent to Siberia to count the birches. -- Russian 
+proverb
+%%
+Your business will go through a period of considerable 
+expansion.
+%%
+Your code should be more efficient!
+%%
+Your computer account is overdrawn.  Please reauthorize.
+%%
+Your education begins where what is called your education 
+is over.
+%%
+Your empty file directory has been deleted.
+%%
+Your ignorance cramps my conversation.
+%%
+Your mind understands what you have been taught; your 
+heart, what is true.
+%%
+Your salary will be increased.
+%%
+Your supervisor is thinking about you.
+%%
+Youth is the trustee of posterity.
diff --git a/xlockmore-4.14/etc/genlauncher/README b/xlockmore-4.14/etc/genlauncher/README
new file mode 100644 (file)
index 0000000..7e675ae
--- /dev/null
@@ -0,0 +1,18 @@
+This is a facility for the maintainer to populate
+the launchers with all the modes.
+
+Written by Charles Vidal <vidalc@club-internet.fr>
+
+README             This file
+lmode.h            The modes
+make.launcher      
+xlockgen.lex
+
+To compile xlockgen.lex 
+lex xlockgen.lex
+# Lex
+gcc lex.yy.c -o xlockgen -ll
+# Flex
+gcc lex.yy.c -o xlockgen -lfl
+
+Then run make.launcher on the genlauncher directory
diff --git a/xlockmore-4.14/etc/genlauncher/etc.xlock.tcl b/xlockmore-4.14/etc/genlauncher/etc.xlock.tcl
new file mode 100644 (file)
index 0000000..988c1b2
--- /dev/null
@@ -0,0 +1,647 @@
+#!/usr/X11/bin/wish -f
+
+#charles vidal 1998 <vidalc@club-intenet.fr>
+# update Sun Oct 18 1998
+# Add the menu file with load resources 
+# and the exit button 
+# Add the load_process procedure loading 
+# the ressource file ~/XLock 
+#
+
+#function find in demo: mkStyles.tcl
+# The procedure below inserts text into a given text widget and
+# applies one or more tags to that text.  The arguments are:
+#
+# w             Window in which to insert
+# text          Text to insert (it's inserted at the "insert" mark)
+# args          One or more tags to apply to text.  If this is empty
+#               then all tags are removed from the text.
+set bgcolor ""
+set fgcolor ""
+set ftname ""
+set mftname ""
+set usernom ""
+set passmot ""
+set XLock_validate ""
+set XLock_invalid ""
+set XLock_program ""
+set geometrie ""
+set icogeometrie ""
+set XLock_info ""
+set indxhelp ""
+set messagesfile ""
+set messagefile "" 
+set bitmap ""
+
+proc openfilesel { var  } {
+upvar $var toto
+set toto [ tk_getOpenFile -parent .]
+return toto
+}
+
+proc insertWithTags {w text args} {
+  set start [$w index insert]
+  $w insert insert $text
+  foreach tag [$w tag names $start] {
+    $w tag remove $tag $start insert
+  }
+  foreach i $args {
+    $w tag add $i $start insert
+  }
+}
+
+# Function for the help
+proc mkHelpCheck { w args } {
+  set nbf 0
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    $w insert insert  "\n"
+    checkbutton $w.c$nbf -variable [lindex $i 0] -text [lindex $i 0]
+    $w window create {end lineend} -window $w.c$nbf
+    $w insert insert  " [lindex $i 1] "
+  }
+}
+
+proc mkHelpEntry { w args } {
+  set nbf 0
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    insertWithTags  $w "\n [lindex $i 0] " underline
+    entry $w.e$nbf -textvariable [lindex $i 1]
+    $w window create {end lineend} -window $w.e$nbf
+    $w insert insert  "\n[lindex $i 2] "
+  }
+}
+
+#
+proc whichcolor { which } {
+  global fgcolor
+  global bgcolor
+  if {$which == "RESETFG"} {set fgcolor ""}
+  if {$which == "RESETBG"} {set bgcolor ""}
+  if ($tk_version>4) then {
+    if {$which== "FG" } {set fgcolor [tk_chooseColor -initialcolor $fgcolor -title "foreground color"];
+      puts $fgcolor
+    }
+  if {$which == "BG"} {set bgcolor [tk_chooseColor -initialcolor $bgcolor -title "background color"];
+      puts $bgcolor
+    }
+  } else
+  {
+    if {$which== "FG" } {set fgcolor [.color.frame.names get [.color.frame.names curselection]];}
+    if {$which == "BG"} {set bgcolor [.color.frame.names get [.color.frame.names curselection]];}
+  }
+}
+
+proc mkColor { what } {
+  if ($tk_version>4) then {
+    whichcolor $what; destroy .color
+  } else
+  {
+    toplevel .color
+    wm title .color "Color"
+    frame .color.frame -borderwidth 10
+    frame .color.frame2 -borderwidth 10
+    set w .color.frame
+    label $w.msg0   -text "Color Options"
+    pack $w.msg0 -side top
+    foreach i {/usr/local/lib/X11/rgb.txt /usr/lib/X11/rgb.txt
+        /X11/R5/lib/X11/rgb.txt /X11/R4/lib/rgb/rgb.txt} {
+      if ![file readable $i] {
+        continue;
+      }
+      set f [open $i]
+      listbox .color.frame.names -yscrollcommand ".color.frame.scroll set" \
+            -relief sunken -borderwidth 2 -exportselection false
+      bind .color.frame.names <Double-1> {
+            .color.test configure -bg [.color.frame.names get [.color.frame.names curselection]]
+      }
+      scrollbar .color.frame.scroll -orient vertical -command ".color.frame.names yview" \
+        -relief sunken -borderwidth 2
+      pack .color.frame.names  -side left
+      pack .color.frame.scroll -side right -fill both
+      pack .color.frame  -fill x
+      while {[gets $f line] >= 0} {
+        if {[llength $line] == 4} {
+          .color.frame.names insert end [lindex $line 3]
+        }
+      }
+      close $f
+      label  .color.test -height 5 -width 20
+      button .color.frame2.cancel -text Cancel -command "destroy .color"
+      button .color.frame2.ok -text OK -command "whichcolor $what; destroy .color"
+      button .color.frame2.reset -text Reset -command "whichcolor RESET$what; destroy .color"
+      pack  .color.test
+      pack .color.frame2.ok .color.frame2.cancel .color.frame2.reset -side left -fill x
+      pack .color.frame2 -fill both
+      break;
+    }
+  }
+}
+
+# moving in text by the list
+proc moveintext { indx } {
+upvar indxhelp t1
+ .help.f.t yview  [ lindex $t1 $indx ]
+
+}
+#----------------------
+# Help ...
+proc Helpxlock {} {
+  global indxhelp
+  toplevel .help
+  wm title .help "Help About Xlock"
+  frame .help.f
+  scrollbar .help.f.s -orient vertical -command {.help.f.t yview}
+  pack .help.f -expand yes -fill both
+  pack .help.f.s -side right -fill y -expand yes
+  text .help.f.t -yscrollcommand {.help.f.s set} -wrap word -width 60 -height 20 \
+    -setgrid 1
+
+  listbox .help.f.names -width 20 -height 20
+
+  bind .help.f.names <Double-1> {
+    set titi [eval .help.f.names curselection]
+    moveintext $titi
+  }
+
+  pack .help.f.names .help.f.t -expand y -fill both -side left
+  set w  .help.f.t
+  $w tag configure big -font -Adobe-Courier-Bold-R-Normal-*-140-*
+
+  foreach i {{"Xlock Help" { Locks the X server still the user enters their pass\
+word at the keyboard.  While xlock  is  running,  all  new\
+server  connections are refused.  The screen saver is dis\
+abled.  The mouse cursor is turned  off.   The  screen  is\
+blanked and a changing pattern is put on the screen.  If a\
+key or a mouse button is pressed then the user is prompted\
+for the password of the user who started xlock.
+If  the  correct  password  is  typed,  then the screen is\
+unlocked and the X server is restored.   When  typing  the\
+password  Control-U  and  Control-H are active as kill and\
+erase respectively.  To return to the locked screen, click\
+in the small icon version of the changing pattern.} 0 }
+    {"Options" {The option sets  the  X11  display  to  lock.\
+xlock  locks all available screens on a given server,\
+and restricts you to locking only a local server such\
+as  unix::00,,  localhost::00,,  or  ::00  unless you set the\
+     -remote option.} 0 }\
+    {"-name" {is used instead of XLock  when  looking for resources to configure xlock.} 1 }
+    {"-mode" {As  of  this  writing there are 80+ display modes supported (plus one more for random selection of one  of the 80+).} 1 }
+    {"-delay"  {It simply sets the number  of  microseconds to  delay
+between  batches  of animations.  In blank mode, it is important to set this to
+some small  number  of  microseconds,  because the keyboard and mouse are only checked after each delay, so you cannot set  the delay  too high, but a delay of
+zero would needlessly consume cpu checking for mouse and keyboard input  in a tight loop, since blank mode has no work to do.} 1 }
+    {"-saturation" {This option sets saturation  of  the  color ramp .  0 is grayscale and 1 is very rich color. 0.4 is a nice pastel.} 1 }
+    {"-username" {text string to use for Name prompt} 1 }\
+    {"-password" {text string to use for Password prompt} 1 }\
+    {"-info" {text string to use for instructions} 1 }\
+    {"-validate" {the message shown  while  validating  the password,
+defaults to \"Validating login...\"} 1 }\
+    {"-invalid" {the  message  shown  when  password  is invalid, defaults to \"Invalid login.\"} 1 }\
+    {"-geometry"  {This option sets the size and offset  of the  lock
+window  (normally the entire screen).  The entire screen format is still used for  entering  the password.   The  purpose  is  to  see the screen even though it is locked.  This should be used  with  caution since many of the modes will fail if the windows are far from square or are too small  (size  must  be greater
+than  0x0).   This  should also be used with esaver to protect screen from phosphor burn.} 1 }\
+    {"-icongeometry" {this option sets  the  size  of  the iconic screen (normally 64x64) seen when entering the password.  This should be  used  with  caution  since many  of  the  modes will fail if the windows are far from square
+or are too small (size  must  be  greater than  0x0).   The  greatest  size  is
+256x256.  There should be some limit  so  users  could  see  who  has locked  the  screen.  Position information of icon is ignored.} 1 }
+    {"-font" { Ths option  sets  the  font  to be used on the prompt screen.} 1 }
+    { "-fg "  { This option sets the color of the text on the password screen.} 1 }
+    {"-bg" { This option sets the color of the background on the password screen.} 1 }
+    {"-forceLogout" { This option sets the  auto-logout.  This  might not be enforced depending how your system is configured.} 1 }} {
+    lappend indxhelp [$w index current]
+    if {  [lindex $i 2] == 1 } then {.help.f.names insert end "    [lindex $i 0]"} else {.help.f.names insert end " [lindex $i 0]"}
+    insertWithTags  $w "[lindex $i 0] " big
+    $w insert end "\n"
+    $w insert end [lindex $i 1]
+    $w insert end "\n"
+  }
+  lappend indxhelp [$w index current]
+  insertWithTags  $w "Options boolean" big
+   $w insert end "\n"
+  .help.f.names insert end "Options boolean"
+  mkHelpCheck $w {XLock_mono {turn on/off monochrome override}}\
+                {nolock {trun on/off no password required mode}}\
+                {remote {turn on/off remote host access}}\
+                {allowroot {turn on/off allow root password mode (ignored)}}\
+                {enablesaver {turn on/off enable X server screen saver}}\
+                {allowaccess {turn on/off access of the terminal X}}\
+                {grabmouse {turn on/off grabbing of mouse and keyboard}}\
+                {echokeys {turn on/off echo \'?\' for each password key}}\
+                {usefirst {turn on/off using the first char typed in password}}\
+                {verbose {turn on/off verbose mode}}\
+                {inwindow {turn on/off making xlock run in a window}}\
+                {inroot {turn on/off making xlock run in the root window}}\
+                {timeelapsed {turn on/off clock}}\
+                {install {whether to use private colormap if needed (yes/no)}}\
+                {sound {whether to use sound if configured for it (yes/no}}
+        button .help.ok -text OK -command "destroy .help"
+  pack  .help.ok
+}
+
+# Create toplevel Author and Maintener.
+proc mkAuthor {} {
+  toplevel .author
+  wm title .author "Author and Maintener of xlock"
+  frame .author.frame -borderwidth 10
+  set w .author.frame
+
+  label $w.msg0   -text "Author and Maintener of xlock"
+  label $w.msg1   -text "Maintained by: David A. Bagley (bagleyd@tux.org)"
+  label $w.msg2   -text "Original Author: Patrick J. Naughton (naughton@eng.sun.com)"
+  label $w.msg3   -text "Mailstop 21-14 Sun Microsystems Laboratories,"
+  label $w.msg4   -text "Inc.  Mountain View, CA  94043 15//336-1080"
+  label $w.msg5   -text "with many additional contributors"
+  pack $w.msg0 $w.msg1 $w.msg2 $w.msg3 $w.msg4 $w.msg5 -side top
+
+  label $w.msg6   -text "xlock.tcl\n created by charles VIDAL\n (author of flag mode and xmlock launcher )"
+  pack $w.msg6 -side top
+
+  button .author.ok -text OK -command "destroy .author"
+  pack $w .author.ok
+}
+
+proc mkFileDialog { nom titre args }  {
+  toplevel .$nom
+  wm title .$nom "$titre"
+  frame .$nom.frame -borderwidth 10
+  frame .$nom.frame2 -borderwidth 10
+  frame .$nom.frame.frame4 -borderwidth 10
+  set w .$nom.frame
+  set w2 .$nom.frame2
+  set w4 .$nom.frame.frame4
+  set nbf 0
+
+  label $w.msg0   -text "$titre"
+  pack $w.msg0 -side top
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    frame $w4.f$nbf 
+    label $w4.f$nbf.l$nbf -text [lindex $i 0]
+    entry $w4.f$nbf.e$nbf -textvariable [lindex $i 1]
+    button $w4.f$nbf.b$nbf -text "..." -command "openfilesel [lindex $i 1]"
+    pack $w4.f$nbf.l$nbf $w4.f$nbf.e$nbf $w4.f$nbf.b$nbf  -side left -expand yes
+    pack $w4.f$nbf -expand yes
+  }
+  button $w2.ok -text OK -command "destroy .$nom"
+  button $w2.cancel -text Cancel -command "destroy .$nom"
+  pack $w -side top -expand yes
+  pack $w4 -side right -expand yes
+  pack $w2.ok $w2.cancel -side left -fill x -expand yes
+  pack $w2  -side bottom -expand yes
+}
+
+proc mkDialog { nom titre args } {
+  toplevel .$nom
+  wm title .$nom "$titre"
+  frame .$nom.frame -borderwidth 10
+  frame .$nom.frame2 -borderwidth 10
+  frame .$nom.frame.frame3 -borderwidth 10
+  frame .$nom.frame.frame4 -borderwidth 10
+  set w .$nom.frame
+  set w2 .$nom.frame2
+  set w3 .$nom.frame.frame3
+  set w4 .$nom.frame.frame4
+  set nbf 0
+
+  label $w.msg0   -text "$titre"
+  pack $w.msg0 -side top
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    label $w3.l$nbf -text [lindex $i 0]
+    entry $w4.e$nbf -textvariable [lindex $i 1]
+    pack $w3.l$nbf
+    pack $w4.e$nbf
+  }
+  button $w2.ok -text OK -command "destroy .$nom"
+  button $w2.cancel -text Cancel -command "destroy .$nom"
+  pack $w -side top
+  pack $w3 -side left
+  pack $w4 -side right
+  pack $w2.ok $w2.cancel -side left -fill x
+  pack $w2  -side bottom
+}
+
+proc mkMessage {} {
+  global passmot
+  global XLock_validate
+  global XLock_invalid
+  global XLock_info
+  mkDialog message {Message Options} \
+  {"message password" passmot} \
+  {"validate string" XLock_validate} \
+  {"invalid string" XLock_invalid} \
+  {"info string" XLock_info}
+}
+
+proc mkGeometry {} {
+  global geometrie
+  global icogeometrie
+  mkDialog geometry {Geometry Options} \
+  {"geometry" geometrie} \
+  {"icon geometry" icogeometrie}
+}
+
+proc mkFileOption {} {
+  global messagesfile
+  global messagefile
+  global bitmap
+  mkFileDialog fileoption {Files Options} \
+  {"messagesfile" messagesfile} \
+  {"messagefile" messagefile} \
+  {"bitmap" bitmap} 
+}
+
+proc whichfont { which } {
+  global ftname
+  global mftname
+ if {$which== "FONT" } {set ftname [.font.frame.names get [.font.frame.names curselection]];}
+ if {$which == "MFONT"} {set mftname [.font.frame.names get [.font.frame.names curselection]];}
+ if {$which == "RESETFONT"} {set ftname ""}
+ if {$which == "RESETMFONT"} {set mftname ""}
+}
+
+#this function should be erase in the newer version...
+proc mkFont { What } {
+  toplevel .font
+  wm title .font "Font Options"
+  label  .font.label -text "ABCDEFGH\nIJKabedfg\nhijkmnopq"
+  frame .font.frame -borderwidth 10
+  frame .font.frame2 -borderwidth 10
+  set w .font.frame
+  label $w.msg0   -text "Font Options"
+  pack $w.msg0 -side top
+  eval exec "xlsfonts \> /tmp/xlsfont.tmp"
+  set f [open "/tmp/xlsfont.tmp"]
+  listbox .font.frame.names -yscrollcommand ".font.frame.scroll set" \
+    -xscrollcommand ".font.scroll2 set"  -setgrid 1 \
+    -exportselection false
+  bind .font.frame.names <Double-1> {
+   .font.test configure -font [.font.frame.names get [.font.frame.names curselection]]
+  }
+  scrollbar .font.frame.scroll -orient vertical -command ".font.frame.names yview" \
+    -relief sunken -borderwidth 2
+  scrollbar .font.scroll2 -orient horizontal -command ".font.frame.names xview" \
+    -relief sunken -borderwidth 2
+  while {[gets $f line] >= 0} {
+    .font.frame.names insert end $line
+  }
+  close $f
+
+  eval exec "/bin/rm -f /tmp/xlsfont.tmp"
+  pack .font.frame.names  -side left -expand y -fill both
+  pack .font.frame.scroll -side right -fill both
+  pack .font.frame  -fill x
+  pack .font.scroll2 -fill both
+  label  .font.test -text "ABCDEFGHIJKabedfghijkmnopq12345"
+  pack .font.test
+
+  button .font.frame2.cancel -text Cancel -command "destroy .font"
+  button .font.frame2.reset -text Reset -command "whichfont RESET$What;destroy .font"
+  button .font.frame2.ok -text OK -command "whichfont $What;destroy .font"
+  pack .font.frame2.ok .font.frame2.cancel .font.frame2.reset -side left -fill both
+  pack .font.frame2 -fill both
+
+  #frame $w.fontname
+  #label $w.fontname.l1 -text "font name"
+  #entry $w.fontname.e1 -relief sunken
+  #frame $w.specfont
+  #label $w.specfont.l2 -text "specifique font name"
+  #entry $w.specfont.e2 -relief sunken
+  #pack $w.fontname $w.specfont
+  #pack $w.fontname.l1 -side left
+  #pack $w.specfont.l2 -side left
+  #pack $w.fontname.e1 $w.specfont.e2  -side top -pady 5 -fill x
+  #button .font.frame2.ok -text OK -command "destroy .font"
+  #button .font.frame2.cancel -text Cancel -command "destroy .font"
+  #pack $w .font.frame2.ok .font.frame2.cancel -side left -fill x
+  #pack .font.frame2 -side bottom
+}
+
+proc mkEntry {} {
+  global usernom
+  global XLock_program
+  mkDialog option {User Options} \
+  {"user name" usernom} \
+  {"program name" XLock_program}
+}
+
+proc Affopts { device } {
+
+#options booleans
+  global XLock_mono
+  global nolock
+  global remote
+  global allowroot
+  global enablesaver
+  global allowaccess
+  global grabmouse
+  global echokeys
+  global usefirst
+  global install
+  global sound
+
+  global fgcolor
+  global bgcolor
+  global ftname
+  global mftname
+
+  global usernom
+  global passmot
+  global XLock_validate
+  global XLock_invalid
+  global XLock_program
+  global geometrie
+  global icogeometrie
+  global XLock_info
+  global messagesfile 
+  global messagefile  
+  global bitmap 
+
+  set linecommand "xlock "
+
+  if {$device == 1} {append linecommand "-inwindow "} elseif {$device == 2} {append linecommand "-inroot "}
+  if {$bgcolor!=""} {append linecommand "-bg $bgcolor "}
+  if {$fgcolor!=""} {append linecommand "-fg $fgcolor "}
+  if {$ftname!=""} {append linecommand "-font $ftname "}
+  if {$mftname!=""} {append linecommand "-messagefont $mftname "}
+#entry action
+  if {$usernom!=""} {append linecommand "-username $usernom "}
+  if {$passmot!=""} {append linecommand "-password $passmot "}
+  if {$XLock_validate!=""} {append linecommand "-validate $XLock_validate "}
+  if {$XLock_invalid!=""} {append linecommand "-invalid $XLock_invalid "}
+  if {$XLock_program!=""} {append linecommand "-program $XLock_program "}
+  if {$geometrie!=""} {append linecommand "-geometry $geometrie "}
+  if {$icogeometrie!=""} {append linecommand "-icongeometry $icogeometrie "}
+  if {$messagesfile!=""} {append linecommand "-messagesfile $messagesfile "}
+  if {$bitmap!=""} {append linecommand "-bitmap $bitmap "}
+  if {$icogeometrie!=""} {append linecommand "-icongeometry $icogeometrie "}
+  if {$XLock_info!=""} {append linecommand "-info $XLock_info "}
+#check actions
+  if { $XLock_mono == 1 } {append linecommand "-mono "}
+  if { $install == 1 } {append linecommand "+install "}
+  if { $sound == 1 } {append linecommand "+sound "}
+  if { $nolock == 1 } {append linecommand "-nolock "}
+  if { $remote == 1 } {append linecommand "-remote "}
+  if { $allowroot == 1 } {append linecommand "-allowroot "}
+  if { $enablesaver == 1 } {append linecommand "-enablesaver "}
+  if { $allowaccess == 1 } {append linecommand "-allowaccess "}
+  if { $grabmouse == 1 } {append linecommand "-grabmouse "}
+  if { $echokeys == 1 } {append linecommand "-echokeys "}
+  if { $usefirst == 1 } {append linecommand "-usefirst "}
+  append linecommand "-mode "
+  append linecommand [.listscrol.list get [eval .listscrol.list curselection]]
+  puts $linecommand
+  eval exec $linecommand
+}
+
+proc load_ressource { } {
+  global XLock_invalid
+  global XLock_validate
+  global XLock_info
+  global XLock_program
+
+set filename ""
+
+openfilesel filename
+
+set f [ open $filename r ]
+while { ! [eof $f ] } {
+       gets $f line
+               switch -regexp $line {
+       {^XLock\.[a-zA-Z]+:} {
+               if { [ regexp -nocase {\: $} tyty ]} {
+               }
+       regsub {^} $line "set " line2
+       regsub {XLock\.} $line2 "XLock_" line3
+       regsub {: } $line3 " \"" line4
+       regsub {on$} $line4 "1" line5
+       regsub {off$} $line4 "0" line5
+       eval "$line5\""
+       }
+       {^XLock\.[a-zA-Z]+\.[a-zA-Z]+:[ \t]*[a-zA-Z0-9]+$} {
+       regsub {^} $line "set " line2
+       regsub {XLock\.} $line2 "XLock_" line3
+       regsub {\.} $line3 "(" line4
+       regsub {: } $line4 ") \"" line5
+       eval "$line5\""
+       }
+}
+}
+}
+
+# Creation of GUI
+
+wm title . "xlock launcher"
+. configure -cursor top_left_arrow
+frame .menu -relief raised -borderwidth 1
+menubutton .menu.button -text "switches" -menu .menu.button.check
+pack .menu -side top -fill x
+
+global XLock_mono
+global sound
+global install
+global nolock
+global remote
+global allowroot
+global enablesaver
+global allowaccess
+global grabmouses
+global echokeys
+global usefirst
+
+global usernom
+global passmot
+global geometrie
+global icogeometrie
+global XLock_info
+
+# Creation of GUI
+
+#Creation of  menu
+set fileressource ""
+
+menubutton .menu.buttonf -text "file" -menu .menu.buttonf.file
+menu .menu.buttonf.file
+set FILE .menu.buttonf.file
+$FILE add command -label "Load ressource" -command "load_ressource"
+$FILE add command -label "exit" -command "exit"
+
+menu .menu.button.check
+set CHECK .menu.button.check
+
+#menu with les check buttons
+$CHECK add check -label "mono" -variable XLock_mono
+$CHECK add check -label "nolock" -variable nolock
+$CHECK add check -label "remote" -variable remote
+$CHECK add check -label "allowroot" -variable allowroot
+$CHECK add check -label "enablesaver" -variable enablesaver
+$CHECK add check -label "allowaccess" -variable allowaccess
+$CHECK add check -label "grabmouse" -variable grabmouse
+$CHECK add check -label "echokeys" -variable echokeys
+$CHECK add check -label "usefirst" -variable usefirst
+$CHECK add check -label "install" -variable install
+$CHECK add check -label "sound" -variable sound
+
+menubutton .menu.button2 -text "options" -menu .menu.button2.options
+menu .menu.button2.options
+set OPTIONS .menu.button2.options
+#les options
+$OPTIONS add command -label "generals options" -command "mkEntry"
+$OPTIONS add command -label "font to use for password prompt" -command "mkFont FONT"
+$OPTIONS add command -label "font for a specific mode" -command "mkFont MFONT"
+
+
+$OPTIONS add command -label "geometry options" -command "mkGeometry"
+$OPTIONS add command -label "file options" -command "mkFileOption"
+$OPTIONS add command -label "message options" -command "mkMessage"
+
+#Color
+menubutton .menu.button4 -text "color" -menu .menu.button4.color
+menu .menu.button4.color
+set COLOR .menu.button4.color
+#if {$tk_version < 4} then {
+#$COLOR add command -label "foreground options for password" -command "mkColor FG"
+#$COLOR add command -label "background options for password" -command "mkColor BG"
+#}
+#else {
+$COLOR add command -label "foreground options for password" -command "tk_chooseColor"
+$COLOR add command -label "background options for password" -command "tk_chooseColor"
+#}
+menubutton .menu.button3 -text "help" -menu .menu.button3.help
+menu .menu.button3.help
+set HELP .menu.button3.help
+$HELP add command -label "about xlock" -command "Helpxlock"
+$HELP add command -label "about author" -command "mkAuthor"
+
+pack .menu.buttonf .menu.button  .menu.button2 .menu.button4 -side left
+pack .menu.button3 -side right
+
+#---------------------------
+#creation de la liste
+#---------------------------
+frame .listscrol -borderwidth 4 -relief ridge
+set LISTSCROL .listscrol
+scrollbar $LISTSCROL.scroll -relief sunken -command "$LISTSCROL.list yview"
+listbox $LISTSCROL.list -yscroll  "$LISTSCROL.scroll set"
+
+#---------------------------
+#insert all modes in list
+#---------------------------
+$LISTSCROL.list  insert 0 \
+$%LISTTCL
+
+pack $LISTSCROL.scroll -side right -fill y
+pack $LISTSCROL.list -side left -expand yes -fill both
+pack $LISTSCROL  -fill both -expand yes
+
+frame .buttons -borderwidth 4 -relief ridge
+set BUTTON .buttons
+button $BUTTON.launch -text "Launch"  -command "Affopts 0"
+button $BUTTON.launchinW -text "Launch in Window" -command "Affopts 1"
+button $BUTTON.launchinR -text "Launch in Root" -command "Affopts 2"
+button $BUTTON.quit -text Quit -command "exit"
+pack  $BUTTON.launch $BUTTON.launchinW $BUTTON.launchinR -side left
+pack $BUTTON.quit -side right
+pack $BUTTON -fill x -side bottom
+
diff --git a/xlockmore-4.14/etc/genlauncher/lex.yy.c b/xlockmore-4.14/etc/genlauncher/lex.yy.c
new file mode 100644 (file)
index 0000000..e299414
--- /dev/null
@@ -0,0 +1,1619 @@
+/* A lexical scanner generated by flex */
+
+/* Scanner skeleton version:
+ * $Header: /home/daffy/u0/vern/flex/RCS/flex.skl,v 2.91 96/09/10 16:58:48 vern Exp $
+ */
+
+#define FLEX_SCANNER
+#define YY_FLEX_MAJOR_VERSION 2
+#define YY_FLEX_MINOR_VERSION 5
+
+#include <stdio.h>
+
+
+/* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
+#ifdef c_plusplus
+#ifndef __cplusplus
+#define __cplusplus
+#endif
+#endif
+
+
+#ifdef __cplusplus
+
+#include <stdlib.h>
+#include <unistd.h>
+
+/* Use prototypes in function declarations. */
+#define YY_USE_PROTOS
+
+/* The "const" storage-class-modifier is valid. */
+#define YY_USE_CONST
+
+#else  /* ! __cplusplus */
+
+#if __STDC__
+
+#define YY_USE_PROTOS
+#define YY_USE_CONST
+
+#endif /* __STDC__ */
+#endif /* ! __cplusplus */
+
+#ifdef __TURBOC__
+ #pragma warn -rch
+ #pragma warn -use
+#include <io.h>
+#include <stdlib.h>
+#define YY_USE_CONST
+#define YY_USE_PROTOS
+#endif
+
+#ifdef YY_USE_CONST
+#define yyconst const
+#else
+#define yyconst
+#endif
+
+
+#ifdef YY_USE_PROTOS
+#define YY_PROTO(proto) proto
+#else
+#define YY_PROTO(proto) ()
+#endif
+
+/* Returned upon end-of-file. */
+#define YY_NULL 0
+
+/* Promotes a possibly negative, possibly signed char to an unsigned
+ * integer for use as an array index.  If the signed char is negative,
+ * we want to instead treat it as an 8-bit unsigned char, hence the
+ * double cast.
+ */
+#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
+
+/* Enter a start condition.  This macro really ought to take a parameter,
+ * but we do it the disgusting crufty way forced on us by the ()-less
+ * definition of BEGIN.
+ */
+#define BEGIN yy_start = 1 + 2 *
+
+/* Translate the current start state into a value that can be later handed
+ * to BEGIN to return to the state.  The YYSTATE alias is for lex
+ * compatibility.
+ */
+#define YY_START ((yy_start - 1) / 2)
+#define YYSTATE YY_START
+
+/* Action number for EOF rule of a given start state. */
+#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
+
+/* Special action meaning "start processing a new file". */
+#define YY_NEW_FILE yyrestart( yyin )
+
+#define YY_END_OF_BUFFER_CHAR 0
+
+/* Size of default input buffer. */
+#define YY_BUF_SIZE 16384
+
+typedef struct yy_buffer_state *YY_BUFFER_STATE;
+
+extern int yyleng;
+extern FILE *yyin, *yyout;
+
+#define EOB_ACT_CONTINUE_SCAN 0
+#define EOB_ACT_END_OF_FILE 1
+#define EOB_ACT_LAST_MATCH 2
+
+/* The funky do-while in the following #define is used to turn the definition
+ * int a single C statement (which needs a semi-colon terminator).  This
+ * avoids problems with code like:
+ *
+ *     if ( condition_holds )
+ *             yyless( 5 );
+ *     else
+ *             do_something_else();
+ *
+ * Prior to using the do-while the compiler would get upset at the
+ * "else" because it interpreted the "if" statement as being all
+ * done when it reached the ';' after the yyless() call.
+ */
+
+/* Return all but the first 'n' matched characters back to the input stream. */
+
+#define yyless(n) \
+       do \
+               { \
+               /* Undo effects of setting up yytext. */ \
+               *yy_cp = yy_hold_char; \
+               YY_RESTORE_YY_MORE_OFFSET \
+               yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
+               YY_DO_BEFORE_ACTION; /* set up yytext again */ \
+               } \
+       while ( 0 )
+
+#define unput(c) yyunput( c, yytext_ptr )
+
+/* The following is because we cannot portably get our hands on size_t
+ * (without autoconf's help, which isn't available because we want
+ * flex-generated scanners to compile on their own).
+ */
+typedef unsigned int yy_size_t;
+
+
+struct yy_buffer_state
+       {
+       FILE *yy_input_file;
+
+       char *yy_ch_buf;                /* input buffer */
+       char *yy_buf_pos;               /* current position in input buffer */
+
+       /* Size of input buffer in bytes, not including room for EOB
+        * characters.
+        */
+       yy_size_t yy_buf_size;
+
+       /* Number of characters read into yy_ch_buf, not including EOB
+        * characters.
+        */
+       int yy_n_chars;
+
+       /* Whether we "own" the buffer - i.e., we know we created it,
+        * and can realloc() it to grow it, and should free() it to
+        * delete it.
+        */
+       int yy_is_our_buffer;
+
+       /* Whether this is an "interactive" input source; if so, and
+        * if we're using stdio for input, then we want to use getc()
+        * instead of fread(), to make sure we stop fetching input after
+        * each newline.
+        */
+       int yy_is_interactive;
+
+       /* Whether we're considered to be at the beginning of a line.
+        * If so, '^' rules will be active on the next match, otherwise
+        * not.
+        */
+       int yy_at_bol;
+
+       /* Whether to try to fill the input buffer when we reach the
+        * end of it.
+        */
+       int yy_fill_buffer;
+
+       int yy_buffer_status;
+#define YY_BUFFER_NEW 0
+#define YY_BUFFER_NORMAL 1
+       /* When an EOF's been seen but there's still some text to process
+        * then we mark the buffer as YY_EOF_PENDING, to indicate that we
+        * shouldn't try reading from the input source any more.  We might
+        * still have a bunch of tokens to match, though, because of
+        * possible backing-up.
+        *
+        * When we actually see the EOF, we change the status to "new"
+        * (via yyrestart()), so that the user can continue scanning by
+        * just pointing yyin at a new input file.
+        */
+#define YY_BUFFER_EOF_PENDING 2
+       };
+
+static YY_BUFFER_STATE yy_current_buffer = 0;
+
+/* We provide macros for accessing buffer states in case in the
+ * future we want to put the buffer states in a more general
+ * "scanner state".
+ */
+#define YY_CURRENT_BUFFER yy_current_buffer
+
+
+/* yy_hold_char holds the character lost when yytext is formed. */
+static char yy_hold_char;
+
+static int yy_n_chars;         /* number of characters read into yy_ch_buf */
+
+
+int yyleng;
+
+/* Points to current character in buffer. */
+static char *yy_c_buf_p = (char *) 0;
+static int yy_init = 1;                /* whether we need to initialize */
+static int yy_start = 0;       /* start state number */
+
+/* Flag which is used to allow yywrap()'s to do buffer switches
+ * instead of setting up a fresh yyin.  A bit of a hack ...
+ */
+static int yy_did_buffer_switch_on_eof;
+
+void yyrestart YY_PROTO(( FILE *input_file ));
+
+void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
+void yy_load_buffer_state YY_PROTO(( void ));
+YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
+void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
+void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
+void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
+#define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
+
+YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
+YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str ));
+YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
+
+static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
+static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
+static void yy_flex_free YY_PROTO(( void * ));
+
+#define yy_new_buffer yy_create_buffer
+
+#define yy_set_interactive(is_interactive) \
+       { \
+       if ( ! yy_current_buffer ) \
+               yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
+       yy_current_buffer->yy_is_interactive = is_interactive; \
+       }
+
+#define yy_set_bol(at_bol) \
+       { \
+       if ( ! yy_current_buffer ) \
+               yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
+       yy_current_buffer->yy_at_bol = at_bol; \
+       }
+
+#define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
+
+
+#define YY_USES_REJECT
+typedef unsigned char YY_CHAR;
+FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
+typedef int yy_state_type;
+#define YY_FLEX_LEX_COMPAT
+extern int yylineno;
+int yylineno = 1;
+extern char yytext[];
+
+
+static yy_state_type yy_get_previous_state YY_PROTO(( void ));
+static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
+static int yy_get_next_buffer YY_PROTO(( void ));
+static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
+
+/* Done after the current pattern has been matched and before the
+ * corresponding action - sets up yytext.
+ */
+#define YY_DO_BEFORE_ACTION \
+       yytext_ptr = yy_bp; \
+       yyleng = (int) (yy_cp - yy_bp); \
+       yy_hold_char = *yy_cp; \
+       *yy_cp = '\0'; \
+       if ( yyleng + yy_more_offset >= YYLMAX ) \
+               YY_FATAL_ERROR( "token too large, exceeds YYLMAX" ); \
+       yy_flex_strncpy( &yytext[yy_more_offset], yytext_ptr, yyleng + 1 ); \
+       yyleng += yy_more_offset; \
+       yy_prev_more_offset = yy_more_offset; \
+       yy_more_offset = 0; \
+       yy_c_buf_p = yy_cp;
+
+#define YY_NUM_RULES 5
+#define YY_END_OF_BUFFER 6
+static yyconst short int yy_acclist[8] =
+    {   0,
+        6,    5,    5,    3,    4,    1,    2
+    } ;
+
+static yyconst short int yy_accept[30] =
+    {   0,
+        1,    1,    1,    2,    3,    4,    4,    4,    4,    4,
+        4,    4,    4,    4,    4,    4,    4,    4,    4,    4,
+        4,    4,    5,    6,    6,    6,    7,    8,    8
+    } ;
+
+static yyconst int yy_ec[256] =
+    {   0,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    2,    3,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    4,    5,    6,    1,    1,    7,
+        1,    1,    8,    9,    1,   10,   11,    1,   12,    1,
+        1,    1,   13,   14,    1,   15,    1,   16,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1
+    } ;
+
+static yyconst int yy_meta[17] =
+    {   0,
+        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
+        1,    1,    1,    1,    1,    1
+    } ;
+
+static yyconst short int yy_base[30] =
+    {   0,
+       33,   32,   33,   36,   29,   21,   22,   16,   14,    0,
+       23,   18,   13,   18,    8,   17,    7,   10,   15,    5,
+        9,   36,   36,    0,    0,   36,   36,   36,    0
+    } ;
+
+static yyconst short int yy_def[30] =
+    {   0,
+       29,   29,   28,   28,   28,   28,   28,   28,   28,   28,
+       28,   28,   28,   28,   28,   28,   28,   28,   28,   28,
+       28,   28,   28,   28,   28,   28,   28,    0,   28
+    } ;
+
+static yyconst short int yy_nxt[53] =
+    {   0,
+        4,   28,   28,   28,   28,   28,   27,   28,   11,   12,
+       13,   28,   28,   14,   28,   26,   25,   24,   23,   22,
+       21,   20,   19,   18,   17,   16,   15,   10,    9,    8,
+        7,    6,   28,    5,    5,    3,   28,   28,   28,   28,
+       28,   28,   28,   28,   28,   28,   28,   28,   28,   28,
+       28,   28
+    } ;
+
+static yyconst short int yy_chk[53] =
+    {   0,
+       29,    0,    0,    0,    0,    0,   25,    0,   10,   10,
+       10,    0,    0,   10,    0,   24,   21,   20,   19,   18,
+       17,   16,   15,   14,   13,   12,   11,    9,    8,    7,
+        6,    5,    3,    2,    1,   28,   28,   28,   28,   28,
+       28,   28,   28,   28,   28,   28,   28,   28,   28,   28,
+       28,   28
+    } ;
+
+static yy_state_type yy_state_buf[YY_BUF_SIZE + 2], *yy_state_ptr;
+static char *yy_full_match;
+static int yy_lp;
+#define REJECT \
+{ \
+*yy_cp = yy_hold_char; /* undo effects of setting up yytext */ \
+yy_cp = yy_full_match; /* restore poss. backed-over text */ \
+++yy_lp; \
+goto find_rule; \
+}
+static int yy_more_offset = 0;
+static int yy_prev_more_offset = 0;
+#define yymore() (yy_more_offset = yy_flex_strlen( yytext ))
+#define YY_NEED_STRLEN
+#define YY_MORE_ADJ 0
+#define YY_RESTORE_YY_MORE_OFFSET \
+       { \
+       yy_more_offset = yy_prev_more_offset; \
+       yyleng -= yy_more_offset; \
+       }
+#ifndef YYLMAX
+#define YYLMAX 8192
+#endif
+
+char yytext[YYLMAX];
+char *yytext_ptr;
+#line 1 "xlockgen.lex"
+#define INITIAL 0
+#line 2 "xlockgen.lex"
+#include <stdio.h>\r
+#include <string.h>\r
+#include "lmode.h"\r
+char *Begin="\"";\r
+char *Sep="\",";\r
+char *End="\"";\r
+#line 418 "lex.yy.c"
+
+/* Macros after this point can all be overridden by user definitions in
+ * section 1.
+ */
+
+#ifndef YY_SKIP_YYWRAP
+#ifdef __cplusplus
+extern "C" int yywrap YY_PROTO(( void ));
+#else
+extern int yywrap YY_PROTO(( void ));
+#endif
+#endif
+
+#ifndef YY_NO_UNPUT
+static void yyunput YY_PROTO(( int c, char *buf_ptr ));
+#endif
+
+#ifndef yytext_ptr
+static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
+#endif
+
+#ifdef YY_NEED_STRLEN
+static int yy_flex_strlen YY_PROTO(( yyconst char * ));
+#endif
+
+#ifndef YY_NO_INPUT
+#ifdef __cplusplus
+static int yyinput YY_PROTO(( void ));
+#else
+static int input YY_PROTO(( void ));
+#endif
+#endif
+
+#if YY_STACK_USED
+static int yy_start_stack_ptr = 0;
+static int yy_start_stack_depth = 0;
+static int *yy_start_stack = 0;
+#ifndef YY_NO_PUSH_STATE
+static void yy_push_state YY_PROTO(( int new_state ));
+#endif
+#ifndef YY_NO_POP_STATE
+static void yy_pop_state YY_PROTO(( void ));
+#endif
+#ifndef YY_NO_TOP_STATE
+static int yy_top_state YY_PROTO(( void ));
+#endif
+
+#else
+#define YY_NO_PUSH_STATE 1
+#define YY_NO_POP_STATE 1
+#define YY_NO_TOP_STATE 1
+#endif
+
+#ifdef YY_MALLOC_DECL
+YY_MALLOC_DECL
+#else
+#if __STDC__
+#ifndef __cplusplus
+#include <stdlib.h>
+#endif
+#else
+/* Just try to get by without declaring the routines.  This will fail
+ * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
+ * or sizeof(void*) != sizeof(int).
+ */
+#endif
+#endif
+
+/* Amount of stuff to slurp up with each read. */
+#ifndef YY_READ_BUF_SIZE
+#define YY_READ_BUF_SIZE 8192
+#endif
+
+/* Copy whatever the last rule matched to the standard output. */
+
+#ifndef ECHO
+/* This used to be an fputs(), but since the string might contain NUL's,
+ * we now use fwrite().
+ */
+#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
+#endif
+
+/* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
+ * is returned in "result".
+ */
+#ifndef YY_INPUT
+#define YY_INPUT(buf,result,max_size) \
+       if ( yy_current_buffer->yy_is_interactive ) \
+               { \
+               int c = '*', n; \
+               for ( n = 0; n < max_size && \
+                            (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
+                       buf[n] = (char) c; \
+               if ( c == '\n' ) \
+                       buf[n++] = (char) c; \
+               if ( c == EOF && ferror( yyin ) ) \
+                       YY_FATAL_ERROR( "input in flex scanner failed" ); \
+               result = n; \
+               } \
+       else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
+                 && ferror( yyin ) ) \
+               YY_FATAL_ERROR( "input in flex scanner failed" );
+#endif
+
+/* No semi-colon after return; correct usage is to write "yyterminate();" -
+ * we don't want an extra ';' after the "return" because that will cause
+ * some compilers to complain about unreachable statements.
+ */
+#ifndef yyterminate
+#define yyterminate() return YY_NULL
+#endif
+
+/* Number of entries by which start-condition stack grows. */
+#ifndef YY_START_STACK_INCR
+#define YY_START_STACK_INCR 25
+#endif
+
+/* Report a fatal error. */
+#ifndef YY_FATAL_ERROR
+#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
+#endif
+
+/* Default declaration of generated scanner - a define so the user can
+ * easily add parameters.
+ */
+#ifndef YY_DECL
+#define YY_DECL int yylex YY_PROTO(( void ))
+#endif
+
+/* Code executed at the beginning of each rule, after yytext and yyleng
+ * have been set up.
+ */
+#ifndef YY_USER_ACTION
+#define YY_USER_ACTION
+#endif
+
+/* Code executed at the end of each rule. */
+#ifndef YY_BREAK
+#define YY_BREAK break;
+#endif
+
+#define YY_RULE_SETUP \
+       YY_USER_ACTION
+
+YY_DECL
+       {
+       register yy_state_type yy_current_state;
+       register char *yy_cp, *yy_bp;
+       register int yy_act;
+
+#line 10 "xlockgen.lex"
+
+#line 571 "lex.yy.c"
+
+       if ( yy_init )
+               {
+               yy_init = 0;
+
+#ifdef YY_USER_INIT
+               YY_USER_INIT;
+#endif
+
+               if ( ! yy_start )
+                       yy_start = 1;   /* first start state */
+
+               if ( ! yyin )
+                       yyin = stdin;
+
+               if ( ! yyout )
+                       yyout = stdout;
+
+               if ( ! yy_current_buffer )
+                       yy_current_buffer =
+                               yy_create_buffer( yyin, YY_BUF_SIZE );
+
+               yy_load_buffer_state();
+               }
+
+       while ( 1 )             /* loops until end-of-file is reached */
+               {
+               yy_cp = yy_c_buf_p;
+
+               /* Support of yytext. */
+               *yy_cp = yy_hold_char;
+
+               /* yy_bp points to the position in yy_ch_buf of the start of
+                * the current run.
+                */
+               yy_bp = yy_cp;
+
+               yy_current_state = yy_start;
+               yy_state_ptr = yy_state_buf;
+               *yy_state_ptr++ = yy_current_state;
+yy_match:
+               do
+                       {
+                       register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
+                       while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+                               {
+                               yy_current_state = (int) yy_def[yy_current_state];
+                               if ( yy_current_state >= 29 )
+                                       yy_c = yy_meta[(unsigned int) yy_c];
+                               }
+                       yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+                       *yy_state_ptr++ = yy_current_state;
+                       ++yy_cp;
+                       }
+               while ( yy_base[yy_current_state] != 36 );
+
+yy_find_action:
+               yy_current_state = *--yy_state_ptr;
+               yy_lp = yy_accept[yy_current_state];
+find_rule: /* we branch to this label when backing up */
+               for ( ; ; ) /* until we find what rule we matched */
+                       {
+                       if ( yy_lp && yy_lp < yy_accept[yy_current_state + 1] )
+                               {
+                               yy_act = yy_acclist[yy_lp];
+                                       {
+                                       yy_full_match = yy_cp;
+                                       break;
+                                       }
+                               }
+                       --yy_cp;
+                       yy_current_state = *--yy_state_ptr;
+                       yy_lp = yy_accept[yy_current_state];
+                       }
+
+               YY_DO_BEFORE_ACTION;
+
+               if ( yy_act != YY_END_OF_BUFFER )
+                       {
+                       int yyl;
+                       for ( yyl = 0; yyl < yyleng; ++yyl )
+                               if ( yytext[yyl] == '\n' )
+                                       ++yylineno;
+                       }
+
+do_action:     /* This label is used only to access EOF actions. */
+
+
+               switch ( yy_act )
+       { /* beginning of action switch */
+case 1:
+YY_RULE_SETUP
+#line 11 "xlockgen.lex"
+{int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {if (LockProcs[i].define!=NULL) printf("%s\n",LockProcs[i].define);\r
+                       if (i!=numprocs-1) \r
+                       printf("%s%s%s\n",Begin,LockProcs[i].cmdline_arg,Sep);\r
+                       else\r
+                       printf("%s%s%s\n",Begin,LockProcs[i].cmdline_arg,Sep);\r
+                       /*printf("%s%s%s\n",Begin,LockProcs[i].cmdline_arg,End);*/\r
+                       if (LockProcs[i].define!=NULL) printf("#endif\n");\r
+                       }\r
+               }\r
+       YY_BREAK
+case 2:
+YY_RULE_SETUP
+#line 23 "xlockgen.lex"
+{int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {if (LockProcs[i].define!=NULL) printf("%s\n",LockProcs[i].define);\r
+                       if (i!=numprocs-1)\r
+                       {\r
+                       printf("{\"%s\",",LockProcs[i].cmdline_arg);\r
+                       printf("\"%s\"},\n",LockProcs[i].desc);\r
+                       }\r
+                       else\r
+                       {\r
+                       printf("{\"%s\",",LockProcs[i].cmdline_arg);\r
+                       printf("\"%s\"},\n",LockProcs[i].desc);\r
+                       }\r
+                       if (LockProcs[i].define!=NULL) printf("#endif\n");\r
+                }\r
+               }\r
+       YY_BREAK
+case 3:
+YY_RULE_SETUP
+#line 40 "xlockgen.lex"
+{\r
+       int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {if (i!=numprocs-1)\r
+                       printf("%s\\\n",LockProcs[i].cmdline_arg);\r
+                       else\r
+                       printf("%s\n",LockProcs[i].cmdline_arg);\r
+                       }\r
+       }\r
+       YY_BREAK
+case 4:
+YY_RULE_SETUP
+#line 50 "xlockgen.lex"
+{\r
+               int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {\r
+                       printf("lst.addItem(\"%s\");\n",LockProcs[i].cmdline_arg);\r
+                       }\r
+               }\r
+       YY_BREAK
+case 5:
+YY_RULE_SETUP
+#line 58 "xlockgen.lex"
+ECHO;
+       YY_BREAK
+#line 730 "lex.yy.c"
+                       case YY_STATE_EOF(INITIAL):
+                               yyterminate();
+
+       case YY_END_OF_BUFFER:
+               {
+               /* Amount of text matched not including the EOB char. */
+               int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
+
+               /* Undo the effects of YY_DO_BEFORE_ACTION. */
+               *yy_cp = yy_hold_char;
+               YY_RESTORE_YY_MORE_OFFSET
+
+               if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
+                       {
+                       /* We're scanning a new file or input source.  It's
+                        * possible that this happened because the user
+                        * just pointed yyin at a new source and called
+                        * yylex().  If so, then we have to assure
+                        * consistency between yy_current_buffer and our
+                        * globals.  Here is the right place to do so, because
+                        * this is the first action (other than possibly a
+                        * back-up) that will match for the new input source.
+                        */
+                       yy_n_chars = yy_current_buffer->yy_n_chars;
+                       yy_current_buffer->yy_input_file = yyin;
+                       yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
+                       }
+
+               /* Note that here we test for yy_c_buf_p "<=" to the position
+                * of the first EOB in the buffer, since yy_c_buf_p will
+                * already have been incremented past the NUL character
+                * (since all states make transitions on EOB to the
+                * end-of-buffer state).  Contrast this with the test
+                * in input().
+                */
+               if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
+                       { /* This was really a NUL. */
+                       yy_state_type yy_next_state;
+
+                       yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
+
+                       yy_current_state = yy_get_previous_state();
+
+                       /* Okay, we're now positioned to make the NUL
+                        * transition.  We couldn't have
+                        * yy_get_previous_state() go ahead and do it
+                        * for us because it doesn't know how to deal
+                        * with the possibility of jamming (and we don't
+                        * want to build jamming into it because then it
+                        * will run more slowly).
+                        */
+
+                       yy_next_state = yy_try_NUL_trans( yy_current_state );
+
+                       yy_bp = yytext_ptr + YY_MORE_ADJ;
+
+                       if ( yy_next_state )
+                               {
+                               /* Consume the NUL. */
+                               yy_cp = ++yy_c_buf_p;
+                               yy_current_state = yy_next_state;
+                               goto yy_match;
+                               }
+
+                       else
+                               {
+                               yy_cp = yy_c_buf_p;
+                               goto yy_find_action;
+                               }
+                       }
+
+               else switch ( yy_get_next_buffer() )
+                       {
+                       case EOB_ACT_END_OF_FILE:
+                               {
+                               yy_did_buffer_switch_on_eof = 0;
+
+                               if ( yywrap() )
+                                       {
+                                       /* Note: because we've taken care in
+                                        * yy_get_next_buffer() to have set up
+                                        * yytext, we can now set up
+                                        * yy_c_buf_p so that if some total
+                                        * hoser (like flex itself) wants to
+                                        * call the scanner after we return the
+                                        * YY_NULL, it'll still work - another
+                                        * YY_NULL will get returned.
+                                        */
+                                       yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
+
+                                       yy_act = YY_STATE_EOF(YY_START);
+                                       goto do_action;
+                                       }
+
+                               else
+                                       {
+                                       if ( ! yy_did_buffer_switch_on_eof )
+                                               YY_NEW_FILE;
+                                       }
+                               break;
+                               }
+
+                       case EOB_ACT_CONTINUE_SCAN:
+                               yy_c_buf_p =
+                                       yytext_ptr + yy_amount_of_matched_text;
+
+                               yy_current_state = yy_get_previous_state();
+
+                               yy_cp = yy_c_buf_p;
+                               yy_bp = yytext_ptr + YY_MORE_ADJ;
+                               goto yy_match;
+
+                       case EOB_ACT_LAST_MATCH:
+                               yy_c_buf_p =
+                               &yy_current_buffer->yy_ch_buf[yy_n_chars];
+
+                               yy_current_state = yy_get_previous_state();
+
+                               yy_cp = yy_c_buf_p;
+                               yy_bp = yytext_ptr + YY_MORE_ADJ;
+                               goto yy_find_action;
+                       }
+               break;
+               }
+
+       default:
+               YY_FATAL_ERROR(
+                       "fatal flex scanner internal error--no action found" );
+       } /* end of action switch */
+               } /* end of scanning one token */
+       } /* end of yylex */
+
+
+/* yy_get_next_buffer - try to read in a new buffer
+ *
+ * Returns a code representing an action:
+ *     EOB_ACT_LAST_MATCH -
+ *     EOB_ACT_CONTINUE_SCAN - continue scanning from current position
+ *     EOB_ACT_END_OF_FILE - end of file
+ */
+
+static int yy_get_next_buffer()
+       {
+       register char *dest = yy_current_buffer->yy_ch_buf;
+       register char *source = yytext_ptr;
+       register int number_to_move, i;
+       int ret_val;
+
+       if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
+               YY_FATAL_ERROR(
+               "fatal flex scanner internal error--end of buffer missed" );
+
+       if ( yy_current_buffer->yy_fill_buffer == 0 )
+               { /* Don't try to fill the buffer, so this is an EOF. */
+               if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
+                       {
+                       /* We matched a single character, the EOB, so
+                        * treat this as a final EOF.
+                        */
+                       return EOB_ACT_END_OF_FILE;
+                       }
+
+               else
+                       {
+                       /* We matched some text prior to the EOB, first
+                        * process it.
+                        */
+                       return EOB_ACT_LAST_MATCH;
+                       }
+               }
+
+       /* Try to read more data. */
+
+       /* First move last chars to start of buffer. */
+       number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
+
+       for ( i = 0; i < number_to_move; ++i )
+               *(dest++) = *(source++);
+
+       if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
+               /* don't do the read, it's not guaranteed to return an EOF,
+                * just force an EOF
+                */
+               yy_current_buffer->yy_n_chars = yy_n_chars = 0;
+
+       else
+               {
+               int num_to_read =
+                       yy_current_buffer->yy_buf_size - number_to_move - 1;
+
+               while ( num_to_read <= 0 )
+                       { /* Not enough room in the buffer - grow it. */
+#ifdef YY_USES_REJECT
+                       YY_FATAL_ERROR(
+"input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
+#else
+
+                       /* just a shorter name for the current buffer */
+                       YY_BUFFER_STATE b = yy_current_buffer;
+
+                       int yy_c_buf_p_offset =
+                               (int) (yy_c_buf_p - b->yy_ch_buf);
+
+                       if ( b->yy_is_our_buffer )
+                               {
+                               int new_size = b->yy_buf_size * 2;
+
+                               if ( new_size <= 0 )
+                                       b->yy_buf_size += b->yy_buf_size / 8;
+                               else
+                                       b->yy_buf_size *= 2;
+
+                               b->yy_ch_buf = (char *)
+                                       /* Include room in for 2 EOB chars. */
+                                       yy_flex_realloc( (void *) b->yy_ch_buf,
+                                                        b->yy_buf_size + 2 );
+                               }
+                       else
+                               /* Can't grow it, we don't own it. */
+                               b->yy_ch_buf = 0;
+
+                       if ( ! b->yy_ch_buf )
+                               YY_FATAL_ERROR(
+                               "fatal error - scanner input buffer overflow" );
+
+                       yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
+
+                       num_to_read = yy_current_buffer->yy_buf_size -
+                                               number_to_move - 1;
+#endif
+                       }
+
+               if ( num_to_read > YY_READ_BUF_SIZE )
+                       num_to_read = YY_READ_BUF_SIZE;
+
+               /* Read in more data. */
+               YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
+                       yy_n_chars, num_to_read );
+
+               yy_current_buffer->yy_n_chars = yy_n_chars;
+               }
+
+       if ( yy_n_chars == 0 )
+               {
+               if ( number_to_move == YY_MORE_ADJ )
+                       {
+                       ret_val = EOB_ACT_END_OF_FILE;
+                       yyrestart( yyin );
+                       }
+
+               else
+                       {
+                       ret_val = EOB_ACT_LAST_MATCH;
+                       yy_current_buffer->yy_buffer_status =
+                               YY_BUFFER_EOF_PENDING;
+                       }
+               }
+
+       else
+               ret_val = EOB_ACT_CONTINUE_SCAN;
+
+       yy_n_chars += number_to_move;
+       yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
+       yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
+
+       yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
+
+       return ret_val;
+       }
+
+
+/* yy_get_previous_state - get the state just before the EOB char was reached */
+
+static yy_state_type yy_get_previous_state()
+       {
+       register yy_state_type yy_current_state;
+       register char *yy_cp;
+
+       yy_current_state = yy_start;
+       yy_state_ptr = yy_state_buf;
+       *yy_state_ptr++ = yy_current_state;
+
+       for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
+               {
+               register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
+               while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+                       {
+                       yy_current_state = (int) yy_def[yy_current_state];
+                       if ( yy_current_state >= 29 )
+                               yy_c = yy_meta[(unsigned int) yy_c];
+                       }
+               yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+               *yy_state_ptr++ = yy_current_state;
+               }
+
+       return yy_current_state;
+       }
+
+
+/* yy_try_NUL_trans - try to make a transition on the NUL character
+ *
+ * synopsis
+ *     next_state = yy_try_NUL_trans( current_state );
+ */
+
+#ifdef YY_USE_PROTOS
+static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
+#else
+static yy_state_type yy_try_NUL_trans( yy_current_state )
+yy_state_type yy_current_state;
+#endif
+       {
+       register int yy_is_jam;
+
+       register YY_CHAR yy_c = 1;
+       while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+               {
+               yy_current_state = (int) yy_def[yy_current_state];
+               if ( yy_current_state >= 29 )
+                       yy_c = yy_meta[(unsigned int) yy_c];
+               }
+       yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+       yy_is_jam = (yy_current_state == 28);
+       if ( ! yy_is_jam )
+               *yy_state_ptr++ = yy_current_state;
+
+       return yy_is_jam ? 0 : yy_current_state;
+       }
+
+
+#ifndef YY_NO_UNPUT
+#ifdef YY_USE_PROTOS
+static void yyunput( int c, register char *yy_bp )
+#else
+static void yyunput( c, yy_bp )
+int c;
+register char *yy_bp;
+#endif
+       {
+       register char *yy_cp = yy_c_buf_p;
+
+       /* undo effects of setting up yytext */
+       *yy_cp = yy_hold_char;
+
+       if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
+               { /* need to shift things up to make room */
+               /* +2 for EOB chars. */
+               register int number_to_move = yy_n_chars + 2;
+               register char *dest = &yy_current_buffer->yy_ch_buf[
+                                       yy_current_buffer->yy_buf_size + 2];
+               register char *source =
+                               &yy_current_buffer->yy_ch_buf[number_to_move];
+
+               while ( source > yy_current_buffer->yy_ch_buf )
+                       *--dest = *--source;
+
+               yy_cp += (int) (dest - source);
+               yy_bp += (int) (dest - source);
+               yy_current_buffer->yy_n_chars =
+                       yy_n_chars = yy_current_buffer->yy_buf_size;
+
+               if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
+                       YY_FATAL_ERROR( "flex scanner push-back overflow" );
+               }
+
+       *--yy_cp = (char) c;
+
+       if ( c == '\n' )
+               --yylineno;
+
+       yytext_ptr = yy_bp;
+       yy_hold_char = *yy_cp;
+       yy_c_buf_p = yy_cp;
+       }
+#endif /* ifndef YY_NO_UNPUT */
+
+
+#ifdef __cplusplus
+static int yyinput()
+#else
+static int input()
+#endif
+       {
+       int c;
+
+       *yy_c_buf_p = yy_hold_char;
+
+       if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
+               {
+               /* yy_c_buf_p now points to the character we want to return.
+                * If this occurs *before* the EOB characters, then it's a
+                * valid NUL; if not, then we've hit the end of the buffer.
+                */
+               if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
+                       /* This was really a NUL. */
+                       *yy_c_buf_p = '\0';
+
+               else
+                       { /* need more input */
+                       int offset = yy_c_buf_p - yytext_ptr;
+                       ++yy_c_buf_p;
+
+                       switch ( yy_get_next_buffer() )
+                               {
+                               case EOB_ACT_LAST_MATCH:
+                                       /* This happens because yy_g_n_b()
+                                        * sees that we've accumulated a
+                                        * token and flags that we need to
+                                        * try matching the token before
+                                        * proceeding.  But for input(),
+                                        * there's no matching to consider.
+                                        * So convert the EOB_ACT_LAST_MATCH
+                                        * to EOB_ACT_END_OF_FILE.
+                                        */
+
+                                       /* Reset buffer status. */
+                                       yyrestart( yyin );
+
+                                       /* fall through */
+
+                               case EOB_ACT_END_OF_FILE:
+                                       {
+                                       if ( yywrap() )
+                                               return EOF;
+
+                                       if ( ! yy_did_buffer_switch_on_eof )
+                                               YY_NEW_FILE;
+#ifdef __cplusplus
+                                       return yyinput();
+#else
+                                       return input();
+#endif
+                                       }
+
+                               case EOB_ACT_CONTINUE_SCAN:
+                                       yy_c_buf_p = yytext_ptr + offset;
+                                       break;
+                               }
+                       }
+               }
+
+       c = *(unsigned char *) yy_c_buf_p;      /* cast for 8-bit char's */
+       *yy_c_buf_p = '\0';     /* preserve yytext */
+       yy_hold_char = *++yy_c_buf_p;
+
+       if ( c == '\n' )
+               ++yylineno;
+
+       return c;
+       }
+
+
+#ifdef YY_USE_PROTOS
+void yyrestart( FILE *input_file )
+#else
+void yyrestart( input_file )
+FILE *input_file;
+#endif
+       {
+       if ( ! yy_current_buffer )
+               yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
+
+       yy_init_buffer( yy_current_buffer, input_file );
+       yy_load_buffer_state();
+       }
+
+
+#ifdef YY_USE_PROTOS
+void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
+#else
+void yy_switch_to_buffer( new_buffer )
+YY_BUFFER_STATE new_buffer;
+#endif
+       {
+       if ( yy_current_buffer == new_buffer )
+               return;
+
+       if ( yy_current_buffer )
+               {
+               /* Flush out information for old buffer. */
+               *yy_c_buf_p = yy_hold_char;
+               yy_current_buffer->yy_buf_pos = yy_c_buf_p;
+               yy_current_buffer->yy_n_chars = yy_n_chars;
+               }
+
+       yy_current_buffer = new_buffer;
+       yy_load_buffer_state();
+
+       /* We don't actually know whether we did this switch during
+        * EOF (yywrap()) processing, but the only time this flag
+        * is looked at is after yywrap() is called, so it's safe
+        * to go ahead and always set it.
+        */
+       yy_did_buffer_switch_on_eof = 1;
+       }
+
+
+#ifdef YY_USE_PROTOS
+void yy_load_buffer_state( void )
+#else
+void yy_load_buffer_state()
+#endif
+       {
+       yy_n_chars = yy_current_buffer->yy_n_chars;
+       yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
+       yyin = yy_current_buffer->yy_input_file;
+       yy_hold_char = *yy_c_buf_p;
+       }
+
+
+#ifdef YY_USE_PROTOS
+YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
+#else
+YY_BUFFER_STATE yy_create_buffer( file, size )
+FILE *file;
+int size;
+#endif
+       {
+       YY_BUFFER_STATE b;
+
+       b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
+       if ( ! b )
+               YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
+
+       b->yy_buf_size = size;
+
+       /* yy_ch_buf has to be 2 characters longer than the size given because
+        * we need to put in 2 end-of-buffer characters.
+        */
+       b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
+       if ( ! b->yy_ch_buf )
+               YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
+
+       b->yy_is_our_buffer = 1;
+
+       yy_init_buffer( b, file );
+
+       return b;
+       }
+
+
+#ifdef YY_USE_PROTOS
+void yy_delete_buffer( YY_BUFFER_STATE b )
+#else
+void yy_delete_buffer( b )
+YY_BUFFER_STATE b;
+#endif
+       {
+       if ( ! b )
+               return;
+
+       if ( b == yy_current_buffer )
+               yy_current_buffer = (YY_BUFFER_STATE) 0;
+
+       if ( b->yy_is_our_buffer )
+               yy_flex_free( (void *) b->yy_ch_buf );
+
+       yy_flex_free( (void *) b );
+       }
+
+
+#ifndef YY_ALWAYS_INTERACTIVE
+#ifndef YY_NEVER_INTERACTIVE
+extern int isatty YY_PROTO(( int ));
+#endif
+#endif
+
+#ifdef YY_USE_PROTOS
+void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
+#else
+void yy_init_buffer( b, file )
+YY_BUFFER_STATE b;
+FILE *file;
+#endif
+
+
+       {
+       yy_flush_buffer( b );
+
+       b->yy_input_file = file;
+       b->yy_fill_buffer = 1;
+
+#if YY_ALWAYS_INTERACTIVE
+       b->yy_is_interactive = 1;
+#else
+#if YY_NEVER_INTERACTIVE
+       b->yy_is_interactive = 0;
+#else
+       b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
+#endif
+#endif
+       }
+
+
+#ifdef YY_USE_PROTOS
+void yy_flush_buffer( YY_BUFFER_STATE b )
+#else
+void yy_flush_buffer( b )
+YY_BUFFER_STATE b;
+#endif
+
+       {
+       if ( ! b )
+               return;
+
+       b->yy_n_chars = 0;
+
+       /* We always need two end-of-buffer characters.  The first causes
+        * a transition to the end-of-buffer state.  The second causes
+        * a jam in that state.
+        */
+       b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
+       b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
+
+       b->yy_buf_pos = &b->yy_ch_buf[0];
+
+       b->yy_at_bol = 1;
+       b->yy_buffer_status = YY_BUFFER_NEW;
+
+       if ( b == yy_current_buffer )
+               yy_load_buffer_state();
+       }
+
+
+#ifndef YY_NO_SCAN_BUFFER
+#ifdef YY_USE_PROTOS
+YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
+#else
+YY_BUFFER_STATE yy_scan_buffer( base, size )
+char *base;
+yy_size_t size;
+#endif
+       {
+       YY_BUFFER_STATE b;
+
+       if ( size < 2 ||
+            base[size-2] != YY_END_OF_BUFFER_CHAR ||
+            base[size-1] != YY_END_OF_BUFFER_CHAR )
+               /* They forgot to leave room for the EOB's. */
+               return 0;
+
+       b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
+       if ( ! b )
+               YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
+
+       b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
+       b->yy_buf_pos = b->yy_ch_buf = base;
+       b->yy_is_our_buffer = 0;
+       b->yy_input_file = 0;
+       b->yy_n_chars = b->yy_buf_size;
+       b->yy_is_interactive = 0;
+       b->yy_at_bol = 1;
+       b->yy_fill_buffer = 0;
+       b->yy_buffer_status = YY_BUFFER_NEW;
+
+       yy_switch_to_buffer( b );
+
+       return b;
+       }
+#endif
+
+
+#ifndef YY_NO_SCAN_STRING
+#ifdef YY_USE_PROTOS
+YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
+#else
+YY_BUFFER_STATE yy_scan_string( yy_str )
+yyconst char *yy_str;
+#endif
+       {
+       int len;
+       for ( len = 0; yy_str[len]; ++len )
+               ;
+
+       return yy_scan_bytes( yy_str, len );
+       }
+#endif
+
+
+#ifndef YY_NO_SCAN_BYTES
+#ifdef YY_USE_PROTOS
+YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
+#else
+YY_BUFFER_STATE yy_scan_bytes( bytes, len )
+yyconst char *bytes;
+int len;
+#endif
+       {
+       YY_BUFFER_STATE b;
+       char *buf;
+       yy_size_t n;
+       int i;
+
+       /* Get memory for full buffer, including space for trailing EOB's. */
+       n = len + 2;
+       buf = (char *) yy_flex_alloc( n );
+       if ( ! buf )
+               YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
+
+       for ( i = 0; i < len; ++i )
+               buf[i] = bytes[i];
+
+       buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
+
+       b = yy_scan_buffer( buf, n );
+       if ( ! b )
+               YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
+
+       /* It's okay to grow etc. this buffer, and we should throw it
+        * away when we're done.
+        */
+       b->yy_is_our_buffer = 1;
+
+       return b;
+       }
+#endif
+
+
+#ifndef YY_NO_PUSH_STATE
+#ifdef YY_USE_PROTOS
+static void yy_push_state( int new_state )
+#else
+static void yy_push_state( new_state )
+int new_state;
+#endif
+       {
+       if ( yy_start_stack_ptr >= yy_start_stack_depth )
+               {
+               yy_size_t new_size;
+
+               yy_start_stack_depth += YY_START_STACK_INCR;
+               new_size = yy_start_stack_depth * sizeof( int );
+
+               if ( ! yy_start_stack )
+                       yy_start_stack = (int *) yy_flex_alloc( new_size );
+
+               else
+                       yy_start_stack = (int *) yy_flex_realloc(
+                                       (void *) yy_start_stack, new_size );
+
+               if ( ! yy_start_stack )
+                       YY_FATAL_ERROR(
+                       "out of memory expanding start-condition stack" );
+               }
+
+       yy_start_stack[yy_start_stack_ptr++] = YY_START;
+
+       BEGIN(new_state);
+       }
+#endif
+
+
+#ifndef YY_NO_POP_STATE
+static void yy_pop_state()
+       {
+       if ( --yy_start_stack_ptr < 0 )
+               YY_FATAL_ERROR( "start-condition stack underflow" );
+
+       BEGIN(yy_start_stack[yy_start_stack_ptr]);
+       }
+#endif
+
+
+#ifndef YY_NO_TOP_STATE
+static int yy_top_state()
+       {
+       return yy_start_stack[yy_start_stack_ptr - 1];
+       }
+#endif
+
+#ifndef YY_EXIT_FAILURE
+#define YY_EXIT_FAILURE 2
+#endif
+
+#ifdef YY_USE_PROTOS
+static void yy_fatal_error( yyconst char msg[] )
+#else
+static void yy_fatal_error( msg )
+char msg[];
+#endif
+       {
+       (void) fprintf( stderr, "%s\n", msg );
+       exit( YY_EXIT_FAILURE );
+       }
+
+
+
+/* Redefine yyless() so it works in section 3 code. */
+
+#undef yyless
+#define yyless(n) \
+       do \
+               { \
+               /* Undo effects of setting up yytext. */ \
+               yytext[yyleng] = yy_hold_char; \
+               yy_c_buf_p = yytext + n; \
+               yy_hold_char = *yy_c_buf_p; \
+               *yy_c_buf_p = '\0'; \
+               yyleng = n; \
+               } \
+       while ( 0 )
+
+
+/* Internal utility routines. */
+
+#ifndef yytext_ptr
+#ifdef YY_USE_PROTOS
+static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
+#else
+static void yy_flex_strncpy( s1, s2, n )
+char *s1;
+yyconst char *s2;
+int n;
+#endif
+       {
+       register int i;
+       for ( i = 0; i < n; ++i )
+               s1[i] = s2[i];
+       }
+#endif
+
+#ifdef YY_NEED_STRLEN
+#ifdef YY_USE_PROTOS
+static int yy_flex_strlen( yyconst char *s )
+#else
+static int yy_flex_strlen( s )
+yyconst char *s;
+#endif
+       {
+       register int n;
+       for ( n = 0; s[n]; ++n )
+               ;
+
+       return n;
+       }
+#endif
+
+
+#ifdef YY_USE_PROTOS
+static void *yy_flex_alloc( yy_size_t size )
+#else
+static void *yy_flex_alloc( size )
+yy_size_t size;
+#endif
+       {
+       return (void *) malloc( size );
+       }
+
+#ifdef YY_USE_PROTOS
+static void *yy_flex_realloc( void *ptr, yy_size_t size )
+#else
+static void *yy_flex_realloc( ptr, size )
+void *ptr;
+yy_size_t size;
+#endif
+       {
+       /* The cast to (char *) in the following accommodates both
+        * implementations that use char* generic pointers, and those
+        * that use void* generic pointers.  It works with the latter
+        * because both ANSI C and C++ allow castless assignment from
+        * any pointer type to void*, and deal with argument conversions
+        * as though doing an assignment.
+        */
+       return (void *) realloc( (char *) ptr, size );
+       }
+
+#ifdef YY_USE_PROTOS
+static void yy_flex_free( void *ptr )
+#else
+static void yy_flex_free( ptr )
+void *ptr;
+#endif
+       {
+       free( ptr );
+       }
+
+#if YY_MAIN
+int main()
+       {
+       yylex();
+       return 0;
+       }
+#endif
+#line 58 "xlockgen.lex"
+
+main(int argc,char *argv[])\r
+{\r
+yylex();\r
+}\r
+\r
diff --git a/xlockmore-4.14/etc/genlauncher/lmode.h b/xlockmore-4.14/etc/genlauncher/lmode.h
new file mode 100644 (file)
index 0000000..ee0c17f
--- /dev/null
@@ -0,0 +1,395 @@
+/*-
+ * @(#)mode.h 4.00 97/01/01 xlockmore
+ *
+ * mode.h - mode management for xlock, the X Window System lockscreen.
+ *
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * See xlock.c for copying information.
+ *
+ * Revision History:
+ *
+ * Changes maintained by David Bagley <bagleyd@tux.org>
+ * 18-Mar-96: Ron Hitchens <ron@idiom.com>
+ *    Extensive revision to define new data types for
+ *    the new mode calling scheme.
+ * 02-Jun-95: Extracted out of resource.c.
+ *
+ */
+
+/*-
+ * Declare external interface routines for supported screen savers.
+ */
+
+/* -------------------------------------------------------------------- */
+
+#define HAVE_CXX
+#define USE_XPM
+#define USE_GL
+#define USE_UNSTABLE
+#define USE_BOMB
+
+typedef struct {
+       int      dummy;
+} ModeSpecOpt;
+
+struct LockStruct_s;
+struct ModeInfo_s;
+
+typedef void (ModeHook) (struct ModeInfo_s *);
+typedef void (HookProc) (struct LockStruct_s *, struct ModeInfo_s *);
+
+typedef struct LockStruct_s {
+       char       *cmdline_arg;        /* mode name */
+#if 0
+       char       *init_hook;  /* func to init a mode */
+       char       *callback_hook;      /* func to run (tick) a mode */
+       char       *release_hook;       /* func to shutdown a mode */
+       char       *refresh_hook;       /* tells mode to repaint */
+       char       *change_hook;        /* user wants mode to change */
+       char       *unused_hook;        /* for future expansion */
+       ModeSpecOpt *msopt;     /* this mode's def resources */
+#endif
+       int      def_delay;     /* default delay for mode */
+       int      def_count;
+       int      def_cycles;
+       int      def_size;
+       int      def_ncolors;
+       float       def_saturation;
+       char       *def_bitmap;
+       char       *desc;       /* text description of mode */
+       unsigned int flags;     /* state flags for this mode */
+       void       *userdata;   /* for use by the mode */
+       char       *define;
+} LockStruct;
+
+LockStruct  LockProcs[] =
+{
+       {"ant",
+        1000, -3, 40000, -7, 64, 1.0, "",
+        "Shows Langton's and Turk's generalized ants", 0, NULL, NULL},
+#ifdef USE_GL
+       {"atlantis",
+        1000, 4, 100, 6000, 64, 1.0, "",
+        "Shows moving sharks/whales/dolphin", 0, NULL, "#ifdef USE_GL"},
+#endif
+       {"ball",
+        10000, 10, 20, -100, 64, 1.0, "",
+        "Shows bouncing balls", 0, NULL, NULL},
+       {"bat",
+        100000, -8, 1, 0, 64, 1.0, "",
+        "Shows bouncing flying bats", 0, NULL, NULL},
+       {"blot",
+        200000, 6, 30, 1, 64, 0.3, "",
+        "Shows Rorschach's ink blot test", 0, NULL, NULL},
+       {"bouboule",
+        10000, 100, 1, 15, 64, 1.0, "",
+        "Shows Mimi's bouboule of moving stars", 0, NULL, NULL},
+       {"bounce",
+        5000, -10, 1, 0, 64, 1.0, "",
+        "Shows bouncing footballs", 0, NULL, NULL},
+       {"braid",
+        1000, 15, 100, -7, 64, 1.0, "",
+        "Shows random braids and knots", 0, NULL, NULL},
+       {"bubble",
+        100000, 25, 1, 100, 64, 0.6, "",
+        "Shows popping bubbles", 0, NULL, NULL},
+#if defined( USE_GL ) && defined( HAVE_CXX )
+       {"bubble3d",
+        1000, 1, 2, 1, 64, 1.0, "",
+        "Richard Jones's GL bubbles", 0, NULL, "#if defined( USE_GL ) && defined( HAVE_CXX )"},
+#endif
+       {"bug",
+        75000, 10, 32767, -4, 64, 1.0, "",
+        "Shows Palmiter's bug evolution and garden of Eden", 0, NULL, NULL},
+#ifdef USE_GL
+       {"cage",
+        1000, 1, 1, 1, 64, 1.0, "",
+        "Shows the Impossible Cage, an Escher-like GL scene", 0, NULL, "#ifdef USE_GL"},
+#endif
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       {"cartoon",
+        10000, 1, 1, 1, 64, 1.0, "",
+        "Shows bouncing cartoons", 0, NULL, "#if defined( USE_XPM ) || defined( USE_XPMINC )"},
+#endif
+       {"clock",
+        100000, -16, 200, -200, 64, 1.0, "",
+        "Shows Packard's clock", 0, NULL, NULL},
+       {"coral",
+        60000, -3, 1, 35, 64, 0.6, "",
+        "Shows a coral reef", 0, NULL, NULL},
+       {"crystal",
+        60000, -500, 200, -15, 64, 1.0, "",
+        "Shows polygons in 2D plane groups", 0, NULL, NULL},
+       {"daisy",
+        100000, 300, 350, 1, 64, 1.0, "",
+        "Shows a meadow of daisies", 0, NULL, NULL},
+       {"dclock",
+        10000, 1, 10000, 1, 64, 0.3, "",
+        "Shows a floating digital clock or message", 0, NULL, NULL},
+       {"decay",
+        200000, 6, 30, 1, 64, 0.3, "",
+        "Shows a decaying screen", 0, NULL, NULL},
+       {"deco",
+        1000000, -30, 2, -10, 64, 0.6, "",
+        "Shows art as ugly as sin", 0, NULL, NULL},
+       {"demon",
+        50000, 0, 1000, -7, 64, 1.0, "",
+        "Shows Griffeath's cellular automata", 0, NULL, NULL},
+       {"dilemma",
+        200000, -2, 1000, 0, 64, 1.0, "",
+        "Shows Lloyd's Prisoner's Dilemma simulation", 0, NULL, NULL},
+       {"discrete",
+        1000, 4096, 2500, 1, 64, 1.0, "",
+        "Shows various discrete maps", 0, NULL, NULL},
+       {"drift",
+        10000, 30, 1, 1, 64, 1.0, "",
+        "Shows cosmic drifting flame fractals", 0, NULL, NULL},
+       {"eyes",
+        20000, -8, 5, 1, 64, 1.0, "",
+        "Shows eyes following a bouncing grelb", 0, NULL, NULL},
+       {"fadeplot",
+        30000, 10, 1500, 1, 64, 0.6, "",
+        "Shows a fading plot of sine squared", 0, NULL, NULL},
+       {"flag",
+        50000, 1, 1000, -7, 64, 1.0, "",
+        "Shows a waving flag image", 0, NULL, NULL},
+       {"flame",
+        750000, 20, 10000, 1, 64, 1.0, "",
+        "Shows cosmic flame fractals", 0, NULL, NULL},
+       {"flow",
+        1000, 1024, 3000, 1, 64, 1.0, "",
+        "Shows dynamic strange attractors", 0, NULL, NULL},
+       {"forest",
+        400000, 100, 200, 1, 64, 1.0, "",
+        "Shows binary trees of a fractal forest", 0, NULL, NULL},
+       {"galaxy",
+        100, -5, 250, -3, 64, 1.0, "",
+        "Shows crashing spiral galaxies", 0, NULL, NULL},
+#ifdef USE_GL
+       {"gears",
+        1000, 1, 2, 1, 64, 1.0, "",
+        "Shows GL's gears", 0, NULL, "#ifdef USE_GL"},
+#endif
+       {"goop",
+        10000, -12, 1, 1, 64, 1.0, "",
+        "Shows goop from a lava lamp", 0, NULL, NULL},
+       {"grav",
+        10000, -12, 1, 1, 64, 1.0, "",
+        "Shows orbiting planets", 0, NULL, NULL},
+       {"helix",
+        25000, 1, 100, 1, 64, 1.0, "",
+        "Shows string art", 0, NULL, NULL},
+       {"hop",
+        10000, 1000, 2500, 1, 64, 1.0, "",
+        "Shows real plane iterated fractals", 0, NULL, NULL},
+       {"hyper",
+        100000, -6, 300, 1, 64, 1.0, "",
+        "Shows spinning n-dimensional hypercubes", 0, NULL, NULL},
+       {"ico",
+        100000, 0, 400, 0, 64, 1.0, "",
+        "Shows a bouncing polyhedron", 0, NULL, NULL},
+       {"ifs",
+        1000, 1, 1, 1, 64, 1.0, "",
+        "Shows a modified iterated function system", 0, NULL, NULL},
+       {"image",
+        2000000, -10, 1, 1, 64, 1.0, "",
+        "Shows randomly appearing logos", 0, NULL, NULL},
+#if defined( USE_GL ) && defined( HAVE_CXX )
+       {"invert",
+        100, 1, 1, 1, 64, 1.0, "",
+        "Shows a sphere inverted without wrinkles", 0, NULL, NULL},
+#endif
+       {"julia",
+        10000, 1000, 20, 1, 64, 1.0, "",
+        "Shows the Julia set", 0, NULL, NULL},
+       {"kaleid",
+        80000, 4, 40, -9, 64, 0.6, "",
+        "Shows a kaleidoscope", 0, NULL, NULL},
+       {"kumppa",
+        10000, 1, 1, 1, 64, 1.0, "",
+        "Shows kumppa", 0, NULL, NULL},
+#if defined( USE_GL ) && ( defined( USE_XPM ) || defined( USE_XPMINC ))
+       {"lament",
+        10000, 1, 1, 1, 64, 1.0, "",
+        "Shows Lemarchand's Box", 0, NULL, "#if defined( USE_GL ) && ( defined( USE_XPM ) || defined( USE_XPMINC ))"},
+#endif
+       {"laser",
+        20000, -10, 200, 1, 64, 1.0, "",
+        "Shows spinning lasers", 0, NULL, NULL},
+       {"life",
+        750000, 40, 140, 0, 64, 1.0, "",
+        "Shows Conway's game of Life", 0, NULL, NULL},
+       {"life1d",
+        10000, 1, 10, 0, 64, 1.0, "",
+        "Shows Wolfram's game of 1D Life", 0, NULL, NULL},
+       {"life3d",
+        1000000, 35, 85, 1, 64, 1.0, "",
+        "Shows Bays' game of 3D Life", 0, NULL, NULL},
+       {"lightning",
+        10000, 1, 1, 1, 64, 0.6, "",
+        "Shows Keith's fractal lightning bolts", 0, NULL, NULL},
+       {"lisa",
+        25000, 1, 256, -1, 64, 1.0, "",
+        "Shows animated lisajous loops", 0, NULL, NULL},
+       {"lissie",
+        10000, 1, 2000, -200, 64, 0.6, "",
+        "Shows lissajous worms", 0, NULL, NULL},
+       {"loop",
+        100000, 1, 1600, -12, 64, 1.0, "",
+        "Shows Langton's self-producing loops", 0, NULL, NULL},
+       {"lyapunov",
+        25000, 600, 1, 1, 64, 1.0, "",
+        "Shows lyapunov space", 0, NULL, NULL},
+       {"mandelbrot",
+        25000, -8, 20000, 1, 64, 1.0, "",
+        "Shows mandelbrot sets", 0, NULL, NULL},
+       {"marquee",
+        100000, 1, 1, 1, 64, 1.0, "",
+        "Shows messages", 0, NULL, NULL},
+       {"matrix",
+        100, 1, 1, 1, 64, 1.0, "",
+        "Shows the matrix", 0, NULL, NULL},
+       {"maze",
+        1000, 1, 3000, -40, 64, 1.0, "",
+     "Shows a random maze and a depth first search solution", 0, NULL, NULL},
+#ifdef USE_GL
+       {"moebius",
+        1000, 1, 1, 1, 64, 1.0, "",
+        "Shows Moebius Strip II, an Escher-like GL scene with ants", 0, NULL, "#ifdef USE_GL"},
+       {"morph3d",
+        1000, 0, 1, 1, 64, 1.0, "",
+        "Shows GL morphing polyhedra", 0, NULL, "#ifdef USE_GL"},
+#endif
+       {"mountain",
+        1000, 30, 4000, 1, 64, 1.0, "",
+        "Shows Papo's mountain range", 0, NULL, NULL},
+       {"munch",
+        5000, 1, 7, 1, 64, 1.0, "",
+        "Shows munching squares", 0, NULL, NULL},
+       {"nose",
+        100000, 1, 1, 1, 64, 1.0, "",
+        "Shows a man with a big nose runs around spewing out messages", 0, NULL, NULL},
+       {"pacman",
+        100000, 10, 1, 0, 64, 1.0, "",
+        "Shows Pacman(tm)", 0, NULL, NULL},
+       {"penrose",
+        10000, 1, 1, -40, 64, 1.0, "",
+        "Shows Penrose's quasiperiodic tilings", 0, NULL, NULL},
+       {"petal",
+        10000, -500, 400, 1, 64, 1.0, "",
+        "Shows various GCD Flowers", 0, NULL, NULL},
+#ifdef USE_GL
+       {"pipes",
+        1000, 2, 5, 500, 64, 1.0, "",
+        "Shows a selfbuilding pipe system", 0, NULL, "#ifdef USE_GL"},
+#endif
+       {"puzzle",
+        10000, 250, 1, 1, 64, 1.0, "",
+        "Shows a puzzle being scrambled and then solved", 0, NULL, NULL},
+       {"pyro",
+        15000, 100, 1, -3, 64, 1.0, "",
+        "Shows fireworks", 0, NULL, NULL},
+       {"qix",
+        30000, -5, 32, 1, 64, 1.0, "",
+        "Shows spinning lines a la Qix(tm)", 0, NULL, NULL},
+       {"roll",
+        100000, 25, 1, -64, 64, 0.6, "",
+        "Shows a rolling ball", 0, NULL, NULL},
+       {"rotor",
+        10000, 4, 20, -6, 64, 0.3, "",
+        "Shows Tom's Roto-Rooter", 0, NULL, NULL},
+#ifdef USE_GL
+       {"rubik",
+        10000, -30, 5, -6, 64, 1.0, "",
+        "Shows an auto-solving Rubik's Cube", 0, NULL, "#ifdef USE_GL"},
+#endif
+       {"shape",
+        10000, 100, 256, 1, 64, 1.0, "",
+        "Shows stippled rectangles, ellipses, and triangles", 0, NULL, NULL},
+       {"sierpinski",
+        400000, 2000, 100, 1, 64, 1.0, "",
+        "Shows Sierpinski's triangle", 0, NULL, NULL},
+       {"slip",
+        50000, 35, 50, 1, 64, 1.0, "",
+        "Shows slipping blits", 0, NULL, NULL},
+       {"sphere",
+        5000, 1, 20, 0, 64, 1.0, "",
+        "Shows a bunch of shaded spheres", 0, NULL, NULL},
+       {"spiral",
+        5000, -40, 350, 1, 64, 1.0, "",
+        "Shows a helical locus of points", 0, NULL, NULL},
+       {"spline",
+        30000, -6, 2048, 1, 64, 0.3, "",
+        "Shows colorful moving splines", 0, NULL, NULL},
+#ifdef USE_GL
+       {"sproingies",
+        1000, 5, 0, 400, 64, 1.0, "",
+        "Shows Sproingies!  Nontoxic.  Safe for pets and small children", 0, NULL, "#ifdef USE_GL"},
+       {"stairs",
+        200000, 0, 1, 1, 64, 1.0, "",
+"Shows some Infinite Stairs, an Escher-like scene", 0, NULL, "#ifdef USE_GL"},
+#endif
+       {"star",
+        75000, 100, 1, 100, 64, 0.3, "",
+        "Shows a star field with a twist", 0, NULL, NULL},
+       {"starfish",
+        10000, 1, 1, 1, 64, 1.0, "",
+        "Shows starfish", 0, NULL, NULL},
+       {"strange",
+        1000, 1, 1, 1, 64, 1.0, "",
+        "Shows strange attractors", 0, NULL, NULL},
+#ifdef USE_GL
+       {"superquadrics",
+        1000, 25, 40, 1, 64, 1.0, "",
+        "Shows 3D mathematical shapes", 0, NULL, "#ifdef USE_GL"},
+#endif
+       {"swarm",
+        15000, 100, 1, 1, 64, 1.0, "",
+        "Shows a swarm of bees following a wasp", 0, NULL, NULL},
+       {"swirl",
+        5000, 5, 1, 1, 64, 1.0, "",
+        "Shows animated swirling patterns", 0, NULL, NULL},
+       {"tetris",
+   50000, 1, 1, 0, 64, 1.0, "",
+        "Shows tetris", 0, NULL, NULL},
+       {"thornbird",
+        1000, 800, 16, 1, 64, 1.0, "",
+        "Shows an animated bird in a thorn bush fractal map", 0, NULL, NULL},
+       {"triangle",
+        10000, 1, 1, 1, 64, 1.0, "",
+        "Shows a triangle mountain range", 0, NULL, NULL},
+       {"tube",
+        25000, -9, 20000, -200, 64, 1.0, "",
+        "Shows an animated tube", 0, NULL, NULL},
+       {"turtle",
+        1000000, 1, 20, 1, 64, 1.0, "",
+        "Shows turtle fractals", 0, NULL, NULL},
+       {"vines",
+        200000, 0, 1, 1, 64, 1.0, "",
+        "Shows fractals", 0, NULL, NULL},
+       {"voters",
+        1000, 0, 327670, 0, 64, 1.0, "",
+        "Shows Dewdney's Voters", 0, NULL, NULL},
+       {"wator",
+        750000, 1, 32767, 0, 64, 1.0, "",
+     "Shows Dewdney's Water-Torus planet of fish and sharks", 0, NULL, NULL},
+       {"wire",
+        500000, 1000, 150, -8, 64, 1.0, "",
+        "Shows a random circuit with 2 electrons", 0, NULL, NULL},
+       {"world",
+        100000, -16, 1, 1, 64, 0.3, "",
+        "Shows spinning Earths", 0, NULL, NULL},
+       {"worm",
+        17000, -20, 10, -3, 64, 1.0, "",
+        "Shows wiggly worms", 0, NULL, NULL},
+       {"xjack",
+        50000, 1, 1, 1, 64, 1.0, "",
+        "Shows Jack having one of those days", 0, NULL, NULL},
+
+/* SPECIAL MODES */
+       {"blank",
+        3000000, 1, 1, 1, 64, 1.0, "",
+        "Shows nothing but a black screen", 0, NULL, NULL}
+
+};
diff --git a/xlockmore-4.14/etc/genlauncher/make.launcher b/xlockmore-4.14/etc/genlauncher/make.launcher
new file mode 100755 (executable)
index 0000000..5c50390
--- /dev/null
@@ -0,0 +1,43 @@
+#/bin/sh
+if test -f xlockgen 
+then
+  echo "xlockgen is present ok"
+  echo " Make the xlock.tcl in two passes "
+  if test -f ../xlock.tcl 
+  then
+    cat etc.xlock.tcl | ./xlockgen > /tmp/xlock.tcl
+    echo " first pass "
+    cp  ../xlock.tcl /tmp/etc.xlock.tcl.old
+    cp  /tmp/xlock.tcl ../xlock.tcl
+    echo " two pass ok"
+  else 
+    echo etc.xlock.tcl missing error ?
+  fi
+  echo " Make the modes of xmlock.c in two passes "
+  #if test -f ../../xmlock/modes.h
+  if test -f xmlock.modes.tpl
+  then
+   # cat ../../xmlock/modes.h | ./xlockgen > /tmp/modes
+   cat xmlock.modes.tpl | ./xlockgen > /tmp/modes
+    echo " first pass "
+    #cp  ../../xmlock/modes.h /tmp/xmlock.modes.h.old
+    cp  xmlock.modes.tpl /tmp/xmlock.modes.h.old
+    cp  /tmp/modes ../../xmlock/modes.h
+    echo " two pass ok you could build xmlock"
+  else 
+       echo xmlock.modes.tpl missing error ?
+  fi
+  echo " Make the modes of xalock.c in two pass "
+  if test -f xalock.modes.tpl
+  then
+    cat xalock.modes.tpl | ./xlockgen > /tmp/modes
+    echo " first pass "
+#      cp  ../../xalock/modes.h /tmp/xalock.modes.h.old
+    cp  /tmp/modes ../../xalock/modes.h
+    echo " two pass ok you could build xalock"
+  else
+       echo xalock.modes.tpl missing error ?
+  fi
+else
+  echo "xlockgen is not present, please compile it"
+fi
diff --git a/xlockmore-4.14/etc/genlauncher/xalock.modes.tpl b/xlockmore-4.14/etc/genlauncher/xalock.modes.tpl
new file mode 100644 (file)
index 0000000..2e9e50c
--- /dev/null
@@ -0,0 +1,12 @@
+static char *LockProcs[] =
+{
+$%LISTLIBSX
+#ifdef USE_BOMB
+"bomb",
+"random"
+#else
+"random"
+#endif
+};
+
+static int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);
diff --git a/xlockmore-4.14/etc/genlauncher/xlockgen.lex b/xlockmore-4.14/etc/genlauncher/xlockgen.lex
new file mode 100644 (file)
index 0000000..62d066b
--- /dev/null
@@ -0,0 +1,63 @@
+%{\r
+#include <stdio.h>\r
+#include <string.h>\r
+#include "lmode.h"\r
+char *Begin="\"";\r
+char *Sep="\",";\r
+char *End="\"";\r
+%}\r
+\r
+%%\r
+"$%LISTLIBSX"  {int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {if (LockProcs[i].define!=NULL) printf("%s\n",LockProcs[i].define);\r
+                       if (i!=numprocs-1) \r
+                       printf("%s%s%s\n",Begin,LockProcs[i].cmdline_arg,Sep);\r
+                       else\r
+                       printf("%s%s%s\n",Begin,LockProcs[i].cmdline_arg,Sep);\r
+                       /*printf("%s%s%s\n",Begin,LockProcs[i].cmdline_arg,End);*/\r
+                       if (LockProcs[i].define!=NULL) printf("#endif\n");\r
+                       }\r
+               }\r
+"$%LISTMOTIF"  {int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {if (LockProcs[i].define!=NULL) printf("%s\n",LockProcs[i].define);\r
+                       if (i!=numprocs-1)\r
+                       {\r
+                       printf("{\"%s\",",LockProcs[i].cmdline_arg);\r
+                       printf("\"%s\"},\n",LockProcs[i].desc);\r
+                       }\r
+                       else\r
+                       {\r
+                       printf("{\"%s\",",LockProcs[i].cmdline_arg);\r
+                       printf("\"%s\"},\n",LockProcs[i].desc);\r
+                       }\r
+                       if (LockProcs[i].define!=NULL) printf("#endif\n");\r
+                }\r
+               }\r
+"$%LISTTCL"    {\r
+       int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {if (i!=numprocs-1)\r
+                       printf("%s\\\n",LockProcs[i].cmdline_arg);\r
+                       else\r
+                       printf("%s\n",LockProcs[i].cmdline_arg);\r
+                       }\r
+       }\r
+"$%LISTJAVA" {\r
+               int i;\r
+               int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);\r
+               for (i=0;i<numprocs;i++)\r
+                       {\r
+                       printf("lst.addItem(\"%s\");\n",LockProcs[i].cmdline_arg);\r
+                       }\r
+               }\r
+%%\r
+main(int argc,char *argv[])\r
+{\r
+yylex();\r
+}\r
+\r
diff --git a/xlockmore-4.14/etc/genlauncher/xmlock.modes.tpl b/xlockmore-4.14/etc/genlauncher/xmlock.modes.tpl
new file mode 100644 (file)
index 0000000..7022b32
--- /dev/null
@@ -0,0 +1,21 @@
+typedef struct LockStruct_s
+{
+       char *cmdline_arg;          /* mode name */
+       /* Maybe other things should be added here from xlock? */
+       /* Should read in XLock as well to set defaults */
+       char *desc;                 /* text description of mode */
+} LockStruct;
+               
+static LockStruct LockProcs[] =
+{
+$%LISTMOTIF 
+#ifdef USE_BOMB
+  {"bomb", "Shows a bomb and will autologout after a time"},
+  {"random", "Shows a random mode (except blank and bomb)"}
+  #else
+  {"random", "Shows a random mode (except blank)"}
+#endif
+};
+
+
+static int  numprocs = sizeof (LockProcs) / sizeof (LockProcs[0]);
diff --git a/xlockmore-4.14/etc/gif/README b/xlockmore-4.14/etc/gif/README
new file mode 100644 (file)
index 0000000..7b1ada2
--- /dev/null
@@ -0,0 +1,2 @@
+This directory is only for configure.tcl
+The gif format currently does not work with xlock.
diff --git a/xlockmore-4.14/etc/gif/deflag.gif b/xlockmore-4.14/etc/gif/deflag.gif
new file mode 100644 (file)
index 0000000..66086bd
Binary files /dev/null and b/xlockmore-4.14/etc/gif/deflag.gif differ
diff --git a/xlockmore-4.14/etc/gif/frflag.gif b/xlockmore-4.14/etc/gif/frflag.gif
new file mode 100644 (file)
index 0000000..8b60407
Binary files /dev/null and b/xlockmore-4.14/etc/gif/frflag.gif differ
diff --git a/xlockmore-4.14/etc/gif/nlflag.gif b/xlockmore-4.14/etc/gif/nlflag.gif
new file mode 100644 (file)
index 0000000..8997e63
Binary files /dev/null and b/xlockmore-4.14/etc/gif/nlflag.gif differ
diff --git a/xlockmore-4.14/etc/gif/ukflag.gif b/xlockmore-4.14/etc/gif/ukflag.gif
new file mode 100644 (file)
index 0000000..2c74822
Binary files /dev/null and b/xlockmore-4.14/etc/gif/ukflag.gif differ
diff --git a/xlockmore-4.14/etc/glider.3dlife b/xlockmore-4.14/etc/glider.3dlife
new file mode 100644 (file)
index 0000000..546110e
--- /dev/null
@@ -0,0 +1,8 @@
+#P -2 -2 -1
+.**.
+*..*
+*..*
+
+....
+.**.
+.**.
diff --git a/xlockmore-4.14/etc/glider.hlife b/xlockmore-4.14/etc/glider.hlife
new file mode 100644 (file)
index 0000000..debccb2
--- /dev/null
@@ -0,0 +1,7 @@
+#P -2 -2
+    . . O .
+   . . . O
+  O . . O
+ . . . O
+. . . O
+
diff --git a/xlockmore-4.14/etc/glider.life b/xlockmore-4.14/etc/glider.life
new file mode 100644 (file)
index 0000000..03c4c8a
--- /dev/null
@@ -0,0 +1,4 @@
+#P -1 -1
+***
+..*
+.*.
diff --git a/xlockmore-4.14/etc/play.sh b/xlockmore-4.14/etc/play.sh
new file mode 100755 (executable)
index 0000000..83c0a1a
--- /dev/null
@@ -0,0 +1,2 @@
+#!/bin/sh
+cat $1 > /dev/audio
diff --git a/xlockmore-4.14/etc/rplay.conf b/xlockmore-4.14/etc/rplay.conf
new file mode 100644 (file)
index 0000000..859b8eb
--- /dev/null
@@ -0,0 +1,4 @@
+/usr/local/sounds/complete.au
+/usr/local/sounds/identify-please.au
+/usr/local/sounds/not-programmed.au
+/usr/local/sounds/thank-you.au
diff --git a/xlockmore-4.14/etc/rplay.hosts b/xlockmore-4.14/etc/rplay.hosts
new file mode 100644 (file)
index 0000000..72e8ffc
--- /dev/null
@@ -0,0 +1 @@
+*
diff --git a/xlockmore-4.14/etc/rplay.servers b/xlockmore-4.14/etc/rplay.servers
new file mode 100644 (file)
index 0000000..060fcae
--- /dev/null
@@ -0,0 +1 @@
+*:rwx
diff --git a/xlockmore-4.14/etc/showmodes.sh b/xlockmore-4.14/etc/showmodes.sh
new file mode 100755 (executable)
index 0000000..2f865b5
--- /dev/null
@@ -0,0 +1,30 @@
+#!/bin/ksh
+
+# or /bin/bash
+
+# Simple script to look all xlock modes supported.
+#
+# Permission to use, copy, modify, and distribute this software and its
+# documentation for any purpose and without fee is hereby granted,
+# provided that the above copyright notice appear in all copies and that
+# both that copyright notice and this permission notice appear in
+# supporting documentation.
+#
+# This file is provided AS IS with no warranties of any kind.  The author
+# shall have no liability with respect to the infringement of copyrights,
+# trade secrets or any patents by this file or any part thereof.  In no
+# event will the author be liable for any lost revenue or profits or
+# other special, indirect and consequential damages.
+#
+# xlock-show-modes Copyright (C)  1998 Andrea Arcangeli
+#              by Andrea Arcangeli <arcangeli@mbox.queen.it>
+#
+# awk fails on Solaris but nawk is OK
+
+function listmodes
+{
+       xlock --help 2>&1 | \
+       awk '{ if (!true && match ($0,"-mode")) { gsub(/.*-mode/, ""); gsub(/\| /, ""); gsub("^ +", ""); printf("%s ", $0); true = 1 } else { if (true && /\|/) { gsub(/\| /, ""); gsub("^ +", ""); gsub("\]$", ""); printf("%s ", $0) } } }'
+}
+
+for i in `listmodes`; do echo Trying mode $i; xlock -nolock -mode $i; done
diff --git a/xlockmore-4.14/etc/system.fvwm2rc.xlock b/xlockmore-4.14/etc/system.fvwm2rc.xlock
new file mode 100644 (file)
index 0000000..dedf61b
--- /dev/null
@@ -0,0 +1,405 @@
+# Add this to your system or personal menu file
+# System: /usr/lib/X11/fvwm2/system.fvwm2rc
+# Personal $HOME/.fvwm2rc
+# Put this in your "Utilities" uncommented.
+# +    "Lock_Saver"    Menu Lock_Saver Close
+
+AddToMenu "Automata-Lock"
++      "Automata-Lock" Title
++      "Ant"           Exec    xlock -mode ant -neighbors 4 +truchet
++      "Ant Truchet"   Exec    xlock -mode ant -neighbors 4 -truchet
++      "Bee"           Exec    xlock -mode ant -neighbors 6 +truchet
++      "Bee Truchet"   Exec    xlock -mode ant -neighbors 6 -truchet
++      "Bug"           Exec    xlock -mode bug
++      "Demon"         Exec    xlock -mode demon
++      "Dilemma"       Exec    xlock -mode dilemma
++      "Life"          Exec    xlock -mode life
++      "Life Callahan" Exec    xlock -mode life -callahan -size 7
++      "Life1d"        Exec    xlock -mode life1d
++      "Life3d"        Exec    xlock -mode life3d
++      "Loop"          Exec    xlock -mode loop
++      "Voters"        Exec    xlock -mode voters
++      "Wator"         Exec    xlock -mode wator
++      "Wire"          Exec    xlock -mode wire
++      "Random"        Exec    xlock -mode random -modelist allautomata -fullrandom -neighbors 0
+
+AddToMenu "Fractal-Lock"
++      "Fractal-Lock"  Title
++      "Coral"         Exec    xlock -mode coral
++      "Discrete"      Exec    xlock -mode discrete
++      "Drift"         Exec    xlock -mode drift -fullrandom
++      "Flame"         Exec    xlock -mode flame
++      "Flow"          Exec    xlock -mode flow
++      "Forest"        Exec    xlock -mode forest
++      "Hop"           Exec    xlock -mode hop -fullrandom
++      "IFS"           Exec    xlock -mode ifs
++      "Julia"         Exec    xlock -mode julia +trackmouse
++      "Juliaptr"      Exec    xlock -mode julia -trackmouse
++      "Kumppa"        Exec    xlock -mode kumppa
++      "Lightning"     Exec    xlock -mode lightning
++      "Lyapunov"      Exec    xlock -mode lyapunov -install
++      "Mandelbrot"    Exec    xlock -mode mandelbrot -install
++      "Mountain"      Exec    xlock -mode mountain
++      "Sierpinski"    Exec    xlock -mode sierpinski 
++      "Strange"       Exec    xlock -mode strange 
++      "Thornbird"     Exec    xlock -mode thornbird
++      "Triangle"      Exec    xlock -mode triangle
++      "Turtle"        Exec    xlock -mode turtle
++      "Vines"         Exec    xlock -mode vines
++      "Random"        Exec    xlock -mode random -modelist allfractal -fullrandom
+
+AddToMenu "Geometry-Lock"
++      "Geometry-Lock" Title
++      "Braid"         Exec    xlock -mode braid
++      "Fadeplot"      Exec    xlock -mode fadeplot
++      "Helix"         Exec    xlock -mode helix -fullrandom
++      "Hyper"         Exec    xlock -mode hyper
++      "Ico"           Exec    xlock -mode ico
++      "Kaleid"        Exec    xlock -mode kaleid
++      "Laser"         Exec    xlock -mode laser
++      "Lisa"          Exec    xlock -mode lisa
++      "Lissie"        Exec    xlock -mode lissie
++      "Penrose"       Exec    xlock -mode penrose +ammann
++      "Penrose Ammann"        Exec xlock -mode penrose -ammann
++      "Petal"         Exec    xlock -mode petal
++      "Qix"           Exec    xlock -mode qix +complete
++      "Qix complete"  Exec    xlock -mode qix -complete
++      "Rotor"         Exec    xlock -mode rotor
++      "Shape"         Exec    xlock -mode shape
++      "Sphere"        Exec    xlock -mode sphere
++      "Spiral"        Exec    xlock -mode spiral
++      "Spline"        Exec    xlock -mode spline
++      "Random"        Exec    xlock -mode random -modelist allgeometry -fullrandom
+
+AddToMenu "Space-Lock"
++      "Space-Lock"    Title
++      "Bouboule"      Exec    xlock -mode bouboule +use3d
++      "Bouboule3d"    Exec    xlock -mode bouboule -use3d
++      "Galaxy"        Exec    xlock -mode galaxy
++      "Grav"          Exec    xlock -mode grav +trail +decay
++      "Grav Trail"    Exec    xlock -mode grav -trail
++      "Grav Decay"    Exec    xlock -mode grav -decay
++      "Rock"          Exec    xlock -mode star -rock
++      "Star"          Exec    xlock -mode star +rock +use3d +trek 0
++      "Star3d"        Exec    xlock -mode star -use3d
++      "Star Trek"     Exec    xlock -mode star -trek 100
++      "World"         Exec    xlock -mode world
++      "Random Space"  Exec    xlock -mode random -modelist allspace
+
+AddToMenu "Assorted-Lock"
++      "Assorted-Lock" Title
++      "Ball"          Exec    xlock -mode ball
++      "Blot"          Exec    xlock -mode blot
++      "Bounce"        Exec    xlock -mode bounce
++      "Bubble"        Exec    xlock -mode bubble
++      "Clock"         Exec    xlock -mode clock
++      "Crystal"       Exec    xlock -mode crystal
++      "Daisy"         Exec    xlock -mode daisy
++      "Dclock"        Exec    xlock -mode dclock
++      "Deco"          Exec    xlock -mode deco
++      "Decay"         Exec    xlock -mode decay
++      "Eyes"          Exec    xlock -mode eyes +trackmouse
++      "Eyesptr"       Exec    xlock -mode eyes -trackmouse
++      "Goop"          Exec    xlock -mode goop
++      "Marquee"       Exec    xlock -mode marquee
++      "Matrix"        Exec    xlock -mode matrix
++      "Munch"         Exec    xlock -mode munch
++      "Nose"          Exec    xlock -mode nose
++      "Pacman"        Exec    xlock -mode pacman
++      "Pyro"          Exec    xlock -mode pyro +use3d
++      "Pyro3d"        Exec    xlock -mode pyro -use3d
++      "Roll"          Exec    xlock -mode roll
++      "Slip"          Exec    xlock -mode slip
++      "Starfish"      Exec    xlock -mode starfish -install
++      "Swarm"         Exec    xlock -mode swarm +trackmouse
++      "Swarmptr"      Exec    xlock -mode swarm -trackmouse
++      "Swirl"         Exec    xlock -mode swirl -install
++      "Tetris"        Exec    xlock -mode tetris
++      "Tube"          Exec    xlock -mode tube -install
++      "Worm"          Exec    xlock -mode worm +use3d
++      "Worm3d"        Exec    xlock -mode worm -use3d
++      "Xjack"         Exec    xlock -mode xjack
+
+AddToMenu "XPM-Lock"
++      "XPM-Lock"      Title   
++      "Bat"           Exec    xlock -mode bat
++      "Cartoon"       Exec    xlock -mode cartoon
++      "Image"         Exec    xlock -mode image
++      "Flag"          Exec    xlock -mode flag
++      "Life"          Exec    xlock -mode life
++      "Life1d"        Exec    xlock -mode life1d
++      "Maze"          Exec    xlock -mode maze
++      "Puzzle"        Exec    xlock -mode puzzle
++      "Random"        Exec    xlock -mode random -modelist allxpm -fullrandom
+
+AddToMenu "GL-Lock"
++      "GL-Lock"       Title   
++      "Atlantis"      Exec    xlock -mode atlantis
++      "Bubble3d"      Exec    xlock -mode bubble3d
++      "Cage"          Exec    xlock -mode cage
++      "Gears"         Exec    xlock -mode gears
++      "Invert"        Exec    xlock -mode invert
++      "Lament"        Exec    xlock -mode lament
++      "Moebius"       Exec    xlock -mode moebius
++      "Morph3d"       Exec    xlock -mode morph3d
++      "Pipes"         Exec    xlock -mode pipes
++      "Rubik"         Exec    xlock -mode rubik
++      "Sproingies"    Exec    xlock -mode sproingies
++      "Stairs"        Exec    xlock -mode stairs
++      "Superquadrics" Exec    xlock -mode superquadrics
++      "Random"        Exec    xlock -mode random -modelist allgl -fullrandom
+
+AddToMenu "Marquee-Message-Lock"
++      "Message-Lock"  Title   
++      "Back Soon"     Exec    xlock -mode marquee -message "$LOGNAME will be back soon."
++      "Overnight"     Exec    xlock -mode marquee -message "$LOGNAME will be back in the morning."
++      "Rude"          Exec    xlock -mode marquee -message "$LOGNAME not here, please go away!"
+
+AddToMenu "Nose-Message-Lock"
++      "Message-Lock"  Title   
++      "Back Soon"     Exec    xlock -mode nose -message "$LOGNAME will be back soon."
++      "Overnight"     Exec    xlock -mode nose -message "$LOGNAME will be back in the morning."
++      "Rude"          Exec    xlock -mode nose -message "$LOGNAME not here, please go away!"
+
+AddToMenu "Xjack-Message-Lock"
++      "Xjack-Lock"    Title   
++      "Crazy Boy"     Exec    xlock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
++      "Crazy Girl"    Exec    xlock -mode xjack -message "All work and no play makes $LOGNAME a dull girl."
+
+AddToMenu "Special-Lock"
++      "Special-Lock"  Title   
++      "Blank"         Exec    xlock -mode blank
++      "Bomb"          Exec    xlock -mode bomb
++      "Random nice"   Exec    xlock -mode random -modelist allnice -fullrandom -neighbors 0
++      "Random standard"       Exec    xlock -mode random -modelist all-allgl -fullrandom -neighbors 0
++      "Random all"    Exec    xlock -mode random -modelist all -fullrandom -neighbors 0
++      "Random 3d"     Exec    xlock -mode random -modelist all3d -use3d -fullrandom
++      "Random ptr"    Exec    xlock -mode random -modelist allmouse -trackmouse -fullrandom
++      "Random write"  Exec    xlock -mode random -modelist allwrite -install -fullrandom
+
+AddToMenu "Automata-Saver"
++      "Automata-Saver"        Title
++      "Ant"           Exec    xlock -nolock -mode ant -neighbors 4 +truchet
++      "Ant Truchet"   Exec    xlock -nolock -mode ant -neighbors 4 -truchet
++      "Bee"           Exec    xlock -nolock -mode ant -neighbors 6 +truchet
++      "Bee Truchet"   Exec    xlock -nolock -mode ant -neighbors 6 -truchet
++      "Bug"           Exec    xlock -nolock -mode bug
++      "Demon"         Exec    xlock -nolock -mode demon
++      "Dilemma"       Exec    xlock -nolock -mode dilemma
++      "Life"          Exec    xlock -nolock -mode life
++      "Life Callahan" Exec    xlock -nolock -mode life -callahan -size 7
++      "Life1d"        Exec    xlock -nolock -mode life1d
++      "Life3d"        Exec    xlock -nolock -mode life3d
++      "Loop"          Exec    xlock -nolock -mode loop
++      "Voters"        Exec    xlock -nolock -mode voters
++      "Wator"         Exec    xlock -nolock -mode wator
++      "Wire"          Exec    xlock -nolock -mode wire
++      "Random"        Exec    xlock -nolock -mode random -modelist allautomata -fullrandom -neighbors 0
+
+AddToMenu "Fractal-Saver"
++      "Fractal-Saver" Title
++      "Coral"         Exec    xlock -nolock -mode coral
++      "Discrete"      Exec    xlock -nolock -mode discrete
++      "Drift"         Exec    xlock -nolock -mode drift -fullrandom
++      "Flame"         Exec    xlock -nolock -mode flame
++      "Flow"          Exec    xlock -nolock -mode flow
++      "Forest"        Exec    xlock -nolock -mode forest
++      "Hop"           Exec    xlock -nolock -mode hop -fullrandom
++      "IFS"           Exec    xlock -nolock -mode ifs
++      "Julia"         Exec    xlock -nolock -mode julia +trackmouse
++      "Juliaptr"      Exec    xlock -nolock -mode julia -trackmouse
++      "Kumppa"        Exec    xlock -nolock -mode kumppa
++      "Lightning"     Exec    xlock -nolock -mode lightning
++      "Lyapunov"      Exec    xlock -nolock -mode lyapunov -install
++      "Mandelbrot"    Exec    xlock -nolock -mode mandelbrot -install
++      "Mountain"      Exec    xlock -nolock -mode mountain
++      "Sierpinski"    Exec    xlock -nolock -mode sierpinski
++      "Strange"       Exec    xlock -nolock -mode strange
++      "Thornbird"     Exec    xlock -nolock -mode thornbird
++      "Triangle"      Exec    xlock -nolock -mode triangle
++      "Turtle"        Exec    xlock -nolock -mode turtle
++      "Vines"         Exec    xlock -nolock -mode vines
++      "Random"        Exec    xlock -nolock -mode random -modelist allfractal -fullrandom
+
+AddToMenu "Geometry-Saver"
++      "Geometry-Saver"        Title
++      "Braid"         Exec    xlock -nolock -mode braid
++      "Fadeplot"      Exec    xlock -nolock -mode fadeplot
++      "Helix"         Exec    xlock -nolock -mode helix -fullrandom
++      "Hyper"         Exec    xlock -nolock -mode hyper
++      "Ico"           Exec    xlock -nolock -mode ico
++      "Kaleid"        Exec    xlock -nolock -mode kaleid
++      "Laser"         Exec    xlock -nolock -mode laser
++      "Lisa"          Exec    xlock -nolock -mode lisa
++      "Lissie"        Exec    xlock -nolock -mode lissie
++      "Penrose"       Exec    xlock -nolock -mode penrose +ammann
++      "Penrose Ammann"        Exec xlock -nolock -mode penrose -ammann
++      "Petal"         Exec    xlock -nolock -mode petal
++      "Qix"           Exec    xlock -nolock -mode qix +complete
++      "Qix complete"  Exec    xlock -nolock -mode qix -complete
++      "Rotor"         Exec    xlock -nolock -mode rotor
++      "Shape"         Exec    xlock -nolock -mode shape
++      "Sphere"        Exec    xlock -nolock -mode sphere
++      "Spiral"        Exec    xlock -nolock -mode spiral
++      "Spline"        Exec    xlock -nolock -mode spline
++      "Random"        Exec    xlock -nolock -mode random -modelist allgeometry
+
+AddToMenu "Space-Saver"
++      "Space-Saver"   Title
++      "Bouboule"      Exec    xlock -nolock -mode bouboule +use3d
++      "Bouboule3d"    Exec    xlock -nolock -mode bouboule -use3d
++      "Galaxy"        Exec    xlock -nolock -mode galaxy
++      "Grav"          Exec    xlock -nolock -mode grav +trail +decay
++      "Grav Trail"    Exec    xlock -nolock -mode grav -trail
++      "Grav Decay"    Exec    xlock -nolock -mode grav -decay
++      "Rock"          Exec    xlock -nolock -mode star -rock
++      "Star"          Exec    xlock -nolock -mode star +rock +use3d +trek 0
++      "Star3d"        Exec    xlock -nolock -mode star -use3d
++      "Star Trek"     Exec    xlock -nolock -mode star -trek 100
++      "World"         Exec    xlock -nolock -mode world
++      "Random Space"  Exec    xlock -nolock -mode random -modelist allspace
+
+AddToMenu "Assorted-Saver"
++      "Assorted-Saver"        Title
++      "Ball"          Exec    xlock -nolock -mode ball
++      "Blot"          Exec    xlock -nolock -mode blot
++      "Bounce"        Exec    xlock -nolock -mode bounce
++      "Bubble"        Exec    xlock -nolock -mode bubble
++      "Clock"         Exec    xlock -nolock -mode clock
++      "Crystal"       Exec    xlock -nolock -mode crystal
++      "Daisy"         Exec    xlock -nolock -mode daisy
++      "Dclock"        Exec    xlock -nolock -mode dclock
++      "Deco"          Exec    xlock -nolock -mode deco
++      "Decay"         Exec    xlock -nolock -mode decay
++      "Eyes"          Exec    xlock -nolock -mode eyes +trackmouse
++      "Eyesptr"       Exec    xlock -nolock -mode eyes -trackmouse
++      "Goop"          Exec    xlock -nolock -mode goop
++      "Marquee"       Exec    xlock -nolock -mode marquee
++      "Matrix"        Exec    xlock -nolock -mode matrix
++      "Munch"         Exec    xlock -nolock -mode munch
++      "Nose"          Exec    xlock -nolock -mode nose
++      "Pacman"        Exec    xlock -nolock -mode pacman
++      "Pyro"          Exec    xlock -nolock -mode pyro +use3d
++      "Pyro3d"        Exec    xlock -nolock -mode pyro -use3d
++      "Roll"          Exec    xlock -nolock -mode roll
++      "Slip"          Exec    xlock -nolock -mode slip
++      "Starfish"      Exec    xlock -nolock -mode starfish -install
++      "Swarm"         Exec    xlock -nolock -mode swarm +trackmouse
++      "Swarmptr"      Exec    xlock -nolock -mode swarm -trackmouse
++      "Swirl"         Exec    xlock -nolock -mode swirl -install
++      "Tetris"        Exec    xlock -nolock -mode tetris
++      "Tube"          Exec    xlock -nolock -mode tube -install
++      "Worm"          Exec    xlock -nolock -mode worm +use3d
++      "Worm3d"        Exec    xlock -nolock -mode worm -use3d
++      "Xjack"         Exec    xlock -nolock -mode xjack
+
+AddToMenu "XPM-Saver"
++      "XPM-Saver"     Title   
++      "Bat"           Exec    xlock -nolock -mode bat
++      "Cartoon"       Exec    xlock -nolock -mode cartoon
++      "Image"         Exec    xlock -nolock -mode image
++      "Flag"          Exec    xlock -nolock -mode flag
++      "Life"          Exec    xlock -nolock -mode life
++      "Life1d"        Exec    xlock -nolock -mode life1d
++      "Maze"          Exec    xlock -nolock -mode maze
++      "Puzzle"        Exec    xlock -nolock -mode puzzle
++ "Random"             Exec    xlock -nolock -mode random -modelist allxpm -fullrandom
+
+AddToMenu "GL-Saver"
++      "GL-Saver"      Title   
++      "Atlantis"      Exec    xlock -nolock -mode atlantis
++      "Bubble3d"      Exec    xlock -nolock -mode bubble3d
++      "Cage"          Exec    xlock -nolock -mode cage
++      "Gears"         Exec    xlock -nolock -mode gears
++      "Lament"        Exec    xlock -nolock -mode lament
++      "Moebius"       Exec    xlock -nolock -mode moebius
++      "Morph3d"       Exec    xlock -nolock -mode morph3d
++      "Pipes"         Exec    xlock -nolock -mode pipes
++      "Rubik"         Exec    xlock -nolock -mode rubik
++      "Sproingies"    Exec    xlock -nolock -mode sproingies
++      "Stairs"        Exec    xlock -nolock -mode stairs
++      "Superquadrics" Exec    xlock -nolock -mode superquadrics
++ "Random"   Exec      xlock -nolock -mode random -modelist allgl -fullrandom
+
+AddToMenu "Marquee-Message-Saver"
++      "Marquee-Message"       Title
++      "Brilliant!"    Exec    xlock -nolock -mode marquee -message "WOW! $LOGNAME, You're Brilliant!"
++      "Love You"      Exec    xlock -nolock -mode marquee -message "You know, I Love You $LOGNAME."
++      "Available"     Exec    xlock -nolock -mode marquee -message "Hey, I'm available now!"
+
+AddToMenu "Nose-Message-Saver"
++      "Nose-Message"  Title
++      "Brilliant!"    Exec    xlock -nolock -mode nose -message "WOW! $LOGNAME, You're Brilliant!"
++      "Love You"      Exec    xlock -nolock -mode nose -message "You know, I Love You $LOGNAME."
++      "Available"     Exec    xlock -nolock -mode nose -message "Hey, I'm available now!"
+
+AddToMenu "Xjack-Message-Lock"
++      "Xjack-Lock"    Title   
++      "Crazy Boy"             Exec    xlock -nolock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
++      "Crazy Girl"            Exec    xlock -nolock -mode xjack -message "All work and no play makes $LOGNAME a dull girl."
+
+AddToMenu "Special-Saver"
++      "Special-Saver" Title   
++      "Blank"         Exec    xlock -nolock -mode blank
++      "Bomb"          Exec    xlock -nolock -mode bomb
++      "Random nice"   Exec    xlock -nolock -mode random -modelist allnice -fullrandom -neighbors 0
++      "Random standard"       Exec    xlock -nolock -mode random -modelist all-allgl -fullrandom -neighbors 0
++      "Random all"    Exec    xlock -nolock -mode random -modelist all -fullrandom -neighbors 0
++      "Random 3d"     Exec    xlock -nolock -mode random -modelist all3d -use3d -fullrandom
++      "Random ptr"    Exec    xlock -nolock -mode random -modelist allmouse -trackmouse -fullrandom
++      "Random write"  Exec    xlock -nolock -mode random -modelist allwrite -fullrandom
+
+AddToMenu Screenlock
++      "Screenlock"            Title
++      "Cellular Automata"     Menu Automata-Lock Close
++       ""                      Nop
++      "Fractal"               Menu Fractal-Lock Close
++       ""                      Nop
++      "Geometry"              Menu Geometry-Lock Close
++       ""                      Nop
++      "Space"                 Menu Space-Lock Close
++       ""                      Nop
++      "Assorted"              Menu Assorted-Lock Close
++       ""                      Nop
++      "XPM"           Menu XPM-Lock Close
++       ""                      Nop
++      "GL"            Menu GL-Lock Close
++       ""                      Nop
++      "Marquee Message"       Menu Marquee-Message-Lock Close
++       ""                      Nop
++      "Nose Message"          Menu Nose-Message-Lock Close
++       ""                      Nop
++      "Xjack Message"         Menu Xjack-Message-Lock Close
++       ""                      Nop
++      "Special"               Menu Special-Lock Close
+
+AddToMenu Screensaver
++      "Screensaver"           Title
++      "Cellular Automata"     Menu Automata-Saver Close
++      ""                      Nop
++      "Fractal"               Menu Fractal-Saver Close
++       ""                     Nop
++      "Geometry"              Menu Geometry-Saver Close
++       ""                     Nop
++      "Space"                 Menu Space-Saver Close
++       ""                     Nop
++      "Assorted"              Menu Assorted-Saver Close
++       ""                     Nop
++      "XPM"           Menu XPM-Saver Close
++       ""                     Nop
++      "GL"            Menu GL-Saver Close
++       ""                     Nop
++      "Marquee Message"       Menu Marquee-Message-Saver Close
++       ""                      Nop
++      "Nose Message"          Menu Nose-Message-Saver Close
++       ""                      Nop
++      "Xjack Message"         Menu Xjack-Message-Saver Close
++       ""                      Nop
++      "Special"               Menu Special-Saver Close
+
+AddToMenu "Lock_Saver"
++      "Lock_Saver"            Title
++      "Screenlock"    Menu Screenlock Close
++      ""                      Nop
++      "Screensaver"           Menu Screensaver Close
+
diff --git a/xlockmore-4.14/etc/system.fvwmrc.xlock b/xlockmore-4.14/etc/system.fvwmrc.xlock
new file mode 100644 (file)
index 0000000..d12498a
--- /dev/null
@@ -0,0 +1,431 @@
+# Add this to your system or personal menu file
+# System: /usr/lib/X11/fvwm/system.fvwmrc
+# Personal $HOME/.fvwmrc
+# Put this in your "Utilities" uncommented.
+#      Popup   "Lock_Saver"    Lock_Saver
+# This is for fvwm <=1.24r
+# For -install to work right you must disable it before fvwm is compiled
+# see README
+
+Popup "Automata-Lock"
+       Title   "Automata-Lock"
+       Exec    "Ant"           exec xlock -mode ant -neighbors 4 +truchet &
+       Exec    "Ant Truchet"   exec xlock -mode ant -neighbors 4 -truchet &
+       Exec    "Bee"           exec xlock -mode ant -neighbors 6 +truchet &
+       Exec    "Bee Truchet"   exec xlock -mode ant -neighbors 6 -truchet &
+       Exec    "Bug"           exec xlock -mode bug &
+       Exec    "Demon"         exec xlock -mode demon &
+       Exec    "Dilemma"       exec xlock -mode dilemma &
+       Exec    "Life"          exec xlock -mode life &
+       Exec    "Life Callahan" exec xlock -mode life -callahan -size 7 &
+       Exec    "Life1d"        exec xlock -mode life1d &
+       Exec    "Life3d"        exec xlock -mode life3d &
+       Exec    "Loop"          exec xlock -mode loop &
+       Exec    "Voters"        exec xlock -mode voters &
+       Exec    "Wator"         exec xlock -mode wator &
+       Exec    "Wire"          exec xlock -mode wire &
+       Exec    "Random Automata"       exec xlock -mode random -modelist allautomata -fullrandom -neighbors 0 &
+EndPopup
+
+Popup "Fractal-Lock"
+       Title   "Fractal-Lock"
+       Exec    "Coral"         exec xlock -mode coral &
+       Exec    "Discrete"      exec xlock -mode discrete &
+       Exec    "Drift"         exec xlock -mode drift -fullrandom &
+       Exec    "Flame"         exec xlock -mode flame &
+       Exec    "Flow"          exec xlock -mode flow &
+       Exec    "Forest"        exec xlock -mode forest &
+       Exec    "Hop"i          exec xlock -mode hop -fullrandom &
+       Exec    "IFS"           exec xlock -mode ifs &
+       Exec    "Julia"         exec xlock -mode julia +trackmouse &
+       Exec    "Juliaptr"      exec xlock -mode julia -trackmouse &
+       Exec    "Kumppa"        exec xlock -mode kumppa &
+       Exec    "Lightning"     exec xlock -mode lightning &
+       Exec    "Mandelbrot"    exec xlock -mode lyapunov -install &
+       Exec    "Mandelbrot"    exec xlock -mode mandelbrot -install &
+       Exec    "Mountain"      exec xlock -mode mountain &
+       Exec    "Sierpinski"    exec xlock -mode sierpinski &
+       Exec    "Strange"       exec xlock -mode strange &
+       Exec    "Thornbird"     exec xlock -mode thornbird &
+       Exec    "Triangle"      exec xlock -mode triangle &
+       Exec    "Turtle"        exec xlock -mode turtle &
+       Exec    "Vines"         exec xlock -mode vines &
+       Exec    "Random Fractal"        exec xlock -mode random -modelist allfractal -fullrandom &
+EndPopup
+
+Popup "Geometry-Lock"
+       Title   "Geometry-Lock"
+       Exec    "Braid"         exec xlock -mode braid &
+       Exec    "Fadeplot"      exec xlock -mode fadeplot &
+       Exec    "Helix"         exec xlock -mode helix -fullrandom &
+       Exec    "Hyper"         exec xlock -mode hyper &
+       Exec    "Ico"           exec xlock -mode ico &
+       Exec    "Kaleid"        exec xlock -mode kaleid &
+       Exec    "Laser"         exec xlock -mode laser &
+       Exec    "Lisa"          exec xlock -mode lisa &
+       Exec    "Lissie"        exec xlock -mode lissie &
+       Exec    "Penrose"       exec xlock -mode penrose +ammann &
+       Exec    "Penrose Ammann"        exec xlock -mode penrose -ammann &
+       Exec    "Petal"         exec xlock -mode petal &
+       Exec    "Qix"           exec xlock -mode qix +complete &
+       Exec    "Qix complete"  exec xlock -mode qix -complete &
+       Exec    "Rotor"         exec xlock -mode rotor &
+       Exec    "Shape"         exec xlock -mode shape &
+       Exec    "Sphere"        exec xlock -mode sphere &
+       Exec    "Spiral"        exec xlock -mode spiral &
+       Exec    "Spline"        exec xlock -mode spline &
+       Exec    "Random Geometry"       exec xlock -mode random -modelist allgeometry -fullrandom &
+EndPopup
+
+Popup "Space-Lock"
+       Title   "Space-Lock"
+       Exec    "Bouboule"      exec xlock -mode bouboule +use3d &
+       Exec    "Bouboule3d"    exec xlock -mode bouboule -use3d &
+       Exec    "Galaxy"        exec xlock -mode galaxy &
+       Exec    "Grav"          exec xlock -mode grav +trail +decay &
+       Exec    "Grav Trail"    exec xlock -mode grav -trail &
+       Exec    "Grav Decay"    exec xlock -mode grav -decay &
+       Exec    "Rock"i         exec xlock -mode star -rock &
+       Exec    "Star"          exec xlock -mode star +rock +use3d -trek 0 &
+       Exec    "Star3dk"       exec xlock -mode star -use3d &
+       Exec    "Star Trek"     exec xlock -mode star -trek 100 &
+       Exec    "World"         exec xlock -mode world &
+       Exec    "Random Space"  exec xlock -mode random -modelist allspace -fullrandom &
+EndPopup
+
+Popup "Assorted-Lock"
+       Title   "Assorted-Lock"
+       Exec    "Ball"          exec xlock -mode ball &
+       Exec    "Blot"          exec xlock -mode blot &
+       Exec    "Bounce"        exec xlock -mode bounce &
+       Exec    "Bubble"        exec xlock -mode bubble &
+       Exec    "Clock"         exec xlock -mode clock &
+       Exec    "Crystal"       exec xlock -mode crystal &
+       Exec    "Daisy"         exec xlock -mode daisy &
+       Exec    "Dclock"        exec xlock -mode dclock &
+       Exec    "Decay"         exec xlock -mode decay &
+       Exec    "Deco"          exec xlock -mode deco &
+       Exec    "Eyes"          exec xlock -mode eyes +trackmouse &
+       Exec    "Eyesptr"       exec xlock -mode eyes -trackmouse &
+       Exec    "Goop"          exec xlock -mode goop &
+       Exec    "Marquee"       exec xlock -mode marquee &
+       Exec    "Matrix"        exec xlock -mode matrix &
+       Exec    "Munch"         exec xlock -mode munch &
+       Exec    "Nose"          exec xlock -mode nose &
+       Exec    "Pacman"        exec xlock -mode pacman &
+       Exec    "Pyro"          exec xlock -mode pyro +use3d &
+       Exec    "Pyro3d"        exec xlock -mode pyro -use3d &
+       Exec    "Roll"          exec xlock -mode roll &
+       Exec    "Slip"          exec xlock -mode slip &
+       Exec    "Starfish"      exec xlock -mode starfish -install &
+       Exec    "Swarm"         exec xlock -mode swarm +trackmouse &
+       Exec    "Swarmptr"      exec xlock -mode swarm -trackmouse &
+       Exec    "Swirl"         exec xlock -mode swirl -install &
+       Exec    "Tetris"        exec xlock -mode tetris &
+       Exec    "Tube"          exec xlock -mode tube -install &
+       Exec    "Worm"          exec xlock -mode worm +use3d &
+       Exec    "Worm3d"        exec xlock -mode worm -use3d &
+       Exec    "Xjack"         exec xlock -mode xjack &
+EndPopup
+
+Popup "XPM-Lock"
+       Exec    "Bat"           exec xlock -mode bat &
+       Exec    "Cartoon"       exec xlock -mode cartoon &
+       Exec    "Image"         exec xlock -mode image &
+       Exec    "Flag"          exec xlock -mode flag &
+       Exec    "Life"          exec xlock -mode life &
+       Exec    "Life1d"        exec xlock -mode life1d &
+       Exec    "Maze"          exec xlock -mode maze &
+       Exec    "Puzzle"        exec xlock -mode puzzle &
+       Exec    "Random XPM"    exec xlock -mode random -modelist allxpm -fullrandom &
+EndPopup
+
+Popup "GL-Lock"
+       Exec    "Atlantis"      exec xlock -mode atlantis &
+       Exec    "Bubble3d"      exec xlock -mode bubble3d &
+       Exec    "Cage"          exec xlock -mode cage &
+       Exec    "Gears"         exec xlock -mode gears &
+       Exec    "Invert"        exec xlock -mode invert &
+       Exec    "Lament"        exec xlock -mode lament &
+       Exec    "Moebius"       exec xlock -mode moebius &
+       Exec    "Morph3d"       exec xlock -mode morph3d &
+       Exec    "Pipes"         exec xlock -mode pipes &
+       Exec    "Rubik"         exec xlock -mode rubik &
+       Exec    "Sproingies"    exec xlock -mode sproingies &
+       Exec    "Stairs"        exec xlock -mode stairs &
+       Exec    "Superquadrics" exec xlock -mode superquadrics &
+       Exec    "Random GL"     exec xlock -mode random -modelist allgl -fullrandom &
+EndPopup
+
+Popup "Marquee-Message-Lock"
+       Title   "Marquee-Message-Lock"
+       Exec    "Back Soon"     exec xlock -mode marquee -message "$LOGNAME will be back soon." &
+       Exec    "Overnight"     exec xlock -mode marquee -message "$LOGNAME will be back in the morning." &
+       Exec    "Rude"          exec xlock -mode marquee -message "$LOGNAME not here, please go away! " &
+EndPopup
+
+Popup "Nose-Message-Lock"
+       Title   "Nose-Message-Lock"
+       Exec    "Back Soon"     exec xlock -mode nose -message "$LOGNAME will be back soon."
+       Exec    "Overnight"     exec xlock -mode nose -message "$LOGNAME will be back in the morning." &
+       Exec    "Rude"  exec xlock -mode nose -message "$LOGNAME not here, please go away! " &
+EndPopup
+
+Popup "Xjack-Message-Lock"
+       Title   "Xjack-Message-Lock"
+       Exec    "Crazy Boy"     exec xlock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+       Exec    "Crazy Girl"    exec xlock -mode xjack -message "All work and no play makes $LOGNAME a dull girl." &
+EndPopup
+
+Popup "Special-Lock"
+       Title   "Special-Lock"
+       Exec    "Blank" exec xlock -mode blank &
+       Exec    "Bomb"  exec xlock -mode bomb &
+       Exec    "Random nice"   exec xlock -mode random -modelist allnice -fullrandom -neighbors 0 &
+       Exec    "Random standard"       exec xlock -mode random -modelist all-allgl -fullrandom -neighbors 0 &
+       Exec    "Random all"    exec xlock -mode random -modelist all -fullrandom -neighbors 0 &
+       Exec    "Random 3d"     exec xlock -mode random -modelist all3d -use3d -fullrandom &
+       Exec    "Random ptr"    exec xlock -mode random -modelist allmouse -trackmouse -fullrandom &
+       Exec    "Random write"  exec xlock -mode random -modelist allwrite -fullrandom &
+EndPopup
+
+Popup "Screenlock"
+       Title   "Screenlock"
+       Popup   "Cellular Automata"     Automata-Lock
+       Nop     ""
+       Popup   "Fractal"       Fractal-Lock
+       Nop     ""
+       Popup   "Geometry"      Geometry-Lock
+       Nop     ""
+       Popup   "Space"         Space-Lock
+       Nop     ""
+       Popup   "Assorted"      Assorted-Lock
+       Nop     ""
+       Popup   "XPM"           XPM-Lock
+       Nop     ""
+       Popup   "GL"            GL-Lock
+       Nop     ""
+       Popup   "Marquee Message"       Marquee-Message-Lock
+       Nop     ""
+       Popup   "Nose Message"  Nose-Message-Lock
+       Nop     ""
+       Popup   "Xjack Message" Xjack-Message-Lock
+       Nop     ""
+       Popup   "Special"       Special-Lock
+EndPopup
+
+Popup "Automata-Saver"
+       Title   "Automata-Saver"
+       Exec    "Ant"           exec xlock -nolock -mode ant -neighbors 4 +truchet &
+       Exec    "Ant Truchet"   exec xlock -nolock -mode ant -neighbors 4 -truchet &
+       Exec    "Bee"           exec xlock -nolock -mode ant -neighbors 6 +truchet &
+       Exec    "Bee Truchet"   exec xlock -nolock -mode ant -neighbors 6 -truchet &
+       Exec    "Bug"           exec xlock -nolock -mode bug &
+       Exec    "Demon"         exec xlock -nolock -mode demon &
+       Exec    "Dilemma"       exec xlock -nolock -mode dilemma &
+       Exec    "Life"          exec xlock -nolock -mode life &
+       Exec    "Life Callahan" exec xlock -nolock -mode life -callahan -size 7 &
+       Exec    "Life1d"        exec xlock -nolock -mode life1d &
+       Exec    "Life3d"        exec xlock -nolock -mode life3d &
+       Exec    "Loop"          exec xlock -nolock -mode loop &
+       Exec    "Voters"        exec xlock -nolock -mode voters &
+       Exec    "Wator"         exec xlock -nolock -mode wator &
+       Exec    "Wire"          exec xlock -nolock -mode wire &
+       Exec    "Random Automata"       exec xlock -nolock -mode random -modelist allautomata -fullrandom -neighbors 0 &
+
+EndPopup
+
+Popup "Fractal-Saver"
+       Title   "Fractal-Saver"
+       Exec    "Coral"         exec xlock -nolock -mode coral &
+       Exec    "Discrete"      exec xlock -nolock -mode discrete &
+       Exec    "Drift"         exec xlock -nolock -mode drift -fullrandom &
+       Exec    "Flame"         exec xlock -nolock -mode flame &
+       Exec    "Flow"          exec xlock -nolock -mode flow &
+       Exec    "Forest"        exec xlock -nolock -mode forest &
+       Exec    "Hop"           exec xlock -nolock -mode hop -fullrandom &
+       Exec    "IFS"           exec xlock -nolock -mode ifs &
+       Exec    "Julia"         exec xlock -nolock -mode julia +trackmouse &
+       Exec    "Juliaptr"      exec xlock -nolock -mode julia -trackmouse &
+       Exec    "Kumppa"        exec xlock -nolock -mode kumppa &
+       Exec    "Lightning"     exec xlock -nolock -mode lightning &
+       Exec    "Lyapunov"      exec xlock -nolock -mode lyapunov -install &
+       Exec    "Mandelbrot"    exec xlock -nolock -mode mandelbrot -install &
+       Exec    "Mountain"      exec xlock -nolock -mode mountain &
+       Exec    "Sierpinski"    exec xlock -nolock -mode sierpinski &
+       Exec    "Strange"       exec xlock -nolock -mode strange &
+       Exec    "Thornbird"     exec xlock -nolock -mode thornbird &
+       Exec    "Triangle"      exec xlock -nolock -mode triangle &
+       Exec    "Turtle"        exec xlock -nolock -mode turtle &
+       Exec    "Vines"         exec xlock -nolock -mode vines &
+       Exec    "Random Fractal"        exec xlock -nolock -mode random -modelist allfractal -fullrandom &
+EndPopup
+
+Popup "Geometry-Saver"
+       Title   "Geometry-Saver"
+       Exec    "Braid"         exec xlock -nolock -mode braid &
+       Exec    "Fadeplot"      exec xlock -nolock -mode fadeplot &
+       Exec    "Helix"         exec xlock -nolock -mode helix -fullrandom &
+       Exec    "Hyper"         exec xlock -nolock -mode hyper &
+       Exec    "Ico"           exec xlock -nolock -mode ico &
+       Exec    "Kaleid"        exec xlock -nolock -mode kaleid &
+       Exec    "Laser"         exec xlock -nolock -mode laser &
+       Exec    "Lisa"          exec xlock -nolock -mode lisa &
+       Exec    "Lissiekk"      exec xlock -nolock -mode lissie &
+       Exec    "Penrose"       exec xlock -nolock -mode penrose +ammann &
+       Exec    "Penrose Ammann"        exec xlock -nolock -mode penrose -ammann &
+       Exec    "Petal"         exec xlock -nolock -mode petal &
+       Exec    "Qix"           exec xlock -nolock -mode qix +complete &
+       Exec    "Qix complete"  exec xlock -nolock -mode qix -complete &
+       Exec    "Rotor"         exec xlock -nolock -mode rotor &
+       Exec    "Shape"         exec xlock -nolock -mode shape &
+       Exec    "Sphere"        exec xlock -nolock -mode sphere &
+       Exec    "Spiral"        exec xlock -nolock -mode spiral &
+       Exec    "Spline"        exec xlock -nolock -mode spline &
+       Exec    "Random Geometry"       exec xlock -nolock -mode random -modelist allgeometry -fullrandom &
+EndPopup
+
+Popup "Space-Saver"
+       Title   "Space-Saver"
+       Exec    "Bouboule"      exec xlock -nolock -mode bouboule +use3d &
+       Exec    "Bouboule3d"    exec xlock -nolock -mode bouboule -use3d &
+       Exec    "Galaxy"        exec xlock -nolock -mode galaxy &
+       Exec    "Grav"          exec xlock -nolock -mode grav +trail +decay &
+       Exec    "Grav Trail"    exec xlock -nolock -mode grav -trail &
+       Exec    "Grav Decay"    exec xlock -nolock -mode grav -decay &
+       Exec    "Rock"          exec xlock -nolock -mode star -rock &
+       Exec    "Star"          exec xlock -nolock -mode star +rock +use3d +trek 0 &
+       Exec    "Star3d"        exec xlock -nolock -mode star -use3d &
+       Exec    "Star Trek"     exec xlock -nolock -mode star -trek 100 &
+       Exec    "World"         exec xlock -nolock -mode world &
+       Exec    "Random Space"  exec xlock -nolock -mode random -modelist allspace -fullrandom &
+EndPopup
+
+Popup "Assorted-Saver"
+       Title   "Assorted-Saver"
+       Exec    "Ball"          exec xlock -nolock -mode ball &
+       Exec    "Blot"          exec xlock -nolock -mode blot &
+       Exec    "Bounce"        exec xlock -nolock -mode bounce &
+       Exec    "Bubble"        exec xlock -nolock -mode bubble &
+       Exec    "Clock"         exec xlock -nolock -mode clock &
+       Exec    "Crystal"       exec xlock -nolock -mode crystal &
+       Exec    "Daisy"         exec xlock -nolock -mode daisy &
+       Exec    "Dclock"        exec xlock -nolock -mode dclock &
+       Exec    "Decay"         exec xlock -nolock -mode decay &
+       Exec    "Deco"          exec xlock -nolock -mode deco &
+       Exec    "Eyes"          exec xlock -nolock -mode eyes +trackmouse &
+       Exec    "Eyesptr"       exec xlock -nolock -mode eyes -trackmouse &
+       Exec    "Goop"          exec xlock -nolock -mode goop &
+       Exec    "Marquee"       exec xlock -nolock -mode marquee &
+       Exec    "Matrix"        exec xlock -nolock -mode matrix &
+       Exec    "Munch"         exec xlock -nolock -mode munch &
+       Exec    "Nose"          exec xlock -nolock -mode nose &
+       Exec    "Pacman"        exec xlock -nolock -mode pacman &
+       Exec    "Pyro"          exec xlock -nolock -mode pyro +use3d &
+       Exec    "Pyro3d"        exec xlock -nolock -mode pyro -use3d &
+       Exec    "Roll"          exec xlock -nolock -mode roll &
+       Exec    "Slip"          exec xlock -nolock -mode slip &
+       Exec    "Starfish"      exec xlock -nolock -mode starfish -install &
+       Exec    "Swarm"         exec xlock -nolock -mode swarm +trackmouse &
+       Exec    "Swarmptr"      exec xlock -nolock -mode swarm -trackmouse &
+       Exec    "Swirl"         exec xlock -nolock -mode swirl -install &
+       Exec    "Tetris"        exec xlock -nolock -mode tetris &
+       Exec    "Tube"          exec xlock -nolock -mode tube -install &
+       Exec    "Worm"          exec xlock -nolock -mode worm +use3d &
+       Exec    "Worm3d"        exec xlock -nolock -mode worm -use3d &
+       Exec    "Xjack"         exec xlock -nolock -mode xjack &
+EndPopup
+
+Popup "XPM-Saver"
+       Exec    "Bat"           exec xlock -nolock -mode bat &
+       Exec    "Cartoon"       exec xlock -nolock -mode cartoon &
+       Exec    "Image"         exec xlock -nolock -mode image &
+       Exec    "Flag"          exec xlock -nolock -mode flag &
+       Exec    "Life"          exec xlock -nolock -mode life &
+       Exec    "Life1d"        exec xlock -nolock -mode life1d &
+       Exec    "Maze"          exec xlock -nolock -mode maze &
+       Exec    "Puzzle"        exec xlock -nolock -mode puzzle &
+       Exec    "Random XPM"    exec xlock -nolock -mode random -modelist allxpm -fullrandom &
+EndPopup
+
+Popup "GL-Saver"
+       Exec    "Atlantis"      exec xlock -nolock -mode atlantis &
+       Exec    "Bubble3d"      exec xlock -nolock -mode bubble3d &
+       Exec    "Cage"          exec xlock -nolock -mode cage &
+       Exec    "Gears"         exec xlock -nolock -mode gears &
+       Exec    "Moebius"       exec xlock -nolock -mode invert &
+       Exec    "Moebius"       exec xlock -nolock -mode lament &
+       Exec    "Moebius"       exec xlock -nolock -mode moebius &
+       Exec    "Morph3d"       exec xlock -nolock -mode morph3d &
+       Exec    "Pipes"         exec xlock -nolock -mode pipes &
+       Exec    "Rubik"         exec xlock -nolock -mode rubik &
+       Exec    "Sproingies"    exec xlock -nolock -mode sproingies &
+       Exec    "Stairs"        exec xlock -nolock -mode stairs &
+       Exec    "Superquadrics" exec xlock -nolock -mode superquadrics &
+       Exec    "Random GL"     exec xlock -nolock -mode random -modelist allgl -fullrandom &
+EndPopup
+
+Popup "Marquee-Message-Saver"
+       Title   "Marquee-Message-Saver"
+       Exec    "Brilliant"     exec xlock -nolock -mode marquee -message "WOW! $LOGNAME, You are Brilliant! " &
+       Exec    "Love You"              exec xlock -mode marquee -message "You know, I Love You $LOGNAME." &
+       Exec    "Available"             exec xlock -mode marquee -message "Hey, I am available now! " &
+EndPopup
+
+Popup "Nose-Message-Saver"
+       Title   "Nose-Message-Saver"
+       Exec    "Brilliant!"    exec xlock -mode nose -message "WOW! $LOGNAME, You are Briilliant! "
+       Exec    "Love You"      exec xlock -mode nose -message "You know, I Love You $LOGNAME." &
+       Exec    "Available"     exec xlock -mode nose -message "Hey, I am available now! " &
+EndPopup
+
+Popup "Xjack-Message-Saver"
+       Title   "Xjack-Message-Saver"
+       Exec    "Crazy Boy"     exec xlock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+       Exec    "Crazy Girl"    exec xlock -mode xjack -message "All work and no play makes $LOGNAME a dull girl." &
+EndPopup
+
+Popup "Special-Saver"
+       Title   "Special-Saver"
+       Exec    "Blank"         exec xlock -nolock -mode blank &
+       Exec    "Bomb"          exec xlock -nolock -mode bomb &
+       Exec    "Random nice"   exec xlock -nolock -mode random -modelist allnice -fullrandom -neighbors 0 &
+       Exec    "Random standard"       exec xlock -nolock -mode random -modelist all-allgl -fullrandom -neighbors 0 &
+       Exec    "Random all"    exec xlock -nolock -mode random -modelist all -fullrandom -neighbors 0 &
+       Exec    "Random 3d"     exec xlock -nolock -mode random -modelist all3d -use3d -fullrandom &
+       Exec    "Random ptr"    exec xlock -nolock -mode random -modelist allmouse -trackmouse -fullrandom &
+       Exec    "Random write"  exec xlock -nolock -mode random -modelist allwrite -fullrandom &
+EndPopup
+
+Popup "Screensaver"
+       Title   "Screensaver"
+       Popup   "Cellular Automata"     Automata-Saver
+       Nop     ""
+       Popup   "Fractal"       Fractal-Saver
+       Nop     ""
+       Popup   "Geometry"      Geometry-Saver
+       Nop     ""
+       Popup   "Space"         Space-Saver
+       Nop     ""
+       Popup   "Assorted"      Assorted-Saver
+       Nop     ""
+       Popup   "XPM"           XPM-Saver
+       Nop     ""
+       Popup   "GL"            GL-Saver
+       Nop     ""
+       Popup   "Marquee Message"       Marquee-Message-Saver
+       Nop     ""
+       Popup   "Nose Message"  Nose-Message-Saver
+       Nop     ""
+       Popup   "Xjack Message" Xjack-Message-Saver
+       Nop     ""
+       Popup   "Special"       Special-Saver
+EndPopup
+
+Popup "Lock_Saver"
+       Title   "Lock_Saver"
+       Popup   "Screenlock"    Screenlock
+       Nop     ""
+       Popup   "Screensaver"   Screensaver
+EndPopup
+
diff --git a/xlockmore-4.14/etc/system.mwmrc.xlock b/xlockmore-4.14/etc/system.mwmrc.xlock
new file mode 100644 (file)
index 0000000..4a2f3f9
--- /dev/null
@@ -0,0 +1,463 @@
+# Add this to your system or personal menu file contents
+# System
+#  Motif file: /usr/lib/X11/system.mwmrc
+#  Desktop file: /usr/dt/config/C/sys.dtwmrc
+# Personal
+#  Motif file: $HOME/.mwmrc
+#  Desktop file: $HOME/.dt/dtwmrc
+# Put this in your RootMenu (mwm) or ProgramsMenu (dtwm) uncommented.
+#  "Lock_Saver"        f.menu Lock_Saver
+# For dt you may have to add the full path of xlock to "xlock" depending
+# whether the location xlock is installed is in a path of DT.
+# See /usr/dt/bin/Xsession look for instances of $PATH for system setup.
+# See supplied dtprofile for personal setup...i.e. DTSOURCEPROFILE=true 
+
+Menu Automata-Lock
+{
+       "Automata-Lock" f.title
+       "Ant"           f.exec "xlock -mode ant -neighbors 4 +truchet &"
+       "Ant Truchet"   f.exec "xlock -mode ant -neighbors 4 -truchet &
+       "Bee"           f.exec "xlock -mode ant -neighbors 6 +truchet &"
+       "Bee Truchet"   f.exec "xlock -mode ant -neighbors 6 -truchet &"
+       "Bug"           f.exec "xlock -mode bug &"
+       "Demon"         f.exec "xlock -mode demon &"
+       "Dilemma"       f.exec "xlock -mode dilemma &"
+       "Life"          f.exec "xlock -mode life &"
+       "Life Callahan" f.exec "xlock -mode life -callahan -size 7 &"
+       "Life1d"        f.exec "xlock -mode life1d &"
+       "Life3d"        f.exec "xlock -mode life3d &"
+       "Loop"          f.exec "xlock -mode loop &"
+       "Voters"        f.exec "xlock -mode voters &"
+       "Wator"         f.exec "xlock -mode wator &"
+       "Wire"          f.exec "xlock -mode wire &"
+       "Random Automata"       f.exec "xlock -mode random -modelist allautomata -fullrandom -neighbors 0 &"
+}
+
+Menu Fractal-Lock
+{
+       "Fractal-Lock"  f.title
+       "Coral"         f.exec "xlock -mode coral &"
+       "Discrete"      f.exec "xlock -mode discrete &"
+       "Drift"         f.exec "xlock -mode drift -fullrandom &"
+       "Flame"         f.exec "xlock -mode flame &"
+       "Flow"          f.exec "xlock -mode flow &"
+       "Forest"        f.exec "xlock -mode forest &"
+       "Hop"           f.exec "xlock -mode hop -fullrandom &"
+       "IFS"           f.exec "xlock -mode ifs &"
+       "Julia"         f.exec "xlock -mode julia +trackmouse &"
+       "Juliaptr"      f.exec "xlock -mode julia -trackmouse &"
+       "Kumppa"        f.exec "xlock -mode kumppa &"
+       "Lightning"     f.exec "xlock -mode lightning &"
+       "Lyapunov"      f.exec "xlock -mode lyapunov -install &"
+       "Mandelbrot"    f.exec "xlock -mode mandelbrot -install &"
+       "Mountain"      f.exec "xlock -mode mountain &"
+       "Sierpinski"    f.exec "xlock -mode sierpinski &"
+       "Strange"       f.exec "xlock -mode strange &"
+       "Thornbird"     f.exec "xlock -mode thornbird &"
+       "Triangle"      f.exec "xlock -mode triangle &"
+       "Turtle"        f.exec "xlock -mode turtle &"
+       "Vines"         f.exec "xlock -mode vines &"
+       "Random Fractal"        f.exec "xlock -mode random -modelist allfractal -fullrandom &"
+}
+
+Menu Geometry-Lock
+{
+       "Geometry-Lock" f.title
+       "Braid"         f.exec "xlock -mode braid &"
+       "Fadeplot"      f.exec "xlock -mode fadeplot &"
+       "Helix"         f.exec "xlock -mode helix -fullrandom &"
+       "Hyper"         f.exec "xlock -mode hyper &"
+       "Ico"           f.exec "xlock -mode ico &"
+       "Kaleid"        f.exec "xlock -mode kaleid &"
+       "Laser"         f.exec "xlock -mode laser &"
+       "Lisa"          f.exec "xlock -mode lisa &"
+       "Lissie"        f.exec "xlock -mode lissie &"
+       "Penrose"       f.exec "xlock -mode penrose +ammann &"
+       "Penrose Ammann"        f.exec "xlock -mode penrose -ammann &"
+       "Petal"         f.exec "xlock -mode petal &"
+       "Qix"           f.exec "xlock -mode qix +complete &"
+       "Qix complete"  f.exec "xlock -mode qix -complete &"
+       "Rotor"         f.exec "xlock -mode rotor &"
+       "Shape"         f.exec "xlock -mode shape &"
+       "Sphere"        f.exec "xlock -mode sphere &"
+       "Spiral"        f.exec "xlock -mode spiral &"
+       "Spline"        f.exec "xlock -mode spline &"
+       "Random Geometry"       f.exec "xlock -mode random -modelist allgeometry -fullrandom &"
+}
+
+Menu Space-Lock
+{
+       "Space-Lock"    f.title
+       "Bouboule"      f.exec "xlock -mode bouboule +use3d &"
+       "Bouboule3d"    f.exec "xlock -mode bouboule -use3d &"
+       "Galaxy"        f.exec "xlock -mode galaxy &"
+       "Grav"          f.exec "xlock -mode grav +trail +decay &"
+       "Grav Trail"    f.exec "xlock -mode grav -trail &"
+       "Grav Decay"    f.exec "xlock -mode grav -decay &"
+       "Rock"          f.exec "xlock -mode star -rock &"
+       "Star"          f.exec "xlock -mode star +rock +use3d -trek 0 &"
+       "Star3d"        f.exec "xlock -mode star -use3d &"
+       "Star Trek"     f.exec "xlock -mode star -trek 100 &"
+       "World"         f.exec "xlock -mode world &"
+       "Random Space"  f.exec "xlock -mode random -modelist allspace -fullrandom &"
+}
+
+Menu Assorted-Lock
+{
+       "Assorted-Lock" f.title
+       "Ball"          f.exec "xlock -mode ball &"
+       "Blot"          f.exec "xlock -mode blot &"
+       "Bounce"        f.exec "xlock -mode bounce &"
+       "Bubble"        f.exec "xlock -mode bubble &"
+       "Clock"         f.exec "xlock -mode clock &"
+       "Crystal"       f.exec "xlock -mode crystal &"
+       "Daisy"         f.exec "xlock -mode daisy &"
+       "Dclock"        f.exec "xlock -mode dclock &"
+       "Decay"         f.exec "xlock -mode decay &"
+       "Deco"          f.exec "xlock -mode deco &"
+       "Eyes"          f.exec "xlock -mode eyes +trackmouse &"
+       "Eyesptr"       f.exec "xlock -mode eyes -trackmouse &"
+       "Goop"          f.exec "xlock -mode goop &"
+       "Marquee"       f.exec "xlock -mode marquee &"
+       "Matrix"        f.exec "xlock -mode matrix &"
+       "Munch"         f.exec "xlock -mode munch &"
+       "Nose"          f.exec "xlock -mode nose &"
+       "Pacman"        f.exec "xlock -mode pacman &"
+       "Pyro"          f.exec "xlock -mode pyro +use3d &"
+       "Pyro3d"        f.exec "xlock -mode pyro -use3d &"
+       "Roll"          f.exec "xlock -mode roll &"
+       "Slip"          f.exec "xlock -mode slip &"
+       "Starfish"      f.exec "xlock -mode starfish -install &"
+       "Swarm"         f.exec "xlock -mode swarm +trackmouse &"
+       "Swarmptr"      f.exec "xlock -mode swarm -trackmouse &"
+       "Swirl"         f.exec "xlock -mode swirl -install &"
+       "Tetris"        f.exec "xlock -mode tetris &"
+       "Tube"          f.exec "xlock -mode tube -install &"
+       "Worm"          f.exec "xlock -mode worm +use3d &"
+       "Worm3d"        f.exec "xlock -mode worm -use3d &"
+       "Xjack"         f.exec "xlock -mode xjack &"
+}
+
+Menu XPM-Lock
+{
+       "XPM-Lock" f.title
+       "Bat"           f.exec "xlock -mode bat &"
+       "Cartoon"       f.exec "xlock -mode cartoon &"
+       "Image"         f.exec "xlock -mode image &"
+       "Flag"          f.exec "xlock -mode flag &"
+       "Life"          f.exec "xlock -mode life &"
+       "Life1d"        f.exec "xlock -mode life1d &"
+       "Maze"          f.exec "xlock -mode maze &"
+       "Puzzle"        f.exec "xlock -mode puzzle &"
+       "Random XPM"    f.exec "xlock -mode random -modelist allxpm -fullrandom &"
+}
+
+Menu GL-Lock
+{
+       "GL-Lock" f.title
+       "Atlantis"      f.exec "xlock -mode atlantis &"
+       "Bubble3d"      f.exec "xlock -mode bubble3d &"
+       "Cage"          f.exec "xlock -mode cage &"
+       "Gears"         f.exec "xlock -mode gears &"
+       "Invert"        f.exec "xlock -mode invert &"
+       "Lament"        f.exec "xlock -mode lament &"
+       "Moebius"       f.exec "xlock -mode moebius &"
+       "Morph3d"       f.exec "xlock -mode morph3d &"
+       "Pipes"         f.exec "xlock -mode pipes &"
+       "Rubik"         f.exec "xlock -mode rubik &"
+       "Sproingies"    f.exec "xlock -mode sproingies &"
+       "Stairs"        f.exec "xlock -mode stairs &"
+       "Superquadrics" f.exec "xlock -mode superquadrics &"
+       "Random GL"     f.exec "xlock -mode random -modelist allgl -fullrandom &"
+}
+
+Menu Marquee-Message-Lock
+{
+       "Marquee-Message-Lock"  f.title
+       "Back Soon"     f.exec "xlock -mode marquee -message "$LOGNAME will be back soon." &"
+       "Overnight"     f.exec "xlock -mode marquee -message "$LOGNAME will be back in the morning." &"
+       "Rude"          f.exec "xlock -mode marquee -message "$LOGNAME not here, please go away! " &"
+}
+
+Menu Nose-Message-Lock
+{
+       "Nose-Message-Lock"     f.title
+       "Back Soon"     f.exec "xlock -mode nose -message "$LOGNAME will be back soon."
+       "Overnight"     f.exec "xlock -mode nose -message "$LOGNAME will be back in the morning." &"
+       "Rude"          f.exec "xlock -mode nose -message "$LOGNAME not here, please go away! " &"
+}
+
+Menu Xjack-Message-Lock
+{
+       "Xjack-Message-Lock"    f.title
+       "Crazy Boy"     f.exec "xlock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+       "Crazy Girl"    f.exec "xlock -mode xjack -message "All work and no play makes $LOGNAME a dull girl." &"
+}
+
+Menu Special-Lock
+{
+       "Special-Lock"  f.title
+       "Blank"         f.exec "xlock -mode blank &"
+       "Bomb"          f.exec "xlock -mode bomb &"
+       "Random nice"   f.exec "xlock -mode random -modelist allnice -fullrandom -neighbors 0 &"
+       "Random standard"       f.exec "xlock -mode random -modelist all-allgl -fullrandom -neighbors 0 &"
+       "Random all"    f.exec "xlock -mode random -modelist all -fullrandom -neighbors 0 &"
+       "Random 3d"     f.exec "xlock -mode random -modelist all3d -use3d -fullrandom &"
+       "Random ptr"    f.exec "xlock -mode random -modelist allmouse -trackmouse -fullrandom &"
+       "Random write"  f.exec "xlock -mode random -modelist allwrite -fullrandom &"
+}
+
+Menu Screenlock
+{
+       "Screenlock" f.title
+       "Cellular Automata"     f.menu Automata-Lock
+       no-label        f.separator
+       "Fractal"       f.menu Fractal-Lock
+       no-label        f.separator
+       "Geometry"      f.menu Geometry-Lock
+       no-label        f.separator
+       "Space"         f.menu Space-Lock
+       no-label        f.separator
+       "Assorted"      f.menu Assorted-Lock
+       no-label        f.separator
+       "XPM"           f.menu XPM-Lock
+       no-label        f.separator
+       "GL"            f.menu GL-Lock
+       no-label        f.separator
+       "Marquee Message"       f.menu Marquee-Message-Lock
+       no-label        f.separator
+       "Nose Message"  f.menu Nose-Message-Lock
+       no-label        f.separator
+       "Xjack Message" f.menu Xjack-Message-Lock
+       no-label        f.separator
+       "Special"       f.menu Special-Lock
+}
+
+Menu Automata-Saver
+{
+       "Automata-Saver"        f.title
+       "Ant"           f.exec "xlock -nolock -mode ant -neighbors 4 +truchet &"
+       "Ant Truchet"   f.exec "xlock -nolock -mode ant -neighbors 4 -truchet &"
+       "Bee"           f.exec "xlock -nolock -mode ant -neighbors 6 +truchet &"
+       "Bee Truchet"   f.exec "xlock -nolock -mode ant -neighbors 6 -truchet &"
+       "Bug"           f.exec "xlock -nolock -mode bug &"
+       "Demon"         f.exec "xlock -nolock -mode demon &"
+       "Dilemma"       f.exec "xlock -nolock -mode dilemma &"
+       "Life"          f.exec "xlock -nolock -mode life &"
+       "Life Callahan" f.exec "xlock -nolock -mode life -callahan -size 7 &"
+       "Life1d"        f.exec "xlock -nolock -mode life1d &"
+       "Life3d"        f.exec "xlock -nolock -mode life3d &"
+       "Loop"          f.exec "xlock -nolock -mode loop &"
+       "Voters"        f.exec "xlock -nolock -mode voters &"
+       "Wator"         f.exec "xlock -nolock -mode wator &"
+       "Wire"          f.exec "xlock -nolock -mode wire &"
+       "Random Automata"       f.exec "xlock -nolock -mode random -modelist allautomata -fullrandom -neighbors 0 &"
+}
+
+Menu Fractal-Saver
+{
+       "Fractal-Saver" f.title
+       "Coral"         f.exec "xlock -nolock -mode coral &"
+       "Discrete"      f.exec "xlock -nolock -mode discrete &"
+       "Drift"         f.exec "xlock -nolock -mode drift -fullrandom &"
+       "Flame"         f.exec "xlock -nolock -mode flame &"
+       "Flow"          f.exec "xlock -nolock -mode flow &"
+       "Forest"        f.exec "xlock -nolock -mode forest &"
+       "Hop"           f.exec "xlock -nolock -mode hop -fullrandom &"
+       "IFS"           f.exec "xlock -nolock -mode ifs &"
+       "Julia"         f.exec "xlock -nolock -mode julia +trackmouse &"
+       "Juliaptr"      f.exec "xlock -nolock -mode julia -trackmouse &"
+       "Kumppa"        f.exec "xlock -nolock -mode kumppa &"
+       "Lightning"     f.exec "xlock -nolock -mode lightning &"
+       "Lyapunov"      f.exec "xlock -nolock -mode lyapunov -install &"
+       "Mandelbrot"    f.exec "xlock -nolock -mode mandelbrot -install &"
+       "Mountain"      f.exec "xlock -nolock -mode mountain &"
+       "Sierpinski"    f.exec "xlock -nolock -mode sierpinski &"
+       "Strange"       f.exec "xlock -nolock -mode strange &"
+       "Thornbird"     f.exec "xlock -nolock -mode thornbird &"
+       "Triangle"      f.exec "xlock -nolock -mode triangle &"
+       "Turtle"        f.exec "xlock -nolock -mode turtle &"
+       "Vines"         f.exec "xlock -nolock -mode vines &"
+       "Random Fractal"        f.exec "xlock -nolock -mode random -modelist allfractal -fullrandom &"
+}
+
+Menu Geometry-Saver
+{
+       "Geometry-Saver"        f.title
+       "Braid"         f.exec "xlock -nolock -mode braid &"
+       "Fadeplot"      f.exec "xlock -nolock -mode fadeplot &"
+       "Helix"         f.exec "xlock -nolock -mode helix -fullrandom &"
+       "Hyper"         f.exec "xlock -nolock -mode hyper &"
+       "Ico"           f.exec "xlock -nolock -mode ico &"
+       "Kaleid"        f.exec "xlock -nolock -mode kaleid &"
+       "Laser"         f.exec "xlock -nolock -mode laser &"
+       "Lisa"          f.exec "xlock -nolock -mode lisa &"
+       "Lissie"        f.exec "xlock -nolock -mode lissie &"
+       "Penrose"       f.exec "xlock -nolock -mode penrose +ammann &"
+       "Penrose Ammann"        f.exec "xlock -nolock -mode penrose -ammann &"
+       "Petal"         f.exec "xlock -nolock -mode petal &"
+       "Qix"           f.exec "xlock -nolock -mode qix +complete &"
+       "Qix complete"  f.exec "xlock -nolock -mode qix -complete &"
+       "Rotor"         f.exec "xlock -nolock -mode rotor &"
+       "Shape"         f.exec "xlock -nolock -mode shape &"
+       "Sphere"        f.exec "xlock -nolock -mode sphere &"
+       "Spiral"        f.exec "xlock -nolock -mode spiral &"
+       "Spline"        f.exec "xlock -nolock -mode spline &"
+       "Random Geometry"       f.exec "xlock -nolock -mode random -modelist allgeometry -fullrandom &"
+}
+
+Menu Space-Saver
+{
+       "Space-Saver"   f.title
+       "Bouboule"      f.exec "xlock -nolock -mode bouboule +use3d &"
+       "Bouboule3d"    f.exec "xlock -nolock -mode bouboule -use3d &"
+       "Galaxy"        f.exec "xlock -nolock -mode galaxy &"
+       "Grav"          f.exec "xlock -nolock -mode grav +trail +decay &"
+       "Grav Trail"    f.exec "xlock -nolock -mode grav -trail &"
+       "Grav Decay"    f.exec "xlock -nolock -mode grav -decay &"
+       "Rock"          f.exec "xlock -nolock -mode star -rock &"
+       "Star"          f.exec "xlock -nolock -mode star +rock +use3d +trek 0 &"
+       "Star3d"        f.exec "xlock -nolock -mode star -use3d &"
+       "Star Trek"     f.exec "xlock -nolock -mode star -trek 100 &"
+       "World"         f.exec "xlock -nolock -mode world &"
+       "Random Space"  f.exec "xlock -nolock -mode random -modelist allspace -fullrandom &"
+}
+
+Menu Assorted-Saver
+{
+       "Assorted-Saver"        f.title
+       "Ball"          f.exec "xlock -nolock -mode ball &"
+       "Blot"          f.exec "xlock -nolock -mode blot &"
+       "Bounce"        f.exec "xlock -nolock -mode bounce &"
+       "Bubble"        f.exec "xlock -nolock -mode bubble &"
+       "Clock"         f.exec "xlock -nolock -mode clock &"
+       "Crystal"       f.exec "xlock -nolock -mode crystal &"
+       "Daisy"         f.exec "xlock -nolock -mode daisy &"
+       "Dclock"        f.exec "xlock -nolock -mode dclock &"
+       "Decay"         f.exec "xlock -nolock -mode decay &"
+       "Deco"          f.exec "xlock -nolock -mode deco &"
+       "Eyes"          f.exec "xlock -nolock -mode eyes +trackmouse &"
+       "Eyesptr"       f.exec "xlock -nolock -mode eyes -trackmouse &"
+       "Goop"          f.exec "xlock -nolock -mode goop &"
+       "Marquee"       f.exec "xlock -nolock -mode marquee &"
+       "Matrix"        f.exec "xlock -nolock -mode matrix &"
+       "Munch"         f.exec "xlock -nolock -mode munch &"
+       "Nose"          f.exec "xlock -nolock -mode nose &"
+       "Pacman"        f.exec "xlock -nolock -mode pacman &"
+       "Pyro"          f.exec "xlock -nolock -mode pyro +use3d &"
+       "Pyro3d"        f.exec "xlock -nolock -mode pyro -use3d &"
+       "Roll"          f.exec "xlock -nolock -mode roll &"
+       "Slip"          f.exec "xlock -nolock -mode slip &"
+       "Starfish"      f.exec "xlock -nolock -mode starfish -install &"
+       "Swarm"         f.exec "xlock -nolock -mode swarm +trackmouse &"
+       "Swarmptr"      f.exec "xlock -nolock -mode swarm -trackmouse &"
+       "Swirl"         f.exec "xlock -nolock -mode swirl -install &"
+       "Tetris"        f.exec "xlock -nolock -mode tetris &"
+       "Tube"          f.exec "xlock -nolock -mode tube -install &"
+       "Worm"          f.exec "xlock -nolock -mode worm +use3d &"
+       "Worm3d"        f.exec "xlock -nolock -mode worm -use3d &"
+       "Xjack"         f.exec "xlock -nolock -mode xjack &"
+}
+
+Menu XPM-Saver
+{
+       "XPM-Saver"     f.title
+       "Bat"           f.exec "xlock -nolock -mode bat &"
+       "Cartoon"       f.exec "xlock -nolock -mode cartoon &"
+       "Image"         f.exec "xlock -nolock -mode image &"
+       "Flag"          f.exec "xlock -nolock -mode flag &"
+       "Life"          f.exec "xlock -nolock -mode life &"
+       "Life1d"        f.exec "xlock -nolock -mode life1d &"
+       "Maze"          f.exec "xlock -nolock -mode maze &"
+       "Puzzle"        f.exec "xlock -nolock -mode puzzle &"
+       "Random XPM"    f.exec "xlock -nolock -mode random -modelist allxpm -fullrandom &"
+}
+
+Menu GL-Saver
+{
+       "GL-Saver"      f.title
+       "Atlantis"      f.exec "xlock -nolock -mode atlantis &"
+       "Bubble3d"      f.exec "xlock -nolock -mode bubble3d &"
+       "Cage"          f.exec "xlock -nolock -mode cage &"
+       "Gears"         f.exec "xlock -nolock -mode gears &"
+       "Invert"        f.exec "xlock -nolock -mode invert &"
+       "Lament"        f.exec "xlock -nolock -mode lament &"
+       "Moebius"       f.exec "xlock -nolock -mode moebius &"
+       "Morph3d"       f.exec "xlock -nolock -mode morph3d &"
+       "Pipes"         f.exec "xlock -nolock -mode pipes &"
+       "Rubik"         f.exec "xlock -nolock -mode rubik &"
+       "Sproingies"    f.exec "xlock -nolock -mode sproingies &"
+       "Stairs"        f.exec "xlock -nolock -mode stairs &"
+       "Superquadrics" f.exec "xlock -nolock -mode superquadrics &"
+       "Random GL"     f.exec "xlock -nolock -mode random -modelist allgl -fullrandom &"
+}
+
+Menu Marquee-Message-Saver
+{
+       "Marquee-Message-Saver" f.title
+       "Brilliant"     f.exec "xlock -nolock -mode marquee -message "WOW! $LOGNAME, You are Brilliant! " &"
+       "Love You"      f.exec "xlock -mode marquee -message "You know, I Love You $LOGNAME." &"
+       "Available"     f.exec "xlock -mode marquee -message "Hey, I am available now! " &"
+}
+
+Menu Nose-Message-Saver
+{
+       "Nose-Message-Saver"    f.title
+       "Brilliant!"    f.exec "xlock -mode nose -message "WOW! $LOGNAME, You are Briilliant! "
+       "Love You"      f.exec "xlock -mode nose -message "You know, I Love You $LOGNAME." &"
+       "Available"     f.exec "xlock -mode nose -message "Hey, I am available now! " &"
+}
+
+Menu Xjack-Message-Saver
+{
+       "Xjack-Message-Saver"   f.title
+       "Crazy Boy"     f.exec "xlock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+       "Crazy Girl"    f.exec "xlock -mode xjack -message "All work and no play makes $LOGNAME a dull girl." &"
+}
+
+Menu Special-Saver
+{
+       "Special-Saver" f.title
+       "Blank"         f.exec "xlock -nolock -mode blank &"
+       "Bomb"          f.exec "xlock -nolock -mode bomb &"
+       "Random nice"   f.exec "xlock -nolock -mode random -modelist allnice -fullrandom -neighbors 0 &"
+       "Random standard"       f.exec "xlock -nolock -mode random -modelist all-allgl -fullrandom -neighbors 0 &"
+       "Random all"    f.exec "xlock -nolock -mode random -modelist all -fullrandom -neighbors 0 &"
+       "Random 3d"     f.exec "xlock -nolock -mode random -modelist all3d -use3d -fullranodm &"
+       "Random ptr"    f.exec "xlock -nolock -mode random -modelist allmouse -trackmouse -fullrandom &"
+       "Random write"  f.exec "xlock -nolock -mode random -modelist allwrite -fullrandom &"
+}
+
+Menu Screensaver
+{
+       "Screensaver"   f.title
+       "Cellular Automata"     f.menu Automata-Saver
+       no-label        f.separator
+       "Fractal"       f.menu Fractal-Saver
+       no-label        f.separator
+       "Geometry"      f.menu Geometry-Saver
+       no-label        f.separator
+       "Space"         f.menu Space-Saver
+       no-label        f.separator
+       "Assorted"      f.menu Assorted-Saver
+       no-label        f.separator
+       "XPM"           f.menu XPM-Saver
+       no-label        f.separator
+       "GL"            f.menu GL-Saver
+       no-label        f.separator
+       "Marquee Message"       f.menu Marquee-Message-Saver
+       no-label        f.separator
+       "Nose Message"  f.menu Nose-Message-Saver
+       no-label        f.separator
+       "Xjack Message" f.menu Xjack-Message-Saver
+       no-label        f.separator
+       "Special"       f.menu Special-Saver
+}
+
+Menu "Lock_Saver"
+{
+       "Lock_Saver"    f.title
+       "Screenlock"    f.menu Screenlock
+       "Screensaver"   f.menu Screensaver
+}
+
diff --git a/xlockmore-4.14/etc/system.olwmrc.xlock b/xlockmore-4.14/etc/system.olwmrc.xlock
new file mode 100644 (file)
index 0000000..6042b7a
--- /dev/null
@@ -0,0 +1,357 @@
+# Add this to your system or personal menu file
+# System: /usr/openwin/lib/openwin-menu
+# Personal $HOME/.openwin-menu
+# Put this in your menu uncommented.
+# "Lock_Saver" MENU   $THISFILEPATH/system.olwmrc.xlock
+
+# put this in your $OPENWINHOME/lib, usually $OPENWINHOME is /usr/openwin
+
+"Screenlock" MENU
+       "Screenlock" TITLE PIN
+       "Cellular Automata" MENU
+         "Automata" TITLE
+               "Ant"                   exec xlock -mode ant -neighbors 4 +truchet
+               "Ant Truchet"           exec xlock -mode ant -neighbors 4 -truchet
+               "Bee"                   exec xlock -mode ant -neighbors 6 +truchet
+               "Bee Truchet"           exec xlock -mode ant -neighbors 6 -truchet
+               "Bug"                   exec xlock -mode bug
+               "Demon"                 exec xlock -mode demon
+               "Dilemma"               exec xlock -mode dilemma
+               "Life"                  exec xlock -mode life
+               "Life Callahan"         exec xlock -mode life -callahan -size 7
+               "Life1d"                exec xlock -mode life1d
+               "Life3d"                exec xlock -mode life3d
+               "Loop"                  exec xlock -mode loop
+               "Voters"                exec xlock -mode voters
+               "Wator"                 exec xlock -mode wator
+               "Wire"                  exec xlock -mode wire
+               "Random Automata"       DEFAULT exec xlock -mode random -modelist allautomata -fullrandom -neighbors 0
+       "Cellular Automata" END
+       "Fractal" MENU
+         "Fractal" TITLE
+               "Coral"                 exec xlock -mode coral
+               "Discrete"              exec xlock -mode discrete
+               "Drift"                 exec xlock -mode drift -fullrandom
+               "Flame"                 exec xlock -mode flame
+               "Flow"                  exec xlock -mode flow
+               "Forest"                exec xlock -mode forest
+               "Hop"                   exec xlock -mode hop -fullrandom
+               "IFS"                   exec xlock -mode ifs
+               "Julia"                 exec xlock -mode julia +trackmouse
+               "Juliaptr"              exec xlock -mode julia -trackmouse
+               "Kumppa"                exec xlock -mode kumppa
+               "Lightning"             exec xlock -mode lightning
+               "Lyapunov"              exec xlock -mode lyaponov -install
+               "Mandelbrot"            exec xlock -mode mandelbrot -install
+               "Mountain"              exec xlock -mode mountain
+               "Sierpinski"            exec xlock -mode sierpinski
+               "Strange"               exec xlock -mode strange
+               "Thornbird"             exec xlock -mode thornbird
+               "Triangle"              exec xlock -mode triangle
+               "Turtle"                exec xlock -mode turtle
+               "Vines"                 exec xlock -mode vines
+               "Random Fractal"        DEFAULT exec xlock -mode random -modelist allfractal -fullrandom
+       "Fractal" END
+       "Geometry" MENU
+         "Geometry" TITLE
+               "Braid"                 exec xlock -mode braid
+               "Fadeplot"              exec xlock -mode fadeplot
+               "Helix"                 exec xlock -mode helix -fullrandom
+               "Hyper"                 exec xlock -mode hyper
+               "Ico"                   exec xlock -mode ico
+               "Kaleid"                exec xlock -mode kaleid
+               "Laser"                 exec xlock -mode laser
+               "Lisa"                  exec xlock -mode lisa
+               "Lissie"                exec xlock -mode lissie
+               "Penrose"               exec xlock -mode penrose +ammann
+               "Penrose Ammann"        exec xlock -mode penrose -ammann
+               "Petal"                 exec xlock -mode petal
+               "Qix"                   exec xlock -mode qix +complete
+               "Qix complete"          exec xlock -mode qix -complete
+               "Shape"                 exec xlock -mode shape
+               "Sphere"                exec xlock -mode sphere
+               "Spiral"                exec xlock -mode spiral
+               "Spline"                exec xlock -mode spline
+               "Random Geometry"       DEFAULT exec xlock -mode random -modelist allgeometry -fullrandom
+       "Geometry" END
+       "Space" MENU
+         "Space" TITLE
+               "Bouboule"              exec xlock -mode bouboule +use3d
+               "Bouboule3d"            exec xlock -mode bouboule -use3d
+               "Galaxy"                exec xlock -mode galaxy
+               "Grav"                  exec xlock -mode grav +trail +grav
+               "Grav Trail"            exec xlock -mode grav -trail
+               "Grav Decay"            exec xlock -mode grav -grav
+               "Rock"                  exec xlock -mode star -rock
+               "Star"                  exec xlock -mode star +rock +use3d -trek 0
+               "Star3d"                exec xlock -mode star -use3d
+               "Star Trek"             exec xlock -mode star -trek 100
+               "World"                 exec xlock -mode world
+               "Random Space"  DEFAULT exec xlock -mode random -modelist allspace -fullrandom
+       "Space" END
+       "Assorted" MENU
+         "Assorted" TITLE
+               "Ball"                  exec xlock -mode ball
+               "Blot"                  exec xlock -mode blot
+               "Bounce"                exec xlock -mode bounce
+               "Bubble"                exec xlock -mode bubble
+               "Clock"                 exec xlock -mode clock
+               "Crystal"       DEFAULT exec xlock -mode crystal
+               "Daisy"                 exec xlock -mode daisy
+               "Dclock"                exec xlock -mode dclock
+               "Decay"                 exec xlock -mode decay
+               "Deco"                  exec xlock -mode deco
+               "Eyes"                  exec xlock -mode eyes +trackmouse
+               "Eyesptr"               exec xlock -mode eyes -trackmouse
+               "Goop"                  exec xlock -mode goop
+               "Marquee"               exec xlock -mode marquee
+               "Matrix"                exec xlock -mode matrix
+               "Munch"                 exec xlock -mode munch
+               "Nose"                  exec xlock -mode nose
+               "Pacman"                exec xlock -mode pacman
+               "Pyro"                  exec xlock -mode pyro +use3d
+               "Pyro3d"                exec xlock -mode pyro -use3d
+               "Roll"                  exec xlock -mode roll
+               "Rotor"                 exec xlock -mode rotor
+               "Slip"                  exec xlock -mode slip
+               "Starfish"              exec xlock -mode starfish -install
+               "Swarm"                 exec xlock -mode swarm +trackmouse
+               "Swarmptr"              exec xlock -mode swarm -trackmouse
+               "Swirl"                 exec xlock -mode swirl -install
+               "Tetris"                exec xlock -mode tetris
+               "Tube"                  exec xlock -mode tube -install
+               "Worm"                  exec xlock -mode worm +use3d
+               "Worm3d"                exec xlock -mode worm -use3d
+               "Xjack"                 exec xlock -mode xjack
+       "Assorted" END
+       "XPM" MENU
+               "Bat"                           exec xlock -mode bat
+               "Cartoon"               exec xlock -mode cartoon
+               "Image"                 exec xlock -mode image
+               "Flag"                  exec xlock -mode flag
+               "Life"                  exec xlock -mode life
+               "Life1d"                exec xlock -mode life1d
+               "Maze"                  exec xlock -mode maze
+               "Puzzle"                exec xlock -mode puzzle
+               "Random XPM"    DEFAULT exec xlock -mode random -modelist allxpm -fullrandom
+       "XPM" END
+       "GL" MENU
+         "GL" TITLE
+               "Atlantis"              exec xlock -mode atlantis
+               "Bubble3d"              exec xlock -mode bubble3d
+               "Cage"                  exec xlock -mode cage
+               "Gears"                 exec xlock -mode gears
+               "Invert"                exec xlock -mode invert 
+               "Lament"                exec xlock -mode lament
+               "Moebius"               exec xlock -mode moebius
+               "Morph3d"               exec xlock -mode morph3d
+               "Pipes"                 exec xlock -mode pipes
+               "Rubik"                 exec xlock -mode rubik
+               "Sproingies"            exec xlock -mode sproingies
+               "Stairs"                exec xlock -mode stairs
+               "Superquadrics"         exec xlock -mode superquadrics
+               "Random GL"     DEFAULT exec xlock -mode random -modelist allgl -fullrandom
+       "GL" END
+       "Marquee Messages" MENU
+         "Marquee Messages" TITLE
+               "Back Soon"     DEFAULT exec xlock -mode marquee -message "$LOGNAME will be back soon."
+               "Overnight"             exec xlock -mode marquee -message "$LOGNAME will be back in the morning."
+               "Rude"                  exec xlock -mode marquee -message "$LOGNAME not here, please go away! "
+       "Marquee Messages" END
+       "Nose Messages" MENU
+         "Nose Messages" TITLE
+               "Back Soon"     DEFAULT exec xlock -mode nose -message "$LOGNAME will be back soon."
+               "Overnight"             exec xlock -mode nose -message "$LOGNAME will be back in the morning."
+               "Rude"                  exec xlock -mode nose -message "$LOGNAME not here, please go away! "
+       "Nose Messages" END
+       "Xjack Messages" MENU
+         "Nose Messages" TITLE
+               "Crazy Boy"     DEFAULT exec xlock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+               "Crazy Girl"            exec xlock -mode xjack -message "All work and no play makes $LOGNAME a dull girl."
+       "Xjack Messages" END
+       "Special" DEFAULT MENU
+         "Special" TITLE
+               "Blank"                 exec xlock -mode blank
+               "Bomb"                  exec xlock -mode bomb
+               "Random nice"           exec xlock -mode random -modelist allnice -fullrandom -neighbors 0
+               "Random standard"       exec xlock -mode random -modelist all-allgl -fullrandom -neighbors 0
+               "Random all"    DEFAULT exec xlock -mode random -modelist all -fullrandom -neighbors 0
+               "Random 3d"             exec xlock -modelist all3d -use3d -fullrandom
+               "Random ptr"            exec xlock -modelist allmouse -trackmouse -fullrandom
+               "Random write"          exec xlock -modelist allwrite -fullrandom
+       "Special" END
+"Screenlock" END
+"Screensaver" MENU
+       "Screensaver" TITLE PIN
+       "Cellular-Automata" MENU
+         "Automata" TITLE
+               "Ant"                   exec xlock -nolock -mode ant -neighbors 4 +truchet
+               "Ant Truchet"           exec xlock -nolock -mode ant -neighbors 4 -truchet
+               "Bee"                   exec xlock -nolock -mode ant -neighbors 6 +truchet
+               "Bee Truchet"           exec xlock -nolock -mode ant -neighbors 6 -truchet
+               "Bug"                   exec xlock -nolock -mode bug
+               "Demon"                 exec xlock -nolock -mode demon
+               "Dilemma"                       exec xlock -nolock -mode dilemma
+               "Life"                  exec xlock -nolock -mode life
+               "Life Callahan"         exec xlock -nolock -mode life -callahan -size 7
+               "Life1d"                exec xlock -nolock -mode life1d
+               "Life3d"                exec xlock -nolock -mode life3d
+               "Loop"                  exec xlock -nolock -mode loop
+               "Voters"                exec xlock -nolock -mode voters
+               "Wator"                 exec xlock -nolock -mode wator
+               "Wire"                  exec xlock -nolock -mode wire
+               "Random Automata"       DEFAULT exec xlock -nolock -mode random -modelist allautomata -fullrandom -neighbors 0
+       "Cellular-Automata" END
+       "Fractal" MENU
+         "Fractal" TITLE
+               "Coral"                 exec xlock -nolock -mode coral
+               "Discrete"              exec xlock -nolock -mode discrete
+               "Drift"                 exec xlock -nolock -mode drift -fullrandom
+               "Flame"                 exec xlock -nolock -mode flame
+               "Flow"                  exec xlock -nolock -mode flow
+               "Forest"                exec xlock -nolock -mode forest
+               "Hop"                   exec xlock -nolock -mode hop -fullrandom
+               "IFS"                   exec xlock -nolock -mode ifs
+               "Julia"                 exec xlock -nolock -mode julia +trackmouse
+               "Juliaptr"              exec xlock -nolock -mode julia -trackmouse
+               "Kumppa"                exec xlock -nolock -mode kumppa
+               "Lightning"             exec xlock -nolock -mode lightning
+               "Lyapunov"              exec xlock -nolock -mode lyapunov -install
+               "Mandelbrot"            exec xlock -nolock -mode mandelbrot -install
+               "Mountain"              exec xlock -nolock -mode mountain
+               "Sierpinski"            exec xlock -nolock -mode sierpinski
+               "Strange"               exec xlock -nolock -mode strange
+               "Thornbird"             exec xlock -nolock -mode thornbird
+               "Triangle"              exec xlock -nolock -mode triangle
+               "Turtle"                exec xlock -nolock -mode turtle
+               "Vines"                 exec xlock -nolock -mode vines
+               "Random Fractal"        DEFAULT exec xlock -nolock -mode random -modelist allfractal -fullrandom
+       "Fractal" END
+       "Geometry" MENU
+         "Geometry" TITLE
+               "Braid"                 exec xlock -nolock -mode braid
+               "Fadeplot"              exec xlock -nolock -mode fadeplot
+               "Helix"                 exec xlock -nolock -mode helix -fullrandom
+               "Hyper"                 exec xlock -nolock -mode hyper
+               "Ico"                   exec xlock -nolock -mode ico
+               "Kaleid"                exec xlock -nolock -mode kaleid
+               "Laser"                 exec xlock -nolock -mode laser
+               "Lisa"          exec xlock -nolock -mode lisa
+               "Lissie"                exec xlock -nolock -mode lissie
+               "Penrose"               exec xlock -nolock -mode penrose +ammann
+               "Penrose Ammann"        exec xlock -nolock -mode penrose -ammann
+               "Petal"                 exec xlock -nolock -mode petal
+               "Qix"                   exec xlock -nolock -mode qix +complete
+               "Qix complete"          exec xlock -nolock -mode qix -complete
+               "Shape"                 exec xlock -nolock -mode shape
+               "Sphere"                exec xlock -nolock -mode sphere
+               "Spiral"                exec xlock -nolock -mode spiral
+               "Spline"                exec xlock -nolock -mode spline
+               "Random Geometry"       DEFAULT exec xlock -nolock -mode random -modelist allgeometry -fullrandom
+       "Geometry" END
+       "Space" MENU
+         "Space" TITLE
+               "Bouboule"              exec xlock -nolock -mode bouboule +use3d
+               "Bouboule3d"            exec xlock -nolock -mode bouboule -use3d
+               "Galaxy"                exec xlock -nolock -mode galaxy
+               "Grav"                  exec xlock -nolock -mode grav +trail +decay
+               "Grav Trail"            exec xlock -nolock -mode grav -trail
+               "Grav Decay"            exec xlock -nolock -mode grav -decay
+               "Rock"                  exec xlock -nolock -mode star -rock +use3d -trek 0
+               "Star"                  exec xlock -nolock -mode star +rock +use3d -trek 0
+               "Star3d"                exec xlock -nolock -mode star -use3d
+               "Star Trek"             exec xlock -nolock -mode star -trek 100
+               "World"                 exec xlock -nolock -mode world
+               "Random Space"  DEFAULT exec xlock -nolock -mode random -modelist allspace -fullrandom
+       "Space" END
+       "Assorted" MENU
+         "Assorted" TITLE
+               "Ball"                  exec xlock -nolock -mode ball
+               "Blot"                  exec xlock -nolock -mode blot
+               "Bounce"                exec xlock -nolock -mode bounce
+               "Bubble"                exec xlock -nolock -mode bubble
+               "Clock"                 exec xlock -nolock -mode clock
+               "Crystal" DEFAULT       exec xlock -nolock -mode crystal
+               "Daisy"                 exec xlock -nolock -mode daisy
+               "Dclock"                exec xlock -nolock -mode dclock
+               "Decay"                 exec xlock -nolock -mode decay
+               "Deco"                  exec xlock -nolock -mode deco
+               "Eyes"                  exec xlock -nolock -mode eyes +trackmouse
+               "Eyesptr"               exec xlock -nolock -mode eyes -trackmouse
+               "Goop"                  exec xlock -nolock -mode goop
+               "Marquee"               exec xlock -nolock -mode marquee
+               "Matrix"                exec xlock -nolock -mode matrix
+               "Munch"                 exec xlock -nolock -mode munch
+               "Nose"                  exec xlock -nolock -mode nose
+               "Pacman"                exec xlock -nolock -mode pacman
+               "Pyro"                  exec xlock -nolock -mode pyro +use3d
+               "Pyro3d"                exec xlock -nolock -mode pyro -use3d
+               "Roll"                  exec xlock -nolock -mode roll
+               "Rotor"                 exec xlock -nolock -mode rotor
+               "Slip"                  exec xlock -nolock -mode slip
+               "Starfish"      exec xlock -nolock -mode starfish -install
+               "Swarm"                 exec xlock -nolock -mode swarm +trackmouse
+               "Swarmptr"      exec xlock -nolock -mode swarm -trackmouse
+               "Swirl"                 exec xlock -nolock -mode swirl -install
+               "Tetris"                exec xlock -nolock -mode tetris
+               "Tube"                  exec xlock -nolock -mode tube -install
+               "Worm"                  exec xlock -nolock -mode worm +use3d
+               "Worm3d"                exec xlock -nolock -mode worm -use3d
+               "Xjack"                 exec xlock -nolock -mode xjack
+       "Assorted" END
+       "XPM" MENU
+               "Bat"                   exec xlock -nolock -mode bat
+               "Cartoon"               exec xlock -nolock -mode cartoon
+               "Image"                 exec xlock -nolock -mode image
+               "Flag"                  exec xlock -nolock -mode flag
+               "Life"                  exec xlock -nolock -mode life
+               "Life1d"                exec xlock -nolock -mode life1d
+               "Maze"                  exec xlock -nolock -mode maze
+               "Puzzle"                exec xlock -nolock -mode puzzle
+               "Random XPM"    DEFAULT exec xlock -nolock -mode random -modelist allxpm -fullrandom
+       "XPM" END
+       "GL" MENU
+               "Atlantis"              exec xlock -nolock -mode atlantis
+               "Bubble3d"              exec xlock -nolock -mode bubble3d
+               "Cage"                  exec xlock -nolock -mode cage
+               "Gears"                 exec xlock -nolock -mode gears
+               "Invert"                exec xlock -nolock -mode invert
+               "Lament"                exec xlock -nolock -mode lament
+               "Moebius"               exec xlock -nolock -mode moebius
+               "Morph3d"               exec xlock -nolock -mode morph3d
+               "Pipes"                 exec xlock -nolock -mode pipes
+               "Rubik"                 exec xlock -nolock -mode rubik
+               "Sprongies"             exec xlock -nolock -mode sproingies
+               "Stairs"                exec xlock -nolock -mode stairs
+               "Superquadrics"         exec xlock -nolock -mode superquadrics
+               "Random GL"     DEFAULT exec xlock -nolock -mode random -modelist allgl -fullrandom
+       "GL" END
+       "Marquee Messages" MENU
+         "Marquee Messages" TITLE
+               "Brilliant"             exec xlock -nolock -mode marquee -message "WOW! $LOGNAME, You are Brilliant! "
+               "Love You"              exec xlock -nolock -mode marquee -message "You know, I Love You $LOGNAME."
+               "Available"             exec xlock -nolock -mode marquee -message "Hey, I am available now! "
+       "Marquee Messages" END
+       "Nose Messages" MENU
+         "Nose Messages" TITLE
+               "Brilliant"             exec xlock -nolock -mode nose -message "WOW! $LOGNAME, You are Brilliant! "
+               "Love You"              exec xlock -nolock -mode nose -message "You know, I Love You $LOGNAME."
+               "Available"             exec xlock -nolock -mode nose -message "Hey, I am available now! "
+       "Nose Messages" END
+       "Xjack Messages" MENU
+         "Xjack Messages" TITLE
+               "Crazy Boy"             exec xlock -nolock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+               "Crazy Girl"            exec xlock -nolock -mode xjack -message "All work and no play makes $LOGNAME a dull girl."
+       "Xjack Messages" END
+       "Special" DEFAULT MENU
+         "Special" TITLE
+               "Blank"                 exec xlock -nolock -mode blank
+               "Bomb"                  exec xlock -nolock -mode bomb
+               "Random nice"           exec xlock -nolock -mode random -modelist allnice -fullrandom -neighbors 0
+               "Random standard"       exec xlock -nolock -mode random -modelist all-allgl -fullrandom -neighbors 0
+               "Random all"    DEFAULT exec xlock -nolock -mode random -modelist all -fullrandom -neighbors 0
+               "Random 3d"             exec xlock -nolock -modelist all3d -use3d -fullrandom
+               "Random ptr"            exec xlock -nolock -modelist allmouse -trackmouse -fullrandom
+               "Random write"          exec xlock -nolock -modelist allwrite -fullrandom
+       "Special" END
+"Screensaver" END
diff --git a/xlockmore-4.14/etc/system.wmrc.xlock b/xlockmore-4.14/etc/system.wmrc.xlock
new file mode 100644 (file)
index 0000000..6aa51c3
--- /dev/null
@@ -0,0 +1,360 @@
+# Copy this to your personal Library directory for WindowMaker:
+# $HOME/GNUstep/Library/WindowMaker/
+# And add this to $HOME/GNUstep/Library/WindowMaker/menu (or menu.xx)
+# Put this in your "Workspace" menu
+#      "Lock_Saver"    OPEN_MENU system.wmrc.xlock
+
+"Lock_Saver" MENU
+"ScreenLock" MENU
+"Automata" MENU
+       "Ant"           EXEC    xlock -mode ant -neighbors 4 +truchet
+       "Ant Truchet"   EXEC    xlock -mode ant -neighbors 4 -truchet
+       "Bee"           EXEC    xlock -mode ant -neighbors 6 +truchet
+       "Bee Truchet"   EXEC    xlock -mode ant -neighbors 6 -truchet
+       "Bug"           EXEC    xlock -mode bug
+       "Demon"         EXEC    xlock -mode demon
+       "Dilemma"       EXEC    xlock -mode dilemma
+       "Life"          EXEC    xlock -mode life
+       "Life Callahan" EXEC    xlock -mode life -callahan -size 7
+       "Life1d"        EXEC    xlock -mode life1d
+       "Life3d"        EXEC    xlock -mode life3d
+       "Loop"          EXEC    xlock -mode loop
+       "Voters"        EXEC    xlock -mode voters
+       "Wator"         EXEC    xlock -mode wator
+       "Wire"          EXEC    xlock -mode wire
+       "Random"        EXEC    xlock -mode random -modelist allautomata -fullrandom -neighbors 0
+"Automata" END
+
+"Fractal" MENU
+       "Coral"         EXEC    xlock -mode coral
+       "Discrete"      EXEC    xlock -mode discrete
+       "Drift"         EXEC    xlock -mode drift -fullrandom
+       "Flame"         EXEC    xlock -mode flame
+       "Flow"          EXEC    xlock -mode flow
+       "Forest"        EXEC    xlock -mode forest
+       "Hop"           EXEC    xlock -mode hop -fullrandom
+       "IFS"           EXEC    xlock -mode ifs
+       "Julia"         EXEC    xlock -mode julia +trackmouse
+       "Juliaptr"      EXEC    xlock -mode julia -trackmouse
+       "Kumppa"        EXEC    xlock -mode kumppa
+       "Lightning"     EXEC    xlock -mode lightning
+       "Lyapunov"      EXEC    xlock -mode lyapunov -install
+       "Mandelbrot"    EXEC    xlock -mode mandelbrot -install
+       "Mountain"      EXEC    xlock -mode mountain
+       "Sierpinski"    EXEC    xlock -mode sierpinski 
+       "Strange"       EXEC    xlock -mode strange 
+       "Thornbird"     EXEC    xlock -mode thornbird
+       "Triangle"      EXEC    xlock -mode triangle
+       "Turtle"        EXEC    xlock -mode turtle
+       "Vines" EXEC    xlock -mode vines
+       "Random"        EXEC    xlock -mode random -modelist allfractal -fullrandom
+"Fractal" END
+
+"Geometry" MENU
+       "Braid"         EXEC    xlock -mode braid
+       "Fadeplot"      EXEC    xlock -mode fadeplot
+       "Helix"         EXEC    xlock -mode helix -fullrandom
+       "Hyper"         EXEC    xlock -mode hyper
+       "Ico"           EXEC    xlock -mode ico
+       "Kaleid"        EXEC    xlock -mode kaleid
+       "Laser"         EXEC    xlock -mode laser
+       "Lisa"  EXEC    xlock -mode lisa
+       "Lissie"        EXEC    xlock -mode lissie
+       "Penrose"       EXEC    xlock -mode penrose +ammann
+       "Penrose Ammann"        EXEC xlock -mode penrose -ammann
+       "Petal"         EXEC    xlock -mode petal
+       "Qix"           EXEC    xlock -mode qix +complete
+       "Qix complete"          EXEC    xlock -mode qix -complete
+       "Rotor"         EXEC    xlock -mode rotor
+       "Shape"         EXEC    xlock -mode shape
+       "Sphere"        EXEC    xlock -mode sphere
+       "Spiral"        EXEC    xlock -mode spiral
+       "Spline"        EXEC    xlock -mode spline
+       "Random"        EXEC    xlock -mode random -modelist allgeometry -fullrandom
+"Geometry" END
+
+"Space" MENU
+       "Bouboule"      EXEC    xlock -mode bouboule +use3d
+       "Bouboule3d"    EXEC    xlock -mode bouboule -use3d
+       "Galaxy"        EXEC    xlock -mode galaxy
+       "Grav"          EXEC    xlock -mode grav +trail +decay
+       "Grav Trail"    EXEC    xlock -mode grav -trail
+       "Grav Decay"    EXEC    xlock -mode grav -decay
+       "Rock"          EXEC    xlock -mode star -rock
+       "Star"          EXEC    xlock -mode star +rock +use3d +trek 0
+       "Star3d"        EXEC    xlock -mode star -use3d
+       "Star Trek"     EXEC    xlock -mode star -trek 100
+       "World"         EXEC    xlock -mode world
+       "Random Space"  EXEC    xlock -mode random -modelist allspace
+"Space" END
+
+"Assorted" MENU
+       "Ball"          EXEC    xlock -mode ball
+       "Blot"          EXEC    xlock -mode blot
+       "Bounce"        EXEC    xlock -mode bounce
+       "Bubble"        EXEC    xlock -mode bubble
+       "Clock"         EXEC    xlock -mode clock
+       "Crystal"       EXEC    xlock -mode crystal
+       "Daisy"         EXEC    xlock -mode daisy
+       "Dclock"        EXEC    xlock -mode dclock
+       "Decay"         EXEC    xlock -mode decay
+       "Deco"          EXEC    xlock -mode deco
+       "Eyes"          EXEC    xlock -mode eyes +trackmouse
+       "Eyesptr"       EXEC    xlock -mode eyes -trackmouse
+       "Goop"          EXEC    xlock -mode goop
+       "Marquee"       EXEC    xlock -mode marquee
+       "Matrix"        EXEC    xlock -mode matrix
+       "Munch"         EXEC    xlock -mode munch
+       "Nose"          EXEC    xlock -mode nose
+       "Pacman"        EXEC    xlock -mode pacman
+       "Pyro"          EXEC    xlock -mode pyro +use3d
+       "Pyro3d"        EXEC    xlock -mode pyro -use3d
+       "Roll"          EXEC    xlock -mode roll
+       "Slip"          EXEC    xlock -mode slip
+       "Starfish"      EXEC    xlock -mode starfish -install
+       "Swarm"         EXEC    xlock -mode swarm +trackmouse
+       "Swarmptr"      EXEC    xlock -mode swarm -trackmouse
+       "Swirl"         EXEC    xlock -mode swirl -install
+       "Tetris"                EXEC    xlock -mode tetris
+       "Tube"          EXEC    xlock -mode tube -install
+       "Worm"          EXEC    xlock -mode worm +use3d
+       "Worm3d"        EXEC    xlock -mode worm -use3d
+       "Xjack" EXEC    xlock -mode xjack
+"Assorted" END
+
+"XPM" MENU
+       "Bat"           EXEC    xlock -mode bat
+       "Cartoon"       EXEC    xlock -mode cartoon
+       "Image"         EXEC    xlock -mode image
+       "Flag"          EXEC    xlock -mode flag
+       "Life"          EXEC    xlock -mode life
+       "Life1d"        EXEC    xlock -mode life1d
+       "Maze"          EXEC    xlock -mode maze
+       "Puzzle"        EXEC    xlock -mode puzzle
+       "Random"        EXEC    xlock -mode random -modelist allxpm -fullrandom
+"XPM" END
+
+"GL" MENU
+       "Atlantis"      EXEC    xlock -mode atlantis
+       "Bubble3d"      EXEC    xlock -mode bubble3d
+       "Cage"          EXEC    xlock -mode cage
+       "Gears"         EXEC    xlock -mode gears
+       "Invert"        EXEC    xlock -mode invert
+       "Lament"        EXEC    xlock -mode lament
+       "Moebius"       EXEC    xlock -mode moebius
+       "Morph3d"       EXEC    xlock -mode morph3d
+       "Pipes"         EXEC    xlock -mode pipes
+       "Rubik"         EXEC    xlock -mode rubik
+       "Sproingies"    EXEC    xlock -mode sproingies
+       "Stairs"        EXEC    xlock -mode stairs
+       "Superquadrics" EXEC    xlock -mode superquadrics
+       "Text3d"        EXEC    xlock -mode text3d -message "$LOGNAME"
+       "Random"        EXEC    xlock -mode random -modelist allgl -fullrandom
+"GL" END
+
+"Marquee-Message" MENU
+       "Back Soon"     EXEC    xlock -mode marquee -message "$LOGNAME will be back soon."
+       "Overnight"     EXEC    xlock -mode marquee -message "$LOGNAME will be back in the morning."
+       "Rude"          EXEC    xlock -mode marquee -message "$LOGNAME not here, please go away!"
+"Marquee-Message" END
+
+"Nose-Message" MENU
+       "Back Soon"     EXEC    xlock -mode nose -message "$LOGNAME will be back soon."
+       "Overnight"     EXEC    xlock -mode nose -message "$LOGNAME will be back in the morning."
+       "Rude"          EXEC    xlock -mode nose -message "$LOGNAME not here, please go away!"
+"Nose-Message" END
+
+"Xjack-Message" MENU
+       "Crazy Boy"     EXEC    xlock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+       "Crazy Girl"    EXEC    xlock -mode xjack -message "All work and no play makes $LOGNAME a dull girl."
+"Xjack-Message" END
+
+"Special" MENU
+       "Blank"         EXEC    xlock -mode blank
+       "Bomb"          EXEC    xlock -mode bomb
+       "Random nice"   EXEC    xlock -mode random -modelist allnice -fullrandom -neighbors 0
+       "Random standard"       EXEC    xlock -mode random -modelist all-allgl -fullrandom -neighbors 0
+       "Random all"    EXEC    xlock -mode random -modelist all -fullrandom -neighbors 0
+       "Random 3d"     EXEC    xlock -mode random -modelist all3d -use3d -fullrandom
+       "Random ptr"    EXEC    xlock -mode random -modelist allmouse -trackmouse -fullrandom
+       "Random write"  EXEC    xlock -mode random -modelist allwrite -install -fullrandom
+"Special" END
+"ScreenLock" END
+
+"ScreenSaver" MENU
+"Automata" MENU
+       "Ant"           EXEC    xlock -nolock -mode ant -neighbors 4 +truchet
+       "Ant Truchet"   EXEC    xlock -nolock -mode ant -neighbors 4 -truchet
+       "Bee"           EXEC    xlock -nolock -mode ant -neighbors 6 +truchet
+       "Bee Truchet"   EXEC    xlock -nolock -mode ant -neighbors 6 -truchet
+       "Bug"           EXEC    xlock -nolock -mode bug
+       "Demon"         EXEC    xlock -nolock -mode demon
+       "Dilemma"       EXEC    xlock -nolock -mode dilemma
+       "Life"          EXEC    xlock -nolock -mode life
+       "Life Callahan" EXEC    xlock -nolock -mode life -callahan -size 7
+       "Life1d"        EXEC    xlock -nolock -mode life1d
+       "Life3d"        EXEC    xlock -nolock -mode life3d
+       "Loop"          EXEC    xlock -nolock -mode loop
+       "Voters"        EXEC    xlock -nolock -mode voters
+       "Wator"         EXEC    xlock -nolock -mode wator
+       "Wire"          EXEC    xlock -nolock -mode wire
+       "Random"        EXEC    xlock -nolock -mode random -modelist allautomata -fullrandom -neighbors 0
+"Automata" END
+
+"Fractal" MENU
+       "Coral"         EXEC    xlock -nolock -mode coral
+       "Discrete"      EXEC    xlock -nolock -mode discrete
+       "Drift"         EXEC    xlock -nolock -mode drift -fullrandom
+       "Flame"         EXEC    xlock -nolock -mode flame
+       "Flow"          EXEC    xlock -nolock -mode flow
+       "Forest"        EXEC    xlock -nolock -mode forest
+       "Hop"           EXEC    xlock -nolock -mode hop -fullrandom
+       "IFS"           EXEC    xlock -nolock -mode ifs
+       "Julia"         EXEC    xlock -nolock -mode julia +trackmouse
+       "Juliaptr"      EXEC    xlock -nolock -mode julia -trackmouse
+       "Kumppa"        EXEC    xlock -nolock -mode kumppa
+       "Lightning"     EXEC    xlock -nolock -mode lightning
+       "Lyapunov"      EXEC    xlock -nolock -mode lyapunov -install
+       "Mandelbrot"    EXEC    xlock -nolock -mode mandelbrot -install
+       "Mountain"      EXEC    xlock -nolock -mode mountain
+       "Sierpinski"    EXEC    xlock -nolock -mode sierpinski
+       "Strange"       EXEC    xlock -nolock -mode strange
+       "Thornbird"     EXEC    xlock -nolock -mode thornbird
+       "Triangle"      EXEC    xlock -nolock -mode triangle
+       "Turtle"        EXEC    xlock -nolock -mode turtle
+       "Vines"         EXEC    xlock -nolock -mode vines
+       "Random"        EXEC    xlock -nolock -mode random -modelist allfractal -fullrandom
+"Fractal" END
+
+"Geometry" MENU
+       "Braid"         EXEC    xlock -nolock -mode braid
+       "Fadeplot"      EXEC    xlock -nolock -mode fadeplot
+       "Helix"         EXEC    xlock -nolock -mode helix -fullrandom
+       "Hyper"         EXEC    xlock -nolock -mode hyper
+       "Ico"           EXEC    xlock -nolock -mode ico
+       "Kaleid"        EXEC    xlock -nolock -mode kaleid
+       "Laser"         EXEC    xlock -nolock -mode laser
+       "Lisa"          EXEC    xlock -nolock -mode lisa
+       "Lissie"        EXEC    xlock -nolock -mode lissie
+       "Penrose"       EXEC    xlock -nolock -mode penrose +ammann
+       "Penrose Ammann"        EXEC xlock -nolock -mode penrose -ammann
+       "Petal"         EXEC    xlock -nolock -mode petal
+       "Qix"           EXEC    xlock -nolock -mode qix +complete
+       "Qix complete"  EXEC    xlock -nolock -mode qix -complete
+       "Rotor"         EXEC    xlock -nolock -mode rotor
+       "Shape"         EXEC    xlock -nolock -mode shape
+       "Sphere"        EXEC    xlock -nolock -mode sphere
+       "Spiral"        EXEC    xlock -nolock -mode spiral
+       "Spline"        EXEC    xlock -nolock -mode spline
+       "Random"        EXEC    xlock -nolock -mode random -modelist allgeometry
+"Geometry" END
+
+"Space" MENU
+       "Bouboule"      EXEC    xlock -nolock -mode bouboule +use3d
+       "Bouboule3d"    EXEC    xlock -nolock -mode bouboule -use3d
+       "Galaxy"        EXEC    xlock -nolock -mode galaxy
+       "Grav"          EXEC    xlock -nolock -mode grav +trail +decay
+       "Grav Trail"    EXEC    xlock -nolock -mode grav -trail
+       "Grav Decay"    EXEC    xlock -nolock -mode grav -decay
+       "Rock"          EXEC    xlock -nolock -mode star -rock
+       "Star"          EXEC    xlock -nolock -mode star +rock +use3d +trek 0
+       "Star3d"        EXEC    xlock -nolock -mode star -use3d
+       "Star Trek"     EXEC    xlock -nolock -mode star -trek 100
+       "World"         EXEC    xlock -nolock -mode world
+       "Random Space"  EXEC    xlock -nolock -mode random -modelist allspace
+"Space" END
+
+"Assorted" MENU
+       "Ball"          EXEC    xlock -nolock -mode ball
+       "Blot"          EXEC    xlock -nolock -mode blot
+       "Bounce"        EXEC    xlock -nolock -mode bounce
+       "Bubble"        EXEC    xlock -nolock -mode bubble
+       "Clock"         EXEC    xlock -nolock -mode clock
+       "Crystal"       EXEC    xlock -nolock -mode crystal
+       "Daisy"         EXEC    xlock -nolock -mode daisy
+       "Dclock"        EXEC    xlock -nolock -mode dclock
+       "Decay"         EXEC    xlock -nolock -mode decay
+       "Deco"          EXEC    xlock -nolock -mode deco
+       "Eyes"          EXEC    xlock -nolock -mode eyes +trackmouse
+       "Eyesptr"       EXEC    xlock -nolock -mode eyes -trackmouse
+       "Goop"          EXEC    xlock -nolock -mode goop
+       "Marquee"       EXEC    xlock -nolock -mode marquee
+       "Matrix"        EXEC    xlock -nolock -mode matrix
+       "Munch"         EXEC    xlock -nolock -mode munch
+       "Nose"          EXEC    xlock -nolock -mode nose
+       "Pacman"        EXEC    xlock -nolock -mode pacman
+       "Pyro"          EXEC    xlock -nolock -mode pyro +use3d
+       "Pyro3d"        EXEC    xlock -nolock -mode pyro -use3d
+       "Roll"          EXEC    xlock -nolock -mode roll
+       "Slip"          EXEC    xlock -nolock -mode slip
+       "Starfish"      EXEC    xlock -nolock -mode starfish -install
+       "Swarm"         EXEC    xlock -nolock -mode swarm +trackmouse
+       "Swarmptr"      EXEC    xlock -nolock -mode swarm -trackmouse
+       "Swirl"         EXEC    xlock -nolock -mode swirl -install
+       "Tetris"        EXEC    xlock -nolock -mode tetris
+       "Tube"          EXEC    xlock -nolock -mode tube -install
+       "Worm"          EXEC    xlock -nolock -mode worm +use3d
+       "Worm3d"        EXEC    xlock -nolock -mode worm -use3d
+       "Xjack"         EXEC    xlock -nolock -mode xjack
+"Assorted" END
+
+"XPM" MENU
+       "Bat"           EXEC    xlock -nolock -mode bat
+       "Cartoon"       EXEC    xlock -nolock -mode cartoon
+       "Image"         EXEC    xlock -nolock -mode image
+       "Flag"          EXEC    xlock -nolock -mode flag
+       "Life"          EXEC    xlock -nolock -mode life
+       "Life1d"        EXEC    xlock -nolock -mode life1d
+       "Maze"          EXEC    xlock -nolock -mode maze
+       "Puzzle"        EXEC    xlock -nolock -mode puzzle
+       "Random"        EXEC    xlock -nolock -mode random -modelist allxpm -fullrandom
+"XPM" END
+
+"GL" MENU
+       "Atlantis"      EXEC    xlock -nolock -mode atlantis
+       "Bubble3d"      EXEC    xlock -nolock -mode bubble3d
+       "Cage"          EXEC    xlock -nolock -mode cage
+       "Gears"         EXEC    xlock -nolock -mode gears
+       "Invert"        EXEC    xlock -nolock -mode invert
+       "Lament"        EXEC    xlock -nolock -mode lament
+       "Moebius"       EXEC    xlock -nolock -mode moebius
+       "Morph3d"       EXEC    xlock -nolock -mode morph3d
+       "Pipes"         EXEC    xlock -nolock -mode pipes
+       "Rubik"         EXEC    xlock -nolock -mode rubik
+       "Sproingies"    EXEC    xlock -nolock -mode sproingies
+       "Stairs"        EXEC    xlock -nolock -mode stairs
+       "Superquadrics" EXEC    xlock -nolock -mode superquadrics
+       "Text3d"        EXEC    xlock -nolock -mode text3d -message "$LOGNAME"
+       "Random"        EXEC    xlock -nolock -mode random -modelist allgl -fullrandom
+"GL" END
+
+"Marquee-Message" MENU
+       "Brilliant!"    EXEC    xlock -nolock -mode marquee -message "WOW! $LOGNAME, You're Brilliant!"
+       "Love You"      EXEC    xlock -nolock -mode marquee -message "You know, I Love You $LOGNAME."
+       "Available"     EXEC    xlock -nolock -mode marquee -message "Hey, I'm available now!"
+"Marquee-Message" END
+
+"Nose-Message" MENU
+       "Brilliant!"    EXEC    xlock -nolock -mode nose -message "WOW! $LOGNAME, You're Brilliant!"
+       "Love You"      EXEC    xlock -nolock -mode nose -message "You know, I Love You $LOGNAME."
+       "Available"     EXEC    xlock -nolock -mode nose -message "Hey, I'm available now!"
+"Nose-Message" END
+
+"Xjack-Message" MENU
+       "Crazy Boy"     EXEC    xlock -nolock -mode xjack -message "All work and no play makes $LOGNAME a dull boy."
+       "Crazy Girl"    EXEC    xlock -nolock -mode xjack -message "All work and no play makes $LOGNAME a dull girl."
+"Xjack-Message" END
+
+"Special" MENU
+       "Blank"         EXEC    xlock -nolock -mode blank
+       "Bomb"          EXEC    xlock -nolock -mode bomb
+       "Random nice"   EXEC    xlock -nolock -mode random -modelist allnice -fullrandom -neighbors 0
+       "Random standard"       EXEC    xlock -nolock -mode random -modelist all-allgl -fullrandom -neighbors 0
+       "Random all"    EXEC    xlock -nolock -mode random -modelist all -fullrandom -neighbors 0
+       "Random 3d"     EXEC    xlock -nolock -mode random -modelist all3d -use3d -fullrandom
+       "Random ptr"    EXEC    xlock -nolock -mode random -modelist allmouse -trackmouse -fullrandom
+       "Random write"  EXEC    xlock -nolock -mode random -modelist allwrite -fullrandom
+"Special" END
+
+"ScreenSaver" END
+"Lock_Saver" END
diff --git a/xlockmore-4.14/etc/vtswitch.c b/xlockmore-4.14/etc/vtswitch.c
new file mode 100644 (file)
index 0000000..d740588
--- /dev/null
@@ -0,0 +1,122 @@
+/* Copyright (c) R. Cohen-Scali, 1998. */
+
+/*
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * <remi.cohenscali@pobox.com>
+ */
+
+
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <fcntl.h>
+#include <sys/ioctl.h>
+#include <linux/vt.h>
+
+#define CONSOLE "/dev/console"
+
+static char *progname = NULL;
+static char errmsg[1024]; 
+
+static void usage( int verb )
+{
+    fprintf( stderr, "%s: usage: %s [-h] <on/off>\n", progname, progname );
+    if ( verb )
+    {
+        fprintf( stderr, "    Allows to enable/disable to VT switching ability\n" ); 
+        fprintf( stderr, "      -- %s on -- enable VT switching\n", progname ); 
+        fprintf( stderr, "      -- %s off -- disable VT switching\n", progname );
+        fprintf( stderr, "    Option -h display this message\n" ); 
+    }
+    fprintf( stderr, "\n", progname, progname );
+}
+
+main( int argc, char **argv )
+{
+    char *cmd = argv[1];
+    int allow = 0, consfd = -1;
+    uid_t uid = -1;
+    struct stat consstat; 
+
+    /* Program name */
+    progname =( progname = strrchr( argv[0], '/' ) ) ? progname +1 : argv[0]; 
+
+    /* Check args */
+    if ( argc != 2 && argc != 3 )
+    {
+        usage( 0 );
+        exit( 1 );
+    }
+
+    /* Process -h */
+    if ( !strcmp( cmd, "-h" ) || !strcmp( cmd, "--help" ) )
+    {
+        usage( 1 );
+        cmd = argv[2]; 
+        if ( argc == 2 ) exit( 0 );
+    }
+
+    /* Process on/off (case insensitive) */
+    if ( strcasecmp( cmd, "on" ) && strcasecmp( cmd, "off" ) )
+    {
+        usage( 0 );
+        exit( 1 );
+    }
+    allow = !strcasecmp( cmd, "on" );
+
+    /* Check user is allowed to do it */
+    uid = getuid();
+    if ( stat( CONSOLE, &consstat ) == -1 )
+    {
+        sprintf( errmsg, "%s: Cannot stat " CONSOLE, progname ); 
+        perror( errmsg );
+        exit( 1 );
+    }
+    if ( uid != consstat.st_uid )
+    {
+        fprintf(stderr,
+                "%s: Sorry, you are not allowed to %slock"
+                " VT switching: Operation not permitted\n",
+                progname,
+                allow ? "un" : "" );
+        exit( 1 );
+    }
+    seteuid( 0 ); 
+
+    /* Open console */
+    if ( ( consfd = open( CONSOLE, O_RDWR ) ) == -1 )
+    {
+        sprintf( errmsg, "%s: Cannot open " CONSOLE, progname ); 
+        perror( errmsg );
+        seteuid( uid ); 
+        exit( 1 );
+    }
+
+    /* Do it */
+    if ( ioctl( consfd, allow?VT_UNLOCKSWITCH:VT_LOCKSWITCH ) == -1 )
+    {
+        sprintf( errmsg, "%s: Cannot %slock VT switching for " CONSOLE, progname, allow ? "un" : "" ); 
+        perror( errmsg );
+        seteuid( uid ); 
+        exit( 1 );
+    }
+
+    /* Terminate */
+    close( consfd );
+    fprintf( stdout, "VT switching %s\n", allow ? "enabled" : "disabled" ); 
+    seteuid( uid ); 
+    exit( 0 );
+}
diff --git a/xlockmore-4.14/etc/xlock.java b/xlockmore-4.14/etc/xlock.java
new file mode 100644 (file)
index 0000000..e28339c
--- /dev/null
@@ -0,0 +1,28 @@
+// charles vidal 28.08.97 <vidalc@club-internet.fr>
+// the main file , with the main class 
+// to compile javac xlock.java
+// to launch java xlock
+// in a browser you could show the GUI but , not launch the program
+
+import java.awt.*;
+import xlockFrame;
+
+class xlock extends java.applet.Applet
+{
+int isapp=0;
+public void init(){
+Frame theAppWindow = new Frame("FrameTest");
+xlockFrame theApplet = new xlockFrame();
+theApplet.init();
+theApplet.start();
+theAppWindow.add("Center",theApplet);
+theAppWindow.resize(350,400);
+theAppWindow.show();
+}
+public static  void main(String args[]) {
+xlock xpj = new xlock();
+xpj.init();
+xpj.start();
+}
+
+}
diff --git a/xlockmore-4.14/etc/xlock.sh b/xlockmore-4.14/etc/xlock.sh
new file mode 100755 (executable)
index 0000000..7ff3f10
--- /dev/null
@@ -0,0 +1,10 @@
+#!/bin/sh -
+# Wrapper script to get better performance
+#      by Tim Auckland <Tim.Auckland@Sun.COM>
+# It simply suspends all netscape and JAVA applications and resumes them
+# once xlock exits.  These applications poll when idle and that is quite
+# inconsiderate when you need all the cycles you can get for a good
+# screensaver.
+jobs=`ps -u $USER| awk '/jre/||/netscape/{print $1}'`
+[ -n "$jobs" ] && trap 'kill -CONT $jobs' 0 1 2 14 15 && kill -STOP $jobs
+/usr/local/bin/xlock "$@"
diff --git a/xlockmore-4.14/etc/xlock.staff b/xlockmore-4.14/etc/xlock.staff
new file mode 100644 (file)
index 0000000..ec59a91
--- /dev/null
@@ -0,0 +1,4 @@
+root
+wheel
+bagleyd
+david
diff --git a/xlockmore-4.14/etc/xlock.tcl b/xlockmore-4.14/etc/xlock.tcl
new file mode 100755 (executable)
index 0000000..d582779
--- /dev/null
@@ -0,0 +1,747 @@
+#!/usr/X11/bin/wish -f
+
+#charles vidal 1998 <vidalc@club-intenet.fr>
+# update Sun Oct 18 1998
+# Add the menu file with load resources 
+# and the exit button 
+# Add the load_process procedure loading 
+# the resource file ~/XLock 
+#
+
+#function find in demo: mkStyles.tcl
+# The procedure below inserts text into a given text widget and
+# applies one or more tags to that text.  The arguments are:
+#
+# w             Window in which to insert
+# text          Text to insert (it's inserted at the "insert" mark)
+# args          One or more tags to apply to text.  If this is empty
+#               then all tags are removed from the text.
+set bgcolor ""
+set fgcolor ""
+set ftname ""
+set mftname ""
+set usernom ""
+set passmot ""
+set XLock_validate ""
+set XLock_invalid ""
+set XLock_program ""
+set geometrie ""
+set icogeometrie ""
+set XLock_info ""
+set indxhelp ""
+set messagesfile ""
+set messagefile "" 
+set bitmap ""
+
+proc openfilesel { var  } {
+upvar $var toto
+set toto [ tk_getOpenFile -parent .]
+return toto
+}
+
+proc insertWithTags {w text args} {
+  set start [$w index insert]
+  $w insert insert $text
+  foreach tag [$w tag names $start] {
+    $w tag remove $tag $start insert
+  }
+  foreach i $args {
+    $w tag add $i $start insert
+  }
+}
+
+# Function for the help
+proc mkHelpCheck { w args } {
+  set nbf 0
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    $w insert insert  "\n"
+    checkbutton $w.c$nbf -variable [lindex $i 0] -text [lindex $i 0]
+    $w window create {end lineend} -window $w.c$nbf
+    $w insert insert  " [lindex $i 1] "
+  }
+}
+
+proc mkHelpEntry { w args } {
+  set nbf 0
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    insertWithTags  $w "\n [lindex $i 0] " underline
+    entry $w.e$nbf -textvariable [lindex $i 1]
+    $w window create {end lineend} -window $w.e$nbf
+    $w insert insert  "\n[lindex $i 2] "
+  }
+}
+
+#
+proc whichcolor { which } {
+  global fgcolor
+  global bgcolor
+  if {$which == "RESETFG"} {set fgcolor ""}
+  if {$which == "RESETBG"} {set bgcolor ""}
+  if ($tk_version>4) then {
+    if {$which== "FG" } {set fgcolor [tk_chooseColor -initialcolor $fgcolor -title "foreground color"];
+      puts $fgcolor
+    }
+  if {$which == "BG"} {set bgcolor [tk_chooseColor -initialcolor $bgcolor -title "background color"];
+      puts $bgcolor
+    }
+  } else
+  {
+    if {$which== "FG" } {set fgcolor [.color.frame.names get [.color.frame.names curselection]];}
+    if {$which == "BG"} {set bgcolor [.color.frame.names get [.color.frame.names curselection]];}
+  }
+}
+
+proc mkColor { what } {
+  if ($tk_version>4) then {
+    whichcolor $what; destroy .color
+  } else
+  {
+    toplevel .color
+    wm title .color "Color"
+    frame .color.frame -borderwidth 10
+    frame .color.frame2 -borderwidth 10
+    set w .color.frame
+    label $w.msg0   -text "Color Options"
+    pack $w.msg0 -side top
+    foreach i {/usr/local/lib/X11/rgb.txt /usr/lib/X11/rgb.txt
+        /X11/R5/lib/X11/rgb.txt /X11/R4/lib/rgb/rgb.txt} {
+      if ![file readable $i] {
+        continue;
+      }
+      set f [open $i]
+      listbox .color.frame.names -yscrollcommand ".color.frame.scroll set" \
+            -relief sunken -borderwidth 2 -exportselection false
+      bind .color.frame.names <Double-1> {
+            .color.test configure -bg [.color.frame.names get [.color.frame.names curselection]]
+      }
+      scrollbar .color.frame.scroll -orient vertical -command ".color.frame.names yview" \
+        -relief sunken -borderwidth 2
+      pack .color.frame.names  -side left
+      pack .color.frame.scroll -side right -fill both
+      pack .color.frame  -fill x
+      while {[gets $f line] >= 0} {
+        if {[llength $line] == 4} {
+          .color.frame.names insert end [lindex $line 3]
+        }
+      }
+      close $f
+      label  .color.test -height 5 -width 20
+      button .color.frame2.cancel -text Cancel -command "destroy .color"
+      button .color.frame2.ok -text OK -command "whichcolor $what; destroy .color"
+      button .color.frame2.reset -text Reset -command "whichcolor RESET$what; destroy .color"
+      pack  .color.test
+      pack .color.frame2.ok .color.frame2.cancel .color.frame2.reset -side left -fill x
+      pack .color.frame2 -fill both
+      break;
+    }
+  }
+}
+
+# moving in text by the list
+proc moveintext { indx } {
+upvar indxhelp t1
+ .help.f.t yview  [ lindex $t1 $indx ]
+
+}
+#----------------------
+# Help ...
+proc Helpxlock {} {
+  global indxhelp
+  toplevel .help
+  wm title .help "Help About Xlock"
+  frame .help.f
+  scrollbar .help.f.s -orient vertical -command {.help.f.t yview}
+  pack .help.f -expand yes -fill both
+  pack .help.f.s -side right -fill y -expand yes
+  text .help.f.t -yscrollcommand {.help.f.s set} -wrap word -width 60 -height 20 \
+    -setgrid 1
+
+  listbox .help.f.names -width 20 -height 20
+
+  bind .help.f.names <Double-1> {
+    set titi [eval .help.f.names curselection]
+    moveintext $titi
+  }
+
+  pack .help.f.names .help.f.t -expand y -fill both -side left
+  set w  .help.f.t
+  $w tag configure big -font -Adobe-Courier-Bold-R-Normal-*-140-*
+
+  foreach i {{"Xlock Help" { Locks the X server still the user enters their pass\
+word at the keyboard.  While xlock  is  running,  all  new\
+server  connections are refused.  The screen saver is dis\
+abled.  The mouse cursor is turned  off.   The  screen  is\
+blanked and a changing pattern is put on the screen.  If a\
+key or a mouse button is pressed then the user is prompted\
+for the password of the user who started xlock.
+If  the  correct  password  is  typed,  then the screen is\
+unlocked and the X server is restored.   When  typing  the\
+password  Control-U  and  Control-H are active as kill and\
+erase respectively.  To return to the locked screen, click\
+in the small icon version of the changing pattern.} 0 }
+    {"Options" {The option sets  the  X11  display  to  lock.\
+xlock  locks all available screens on a given server,\
+and restricts you to locking only a local server such\
+as  unix::00,,  localhost::00,,  or  ::00  unless you set the\
+     -remote option.} 0 }\
+    {"-name" {is used instead of XLock  when  looking for resources to configure xlock.} 1 }
+    {"-mode" {As  of  this  writing there are 80+ display modes supported (plus one more for random selection of one  of the 80+).} 1 }
+    {"-delay"  {It simply sets the number  of  microseconds to  delay
+between  batches  of animations.  In blank mode, it is important to set this to
+some small  number  of  microseconds,  because the keyboard and mouse are only checked after each delay, so you cannot set  the delay  too high, but a delay of
+zero would needlessly consume cpu checking for mouse and keyboard input  in a tight loop, since blank mode has no work to do.} 1 }
+    {"-saturation" {This option sets saturation  of  the  color ramp .  0 is grayscale and 1 is very rich color. 0.4 is a nice pastel.} 1 }
+    {"-username" {text string to use for Name prompt} 1 }\
+    {"-password" {text string to use for Password prompt} 1 }\
+    {"-info" {text string to use for instructions} 1 }\
+    {"-validate" {the message shown  while  validating  the password,
+defaults to \"Validating login...\"} 1 }\
+    {"-invalid" {the  message  shown  when  password  is invalid, defaults to \"Invalid login.\"} 1 }\
+    {"-geometry"  {This option sets the size and offset  of the  lock
+window  (normally the entire screen).  The entire screen format is still used for  entering  the password.   The  purpose  is  to  see the screen even though it is locked.  This should be used  with  caution since many of the modes will fail if the windows are far from square or are too small  (size  must  be greater
+than  0x0).   This  should also be used with esaver to protect screen from phosphor burn.} 1 }\
+    {"-icongeometry" {this option sets  the  size  of  the iconic screen (normally 64x64) seen when entering the password.  This should be  used  with  caution  since many  of  the  modes will fail if the windows are far from square
+or are too small (size  must  be  greater than  0x0).   The  greatest  size  is
+256x256.  There should be some limit  so  users  could  see  who  has locked  the  screen.  Position information of icon is ignored.} 1 }
+    {"-font" { Ths option  sets  the  font  to be used on the prompt screen.} 1 }
+    { "-fg "  { This option sets the color of the text on the password screen.} 1 }
+    {"-bg" { This option sets the color of the background on the password screen.} 1 }
+    {"-forceLogout" { This option sets the  auto-logout.  This  might not be enforced depending how your system is configured.} 1 }} {
+    lappend indxhelp [$w index current]
+    if {  [lindex $i 2] == 1 } then {.help.f.names insert end "    [lindex $i 0]"} else {.help.f.names insert end " [lindex $i 0]"}
+    insertWithTags  $w "[lindex $i 0] " big
+    $w insert end "\n"
+    $w insert end [lindex $i 1]
+    $w insert end "\n"
+  }
+  lappend indxhelp [$w index current]
+  insertWithTags  $w "Options boolean" big
+   $w insert end "\n"
+  .help.f.names insert end "Options boolean"
+  mkHelpCheck $w {XLock_mono {turn on/off monochrome override}}\
+                {nolock {trun on/off no password required mode}}\
+                {remote {turn on/off remote host access}}\
+                {allowroot {turn on/off allow root password mode (ignored)}}\
+                {enablesaver {turn on/off enable X server screen saver}}\
+                {allowaccess {turn on/off access of the terminal X}}\
+                {grabmouse {turn on/off grabbing of mouse and keyboard}}\
+                {echokeys {turn on/off echo \'?\' for each password key}}\
+                {usefirst {turn on/off using the first char typed in password}}\
+                {verbose {turn on/off verbose mode}}\
+                {inwindow {turn on/off making xlock run in a window}}\
+                {inroot {turn on/off making xlock run in the root window}}\
+                {timeelapsed {turn on/off clock}}\
+                {install {whether to use private colormap if needed (yes/no)}}\
+                {sound {whether to use sound if configured for it (yes/no}}
+        button .help.ok -text OK -command "destroy .help"
+  pack  .help.ok
+}
+
+# Create toplevel Author and Maintener.
+proc mkAuthor {} {
+  toplevel .author
+  wm title .author "Author and Maintener of xlock"
+  frame .author.frame -borderwidth 10
+  set w .author.frame
+
+  label $w.msg0   -text "Author and Maintener of xlock"
+  label $w.msg1   -text "Maintained by: David A. Bagley (bagleyd@tux.org)"
+  label $w.msg2   -text "Original Author: Patrick J. Naughton (naughton@eng.sun.com)"
+  label $w.msg3   -text "Mailstop 21-14 Sun Microsystems Laboratories,"
+  label $w.msg4   -text "Inc.  Mountain View, CA  94043 15//336-1080"
+  label $w.msg5   -text "with many additional contributors"
+  pack $w.msg0 $w.msg1 $w.msg2 $w.msg3 $w.msg4 $w.msg5 -side top
+
+  label $w.msg6   -text "xlock.tcl\n created by charles VIDAL\n (author of flag mode and xmlock launcher )"
+  pack $w.msg6 -side top
+
+  button .author.ok -text OK -command "destroy .author"
+  pack $w .author.ok
+}
+
+proc mkFileDialog { nom titre args }  {
+  toplevel .$nom
+  wm title .$nom "$titre"
+  frame .$nom.frame -borderwidth 10
+  frame .$nom.frame2 -borderwidth 10
+  frame .$nom.frame.frame4 -borderwidth 10
+  set w .$nom.frame
+  set w2 .$nom.frame2
+  set w4 .$nom.frame.frame4
+  set nbf 0
+
+  label $w.msg0   -text "$titre"
+  pack $w.msg0 -side top
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    frame $w4.f$nbf 
+    label $w4.f$nbf.l$nbf -text [lindex $i 0]
+    entry $w4.f$nbf.e$nbf -textvariable [lindex $i 1]
+    button $w4.f$nbf.b$nbf -text "..." -command "openfilesel [lindex $i 1]"
+    pack $w4.f$nbf.l$nbf $w4.f$nbf.e$nbf $w4.f$nbf.b$nbf  -side left -expand yes
+    pack $w4.f$nbf -expand yes
+  }
+  button $w2.ok -text OK -command "destroy .$nom"
+  button $w2.cancel -text Cancel -command "destroy .$nom"
+  pack $w -side top -expand yes
+  pack $w4 -side right -expand yes
+  pack $w2.ok $w2.cancel -side left -fill x -expand yes
+  pack $w2  -side bottom -expand yes
+}
+
+proc mkDialog { nom titre args } {
+  toplevel .$nom
+  wm title .$nom "$titre"
+  frame .$nom.frame -borderwidth 10
+  frame .$nom.frame2 -borderwidth 10
+  frame .$nom.frame.frame3 -borderwidth 10
+  frame .$nom.frame.frame4 -borderwidth 10
+  set w .$nom.frame
+  set w2 .$nom.frame2
+  set w3 .$nom.frame.frame3
+  set w4 .$nom.frame.frame4
+  set nbf 0
+
+  label $w.msg0   -text "$titre"
+  pack $w.msg0 -side top
+  foreach i $args {
+    set nbf [ expr $nbf +1 ]
+    label $w3.l$nbf -text [lindex $i 0]
+    entry $w4.e$nbf -textvariable [lindex $i 1]
+    pack $w3.l$nbf
+    pack $w4.e$nbf
+  }
+  button $w2.ok -text OK -command "destroy .$nom"
+  button $w2.cancel -text Cancel -command "destroy .$nom"
+  pack $w -side top
+  pack $w3 -side left
+  pack $w4 -side right
+  pack $w2.ok $w2.cancel -side left -fill x
+  pack $w2  -side bottom
+}
+
+proc mkMessage {} {
+  global passmot
+  global XLock_validate
+  global XLock_invalid
+  global XLock_info
+  mkDialog message {Message Options} \
+  {"message password" passmot} \
+  {"validate string" XLock_validate} \
+  {"invalid string" XLock_invalid} \
+  {"info string" XLock_info}
+}
+
+proc mkGeometry {} {
+  global geometrie
+  global icogeometrie
+  mkDialog geometry {Geometry Options} \
+  {"geometry" geometrie} \
+  {"icon geometry" icogeometrie}
+}
+
+proc mkFileOption {} {
+  global messagesfile
+  global messagefile
+  global bitmap
+  mkFileDialog fileoption {Files Options} \
+  {"messagesfile" messagesfile} \
+  {"messagefile" messagefile} \
+  {"bitmap" bitmap} 
+}
+
+proc whichfont { which } {
+  global ftname
+  global mftname
+ if {$which== "FONT" } {set ftname [.font.frame.names get [.font.frame.names curselection]];}
+ if {$which == "MFONT"} {set mftname [.font.frame.names get [.font.frame.names curselection]];}
+ if {$which == "RESETFONT"} {set ftname ""}
+ if {$which == "RESETMFONT"} {set mftname ""}
+}
+
+#this function should be erase in the newer version...
+proc mkFont { What } {
+  toplevel .font
+  wm title .font "Font Options"
+  label  .font.label -text "ABCDEFGH\nIJKabedfg\nhijkmnopq"
+  frame .font.frame -borderwidth 10
+  frame .font.frame2 -borderwidth 10
+  set w .font.frame
+  label $w.msg0   -text "Font Options"
+  pack $w.msg0 -side top
+  eval exec "xlsfonts \> /tmp/xlsfont.tmp"
+  set f [open "/tmp/xlsfont.tmp"]
+  listbox .font.frame.names -yscrollcommand ".font.frame.scroll set" \
+    -xscrollcommand ".font.scroll2 set"  -setgrid 1 \
+    -exportselection false
+  bind .font.frame.names <Double-1> {
+   .font.test configure -font [.font.frame.names get [.font.frame.names curselection]]
+  }
+  scrollbar .font.frame.scroll -orient vertical -command ".font.frame.names yview" \
+    -relief sunken -borderwidth 2
+  scrollbar .font.scroll2 -orient horizontal -command ".font.frame.names xview" \
+    -relief sunken -borderwidth 2
+  while {[gets $f line] >= 0} {
+    .font.frame.names insert end $line
+  }
+  close $f
+
+  eval exec "/bin/rm -f /tmp/xlsfont.tmp"
+  pack .font.frame.names  -side left -expand y -fill both
+  pack .font.frame.scroll -side right -fill both
+  pack .font.frame  -fill x
+  pack .font.scroll2 -fill both
+  label  .font.test -text "ABCDEFGHIJKabedfghijkmnopq12345"
+  pack .font.test
+
+  button .font.frame2.cancel -text Cancel -command "destroy .font"
+  button .font.frame2.reset -text Reset -command "whichfont RESET$What;destroy .font"
+  button .font.frame2.ok -text OK -command "whichfont $What;destroy .font"
+  pack .font.frame2.ok .font.frame2.cancel .font.frame2.reset -side left -fill both
+  pack .font.frame2 -fill both
+
+  #frame $w.fontname
+  #label $w.fontname.l1 -text "font name"
+  #entry $w.fontname.e1 -relief sunken
+  #frame $w.specfont
+  #label $w.specfont.l2 -text "specifique font name"
+  #entry $w.specfont.e2 -relief sunken
+  #pack $w.fontname $w.specfont
+  #pack $w.fontname.l1 -side left
+  #pack $w.specfont.l2 -side left
+  #pack $w.fontname.e1 $w.specfont.e2  -side top -pady 5 -fill x
+  #button .font.frame2.ok -text OK -command "destroy .font"
+  #button .font.frame2.cancel -text Cancel -command "destroy .font"
+  #pack $w .font.frame2.ok .font.frame2.cancel -side left -fill x
+  #pack .font.frame2 -side bottom
+}
+
+proc mkEntry {} {
+  global usernom
+  global XLock_program
+  mkDialog option {User Options} \
+  {"user name" usernom} \
+  {"program name" XLock_program}
+}
+
+proc Affopts { device } {
+
+#options booleans
+  global XLock_mono
+  global nolock
+  global remote
+  global allowroot
+  global enablesaver
+  global allowaccess
+  global grabmouse
+  global echokeys
+  global usefirst
+  global install
+  global sound
+
+  global fgcolor
+  global bgcolor
+  global ftname
+  global mftname
+
+  global usernom
+  global passmot
+  global XLock_validate
+  global XLock_invalid
+  global XLock_program
+  global geometrie
+  global icogeometrie
+  global XLock_info
+  global messagesfile 
+  global messagefile  
+  global bitmap 
+
+  set linecommand "xlock "
+
+  if {$device == 1} {append linecommand "-inwindow "} elseif {$device == 2} {append linecommand "-inroot "}
+  if {$bgcolor!=""} {append linecommand "-bg $bgcolor "}
+  if {$fgcolor!=""} {append linecommand "-fg $fgcolor "}
+  if {$ftname!=""} {append linecommand "-font $ftname "}
+  if {$mftname!=""} {append linecommand "-messagefont $mftname "}
+#entry action
+  if {$usernom!=""} {append linecommand "-username $usernom "}
+  if {$passmot!=""} {append linecommand "-password $passmot "}
+  if {$XLock_validate!=""} {append linecommand "-validate $XLock_validate "}
+  if {$XLock_invalid!=""} {append linecommand "-invalid $XLock_invalid "}
+  if {$XLock_program!=""} {append linecommand "-program $XLock_program "}
+  if {$geometrie!=""} {append linecommand "-geometry $geometrie "}
+  if {$icogeometrie!=""} {append linecommand "-icongeometry $icogeometrie "}
+  if {$messagesfile!=""} {append linecommand "-messagesfile $messagesfile "}
+  if {$bitmap!=""} {append linecommand "-bitmap $bitmap "}
+  if {$icogeometrie!=""} {append linecommand "-icongeometry $icogeometrie "}
+  if {$XLock_info!=""} {append linecommand "-info $XLock_info "}
+#check actions
+  if { $XLock_mono == 1 } {append linecommand "-mono "}
+  if { $install == 1 } {append linecommand "+install "}
+  if { $sound == 1 } {append linecommand "+sound "}
+  if { $nolock == 1 } {append linecommand "-nolock "}
+  if { $remote == 1 } {append linecommand "-remote "}
+  if { $allowroot == 1 } {append linecommand "-allowroot "}
+  if { $enablesaver == 1 } {append linecommand "-enablesaver "}
+  if { $allowaccess == 1 } {append linecommand "-allowaccess "}
+  if { $grabmouse == 1 } {append linecommand "-grabmouse "}
+  if { $echokeys == 1 } {append linecommand "-echokeys "}
+  if { $usefirst == 1 } {append linecommand "-usefirst "}
+  append linecommand "-mode "
+  append linecommand [.listscrol.list get [eval .listscrol.list curselection]]
+  puts $linecommand
+  eval exec $linecommand
+}
+
+proc load_ressource { } {
+  global XLock_invalid
+  global XLock_validate
+  global XLock_info
+  global XLock_program
+
+set filename ""
+
+openfilesel filename
+
+set f [ open $filename r ]
+while { ! [eof $f ] } {
+       gets $f line
+               switch -regexp $line {
+       {^XLock\.[a-zA-Z]+:} {
+               if { [ regexp -nocase {\: $} tyty ]} {
+               }
+       regsub {^} $line "set " line2
+       regsub {XLock\.} $line2 "XLock_" line3
+       regsub {: } $line3 " \"" line4
+       regsub {on$} $line4 "1" line5
+       regsub {off$} $line4 "0" line5
+       eval "$line5\""
+       }
+       {^XLock\.[a-zA-Z]+\.[a-zA-Z]+:[ \t]*[a-zA-Z0-9]+$} {
+       regsub {^} $line "set " line2
+       regsub {XLock\.} $line2 "XLock_" line3
+       regsub {\.} $line3 "(" line4
+       regsub {: } $line4 ") \"" line5
+       eval "$line5\""
+       }
+}
+}
+}
+
+# Creation of GUI
+
+wm title . "xlock launcher"
+. configure -cursor top_left_arrow
+frame .menu -relief raised -borderwidth 1
+menubutton .menu.button -text "switches" -menu .menu.button.check
+pack .menu -side top -fill x
+
+global XLock_mono
+global sound
+global install
+global nolock
+global remote
+global allowroot
+global enablesaver
+global allowaccess
+global grabmouses
+global echokeys
+global usefirst
+
+global usernom
+global passmot
+global geometrie
+global icogeometrie
+global XLock_info
+
+# Creation of GUI
+
+#Creation of  menu
+set fileressource ""
+
+menubutton .menu.buttonf -text "file" -menu .menu.buttonf.file
+menu .menu.buttonf.file
+set FILE .menu.buttonf.file
+$FILE add command -label "Load ressource" -command "load_ressource"
+$FILE add command -label "exit" -command "exit"
+
+menu .menu.button.check
+set CHECK .menu.button.check
+
+#menu with les check buttons
+$CHECK add check -label "mono" -variable XLock_mono
+$CHECK add check -label "nolock" -variable nolock
+$CHECK add check -label "remote" -variable remote
+$CHECK add check -label "allowroot" -variable allowroot
+$CHECK add check -label "enablesaver" -variable enablesaver
+$CHECK add check -label "allowaccess" -variable allowaccess
+$CHECK add check -label "grabmouse" -variable grabmouse
+$CHECK add check -label "echokeys" -variable echokeys
+$CHECK add check -label "usefirst" -variable usefirst
+$CHECK add check -label "install" -variable install
+$CHECK add check -label "sound" -variable sound
+
+menubutton .menu.button2 -text "options" -menu .menu.button2.options
+menu .menu.button2.options
+set OPTIONS .menu.button2.options
+#les options
+$OPTIONS add command -label "generals options" -command "mkEntry"
+$OPTIONS add command -label "font to use for password prompt" -command "mkFont FONT"
+$OPTIONS add command -label "font for a specific mode" -command "mkFont MFONT"
+
+
+$OPTIONS add command -label "geometry options" -command "mkGeometry"
+$OPTIONS add command -label "file options" -command "mkFileOption"
+$OPTIONS add command -label "message options" -command "mkMessage"
+
+#Color
+menubutton .menu.button4 -text "color" -menu .menu.button4.color
+menu .menu.button4.color
+set COLOR .menu.button4.color
+#if {$tk_version < 4} then {
+#$COLOR add command -label "foreground options for password" -command "mkColor FG"
+#$COLOR add command -label "background options for password" -command "mkColor BG"
+#}
+#else {
+$COLOR add command -label "foreground options for password" -command "tk_chooseColor"
+$COLOR add command -label "background options for password" -command "tk_chooseColor"
+#}
+menubutton .menu.button3 -text "help" -menu .menu.button3.help
+menu .menu.button3.help
+set HELP .menu.button3.help
+$HELP add command -label "about xlock" -command "Helpxlock"
+$HELP add command -label "about author" -command "mkAuthor"
+
+pack .menu.buttonf .menu.button  .menu.button2 .menu.button4 -side left
+pack .menu.button3 -side right
+
+#---------------------------
+#creation de la liste
+#---------------------------
+frame .listscrol -borderwidth 4 -relief ridge
+set LISTSCROL .listscrol
+scrollbar $LISTSCROL.scroll -relief sunken -command "$LISTSCROL.list yview"
+listbox $LISTSCROL.list -yscroll  "$LISTSCROL.scroll set"
+
+#---------------------------
+#insert all modes in list
+#---------------------------
+$LISTSCROL.list  insert 0 \
+ant\
+atlantis\
+ball\
+bat\
+blot\
+bouboule\
+bounce\
+braid\
+bubble\
+bubble3d\
+bug\
+cage\
+cartoon\
+clock\
+coral\
+crystal\
+daisy\
+dclock\
+decay\
+deco\
+demon\
+dilemma\
+discrete\
+drift\
+eyes\
+fadeplot\
+flag\
+flame\
+flow\
+forest\
+galaxy\
+gears\
+goop\
+grav\
+helix\
+hop\
+hyper\
+ico\
+ifs\
+image\
+invert\
+julia\
+kaleid\
+kumppa\
+lament\
+laser\
+life\
+life1d\
+life3d\
+lightning\
+lisa\
+lissie\
+loop\
+lyapunov\
+mandelbrot\
+marquee\
+matrix\
+maze\
+moebius\
+morph3d\
+mountain\
+munch\
+nose\
+pacman\
+penrose\
+petal\
+pipes\
+puzzle\
+pyro\
+qix\
+roll\
+rotor\
+rubik\
+shape\
+sierpinski\
+slip\
+sphere\
+spiral\
+spline\
+sproingies\
+stairs\
+star\
+starfish\
+strange\
+superquadrics\
+swarm\
+swirl\
+tetris\
+thornbird\
+triangle\
+tube\
+turtle\
+vines\
+voters\
+wator\
+wire\
+world\
+worm\
+xjack\
+blank
+
+
+pack $LISTSCROL.scroll -side right -fill y
+pack $LISTSCROL.list -side left -expand yes -fill both
+pack $LISTSCROL  -fill both -expand yes
+
+frame .buttons -borderwidth 4 -relief ridge
+set BUTTON .buttons
+button $BUTTON.launch -text "Launch"  -command "Affopts 0"
+button $BUTTON.launchinW -text "Launch in Window" -command "Affopts 1"
+button $BUTTON.launchinR -text "Launch in Root" -command "Affopts 2"
+button $BUTTON.quit -text Quit -command "exit"
+pack  $BUTTON.launch $BUTTON.launchinW $BUTTON.launchinR -side left
+pack $BUTTON.quit -side right
+pack $BUTTON -fill x -side bottom
+
diff --git a/xlockmore-4.14/etc/xlockFrame.java b/xlockmore-4.14/etc/xlockFrame.java
new file mode 100644 (file)
index 0000000..a45a4ef
--- /dev/null
@@ -0,0 +1,292 @@
+// charles vidal <vidalc@club-internet.fr>
+// the GUI definition and the handler event
+import java.applet.*;
+import java.awt.*;
+import java.lang.Runtime;
+
+public class xlockFrame extends Applet {
+
+public static final int nbcoption=9;
+public static final int nbbooleanopt=14;
+Button blaunch;
+Button blaunchinw;
+Button bquit;
+Choice coptions;
+TextField foroptions; 
+ List lst ;
+int    currentOption=0;
+
+MyFrameError mfe;
+
+boolean isinapp=false;
+
+// Array of option name 
+String[] nomOption={"Name program",
+"File",
+"Message Password",
+"Message Valid",
+"Message Invalid",
+"Prompt",
+"Fonts",
+"Geometry","Display"};
+
+String[] valueOption={"","","","","","","","",""};
+String[] cmdlineOption={"-program","-messagefile","-password","-validate","-invalid","","-font","-geometry","-display"};
+
+// Array of option boolean name 
+String[] booleanOption={ 
+"-mono ",
+"-nolock ",
+"-remote ",
+"-allowroot ",
+"-enablesaver ",
+"-allowaccess ",
+"-grabmouse ",
+"-echokeys ",
+"-usefirst ",
+"-verbose ",
+"-inroot ",
+"-timeelapsed ",
+"-install ",
+"-use3d "};
+Checkbox bopt[]=new Checkbox[15];
+ public void init()
+        {
+ Frame theAppWindow = new Frame("xlockFrame");
+ Panel Panel1 = new Panel();
+ Panel Panel2 = new Panel();
+ Panel Panel3 = new Panel();
+ setLayout(new BorderLayout(10,10));
+
+ lst = new List();
+
+coptions=new Choice();
+for (int i=0;i<nbcoption;i++)
+       coptions.addItem(nomOption[i]);
+
+Panel3.add(coptions);
+
+foroptions = new TextField(20);
+Panel3.add(foroptions);
+
+add("North", Panel3);
+
+add("Center",lst);
+lst.addItem("ant");
+lst.addItem("atlantis");
+lst.addItem("ball");
+lst.addItem("bat");
+lst.addItem("blot");
+lst.addItem("bouboule");
+lst.addItem("bounce");
+lst.addItem("braid");
+lst.addItem("bubble");
+lst.addItem("bubble3d");
+lst.addItem("bug");
+lst.addItem("cage");
+lst.addItem("cartoon");
+lst.addItem("clock");
+lst.addItem("coral");
+lst.addItem("crystal");
+lst.addItem("daisy");
+lst.addItem("dclock");
+lst.addItem("decay");
+lst.addItem("deco");
+lst.addItem("demon");
+lst.addItem("dilemma");
+lst.addItem("discrete");
+lst.addItem("drift");
+lst.addItem("eyes");
+lst.addItem("fadeplot");
+lst.addItem("flag");
+lst.addItem("flame");
+lst.addItem("flow");
+lst.addItem("forest");
+lst.addItem("galaxy");
+lst.addItem("gears");
+lst.addItem("goop");
+lst.addItem("grav");
+lst.addItem("helix");
+lst.addItem("hop");
+lst.addItem("hyper");
+lst.addItem("ico");
+lst.addItem("ifs");
+lst.addItem("image");
+lst.addItem("invert");
+lst.addItem("julia");
+lst.addItem("kaleid");
+lst.addItem("kumppa");
+lst.addItem("lament");
+lst.addItem("laser");
+lst.addItem("life");
+lst.addItem("life1d");
+lst.addItem("life3d");
+lst.addItem("lisa");
+lst.addItem("lissie");
+lst.addItem("loop");
+lst.addItem("lyapunov");
+lst.addItem("mandelbrot");
+lst.addItem("marquee");
+lst.addItem("matrix");
+lst.addItem("maze");
+lst.addItem("moebius");
+lst.addItem("morph3d");
+lst.addItem("mountain");
+lst.addItem("munch");
+lst.addItem("nose");
+lst.addItem("pacman");
+lst.addItem("penrose");
+lst.addItem("petal");
+lst.addItem("pipes");
+lst.addItem("puzzle");
+lst.addItem("pyro");
+lst.addItem("qix");
+lst.addItem("roll");
+lst.addItem("rotor");
+lst.addItem("rubik");
+lst.addItem("shape");
+lst.addItem("sierpinski");
+lst.addItem("slip");
+lst.addItem("sphere");
+lst.addItem("spiral");
+lst.addItem("spline");
+lst.addItem("sproingies");
+lst.addItem("stairs");
+lst.addItem("star");
+lst.addItem("starfish");
+lst.addItem("strange");
+lst.addItem("superquadrics");
+lst.addItem("swarm");
+lst.addItem("swirl");
+lst.addItem("tetris");
+lst.addItem("thornbird");
+lst.addItem("triangle");
+lst.addItem("tube");
+lst.addItem("turtle");
+lst.addItem("vines");
+lst.addItem("voters");
+lst.addItem("wator");
+lst.addItem("wire");
+lst.addItem("world");
+lst.addItem("xjack");
+lst.addItem("worm");
+lst.addItem("blank");
+lst.addItem("bomb");
+lst.addItem("random");
+lst.select(0);
+
+add("East", Panel1);
+Panel1.setLayout(new GridLayout(15,1));
+for (int i=0;i<nbbooleanopt;i++)
+       { bopt[i]=new Checkbox(booleanOption[i],null,false);
+       Panel1.add(bopt[i]);
+       }
+
+add("South", Panel2);
+blaunch=new Button("Launch");
+blaunchinw=new Button("Launch in window");
+bquit=new Button("Quit");
+Panel2.add(blaunch);
+Panel2.add(blaunchinw);
+Panel2.add(bquit);
+}
+public String getBooleanOption()
+{
+String result="";
+for (int i=0;i<nbbooleanopt;i++)
+       {if (bopt[i].getState()) result=result.concat(booleanOption[i]);
+       }
+       return (result);
+}
+public boolean action (Event evt, Object arg)
+{
+
+Runtime r=Runtime.getRuntime();
+
+
+if (isinapp)
+       mfe=new MyFrameError("An error occured , You can't launch xlock");
+       else
+       mfe=new MyFrameError("An error occured , You can't launch xlock");
+       //mfe=new MyFrameError("You can't launch by a Browser");
+
+mfe.resize(350,150);
+
+if (evt.target == blaunch || evt.target == blaunchinw)
+       {
+       String label= (String) arg;
+       String cmdlinexlock="xlock ";
+       if (evt.target == blaunchinw ) cmdlinexlock=cmdlinexlock.concat("-inwindow ");
+       for (int i=0;i<nbcoption;i++)
+               {
+               if (!valueOption[i].equals("")) 
+                       {
+                       cmdlinexlock=cmdlinexlock.concat(cmdlineOption[i]+" "+valueOption[i]+" "); 
+                       }
+               }
+       cmdlinexlock=cmdlinexlock.concat(getBooleanOption());
+       cmdlinexlock=cmdlinexlock.concat(" -mode ");
+       cmdlinexlock=cmdlinexlock.concat(lst.getSelectedItem());
+       try {
+  System.out.println(cmdlinexlock);
+       r.getRuntime().exec(cmdlinexlock); } 
+                       catch ( Exception e )
+                               {mfe.show();}
+       return true;}
+else
+       if (evt.target == coptions)
+       {
+       String label= (String) arg;
+       valueOption[currentOption]=foroptions.getText();
+       for (int i=0;i<nbcoption;i++)
+               {
+               if (nomOption[i].equals(label)) 
+                       {foroptions.setText(valueOption[i]);
+                       currentOption=i;
+                       }
+               }
+       }
+else 
+       if (evt.target == bquit) {System.exit(0);}
+       else if (evt.target instanceof Checkbox)
+       {
+       return true;
+       }
+else
+       if (evt.target == foroptions)
+       {
+       String label= (String) arg;
+       valueOption[currentOption]=label;
+       return true;    
+       }
+       return false;
+  }
+
+public void SetInAppl()
+{
+isinapp=true;
+}
+
+}
+class MyFrameError extends Frame {
+Label l;
+Button b_ok;
+MyFrameError (String erreur) {
+       
+       setLayout(new BorderLayout());
+       l=new Label(erreur,Label.CENTER);
+       add("Center",l);
+       b_ok=new Button("Ok");
+       add("South",b_ok);
+       setTitle(erreur);
+       setCursor(HAND_CURSOR);
+       }
+public boolean action (Event evt,Object arj){
+       if (evt.target instanceof Button)
+               {
+               this.hide();
+               return (true);
+               }
+               return (false);
+}
+}
diff --git a/xlockmore-4.14/etc/xlockhexlife.pl b/xlockmore-4.14/etc/xlockhexlife.pl
new file mode 100755 (executable)
index 0000000..7f400b1
--- /dev/null
@@ -0,0 +1,81 @@
+#!/usr/bin/perl
+# This is used  to add life to life
+# This is a QUICK hack to convert life files to xlock's life format.
+# Patterns MUST have <= 64 pts at start for life.c to use the data generated
+# Below is an example of a life file without the first initial #'s
+# Call the file glider.hlife and run it like xlockhexlife.pl < glider.hlife
+#glider.hlife
+##P -2 -2   Treated as a comment, program finds own center
+#       . . O .
+#      . . . O
+#     O . . O
+#    . . . O
+#   . . . O
+
+print "
+Drop these points in life.c, within the 'patterns' array.
+Note if the number of points > 64, one must increase points NUMPTS;
+also to fit most screens and especially the iconified window,
+one should have the size < 32x32.\n\n";
+&search;
+print "\npoints = $PTS; size = ${X}x$Y\n";
+
+sub search {
+    local ($row, $col, $firstrow, $firstcol);
+    local ($i, $j, $found, $c, $tempx, $tempy);
+    local (@array);
+  
+
+    $row = $col = 0;
+    $firstrow = -1;
+    $firstcol = 80;
+    $PTS = $X = $Y = 0;
+    while (<>) {
+         if (!($_ =~ /^#/))
+         {
+            @chars = split(//);
+            $col = 0;
+            foreach $c (@chars) {
+                if ($c =~ /[\*0O]/) {
+                       $col++;
+                    if ($firstrow < 0) {
+                        $row = $firstrow = 1;
+                    }
+                    if ($col < $firstcol) {
+                        $firstcol = $col;
+                    }
+                    if ($row > $Y) {
+                        $Y = $row;
+                    }
+                    if ($col > $X) {
+                        $X = $col;
+                    }
+                    $array{$col, $row} = 1;
+                    $PTS++;
+                } elsif ($c =~ /[\.]/) {
+                       $col++;
+                       }
+            }
+            $row++;
+        }
+    }
+    $col = $X - $firstcol + 1;
+    $row = $Y;
+    print "    {\n        ";
+    for ($j = 0; $j <= $Y; $j++) {
+        $found = 0;
+        for ($i = 0; $i <= $X; $i++) {
+            if ($array{$i, $j}) {
+                $found = 1;
+                $tempx = $i - int(($col + 2) / 2) - $firstcol + 1;
+                $tempy = $j - int(($row + 2) / 2);
+                printf "$tempx, $tempy, ";
+            }
+        }
+        if ($found) {
+            print "\n        ";
+        }
+  }
+  print "127\n    },\n";
+  $X = $col;
+}
diff --git a/xlockmore-4.14/etc/xlocklife.pl b/xlockmore-4.14/etc/xlocklife.pl
new file mode 100755 (executable)
index 0000000..2f46b3d
--- /dev/null
@@ -0,0 +1,81 @@
+#!/usr/bin/perl
+# This is used  to add life to life
+# This is a QUICK hack to convert life files to xlock's life format.
+# Patterns MUST have <= 64 pts at start for life.c to use the data generated
+# Below is an example of a life file without the first initial #'s
+# Call the file piston.life and run it like xlocklife.pl < piston.life
+#piston.life
+##P -10 -3  Treated as a comment, program finds own center
+#..........*...........
+#..........****........
+#**.........****.......
+#**.........*..*.....**
+#...........****.....**
+#..........****........
+#..........*...........
+
+print "
+Drop these points in life.c, within the 'patterns' array.
+Note if the number of points > 64, one must increase points NUMPTS;
+also to fit most screens and especially the iconified window,
+one should have the size < 32x32.\n\n";
+&search;
+print "\npoints = $PTS; size = ${X}x$Y\n";
+
+sub search {
+    local ($row, $col, $firstrow, $firstcol);
+    local ($i, $j, $found, $c, $tempx, $tempy);
+    local (@array);
+  
+
+    $row = $col = 0;
+    $firstrow = -1;
+    $firstcol = 80;
+    $PTS = $X = $Y = 0;
+    while (<>) {
+         if (!($_ =~ /^#/))
+         {
+            @chars = split(//);
+            $col = 0;
+            foreach $c (@chars) {
+                $col++;
+                if ($c =~ /[\*0O]/) {
+                    if ($firstrow < 0) {
+                        $row = $firstrow = 1;
+                    }
+                    if ($col < $firstcol) {
+                        $firstcol = $col;
+                    }
+                    if ($row > $Y) {
+                        $Y = $row;
+                    }
+                    if ($col > $X) {
+                        $X = $col;
+                    }
+                    $array{$col, $row} = 1;
+                    $PTS++;
+                }
+            }
+            $row++;
+        }
+    }
+    $col = $X - $firstcol + 1;
+    $row = $Y;
+    print "    {\n             ";
+    for ($j = 0; $j <= $Y; $j++) {
+        $found = 0;
+        for ($i = 0; $i <= $X; $i++) {
+            if ($array{$i, $j}) {
+                $found = 1;
+                $tempx = $i - int(($col + 2) / 2) - $firstcol + 1;
+                $tempy = $j - int(($row + 2) / 2);
+                printf "$tempx, $tempy, ";
+            }
+        }
+        if ($found) {
+            print "\n          ";
+        }
+  }
+  print "127\n },\n";
+  $X = $col;
+}
diff --git a/xlockmore-4.14/etc/xlockranddur.pl b/xlockmore-4.14/etc/xlockranddur.pl
new file mode 100755 (executable)
index 0000000..dea1046
--- /dev/null
@@ -0,0 +1,6 @@
+#!/usr/bin/perl
+# xarand
+    open(S,"/usr/games/fortune|wc|");
+    @numbers = split(" ",<S>);
+    print int $numbers[2]/3;  
+
diff --git a/xlockmore-4.14/etc/xlockrandimage.pl b/xlockmore-4.14/etc/xlockrandimage.pl
new file mode 100755 (executable)
index 0000000..1b185d9
--- /dev/null
@@ -0,0 +1,28 @@
+#!/usr/bin/perl
+# This is used if the RANDIMAGEFILE switch does not work so instead of:
+# xlock -imagefile [ DIRECTORY | FILE ] [other xlock options]
+# try
+# randimagefile.pl [DIRECTORY | FILE] [other xlock options]
+# By the way the typical other xlock options that would be used here are
+# -mode [image | puzzle] -install
+
+$file = shift(@ARGV);
+if ($file eq "") {
+    print "\nUsage: $0 [DIRECTORY | FILE] [other xlock options]\n";
+    print "\tother xlock options typically are: -mode [image | puzzle] -install\n";
+    exit 1;
+}
+
+getrandfile();
+#printf "xlock -imagefile $file @ARGV\n";
+system "xlock -imagefile $file @ARGV";
+
+sub getrandfile {
+  if (-d $file) { # OK so its not really a file :)
+    opendir(DIR, $file) || die "Can not open $file";
+    local(@filenames) = grep(!/^\.\.?$/, readdir(DIR)); # ls but avoid . && ..
+    closedir(DIR);
+    srand(time); # use time|$$ if security involved
+    $file = splice(@filenames, rand @filenames, 1); # pick one
+  }
+}
diff --git a/xlockmore-4.14/etc/xlocksat.pl b/xlockmore-4.14/etc/xlocksat.pl
new file mode 100755 (executable)
index 0000000..6a285dd
--- /dev/null
@@ -0,0 +1,6 @@
+#!/usr/bin/perl 
+# xlocksat
+$h = `/bin/date "+%H:"`;
+$sat = (12 - abs($h - 12)) / 12 ;
+printf("%.2f\n",$sat);
diff --git a/xlockmore-4.14/etc/xtermlock.sh b/xlockmore-4.14/etc/xtermlock.sh
new file mode 100755 (executable)
index 0000000..93cc1c1
--- /dev/null
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Runs xlock displaying to the current X terminal emulator window
+# Works well in xterm, but not so well in terminal emulators like
+# dtterm that have menu bars and other junk.
+#
+# All arguments are passed to xlock.
+
+g=`stty -a |
+    sed -ne's/.* ypixels = \([^;]*\); xpixels = \([^;]*\).*/\2x\1/p'`
+exec xlock -inwindow -parent $WINDOWID +install -geometry $g "$@"
diff --git a/xlockmore-4.14/etc/xwinlock.sh b/xlockmore-4.14/etc/xwinlock.sh
new file mode 100755 (executable)
index 0000000..ae2d465
--- /dev/null
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+# Runs xlock displaying in another X client's window.
+# use -me to use current terminal emulator window (works in ddterm).
+# use -id <windowid> to display to a specific window.
+# Otherwise select the target window with the cross-hair cursor.
+# 
+# All other arguments are passed to xlock.
+
+case $1 in
+-me)if [ "$WINDOWID" ]; then id="-id $WINDOWID"; shift
+    else echo >&2 "WINDOWID not set"; exit 1; fi;;
+-id)if [ $# -gt 1 ]; then id="-id $2"; shift; shift
+    else echo >&2 "ID not specified"; exit 1; fi;;
+esac
+exec xlock  +install -inwindow -parent `xwininfo $id -int |
+    awk '/Window id/{printf "%d", $4};
+         /Width/{printf " -geometry %d", $2};
+         /Height/{printf "x%d", $2}'` "$@"
diff --git a/xlockmore-4.14/iconfig.h b/xlockmore-4.14/iconfig.h
new file mode 100644 (file)
index 0000000..b277a97
--- /dev/null
@@ -0,0 +1,510 @@
+/* Config file for xlockmore
+ * Many "ideas" taken from xscreensaver-1.34 by Jamie Zawinski.
+ *
+ * This file is included by the various Imakefiles.
+ * After editing this file, you need to execute the commands
+ *
+ *         xmkmf
+ *         make Makefiles
+ *
+ * Substitute #undef with #define to activate option
+ */
+
+XCOMM !!!WARNING!!! Known security hole with MesaGL < 3.0 if setuid root
+XCOMM Define these now or down further below, see below for explaination.
+XCOMM  #define XpmLibrary
+XCOMM  #define XmLibrary
+XCOMM  #define XawLibrary
+XCOMM  #define GLLibrary
+XCOMM  #define DtSaverLibrary
+XCOMM  #define DPMSLibrary
+XCOMM  #define RplayLibrary
+XCOMM  #define NasLibrary
+XCOMM  #define Modules
+XCOMM  #define Check
+XCOMM  #define Unstable
+
+N =
+O = .o
+XCOMM  O = .obj
+C=.c
+XCOMM  C = .cc
+S=$(N) $(N)
+XCOMM  S = ,
+
+XCOMM please define
+XCOMM C as the C source code extension
+XCOMM O as the object extension
+XCOMM S as the separator for object code
+
+XCOMM  CC = cc
+XCOMM  CC = acc
+XCOMM  CC = CC
+XCOMM  CC = gcc -Wall
+XCOMM  CC = g++ -Wall
+
+LN_S = $(LN)
+
+XCOMM   *** BEGIN XPM CONFIG SECTION ***
+
+XCOMM Only the image.c and bat.c modes use this.
+XCOMM If your system has libXpm, remove the 'XCOMM  ' from the next line.
+XCOMM  #define XpmLibrary
+
+#ifdef XpmLibrary
+XPMDEF = -DUSE_XPM
+XCOMM Use the following if your xpm.h file is not in an X11 directory
+XCOMM  XPMDEF = -DUSE_XPMINC
+
+XCOMM If you get an error "Cannot find xpm.h" while compiling, set
+XCOMM XPMINC to the directory X11/xpm.h is in.  Below is a guess.
+XPMINC = -I/usr/local/include
+XCOMM SGI's ViewKit (use with -DUSE_XPMINC)
+XCOMM  XPMINC = -I/usr/include/Vk
+
+XCOMM If you get an error "Cannot find libXpm" while linking, set XPMLIBPATH
+XCOMM to the directory libXpm.* is in.  Below is a guess.
+XPMLIB = -L/usr/local/lib -lXpm
+
+#endif
+
+XCOMM   *** END XPM CONFIG SECTION ***
+
+XCOMM   *** BEGIN XM CONFIG SECTION ***
+XCOMM Only options.c and xmlock.c uses Motif.
+XCOMM If your system has libXm, remove the 'XCOMM  ' from the next line.
+XCOMM  #define XmLibrary
+#ifdef XmLibrary
+XCOMM If its not with your X11 stuff you should set the following
+XCOMM  MOTIFHOME = /usr/local
+XCOMM  MOTIFHOME = /usr/dt
+XCOMM If you get an error "Cannot find Xm/PanedW.h" while compiling, set
+XCOMM XMINC to the directory Xm/PanedW.h is in.  Below is a guess.
+XCOMM  XMINC = -I$(MOTIFHOME)/include
+XCOMM If you get an error "Cannot find libXm" while linking, set XMLIBPATH
+XCOMM to the directory libXm.* is in.  Below is a guess.
+XCOMM  XMLIB = -L$(MOTIFHOME)/lib -lXm
+XMLIB = -lXm
+XCOMM Debugging with editres
+XCOMM  EDITRESDEF = -DUSE_XMU
+XCOMM  EDITRESLIB = -lXmu
+#endif
+XCOMM   *** END XM CONFIG SECTION ***
+
+XCOMM   *** BEGIN XAW CONFIG SECTION ***
+XCOMM Only options.c and xalock.c uses Athena.
+XCOMM If your system has libsx, libXaw, and libXmu,
+XCOMM remove the 'XCOMM  ' from the next line.
+XCOMM  #define XawLibrary
+#ifdef XawLibrary
+XCOMM If its not with your X11 stuff you should set the following
+XCOMM  ATHENAHOME = /usr/local
+XCOMM Below is a guess.
+XCOMM  XAWINC = -I$(ATHENAHOME)/include
+XCOMM Below is a guess.
+XCOMM  XAWLIB = -L$(ATHENAHOME)/lib -lsx -lXaw -lXmu
+XAWLIB = -lsx -lXaw -lXmu
+#endif
+XCOMM   *** END XAW CONFIG SECTION ***
+
+XCOMM   *** BEGIN MESAGL AND OPENGL CONFIG SECTION ***
+
+XCOMM escher, gears, morph3d, pipes, superquadrics, sproingies modes use this.
+XCOMM If your system has libMesaGL & widgets,
+XCOMM remove the 'XCOMM  ' from the next line.
+XCOMM  #define GLLibrary
+
+#ifdef GLLibrary
+GLDEF = -DUSE_GL
+
+XCOMM If you get an error "Cannot find GL/gl.h" while compiling, set
+XCOMM GLINC to the directory GL/gl.h is in.
+GLINC = -I/usr/local/include
+
+XCOMM If you get an error "Cannot find libMesaGL" while linking, set GLLIBPATH
+XCOMM to the directory libMesaGL.* is in.  Below is a guess.
+XCOMM !!!WARNING!!! Known security hole with MesaGL < 3.0 if setuid root
+GLLIB = -L/usr/local/lib -lMesaGL -lMesaGLU
+
+XCOMM On SGI
+XCOMM  GLLIB = -lGL -lGLU -lgl
+XCOMM On other OpenGL
+XCOMM  GLLIB = -lGL -lGLU
+XCOMM On Sun with OGL1.1
+XCOMM  GLDEF += -DSUN_OGL_NO_VERTEX_MACROS
+XCOMM 3Dfx card
+XCOMM  GLDEF += -DFX
+XCOMM Threads
+XCOMM  GLLIB += -lpthread
+#endif
+
+XCOMM   *** END MESAGL AND OPENGL CONFIG SECTION ***
+
+XCOMM   *** BEGIN CDE DT CONFIG SECTION ***
+XCOMM COMMON DESKTOP ENVIRONMENT
+XCOMM if your system has libDtSvc, remove the 'XCOMM  ' from the next line
+XCOMM  #define DtSaverLibrary
+
+#ifdef DtSaverLibrary
+DTSAVERDEF = -DUSE_DTSAVER
+DTSAVERINC = -I/usr/dt/include
+DTSAVERLIB = -L/usr/dt/lib -lDtSvc
+#endif
+
+XCOMM   *** END CDE DT CONFIG SECTION ***
+
+XCOMM   *** BEGIN DPMS CONFIG SECTION ***
+XCOMM DISPLAY POWER MANAGEMENT SIGNALING
+XCOMM if your system has libXdpms, remove the 'XCOMM  ' from the next line
+XCOMM  #define DPMSLibrary
+
+#ifdef DPMSLibrary
+DTSAVERDEF = -DUSE_DPMS
+XCOMM DPMSINC =
+DPMSLIB = -lXdpms
+#endif
+
+XCOMM   *** END DPMS CONFIG SECTION ***
+
+XCOMM   *** BEGIN SOUND CONFIG SECTION ***
+XCOMM Only xlock.c and resource.c use this
+XCOMM if your system has these sound libraries, remove the 'XCOMM  '
+XCOMM  #define RplayLibrary
+XCOMM  #define NasLibrary
+
+#ifdef RplayLibrary
+SOUNDDEF = -DUSE_RPLAY
+SOUNDINC = -I/usr/local/include
+XCOMM SOUNDLIB = -L/share/lib -lrplay
+SOUNDLIB = -L/usr/local/lib -lrplay
+#endif
+
+#ifdef NasLibrary
+SOUNDDEF = -DUSE_NAS
+SOUNDINC = -I/usr/X11R6/include
+SOUNDLIB = -L/usr/X11R6/lib -laudio
+#endif
+
+XCOMM system play (optional software)
+XCOMM SUNOS 4.1.3
+XCOMM  DEF_PLAY = "/usr/demo/SOUND/play /usr/local/share/sounds/xlock/"
+XCOMM IRIX 5.3
+XCOMM  DEF_PLAY = "/usr/sbin/sfplay /usr/local/share/sounds/xlock/"
+XCOMM Digital Unix with Multimedia Services installed:
+XCOMM  DEF_PLAY = "/usr/bin/mme/decsound -play /usr/local/share/sounds/xlock/"
+XCOMM LINUX and others (see config directory)
+XCOMM  DEF_PLAY = "/usr/local/bin/play.sh /usr/local/share/sounds/xlock/"
+XCOMM Uncomment line below if you have one of the above
+XCOMM  SOUNDDEF = -DDEF_PLAY=\"$(DEF_PLAY)\"
+
+XCOMM      *** END SOUND CONFIG SECTION ***
+
+XCOMM      *** BEGIN RNG CONFIG SECTION ***
+
+XCOMM Uncomment to use your system's Random Number Generator
+XCOMM They usually come in 3 types
+
+XCOMM Uncomment to use high-precision (but expensive) RNG
+XCOMM  SRANDDEF = -DSRAND=srand48
+XCOMM  LRANDDEF = -DLRAND=lrand48
+
+XCOMM  SRANDDEF = -DSRAND=srandom
+XCOMM  LRANDDEF = -DLRAND=random
+
+XCOMM Least desirable RNG
+XCOMM  SRANDDEF = -DSRAND=srand
+XCOMM  LRANDDEF = -DLRAND=rand
+
+XCOMM Normally use the above with (default)
+XCOMM  MAXRANDDEF = -DMAXRAND=2147483648.0
+XCOMM Use the following if using srand/rand and NOT AIXV3
+XCOMM  MAXRANDDEF = -DMAXRAND=32767.0
+RANDDEF = $(SRANDDEF) $(LRANDDEF) $(MAXRANDDEF)
+
+XCOMM      *** END RNG CONFIG SECTION ***
+
+XCOMM    *** BEGIN MODULES CONFIG SECTION **
+
+XCOMM This is a HIGHLY experimental section.
+XCOMM To use modules, you must have an ELF setup installed, and
+XCOMM libdl.  This was originally written for Linux.
+XCOMM /usr/include/dlfcn.h is not present on all Linux machines.
+XCOMM Also tried to get this running on XCOMM Solaris-2.6 with gcc and gmake.
+XCOMM Do not know if other Unixes support this kind of dynamic loading.
+XCOMM Un-commenting Modules will compile xlock so that all of the modes
+XCOMM are in separate modules which are loaded at runtime.  This means
+XCOMM you can add new modes simply by putting them in your modules
+XCOMM directory.
+XCOMM  #define Modules
+
+#ifdef Modules
+
+XCOMM #define UseElfFormat YES
+
+XCOMM This is the default directory to look in for modules. It can be
+XCOMM a colon separated list of directories.
+DEF_MODULEPATH = $(USRLIBDIR)/X11/xlock_modules
+
+XCOMM Flag to compile the main program so that global variables will be
+XCOMM available to modules
+MODULEFLAGS = -rdynamic
+
+MODULEDEF = -DDEF_MODULEPATH=\"$(DEF_MODULEPATH)\" -DUSE_MODULES
+
+XCOMM Library necessary to use dynamic loading
+MODULELIB = -ldl
+
+#endif
+
+XCOMM    *** END MODULES CONFIG SECTION ***
+
+XCOMM      *** BEGIN DEBUG CHECK SECTION ***
+XCOMM #define Check
+#ifdef Check
+XCOMM Very experimental
+CHECKDEF = -DDEBUG
+#endif
+XCOMM      *** END DEBUG CHECK SECTION ***
+
+#ifndef __QNX__
+#ifndef MathLibrary
+#define MathLibrary -lm
+#endif
+#else
+#define MathLibrary
+PASSWDDEF = -DHAVE_SHADOW -Dlinux
+PASSWDLIB = -l/src/util/Lib/util
+#endif
+
+XCOMM KERBEROS Ver. 4
+XCOMM  PASSWDDEF = -DHAVE_KRB4
+XCOMM  PASSWDINC = -I/usr/athena/include
+XCOMM  PASSWDLIB = -L/usr/athena/lib -lkrb -ldes -lresolv
+XCOMM
+XCOMM KERBEROS Ver. 5
+XCOMM  PASSWDDEF = -DHAVE_KRB5
+XCOMM  PASSWDINC = -I/opt/krb5/include
+XCOMM  PASSWDLIB = -L/opt/krb5/lib -lkrb5 -lcrypto -lcom_err
+
+XCOMM DCE authentication (tested only on HP's)
+XCOMM  PASSWDDEF = -DDCE_PASSWD
+XCOMM  PASSWDINC = -I/usr/include/reentrant
+XCOMM  PASSWDLIB = -ldce -lc_r
+
+XCOMM PAM (tested only on Linux)
+XCOMM  PASSWDDEF = -DUSE_PAM
+XCOMM  PASSWDLIB = -lpam -ldl
+
+#ifdef SVR4ix86Architecture
+PASSWDDEF = -DHAVE_SHADOW
+#endif
+
+#ifdef SunArchitecture
+#if SystemV4
+#if OSMajorVersion == 2 && OSMinorVersion < 5
+SYSTEMDEF = -DLESS_THAN_SOLARIS2_5 -DSOLARIS2
+#else
+SYSTEMDEF = -DSOLARIS2
+#endif
+XCOMM imake is usually not set up right here.
+XCOMM Assume shadowing... usually more correct.
+XCOMM  #if HasShadowPasswd
+XCOMM  PASSWDDEF = -DHAVE_SHADOW
+XCOMM  #endif
+PASSWDDEF = -DHAVE_SHADOW
+XCOMM  SLEEPDEF = -DHAVE_NAONOSLEEP
+
+XCOMM Problems finding libXext.so.0 when sticky bit is set
+EXTRA_LDOPTIONS = -R/usr/lib:/usr/openwin/lib:/usr/dt/lib:/usr/local/lib
+
+PIXMAPTYPE = sol
+#else
+SYSTEMDEF = -DSUNOS4 -DUSE_MATHERR
+SLEEPDEF = -DHAVE_USLEEP
+#if HasShadowPasswd
+XCOMM  PASSWDDEF = -DSUNOS_ADJUNCT_PASSWD
+PASSWDDEF = -DHAVE_SHADOW
+#endif
+PIXMAPTYPE = sun
+#endif
+BITMAPTYPE = sun
+#else 
+#if HasShadowPasswd
+PASSWDDEF = -DHAVE_SHADOW
+XCOMM  PASSWDLIB = -lshadow
+#endif
+#if defined(HPArchitecture) || defined(ApolloArchitecture)
+#ifdef HPArchitecture
+XCOMM If your site is using Secured Passwords,
+XCOMM  PASSWDDEF = -DHPUX_SECURE_PASSWD
+XCOMM If your site is using Passwd Etc,
+XCOMM  PASSWDDEF = -DHP_PASSWDETC
+XCOMM  PASSWDLIB = -lrgy -lnck -lndbm
+XCOMM  PASSWDLIB = -lrgy -lnck -lndbm -lsec
+CCOPTIONS = -Aa
+SYSTEMDEF = -D_HPUX_SOURCE -DSYSV -DUSE_MATHERR
+#else
+SLEEPDEF = -DHAVE_USLEEP
+#endif
+EXTRA_LIBRARIES = -lXhp11
+BITMAPTYPE = hp
+PIXMAPTYPE = hp
+#else
+#ifdef i386SVR4Architecture
+EXTRA_LIBRARIES = -lsocket -lnsl -lgen
+PASSWDDEF = -DHAVE_SHADOW
+BITMAPTYPE = x11
+PIXMAPTYPE = x11
+#else
+#if defined(FreeBSDArchitecture) || defined(NetBSDArchitecture) || defined(i386BsdArchitecture)
+SLEEPDEF = -DHAVE_USLEEP
+BITMAPTYPE = bsd
+PIXMAPTYPE = bsd
+INSTPGMFLAGS = -s -o root -m 4111
+#else
+#ifdef LinuxArchitecture
+SLEEPDEF = -DHAVE_USLEEP
+BITMAPTYPE = linux
+PIXMAPTYPE = linux
+#if HasShadowPasswd && !UseElfFormat
+EXTRA_LIBRARIES = -lgdbm
+#endif
+#else
+#ifdef SGIArchitecture
+BITMAPTYPE = sgi
+PIXMAPTYPE = sgi
+#else
+#ifdef AIXArchitecture
+BITMAPTYPE = ibm
+PIXMAPTYPE = ibm
+XCOMM If AIX 3.1 or less, do not have struct passwd and other things
+#if OSMajorVersion < 3 || (OSMajorVersion == 3 && OSMinorVersion < 2)
+SYSTEMDEF = -DLESS_THAN_AIX3_2
+#endif
+XCOMM Use this if your site is using AFS:
+XCOMM  PASSWDDEF = -DAFS
+XCOMM  Solaris 2.x may need the next line
+XCOMM  PASSWDDEF += -DSHADOW
+XCOMM  PASSWDINC = -I/usr/afsws/include
+XCOMM  PASSWDLIB = -L/usr/afsws/lib -L/usr/afsws/lib/afs -L/usr/afsws/domestic/lib -lkauth -lubik -lprot -lrxkad -lrx -llwp -lauth -lsys -ldes -lcmd -lcom_err /usr/afsws/lib/afs/util.a
+XCOMM  SunOS 4.1.x may need the next line
+XCOMM  PASSWDLIB += /usr/afsws/domestic/lib/librxkad.a
+XCOMM  Solaris 2.x may need the next line
+XCOMM  PASSWDLIB += /usr/afsws/domestic/lib/librxkad.a usr/lib/libsocket.so.1 /usr/lib/libnsl.so.1 /usr/ucblib/libucb.a
+XCOMM You may need this one too.
+XCOMM  EXTRA_LIBRARIES = -laudit
+
+
+#else
+#ifdef UltrixArchitecture
+BITMAPTYPE = dec
+PIXMAPTYPE = dec
+EXTRA_LIBRARIES = -lauth
+#else
+
+#ifdef SCOArchitecture
+PASSWDDEF = -DHAVE_SHADOW -DSVR4
+BITMAPTYPE = sco
+PIXMAPTYPE = sco
+#else
+BITMAPTYPE = x11
+PIXMAPTYPE = x11
+
+#endif
+#endif
+#endif
+#endif
+#endif
+#endif
+#endif
+#endif
+#endif
+
+XLOCKINC = -I$(top_srcdir) -I. -I$(UTILSDIR)
+
+XCOMM -DUSE_VROOT              Allows xlock to run in root window (some
+XCOMM                          window managers have problems)
+XCOMM -DALWAYS_ALLOW_ROOT      Users can not turn off allowroot
+XCOMM -DUSE_SYSLOG             Paranoid administrator option (a check is also
+XCOMM                          done to see if you have it)
+XCOMM -DUSE_MULTIPLE_USER      Multiple users ... security?
+XCOMM -DUSE_MULTIPLE_ROOT      Multiple root users ... security?
+XCOMM -DUSE_WINDOW_VISIBILITY  Allow a window to be placed over xlock
+XCOMM -DUSE_OLD_EVENT_LOOP     Some machines may still need this (fd_set
+XCOMM                          errors may be a sign)
+XCOMM -DUSE_VMSUTILS           This patches up old __VMS_VER < 70000000
+XCOMM -DUSE_DPMS               DPMS stuff
+XCOMM
+XCOMM For personal use you may want to consider:
+XCOMM -DUSE_XLOCKRC            paranoid admin or unknown shadow passwd alg
+XCOMM
+XCOMM For labs you may want to consider:
+XCOMM -DUSE_AUTO_LOGOUT=240     Enable auto-logout and set deadline (minutes)
+XCOMM -DDEF_AUTO_LOGOUT=\"120\" Set default auto-logout deadline (minutes)
+XCOMM -DUSE_BUTTON_LOGOUT=10    Enable logout button and set appear time (min) 
+XCOMM -DDEF_BUTTON_LOGOUT=\"5\" Set default logout button (minutes) 
+XCOMM -DUSE_BOMB                Enable automatic logout mode (does not come up
+XCOMM                           in random mode)
+XCOMM -DUSE_UNSTABLE            Enable unstable bubble3d GL mode
+XCOMM -DCLOSEDOWN_LOGOUT        Use with USE_AUTO_LOGOUT, USE_BUTTON_LOGOUT,
+XCOMM                           USE_BOMB if using xdm
+XCOMM -DSESSION_LOGOUT          Alternate of above
+XCOMM -DSTAFF_FILE=\"/etc/xlock.staff\"  File of staff who are exempt
+XCOMM -DSTAFF_NETGROUP=\"/etc/xlock.netgroup\"  Netgroup that is exempt
+
+XCOMM May have to combine in one long line if "+=" does not work
+OPTDEF = -DUSE_VROOT -DALWAYS_ALLOW_ROOT -DUSE_BOMB
+XCOMM  OPTDEF += -DUSE_UNSTABLE
+XCOMM  OPTDEF += -DUSE_SYSLOG -DSYSLOG_FACILITY=LOG_AUTH
+XCOMM  OPTDEF += -DSYSLOG_WARNING=LOG_WARNING
+XCOMM  OPTDEF += -DSYSLOG_NOTICE=LOG_NOTICE -DSYSLOG_INFO=LOG_INFO
+XCOMM  OPTDEF += -DUSE_MULTIPLE_USER
+XCOMM  OPTDEF += -DUSE_MULTIPLE_ROOT
+XCOMM  OPTDEF += -DUSE_OLD_EVENT_LOOP
+XCOMM  OPTDEF += -DUSE_XLOCKRC
+XCOMM  OPTDEF += -DUSE_AUTO_LOGOUT=240
+XCOMM  OPTDEF += -DDEF_AUTO_LOGOUT=\"120\"
+XCOMM  OPTDEF += -DUSE_BUTTON_LOGOUT=10
+XCOMM  OPTDEF += -DDEF_BUTTON_LOGOUT=\"5\"
+XCOMM  OPTDEF += -DCLOSEDOWN_LOGOUT
+XCOMM  OPTDEF += -DSESSION_LOGOUT
+XCOMM  OPTDEF += -DSTAFF_FILE=\"/etc/xlock.staff\"
+XCOMM  OPTDEF += -DSTAFF_NETGROUP=\"/etc/xlock.netgroup\"
+
+DEFINES = -DDEF_FILESEARCHPATH=\"$(LIBDIR)/%T/%N%S\" \
+$(SYSTEMDEF) $(EDITRESDEF) $(SLEEPDEF) $(OPTDEF) $(RANDDEF) $(MODULEDEF) \
+$(PASSWDDEF) $(XMINC) $(XAWINC) $(XPMDEF) $(GLDEF) $(DTSAVERDEF) $(DPMSDEF) \
+$(SOUNDDEF) $(PASSWDINC) $(XPMINC) $(GLINC) $(DTSAVERINC) $(DPMSINC) \
+$(SOUNDINC) $(XLOCKINC)
+
+DEPLIBS = $(DEPXLIB)
+LOCAL_LIBRARIES = $(MODULELIB) $(XLIB) \
+$(XPMLIB) $(GLLIB) $(DTSAVERLIB) $(DPMSLIB) $(SOUNDLIB)
+MLIBS = $(XPMLIB) $(XMLIB) $(EDITRESLIB) -lXt $(XLIB) $(SMLIB) $(ICELIB)
+ALIBS = $(XAWLIB) -lXt $(XLIB) $(SMLIB) $(ICELIB)
+LINTLIBS = $(LINTXLIB)
+#if HasLibCrypt
+       CRYPTLIB = -lcrypt
+#endif
+SYS_LIBRARIES = $(CRYPTLIB) $(PASSWDLIB) MathLibrary
+
+VER = xlockmore
+DISTVER = xlockmore-4.13
diff --git a/xlockmore-4.14/install-sh b/xlockmore-4.14/install-sh
new file mode 100755 (executable)
index 0000000..ebc6691
--- /dev/null
@@ -0,0 +1,250 @@
+#! /bin/sh
+#
+# install - install a program, script, or datafile
+# This comes from X11R5 (mit/util/scripts/install.sh).
+#
+# Copyright 1991 by the Massachusetts Institute of Technology
+#
+# Permission to use, copy, modify, distribute, and sell this software and its
+# documentation for any purpose is hereby granted without fee, provided that
+# the above copyright notice appear in all copies and that both that
+# copyright notice and this permission notice appear in supporting
+# documentation, and that the name of M.I.T. not be used in advertising or
+# publicity pertaining to distribution of the software without specific,
+# written prior permission.  M.I.T. makes no representations about the
+# suitability of this software for any purpose.  It is provided "as is"
+# without express or implied warranty.
+#
+# Calling this script install-sh is preferred over install.sh, to prevent
+# `make' implicit rules from creating a file called install from it
+# when there is no Makefile.
+#
+# This script is compatible with the BSD install script, but was written
+# from scratch.  It can only install one file at a time, a restriction
+# shared with many OS's install programs.
+
+
+# set DOITPROG to echo to test this script
+
+# Don't use :- since 4.3BSD and earlier shells don't like it.
+doit="${DOITPROG-}"
+
+
+# put in absolute paths if you don't have them in your path; or use env. vars.
+
+mvprog="${MVPROG-mv}"
+cpprog="${CPPROG-cp}"
+chmodprog="${CHMODPROG-chmod}"
+chownprog="${CHOWNPROG-chown}"
+chgrpprog="${CHGRPPROG-chgrp}"
+stripprog="${STRIPPROG-strip}"
+rmprog="${RMPROG-rm}"
+mkdirprog="${MKDIRPROG-mkdir}"
+
+transformbasename=""
+transform_arg=""
+instcmd="$mvprog"
+chmodcmd="$chmodprog 0755"
+chowncmd=""
+chgrpcmd=""
+stripcmd=""
+rmcmd="$rmprog -f"
+mvcmd="$mvprog"
+src=""
+dst=""
+dir_arg=""
+
+while [ x"$1" != x ]; do
+    case $1 in
+       -c) instcmd="$cpprog"
+           shift
+           continue;;
+
+       -d) dir_arg=true
+           shift
+           continue;;
+
+       -m) chmodcmd="$chmodprog $2"
+           shift
+           shift
+           continue;;
+
+       -o) chowncmd="$chownprog $2"
+           shift
+           shift
+           continue;;
+
+       -g) chgrpcmd="$chgrpprog $2"
+           shift
+           shift
+           continue;;
+
+       -s) stripcmd="$stripprog"
+           shift
+           continue;;
+
+       -t=*) transformarg=`echo $1 | sed 's/-t=//'`
+           shift
+           continue;;
+
+       -b=*) transformbasename=`echo $1 | sed 's/-b=//'`
+           shift
+           continue;;
+
+       *)  if [ x"$src" = x ]
+           then
+               src=$1
+           else
+               # this colon is to work around a 386BSD /bin/sh bug
+               :
+               dst=$1
+           fi
+           shift
+           continue;;
+    esac
+done
+
+if [ x"$src" = x ]
+then
+       echo "install:  no input file specified"
+       exit 1
+else
+       true
+fi
+
+if [ x"$dir_arg" != x ]; then
+       dst=$src
+       src=""
+       
+       if [ -d $dst ]; then
+               instcmd=:
+       else
+               instcmd=mkdir
+       fi
+else
+
+# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
+# might cause directories to be created, which would be especially bad 
+# if $src (and thus $dsttmp) contains '*'.
+
+       if [ -f $src -o -d $src ]
+       then
+               true
+       else
+               echo "install:  $src does not exist"
+               exit 1
+       fi
+       
+       if [ x"$dst" = x ]
+       then
+               echo "install:  no destination specified"
+               exit 1
+       else
+               true
+       fi
+
+# If destination is a directory, append the input filename; if your system
+# does not like double slashes in filenames, you may need to add some logic
+
+       if [ -d $dst ]
+       then
+               dst="$dst"/`basename $src`
+       else
+               true
+       fi
+fi
+
+## this sed command emulates the dirname command
+dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
+
+# Make sure that the destination directory exists.
+#  this part is taken from Noah Friedman's mkinstalldirs script
+
+# Skip lots of stat calls in the usual case.
+if [ ! -d "$dstdir" ]; then
+defaultIFS='   
+'
+IFS="${IFS-${defaultIFS}}"
+
+oIFS="${IFS}"
+# Some sh's can't handle IFS=/ for some reason.
+IFS='%'
+set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'`
+IFS="${oIFS}"
+
+pathcomp=''
+
+while [ $# -ne 0 ] ; do
+       pathcomp="${pathcomp}${1}"
+       shift
+
+       if [ ! -d "${pathcomp}" ] ;
+        then
+               $mkdirprog "${pathcomp}"
+       else
+               true
+       fi
+
+       pathcomp="${pathcomp}/"
+done
+fi
+
+if [ x"$dir_arg" != x ]
+then
+       $doit $instcmd $dst &&
+
+       if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi &&
+       if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi &&
+       if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi &&
+       if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi
+else
+
+# If we're going to rename the final executable, determine the name now.
+
+       if [ x"$transformarg" = x ] 
+       then
+               dstfile=`basename $dst`
+       else
+               dstfile=`basename $dst $transformbasename | 
+                       sed $transformarg`$transformbasename
+       fi
+
+# don't allow the sed command to completely eliminate the filename
+
+       if [ x"$dstfile" = x ] 
+       then
+               dstfile=`basename $dst`
+       else
+               true
+       fi
+
+# Make a temp file name in the proper directory.
+
+       dsttmp=$dstdir/#inst.$$#
+
+# Move or copy the file name to the temp name
+
+       $doit $instcmd $src $dsttmp &&
+
+       trap "rm -f ${dsttmp}" 0 &&
+
+# and set any options; do chmod last to preserve setuid bits
+
+# If any of these fail, we abort the whole thing.  If we want to
+# ignore errors from any of these, just make sure not to ignore
+# errors from the above "$doit $instcmd $src $dsttmp" command.
+
+       if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi &&
+       if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi &&
+       if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi &&
+       if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi &&
+
+# Now rename the file to the real destination.
+
+       $doit $rmcmd -f $dstdir/$dstfile &&
+       $doit $mvcmd $dsttmp $dstdir/$dstfile 
+
+fi &&
+
+
+exit 0
diff --git a/xlockmore-4.14/make.com b/xlockmore-4.14/make.com
new file mode 100644 (file)
index 0000000..92da87f
--- /dev/null
@@ -0,0 +1,499 @@
+$ save_verify='f$verify(0)
+$! set ver 
+$!
+$!      VMS compile and link for xlockmore
+$!
+$! USAGE:
+$! @make [debug clobber clean]
+$!       debug : compile with degugger switch
+$!       clean : clean all except executable
+$!       clobber : clean all
+$!
+$! If you have
+$!              XPM library
+$!              XVMSUTILS library (VMS6.2 or lower)
+$!              Mesa GL library
+$! insert the correct directory instead of X11 or GL:
+$ xvmsutilsf="X11:XVMSUTILS.OLB"
+$ xpmf="X11:LIBXPM.OLB"
+$ glf="GL:LIBMESAGL.OLB"
+$ gluf="GL:LIBMESAGLU.OLB"
+$ ttff="SYS$LIBRARY:LIBTTF.OLB"
+$ glttf="SYS$LIBRARY:LIBGLTT.OLB"
+$!
+$! Assume C.
+$ deccxx=0
+$! Assume C++ (but may not link on VMS6.2 or lower)
+$! deccxx=1
+$! test on C++.
+$! deccxx=f$search("SYS$SYSTEM:CXX$COMPILER.EXE") .nes. ""
+$!
+$! Already assumes DEC C on Alpha.
+$! Assume VAX C on VAX.
+$! decc=0
+$! Assume DEC C on VAX.
+$! decc=1
+$! test on DEC C.
+$ decc=f$search("SYS$SYSTEM:DECC$COMPILER.EXE") .nes. ""
+$!
+$! if vroot<>0 the use of the root window is enabled
+$ vroot=1
+$! vroot=0
+$!
+$! if bomb<>0 the use bomb mode is included (does not come up in random mode)
+$ bomb=1
+$! bomb=0
+$!
+$! if unstable<>0 some of these mode(s) included could be a little buggy 
+$! unstable=0
+$ unstable=1
+$!
+$! if sound<>0 sound capability is included (only available on Alpha)
+$! from vms_amd.c and vms_amd.h
+$ sound=1
+$! sound=0
+$!
+$! Memory Check stuff.  Very experimental!
+$ check=0
+$! check=1
+$
+$! Compliant colour map if <>1
+$ complmap=0
+$! complmap=1
+$!
+$!
+$! NOTHING SHOULD BE MODIFIED BELOW
+$!
+$ if p1 .eqs. "CLEAN" then goto Clean
+$ if p1 .eqs. "CLOBBER" then goto Clobber
+$!
+$ defs=="VMS"
+$ dtsaver=f$search("SYS$LIBRARY:CDE$LIBDTSVC.EXE") .nes. ""
+$ xpm=f$search("''xpmf'") .nes. ""
+$ gl=f$search("''glf'") .nes. ""
+$ glu=f$search("''gluf'") .nes. ""
+$ gltt=f$search("''glttf'") .nes. ""
+$ ttf=f$search("''ttff'") .nes. ""
+$ iscxx=f$search("SYS$SYSTEM:CXX$COMPILER.EXE") .nes. ""
+$ axp=f$getsyi("HW_MODEL") .ge. 1024
+$ sys_ver=f$edit(f$getsyi("version"),"compress")
+$ if f$extract(0,1,sys_ver) .nes. "V"
+$ then
+$   type sys$input
+This script will assume that the operating system version is at least V7.0. 
+$!
+$   sys_ver="V7.0"
+$ endif
+$ sys_maj=0+f$extract(1,1,sys_ver)
+$ if sys_maj .lt. 7
+$ then
+$   xvmsutils=f$search("''xvmsutilsf'") .nes. ""
+$ endif
+$!
+$! Create .opt file
+$ close/nolog optf
+$ open/write optf xlock.opt
+$!
+$ if iscxx then defs=="''defs',HAVE_CXX" 
+$ if ttf then defs=="''defs',HAVE_TTF"
+$ if gltt then defs=="''defs',HAVE_GLTT"
+$ if iscxx .and. ttf .and. gltt then defs=="''defs',USE_TEXT" 
+$ if complmap then defs=="''defs',COMPLIANT_COLORMAP"
+$ if xpm then defs=="''defs',USE_XPM"
+$ if gl then defs=="''defs',USE_GL,HAVE_GLBINDTEXTURE"
+$ if dtsaver then defs=="''defs',USE_DTSAVER"
+$ if axp .and. sound then defs=="''defs',USE_VMSPLAY"
+$ if sys_maj .lt. 7
+$ then
+$   if xvmsutils then defs=="''defs',USE_XVMSUTILS"
+$ endif
+$ if vroot then defs=="''defs',USE_VROOT"
+$ if bomb then defs=="''defs',USE_BOMB"
+$ if unstable then defs=="''defs',USE_UNSTABLE"
+$ if check then defs=="''defs',DEBUG"
+$! The next must be the last one.
+$ if sys_maj .ge. 7
+$ then
+$   defs=="''defs',HAVE_USLEEP"
+$   defs=="''defs',SRAND=""""srand48"""",LRAND=""""lrand48"""",MAXRAND=2147483648.0"
+$ endif
+$!
+$! Establish the Compiling Environment
+$!
+$! Set compiler command
+$! Put in /include=[] for local include file like a pwd.h ...
+$!   not normally required.
+$     cxx=="cxx/include=([],[.xlock])/define=(''defs')"
+$ if deccxx
+$ then
+$   cc=="cxx/include=([],[.xlock])/define=(''defs')"
+$ else
+$   if axp
+$   then
+$!     cc=="cc/standard=vaxc/include=([],[.xlock])/define=(''defs')"
+$     cc=="cc/include=([],[.xlock])/define=(''defs')"
+$   else
+$     if decc
+$     then
+$!       cc=="cc/decc/standard=vaxc/include=([],[.xlock])/define=(''defs')"
+$       cc=="cc/decc/include=([],[.xlock])/define=(''defs')"
+$     else ! VAX C
+$       cc=="cc/include=([],[.xlock])/define=(''defs')"
+$     endif
+$   endif
+$ endif
+$ if p1 .eqs. "DEBUG" .or. p2 .eqs. "DEBUG" .or. p3 .eqs. "DEBUG"
+$ then
+$   if deccxx
+$   then
+$     cc=="cxx/deb/noopt/include=([],[.xlock])/define=(''defs')/list"
+$   else
+$     if axp
+$     then
+$!       cc=="cc/deb/noopt/standard=vaxc/include=([],[.xlock])/define=(''defs')/list"
+$       cc=="cc/deb/noopt/include=([],[.xlock])/define=(''defs')/list"
+$     else
+$       if decc
+$       then
+$!         cc=="cc/deb/noopt/decc/standard=vaxc/include=([],[.xlock])/define=(''defs')/list"
+$         cc=="cc/deb/noopt/decc/include=([],[.xlock])/define=(''defs')/list"
+$       else ! VAX C
+$         cc=="cc/deb/noopt/include=([],[.xlock])/define=(''defs')/list"
+$       endif
+$     endif
+$   endif
+$   link=="link/deb"
+$ endif
+$!
+$ if axp .or. .not. decc
+$ then
+$   define/nolog sys sys$library
+$ endif
+$!
+$ write sys$output "Linking Include Files"
+$ call make decay.xbm  "set file/enter=[]decay.xbm [.bitmaps]l-xlock.xbm" [.bitmaps]l-xlock.xbm
+$! call make eyes.xbm   "set file/enter=[]eyes.xbm [.bitmaps]m-dec.xbm"    [.bitmaps]m-dec.xbm
+$ call make eyes.xbm   "set file/enter=[]eyes.xbm [.bitmaps]m-grelb.xbm"  [.bitmaps]m-grelb.xbm
+$ call make flag.xbm   "set file/enter=[]flag.xbm [.bitmaps]m-dec.xbm"    [.bitmaps]m-dec.xbm
+$! call make ghost.xbm  "set file/enter=[]ghost.xbm [.bitmaps]m-dec.xbm"   [.bitmaps]m-dec.xbm
+$ call make ghost.xbm  "set file/enter=[]ghost.xbm [.bitmaps]m-ghost.xbm" [.bitmaps]m-ghost.xbm
+$ call make image.xbm  "set file/enter=[]image.xbm [.bitmaps]m-dec.xbm"   [.bitmaps]m-dec.xbm
+$ call make life.xbm   "set file/enter=[]life.xbm [.bitmaps]s-grelb.xbm"  [.bitmaps]s-grelb.xbm
+$! call make life.xbm   "set file/enter=[]life.xbm [.bitmaps]s-dec.xbm"    [.bitmaps]s-dec.xbm
+$ call make life1d.xbm "set file/enter=[]life1d.xbm [.bitmaps]t-x11.xbm"  [.bitmaps]t-x11.xbm
+$ call make maze.xbm   "set file/enter=[]maze.xbm [.bitmaps]l-dec.xbm"    [.bitmaps]l-dec.xbm
+$ call make puzzle.xbm "set file/enter=[]puzzle.xbm [.bitmaps]l-xlock.xbm"  [.bitmaps]l-xlock.xbm
+$ if xpm
+$ then
+$   call make decay.xpm  "set file/enter=[]decay.xpm [.pixmaps]l-xlock.xpm"  [.pixmaps]l-xlock.xpm
+$!   call make decay.xpm "set file/enter=[]decay.xpm [.pixmaps]m-dec.xpm"  [.pixmaps]m-dec.xpm
+$   call make flag.xpm   "set file/enter=[]flag.xpm [.pixmaps]m-dec.xpm"    [.pixaps]m-dec.xpm
+$   call make image.xpm  "set file/enter=[]image.xpm [.pixmaps]m-dec.xpm"   [.pixmaps]m-dec.xpm
+$   call make maze.xpm   "set file/enter=[]maze.xpm [.pixmaps]m-dec.xpm"    [.pixmaps]m-dec.xpm
+$   call make puzzle.xpm "set file/enter=[]puzzle.xpm [.pixmaps]l-xlock.xpm"  [.pixmaps]l-xlock.xpm
+$!   call make puzzle.xpm "set file/enter=[]puzzle.xpm [.pixmaps]m-dec.xpm"  [.pixmaps]m-dec.xpm
+$ endif
+$!
+$ write sys$output "Compiling XLock where cc ="
+$ write sys$output "''cc'"
+$ call make [.xlock]xlock.obj     "cc /object=[.xlock] [.xlock]xlock.c"     [.xlock]xlock.c [.xlock]xlock.h [.xlock]mode.h [.xlock]vroot.h
+$ call make [.xlock]passwd.obj    "cc /object=[.xlock] [.xlock]passwd.c"    [.xlock]passwd.c [.xlock]xlock.h
+$ call make [.xlock]resource.obj  "cc /object=[.xlock] [.xlock]resource.c"  [.xlock]resource.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.xlock]parsecmd.obj  "cc /object=[.xlock] [.xlock]parsecmd.c"  [.xlock]parsecmd.c
+$ call make [.xlock]util.obj      "cc /object=[.xlock] [.xlock]util.c"      [.xlock]util.c [.xlock]xlock.h [.xlock]util.h
+$ call make [.xlock]logout.obj    "cc /object=[.xlock] [.xlock]logout.c"    [.xlock]logout.c [.xlock]xlock.h
+$ call make [.xlock]mode.obj      "cc /object=[.xlock] [.xlock]mode.c"      [.xlock]mode.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.xlock]ras.obj       "cc /object=[.xlock] [.xlock]ras.c"       [.xlock]ras.c [.xlock]xlock.h [.xlock]ras.h
+$ call make [.xlock]xbm.obj       "cc /object=[.xlock] [.xlock]xbm.c"       [.xlock]xbm.c [.xlock]xlock.h
+$ call make [.xlock]vis.obj       "cc /object=[.xlock] [.xlock]vis.c"       [.xlock]vis.c [.xlock]xlock.h [.xlock]vis.h
+$ call make [.xlock]color.obj     "cc /object=[.xlock] [.xlock]color.c"     [.xlock]color.c [.xlock]xlock.h [.xlock]color.h
+$ call make [.xlock]random.obj    "cc /object=[.xlock] [.xlock]random.c"    [.xlock]random.c [.xlock]xlock.h [.xlock]random.h
+$ call make [.xlock]iostuff.obj   "cc /object=[.xlock] [.xlock]iostuff.c"   [.xlock]iostuff.c [.xlock]xlock.h [.xlock]iostuff.h
+$ call make [.xlock]automata.obj  "cc /object=[.xlock] [.xlock]automata.c"  [.xlock]automata.c [.xlock]xlock.h [.xlock]automata.h
+$ call make [.xlock]spline.obj    "cc /object=[.xlock] [.xlock]spline.c"    [.xlock]spline.c [.xlock]xlock.h [.xlock]spline.h
+$ call make [.xlock]erase.obj    "cc /object=[.xlock] [.xlock]erase.c"    [.xlock]erase.c [.xlock]xlock.h [.xlock]erase.h [.xlock]erase_debug.h [.xlock]erase_init.h
+$ if check
+$ then
+$   write sys$output "Compiling XLock Memory Check Caution: Experimental!"
+$   call make [.xlock]memcheck.obj     "cc /object=[.xlock] [.xlock]memcheck.c"     [.xlock]memcheck.c [.xlock]xlock.h
+$ endif
+$ if axp .and. sound
+$ then
+$   call make [.xlock]sound.obj     "cc /object=[.xlock] [.xlock]sound.c"     [.xlock]sound.c [.xlock]xlock.h [.xlock]vms_amd.h
+$   call make [.xlock]vms_amd.obj   "cc /object=[.xlock] [.xlock]vms_amd.c"   [.xlock]vms_amd.c [.xlock]vms_amd.h
+$ else
+$   call make [.xlock]sound.obj     "cc /object=[.xlock] [.xlock]sound.c"     [.xlock]sound.c [.xlock]xlock.h
+$ endif
+$ call make [.modes]ant.obj       "cc /object=[.modes] [.modes]ant.c"       [.modes]ant.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]ball.obj      "cc /object=[.modes] [.modes]ball.c"      [.modes]ball.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]bat.obj       "cc /object=[.modes] [.modes]bat.c"       [.modes]bat.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]blot.obj      "cc /object=[.modes] [.modes]blot.c"      [.modes]blot.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]bouboule.obj  "cc /object=[.modes] [.modes]bouboule.c"  [.modes]bouboule.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]bounce.obj    "cc /object=[.modes] [.modes]bounce.c"    [.modes]bounce.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]braid.obj     "cc /object=[.modes] [.modes]braid.c"     [.modes]braid.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]bubble.obj    "cc /object=[.modes] [.modes]bubble.c"    [.modes]bubble.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]bug.obj       "cc /object=[.modes] [.modes]bug.c"       [.modes]bug.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]clock.obj     "cc /object=[.modes] [.modes]clock.c"     [.modes]clock.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]coral.obj     "cc /object=[.modes] [.modes]coral.c"     [.modes]coral.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]crystal.obj   "cc /object=[.modes] [.modes]crystal.c"   [.modes]crystal.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]daisy.obj     "cc /object=[.modes] [.modes]daisy.c"     [.modes]daisy.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]dclock.obj    "cc /object=[.modes] [.modes]dclock.c"    [.modes]dclock.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]decay.obj     "cc /object=[.modes] [.modes]decay.c"     [.modes]decay.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]deco.obj      "cc /object=[.modes] [.modes]deco.c"      [.modes]deco.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]demon.obj     "cc /object=[.modes] [.modes]demon.c"     [.modes]demon.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]dilemma.obj   "cc /object=[.modes] [.modes]dilemma.c"   [.modes]dilemma.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]discrete.obj  "cc /object=[.modes] [.modes]discrete.c"  [.modes]discrete.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]drift.obj     "cc /object=[.modes] [.modes]drift.c"     [.modes]drift.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]eyes.obj      "cc /object=[.modes] [.modes]eyes.c"      [.modes]eyes.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]fadeplot.obj  "cc /object=[.modes] [.modes]fadeplot.c"  [.modes]fadeplot.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]flag.obj      "cc /object=[.modes] [.modes]flag.c"      [.modes]flag.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]flame.obj     "cc /object=[.modes] [.modes]flame.c"     [.modes]flame.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]flow.obj      "cc /object=[.modes] [.modes]flow.c"      [.modes]flow.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]forest.obj    "cc /object=[.modes] [.modes]forest.c"    [.modes]forest.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]galaxy.obj    "cc /object=[.modes] [.modes]galaxy.c"    [.modes]galaxy.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]goop.obj      "cc /object=[.modes] [.modes]goop.c"      [.modes]goop.c [.xlock]xlock.h [.xlock]mode.h [.xlock]spline.h
+$ call make [.modes]grav.obj      "cc /object=[.modes] [.modes]grav.c"      [.modes]grav.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]helix.obj     "cc /object=[.modes] [.modes]helix.c"     [.modes]helix.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]hop.obj       "cc /object=[.modes] [.modes]hop.c"       [.modes]hop.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]hyper.obj     "cc /object=[.modes] [.modes]hyper.c"     [.modes]hyper.c [.xlock]xlock.h [.xlock]mode.h
+$! call make [.modes]hyperer.obj   "cc /object=[.modes] [.modes]hyperer.c"     [.modes]hyperer.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]ico.obj       "cc /object=[.modes] [.modes]ico.c"       [.modes]ico.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]ifs.obj       "cc /object=[.modes] [.modes]ifs.c"       [.modes]ifs.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]image.obj     "cc /object=[.modes] [.modes]image.c"     [.modes]image.c [.xlock]xlock.h [.xlock]mode.h ras.h
+$ call make [.modes]julia.obj     "cc /object=[.modes] [.modes]julia.c"     [.modes]julia.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]kaleid.obj    "cc /object=[.modes] [.modes]kaleid.c"    [.modes]kaleid.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]kumppa.obj    "cc /object=[.modes] [.modes]kumppa.c"    [.modes]kumppa.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]laser.obj     "cc /object=[.modes] [.modes]laser.c"     [.modes]laser.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]life.obj      "cc /object=[.modes] [.modes]life.c"      [.modes]life.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]life1d.obj    "cc /object=[.modes] [.modes]life1d.c"    [.modes]life1d.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]life3d.obj    "cc /object=[.modes] [.modes]life3d.c"    [.modes]life3d.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]lightning.obj "cc /object=[.modes] [.modes]lightning.c" [.modes]lightning.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]lisa.obj      "cc /object=[.modes] [.modes]lisa.c"      [.modes]lisa.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]lissie.obj    "cc /object=[.modes] [.modes]lissie.c"    [.modes]lissie.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]loop.obj      "cc /object=[.modes] [.modes]loop.c"      [.modes]loop.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]lyapunov.obj  "cc /object=[.modes] [.modes]lyapunov.c"  [.modes]lyapunov.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]mandelbrot.obj "cc /object=[.modes] [.modes]mandelbrot.c" [.modes]mandelbrot.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]marquee.obj   "cc /object=[.modes] [.modes]marquee.c"   [.modes]marquee.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]matrix.obj   "cc /object=[.modes] [.modes]matrix.c"   [.modes]matrix.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]maze.obj      "cc /object=[.modes] [.modes]maze.c"      [.modes]maze.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]mountain.obj  "cc /object=[.modes] [.modes]mountain.c"  [.modes]mountain.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]munch.obj     "cc /object=[.modes] [.modes]munch.c"     [.modes]munch.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]nose.obj      "cc /object=[.modes] [.modes]nose.c"      [.modes]nose.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]qix.obj       "cc /object=[.modes] [.modes]qix.c"       [.modes]qix.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]pacman.obj    "cc /object=[.modes] [.modes]pacman.c"    [.modes]pacman.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]penrose.obj   "cc /object=[.modes] [.modes]penrose.c"   [.modes]penrose.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]petal.obj     "cc /object=[.modes] [.modes]petal.c"     [.modes]petal.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]puzzle.obj    "cc /object=[.modes] [.modes]puzzle.c"    [.modes]puzzle.c [.xlock]xlock.h [.xlock]mode.h ras.h
+$ call make [.modes]pyro.obj      "cc /object=[.modes] [.modes]pyro.c"      [.modes]pyro.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]roll.obj      "cc /object=[.modes] [.modes]roll.c"      [.modes]roll.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]rotor.obj     "cc /object=[.modes] [.modes]rotor.c"     [.modes]rotor.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]shape.obj     "cc /object=[.modes] [.modes]shape.c"     [.modes]shape.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]sierpinski.obj "cc /object=[.modes] [.modes]sierpinski.c" [.modes]sierpinski.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]slip.obj      "cc /object=[.modes] [.modes]slip.c"      [.modes]slip.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]sphere.obj    "cc /object=[.modes] [.modes]sphere.c"    [.modes]sphere.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]spiral.obj    "cc /object=[.modes] [.modes]spiral.c"    [.modes]spiral.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]spline.obj    "cc /object=[.modes] [.modes]spline.c"    [.modes]spline.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]star.obj      "cc /object=[.modes] [.modes]star.c"      [.modes]star.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]starfish.obj  "cc /object=[.modes] [.modes]starfish.c"  [.modes]starfish.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]strange.obj   "cc /object=[.modes] [.modes]strange.c"   [.modes]strange.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]swarm.obj     "cc /object=[.modes] [.modes]swarm.c"     [.modes]swarm.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]swirl.obj     "cc /object=[.modes] [.modes]swirl.c"     [.modes]swirl.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes]tetris.obj     "cc /object=[.modes] [.modes]tetris.c"     [.modes]tetris.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]thornbird.obj "cc /object=[.modes] [.modes]thornbird.c"  [.modes]thornbird.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]triangle.obj  "cc /object=[.modes] [.modes]triangle.c"  [.modes]triangle.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]tube.obj      "cc /object=[.modes] [.modes]tube.c"      [.modes]tube.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]turtle.obj    "cc /object=[.modes] [.modes]turtle.c"    [.modes]turtle.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]vines.obj     "cc /object=[.modes] [.modes]vines.c"     [.modes]vines.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]voters.obj    "cc /object=[.modes] [.modes]voters.c"    [.modes]voters.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]wator.obj     "cc /object=[.modes] [.modes]wator.c"     [.modes]wator.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]wire.obj      "cc /object=[.modes] [.modes]wire.c"      [.modes]wire.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]world.obj     "cc /object=[.modes] [.modes]world.c"     [.modes]world.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]worm.obj      "cc /object=[.modes] [.modes]worm.c"      [.modes]worm.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes]xjack.obj     "cc /object=[.modes] [.modes]xjack.c"     [.modes]xjack.c [.xlock]xlock.h [.xlock]mode.h
+$ if unstable
+$ then
+$   call make [.modes]space.obj     "cc /object=[.modes] [.modes]space.c"     [.modes]space.c [.xlock]xlock.h [.xlock]mode.h
+$ endif
+$ if xpm 
+$ then
+$   call make [.modes]cartoon.obj   "cc /object=[.modes] [.modes]cartoon.c"   [.modes]cartoon.c [.xlock]xlock.h [.xlock]mode.h
+$ endif
+$ if gl
+$ then
+$   call make [.modes.glx]cage.obj    "cc /object=[.modes.glx] [.modes.glx]cage.c"    [.modes.glx]cage.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]gears.obj     "cc /object=[.modes.glx] [.modes.glx]gears.c"     [.modes.glx]gears.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]moebius.obj    "cc /object=[.modes.glx] [.modes.glx]moebius.c"    [.modes.glx]moebius.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]morph3d.obj   "cc /object=[.modes.glx] [.modes.glx]morph3d.c"   [.modes.glx]morph3d.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]rubik.obj     "cc /object=[.modes.glx] [.modes.glx]rubik.c"     [.modes.glx]rubik.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]stairs.obj    "cc /object=[.modes.glx] [.modes.glx]stairs.c" [.modes.glx]stairs.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]superquadrics.obj "cc /object=[.modes.glx] [.modes.glx]superquadrics.c" [.modes.glx]superquadrics.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]buildlwo.obj  "cc /object=[.modes.glx] [.modes.glx]buildlwo.c"  [.modes.glx]buildlwo.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]pipes.obj     "cc /object=[.modes.glx] [.modes.glx]pipes.c"     [.modes.glx]pipes.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]pipeobjs.obj  "cc /object=[.modes.glx] [.modes.glx]pipeobjs.c"  [.modes.glx]pipeobjs.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]sproingies.obj "cc /object=[.modes.glx] [.modes.glx]sproingies.c" [.modes.glx]sproingies.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]sproingiewrap.obj "cc /object=[.modes.glx] [.modes.glx]sproingiewrap.c" [.modes.glx]sproingiewrap.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]s1_b.obj      "cc /object=[.modes.glx] [.modes.glx]s1_b.c"      [.modes.glx]s1_b.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]s1_1.obj      "cc /object=[.modes.glx] [.modes.glx]s1_1.c"      [.modes.glx]s1_1.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]s1_2.obj      "cc /object=[.modes.glx] [.modes.glx]s1_2.c"      [.modes.glx]s1_2.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]s1_3.obj      "cc /object=[.modes.glx] [.modes.glx]s1_3.c"      [.modes.glx]s1_3.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]s1_4.obj      "cc /object=[.modes.glx] [.modes.glx]s1_4.c"      [.modes.glx]s1_4.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]s1_5.obj      "cc /object=[.modes.glx] [.modes.glx]s1_5.c"      [.modes.glx]s1_5.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]s1_6.obj      "cc /object=[.modes.glx] [.modes.glx]s1_6.c"      [.modes.glx]s1_6.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]atlantis.obj  "cc /object=[.modes.glx] [.modes.glx]atlantis.c"  [.modes.glx]atlantis.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]dolphin.obj   "cc /object=[.modes.glx] [.modes.glx]dolphin.c"   [.modes.glx]dolphin.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]shark.obj     "cc /object=[.modes.glx] [.modes.glx]shark.c"     [.modes.glx]shark.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]swim.obj      "cc /object=[.modes.glx] [.modes.glx]swim.c"      [.modes.glx]swim.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]whale.obj     "cc /object=[.modes.glx] [.modes.glx]whale.c"     [.modes.glx]whale.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]bubble3d.obj "cc /object=[.modes.glx] [.modes.glx]bubble3d.c"     [.modes.glx]bubble3d.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]b_draw.obj "cc /object=[.modes.glx] [.modes.glx]b_draw.c"     [.modes.glx]b_draw.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]b_lockglue.obj "cc /object=[.modes.glx] [.modes.glx]b_lockglue.c"     [.modes.glx]b_lockglue.c [.xlock]xlock.h [.xlock]mode.h
+$   call make [.modes.glx]b_sphere.obj "cc /object=[.modes.glx] [.modes.glx]b_sphere.c"     [.modes.glx]b_sphere.c [.xlock]xlock.h [.xlock]mode.h
+$   if unstable .and. xpm
+$   then
+$     call make [.modes.glx]lament.obj "cc /object=[.modes.glx] [.modes.glx]lament.c"     [.modes.glx]lament.c [.xlock]xlock.h [.xlock]mode.h
+$   endif
+$   if iscxx
+$   then
+$     call make [.modes.glx]invert.obj  "cc /object=[.modes.glx] [.modes.glx]invert.c"  [.modes.glx]invert.c [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_figureeight.obj  "cxx /object=[.modes.glx] [.modes.glx]i_figureeight.cc"  [.modes.glx]i_figureeight.cc [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_linkage.obj  "cxx /object=[.modes.glx] [.modes.glx]i_linkage.cc"  [.modes.glx]i_linkage.cc [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_sphere.obj  "cxx /object=[.modes.glx] [.modes.glx]i_sphere.cc"  [.modes.glx]i_sphere.cc [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_spline.obj  "cxx /object=[.modes.glx] [.modes.glx]i_spline.cc"  [.modes.glx]i_spline.cc [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_threejet.obj  "cxx /object=[.modes.glx] [.modes.glx]i_threejet.cc"  [.modes.glx]i_threejet.cc [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_threejetvec.obj  "cxx /object=[.modes.glx] [.modes.glx]i_threejetvec.cc"  [.modes.glx]i_threejetvec.cc [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_twojet.obj  "cxx /object=[.modes.glx] [.modes.glx]i_twojet.cc"  [.modes.glx]i_twojet.cc [.xlock]xlock.h [.xlock]mode.h
+$     call make [.modes.glx]i_twojetvec.obj  "cxx /object=[.modes.glx] [.modes.glx]i_twojetvec.cc"  [.modes.glx]i_twojetvec.cc [.xlock]xlock.h [.xlock]mode.h
+$     if ttf .and. gltt
+$     then
+$       call make [.modes.glx]text3d.obj  "cxx /object=[.modes.glx] [.modes.glx]text3d.cc"  [.modes.glx]text3d.cc [.xlock]xlock.h [.xlock]mode.h
+$     endif
+$   endif
+$ endif
+$ if bomb
+$ then
+$   call make [.modes]bomb.obj      "cc /object=[.modes] [.modes]bomb.c"      [.modes]bomb.c [.xlock]xlock.h [.xlock]mode.h
+$ endif
+$ call make [.modes]blank.obj     "cc /object=[.modes] [.modes]blank.c"     [.modes][.modes]blank.c [.xlock]xlock.h [.xlock]mode.h
+$ call make [.modes]random.obj    "cc /object=[.modes] [.modes]random.c"    [.modes]random.c [.xlock]xlock.h [.xlock]mode.h
+$!
+$! Get libraries
+$ if gltt then write optf "''glttf'/lib"
+$ if ttf then write optf "''ttff'/lib"
+$ if xpm then write optf "''xpmf'/lib"
+$ if gl then write optf "''glf'/lib"
+$ if glu then write optf "''gluf'/lib"
+$ if sys_maj .lt. 7
+$ then
+$   if xvmsutils then write optf "''xvmsutilsf'/lib"
+$ endif
+$! if .not. axp then write optf "sys$library:vaxcrtl/lib"
+$ write optf "sys$library:vaxcrtl/lib"
+$ if dtsaver then write optf "sys$library:cde$libdtsvc.exe/share"
+$ if axp then write optf "sys$library:ucx$ipc_shr/share"
+$ if axp then write optf "sys$share:decw$xextlibshr/share"
+$ if axp then write optf "sys$share:decw$xtlibshrr5/share"
+$ if .not. axp then write optf "sys$library:ucx$ipc/lib"
+$ write optf "sys$share:decw$dxmlibshr/share"
+$ write optf "sys$share:decw$xlibshr/share"
+$ close optf
+$!
+$! LINK
+$ write sys$output "Linking XLock"
+$ link/map/exec=[.xlock] xlock/opt
+$!
+$! Create .opt file
+$ open/write optf xmlock.opt
+$ write sys$output "Compiling XmLock where cc ="
+$ write sys$output "''cc'"
+$ call make [.xmlock]option.obj "cc /object=[.xmlock] [.xmlock]option.c" option.c
+$ call make [.xmlock]xmlock.obj "cc /object=[.xmlock] [.xmlock]xmlock.c" xmlock.c
+$! Get libraries
+$! if .not. axp then write optf "sys$library:vaxcrtl/lib"
+$ write optf "sys$library:vaxcrtl/lib"
+$ if axp then write optf "sys$library:ucx$ipc_shr/share"
+$ if axp then write optf "sys$share:decw$xextlibshr/share"
+$ if axp then write optf "sys$share:decw$xtlibshrr5/share"
+$ if .not. axp then write optf "sys$library:ucx$ipc/lib"
+$! write optf "sys$share:decw$dxmlibshr/share"
+$ write optf "sys$share:decw$xmlibshr12/share"
+$ write optf "sys$share:decw$xlibshr/share"
+$ close optf
+$!
+$! LINK
+$ write sys$output "Linking XmLock"
+$ link/map/exec=[.xmlock] xmlock/opt
+$!
+$ set noverify
+$ exit
+$!
+$Clobber:      ! Delete executables, Purge directory and clean up object files
+$!                and listings
+$ delete/noconfirm [.xlock]xlock.exe;*
+$ delete/noconfirm [.xmlock]xmlock.exe;*
+$!
+$Clean:        ! Purge directory, clean up object files and listings
+$ close/nolog optf
+$ purge [...]
+$ delete/noconfirm [...]*.lis;*
+$ delete/noconfirm [...]*.obj;*
+$ delete/noconfirm [...]*.opt;*
+$ delete/noconfirm [...]*.map;*
+$ set file/remove decay.xbm;*
+$ set file/remove eyes.xbm;*
+$ set file/remove flag.xbm;*
+$ set file/remove image.xbm;*
+$ set file/remove ghost.xbm;*
+$ set file/remove life.xbm;*
+$ set file/remove life1d.xbm;*
+$ set file/remove maze.xbm;*
+$ set file/remove puzzle.xbm;*
+$ set file/remove decay.xpm;*
+$ set file/remove flag.xpm;*
+$ set file/remove image.xpm;*
+$ set file/remove maze.xpm;*
+$ set file/remove puzzle.xpm;*
+$!
+$ exit
+$!
+! SUBROUTINE TO CHECK DEPENDENCIES
+$ make: subroutine
+$   v='f$verify(0)
+$!   p1       What we are trying to make
+$!   p2       Command to make it
+$!   p3 - p8  What it depends on
+$
+$   if (f$extract(0,3,p2) .eqs. "cc ") then write optf "''p1'"
+$   if (f$extract(0,4,p2) .eqs. "cxx ") then write optf "''p1'"
+$
+$   if f$search(p1) .eqs. "" then goto MakeIt
+$   time=f$cvtime(f$file(p1,"RDT"))
+$   arg=3
+$Loop:
+$   argument=p'arg
+$   if argument .eqs. "" then goto Exit
+$   el=0
+$Loop2:
+$   file=f$element(el," ",argument)
+$   if file .eqs. " " then goto Endl
+$   afile=""
+$Loop3:
+$   ofile=afile
+$   afile=f$search(file)
+$   if afile .eqs. "" .or. afile .eqs. ofile then goto NextEl
+$   if f$cvtime(f$file(afile,"RDT")) .gts. time then goto MakeIt
+$   goto Loop3
+$NextEL:
+$   el=el+1
+$   goto Loop2
+$EndL:
+$   arg=arg+1
+$   if arg .le. 8 then goto Loop
+$   goto Exit
+$
+$MakeIt:
+$   set verify
+$   'p2
+$   vv='f$verify(0)
+$Exit:
+$   if v then set verify
+$ endsubroutine
diff --git a/xlockmore-4.14/mkinstalldirs b/xlockmore-4.14/mkinstalldirs
new file mode 100755 (executable)
index 0000000..5e1a43e
--- /dev/null
@@ -0,0 +1,30 @@
+#! /bin/sh
+# mkinstalldirs --- make directory hierarchy
+# Author: Noah Friedman <friedman@prep.ai.mit.edu>
+# Created: 1993-05-16
+# Public domain
+
+errstatus=0
+
+for file
+do
+   set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
+   shift
+
+   pathcomp=
+   for d in ${1+"$@"} ; do
+     pathcomp="$pathcomp$d"
+     case "$pathcomp" in
+       -* ) pathcomp=./$pathcomp ;;
+     esac
+
+     if test ! -d "$pathcomp"; then
+        echo "mkdir $pathcomp" 1>&2
+        mkdir "$pathcomp" || errstatus=$?
+     fi
+
+     pathcomp="$pathcomp/"
+   done
+done
+
+exit $errstatus
diff --git a/xlockmore-4.14/modes/Imakefile b/xlockmore-4.14/modes/Imakefile
new file mode 100644 (file)
index 0000000..3c58bdf
--- /dev/null
@@ -0,0 +1,330 @@
+#ifndef XCOMM
+#define XCOMM /**/#
+#endif
+XCOMM @(#)Sub Imakefile        xlockmore
+XCOMM
+
+#include "../iconfig.h"
+
+top_srcdir = ..
+BITMAPDIR = $(top_srcdir)/bitmaps/
+PIXMAPDIR = $(top_srcdir)/pixmaps/
+UTILDIR = ../xlock/
+GLDIR = glx/
+UTILOBJDIR = ../xlock/
+GLOBJDIR = glx/
+
+DM =
+DOM =
+DU = $(UTILDIR)
+DOU = $(UTILOBJDIR)
+DG = $(GLDIR)
+DOG = $(GLOBJDIR)
+OM = $(O)$(S)$(DOM)
+OU = $(O)$(S)$(DOU)
+OG = $(O)$(S)$(DOG)
+CM = $(C) $(DM)
+CU = $(C) $(DU)
+CG = $(C) $(DG)
+
+XCOMM  please define
+XCOMM  C as the C source code extension
+XCOMM  O as the object extension
+XCOMM  S as the separator for object code
+
+XCOMM Here is your chance to override the default icon:
+XCOMM TINYBITMAP = $(BITMAPTYPE)
+TINYBITMAP = t-x11
+SMALLBITMAP = s-$(BITMAPTYPE)
+MEDIUMBITMAP = m-$(BITMAPTYPE)
+LARGEBITMAP = l-$(BITMAPTYPE)
+MEDIUMPIXMAP = m-$(PIXMAPTYPE)
+LARGEPIXMAP = l-$(PIXMAPTYPE)
+
+XCOMM DECAYBITMAP = $(LARGEBITMAP)
+DECAYBITMAP = l-xlock
+XCOMM DECAYBITMAP = l-linux
+XCOMM EYESBITMAP = $(MEDIUMBITMAP)
+EYESBITMAP = m-grelb
+FLAGBITMAP = $(MEDIUMBITMAP)
+IMAGEBITMAP = $(MEDIUMBITMAP)
+XCOMM IMAGEBITMAP = l-bob #Slackware icon
+XCOMM IMAGEBITMAP = m-xlock #XLock icon
+XCOMM LIFEBITMAP = $(SMALLBITMAP)
+LIFEBITMAP = s-grelb
+LIFE1DBITMAP = $(TINYBITMAP)
+MAZEBITMAP = $(LARGEBITMAP)
+XCOMM MAZEBITMAP = m-xlock
+XCOMM PACMANBITMAP = $(MEDIUMBITMAP)
+PACMANBITMAP = m-ghost
+XCOMM PUZZLEBITMAP = $(LARGEBITMAP)
+PUZZLEBITMAP = l-xlock
+XCOMM PUZZLEBITMAP = l-linux
+XCOMM DECAYPIXMAP = $(LARGEPIXMAP)
+DECAYPIXMAP = l-xlock
+XCOMM DECAYPIXMAP = l-linux
+FLAGPIXMAP = $(MEDIUMPIXMAP)
+XCOMM FLAGPIXMAP = m-xlock
+IMAGEPIXMAP = $(MEDIUMPIXMAP)
+XCOMM IMAGEPIXMAP = m-xlock
+MAZEPIXMAP = $(MEDIUMPIXMAP)
+XCOMM MAZEPIXMAP = m-xlock
+XCOMM PUZZLEPIXMAP = $(LARGEPIXMAP)
+PUZZLEPIXMAP = l-xlock
+XCOMM PUZZLEPIXMAP = l-linux
+
+XCOMM  List of object files
+XLOCKUTILOBJS = $(DOU)xlock$(OU)passwd$(OU)resource$(OU)parsecmd$(O)$(S)\
+$(DOU)util$(OU)logout$(OU)mode$(OU)ras$(OU)xbm$(O)$(S)\
+$(DOU)vis$(OU)color$(OU)random$(OU)iostuff$(OU)automata$(O)$(S)\
+$(DOU)spline$(OU)erase$(OU)sound$(O)$(S)\
+$(DOU)vtlock$(O)
+#ifdef Check 
+XLOCKCHECKOBJS = $(S)memcheck$(O)
+#endif
+#ifdef Unstable
+XLOCKUNSTABLEOBJS = $(DOM)space$(O)
+#endif
+XLOCKMODEOBJS = $(DOM)ant$(OM)ball$(OM)bat$(OM)blot$(OM)\
+bouboule$(OM)bounce$(OM)braid$(OM)bubble$(OM)bug$(OM)\
+clock$(OM)coral$(OM)crystal$(OM)\
+daisy$(OM)dclock$(OM)decay$(OM)deco$(OM)demon$(OM)\
+dilemma$(OM)discrete$(OM)drift$(OM)eyes$(OM)\
+fadeplot$(OM)flag$(OM)flame$(OM)flow$(OM)forest$(OM)\
+galaxy$(OM)goop$(OM)grav$(OM)\
+helix$(OM)hop$(OM)hyper$(OM)\
+ico$(OM)ifs$(OM)image$(OM)julia$(OM)kaleid$(OM)kumppa$(OM)\
+laser$(OM)life$(OM)life1d$(OM)life3d$(OM)\
+lightning$(OM)lisa$(OM)lissie$(OM)loop$(OM)lyapunov$(OM)\
+mandelbrot$(OM)marquee$(OM)matrix$(OM)maze$(OM)\
+mountain$(OM)munch$(OM)nose$(OM)\
+pacman$(OM)penrose$(OM)petal$(OM)puzzle$(OM)pyro$(OM)\
+qix$(OM)roll$(OM)rotor$(OM)\
+shape$(OM)sierpinski$(OM)slip$(OM)\
+sphere$(OM)spiral$(OM)spline$(OM)\
+star$(OM)starfish$(OM)strange$(OM)swarm$(OM)swirl$(OM)\
+tetris$(OM)thornbird$(OM)triangle$(OM)tube$(OM)turtle$(OM)\
+vines$(OM)voters$(OM)\
+wator$(OM)wire$(OM)world$(OM)worm$(OM)xjack$(OM)\
+$(XLOCKUNSTABLEOBJS)
+#ifdef XpmLibrary
+XLOCKXPMOBJS = $(DOM)cartoon$(O)
+#endif
+#ifdef GLLibrary
+#ifdef XpmLibrary
+#ifdef Unstable
+XLOCKUNSTABLEGLOBJS = $(DOG)lament$(O)
+#endif
+#endif
+XLOCKGLOBJS = $(DOG)cage$(OG)gears$(O)$(S)\
+$(DOG)moebius$(OG)morph3d$(O)$(S)\
+$(DOG)rubik$(OG)stairs$(OG)superquadrics$(O)$(S)\
+$(DOG)buildlwo$(OG)pipes$(OG)pipeobjs$(O)$(S)\
+$(DOG)sproingies$(OG)sproingiewrap$(OG)s1_b$(O)$(S)\
+$(DOG)s1_1$(OG)s1_2$(OG)s1_3$(OG)s1_4$(OG)s1_5$(OG)s1_6$(O)$(S)\
+$(DOG)atlantis$(OG)dolphin$(OG)shark$(OG)swim$(OG)whale$(O)$(S)\
+$(DOG)bubble3d$(OG)b_draw$(OG)b_sphere$(OG)b_lockglue$(O)$(S)\
+$(XLOCKUNSTABLEGLOBJS)
+#endif
+#if 1
+XLOCKBOMBOBJS = $(DOM)bomb$(O)
+#endif
+XLOCKUTILMODEOBJS = $(XLOCKBOMBOBJS)$(S)$(DOM)blank$(OM)random$(O)
+XLOCKALLMODEOBJS = $(XLOCKMODEOBJS)$(S)\
+$(XLOCKXPMOBJS)$(S)$(XLOCKGLOBJS)$(S)$(XLOCKUTILMODEOBJS)
+XLOCKALLUTILOBJS = $(XLOCKUTILOBJS)$(XLOCKCHECKOBJS)
+XLOCKOBJS = $(XLOCKALLUTILOBJS)$(S)$(XLOCKALLMODEOBJS)
+
+XCOMM  List of source files
+BITMAPS = eyes.xbm flag.xbm ghost.xbm image.xbm life.xbm life1d.xbm \
+maze.xbm puzzle.xbm
+PIXMAPS = flag.xpm image.xpm maze.xpm puzzle.xpm
+XLOCKUTILHDRS = xlock.h mode.h vroot.h ras.h spline.h version.h config.h
+XLOCKUTILSRCS = $(DU)xlock$(CU)passwd$(CU)resource$(CU)parsecmd$(C) \
+$(DU)vis$(CU)color$(CU)random$(CU)iostuff$(CU)automata$(C) \
+$(DU)spline$(CU)sound$(C)
+XLOCKCHECKSRCS = $(DU)memcheck$(C)
+XLOCKMODESRCS = $(DM)ant$(CM)ball$(CM)bat$(CM)blot$(C) \
+$(DM)bouboule$(CM)bounce$(CM)braid$(CM)bubble$(CM)bug$(C) \
+$(DM)clock$(CM)coral$(CM)crystal$(C) \
+$(DM)daisy$(CM)dclock$(CM)decay$(CM)deco$(CM)demon$(C) \
+$(DM)dilemma$(CM)discrete$(OM)drift$(C) \
+$(DM)eyes$(CM)fadeplot$(CM)flag$(CM)flame$(CM)flow$(CM)forest$(C) \
+$(DM)galaxy$(CM)goop$(CM)grav$(C) \
+$(DM)helix$(CM)hop$(CM)hyper$(C) \
+$(DM)ico$(CM)ifs$(CM)image$(CM)julia$(CM)kaleid$(CM)kumppa$(C) \
+$(DM)laser$(CM)life$(CM)life1d$(CM)life3d$(C) \
+$(DM)lightning$(CM)lisa$(CM)lissie$(CM)loop$(CM)lyapunov$(C) \
+$(DM)mandelbrot$(CM)marquee$(CM)matrix$(CM)maze$(C) \
+$(DM)mountain$(CM)munch$(CM)nose$(C) \
+$(DM)pacman$(CM)penrose$(CM)petal$(CM)puzzle$(CM)pyro$(C) \
+$(DM)qix$(CM)roll$(CM)rotor$(C) \
+$(DM)shape$(CM)sierpinski$(CM)slip$(C) \
+$(DM)space$(CM)sphere$(CM)spiral$(CM)spline$(C) \
+$(DM)star$(CM)starfish$(CM)strange$(CM)swarm$(CM)swirl$(C) \
+$(DM)tetris$(CM)thornbird$(CM)triangle$(CM)tube$(CM)turtle$(C) \
+$(DM)vines$(CM)voters$(C) \
+$(DM)wator$(CM)wire$(CM)world$(CM)worm$(CM)xjack$(C)
+XLOCKXPMSRCS = $(DM)cartoon$(C)
+XLOCKGLSRCS = $(DG)cage$(CG)gears$(C) \
+$(DG)lament$(CG)moebius$(CG)morph3d$(C) \
+$(DG)rubik$(CG)stairs$(CG)superquadrics$(C) \
+$(DG)buildlwo$(CG)pipes$(CG)pipeobjs$(C) \
+$(DG)sproingies$(CG)sproingiewrap$(CG)s1_b$(C) \
+$(DG)s1_1$(CG)s1_2$(CG)s1_3$(CG)s1_4$(CG)s1_5$(CG)s1_6$(C) \
+$(DG)atlantis$(CG)dolphin$(CG)shark$(CG)swim$(CG)whale$(C) \
+$(DG)bubble3d$(CG)b_draw$(CG)b_sphere$(CG)b_lockglue$(C)
+XLOCKBOMBSRCS = $(DM)bomb$(C)
+XLOCKUTILMODESRCS = $(XLOCKBOMBSRCS) $(DM)blank$(CM)random$(C)
+XLOCKSRCS = $(XLOCKUTILSRCS) $(XLOCKCHECKSRCS) $(XLOCKXPMSRCS) $(XLOCKGLSRCS) \
+$(XLOCKMODESRCS) $(XLOCKUTILMODESRCS)
+
+AllTarget($(UTILDIR)xlock)
+#ifdef XpmLibrary
+depend:: $(BITMAPS) $(PIXMAPS)
+#else
+depend:: $(BITMAPS)
+#endif
+
+MODULES = $(XLOCKALLMODEOBJS:.o=.xlk)
+
+#ifndef Modules
+
+NormalProgramTarget($(UTILDIR)xlock, $(XLOCKOBJS), $(DEPXLIB), $(LOCAL_LIBRARIES), NullParameter)
+
+#else
+
+EXTRA_LDOPTIONS += $(MODULEFLAGS)
+AllTarget($(MODULES) $(UTILDIR)xlock)
+
+NormalProgramTarget($(UTILDIR)xlock, $(XLOCKOBJS), $(DEPXLIB), $(LOCAL_LIBRARIES), NullParameter)
+
+InstallMultiple($(MODULES), $(DEF_MODULEPATH))
+
+$(XLOCKALLMODEOBJS) : %.o:%.c
+       NormalSharedLibObjCompile()
+
+$(MODULES) : %.xlk:%.o
+       $(RM) $@
+       $(CCLINK) $(CFLAGS) $(SHLIBLDFLAGS) -o $@ $<
+
+clean::
+       $(RM) $(MODULES)
+#endif
+
+DependTarget()
+LintTarget()
+
+decay$(O) : decay$(C) decay.xbm decay.xpm
+eyes$(O) : eyes$(C) eyes.xbm
+life$(O) : life$(C) life.xbm
+life1d$(O) : life1d$(C) life1d.xbm
+pacman$(O) : pacman$(C) ghost.xbm
+# Do not need xpm files if not using them but not worth figuring out
+flag$(O) : flag$(C) flag.xbm flag.xpm
+image$(O) : image$(C) image.xbm image.xpm
+maze$(O) : maze$(C) maze.xbm maze.xpm
+puzzle$(O) : puzzle$(C) puzzle.xbm puzzle.xpm
+
+decay.xbm : $(BITMAPDIR)$(DECAYBITMAP).xbm
+       $(RM) decay.xbm ; $(LN_S) $(BITMAPDIR)$(DECAYBITMAP).xbm decay.xbm
+
+eyes.xbm : $(BITMAPDIR)$(EYESBITMAP).xbm
+       $(RM) eyes.xbm ; $(LN_S) $(BITMAPDIR)$(EYESBITMAP).xbm eyes.xbm
+
+flag.xbm : $(BITMAPDIR)$(FLAGBITMAP).xbm
+       $(RM) flag.xbm ; $(LN_S) $(BITMAPDIR)$(FLAGBITMAP).xbm flag.xbm
+
+image.xbm : $(BITMAPDIR)$(IMAGEBITMAP).xbm
+       $(RM) image.xbm ; $(LN_S) $(BITMAPDIR)$(IMAGEBITMAP).xbm image.xbm
+
+ghost.xbm : $(BITMAPDIR)$(PACMANBITMAP).xbm
+       $(RM) ghost.xbm ; $(LN_S) $(BITMAPDIR)$(PACMANBITMAP).xbm ghost.xbm
+
+life.xbm : $(BITMAPDIR)$(LIFEBITMAP).xbm
+       $(RM) life.xbm ; $(LN_S) $(BITMAPDIR)$(LIFEBITMAP).xbm life.xbm
+
+life1d.xbm : $(BITMAPDIR)$(LIFE1DBITMAP).xbm
+       $(RM) life1d.xbm ; $(LN_S) $(BITMAPDIR)$(LIFE1DBITMAP).xbm life1d.xbm
+
+maze.xbm : $(BITMAPDIR)$(MAZEBITMAP).xbm
+       $(RM) maze.xbm ; $(LN_S) $(BITMAPDIR)$(MAZEBITMAP).xbm maze.xbm
+
+puzzle.xbm : $(BITMAPDIR)$(PUZZLEBITMAP).xbm
+       $(RM) puzzle.xbm ; $(LN_S) $(BITMAPDIR)$(PUZZLEBITMAP).xbm puzzle.xbm
+
+flag.xpm : $(PIXMAPDIR)$(FLAGPIXMAP).xpm
+       $(RM) flag.xpm ; $(LN_S) $(PIXMAPDIR)$(FLAGPIXMAP).xpm flag.xpm
+
+image.xpm : $(PIXMAPDIR)$(IMAGEPIXMAP).xpm
+       $(RM) image.xpm ; $(LN_S) $(PIXMAPDIR)$(IMAGEPIXMAP).xpm image.xpm
+
+maze.xpm : $(PIXMAPDIR)$(MAZEPIXMAP).xpm
+       $(RM) maze.xpm ; $(LN_S) $(PIXMAPDIR)$(MAZEPIXMAP).xpm maze.xpm
+
+puzzle.xpm : $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm
+       $(RM) puzzle.xpm ; $(LN_S) $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm puzzle.xpm
+
+$(UTILOBJDIR)xlock.o : $(UTILDIR)xlock.c
+$(UTILOBJDIR)passwd.o : $(UTILDIR)passwd.c
+$(UTILOBJDIR)resource.o : $(UTILDIR)resource.c
+$(UTILOBJDIR)util.o : $(UTILDIR)util.c
+$(UTILOBJDIR)logout.o : $(UTILDIR)logout.c
+$(UTILOBJDIR)mode.o : $(UTILDIR)mode.c
+$(UTILOBJDIR)ras.o : $(UTILDIR)ras.c
+$(UTILOBJDIR)xbm.o : $(UTILDIR)xbm.c
+$(UTILOBJDIR)vis.o : $(UTILDIR)vis.c
+$(UTILOBJDIR)color.o : $(UTILDIR)color.c
+$(UTILOBJDIR)random.o : $(UTILDIR)random.c
+$(UTILOBJDIR)iostuff.o : $(UTILDIR)iostuff.c
+$(UTILOBJDIR)automata.o : $(UTILDIR)automata.c
+$(UTILOBJDIR)spline.o : $(UTILDIR)spline.c
+$(UTILOBJDIR)sound.o : $(UTILDIR)sound.c
+$(UTILOBJDIR)vtlock.o : $(UTILDIR)vtlock.c
+$(UTILOBJDIR)memcheck.o : $(UTILDIR)memcheck.c
+
+$(XLOCKUTILOBJS) :
+       cd $(UTILOBJDIR) ; \
+$(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+
+$(GLOBJDIR)cage.o : $(GLDIR)cage.c
+$(GLOBJDIR)gears.o : $(GLDIR)gears.c
+$(GLOBJDIR)lament.o : $(GLDIR)lament.c
+$(GLOBJDIR)moebius.o : $(GLDIR)moebius.c
+$(GLOBJDIR)morph3d.o : $(GLDIR)morph3d.c
+$(GLOBJDIR)rubik.o : $(GLDIR)rubik.c
+$(GLOBJDIR)stairs.o : $(GLDIR)stairs.c
+$(GLOBJDIR)superquadrics.o : $(GLDIR)superquadrics.c
+$(GLOBJDIR)buildlwo.o : $(GLDIR)buildlwo.c
+$(GLOBJDIR)pipes.o : $(GLDIR)pipes.c
+$(GLOBJDIR)pipeobjs.o : $(GLDIR)pipeobjs.c
+$(GLOBJDIR)sproingies.o : $(GLDIR)sproingies.c
+$(GLOBJDIR)sproingiewrap.o : $(GLDIR)sproingiewrap.c
+$(GLOBJDIR)s1_b.o : $(GLDIR)s1_b.c
+$(GLOBJDIR)s1_1.o : $(GLDIR)s1_1.c
+$(GLOBJDIR)s1_2.o : $(GLDIR)s1_2.c
+$(GLOBJDIR)s1_3.o : $(GLDIR)s1_3.c
+$(GLOBJDIR)s1_4.o : $(GLDIR)s1_4.c
+$(GLOBJDIR)s1_5.o : $(GLDIR)s1_5.c
+$(GLOBJDIR)s1_6.o : $(GLDIR)s1_6.c
+$(GLOBJDIR)atlantis.o : $(GLDIR)atlantis.c
+$(GLOBJDIR)swim.o : $(GLDIR)swim.c
+$(GLOBJDIR)dolphin.o : $(GLDIR)dolphin.c
+$(GLOBJDIR)shark.o : $(GLDIR)shark.c
+$(GLOBJDIR)whale.o : $(GLDIR)whale.c
+$(GLOBJDIR)bubble3d.o : $(GLDIR)bubble3d.c
+$(GLOBJDIR)b_draw.o : $(GLDIR)b_draw.c
+$(GLOBJDIR)b_sphere.o : $(GLDIR)b_sphere.c
+$(GLOBJDIR)b_lockglue.o : $(GLDIR)b_lockglue.c
+
+$(XLOCKGLOBJS) :
+       cd $(GLDIR) ; \
+$(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+
+XLOCKINC = -I$(top_srcdir) -I. -I$(UTILDIR) -I../$(UTILDIR)
+
+distclean:: clean
+       $(RM) Makefile $(BITMAPS) $(PIXMAPS) \
+config.status config.cache config.log config.h
+
+clean.all:: distclean
diff --git a/xlockmore-4.14/modes/Makefile.in b/xlockmore-4.14/modes/Makefile.in
new file mode 100644 (file)
index 0000000..4559632
--- /dev/null
@@ -0,0 +1,1276 @@
+# $Id : Makefile.in 4.04 1997/07/10 $
+#
+# xlockmore Makefile.in for autoconf (UNIX/VMS X11 support)
+############################################################
+
+# @SET_MAKE@
+
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@/
+BITMAPDIR = @BITMAPDIR@/
+PIXMAPDIR = @PIXMAPDIR@/
+UTILDIR = $(top_srcdir)/xlock/
+GLDIR = $(top_srcdir)/modes/glx/
+UTILOBJDIR = ../xlock/
+GLOBJDIR = glx/
+
+N =
+O = .o
+#O = .obj
+C = .c
+CX = .cc
+S = $(N) $(N)
+#S = ,
+
+DM = $(VPATH)
+DOM =
+DU = $(UTILDIR)
+DOU = $(UTILOBJDIR)
+DG = $(GLDIR)
+DOG = $(GLOBJDIR)
+OM = $(O)$(S)$(DOM)
+OU = $(O)$(S)$(DOU)
+OG = $(O)$(S)$(DOG)
+CM = $(C) $(DM)
+CU = $(C) $(DU)
+CG = $(C) $(DG)
+CXG = $(CX) $(DG)
+
+# please define
+# C as the C source code extension
+# CX as the C++ source code extension
+# O as the object extension
+# S as the separator for object code
+
+
+# This debugging is new and is untested on many systems.
+@CHECK@CHECKDEF = -DDEBUG
+@CHECK@CHECKLDFLAG = -g
+@CHECK@XLOCKCHECKOBJS = $(DOU)memcheck$(O)
+
+# List of object files
+XLOCKUTILOBJS = $(DOU)xlock$(OU)passwd$(OU)resource$(OU)parsecmd$(O)$(S)\
+$(DOU)util$(OU)logout$(OU)mode$(OU)ras$(OU)xbm$(O)$(S)\
+$(DOU)vis$(OU)color$(OU)random$(OU)iostuff$(OU)automata$(O)$(S)\
+$(DOU)spline$(OU)sound$(OU)erase$(O)$(S)\
+$(DOU)vtlock$(OU)vtlock_proc$(O)$(S)$(XLOCKCHECKOBJS)
+
+XLOCKMODEOBJS = $(DOM)ant$(OM)ball$(OM)bat$(OM)blot$(OM)\
+bouboule$(OM)bounce$(OM)braid$(OM)bubble$(OM)bug$(OM)\
+clock$(OM)coral$(OM)crystal$(OM)\
+daisy$(OM)dclock$(OM)decay$(OM)deco$(OM)demon$(OM)\
+dilemma$(OM)discrete$(OM)drift$(OM)\
+eyes$(OM)fadeplot$(OM)flag$(OM)flame$(OM)flow$(OM)forest$(OM)\
+galaxy$(OM)goop$(OM)grav$(OM)\
+helix$(OM)hop$(OM)hyper$(OM)\
+ico$(OM)ifs$(OM)image$(OM)julia$(OM)kaleid$(OM)kumppa$(OM)\
+laser$(OM)life$(OM)life1d$(OM)life3d$(OM)\
+lightning$(OM)lisa$(OM)lissie$(OM)loop$(OM)lyapunov$(OM)\
+mandelbrot$(OM)marquee$(OM)matrix$(OM)maze$(OM)\
+mountain$(OM)munch$(OM)nose$(OM)\
+pacman$(OM)penrose$(OM)petal$(OM)puzzle$(OM)pyro$(OM)\
+qix$(OM)roll$(OM)rotor$(OM)\
+shape$(OM)sierpinski$(OM)slip$(OM)\
+sphere$(OM)spiral$(OM)spline$(OM)\
+star$(OM)starfish$(OM)strange$(OM)swarm$(OM)swirl$(OM)\
+tetris$(OM)thornbird$(OM)triangle$(OM)tube$(OM)turtle$(OM)\
+vines$(OM)voters$(OM)\
+wator$(OM)wire$(OM)world$(OM)worm$(OM)xjack$(O)
+@UNSTABLE@XLOCKUNSTABLEOBJS = space$(O)
+@XPM@XLOCKXPMOBJS = $(DOM)cartoon$(O)
+@GL@XLOCKGLOBJS = $(DOG)cage$(OG)gears$(O)$(S)\
+@GL@$(DOG)moebius$(OG)morph3d$(O)$(S)\
+@GL@$(DOG)rubik$(OG)stairs$(OG)superquadrics$(O)$(S)\
+@GL@$(DOG)buildlwo$(OG)pipes$(OG)pipeobjs$(O)$(S)\
+@GL@$(DOG)sproingies$(OG)sproingiewrap$(OG)s1_b$(O)$(S)\
+@GL@$(DOG)s1_1$(OG)s1_2$(OG)s1_3$(OG)s1_4$(OG)s1_5$(OG)s1_6$(O)$(S)\
+@GL@$(DOG)atlantis$(OG)dolphin$(OG)shark$(OG)swim$(OG)whale$(O)$(S)\
+@GL@$(DOG)bubble3d$(OG)b_draw$(OG)b_sphere$(OG)b_lockglue$(O)
+@XPM@@GL@XLOCKXPMGLOBJS = $(DOG)lament$(O)
+@CCC@@GL@XLOCKCPPGLOBJS = $(DOG)invert$(OG)i_figureeight$(OG)i_linkage$(O)$(S)\
+@CCC@@GL@$(DOG)i_sphere$(OG)i_spline$(O)$(S)\
+@CCC@@GL@$(DOG)i_threejet$(OG)i_threejetvec$(O)$(S)\
+@CCC@@GL@$(DOG)i_twojet$(OG)i_twojetvec$(O)
+@UNSTABLE@@CCC@@GL@@GLTT@XLOCKUNSTABLETEXTGLOBJS = $(DOG)text3d$(O)
+@UNSTABLE@@GL@XLOCKUNSTABLEGLOBJS =
+@BOMB@XLOCKBOMBOBJS = $(DOM)bomb$(O)
+XLOCKUTILMODEOBJS = $(XLOCKBOMBOBJS)$(S)$(DOM)blank$(OM)random$(O)
+XLOCKALLMODEOBJS = $(XLOCKMODEOBJS)$(S)$(XLOCKUNSTABLEOBJS)$(S)\
+$(XLOCKXPMOBJS)$(S)$(XLOCKGLOBJS)$(S)\
+$(XLOCKXPMGLOBJS)$(S)$(XLOCKCPPGLOBJS)$(S)\
+$(XLOCKUNSTABLEGLOBJS)$(S)$(XLOCKUNSTABLETEXTGLOBJS)$(S)\
+$(XLOCKUTILMODEOBJS)
+XLOCKALLUTILOBJS = $(XLOCKUTILOBJS)$(XLOCKDEBUGOBJS)
+XLOCKOBJS = $(XLOCKALLUTILOBJS)$(S)$(XLOCKALLMODEOBJS)
+
+# List of source files
+BITMAPS = decay.xbm eyes.xbm flag.xbm ghost.xbm image.xbm \
+life.xbm life1d.xbm maze.xbm puzzle.xbm
+PIXMAPS = decay.xpm flag.xpm image.xpm maze.xpm puzzle.xpm
+XLOCKUTILHDRS = xlock.h mode.h vroot.h ras.h version.h config.h
+XLOCKCHECKSRCS = $(DU)memcheck$(C)
+XLOCKUTILSRCS = $(DU)xlock$(CU)passwd$(CU)resource$(CU)parsecmd$(C) \
+$(DU)util$(CU)logout$(CU)mode$(CU)ras$(CU)xbm$(C) \
+$(DU)vis$(CU)color$(CU)random$(CU)iostuff$(CU)automata$(C) \
+$(DU)spline$(CU)sound$(CU)erase$(C) \
+$(DU)vtlock$(CU)vtlock_proc$(C) $(XLOCKCHECKSRCS)
+
+XLOCKMODESRCS = $(DM)ant$(CM)ball$(CM)bat$(CM)blot$(C) \
+$(DM)bouboule$(CM)bounce$(CM)braid$(CM)bubble$(CM)bug$(C) \
+$(DM)clock$(CM)coral$(CM)crystal$(C) \
+$(DM)daisy$(CM)dclock$(CM)decay$(CM)deco$(CM)demon$(C) \
+$(DM)dilemma$(CM)discrete$(CM)drift$(CM)eyes$(C) \
+$(DM)fadeplot$(CM)flag$(CM)flame$(CM)flow$(CM)forest$(C) \
+$(DM)galaxy$(CM)goop$(CM)grav$(C) \
+$(DM)helix$(CM)hop$(CM)hyper$(C) \
+$(DM)ico$(CM)ifs$(CM)image$(CM)julia$(CM)kaleid$(CM)kumppa$(C) \
+$(DM)laser$(CM)life$(CM)life1d$(CM)life3d$(C) \
+$(DM)lightning$(CM)lisa$(CM)lissie$(CM)loop$(CM)lyapunov$(C) \
+$(DM)mandelbrot$(CM)marquee$(CM)matrix$(CM)maze$(C) \
+$(DM)mountain$(CM)munch$(CM)nose$(C) \
+$(DM)pacman$(CM)penrose$(CM)petal$(CM)puzzle$(CM)pyro$(C) \
+$(DM)qix$(CM)roll$(CM)rotor$(C) \
+$(DM)shape$(CM)sierpinski$(CM)slip$(C) \
+$(DM)space$(CM)sphere$(CM)spiral$(CM)spline$(C) \
+$(DM)star$(CM)starfish$(CM)strange$(CM)swarm$(CM)swirl$(C) \
+$(DM)tetris$(CM)thornbird$(CM)triangle$(CM)tube$(CM)turtle$(C) \
+$(DM)vines$(CM)voters$(C) \
+$(DM)wator$(CM)wire$(CM)world$(CM)worm$(CM)xjack$(C)
+@XPM@XLOCKXPMSRCS = $(DM)cartoon$(C)
+@GL@XLOCKGLSRCS = $(DG)cage$(CG)gears$(C) \
+@GL@$(DG)lament$(CG)moebius$(CG)morph3d$(C) \
+@GL@$(DG)rubik$(CG)stairs$(CG)superquadrics$(C) \
+@GL@$(DG)buildlwo$(CG)pipes$(CG)pipeobjs$(C) \
+@GL@$(DG)sproingies$(CG)sproingiewrap$(CG)s1_b$(C) \
+@GL@$(DG)s1_1$(CG)s1_2$(CG)s1_3$(CG)s1_4$(CG)s1_5$(CG)s1_6$(C) \
+@GL@$(DG)atlantis$(CG)dolphin$(CG)shark$(CG)swim$(CG)whale$(C) \
+@GL@$(DG)bubble3d$(CG)text3d$(CXG)b_draw$(CG)b_sphere$(CG)b_lockglue$(C)
+@BOMB@XLOCKBOMBSRCS = $(DM)bomb$(C)
+XLOCKUTILMODESRCS = $(XLOCKBOMBSRCS) $(DM)blank$(CM)random$(C)
+XLOCKSRCS = $(XLOCKUTILSRCS) $(XLOCKXPMSRCS) $(XLOCKGLSRCS) \
+$(XLOCKMODESRCS) $(XLOCKUTILMODESRCS)
+
+# default target
+all : $(XLOCKOBJS) $(UTILOBJDIR)xlock
+
+# this tells GNU make not to export variables into the environment
+# But other makes do not understand its significance, so it must
+# not be the first target in the file. So it is here, before
+# any variables are created, but after the default target
+.NOEXPORT :
+
+SHELL = /bin/sh
+
+prefix = @prefix@
+exec_prefix = @exec_prefix@
+
+bindir = @bindir@
+mandir = @mandir@/man1
+xapploaddir = @APPDEFAULTS@
+
+INSTALL = @INSTALL@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_DATA = @INSTALL_DATA@
+INSTPGMFLAGS = @INSTPGMFLAGS@
+
+
+#CC = cc -g
+#CC = cc -Ac -g
+#CC = cc -Xc -g
+#CC = acc -g
+#CC = CC -g
+#CC = gcc -g -Wall -ansi -pedantic
+#CC = gcc -g -Wall -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wwrite-strings -Waggregate-return -Wmissing-prototypes -Wstrict-prototypes
+#CC = g++ -g -Wall
+CC = @CC@
+CXX = @CXX@
+
+LINT = lint
+#LINT = alint
+
+#DEPEND = makedepend
+DEPEND = @DEPEND@
+DEPEND_FLAGS = @DEPEND_FLAGS@
+DEPEND_DEFINES = @DEPEND_DEFINES@
+
+#BITMAPTYPE = x11
+#PIXMAPTYPE = x11
+BITMAPTYPE = @BITMAPTYPE@
+PIXMAPTYPE = @PIXMAPTYPE@
+
+# Here is your chance to override the default icon:
+TINYBITMAP = $(BITMAPTYPE)
+TINYBITMAP = t-x11
+SMALLBITMAP = s-$(BITMAPTYPE)
+MEDIUMBITMAP = m-$(BITMAPTYPE)
+LARGEBITMAP = l-$(BITMAPTYPE)
+MEDIUMPIXMAP = m-$(PIXMAPTYPE)
+LARGEPIXMAP = l-$(PIXMAPTYPE)
+
+#DECAYBITMAP = $(LARGEBITMAP)
+DECAYBITMAP = l-xlock
+#DECAYBITMAP = l-linux
+#EYESBITMAP = $(MEDIUMBITMAP)
+EYESBITMAP = m-grelb
+FLAGBITMAP = $(MEDIUMBITMAP)
+IMAGEBITMAP = $(MEDIUMBITMAP)
+#IMAGEBITMAP = l-bob #Slackware icon
+#IMAGEBITMAP = m-xlock #XLock icon
+#LIFEBITMAP = $(SMALLBITMAP)
+LIFEBITMAP = s-grelb
+LIFE1DBITMAP = $(TINYBITMAP)
+MAZEBITMAP = $(LARGEBITMAP)
+#MAZEBITMAP = m-xlock
+#PACMANBITMAP = $(MEDIUMBITMAP)
+PACMANBITMAP = m-ghost
+#PUZZLEBITMAP = $(LARGEBITMAP)
+PUZZLEBITMAP = l-xlock
+#PUZZLEBITMAP = l-linux
+#DECAYPIXMAP = $(LARGEPIXMAP)
+DECAYPIXMAP = l-xlock
+#DECAYPIXMAP = l-linux
+FLAGPIXMAP = $(MEDIUMPIXMAP)
+#FLAGPIXMAP = m-xlock
+IMAGEPIXMAP = $(MEDIUMPIXMAP)
+#IMAGEPIXMAP = m-xlock
+MAZEPIXMAP = $(MEDIUMPIXMAP)
+#MAZEPIXMAP = m-xlock
+#PUZZLEPIXMAP = $(LARGEPIXMAP)
+PUZZLEPIXMAP = l-xlock
+#PUZZLEPIXMAP = l-linux
+
+LN_S = @LN_S@
+RM = rm -f
+RM_S = $(RM)
+ECHO = echo
+
+#BLN_S = set file/enter=[]
+#RM = delete/noconfirm/nolog
+#RM_S = set file/remove/nolog
+#ECHO = write sys$output
+
+DEFINES = -DDEF_FILESEARCHPATH=\"$(xapploaddir)/%N%C%S:$(xapploaddir)/%N%S\" $(CHECKDEF)
+DEFS = @DEFS@ $(DEFINES)
+XLOCKINC = -I. -I.. -I$(UTILDIR) -I../.. @XLOCKINC@
+CFLAGS = @CFLAGS@
+CXXFLAGS = @CXXFLAGS@
+#CFLAGS = -O
+#CFLAGS = -g
+XLOCKLDFLAGS = @XLOCKLDFLAGS@ $(CHECKLDFLAG)
+XLIBS = @XLIBS@
+XLOCKLIBS = @XLOCKLIBS@
+
+####
+#### These might have become not necessary as configure do the job
+#### It check for pthread, svga & glide in MesaGL lib and add each of them
+#### if they was linked against.
+####
+#MesaGL threads
+#XLOCKLIBS = @XLOCKLIBS@ -lpthread
+#MesaGL vga
+#XLOCKLIBS = @XLOCKLIBS@ -lvga
+#3Dfx Glide VooDoo graphics device driver for MesaGL >= 2.3?  _NOT_ tested.
+#XLOCKLIBS = @XLOCKLIBS@ -lglide -ltexus
+####
+####
+
+#SAFEWORD
+#XLOCKLIBS = @XLOCKLIBS@ -lidpb
+#If you have purify, and want to use it, uncomment this definition or
+# run the make as `make PURIFY=purify'
+# or run configure with the --with-purify argument.
+PURIFY = @PURIFY@
+
+xlock : $(UTILOBJDIR)xlock
+
+$(UTILOBJDIR)xlock : $(XLOCKOBJS)
+       $(PURIFY) $(CXX) $(CFLAGS) -o $@ $(XLOCKOBJS) $(XLOCKLDFLAGS) $(XLOCKLIBS)
+       @ $(ECHO) "$@ BUILD COMPLETE"
+       @ $(ECHO) ""
+
+decay.xbm : $(BITMAPDIR)$(DECAYBITMAP).xbm
+       $(RM) decay.xbm ; $(LN_S) $(BITMAPDIR)$(DECAYBITMAP).xbm decay.xbm
+
+eyes.xbm : $(BITMAPDIR)$(EYESBITMAP).xbm
+       $(RM) eyes.xbm ; $(LN_S) $(BITMAPDIR)$(EYESBITMAP).xbm eyes.xbm
+
+flag.xbm : $(BITMAPDIR)$(FLAGBITMAP).xbm
+       $(RM) flag.xbm ; $(LN_S) $(BITMAPDIR)$(FLAGBITMAP).xbm flag.xbm
+
+image.xbm : $(BITMAPDIR)$(IMAGEBITMAP).xbm
+       $(RM) image.xbm ; $(LN_S) $(BITMAPDIR)$(IMAGEBITMAP).xbm image.xbm
+
+ghost.xbm : $(BITMAPDIR)$(PACMANBITMAP).xbm
+       $(RM) ghost.xbm ; $(LN_S) $(BITMAPDIR)$(PACMANBITMAP).xbm ghost.xbm
+
+life.xbm : $(BITMAPDIR)$(LIFEBITMAP).xbm
+       $(RM) life.xbm ; $(LN_S) $(BITMAPDIR)$(LIFEBITMAP).xbm life.xbm
+
+life1d.xbm : $(BITMAPDIR)$(LIFE1DBITMAP).xbm
+       $(RM) life1d.xbm ; $(LN_S) $(BITMAPDIR)$(LIFE1DBITMAP).xbm life1d.xbm
+
+maze.xbm : $(BITMAPDIR)$(MAZEBITMAP).xbm
+       $(RM) maze.xbm ; $(LN_S) $(BITMAPDIR)$(MAZEBITMAP).xbm maze.xbm
+
+puzzle.xbm : $(BITMAPDIR)$(PUZZLEBITMAP).xbm
+       $(RM) puzzle.xbm ; $(LN_S) $(BITMAPDIR)$(PUZZLEBITMAP).xbm puzzle.xbm
+
+decay.xpm : $(PIXMAPDIR)$(DECAYPIXMAP).xpm
+       $(RM) decay.xpm ; $(LN_S) $(PIXMAPDIR)$(DECAYPIXMAP).xpm decay.xpm
+
+flag.xpm : $(PIXMAPDIR)$(FLAGPIXMAP).xpm
+       $(RM) flag.xpm ; $(LN_S) $(PIXMAPDIR)$(FLAGPIXMAP).xpm flag.xpm
+
+image.xpm : $(PIXMAPDIR)$(IMAGEPIXMAP).xpm
+       $(RM) image.xpm ; $(LN_S) $(PIXMAPDIR)$(IMAGEPIXMAP).xpm image.xpm
+
+maze.xpm : $(PIXMAPDIR)$(MAZEPIXMAP).xpm
+       $(RM) maze.xpm ; $(LN_S) $(PIXMAPDIR)$(MAZEPIXMAP).xpm maze.xpm
+
+puzzle.xpm : $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm
+       $(RM) puzzle.xpm ; $(LN_S) $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm puzzle.xpm
+
+$(UTILOBJDIR)xlock.o : $(UTILDIR)xlock.c
+$(UTILOBJDIR)passwd.o : $(UTILDIR)passwd.c
+$(UTILOBJDIR)resource.o : $(UTILDIR)resource.c
+$(UTILOBJDIR)parsecmd.o : $(UTILDIR)parsecmd.c
+$(UTILOBJDIR)util.o : $(UTILDIR)util.c
+$(UTILOBJDIR)logout.o : $(UTILDIR)logout.c
+$(UTILOBJDIR)mode.o : $(UTILDIR)mode.c
+$(UTILOBJDIR)ras.o : $(UTILDIR)ras.c
+$(UTILOBJDIR)xbm.o : $(UTILDIR)xbm.c
+$(UTILOBJDIR)vis.o : $(UTILDIR)vis.c
+$(UTILOBJDIR)color.o : $(UTILDIR)color.c
+$(UTILOBJDIR)random.o : $(UTILDIR)random.c
+$(UTILOBJDIR)iostuff.o : $(UTILDIR)iostuff.c
+$(UTILOBJDIR)automata.o : $(UTILDIR)automata.c
+$(UTILOBJDIR)spline.o : $(UTILDIR)spline.c
+$(UTILOBJDIR)sound.o : $(UTILDIR)sound.c
+$(UTILOBJDIR)erase.o : $(UTILDIR)erase.c
+$(UTILOBJDIR)vtlock.o : $(UTILDIR)vtlock.c
+$(UTILOBJDIR)vtlock_proc.o : $(UTILDIR)vtlock_proc.c
+$(UTILOBJDIR)memcheck.o : $(UTILDIR)memcheck.c
+
+#$(XLOCKUTILOBJS) :
+#      cd $(UTILOBJDIR) ; \
+#$(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+
+$(GLOBJDIR)cage.o : $(GLDIR)cage.c
+$(GLOBJDIR)gears.o : $(GLDIR)gears.c
+$(GLOBJDIR)lament.o : $(GLDIR)lament.c
+$(GLOBJDIR)text3d.o : $(GLDIR)text3d.cc
+$(GLOBJDIR)moebius.o : $(GLDIR)moebius.c
+$(GLOBJDIR)morph3d.o : $(GLDIR)morph3d.c
+$(GLOBJDIR)rubik.o : $(GLDIR)rubik.c
+$(GLOBJDIR)stairs.o : $(GLDIR)stairs.c
+$(GLOBJDIR)superquadrics.o : $(GLDIR)superquadrics.c
+$(GLOBJDIR)buildlwo.o : $(GLDIR)buildlwo.c
+$(GLOBJDIR)pipes.o : $(GLDIR)pipes.c
+$(GLOBJDIR)pipeobjs.o : $(GLDIR)pipeobjs.c
+$(GLOBJDIR)sproingies.o : $(GLDIR)sproingies.c
+$(GLOBJDIR)sproingiewrap.o : $(GLDIR)sproingiewrap.c
+$(GLOBJDIR)s1_b.o : $(GLDIR)s1_b.c
+$(GLOBJDIR)s1_1.o : $(GLDIR)s1_1.c
+$(GLOBJDIR)s1_2.o : $(GLDIR)s1_2.c
+$(GLOBJDIR)s1_3.o : $(GLDIR)s1_3.c
+$(GLOBJDIR)s1_4.o : $(GLDIR)s1_4.c
+$(GLOBJDIR)s1_5.o : $(GLDIR)s1_5.c
+$(GLOBJDIR)s1_6.o : $(GLDIR)s1_6.c
+
+#$(XLOCKGLOBJS) :
+#      cd $(GLOBJDIR) ; \
+#$(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+
+.SUFFIXES : $(C) $(CX) $(O)
+
+$(C)$(O) :
+       $(CC) -c -o $@ $(CPPFLAGS) $(DEFS) $(XLOCKINC) $(CFLAGS) $<
+
+$(CX)$(O) :
+       $(CXX) -c -o $@ $(CPPFLAGS) $(DEFS) $(XLOCKINC) $(CXXFLAGS) $<
+
+install : install-program install-man install-ad
+       @ $(ECHO) "$@ COMPLETE"
+       @ $(ECHO) ""
+
+install-program : xlock
+       $(top_srcdir)/mkinstalldirs $(bindir)
+       $(INSTALL_PROGRAM) $(INSTPGMFLAGS) $(UTILOBJDIR)xlock $(bindir)
+
+install-man :
+       $(top_srcdir)/mkinstalldirs $(mandir)
+       $(INSTALL_DATA) $(UTILDIR)xlock.man $(mandir)/xlock.1
+
+install-ad :
+       $(top_srcdir)/mkinstalldirs $(xapploaddir)
+       $(INSTALL_DATA) $(UTILDIR)XLock.ad $(xapploaddir)/XLock
+
+uninstall : uninstall-program uninstall-man uninstall-ad
+
+uninstall-program :
+       $(RM) $(bindir)/xlock
+
+uninstall-man :
+       $(RM) $(mandir)/xlock.1
+
+uninstall-ad :
+       $(RM) $(xapploaddir)/XLock
+
+lint :
+       $(LINT) -ax -DLINT $(DEFS) $(XLOCKINC) $(XLOCKSRCS) -L/usr/openwin/lib -lX11 -lm
+
+xrdb :
+
+man :
+
+html :
+
+hlp :
+
+clean :
+       $(RM) *.o *.xlk core *~ *% *.bak *.orig *.rej make.log MakeOut *.patch
+
+distclean : clean
+       $(RM) Makefile $(BITMAPS) $(PIXMAPS)
+
+clean.all : distclean
+
+# Adds all current dependencies to Makefile
+depend : $(BITMAPS) $(PIXMAPS)
+       $(DEPEND) -s '# DO NOT DELETE: updated by make depend'              \
+       $(DEPEND_FLAGS) --                                                  \
+       $(XLOCKINC) $(DEFS) $(DEPEND_DEFINES) $(CFLAGS) --                  \
+       $(XLOCKSRCS)
+
+# Adds some dependencies to Makefile.in -- not totally accurate, but pretty
+# close.  This excludes dependencies on files in /usr/include, etc.  It tries
+# to include only dependencies on files which are themselves a part of this
+# package.
+distdepend :
+       @echo updating dependencies in `pwd`/Makefile.in... ;               \
+       $(DEPEND) -w 0 -f -                                                 \
+       -s '# DO NOT DELETE: updated by make distdepend' $(DEPEND_FLAGS) -- \
+       $(XLOCKINC) $(DEFS) $(DEPEND_DEFINES) $(CFLAGS) --                  \
+       $(XLOCKSRCS) |                                                      \
+       (                                                                   \
+         awk '/^#.*Id : Makefile.in/,/^# DO .*distdepend/' < Makefile.in ; \
+         sed -e 's@ \./@ @g;s@ /[^ ]*@@g;/^.*:$$/d'                        \
+             -e 's@^\.\./xlock@$$(UTILOBJDIR)@'                            \
+             -e 's@^\.\./modes/glx@$$(GLOBJDIR)@'                          \
+             -e 's@\.\./bitmaps@$$(BITMAPDIR)@g'                           \
+             -e 's@\.\./pixmaps@$$(PIXMAPDIR)@g'                           \
+             -e 's@\.\./xlock@$$(UTILDIR)@g'                               \
+             -e 's@\.\./modes/glx@$$(GLDIR)@g' ;                           \
+         echo ''                                                           \
+       ) > /tmp/distdepend.$$$$ &&                                         \
+       mv Makefile.in Makefile.in.bak &&                                   \
+       mv /tmp/distdepend.$$$$ Makefile.in
+
+#            -e 's@ \([^$$]\)@ $$(srcdir)/\1@g'                            \
+#            -e 's@ $$(srcdir)/\(.*config.h\)@ \1@g' ;                     \
+
+##############################################################################
+#
+# DO NOT DELETE: updated by make distdepend
+
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/xlock.o: ../config.h
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/color.h
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/util.h
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/iostuff.h
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/passwd.h
+$(UTILOBJDIR)/xlock.o: $(BITMAPDIR)/mailempty.xbm
+$(UTILOBJDIR)/xlock.o: $(BITMAPDIR)/mailfull.xbm
+$(UTILOBJDIR)/xlock.o: $(UTILDIR)/vroot.h
+$(UTILOBJDIR)/passwd.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/passwd.o: ../config.h
+$(UTILOBJDIR)/passwd.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/passwd.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/passwd.o: $(UTILDIR)/iostuff.h
+$(UTILOBJDIR)/passwd.o: $(UTILDIR)/passwd.h
+$(UTILOBJDIR)/resource.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/resource.o: ../config.h
+$(UTILOBJDIR)/resource.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/resource.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/resource.o: $(UTILDIR)/vis.h
+$(UTILOBJDIR)/resource.o: $(UTILDIR)/iostuff.h
+$(UTILOBJDIR)/resource.o: $(UTILDIR)/version.h
+$(UTILOBJDIR)/util.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/util.o: ../config.h
+$(UTILOBJDIR)/util.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/util.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/util.o: $(UTILDIR)/util.h
+$(UTILOBJDIR)/logout.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/logout.o: ../config.h
+$(UTILOBJDIR)/logout.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/logout.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/logout.o: $(UTILDIR)/iostuff.h
+$(UTILOBJDIR)/mode.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/mode.o: ../config.h
+$(UTILOBJDIR)/mode.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/mode.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/ras.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/ras.o: ../config.h
+$(UTILOBJDIR)/ras.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/ras.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/ras.o: $(UTILDIR)/iostuff.h
+$(UTILOBJDIR)/ras.o: $(UTILDIR)/ras.h
+$(UTILOBJDIR)/xbm.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/xbm.o: ../config.h
+$(UTILOBJDIR)/xbm.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/xbm.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/vis.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/vis.o: ../config.h
+$(UTILOBJDIR)/vis.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/vis.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/vis.o: $(UTILDIR)/vis.h
+$(UTILOBJDIR)/color.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/color.o: ../config.h
+$(UTILOBJDIR)/color.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/color.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/color.o: $(UTILDIR)/color.h
+$(UTILOBJDIR)/color.o: $(UTILDIR)/vis.h
+$(UTILOBJDIR)/iostuff.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/iostuff.o: ../config.h
+$(UTILOBJDIR)/iostuff.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/iostuff.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/iostuff.o: $(UTILDIR)/vis.h
+$(UTILOBJDIR)/iostuff.o: $(UTILDIR)/color.h
+$(UTILOBJDIR)/iostuff.o: $(UTILDIR)/iostuff.h
+$(UTILOBJDIR)/iostuff.o: $(UTILDIR)/ras.h
+$(UTILOBJDIR)/automata.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/automata.o: ../config.h
+$(UTILOBJDIR)/automata.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/automata.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/automata.o: $(UTILDIR)/automata.h
+$(UTILOBJDIR)/spline.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/spline.o: ../config.h
+$(UTILOBJDIR)/spline.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/spline.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/spline.o: $(UTILDIR)/spline.h
+$(UTILOBJDIR)/sound.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/sound.o: ../config.h
+$(UTILOBJDIR)/sound.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/sound.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/erase.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/erase.o: ../config.h
+$(UTILOBJDIR)/erase.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/erase.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/erase.o: $(UTILDIR)/erase_init.h
+$(UTILOBJDIR)/erase.o: $(UTILDIR)/erase.h
+$(UTILOBJDIR)/erase.o: $(UTILDIR)/erase_debug.h
+$(UTILOBJDIR)/vtlock.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/vtlock.o: ../config.h
+$(UTILOBJDIR)/vtlock.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/vtlock.o: $(UTILDIR)/random.h
+$(UTILOBJDIR)/vtlock_proc.o: $(UTILDIR)/xlock.h
+$(UTILOBJDIR)/vtlock_proc.o: ../config.h
+$(UTILOBJDIR)/vtlock_proc.o: $(UTILDIR)/mode.h
+$(UTILOBJDIR)/vtlock_proc.o: $(UTILDIR)/random.h
+cartoon.o: $(UTILDIR)/xlock.h
+cartoon.o: ../config.h
+cartoon.o: $(UTILDIR)/mode.h
+cartoon.o: $(UTILDIR)/random.h
+cartoon.o: $(UTILDIR)/vis.h
+cartoon.o: $(UTILDIR)/color.h
+cartoon.o: $(UTILDIR)/iostuff.h
+cartoon.o: $(PIXMAPDIR)/calvin2.xpm
+cartoon.o: $(PIXMAPDIR)/gravity.xpm
+cartoon.o: $(PIXMAPDIR)/calvin4.xpm
+cartoon.o: $(PIXMAPDIR)/calvinf.xpm
+cartoon.o: $(PIXMAPDIR)/hobbes.xpm
+cartoon.o: $(PIXMAPDIR)/calvin.xpm
+cartoon.o: $(PIXMAPDIR)/marino2.xpm
+cartoon.o: $(PIXMAPDIR)/calvin3.xpm
+cartoon.o: $(PIXMAPDIR)/garfield.xpm
+$(GLOBJDIR)/cage.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/cage.o: ../config.h
+$(GLOBJDIR)/cage.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/cage.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/cage.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/cage.o: $(GLDIR)/e_textures.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/gears.o: ../config.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/lament.o: ../config.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/lament.o: $(PIXMAPDIR)/lament.xpm
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/moebius.o: ../config.h
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/moebius.o: $(GLDIR)/e_textures.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/morph3d.o: ../config.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/rubik.o: ../config.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/stairs.o: ../config.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/stairs.o: $(GLDIR)/e_textures.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/superquadrics.o: ../config.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/buildlwo.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/buildlwo.o: ../config.h
+$(GLOBJDIR)/buildlwo.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/buildlwo.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/buildlwo.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/pipes.o: ../config.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/pipes.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/pipeobjs.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/pipeobjs.o: ../config.h
+$(GLOBJDIR)/pipeobjs.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/pipeobjs.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/pipeobjs.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/sproingies.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/sproingies.o: ../config.h
+$(GLOBJDIR)/sproingies.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/sproingies.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/sproingies.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/sproingiewrap.o: ../config.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/s1_b.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_b.o: ../config.h
+$(GLOBJDIR)/s1_b.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_b.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_b.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/s1_1.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_1.o: ../config.h
+$(GLOBJDIR)/s1_1.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_1.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_1.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/s1_2.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_2.o: ../config.h
+$(GLOBJDIR)/s1_2.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_2.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_2.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/s1_3.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_3.o: ../config.h
+$(GLOBJDIR)/s1_3.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_3.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_3.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/s1_4.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_4.o: ../config.h
+$(GLOBJDIR)/s1_4.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_4.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_4.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/s1_5.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_5.o: ../config.h
+$(GLOBJDIR)/s1_5.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_5.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_5.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/s1_6.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_6.o: ../config.h
+$(GLOBJDIR)/s1_6.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_6.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_6.o: $(GLDIR)/buildlwo.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/atlantis.o: ../config.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/atlantis.o: $(GLDIR)/atlantis.h
+$(GLOBJDIR)/dolphin.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/dolphin.o: ../config.h
+$(GLOBJDIR)/dolphin.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/dolphin.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/dolphin.o: $(GLDIR)/atlantis.h
+$(GLOBJDIR)/shark.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/shark.o: ../config.h
+$(GLOBJDIR)/shark.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/shark.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/shark.o: $(GLDIR)/atlantis.h
+$(GLOBJDIR)/swim.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/swim.o: ../config.h
+$(GLOBJDIR)/swim.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/swim.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/swim.o: $(GLDIR)/atlantis.h
+$(GLOBJDIR)/whale.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/whale.o: ../config.h
+$(GLOBJDIR)/whale.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/whale.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/whale.o: $(GLDIR)/atlantis.h
+$(GLOBJDIR)/bubble3d.o: $(GLDIR)/bubble3d.h
+$(GLOBJDIR)/bubble3d.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/bubble3d.o: ../config.h
+$(GLOBJDIR)/bubble3d.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/bubble3d.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/text3d.o: ../config.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/text3d.o: $(GLDIR)/text3d.h
+$(GLOBJDIR)/b_draw.o: $(GLDIR)/bubble3d.h
+$(GLOBJDIR)/b_draw.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/b_draw.o: ../config.h
+$(GLOBJDIR)/b_draw.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/b_draw.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/b_sphere.o: $(GLDIR)/bubble3d.h
+$(GLOBJDIR)/b_sphere.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/b_sphere.o: ../config.h
+$(GLOBJDIR)/b_sphere.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/b_sphere.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/b_lockglue.o: $(GLDIR)/bubble3d.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/b_lockglue.o: ../config.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/vis.h
+ant.o: $(UTILDIR)/xlock.h
+ant.o: ../config.h
+ant.o: $(UTILDIR)/mode.h
+ant.o: $(UTILDIR)/random.h
+ant.o: $(UTILDIR)/automata.h
+ball.o: $(UTILDIR)/xlock.h
+ball.o: ../config.h
+ball.o: $(UTILDIR)/mode.h
+ball.o: $(UTILDIR)/random.h
+bat.o: $(UTILDIR)/xlock.h
+bat.o: ../config.h
+bat.o: $(UTILDIR)/mode.h
+bat.o: $(UTILDIR)/random.h
+bat.o: $(UTILDIR)/vis.h
+bat.o: $(UTILDIR)/color.h
+bat.o: $(UTILDIR)/iostuff.h
+bat.o: $(PIXMAPDIR)/bat-0.xpm
+bat.o: $(PIXMAPDIR)/bat-1.xpm
+bat.o: $(PIXMAPDIR)/bat-2.xpm
+bat.o: $(PIXMAPDIR)/bat-3.xpm
+bat.o: $(PIXMAPDIR)/bat-4.xpm
+bat.o: $(BITMAPDIR)/bat-0.xbm
+bat.o: $(BITMAPDIR)/bat-1.xbm
+bat.o: $(BITMAPDIR)/bat-2.xbm
+bat.o: $(BITMAPDIR)/bat-3.xbm
+bat.o: $(BITMAPDIR)/bat-4.xbm
+blot.o: $(UTILDIR)/xlock.h
+blot.o: ../config.h
+blot.o: $(UTILDIR)/mode.h
+blot.o: $(UTILDIR)/random.h
+bouboule.o: $(UTILDIR)/xlock.h
+bouboule.o: ../config.h
+bouboule.o: $(UTILDIR)/mode.h
+bouboule.o: $(UTILDIR)/random.h
+bounce.o: $(UTILDIR)/xlock.h
+bounce.o: ../config.h
+bounce.o: $(UTILDIR)/mode.h
+bounce.o: $(UTILDIR)/random.h
+bounce.o: $(BITMAPDIR)/bounce-0.xbm
+bounce.o: $(BITMAPDIR)/bounce-1.xbm
+bounce.o: $(BITMAPDIR)/bounce-2.xbm
+bounce.o: $(BITMAPDIR)/bounce-3.xbm
+bounce.o: $(BITMAPDIR)/bounce-mask.xbm
+braid.o: $(UTILDIR)/xlock.h
+braid.o: ../config.h
+braid.o: $(UTILDIR)/mode.h
+braid.o: $(UTILDIR)/random.h
+bubble.o: $(UTILDIR)/xlock.h
+bubble.o: ../config.h
+bubble.o: $(UTILDIR)/mode.h
+bubble.o: $(UTILDIR)/random.h
+bug.o: $(UTILDIR)/xlock.h
+bug.o: ../config.h
+bug.o: $(UTILDIR)/mode.h
+bug.o: $(UTILDIR)/random.h
+bug.o: $(UTILDIR)/automata.h
+clock.o: $(UTILDIR)/xlock.h
+clock.o: ../config.h
+clock.o: $(UTILDIR)/mode.h
+clock.o: $(UTILDIR)/random.h
+coral.o: $(UTILDIR)/xlock.h
+coral.o: ../config.h
+coral.o: $(UTILDIR)/mode.h
+coral.o: $(UTILDIR)/random.h
+crystal.o: $(UTILDIR)/xlock.h
+crystal.o: ../config.h
+crystal.o: $(UTILDIR)/mode.h
+crystal.o: $(UTILDIR)/random.h
+crystal.o: $(UTILDIR)/color.h
+daisy.o: $(UTILDIR)/xlock.h
+daisy.o: ../config.h
+daisy.o: $(UTILDIR)/mode.h
+daisy.o: $(UTILDIR)/random.h
+dclock.o: $(UTILDIR)/xlock.h
+dclock.o: ../config.h
+dclock.o: $(UTILDIR)/mode.h
+dclock.o: $(UTILDIR)/random.h
+dclock.o: $(UTILDIR)/util.h
+dclock.o: $(UTILDIR)/iostuff.h
+decay.o: $(UTILDIR)/xlock.h
+decay.o: ../config.h
+decay.o: $(UTILDIR)/mode.h
+decay.o: $(UTILDIR)/random.h
+decay.o: $(UTILDIR)/iostuff.h
+decay.o: $(UTILDIR)/color.h
+decay.o: decay.xbm
+decay.o: decay.xpm
+deco.o: $(UTILDIR)/xlock.h
+deco.o: ../config.h
+deco.o: $(UTILDIR)/mode.h
+deco.o: $(UTILDIR)/random.h
+demon.o: $(UTILDIR)/xlock.h
+demon.o: ../config.h
+demon.o: $(UTILDIR)/mode.h
+demon.o: $(UTILDIR)/random.h
+demon.o: $(UTILDIR)/automata.h
+dilemma.o: $(UTILDIR)/xlock.h
+dilemma.o: ../config.h
+dilemma.o: $(UTILDIR)/mode.h
+dilemma.o: $(UTILDIR)/random.h
+dilemma.o: $(UTILDIR)/automata.h
+dilemma.o: $(BITMAPDIR)/cooperat.xbm
+dilemma.o: $(BITMAPDIR)/defect.xbm
+discrete.o: $(UTILDIR)/xlock.h
+discrete.o: ../config.h
+discrete.o: $(UTILDIR)/mode.h
+discrete.o: $(UTILDIR)/random.h
+drift.o: $(UTILDIR)/xlock.h
+drift.o: ../config.h
+drift.o: $(UTILDIR)/mode.h
+drift.o: $(UTILDIR)/random.h
+eyes.o: $(UTILDIR)/xlock.h
+eyes.o: ../config.h
+eyes.o: $(UTILDIR)/mode.h
+eyes.o: $(UTILDIR)/random.h
+eyes.o: $(UTILDIR)/iostuff.h
+eyes.o: eyes.xbm
+fadeplot.o: $(UTILDIR)/xlock.h
+fadeplot.o: ../config.h
+fadeplot.o: $(UTILDIR)/mode.h
+fadeplot.o: $(UTILDIR)/random.h
+flag.o: $(UTILDIR)/xlock.h
+flag.o: ../config.h
+flag.o: $(UTILDIR)/mode.h
+flag.o: $(UTILDIR)/random.h
+flag.o: $(UTILDIR)/color.h
+flag.o: $(UTILDIR)/iostuff.h
+flag.o: flag.xbm
+flag.o: flag.xpm
+flame.o: $(UTILDIR)/xlock.h
+flame.o: ../config.h
+flame.o: $(UTILDIR)/mode.h
+flame.o: $(UTILDIR)/random.h
+flow.o: $(UTILDIR)/xlock.h
+flow.o: ../config.h
+flow.o: $(UTILDIR)/mode.h
+flow.o: $(UTILDIR)/random.h
+forest.o: $(UTILDIR)/xlock.h
+forest.o: ../config.h
+forest.o: $(UTILDIR)/mode.h
+forest.o: $(UTILDIR)/random.h
+galaxy.o: $(UTILDIR)/xlock.h
+galaxy.o: ../config.h
+galaxy.o: $(UTILDIR)/mode.h
+galaxy.o: $(UTILDIR)/random.h
+goop.o: $(UTILDIR)/xlock.h
+goop.o: ../config.h
+goop.o: $(UTILDIR)/mode.h
+goop.o: $(UTILDIR)/random.h
+goop.o: $(UTILDIR)/spline.h
+grav.o: $(UTILDIR)/xlock.h
+grav.o: ../config.h
+grav.o: $(UTILDIR)/mode.h
+grav.o: $(UTILDIR)/random.h
+helix.o: $(UTILDIR)/xlock.h
+helix.o: ../config.h
+helix.o: $(UTILDIR)/mode.h
+helix.o: $(UTILDIR)/random.h
+hop.o: $(UTILDIR)/xlock.h
+hop.o: ../config.h
+hop.o: $(UTILDIR)/mode.h
+hop.o: $(UTILDIR)/random.h
+hyper.o: $(UTILDIR)/xlock.h
+hyper.o: ../config.h
+hyper.o: $(UTILDIR)/mode.h
+hyper.o: $(UTILDIR)/random.h
+ico.o: $(UTILDIR)/xlock.h
+ico.o: ../config.h
+ico.o: $(UTILDIR)/mode.h
+ico.o: $(UTILDIR)/random.h
+ifs.o: $(UTILDIR)/xlock.h
+ifs.o: ../config.h
+ifs.o: $(UTILDIR)/mode.h
+ifs.o: $(UTILDIR)/random.h
+image.o: $(UTILDIR)/xlock.h
+image.o: ../config.h
+image.o: $(UTILDIR)/mode.h
+image.o: $(UTILDIR)/random.h
+image.o: $(UTILDIR)/color.h
+image.o: $(UTILDIR)/iostuff.h
+image.o: image.xbm
+image.o: image.xpm
+julia.o: $(UTILDIR)/xlock.h
+julia.o: ../config.h
+julia.o: $(UTILDIR)/mode.h
+julia.o: $(UTILDIR)/random.h
+kaleid.o: $(UTILDIR)/xlock.h
+kaleid.o: ../config.h
+kaleid.o: $(UTILDIR)/mode.h
+kaleid.o: $(UTILDIR)/random.h
+kumppa.o: $(UTILDIR)/xlock.h
+kumppa.o: ../config.h
+kumppa.o: $(UTILDIR)/mode.h
+kumppa.o: $(UTILDIR)/random.h
+laser.o: $(UTILDIR)/xlock.h
+laser.o: ../config.h
+laser.o: $(UTILDIR)/mode.h
+laser.o: $(UTILDIR)/random.h
+life.o: $(UTILDIR)/xlock.h
+life.o: ../config.h
+life.o: $(UTILDIR)/mode.h
+life.o: $(UTILDIR)/random.h
+life.o: $(UTILDIR)/color.h
+life.o: $(UTILDIR)/iostuff.h
+life.o: $(UTILDIR)/automata.h
+life.o: life.xbm
+life1d.o: $(UTILDIR)/xlock.h
+life1d.o: ../config.h
+life1d.o: $(UTILDIR)/mode.h
+life1d.o: $(UTILDIR)/random.h
+life1d.o: $(UTILDIR)/color.h
+life1d.o: $(UTILDIR)/automata.h
+life1d.o: $(UTILDIR)/iostuff.h
+life1d.o: life1d.xbm
+life3d.o: $(UTILDIR)/xlock.h
+life3d.o: ../config.h
+life3d.o: $(UTILDIR)/mode.h
+life3d.o: $(UTILDIR)/random.h
+life3d.o: $(UTILDIR)/iostuff.h
+lightning.o: $(UTILDIR)/xlock.h
+lightning.o: ../config.h
+lightning.o: $(UTILDIR)/mode.h
+lightning.o: $(UTILDIR)/random.h
+lisa.o: $(UTILDIR)/xlock.h
+lisa.o: ../config.h
+lisa.o: $(UTILDIR)/mode.h
+lisa.o: $(UTILDIR)/random.h
+lissie.o: $(UTILDIR)/xlock.h
+lissie.o: ../config.h
+lissie.o: $(UTILDIR)/mode.h
+lissie.o: $(UTILDIR)/random.h
+loop.o: $(UTILDIR)/xlock.h
+loop.o: ../config.h
+loop.o: $(UTILDIR)/mode.h
+loop.o: $(UTILDIR)/random.h
+loop.o: $(UTILDIR)/automata.h
+lyapunov.o: $(UTILDIR)/xlock.h
+lyapunov.o: ../config.h
+lyapunov.o: $(UTILDIR)/mode.h
+lyapunov.o: $(UTILDIR)/random.h
+lyapunov.o: $(UTILDIR)/vis.h
+lyapunov.o: $(UTILDIR)/color.h
+mandelbrot.o: $(UTILDIR)/xlock.h
+mandelbrot.o: ../config.h
+mandelbrot.o: $(UTILDIR)/mode.h
+mandelbrot.o: $(UTILDIR)/random.h
+mandelbrot.o: $(UTILDIR)/vis.h
+mandelbrot.o: $(UTILDIR)/color.h
+marquee.o: $(UTILDIR)/xlock.h
+marquee.o: ../config.h
+marquee.o: $(UTILDIR)/mode.h
+marquee.o: $(UTILDIR)/random.h
+marquee.o: $(UTILDIR)/iostuff.h
+matrix.o: $(UTILDIR)/xlock.h
+matrix.o: ../config.h
+matrix.o: $(UTILDIR)/mode.h
+matrix.o: $(UTILDIR)/random.h
+maze.o: $(UTILDIR)/xlock.h
+maze.o: ../config.h
+maze.o: $(UTILDIR)/mode.h
+maze.o: $(UTILDIR)/random.h
+maze.o: $(UTILDIR)/color.h
+maze.o: $(UTILDIR)/iostuff.h
+maze.o: $(BITMAPDIR)/gray1.xbm
+maze.o: maze.xbm
+maze.o: maze.xpm
+mountain.o: $(UTILDIR)/xlock.h
+mountain.o: ../config.h
+mountain.o: $(UTILDIR)/mode.h
+mountain.o: $(UTILDIR)/random.h
+munch.o: $(UTILDIR)/xlock.h
+munch.o: ../config.h
+munch.o: $(UTILDIR)/mode.h
+munch.o: $(UTILDIR)/random.h
+nose.o: $(UTILDIR)/xlock.h
+nose.o: ../config.h
+nose.o: $(UTILDIR)/mode.h
+nose.o: $(UTILDIR)/random.h
+nose.o: $(UTILDIR)/iostuff.h
+nose.o: $(BITMAPDIR)/nose-hat.xbm
+nose.o: $(BITMAPDIR)/nose-hatd.xbm
+nose.o: $(BITMAPDIR)/nose-facef.xbm
+nose.o: $(BITMAPDIR)/nose-faced.xbm
+nose.o: $(BITMAPDIR)/nose-facel.xbm
+nose.o: $(BITMAPDIR)/nose-facer.xbm
+nose.o: $(BITMAPDIR)/nose-shoef.xbm
+nose.o: $(BITMAPDIR)/nose-shoel.xbm
+nose.o: $(BITMAPDIR)/nose-shoer.xbm
+nose.o: $(BITMAPDIR)/nose-stepl.xbm
+nose.o: $(BITMAPDIR)/nose-stepr.xbm
+pacman.o: $(UTILDIR)/xlock.h
+pacman.o: ../config.h
+pacman.o: $(UTILDIR)/mode.h
+pacman.o: $(UTILDIR)/random.h
+pacman.o: $(UTILDIR)/iostuff.h
+pacman.o: ghost.xbm
+penrose.o: $(UTILDIR)/xlock.h
+penrose.o: ../config.h
+penrose.o: $(UTILDIR)/mode.h
+penrose.o: $(UTILDIR)/random.h
+petal.o: $(UTILDIR)/xlock.h
+petal.o: ../config.h
+petal.o: $(UTILDIR)/mode.h
+petal.o: $(UTILDIR)/random.h
+puzzle.o: $(UTILDIR)/xlock.h
+puzzle.o: ../config.h
+puzzle.o: $(UTILDIR)/mode.h
+puzzle.o: $(UTILDIR)/random.h
+puzzle.o: $(UTILDIR)/color.h
+puzzle.o: $(UTILDIR)/iostuff.h
+puzzle.o: puzzle.xbm
+puzzle.o: puzzle.xpm
+pyro.o: $(UTILDIR)/xlock.h
+pyro.o: ../config.h
+pyro.o: $(UTILDIR)/mode.h
+pyro.o: $(UTILDIR)/random.h
+qix.o: $(UTILDIR)/xlock.h
+qix.o: ../config.h
+qix.o: $(UTILDIR)/mode.h
+qix.o: $(UTILDIR)/random.h
+roll.o: $(UTILDIR)/xlock.h
+roll.o: ../config.h
+roll.o: $(UTILDIR)/mode.h
+roll.o: $(UTILDIR)/random.h
+rotor.o: $(UTILDIR)/xlock.h
+rotor.o: ../config.h
+rotor.o: $(UTILDIR)/mode.h
+rotor.o: $(UTILDIR)/random.h
+shape.o: $(UTILDIR)/xlock.h
+shape.o: ../config.h
+shape.o: $(UTILDIR)/mode.h
+shape.o: $(UTILDIR)/random.h
+shape.o: $(BITMAPDIR)/gray1.xbm
+shape.o: $(BITMAPDIR)/gray3.xbm
+shape.o: $(BITMAPDIR)/stipple.xbm
+shape.o: $(BITMAPDIR)/cross_weave.xbm
+shape.o: $(BITMAPDIR)/dimple1.xbm
+shape.o: $(BITMAPDIR)/dimple3.xbm
+shape.o: $(BITMAPDIR)/flipped_gray.xbm
+shape.o: $(BITMAPDIR)/hlines2.xbm
+shape.o: $(BITMAPDIR)/light_gray.xbm
+shape.o: $(BITMAPDIR)/root_weave.xbm
+shape.o: $(BITMAPDIR)/vlines2.xbm
+shape.o: $(BITMAPDIR)/vlines3.xbm
+sierpinski.o: $(UTILDIR)/xlock.h
+sierpinski.o: ../config.h
+sierpinski.o: $(UTILDIR)/mode.h
+sierpinski.o: $(UTILDIR)/random.h
+slip.o: $(UTILDIR)/xlock.h
+slip.o: ../config.h
+slip.o: $(UTILDIR)/mode.h
+slip.o: $(UTILDIR)/random.h
+space.o: $(UTILDIR)/xlock.h
+space.o: ../config.h
+space.o: $(UTILDIR)/mode.h
+space.o: $(UTILDIR)/random.h
+sphere.o: $(UTILDIR)/xlock.h
+sphere.o: ../config.h
+sphere.o: $(UTILDIR)/mode.h
+sphere.o: $(UTILDIR)/random.h
+spiral.o: $(UTILDIR)/xlock.h
+spiral.o: ../config.h
+spiral.o: $(UTILDIR)/mode.h
+spiral.o: $(UTILDIR)/random.h
+spline.o: $(UTILDIR)/xlock.h
+spline.o: ../config.h
+spline.o: $(UTILDIR)/mode.h
+spline.o: $(UTILDIR)/random.h
+star.o: $(UTILDIR)/xlock.h
+star.o: ../config.h
+star.o: $(UTILDIR)/mode.h
+star.o: $(UTILDIR)/random.h
+star.o: $(BITMAPDIR)/trek-0.xbm
+star.o: $(BITMAPDIR)/trek-1.xbm
+starfish.o: $(UTILDIR)/xlock.h
+starfish.o: ../config.h
+starfish.o: $(UTILDIR)/mode.h
+starfish.o: $(UTILDIR)/random.h
+starfish.o: $(UTILDIR)/color.h
+starfish.o: $(UTILDIR)/spline.h
+strange.o: $(UTILDIR)/xlock.h
+strange.o: ../config.h
+strange.o: $(UTILDIR)/mode.h
+strange.o: $(UTILDIR)/random.h
+swarm.o: $(UTILDIR)/xlock.h
+swarm.o: ../config.h
+swarm.o: $(UTILDIR)/mode.h
+swarm.o: $(UTILDIR)/random.h
+swirl.o: $(UTILDIR)/xlock.h
+swirl.o: ../config.h
+swirl.o: $(UTILDIR)/mode.h
+swirl.o: $(UTILDIR)/random.h
+swirl.o: $(UTILDIR)/vis.h
+swirl.o: $(UTILDIR)/color.h
+tetris.o: $(UTILDIR)/xlock.h
+tetris.o: ../config.h
+tetris.o: $(UTILDIR)/mode.h
+tetris.o: $(UTILDIR)/random.h
+tetris.o: $(UTILDIR)/color.h
+tetris.o: $(BITMAPDIR)/rot00.xbm
+tetris.o: $(BITMAPDIR)/rot01.xbm
+tetris.o: $(BITMAPDIR)/rot02.xbm
+tetris.o: $(BITMAPDIR)/rot03.xbm
+tetris.o: $(BITMAPDIR)/rot04.xbm
+tetris.o: $(BITMAPDIR)/rot05.xbm
+tetris.o: $(BITMAPDIR)/rot06.xbm
+tetris.o: $(BITMAPDIR)/rot07.xbm
+tetris.o: $(BITMAPDIR)/rot08.xbm
+tetris.o: $(BITMAPDIR)/rot09.xbm
+tetris.o: $(BITMAPDIR)/rot10.xbm
+tetris.o: $(BITMAPDIR)/rot11.xbm
+tetris.o: $(BITMAPDIR)/rot12.xbm
+tetris.o: $(BITMAPDIR)/rot13.xbm
+tetris.o: $(BITMAPDIR)/rot14.xbm
+tetris.o: $(BITMAPDIR)/rot15.xbm
+thornbird.o: $(UTILDIR)/xlock.h
+thornbird.o: ../config.h
+thornbird.o: $(UTILDIR)/mode.h
+thornbird.o: $(UTILDIR)/random.h
+triangle.o: $(UTILDIR)/xlock.h
+triangle.o: ../config.h
+triangle.o: $(UTILDIR)/mode.h
+triangle.o: $(UTILDIR)/random.h
+tube.o: $(UTILDIR)/xlock.h
+tube.o: ../config.h
+tube.o: $(UTILDIR)/mode.h
+tube.o: $(UTILDIR)/random.h
+tube.o: $(UTILDIR)/vis.h
+tube.o: $(UTILDIR)/color.h
+turtle.o: $(UTILDIR)/xlock.h
+turtle.o: ../config.h
+turtle.o: $(UTILDIR)/mode.h
+turtle.o: $(UTILDIR)/random.h
+vines.o: $(UTILDIR)/xlock.h
+vines.o: ../config.h
+vines.o: $(UTILDIR)/mode.h
+vines.o: $(UTILDIR)/random.h
+voters.o: $(UTILDIR)/xlock.h
+voters.o: ../config.h
+voters.o: $(UTILDIR)/mode.h
+voters.o: $(UTILDIR)/random.h
+voters.o: $(UTILDIR)/automata.h
+voters.o: $(BITMAPDIR)/sickle.xbm
+voters.o: $(BITMAPDIR)/donkey.xbm
+voters.o: $(BITMAPDIR)/elephant.xbm
+wator.o: $(UTILDIR)/xlock.h
+wator.o: ../config.h
+wator.o: $(UTILDIR)/mode.h
+wator.o: $(UTILDIR)/random.h
+wator.o: $(UTILDIR)/automata.h
+wator.o: $(BITMAPDIR)/fish-0.xbm
+wator.o: $(BITMAPDIR)/fish-1.xbm
+wator.o: $(BITMAPDIR)/fish-2.xbm
+wator.o: $(BITMAPDIR)/fish-3.xbm
+wator.o: $(BITMAPDIR)/fish-4.xbm
+wator.o: $(BITMAPDIR)/fish-5.xbm
+wator.o: $(BITMAPDIR)/fish-6.xbm
+wator.o: $(BITMAPDIR)/fish-7.xbm
+wator.o: $(BITMAPDIR)/shark-0.xbm
+wator.o: $(BITMAPDIR)/shark-1.xbm
+wator.o: $(BITMAPDIR)/shark-2.xbm
+wator.o: $(BITMAPDIR)/shark-3.xbm
+wator.o: $(BITMAPDIR)/shark-4.xbm
+wator.o: $(BITMAPDIR)/shark-5.xbm
+wator.o: $(BITMAPDIR)/shark-6.xbm
+wator.o: $(BITMAPDIR)/shark-7.xbm
+wire.o: $(UTILDIR)/xlock.h
+wire.o: ../config.h
+wire.o: $(UTILDIR)/mode.h
+wire.o: $(UTILDIR)/random.h
+wire.o: $(UTILDIR)/automata.h
+world.o: $(UTILDIR)/xlock.h
+world.o: ../config.h
+world.o: $(UTILDIR)/mode.h
+world.o: $(UTILDIR)/random.h
+world.o: $(BITMAPDIR)/terra-00.xbm
+world.o: $(BITMAPDIR)/terra-01.xbm
+world.o: $(BITMAPDIR)/terra-02.xbm
+world.o: $(BITMAPDIR)/terra-03.xbm
+world.o: $(BITMAPDIR)/terra-04.xbm
+world.o: $(BITMAPDIR)/terra-05.xbm
+world.o: $(BITMAPDIR)/terra-06.xbm
+world.o: $(BITMAPDIR)/terra-07.xbm
+world.o: $(BITMAPDIR)/terra-08.xbm
+world.o: $(BITMAPDIR)/terra-09.xbm
+world.o: $(BITMAPDIR)/terra-10.xbm
+world.o: $(BITMAPDIR)/terra-11.xbm
+world.o: $(BITMAPDIR)/terra-12.xbm
+world.o: $(BITMAPDIR)/terra-13.xbm
+world.o: $(BITMAPDIR)/terra-14.xbm
+world.o: $(BITMAPDIR)/terra-15.xbm
+world.o: $(BITMAPDIR)/terra-16.xbm
+world.o: $(BITMAPDIR)/terra-17.xbm
+world.o: $(BITMAPDIR)/terra-18.xbm
+world.o: $(BITMAPDIR)/terra-19.xbm
+world.o: $(BITMAPDIR)/terra-20.xbm
+world.o: $(BITMAPDIR)/terra-21.xbm
+world.o: $(BITMAPDIR)/terra-22.xbm
+world.o: $(BITMAPDIR)/terra-23.xbm
+world.o: $(BITMAPDIR)/terra-24.xbm
+world.o: $(BITMAPDIR)/terra-25.xbm
+world.o: $(BITMAPDIR)/terra-26.xbm
+world.o: $(BITMAPDIR)/terra-27.xbm
+world.o: $(BITMAPDIR)/terra-28.xbm
+world.o: $(BITMAPDIR)/terra-29.xbm
+worm.o: $(UTILDIR)/xlock.h
+worm.o: ../config.h
+worm.o: $(UTILDIR)/mode.h
+worm.o: $(UTILDIR)/random.h
+xjack.o: $(UTILDIR)/xlock.h
+xjack.o: ../config.h
+xjack.o: $(UTILDIR)/mode.h
+xjack.o: $(UTILDIR)/random.h
+xjack.o: $(UTILDIR)/iostuff.h
+bomb.o: $(UTILDIR)/xlock.h
+bomb.o: ../config.h
+bomb.o: $(UTILDIR)/mode.h
+bomb.o: $(UTILDIR)/random.h
+bomb.o: $(UTILDIR)/iostuff.h
+blank.o: $(UTILDIR)/xlock.h
+blank.o: ../config.h
+blank.o: $(UTILDIR)/mode.h
+blank.o: $(UTILDIR)/random.h
+random.o: $(UTILDIR)/xlock.h
+random.o: ../config.h
+random.o: $(UTILDIR)/mode.h
+random.o: $(UTILDIR)/random.h
+random.o: $(UTILDIR)/color.h
+random.o: $(UTILDIR)/util.h
+
diff --git a/xlockmore-4.14/modes/Makefile.inxs b/xlockmore-4.14/modes/Makefile.inxs
new file mode 100644 (file)
index 0000000..992fbb8
--- /dev/null
@@ -0,0 +1,1721 @@
+# xlockmore/modes/Makefile.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski.
+# the `../../configure' script generates `xlockmore/modes/Makefile' from this file.
+
+@SET_MAKE@
+.SUFFIXES:
+.SUFFIXES: .c .o
+
+srcdir         = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH          = @srcdir@
+
+install_prefix =
+prefix         = @prefix@
+exec_prefix    = @exec_prefix@
+bindir         = @bindir@
+mandir         = @mandir@
+man1dir                = $(mandir)/man1
+mansuffix      = 1
+
+CC             = @CC@
+CFLAGS         = @CFLAGS@
+LDFLAGS                = @LDFLAGS@
+DEFS           = -DSTANDALONE @DEFS@
+LIBS           = @LIBS@
+
+DEPEND         = @DEPEND@
+DEPEND_FLAGS   = @DEPEND_FLAGS@
+DEPEND_DEFINES = @DEPEND_DEFINES@
+
+SHELL          = /bin/sh
+INSTALL                = @INSTALL@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_DATA   = @INSTALL_DATA@
+HACKDIR                = @HACKDIR@
+
+X_CFLAGS       = @X_CFLAGS@
+X_LIBS         = @X_LIBS@
+X_PRE_LIBS     = @X_PRE_LIBS@
+X_EXTRA_LIBS   = @X_EXTRA_LIBS@
+
+HACK_PRE  = $(LIBS) $(X_LIBS) $(X_PRE_LIBS)
+HACK_POST = -lXt -lX11 -lXext $(X_EXTRA_LIBS) -lm
+HACK_LIBS = $(HACK_PRE)            @HACK_LIBS@ $(HACK_POST)
+XPM_LIBS  = $(HACK_PRE) @XPM_LIBS@ @HACK_LIBS@ $(HACK_POST)
+XLOCK_LIBS  = $(HACK_LIBS)
+
+#XS    = $(topdir)
+XS     = $(srcdir)/../..
+HACK_SRC       = $(XS)/hacks
+HACK_BIN       = ../../hacks
+UTILS_SRC      = $(XS)/utils
+UTILS_BIN      = ../../utils
+XLOCK_SRC      = $(XS)/xlockmore/xlock
+XLOCK_BIN      = ../xlock
+
+INCLUDES       = -I$(srcdir) -I$(XLOCK_SRC) -I$(UTILS_SRC) -I$(HACK_SRC) \
+                 -I$(HACK_SRC)/.. -I.. @INCLUDES@
+
+UTIL_SRCS = $(UTILS_SRC)/alpha.c $(UTILS_SRC)/colors.c \
+      $(UTILS_SRC)/grabscreen.c $(UTILS_SRC)/hsv.c \
+      $(UTILS_SRC)/resources.c $(UTILS_SRC)/spline.c \
+      $(UTILS_SRC)/usleep.c $(UTILS_SRC)/visual.c \
+      $(UTILS_SRC)/xroger.c $(UTILS_SRC)/yarandom.c \
+      $(UTILS_SRC)/erase.c $(UTILS_SRC)/sgivideo.c
+
+XLOCKMORE_SRCS = $(XLOCK_SRC)/automata.c $(XLOCK_SRC)/iostuff.c $(XLOCK_SRC)/spline.c $(XLOCK_SRC)/xbm.c
+
+UTIL_OBJS = $(UTILS_BIN)/alpha.o $(UTILS_BIN)/colors.o \
+      $(UTILS_BIN)/grabscreen.o $(UTILS_BIN)/hsv.o \
+      $(UTILS_BIN)/resources.o $(UTILS_BIN)/spline.o \
+      $(UTILS_BIN)/usleep.o $(UTILS_BIN)/visual.o \
+      $(UTILS_BIN)/xroger.o $(UTILS_BIN)/yarandom.o \
+      $(UTILS_BIN)/erase.o $(UTILS_BIN)/sgivideo.o
+
+XLOCKMORE_OBJS = $(XLOCK_BIN)/automata.o $(XLOCK_BIN)/iostuff.o $(XLOCK_BIN)/spline.o $(XLOCK_BIN)/xbm.o
+
+#
+
+XLOCKMODEOBJS = ant.o ball.o bat.o blot.o \
+bouboule.o bounce.o braid.o bubble.o bug.o \
+clock.o coral.o crystal.o \
+daisy.o deco.o dclock.o demon.o dilemma.o discrete.o drift.o \
+eyes.o fadeplot.o flag.o flame.o flow.o forest.o \
+galaxy.o goop.o grav.o \
+helix.o hop.o hyper.o \
+ico.o ifs.o image.o julia.o kaleid.o \
+laser.o life.o life1d.o life3d.o \
+lightning.o lisa.o lissie.o loop.o \
+mandelbrot.o marquee.o maze.o mountain.o munch.o nose.o \
+pacman.o penrose.o petal.o puzzle.o pyro.o \
+qix.o roll.o rotor.o \
+shape.o sierpinski.o slip.o \
+sphere.o spiral.o spline.o \
+star.o strange.o swarm.o swirl.o \
+thornbird.o triangle.o tube.o turtle.o \
+vines.o voters.o \
+wator.o wire.o world.o worm.o \
+cartoon.o blank.o bomb.o
+# @XPM@XLOCKXPMOBJS = cartoon.o
+# @BOMB@XLOCKBOMBOBJS = $(DOM)bomb.o
+# XLOCKUTILMODEOBJS = $(XLOCKBOMBOBJS)$(S)$(DOM)blank.o random.o
+XLOCKALLMODEOBJS = $(XLOCKMODEOBJS)$(S)\
+$(XLOCKXPMOBJS)$(S)$(XLOCKGLOBJS)$(S)$(XLOCKUTILMODEOBJS)
+XLOCKALLUTILOBJS = $(XLOCKUTILOBJS)$(XLOCKDEBUGOBJS)
+OBJS = $(XLOCKALLUTILOBJS)$(S)$(XLOCKALLMODEOBJS)
+
+# List of source files
+BITMAPS = eyes.xbm flag.xbm ghost.xbm image.xbm life.xbm life1d.xbm \
+maze.xbm puzzle.xbm
+PIXMAPS = flag.xpm image.xpm maze.xpm puzzle.xpm
+
+XLOCKMODESRCS = ant.c ball.c bat.c blot.c \
+bouboule.c bounce.c braid.c bubble.c bug.c \
+clock.c coral.c crystal.c \
+daisy.c dclock.c deco.c demon.c dilemma.c discrete.c drift.c \
+eyes.c fadeplot.c flag.c flame.c flow.c forest.c \
+galaxy.c goop.c grav.c \
+helix.c hop.c hyper.c \
+ico.c ifs.c image.c julia.c kaleid.c \
+laser.c life.c life1d.c life3d.c \
+lightning.c lisa.c lissie.c loop.c \
+mandelbrot.c marquee.c maze.c mountain.c munch.c nose.c \
+pacman.c penrose.c petal.c puzzle.c pyro.c \
+qix.c roll.c rotor.c \
+shape.c sierpinski.c slip.c \
+sphere.c spiral.c spline.c \
+star.c strange.c swarm.c swirl.c \
+thornbird.c triangle.c tube.c turtle.c \
+vines.c voters.c \
+wator.c wire.c world.c worm.c \
+cartoon.c blank.c bomb.c
+# @XPM@XLOCKXPMSRCS = cartoon.c
+# @BOMB@XLOCKBOMBSRCS = bomb.c
+# XLOCKUTILMODESRCS = $(XLOCKBOMBSRCS) blank.c random.c
+SRCS = $(XLOCKUTILSRCS) $(XLOCKXPMSRCS) $(XLOCKGLSRCS) \
+$(XLOCKMODESRCS) $(XLOCKUTILMODESRCS)
+
+XLOCKMODEEXES  = ant ball bat blot \
+bouboule bounce braid bubble bug \
+clock coral crystal \
+daisy dclock deco demon dilemma discrete drift \
+eyes fadeplot flame flag flow forest \
+galaxy goop grav \
+helix hop hyper \
+ico ifs image julia kaleid \
+laser life life1d life3d \
+lightning lisa lissie loop \
+mandelbrot marquee maze mountain munch nose \
+pacman penrose petal puzzle pyro \
+qix roll rotor \
+shape sierpinski slip \
+sphere spiral spline \
+star strange swarm swirl \
+thornbird triangle tube turtle \
+vines voters \
+wator wire world worm \
+cartoon blank bomb
+# @XPM@XLOCKXPMEXES = cartoon
+# @BOMB@XLOCKBOMBEXES = bomb
+# XLOCKUTILMODEEXES = $(XLOCKBOMBEXES) blank random
+EXES = $(XLOCKUTILEXES) $(XLOCKXPMEXES) $(XLOCKGLEXES) \
+$(XLOCKMODEEXES) $(XLOCKUTILMODEEXES)
+
+HACK_OBJS_1 = $(UTILS_BIN)/resources.o $(UTILS_BIN)/visual.o \
+ $(UTILS_BIN)/usleep.o $(UTILS_BIN)/yarandom.o @XMU_OBJS@
+HACK_OBJS = $(HACK_BIN)/screenhack.o $(HACK_OBJS_1)
+XLOCK_OBJS  = $(HACK_BIN)/screenhack-xlock.o $(XLOCK_BIN)/xlock.o $(COLOR_OBJS) $(HACK_OBJS_1)
+COLOR_OBJS  = $(UTILS_BIN)/hsv.o $(UTILS_BIN)/colors.o
+GRAB_OBJS_1 = $(UTILS_BIN)/grabscreen.o $(SGI_VIDEO_OBJS)
+GRAB_OBJS = $(GRAB_OBJS_1) $(COLOR_OBJS)
+GRAB_LIBS = $(SGI_VIDEO_LIBS)
+
+HDRS           =
+MEN            = 
+EXTRAS         = README Makefile.in
+
+TARFILES       = $(SRCS) $(HDRS) $(MEN) $(EXTRAS)
+
+
+all: $(EXES)
+
+install:   install-program   install-man
+uninstall: uninstall-program uninstall-man
+
+install-strip:
+       $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install
+
+install-program:
+       @exes="$(EXES)" ;                                               \
+       for program in $$exes; do                                       \
+         echo $(INSTALL_PROGRAM) $$program $(HACKDIR)/$$program ;      \
+         $(INSTALL_PROGRAM) $$program $(HACKDIR)/$$program ;           \
+       done
+
+install-man:
+       @men="$(MEN)" ;                                                 \
+       for man in $$men; do                                            \
+         instname=`echo $$man | sed 's/\.man$$/\.$(mansuffix)/'` ;     \
+         echo $(INSTALL_DATA) $(srcdir)/$$man $(man1dir)/$$instname ;  \
+         $(INSTALL_DATA) $(srcdir)/$$man $(man1dir)/$$instname ;       \
+       done
+
+uninstall-program:
+       @for program in $(EXES); do                                     \
+         echo rm -f $(HACKDIR)/$$program ;                             \
+         rm -f $(HACKDIR)/$$program ;                                  \
+       done
+
+uninstall-man:
+       @men="$(MEN)" ;                                                 \
+       for man in $$men; do                                            \
+         instname=`echo $$man | sed 's/\.man$$/\.$(mansuffix)/'` ;     \
+         echo rm -f $(man1dir)/$$instname ;                            \
+         rm -f $(man1dir)/$$instname ;                                 \
+       done
+
+clean:
+       -rm -f *.o a.out core $(EXES)
+
+distclean: clean
+       -rm -f Makefile *~ "#"*
+
+# Adds all current dependencies to Makefile
+depend:
+       $(DEPEND) -s '# DO NOT DELETE: updated by make depend'              \
+       $(DEPEND_FLAGS) --                                                  \
+       $(INCLUDES) $(DEFS) $(DEPEND_DEFINES) $(CFLAGS) $(X_CFLAGS) --      \
+       $(SRCS)
+
+# Adds some dependencies to Makefile.in -- not totally accurate, but pretty
+# close.  This excludes dependencies on files in /usr/include, etc.  It tries
+# to include only dependencies on files which are themselves a part of this
+# package.
+distdepend:
+       @echo updating dependencies in `pwd`/Makefile.in... ;               \
+       $(DEPEND) -w 0 -f -                                                 \
+       -s '# DO NOT DELETE: updated by make distdepend' $(DEPEND_FLAGS) -- \
+       $(INCLUDES) $(DEFS) $(DEPEND_DEFINES) $(CFLAGS) $(X_CFLAGS) --      \
+       $(SRCS) |                                                           \
+       (                                                                   \
+         awk '/^# .*Makefile.in ---/,/^# DO .*distdepend/' < Makefile.in ; \
+         sed -e 's@ \./@ @g;s@ /[^ ]*@@g;/^.*:$$/d'                        \
+             -e 's@\.\./\.\./utils@$$(UTILS_SRC)@g'                        \
+             -e 's@\.\./glx/@@g'                                           \
+             -e 's@ \.\./@ $$(HACK_SRC)/@g'                                \
+             -e 's@ \([^$$]\)@ $$(srcdir)/\1@g'                            \
+             -e 's@ $$(srcdir)/\(.*config.h\)@ \1@g' ;                     \
+         echo ''                                                           \
+       ) > /tmp/distdepend.$$$$ &&                                         \
+       mv Makefile.in Makefile.in.bak &&                                   \
+       mv /tmp/distdepend.$$$$ Makefile.in
+
+TAGS: tags
+tags:
+       find $(srcdir) -name '*.[chly]' -print | xargs etags -a
+
+echo_tarfiles:
+       @echo $(TARFILES)
+
+BITMAPTYPE = x11
+PIXMAPTYPE = x11
+#BITMAPTYPE = @BITMAPTYPE@
+#PIXMAPTYPE = @PIXMAPTYPE@
+
+# Here is your chance to override the default icon:
+TINYBITMAP = $(BITMAPTYPE)
+TINYBITMAP = t-x11
+SMALLBITMAP = s-$(BITMAPTYPE)
+MEDIUMBITMAP = m-$(BITMAPTYPE)
+LARGEBITMAP = l-$(BITMAPTYPE)
+MEDIUMPIXMAP = m-$(PIXMAPTYPE)
+LARGEPIXMAP = l-$(PIXMAPTYPE)
+
+#EYESBITMAP = $(MEDIUMBITMAP)
+EYESBITMAP = m-grelb
+FLAGBITMAP = $(MEDIUMBITMAP)
+IMAGEBITMAP = $(MEDIUMBITMAP)
+#IMAGEBITMAP = l-bob #Slackware icon
+#IMAGEBITMAP = m-xlock #XLock icon
+LIFEBITMAP = $(TINYBITMAP)
+#LIFEBITMAP = $(SMALLBITMAP)
+#LIFEBITMAP = s-grelb
+LIFE1DBITMAP = $(TINYBITMAP)
+MAZEBITMAP = $(LARGEBITMAP)
+#MAZEBITMAP = m-xlock
+#PACMANBITMAP = $(MEDIUMBITMAP)
+PACMANBITMAP = m-ghost
+#PUZZLEBITMAP = $(LARGEBITMAP)
+PUZZLEBITMAP = l-xlock
+#PUZZLEBITMAP = l-linux
+FLAGPIXMAP = $(MEDIUMPIXMAP)
+#FLAGPIXMAP = m-xlock
+IMAGEPIXMAP = $(MEDIUMPIXMAP)
+#IMAGEPIXMAP = m-xlock
+MAZEPIXMAP = $(MEDIUMPIXMAP)
+#MAZEPIXMAP = m-xlock
+#PUZZLEPIXMAP = $(LARGEPIXMAP)
+PUZZLEPIXMAP = l-xlock
+#PUZZLEPIXMAP = l-linux
+
+eyes.o: eyes.c eyes.xbm
+life.o : life.c life.xbm
+life1d.o : life1d.c life1d.xbm
+pacman.o : pacman.c ghost.xbm
+# Do not need xpm files if not using them but not worth figuring out
+flag.o : flag.c flag.xbm flag.xpm
+image.o : image.c image.xbm image.xpm
+maze.o : maze.c maze.xbm maze.xpm
+puzzle.o : puzzle.c puzzle.xbm puzzle.xpm
+
+BITMAPDIR = $(HACK_SRC)/../xlockmore/bitmaps/
+PIXMAPDIR = $(HACK_SRC)/../xlockmore/pixmaps/
+LN_S = ln -s
+
+eyes.xbm : $(BITMAPDIR)$(EYESBITMAP).xbm
+       $(RM) eyes.xbm ; $(LN_S) $(BITMAPDIR)$(EYESBITMAP).xbm eyes.xbm
+
+flag.xbm : $(BITMAPDIR)$(FLAGBITMAP).xbm
+       $(RM) flag.xbm ; $(LN_S) $(BITMAPDIR)$(FLAGBITMAP).xbm flag.xbm
+
+image.xbm : $(BITMAPDIR)$(IMAGEBITMAP).xbm
+       $(RM) image.xbm ; $(LN_S) $(BITMAPDIR)$(IMAGEBITMAP).xbm image.xbm
+
+ghost.xbm : $(BITMAPDIR)$(PACMANBITMAP).xbm
+       $(RM) ghost.xbm ; $(LN_S) $(BITMAPDIR)$(PACMANBITMAP).xbm ghost.xbm
+
+life.xbm : $(BITMAPDIR)$(LIFEBITMAP).xbm
+       $(RM) life.xbm ; $(LN_S) $(BITMAPDIR)$(LIFEBITMAP).xbm life.xbm
+
+life1d.xbm : $(BITMAPDIR)$(LIFE1DBITMAP).xbm
+       $(RM) life1d.xbm ; $(LN_S) $(BITMAPDIR)$(LIFE1DBITMAP).xbm life1d.xbm
+
+maze.xbm : $(BITMAPDIR)$(MAZEBITMAP).xbm
+       $(RM) maze.xbm ; $(LN_S) $(BITMAPDIR)$(MAZEBITMAP).xbm maze.xbm
+
+puzzle.xbm : $(BITMAPDIR)$(PUZZLEBITMAP).xbm
+       $(RM) puzzle.xbm ; $(LN_S) $(BITMAPDIR)$(PUZZLEBITMAP).xbm puzzle.xbm
+
+flag.xpm : $(PIXMAPDIR)$(FLAGPIXMAP).xpm
+       $(RM) flag.xpm ; $(LN_S) $(PIXMAPDIR)$(FLAGPIXMAP).xpm flag.xpm
+
+image.xpm : $(PIXMAPDIR)$(IMAGEPIXMAP).xpm
+       $(RM) image.xpm ; $(LN_S) $(PIXMAPDIR)$(IMAGEPIXMAP).xpm image.xpm
+
+maze.xpm : $(PIXMAPDIR)$(MAZEPIXMAP).xpm
+       $(RM) maze.xpm ; $(LN_S) $(PIXMAPDIR)$(MAZEPIXMAP).xpm maze.xpm
+
+puzzle.xpm : $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm
+       $(RM) puzzle.xpm ; $(LN_S) $(PIXMAPDIR)$(PUZZLEPIXMAP).xpm puzzle.xpm
+
+# Rules for noticing when the objects from the utils directory are out of
+# date with respect to their sources, and going and building them according
+# to the rules in their own Makefile...
+#
+$(UTILS_BIN)/alpha.o:   $(UTILS_SRC)/alpha.c
+$(UTILS_BIN)/colors.o:    $(UTILS_SRC)/colors.c
+$(UTILS_BIN)/grabscreen.o:  $(UTILS_SRC)/grabscreen.c
+$(UTILS_BIN)/sgivideo.o:  $(UTILS_SRC)/sgivideo.c
+$(UTILS_BIN)/hsv.o:   $(UTILS_SRC)/hsv.c
+$(UTILS_BIN)/resources.o: $(UTILS_SRC)/resources.c
+$(UTILS_BIN)/spline.o:    $(UTILS_SRC)/spline.c
+$(UTILS_BIN)/usleep.o:    $(UTILS_SRC)/usleep.c
+$(UTILS_BIN)/visual.o:    $(UTILS_SRC)/visual.c
+$(UTILS_BIN)/xmu.o:   $(UTILS_SRC)/xmu.c
+$(UTILS_BIN)/xroger.o:    $(UTILS_SRC)/xroger.c
+$(UTILS_BIN)/yarandom.o:  $(UTILS_SRC)/yarandom.c
+$(UTILS_BIN)/erase.o:   $(UTILS_SRC)/erase.c
+
+$(XLOCK_BIN)/automata.o:   $(XLOCK_SRC)/automata.c
+$(XLOCK_BIN)/iostuff.o:   $(XLOCK_SRC)/iostuff.c
+$(XLOCK_BIN)/xbm.o:   $(XLOCK_SRC)/xbm.c
+$(XLOCK_BIN)/spline.o:   $(XLOCK_SRC)/spline.c
+
+$(UTIL_OBJS):
+       cd $(UTILS_BIN) ; \
+       $(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+
+$(XLOCKMORE_OBJS):
+       cd $(XLOCK_BIN) ; \
+       $(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+
+# How we build object files in this directory.
+.c.o:
+       $(CC) -c $(INCLUDES) $(DEFS) $(CFLAGS) $(X_CFLAGS) $<
+
+# Some hacks use a slightly-differently-compiled variant of this file.
+# This is how to make the the other .o file from it.
+#
+$(HACK_BIN)/screenhack-xlock.o: $(HACK_SRC)/screenhack.c
+       $(CC) -o $@ -c $(INCLUDES) $(DEFS) $(CFLAGS) $(X_CFLAGS) \
+ -DXLOCKMORE $(HACK_SRC)/screenhack.c
+
+# Some abbreviations to keep the lines short...
+ALP   = $(HSV) $(UTILS_BIN)/alpha.o
+HSV   = $(UTILS_BIN)/hsv.o
+#SPL   = $(UTILS_BIN)/spline.o
+XROG    = $(UTILS_BIN)/xroger.o $(SPL)
+GRAB    = $(GRAB_OBJS)
+ERASE   = $(UTILS_BIN)/erase.o
+AUTOMATA   = $(XLOCK_BIN)/automata.o
+IOSTUFF   = $(XLOCK_BIN)/iostuff.o $(XLOCK_BIN)/xbm.o
+SPLINE   = $(XLOCK_BIN)/spline.o
+COL   = $(COLOR_OBJS)
+
+$(XLOCK_BIN)/xlock.o: $(XLOCK_SRC)/xlock.c
+       cd $(XLOCK_BIN)  ; $(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)"
+
+
+CC_HACK                = $(CC) $(LDFLAGS)
+
+ant:           ant.o   $(XLOCK_OBJS) $(AUTOMATA) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(ERASE) $(HACK_LIBS)
+
+ball:          ball.o  $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+bat:           bat.o   $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(XPM_LIBS)
+
+blank:         blank.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+blot:          blot.o          $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+bomb:          bomb.o          $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(HACK_LIBS)
+
+bouboule:              bouboule.o              $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+bounce:                bounce.o                $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+braid:         braid.o         $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+bubble:                bubble.o                $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+bug:           bug.o           $(XLOCK_OBJS) $(AUTOMATA)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(HACK_LIBS)
+
+cartoon:               cartoon.o               $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(XPM_LIBS)
+
+clock:         clock.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+coral:         coral.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+crystal:               crystal.o               $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+daisy:         daisy.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+dclock:                dclock.o                $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(HACK_LIBS)
+
+deco:          deco.o          $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+demon:         demon.o         $(XLOCK_OBJS) $(AUTOMATA)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(HACK_LIBS)
+
+dilemma:               dilemma.o               $(XLOCK_OBJS) $(AUTOMATA)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(HACK_LIBS)
+
+discrete:              discrete.o              $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+drift:         drift.o         $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+eyes:          eyes.o          $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(HACK_LIBS)
+
+fadeplot:              fadeplot.o              $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+flag:          flag.o          $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(XPM_LIBS)
+
+flame:         flame.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+flow:          flow.o          $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+forest:                forest.o                $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+galaxy:                galaxy.o                $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+goop:          goop.o          $(XLOCK_OBJS) $(SPLINE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(SPLINE) $(HACK_LIBS)
+
+grav:          grav.o          $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+helix:         helix.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+hop:           hop.o           $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+hyper:         hyper.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+ico:           ico.o           $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+ifs:           ifs.o           $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+image:         image.o         $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(XPM_LIBS)
+
+julia:         julia.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+kaleid:                kaleid.o                $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+laser:         laser.o         $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+life:          life.o          $(XLOCK_OBJS) $(AUTOMATA) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(IOSTUFF) $(HACK_LIBS)
+
+life1d:                life1d.o        $(XLOCK_OBJS) $(AUTOMATA) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(IOSTUFF) $(HACK_LIBS)
+
+life3d:                life3d.o        $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(HACK_LIBS)
+
+lightning:  lightning.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+lisa:   lisa.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+lissie:   lissie.o      $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+loop:   loop.o  $(XLOCK_OBJS) $(AUTOMATA)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(HACK_LIBS)
+
+mandelbrot:   mandelbrot.o      $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+marquee:   marquee.o    $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(HACK_LIBS)
+
+maze:   maze.o  $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(XPM_LIBS)
+
+mountain: mountain.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+munch: munch.o  $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+nose:  nose.o  $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(HACK_LIBS)
+
+pacman:  pacman.o      $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(HACK_LIBS)
+
+penrose:  penrose.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+petal:  petal.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+puzzle:  puzzle.o      $(XLOCK_OBJS) $(IOSTUFF)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(IOSTUFF) $(XPM_LIBS)
+
+pyro:  pyro.o  $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+qix:  qix.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+random:                random.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+roll:  roll.o  $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+rotor:    rotor.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+shape: shape.o  $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+sierpinski: sierpinski.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+slip:   slip.o    $(XLOCK_OBJS) $(GRAB)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(GRAB_OBJS_1) $(HACK_LIBS) $(GRAB_LIBS)
+
+sphere:   sphere.o      $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+spiral:   spiral.o      $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+spline:  spline.o      $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+star:  star.o  $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+strange:  strange.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+swarm:    swarm.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+swirl:    swirl.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+thornbird:             thornbird.o     $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+triangle: triangle.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+tube: tube.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+turtle: turtle.o        $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+vines:    vines.o          $(XLOCK_OBJS) $(ERASE)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS)
+
+voters:    voters.o        $(XLOCK_OBJS) $(AUTOMATA)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(HACK_LIBS)
+
+wator:   wator.o          $(XLOCK_OBJS) $(AUTOMATA)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(HACK_LIBS)
+
+wire:   wire.o    $(XLOCK_OBJS) $(AUTOMATA)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(AUTOMATA) $(HACK_LIBS)
+
+world:   world.o          $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+worm:   worm.o    $(XLOCK_OBJS)
+       $(CC_HACK) -o $@ $@.o   $(XLOCK_OBJS) $(HACK_LIBS)
+
+##############################################################################
+#
+# DO NOT DELETE: updated by make distdepend
+
+ant.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+ant.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+ant.o: $(HACK_SRC)/../config.h
+ant.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+ant.o: $(HACK_SRC)/../hacks/screenhack.h
+ant.o: $(UTILS_SRC)/yarandom.h
+ant.o: $(UTILS_SRC)/usleep.h
+ant.o: $(UTILS_SRC)/resources.h
+ant.o: $(UTILS_SRC)/hsv.h
+ant.o: $(UTILS_SRC)/colors.h
+ant.o: $(UTILS_SRC)/grabscreen.h
+ant.o: $(UTILS_SRC)/visual.h
+ant.o: $(UTILS_SRC)/erase.h
+ant.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+ball.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+ball.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+ball.o: $(HACK_SRC)/../config.h
+ball.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+ball.o: $(HACK_SRC)/../hacks/screenhack.h
+ball.o: $(UTILS_SRC)/yarandom.h
+ball.o: $(UTILS_SRC)/usleep.h
+ball.o: $(UTILS_SRC)/resources.h
+ball.o: $(UTILS_SRC)/hsv.h
+ball.o: $(UTILS_SRC)/colors.h
+ball.o: $(UTILS_SRC)/grabscreen.h
+ball.o: $(UTILS_SRC)/visual.h
+bat.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+bat.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+bat.o: $(HACK_SRC)/../config.h
+bat.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+bat.o: $(HACK_SRC)/../hacks/screenhack.h
+bat.o: $(UTILS_SRC)/yarandom.h
+bat.o: $(UTILS_SRC)/usleep.h
+bat.o: $(UTILS_SRC)/resources.h
+bat.o: $(UTILS_SRC)/hsv.h
+bat.o: $(UTILS_SRC)/colors.h
+bat.o: $(UTILS_SRC)/grabscreen.h
+bat.o: $(UTILS_SRC)/visual.h
+bat.o: $(HACK_SRC)/../xlockmore/bitmaps/bat-0.xbm
+bat.o: $(HACK_SRC)/../xlockmore/bitmaps/bat-1.xbm
+bat.o: $(HACK_SRC)/../xlockmore/bitmaps/bat-2.xbm
+bat.o: $(HACK_SRC)/../xlockmore/bitmaps/bat-3.xbm
+bat.o: $(HACK_SRC)/../xlockmore/bitmaps/bat-4.xbm
+blot.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+blot.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+blot.o: $(HACK_SRC)/../config.h
+blot.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+blot.o: $(HACK_SRC)/../hacks/screenhack.h
+blot.o: $(UTILS_SRC)/yarandom.h
+blot.o: $(UTILS_SRC)/usleep.h
+blot.o: $(UTILS_SRC)/resources.h
+blot.o: $(UTILS_SRC)/hsv.h
+blot.o: $(UTILS_SRC)/colors.h
+blot.o: $(UTILS_SRC)/grabscreen.h
+blot.o: $(UTILS_SRC)/visual.h
+bouboule.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+bouboule.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+bouboule.o: $(HACK_SRC)/../config.h
+bouboule.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+bouboule.o: $(HACK_SRC)/../hacks/screenhack.h
+bouboule.o: $(UTILS_SRC)/yarandom.h
+bouboule.o: $(UTILS_SRC)/usleep.h
+bouboule.o: $(UTILS_SRC)/resources.h
+bouboule.o: $(UTILS_SRC)/hsv.h
+bouboule.o: $(UTILS_SRC)/colors.h
+bouboule.o: $(UTILS_SRC)/grabscreen.h
+bouboule.o: $(UTILS_SRC)/visual.h
+bounce.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+bounce.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+bounce.o: $(HACK_SRC)/../config.h
+bounce.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+bounce.o: $(HACK_SRC)/../hacks/screenhack.h
+bounce.o: $(UTILS_SRC)/yarandom.h
+bounce.o: $(UTILS_SRC)/usleep.h
+bounce.o: $(UTILS_SRC)/resources.h
+bounce.o: $(UTILS_SRC)/hsv.h
+bounce.o: $(UTILS_SRC)/colors.h
+bounce.o: $(UTILS_SRC)/grabscreen.h
+bounce.o: $(UTILS_SRC)/visual.h
+bounce.o: $(HACK_SRC)/../xlockmore/bitmaps/bounce-0.xbm
+bounce.o: $(HACK_SRC)/../xlockmore/bitmaps/bounce-1.xbm
+bounce.o: $(HACK_SRC)/../xlockmore/bitmaps/bounce-2.xbm
+bounce.o: $(HACK_SRC)/../xlockmore/bitmaps/bounce-3.xbm
+bounce.o: $(HACK_SRC)/../xlockmore/bitmaps/bounce-mask.xbm
+braid.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+braid.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+braid.o: $(HACK_SRC)/../config.h
+braid.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+braid.o: $(HACK_SRC)/../hacks/screenhack.h
+braid.o: $(UTILS_SRC)/yarandom.h
+braid.o: $(UTILS_SRC)/usleep.h
+braid.o: $(UTILS_SRC)/resources.h
+braid.o: $(UTILS_SRC)/hsv.h
+braid.o: $(UTILS_SRC)/colors.h
+braid.o: $(UTILS_SRC)/grabscreen.h
+braid.o: $(UTILS_SRC)/visual.h
+braid.o: $(UTILS_SRC)/erase.h
+bubble.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+bubble.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+bubble.o: $(HACK_SRC)/../config.h
+bubble.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+bubble.o: $(HACK_SRC)/../hacks/screenhack.h
+bubble.o: $(UTILS_SRC)/yarandom.h
+bubble.o: $(UTILS_SRC)/usleep.h
+bubble.o: $(UTILS_SRC)/resources.h
+bubble.o: $(UTILS_SRC)/hsv.h
+bubble.o: $(UTILS_SRC)/colors.h
+bubble.o: $(UTILS_SRC)/grabscreen.h
+bubble.o: $(UTILS_SRC)/visual.h
+bug.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+bug.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+bug.o: $(HACK_SRC)/../config.h
+bug.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+bug.o: $(HACK_SRC)/../hacks/screenhack.h
+bug.o: $(UTILS_SRC)/yarandom.h
+bug.o: $(UTILS_SRC)/usleep.h
+bug.o: $(UTILS_SRC)/resources.h
+bug.o: $(UTILS_SRC)/hsv.h
+bug.o: $(UTILS_SRC)/colors.h
+bug.o: $(UTILS_SRC)/grabscreen.h
+bug.o: $(UTILS_SRC)/visual.h
+bug.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+clock.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+clock.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+clock.o: $(HACK_SRC)/../config.h
+clock.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+clock.o: $(HACK_SRC)/../hacks/screenhack.h
+clock.o: $(UTILS_SRC)/yarandom.h
+clock.o: $(UTILS_SRC)/usleep.h
+clock.o: $(UTILS_SRC)/resources.h
+clock.o: $(UTILS_SRC)/hsv.h
+clock.o: $(UTILS_SRC)/colors.h
+clock.o: $(UTILS_SRC)/grabscreen.h
+clock.o: $(UTILS_SRC)/visual.h
+coral.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+coral.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+coral.o: $(HACK_SRC)/../config.h
+coral.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+coral.o: $(HACK_SRC)/../hacks/screenhack.h
+coral.o: $(UTILS_SRC)/yarandom.h
+coral.o: $(UTILS_SRC)/usleep.h
+coral.o: $(UTILS_SRC)/resources.h
+coral.o: $(UTILS_SRC)/hsv.h
+coral.o: $(UTILS_SRC)/colors.h
+coral.o: $(UTILS_SRC)/grabscreen.h
+coral.o: $(UTILS_SRC)/visual.h
+crystal.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+crystal.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+crystal.o: $(HACK_SRC)/../config.h
+crystal.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+crystal.o: $(HACK_SRC)/../hacks/screenhack.h
+crystal.o: $(UTILS_SRC)/yarandom.h
+crystal.o: $(UTILS_SRC)/usleep.h
+crystal.o: $(UTILS_SRC)/resources.h
+crystal.o: $(UTILS_SRC)/hsv.h
+crystal.o: $(UTILS_SRC)/colors.h
+crystal.o: $(UTILS_SRC)/grabscreen.h
+crystal.o: $(UTILS_SRC)/visual.h
+daisy.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+daisy.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+daisy.o: $(HACK_SRC)/../config.h
+daisy.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+daisy.o: $(HACK_SRC)/../hacks/screenhack.h
+daisy.o: $(UTILS_SRC)/yarandom.h
+daisy.o: $(UTILS_SRC)/usleep.h
+daisy.o: $(UTILS_SRC)/resources.h
+daisy.o: $(UTILS_SRC)/hsv.h
+daisy.o: $(UTILS_SRC)/colors.h
+daisy.o: $(UTILS_SRC)/grabscreen.h
+daisy.o: $(UTILS_SRC)/visual.h
+dclock.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+dclock.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+dclock.o: $(HACK_SRC)/../config.h
+dclock.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+dclock.o: $(HACK_SRC)/../hacks/screenhack.h
+dclock.o: $(UTILS_SRC)/yarandom.h
+dclock.o: $(UTILS_SRC)/usleep.h
+dclock.o: $(UTILS_SRC)/resources.h
+dclock.o: $(UTILS_SRC)/hsv.h
+dclock.o: $(UTILS_SRC)/colors.h
+dclock.o: $(UTILS_SRC)/grabscreen.h
+dclock.o: $(UTILS_SRC)/visual.h
+dclock.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+deco.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+deco.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+deco.o: $(HACK_SRC)/../config.h
+deco.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+deco.o: $(HACK_SRC)/../hacks/screenhack.h
+deco.o: $(UTILS_SRC)/yarandom.h
+deco.o: $(UTILS_SRC)/usleep.h
+deco.o: $(UTILS_SRC)/resources.h
+deco.o: $(UTILS_SRC)/hsv.h
+deco.o: $(UTILS_SRC)/colors.h
+deco.o: $(UTILS_SRC)/grabscreen.h
+deco.o: $(UTILS_SRC)/visual.h
+demon.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+demon.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+demon.o: $(HACK_SRC)/../config.h
+demon.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+demon.o: $(HACK_SRC)/../hacks/screenhack.h
+demon.o: $(UTILS_SRC)/yarandom.h
+demon.o: $(UTILS_SRC)/usleep.h
+demon.o: $(UTILS_SRC)/resources.h
+demon.o: $(UTILS_SRC)/hsv.h
+demon.o: $(UTILS_SRC)/colors.h
+demon.o: $(UTILS_SRC)/grabscreen.h
+demon.o: $(UTILS_SRC)/visual.h
+demon.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+dilemma.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+dilemma.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+dilemma.o: $(HACK_SRC)/../config.h
+dilemma.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+dilemma.o: $(HACK_SRC)/../hacks/screenhack.h
+dilemma.o: $(UTILS_SRC)/yarandom.h
+dilemma.o: $(UTILS_SRC)/usleep.h
+dilemma.o: $(UTILS_SRC)/resources.h
+dilemma.o: $(UTILS_SRC)/hsv.h
+dilemma.o: $(UTILS_SRC)/colors.h
+dilemma.o: $(UTILS_SRC)/grabscreen.h
+dilemma.o: $(UTILS_SRC)/visual.h
+dilemma.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+dilemma.o: $(HACK_SRC)/../xlockmore/bitmaps/cooperat.xbm
+dilemma.o: $(HACK_SRC)/../xlockmore/bitmaps/defect.xbm
+discrete.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+discrete.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+discrete.o: $(HACK_SRC)/../config.h
+discrete.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+discrete.o: $(HACK_SRC)/../hacks/screenhack.h
+discrete.o: $(UTILS_SRC)/yarandom.h
+discrete.o: $(UTILS_SRC)/usleep.h
+discrete.o: $(UTILS_SRC)/resources.h
+discrete.o: $(UTILS_SRC)/hsv.h
+discrete.o: $(UTILS_SRC)/colors.h
+discrete.o: $(UTILS_SRC)/grabscreen.h
+discrete.o: $(UTILS_SRC)/visual.h
+discrete.o: $(UTILS_SRC)/erase.h
+drift.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+drift.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+drift.o: $(HACK_SRC)/../config.h
+drift.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+drift.o: $(HACK_SRC)/../hacks/screenhack.h
+drift.o: $(UTILS_SRC)/yarandom.h
+drift.o: $(UTILS_SRC)/usleep.h
+drift.o: $(UTILS_SRC)/resources.h
+drift.o: $(UTILS_SRC)/hsv.h
+drift.o: $(UTILS_SRC)/colors.h
+drift.o: $(UTILS_SRC)/grabscreen.h
+drift.o: $(UTILS_SRC)/visual.h
+drift.o: $(UTILS_SRC)/erase.h
+eyes.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+eyes.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+eyes.o: $(HACK_SRC)/../config.h
+eyes.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+eyes.o: $(HACK_SRC)/../hacks/screenhack.h
+eyes.o: $(UTILS_SRC)/yarandom.h
+eyes.o: $(UTILS_SRC)/usleep.h
+eyes.o: $(UTILS_SRC)/resources.h
+eyes.o: $(UTILS_SRC)/hsv.h
+eyes.o: $(UTILS_SRC)/colors.h
+eyes.o: $(UTILS_SRC)/grabscreen.h
+eyes.o: $(UTILS_SRC)/visual.h
+eyes.o: $(srcdir)/eyes.xbm
+fadeplot.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+fadeplot.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+fadeplot.o: $(HACK_SRC)/../config.h
+fadeplot.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+fadeplot.o: $(HACK_SRC)/../hacks/screenhack.h
+fadeplot.o: $(UTILS_SRC)/yarandom.h
+fadeplot.o: $(UTILS_SRC)/usleep.h
+fadeplot.o: $(UTILS_SRC)/resources.h
+fadeplot.o: $(UTILS_SRC)/hsv.h
+fadeplot.o: $(UTILS_SRC)/colors.h
+fadeplot.o: $(UTILS_SRC)/grabscreen.h
+fadeplot.o: $(UTILS_SRC)/visual.h
+flag.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+flag.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+flag.o: $(HACK_SRC)/../config.h
+flag.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+flag.o: $(HACK_SRC)/../hacks/screenhack.h
+flag.o: $(UTILS_SRC)/yarandom.h
+flag.o: $(UTILS_SRC)/usleep.h
+flag.o: $(UTILS_SRC)/resources.h
+flag.o: $(UTILS_SRC)/hsv.h
+flag.o: $(UTILS_SRC)/colors.h
+flag.o: $(UTILS_SRC)/grabscreen.h
+flag.o: $(UTILS_SRC)/visual.h
+flag.o: $(HACK_SRC)/../hacks/images/bob.xbm
+flame.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+flame.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+flame.o: $(HACK_SRC)/../config.h
+flame.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+flame.o: $(HACK_SRC)/../hacks/screenhack.h
+flame.o: $(UTILS_SRC)/yarandom.h
+flame.o: $(UTILS_SRC)/usleep.h
+flame.o: $(UTILS_SRC)/resources.h
+flame.o: $(UTILS_SRC)/hsv.h
+flame.o: $(UTILS_SRC)/colors.h
+flame.o: $(UTILS_SRC)/grabscreen.h
+flame.o: $(UTILS_SRC)/visual.h
+flow.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+flow.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+flow.o: $(HACK_SRC)/../config.h
+flow.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+flow.o: $(HACK_SRC)/../hacks/screenhack.h
+flow.o: $(UTILS_SRC)/yarandom.h
+flow.o: $(UTILS_SRC)/usleep.h
+flow.o: $(UTILS_SRC)/resources.h
+flow.o: $(UTILS_SRC)/hsv.h
+flow.o: $(UTILS_SRC)/colors.h
+flow.o: $(UTILS_SRC)/grabscreen.h
+flow.o: $(UTILS_SRC)/visual.h
+flow.o: $(UTILS_SRC)/erase.h
+forest.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+forest.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+forest.o: $(HACK_SRC)/../config.h
+forest.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+forest.o: $(HACK_SRC)/../hacks/screenhack.h
+forest.o: $(UTILS_SRC)/yarandom.h
+forest.o: $(UTILS_SRC)/usleep.h
+forest.o: $(UTILS_SRC)/resources.h
+forest.o: $(UTILS_SRC)/hsv.h
+forest.o: $(UTILS_SRC)/colors.h
+forest.o: $(UTILS_SRC)/grabscreen.h
+forest.o: $(UTILS_SRC)/visual.h
+forest.o: $(UTILS_SRC)/erase.h
+galaxy.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+galaxy.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+galaxy.o: $(HACK_SRC)/../config.h
+galaxy.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+galaxy.o: $(HACK_SRC)/../hacks/screenhack.h
+galaxy.o: $(UTILS_SRC)/yarandom.h
+galaxy.o: $(UTILS_SRC)/usleep.h
+galaxy.o: $(UTILS_SRC)/resources.h
+galaxy.o: $(UTILS_SRC)/hsv.h
+galaxy.o: $(UTILS_SRC)/colors.h
+galaxy.o: $(UTILS_SRC)/grabscreen.h
+galaxy.o: $(UTILS_SRC)/visual.h
+goop.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+goop.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+goop.o: $(HACK_SRC)/../config.h
+goop.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+goop.o: $(HACK_SRC)/../hacks/screenhack.h
+goop.o: $(UTILS_SRC)/yarandom.h
+goop.o: $(UTILS_SRC)/usleep.h
+goop.o: $(UTILS_SRC)/resources.h
+goop.o: $(UTILS_SRC)/hsv.h
+goop.o: $(UTILS_SRC)/colors.h
+goop.o: $(UTILS_SRC)/grabscreen.h
+goop.o: $(UTILS_SRC)/visual.h
+goop.o: $(HACK_SRC)/../xlockmore/xlock/spline.h
+grav.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+grav.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+grav.o: $(HACK_SRC)/../config.h
+grav.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+grav.o: $(HACK_SRC)/../hacks/screenhack.h
+grav.o: $(UTILS_SRC)/yarandom.h
+grav.o: $(UTILS_SRC)/usleep.h
+grav.o: $(UTILS_SRC)/resources.h
+grav.o: $(UTILS_SRC)/hsv.h
+grav.o: $(UTILS_SRC)/colors.h
+grav.o: $(UTILS_SRC)/grabscreen.h
+grav.o: $(UTILS_SRC)/visual.h
+helix.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+helix.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+helix.o: $(HACK_SRC)/../config.h
+helix.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+helix.o: $(HACK_SRC)/../hacks/screenhack.h
+helix.o: $(UTILS_SRC)/yarandom.h
+helix.o: $(UTILS_SRC)/usleep.h
+helix.o: $(UTILS_SRC)/resources.h
+helix.o: $(UTILS_SRC)/hsv.h
+helix.o: $(UTILS_SRC)/colors.h
+helix.o: $(UTILS_SRC)/grabscreen.h
+helix.o: $(UTILS_SRC)/visual.h
+hop.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+hop.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+hop.o: $(HACK_SRC)/../config.h
+hop.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+hop.o: $(HACK_SRC)/../hacks/screenhack.h
+hop.o: $(UTILS_SRC)/yarandom.h
+hop.o: $(UTILS_SRC)/usleep.h
+hop.o: $(UTILS_SRC)/resources.h
+hop.o: $(UTILS_SRC)/hsv.h
+hop.o: $(UTILS_SRC)/colors.h
+hop.o: $(UTILS_SRC)/grabscreen.h
+hop.o: $(UTILS_SRC)/visual.h
+hop.o: $(UTILS_SRC)/erase.h
+hyper.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+hyper.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+hyper.o: $(HACK_SRC)/../config.h
+hyper.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+hyper.o: $(HACK_SRC)/../hacks/screenhack.h
+hyper.o: $(UTILS_SRC)/yarandom.h
+hyper.o: $(UTILS_SRC)/usleep.h
+hyper.o: $(UTILS_SRC)/resources.h
+hyper.o: $(UTILS_SRC)/hsv.h
+hyper.o: $(UTILS_SRC)/colors.h
+hyper.o: $(UTILS_SRC)/grabscreen.h
+hyper.o: $(UTILS_SRC)/visual.h
+ico.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+ico.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+ico.o: $(HACK_SRC)/../config.h
+ico.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+ico.o: $(HACK_SRC)/../hacks/screenhack.h
+ico.o: $(UTILS_SRC)/yarandom.h
+ico.o: $(UTILS_SRC)/usleep.h
+ico.o: $(UTILS_SRC)/resources.h
+ico.o: $(UTILS_SRC)/hsv.h
+ico.o: $(UTILS_SRC)/colors.h
+ico.o: $(UTILS_SRC)/grabscreen.h
+ico.o: $(UTILS_SRC)/visual.h
+ifs.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+ifs.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+ifs.o: $(HACK_SRC)/../config.h
+ifs.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+ifs.o: $(HACK_SRC)/../hacks/screenhack.h
+ifs.o: $(UTILS_SRC)/yarandom.h
+ifs.o: $(UTILS_SRC)/usleep.h
+ifs.o: $(UTILS_SRC)/resources.h
+ifs.o: $(UTILS_SRC)/hsv.h
+ifs.o: $(UTILS_SRC)/colors.h
+ifs.o: $(UTILS_SRC)/grabscreen.h
+ifs.o: $(UTILS_SRC)/visual.h
+image.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+image.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+image.o: $(HACK_SRC)/../config.h
+image.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+image.o: $(HACK_SRC)/../hacks/screenhack.h
+image.o: $(UTILS_SRC)/yarandom.h
+image.o: $(UTILS_SRC)/usleep.h
+image.o: $(UTILS_SRC)/resources.h
+image.o: $(UTILS_SRC)/hsv.h
+image.o: $(UTILS_SRC)/colors.h
+image.o: $(UTILS_SRC)/grabscreen.h
+image.o: $(UTILS_SRC)/visual.h
+image.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+image.o: $(srcdir)/image.xbm
+julia.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+julia.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+julia.o: $(HACK_SRC)/../config.h
+julia.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+julia.o: $(HACK_SRC)/../hacks/screenhack.h
+julia.o: $(UTILS_SRC)/yarandom.h
+julia.o: $(UTILS_SRC)/usleep.h
+julia.o: $(UTILS_SRC)/resources.h
+julia.o: $(UTILS_SRC)/hsv.h
+julia.o: $(UTILS_SRC)/colors.h
+julia.o: $(UTILS_SRC)/grabscreen.h
+julia.o: $(UTILS_SRC)/visual.h
+kaleid.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+kaleid.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+kaleid.o: $(HACK_SRC)/../config.h
+kaleid.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+kaleid.o: $(HACK_SRC)/../hacks/screenhack.h
+kaleid.o: $(UTILS_SRC)/yarandom.h
+kaleid.o: $(UTILS_SRC)/usleep.h
+kaleid.o: $(UTILS_SRC)/resources.h
+kaleid.o: $(UTILS_SRC)/hsv.h
+kaleid.o: $(UTILS_SRC)/colors.h
+kaleid.o: $(UTILS_SRC)/grabscreen.h
+kaleid.o: $(UTILS_SRC)/visual.h
+laser.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+laser.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+laser.o: $(HACK_SRC)/../config.h
+laser.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+laser.o: $(HACK_SRC)/../hacks/screenhack.h
+laser.o: $(UTILS_SRC)/yarandom.h
+laser.o: $(UTILS_SRC)/usleep.h
+laser.o: $(UTILS_SRC)/resources.h
+laser.o: $(UTILS_SRC)/hsv.h
+laser.o: $(UTILS_SRC)/colors.h
+laser.o: $(UTILS_SRC)/grabscreen.h
+laser.o: $(UTILS_SRC)/visual.h
+life.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+life.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+life.o: $(HACK_SRC)/../config.h
+life.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+life.o: $(HACK_SRC)/../hacks/screenhack.h
+life.o: $(UTILS_SRC)/yarandom.h
+life.o: $(UTILS_SRC)/usleep.h
+life.o: $(UTILS_SRC)/resources.h
+life.o: $(UTILS_SRC)/hsv.h
+life.o: $(UTILS_SRC)/colors.h
+life.o: $(UTILS_SRC)/grabscreen.h
+life.o: $(UTILS_SRC)/visual.h
+life.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+life.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+life.o: $(srcdir)/life.xbm
+life1d.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+life1d.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+life1d.o: $(HACK_SRC)/../config.h
+life1d.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+life1d.o: $(HACK_SRC)/../hacks/screenhack.h
+life1d.o: $(UTILS_SRC)/yarandom.h
+life1d.o: $(UTILS_SRC)/usleep.h
+life1d.o: $(UTILS_SRC)/resources.h
+life1d.o: $(UTILS_SRC)/hsv.h
+life1d.o: $(UTILS_SRC)/colors.h
+life1d.o: $(UTILS_SRC)/grabscreen.h
+life1d.o: $(UTILS_SRC)/visual.h
+life1d.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+life1d.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+life1d.o: $(srcdir)/life1d.xbm
+life3d.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+life3d.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+life3d.o: $(HACK_SRC)/../config.h
+life3d.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+life3d.o: $(HACK_SRC)/../hacks/screenhack.h
+life3d.o: $(UTILS_SRC)/yarandom.h
+life3d.o: $(UTILS_SRC)/usleep.h
+life3d.o: $(UTILS_SRC)/resources.h
+life3d.o: $(UTILS_SRC)/hsv.h
+life3d.o: $(UTILS_SRC)/colors.h
+life3d.o: $(UTILS_SRC)/grabscreen.h
+life3d.o: $(UTILS_SRC)/visual.h
+life3d.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+lightning.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+lightning.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+lightning.o: $(HACK_SRC)/../config.h
+lightning.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+lightning.o: $(HACK_SRC)/../hacks/screenhack.h
+lightning.o: $(UTILS_SRC)/yarandom.h
+lightning.o: $(UTILS_SRC)/usleep.h
+lightning.o: $(UTILS_SRC)/resources.h
+lightning.o: $(UTILS_SRC)/hsv.h
+lightning.o: $(UTILS_SRC)/colors.h
+lightning.o: $(UTILS_SRC)/grabscreen.h
+lightning.o: $(UTILS_SRC)/visual.h
+lisa.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+lisa.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+lisa.o: $(HACK_SRC)/../config.h
+lisa.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+lisa.o: $(HACK_SRC)/../hacks/screenhack.h
+lisa.o: $(UTILS_SRC)/yarandom.h
+lisa.o: $(UTILS_SRC)/usleep.h
+lisa.o: $(UTILS_SRC)/resources.h
+lisa.o: $(UTILS_SRC)/hsv.h
+lisa.o: $(UTILS_SRC)/colors.h
+lisa.o: $(UTILS_SRC)/grabscreen.h
+lisa.o: $(UTILS_SRC)/visual.h
+lissie.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+lissie.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+lissie.o: $(HACK_SRC)/../config.h
+lissie.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+lissie.o: $(HACK_SRC)/../hacks/screenhack.h
+lissie.o: $(UTILS_SRC)/yarandom.h
+lissie.o: $(UTILS_SRC)/usleep.h
+lissie.o: $(UTILS_SRC)/resources.h
+lissie.o: $(UTILS_SRC)/hsv.h
+lissie.o: $(UTILS_SRC)/colors.h
+lissie.o: $(UTILS_SRC)/grabscreen.h
+lissie.o: $(UTILS_SRC)/visual.h
+loop.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+loop.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+loop.o: $(HACK_SRC)/../config.h
+loop.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+loop.o: $(HACK_SRC)/../hacks/screenhack.h
+loop.o: $(UTILS_SRC)/yarandom.h
+loop.o: $(UTILS_SRC)/usleep.h
+loop.o: $(UTILS_SRC)/resources.h
+loop.o: $(UTILS_SRC)/hsv.h
+loop.o: $(UTILS_SRC)/colors.h
+loop.o: $(UTILS_SRC)/grabscreen.h
+loop.o: $(UTILS_SRC)/visual.h
+loop.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+mandelbrot.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+mandelbrot.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+mandelbrot.o: $(HACK_SRC)/../config.h
+mandelbrot.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+mandelbrot.o: $(HACK_SRC)/../hacks/screenhack.h
+mandelbrot.o: $(UTILS_SRC)/yarandom.h
+mandelbrot.o: $(UTILS_SRC)/usleep.h
+mandelbrot.o: $(UTILS_SRC)/resources.h
+mandelbrot.o: $(UTILS_SRC)/hsv.h
+mandelbrot.o: $(UTILS_SRC)/colors.h
+mandelbrot.o: $(UTILS_SRC)/grabscreen.h
+mandelbrot.o: $(UTILS_SRC)/visual.h
+marquee.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+marquee.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+marquee.o: $(HACK_SRC)/../config.h
+marquee.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+marquee.o: $(HACK_SRC)/../hacks/screenhack.h
+marquee.o: $(UTILS_SRC)/yarandom.h
+marquee.o: $(UTILS_SRC)/usleep.h
+marquee.o: $(UTILS_SRC)/resources.h
+marquee.o: $(UTILS_SRC)/hsv.h
+marquee.o: $(UTILS_SRC)/colors.h
+marquee.o: $(UTILS_SRC)/grabscreen.h
+marquee.o: $(UTILS_SRC)/visual.h
+marquee.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+maze.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+maze.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+maze.o: $(HACK_SRC)/../config.h
+maze.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+maze.o: $(HACK_SRC)/../hacks/screenhack.h
+maze.o: $(UTILS_SRC)/yarandom.h
+maze.o: $(UTILS_SRC)/usleep.h
+maze.o: $(UTILS_SRC)/resources.h
+maze.o: $(UTILS_SRC)/hsv.h
+maze.o: $(UTILS_SRC)/colors.h
+maze.o: $(UTILS_SRC)/grabscreen.h
+maze.o: $(UTILS_SRC)/visual.h
+maze.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+maze.o: $(HACK_SRC)/../xlockmore/bitmaps/gray1.xbm
+maze.o: $(srcdir)/maze.xbm
+mountain.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+mountain.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+mountain.o: $(HACK_SRC)/../config.h
+mountain.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+mountain.o: $(HACK_SRC)/../hacks/screenhack.h
+mountain.o: $(UTILS_SRC)/yarandom.h
+mountain.o: $(UTILS_SRC)/usleep.h
+mountain.o: $(UTILS_SRC)/resources.h
+mountain.o: $(UTILS_SRC)/hsv.h
+mountain.o: $(UTILS_SRC)/colors.h
+mountain.o: $(UTILS_SRC)/grabscreen.h
+mountain.o: $(UTILS_SRC)/visual.h
+munch.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+munch.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+munch.o: $(HACK_SRC)/../config.h
+munch.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+munch.o: $(HACK_SRC)/../hacks/screenhack.h
+munch.o: $(UTILS_SRC)/yarandom.h
+munch.o: $(UTILS_SRC)/usleep.h
+munch.o: $(UTILS_SRC)/resources.h
+munch.o: $(UTILS_SRC)/hsv.h
+munch.o: $(UTILS_SRC)/colors.h
+munch.o: $(UTILS_SRC)/grabscreen.h
+munch.o: $(UTILS_SRC)/visual.h
+nose.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+nose.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+nose.o: $(HACK_SRC)/../config.h
+nose.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+nose.o: $(HACK_SRC)/../hacks/screenhack.h
+nose.o: $(UTILS_SRC)/yarandom.h
+nose.o: $(UTILS_SRC)/usleep.h
+nose.o: $(UTILS_SRC)/resources.h
+nose.o: $(UTILS_SRC)/hsv.h
+nose.o: $(UTILS_SRC)/colors.h
+nose.o: $(UTILS_SRC)/grabscreen.h
+nose.o: $(UTILS_SRC)/visual.h
+nose.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-hat.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-hatd.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-facef.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-faced.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-facel.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-facer.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-shoef.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-shoel.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-shoer.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-stepl.xbm
+nose.o: $(HACK_SRC)/../xlockmore/bitmaps/nose-stepr.xbm
+pacman.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+pacman.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+pacman.o: $(HACK_SRC)/../config.h
+pacman.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+pacman.o: $(HACK_SRC)/../hacks/screenhack.h
+pacman.o: $(UTILS_SRC)/yarandom.h
+pacman.o: $(UTILS_SRC)/usleep.h
+pacman.o: $(UTILS_SRC)/resources.h
+pacman.o: $(UTILS_SRC)/hsv.h
+pacman.o: $(UTILS_SRC)/colors.h
+pacman.o: $(UTILS_SRC)/grabscreen.h
+pacman.o: $(UTILS_SRC)/visual.h
+pacman.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+pacman.o: $(srcdir)/ghost.xbm
+penrose.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+penrose.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+penrose.o: $(HACK_SRC)/../config.h
+penrose.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+penrose.o: $(HACK_SRC)/../hacks/screenhack.h
+penrose.o: $(UTILS_SRC)/yarandom.h
+penrose.o: $(UTILS_SRC)/usleep.h
+penrose.o: $(UTILS_SRC)/resources.h
+penrose.o: $(UTILS_SRC)/hsv.h
+penrose.o: $(UTILS_SRC)/colors.h
+penrose.o: $(UTILS_SRC)/grabscreen.h
+penrose.o: $(UTILS_SRC)/visual.h
+petal.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+petal.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+petal.o: $(HACK_SRC)/../config.h
+petal.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+petal.o: $(HACK_SRC)/../hacks/screenhack.h
+petal.o: $(UTILS_SRC)/yarandom.h
+petal.o: $(UTILS_SRC)/usleep.h
+petal.o: $(UTILS_SRC)/resources.h
+petal.o: $(UTILS_SRC)/hsv.h
+petal.o: $(UTILS_SRC)/colors.h
+petal.o: $(UTILS_SRC)/grabscreen.h
+petal.o: $(UTILS_SRC)/visual.h
+puzzle.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+puzzle.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+puzzle.o: $(HACK_SRC)/../config.h
+puzzle.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+puzzle.o: $(HACK_SRC)/../hacks/screenhack.h
+puzzle.o: $(UTILS_SRC)/yarandom.h
+puzzle.o: $(UTILS_SRC)/usleep.h
+puzzle.o: $(UTILS_SRC)/resources.h
+puzzle.o: $(UTILS_SRC)/hsv.h
+puzzle.o: $(UTILS_SRC)/colors.h
+puzzle.o: $(UTILS_SRC)/grabscreen.h
+puzzle.o: $(UTILS_SRC)/visual.h
+puzzle.o: $(HACK_SRC)/../xlockmore/xlock/iostuff.h
+puzzle.o: $(srcdir)/puzzle.xbm
+pyro.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+pyro.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+pyro.o: $(HACK_SRC)/../config.h
+pyro.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+pyro.o: $(HACK_SRC)/../hacks/screenhack.h
+pyro.o: $(UTILS_SRC)/yarandom.h
+pyro.o: $(UTILS_SRC)/usleep.h
+pyro.o: $(UTILS_SRC)/resources.h
+pyro.o: $(UTILS_SRC)/hsv.h
+pyro.o: $(UTILS_SRC)/colors.h
+pyro.o: $(UTILS_SRC)/grabscreen.h
+pyro.o: $(UTILS_SRC)/visual.h
+qix.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+qix.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+qix.o: $(HACK_SRC)/../config.h
+qix.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+qix.o: $(HACK_SRC)/../hacks/screenhack.h
+qix.o: $(UTILS_SRC)/yarandom.h
+qix.o: $(UTILS_SRC)/usleep.h
+qix.o: $(UTILS_SRC)/resources.h
+qix.o: $(UTILS_SRC)/hsv.h
+qix.o: $(UTILS_SRC)/colors.h
+qix.o: $(UTILS_SRC)/grabscreen.h
+qix.o: $(UTILS_SRC)/visual.h
+roll.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+roll.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+roll.o: $(HACK_SRC)/../config.h
+roll.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+roll.o: $(HACK_SRC)/../hacks/screenhack.h
+roll.o: $(UTILS_SRC)/yarandom.h
+roll.o: $(UTILS_SRC)/usleep.h
+roll.o: $(UTILS_SRC)/resources.h
+roll.o: $(UTILS_SRC)/hsv.h
+roll.o: $(UTILS_SRC)/colors.h
+roll.o: $(UTILS_SRC)/grabscreen.h
+roll.o: $(UTILS_SRC)/visual.h
+rotor.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+rotor.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+rotor.o: $(HACK_SRC)/../config.h
+rotor.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+rotor.o: $(HACK_SRC)/../hacks/screenhack.h
+rotor.o: $(UTILS_SRC)/yarandom.h
+rotor.o: $(UTILS_SRC)/usleep.h
+rotor.o: $(UTILS_SRC)/resources.h
+rotor.o: $(UTILS_SRC)/hsv.h
+rotor.o: $(UTILS_SRC)/colors.h
+rotor.o: $(UTILS_SRC)/grabscreen.h
+rotor.o: $(UTILS_SRC)/visual.h
+shape.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+shape.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+shape.o: $(HACK_SRC)/../config.h
+shape.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+shape.o: $(HACK_SRC)/../hacks/screenhack.h
+shape.o: $(UTILS_SRC)/yarandom.h
+shape.o: $(UTILS_SRC)/usleep.h
+shape.o: $(UTILS_SRC)/resources.h
+shape.o: $(UTILS_SRC)/hsv.h
+shape.o: $(UTILS_SRC)/colors.h
+shape.o: $(UTILS_SRC)/grabscreen.h
+shape.o: $(UTILS_SRC)/visual.h
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/gray1.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/gray3.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/stipple.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/cross_weave.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/dimple1.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/dimple3.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/flipped_gray.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/hlines2.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/light_gray.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/root_weave.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/vlines2.xbm
+shape.o: $(HACK_SRC)/../xlockmore/bitmaps/vlines3.xbm
+sierpinski.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+sierpinski.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+sierpinski.o: $(HACK_SRC)/../config.h
+sierpinski.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+sierpinski.o: $(HACK_SRC)/../hacks/screenhack.h
+sierpinski.o: $(UTILS_SRC)/yarandom.h
+sierpinski.o: $(UTILS_SRC)/usleep.h
+sierpinski.o: $(UTILS_SRC)/resources.h
+sierpinski.o: $(UTILS_SRC)/hsv.h
+sierpinski.o: $(UTILS_SRC)/colors.h
+sierpinski.o: $(UTILS_SRC)/grabscreen.h
+sierpinski.o: $(UTILS_SRC)/visual.h
+slip.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+slip.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+slip.o: $(HACK_SRC)/../config.h
+slip.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+slip.o: $(HACK_SRC)/../hacks/screenhack.h
+slip.o: $(UTILS_SRC)/yarandom.h
+slip.o: $(UTILS_SRC)/usleep.h
+slip.o: $(UTILS_SRC)/resources.h
+slip.o: $(UTILS_SRC)/hsv.h
+slip.o: $(UTILS_SRC)/colors.h
+slip.o: $(UTILS_SRC)/grabscreen.h
+slip.o: $(UTILS_SRC)/visual.h
+sphere.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+sphere.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+sphere.o: $(HACK_SRC)/../config.h
+sphere.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+sphere.o: $(HACK_SRC)/../hacks/screenhack.h
+sphere.o: $(UTILS_SRC)/yarandom.h
+sphere.o: $(UTILS_SRC)/usleep.h
+sphere.o: $(UTILS_SRC)/resources.h
+sphere.o: $(UTILS_SRC)/hsv.h
+sphere.o: $(UTILS_SRC)/colors.h
+sphere.o: $(UTILS_SRC)/grabscreen.h
+sphere.o: $(UTILS_SRC)/visual.h
+spiral.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+spiral.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+spiral.o: $(HACK_SRC)/../config.h
+spiral.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+spiral.o: $(HACK_SRC)/../hacks/screenhack.h
+spiral.o: $(UTILS_SRC)/yarandom.h
+spiral.o: $(UTILS_SRC)/usleep.h
+spiral.o: $(UTILS_SRC)/resources.h
+spiral.o: $(UTILS_SRC)/hsv.h
+spiral.o: $(UTILS_SRC)/colors.h
+spiral.o: $(UTILS_SRC)/grabscreen.h
+spiral.o: $(UTILS_SRC)/visual.h
+spline.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+spline.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+spline.o: $(HACK_SRC)/../config.h
+spline.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+spline.o: $(HACK_SRC)/../hacks/screenhack.h
+spline.o: $(UTILS_SRC)/yarandom.h
+spline.o: $(UTILS_SRC)/usleep.h
+spline.o: $(UTILS_SRC)/resources.h
+spline.o: $(UTILS_SRC)/hsv.h
+spline.o: $(UTILS_SRC)/colors.h
+spline.o: $(UTILS_SRC)/grabscreen.h
+spline.o: $(UTILS_SRC)/visual.h
+star.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+star.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+star.o: $(HACK_SRC)/../config.h
+star.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+star.o: $(HACK_SRC)/../hacks/screenhack.h
+star.o: $(UTILS_SRC)/yarandom.h
+star.o: $(UTILS_SRC)/usleep.h
+star.o: $(UTILS_SRC)/resources.h
+star.o: $(UTILS_SRC)/hsv.h
+star.o: $(UTILS_SRC)/colors.h
+star.o: $(UTILS_SRC)/grabscreen.h
+star.o: $(UTILS_SRC)/visual.h
+star.o: $(HACK_SRC)/../xlockmore/bitmaps/trek-0.xbm
+star.o: $(HACK_SRC)/../xlockmore/bitmaps/trek-1.xbm
+strange.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+strange.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+strange.o: $(HACK_SRC)/../config.h
+strange.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+strange.o: $(HACK_SRC)/../hacks/screenhack.h
+strange.o: $(UTILS_SRC)/yarandom.h
+strange.o: $(UTILS_SRC)/usleep.h
+strange.o: $(UTILS_SRC)/resources.h
+strange.o: $(UTILS_SRC)/hsv.h
+strange.o: $(UTILS_SRC)/colors.h
+strange.o: $(UTILS_SRC)/grabscreen.h
+strange.o: $(UTILS_SRC)/visual.h
+swarm.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+swarm.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+swarm.o: $(HACK_SRC)/../config.h
+swarm.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+swarm.o: $(HACK_SRC)/../hacks/screenhack.h
+swarm.o: $(UTILS_SRC)/yarandom.h
+swarm.o: $(UTILS_SRC)/usleep.h
+swarm.o: $(UTILS_SRC)/resources.h
+swarm.o: $(UTILS_SRC)/hsv.h
+swarm.o: $(UTILS_SRC)/colors.h
+swarm.o: $(UTILS_SRC)/grabscreen.h
+swarm.o: $(UTILS_SRC)/visual.h
+swirl.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+swirl.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+swirl.o: $(HACK_SRC)/../config.h
+swirl.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+swirl.o: $(HACK_SRC)/../hacks/screenhack.h
+swirl.o: $(UTILS_SRC)/yarandom.h
+swirl.o: $(UTILS_SRC)/usleep.h
+swirl.o: $(UTILS_SRC)/resources.h
+swirl.o: $(UTILS_SRC)/hsv.h
+swirl.o: $(UTILS_SRC)/colors.h
+swirl.o: $(UTILS_SRC)/grabscreen.h
+swirl.o: $(UTILS_SRC)/visual.h
+thornbird.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+thornbird.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+thornbird.o: $(HACK_SRC)/../config.h
+thornbird.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+thornbird.o: $(HACK_SRC)/../hacks/screenhack.h
+thornbird.o: $(UTILS_SRC)/yarandom.h
+thornbird.o: $(UTILS_SRC)/usleep.h
+thornbird.o: $(UTILS_SRC)/resources.h
+thornbird.o: $(UTILS_SRC)/hsv.h
+thornbird.o: $(UTILS_SRC)/colors.h
+thornbird.o: $(UTILS_SRC)/grabscreen.h
+thornbird.o: $(UTILS_SRC)/visual.h
+triangle.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+triangle.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+triangle.o: $(HACK_SRC)/../config.h
+triangle.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+triangle.o: $(HACK_SRC)/../hacks/screenhack.h
+triangle.o: $(UTILS_SRC)/yarandom.h
+triangle.o: $(UTILS_SRC)/usleep.h
+triangle.o: $(UTILS_SRC)/resources.h
+triangle.o: $(UTILS_SRC)/hsv.h
+triangle.o: $(UTILS_SRC)/colors.h
+triangle.o: $(UTILS_SRC)/grabscreen.h
+triangle.o: $(UTILS_SRC)/visual.h
+tube.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+tube.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+tube.o: $(HACK_SRC)/../config.h
+tube.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+tube.o: $(HACK_SRC)/../hacks/screenhack.h
+tube.o: $(UTILS_SRC)/yarandom.h
+tube.o: $(UTILS_SRC)/usleep.h
+tube.o: $(UTILS_SRC)/resources.h
+tube.o: $(UTILS_SRC)/hsv.h
+tube.o: $(UTILS_SRC)/colors.h
+tube.o: $(UTILS_SRC)/grabscreen.h
+tube.o: $(UTILS_SRC)/visual.h
+turtle.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+turtle.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+turtle.o: $(HACK_SRC)/../config.h
+turtle.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+turtle.o: $(HACK_SRC)/../hacks/screenhack.h
+turtle.o: $(UTILS_SRC)/yarandom.h
+turtle.o: $(UTILS_SRC)/usleep.h
+turtle.o: $(UTILS_SRC)/resources.h
+turtle.o: $(UTILS_SRC)/hsv.h
+turtle.o: $(UTILS_SRC)/colors.h
+turtle.o: $(UTILS_SRC)/grabscreen.h
+turtle.o: $(UTILS_SRC)/visual.h
+vines.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+vines.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+vines.o: $(HACK_SRC)/../config.h
+vines.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+vines.o: $(HACK_SRC)/../hacks/screenhack.h
+vines.o: $(UTILS_SRC)/yarandom.h
+vines.o: $(UTILS_SRC)/usleep.h
+vines.o: $(UTILS_SRC)/resources.h
+vines.o: $(UTILS_SRC)/hsv.h
+vines.o: $(UTILS_SRC)/colors.h
+vines.o: $(UTILS_SRC)/grabscreen.h
+vines.o: $(UTILS_SRC)/visual.h
+vines.o: $(UTILS_SRC)/erase.h
+voters.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+voters.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+voters.o: $(HACK_SRC)/../config.h
+voters.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+voters.o: $(HACK_SRC)/../hacks/screenhack.h
+voters.o: $(UTILS_SRC)/yarandom.h
+voters.o: $(UTILS_SRC)/usleep.h
+voters.o: $(UTILS_SRC)/resources.h
+voters.o: $(UTILS_SRC)/hsv.h
+voters.o: $(UTILS_SRC)/colors.h
+voters.o: $(UTILS_SRC)/grabscreen.h
+voters.o: $(UTILS_SRC)/visual.h
+voters.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+voters.o: $(HACK_SRC)/../xlockmore/bitmaps/sickle.xbm
+voters.o: $(HACK_SRC)/../xlockmore/bitmaps/donkey.xbm
+voters.o: $(HACK_SRC)/../xlockmore/bitmaps/elephant.xbm
+wator.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+wator.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+wator.o: $(HACK_SRC)/../config.h
+wator.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+wator.o: $(HACK_SRC)/../hacks/screenhack.h
+wator.o: $(UTILS_SRC)/yarandom.h
+wator.o: $(UTILS_SRC)/usleep.h
+wator.o: $(UTILS_SRC)/resources.h
+wator.o: $(UTILS_SRC)/hsv.h
+wator.o: $(UTILS_SRC)/colors.h
+wator.o: $(UTILS_SRC)/grabscreen.h
+wator.o: $(UTILS_SRC)/visual.h
+wator.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-0.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-1.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-2.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-3.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-4.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-5.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-6.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/fish-7.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-0.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-1.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-2.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-3.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-4.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-5.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-6.xbm
+wator.o: $(HACK_SRC)/../xlockmore/bitmaps/shark-7.xbm
+wire.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+wire.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+wire.o: $(HACK_SRC)/../config.h
+wire.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+wire.o: $(HACK_SRC)/../hacks/screenhack.h
+wire.o: $(UTILS_SRC)/yarandom.h
+wire.o: $(UTILS_SRC)/usleep.h
+wire.o: $(UTILS_SRC)/resources.h
+wire.o: $(UTILS_SRC)/hsv.h
+wire.o: $(UTILS_SRC)/colors.h
+wire.o: $(UTILS_SRC)/grabscreen.h
+wire.o: $(UTILS_SRC)/visual.h
+wire.o: $(HACK_SRC)/../xlockmore/xlock/automata.h
+world.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+world.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+world.o: $(HACK_SRC)/../config.h
+world.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+world.o: $(HACK_SRC)/../hacks/screenhack.h
+world.o: $(UTILS_SRC)/yarandom.h
+world.o: $(UTILS_SRC)/usleep.h
+world.o: $(UTILS_SRC)/resources.h
+world.o: $(UTILS_SRC)/hsv.h
+world.o: $(UTILS_SRC)/colors.h
+world.o: $(UTILS_SRC)/grabscreen.h
+world.o: $(UTILS_SRC)/visual.h
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-00.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-01.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-02.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-03.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-04.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-05.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-06.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-07.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-08.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-09.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-10.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-11.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-12.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-13.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-14.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-15.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-16.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-17.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-18.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-19.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-20.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-21.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-22.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-23.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-24.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-25.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-26.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-27.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-28.xbm
+world.o: $(HACK_SRC)/../xlockmore/bitmaps/terra-29.xbm
+worm.o: $(HACK_SRC)/../xlockmore/xlock/xlockmore.h
+worm.o: $(HACK_SRC)/../xlockmore/xlock/xlock.h
+worm.o: $(HACK_SRC)/../config.h
+worm.o: $(HACK_SRC)/../xlockmore/xlock/mode.h
+worm.o: $(HACK_SRC)/../hacks/screenhack.h
+worm.o: $(UTILS_SRC)/yarandom.h
+worm.o: $(UTILS_SRC)/usleep.h
+worm.o: $(UTILS_SRC)/resources.h
+worm.o: $(UTILS_SRC)/hsv.h
+worm.o: $(UTILS_SRC)/colors.h
+worm.o: $(UTILS_SRC)/grabscreen.h
+worm.o: $(UTILS_SRC)/visual.h
+
diff --git a/xlockmore-4.14/modes/ant.c b/xlockmore-4.14/modes/ant.c
new file mode 100644 (file)
index 0000000..00f807d
--- /dev/null
@@ -0,0 +1,1233 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/*-
+ * ant --- Chris Langton's generalized turing machine ants (also known
+ *         as Greg Turk's turmites) whose tape is the screen
+ */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)ant.c        4.11 98/06/18 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 16-Apr-97: -neighbors 3 and 8 added
+ * 01-Jan-97: Updated ant.c to handle more kinds of ants.  Thanks to
+ *            J Austin David <Austin.David@tlogic.com>.  Check it out in
+ *            java at http://havoc.gtf.gatech.edu/austin  He thought up the
+ *            new Ladder ant.
+ * 04-Apr-96: -neighbors 6 runtime-time option added for hexagonal ants
+ *            (bees), coded from an idea of Jim Propp's in Science News,
+ *            Oct 28, 1995 VOL. 148 page 287
+ * 20-Sep-95: Memory leak in ant fixed.  Now random colors.
+ * 05-Sep-95: Coded from A.K. Dewdney's "Computer Recreations", Scientific
+ *            American Magazine" Sep 1989 pp 180-183, Mar 1990 p 121
+ *            Also used Ian Stewart's Mathematical Recreations, Scientific
+ *            American Jul 1994 pp 104-107
+ *            also used demon.c and life.c as a guide.
+ */
+
+/*-
+  Species Grid     Number of Neigbors
+  ------- ----     ------------------
+  Ants    Square   4 (or 8)
+  Bees    Hexagon  6
+  Bees    Triangle 3 (or 9, 12)
+
+  Neighbors 6 and neighbors 3 produce the same Turk ants.
+*/
+
+#ifdef STANDALONE
+#define PROGCLASS "Ant"
+#define HACK_INIT init_ant
+#define HACK_DRAW draw_ant
+#define ant_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: -3 \n" \
+ "*cycles: 40000 \n" \
+ "*size: -12 \n" \
+ "*ncolors: 64 \n" \
+ "*neighbors: 0 \n" \
+ "*sharpturn: False \n" \
+ "*fullrandom: True \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_ant
+
+/*-
+ * neighbors of 0 randomizes it between 3, 4 and 6.
+ * 8, 9 12 are available also but not recommended.
+ */
+
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+#define DEF_TRUCHET  "False"
+#define DEF_EYES  "False"
+#define DEF_SHARPTURN  "False"
+
+static int  neighbors;
+static Bool truchet;
+static Bool eyes;
+static Bool sharpturn;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".ant.neighbors", XrmoptionSepArg, (caddr_t) NULL},
+       {"-truchet", ".ant.truchet", XrmoptionNoArg, (caddr_t) "on"},
+       {"+truchet", ".ant.truchet", XrmoptionNoArg, (caddr_t) "off"},
+       {"-eyes", ".ant.eyes", XrmoptionNoArg, (caddr_t) "on"},
+       {"+eyes", ".ant.eyes", XrmoptionNoArg, (caddr_t) "off"},
+       {"-sharpturn", ".ant.sharpturn", XrmoptionNoArg, (caddr_t) "on"},
+       {"+sharpturn", ".ant.sharpturn", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int},
+       {(caddr_t *) & truchet, "truchet", "Truchet", DEF_TRUCHET, t_Bool},
+       {(caddr_t *) & eyes, "eyes", "Eyes", DEF_EYES, t_Bool},
+   {(caddr_t *) & sharpturn, "sharpturn", "SharpTurn", DEF_SHARPTURN, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-neighbors num", "squares 4 or 8, hexagons 6, triangles 3, 9 or 12"},
+       {"-/+truchet", "turn on/off Truchet lines"},
+       {"-/+eyes", "turn on/off eyes"},
+       {"-/+sharpturn", "turn on/off sharp turns (6 or 12 neighbors only)"}
+};
+
+ModeSpecOpt ant_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   ant_description =
+{"ant", "init_ant", "draw_ant", "release_ant",
+ "refresh_ant", "init_ant", NULL, &ant_opts,
+ 1000, -3, 40000, -12, 64, 1.0, "",
+ "Shows Langton's and Turk's generalized ants", 0, NULL};
+
+#endif
+
+#define ANTBITS(n,w,h)\
+  ap->pixmaps[ap->init_bits++]=\
+  XCreatePixmapFromBitmapData(display,window,(char *)n,w,h,1,0,1)
+
+/* If you change the table you may have to change the following 2 constants */
+#define STATES 2
+#define MINANTS 1
+#define REDRAWSTEP 2000                /* How much tape to draw per cycle */
+#define MINGRIDSIZE 24
+#define MINSIZE 1
+#define MINRANDOMSIZE 5
+#define ANGLES 360
+
+typedef struct {
+       unsigned char color;
+       short       direction;
+       unsigned char next;
+} statestruct;
+
+typedef struct {
+       int         col, row;
+       short       direction;
+       unsigned char state;
+} antstruct;
+
+typedef struct {
+       Bool        painted;
+       int         neighbors;
+       int         generation;
+       int         xs, ys;
+       int         xb, yb;
+       int         nrows, ncols;
+       int         width, height;
+       unsigned char ncolors, nstates;
+       int         n;
+       int         redrawing, redrawpos;
+       int         truchet;    /* Only for Turk modes */
+       int         eyes;
+       int         sharpturn;  /* Only for even neighbors > 4 (i.e. 6 and 12) */
+       statestruct machine[NUMSTIPPLES * STATES];
+       unsigned char *tape;
+       unsigned char *truchet_state;
+       antstruct  *ants;
+       int         init_bits;
+       unsigned char colors[NUMSTIPPLES - 1];
+       GC          stippledGC;
+       Pixmap      pixmaps[NUMSTIPPLES - 1];
+       union {
+               XPoint      hexagon[7];         /* Need more than 6 for truchet */
+               XPoint      triangle[2][4];     /* Need more than 3 for truchet */
+       } shape;
+} antfarmstruct;
+
+static char plots[] =
+{3,
+#if 1                          /* Without this... this mode is misnamed... */
+ 4,
+#endif
+ 6};                           /* Neighborhoods, 8 just makes a mess */
+
+#define NEIGHBORKINDS (long) (sizeof plots / sizeof *plots)
+
+/* Relative ant moves */
+#define FS 0                   /* Step */
+#define TRS 1                  /* Turn right, then step */
+#define THRS 2                 /* Turn hard right, then step */
+#define TBS 3                  /* Turn back, then step */
+#define THLS 4                 /* Turn hard left, then step */
+#define TLS 5                  /* Turn left, then step */
+#define SF 6                   /* Step */
+#define STR 7                  /* Step then turn right */
+#define STHR 8                 /* Step then turn hard right */
+#define STB 9                  /* Step then turn back */
+#define STHL 10                        /* Step then turn hard left */
+#define STL 11                 /* Step then turn left */
+
+static antfarmstruct *antfarms = NULL;
+
+/* LANGTON'S ANT (10) Chaotic after 500, Builder after 10,000 (104p) */
+/* TURK'S 100 ANT Always chaotic?, tested past 150,000,000 */
+/* TURK'S 101 ANT Always chaotic? */
+/* TURK'S 110 ANT Builder at 150 (18p) */
+/* TURK'S 1000 ANT Always chaotic? */
+/* TURK'S 1100 SYMMETRIC ANT  all even run 1's and 0's are symmetric */
+/* other examples 1001, 110011, 110000, 1001101 */
+/* TURK'S 1101 ANT Builder after 250,000 (388p) */
+/* Once saw a chess horse type builder (i.e. non-45 degree builder) */
+
+/* BEE ONLY */
+/* All alternating 10 appear symmetric, no proof (i.e. 10, 1010, etc) */
+/* Even runs of 0's and 1's are also symmetric */
+/* I have seen Hexagonal builders but they are more rare. */
+
+static unsigned char tables[][3 * NUMSTIPPLES * STATES + 2] =
+{
+#if 0
+  /* Here just so you can figure out notation */
+       {                       /* Langton's ant */
+               2, 1,
+               1, TLS, 0, 0, TRS, 0
+       },
+#else
+  /* First 2 numbers are the size (ncolors, nstates) */
+       {                       /* LADDER BUILDER */
+               4, 1,
+               1, STR, 0, 2, STL, 0, 3, TRS, 0, 0, TLS, 0
+       },
+       {                       /* SPIRALING PATTERN */
+               2, 2,
+               1, TLS, 0, 0, FS, 1,
+               1, TRS, 0, 1, TRS, 0
+       },
+       {                       /* SQUARE (HEXAGON) BUILDER */
+               2, 2,
+               1, TLS, 0, 0, FS, 1,
+               0, TRS, 0, 1, TRS, 0
+       },
+#endif
+};
+
+#define NTABLES   (sizeof tables / sizeof tables[0])
+
+static void
+position_of_neighbor(antfarmstruct * ap, int dir, int *pcol, int *prow)
+{
+       int         col = *pcol, row = *prow;
+
+       if (ap->neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                               break;
+                       case 60:
+                               if (!(row & 1))
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                               row = (!row) ? ap->nrows - 1 : row - 1;
+                               break;
+                       case 120:
+                               if (row & 1)
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                               row = (!row) ? ap->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? ap->ncols - 1 : col - 1;
+                               break;
+                       case 240:
+                               if (row & 1)
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                               row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                               break;
+                       case 300:
+                               if (!(row & 1))
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                               row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else if (ap->neighbors == 4 || ap->neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                               break;
+                       case 45:
+                               col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                               row = (!row) ? ap->nrows - 1 : row - 1;
+                               break;
+                       case 90:
+                               row = (!row) ? ap->nrows - 1 : row - 1;
+                               break;
+                       case 135:
+                               col = (!col) ? ap->ncols - 1 : col - 1;
+                               row = (!row) ? ap->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? ap->ncols - 1 : col - 1;
+                               break;
+                       case 225:
+                               col = (!col) ? ap->ncols - 1 : col - 1;
+                               row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                               break;
+                       case 270:
+                               row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                               break;
+                       case 315:
+                               col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                               row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {                /* TRI */
+               if ((col + row) % 2) {  /* right */
+                       switch (dir) {
+                               case 0:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       row = (!row) ? ap->nrows - 1 : row - 1;
+                                       break;
+                               case 60:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       if (!row)
+                                               row = ap->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = ap->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (!row)
+                                               row = ap->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = ap->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 120:
+                                       row = (!row) ? ap->nrows - 1 : row - 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       row = (!row) ? ap->nrows - 1 : row - 1;
+                                       break;
+                               case 180:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                                       break;
+                               case 240:
+                                       row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (row + 1 == ap->nrows)
+                                               row = 1;
+                                       else if (row + 2 == ap->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 300:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       if (row + 1 == ap->nrows)
+                                               row = 1;
+                                       else if (row + 2 == ap->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               } else {        /* left */
+                       switch (dir) {
+                               case 0:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                                       break;
+                               case 60:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       if (row + 1 == ap->nrows)
+                                               row = 1;
+                                       else if (row + 2 == ap->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (row + 1 == ap->nrows)
+                                               row = 1;
+                                       else if (row + 2 == ap->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 120:
+                                       row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       row = (row + 1 == ap->nrows) ? 0 : row + 1;
+                                       break;
+                               case 180:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (!col) ? ap->ncols - 1 : col - 1;
+                                       row = (!row) ? ap->nrows - 1 : row - 1;
+                                       break;
+                               case 240:
+                                       row = (!row) ? ap->nrows - 1 : row - 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (!row)
+                                               row = ap->nrows - 2;
+                                       else if (row == 1)
+                                               row = ap->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 300:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       if (!row)
+                                               row = ap->nrows - 2;
+                                       else if (row == 1)
+                                               row = ap->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (col + 1 == ap->ncols) ? 0 : col + 1;
+                                       row = (!row) ? ap->nrows - 1 : row - 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               }
+       }
+       *pcol = col;
+       *prow = row;
+}
+
+static void
+fillcell(ModeInfo * mi, GC gc, int col, int row)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+
+       if (ap->neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               ap->shape.hexagon[0].x = ap->xb + ccol * ap->xs;
+               ap->shape.hexagon[0].y = ap->yb + crow * ap->ys;
+               if (ap->xs == 1 && ap->ys == 1)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                       ap->shape.hexagon[0].x, ap->shape.hexagon[0].y);
+               else
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                           ap->shape.hexagon, 6, Convex, CoordModePrevious);
+       } else if (ap->neighbors == 4 || ap->neighbors == 8) {
+               XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+               ap->xb + ap->xs * col, ap->yb + ap->ys * row,
+               ap->xs - (ap->xs > 3), ap->ys - (ap->ys > 3));
+       } else {                /* TRI */
+               int         orient = (col + row) % 2;   /* O left 1 right */
+
+               ap->shape.triangle[orient][0].x = ap->xb + col * ap->xs;
+               ap->shape.triangle[orient][0].y = ap->yb + row * ap->ys;
+               if (ap->xs <= 3 || ap->ys <= 3)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                       ((orient) ? -1 : 1) + ap->shape.triangle[orient][0].x,
+                                      ap->shape.triangle[orient][0].y);
+               else {
+                       if (orient)
+                               ap->shape.triangle[orient][0].x += (ap->xs / 2 - 1);
+                       else
+                               ap->shape.triangle[orient][0].x -= (ap->xs / 2 - 1);
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                    ap->shape.triangle[orient], 3, Convex, CoordModePrevious);
+               }
+       }
+}
+
+static void
+truchetcell(ModeInfo * mi, int col, int row, int truchetstate)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+
+       if (ap->neighbors == 6) {
+
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+               int         side;
+               int         fudge = 7;  /* fudge because the hexagons are not exact */
+               XPoint      hex, hex2;
+
+               if (ap->sharpturn) {
+                       hex.x = ap->xb + ccol * ap->xs - (int) ((double) ap->xs / 2.0) - 1;
+                       hex.y = ap->yb + crow * ap->ys - (int) ((double) ap->ys / 2.0) - 1;
+                       for (side = 0; side < 6; side++) {
+                               if (side > 0) {
+                                       hex.x += ap->shape.hexagon[side].x;
+                                       hex.y += ap->shape.hexagon[side].y;
+                               }
+                               if (truchetstate == side % 2)
+                                       XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                                                hex.x, hex.y, ap->xs, ap->ys,
+                                                ((570 - (side * 60) + fudge) % 360) * 64, (120 - 2 * fudge) * 64);
+                       }
+               } else {
+                       /* Very crude approx of Sqrt 3, so it will not cause drawing errors. */
+                       hex.x = ap->xb + ccol * ap->xs - (int) ((double) ap->xs * 1.6 / 2.0);
+                       hex.y = ap->yb + crow * ap->ys - (int) ((double) ap->ys * 1.6 / 2.0);
+                       for (side = 0; side < 6; side++) {
+                               if (side > 0) {
+                                       hex.x += ap->shape.hexagon[side].x;
+                                       hex.y += ap->shape.hexagon[side].y;
+                               }
+                               hex2.x = hex.x + ap->shape.hexagon[side + 1].x / 2;
+                               hex2.y = hex.y + ap->shape.hexagon[side + 1].y / 2;
+                               if (truchetstate == side % 3)
+                                       /* Crude approx of 120 deg, so it will not cause drawing errors. */
+                                       XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                                                hex2.x, hex2.y,
+                                                (int) ((double) ap->xs * 1.5), (int) ((double) ap->ys * 1.5),
+                                                ((555 - (side * 60)) % 360) * 64, 90 * 64);
+                       }
+               }
+       } else if (ap->neighbors == 4) {
+               if (truchetstate) {
+                       XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                                ap->xb + ap->xs * col - ap->xs / 2 + 1,
+                                ap->yb + ap->ys * row + ap->ys / 2 - 1,
+                                ap->xs - 2, ap->ys - 2,
+                                0 * 64, 90 * 64);
+                       XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                                ap->xb + ap->xs * col + ap->xs / 2 - 1,
+                                ap->yb + ap->ys * row - ap->ys / 2 + 1,
+                                ap->xs - 2, ap->ys - 2,
+                                -90 * 64, -90 * 64);
+               } else {
+                       XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                                ap->xb + ap->xs * col - ap->xs / 2 + 1,
+                                ap->yb + ap->ys * row - ap->ys / 2 + 1,
+                                ap->xs - 2, ap->ys - 2,
+                                0 * 64, -90 * 64);
+                       XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                                ap->xb + ap->xs * col + ap->xs / 2 - 1,
+                                ap->yb + ap->ys * row + ap->ys / 2 - 1,
+                                ap->xs - 2, ap->ys - 2,
+                                90 * 64, 90 * 64);
+               }
+       } else if (ap->neighbors == 3) {
+               int         orient = (col + row) % 2;   /* O left 1 right */
+               int         side, ang;
+               int         fudge = 7;  /* fudge because the triangles are not exact */
+               XPoint      tri;
+
+               tri.x = ap->xb + col * ap->xs;
+               tri.y = ap->yb + row * ap->ys;
+               if (orient) {
+                       tri.x += (ap->xs / 2 - 1);
+               } else {
+                       tri.x -= (ap->xs / 2 - 1);
+               }
+               for (side = 0; side < 3; side++) {
+                       if (side > 0) {
+                               tri.x += ap->shape.triangle[orient][side].x;
+                               tri.y += ap->shape.triangle[orient][side].y;
+                       }
+                       if (truchetstate == side % 3) {
+                               if (orient)
+                                       ang = (510 - side * 120) % 360;         /* Right */
+                               else
+                                       ang = (690 - side * 120) % 360;         /* Left */
+                               XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                                 tri.x - ap->xs / 2, tri.y - 3 * ap->ys / 4,
+                                        ap->xs, 3 * ap->ys / 2,
+                                 (ang + fudge) * 64, (60 - 2 * fudge) * 64);
+                       }
+               }
+       }
+}
+
+static void
+drawcell(ModeInfo * mi, int col, int row, unsigned char color)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+       GC          gc;
+
+       if (!color) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+               gc = MI_GC(mi);
+       } else if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi),
+                              MI_PIXEL(mi, ap->colors[color - 1]));
+               gc = MI_GC(mi);
+       } else {
+               XGCValues   gcv;
+
+               gcv.stipple = ap->pixmaps[color - 1];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), ap->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = ap->stippledGC;
+       }
+       fillcell(mi, gc, col, row);
+}
+
+static void
+drawtruchet(ModeInfo * mi, int col, int row,
+           unsigned char color, unsigned char truchetstate)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+
+       if (!color)
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WHITE_PIXEL(mi));
+       else if (MI_NPIXELS(mi) > 2 || color > ap->ncolors / 2)
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+       else
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WHITE_PIXEL(mi));
+       truchetcell(mi, col, row, truchetstate);
+}
+
+static void
+draw_anant(ModeInfo * mi, int direction, int col, int row)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       XSetForeground(display, MI_GC(mi), MI_WHITE_PIXEL(mi));
+       fillcell(mi, MI_GC(mi), col, row);
+       if (ap->eyes && ap->xs > 3 && ap->ys > 3) {             /* Draw Eyes */
+
+               XSetForeground(display, MI_GC(mi), MI_BLACK_PIXEL(mi));
+#if 0  /* under construction */
+               if (ap->neighbors == 6) {
+                       int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+                       int         side;
+                       XPoint      hex;
+
+                       hex.x = ap->xb + ccol * ap->xs;
+                       hex.y = ap->yb + crow * ap->ys;
+                       for (side = 0; side < direction / 60; side++) {
+                               hex.x += ap->shape.hexagon[side].x;
+                               hex.y += ap->shape.hexagon[side].y;
+                       }
+               XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+               hex.x, hex.y, 7, 7);
+
+                                       /*case 0:
+                                       case 60:
+                                       case 120:
+                                       case 180:
+                                       case 240:
+                                       case 300:
+                                       default:
+                                               (void) fprintf(stderr, "wrong direction %d\n", direction); */
+               } else
+#endif
+               if (ap->neighbors == 4 || ap->neighbors == 8) {
+                       switch (direction) {
+                               case 0:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * (col + 1) - 3,
+                                               ap->yb + ap->ys * row + ap->ys / 2 - 2);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * (col + 1) - 3,
+                                               ap->yb + ap->ys * row + ap->ys / 2);
+                                       break;
+                               case 45:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * (col  + 1) - 4,
+                                               ap->yb + ap->ys * row + 1);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * (col  + 1) - 3,
+                                               ap->yb + ap->ys * row + 2);
+                                       break;
+                               case 90:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + ap->xs / 2 - 2,
+                                               ap->yb + ap->ys * row + 1);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + ap->xs / 2,
+                                               ap->yb + ap->ys * row + 1);
+                                       break;
+                               case 135:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + 2,
+                                               ap->yb + ap->ys * row + 1);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + 1,
+                                               ap->yb + ap->ys * row + 2);
+                                       break;
+                               case 180:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + 1,
+                                               ap->yb + ap->ys * row + ap->ys / 2 - 2);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + 1,
+                                               ap->yb + ap->ys * row + ap->ys / 2);
+                                       break;
+                               case 225:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + 2,
+                                               ap->yb + ap->ys * (row + 1) - 3);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + 1,
+                                               ap->yb + ap->ys * (row + 1) - 4);
+                                       break;
+                               case 270:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + ap->xs / 2 - 2,
+                                               ap->yb + ap->ys * (row + 1) - 3);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * col + ap->xs / 2,
+                                               ap->yb + ap->ys * (row + 1) - 3);
+                                       break;
+                               case 315:
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * (col + 1) - 4,
+                                               ap->yb + ap->ys * (row + 1) - 3);
+                                       XDrawPoint(display, window, MI_GC(mi),
+                                               ap->xb + ap->xs * (col + 1) - 3,
+                                               ap->yb + ap->ys * (row + 1) - 4);
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", direction);
+                       }
+               }
+       }
+}
+
+#if 0
+static void
+RandomSoup(mi)
+       ModeInfo   *mi;
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+       int         row, col, mrow = 0;
+
+       for (row = 0; row < ap->nrows; ++row) {
+               for (col = 0; col < ap->ncols; ++col) {
+                       ap->old[col + mrow] = (unsigned char) NRAND((int) ap->ncolors);
+                       drawcell(mi, col, row, ap->old[col + mrow]);
+               }
+               mrow += ap->nrows;
+       }
+}
+
+#endif
+
+static short
+fromTableDirection(unsigned char dir, int local_neighbors)
+{
+       switch (dir) {
+               case FS:
+                       return 0;
+               case TRS:
+                       return (ANGLES / local_neighbors);
+               case THRS:
+                       return (ANGLES / 2 - ANGLES / local_neighbors);
+               case TBS:
+                       return (ANGLES / 2);
+               case THLS:
+                       return (ANGLES / 2 + ANGLES / local_neighbors);
+               case TLS:
+                       return (ANGLES - ANGLES / local_neighbors);
+               case SF:
+                       return ANGLES;
+               case STR:
+                       return (ANGLES + ANGLES / local_neighbors);
+               case STHR:
+                       return (3 * ANGLES / 2 - ANGLES / local_neighbors);
+               case STB:
+                       return (3 * ANGLES / 2);
+               case STHL:
+                       return (3 * ANGLES / 2 + ANGLES / local_neighbors);
+               case STL:
+                       return (2 * ANGLES - ANGLES / local_neighbors);
+               default:
+                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+       }
+       return -1;
+}
+
+static void
+getTable(ModeInfo * mi, int i)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+       int         j, total;
+       unsigned char *patptr;
+
+       patptr = &tables[i][0];
+       ap->ncolors = *patptr++;
+       ap->nstates = *patptr++;
+       total = ap->ncolors * ap->nstates;
+       if (MI_IS_VERBOSE(mi))
+               (void) fprintf(stdout,
+                              "ants %d, neighbors %d, table number %d, colors %d, states %d\n",
+                         ap->n, ap->neighbors, i, ap->ncolors, ap->nstates);
+       for (j = 0; j < total; j++) {
+               ap->machine[j].color = *patptr++;
+               if (ap->sharpturn && ap->neighbors > 4 && !(ap->neighbors % 2)) {
+                       int         k = *patptr++;
+
+                       switch (k) {
+                               case TRS:
+                                       k = THRS;
+                                       break;
+                               case THRS:
+                                       k = TRS;
+                                       break;
+                               case THLS:
+                                       k = TLS;
+                                       break;
+                               case TLS:
+                                       k = THLS;
+                                       break;
+                               case STR:
+                                       k = STHR;
+                                       break;
+                               case STHR:
+                                       k = STR;
+                                       break;
+                               case STHL:
+                                       k = STL;
+                                       break;
+                               case STL:
+                                       k = STHL;
+                                       break;
+                               default:
+                                       break;
+                       }
+                       ap->machine[j].direction = fromTableDirection(k, ap->neighbors);
+               } else {
+                       ap->machine[j].direction = fromTableDirection(*patptr++, ap->neighbors);
+               }
+               ap->machine[j].next = *patptr++;
+       }
+       ap->truchet = False;
+}
+
+static void
+getTurk(ModeInfo * mi, int i)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+       int         power2, j, number, total;
+
+       /* To force a number, say <i = 2;> has  i + 2 (or 4) binary digits */
+       power2 = 1 << (i + 1);
+       /* Do not want numbers which in binary are all 1's. */
+       number = NRAND(power2 - 1) + power2;
+       /* To force a particular number, say <number = 10;> */
+
+       ap->ncolors = i + 2;
+       ap->nstates = 1;
+       total = ap->ncolors * ap->nstates;
+       for (j = 0; j < total; j++) {
+               ap->machine[j].color = (j + 1) % total;
+               if (ap->sharpturn && ap->neighbors > 4 && !(ap->neighbors % 2)) {
+                       ap->machine[j].direction = (power2 & number) ?
+                               fromTableDirection(THRS, ap->neighbors) :
+                               fromTableDirection(THLS, ap->neighbors);
+               } else {
+                       ap->machine[j].direction = (power2 & number) ?
+                               fromTableDirection(TRS, ap->neighbors) :
+                               fromTableDirection(TLS, ap->neighbors);
+               }
+               ap->machine[j].next = 0;
+               power2 >>= 1;
+       }
+       ap->truchet = (ap->truchet && ap->xs > 2 && ap->ys > 2 &&
+          (ap->neighbors == 3 || ap->neighbors == 4 || ap->neighbors == 6));
+       if (MI_IS_VERBOSE(mi))
+               (void) fprintf(stdout,
+                     "ants %d, neighbors %d, Turk's number %d, colors %d\n",
+                              ap->n, ap->neighbors, number, ap->ncolors);
+}
+
+void
+init_ant(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         size = MI_SIZE(mi);
+       antfarmstruct *ap;
+       int         col, row, dir;
+       long        i;
+
+       if (antfarms == NULL) {
+               if ((antfarms = (antfarmstruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (antfarmstruct))) == NULL)
+                       return;
+       }
+       ap = &antfarms[MI_SCREEN(mi)];
+       ap->redrawing = 0;
+       if (MI_NPIXELS(mi) <= 2) {
+               if (ap->stippledGC == None) {
+                       XGCValues   gcv;
+
+                       gcv.fill_style = FillOpaqueStippled;
+                       ap->stippledGC = XCreateGC(display, window, GCFillStyle, &gcv);
+               }
+               if (ap->init_bits == 0) {
+                       for (i = 1; i < NUMSTIPPLES; i++)
+                               ANTBITS(stipples[i], STIPPLESIZE, STIPPLESIZE);
+               }
+       }
+       ap->generation = 0;
+       ap->n = MI_COUNT(mi);
+       if (ap->n < -MINANTS) {
+               /* if ap->n is random ... the size can change */
+               if (ap->ants != NULL) {
+                       (void) free((void *) ap->ants);
+                       ap->ants = NULL;
+               }
+               ap->n = NRAND(-ap->n - MINANTS + 1) + MINANTS;
+       } else if (ap->n < MINANTS)
+               ap->n = MINANTS;
+
+       ap->width = MI_WIDTH(mi);
+       ap->height = MI_HEIGHT(mi);
+
+       if (neighbors == 8 || neighbors == 9 || neighbors == 12)
+               ap->neighbors = neighbors;      /* Discourage but not deny use... */
+       else
+               for (i = 0; i < NEIGHBORKINDS; i++) {
+                       if (neighbors == plots[i]) {
+                               ap->neighbors = plots[i];
+                               break;
+                       }
+                       if (i == NEIGHBORKINDS - 1) {
+                               ap->neighbors = plots[NRAND(NEIGHBORKINDS)];
+                               break;
+                       }
+               }
+
+       if (ap->neighbors == 6) {
+               int         nccols, ncrows;
+
+               if (ap->width < 2)
+                       ap->width = 2;
+               if (ap->height < 4)
+                       ap->height = 4;
+               if (size < -MINSIZE) {
+                       ap->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(ap->width, ap->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+                       if (ap->ys < MINRANDOMSIZE)
+                               ap->ys = MIN(MINRANDOMSIZE,
+                                            MAX(MINSIZE, MIN(ap->width, ap->height) / MINGRIDSIZE));
+               } else if (size < MINSIZE) {
+                       if (!size)
+                               ap->ys = MAX(MINSIZE, MIN(ap->width, ap->height) / MINGRIDSIZE);
+                       else
+                               ap->ys = MINSIZE;
+               } else
+                       ap->ys = MIN(size, MAX(MINSIZE, MIN(ap->width, ap->height) /
+                                              MINGRIDSIZE));
+               ap->xs = ap->ys;
+               nccols = MAX(ap->width / ap->xs - 2, 2);
+               ncrows = MAX(ap->height / ap->ys - 1, 2);
+               ap->ncols = nccols / 2;
+               ap->nrows = 2 * (ncrows / 4);
+               ap->xb = (ap->width - ap->xs * nccols) / 2 + ap->xs / 2;
+               ap->yb = (ap->height - ap->ys * (ncrows / 2) * 2) / 2 + ap->ys;
+               for (i = 0; i < 6; i++) {
+                       ap->shape.hexagon[i].x = (ap->xs - 1) * hexagonUnit[i].x;
+                       ap->shape.hexagon[i].y = ((ap->ys - 1) * hexagonUnit[i].y / 2) * 4 / 3;
+               }
+               /* Avoid array bounds read of hexagonUnit */
+               ap->shape.hexagon[6].x = 0;
+               ap->shape.hexagon[6].y = 0;
+       } else if (ap->neighbors == 4 || ap->neighbors == 8) {
+               if (size < -MINSIZE) {
+                       ap->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(ap->width, ap->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+                       if (ap->ys < MINRANDOMSIZE)
+                               ap->ys = MIN(MINRANDOMSIZE,
+                                            MAX(MINSIZE, MIN(ap->width, ap->height) / MINGRIDSIZE));
+               } else if (size < MINSIZE) {
+                       if (!size)
+                               ap->ys = MAX(MINSIZE, MIN(ap->width, ap->height) / MINGRIDSIZE);
+                       else
+                               ap->ys = MINSIZE;
+               } else
+                       ap->ys = MIN(size, MAX(MINSIZE, MIN(ap->width, ap->height) /
+                                              MINGRIDSIZE));
+               ap->xs = ap->ys;
+               ap->ncols = MAX(ap->width / ap->xs, 2);
+               ap->nrows = MAX(ap->height / ap->ys, 2);
+               ap->xb = (ap->width - ap->xs * ap->ncols) / 2;
+               ap->yb = (ap->height - ap->ys * ap->nrows) / 2;
+       } else {                /* TRI */
+               int         orient;
+
+               if (ap->width < 2)
+                       ap->width = 2;
+               if (ap->height < 2)
+                       ap->height = 2;
+               if (size < -MINSIZE) {
+                       ap->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(ap->width, ap->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+                       if (ap->ys < MINRANDOMSIZE)
+                               ap->ys = MIN(MINRANDOMSIZE,
+                                            MAX(MINSIZE, MIN(ap->width, ap->height) / MINGRIDSIZE));
+               } else if (size < MINSIZE) {
+                       if (!size)
+                               ap->ys = MAX(MINSIZE, MIN(ap->width, ap->height) / MINGRIDSIZE);
+                       else
+                               ap->ys = MINSIZE;
+               } else
+                       ap->ys = MIN(size, MAX(MINSIZE, MIN(ap->width, ap->height) /
+                                              MINGRIDSIZE));
+               ap->xs = (int) (1.52 * ap->ys);
+               ap->ncols = (MAX(ap->width / ap->xs - 1, 2) / 2) * 2;
+               ap->nrows = (MAX(ap->height / ap->ys - 1, 2) / 2) * 2;
+               ap->xb = (ap->width - ap->xs * ap->ncols) / 2 + ap->xs / 2;
+               ap->yb = (ap->height - ap->ys * ap->nrows) / 2 + ap->ys;
+               for (orient = 0; orient < 2; orient++) {
+                       for (i = 0; i < 3; i++) {
+                               ap->shape.triangle[orient][i].x =
+                                       (ap->xs - 2) * triangleUnit[orient][i].x;
+                               ap->shape.triangle[orient][i].y =
+                                       (ap->ys - 2) * triangleUnit[orient][i].y;
+                       }
+                       /* Avoid array bounds read of triangleUnit */
+                       ap->shape.triangle[orient][3].x = 0;
+                       ap->shape.triangle[orient][3].y = 0;
+               }
+       }
+
+       XSetLineAttributes(display, MI_GC(mi), 1, LineSolid, CapNotLast, JoinMiter);
+       MI_CLEARWINDOW(mi);
+       ap->painted = False;
+
+       if (MI_IS_FULLRANDOM(mi)) {
+               ap->truchet = (Bool) (LRAND() & 1);
+               ap->eyes = (Bool) (LRAND() & 1);
+               ap->sharpturn = (Bool) (LRAND() & 1);
+       } else {
+               ap->truchet = truchet;
+               ap->eyes = eyes;
+               ap->sharpturn = sharpturn;
+       }
+       ap->eyes = (ap->eyes && ap->xs > 3 && ap->ys > 3);
+       /* Exclude odd # of neighbors, stepping forward not defined */
+       if (!NRAND(NUMSTIPPLES) && ((ap->neighbors + 1) % 2)) {
+               getTable(mi, (int) (NRAND(NTABLES)));
+       } else
+               getTurk(mi, (int) (NRAND(NUMSTIPPLES - 1)));
+       if (MI_NPIXELS(mi) > 2)
+               for (i = 0; i < (int) ap->ncolors - 1; i++)
+                       ap->colors[i] = (unsigned char) (NRAND(MI_NPIXELS(mi)) +
+                            i * MI_NPIXELS(mi)) / ((int) (ap->ncolors - 1));
+       if (ap->ants == NULL)
+               ap->ants = (antstruct *) malloc(ap->n * sizeof (antstruct));
+       if (ap->tape != NULL)
+               (void) free((void *) ap->tape);
+       ap->tape = (unsigned char *)
+               calloc(ap->ncols * ap->nrows, sizeof (unsigned char));
+
+       if (ap->truchet_state != NULL)
+               (void) free((void *) ap->truchet_state);
+       ap->truchet_state = (unsigned char *)
+               calloc(ap->ncols * ap->nrows, sizeof (unsigned char));
+
+       col = ap->ncols / 2;
+       row = ap->nrows / 2;
+       dir = NRAND(ap->neighbors) * ANGLES / ap->neighbors;
+       /* Have them all start in the same spot, why not? */
+       for (i = 0; i < ap->n; i++) {
+               ap->ants[i].col = col;
+               ap->ants[i].row = row;
+               ap->ants[i].direction = dir;
+               ap->ants[i].state = 0;
+       }
+       draw_anant(mi, dir, col, row);
+}
+
+void
+draw_ant(ModeInfo * mi)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+       antstruct  *anant;
+       statestruct *status;
+       int         i, state_pos, tape_pos;
+       unsigned char color;
+       short       chg_dir, old_dir;
+
+       MI_IS_DRAWN(mi) = True;
+
+       ap->painted = True;
+       for (i = 0; i < ap->n; i++) {
+               anant = &ap->ants[i];
+               tape_pos = anant->col + anant->row * ap->ncols;
+               color = ap->tape[tape_pos];     /* read tape */
+               state_pos = color + anant->state * ap->ncolors;
+               status = &(ap->machine[state_pos]);
+               drawcell(mi, anant->col, anant->row, status->color);
+               ap->tape[tape_pos] = status->color;     /* write on tape */
+
+               /* Find direction of Bees or Ants. */
+               /* Translate relative direction to actual direction */
+               old_dir = anant->direction;
+               chg_dir = (2 * ANGLES - status->direction) % ANGLES;
+               anant->direction = (chg_dir + old_dir) % ANGLES;
+               if (ap->truchet) {
+                       int         a = 0, b;
+
+                       if (ap->neighbors == 6) {
+                               if (ap->sharpturn) {
+                                       a = (chg_dir / 120 == 2);
+                                       drawtruchet(mi, anant->col, anant->row, status->color, a);
+                               } else {
+                                       a = (old_dir / 60) % 3;
+                                       b = (anant->direction / 60) % 3;
+                                       a = (a + b + 1) % 3;
+                                       drawtruchet(mi, anant->col, anant->row, status->color, a);
+                               }
+                       } else if (ap->neighbors == 4) {
+                               a = old_dir / 180;
+                               b = anant->direction / 180;
+                               a = ((a && !b) || (b && !a));
+                               drawtruchet(mi, anant->col, anant->row, status->color, a);
+                       } else if (ap->neighbors == 3) {
+                               if (chg_dir == 240)
+                                       a = (2 + anant->direction / 120) % 3;
+                               else
+                                       a = (1 + anant->direction / 120) % 3;
+                               drawtruchet(mi, anant->col, anant->row, status->color, a);
+                       }
+                       ap->truchet_state[tape_pos] = a + 1;
+               }
+               anant->state = status->next;
+
+               /* If edge than wrap it */
+               old_dir = ((status->direction < ANGLES) ? anant->direction : old_dir);
+               position_of_neighbor(ap, old_dir, &(anant->col), &(anant->row));
+               draw_anant(mi, anant->direction, anant->col, anant->row);
+       }
+       if (++ap->generation > MI_CYCLES(mi)) {
+               init_ant(mi);
+       }
+       if (ap->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       if (ap->tape[ap->redrawpos] ||
+                        (ap->truchet && ap->truchet_state[ap->redrawpos])) {
+                               drawcell(mi, ap->redrawpos % ap->ncols, ap->redrawpos / ap->ncols,
+                                        ap->tape[ap->redrawpos]);
+                               if (ap->truchet)
+                                       drawtruchet(mi, ap->redrawpos % ap->ncols, ap->redrawpos / ap->ncols,
+                                                   ap->tape[ap->redrawpos],
+                                       ap->truchet_state[ap->redrawpos] - 1);
+                       }
+                       if (++(ap->redrawpos) >= ap->ncols * ap->nrows) {
+                               ap->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+void
+release_ant(ModeInfo * mi)
+{
+       if (antfarms != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       antfarmstruct *ap = &antfarms[screen];
+                       int         shade;
+
+                       if (ap->stippledGC != None) {
+                               XFreeGC(MI_DISPLAY(mi), ap->stippledGC);
+                       }
+                       for (shade = 0; shade < ap->init_bits; shade++)
+                               XFreePixmap(MI_DISPLAY(mi), ap->pixmaps[shade]);
+                       if (ap->tape != NULL)
+                               (void) free((void *) ap->tape);
+                       if (ap->ants != NULL)
+                               (void) free((void *) ap->ants);
+                       if (ap->truchet_state != NULL)
+                               (void) free((void *) ap->truchet_state);
+               }
+               (void) free((void *) antfarms);
+               antfarms = NULL;
+       }
+}
+
+void
+refresh_ant(ModeInfo * mi)
+{
+       antfarmstruct *ap = &antfarms[MI_SCREEN(mi)];
+
+       if (ap->painted) {
+               MI_CLEARWINDOW(mi);
+               ap->redrawing = 1;
+               ap->redrawpos = 0;
+       }
+}
+
+#endif /* MODE_ant */
diff --git a/xlockmore-4.14/modes/ball.c b/xlockmore-4.14/modes/ball.c
new file mode 100644 (file)
index 0000000..c44fcec
--- /dev/null
@@ -0,0 +1,511 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* ball --- bouncing balls with random drawing functions that leave a trail */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)ball.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by Heath Rice <rice@asl.dl.nec.com>.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Ball"
+#define HACK_INIT init_ball
+#define HACK_DRAW draw_ball
+#define ball_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 10 \n" \
+ "*cycles: 20 \n" \
+ "*size: -100 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_ball
+
+ModeSpecOpt ball_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   ball_description =
+{"ball", "init_ball", "draw_ball", "release_ball",
+ "refresh_ball", "init_ball", NULL, &ball_opts,
+ 10000, 10, 20, -100, 64, 1.0, "",
+ "Shows bouncing balls", 0, NULL};
+
+#endif
+
+#define NONE   0               /* not in a window */
+#define V      1               /* vertical */
+#define H      2               /* horizontal */
+#define B      3               /* ball */
+
+#define MINBALLS 1
+#define MINSIZE 2
+#define MINGRIDSIZE 4
+
+#define DEFNO  6
+#define SPEED  156
+#define SQLIMIT        (SPEED*SPEED/(30*30))   /* square of lower speed limit */
+#define RATE    600
+
+typedef struct {
+       int         x, y;       /* x and y coords */
+       int         dx, dy;     /* x and y velocity */
+       int         rad;
+       int         bounce;
+       int         dyold;
+       int         started;
+       int         def;
+       GC          GcF, GcB;
+} balltype;
+
+typedef struct {
+       Bool        painted;
+       balltype   *bt;
+       int         rad;
+       int         size;
+       int         width, height;
+       int         bounce;
+       int         nballs;
+       int         dispx, dispy;
+} ballstruct;
+
+static ballstruct *balls = NULL;
+
+static void
+collided(ModeInfo * mi, int i, int n, int *dx, int *dy, int td)
+{
+       ballstruct *bp = &balls[MI_SCREEN(mi)];
+       balltype   *bti = &bp->bt[i];
+       balltype   *btn = &bp->bt[n];
+       int         rx1, ry1, rx2, ry2;
+       int         Vx1, Vy1, Vx2, Vy2;
+       int         NVx1, NVy1, NVx2, NVy2;
+
+       float       Ux1, Uy1, Ux2, Uy2;
+       float       mag1, mag2, imp;
+
+       rx1 = bti->x;
+       ry1 = bti->y;
+       Vx1 = bti->dx;
+       Vy1 = bti->dy;
+
+       rx2 = btn->x;
+       ry2 = btn->y;
+       Vx2 = btn->dx;
+       Vy2 = btn->dy;
+
+       Ux1 = rx1 - rx2;
+       Uy1 = ry1 - ry2;
+       mag1 = sqrt(((Ux1 * Ux1) + (Uy1 * Uy1)));
+       Ux1 = Ux1 / mag1;
+       Uy1 = Uy1 / mag1;
+
+       Ux2 = rx2 - rx1;
+       Uy2 = ry2 - ry1;
+       mag2 = sqrt(((Ux2 * Ux2) + (Uy2 * Uy2)));
+       Ux2 = Ux2 / mag2;
+       Uy2 = Uy2 / mag2;
+
+       imp = ((Vx1 * Ux2) + (Vy1 * Uy2)) + ((Vx2 * Ux1) + (Vy2 * Uy1));
+
+       NVx1 = Vx1 + (int) (imp * Ux1);
+       NVy1 = Vy1 + (int) (imp * Uy1);
+
+       NVx2 = Vx2 + (int) (imp * Ux2);
+       NVy2 = Vy2 + (int) (imp * Uy2);
+
+       bti->dx = NVx1;
+       bti->dy = NVy1;
+
+       btn->dx = NVx2;
+       btn->dy = NVy2;
+
+       XFillArc(MI_DISPLAY(mi), MI_WINDOW(mi), btn->GcB,
+                btn->x - (btn->rad / 2), btn->y - (btn->rad / 2),
+                btn->rad, btn->rad, 0, 360 * 64);
+       if (bp->dispx > 100) {
+               *dx = (td * btn->dx) / RATE;
+               *dy = (td * btn->dy) / RATE;
+       } else {
+               *dx = (td * btn->dx) / 150;
+               *dy = (td * btn->dy) / 150;
+       }
+
+       btn->x += (*dx / 2);
+       btn->y += (*dy / 2);
+       XFillArc(MI_DISPLAY(mi), MI_WINDOW(mi), btn->GcF,
+                btn->x - (btn->rad / 2), btn->y - (btn->rad / 2),
+                btn->rad, btn->rad, 0, 360 * 64);
+
+       if (bp->dispx > 100) {
+               *dx = (td * bti->dx) / RATE;
+               *dy = (td * bti->dy) / RATE;
+       } else {
+               *dx = (td * bti->dx) / 150;
+               *dy = (td * bti->dy) / 150;
+       }
+
+       bti->x += (*dx / 2);
+       bti->y += (*dy / 2);
+}
+
+static int
+inwin(ballstruct * bp, int x, int y, int *n, int rad)
+{
+       int         i, diffx, diffy;
+
+       if ((x < 0) || (x > bp->dispx)) {
+               return (V);
+       }
+       if ((y < 0) || (y > bp->dispy)) {
+               return (H);
+       }
+       if (bp->dispx > 100) {
+               for (i = 0; i < bp->nballs; i++) {
+                       if ((i == (*n)) || (!bp->bt[i].def))
+                               continue;
+                       diffx = (bp->bt[i].x - x);
+                       diffy = (bp->bt[i].y - y);
+                       if ((diffx * diffx + diffy * diffy) <
+                           (((rad / 2) * (rad / 2) * 2) +
+                         ((bp->bt[i].rad / 2) * (bp->bt[i].rad / 2) * 2))) {
+                               (*n) = i;
+                               return (B);
+                       }
+               }
+       }
+       return (NONE);
+}
+
+static void
+randomball(ModeInfo * mi, int i)
+{
+       ballstruct *bp = &balls[MI_SCREEN(mi)];
+       balltype   *bti = &bp->bt[i];
+       Display    *display = MI_DISPLAY(mi);
+       int         x, y, bn;
+       int         dum;
+       int         attempts;
+       unsigned long randbg = 1;
+
+       attempts = 0;
+       if (bp->bounce == -2)
+               bn = 30 + NRAND(69L);
+       else
+               bn = bp->bounce;
+
+       if (bn > 100)
+               bn = 100;
+       if (bn < 0)
+               bn = 0;
+       bn = (0 - bn);
+
+       if (bp->dispx > 100) {
+               bti->dx = NRAND(2L * SPEED) + SPEED;
+               bti->dy = NRAND(2L * SPEED) + (SPEED / 2);
+       } else {
+               bti->dx = NRAND(4L * SPEED) + (SPEED / 20);
+               bti->dy = NRAND(2L * SPEED) + (SPEED / 40);
+       }
+
+       switch (NRAND(9L) % 2) {
+               case 0:
+                       break;
+               case 1:
+                       bti->dx = (0 - bti->dx);
+                       break;
+       }
+
+       bti->bounce = bn;
+       bti->dyold = 0;
+       bti->rad = bp->rad;     /* Pretty lame... should be different sizes */
+
+       do {
+               dum = i;
+               x = NRAND((long) bp->dispx);
+               y = 0;
+               attempts++;
+               if (attempts > 5) {
+                       bti->def = 0;
+                       return;
+               }
+       }
+
+       while ((inwin(bp, x, y, &dum, bti->rad) != NONE) ||
+              (inwin(bp, bti->dx + x, bti->dy + y, &dum, bti->rad) != NONE));
+
+       bti->def = 1;
+       bti->x = x;
+       bti->y = y;
+
+       /* set background color for ball */
+
+       if (MI_NPIXELS(mi) > 2) {
+               randbg = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       } else {
+               randbg = MI_BLACK_PIXEL(mi);
+       }
+       XSetForeground(display, bti->GcB, randbg);
+
+       /* set foreground color for ball */
+
+       if (MI_NPIXELS(mi) > 2) {
+               randbg = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       } else {
+               randbg = MI_WHITE_PIXEL(mi);
+       }
+       XSetForeground(display, bti->GcF, randbg);
+
+       XFillArc(display, MI_WINDOW(mi),
+                bti->GcB, bti->x - (bti->rad / 2), bti->y - (bti->rad / 2),
+                bti->rad, bti->rad, 0, 360 * 64);
+}
+
+void
+init_ball(ModeInfo * mi)
+{
+       ballstruct *bp;
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         GcLp, i;
+       int         size = MI_SIZE(mi);
+
+       if (balls == NULL) {
+               if ((balls = (ballstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (ballstruct))) == NULL)
+                       return;
+       }
+       bp = &balls[MI_SCREEN(mi)];
+
+       bp->bounce = 85;
+       bp->width = MI_WIDTH(mi);
+       bp->height = MI_HEIGHT(mi);
+
+       bp->nballs = MI_COUNT(mi);
+       if (bp->nballs < -MINBALLS) {
+               /* if bp->nballs is random ... the size can change */
+               if (bp->bt != NULL) {
+                       (void) free((void *) bp->bt);
+                       bp->bt = NULL;
+               }
+               bp->nballs = NRAND(-bp->nballs - MINBALLS + 1) + MINBALLS;
+       } else if (bp->nballs < MINBALLS)
+               bp->nballs = MINBALLS;
+       if (bp->bt == NULL) {
+               bp->bt = (balltype *) calloc(bp->nballs, sizeof (balltype));
+       }
+       if (size == 0 ||
+        MINGRIDSIZE * size > bp->width || MINGRIDSIZE * size > bp->height) {
+               bp->rad = MAX(MINSIZE, MIN(bp->width, bp->height) / MINGRIDSIZE);
+       } else {
+               if (size < -MINSIZE)
+                       bp->rad = NRAND(MIN(-size, MAX(MINSIZE, MIN(bp->width, bp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE)
+                       bp->rad = MINSIZE;
+               else
+                       bp->rad = MIN(size, MAX(MINSIZE, MIN(bp->width, bp->height) /
+                                               MINGRIDSIZE));
+       }
+
+       /* clearballs */
+       MI_CLEARWINDOW(mi);
+       bp->painted = False;
+       XFlush(display);
+       if (bp->nballs <= 0)
+               bp->nballs = 1;
+       if (!bp->bt[0].GcB) {
+               XGCValues   gcv;
+
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               for (GcLp = 0; GcLp < bp->nballs; GcLp++) {
+                       bp->bt[GcLp].GcB = XCreateGC(display, window,
+                                         GCForeground | GCBackground, &gcv);
+                       bp->bt[GcLp].GcF = XCreateGC(display, window,
+                                         GCForeground | GCBackground, &gcv);
+               }
+       }
+       for (GcLp = 0; GcLp < bp->nballs; GcLp++) {
+               if (MI_NPIXELS(mi) > 2) {
+                       XSetFunction(display, bp->bt[GcLp].GcB, NRAND(16L));
+                       XSetFunction(display, bp->bt[GcLp].GcF, NRAND(16L));
+               } else {
+                       XSetFunction(display, bp->bt[GcLp].GcB, NRAND(8L));
+                       XSetFunction(display, bp->bt[GcLp].GcF, NRAND(8L));
+               }
+       }
+
+       bp->dispx = MI_WIDTH(mi);
+       bp->dispy = MI_HEIGHT(mi);
+
+       XFlush(display);
+       for (i = 0; i < bp->nballs; i++) {
+               randomball(mi, i);
+       }
+}
+
+void
+draw_ball(ModeInfo * mi)
+{
+       ballstruct *bp = &balls[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         i, n;
+       int         td;
+       int         dx, dy;
+       int         redo;
+
+       MI_IS_DRAWN(mi) = True;
+
+       td = 10;
+       bp->painted = True;
+       for (i = 0; i < bp->nballs; i++) {
+               if (!bp->bt[i].def)
+                       randomball(mi, i);
+       }
+
+       for (i = 0; i < bp->nballs; i++) {
+               if (!bp->bt[i].def) {
+                       continue;
+               }
+               XFillArc(display, window, bp->bt[i].GcB,
+                        bp->bt[i].x - (bp->bt[i].rad / 2), bp->bt[i].y - (bp->bt[i].rad / 2),
+                        bp->bt[i].rad, bp->bt[i].rad, 0, 360 * 64);
+               redo = 0;
+               if (((bp->bt[i].dx * bp->bt[i].dx + bp->bt[i].dy * bp->bt[i].dy) <
+                    SQLIMIT) && (bp->bt[i].y >= (bp->dispy - 3))) {
+                       redo = 25;
+               }
+               do {
+                       if (bp->dispx > 100) {
+                               dx = (td * bp->bt[i].dx) / RATE;
+                               dy = (td * bp->bt[i].dy) / RATE;
+                       } else {
+                               dx = (td * bp->bt[i].dx) / 150;
+                               dy = (td * bp->bt[i].dy) / 150;
+                       }
+
+                       if (redo > 5) {
+                               redo = 0;
+                               randomball(mi, i);
+                               if (!bp->bt[i].def)
+                                       continue;
+                               XFillArc(display, window, bp->bt[i].GcF,
+                                        bp->bt[i].x - (bp->bt[i].rad / 2),
+                                        bp->bt[i].y - (bp->bt[i].rad / 2),
+                                 bp->bt[i].rad, bp->bt[i].rad, 0, 360 * 64);
+                       }
+                       n = i;
+                       switch (inwin(bp, dx + bp->bt[i].x, dy + bp->bt[i].y, &n,
+                                     bp->bt[i].rad)) {
+                               case NONE:
+                                       bp->bt[i].x += dx;
+                                       bp->bt[i].y += dy;
+                                       redo = 0;
+                                       break;
+                               case V:
+                                       bp->bt[i].dx = (int) (((float) bp->bt[i].bounce *
+                                       (float) bp->bt[i].dx) / (float) 100);
+                                       redo++;
+                                       break;
+                               case H:
+                                       bp->bt[i].dy = (int) (((float) bp->bt[i].bounce *
+                                       (float) bp->bt[i].dy) / (float) 100);
+                                       if (bp->bt[i].bounce != 100) {
+                                               if ((bp->bt[i].y >= (bp->dispy - 3)) && (bp->bt[i].dy > -250) &&
+                                                   (bp->bt[i].dy < 0)) {
+                                                       redo = 15;
+                                               }
+                                               if ((bp->bt[i].y >= (bp->dispy - 3)) &&
+                                                   (bp->bt[i].dy == bp->bt[i].dyold)) {
+                                                       redo = 10;
+                                               }
+                                               bp->bt[i].dyold = bp->bt[i].dy;
+                                       }
+                                       redo++;
+                                       break;
+                               case B:
+                                       if (redo > 5) {
+                                               if (bp->bt[i].y >= (bp->dispy - 3)) {
+                                                       randomball(mi, i);
+                                                       redo = 0;
+                                               } else if (bp->bt[n].y >= (bp->dispy - 3)) {
+                                                       randomball(mi, n);
+                                                       redo = 0;
+                                               } else
+                                                       redo = 0;
+                                       } else {
+                                               collided(mi, i, n, &dx, &dy, td);
+                                               redo = 0;
+                                       }
+                                       break;
+                       }
+               }
+               while (redo);
+               bp->bt[i].dy += td;
+
+               if (bp->bt[i].def)
+                       XFillArc(display, window, bp->bt[i].GcF,
+                                bp->bt[i].x - (bp->bt[i].rad / 2), bp->bt[i].y - (bp->bt[i].rad / 2),
+                                bp->bt[i].rad, bp->bt[i].rad, 0, 360 * 64);
+       }
+
+       XFlush(display);
+}
+
+void
+release_ball(ModeInfo * mi)
+{
+       if (balls != NULL) {
+               int         screen, i;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       ballstruct *bp = &balls[screen];
+
+                       for (i = 0; i < bp->nballs; i++) {
+                               if (bp->bt[i].GcF)
+                                       XFreeGC(MI_DISPLAY(mi), bp->bt[i].GcF);
+                               if (bp->bt[i].GcB)
+                                       XFreeGC(MI_DISPLAY(mi), bp->bt[i].GcB);
+                       }
+                       if (bp->bt != NULL)
+                               (void) free((void *) bp->bt);
+
+               }
+               (void) free((void *) balls);
+               balls = NULL;
+       }
+}
+
+void
+refresh_ball(ModeInfo * mi)
+{
+       ballstruct *bp = &balls[MI_SCREEN(mi)];
+
+       if (bp->painted)
+               MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_ball */
diff --git a/xlockmore-4.14/modes/bat.c b/xlockmore-4.14/modes/bat.c
new file mode 100644 (file)
index 0000000..746f284
--- /dev/null
@@ -0,0 +1,583 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* bat --- bouncing bats */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)bat.c        4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1988 by Sun Microsystems
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 18-Sep-95: 5 bats now in color <patol@info.isbiel.ch>
+ * 20-Sep-94: 5 bats instead of bouncing balls, based on bounce.c
+ *            <patol@info.isbiel.ch>
+ * 2-Sep-93: bounce version David Bagley <bagleyd@tux.org>
+ * 1986: Sun Microsystems
+ */
+
+/*-
+ * original copyright
+ * **************************************************************************
+ * Copyright 1988 by Sun Microsystems, Inc. Mountain View, CA.
+ *
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the names of Sun or MIT not be used in advertising
+ * or publicity pertaining to distribution of the software without specific
+ * prior written permission. Sun and M.I.T. make no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
+ * without any express or implied warranty.
+ *
+ * SUN DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ * IN NO EVENT SHALL SUN BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
+ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
+ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
+ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+ * SOFTWARE.
+ * ***************************************************************************
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Bat"
+#define HACK_INIT init_bat
+#define HACK_DRAW draw_bat
+#define bat_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: -8 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 200 \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "vis.h"
+#include "color.h"
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_bat
+
+ModeSpecOpt bat_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   bat_description =
+{"bat", "init_bat", "draw_bat", "release_bat",
+ "refresh_bat", "init_bat", NULL, &bat_opts,
+ 100000, -8, 1, 0, 64, 1.0, "",
+ "Shows bouncing flying bats", 0, NULL};
+
+#endif
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+#if USE_XPMINC
+#include <xpm.h>
+#else
+#include <X11/xpm.h>           /* Normal spot */
+#endif
+#include "pixmaps/bat-0.xpm"
+#include "pixmaps/bat-1.xpm"
+#include "pixmaps/bat-2.xpm"
+#include "pixmaps/bat-3.xpm"
+#include "pixmaps/bat-4.xpm"
+#endif
+
+#include "bitmaps/bat-0.xbm"
+#include "bitmaps/bat-1.xbm"
+#include "bitmaps/bat-2.xbm"
+#include "bitmaps/bat-3.xbm"
+#include "bitmaps/bat-4.xbm"
+
+#define MAX_STRENGTH 24
+#define FRICTION 15
+#define PENETRATION 0.4
+#define SLIPAGE 4
+#define TIME 32
+#define MINBATS 1
+#define MINSIZE 1
+#define MINGRIDSIZE 3
+
+#define ORIENTS 8
+#define ORIENTCYCLE 32
+#define CCW 1
+#define CW (ORIENTS-1)
+#define DIR(x) (((x)>=0)?CCW:CW)
+#define SIGN(x)        (((x)>=0)?1:-1)
+
+static XImage bimages[] =
+{
+       {0, 0, 0, XYBitmap, 0, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, 0, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, 0, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, 0, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, 0, LSBFirst, 8, LSBFirst, 8, 1}
+};
+
+typedef struct {
+       int         x, y, xlast, ylast;
+       int         spincount, spindelay, spindir, orient;
+       int         vx, vy, vang;
+       int         graphics_format;
+       unsigned long color;
+} batstruct;
+
+typedef struct {
+       int         width, height;
+       int         nbats;
+       int         xs, ys;
+       int         avgsize;
+       int         restartnum;
+       int         graphics_format;
+       int         pixelmode;
+       GC          backGC;
+       Colormap    cmap;
+       unsigned long black;
+       batstruct  *bats;
+       XImage     *images[ORIENTS / 2 + 1];
+} bouncestruct;
+
+static bouncestruct *bounces = NULL;
+
+static void checkCollision(bouncestruct * bp, int a_bat);
+static void drawabat(ModeInfo * mi, batstruct * bat);
+static void movebat(bouncestruct * bp, batstruct * bat);
+static void flapbat(batstruct * bat, int dir, int *vel, int avgsize);
+static int  collide(bouncestruct * bp, int a_bat);
+
+static unsigned char *bits[] =
+{
+       bat0_bits, bat1_bits, bat2_bits, bat3_bits, bat4_bits
+};
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+static char **pixs[] =
+{
+       bat0, bat1, bat2, bat3, bat4
+};
+
+#endif
+
+static void
+checkCollision(bouncestruct * bp, int a_bat)
+{
+       int         i, amount, spin, d, size;
+       double      x, y;
+
+       for (i = 0; i < bp->nbats; i++) {
+               if (i != a_bat) {
+                       x = (double) (bp->bats[i].x - bp->bats[a_bat].x);
+                       y = (double) (bp->bats[i].y - bp->bats[a_bat].y);
+                       d = (int) sqrt(x * x + y * y);
+                       size = bp->avgsize;
+                       if (d > 0 && d < size) {
+                               amount = size - d;
+                               if (amount > PENETRATION * size)
+                                       amount = (int) (PENETRATION * size);
+                               bp->bats[i].vx += (int) ((double) amount * x / d);
+                               bp->bats[i].vy += (int) ((double) amount * y / d);
+                               bp->bats[i].vx -= bp->bats[i].vx / FRICTION;
+                               bp->bats[i].vy -= bp->bats[i].vy / FRICTION;
+                               bp->bats[a_bat].vx -= (int) ((double) amount * x / d);
+                               bp->bats[a_bat].vy -= (int) ((double) amount * y / d);
+                               bp->bats[a_bat].vx -= bp->bats[a_bat].vx / FRICTION;
+                               bp->bats[a_bat].vy -= bp->bats[a_bat].vy / FRICTION;
+                               spin = (bp->bats[i].vang - bp->bats[a_bat].vang) /
+                                       (2 * size * SLIPAGE);
+                               bp->bats[i].vang -= spin;
+                               bp->bats[a_bat].vang += spin;
+                               bp->bats[i].spindir = DIR(bp->bats[i].vang);
+                               bp->bats[a_bat].spindir = DIR(bp->bats[a_bat].vang);
+                               if (!bp->bats[i].vang) {
+                                       bp->bats[i].spindelay = 1;
+                                       bp->bats[i].spindir = 0;
+                               } else
+                                       bp->bats[i].spindelay = (int) ((double) M_PI *
+                                                                      bp->avgsize / (ABS(bp->bats[i].vang))) + 1;
+                               if (!bp->bats[a_bat].vang) {
+                                       bp->bats[a_bat].spindelay = 1;
+                                       bp->bats[a_bat].spindir = 0;
+                               } else
+                                       bp->bats[a_bat].spindelay = (int) ((double) M_PI *
+                                                                          bp->avgsize / (ABS(bp->bats[a_bat].vang))) + 1;
+                               return;
+                       }
+               }
+       }
+}
+
+static void
+drawabat(ModeInfo * mi, batstruct * bat)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+
+       if (bp->pixelmode) {
+               if (bat->xlast != -1) {
+                       XSetForeground(display, bp->backGC, bp->black);
+                       XFillRectangle(display, window, bp->backGC,
+                                    bat->xlast, bat->ylast, bp->xs, bp->ys);
+               }
+               XSetForeground(display, bp->backGC, bat->color);
+               XFillRectangle(display, window, bp->backGC,
+                              bat->x, bat->y, bp->xs, bp->ys);
+       } else {
+               XSetForeground(display, bp->backGC, bat->color);
+/* PURIFY 4.0.1 on SunOS4 and on Solaris 2 reports a 15985 byte memory leak on
+   * the next line. */
+               (void) XPutImage(display, window, bp->backGC,
+                                bp->images[(bat->orient > ORIENTS / 2) ?
+                                       ORIENTS - bat->orient : bat->orient],
+                                0, 0, bat->x, bat->y, bp->xs, bp->ys);
+               if (bat->xlast != -1) {
+                       XSetForeground(display, bp->backGC, bp->black);
+                       ERASE_IMAGE(display, window, bp->backGC,
+                                   bat->x, bat->y, bat->xlast, bat->ylast, bp->xs, bp->ys);
+               }
+       }
+}
+
+static void
+movebat(bouncestruct * bp, batstruct * bat)
+{
+       bat->xlast = bat->x;
+       bat->ylast = bat->y;
+       bat->x += bat->vx;
+       if (bat->x > (bp->width - bp->xs)) {
+               /* Bounce off the right edge */
+               bat->x = 2 * (bp->width - bp->xs) - bat->x;
+               bat->vx = -bat->vx + bat->vx / FRICTION;
+               flapbat(bat, 1, &bat->vy, bp->avgsize);
+       } else if (bat->x < 0) {
+               /* Bounce off the left edge */
+               bat->x = -bat->x;
+               bat->vx = -bat->vx + bat->vx / FRICTION;
+               flapbat(bat, -1, &bat->vy, bp->avgsize);
+       }
+       bat->vy++;
+       bat->y += bat->vy;
+       if (bat->y >= (bp->height + bp->ys)) {  /* Don't see bat bounce */
+               /* Bounce off the bottom edge */
+               bat->y = (bp->height - bp->ys);
+               bat->vy = -bat->vy + bat->vy / FRICTION;
+               flapbat(bat, -1, &bat->vx, bp->avgsize);
+       }                       /* else if (bat->y < 0) { */
+       /* Bounce off the top edge */
+       /*bat->y = -bat->y;
+          bat->vy = -bat->vy + bat->vy / FRICTION;
+          flapbat(bat, 1, &bat->vx, bp->avgsize);
+          } */
+       if (bat->spindir) {
+               bat->spincount--;
+               if (!bat->spincount) {
+                       bat->orient = (bat->spindir + bat->orient) % ORIENTS;
+                       bat->spincount = bat->spindelay;
+               }
+       }
+}
+
+static void
+flapbat(batstruct * bat, int dir, int *vel, int avgsize)
+{
+       *vel -= (int) ((*vel + SIGN(*vel * dir) *
+                bat->spindelay * ORIENTCYCLE / (M_PI * avgsize)) / SLIPAGE);
+       if (*vel) {
+               bat->spindir = DIR(*vel * dir);
+               bat->vang = *vel * ORIENTCYCLE;
+               bat->spindelay = (int) ((double) M_PI * avgsize / (ABS(bat->vang))) + 1;
+       } else
+               bat->spindir = 0;
+}
+
+static int
+collide(bouncestruct * bp, int a_bat)
+{
+       int         i, d, x, y;
+
+       for (i = 0; i < a_bat; i++) {
+               x = (bp->bats[i].x - bp->bats[a_bat].x);
+               y = (bp->bats[i].y - bp->bats[a_bat].y);
+               d = (int) sqrt((double) (x * x + y * y));
+               if (d < bp->avgsize)
+                       return i;
+       }
+       return i;
+}
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+       int i;
+
+       if (!bp->cmap && !bp->pixelmode) {
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+               int         total = 0;
+               XpmAttributes attrib;
+
+#ifndef STANDALONE
+               if (!fixedColors(mi)) {
+                       bp->cmap = XCreateColormap(display, window, MI_VISUAL(mi), AllocNone);
+                       attrib.colormap = bp->cmap;
+                       reserveColors(mi, bp->cmap, &bp->black);
+               } else
+#endif /* STANDALONE */
+                       attrib.colormap = MI_COLORMAP(mi);
+
+               attrib.visual = MI_VISUAL(mi);
+               attrib.depth = MI_DEPTH(mi);
+               attrib.valuemask = XpmVisual | XpmColormap | XpmDepth;
+
+               if (bp->graphics_format == IS_NONE
+#ifndef USE_MONOXPM
+                   && MI_NPIXELS(mi) > 2
+#endif
+                       ) {
+                       for (i = 0; i <= ORIENTS / 2; i++)
+                               if (XpmSuccess != XpmCreateImageFromData(display, pixs[i],
+                               &(bp->images[i]), (XImage **) NULL, &attrib))
+                                       break;
+                       bp->graphics_format = IS_XPM;
+                       total = i;
+                       if (total <= ORIENTS / 2) {     /* All or nothing */
+                               bp->graphics_format = IS_XBM;
+                               if (MI_IS_VERBOSE(mi))
+                                       (void) fprintf(stderr, "Full color images could not be loaded.\n");
+                               for (i = 0; i < total; i++) {
+                                       (void) XDestroyImage(bp->images[i]);
+                                       bp->images[i] = None;
+                               }
+                               bp->images[total] = None;
+                               if (bp->cmap != None) {
+                                       XFreeColormap(display, bp->cmap);
+                                       bp->cmap = None;
+                               }
+                       }
+               }
+               if (total <= ORIENTS / 2)
+#endif
+
+               {
+                       if (!bimages[0].data)   /* Only need to do this once */
+                               for (i = 0; i <= ORIENTS / 2; i++) {
+                                       bimages[i].data = (char *) bits[i];
+                                       bimages[i].width = bat0_width;
+                                       bimages[i].height = bat0_height;
+                                       bimages[i].bytes_per_line = (bat0_width + 7) / 8;
+                               }
+                       for (i = 0; i <= ORIENTS / 2; i++)
+                               bp->images[i] = &(bimages[i]);
+               }
+       }
+       if (bp->cmap != None) {
+
+#ifndef STANDALONE
+               setColormap(display, window, bp->cmap, MI_IS_INWINDOW(mi));
+#endif
+               if (bp->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = bp->black;
+                       bp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else {
+               bp->black = MI_BLACK_PIXEL(mi);
+               bp->backGC = MI_GC(mi);
+       }
+}
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+static void
+free_stuff(Display * display, bouncestruct * bp)
+{
+       if (bp->graphics_format == IS_XPM) {
+               int         i;
+
+               for (i = 0; i <= ORIENTS / 2; i++) {
+                       if (bp->images[i]) {
+                               (void) XDestroyImage(bp->images[i]);
+                               bp->images[i] = None;
+                       }
+               }
+               bp->graphics_format = IS_NONE;
+       }
+       if (bp->cmap != None) {
+               XFreeColormap(display, bp->cmap);
+               if (bp->backGC != None) {
+                       XFreeGC(display, bp->backGC);
+                       bp->backGC = None;
+               }
+               bp->cmap = None;
+       } else
+               bp->backGC = None;
+}
+#endif
+
+void
+init_bat(ModeInfo * mi)
+{
+       bouncestruct *bp;
+       int         size = MI_SIZE(mi);
+       int         i, tryagain = 0;
+
+       if (bounces == NULL) {
+               if ((bounces = (bouncestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (bouncestruct))) == NULL)
+                       return;
+       }
+       bp = &bounces[MI_SCREEN(mi)];
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       free_stuff(MI_DISPLAY(mi), bp);
+#endif
+
+       bp->width = MI_WIDTH(mi);
+       bp->height = MI_HEIGHT(mi);
+       if (bp->width < 2)
+               bp->width = 2;
+       if (bp->height < 2)
+               bp->height = 2;
+       bp->restartnum = TIME;
+
+       bp->nbats = MI_COUNT(mi);
+       if (bp->nbats < -MINBATS) {
+               /* if bp->nbats is random ... the size can change */
+               if (bp->bats != NULL) {
+                       (void) free((void *) bp->bats);
+                       bp->bats = NULL;
+               }
+               bp->nbats = NRAND(-bp->nbats - MINBATS + 1) + MINBATS;
+       } else if (bp->nbats < MINBATS)
+               bp->nbats = MINBATS;
+       if (!bp->bats)
+               bp->bats = (batstruct *) malloc(bp->nbats * sizeof (batstruct));
+       if (size == 0 ||
+           MINGRIDSIZE * size > bp->width / 2 || MINGRIDSIZE * size > bp->height) {
+               if (bp->width > MINGRIDSIZE * bat0_width &&
+                   bp->height > MINGRIDSIZE * bat0_height) {
+                       bp->pixelmode = False;
+                       bp->xs = bat0_width;
+                       bp->ys = bat0_height;
+               } else {
+                       bp->pixelmode = True;
+                       bp->ys = MAX(MINSIZE, MIN(bp->width / 2, bp->height) / MINGRIDSIZE);
+                       bp->xs = 2 * bp->ys;
+               }
+       } else {
+               bp->pixelmode = True;
+               if (size < -MINSIZE)
+                       bp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(bp->width / 2, bp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE)
+                       bp->ys = MINSIZE;
+               else
+                       bp->ys = MIN(size, MAX(MINSIZE, MIN(bp->width / 2, bp->height) /
+                                              MINGRIDSIZE));
+               bp->xs = 2 * bp->ys;
+       }
+       bp->avgsize = (bp->xs + bp->ys) / 2;
+
+       init_stuff(mi);
+
+       i = 0;
+       while (i < bp->nbats) {
+               bp->bats[i].vx = ((LRAND() & 1) ? -1 : 1) * (NRAND(MAX_STRENGTH) + 1);
+               bp->bats[i].x = (bp->bats[i].vx >= 0) ? 0 : bp->width - bp->xs;
+               bp->bats[i].y = NRAND(bp->height / 2);
+               if (i == collide(bp, i) || tryagain >= 8) {
+                       if (MI_NPIXELS(mi) > 2)
+                               bp->bats[i].color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       else
+                               bp->bats[i].color = MI_WHITE_PIXEL(mi);
+                       bp->bats[i].xlast = -1;
+                       bp->bats[i].ylast = 0;
+                       bp->bats[i].spincount = 1;
+                       bp->bats[i].spindelay = 1;
+                       bp->bats[i].vy = ((LRAND() & 1) ? -1 : 1) * NRAND(MAX_STRENGTH);
+                       bp->bats[i].spindir = 0;
+                       bp->bats[i].vang = 0;
+                       bp->bats[i].orient = NRAND(ORIENTS);
+                       i++;
+               } else
+                       tryagain++;
+       }
+       MI_CLEARWINDOWCOLORMAP(mi, bp->backGC, bp->black);
+}
+
+void
+draw_bat(ModeInfo * mi)
+{
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < bp->nbats; i++) {
+               drawabat(mi, &bp->bats[i]);
+               movebat(bp, &bp->bats[i]);
+       }
+       for (i = 0; i < bp->nbats; i++)
+               checkCollision(bp, i);
+       if (!NRAND(TIME))       /* Put some randomness into the time */
+               bp->restartnum--;
+       if (!bp->restartnum)
+               init_bat(mi);
+}
+
+void
+release_bat(ModeInfo * mi)
+{
+       if (bounces != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       bouncestruct *bp = &bounces[screen];
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                       free_stuff(MI_DISPLAY(mi), bp);
+#endif
+
+                       if (bp->bats != NULL)
+                               (void) free((void *) bp->bats);
+               }
+               (void) free((void *) bounces);
+               bounces = NULL;
+       }
+}
+
+void
+refresh_bat(ModeInfo * mi)
+{
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOWCOLORMAP(mi, bp->backGC, bp->black);
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       /* This is needed when another program changes the colormap. */ 
+       free_stuff(MI_DISPLAY(mi), bp);
+       init_stuff(mi);
+#endif
+}
+
+#endif /* MODE_bat */
diff --git a/xlockmore-4.14/modes/blank.c b/xlockmore-4.14/modes/blank.c
new file mode 100644 (file)
index 0000000..4ac768e
--- /dev/null
@@ -0,0 +1,97 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* blank --- blank screen */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)blank.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver :)  OK you probably should not
+ *    use this for xscreensaver but I could not resist.
+ * 21-Mar-96: Ron Hitchens <ron@idiom.com>
+ *             Bonehead alert.  Don't blank during password prompting.
+ * 19-Mar-96: Ron Hitchens <ron@idiom.com>
+ *             Changed to activate X server's native screensaver.
+ *             On some devices, this will result in power saving "sleep"
+ *             mode, or video blanking.
+ * 31-Aug-90: Written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Blank"
+#define HACK_INIT init_blank
+#define HACK_DRAW draw_blank
+#define blank_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000000 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+ModeSpecOpt blank_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   blank_description =
+{"blank", "init_blank", "draw_blank", "release_blank",
+ "refresh_blank", "init_blank", NULL, &blank_opts,
+ 3000000, 1, 1, 1, 64, 1.0, "",
+ "Shows nothing but a black screen", 0, NULL};
+
+#endif
+
+extern Bool enablesaver;
+
+void
+init_blank(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+       /* Must set PreferBlanking, or XForceScreenSaver won't work */
+       if (!MI_IS_INWINDOW(mi) && !MI_IS_INROOT(mi) && enablesaver)
+               XSetScreenSaver(MI_DISPLAY(mi), 0, 0, PreferBlanking, 0);
+}
+
+/* ARGSUSED */
+void
+draw_blank(ModeInfo * mi)
+{
+       /* Leave the lights on while user types password */
+       if (!MI_IS_INWINDOW(mi) && !MI_IS_INROOT(mi) && enablesaver) {
+               if (MI_IS_ICONIC(mi))
+                       XForceScreenSaver(MI_DISPLAY(mi), ScreenSaverReset);
+               else
+                       XForceScreenSaver(MI_DISPLAY(mi), ScreenSaverActive);
+       }
+}
+
+void
+release_blank(ModeInfo * mi)
+{
+       /* clear screensaver settings, just in case */
+       if (!MI_IS_INWINDOW(mi) && !MI_IS_INROOT(mi) && enablesaver) {
+               XForceScreenSaver(MI_DISPLAY(mi), ScreenSaverReset);
+               XSetScreenSaver(MI_DISPLAY(mi), 0, 0, 0, 0);
+       }
+}
+
+void
+refresh_blank(ModeInfo * mi)
+{
+       /* Do nothing, it will refresh by itself :) */
+}
diff --git a/xlockmore-4.14/modes/blot.c b/xlockmore-4.14/modes/blot.c
new file mode 100644 (file)
index 0000000..cc150ec
--- /dev/null
@@ -0,0 +1,202 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* blot --- Rorschach's ink blot test */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)blot.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1992 by Jamie Zawinski
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * 10-May-97: Compatible with xscreensaver
+ * 05-Jan-95: patch for Dual-Headed machines from Greg Onufer
+ *            <Greg.Onufer@Eng.Sun.COM>
+ * 07-Dec-94: now randomly has xsym, ysym, or both.
+ * 02-Sep-93: xlock version David Bagley <bagleyd@tux.org>
+ * 1992:      xscreensaver version Jamie Zawinski <jwz@jwz.org>
+ */
+
+/*-
+ * original copyright
+ * Copyright (c) 1992 by Jamie Zawinski
+ * Permission to use, copy, modify, distribute, and sell this software and
+ * its documentation for any purpose is hereby granted without fee, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this 
+ * software for any purpose.  It is provided "as is" without express or
+ * implied warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Blot"
+#define HACK_INIT init_blot
+#define HACK_DRAW draw_blot
+#define blot_opts xlockmore_opts
+#define DEFAULTS "*delay: 2000000 \n" \
+ "*count: 6 \n" \
+ "*cycles: 30 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_blot
+
+ModeSpecOpt blot_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   blot_description =
+{"blot", "init_blot", "draw_blot", "release_blot",
+ "refresh_blot", "init_blot", NULL, &blot_opts,
+ 200000, 6, 30, 1, 64, 0.3, "",
+ "Shows Rorschach's ink blot test", 0, NULL};
+
+#endif
+
+typedef struct {
+       int         width;
+       int         height;
+       int         xmid, ymid;
+       int         offset;
+       int         xsym, ysym;
+       int         size;
+       int         pix;
+       int         count;
+       XPoint     *pointBuffer;
+       unsigned int pointBufferSize;
+} blotstruct;
+
+static blotstruct *blots = NULL;
+
+void
+init_blot(ModeInfo * mi)
+{
+       blotstruct *bp;
+       Display    *display = MI_DISPLAY(mi);
+
+       if (blots == NULL) {
+               if ((blots = (blotstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (blotstruct))) == NULL)
+                       return;
+       }
+       bp = &blots[MI_SCREEN(mi)];
+
+       bp->width = MI_WIDTH(mi);
+       bp->height = MI_HEIGHT(mi);
+       bp->xmid = bp->width / 2;
+       bp->ymid = bp->height / 2;
+
+       bp->offset = 4;
+       bp->ysym = (int) LRAND() & 1;
+       bp->xsym = (bp->ysym) ? (int) LRAND() & 1 : 1;
+       if (MI_NPIXELS(mi) > 2)
+               bp->pix = NRAND(MI_NPIXELS(mi));
+       if (bp->offset <= 0)
+               bp->offset = 3;
+       if (MI_COUNT(mi) < 0)
+               bp->size = NRAND(-MI_COUNT(mi) + 1);
+       else
+               bp->size = MI_COUNT(mi);
+
+       /* Fudge the size so it takes up the whole screen */
+       bp->size *= (bp->width / 32 + 1) * (bp->height / 32 + 1);
+       if (!bp->pointBuffer || bp->pointBufferSize < bp->size * sizeof (XPoint)) {
+               if (bp->pointBuffer != NULL)
+                       (void) free((void *) bp->pointBuffer);
+               bp->pointBufferSize = bp->size * sizeof (XPoint);
+               bp->pointBuffer = (XPoint *) malloc(bp->pointBufferSize);
+       }
+       MI_CLEARWINDOW(mi);
+       XSetForeground(display, MI_GC(mi), MI_WHITE_PIXEL(mi));
+       bp->count = 0;
+}
+
+void
+draw_blot(ModeInfo * mi)
+{
+       blotstruct *bp = &blots[MI_SCREEN(mi)];
+       XPoint     *xp = bp->pointBuffer;
+       int         x, y, k;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_PIXEL(mi, bp->pix));
+               if (++bp->pix >= MI_NPIXELS(mi))
+                       bp->pix = 0;
+       }
+       x = bp->xmid;
+       y = bp->ymid;
+       k = bp->size;
+       while (k >= 4) {
+               x += (NRAND(1 + (bp->offset << 1)) - bp->offset);
+               y += (NRAND(1 + (bp->offset << 1)) - bp->offset);
+               k--;
+               xp->x = x;
+               xp->y = y;
+               xp++;
+               if (bp->xsym) {
+                       k--;
+                       xp->x = bp->width - x;
+                       xp->y = y;
+                       xp++;
+               }
+               if (bp->ysym) {
+                       k--;
+                       xp->x = x;
+                       xp->y = bp->height - y;
+                       xp++;
+               }
+               if (bp->xsym && bp->ysym) {
+                       k--;
+                       xp->x = bp->width - x;
+                       xp->y = bp->height - y;
+                       xp++;
+               }
+       }
+       XDrawPoints(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                   bp->pointBuffer, (bp->size - k), CoordModeOrigin);
+       if (++bp->count > MI_CYCLES(mi))
+               init_blot(mi);
+}
+
+
+void
+release_blot(ModeInfo * mi)
+{
+       if (blots != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       if (blots[screen].pointBuffer != NULL) {
+                               (void) free((void *) blots[screen].pointBuffer);
+                       }
+               }
+               (void) free((void *) blots);
+               blots = NULL;
+       }
+}
+
+void
+refresh_blot(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_blot */
diff --git a/xlockmore-4.14/modes/bomb.c b/xlockmore-4.14/modes/bomb.c
new file mode 100644 (file)
index 0000000..4b307e5
--- /dev/null
@@ -0,0 +1,417 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* bomb --- temporary screen */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)bomb.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1994 by Dave Shield
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Made more compatible with xscreensaver :) 
+ * 09-Jan-95: Assorted defines to control various aspects of bomb mode.
+ *            Uncomment, or otherwise define the appropriate line
+ *            to obtain the relevant behaviour, thanks to Dave Shield
+ *            <D.T.Shield@csc.liv.ac.uk>.
+ * 20-Dec-94: Time patch for multiprocessor machines (ie. Sun10) thanks to
+ *            Nicolas Pioch <pioch@Email.ENST.Fr>.
+ * 1994:      Written.  Dave Shield  Liverpool Computer Science
+ */
+
+/*-
+ * This mode may have limited appeal.  Its good for logging yourself out
+ * if you do not know if your going to be back.  It is no longer to be used
+ * as a way of forcing users in a lab to logout after locking the screen.
+ */
+
+
+#ifdef STANDALONE
+#define USE_BOMB
+#define PROGCLASS "Bomb"
+#define HACK_INIT init_bomb
+#define HACK_DRAW draw_bomb
+#define bomb_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000000 \n" \
+ "*count: 10 \n" \
+ "*cycles: 20 \n" \
+ "*ncolors: 200 \n" \
+ "*verbose: False \n"
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_bomb
+
+ModeSpecOpt bomb_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   bomb_description =
+{"bomb", "init_bomb", "draw_bomb", "release_bomb",
+ "refresh_bomb", "change_bomb", NULL, &bomb_opts,
+ 100000, 10, 20, 1, 64, 1.0, "",
+ "Shows a bomb and will autologout after a time", 0, NULL};
+
+#endif
+
+#include <sys/signal.h>
+
+#if 0
+#define SIMPLE_COUNTDOWN       /* Display a simple integer countdown,     */
+#endif
+                             /*  rather than a "MIN:SEC" format.        */
+#define COLOUR_CHANGE          /* Display cycles through the colour wheel */
+                             /*  rather than staying red throughout.    */
+
+#define FULL_COUNT_FONT         "-*-*-*-*-*-*-34-*-*-*-*-*-*-*"
+#define ICON_COUNT_FONT         "-*-*-*-*-*-*-8-*-*-*-*-*-*-*"
+#define COUNTDOWN       600    /* No. seconds to lock for */
+#define NDIGITS         4      /* Number of digits in count */
+
+#define MAX_DELAY       1000000        /* Max delay between updates */
+#define NAP_TIME        5      /* Sleep between shutdown attempts */
+#define DELTA           10     /* Border around the digits */
+#define RIVET_RADIUS    6      /* Size of detonator 'rivets' */
+
+extern XFontStruct *getFont(Display * display);
+
+typedef struct {
+       Bool        painted;
+       int         width, height;
+       int         x, y;
+       XPoint      loc;
+       int         delta;
+       int         color;
+       int         countdown;
+       int         startcountdown;
+       int         text_width;
+       int         text_ascent;
+       int         text_descent;
+       int         moveok;
+} bombstruct;
+
+static bombstruct *bombs = NULL;
+
+static XFontStruct *mode_font = None;
+
+static void
+rivet(ModeInfo * mi, int x, int y)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       if (MI_NPIXELS(mi) > 2) {
+               XDrawArc(display, MI_WINDOW(mi), gc, x, y,
+                     2 * RIVET_RADIUS, 2 * RIVET_RADIUS, 270 * 64, 90 * 64);
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               XDrawArc(display, MI_WINDOW(mi), gc, x, y,
+                     2 * RIVET_RADIUS, 2 * RIVET_RADIUS, 70 * 64, 130 * 64);
+       } else
+               XDrawArc(display, MI_WINDOW(mi), gc, x, y,
+                        2 * RIVET_RADIUS, 2 * RIVET_RADIUS, 0, 360 * 64);
+}
+
+static void
+detonator(ModeInfo * mi, int draw)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       bombstruct *bp = &bombs[MI_SCREEN(mi)];
+       int         b_width, b_height;
+
+       b_width = bp->width / 2;
+       b_height = bp->height / 3;
+       if (draw) {
+#ifdef SOLARIS2
+               /*
+                * if this is not done the rectangle is sometimes messed up on
+                * Solaris2 with 24 bit TrueColor (Ultra2)
+                */
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, MI_WINDOW(mi), gc,
+                              bp->loc.x, bp->loc.y, b_width, b_height);
+#endif
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(MI_DISPLAY(mi), MI_GC(mi),
+                                      MI_PIXEL(mi, bp->color));
+               else
+                       XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WHITE_PIXEL(mi));
+               /*XSetForeground(display, gc, allocPixel(display, MI_COLORMAP(mi),
+                  "grey", "white")); */
+               XFillRectangle(display, MI_WINDOW(mi), gc,
+                              bp->loc.x, bp->loc.y, b_width, b_height);
+
+               /*
+                *  If a full size screen (and colour),
+                *      'rivet' the box to it
+                */
+               if (bp->width > 160 && bp->height > 160) {
+                       rivet(mi, bp->loc.x + RIVET_RADIUS, bp->loc.y + RIVET_RADIUS);
+                       rivet(mi, bp->loc.x + RIVET_RADIUS,
+                             bp->loc.y + b_height - 3 * RIVET_RADIUS);
+                       rivet(mi, bp->loc.x + b_width - 3 * RIVET_RADIUS,
+                             bp->loc.y + RIVET_RADIUS);
+                       rivet(mi, bp->loc.x + b_width - 3 * RIVET_RADIUS,
+                             bp->loc.y + b_height - 3 * RIVET_RADIUS);
+               }
+       } else {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, MI_WINDOW(mi), gc,
+                              bp->loc.x, bp->loc.y, b_width, b_height);
+       }
+}
+
+void
+init_bomb(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       bombstruct *bp;
+       char        number[NDIGITS + 2];
+
+       if (bombs == NULL) {
+               if ((bombs = (bombstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (bombstruct))) == NULL)
+                       return;
+       }
+       bp = &bombs[MI_SCREEN(mi)];
+
+       bp->width = MI_WIDTH(mi);
+       bp->height = MI_HEIGHT(mi);
+
+       if (mode_font != None) {
+               XFreeFont(MI_DISPLAY(mi), mode_font);
+               mode_font = None;
+       }
+       /* Set up text font */
+       if (bp->width > 256 && bp->height > 256) {      /* Full screen */
+               mode_font = XLoadQueryFont(display, FULL_COUNT_FONT);
+               bp->delta = DELTA;
+       } else {                /* icon window */
+               mode_font = XLoadQueryFont(display, ICON_COUNT_FONT);
+               bp->delta = 2;
+       }
+       if (mode_font == None)
+               mode_font = getFont(display);
+       if (mode_font != None)
+               XSetFont(display, gc, mode_font->fid);
+
+#ifdef SIMPLE_COUNTDOWN
+       (void) sprintf(number, "%0*d", NDIGITS, 0);
+#else
+       (void) sprintf(number, "%.*s:**", NDIGITS - 2, "*******");
+#endif
+       if (mode_font != None)
+               bp->text_width = XTextWidth(mode_font, number, NDIGITS + 1);
+       else
+               bp->text_width = 8;
+       bp->text_ascent = mode_font->max_bounds.ascent;
+       bp->text_descent = mode_font->max_bounds.descent;
+
+#ifndef STANDALONE
+       if (MI_DELAY(mi) > MAX_DELAY)
+               MI_DELAY(mi) = MAX_DELAY;       /* Time cannot move slowly */
+#endif /* STANDALONE */
+       if (MI_COUNT(mi) < 1)
+               bp->startcountdown = 1;         /* Do not want an instantaneous logout */
+       bp->startcountdown = MI_COUNT(mi);
+       bp->startcountdown *= 60;
+#if 0                          /* Stricter if uncommented but people do not have to run bomb */
+       if (bp->startcountdown > COUNTDOWN)
+               bp->startcountdown = COUNTDOWN;
+#endif
+       if (bp->countdown == 0) /* <--Stricter if uncommented */
+               bp->countdown = (int) (time((time_t *) NULL) + bp->startcountdown);
+       /* Detonator Primed */
+
+       MI_CLEARWINDOW(mi);
+       bp->painted = False;
+
+       /*
+        *  Draw the graphics
+        *      Very simple - detonator box with countdown
+        *
+        *  ToDo:  Improve the graphics
+        *      (e.g. stick of dynamite, with burning fuse?)
+        */
+       bp->loc.x = NRAND(bp->width / 2);
+       bp->loc.y = NRAND(bp->height * 3 / 5);
+       bp->x = bp->loc.x + bp->width / 4 - (bp->text_width / 2);
+       bp->y = bp->loc.y + bp->height / 5;     /* Central-ish */
+       if (MI_NPIXELS(mi) > 2)
+               bp->color = NRAND(MI_NPIXELS(mi));
+       detonator(mi, 1);
+       bp->moveok = 0;
+}
+
+       /*
+        *  Game Over
+        */
+static void
+explode(ModeInfo * mi)
+{
+       bombstruct *bp = &bombs[MI_SCREEN(mi)];
+       char        buff[NDIGITS + 2];
+       extern void logoutUser(Display * display);
+
+#ifdef SunCplusplus
+/* #include <signal.h> */
+       extern int  kill(pid_t, int);
+
+#else
+#if 0
+       extern int  kill(int, int);
+
+#endif
+#endif
+
+       /*
+        *  ToDo:
+        *      Improve the graphics - some sort of explosion?
+        *      (Will need to involve the main X event loop)
+        */
+#ifdef SIMPLE_COUNTDOWN
+       (void) sprintf(buff, "%.*s", NDIGITS, "*********");
+#else
+       (void) sprintf(buff, "%.*s:**", NDIGITS - 2, "*******");
+#endif
+       XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_PIXEL(mi, 1));
+       (void) XDrawString(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                          bp->x, bp->y, buff, NDIGITS);
+
+       (void) fprintf(stderr, "BOOM!!!!\n");
+#ifndef DEBUG
+       if (MI_IS_INWINDOW(mi) || MI_IS_INROOT(mi) ||
+           MI_IS_NOLOCK(mi) || MI_IS_DEBUG(mi))
+               (void) kill((int) getpid(), SIGTERM);
+       else if ((int) getuid() == 0) {         /* Do not try to logout root! */
+               bp->countdown = 0;
+               init_bomb(mi);
+       } else
+               logoutUser(MI_DISPLAY(mi));
+#else
+       (void) kill(getpid(), SIGTERM);
+#endif
+}
+
+void
+draw_bomb(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       bombstruct *bp = &bombs[MI_SCREEN(mi)];
+       char        number[NDIGITS + 2];
+       unsigned long crayon;
+       time_t      countleft;
+
+       countleft = (bp->countdown - time((time_t *) NULL));
+       if (countleft <= 0)
+               explode(mi);    /* Bye, bye.... */
+       else {
+               bp->painted = True;
+#ifdef SIMPLE_COUNTDOWN
+               (void) sprintf(number, "%0*d", NDIGITS, (int) countleft);
+#else
+               (void) sprintf(number, "%0*d:%02d", NDIGITS - 2,
+                              (int) countleft / 60, (int) countleft % 60);
+#endif
+
+               /* Blank out the previous number .... */
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, MI_WINDOW(mi), gc,
+                              bp->x - bp->delta,
+                              (bp->y - bp->text_ascent) - bp->delta,
+                              bp->text_width + (2 * bp->delta),
+                    (bp->text_ascent + bp->text_descent) + (2 * bp->delta));
+
+               /* ... and count down */
+               if (MI_NPIXELS(mi) <= 2)
+                       crayon = MI_WHITE_PIXEL(mi);
+               else
+#ifdef COLOUR_CHANGE           /* Blue to red */
+                       crayon = MI_PIXEL(mi, countleft * MI_NPIXELS(mi) / bp->startcountdown);
+#else
+                       crayon = MI_PIXEL(mi, 1);
+#endif
+               if (!(countleft % 60)) {
+                       if (bp->moveok) {
+                               detonator(mi, 0);
+                               bp->loc.x = NRAND(bp->width / 2);
+                               bp->loc.y = NRAND(bp->height * 3 / 5);
+                               bp->x = bp->loc.x + bp->width / 4 - (bp->text_width / 2);
+                               bp->y = bp->loc.y + bp->height / 5;     /* Central-ish */
+                               if (MI_NPIXELS(mi) > 2)
+                                       bp->color = NRAND(MI_NPIXELS(mi));
+                               detonator(mi, 1);
+                               bp->moveok = 0;
+                       }
+               } else {
+                       bp->moveok = 1;
+               }
+               XSetForeground(display, gc, crayon);
+               (void) XDrawString(display, MI_WINDOW(mi), gc, bp->x, bp->y,
+                                  number, strlen(number));
+       }
+}
+
+void
+release_bomb(ModeInfo * mi)
+{
+       if (bombs != NULL) {
+               (void) free((void *) bombs);
+               bombs = NULL;
+       }
+       if (mode_font != None) {
+               XFreeFont(MI_DISPLAY(mi), mode_font);
+               mode_font = None;
+       }
+}
+
+void
+refresh_bomb(ModeInfo * mi)
+{
+       bombstruct *bp = &bombs[MI_SCREEN(mi)];
+
+       if (bp->painted) {
+               MI_CLEARWINDOW(mi);
+               detonator(mi, 1);
+       }
+}
+
+void
+change_bomb(ModeInfo * mi)
+{
+       bombstruct *bp = &bombs[MI_SCREEN(mi)];
+
+       detonator(mi, 0);
+       bp->painted = False;
+       bp->loc.x = NRAND(bp->width / 2);
+       bp->loc.y = NRAND(bp->height * 3 / 5);
+       bp->x = bp->loc.x + bp->width / 4 - (bp->text_width / 2);
+       bp->y = bp->loc.y + bp->height / 5;     /* Central-ish */
+       if (MI_NPIXELS(mi) > 2)
+               bp->color = NRAND(MI_NPIXELS(mi));
+       detonator(mi, 1);
+       bp->moveok = 0;
+}
+
+#endif  /* MODE_bomb */
diff --git a/xlockmore-4.14/modes/bouboule.c b/xlockmore-4.14/modes/bouboule.c
new file mode 100644 (file)
index 0000000..1f8d9b5
--- /dev/null
@@ -0,0 +1,850 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* bouboule --- glob of spheres twisting and changing size */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)bouboule.c   4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright 1996 by Jeremie PETIT <petit@eurecom.fr>, <jpetit@essi.fr>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 15-May-97: jwz@jwz.org: turned into a standalone program.
+ * 04-Sep-96: Added 3d support Henrik Theiling <theiling@coli-uni-sb.de>
+ * 20-Feb-96: Added tests so that already malloced objects are not
+ *            malloced twice, thanks to the report from <mccomb@interport.net>
+ * 01-Feb-96: Patched by Jouk Jansen <joukj@hrem.stm.tudelft.nl> for VMS
+ *            Patched by <bagleyd@tux.org> for TrueColor displays
+ * 30-Jan-96: Wrote all that I wanted to.
+ *
+ * Sort of starfield with a 3D engine.  For a real starfield, I only scale
+ * the sort of sphere you see to the whole sky and clip the stars to the
+ * camera screen.
+ *
+ * Use: batchcount is the number of stars.
+ *      cycles is the maximum size for a star
+ *
+ * DONE: Build up a XArc list and Draw everything once with XFillArcs
+ *       That idea came from looking at swarm code.
+ * DONE: Add an old arcs list for erasing.
+ * DONE: Make center of starfield SinVariable.
+ * DONE: Add some random in the sinvary() function.
+ * DONE: check time for erasing the stars with the two methods and use the
+ *       better one. Note that sometimes the time difference between
+ *       beginning of erasing and its end is negative! I check this, and
+ *       do not use this result when it occurs. If all values are negative,
+ *       the erasing will continue being done in the currently tested mode.
+ * DONE: Allow stars size customization.
+ * DONE: Make sizey be no less than half sizex or no bigger than twice sizex.
+ *
+ * IDEA: A simple check can be performed to know which stars are "behind"
+ *       and which are "in front". So is possible to very simply change
+ *       the drawing mode for these two sorts of stars. BUT: this would lead
+ *       to a rewrite of the XArc list code because drawing should be done
+ *       in two steps: "behind" stars then "in front" stars. Also, what could
+ *       be the difference between the rendering of these two types of stars?
+ * IDEA: Calculate the distance of each star to the "viewer" and render the
+ *       star accordingly to this distance. Same remarks as for previous
+ *       ideas can be pointed out. This would even lead to reget the old stars
+ *       drawing code, that has been replaced by the XFillArcs. On another
+ *       hand, this would allow particular stars (own color, shape...), as
+ *       far as they would be individually drawn. One should be careful to
+ *       draw them according to their distance, that is not drawing a far
+ *       star after a close one.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Bouboule"
+#define HACK_INIT init_bouboule
+#define HACK_DRAW draw_bouboule
+#define bouboule_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 100 \n" \
+ "*size: 15 \n" \
+ "*ncolors: 64 \n" \
+ "*use3d: False \n" \
+ "*delta3d: 1.5 \n" \
+ "*right3d: red \n" \
+ "*left3d: blue \n" \
+ "*both3d: magenta \n" \
+ "*none3d: black \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_bouboule
+
+ModeSpecOpt bouboule_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   bouboule_description =
+{"bouboule", "init_bouboule", "draw_bouboule", "release_bouboule",
+ "refresh_bouboule", "init_bouboule", NULL, &bouboule_opts,
+ 10000, 100, 1, 15, 64, 1.0, "",
+ "Shows Mimi's bouboule of moving stars", 0, NULL};
+
+#endif
+
+#define USEOLDXARCS  1         /* If 1, we use old xarcs list for erasing.
+                                  * else we just roughly erase the window.
+                                  * This mainly depends on the number of stars,
+                                  * because when they are many, it is faster to
+                                  * erase the whole window than to erase each star
+                                */
+
+#if HAVE_GETTIMEOFDAY
+#define ADAPT_ERASE  1         /* If 1, then we try ADAPT_CHECKS black XFillArcs,
+                                  * and after, ADAPT_CHECKS XFillRectangle.
+                                  * We check which method seems better, knowing that
+                                  * XFillArcs is generally visually better. So we
+                                  * consider that XFillArcs is still better if its time
+                                  * is about XFillRectangle * ADAPT_ARC_PREFERED
+                                  * We need gettimeofday
+                                  * for this... Does it exist on other systems ? Do we
+                                  * have to use another function for others ?
+                                  * This value overrides USEOLDXARCS.
+                                */
+
+#ifdef USE_XVMSUTILS
+#if 0
+#include "../xvmsutils/unix_time.h"
+#else
+#include <X11/unix_time.h>
+#endif
+#endif
+#if HAVE_SYS_TIME_H
+#include <sys/time.h>
+#else
+#if HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
+#endif
+#define ADAPT_CHECKS 50
+#define ADAPT_ARC_PREFERED 150 /* Maybe the value that is the most important
+                                  * for adapting to a system */
+#endif
+
+#define dtor(x)    (((x) * M_PI) / 180.0)      /* Degrees to radians */
+
+#define MINSTARS      1
+#define MINSIZE       1
+#define COLOR_CHANGES 50       /* How often we change colors (1 = always)
+                                  * This value should be tuned accordingly to
+                                  * the number of stars */
+#define MAX_SIZEX_SIZEY 2.     /* This controls whether the sphere can be very
+                                  * very large and have a small height (or the
+                                  * opposite) or no. */
+
+#define THETACANRAND  80       /* percentage of changes for the speed of
+                                  * change of the 3 theta values */
+#define SIZECANRAND   80       /* percentage of changes for the speed of
+                                  * change of the sizex and sizey values */
+#define POSCANRAND    80       /* percentage of changes for the speed of
+                                  * change of the x and y values */
+/*-
+ * Note that these XXXCANRAND values can be 0, that is no rand acceleration
+ * variation.
+ */
+
+#define VARRANDALPHA (NRAND((int) (M_PI * 1000.0))/1000.0)
+#define VARRANDSTEP  (M_PI/(NRAND(100)+100.0))
+#define VARRANDMIN   (-70.0)
+#define VARRANDMAX   70.0
+
+#define MINZVAL   100          /* stars can come this close */
+#define SCREENZ  2000          /* this is where the screen is */
+#define MAXZVAL 10000          /* stars can go this far away */
+
+#define GETZDIFF(z) ((MI_DELTA3D(mi))*20.0*(1.0-(SCREENZ)/(z+1000)))
+#define MAXDIFF  MAX(-GETZDIFF(MINZVAL),GETZDIFF(MAXZVAL))
+
+/*-
+ * These values are the variation parameters of the acceleration variation
+ * of the SinVariables that are randomized.
+ */
+
+/******************************/
+typedef struct SinVariableStruct
+/******************************/
+{
+       double      alpha;      /* 
+                                * Alpha is the current state of the sinvariable
+                                * alpha should be initialized to a value between
+                                * 0.0 and 2 * M_PI
+                                */
+       double      step;       /*
+                                * Speed of evolution of alpha. It should be a reasonable
+                                * fraction of 2 * M_PI. This value directly influence
+                                * the variable speed of variation.
+                                */
+       double      minimum;    /* Minimum value for the variable */
+       double      maximum;    /* Maximum value for the variable */
+       double      value;      /* Current value */
+       int         mayrand;    /* Flag for knowing whether some randomization can be
+                                * applied to the variable */
+       struct SinVariableStruct *varrand;      /* Evolving Variable: the variation of
+                                                  * alpha */
+} SinVariable;
+
+/***********************/
+typedef struct StarStruct
+/***********************/
+{
+       double      x, y, z;    /* Position of the star */
+       short       size;       /* Try to guess */
+} Star;
+
+/****************************/
+typedef struct StarFieldStruct
+/****************************/
+{
+       short       width, height;      /* width and height of the starfield window */
+       short       max_star_size;      /* Maximum radius for stars. stars radius will
+                                        * vary from 1 to MAX_STAR_SIZE */
+       SinVariable x;          /* Evolving variables:               */
+       SinVariable y;          /* Center of the field on the screen */
+       SinVariable z;
+       SinVariable sizex;      /* Evolving variable: half width  of the field */
+       SinVariable sizey;      /* Evolving variable: half height of the field */
+       SinVariable thetax;     /* Evolving Variables:              */
+       SinVariable thetay;     /* rotation angles of the starfield */
+       SinVariable thetaz;     /* around x, y and z local axis     */
+       Star       *star;       /* List of stars */
+       XArc       *xarc;       /* Current List of arcs */
+       XArc       *xarcleft;   /* additional list for the left arcs */
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+       XArc       *oldxarc;    /* Old list of arcs */
+       XArc       *oldxarcleft;
+#endif
+       unsigned long color;    /* Current color of the starfield */
+       int         colorp;     /* Pointer to color of the starfield */
+       int         NbStars;    /* Number of stars */
+       short       colorchange;        /* Counter for the color change */
+#if (ADAPT_ERASE == 1)
+       short       hasbeenchecked;
+       long        rect_time;
+       long        xarc_time;
+#endif
+} StarField;
+
+static StarField *starfield = NULL;
+
+/*********/
+static void
+sinvary(SinVariable * v)
+/*********/
+
+{
+       v->value = v->minimum +
+               (v->maximum - v->minimum) * (sin(v->alpha) + 1.0) / 2.0;
+
+       if (v->mayrand == 0)
+               v->alpha += v->step;
+       else {
+               int         vaval = NRAND(100);
+
+               if (vaval <= v->mayrand)
+                       sinvary(v->varrand);
+               v->alpha += (100.0 + (v->varrand->value)) * v->step / 100.0;
+       }
+
+       if (v->alpha > 2 * M_PI)
+               v->alpha -= 2 * M_PI;
+}
+
+/*************************************************/
+static void
+sininit(SinVariable * v,
+       double alpha, double step, double minimum, double maximum,
+       short int mayrand)
+{
+       v->alpha = alpha;
+       v->step = step;
+       v->minimum = minimum;
+       v->maximum = maximum;
+       v->mayrand = mayrand;
+       if (mayrand != 0) {
+               if (v->varrand == NULL)
+                       v->varrand = (SinVariable *) calloc(1, sizeof (SinVariable));
+               sininit(v->varrand,
+                       VARRANDALPHA,
+                       VARRANDSTEP,
+                       VARRANDMIN,
+                       VARRANDMAX,
+                       0);
+               sinvary(v->varrand);
+       }
+       /* We calculate the values at least once for initialization */
+       sinvary(v);
+}
+
+static void
+sinfree(SinVariable * point)
+{
+       SinVariable *temp, *next;
+
+       next = point->varrand;
+       while (next) {
+               temp = next;
+               next = temp->varrand;
+               (void) free((void *) temp);
+       }
+}
+
+/***************/
+void
+init_bouboule(ModeInfo * mi)
+/***************/
+
+/*-
+ *  The stars init part was first inspirated from the net3d game starfield
+ * code.  But net3d starfield is not really 3d starfield, and I needed real 3d,
+ * so only remains the net3d starfield initialization main idea, that is
+ * the stars distribution on a sphere (theta and omega computing)
+ */
+{
+       StarField  *sp;
+       int         size = MI_SIZE(mi);
+       int         i;
+       double      theta, omega;
+
+       if (starfield == NULL) {
+               if ((starfield = (StarField *) calloc(MI_NUM_SCREENS(mi),
+                                               sizeof (StarField))) == NULL)
+                       return;
+       }
+       sp = &starfield[MI_SCREEN(mi)];
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+
+       /* use the right `black' pixel values: */
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+
+       if (size < -MINSIZE)
+               sp->max_star_size = NRAND(-size - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE)
+               sp->max_star_size = MINSIZE;
+       else
+               sp->max_star_size = size;
+
+       sp->NbStars = MI_COUNT(mi);
+       if (sp->NbStars < -MINSTARS) {
+               if (sp->star) {
+                       (void) free((void *) sp->star);
+                       sp->star = NULL;
+               }
+               if (sp->xarc) {
+                       (void) free((void *) sp->xarc);
+                       sp->xarc = NULL;
+               }
+               if (sp->xarcleft) {
+                       (void) free((void *) sp->xarcleft);
+                       sp->xarcleft = NULL;
+               }
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+               if (sp->oldxarc) {
+                       (void) free((void *) sp->oldxarc);
+                       sp->oldxarc = NULL;
+               }
+               if (sp->oldxarcleft) {
+                       (void) free((void *) sp->oldxarcleft);
+                       sp->oldxarcleft = NULL;
+               }
+#endif
+               sp->NbStars = NRAND(-sp->NbStars - MINSTARS + 1) + MINSTARS;
+       } else if (sp->NbStars < MINSTARS)
+               sp->NbStars = MINSTARS;
+
+       /* We get memory for lists of objects */
+       if (sp->star == NULL)
+               sp->star = (Star *) malloc(sp->NbStars * sizeof (Star));
+       if (sp->xarc == NULL)
+               sp->xarc = (XArc *) malloc(sp->NbStars * sizeof (XArc));
+       if (MI_IS_USE3D(mi) && sp->xarcleft == NULL)
+               sp->xarcleft = (XArc *) malloc(sp->NbStars * sizeof (XArc));
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+       if (sp->oldxarc == NULL)
+               sp->oldxarc = (XArc *) malloc(sp->NbStars * sizeof (XArc));
+       if (MI_IS_USE3D(mi) && sp->oldxarcleft == NULL)
+               sp->oldxarcleft = (XArc *) malloc(sp->NbStars * sizeof (XArc));
+#endif
+
+       {
+               /* We initialize evolving variables */
+               sininit(&sp->x,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(100) + 100.0),
+                       ((double) sp->width) / 4.0,
+                       3.0 * ((double) sp->width) / 4.0,
+                       POSCANRAND);
+               sininit(&sp->y,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(100) + 100.0),
+                       ((double) sp->height) / 4.0,
+                       3.0 * ((double) sp->height) / 4.0,
+                       POSCANRAND);
+
+               /* for z, we have to ensure that the bouboule does not get behind */
+               /* the eyes of the viewer.  His/Her eyes are at 0.  Because the */
+               /* bouboule uses the x-radius for the z-radius, too, we have to */
+               /* use the x-values. */
+               sininit(&sp->z,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(100) + 100.0),
+                       ((double) sp->width / 2.0 + MINZVAL),
+                       ((double) sp->width / 2.0 + MAXZVAL),
+                       POSCANRAND);
+
+
+               sininit(&sp->sizex,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(100) + 100.0),
+                       MIN(((double) sp->width) - sp->x.value,
+                           sp->x.value) / 5.0,
+                       MIN(((double) sp->width) - sp->x.value,
+                           sp->x.value),
+                       SIZECANRAND);
+
+               sininit(&sp->sizey,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(100) + 100.0),
+                       MAX(sp->sizex.value / MAX_SIZEX_SIZEY,
+                           sp->sizey.maximum / 5.0),
+                       MIN(sp->sizex.value * MAX_SIZEX_SIZEY,
+                           MIN(((double) sp->height) -
+                               sp->y.value,
+                               sp->y.value)),
+                       SIZECANRAND);
+
+               sininit(&sp->thetax,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(200) + 200.0),
+                       -M_PI, M_PI,
+                       THETACANRAND);
+               sininit(&sp->thetay,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(200) + 200.0),
+                       -M_PI, M_PI,
+                       THETACANRAND);
+               sininit(&sp->thetaz,
+                       NRAND(3142) / 1000.0, M_PI / (NRAND(400) + 400.0),
+                       -M_PI, M_PI,
+                       THETACANRAND);
+       }
+       for (i = 0; i < sp->NbStars; i++) {
+               Star       *star;
+               XArc       *arc = NULL, *arcleft = NULL;
+
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+               XArc       *oarc = NULL, *oarcleft = NULL;
+
+#endif
+
+               star = &(sp->star[i]);
+               arc = &(sp->xarc[i]);
+               if (MI_IS_USE3D(mi))
+                       arcleft = &(sp->xarcleft[i]);
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+               oarc = &(sp->oldxarc[i]);
+               if (MI_IS_USE3D(mi))
+                       oarcleft = &(sp->oldxarcleft[i]);
+#endif
+               /* Elevation and bearing of the star */
+               theta = dtor((NRAND(1800)) / 10.0 - 90.0);
+               omega = dtor((NRAND(3600)) / 10.0 - 180.0);
+
+               /* Stars coordinates in a 3D space */
+               star->x = cos(theta) * sin(omega);
+               star->y = sin(omega) * sin(theta);
+               star->z = cos(omega);
+
+               /* We set the stars size */
+               star->size = NRAND(2 * sp->max_star_size);
+               if (star->size < sp->max_star_size)
+                       star->size = 0;
+               else
+                       star->size -= sp->max_star_size;
+
+               /* We set default values for the XArc lists elements, but offscreen */
+               arc->x = MI_WIDTH(mi);
+               arc->y = MI_HEIGHT(mi);
+               if (MI_IS_USE3D(mi)) {
+                       arcleft->x = MI_WIDTH(mi);
+                       arcleft->y = MI_HEIGHT(mi);
+               }
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+               oarc->x = MI_WIDTH(mi);
+               oarc->y = MI_HEIGHT(mi);
+               if (MI_IS_USE3D(mi)) {
+                       oarcleft->x = MI_WIDTH(mi);
+                       oarcleft->y = MI_HEIGHT(mi);
+               }
+#endif
+               arc->width = 2 + star->size;
+               arc->height = 2 + star->size;
+               if (MI_IS_USE3D(mi)) {
+                       arcleft->width = 2 + star->size;
+                       arcleft->height = 2 + star->size;
+               }
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+               oarc->width = 2 + star->size;
+               oarc->height = 2 + star->size;
+               if (MI_IS_USE3D(mi)) {
+                       oarcleft->width = 2 + star->size;
+                       oarcleft->height = 2 + star->size;
+               }
+#endif
+
+               arc->angle1 = 0;
+               arc->angle2 = 360 * 64;
+               if (MI_IS_USE3D(mi)) {
+                       arcleft->angle1 = 0;
+                       arcleft->angle2 = 360 * 64;
+               }
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+               oarc->angle1 = 0;
+               oarc->angle2 = 360 * 64;        /* ie. we draw whole disks:
+                                                * from 0 to 360 degrees */
+               if (MI_IS_USE3D(mi)) {
+                       oarcleft->angle1 = 0;
+                       oarcleft->angle2 = 360 * 64;
+               }
+#endif
+       }
+
+       if (MI_NPIXELS(mi) > 2)
+               sp->colorp = NRAND(MI_NPIXELS(mi));
+       /* We set up the starfield color */
+       if (!MI_IS_USE3D(mi) && MI_NPIXELS(mi) > 2)
+               sp->color = MI_PIXEL(mi, sp->colorp);
+       else
+               sp->color = MI_WHITE_PIXEL(mi);
+
+#if (ADAPT_ERASE == 1)
+       /* We initialize the adaptation code for screen erasing */
+       sp->hasbeenchecked = ADAPT_CHECKS * 2;
+       sp->rect_time = 0;
+       sp->xarc_time = 0;
+#endif
+}
+
+/****************/
+void
+draw_bouboule(ModeInfo * mi)
+/****************/
+
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       StarField  *sp = &starfield[MI_SCREEN(mi)];
+       int         i, diff = 0;
+       double      CX, CY, CZ, SX, SY, SZ;
+       Star       *star;
+       XArc       *arc = NULL, *arcleft = NULL;
+
+#if (ADAPT_ERASE == 1)
+       struct timeval tv1;
+       struct timeval tv2;
+
+#endif
+
+#if ((USEOLDXARCS == 0) || (ADAPT_ERASE == 1))
+       short       x_1, y_1, x_2, y_2;
+
+       /* bounding rectangle around the old starfield,
+        * for erasing with the smallest rectangle
+        * instead of filling the whole screen */
+       int         maxdiff = 0;        /* maximal distance between left and right */
+
+       /* star in 3d mode, otherwise 0 */
+#endif
+
+       MI_IS_DRAWN(mi) = True;
+
+#if ((USEOLDXARCS == 0) || (ADAPT_ERASE == 1))
+       if (MI_IS_USE3D(mi)) {
+               maxdiff = (int) MAXDIFF;
+       }
+       x_1 = (int) sp->x.value - (int) sp->sizex.value -
+               sp->max_star_size - maxdiff;
+       y_1 = (int) sp->y.value - (int) sp->sizey.value -
+               sp->max_star_size;
+       x_2 = 2 * ((int) sp->sizex.value + sp->max_star_size + maxdiff);
+       y_2 = 2 * ((int) sp->sizey.value + sp->max_star_size);
+#endif
+       /* We make variables vary. */
+       sinvary(&sp->thetax);
+       sinvary(&sp->thetay);
+       sinvary(&sp->thetaz);
+
+       sinvary(&sp->x);
+       sinvary(&sp->y);
+       if (MI_IS_USE3D(mi))
+               sinvary(&sp->z);
+
+       /* A little trick to prevent the bouboule from being
+        * bigger than the screen */
+       sp->sizex.maximum =
+               MIN(((double) sp->width) - sp->x.value,
+                   sp->x.value);
+       sp->sizex.minimum = sp->sizex.maximum / 3.0;
+
+       /* Another trick to make the ball not too flat */
+       sp->sizey.minimum =
+               MAX(sp->sizex.value / MAX_SIZEX_SIZEY,
+                   sp->sizey.maximum / 3.0);
+       sp->sizey.maximum =
+               MIN(sp->sizex.value * MAX_SIZEX_SIZEY,
+                   MIN(((double) sp->height) - sp->y.value,
+                       sp->y.value));
+
+       sinvary(&sp->sizex);
+       sinvary(&sp->sizey);
+
+       /*
+        * We calculate the rotation matrix values. We just make the
+        * rotation on the fly, without using a matrix.
+        * Star positions are recorded as unit vectors pointing in various
+        * directions. We just make them all rotate.
+        */
+       CX = cos(sp->thetax.value);
+       SX = sin(sp->thetax.value);
+       CY = cos(sp->thetay.value);
+       SY = sin(sp->thetay.value);
+       CZ = cos(sp->thetaz.value);
+       SZ = sin(sp->thetaz.value);
+
+       for (i = 0; i < sp->NbStars; i++) {
+               star = &(sp->star[i]);
+               arc = &(sp->xarc[i]);
+               if (MI_IS_USE3D(mi)) {
+                       arcleft = &(sp->xarcleft[i]);
+                       /* to help the eyes, the starfield is always as wide as */
+                       /* deep, so .sizex.value can be used. */
+                       diff = (int) GETZDIFF(sp->sizex.value *
+                                     ((SY * CX) * star->x + (SX) * star->y +
+                                      (CX * CY) * star->z) + sp->z.value);
+               }
+               arc->x = (short) ((sp->sizex.value *
+                                  ((CY * CZ - SX * SY * SZ) * star->x +
+                                   (-CX * SZ) * star->y +
+                                   (SY * CZ + SZ * SX * CY) * star->z) +
+                                  sp->x.value));
+               arc->y = (short) ((sp->sizey.value *
+                                  ((CY * SZ + SX * SY * CZ) * star->x +
+                                   (CX * CZ) * star->y +
+                                   (SY * SZ - SX * CY * CZ) * star->z) +
+                                  sp->y.value));
+
+               if (MI_IS_USE3D(mi)) {
+                       arcleft->x = (short) ((sp->sizex.value *
+                                       ((CY * CZ - SX * SY * SZ) * star->x +
+                                        (-CX * SZ) * star->y +
+                                        (SY * CZ + SZ * SX * CY) * star->z) +
+                                              sp->x.value));
+                       arcleft->y = (short) ((sp->sizey.value *
+                                       ((CY * SZ + SX * SY * CZ) * star->x +
+                                        (CX * CZ) * star->y +
+                                        (SY * SZ - SX * CY * CZ) * star->z) +
+                                              sp->y.value));
+                       arc->x += diff;
+                       arcleft->x -= diff;
+               }
+               if (star->size != 0) {
+                       arc->x -= star->size;
+                       arc->y -= star->size;
+                       if (MI_IS_USE3D(mi)) {
+                               arcleft->x -= star->size;
+                               arcleft->y -= star->size;
+                       }
+               }
+       }
+
+       /* First, we erase the previous starfield */
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi))
+               XSetForeground(display, gc, MI_NONE_COLOR(mi));
+       else
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+
+#if (ADAPT_ERASE == 1)
+       if (sp->hasbeenchecked == 0) {
+               /* We just calculate which method is the faster and eventually free
+                * the oldxarc list */
+               if (sp->xarc_time >
+                   ADAPT_ARC_PREFERED * sp->rect_time) {
+                       sp->hasbeenchecked = -2;        /* XFillRectangle mode */
+                       (void) free((void *) sp->oldxarc);
+                       sp->oldxarc = NULL;
+                       if (MI_IS_USE3D(mi)) {
+                               (void) free((void *) sp->oldxarcleft);
+                               sp->oldxarcleft = NULL;
+                       }
+               } else {
+                       sp->hasbeenchecked = -1;        /* XFillArcs mode */
+               }
+       }
+       if (sp->hasbeenchecked == -2) {
+               /* Erasing is done with XFillRectangle */
+               XFillRectangle(display, window, gc,
+                              x_1, y_1, x_2, y_2);
+       } else if (sp->hasbeenchecked == -1) {
+               /* Erasing is done with XFillArcs */
+               XFillArcs(display, window, gc,
+                         sp->oldxarc, sp->NbStars);
+               if (MI_IS_USE3D(mi))
+                       XFillArcs(display, window, gc,
+                                 sp->oldxarcleft, sp->NbStars);
+       } else {
+               long        usec;
+
+               if (sp->hasbeenchecked > ADAPT_CHECKS) {
+                       GETTIMEOFDAY(&tv1);
+                       XFillRectangle(display, window, gc,
+                                      x_1, y_1, x_2, y_2);
+                       GETTIMEOFDAY(&tv2);
+                       usec = (tv2.tv_sec - tv1.tv_sec) * 1000000;
+                       if (usec + tv2.tv_usec - tv1.tv_usec > 0) {
+                               sp->rect_time += usec + tv2.tv_usec - tv1.tv_usec;
+                               sp->hasbeenchecked--;
+                       }
+               } else {
+                       GETTIMEOFDAY(&tv1);
+                       XFillArcs(display, window, gc,
+                                 sp->oldxarc, sp->NbStars);
+                       if (MI_IS_USE3D(mi))
+                               XFillArcs(display, window, gc,
+                                         sp->oldxarcleft, sp->NbStars);
+                       GETTIMEOFDAY(&tv2);
+                       usec = (tv2.tv_sec - tv1.tv_sec) * 1000000;
+                       if (usec + tv2.tv_usec - tv1.tv_usec > 0) {
+                               sp->xarc_time += usec + tv2.tv_usec - tv1.tv_usec;
+                               sp->hasbeenchecked--;
+                       }
+               }
+       }
+#else
+#if (USEOLDXARCS == 1)
+       XFillArcs(display, window, gc,
+                 sp->oldxarc, sp->NbStars);
+       if (MI_IS_USE3D(mi))
+               XFillArcs(display, window, gc,
+                         sp->oldxarcleft, sp->NbStars);
+#else
+       XFillRectangle(display, window, gc,
+                      x_1, y_1, x_2, y_2);
+#endif
+#endif
+
+       /* Then we draw the new one */
+       if (MI_IS_USE3D(mi)) {
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXor);
+               XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+               XFillArcs(display, window, gc, sp->xarc, sp->NbStars);
+               XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               XFillArcs(display, window, gc, sp->xarcleft, sp->NbStars);
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXcopy);
+       } else {
+               XSetForeground(display, gc, sp->color);
+               XFillArcs(display, window, gc, sp->xarc, sp->NbStars);
+       }
+
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+#if (ADAPT_ERASE == 1)
+       if (sp->hasbeenchecked >= -1) {
+               arc = sp->xarc;
+               sp->xarc = sp->oldxarc;
+               sp->oldxarc = arc;
+               if (MI_IS_USE3D(mi)) {
+                       arcleft = sp->xarcleft;
+                       sp->xarcleft = sp->oldxarcleft;
+                       sp->oldxarcleft = arcleft;
+               }
+       }
+#else
+       arc = sp->xarc;
+       sp->xarc = sp->oldxarc;
+       sp->oldxarc = arc;
+       if (MI_IS_USE3D(mi)) {
+               arcleft = sp->xarcleft;
+               sp->xarcleft = sp->oldxarcleft;
+               sp->oldxarcleft = arcleft;
+       }
+#endif
+#endif
+
+       /* We set up the color for the next drawing */
+       if (!MI_IS_USE3D(mi) && MI_NPIXELS(mi) > 2 &&
+           (++sp->colorchange >= COLOR_CHANGES)) {
+               sp->colorchange = 0;
+               if (++sp->colorp >= MI_NPIXELS(mi))
+                       sp->colorp = 0;
+               sp->color = MI_PIXEL(mi, sp->colorp);
+       }
+}
+
+void
+release_bouboule(ModeInfo * mi)
+{
+       if (starfield != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       StarField  *sp = &starfield[screen];
+
+                       if (sp->star)
+                               (void) free((void *) sp->star);
+                       if (sp->xarc)
+                               (void) free((void *) sp->xarc);
+                       if (sp->xarcleft)
+                               (void) free((void *) sp->xarcleft);
+#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1))
+                       if (sp->oldxarc)
+                               (void) free((void *) sp->oldxarc);
+                       if (sp->oldxarcleft)
+                               (void) free((void *) sp->oldxarcleft);
+#endif
+                       sinfree(&(sp->x));
+                       sinfree(&(sp->y));
+                       sinfree(&(sp->z));
+                       sinfree(&(sp->sizex));
+                       sinfree(&(sp->sizey));
+                       sinfree(&(sp->thetax));
+                       sinfree(&(sp->thetay));
+                       sinfree(&(sp->thetaz));
+               }
+               (void) free((void *) starfield);
+               starfield = NULL;
+       }
+}
+
+void
+refresh_bouboule(ModeInfo * mi)
+{
+       /* use the right `black' pixel values: */
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+
+}
+
+#endif /* MODE_bouboule */
diff --git a/xlockmore-4.14/modes/bounce.c b/xlockmore-4.14/modes/bounce.c
new file mode 100644 (file)
index 0000000..75a6b32
--- /dev/null
@@ -0,0 +1,598 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* bounce --- bouncing footballs */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)bounce.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1988 by Sun Microsystems
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 01-Apr-97: Curtis Larsen <larsen@rtp3.med.utah.edu>
+ * The modification is only for the inroot mode.  It causes the balls to see
+ * children of the root window and bounce off of the sides of them.  New
+ * windows are only recognized after every init_bounce, because fvwm did not
+ * like xlock setting SubstructureNotifyMask on root.  I did not fix the
+ * initial placement of balls yet, so they can start out underneath windows.
+ * 18-Sep-95: tinkered with it to look like bat.c .
+ * 15-Jul-94: cleaned up in time for the final match.
+ * 4-Apr-94: spinning multiple ball version
+ *             (I got a lot of help from with the physics of ball to ball
+ *             collision looking at the source of xpool from Ismail ARIT
+ *             <iarit@tara.mines.colorado.edu>
+ * 22-Mar-94: got rid of flashing problem by only erasing parts of the image
+ *             that will not be in the next image.
+ * 2-Sep-93: xlock version David Bagley <bagleyd@tux.org>
+ * 1986: Sun Microsystems
+ */
+
+/*-
+ * original copyright
+ * **************************************************************************
+ * Copyright 1988 by Sun Microsystems, Inc. Mountain View, CA.
+ *
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the names of Sun or MIT not be used in advertising
+ * or publicity pertaining to distribution of the software without specific
+ * prior written permission. Sun and M.I.T. make no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
+ * without any express or implied warranty.
+ *
+ * SUN DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ * IN NO EVENT SHALL SUN BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
+ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
+ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
+ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+ * SOFTWARE.
+ * ***************************************************************************
+ */
+
+/*-
+ * Open for improvement:
+ *  include different balls (size and mass)
+ *    how about be real crazy and put in an American/Australian football?
+ *  should only have 1 bitmap for ball, the others should be generated
+ *    as 90 degree rotations.
+ *  multiscreen interaction
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Bounce"
+#define HACK_INIT init_bounce
+#define HACK_DRAW draw_bounce
+#define bounce_opts xlockmore_opts
+#define DEFAULTS "*delay: 5000 \n" \
+ "*count: -10 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_bounce
+
+ModeSpecOpt bounce_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   bounce_description =
+{"bounce", "init_bounce", "draw_bounce", "release_bounce",
+ "refresh_bounce", "init_bounce", NULL, &bounce_opts,
+ 5000, -10, 1, 0, 64, 1.0, "",
+ "Shows bouncing footballs", 0, NULL};
+
+#endif
+
+#include "bitmaps/bounce-0.xbm"
+#include "bitmaps/bounce-1.xbm"
+#include "bitmaps/bounce-2.xbm"
+#include "bitmaps/bounce-3.xbm"
+#include "bitmaps/bounce-mask.xbm"
+#define BALLBITS(n,w,h)\
+  bp->pixmaps[bp->init_orients++]=\
+               XCreateBitmapFromData(display,window,(char *)n,w,h)
+
+#define MAX_STRENGTH 24
+#define FRICTION 24
+#define PENETRATION 0.3
+#define SLIPAGE 4
+#define TIME 32
+#define MINBALLS 1
+#define MINSIZE 1
+#define MINGRIDSIZE 6
+
+#define ORIENTS 4
+#define ORIENTCYCLE 16
+#define CCW 1
+#define CW (ORIENTS-1)
+#define DIR(x) (((x)>=0)?CCW:CW)
+#define SIGN(x)        (((x)>=0)?1:-1)
+
+typedef struct {
+       int         x, y;
+       int         width, height;
+} ballwindow;
+
+typedef struct {
+       int         x, y, xlast, ylast, orientlast;
+       int         spincount, spindelay, spindir, orient;
+       int         vx, vy, vang;
+       unsigned long color;
+} ballstruct;
+
+typedef struct {
+       int         width, height;
+       int         nballs;
+       int         xs, ys, avgsize;
+       int         restartnum;
+       int         pixelmode;
+       ballstruct *balls;
+       GC          stippledGC;
+       Pixmap      pixmaps[ORIENTS + 1];
+       int         init_orients;
+       int         nwindow;
+       ballwindow *windows;
+} bouncestruct;
+
+static bouncestruct *bounces = NULL;
+
+static void
+checkCollision(bouncestruct * bp, int aball)
+{
+       int         i, amount, spin, d, size;
+       double      x, y;
+
+       for (i = 0; i < bp->nballs; i++) {
+               if (i != aball) {
+                       x = (double) (bp->balls[i].x - bp->balls[aball].x);
+                       y = (double) (bp->balls[i].y - bp->balls[aball].y);
+                       d = (int) sqrt(x * x + y * y);
+                       size = bp->avgsize;
+                       if (d > 0 && d < size) {
+                               amount = size - d;
+                               if (amount > PENETRATION * size)
+                                       amount = (int) (PENETRATION * size);
+                               bp->balls[i].vx += (int) ((double) amount * x / d);
+                               bp->balls[i].vy += (int) ((double) amount * y / d);
+                               bp->balls[i].vx -= bp->balls[i].vx / FRICTION;
+                               bp->balls[i].vy -= bp->balls[i].vy / FRICTION;
+                               bp->balls[aball].vx -= (int) ((double) amount * x / d);
+                               bp->balls[aball].vy -= (int) ((double) amount * y / d);
+                               bp->balls[aball].vx -= bp->balls[aball].vx / FRICTION;
+                               bp->balls[aball].vy -= bp->balls[aball].vy / FRICTION;
+                               spin = (bp->balls[i].vang - bp->balls[aball].vang) /
+                                       (2 * size * SLIPAGE);
+                               bp->balls[i].vang -= spin;
+                               bp->balls[aball].vang += spin;
+                               bp->balls[i].spindir = DIR(bp->balls[i].vang);
+                               bp->balls[aball].spindir = DIR(bp->balls[aball].vang);
+                               if (!bp->balls[i].vang) {
+                                       bp->balls[i].spindelay = 1;
+                                       bp->balls[i].spindir = 0;
+                               } else
+                                       bp->balls[i].spindelay = (int) ((double) M_PI *
+                                                                       bp->avgsize / (ABS(bp->balls[i].vang))) + 1;
+                               if (!bp->balls[aball].vang) {
+                                       bp->balls[aball].spindelay = 1;
+                                       bp->balls[aball].spindir = 0;
+                               } else
+                                       bp->balls[aball].spindelay = (int) ((double) M_PI *
+                                                                           bp->avgsize / (ABS(bp->balls[aball].vang))) + 1;
+                               return;
+                       }
+               }
+       }
+}
+
+static void
+drawball(ModeInfo * mi, ballstruct * ball)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+
+       if (bp->pixelmode) {
+               if (ball->xlast != -1) {
+                       XSetForeground(display, MI_GC(mi), MI_BLACK_PIXEL(mi));
+                       XFillRectangle(display, window, MI_GC(mi),
+                                  ball->xlast, ball->ylast, bp->xs, bp->ys);
+               }
+               XSetForeground(display, MI_GC(mi), ball->color);
+               XFillRectangle(display, window, MI_GC(mi),
+                              ball->x, ball->y, bp->xs, bp->ys);
+       } else {
+               if (ball->xlast != -1) {
+                       XSetForeground(display, bp->stippledGC, MI_BLACK_PIXEL(mi));
+                       XSetStipple(display, bp->stippledGC, bp->pixmaps[ORIENTS]);
+                       XSetFillStyle(display, bp->stippledGC, FillStippled);
+                       XSetTSOrigin(display, bp->stippledGC, ball->xlast, ball->ylast);
+#ifdef FLASH
+                       XFillRectangle(display, window, bp->stippledGC,
+                                  ball->xlast, ball->ylast, bp->xs, bp->ys);
+#else
+                       ERASE_IMAGE(display, window, bp->stippledGC, ball->x, ball->y,
+                                   ball->xlast, ball->ylast, bp->xs, bp->ys);
+#endif
+               }
+               XSetTSOrigin(display, bp->stippledGC, ball->x, ball->y);
+               XSetForeground(display, bp->stippledGC, ball->color);
+               XSetStipple(display, bp->stippledGC, bp->pixmaps[ball->orient]);
+#ifdef FLASH
+               XSetFillStyle(display, bp->stippledGC, FillStippled);
+#else
+               XSetFillStyle(display, bp->stippledGC, FillOpaqueStippled);
+#endif
+               XFillRectangle(display, window, bp->stippledGC,
+                              ball->x, ball->y, bp->xs, bp->ys);
+               XFlush(display);
+       }
+}
+
+static void
+spinball(ballstruct * ball, int dir, int *vel, int avgsize)
+{
+       *vel -= (int) ((*vel + SIGN(*vel * dir) *
+               ball->spindelay * ORIENTCYCLE / (M_PI * avgsize)) / SLIPAGE);
+       if (*vel) {
+               ball->spindir = DIR(*vel * dir);
+               ball->vang = *vel * ORIENTCYCLE;
+               ball->spindelay = (int) ((double) M_PI * avgsize / (ABS(ball->vang))) + 1;
+       } else
+               ball->spindir = 0;
+}
+
+#define BETWEEN(x, xmin, xmax) (((x) >= (xmin)) && ((x) <= (xmax)))
+static void
+hit_left_wall(ModeInfo * mi, ballstruct * ball,
+             int ytop, int height, int x, int side)
+{
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+
+       if ((ball->x <= x) && ((ball->xlast >= x) || side) &&
+           BETWEEN(ball->y, ytop - bp->ys, ytop + height)) {
+               /* Bounce off the wall to the left of the ball */
+
+               ball->x = 2 * x - ball->x;
+               ball->vx = (ball->vx - (ball->vx * FRICTION)) / FRICTION;
+               spinball(ball, -1, &ball->vy, bp->avgsize);
+       }
+}
+
+static void
+hit_right_wall(ModeInfo * mi, ballstruct * ball,
+              int ytop, int height, int x, int side)
+{
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+
+       x -= bp->xs;            /* account for ball width */
+
+       if ((ball->x >= x) && ((ball->xlast <= x) || side) &&
+           BETWEEN(ball->y, ytop - bp->ys, ytop + height)) {
+               /* Bounce off the wall to the right of the ball */
+
+               ball->x = 2 * x - ball->x;
+               ball->vx = (ball->vx - (ball->vx * FRICTION)) / FRICTION;
+               spinball(ball, 1, &ball->vy, bp->avgsize);
+       }
+}
+
+static void
+hit_top_wall(bouncestruct * bp, ballstruct * ball, int xleft, int width, int y, int side)
+{
+       if ((ball->y <= y) && ((ball->ylast >= y) || side) &&
+           BETWEEN(ball->x, xleft - bp->xs, xleft + width)) {  /* Bounce off the wall to the top of the ball */
+               ball->y = 2 * y - ball->y;
+               /* HACK to make it look better for iconified mode */
+               if (y == 0) {
+                       ball->vy = 0;
+               } else {
+                       ball->vy = (ball->vy - (FRICTION * ball->vy)) / FRICTION;
+               }
+               spinball(ball, 1, &ball->vx, bp->avgsize);
+       }
+}
+
+
+static void
+hit_bottom_wall(bouncestruct * bp, ballstruct * ball, int xleft, int width, int y, int side)
+{
+       y -= bp->ys;            /* account for ball height */
+
+       if ((ball->y >= y) && ((ball->ylast <= y) || side) &&
+           BETWEEN(ball->x, xleft - bp->xs, xleft + width)) {  /* Bounce off the wall to the bottom of the ball */
+               ball->y = y;
+               ball->vy = (ball->vy - (FRICTION * ball->vy)) / FRICTION;
+               spinball(ball, -1, &ball->vx, bp->avgsize);
+       }
+}
+
+static void
+moveball(ModeInfo * mi, ballstruct * ball)
+{
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+       int         i;
+       ballwindow *win;
+
+       ball->xlast = ball->x;
+       ball->ylast = ball->y;
+       ball->orientlast = ball->orient;
+       ball->x += ball->vx;
+
+       for (i = 0; i < bp->nwindow; i++) {
+               win = &bp->windows[i];
+
+               hit_left_wall(mi, ball, win->y, win->height, win->x + win->width, 0);
+               hit_right_wall(mi, ball, win->y, win->height, win->x, 0);
+       }
+       hit_right_wall(mi, ball, 0, bp->height, bp->width, 1);
+       hit_left_wall(mi, ball, 0, bp->height, 0, 1);
+
+       ball->vy++;
+       ball->y += ball->vy;
+
+       for (i = 0; i < bp->nwindow; i++) {
+               win = &bp->windows[i];
+
+               hit_top_wall(bp, ball, win->x, win->width, win->y + win->height, 0);
+               hit_bottom_wall(bp, ball, win->x, win->width, win->y, 0);
+       }
+       hit_top_wall(bp, ball, 0, bp->width, 0, 1);
+       hit_bottom_wall(bp, ball, 0, bp->width, bp->height, 1);
+
+       if (ball->spindir) {
+               ball->spincount--;
+               if (!ball->spincount) {
+                       ball->orient = (ball->spindir + ball->orient) % ORIENTS;
+                       ball->spincount = ball->spindelay;
+               }
+       }
+}
+
+static int
+collide(bouncestruct * bp, int aball)
+{
+       int         i, d, x, y;
+
+       for (i = 0; i < aball; i++) {
+               x = (bp->balls[i].x - bp->balls[aball].x);
+               y = (bp->balls[i].y - bp->balls[aball].y);
+               d = (int) sqrt((double) (x * x + y * y));
+               if (d < bp->avgsize)
+                       return i;
+       }
+       return i;
+}
+
+static void
+bounce_windows(ModeInfo * mi, bouncestruct * bs)
+{
+       Window      root, parent, *children;
+       unsigned int nchildren;
+       int         i;
+       int         n;
+
+       if (!MI_IS_INROOT(mi)) {
+               bs->nwindow = 0;
+               return;
+       }
+       if (XQueryTree(MI_DISPLAY(mi), MI_WINDOW(mi),
+                      &root, &parent, &children, &nchildren) == 0) {   /* failure */
+               bs->nwindow = 0;
+               return;
+       }
+       bs->nwindow = nchildren;
+       if (bs->windows != NULL) {
+               (void) free((void *) bs->windows);
+       }
+       bs->windows = (ballwindow *) malloc(bs->nwindow * sizeof (ballwindow));
+       for (n = 0, i = 0; i < bs->nwindow; i++) {
+               XWindowAttributes att;
+
+/*-
+   May give
+   X Error of failed request: BadWindow (invalid Window parameter)
+   Major opcode of failed request:  3 (X_GetWindowAttributes)
+ */
+               if (XGetWindowAttributes(MI_DISPLAY(mi), children[i], &att) == 0) {     /* failure */
+                       bs->nwindow = 0;
+                       return;
+               }
+               if ((att.x < 0) || (att.x > bs->width) ||
+                   (att.y < 0) || (att.y > bs->height) ||
+#if defined(__cplusplus) || defined(c_plusplus)
+                   (att.c_class != InputOutput) ||
+#else
+                   (att.class != InputOutput) ||
+#endif
+                   (att.map_state != IsViewable)) {
+                       continue;
+               }
+               bs->windows[n].x = att.x;
+               bs->windows[n].y = att.y;
+               bs->windows[n].width = att.width;
+               bs->windows[n].height = att.height;
+               n++;
+       }
+       bs->nwindow = n;
+       XFree((caddr_t) children);
+       return;
+}
+
+void
+init_bounce(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         size = MI_SIZE(mi);
+       bouncestruct *bp;
+       XGCValues   gcv;
+       int         i, tryagain = 0;
+
+       if (bounces == NULL) {
+               if ((bounces = (bouncestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (bouncestruct))) == NULL)
+                       return;
+       }
+       bp = &bounces[MI_SCREEN(mi)];
+
+       if (!bp->stippledGC) {
+               gcv.foreground = MI_BLACK_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               if ((bp->stippledGC = XCreateGC(display, window,
+                                GCForeground | GCBackground, &gcv)) == None)
+                       return;
+       }
+       if (!bp->init_orients) {
+               BALLBITS(bounce0_bits, bounce0_width, bounce0_height);
+               BALLBITS(bounce1_bits, bounce1_width, bounce1_height);
+               BALLBITS(bounce2_bits, bounce2_width, bounce2_height);
+               BALLBITS(bounce3_bits, bounce3_width, bounce3_height);
+               BALLBITS(bouncemask_bits, bouncemask_width, bouncemask_height);
+       }
+       bp->width = MI_WIDTH(mi);
+       bp->height = MI_HEIGHT(mi);
+       if (bp->width < 2)
+               bp->width = 2;
+       if (bp->height < 2)
+               bp->height = 2;
+       bp->restartnum = TIME;
+       bounce_windows(mi, bp);
+       bp->nballs = MI_COUNT(mi);
+       if (bp->nballs < -MINBALLS) {
+               /* if bp->nballs is random ... the size can change */
+               if (bp->balls != NULL) {
+                       (void) free((void *) bp->balls);
+                       bp->balls = NULL;
+               }
+               bp->nballs = NRAND(-bp->nballs - MINBALLS + 1) + MINBALLS;
+       } else if (bp->nballs < MINBALLS)
+               bp->nballs = MINBALLS;
+       if (!bp->balls)
+               bp->balls = (ballstruct *) malloc(bp->nballs * sizeof (ballstruct));
+       if (size == 0 ||
+        MINGRIDSIZE * size > bp->width || MINGRIDSIZE * size > bp->height) {
+               if (bp->width > MINGRIDSIZE * bounce0_width &&
+                   bp->height > MINGRIDSIZE * bounce0_height) {
+                       bp->pixelmode = False;
+                       bp->xs = bounce0_width;
+                       bp->ys = bounce0_height;
+               } else {
+                       bp->pixelmode = True;
+                       bp->ys = MAX(MINSIZE, MIN(bp->width, bp->height) / MINGRIDSIZE);
+                       bp->xs = bp->ys;
+               }
+       } else {
+               bp->pixelmode = True;
+               if (size < -MINSIZE)
+                       bp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(bp->width, bp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE)
+                       bp->ys = MINSIZE;
+               else
+                       bp->ys = MIN(size, MAX(MINSIZE, MIN(bp->width, bp->height) /
+                                              MINGRIDSIZE));
+               bp->xs = bp->ys;
+       }
+       bp->avgsize = (bp->xs + bp->ys) / 2;
+       i = 0;
+       while (i < bp->nballs) {
+               bp->balls[i].vx = ((LRAND() & 1) ? -1 : 1) * (NRAND(MAX_STRENGTH) + 1);
+               bp->balls[i].x = (bp->balls[i].vx >= 0) ? 0 : bp->width - bp->xs;
+               bp->balls[i].y = NRAND(bp->height / 2);
+               if (i == collide(bp, i) || tryagain >= 8) {
+                       if (MI_NPIXELS(mi) > 2)
+                               bp->balls[i].color =
+                                       MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       else
+                               bp->balls[i].color = MI_WHITE_PIXEL(mi);
+                       bp->balls[i].xlast = -1;
+                       bp->balls[i].ylast = 0;
+                       bp->balls[i].orientlast = 0;
+                       bp->balls[i].spincount = 1;
+                       bp->balls[i].spindelay = 1;
+                       bp->balls[i].vy = ((LRAND() & 1) ? -1 : 1) * NRAND(MAX_STRENGTH);
+                       bp->balls[i].spindir = 0;
+                       bp->balls[i].vang = 0;
+                       bp->balls[i].orient = NRAND(ORIENTS);
+                       i++;
+               } else
+                       tryagain++;
+       }
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_bounce(ModeInfo * mi)
+{
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < bp->nballs; i++) {
+               drawball(mi, &bp->balls[i]);
+               moveball(mi, &bp->balls[i]);
+       }
+       for (i = 0; i < bp->nballs; i++)
+               checkCollision(bp, i);
+       if (!NRAND(TIME))       /* Put some randomness into the time */
+               bp->restartnum--;
+       if (!bp->restartnum)
+               init_bounce(mi);
+}
+
+void
+release_bounce(ModeInfo * mi)
+{
+       if (bounces != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       bouncestruct *bp = &bounces[screen];
+                       int         bits;
+
+                       if (bp->balls != NULL)
+                               (void) free((void *) bp->balls);
+                       if (bp->stippledGC != NULL)
+                               XFreeGC(MI_DISPLAY(mi), bp->stippledGC);
+                       for (bits = 0; bits < bp->init_orients; bits++)
+                               XFreePixmap(MI_DISPLAY(mi), bp->pixmaps[bits]);
+               }
+               (void) free((void *) bounces);
+               bounces = NULL;
+       }
+}
+
+void
+refresh_bounce(ModeInfo * mi)
+{
+       bouncestruct *bp = &bounces[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+       bounce_windows(mi, bp);
+}
+
+#endif /* MODE_bounce */
diff --git a/xlockmore-4.14/modes/braid.c b/xlockmore-4.14/modes/braid.c
new file mode 100644 (file)
index 0000000..b335d34
--- /dev/null
@@ -0,0 +1,445 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/*-
+ * braid --- random braids around a circle and then changes the color in
+ *           a rotational pattern
+ */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)braid.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by John Neil.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Jamie Zawinski <jwz@jwz.org> compatible with xscreensaver
+ * 01-Sep-95: color knotted components differently, J. Neil.
+ * 29-Aug-95: Written.  John Neil <neil@math.idbsu.edu>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Braid"
+#define HACK_INIT init_braid
+#define HACK_DRAW draw_braid
+#define braid_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: 15 \n" \
+ "*cycles: 100 \n" \
+ "*size: -7 \n" \
+ "*ncolors: 64 \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"
+#else /* STANDALONE */
+#include "xlock.h"
+
+#endif /* STANDALONE */
+
+#ifdef MODE_braid
+
+ModeSpecOpt braid_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   braid_description =
+{"braid", "init_braid", "draw_braid", "release_braid",
+ "refresh_braid", "init_braid", NULL, &braid_opts,
+ 1000, 15, 100, 1, 64, 1.0, "",
+ "Shows random braids and knots", 0, NULL};
+
+#endif
+
+#if defined( COLORROUND ) && defined( COLORCOMP )
+#undef COLORROUND
+#undef COLORCOMP
+#endif
+
+#if !defined( COLORROUND ) && !defined( COLORCOMP )
+#if 0
+/* to color in a circular pattern use COLORROUND */
+#define COLORROUND
+#else
+/* to color by component use COLORCOMP */
+#define COLORCOMP
+#endif
+#endif
+
+#define MAXLENGTH  50          /* the maximum length of a braid word */
+#define MINLENGTH  8           /* the minimum length of a braid word */
+#define MAXSTRANDS  15         /* the maximum number of strands in the braid */
+#define MINSTRANDS  3          /* the minimum number of strands in the braid */
+#define SPINRATE  12.0         /* the rate at which the colors spin */
+
+#define INTRAND(min,max) (NRAND((max+1)-(min))+(min))
+#define FLOATRAND(min,max) ((min)+((double) LRAND()/((double) MAXRAND))*((max)-(min)))
+
+typedef struct {
+       int         linewidth;
+       int         braidword[MAXLENGTH];
+       int         components[MAXSTRANDS];
+       int         startcomp[MAXLENGTH][MAXSTRANDS];
+       int         nstrands;
+       int         braidlength;
+       float       startcolor;
+       int         center_x;
+       int         center_y;
+       float       min_radius;
+       float       max_radius;
+       float       top, bottom, left, right;
+       int         age;
+       int         color_direction;
+} braidtype;
+
+static braidtype *braids = NULL;
+
+static int
+applyword(braidtype * braid, int string, int position)
+{
+       int         i, c;
+
+       c = string;
+       for (i = position; i < braid->braidlength; i++) {
+               if (c == ABS(braid->braidword[i]))
+                       c--;
+               else if (c == ABS(braid->braidword[i]) - 1)
+                       c++;
+       }
+       for (i = 0; i < position; i++) {
+               if (c == ABS(braid->braidword[i]))
+                       c--;
+               else if (c == ABS(braid->braidword[i]) - 1)
+                       c++;
+       }
+       return c;
+}
+
+#if 0
+static int
+applywordto(braidtype * braid, int string, int position)
+{
+       int         i, c;
+
+       c = string;
+       for (i = 0; i < position; i++) {
+               if (c == ABS(braid->braidword[i])) {
+                       c--;
+               } else if (c == ABS(braid->braidword[i]) - 1) {
+                       c++;
+               }
+       }
+       return c;
+}
+#endif
+
+static int
+applywordbackto(braidtype * braid, int string, int position)
+{
+       int         i, c;
+
+       c = string;
+       for (i = position - 1; i >= 0; i--) {
+               if (c == ABS(braid->braidword[i])) {
+                       c--;
+               } else if (c == ABS(braid->braidword[i]) - 1) {
+                       c++;
+               }
+       }
+       return c;
+}
+
+void
+init_braid(ModeInfo * mi)
+{
+       braidtype  *braid;
+       int         used[MAXSTRANDS];
+       int         i, count, comp, c;
+       float       min_length;
+
+       if (braids == NULL) {
+               if ((braids = (braidtype *) calloc(MI_NUM_SCREENS(mi),
+                                               sizeof (braidtype))) == NULL)
+                       return;
+       }
+       braid = &braids[MI_SCREEN(mi)];
+
+       braid->center_x = MI_WIDTH(mi) / 2;
+       braid->center_y = MI_HEIGHT(mi) / 2;
+       braid->age = 0;
+
+       /* jwz: go in the other direction sometimes. */
+       braid->color_direction = ((LRAND() & 1) ? 1 : -1);
+
+       MI_CLEARWINDOW(mi);
+
+       min_length = (braid->center_x > braid->center_y) ?
+               braid->center_y : braid->center_x;
+       braid->min_radius = min_length * 0.30;
+       braid->max_radius = min_length * 0.90;
+
+       if (MI_COUNT(mi) < MINSTRANDS)
+               braid->nstrands = MINSTRANDS;
+       else
+               braid->nstrands = INTRAND(MINSTRANDS,
+                                      MAX(MIN(MIN(MAXSTRANDS, MI_COUNT(mi)),
+                                              (int) ((braid->max_radius - braid->min_radius) / 5.0)), MINSTRANDS));
+       braid->braidlength = INTRAND(MINLENGTH, MIN(MAXLENGTH, braid->nstrands * 6));
+
+       for (i = 0; i < braid->braidlength; i++) {
+               braid->braidword[i] =
+                       INTRAND(1, braid->nstrands - 1) * (INTRAND(1, 2) * 2 - 3);
+               if (i > 0)
+                       while (braid->braidword[i] == -braid->braidword[i - 1])
+                               braid->braidword[i] = INTRAND(1, braid->nstrands - 1) * (INTRAND(1, 2) * 2 - 3);
+       }
+
+       while (braid->braidword[0] == -braid->braidword[braid->braidlength - 1])
+               braid->braidword[braid->braidlength - 1] =
+                       INTRAND(1, braid->nstrands - 1) * (INTRAND(1, 2) * 2 - 3);
+
+       do {
+               (void) memset((char *) used, 0, sizeof (used));
+               count = 0;
+               for (i = 0; i < braid->braidlength; i++)
+                       used[ABS(braid->braidword[i])]++;
+               for (i = 0; i < braid->nstrands; i++)
+                       count += (used[i] > 0) ? 1 : 0;
+               if (count < braid->nstrands - 1) {
+                       braid->braidword[braid->braidlength] =
+                               INTRAND(1, braid->nstrands - 1) * (INTRAND(1, 2) * 2 - 3);
+                       while (braid->braidword[braid->braidlength] ==
+                              -braid->braidword[braid->braidlength - 1] &&
+                              braid->braidword[0] == -braid->braidword[braid->braidlength])
+                               braid->braidword[braid->braidlength] =
+                                       INTRAND(1, braid->nstrands - 1) * (INTRAND(1, 2) * 2 - 3);
+                       braid->braidlength++;
+               }
+       } while (count < braid->nstrands - 1 && braid->braidlength < MAXLENGTH);
+
+       braid->startcolor = (MI_NPIXELS(mi) > 2) ?
+               (float) NRAND(MI_NPIXELS(mi)) : 0.0;
+       /* XSetLineAttributes (display, MI_GC(mi), 2, LineSolid, CapRound, 
+          JoinRound); */
+
+       (void) memset((char *) braid->components, 0, sizeof (braid->components));
+       c = 1;
+       comp = 0;
+       braid->components[0] = 1;
+       do {
+               i = comp;
+               do {
+                       i = applyword(braid, i, 0);
+                       braid->components[i] = braid->components[comp];
+               } while (i != comp);
+               count = 0;
+               for (i = 0; i < braid->nstrands; i++)
+                       if (braid->components[i] == 0)
+                               count++;
+               if (count > 0) {
+                       for (comp = 0; braid->components[comp] != 0; comp++);
+                       braid->components[comp] = ++c;
+               }
+       } while (count > 0);
+
+       braid->linewidth = MI_SIZE(mi);
+
+       if (braid->linewidth < 0)
+               braid->linewidth = NRAND(-braid->linewidth) + 1;
+
+       for (i = 0; i < braid->nstrands; i++)
+               if (!(braid->components[i] & 1))
+                       braid->components[i] *= -1;
+}
+
+void
+draw_braid(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       braidtype  *braid = &braids[MI_SCREEN(mi)];
+       int         num_points = 500;
+       float       t_inc;
+       float       theta, psi;
+       float       t, r_diff;
+       int         i, s;
+       float       x_1, y_1, x_2, y_2, r1, r2;
+       float       color, color_use = 0.0, color_inc;
+
+       MI_IS_DRAWN(mi) = True;
+
+       XSetLineAttributes(display, MI_GC(mi), braid->linewidth,
+                          LineSolid,
+                          (braid->linewidth <= 3 ? CapButt : CapRound),
+                          JoinMiter);
+
+       theta = (2.0 * M_PI) / (float) (braid->braidlength);
+       t_inc = (2.0 * M_PI) / (float) num_points;
+       color_inc = (float) MI_NPIXELS(mi) * braid->color_direction /
+               (float) num_points;
+       braid->startcolor += SPINRATE * color_inc;
+       if (((int) braid->startcolor) >= MI_NPIXELS(mi))
+               braid->startcolor = 0.0;
+
+       r_diff = (braid->max_radius - braid->min_radius) / (float) (braid->nstrands);
+
+       color = braid->startcolor;
+       psi = 0.0;
+       for (i = 0; i < braid->braidlength; i++) {
+               psi += theta;
+               for (t = 0.0; t < theta; t += t_inc) {
+#ifdef COLORROUND
+                       color += color_inc;
+                       if (((int) color) >= MI_NPIXELS(mi))
+                               color = 0.0;
+                       color_use = color;
+#endif
+                       for (s = 0; s < braid->nstrands; s++) {
+                               if (ABS(braid->braidword[i]) == s)
+                                       continue;
+                               if (ABS(braid->braidword[i]) - 1 == s) {
+                                       /* crosSINFg */
+#ifdef COLORCOMP
+                                       if (MI_NPIXELS(mi) > 2) {
+                                               color_use = color + SPINRATE *
+                                                       braid->components[applywordbackto(braid, s, i)] +
+                                                       (psi + t) / 2.0 / M_PI * (float) MI_NPIXELS(mi);
+                                               while (((int) color_use) >= MI_NPIXELS(mi))
+                                                       color_use -= (float) MI_NPIXELS(mi);
+                                               while (((int) color_use) < 0)
+                                                       color_use += (float) MI_NPIXELS(mi);
+                                       }
+#endif
+#ifdef COLORROUND
+                                       if (MI_NPIXELS(mi) > 2) {
+                                               color_use += SPINRATE * color_inc;
+                                               while (((int) color_use) >= MI_NPIXELS(mi))
+                                                       color_use -= (float) MI_NPIXELS(mi);
+                                       }
+#endif
+                                       r1 = braid->min_radius + r_diff * (float) (s);
+                                       r2 = braid->min_radius + r_diff * (float) (s + 1);
+                                       if (braid->braidword[i] > 0 ||
+                                           (FABSF(t - theta / 2.0) > theta / 7.0)) {
+                                               x_1 = ((0.5 * (1.0 + SINF(t / theta * M_PI - M_PI_2)) * r2 +
+                                                       0.5 * (1.0 + SINF((theta - t) / theta * M_PI - M_PI_2)) * r1)) *
+                                                       COSF(t + psi) + braid->center_x;
+                                               y_1 = ((0.5 * (1.0 + SINF(t / theta * M_PI - M_PI_2)) * r2 +
+                                                       0.5 * (1.0 + SINF((theta - t) / theta * M_PI - M_PI_2)) * r1)) *
+                                                       SINF(t + psi) + braid->center_y;
+                                               x_2 = ((0.5 * (1.0 + SINF((t + t_inc) / theta * M_PI - M_PI_2)) * r2 +
+                                                       0.5 * (1.0 + SINF((theta - t - t_inc) / theta * M_PI - M_PI_2)) * r1)) *
+                                                       COSF(t + t_inc + psi) + braid->center_x;
+                                               y_2 = ((0.5 * (1.0 + SINF((t + t_inc) / theta * M_PI - M_PI_2)) * r2 +
+                                                       0.5 * (1.0 + SINF((theta - t - t_inc) / theta * M_PI - M_PI_2)) * r1)) *
+                                                       SINF(t + t_inc + psi) + braid->center_y;
+                                               if (MI_NPIXELS(mi) > 2)
+                                                       XSetForeground(display, MI_GC(mi), MI_PIXEL(mi, (int) color_use));
+                                               else
+                                                       XSetForeground(display, MI_GC(mi), MI_WHITE_PIXEL(mi));
+
+                                               XDrawLine(display, window, MI_GC(mi),
+                                                         (int) (x_1), (int) (y_1), (int) (x_2), (int) (y_2));
+                                       }
+#ifdef COLORCOMP
+                                       if (MI_NPIXELS(mi) > 2) {
+                                               color_use = color + SPINRATE *
+                                                       braid->components[applywordbackto(braid, s + 1, i)] +
+                                                       (psi + t) / 2.0 / M_PI * (float) MI_NPIXELS(mi);
+                                               while (((int) color_use) >= MI_NPIXELS(mi))
+                                                       color_use -= (float) MI_NPIXELS(mi);
+                                               while (((int) color_use) < 0)
+                                                       color_use += (float) MI_NPIXELS(mi);
+                                       }
+#endif
+                                       if (braid->braidword[i] < 0 ||
+                                           (FABSF(t - theta / 2.0) > theta / 7.0)) {
+                                               x_1 = ((0.5 * (1.0 + SINF(t / theta * M_PI - M_PI_2)) * r1 +
+                                                       0.5 * (1.0 + SINF((theta - t) / theta * M_PI - M_PI_2)) * r2)) *
+                                                       COSF(t + psi) + braid->center_x;
+                                               y_1 = ((0.5 * (1.0 + SINF(t / theta * M_PI - M_PI_2)) * r1 +
+                                                       0.5 * (1.0 + SINF((theta - t) / theta * M_PI - M_PI_2)) * r2)) *
+                                                       SINF(t + psi) + braid->center_y;
+                                               x_2 = ((0.5 * (1.0 + SINF((t + t_inc) / theta * M_PI - M_PI_2)) * r1 +
+                                                       0.5 * (1.0 + SINF((theta - t - t_inc) / theta * M_PI - M_PI_2)) * r2)) *
+                                                       COSF(t + t_inc + psi) + braid->center_x;
+                                               y_2 = ((0.5 * (1.0 + SINF((t + t_inc) / theta * M_PI - M_PI_2)) * r1 +
+                                                       0.5 * (1.0 + SINF((theta - t - t_inc) / theta * M_PI - M_PI_2)) * r2)) *
+                                                       SINF(t + t_inc + psi) + braid->center_y;
+                                               if (MI_NPIXELS(mi) > 2)
+                                                       XSetForeground(display, MI_GC(mi), MI_PIXEL(mi, (int) color_use));
+                                               else
+                                                       XSetForeground(display, MI_GC(mi), MI_WHITE_PIXEL(mi));
+
+                                               XDrawLine(display, window, MI_GC(mi),
+                                                         (int) (x_1), (int) (y_1), (int) (x_2), (int) (y_2));
+                                       }
+                               } else {
+                                       /* no crosSINFg */
+#ifdef COLORCOMP
+                                       if (MI_NPIXELS(mi) > 2) {
+                                               color_use = color + SPINRATE *
+                                                       braid->components[applywordbackto(braid, s, i)] +
+                                                       (psi + t) / 2.0 / M_PI * (float) MI_NPIXELS(mi);
+                                               while (((int) color_use) >= MI_NPIXELS(mi))
+                                                       color_use -= (float) MI_NPIXELS(mi);
+                                               while (((int) color_use) < 0)
+                                                       color_use += (float) MI_NPIXELS(mi);
+                                       }
+#endif
+#ifdef COLORROUND
+                                       if (MI_NPIXELS(mi) > 2) {
+                                               color_use += SPINRATE * color_inc;
+                                               while (((int) color_use) >= MI_NPIXELS(mi))
+                                                       color_use -= (float) MI_NPIXELS(mi);
+                                       }
+#endif
+                                       r1 = braid->min_radius + r_diff * (float) (s);
+                                       x_1 = r1 * COSF(t + psi) + braid->center_x;
+                                       y_1 = r1 * SINF(t + psi) + braid->center_y;
+                                       x_2 = r1 * COSF(t + t_inc + psi) + braid->center_x;
+                                       y_2 = r1 * SINF(t + t_inc + psi) + braid->center_y;
+                                       if (MI_NPIXELS(mi) > 2)
+                                               XSetForeground(display, MI_GC(mi), MI_PIXEL(mi, (int) color_use));
+                                       else
+                                               XSetForeground(display, MI_GC(mi), MI_WHITE_PIXEL(mi));
+
+                                       XDrawLine(display, window, MI_GC(mi),
+                                                 (int) (x_1), (int) (y_1), (int) (x_2), (int) (y_2));
+                               }
+                       }
+               }
+       }
+       XSetLineAttributes(display, MI_GC(mi), 1, LineSolid, CapNotLast, JoinRound);
+
+       if (++braid->age > MI_CYCLES(mi)) {
+               init_braid(mi);
+       }
+}
+
+void
+release_braid(ModeInfo * mi)
+{
+       if (braids != NULL) {
+               (void) free((void *) braids);
+               braids = NULL;
+       }
+}
+
+void
+refresh_braid(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_braid */
diff --git a/xlockmore-4.14/modes/bubble.c b/xlockmore-4.14/modes/bubble.c
new file mode 100644 (file)
index 0000000..8af7791
--- /dev/null
@@ -0,0 +1,286 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* bubble --- simple exploding bubbles */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)bubble.c     4.07 98/01/08 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1998 by Charles Vidal <vidalc@club-internet.fr>
+ *         http://www.chez.com/vidalc
+ *         and David Bagley
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-Jan-98: Written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Bubble"
+#define HACK_INIT init_bubble
+#define HACK_DRAW draw_bubble
+#define bubble_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: 25 \n" \
+ "*size: 100 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_bubble
+
+#define DEF_BOIL  "False"
+static Bool boil;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-boil", ".bubble.boil", XrmoptionNoArg, (caddr_t) "on"},
+       {"+boil", ".bubble.boil", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & boil, "boil", "Boil", DEF_BOIL, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+boil", "turn on/off boil"}
+};
+
+ModeSpecOpt bubble_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   bubble_description =
+{"bubble", "init_bubble", "draw_bubble", "release_bubble",
+ "refresh_bubble", "init_bubble", NULL, &bubble_opts,
+ 100000, 25, 1, 100, 64, 0.6, "",
+ "Shows popping bubbles", 0, NULL};
+
+#endif
+
+typedef struct {
+       int         x, y, life;
+} bubbletype;
+
+#define MINSIZE 20
+#define MINBUBBLES 1
+
+typedef struct {
+       int         direction;
+       int         color;
+       int         width, height;
+       int         nbubbles;
+       Bool        boil;
+       bubbletype *bubble;
+       int         d;
+       Pixmap      dbuf;
+       GC          dbuf_gc;
+} bubblestruct;
+
+static bubblestruct *bubbles = NULL;
+
+static void
+updateBubble(ModeInfo * mi, int i)
+{
+       bubblestruct *bp = &bubbles[MI_SCREEN(mi)];
+       int         x, diameter, x4, y4, diameter4;
+
+       if (bp->bubble[i].life + 1 > bp->d - NRAND(16) ||
+           bp->bubble[i].y < 0) {
+               bp->bubble[i].life = 0;
+               return;
+       }
+       ++bp->bubble[i].life;
+       diameter = bp->bubble[i].life;
+       x = bp->bubble[i].x;
+       if (bp->boil) {
+               bp->bubble[i].y -= diameter / 2;
+               x += (int) (cos((double) (diameter +
+                      bp->bubble[i].x) / (M_PI / 5.0)) * (double) diameter);
+       }
+       /* SunOS 4.1.X xnews server may crash without this */
+       if (diameter < 4) {
+               XFillRectangle(MI_DISPLAY(mi), bp->dbuf, bp->dbuf_gc,
+                           x - diameter / 2, bp->bubble[i].y - diameter / 2,
+                              diameter, diameter);
+       } else {
+               XDrawArc(MI_DISPLAY(mi), bp->dbuf, bp->dbuf_gc,
+                        x - diameter / 2, bp->bubble[i].y - diameter / 2,
+                        diameter, diameter, 0, 23040);
+       }
+       diameter4 = diameter / 4;
+       if (diameter4 > 0) {
+               x4 = x - diameter4 / 2 +
+                       ((bp->direction / 2) ? (-1) : 1) * diameter / 6;
+               y4 = bp->bubble[i].y - diameter4 / 2 +
+                       ((bp->direction % 2) ? 1 : (-1)) * diameter / 6;
+               /* SunOS 4.1.X xnews server may crash without this */
+               if (diameter4 < 4) {
+                       XFillRectangle(MI_DISPLAY(mi), bp->dbuf, bp->dbuf_gc,
+                                      x4, y4, diameter4, diameter4);
+               } else {
+                       XFillArc(MI_DISPLAY(mi), bp->dbuf, bp->dbuf_gc,
+                                x4, y4, diameter4, diameter4, 0, 23040);
+               }
+       }
+}
+
+static void
+changeBubble(ModeInfo * mi)
+{
+       bubblestruct *bp = &bubbles[MI_SCREEN(mi)];
+       int         i;
+
+       for (i = 0; i < bp->nbubbles; i++) {
+               if (bp->bubble[i].life != 0)
+                       updateBubble(mi, i);
+       }
+       i = NRAND(bp->nbubbles);
+       if (bp->bubble[i].life == 0) {
+               bp->bubble[i].x = NRAND(bp->width);
+               if (bp->boil)
+                       bp->bubble[i].y = bp->height -
+                               ((bp->height >= 16) ? NRAND(bp->height / 16) : 0);
+               else
+                       bp->bubble[i].y = NRAND(bp->height);
+               updateBubble(mi, i);
+       }
+}
+
+void
+init_bubble(ModeInfo * mi)
+{
+       bubblestruct *bp;
+       int         size = MI_SIZE(mi);
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       XGCValues   gcv;
+
+       if (bubbles == NULL) {
+               if ((bubbles = (bubblestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (bubblestruct))) == NULL)
+                       return;
+       }
+       bp = &bubbles[MI_SCREEN(mi)];
+
+       bp->width = MI_WIDTH(mi);
+       bp->height = MI_HEIGHT(mi);
+       bp->direction = NRAND(4);
+       if (MI_IS_FULLRANDOM(mi))
+               bp->boil = (Bool) (LRAND() & 1);
+       else
+               bp->boil = boil;
+
+       if (size < -MINSIZE)
+               bp->d = NRAND(MIN(-size, MAX(MINSIZE,
+                  MIN(bp->width, bp->height) / 2)) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE) {
+               if (!size)
+                       bp->d = MAX(MINSIZE, MIN(bp->width, bp->height) / 2);
+               else
+                       bp->d = MINSIZE;
+       } else
+               bp->d = MIN(size, MAX(MINSIZE,
+                                     MIN(bp->width, bp->height) / 2));
+       bp->nbubbles = MI_COUNT(mi);
+       if (bp->nbubbles < -MINBUBBLES) {
+               bp->nbubbles = NRAND(-bp->nbubbles - MINBUBBLES + 1) + MINBUBBLES;
+       } else if (bp->nbubbles < MINBUBBLES)
+               bp->nbubbles = MINBUBBLES;
+       if (bp->bubble != NULL)
+               (void) free((void *) bp->bubble);
+       bp->bubble = (bubbletype *) calloc(bp->nbubbles, sizeof (bubbletype));
+
+       if (MI_NPIXELS(mi) > 2)
+               bp->color = NRAND(MI_NPIXELS(mi));
+
+       if (bp->dbuf)
+               XFreePixmap(display, bp->dbuf);
+       bp->dbuf = XCreatePixmap(display, window, bp->width, bp->height, 1);
+       /* Do not want any exposure events from XCopyPlane */
+       XSetGraphicsExposures(display, MI_GC(mi), False);
+
+       gcv.foreground = 1;
+       gcv.background = 0;
+       gcv.function = GXcopy;
+       gcv.graphics_exposures = False;
+       gcv.line_width = 2;
+       if (bp->dbuf_gc)
+               XFreeGC(display, bp->dbuf_gc);
+       bp->dbuf_gc = XCreateGC(display, bp->dbuf,
+              GCForeground | GCBackground | GCLineWidth | GCFunction, &gcv);
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_bubble(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       bubblestruct *bp = &bubbles[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (MI_NPIXELS(mi) <= 2)
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       else {
+               bp->color = (bp->color + 1) % MI_NPIXELS(mi);
+               XSetForeground(display, gc, MI_PIXEL(mi, bp->color));
+       }
+       if (bp->dbuf) {
+               XSetForeground(display, bp->dbuf_gc, 0);
+               XFillRectangle(display, bp->dbuf, bp->dbuf_gc,
+                              0, 0, bp->width, bp->height);
+               XSetForeground(display, bp->dbuf_gc, 1);
+               changeBubble(mi);
+               XCopyPlane(display, bp->dbuf, window, gc,
+                          0, 0, bp->width, bp->height, 0, 0, 1);
+       }
+}
+
+void
+release_bubble(ModeInfo * mi)
+{
+       if (bubbles != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       bubblestruct *bp = &bubbles[screen];
+
+                       if (bp->dbuf)
+                               XFreePixmap(MI_DISPLAY(mi), bp->dbuf);
+                       if (bp->dbuf_gc)
+                               XFreeGC(MI_DISPLAY(mi), bp->dbuf_gc);
+                       if (bp->bubble != NULL)
+                               (void) free((void *) bp->bubble);
+               }
+               (void) free((void *) bubbles);
+               bubbles = NULL;
+       }
+}
+
+void
+refresh_bubble(ModeInfo * mi)
+{
+       /* Do nothing, it will refresh by itself */
+}
+
+#endif /* MODE_bubble */
diff --git a/xlockmore-4.14/modes/bug.c b/xlockmore-4.14/modes/bug.c
new file mode 100644 (file)
index 0000000..be6855e
--- /dev/null
@@ -0,0 +1,1162 @@
+#define NEIGHBOR4
+/* -*- Mode: C; tab-width: 4 -*- */
+/* bug --- Michael Palmiter's simulated evolution */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)bug.c        4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 24-Aug-95: Coded from A.K. Dewdney's, "Computer Recreations", Scientific
+ *            American Magazine" May 1989 pp138-141 and Sept 1989 p 183.
+ *            also used wator.c as a guide.
+ */
+
+/*-
+ * Bugs learn to hunt bacteria (or die) in the Garden of Eden and outside.
+ * They start as jitterbugs and "evolve" to move straight (in the Garden
+ *  they may evolve to twirl around).
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Bug"
+#define HACK_INIT init_bug
+#define HACK_DRAW draw_bug
+#define bug_opts xlockmore_opts
+#define DEFAULTS "*delay: 75000 \n" \
+ "*count: 10 \n" \
+ "*cycles: 32767 \n" \
+ "*size: -4 \n" \
+ "*ncolors: 64 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_bug
+
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+#define DEF_EYES  "False"
+
+static int  neighbors;
+static Bool eyes;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".bug.neighbors", XrmoptionSepArg, (caddr_t) NULL},
+       {"-eyes", ".bug.eyes", XrmoptionNoArg, (caddr_t) "on"},
+       {"+eyes", ".bug.eyes", XrmoptionNoArg, (caddr_t) "off"},
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int},
+       {(caddr_t *) & eyes, "eyes", "Eyes", DEF_EYES, t_Bool},
+};
+static OptionStruct desc[] =
+{
+        {"-neighbors num", "squares 4 or 8, hexagons 6"},
+       {"-/+eyes", "turn on/off eyes"}
+};
+
+ModeSpecOpt bug_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+
+#ifdef USE_MODULES
+ModStruct   bug_description =
+{"bug", "init_bug", "draw_bug", "release_bug",
+ "refresh_bug", "init_bug", NULL, &bug_opts,
+ 75000, 10, 32767, -4, 64, 1.0, "",
+ "Shows Palmiter's bug evolution and garden of Eden", 0, NULL};
+
+#endif
+
+#if DEBUG
+#include <assert.h>
+#endif
+
+#define BUGBITS(n,w,h)\
+  bp->pixmaps[bp->init_bits++]=\
+  XCreatePixmapFromBitmapData(display,window,(char *)n,w,h,1,0,1)
+
+#define BACTERIA 0
+#define BUG 1
+
+#define MAXENERGY 1500         /* Max energy storage */
+#define INITENERGY 400         /* Initial energy */
+#define FOODPERCYCLE 1
+#define BACTERIAENERGY 40
+#define STRONG 1000            /* Min energy to breed */
+#define MATURE 800             /* Breeding time of bugs */
+#define MAXGENE 6
+#define MINGENE (-MAXGENE)
+#define REDRAWSTEP 2000                /* How many bacteria to draw per cycle */
+#define MINGRIDSIZE 24
+#define MINSIZE 1
+#define ANGLES 360
+#ifdef NEIGHBORS
+#define NEIGHBORKINDS 6
+#define MAXNEIGHBORS 12
+#else
+#define MAXNEIGHBORS 8
+#define NEIGHBORKINDS 3
+#endif
+
+/* Relative bug moves */
+/* Forward, Right, Hard Right, Reverse, Hard Left, Left */
+
+/* Bug data */
+typedef struct {
+       char        direction;
+       int         age, energy;
+       unsigned int color;
+       int         col, row;
+       int         gene[MAXNEIGHBORS];
+       double      gene_prob[MAXNEIGHBORS];
+} bugstruct;
+
+/* Doublely linked list */
+typedef struct _BugList {
+       bugstruct   info;
+       struct _BugList *previous, *next;
+} BugList;
+
+typedef struct {
+       Bool        painted;
+       int         neighbors;
+       int         nbugs;      /* Number of bugs */
+       int         eden;       /* Does the garden exist? */
+       int         generation;
+       int         ncols, nrows;
+       int         width, height;
+       int         edenwidth, edenheight;
+       int         edenstartx, edenstarty;
+       int         xs, ys, xb, yb;
+       int         redrawing, redrawpos;
+       int         eyes;
+       BugList    *currbug, *babybug, *lastbug, *firstbug, *lasttemp, *firsttemp;
+       BugList   **arr;        /* 0=empty or pts to a bug */
+       char       *bacteria;   /* 0=empty or food */
+       int         init_bits;
+       GC          stippledGC;
+       Pixmap      pixmaps[NUMSTIPPLES - 1];
+       union {
+               XPoint      hexagon[6];
+               XPoint      triangle[2][3];
+       } shape;
+} bugfarmstruct;
+
+static double genexp[MAXGENE - MINGENE + 1];
+
+static char plots[NEIGHBORKINDS] =
+#ifdef NEIGHBORS
+{3, 4, 6, 8, 9, 12};           /* Neighborhoods */
+#else
+{4, 6, 8};             /* Neighborhoods */
+#endif
+
+static bugfarmstruct *bugfarms = NULL;
+
+#ifdef NEIGHBORS
+static void
+position_of_neighbor(bugfarmstruct * bp, int dir, int *pcol, int *prow)
+{
+       int         col = *pcol, row = *prow;
+
+       /* NO WRAPING */
+
+       if (bp->neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = col + 1;
+                               break;
+                       case 60:
+                               if (!(row & 1))
+                                       col = col + 1;
+                               row = row - 1;
+                               break;
+                       case 120:
+                               if (row & 1)
+                                       col = col - 1;
+                               row = row - 1;
+                               break;
+                       case 180:
+                               col = col - 1;
+                               break;
+                       case 240:
+                               if (row & 1)
+                                       col = col - 1;
+                               row = row + 1;
+                               break;
+                       case 300:
+                               if (!(row & 1))
+                                       col = col + 1;
+                               row = row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               col = col + 1;
+                               break;
+                       case 45:
+                               col = col + 1;
+                               row = row - 1;
+                               break;
+                       case 90:
+                               row = row - 1;
+                               break;
+                       case 135:
+                               col = col - 1;
+                               row = row - 1;
+                               break;
+                       case 180:
+                               col = col - 1;
+                               break;
+                       case 225:
+                               col = col - 1;
+                               row = row + 1;
+                               break;
+                       case 270:
+                               row = row + 1;
+                               break;
+                       case 315:
+                               col = col + 1;
+                               row = row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {                /* TRI */
+               if ((col + row) % 2) {  /* right */
+                       switch (dir) {
+                               case 0:
+                                       col = col - 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = col - 1;
+                                       row = row - 1;
+                                       break;
+                               case 60:
+                                       col = col - 1;
+                                       row = row - 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       row = row - 2;
+                                       break;
+                               case 120:
+                                       row = row - 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = col + 1;
+                                       row = row - 1;
+                                       break;
+                               case 180:
+                                       col = col + 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = col + 1;
+                                       row = row + 1;
+                                       break;
+                               case 240:
+                                       row = row + 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       row = row + 2;
+                                       break;
+                               case 300:
+                                       col = col - 1;
+                                       row = row + 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = col - 1;
+                                       row = row + 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               } else {        /* left */
+                       switch (dir) {
+                               case 0:
+                                       col = col + 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = col + 1;
+                                       row = row + 1;
+                                       break;
+                               case 60:
+                                       col = col + 1;
+                                       row = row + 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       row = row + 2;
+                                       break;
+                               case 120:
+                                       row = row + 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = col - 1;
+                                       row = row + 1;
+                                       break;
+                               case 180:
+                                       col = col - 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = col - 1;
+                                       row = row - 1;
+                                       break;
+                               case 240:
+                                       row = row - 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       row = row - 2;
+                                       break;
+                               case 300:
+                                       col = col + 1;
+                                       row = row - 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = col + 1;
+                                       row = row - 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               }
+       }
+       *pcol = col;
+       *prow = row;
+}
+
+#endif
+
+#if 0
+static void
+screen2grid(bugfarmstruct *bp, int sx, int sy, int x, int y)
+{
+       *y = sy / 2;
+       if (bp->neighbors == 6) {
+               *x = (sx + 1) / 2 - 1;
+       } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+               *x = sx / 2;
+       }
+}
+
+#endif
+
+static void
+grid2screen(bugfarmstruct *bp, int x, int y, int *sx, int *sy)
+{
+       *sy = y * 2 + 1;
+       if (bp->neighbors == 6) {
+               *sx = 2 * x + 1 + !(y & 1);
+       } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+               *sx = x * 2 + 1;
+       }
+}
+
+/* This is slightly different than ant since it increases clockwise from
+   y axis as opposed to increasing counterclockwise from x-axis.
+   There is no reason for this difference other than laziness in syncing
+   them back up.
+ */
+static char
+compassmove(bugfarmstruct * bp, int x, int y, int dir, int *nx, int *ny)
+{
+       if (bp->neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               *ny = y - 1;
+                               *nx = x + (int) !(y & 1);
+                               return (*ny >= 0 && *nx < bp->ncols - !(*ny & 1));
+                       case 60:
+                               *ny = y;
+                               *nx = x + 1;
+                               return (*nx < bp->ncols - !(*ny & 1));
+                       case 120:
+                               *ny = y + 1;
+                               *nx = x + (int) !(y & 1);
+                               return (*ny < bp->nrows && *nx < bp->ncols - !(*ny & 1));
+                       case 180:
+                               *ny = y + 1;
+                               *nx = x - (int) (y & 1);
+                               return (*ny < bp->nrows && *nx >= 0);
+                       case 240:
+                               *ny = y;
+                               *nx = x - 1;
+                               return (*nx >= 0);
+                       case 300:
+                               *ny = y - 1;
+                               *nx = x - (int) (y & 1);
+                               return (*ny >= 0 && *nx >= 0);
+                       default:
+                               return 0;
+               }
+       } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               *ny = y - 1;
+                               *nx = x;
+                               return (*ny >= 0);
+                       case 45:
+                               *ny = y - 1;
+                               *nx = x + 1;
+                               return (*ny >= 0 && *nx < bp->ncols);
+                       case 90:
+                               *ny = y;
+                               *nx = x + 1;
+                               return (*nx < bp->ncols);
+                       case 135:
+                               *ny = y + 1;
+                               *nx = x + 1;
+                               return (*ny < bp->nrows && *nx < bp->ncols);
+                       case 180:
+                               *ny = y + 1;
+                               *nx = x;
+                               return (*ny < bp->nrows);
+                       case 225:
+                               *ny = y + 1;
+                               *nx = x - 1;
+                               return (*ny < bp->nrows && *nx >= 0);
+                       case 270:
+                               *ny = y;
+                               *nx = x - 1;
+                               return (*nx >= 0);
+                       case 315:
+                               *ny = y - 1;
+                               *nx = x - 1;
+                               return (*ny >= 0 && *nx >= 0);
+                       default:
+                               return 0;
+               }
+       }
+}
+
+/* This keeps bugs from walking over each other and escaping off the screen */
+static int
+has_neighbor(bugfarmstruct * bp, int col, int row)
+{
+       int         colrow = col + row * bp->ncols;
+
+       if (bp->neighbors == 6) {
+               if ((row > 0) && (bp->arr[colrow - bp->ncols]))
+                       return True;
+               if ((row < bp->nrows - 1) && bp->arr[colrow + bp->ncols])
+                       return True;
+               if (col > 0) {
+                       if (bp->arr[colrow - 1])
+                               return True;
+                       if (row & 1) {
+                               if ((row > 0) && bp->arr[colrow - 1 - bp->ncols])
+                                       return True;
+                               if ((row < bp->nrows - 1) && bp->arr[colrow - 1 + bp->ncols])
+                                       return True;
+                       }
+               }
+               if (col < bp->ncols - 1) {
+                       if (bp->arr[colrow + 1])
+                               return True;
+                       if (!(row & 1)) {
+                               if ((row > 0) && bp->arr[colrow + 1 - bp->ncols])
+                                       return True;
+                               if ((row < bp->nrows - 1) && bp->arr[colrow + 1 + bp->ncols])
+                                       return True;
+                       }
+               }
+       } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+               if ((row > 0) && (bp->arr[colrow - bp->ncols]))
+                       return True;
+               if ((row < bp->nrows - 1) && bp->arr[colrow + bp->ncols])
+                       return True;
+               if ((col > 0) && (bp->arr[colrow - 1]))
+                       return True;
+               if ((col < bp->ncols - 1) && bp->arr[colrow + 1])
+                       return True;
+               if (row > 0 && col > 0 && bp->arr[colrow - bp->ncols - 1])
+                       return True;
+               if (row > 0 && col < bp->ncols - 1 && bp->arr[colrow - bp->ncols + 1])
+                       return True;
+               if (row < bp->nrows - 1 && col > 0 && bp->arr[colrow + bp->ncols - 1])
+                       return True;
+               if (row < bp->nrows - 1 && col < bp->ncols - 1 && bp->arr[colrow + bp->ncols + 1])
+                       return True;
+       }
+       return False;
+}
+
+static void
+drawabacterium(ModeInfo * mi, int col, int row, unsigned char color)
+{
+       bugfarmstruct *bp = &bugfarms[MI_SCREEN(mi)];
+       int         ccol, crow;
+
+       if (color)
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WHITE_PIXEL(mi));
+       else
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+       grid2screen(bp, col, row, &ccol, &crow);
+       XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+              bp->xb + bp->xs * ccol, bp->yb + bp->ys * crow,
+              bp->xs, bp->ys);
+}
+
+static void
+drawabug(ModeInfo * mi, int col, int row, unsigned int color, int direction)
+{
+       bugfarmstruct *bp = &bugfarms[MI_SCREEN(mi)];
+       Display *display = MI_DISPLAY(mi);
+       Window window = MI_WINDOW(mi);
+       int         ccol, crow, compassdir;
+       GC          gc;
+
+       if (MI_NPIXELS(mi) > 3) {
+               XSetForeground(display, MI_GC(mi), MI_PIXEL(mi, color));
+               gc = MI_GC(mi);
+       } else {
+               XGCValues   gcv;
+
+               gcv.stipple = bp->pixmaps[color];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), bp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = bp->stippledGC;
+       }
+
+       grid2screen(bp, col, row, &ccol, &crow);
+       ccol = bp->xb + bp->xs * (ccol - 1);
+       crow = bp->yb + bp->ys * (crow - 1);
+       XFillRectangle(display, window, gc,
+               ccol, crow, 3 * bp->xs, 3 * bp->ys);
+
+       if (bp->eyes && bp->xs >= 1 && bp->ys >= 1) { /* Draw Eyes */
+               XSetForeground(display, MI_GC(mi), MI_BLACK_PIXEL(mi));
+               /* convert from compass direction */
+               if (bp->neighbors == 6) {
+                       direction = (420 - direction) % ANGLES;
+               } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+                       direction = (450 - direction) % ANGLES;
+               }
+               switch (direction) {
+                       case 0:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs - 2,
+                                       crow + 3 * bp->ys / 2 - 1);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs - 2,
+                                       crow + 3 * bp->ys / 2 + 1);
+                                       break;
+                       case 45:
+                       case 60:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs - 3,
+                                       crow + 1);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs - 2,
+                                       crow + 2);
+                               break;
+                       case 90:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs / 2 - 1,
+                                       crow + 1);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs / 2 + 1,
+                                       crow + 1);
+                               break;
+                       case 120:
+                       case 135:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 2,
+                                       crow + 1);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 1,
+                                               crow + 2);
+                               break;
+                       case 180:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 1,
+                                       crow + 3 * bp->ys / 2 - 1);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 1,
+                                       crow + 3 * bp->ys / 2 + 1);
+                               break;
+                       case 225:
+                       case 240:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 2,
+                                       crow + 3 * bp->ys - 2);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 1,
+                                       crow + 3 * bp->ys - 3);
+                               break;
+                       case 270:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs / 2 - 1,
+                                       crow + 3 * bp->ys - 2);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs / 2 + 1,
+                                       crow + 3 * bp->ys - 2);
+                               break;
+                       case 300:
+                       case 315:
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs - 3,
+                                       crow + 3 * bp->ys - 2);
+                               XDrawPoint(display, window, MI_GC(mi),
+                                       ccol + 3 * bp->xs - 2,
+                                       crow + 3 * bp->ys - 3);
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", direction);
+               }
+       }
+}
+
+static void
+eraseabug(ModeInfo * mi, int col, int row)
+{
+       bugfarmstruct *bp = &bugfarms[MI_SCREEN(mi)];
+       int         ccol, crow;
+
+       XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+       grid2screen(bp, col, row, &ccol, &crow);
+       XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+               bp->xb + bp->xs * (ccol - 1), bp->yb + bp->ys * (crow - 1),
+               3 * bp->xs, 3 * bp->ys);
+}
+
+static void
+init_buglist(bugfarmstruct * bp)
+{
+       /* Waste some space at the beginning and end of list
+          so we do not have to complicated checks against falling off the ends. */
+       bp->lastbug = (BugList *) malloc(sizeof (BugList));
+       bp->firstbug = (BugList *) malloc(sizeof (BugList));
+       bp->firstbug->previous = bp->lastbug->next = NULL;
+       bp->firstbug->next = bp->lastbug->previous = NULL;
+       bp->firstbug->next = bp->lastbug;
+       bp->lastbug->previous = bp->firstbug;
+
+       bp->lasttemp = (BugList *) malloc(sizeof (BugList));
+       bp->firsttemp = (BugList *) malloc(sizeof (BugList));
+       bp->firsttemp->previous = bp->lasttemp->next = NULL;
+       bp->firsttemp->next = bp->lasttemp->previous = NULL;
+       bp->firsttemp->next = bp->lasttemp;
+       bp->lasttemp->previous = bp->firsttemp;
+}
+
+static void
+addto_buglist(bugfarmstruct * bp, bugstruct info)
+{
+       bp->currbug = (BugList *) malloc(sizeof (BugList));
+       bp->lastbug->previous->next = bp->currbug;
+       bp->currbug->previous = bp->lastbug->previous;
+       bp->currbug->next = bp->lastbug;
+       bp->lastbug->previous = bp->currbug;
+       bp->currbug->info = info;
+}
+
+static void
+removefrom_buglist(bugfarmstruct * bp, BugList * ptr)
+{
+       ptr->previous->next = ptr->next;
+       ptr->next->previous = ptr->previous;
+       bp->arr[ptr->info.col + ptr->info.row * bp->ncols] = 0;
+       (void) free((void *) ptr);
+}
+
+static void
+dupin_buglist(bugfarmstruct * bp)
+{
+       BugList    *temp;
+
+       temp = (BugList *) malloc(sizeof (BugList));
+       temp->previous = bp->babybug;
+       temp->next = bp->babybug->next;
+       bp->babybug->next = temp;
+       temp->next->previous = temp;
+       temp->info = bp->babybug->info;
+       bp->babybug = temp;
+}
+
+/*-
+ * new bug at end of list, this rotates who goes first, young bugs go last
+ * this most likely will not change the feel to any real degree
+ */
+static void
+cutfrom_buglist(bugfarmstruct * bp)
+{
+       bp->babybug = bp->currbug;
+       bp->currbug = bp->currbug->previous;
+       bp->currbug->next = bp->babybug->next;
+       bp->babybug->next->previous = bp->currbug;
+       bp->babybug->next = bp->lasttemp;
+       bp->babybug->previous = bp->lasttemp->previous;
+       bp->babybug->previous->next = bp->babybug;
+       bp->babybug->next->previous = bp->babybug;
+}
+
+static void
+reattach_buglist(bugfarmstruct * bp)
+{
+       bp->currbug = bp->lastbug->previous;
+       bp->currbug->next = bp->firsttemp->next;
+       bp->currbug->next->previous = bp->currbug;
+       bp->lastbug->previous = bp->lasttemp->previous;
+       bp->lasttemp->previous->next = bp->lastbug;
+       bp->lasttemp->previous = bp->firsttemp;
+       bp->firsttemp->next = bp->lasttemp;
+}
+
+static void
+flush_buglist(bugfarmstruct * bp)
+{
+       while (bp->lastbug->previous != bp->firstbug) {
+               bp->currbug = bp->lastbug->previous;
+               bp->currbug->previous->next = bp->lastbug;
+               bp->lastbug->previous = bp->currbug->previous;
+               /*bp->arr[bp->currbug->info.col + bp->currbug->info.row * bp->ncols] = 0; */
+               (void) free((void *) bp->currbug);
+       }
+
+       while (bp->lasttemp->previous != bp->firsttemp) {
+               bp->currbug = bp->lasttemp->previous;
+               bp->currbug->previous->next = bp->lasttemp;
+               bp->lasttemp->previous = bp->currbug->previous;
+               /*bp->arr[bp->currbug->info.col + bp->currbug->info.row * bp->ncols] = 0; */
+               (void) free((void *) bp->currbug);
+       }
+}
+
+static int
+dirbug(bugstruct * info, int local_neighbors)
+{
+       double      sum = 0.0, prob;
+       int         i;
+
+       prob = (double) LRAND() / MAXRAND;
+       for (i = 0; i < local_neighbors; i++) {
+               sum += info->gene_prob[i];
+               if (prob < sum)
+                       return i;
+       }
+       return local_neighbors - 1;     /* Could miss due to rounding */
+}
+
+static void
+mutatebug(bugstruct * info, int local_neighbors)
+{
+       double      sum = 0.0;
+       int         gene;
+
+       gene = NRAND(local_neighbors);
+       if (LRAND() & 1) {
+               if (info->gene[gene] == MAXGENE)
+                       return;
+               info->gene[gene]++;
+       } else {
+               if (info->gene[gene] == MINGENE)
+                       return;
+               info->gene[gene]--;
+       }
+       for (gene = 0; gene < local_neighbors; gene++)
+               sum += genexp[info->gene[gene] + MAXGENE];
+       for (gene = 0; gene < local_neighbors; gene++)
+               info->gene_prob[gene] = genexp[info->gene[gene] + MAXGENE] / sum;
+}
+
+static void
+makebacteria(ModeInfo * mi,
+            int n, int startx, int starty, int width, int height, Bool draw)
+{
+       int         nbacteria = 0, ntries = 0, col, row, colrow;
+       bugfarmstruct *bp = &bugfarms[MI_SCREEN(mi)];
+
+       /* Make bacteria but if can not, exit */
+       while (nbacteria < n && ntries < 2 * n) {
+               row = NRAND(height) + starty;
+               if (bp->neighbors == 6) {
+                       if (width - (!(row & 1)) > 0)
+                               col = NRAND(width - (!(row & 1))) + startx;
+                       else
+                               col = startx;
+               } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+                       col = NRAND(width) + startx;
+               }
+               colrow = col + row * bp->ncols;
+               ntries++;
+               if (!bp->arr[colrow] && !bp->bacteria[colrow]) {
+                       nbacteria++;
+                       bp->bacteria[colrow] = True;
+                       drawabacterium(mi, col, row, draw);
+               }
+       }
+}
+
+static void
+redrawbacteria(ModeInfo * mi, int colrow)
+{
+       int         col, row;
+       bugfarmstruct *bp = &bugfarms[MI_SCREEN(mi)];
+
+       if (!bp->bacteria[colrow])
+               return;
+
+       row = colrow / bp->ncols;
+       col = colrow % bp->ncols;
+       drawabacterium(mi, col, row, True);
+}
+
+void
+init_bug(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         size = MI_SIZE(mi);
+       XGCValues   gcv;
+       bugfarmstruct *bp;
+       int         nbugs = 0, ntries = 0, col, row, gene, colrow, i;
+       int         nccols, ncrows;
+       double      sum;
+       bugstruct   info;
+
+       if (bugfarms == NULL) {
+               if ((bugfarms = (bugfarmstruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (bugfarmstruct))) == NULL)
+                       return;
+       }
+       bp = &bugfarms[MI_SCREEN(mi)];
+       if (MI_NPIXELS(mi) <= 3) {
+               if (bp->stippledGC == None) {
+                       gcv.fill_style = FillOpaqueStippled;
+                       bp->stippledGC = XCreateGC(display, window, GCFillStyle, &gcv);
+               }
+               if (bp->init_bits == 0) {
+                       for (i = 1; i < NUMSTIPPLES; i++)
+                               BUGBITS(stipples[i], STIPPLESIZE, STIPPLESIZE);
+               }
+       }
+       bp->generation = 0;
+       if (!bp->firstbug) {    /* Genesis */
+               /* Set up what will be a 'triply' linked list.
+                  doubly linked list, doubly linked to an array */
+               init_buglist(bp);
+               genexp[MAXGENE] = 1;
+               for (i = 1; i <= MAXGENE; i++) {
+                       genexp[MAXGENE + i] = genexp[MAXGENE + i - 1] * M_E;
+                       genexp[MAXGENE - i] = 1.0 / genexp[MAXGENE + i];
+               }
+       } else                  /* Apocolypse now */
+               flush_buglist(bp);
+
+       for (i = 0; i < NEIGHBORKINDS; i++) {
+               if (neighbors == plots[i]) {
+                       bp->neighbors = plots[i];
+                       break;
+               }
+               if (i == NEIGHBORKINDS - 1) {
+                       bp->neighbors = plots[NRAND(NEIGHBORKINDS)];
+                       break;
+               }
+       }
+
+       bp->width = MI_WIDTH(mi);
+       bp->height = MI_HEIGHT(mi);
+       if (bp->width < 4)
+               bp->width = 4;
+       if (bp->height < 4)
+               bp->height = 4;
+
+       if (size < -MINSIZE)
+               bp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(bp->width, bp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE) {
+               if (!size)
+                       bp->ys = MAX(MINSIZE, MIN(bp->width, bp->height) / MINGRIDSIZE);
+               else
+                       bp->ys = MINSIZE;
+       } else
+               bp->ys = MIN(size, MAX(MINSIZE, MIN(bp->width, bp->height) /
+                                      MINGRIDSIZE));
+       bp->xs = bp->ys;
+       nccols = MAX(bp->width / bp->xs - 2, 2);
+       ncrows = MAX(bp->height / bp->ys - 1, 2);
+       bp->ncols = nccols / 2;
+       bp->nrows = ncrows / 2;
+       if (bp->neighbors == 6 && !(bp->nrows & 1))
+               bp->nrows--;    /* Must be odd for no wrap */
+       bp->xb = (bp->width - bp->xs * nccols) / 2;
+       bp->yb = (bp->height - bp->ys * ncrows) / 2;
+       if (bp->arr != NULL)
+               (void) free((void *) bp->arr);
+       bp->arr = (BugList **) calloc(bp->ncols * bp->nrows, sizeof (BugList *));
+       if (bp->bacteria != NULL)
+               (void) free((void *) bp->bacteria);
+       bp->bacteria = (char *) calloc(bp->ncols * bp->nrows, sizeof (char));
+
+       bp->edenwidth = bp->ncols / 4;
+       bp->edenheight = bp->nrows / 4;
+       if (bp->neighbors == 6 && bp->edenheight && !(bp->edenheight & 1))
+               bp->edenheight--;       /* Make sure its odd */
+       bp->eden = (bp->edenwidth > 1 && bp->edenheight > 1);
+       if (bp->eden) {
+               bp->edenstartx = NRAND(bp->ncols - bp->edenwidth);
+               bp->edenstarty = NRAND(bp->nrows - bp->edenheight);
+               if (bp->neighbors == 6 && (bp->edenstarty & 1)) {
+                       bp->edenstarty--;
+                       bp->eden = (bp->edenheight > 1);
+               }
+       }
+       /* Play G-d with these numbers... the genes */
+       nbugs = MI_COUNT(mi);
+       if (nbugs < 0)
+               nbugs = NRAND(-nbugs) + 1;
+       bp->nbugs = 0;
+
+       MI_CLEARWINDOW(mi);
+       bp->painted = False;
+
+       if (MI_IS_FULLRANDOM(mi)) {
+                bp->eyes = (Bool) (LRAND() & 1);
+        } else {
+                bp->eyes = eyes;
+        }
+        bp->eyes = (bp->eyes && bp->xs > 1 && bp->ys > 1);
+
+       /* Try to make bugs, but if can not, exit */
+       while (bp->nbugs < nbugs && ntries < 2 * nbugs) {
+               row = NRAND(bp->nrows);
+               if (bp->neighbors == 6) {
+                       if (bp->ncols - (!(row & 1)) > 0)
+                               col = NRAND(bp->ncols - (!(row & 1)));
+                       else
+                               col = 0;
+               } else if (bp->neighbors == 4 || bp->neighbors == 8) {
+                       col = NRAND(bp->ncols);
+               }
+               colrow = col + row * bp->ncols;
+               ntries++;
+               if (!bp->arr[colrow] && !has_neighbor(bp, col, row)) {
+                       bp->nbugs++;
+                       info.age = 0;
+                       info.energy = INITENERGY;
+                       info.direction = NRAND(bp->neighbors);
+                       for (gene = 0; gene < bp->neighbors; gene++)
+#if 0                          /* Some creationalism, may create gliders or twirlers */
+                               do {
+                                       double      temp = (double) LRAND() / MAXRAND;
+
+                                       info.gene[gene] = ((int) (1.0 / (1.0 - temp * temp)) - 1) *
+                                               ((LRAND() & 1) ? -1 : 1);
+                               } while (info.gene[gene] > MAXGENE / 2 ||
+                                        info.gene[gene] < MINGENE / 2);
+#else /* Jitterbugs, evolve or die */
+                               info.gene[gene] = 0;
+#endif
+                       sum = 0;
+                       for (gene = 0; gene < bp->neighbors; gene++)
+                               sum += genexp[info.gene[gene] + MAXGENE];
+                       for (gene = 0; gene < bp->neighbors; gene++)
+                               info.gene_prob[gene] = genexp[info.gene[gene] + MAXGENE] / sum;
+                       if (MI_NPIXELS(mi) > 3)
+                               info.color = NRAND(MI_NPIXELS(mi));
+                       else
+                               info.color = NRAND(NUMSTIPPLES - 1);
+                       info.col = col;
+                       info.row = row;
+                       addto_buglist(bp, info);
+                       bp->arr[colrow] = bp->currbug;
+                       drawabug(mi, col, row, bp->currbug->info.color, (int) bp->currbug->info.direction * ANGLES / bp->neighbors);
+               }
+       }
+       makebacteria(mi, bp->ncols * bp->nrows / 2, 0, 0, bp->ncols, bp->nrows,
+                    False);
+       if (bp->eden)
+               makebacteria(mi, bp->edenwidth * bp->edenheight / 2,
+               bp->edenstartx, bp->edenstarty, bp->edenwidth, bp->edenheight,
+                            False);
+       bp->redrawing = 1;
+       bp->redrawpos = 0;
+}
+
+#define ENOUGH 16
+void
+draw_bug(ModeInfo * mi)
+{
+       bugfarmstruct *bp = &bugfarms[MI_SCREEN(mi)];
+       int         col, row, ncol, nrow, colrow, ncolrow, absdir, tryit;
+
+       MI_IS_DRAWN(mi) = True;
+
+       bp->painted = True;
+       bp->currbug = bp->firstbug->next;
+       while (bp->currbug != bp->lastbug) {
+               col = bp->currbug->info.col;
+               row = bp->currbug->info.row;
+               colrow = col + row * bp->ncols;
+               if (bp->currbug->info.energy-- < 0) {   /* Time to die, Bug */
+#if DEBUG
+                       assert(bp->currbug == bp->arr[colrow]);
+#endif
+                       /* back up one or else in void */
+                       bp->currbug = bp->currbug->previous;
+                       removefrom_buglist(bp, bp->arr[colrow]);
+#if DEBUG
+                       assert(bp->arr[colrow] == 0);
+#endif
+                       bp->arr[colrow] = 0;
+                       eraseabug(mi, col, row);
+                       bp->nbugs--;
+               } else {        /* try to move */
+                       bp->arr[colrow] = 0;    /* Don't want neighbor to detect itself */
+                       tryit = 0;
+                       do {
+                               if (tryit++ > ENOUGH) {
+                                       break;
+                               }
+                               absdir = (bp->currbug->info.direction +
+                                         dirbug(&bp->currbug->info, bp->neighbors)) % bp->neighbors;
+                       } while (!compassmove(bp, col, row, absdir * ANGLES / bp->neighbors,
+                         &ncol, &nrow) || has_neighbor(bp, ncol, nrow) ||
+                         bp->arr[ncol + nrow * bp->ncols]);
+                       bp->currbug->info.age++;
+                       bp->currbug->info.energy--;
+                       if (tryit <= ENOUGH) {
+                               ncolrow = ncol + nrow * bp->ncols;
+                               if (bp->bacteria[ncolrow]) {
+                                       bp->currbug->info.energy += BACTERIAENERGY;
+                                       bp->bacteria[ncolrow] = 0;
+                                       if (bp->currbug->info.energy > MAXENERGY)
+                                               bp->currbug->info.energy = MAXENERGY;
+                               }
+                               bp->currbug->info.col = ncol;
+                               bp->currbug->info.row = nrow;
+                               bp->currbug->info.direction = absdir;
+#if DEBUG
+                               assert(bp->arr[ncolrow] == 0);
+#endif
+                               bp->arr[ncolrow] = bp->currbug;
+                               if (bp->currbug->info.energy > STRONG &&
+                                   bp->currbug->info.age > MATURE) {   /* breed */
+                                       drawabug(mi, ncol, nrow, bp->currbug->info.color, (int) bp->currbug->info.direction * ANGLES / bp->neighbors);
+                                       cutfrom_buglist(bp);    /* This rotates out who goes first */
+                                       bp->babybug->info.age = 0;
+                                       bp->babybug->info.energy = INITENERGY;
+                                       dupin_buglist(bp);
+                                       mutatebug(&bp->babybug->previous->info, bp->neighbors);
+                                       mutatebug(&bp->babybug->info, bp->neighbors);
+                                       bp->arr[colrow] = bp->babybug;
+                                       bp->babybug->info.col = col;
+                                       bp->babybug->info.row = row;
+                                       bp->nbugs++;
+                               } else {
+                                       eraseabug(mi, col, row);
+                                       drawabug(mi, ncol, nrow, bp->currbug->info.color, (int) bp->currbug->info.direction * ANGLES / bp->neighbors);
+                               }
+                       } else
+                               bp->arr[colrow] = bp->currbug;
+               }
+               bp->currbug = bp->currbug->next;
+       }
+       reattach_buglist(bp);
+       makebacteria(mi, FOODPERCYCLE, 0, 0, bp->ncols, bp->nrows, True);
+       if (bp->eden)
+               makebacteria(mi, FOODPERCYCLE,
+                            bp->edenstartx, bp->edenstarty, bp->edenwidth, bp->edenheight, True);
+       if (!bp->nbugs || bp->generation >= MI_CYCLES(mi))
+               init_bug(mi);
+       bp->generation++;
+       if (bp->redrawing) {
+               int         i;
+
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       if (bp->bacteria[bp->redrawpos])
+                               redrawbacteria(mi, bp->redrawpos);
+                       if (++(bp->redrawpos) >= bp->ncols * bp->nrows) {
+                               bp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+void
+release_bug(ModeInfo * mi)
+{
+       if (bugfarms != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       bugfarmstruct *bp = &bugfarms[screen];
+                       int         shade;
+
+                       if (bp->stippledGC != None) {
+                               XFreeGC(MI_DISPLAY(mi), bp->stippledGC);
+                       }
+                       for (shade = 0; shade < bp->init_bits; shade++) {
+                               if (bp->pixmaps[shade])
+                                       XFreePixmap(MI_DISPLAY(mi), bp->pixmaps[shade]);
+                       }
+                       if (bp->firstbug)
+                               flush_buglist(bp);
+                       (void) free((void *) bp->lastbug);
+                       (void) free((void *) bp->firstbug);
+                       (void) free((void *) bp->lasttemp);
+                       (void) free((void *) bp->firsttemp);
+                       if (bp->arr != NULL)
+                               (void) free((void *) bp->arr);
+                       if (bp->bacteria != NULL)
+                               (void) free((void *) bp->bacteria);
+               }
+               (void) free((void *) bugfarms);
+               bugfarms = NULL;
+       }
+}
+
+void
+refresh_bug(ModeInfo * mi)
+{
+       bugfarmstruct *bp = &bugfarms[MI_SCREEN(mi)];
+
+       if (bp->painted) {
+               MI_CLEARWINDOW(mi);
+               bp->painted = False;
+               bp->redrawing = 1;
+               bp->redrawpos = 0;
+       }
+}
+
+#endif /* MODE_bug */
diff --git a/xlockmore-4.14/modes/cartoon.c b/xlockmore-4.14/modes/cartoon.c
new file mode 100644 (file)
index 0000000..7ee2762
--- /dev/null
@@ -0,0 +1,408 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* cartoon --- bouncing cartoons */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)cartoon.c    4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1988 by Sun Microsystems
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ *
+ * 10-May-97: Compatible with xscreensaver
+ * 14-Oct-96: <dhansen@metapath.com>
+ *            Updated the equations for mapping the charater
+ *            to follow a parabolic time curve.  Also adjust
+ *            the rate based on the size (area) of the cartoon.
+ *            Eliminated unused variables carried over from bounce.c
+ *            Still needs a user attribute to control the rate
+ *            depending on their computer and preference.
+ * 20-Sep-94: I done this file starting from the previous bounce.c
+ *            I draw the 8 cartoons like they are.
+ *            Lorenzo Patocchi <patol@info.isbiel.ch>
+ *            David monkeyed around with the cmap stuff to get it to work.
+ * 2-Sep-93: xlock version David Bagley <bagleyd@tux.org>
+ * 1986: Sun Microsystems
+ */
+
+/*-
+ * original copyright
+ * **************************************************************************
+ * Copyright 1988 by Sun Microsystems, Inc. Mountain View, CA.
+ *
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the names of Sun or MIT not be used in advertising
+ * or publicity pertaining to distribution of the software without specific
+ * prior written permission. Sun and M.I.T. make no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
+ * without any express or implied warranty.
+ *
+ * SUN DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ * IN NO EVENT SHALL SUN BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
+ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
+ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
+ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+ * SOFTWARE.
+ * ***************************************************************************
+ */
+
+/*-
+-visual DirectColor may yield
+X Error of failed request:  BadMatch (invalid parameter attributes)
+ Major opcode of failed request:  2 (X_ChangeWindowAttributes)
+puzzle.c has the same disease.  
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Cartoon"
+#define HACK_INIT init_cartoon
+#define HACK_DRAW draw_cartoon
+#define cartoon_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "vis.h"
+#include "color.h"
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_cartoon
+
+ModeSpecOpt cartoon_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   cartoon_description =
+{"cartoon", "init_cartoon", "draw_cartoon", "release_cartoon",
+ NULL, "init_cartoon", NULL, &cartoon_opts,
+ 10000, 1, 1, 1, 64, 1.0, "",
+ "Shows bouncing cartoons", 0, NULL};
+
+#endif
+
+/* Yes, it does not have to be done again but you could override the above... */
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+
+#if USE_XPMINC
+#include <xpm.h>
+#else
+#include <X11/xpm.h>           /* Normal spot */
+#endif
+
+#include "pixmaps/calvin2.xpm"
+#include "pixmaps/gravity.xpm"
+#include "pixmaps/calvin4.xpm"
+#include "pixmaps/calvinf.xpm"
+#include "pixmaps/hobbes.xpm"
+#include "pixmaps/calvin.xpm"
+#include "pixmaps/marino2.xpm"
+#include "pixmaps/calvin3.xpm"
+#include "pixmaps/garfield.xpm"
+#ifdef ALL_CARTOONS            /* Some of these gave me trouble on some systems */
+#include "pixmaps/dragon.xpm"
+#include "pixmaps/cal_hob.xpm"
+#define NUM_CARTOONS    11
+#else
+#define NUM_CARTOONS    9
+#endif
+#else
+#define NUM_CARTOONS    0      /* Not much point... */
+#endif
+
+#define MAX_X_STRENGTH  8
+#define MAX_Y_STRENGTH  3
+
+static char **cartoonlist[NUM_CARTOONS] =
+{
+#if NUM_CARTOONS
+       calvin2, gravity, calvin4, calvinf, hobbes,
+       calvin, marino2, calvin3, garfield
+#ifdef ALL_CARTOONS
+       ,dragon, cal_hob
+#endif
+#endif
+};
+
+typedef struct {
+       int         x, y, xlast, ylast;
+       int         vx, vy, tbx, tby;
+       int         ytime, ybase;
+       double      yrate;
+       int         width, height;
+       GC          backGC;
+       XImage     *image;
+       int         success;
+       int         choice;
+       Colormap    cmap;
+       unsigned long black;
+} cartoonstruct;
+
+static cartoonstruct *cartoons = NULL;
+
+static void erase_image(Display * display, Window win, GC gc,
+                       int x, int y, int xl, int yl, int xsize, int ysize);
+
+static void
+free_stuff(Display * display, cartoonstruct * cp)
+{
+       if (cp->image) {
+               (void) XDestroyImage(cp->image);
+               cp->image = None;
+       }
+       if (cp->cmap != None) {
+               XFreeColormap(display, cp->cmap);
+               if (cp->backGC != None) {
+                       XFreeGC(display, cp->backGC);
+                       cp->backGC = None;
+               }
+               cp->cmap = None;
+       } else
+               cp->backGC = None;
+}
+
+static void
+initimage(ModeInfo * mi, int cartoon)
+{
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       cartoonstruct *cp = &cartoons[MI_SCREEN(mi)];
+       XpmAttributes attrib;
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       free_stuff(display, cp);
+
+#ifndef STANDALONE
+       if (!fixedColors(mi)) {
+               cp->cmap = XCreateColormap(display, window, MI_VISUAL(mi), AllocNone);
+               attrib.colormap = cp->cmap;
+               reserveColors(mi, cp->cmap, &cp->black);
+       } else
+#endif /* !STANDALONE */
+               attrib.colormap = MI_COLORMAP(mi);
+
+       attrib.visual = MI_VISUAL(mi);
+       attrib.depth = MI_DEPTH(mi);
+       attrib.valuemask = XpmVisual | XpmColormap | XpmDepth;
+
+       /* if (MI_NPIXELS(mi) > 2) *//* Does not look too bad in monochrome */
+       cp->success = (XpmSuccess == XpmCreateImageFromData(
+                                                                  display, cartoonlist[cartoon], &cp->image, (XImage **) NULL, &attrib));
+#endif
+       if (MI_IS_VERBOSE(mi))
+               (void) fprintf(stderr, "Color image %d%s loaded.\n",
+                              cartoon, (cp->success) ? "" : " could not be");
+#ifndef STANDALONE
+       if (cp->cmap != None) {
+               setColormap(display, window, cp->cmap, MI_IS_INWINDOW(mi));
+               if (cp->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = cp->black;
+                       cp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else
+#endif /* !STANDALONE */
+       {
+               cp->black = MI_BLACK_PIXEL(mi);
+               cp->backGC = MI_GC(mi);
+       }
+}
+
+static void
+put_cartoon(ModeInfo * mi)
+{
+       cartoonstruct *cp = &cartoons[MI_SCREEN(mi)];
+
+/* PURIFY 4.0.1 on SunOS4 and on Solaris 2 reports a 29756 byte memory leak on
+   * the next line. */
+       (void) XPutImage(MI_DISPLAY(mi), MI_WINDOW(mi), cp->backGC,
+                        cp->image, 0, 0,
+                        cp->x - cp->tbx, cp->y - cp->tby,
+                        cp->image->width, cp->image->height);
+       if (cp->xlast != -1) {
+               erase_image(MI_DISPLAY(mi), MI_WINDOW(mi), cp->backGC,
+                           cp->x - cp->tbx, cp->y - cp->tby,
+                           cp->xlast, cp->ylast,
+                           cp->image->width, cp->image->height);
+       }
+}                              /* put_cartoon */
+
+static void
+select_cartoon(ModeInfo * mi)
+{
+#if ( NUM_CARTOONS <= 0 )
+       return;
+#else
+       cartoonstruct *cp = &cartoons[MI_SCREEN(mi)];
+
+#if ( NUM_CARTOONS > 1 )
+       int         old;
+
+       old = cp->choice;
+       while (old == cp->choice)
+               cp->choice = NRAND(NUM_CARTOONS);
+       if (MI_IS_DEBUG(mi))
+               (void) fprintf(stderr, "cartoon %d.\n", cp->choice);
+       initimage(mi, cp->choice);
+#else /* Probably will never be used but ... */
+       cp->choice = 0;
+       if (MI_IS_DEBUG(mi))
+               (void) fprintf(stderr, "cartoon %d.\n", cp->choice);
+       if (!cp->success)
+               initimage(mi, cp->choice);
+#endif
+#endif
+}                              /* select_cartoon */
+
+/* This stops some flashing, could be more efficient */
+static void
+erase_image(Display * display, Window win, GC gc,
+           int x, int y, int xl, int yl, int xsize, int ysize)
+{
+       if (y < 0)
+               y = 0;
+       if (x < 0)
+               x = 0;
+       if (xl < 0)
+               xl = 0;
+       if (yl < 0)
+               yl = 0;
+
+       if (xl - x > 0)
+               XFillRectangle(display, win, gc, x + xsize, yl, xl - x, ysize);
+       if (yl - y > 0)
+               XFillRectangle(display, win, gc, xl, y + ysize, xsize, yl - y);
+       if (y - yl > 0)
+               XFillRectangle(display, win, gc, xl, yl, xsize, y - yl);
+       if (x - xl > 0)
+               XFillRectangle(display, win, gc, xl, yl, x - xl, ysize);
+}                              /* erase_image */
+
+void
+init_cartoon(ModeInfo * mi)
+{
+       cartoonstruct *cp;
+       int         i;
+
+       if (cartoons == NULL) {
+               if ((cartoons = (cartoonstruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (cartoonstruct))) == NULL)
+                       return;
+       }
+       cp = &cartoons[MI_SCREEN(mi)];
+
+       if (!cp->success) {
+               cp->choice = -1;
+
+       }
+       cp->width = MI_WIDTH(mi);
+       cp->height = MI_HEIGHT(mi);
+
+       select_cartoon(mi);
+
+       if (cp->success) {
+               cp->vx = ((LRAND() & 1) ? -1 : 1) * NRAND(MAX_X_STRENGTH);
+
+               cp->x = (cp->vx >= 0) ? 0 : cp->width - cp->image->width;
+
+               cp->y = cp->height + cp->image->height;
+               cp->ytime = 0;
+               i = 100000 / (cp->image->width * cp->image->height);
+               cp->yrate = (1.0 + NRAND(MAX_Y_STRENGTH)) * ((double) i * i) / 4.0;
+               cp->ybase = (int) sqrt(((3 * cp->y / 4) +
+                                       (NRAND(cp->y / 4))) * 2 / cp->yrate);
+
+               cp->xlast = -1;
+               cp->ylast = 0;
+
+       }
+       MI_CLEARWINDOWCOLORMAP(mi, cp->backGC, cp->black);
+}                              /* init_cartoon */
+
+static void
+move_cartoon(ModeInfo * mi)
+{
+       cartoonstruct *cp = &cartoons[MI_SCREEN(mi)];
+
+       cp->xlast = cp->x - cp->tbx;
+       cp->ylast = cp->y - cp->tby;
+
+       cp->x += cp->vx;
+       if ((cp->width > cp->image->width && cp->x > cp->width - cp->image->width) ||
+           (cp->width < cp->image->width && cp->x < 0)) {
+               /* Bounce off the right edge */
+               cp->x = 2 * (cp->width - cp->image->width) - cp->x;
+               cp->vx = -cp->vx;
+       } else if ((cp->width < cp->image->width &&
+                   cp->x > cp->width - cp->image->width) ||
+                  (cp->width > cp->image->width && cp->x < 0)) {
+               /* Bounce off the left edge */
+               cp->x = -cp->x;
+               cp->vx = -cp->vx;
+       }
+       cp->ytime++;
+
+       cp->y += (int) ((cp->ytime / cp->yrate) - cp->ybase);
+
+
+       if (cp->y >= (cp->height + cp->image->height)) {
+               /* Back at the bottom edge, time for a new cartoon */
+               init_cartoon(mi);
+       }
+}                              /* move_cartoon */
+
+void
+draw_cartoon(ModeInfo * mi)
+{
+       cartoonstruct *cp = &cartoons[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (cp->success) {
+               put_cartoon(mi);
+               move_cartoon(mi);
+       } else
+               init_cartoon(mi);
+}                              /* draw_cartoon */
+
+void
+release_cartoon(ModeInfo * mi)
+{
+       if (cartoons != NULL) {
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       cartoonstruct *cp = &cartoons[screen];
+
+                       free_stuff(MI_DISPLAY(mi), cp);
+               }
+#endif
+               (void) free((void *) cartoons);
+               cartoons = NULL;
+       }
+}                              /* release_cartoon */
+
+#endif /* MODE_cartoon */
diff --git a/xlockmore-4.14/modes/clock.c b/xlockmore-4.14/modes/clock.c
new file mode 100644 (file)
index 0000000..c555af1
--- /dev/null
@@ -0,0 +1,460 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* clock --- displays an analog clock */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)clock.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by Jeremie PETIT <petit@aurora.unice.fr>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The design was highly inspirated from 'oclock' but not the code,
+ * which is all mine.
+ * 
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 24-Dec-95: Ron Hitchens <ron@idiom.com> cycles range and defaults
+ *            changed.
+ * 01-Dec-95: Clock size changes each time it is displayed.
+ * 01-Jun-95: Written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Clock"
+#define HACK_INIT init_clock
+#define HACK_DRAW draw_clock
+#define clock_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: -16 \n" \
+ "*cycles: 200 \n" \
+ "*size: -200 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_clock
+
+ModeSpecOpt clock_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   clock_description =
+{"clock", "init_clock", "draw_clock", "release_clock",
+ "refresh_clock", "init_clock", NULL, &clock_opts,
+ 100000, -16, 200, -200, 64, 1.0, "",
+ "Shows Packard's clock", 0, NULL};
+
+#endif
+
+#ifdef TM_IN_SYS_TIME
+#include <sys/time.h>
+#else
+#include <time.h>
+#endif
+
+#define MIN_CYCLES     50      /* shortest possible time before moving the clock */
+#define MAX_CYCLES   1000      /* longest possible time before moving the clock */
+#define CLOCK_BORDER    9      /* Percentage of the clock size for the border */
+#define HOURS_SIZE     50      /* Percentage of the clock size for hours length */
+#define MINUTES_SIZE   75      /* Idem for minutes */
+#define SECONDS_SIZE   80      /* Idem for seconds */
+#define HOURS_WIDTH    10      /* Percentage of the clock size for hours width */
+#define MINUTES_WIDTH   5      /* Idem for minutes */
+#define SECONDS_WIDTH   2      /* Idem for seconds */
+#define JEWEL_POSITION 90      /* The relative position of the jewel */
+#define JEWEL_SIZE      9      /* The relative size of the jewel */
+#define MINCLOCKS       1
+#define MINSIZE        16      /* size, minimum */
+
+typedef struct {
+       int         size;       /* length of the hand */
+       int         width;      /* width of the hand */
+       unsigned long color;    /* color of the hand */
+} hand;
+
+typedef struct {
+       hand        hours;      /* the hours hand */
+       hand        minutes;    /* the minutes hand */
+       hand        seconds;    /* the seconds hand */
+       XPoint      pos;
+       int         size;
+       int         radius;
+       int         boxsize;
+       int         jewel_size;
+       int         jewel_position;
+       int         border_width;
+       unsigned long border_color;
+       unsigned long jewel_color;
+       struct tm   dd_time;
+} oclock;
+
+typedef struct {
+       oclock     *oclocks;
+       time_t      d_time;
+       int         clock_count;
+       int         width, height;
+       int         nclocks;
+       int         currentclocks;
+       int         redrawing;
+} clockstruct;
+
+static clockstruct *clocks = NULL;
+
+static int
+myrand(int minimum, int maximum)
+{
+       return ((int) (minimum + (LRAND() / MAXRAND) * (maximum + 1 - minimum)));
+}
+
+static double
+HourToAngle(oclock * oclockp)
+{
+       return ((M_PI * ((double) oclockp->dd_time.tm_hour +
+                        ((double) oclockp->dd_time.tm_min / 60) +
+                  ((double) oclockp->dd_time.tm_sec / 3600))) / 6 - M_PI_2);
+}
+
+static double
+MinutesToAngle(oclock * oclockp)
+{
+       return ((M_PI * ((double) oclockp->dd_time.tm_min +
+                   ((double) oclockp->dd_time.tm_sec / 60))) / 30 - M_PI_2);
+}
+
+static double
+SecondsToAngle(oclock * oclockp)
+{
+       return ((M_PI * ((double) oclockp->dd_time.tm_sec) / 30) - M_PI_2);
+}
+
+static void
+DrawDisk(Display * display, Window window, GC gc,
+        int center_x, int center_y, int diameter)
+{
+       int         radius = diameter / 2;
+
+       if (diameter > 1)
+               XFillArc(display, window, gc,
+                        center_x - radius, center_y - radius,
+                        diameter, diameter,
+                        0, 23040);
+       else
+               XDrawPoint(display, window, gc, center_x, center_y);
+}
+
+static void
+DrawBorder(ModeInfo * mi, int clck, short int mode)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+
+
+       if (mode == 0)
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       else
+               XSetForeground(display, gc, cp->oclocks[clck].border_color);
+
+       XSetLineAttributes(display, gc, cp->oclocks[clck].border_width,
+                          LineSolid, CapNotLast, JoinMiter);
+       XDrawArc(display, MI_WINDOW(mi), gc,
+                cp->oclocks[clck].pos.x - cp->oclocks[clck].size / 2,
+                cp->oclocks[clck].pos.y - cp->oclocks[clck].size / 2,
+                cp->oclocks[clck].size, cp->oclocks[clck].size,
+                0, 23040);
+}
+
+static void
+DrawJewel(ModeInfo * mi, int clck, short int mode)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+
+       XSetLineAttributes(display, gc, 1, LineSolid, CapNotLast, JoinMiter);
+       if (mode == 0)
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       else
+               XSetForeground(display, gc, cp->oclocks[clck].jewel_color);
+       DrawDisk(display, MI_WINDOW(mi), gc,
+                cp->oclocks[clck].pos.x,
+                cp->oclocks[clck].pos.y - cp->oclocks[clck].jewel_position,
+                cp->oclocks[clck].jewel_size);
+}
+
+static void
+DrawHand(ModeInfo * mi, int clck, hand * h, double angle, short int mode)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+       int         cosi, sinj;
+
+       /* mode: 0 for erasing, anything else for drawing */
+       if (mode == 0)
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       else
+               XSetForeground(display, gc, h->color);
+       XSetLineAttributes(display, gc, h->width, LineSolid, CapNotLast, JoinMiter);
+       DrawDisk(display, window, gc,
+                cp->oclocks[clck].pos.x, cp->oclocks[clck].pos.y, h->width);
+       cosi = (int) (cos(angle) * (double) (h->size));
+       sinj = (int) (sin(angle) * (double) (h->size));
+       XDrawLine(display, window, gc,
+                 cp->oclocks[clck].pos.x, cp->oclocks[clck].pos.y,
+            cp->oclocks[clck].pos.x + cosi, cp->oclocks[clck].pos.y + sinj);
+       DrawDisk(display, window, gc,
+             cp->oclocks[clck].pos.x + cosi, cp->oclocks[clck].pos.y + sinj,
+                h->width);
+}
+
+static void
+real_draw_clock(ModeInfo * mi, int clck, short int mode)
+{
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+
+       DrawBorder(mi, clck, mode);
+       DrawJewel(mi, clck, mode);
+       DrawHand(mi, clck, &cp->oclocks[clck].hours,
+                HourToAngle(&cp->oclocks[clck]), mode);
+       DrawHand(mi, clck, &cp->oclocks[clck].minutes,
+                MinutesToAngle(&cp->oclocks[clck]), mode);
+       DrawHand(mi, clck, &cp->oclocks[clck].seconds,
+                SecondsToAngle(&cp->oclocks[clck]), mode);
+}
+
+static int
+collide(clockstruct * cp, int clck)
+{
+       int         i, d, x, y;
+
+       for (i = 0; i < clck; i++) {
+               x = (cp->oclocks[i].pos.x - cp->oclocks[clck].pos.x);
+               y = (cp->oclocks[i].pos.y - cp->oclocks[clck].pos.y);
+               d = (int) sqrt((double) (x * x + y * y));
+               if (d < (cp->oclocks[i].size + cp->oclocks[i].border_width +
+               cp->oclocks[clck].size + cp->oclocks[clck].border_width) / 2)
+                       return i;
+       }
+       return clck;
+}
+
+static int
+new_clock_state(ModeInfo * mi, int clck)
+{
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+       int         size = MI_SIZE(mi);
+       int         tryit;
+
+       for (tryit = 0; tryit < 8; tryit++) {
+               /* We change the clock size */
+               if (size < -MINSIZE)
+                       cp->oclocks[clck].size = NRAND(MIN(-size, MAX(MINSIZE,
+                       MIN(cp->width, cp->height))) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               cp->oclocks[clck].size = MAX(MINSIZE, MIN(cp->width, cp->height));
+                       else
+                               cp->oclocks[clck].size = MINSIZE;
+               } else
+                       cp->oclocks[clck].size = MIN(size, MAX(MINSIZE,
+                                               MIN(cp->width, cp->height)));
+
+               /* We must compute new attributes for the clock because its size changes */
+               cp->oclocks[clck].hours.size = (cp->oclocks[clck].size * HOURS_SIZE) / 200;
+               cp->oclocks[clck].minutes.size =
+                       (cp->oclocks[clck].size * MINUTES_SIZE) / 200;
+               cp->oclocks[clck].seconds.size =
+                       (cp->oclocks[clck].size * SECONDS_SIZE) / 200;
+               cp->oclocks[clck].jewel_size = (cp->oclocks[clck].size * JEWEL_SIZE) / 200;
+
+               cp->oclocks[clck].border_width =
+                       (cp->oclocks[clck].size * CLOCK_BORDER) / 200;
+               cp->oclocks[clck].hours.width = (cp->oclocks[clck].size * HOURS_WIDTH) / 200;
+               cp->oclocks[clck].minutes.width =
+                       (cp->oclocks[clck].size * MINUTES_WIDTH) / 200;
+               cp->oclocks[clck].seconds.width =
+                       (cp->oclocks[clck].size * SECONDS_WIDTH) / 200;
+
+               cp->oclocks[clck].jewel_position =
+                       (cp->oclocks[clck].size * JEWEL_POSITION) / 200;
+
+               cp->oclocks[clck].radius =
+                       (cp->oclocks[clck].size / 2) + cp->oclocks[clck].border_width + 1;
+
+               /* Here we set new values for the next clock to be displayed */
+               if (MI_NPIXELS(mi) > 2) {
+                       /* New colors */
+                       cp->oclocks[clck].border_color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       cp->oclocks[clck].jewel_color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       cp->oclocks[clck].hours.color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       cp->oclocks[clck].minutes.color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       cp->oclocks[clck].seconds.color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+               }
+               /* A new position for the clock */
+               cp->oclocks[clck].pos.x = myrand(cp->oclocks[clck].radius,
+                                      cp->width - cp->oclocks[clck].radius);
+               cp->oclocks[clck].pos.y = myrand(cp->oclocks[clck].radius,
+                                     cp->height - cp->oclocks[clck].radius);
+               if (clck == collide(cp, clck))
+                       return True;
+       }
+       cp->currentclocks = clck;
+       return False;
+}
+
+static void
+update_clock(ModeInfo * mi, int clck)
+{
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+
+       DrawHand(mi, clck, &cp->oclocks[clck].hours,
+                HourToAngle(&cp->oclocks[clck]), 0);
+       DrawHand(mi, clck, &cp->oclocks[clck].minutes,
+                MinutesToAngle(&cp->oclocks[clck]), 0);
+       DrawHand(mi, clck, &cp->oclocks[clck].seconds,
+                SecondsToAngle(&cp->oclocks[clck]), 0);
+       cp->d_time = time((time_t *) 0);
+       (void) memcpy((char *) &cp->oclocks[clck].dd_time,
+                     (char *) localtime(&cp->d_time),
+                     sizeof (cp->oclocks[clck].dd_time));
+       DrawHand(mi, clck, &cp->oclocks[clck].hours,
+                HourToAngle(&cp->oclocks[clck]), 1);
+       DrawHand(mi, clck, &cp->oclocks[clck].minutes,
+                MinutesToAngle(&cp->oclocks[clck]), 1);
+       DrawHand(mi, clck, &cp->oclocks[clck].seconds,
+                SecondsToAngle(&cp->oclocks[clck]), 1);
+}
+
+void
+init_clock(ModeInfo * mi)
+{
+       clockstruct *cp;
+       int         clck;
+
+       if (clocks == NULL) {
+               if ((clocks = (clockstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (clockstruct))) == NULL)
+                       return;
+       }
+       cp = &clocks[MI_SCREEN(mi)];
+
+
+       cp->redrawing = 0;
+       cp->width = MI_WIDTH(mi);
+       cp->height = MI_HEIGHT(mi);
+
+       MI_CLEARWINDOW(mi);
+
+       cp->nclocks = MI_COUNT(mi);
+       if (cp->nclocks < -MINCLOCKS) {
+               /* if cp->nclocks is random ... the size can change */
+               if (cp->oclocks != NULL) {
+                       (void) free((void *) cp->oclocks);
+                       cp->oclocks = NULL;
+               }
+               cp->nclocks = NRAND(-cp->nclocks - MINCLOCKS + 1) + MINCLOCKS;
+       } else if (cp->nclocks < MINCLOCKS)
+               cp->nclocks = MINCLOCKS;
+       if (cp->oclocks == NULL)
+               cp->oclocks = (oclock *) malloc(cp->nclocks * sizeof (oclock));
+
+       cp->clock_count = MI_CYCLES(mi);
+       if (cp->clock_count < MIN_CYCLES)
+               cp->clock_count = MIN_CYCLES;
+       if (cp->clock_count > MAX_CYCLES)
+               cp->clock_count = MAX_CYCLES;
+
+       for (clck = 0; clck < cp->nclocks; clck++) {
+               /* By default, we set the clock's colors to white */
+               cp->oclocks[clck].border_color = MI_WHITE_PIXEL(mi);
+               cp->oclocks[clck].jewel_color = MI_WHITE_PIXEL(mi);
+               cp->oclocks[clck].hours.color = MI_WHITE_PIXEL(mi);
+               cp->oclocks[clck].minutes.color = MI_WHITE_PIXEL(mi);
+               cp->oclocks[clck].seconds.color = MI_WHITE_PIXEL(mi);
+               cp->d_time = time((time_t *) 0);
+       }
+       for (clck = 0; clck < cp->nclocks; clck++) {
+               (void) memcpy((char *) &cp->oclocks[clck].dd_time,
+                             (char *) localtime(&cp->d_time),
+                             sizeof (cp->oclocks[clck].dd_time));
+       }
+       cp->currentclocks = cp->nclocks;
+       for (clck = 0; clck < cp->currentclocks; clck++)
+               if (!new_clock_state(mi, clck))
+                       break;
+}
+
+void
+draw_clock(ModeInfo * mi)
+{
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+       int         clck;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (++cp->clock_count >= MI_CYCLES(mi)) {
+               cp->clock_count = 0;
+               for (clck = 0; clck < cp->currentclocks; clck++)
+                       real_draw_clock(mi, clck, 0);
+               cp->currentclocks = cp->nclocks;
+               for (clck = 0; clck < cp->currentclocks; clck++)
+                       if (!new_clock_state(mi, clck))
+                               break;
+               for (clck = 0; clck < cp->currentclocks; clck++)
+                       real_draw_clock(mi, clck, 1);
+               cp->redrawing = 0;
+       } else if (cp->d_time != time((time_t *) 0))
+               for (clck = 0; clck < cp->currentclocks; clck++)
+                       update_clock(mi, clck);
+       if (cp->redrawing) {
+               for (clck = 0; clck < cp->currentclocks; clck++)
+                       real_draw_clock(mi, clck, 1);
+               cp->redrawing = 0;
+       }
+}
+
+void
+release_clock(ModeInfo * mi)
+{
+       if (clocks != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       clockstruct *cp = &clocks[screen];
+
+                       if (cp->oclocks != NULL)
+                               (void) free((void *) cp->oclocks);
+               }
+               (void) free((void *) clocks);
+               clocks = NULL;
+       }
+}
+
+void
+refresh_clock(ModeInfo * mi)
+{
+       clockstruct *cp = &clocks[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+       cp->redrawing = 1;
+}
+
+#endif /* MODE_clock */
diff --git a/xlockmore-4.14/modes/coral.c b/xlockmore-4.14/modes/coral.c
new file mode 100644 (file)
index 0000000..2316147
--- /dev/null
@@ -0,0 +1,332 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* coral --- a coral reef */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)coral.c 4.07 97/11/24 xlockmore";
+
+#endif
+/* 
+ * Copyright (c) 1997 by "Frederick G.M. Roeber" <roeber@netscape.com>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 29-Oct-97: xlock version (David Bagley <bagleyd@tux.org>)
+ * 15-Jul-97: xscreensaver version Frederick G.M. Roeber <roeber@netscape.com>
+ */
+
+/*-
+ * original copyright
+ * Copyright (c) 1997 by "Frederick G.M. Roeber" <roeber@netscape.com>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Coral"
+#define HACK_INIT init_coral
+#define HACK_DRAW draw_coral
+#define coral_opts xlockmore_opts
+#define DEFAULTS "*delay: 60000 \n" \
+ "*batchcount: -3 \n" \
+ "*size: 35 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_coral
+
+ModeSpecOpt coral_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   coral_description =
+{"coral", "init_coral", "draw_coral", "release_coral",
+ "init_coral", "init_coral", NULL, &coral_opts,
+ 60000, -3, 1, 35, 64, 0.6, "",
+ "Shows a coral reef", 0, NULL};
+
+#endif
+
+#define MINSIZE 1
+#define MINSEEDS 1
+#define MAXSIZE 99
+#define MAXPOINTS 200
+#define COLORTHRESH 512
+
+typedef struct {
+       unsigned int default_fg_pixel;
+
+       XPoint     *walkers;
+       XPoint     *pointbuf;
+       unsigned int *reef;
+       int         nwalkers;
+       int         width, widthb;
+       int         height;
+       int         colorindex;
+       int         density;
+       int         seeds;
+} coralstruct;
+
+static coralstruct *reefs = NULL;
+
+#define getdot(x,y) (cp->reef[(y*cp->widthb)+(x>>5)] &  (1<<(x & 31)))
+/* Avoid array bounds reads and writes */
+#define setdot(x,y) (cp->reef[((y*cp->widthb)+(x>>5) >= 0 ? (y*cp->widthb)+(x>>5) : 0)] |= (1<<(x & 31)))
+
+/*-
+ * returns 2 bits of randomness (conserving calls to LRAND()).
+ * This speeds things up a little, but not a lot (5-10% or so.)
+ */
+static int
+rand_2(void)
+{
+       static int  i = 0;
+       static int  r = 0;
+
+       if (i) {
+               i--;
+       } else {
+               i = 15;
+               r = (int) LRAND();
+       }
+
+       {
+               register int j = (r & 3);
+
+               r = r >> 2;
+               return j;
+       }
+}
+
+
+void
+init_coral(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       coralstruct *cp;
+       int         size = MI_SIZE(mi);
+
+       int         i;
+
+       if (reefs == NULL) {
+               if ((reefs = (coralstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (coralstruct))) == NULL)
+                       return;
+       }
+       cp = &reefs[MI_SCREEN(mi)];
+
+
+       cp->width = MAX(MI_WIDTH(mi), 2);
+       cp->height = MAX(MI_HEIGHT(mi), 2);
+
+       cp->widthb = ((cp->width + 31) >> 5);
+
+       if (cp->reef) {
+               (void) free((void *) cp->reef);
+               cp->reef = NULL;
+       }
+       cp->reef = (unsigned int *) calloc((cp->widthb + 1) * cp->height,
+                                          sizeof (unsigned int));
+
+       if (!cp->reef)
+               return;
+
+       if (size < -MINSIZE)
+               cp->density = NRAND(MIN(MAXSIZE, -size) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE)
+               cp->density = MINSIZE;
+       else
+               cp->density = MIN(MAXSIZE, size);
+
+       cp->nwalkers = (cp->width * cp->height * cp->density) / 100;
+       if (cp->walkers) {
+               (void) free((void *) cp->walkers);
+               cp->walkers = NULL;
+       }
+       cp->walkers = (XPoint *) calloc(cp->nwalkers, sizeof (XPoint));
+       if (!cp->walkers)
+               return;
+
+       cp->seeds = MI_COUNT(mi);
+       if (cp->seeds < -MINSEEDS)
+               cp->seeds = NRAND(-cp->seeds - MINSEEDS + 1) + MINSEEDS;
+       else if (cp->seeds < MINSEEDS)
+               cp->seeds = MINSEEDS;
+
+       MI_CLEARWINDOW(mi);
+
+       if (MI_NPIXELS(mi) > 2) {
+               cp->colorindex = NRAND(MI_NPIXELS(mi) * COLORTHRESH);
+               XSetForeground(display, gc, MI_PIXEL(mi, cp->colorindex / COLORTHRESH));
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       for (i = 0; i < cp->seeds; i++) {
+               int         x, y;
+
+               do {
+                       x = NRAND(cp->width);
+                       y = NRAND(cp->height);
+               } while (getdot(x, y));
+
+               setdot((x - 1), (y - 1));
+               setdot(x, (y - 1));
+               setdot((x + 1), (y - 1));
+               setdot((x - 1), y);
+               setdot(x, y);
+               setdot((x + 1), y);
+               setdot((x - 1), (y + 1));
+               setdot(x, (y + 1));
+               setdot((x + 1), (y + 1));
+               XDrawPoint(display, window, gc, x, y);
+       }
+
+       for (i = 0; i < cp->nwalkers; i++) {
+               cp->walkers[i].x = NRAND(cp->width - 2) + 1;
+               cp->walkers[i].y = NRAND(cp->height - 2) + 1;
+       }
+       if (cp->pointbuf) {
+               (void) free((void *) cp->pointbuf);
+               cp->pointbuf = NULL;
+       }
+       cp->pointbuf = (XPoint *) calloc((MAXPOINTS + 2), sizeof (XPoint));
+       if (!cp->pointbuf)
+               return;
+}
+
+
+void
+draw_coral(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       coralstruct *cp = &reefs[MI_SCREEN(mi)];
+
+       int         npoints = 0;
+
+
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < cp->nwalkers; i++) {
+               int         x = cp->walkers[i].x;
+               int         y = cp->walkers[i].y;
+
+               if (getdot(x, y)) {
+
+                       /* XDrawPoint(display, window, gc, x, y); */
+                       cp->pointbuf[npoints].x = x;
+                       cp->pointbuf[npoints].y = y;
+                       npoints++;
+
+                       /* Mark the surrounding area as "sticky" */
+                       setdot((x - 1), (y - 1));
+                       setdot(x, (y - 1));
+                       setdot((x + 1), (y - 1));
+                       setdot((x - 1), y);
+                       setdot((x + 1), y);
+                       setdot((x - 1), (y + 1));
+                       setdot(x, (y + 1));
+                       setdot((x + 1), (y + 1));
+                       cp->nwalkers--;
+                       cp->walkers[i].x = cp->walkers[cp->nwalkers].x;
+                       cp->walkers[i].y = cp->walkers[cp->nwalkers].y;
+
+                       if (0 == cp->nwalkers || npoints >= MAXPOINTS) {
+                               XDrawPoints(display, window, gc, cp->pointbuf, npoints,
+                                           CoordModeOrigin);
+                               npoints = 0;
+                       }
+                       if (MI_NPIXELS(mi) > 2) {
+                               XSetForeground(display, gc, MI_PIXEL(mi, cp->colorindex / COLORTHRESH));
+                               if (++cp->colorindex >= MI_NPIXELS(mi) * COLORTHRESH)
+                                       cp->colorindex = 0;
+                       } else
+                               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+                       if (0 == cp->nwalkers) {
+                               if (cp->pointbuf)
+                                       (void) free((void *) cp->pointbuf);
+                               cp->pointbuf = 0;
+                               init_coral(mi);
+                               return;
+                       }
+               } else {
+                       /* move it a notch */
+                       switch (rand_2()) {
+                               case 0:
+                                       if (1 == x)
+                                               continue;
+                                       cp->walkers[i].x--;
+                                       break;
+                               case 1:
+                                       if (cp->width - 2 == x)
+                                               continue;
+                                       cp->walkers[i].x++;
+                                       break;
+                               case 2:
+                                       if (1 == y)
+                                               continue;
+                                       cp->walkers[i].y--;
+                                       break;
+                               default:        /* case 3: */
+                                       if (cp->height - 2 == y)
+                                               continue;
+                                       cp->walkers[i].y++;
+                                       break;
+                       }
+               }
+       }
+
+       if (npoints > 0) {
+               XDrawPoints(display, window, gc, cp->pointbuf, npoints,
+                           CoordModeOrigin);
+               npoints = 0;
+       }
+}
+
+void
+release_coral(ModeInfo * mi)
+{
+       if (reefs != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       coralstruct *cp = &reefs[screen];
+
+                       if (cp->reef != NULL)
+                               (void) free((void *) cp->reef);
+                       if (cp->pointbuf != NULL)
+                               (void) free((void *) cp->pointbuf);
+                       if (cp->walkers != NULL)
+                               (void) free((void *) cp->walkers);
+               }
+               (void) free((void *) reefs);
+               reefs = NULL;
+       }
+}
+
+#endif /* MODE_coral */
diff --git a/xlockmore-4.14/modes/crystal.c b/xlockmore-4.14/modes/crystal.c
new file mode 100644 (file)
index 0000000..c45d7a7
--- /dev/null
@@ -0,0 +1,1274 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* crystal --- polygons moving according to plane group rules */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)crystal.c    4.12 98/09/10 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by Jouk Jansen <joukj@hrem.stm.tudelft.nl>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The author should like to be notified if changes have been made to the
+ * routine.  Response will only be guaranteed when a VMS version of the 
+ * program is available.
+ *
+ * A moving polygon-mode. The polygons obey 2D-planegroup symmetry.
+ *
+ * The groupings of the cells fall in 3 categories:
+ *   oblique groups 1 and 2 where the angle gamma ranges from 60 to 120 degrees
+ *   square groups 3 through 11 where the angle gamma is 90 degrees
+ *   hexagonal groups 12 through 17 where the angle gamma is 120 degrees
+ *
+ * Revision History:
+ * 03-Dec-98: Random inversion of y-axis included to simulate hexagonal groups
+ *             with an angle of 60 degrees.
+ * 10-Sep-98: new colour scheme
+ * 24-Feb-98: added option centre which turns on/off forcing the centre of
+ *              the screen to be used
+ *            added option maxsize which forces the dimensions to be chasen
+ *              in such ua way that the largest possible part of the screen is
+ *              used 
+ *            When only one unit cell is drawn, it is chosen at random
+ * 18-Feb-98: added support for negative numbers with -nx and -ny meaning
+ *            "random" choice with given maximum
+ *            added +/-grid option. If -cell is specified this option
+ *            determines if one or all unit cells are drawn.
+ *            -batchcount is now a parameter for all the objects on the screen
+ *            instead of the number of "unique" objects
+ *            The maximum size of the objects now scales with the part
+ *            of the screen used.
+ *            fixed "size" problem. Now very small non-vissable objects
+ *            are not allowed
+ * 13-Feb-98: randomized the unit cell size
+ *            runtime options -/+cell (turn on/off unit cell drawing)
+ *             -nx num (number of translational symmetries in x-direction
+ *             -ny num (idem y-direction but ignored for square and
+ *               hexagonal space groups
+ *               i.e. try xlock -mode crystal -nx 3 -ny 2
+ *            Fullrandom overrules the -/+cell option.
+ * 05-Feb-98: Revision + bug repairs
+ *            shows unit cell
+ *            use part of the screen for unit cell
+ *            in hexagonal and square groups a&b axis forced to be equal
+ *            cell angle for oblique groups randomly chosen between 60 and 120
+ *   bugs solved: planegroups with cell angles <> 90.0 now work properly
+ * 19-Sep-97: Added remaining hexagonal groups
+ * 12-Jun-97: Created
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Crystal"
+#define HACK_INIT init_crystal
+#define HACK_DRAW draw_crystal
+#define crystal_opts xlockmore_opts
+#define DEFAULTS "*delay: 60000 \n" \
+ "*count: -500 \n" \
+ "*cycles: 200 \n" \
+ "*size: -15 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+
+#ifdef MODE_crystal
+
+#define DEF_CELL "True"                /* Draw unit cell */
+#define DEF_GRID "False"       /* Draw unit all cell if DEF_CELL is True */
+#define DEF_NX "-3"            /* number of unit cells in x-direction */
+#define DEF_NX1 1              /* number of unit cells in x-direction */
+#define DEF_NY "-3"            /* number of unit cells in y-direction */
+#define DEF_NY1 1              /* number of unit cells in y-direction */
+#define DEF_CENTRE "False"
+#define DEF_MAXSIZE "False"
+#define DEF_CYCLE "True"
+
+#define min(a,b) ((a) <= (b) ? (a) : (b))
+
+static int  nx, ny;
+
+static Bool unit_cell, grid_cell, centre, maxsize, cycle_p;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-nx", "crystal.nx", XrmoptionSepArg, (caddr_t) NULL},
+       {"-ny", "crystal.ny", XrmoptionSepArg, (caddr_t) NULL},
+       {"-centre", ".crystal.centre", XrmoptionNoArg, (caddr_t) "on"},
+       {"+centre", ".crystal.centre", XrmoptionNoArg, (caddr_t) "off"},
+       {"-maxsize", ".crystal.maxsize", XrmoptionNoArg, (caddr_t) "on"},
+       {"+maxsize", ".crystal.maxsize", XrmoptionNoArg, (caddr_t) "off"},
+       {"-cell", ".crystal.cell", XrmoptionNoArg, (caddr_t) "on"},
+       {"+cell", ".crystal.cell", XrmoptionNoArg, (caddr_t) "off"},
+       {"-grid", ".crystal.grid", XrmoptionNoArg, (caddr_t) "on"},
+       {"+grid", ".crystal.grid", XrmoptionNoArg, (caddr_t) "off"},
+       {"-cycle", ".crystal.cycle", XrmoptionNoArg, (caddr_t) "on"},
+       {"+cycle", ".crystal.cycle", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & nx, "nx", "nx", DEF_NX, t_Int},
+       {(caddr_t *) & ny, "ny", "ny", DEF_NY, t_Int},
+       {(caddr_t *) & centre, "centre", "Centre", DEF_CENTRE, t_Bool},
+       {(caddr_t *) & maxsize, "maxsize", "Maxsize", DEF_MAXSIZE, t_Bool},
+       {(caddr_t *) & unit_cell, "cell", "Cell", DEF_CELL, t_Bool},
+       {(caddr_t *) & grid_cell, "grid", "Grid", DEF_GRID, t_Bool},
+       {(caddr_t *) & cycle_p, "cycle", "Cycle", DEF_CYCLE, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-nx num", "Number of unit cells in x-direction"},
+       {"-ny num", "Number of unit cells in y-direction"},
+       {"-/+centre", "turn on/off centering on screen"},
+       {"-/+maxsize", "turn on/off use of maximum part of screen"},
+       {"-/+cell", "turn on/off drawing of unit cell"},
+   {"-/+grid", "turn on/off drawing of grid of unit cells (if -cell is on)"},
+       {"-/+cycle", "turn on/off colour cycling"}
+};
+
+ModeSpecOpt crystal_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   crystal_description =
+{"crystal", "init_crystal", "draw_crystal", "release_crystal",
+ "refresh_crystal", "init_crystal", NULL, &crystal_opts,
+ 60000, -40, 200, -15, 64, 1.0, "",
+ "Shows polygons in 2D plane groups", 0, NULL};
+
+#endif
+
+#define DEF_NUM_ATOM 10
+
+#define DEF_SIZ_ATOM 10
+
+#define PI_RAD (M_PI / 180.0)
+
+static Bool centro[17] =
+{
+       False,
+       True,
+       False,
+       False,
+       False,
+       True,
+       True,
+       True,
+       True,
+       True,
+       True,
+       True,
+       False,
+       False,
+       False,
+       True,
+       True
+};
+
+static Bool primitive[17] =
+{
+       True,
+       True,
+       True,
+       True,
+       False,
+       True,
+       True,
+       True,
+       False,
+       True,
+       True,
+       True,
+       True,
+       True,
+       True,
+       True,
+       True
+};
+
+static short numops[34] =
+{
+       1, 0,
+       1, 0,
+       9, 7,
+       2, 0,
+       9, 7,
+       9, 7,
+       4, 2,
+       5, 3,
+       9, 7,
+       8, 6,
+       10, 6,
+       8, 4,
+       16, 13,
+       19, 13,
+       16, 10,
+       19, 13,
+       19, 13
+};
+
+static short operation[114] =
+{
+       1, 0, 0, 1, 0, 0,
+       -1, 0, 0, 1, 0, 1,
+       -1, 0, 0, 1, 1, 0,
+       1, 0, 0, 1, 0, 0,
+       -1, 0, 0, 1, 1, 1,
+       1, 0, 0, 1, 1, 1,
+       0, -1, 1, 0, 0, 0,
+       1, 0, 0, 1, 0, 0,
+       -1, 0, 0, 1, 0, 0,
+       0, 1, 1, 0, 0, 0,
+       -1, 0, -1, 1, 0, 0,
+       1, -1, 0, -1, 0, 0,
+       0, 1, 1, 0, 0, 0,
+       0, -1, 1, -1, 0, 0,
+       -1, 1, -1, 0, 0, 0,
+       1, 0, 0, 1, 0, 0,
+       0, -1, -1, 0, 0, 0,
+       -1, 1, 0, 1, 0, 0,
+       1, 0, 1, -1, 0, 0
+};
+
+typedef struct {
+       unsigned long colour;
+       int         x0, y0, velocity[2];
+       float       angle, velocity_a;
+       int         num_point, at_type, size_at;
+       XPoint      xy[5];
+} crystalatom;
+
+typedef struct {
+       Bool        painted;
+       int         win_width, win_height, num_atom;
+       int         planegroup, a, b, offset_w, offset_h, nx, ny;
+       float       gamma;
+       crystalatom *atom;
+       GC          gc;
+       Bool        unit_cell, grid_cell;
+       Colormap    cmap;
+       XColor     *colors;
+       int         ncolors;
+       Bool        cycle_p, mono_p, no_colors;
+       unsigned long blackpixel, whitepixel, fg, bg;
+       int         direction , invert;
+} crystalstruct;
+
+static crystalstruct *crystals = NULL;
+
+static void
+trans_coor(XPoint * xyp, XPoint * new_xyp, int num_points,
+          float gamma )
+{
+       int         i;
+
+       for (i = 0; i <= num_points; i++) {
+               new_xyp[i].x = xyp[i].x +
+                       (int) (xyp[i].y * sin((gamma - 90.0) * PI_RAD));
+               new_xyp[i].y = (int) (xyp[i].y / cos((gamma - 90.0) * PI_RAD));
+       }
+}
+
+static void
+trans_coor_back(XPoint * xyp, XPoint * new_xyp,
+               int num_points, float gamma, int offset_w, int offset_h ,
+               int winheight , int invert )
+{
+       int         i;
+
+       for (i = 0; i <= num_points; i++) {
+               new_xyp[i].y = (int) (xyp[i].y * cos((gamma - 90) * PI_RAD)) +
+                       offset_h;
+               new_xyp[i].x = xyp[i].x - (int) (xyp[i].y * sin((gamma - 90.0)
+                                                      * PI_RAD)) + offset_w;
+          if ( invert ) new_xyp[i].y = winheight - new_xyp[i].y;
+       }
+}
+
+static void
+crystal_setupatom(crystalatom * atom0, float gamma)
+{
+       XPoint      xy[5];
+       int         x0, y0;
+
+       y0 = (int) (atom0->y0 * cos((gamma - 90) * PI_RAD));
+       x0 = atom0->x0 - (int) (atom0->y0 * sin((gamma - 90.0) * PI_RAD));
+       switch (atom0->at_type) {
+               case 0: /* rectangles */
+                       xy[0].x = x0 + (int) (2 * atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (atom0->size_at * sin(atom0->angle));
+                       xy[0].y = y0 + (int) (atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (2 * atom0->size_at * sin(atom0->angle));
+                       xy[1].x = x0 + (int) (2 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (atom0->size_at * sin(atom0->angle));
+                       xy[1].y = y0 - (int) (atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (2 * atom0->size_at * sin(atom0->angle));
+                       xy[2].x = x0 - (int) (2 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (atom0->size_at * sin(atom0->angle));
+                       xy[2].y = y0 - (int) (atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (2 * atom0->size_at * sin(atom0->angle));
+                       xy[3].x = x0 - (int) (2 * atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (atom0->size_at * sin(atom0->angle));
+                       xy[3].y = y0 + (int) (atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (2 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[4].x = xy[0].x;
+                       xy[4].y = xy[0].y;
+                       trans_coor(xy, atom0->xy, 4, gamma);
+                       return;
+               case 1: /* squares */
+                       xy[0].x = x0 + (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[0].y = y0 + (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[1].x = x0 + (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[1].y = y0 - (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[2].x = x0 - (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[2].y = y0 - (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[3].x = x0 - (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[3].y = y0 + (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[4].x = xy[0].x;
+                       xy[4].y = xy[0].y;
+                       trans_coor(xy, atom0->xy, 4, gamma);
+                       return;
+               case 2: /* triangles */
+                       xy[0].x = x0 + (int) (1.5 * atom0->size_at *
+                                             sin(atom0->angle));
+                       xy[0].y = y0 + (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle));
+                       xy[1].x = x0 + (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[1].y = y0 - (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[2].x = x0 - (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) -
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[2].y = y0 - (int) (1.5 * atom0->size_at *
+                                             cos(atom0->angle)) +
+                               (int) (1.5 * atom0->size_at *
+                                      sin(atom0->angle));
+                       xy[3].x = xy[0].x;
+                       xy[3].y = xy[0].y;
+                       trans_coor(xy, atom0->xy, 3, gamma);
+                       return;
+       }
+}
+
+static void
+crystal_drawatom(ModeInfo * mi, crystalatom * atom0)
+{
+       crystalstruct *cryst;
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         j, k, l, m;
+
+       cryst = &crystals[MI_SCREEN(mi)];
+       for (j = numops[2 * cryst->planegroup + 1];
+            j < numops[2 * cryst->planegroup]; j++) {
+               XPoint      xy[5], new_xy[5];
+               XPoint      xy_1[5];
+               int         xtrans, ytrans;
+
+               xtrans = operation[j * 6] * atom0->x0 + operation[j * 6 + 1] *
+                       atom0->y0 + (int) (operation[j * 6 + 4] * cryst->a /
+                                          2.0);
+               ytrans = operation[j * 6 + 2] * atom0->x0 + operation[j * 6 +
+                              3] * atom0->y0 + (int) (operation[j * 6 + 5] *
+                                                      cryst->b / 2.0);
+               if (xtrans < 0) {
+                       if (xtrans < -cryst->a)
+                               xtrans = 2 * cryst->a;
+                       else
+                               xtrans = cryst->a;
+               } else if (xtrans >= cryst->a)
+                       xtrans = -cryst->a;
+               else
+                       xtrans = 0;
+               if (ytrans < 0)
+                       ytrans = cryst->b;
+               else if (ytrans >= cryst->b)
+                       ytrans = -cryst->b;
+               else
+                       ytrans = 0;
+               for (k = 0; k < atom0->num_point; k++) {
+                       xy[k].x = operation[j * 6] * atom0->xy[k].x +
+                               operation[j * 6 + 1] *
+                               atom0->xy[k].y + (int) (operation[j * 6 + 4] *
+                                                       cryst->a / 2.0) +
+                               xtrans;
+                       xy[k].y = operation[j * 6 + 2] * atom0->xy[k].x +
+                               operation[j * 6 + 3] *
+                               atom0->xy[k].y + (int) (operation[j * 6 + 5] *
+                                                       cryst->b / 2.0) +
+                               ytrans;
+               }
+               xy[atom0->num_point].x = xy[0].x;
+               xy[atom0->num_point].y = xy[0].y;
+               for (l = 0; l < cryst->nx; l++) {
+                       for (m = 0; m < cryst->ny; m++) {
+
+                               for (k = 0; k <= atom0->num_point; k++) {
+                                       xy_1[k].x = xy[k].x + l * cryst->a;
+                                       xy_1[k].y = xy[k].y + m * cryst->b;
+                               }
+                               trans_coor_back(xy_1, new_xy, atom0->num_point,
+                                               cryst->gamma, cryst->offset_w,
+                                               cryst->offset_h ,
+                                               cryst->win_height,
+                                               cryst->invert);
+                               XFillPolygon(display, window, cryst->gc, new_xy,
+                                 atom0->num_point, Convex, CoordModeOrigin);
+                       }
+               }
+               if (centro[cryst->planegroup] == True) {
+                       for (k = 0; k <= atom0->num_point; k++) {
+                               xy[k].x = cryst->a - xy[k].x;
+                               xy[k].y = cryst->b - xy[k].y;
+                       }
+                       for (l = 0; l < cryst->nx; l++) {
+                               for (m = 0; m < cryst->ny; m++) {
+
+                                       for (k = 0; k <= atom0->num_point; k++) {
+                                               xy_1[k].x = xy[k].x + l * cryst->a;
+                                               xy_1[k].y = xy[k].y + m * cryst->b;
+                                       }
+                                       trans_coor_back(xy_1, new_xy, atom0->num_point,
+                                                       cryst->gamma,
+                                                       cryst->offset_w,
+                                                       cryst->offset_h ,
+                                                       cryst->win_height ,
+                                                       cryst->invert);
+                                       XFillPolygon(display, window, cryst->gc,
+                                                    new_xy,
+                                                    atom0->num_point, Convex,
+                                                    CoordModeOrigin);
+                               }
+                       }
+               }
+               if (primitive[cryst->planegroup] == False) {
+                       if (xy[atom0->num_point].x >= (int) (cryst->a / 2.0))
+                               xtrans = (int) (-cryst->a / 2.0);
+                       else
+                               xtrans = (int) (cryst->a / 2.0);
+                       if (xy[atom0->num_point].y >= (int) (cryst->b / 2.0))
+                               ytrans = (int) (-cryst->b / 2.0);
+                       else
+                               ytrans = (int) (cryst->b / 2.0);
+                       for (k = 0; k <= atom0->num_point; k++) {
+                               xy[k].x = xy[k].x + xtrans;
+                               xy[k].y = xy[k].y + ytrans;
+                       }
+                       for (l = 0; l < cryst->nx; l++) {
+                               for (m = 0; m < cryst->ny; m++) {
+
+                                       for (k = 0; k <= atom0->num_point; k++) {
+                                               xy_1[k].x = xy[k].x + l * cryst->a;
+                                               xy_1[k].y = xy[k].y + m * cryst->b;
+                                       }
+                                       trans_coor_back(xy_1, new_xy, atom0->num_point,
+                                                       cryst->gamma,
+                                                       cryst->offset_w,
+                                                       cryst->offset_h ,
+                                                       cryst->win_height,
+                                                       cryst->invert);
+                                       XFillPolygon(display, window, cryst->gc,
+                                                    new_xy,
+                                                    atom0->num_point, Convex,
+                                                    CoordModeOrigin);
+                               }
+                       }
+                       if (centro[cryst->planegroup] == True) {
+                               XPoint      xy1[5];
+
+                               for (k = 0; k <= atom0->num_point; k++) {
+                                       xy1[k].x = cryst->a - xy[k].x;
+                                       xy1[k].y = cryst->b - xy[k].y;
+                               }
+                               for (l = 0; l < cryst->nx; l++) {
+                                       for (m = 0; m < cryst->ny; m++) {
+
+                                               for (k = 0; k <= atom0->num_point; k++) {
+                                                       xy_1[k].x = xy1[k].x + l * cryst->a;
+                                                       xy_1[k].y = xy1[k].y + m * cryst->b;
+                                               }
+                                               trans_coor_back(xy_1, new_xy, atom0->num_point,
+                                                               cryst->gamma,
+                                                               cryst->offset_w,
+                                                               cryst->offset_h ,
+                                                               cryst->win_height,
+                                                               cryst->invert);
+                                               XFillPolygon(display, window,
+                                                            cryst->gc,
+                                                   new_xy, atom0->num_point,
+                                                   Convex, CoordModeOrigin);
+                                       }
+                               }
+                       }
+               }
+       }
+}
+
+void
+draw_crystal(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       crystalstruct *cryst = &crystals[MI_SCREEN(mi)];
+       int         i;
+
+       if (cryst->no_colors) {
+               release_crystal(mi);
+               init_crystal(mi);
+               return;
+       }
+       cryst->painted = True;
+       MI_IS_DRAWN(mi) = True;
+       XSetFunction(display, cryst->gc, GXxor);
+
+/* Rotate colours */
+       if (cryst->cycle_p) {
+               rotate_colors(display, cryst->cmap, cryst->colors, cryst->ncolors,
+                             cryst->direction);
+               if (!(LRAND() % 1000))
+                       cryst->direction = -cryst->direction;
+       }
+       for (i = 0; i < cryst->num_atom; i++) {
+               crystalatom *atom0;
+
+               atom0 = &cryst->atom[i];
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, cryst->gc, cryst->colors[atom0->colour].pixel);
+               } else {
+                       XSetForeground(display, cryst->gc, atom0->colour);
+               }
+               crystal_drawatom(mi, atom0);
+               atom0->velocity[0] += NRAND(3) - 1;
+               atom0->velocity[0] = MAX(-20, MIN(20, atom0->velocity[0]));
+               atom0->velocity[1] += NRAND(3) - 1;
+               atom0->velocity[1] = MAX(-20, MIN(20, atom0->velocity[1]));
+               atom0->x0 += atom0->velocity[0];
+               /*if (cryst->gamma == 90.0) { */
+               if (atom0->x0 < 0)
+                       atom0->x0 += cryst->a;
+               else if (atom0->x0 >= cryst->a)
+                       atom0->x0 -= cryst->a;
+               atom0->y0 += atom0->velocity[1];
+               if (atom0->y0 < 0)
+                       atom0->y0 += cryst->b;
+               else if (atom0->y0 >= cryst->b)
+                       atom0->y0 -= cryst->b;
+               /*} */
+               atom0->velocity_a += ((float) NRAND(1001) - 500.0) / 2000.0;
+               atom0->angle += atom0->velocity_a;
+               crystal_setupatom(atom0, cryst->gamma);
+               crystal_drawatom(mi, atom0);
+       }
+       XSetFunction(display, cryst->gc, GXcopy);
+}
+
+void
+refresh_crystal(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       crystalstruct *cryst = &crystals[MI_SCREEN(mi)];
+       int         i;
+
+       if (!cryst->painted)
+               return;
+       MI_CLEARWINDOW(mi);
+       XSetFunction(display, cryst->gc, GXxor);
+
+       if (cryst->unit_cell) {
+          int y_coor1 , y_coor2;
+          
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, cryst->gc, MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))));
+               else
+                       XSetForeground(display, cryst->gc, MI_WHITE_PIXEL(mi));
+               if (cryst->grid_cell) {
+                       int         inx, iny;
+
+                  if ( cryst->invert )
+                    y_coor1 = y_coor2 = cryst->win_height - cryst->offset_h;
+                  else
+                    y_coor1 = y_coor2 = cryst->offset_h;
+                       XDrawLine(display, window, cryst->gc, cryst->offset_w,
+                                 y_coor1, cryst->offset_w + cryst->nx * cryst->a,
+                                 y_coor2);
+                  if ( cryst->invert )
+                    {
+                       y_coor1 = cryst->win_height - cryst->offset_h;
+                       y_coor2 = cryst->win_height - (int) (cryst->ny *
+                                                            cryst->b *
+                                        cos((cryst->gamma - 90) * PI_RAD)) -
+                         cryst->offset_h;
+                    }
+                  else
+                    {
+                       y_coor1 = cryst->offset_h;
+                       y_coor2 = (int) (cryst->ny * cryst->b *
+                                        cos((cryst->gamma - 90) * PI_RAD)) +
+                         cryst->offset_h;
+                    }
+                       XDrawLine(display, window, cryst->gc, cryst->offset_w,
+                                 y_coor1, (int) (cryst->offset_w - cryst->ny * cryst->b *
+                                         sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+                       inx = cryst->nx;
+                       for (iny = 1; iny <= cryst->ny; iny++) {
+                  if ( cryst->invert )
+                    {
+                       y_coor1 = cryst->win_height -
+                         (int) (iny * cryst->b * cos((cryst->gamma - 90) *
+                                                 PI_RAD)) - cryst->offset_h;
+                       y_coor2 = cryst->win_height -
+                         (int) (iny * cryst->b * cos((cryst->gamma - 90) *
+                                                     PI_RAD)) -
+                         cryst->offset_h;
+                    }
+                  else
+                    {
+                       y_coor1 = (int) (iny * cryst->b * cos((cryst->gamma - 90) *
+                                                 PI_RAD)) + cryst->offset_h;
+                       y_coor2 = (int) (iny * cryst->b * cos((cryst->gamma - 90) * PI_RAD)) +
+                                         cryst->offset_h;
+                    }
+                               XDrawLine(display, window, cryst->gc,
+                                         (int) (cryst->offset_w +
+                                    inx * cryst->a - (int) (iny * cryst->b *
+                                        sin((cryst->gamma - 90) * PI_RAD))),
+                                         y_coor1,
+                                   (int) (cryst->offset_w - iny * cryst->b *
+                                          sin((cryst->gamma - 90) * PI_RAD)),
+                                         y_coor2);
+                       }
+                       iny = cryst->ny;
+                       for (inx = 1; inx <= cryst->nx; inx++) {
+                          if ( cryst->invert )
+                            {
+                               y_coor1 =cryst->win_height -
+                                 (int) (iny * cryst->b *
+                                               cos((cryst->gamma - 90) *
+                                                   PI_RAD)) - cryst->offset_h;
+                               y_coor2 =cryst->win_height - cryst->offset_h;
+                            }
+                          else
+                            {
+                               y_coor1 =(int) (iny * cryst->b *
+                                               cos((cryst->gamma - 90) *
+                                                   PI_RAD)) + cryst->offset_h;
+                               y_coor2 =cryst->offset_h;
+                            }
+                               XDrawLine(display, window, cryst->gc,
+                                         (int) (cryst->offset_w +
+                                    inx * cryst->a - (int) (iny * cryst->b *
+                                        sin((cryst->gamma - 90) * PI_RAD))),
+                                         y_coor1,
+                                         cryst->offset_w + inx * cryst->a,
+                                         y_coor2);
+                       }
+               } else {
+                       int         inx, iny;
+
+                       inx = NRAND(cryst->nx);
+                       iny = NRAND(cryst->ny);
+                  if ( cryst->invert )
+                    {
+                       y_coor1 =cryst->win_height -
+                         (int) (iny * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) -
+                         cryst->offset_h;
+                       y_coor2 =cryst->win_height -
+                         (int) ( ( iny + 1 ) * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) -
+                         cryst->offset_h;
+                    }
+                  else
+                    {
+                       y_coor1 =(int) (iny * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) +
+                         cryst->offset_h;
+                       y_coor2 =(int) (( iny + 1 ) * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) +
+                         cryst->offset_h;
+                    }
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + inx * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1);
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + inx * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1,
+                                 cryst->offset_w + inx * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + inx * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+               }
+       }
+       for (i = 0; i < cryst->num_atom; i++) {
+               crystalatom *atom0;
+
+               atom0 = &cryst->atom[i];
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, cryst->gc, cryst->colors[atom0->colour].pixel);
+               } else {
+                       XSetForeground(display, cryst->gc, atom0->colour);
+               }
+               crystal_drawatom(mi, atom0);
+       }
+       XSetFunction(display, cryst->gc, GXcopy);
+}
+
+void
+release_crystal(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+
+       if (crystals != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       crystalstruct *cryst = &crystals[screen];
+
+                       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                               MI_WHITE_PIXEL(mi) = cryst->whitepixel;
+                               MI_BLACK_PIXEL(mi) = cryst->blackpixel;
+#ifndef STANDALONE
+                               MI_FG_PIXEL(mi) = cryst->fg;
+                               MI_BG_PIXEL(mi) = cryst->bg;
+#endif
+                               if (cryst->colors && cryst->ncolors && !cryst->no_colors)
+                                       free_colors(display, cryst->cmap, cryst->colors, cryst->ncolors);
+                               if (cryst->colors)
+                                       (void) free((void *) cryst->colors);
+                               XFreeColormap(display, cryst->cmap);
+                       }
+                       if (cryst->gc != NULL)
+                               XFreeGC(display, cryst->gc);
+                       if (cryst->atom != NULL)
+                               (void) free((void *) cryst->atom);
+               }
+               (void) free((void *) crystals);
+               crystals = NULL;
+       }
+}
+
+void
+init_crystal(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       crystalstruct *cryst;
+       int         i, max_atoms, size_atom, neqv;
+       int         cell_min;
+
+#define MIN_CELL 200
+
+/* initialize */
+       if (crystals == NULL) {
+               if ((crystals = (crystalstruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (crystalstruct))) == NULL)
+                       return;
+       }
+       cryst = &crystals[MI_SCREEN(mi)];
+
+       if (!cryst->gc) {
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       XColor      color;
+
+#ifndef STANDALONE
+                       extern char *background;
+                       extern char *foreground;
+
+                       cryst->fg = MI_FG_PIXEL(mi);
+                       cryst->bg = MI_BG_PIXEL(mi);
+#endif
+                       cryst->blackpixel = MI_BLACK_PIXEL(mi);
+                       cryst->whitepixel = MI_WHITE_PIXEL(mi);
+                       cryst->cmap = XCreateColormap(display, window,
+                                                  MI_VISUAL(mi), AllocNone);
+                       XSetWindowColormap(display, window, cryst->cmap);
+                       (void) XParseColor(display, cryst->cmap, "black", &color);
+                       (void) XAllocColor(display, cryst->cmap, &color);
+                       MI_BLACK_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, cryst->cmap, "white", &color);
+                       (void) XAllocColor(display, cryst->cmap, &color);
+                       MI_WHITE_PIXEL(mi) = color.pixel;
+#ifndef STANDALONE
+                       (void) XParseColor(display, cryst->cmap, background, &color);
+                       (void) XAllocColor(display, cryst->cmap, &color);
+                       MI_BG_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, cryst->cmap, foreground, &color);
+                       (void) XAllocColor(display, cryst->cmap, &color);
+                       MI_FG_PIXEL(mi) = color.pixel;
+#endif
+                       cryst->colors = 0;
+                       cryst->ncolors = 0;
+               }
+               if ((cryst->gc = XCreateGC(display, MI_WINDOW(mi),
+                            (unsigned long) 0, (XGCValues *) NULL)) == None)
+                       return;
+       }
+/* Clear Display */
+       MI_CLEARWINDOW(mi);
+       cryst->painted = False;
+       XSetFunction(display, cryst->gc, GXxor);
+
+
+/*Set up crystal data */
+       cryst->direction = (LRAND() & 1) ? 1 : -1;
+       if (MI_IS_FULLRANDOM(mi)) {
+               if (LRAND() & 1)
+                       cryst->unit_cell = True;
+               else
+                       cryst->unit_cell = False;
+       } else
+               cryst->unit_cell = unit_cell;
+       if (cryst->unit_cell) {
+               if (MI_IS_FULLRANDOM(mi)) {
+                       if (LRAND() & 1)
+                               cryst->grid_cell = True;
+                       else
+                               cryst->grid_cell = False;
+               } else
+                       cryst->grid_cell = grid_cell;
+       }
+       cryst->win_width = MI_WIDTH(mi);
+       cryst->win_height = MI_HEIGHT(mi);
+       cell_min = min(cryst->win_width / 2 + 1, MIN_CELL);
+       cell_min = min(cell_min, cryst->win_height / 2 + 1);
+       cryst->planegroup = NRAND(17);
+        cryst->invert = NRAND(2);
+       if (MI_IS_VERBOSE(mi))
+               (void) fprintf(stdout, "Selected plane group no %d\n",
+                              cryst->planegroup + 1);
+       if (cryst->planegroup > 11)
+               cryst->gamma = 120.0;
+       else if (cryst->planegroup < 2)
+               cryst->gamma = 60.0 + NRAND(60);
+       else
+               cryst->gamma = 90.0;
+       neqv = numops[2 * cryst->planegroup] - numops[2 * cryst->planegroup + 1];
+       if (centro[cryst->planegroup] == True)
+               neqv = 2 * neqv;
+       if (primitive[cryst->planegroup] == False)
+               neqv = 2 * neqv;
+
+
+       if (nx > 0)
+               cryst->nx = nx;
+       else if (nx < 0)
+               cryst->nx = NRAND(-nx) + 1;
+       else
+               cryst->nx = DEF_NX1;
+       if (cryst->planegroup > 8)
+               cryst->ny = cryst->nx;
+       else if (ny > 0)
+               cryst->ny = ny;
+       else if (ny < 0)
+               cryst->ny = NRAND(-ny) + 1;
+       else
+               cryst->ny = DEF_NY1;
+       neqv = neqv * cryst->nx * cryst->ny;
+
+       cryst->num_atom = MI_COUNT(mi);
+       max_atoms = MI_COUNT(mi);
+       if (cryst->num_atom == 0) {
+               cryst->num_atom = DEF_NUM_ATOM;
+               max_atoms = DEF_NUM_ATOM;
+       } else if (cryst->num_atom < 0) {
+               max_atoms = -cryst->num_atom;
+               cryst->num_atom = NRAND(-cryst->num_atom) + 1;
+       }
+       if (neqv > 1)
+               cryst->num_atom = cryst->num_atom / neqv + 1;
+
+       if (cryst->atom == NULL)
+               cryst->atom = (crystalatom *) calloc(max_atoms, sizeof (
+                                                              crystalatom));
+
+       if (maxsize) {
+               if (cryst->planegroup < 13) {
+                       cryst->gamma = 90.0;
+                       cryst->offset_w = 0;
+                       cryst->offset_h = 0;
+                       if (cryst->planegroup < 10) {
+                               cryst->b = cryst->win_height;
+                               cryst->a = cryst->win_width;
+                       } else {
+                               cryst->b = min(cryst->win_height, cryst->win_width);
+                               cryst->a = cryst->b;
+                       }
+               } else {
+                       cryst->gamma = 120.0;
+                       cryst->a = (int) (cryst->win_width * 2.0 / 3.0);
+                       cryst->b = cryst->a;
+                       cryst->offset_h = (int) (cryst->b * 0.25 *
+                                         cos((cryst->gamma - 90) * PI_RAD));
+                       cryst->offset_w = (int) (cryst->b * 0.5);
+               }
+       } else {
+               cryst->offset_w = -1;
+               while (cryst->offset_w < 4 || (int) (cryst->offset_w - cryst->b *
+                                   sin((cryst->gamma - 90) * PI_RAD)) < 4) {
+                       cryst->b = NRAND((int) (cryst->win_height / (cos((cryst->gamma - 90) *
+                                           PI_RAD))) - cell_min) + cell_min;
+                       if (cryst->planegroup > 8)
+                               cryst->a = cryst->b;
+                       else
+                               cryst->a = NRAND(cryst->win_width - cell_min) + cell_min;
+                       cryst->offset_w = (int) ((cryst->win_width - (cryst->a - cryst->b *
+                                                   sin((cryst->gamma - 90) *
+                                                       PI_RAD))) / 2.0);
+               }
+               cryst->offset_h = (int) ((cryst->win_height - cryst->b * cos((
+                                       cryst->gamma - 90) * PI_RAD)) / 2.0);
+               if (!centre) {
+                       if (cryst->offset_h > 0)
+                               cryst->offset_h = NRAND(2 * cryst->offset_h);
+                       cryst->offset_w = (int) (cryst->win_width - cryst->a -
+                                                cryst->b *
+                                   fabs(sin((cryst->gamma - 90) * PI_RAD)));
+                       if (cryst->gamma > 90.0) {
+                               if (cryst->offset_w > 0)
+                                       cryst->offset_w = NRAND(cryst->offset_w) +
+                                               (int) (cryst->b * sin((cryst->gamma - 90) * PI_RAD));
+                               else
+                                       cryst->offset_w = (int) (cryst->b * sin((cryst->gamma - 90) *
+                                                                   PI_RAD));
+                       } else if (cryst->offset_w > 0)
+                               cryst->offset_w = NRAND(cryst->offset_w);
+                       else
+                               cryst->offset_w = 0;
+               }
+       }
+
+       size_atom = min((int) ((float) (cryst->a) / 40.) + 1,
+                       (int) ((float) (cryst->b) / 40.) + 1);
+       if (MI_SIZE(mi) < size_atom) {
+               if (MI_SIZE(mi) < -size_atom)
+                       size_atom = -size_atom;
+               else
+                       size_atom = MI_SIZE(mi);
+       }
+       cryst->a = cryst->a / cryst->nx;
+       cryst->b = cryst->b / cryst->ny;
+       if (cryst->unit_cell) {
+          int y_coor1 , y_coor2;
+          
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, cryst->gc, MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))));
+               else
+                       XSetForeground(display, cryst->gc, MI_WHITE_PIXEL(mi));
+               if (cryst->grid_cell) {
+                       int         inx, iny;
+
+                  if ( cryst->invert )
+                    y_coor1 = y_coor2 = cryst->win_height - cryst->offset_h;
+                  else
+                    y_coor1 = y_coor2 = cryst->offset_h;
+                       XDrawLine(display, window, cryst->gc, cryst->offset_w,
+                                 y_coor1, cryst->offset_w + cryst->nx * cryst->a,
+                                 y_coor2);
+                  if ( cryst->invert )
+                    {
+                       y_coor1 = cryst->win_height - cryst->offset_h;
+                       y_coor2 = cryst->win_height - (int) (cryst->ny *
+                                                            cryst->b *
+                                        cos((cryst->gamma - 90) * PI_RAD)) -
+                         cryst->offset_h;
+                    }
+                  else
+                    {
+                       y_coor1 = cryst->offset_h;
+                       y_coor2 = (int) (cryst->ny * cryst->b *
+                                        cos((cryst->gamma - 90) * PI_RAD)) +
+                         cryst->offset_h;
+                    }
+                       XDrawLine(display, window, cryst->gc, cryst->offset_w,
+                                 y_coor1, (int) (cryst->offset_w - cryst->ny * cryst->b *
+                                         sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+                       inx = cryst->nx;
+                       for (iny = 1; iny <= cryst->ny; iny++) {
+                  if ( cryst->invert )
+                    {
+                       y_coor1 = cryst->win_height -
+                         (int) (iny * cryst->b * cos((cryst->gamma - 90) *
+                                                 PI_RAD)) - cryst->offset_h;
+                       y_coor2 = cryst->win_height -
+                         (int) (iny * cryst->b * cos((cryst->gamma - 90) *
+                                                     PI_RAD)) -
+                         cryst->offset_h;
+                    }
+                  else
+                    {
+                       y_coor1 = (int) (iny * cryst->b * cos((cryst->gamma - 90) *
+                                                 PI_RAD)) + cryst->offset_h;
+                       y_coor2 = (int) (iny * cryst->b * cos((cryst->gamma - 90) * PI_RAD)) +
+                                         cryst->offset_h;
+                    }
+                               XDrawLine(display, window, cryst->gc,
+                                         (int) (cryst->offset_w +
+                                    inx * cryst->a - (int) (iny * cryst->b *
+                                        sin((cryst->gamma - 90) * PI_RAD))),
+                                         y_coor1,
+                                   (int) (cryst->offset_w - iny * cryst->b *
+                                          sin((cryst->gamma - 90) * PI_RAD)),
+                                         y_coor2);
+                       }
+                       iny = cryst->ny;
+                       for (inx = 1; inx <= cryst->nx; inx++) {
+                          if ( cryst->invert )
+                            {
+                               y_coor1 =cryst->win_height -
+                                 (int) (iny * cryst->b *
+                                               cos((cryst->gamma - 90) *
+                                                   PI_RAD)) - cryst->offset_h;
+                               y_coor2 =cryst->win_height - cryst->offset_h;
+                            }
+                          else
+                            {
+                               y_coor1 =(int) (iny * cryst->b *
+                                               cos((cryst->gamma - 90) *
+                                                   PI_RAD)) + cryst->offset_h;
+                               y_coor2 =cryst->offset_h;
+                            }
+                               XDrawLine(display, window, cryst->gc,
+                                         (int) (cryst->offset_w +
+                                    inx * cryst->a - (int) (iny * cryst->b *
+                                        sin((cryst->gamma - 90) * PI_RAD))),
+                                         y_coor1,
+                                         cryst->offset_w + inx * cryst->a,
+                                         y_coor2);
+                       }
+               } else {
+                       int         inx, iny;
+
+                       inx = NRAND(cryst->nx);
+                       iny = NRAND(cryst->ny);
+                  if ( cryst->invert )
+                    {
+                       y_coor1 =cryst->win_height -
+                         (int) (iny * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) -
+                         cryst->offset_h;
+                       y_coor2 =cryst->win_height -
+                         (int) ( ( iny + 1 ) * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) -
+                         cryst->offset_h;
+                    }
+                  else
+                    {
+                       y_coor1 =(int) (iny * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) +
+                         cryst->offset_h;
+                       y_coor2 =(int) (( iny + 1 ) * cryst->b *
+                                                 cos((cryst->gamma - 90) *
+                                                     PI_RAD)) +
+                         cryst->offset_h;
+                    }
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + inx * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1);
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + inx * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1,
+                                 cryst->offset_w + inx * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) (iny * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor1,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+                       XDrawLine(display, window, cryst->gc,
+                                 cryst->offset_w + inx * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2,
+                                 cryst->offset_w + (inx + 1) * cryst->a - (int) ((iny + 1) * cryst->b * sin((cryst->gamma - 90) * PI_RAD)),
+                                 y_coor2);
+               }
+       }
+       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+/* Set up colour map */
+               if (cryst->colors && cryst->ncolors && !cryst->no_colors)
+                       free_colors(display, cryst->cmap, cryst->colors, cryst->ncolors);
+               if (cryst->colors)
+                       (void) free((void *) cryst->colors);
+               cryst->colors = 0;
+               cryst->ncolors = MI_NCOLORS(mi);
+               if (cryst->ncolors < 2)
+                       cryst->ncolors = 2;
+               if (cryst->ncolors <= 2)
+                       cryst->mono_p = True;
+               else
+                       cryst->mono_p = False;
+
+               if (cryst->mono_p)
+                       cryst->colors = 0;
+               else
+                       cryst->colors = (XColor *) malloc(sizeof (*cryst->colors) * (cryst->ncolors + 1));
+               cryst->cycle_p = has_writable_cells(mi);
+               if (cryst->cycle_p) {
+                       if (MI_IS_FULLRANDOM(mi)) {
+                               if (!NRAND(8))
+                                       cryst->cycle_p = False;
+                               else
+                                       cryst->cycle_p = True;
+                       } else {
+                               cryst->cycle_p = cycle_p;
+                       }
+               }
+               if (!cryst->mono_p) {
+                       if (!(LRAND() % 10))
+                               make_random_colormap(
+#ifdef STANDALONE
+                                               MI_DISPLAY(mi), MI_WINDOW(mi),
+#else
+            mi,
+#endif
+                                               cryst->cmap, cryst->colors, &cryst->ncolors,
+                                               True, True, &cryst->cycle_p);
+                       else if (!(LRAND() % 2))
+                               make_uniform_colormap(
+#ifdef STANDALONE
+                                               MI_DISPLAY(mi), MI_WINDOW(mi),
+#else
+            mi,
+#endif
+                  cryst->cmap, cryst->colors, &cryst->ncolors,
+                                                     True, &cryst->cycle_p);
+                       else
+                               make_smooth_colormap(
+#ifdef STANDALONE
+                                               MI_DISPLAY(mi), MI_WINDOW(mi),
+#else
+            mi,
+#endif
+                 cryst->cmap, cryst->colors, &cryst->ncolors,
+                                                    True, &cryst->cycle_p);
+               }
+               XInstallColormap(display, cryst->cmap);
+               if (cryst->ncolors < 2) {
+                       cryst->ncolors = 2;
+                       cryst->no_colors = True;
+               } else
+                       cryst->no_colors = False;
+               if (cryst->ncolors <= 2)
+                       cryst->mono_p = True;
+
+               if (cryst->mono_p)
+                       cryst->cycle_p = False;
+
+       }
+       for (i = 0; i < cryst->num_atom; i++) {
+               crystalatom *atom0;
+
+               atom0 = &cryst->atom[i];
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       if (cryst->ncolors > 2)
+                               atom0->colour = NRAND(cryst->ncolors - 2) + 2;
+                       else
+                               atom0->colour = 1;      /* Just in case */
+                       XSetForeground(display, cryst->gc, cryst->colors[atom0->colour].pixel);
+               } else {
+                       if (MI_NPIXELS(mi) > 2)
+                               atom0->colour = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       else
+                               atom0->colour = 1;      /*Xor'red so WHITE may not be appropriate */
+                       XSetForeground(display, cryst->gc, atom0->colour);
+               }
+               atom0->x0 = NRAND(cryst->a);
+               atom0->y0 = NRAND(cryst->b);
+               atom0->velocity[0] = NRAND(7) - 3;
+               atom0->velocity[1] = NRAND(7) - 3;
+               atom0->velocity_a = (NRAND(7) - 3) * PI_RAD;
+               atom0->angle = NRAND(90) * PI_RAD;
+               atom0->at_type = NRAND(3);
+               if (size_atom == 0)
+                       atom0->size_at = DEF_SIZ_ATOM;
+               else if (size_atom > 0)
+                       atom0->size_at = size_atom;
+               else
+                       atom0->size_at = NRAND(-size_atom) + 1;
+               atom0->size_at++;
+               if (atom0->at_type == 2)
+                       atom0->num_point = 3;
+               else
+                       atom0->num_point = 4;
+               crystal_setupatom(atom0, cryst->gamma);
+               crystal_drawatom(mi, atom0);
+       }
+       XSync(display, False);
+       XSetFunction(display, cryst->gc, GXcopy);
+}
+
+#endif /* MODE_crystal */
diff --git a/xlockmore-4.14/modes/daisy.c b/xlockmore-4.14/modes/daisy.c
new file mode 100644 (file)
index 0000000..9b63f79
--- /dev/null
@@ -0,0 +1,313 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* daisy --- flowers in a field */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)daisy.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 07-Aug-96: written.  Initially copied forest.c and made continual
+ *            refinements, pyro was helpful too.  Based on a program
+ *            I saw on a PC.
+ *
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Daisy"
+#define HACK_INIT init_daisy
+#define HACK_DRAW draw_daisy
+#define daisy_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: 300 \n" \
+ "*cycles: 350 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n"
+#define BRIGHT_COLORS
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_daisy
+
+#define DEF_GARDEN  "False"
+
+static Bool garden;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-garden", ".daisy.garden", XrmoptionNoArg, (caddr_t) "on"},
+       {"+garden", ".daisy.garden", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & garden, "garden", "Garden", DEF_GARDEN, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+garden", "turn on/off garden"}
+};
+
+ModeSpecOpt daisy_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   daisy_description =
+{"daisy", "init_daisy", "draw_daisy", "release_daisy",
+ "refresh_daisy", "init_daisy", NULL, &daisy_opts,
+ 100000, 300, 350, 1, 64, 1.0, "",
+ "Shows a meadow of daisies", 0, NULL};
+
+#endif
+
+#define GREEN  (23 * MI_NPIXELS(mi) / 64)
+#define NOTGREEN       (7 * MI_NPIXELS(mi) / 64)
+#define MINDAISIES   1
+
+#define DROOP 20               /* Percentage x with relation to y */
+#define MINHEIGHT  20          /* Daisy height range */
+#define MAXHEIGHT  40
+
+typedef struct {
+       int         width;
+       int         height;
+       int         time;       /* up time */
+       int         ndaisies;
+       int         meadow_y;
+       Bool        garden;
+       float       step;
+} daisystruct;
+
+static daisystruct *daisies = NULL;
+
+/* always green, straight for now, parabolic later */
+static void
+drawstem(ModeInfo * mi, XPoint start, XPoint stop)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, GREEN));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+#if 1
+       XDrawLine(display, window, gc, start.x, start.y, stop.x, stop.y);
+#else
+       XDrawArc(display, window, gc, stop.x, stop.y,
+                NRAND(50) + 30, start.y - stop.y + 1, 90 * 64, 170 * 64);
+#endif
+}
+
+/* not green */
+static unsigned long
+drawpetals(ModeInfo * mi, XPoint center,
+          int size, int circles, int delta, int offset, int petals)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       unsigned long colour = 0;
+       float       start_angle, inc_angle;
+       XPoint      newcenter;
+       int         petal, inc;
+       float       sine, cosine;
+
+       if (MI_NPIXELS(mi) > GREEN + NOTGREEN) {
+               do {
+                       colour = NRAND(MI_NPIXELS(mi));
+               } while ((long) colour >= GREEN - NOTGREEN &&
+                        (long) colour <= GREEN + NOTGREEN);
+       }
+       start_angle = NRAND(360) * M_PI / 180;
+       inc_angle = 2 * M_PI / petals;
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       if (size > 2)
+               XFillArc(display, window, gc,
+                        center.x - size / 2, center.y - size / 2, size, size,
+                        0, 23040);
+       for (petal = 0; petal < petals; petal++) {
+               sine = SINF(start_angle + petal * inc_angle);
+               cosine = COSF(start_angle + petal * inc_angle);
+               if (size > 2)
+                       if (MI_NPIXELS(mi) <= 2) {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               for (inc = 0; inc < circles; inc++) {
+                                       newcenter.x = center.x + (int) (sine * (offset + delta * inc));
+                                       newcenter.y = center.y + (int) (cosine * (offset + delta * inc));
+                                       XDrawArc(display, window, gc,
+                                                newcenter.x - size / 2, newcenter.y - size / 2, size, size,
+                                                0, 23040);
+                               }
+                       }
+               if (MI_NPIXELS(mi) > 2 && MI_NPIXELS(mi) > GREEN + NOTGREEN)
+                       XSetForeground(display, gc, MI_PIXEL(mi, colour));
+               else
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               for (inc = 0; inc < circles; inc++) {
+                       newcenter.x = center.x + (int) (sine * (offset + delta * inc));
+                       newcenter.y = center.y + (int) (cosine * (offset + delta * inc));
+                       if (size < 2)
+                               XDrawPoint(display, window, gc, newcenter.x, newcenter.y);
+                       else
+                               XFillArc(display, window, gc,
+                                        newcenter.x - size / 2, newcenter.y - size / 2, size, size,
+                                        0, 23040);
+               }
+       }
+       return colour;
+}
+
+/* not green */
+static void
+drawcenter(ModeInfo * mi, XPoint center, int size, unsigned long petalcolour)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       unsigned long colour;
+
+       if (MI_NPIXELS(mi) > GREEN + NOTGREEN) {
+               do {
+                       /* Insure good contrast */
+                       colour = (NRAND(2 * MI_NPIXELS(mi) / 3) + petalcolour +
+                                 MI_NPIXELS(mi) / 6) % MI_NPIXELS(mi);
+               } while ((long) colour >= GREEN - NOTGREEN &&
+                        (long) colour <= GREEN + NOTGREEN);
+               XSetForeground(display, gc, MI_PIXEL(mi, colour));
+       } else
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       if (size < 2)
+               XDrawPoint(display, window, gc, center.x, center.y);
+       else
+               XFillArc(display, window, gc,
+                        center.x - size / 2, center.y - size / 2, size, size, 0, 23040);
+}
+
+static void
+drawdaisy(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       daisystruct *dp = &daisies[MI_SCREEN(mi)];
+       XPoint      stem_start, stem_stop;
+       int         height, droop;
+       unsigned long colour;
+
+       /* Care more about the flower being on the screen rather than the stem */
+#ifdef LINEAR
+       stem_stop.y = dp->meadow_y + dp->time * dp->step;
+       height = (NRAND(MAXHEIGHT - MINHEIGHT + 1) + MINHEIGHT) * dp->height / 300 *
+               2 * (dp->time + 20) / (dp->ndaisies + 20);
+#else
+       stem_stop.y = dp->meadow_y + (int) ((float) dp->time * dp->time *
+                                           dp->step / dp->ndaisies);
+       height = (NRAND(MAXHEIGHT - MINHEIGHT + 1) + MINHEIGHT) * dp->height / 300 *
+               2 * (dp->time * dp->time + 1) / (dp->ndaisies * dp->ndaisies + 1);
+#endif
+       stem_start.y = stem_stop.y + height;
+       if (dp->garden) {
+               stem_stop.x = ((LRAND() & 1) ? 1 : -1) *
+                       NRAND(dp->width / 4 * (dp->time + 1) / (dp->ndaisies + 20) +
+                             dp->width / 4) + dp->width / 2;
+       } else {
+               stem_stop.x = NRAND(dp->width);
+       }
+       /* Give about droop left or right with 25% randomness */
+       droop = ((LRAND() & 1) ? 1 : -1) * DROOP * (NRAND(50) + 75) / 100;
+       stem_start.x = stem_stop.x + droop * height / 100;
+       XSetLineAttributes(display, gc, height / 24 + 1,
+                          LineSolid, CapNotLast, JoinRound);
+       drawstem(mi, stem_start, stem_stop);
+       XSetLineAttributes(display, gc, 1, LineSolid, CapNotLast, JoinRound);
+       colour = drawpetals(mi, stem_stop, height / 6, 5, height / 32 + 1,
+                           height / 7, NRAND(6) + 6);
+       drawcenter(mi, stem_stop, height / 7, colour);
+}
+
+
+void
+init_daisy(ModeInfo * mi)
+{
+       daisystruct *dp;
+
+       if (daisies == NULL) {
+               if ((daisies = (daisystruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (daisystruct))) == NULL)
+                       return;
+       }
+       dp = &daisies[MI_SCREEN(mi)];
+
+       dp->width = MI_WIDTH(mi);
+       dp->height = MI_HEIGHT(mi);
+       dp->time = 0;
+       if (MI_IS_FULLRANDOM(mi))
+               dp->garden = (Bool) (LRAND() & 1);
+       else
+               dp->garden = garden;
+
+       dp->ndaisies = MI_COUNT(mi);
+       if (dp->ndaisies < -MINDAISIES)
+               dp->ndaisies = NRAND(-dp->ndaisies - MINDAISIES + 1) + MINDAISIES;
+       else if (dp->ndaisies < MINDAISIES)
+               dp->ndaisies = MINDAISIES;
+       dp->meadow_y = dp->height / 5;
+       dp->step = (float) (dp->height - 2 * dp->meadow_y) / (dp->ndaisies + 1.0);
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_daisy(ModeInfo * mi)
+{
+       daisystruct *dp = &daisies[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (dp->time < dp->ndaisies)
+               drawdaisy(mi);
+       if (++dp->time > MI_CYCLES(mi))
+               init_daisy(mi);
+}
+
+void
+release_daisy(ModeInfo * mi)
+{
+       if (daisies != NULL) {
+               (void) free((void *) daisies);
+               daisies = NULL;
+       }
+}
+
+void
+refresh_daisy(ModeInfo * mi)
+{
+       daisystruct *dp = &daisies[MI_SCREEN(mi)];
+
+       if (dp->time < dp->ndaisies) {
+               MI_CLEARWINDOW(mi);
+       } else {
+               init_daisy(mi);
+       }
+}
+
+#endif /* MODE_daisy */
diff --git a/xlockmore-4.14/modes/dclock.c b/xlockmore-4.14/modes/dclock.c
new file mode 100644 (file)
index 0000000..b6ec72d
--- /dev/null
@@ -0,0 +1,858 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* dclock --- floating digital clock or message */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)dclock.c     4.07 97/11/24 xlockmore";
+
+#endif
+/*-
+ * Copyright (C) 1995 by Michael Stembera <mrbig@fc.net>.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 07-May-99: New "savers" added for y2k and second millennium countdowns.
+ *            Tom Schmidt <tschmidt@micron.com>
+ * 04-Dec-98: New "savers" added for hiv, veg, and lab.
+ *            hiv one due to Kenneth Stailey <kstailey@disclosure.com>
+ * 10-Aug-98: Population Explosion and Tropical Forest Countdown stuff
+ *            I tried to get precise numbers but they may be off a few percent.
+ *            Whether or not, its still pretty scary IMHO. 
+ *            Although I am a US citizen... I have the default for area in
+ *            metric.  David Bagley <bagleyd@tux.org>
+ * 10-May-97: Compatible with xscreensaver
+ * 29-Aug-95: Written.
+ */
+
+/*-
+ *  Some of my calculations laid bare...  (I have a little problem with
+ *  the consistency of the numbers I got at the Bronx Zoo but proportions
+ *  were figured to be 160.70344 people a minute increase not 180 and
+ *  35.303144 hectares (87.198766 acres) a minute decrease not 247 (100 acres).
+ *  So I am going with these more conservative numbers.)
+ *
+ *  Time 0 is 0:00:00 1 Jan 1970 at least according to hard core UNIX fans
+ *  Minutes from 1  Jan 1970 to 21 Jun 1985:  8137440
+ *  Minutes from 21 Jun 1985 to 12 Jul 1988:  6867360
+ *                                    Total: 15004800
+ *
+ *  Population Explosion Saver (popex)
+ *  3,535,369,000 people (figured by extrapolation) 1 Jan 1970
+ *  4,843,083,596 people 21 Jun 1985 (Opening of Wild Asia in the Bronx Zoo)
+ *  5,946,692,000 people 12 Jul 1998 (David Bagley visits zoo ;) )
+ *  180 people a minute increase in global population (I heard 170 also)
+ *  260,000 people a day increase in global population
+ *
+ *  Tropical Forest Countdown Saver (forest)
+ *  1,184,193,000 hectares (figured by extrapolation) 1 Jan 1970
+ *    (2,924,959,000 acres)
+ *  896,916,700 hectares 21 Jun 1985 (Opening of Wild Asia in the Bronx Zoo)
+ *    (2,215,384,320 acres)
+ *  654,477,300 hectares 12 Jul 1998 (David Bagley visits zoo ;) )
+ *    (1,616,559,000 acres)
+ *  247 hectares a minute lost forever (1 hectare = 2.47 acres)
+ *
+ *  HIV Infection Counter Saver (hiv)
+ *  -130,828,080 cases (figured by extrapolation) 1 Jan 1970
+ *  (hmmm...)
+ *  36,503,000 3 Dec 1998 (from http://www.vers.com/aidsclock/INDEXA.HTM)
+ *  11 cases/min
+ *
+ *  365.25 * 24 * 60 =  525960 minutes in a year
+ *
+ *  Animal Research Counter Saver (lab)
+ *  Approximately 17-22 million animals are used in research each year.
+ *  OK so assume 17,000,000 / 525960 = 32.32184957 per minute
+ *  http://www.fcs.uga.edu/~mhulsey/GDB.html
+ *
+ *  Animal Consumation Counter Saver (veg)
+ *  Approximately 5 billion are consumed for food annually.
+ *  OK 5,000,000,000 / 525960 = 9506.426344209 per minute
+ *  http://www.fcs.uga.edu/~mhulsey/GDB.html
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Dclock"
+#define HACK_INIT init_dclock
+#define HACK_DRAW draw_dclock
+#define dclock_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*cycles: 10000 \n" \
+ "*ncolors: 64 \n"
+#define BRIGHT_COLORS
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#include "mode.h"
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "util.h"
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_dclock
+
+#ifndef METRIC
+#define METRIC 1
+#endif
+#if METRIC
+#ifdef NL
+# define AREA_STRING "Hectare"
+#else
+# define AREA_STRING "Hectares"
+#endif
+#define AREA_MIN 35.303144
+#define AREA_TIME_START 1184193000.0
+#else
+#ifdef NL
+# define AREA_STRING "Acre"
+#else
+# define AREA_STRING "Acres"
+#endif
+#define AREA_MIN 87.198766
+#define AREA_TIME_START 2924959000.0
+#endif
+#define PEOPLE_MIN 160.70344
+#define PEOPLE_TIME_START 3535369000.0
+#define HIV_MIN 11.0
+#define HIV_TIME_START -130828080.0
+#define LAB_MIN 32.32184957
+#define LAB_TIME_START 0
+#define VEG_MIN 9506.426344209
+#define VEG_TIME_START 0
+/* epoch time at midnight 1 January 2000 UTC */
+#define Y2K_TIME_START (((30 * 365) + 7) * 24 * 60 * 60)
+#define Y2001_TIME_START (Y2K_TIME_START + 366 * 24 * 60 * 60)
+
+#define DEF_POPEX  "False"
+#define DEF_FOREST "False"
+#define DEF_HIV    "False"
+#define DEF_LAB    "False"
+#define DEF_VEG    "False"
+#define DEF_Y2K    "False"
+#define DEF_Y2001  "False"
+
+static Bool popex;
+static Bool forest;
+static Bool hiv;
+static Bool lab;
+static Bool veg;
+static Bool y2k;
+static Bool millennium;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-popex", ".dclock.popex", XrmoptionNoArg, (caddr_t) "on"},
+       {"+popex", ".dclock.popex", XrmoptionNoArg, (caddr_t) "off"},
+       {"-forest", ".dclock.forest", XrmoptionNoArg, (caddr_t) "on"},
+       {"+forest", ".dclock.forest", XrmoptionNoArg, (caddr_t) "off"},
+       {"-hiv", ".dclock.hiv", XrmoptionNoArg, (caddr_t) "on"},
+       {"+hiv", ".dclock.hiv", XrmoptionNoArg, (caddr_t) "off"},
+       {"-lab", ".dclock.lab", XrmoptionNoArg, (caddr_t) "on"},
+       {"+lab", ".dclock.lab", XrmoptionNoArg, (caddr_t) "off"},
+       {"-veg", ".dclock.veg", XrmoptionNoArg, (caddr_t) "on"},
+       {"+veg", ".dclock.veg", XrmoptionNoArg, (caddr_t) "off"},
+       {"-y2k", ".dclock.y2k", XrmoptionNoArg, (caddr_t) "on"},
+       {"+y2k", ".dclock.y2k", XrmoptionNoArg, (caddr_t) "off"},
+       {"-millennium", ".dclock.millennium", XrmoptionNoArg, (caddr_t) "on"},
+       {"+millennium", ".dclock.millennium", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & popex, "popex", "PopEx", DEF_POPEX, t_Bool},
+       {(caddr_t *) & forest, "forest", "Forest", DEF_FOREST, t_Bool},
+       {(caddr_t *) & hiv, "hiv", "Hiv", DEF_HIV, t_Bool},
+       {(caddr_t *) & lab, "lab", "Lab", DEF_LAB, t_Bool},
+       {(caddr_t *) & veg, "veg", "Veg", DEF_VEG, t_Bool},
+       {(caddr_t *) & y2k, "y2k", "Y2K", DEF_Y2K, t_Bool},
+       {(caddr_t *) & millennium, "millennium", "Millennium", DEF_Y2001, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+popex", "turn on/off population explosion counter"},
+       {"-/+forest", "turn on/off tropical forest destruction counter"},
+       {"-/+hiv", "turn on/off HIV infection counter"},
+       {"-/+lab", "turn on/off Animal Research counter"},
+       {"-/+veg", "turn on/off Animal Consumation counter"},
+       {"-/+y2k", "turn on/off Year 2000 countdown"},
+       {"-/+millennium", "turn on/off 3rd Millennium (1 January 2001) countdown"}
+};
+
+ModeSpecOpt dclock_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   dclock_description =
+{"dclock", "init_dclock", "draw_dclock", "release_dclock",
+ "refresh_dclock", "init_dclock", NULL, &dclock_opts,
+ 10000, 1, 10000, 1, 0.3, 64, "",
+ "Shows a floating digital clock or message", 0, NULL};
+
+#endif
+
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+#include <time.h>
+
+#ifdef FR
+#define POPEX_STRING "Population mondiale"
+#define PEOPLE_STRING " personnes"
+#define FOREST_STRING "Taille des forêts tropicales"
+#define TROPICAL_STRING " zones tropicales en "
+#define HIV_STRING "Infections par le SIDA dans le monde"
+#define CASES_STRING " cas"
+#define LAB_STRING "Animaux utilisés dans la recherche"
+#define VEG_STRING "Animaux consommés comme aliments par l'homme"
+#define YEAR_STRING " cette année"
+#define Y2K_STRING "Décompte pour l'an 2000 (1er Janvier 2000)"
+#define POST_Y2K_STRING "Temps depuis l'an 2000 (1er Janvier 2000)"
+#define Y2001_STRING "Décompte pour le Second Millénaire (1er Janvier 2001)"
+#define POST_Y2001_STRING "Temps depuis le Second Millénaire (1er Janvier 2001)"
+#define DAY "jour"
+#define DAYS "jours"
+#define HOUR "heure"
+#define HOURS "heures"
+#define MINUTE "minute"
+#define MINUTES "minutes"
+#define SECOND "seconde"
+#define SECONDS "secondes"
+#else
+#ifdef NL
+#define POPEX_STRING "Wereld populatie"
+#define PEOPLE_STRING " Mensen"
+#define FOREST_STRING "Aantal tropische wouden"
+#define TROPICAL_STRING " Tropisch gebied in "
+#define HIV_STRING "Huidige staat HIV infecties wereldwijd"
+#define CASES_STRING " gevallen"
+#define LAB_STRING "Verbruikt tijdens onderzoek"
+#define VEG_STRING "Opgegeten door de mens"
+#define YEAR_STRING " dieren dit jaar"
+#define Y2K_STRING "Aftellen tot Y2K (1 Januari 2000, 0.00 uur)"
+#define POST_Y2K_STRING "Tijd sinds Y2K (1 Januari 2000)"
+#define Y2001_STRING "Aftellen tot het einde van het tweede Millennium (1 Januari 2001, 0.00 uur)"
+#define POST_Y2001_STRING "Verstreken tijd sinds het begin van het derde Millennium (1 Januari 2001)"
+
+#define Y2001_STRING "Aftellen tot het tweede millennium (1 Januari 2001)"
+#define POST_Y2001_STRING "Tijd sinds het tweede millennium (1 Januari 2001)"
+#define DAY "dag"
+#define DAYS "dagen"
+#define HOUR "uur"
+#define HOURS "uren"
+#define MINUTE "minuut"
+#define MINUTES "minuten"
+#define SECOND "seconde"
+#define SECONDS "seconden"
+#else
+#define POPEX_STRING "World Population"
+#define PEOPLE_STRING " People"
+#define FOREST_STRING "Tropical Forest Countdown"
+#define TROPICAL_STRING " Tropical Forest in "
+#define HIV_STRING "Current HIV Infections World Wide"
+#define CASES_STRING " Cases"
+#define LAB_STRING "Used in research"
+#define VEG_STRING "Consumed for Food by Mankind"
+#define YEAR_STRING " animals this year"
+#define Y2K_STRING "Countdown to Y2K (1 January 2000, 0:00 hour)"
+#define POST_Y2K_STRING "Time since Y2K (1 January 2000)"
+#define Y2001_STRING "Countdown to the end of the Second Millennium (1 January 2001, 0:00 hour)"
+#define POST_Y2001_STRING "Time since the start of the Third Millennium (1 January 2001)"
+#define DAY "day"
+#define DAYS "days"
+#define HOUR "hour"
+#define HOURS "hours"
+#define MINUTE "minute"
+#define MINUTES "minutes"
+#define SECOND "second"
+#define SECONDS "seconds"
+#endif
+#endif
+
+#define font_height(f) (f->ascent + f->descent)
+
+extern XFontStruct *getFont(Display * display);
+
+typedef struct {
+       int         color;
+       short       height, width;
+       char       *str, str1[40], str2[40], str1old[80], str2old[80];
+       char       *str1pta, *str2pta, *str1ptb, *str2ptb;
+       time_t      timenew, timeold;
+       int         tzoffset;
+       short       maxx, maxy, clockx, clocky;
+       short       text_height, text_width, text_width1, text_width2;
+       short       text_start1, text_start2;
+       short       hour;
+       short       dx, dy;
+       int         done;
+       int         pixw, pixh;
+       Pixmap      pixmap;
+       GC          fgGC, bgGC;
+       Bool        popex, forest, hiv, lab, veg, y2k, millennium;
+} dclockstruct;
+
+static dclockstruct *dclocks = NULL;
+
+static XFontStruct *mode_font = None;
+
+#define BASE 10.0
+#define GROUP 3
+static double logbase;
+
+static unsigned long
+timeAtLastNewYear(unsigned long timeNow)
+{
+  int year = 1970, days; /* Beginning of time */
+       unsigned long  lastNewYear = 0;
+       unsigned long secondCount = 0;
+
+       while (lastNewYear + secondCount < timeNow) {
+               lastNewYear += secondCount;
+               days = 365;
+               if ((!(year % 400)) || ((year % 100) && (!(year % 4))))
+                       days++;
+               secondCount = days * 24 * 60 * 60;
+               year++;
+       }
+       return lastNewYear;
+}
+
+static void
+convert(double x, char *string)
+{
+       int         i, j, k = 0;
+       int         place = (int) (log(x) / logbase);
+       double      divisor = 1.0;
+
+       for (i = 0; i < place; i++)
+               divisor *= BASE;
+
+       for (i = place; i >= 0; i--) {
+               j = (int) (x / divisor);
+               string[k++] = (char) j + '0';
+               x -= j * divisor;
+               divisor /= BASE;
+               if ((i > 0) && (i % GROUP == 0)) {
+                       string[k++] = ',';
+               }
+       }
+       string[k++] = '\0';
+}
+
+static void
+dayhrminsec(long timeCount, int tzoffset, char *string)
+{
+       int      days, hours, minutes, secs;
+       char    *buf;
+
+       timeCount = abs(timeCount);
+       days = timeCount / 86400;
+       hours = (timeCount / 3600) % 24;
+       minutes = (timeCount / 60) % 60;
+       secs = timeCount % 60;
+       buf = (char *) malloc(16);
+       (void) sprintf(string, "%d ", days);
+       if (days == 1)
+               (void) strcat(string, DAY);
+       else
+               (void) strcat(string, DAYS);
+       (void) sprintf(buf, ", %d ", hours);
+       (void) strcat(string, buf);
+       if (hours == 1)
+               (void) strcat(string, HOUR);
+       else
+               (void) strcat(string, HOURS);
+       (void) sprintf(buf, ", %d ", minutes);
+       (void) strcat(string, buf);
+       if (minutes == 1)
+               (void) strcat(string, MINUTE);
+       else
+               (void) strcat(string, MINUTES);
+       (void) sprintf(buf, ", %d ", secs);
+       (void) strcat(string, buf);
+       if (secs == 1)
+               (void) strcat(string, SECOND);
+       else
+               (void) strcat(string, SECONDS);
+       if (!tzoffset)
+               (void) strcat(string, " (UTC)");
+       (void) free((void *) buf);
+       buf = NULL;
+}
+
+static void
+drawDclock(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       dclockstruct *dp = &dclocks[MI_SCREEN(mi)];
+       short       xold, yold;
+       char       *tmppt;
+
+       if (!dp->popex && !dp->forest && !dp->hiv && !dp->lab && !dp->veg &&
+           !dp->y2k && !dp->millennium) {
+               if (dp->timeold != (dp->timenew = time((time_t *) NULL))) {
+                       /* only parse if time has changed */
+                       dp->timeold = dp->timenew;
+                       dp->str = ctime(&dp->timeold);
+
+                       if (!dp->popex && !dp->forest && !dp->hiv && !dp->lab &&
+                           !dp->veg && !dp->y2k && !dp->millennium) {
+
+                               /* keep last disp time so it can be cleared even if it changed */
+                               tmppt = dp->str1ptb;
+                               dp->str1ptb = dp->str1pta;
+                               dp->str1pta = tmppt;
+
+                               /* copy the hours portion for 24 to 12 hr conversion */
+                               (void) strncpy(dp->str1pta, (dp->str + 11), 8);
+                               dp->hour = (short) (dp->str1pta[0] - 48) * 10 +
+                                       (short) (dp->str1pta[1] - 48);
+                               if (dp->hour > 12) {
+                                       dp->hour -= 12;
+                                       (void) strcpy(dp->str1pta + 8, " PM");
+                               } else {
+                                       if (dp->hour == 0)
+                                               dp->hour += 12;
+                                       (void) strcpy(dp->str1pta + 8, " AM");
+                               }
+                               dp->str1pta[0] = (dp->hour / 10) + 48;
+                               dp->str1pta[1] = (dp->hour % 10) + 48;
+                               if (dp->str1pta[0] == '0')
+                                       dp->str1pta[0] = ' ';
+                               /* keep last disp time so it can be cleared even if it changed */
+                       }
+                       tmppt = dp->str2ptb;
+                       dp->str2ptb = dp->str2pta;
+                       dp->str2pta = tmppt;
+
+                       /* copy day month */
+                       (void) strncpy(dp->str2pta, dp->str, 11);
+                       /* copy year */
+                       (void) strncpy(dp->str2pta + 11, (dp->str + 20), 4);
+               }
+       } else {
+               unsigned long timeNow, timeLocal;
+               timeNow = seconds();
+               timeLocal = timeNow - dp->tzoffset;
+
+               if (dp->popex) {
+                       convert(PEOPLE_TIME_START + (PEOPLE_MIN / 60.0) * timeNow, dp->str2);
+                       (void) strcat(dp->str2, PEOPLE_STRING);
+                       dp->str2pta = dp->str2;
+                       dp->str2ptb = dp->str2pta;
+               } else if (dp->forest) {
+                       convert(AREA_TIME_START - (AREA_MIN / 60.0) * timeNow, dp->str2);
+                       (void) strcat(dp->str2, TROPICAL_STRING);
+                       (void) strcat(dp->str2, AREA_STRING);
+                       dp->str2pta = dp->str2;
+                       dp->str2ptb = dp->str2pta;
+               } else if (dp->hiv) {
+                       convert(HIV_TIME_START + (HIV_MIN / 60.0) * timeNow, dp->str2);
+                       (void) strcat(dp->str2, CASES_STRING);
+                       dp->str2pta = dp->str2;
+                       dp->str2ptb = dp->str2pta;
+               } else if (dp->lab) {
+                       convert((LAB_MIN / 60.0) * (timeNow - timeAtLastNewYear(timeNow)),
+                               dp->str2);
+                       (void) strcat(dp->str2, YEAR_STRING);
+                       dp->str2pta = dp->str2;
+                       dp->str2ptb = dp->str2pta;
+               } else if (dp->veg) {
+                       convert((VEG_MIN / 60.0) * (timeNow - timeAtLastNewYear(timeNow)),
+                               dp->str2);
+                       (void) strcat(dp->str2, YEAR_STRING);
+                       dp->str2pta = dp->str2;
+                       dp->str2ptb = dp->str2pta;
+               } else if (dp->y2k) {
+                       if (Y2K_TIME_START >= timeLocal)
+                               dp->str1pta = Y2K_STRING;
+                       else
+                               dp->str1pta = POST_Y2K_STRING;
+                       dp->str1ptb = dp->str1pta;
+                       dayhrminsec(Y2K_TIME_START - timeLocal, dp->tzoffset, dp->str2);
+                       dp->str2pta = dp->str2;
+                       dp->str2ptb = dp->str2pta;
+               } else if (dp->millennium) {
+                       if (Y2001_TIME_START >= timeLocal)
+                               dp->str1pta = Y2001_STRING;
+                       else
+                               dp->str1pta = POST_Y2001_STRING;
+                       dp->str1ptb = dp->str1pta;
+                       dayhrminsec(Y2001_TIME_START - timeLocal, dp->tzoffset, dp->str2);
+                       dp->str2pta = dp->str2;
+                       dp->str2ptb = dp->str2pta;
+               }
+       }
+       /* Recalculate string width since it can change */
+       xold = dp->clockx;
+       yold = dp->clocky;
+       dp->text_width1 = XTextWidth(mode_font, dp->str1pta, strlen(dp->str1pta));
+       dp->text_width2 = XTextWidth(mode_font, dp->str2pta, strlen(dp->str2pta));
+       if (dp->text_width1 > dp->text_width2) {
+               dp->text_width = dp->text_width1;
+               dp->text_start1 = 0;
+               dp->text_start2 = (dp->text_width - dp->text_width2) / 2;
+       } else {
+               dp->text_width = dp->text_width2;
+               dp->text_start1 = (dp->text_width - dp->text_width1) / 2;
+               dp->text_start2 = 0;
+       }
+       dp->width = MI_WIDTH(mi);
+       dp->height = MI_HEIGHT(mi);
+       dp->maxx = dp->width - dp->text_width;
+       dp->maxy = dp->height - dp->text_height - mode_font->descent;
+       dp->clockx += dp->dx;
+       dp->clocky += dp->dy;
+       if (dp->maxx < dp->text_start1) {
+               if (dp->clockx < dp->maxx + dp->text_start1 ||
+                   dp->clockx > dp->text_start1) {
+                       dp->dx = -dp->dx;
+                       dp->clockx += dp->dx;
+               }
+       } else if (dp->maxx > dp->text_start1) {
+               if (dp->clockx >= dp->maxx + dp->text_start1 ||
+                   dp->clockx <= dp->text_start1) {
+                       dp->dx = -dp->dx;
+                       dp->clockx += dp->dx;
+               }
+       }
+       if (dp->maxy < mode_font->ascent) {
+               if (dp->clocky > mode_font->ascent || dp->clocky < dp->maxy) {
+                       dp->dy = -dp->dy;
+                       dp->clocky += dp->dy;
+               }
+       } else if (dp->maxy > mode_font->ascent) {
+               if (dp->clocky > dp->maxy || dp->clocky < mode_font->ascent) {
+                       dp->dy = -dp->dy;
+                       dp->clocky += dp->dy;
+               }
+       }
+       if (dp->pixw != dp->text_width || dp->pixh != 2 * dp->text_height) {
+               XGCValues   gcv;
+
+               if (dp->fgGC)
+                       XFreeGC(display, dp->fgGC);
+               if (dp->bgGC)
+                       XFreeGC(display, dp->bgGC);
+               if (dp->pixmap) {
+                       XFreePixmap(display, dp->pixmap);
+                       MI_CLEARWINDOWCOLORMAPFAST(mi, gc, MI_BLACK_PIXEL(mi));
+               }
+               dp->pixw = dp->text_width;
+               dp->pixh = 2 * dp->text_height;
+               dp->pixmap = XCreatePixmap(display, window, dp->pixw, dp->pixh, 1);
+               gcv.font = mode_font->fid;
+               gcv.background = 0;
+               gcv.foreground = 1;
+               gcv.graphics_exposures = False;
+               dp->fgGC = XCreateGC(display, dp->pixmap,
+                                    GCForeground | GCBackground | GCGraphicsExposures | GCFont, &gcv);
+               gcv.foreground = 0;
+               dp->bgGC = XCreateGC(display, dp->pixmap,
+                                    GCForeground | GCBackground | GCGraphicsExposures | GCFont, &gcv);
+       }
+       XFillRectangle(display, dp->pixmap, dp->bgGC, 0, 0, dp->pixw, dp->pixh);
+
+       (void) XDrawString(display, dp->pixmap, dp->fgGC,
+                          dp->text_start1, mode_font->ascent,
+                          dp->str1pta, strlen(dp->str1pta));
+       (void) XDrawString(display, dp->pixmap, dp->fgGC,
+                       dp->text_start2, mode_font->ascent + dp->text_height,
+                          dp->str2pta, strlen(dp->str2pta));
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       /* This could leave screen dust on the screen if the width changes
+          But that only happens once a day...
+          ... this is solved by the ClearWindow above
+        */
+       ERASE_IMAGE(display, window, gc,
+           (dp->clockx - dp->text_start1), (dp->clocky - mode_font->ascent),
+                   (xold - dp->text_start1), (yold - mode_font->ascent),
+                   dp->pixw, dp->pixh);
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, dp->color));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       XCopyPlane(display, dp->pixmap, window, gc,
+                  0, 0, dp->text_width, 2 * dp->text_height,
+               dp->clockx - dp->text_start1, dp->clocky - mode_font->ascent,
+                  1L);
+}
+
+void
+init_dclock(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       dclockstruct *dp;
+       unsigned long timeNow, timeLocal;
+#if defined(HAVE_TZSET) && !(defined(BSD) && BSD >= 199306)
+       extern long timezone;
+#endif
+
+       if (dclocks == NULL) {
+               logbase = log(BASE);
+               if ((dclocks = (dclockstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (dclockstruct))) == NULL)
+                       return;
+       }
+       dp = &dclocks[MI_SCREEN(mi)];
+
+       dp->width = MI_WIDTH(mi);
+       dp->height = MI_HEIGHT(mi);
+
+       MI_CLEARWINDOW(mi);
+
+       dp->popex = False;
+       dp->forest = False;
+       dp->hiv = False;
+       dp->lab = False;
+       dp->veg = False;
+       dp->y2k = False;
+       dp->millennium = False;
+       if (MI_IS_FULLRANDOM(mi)) {
+               switch (NRAND(8)) {
+                       case 1:
+                               dp->popex = True;
+                               break;
+                       case 2:
+                               dp->forest = True;
+                               break;
+                       case 3:
+                               dp->hiv = True;
+                               break;
+                       case 4:
+                               dp->lab = True;
+                               break;
+                       case 5:
+                               dp->veg = True;
+                               break;
+                       case 6:
+                               dp->y2k = True;
+                               break;
+                       case 7:
+                               dp->millennium = True;
+                               break;
+                       default:
+                               break;
+               }
+       } else { /* first come, first served */
+               dp->popex = popex;
+               dp->forest = forest;
+               dp->hiv = hiv;
+               dp->lab = lab;
+               dp->veg = veg;
+               dp->y2k = y2k;
+               dp->millennium = millennium;
+       }
+
+       if (mode_font == None)
+               mode_font = getFont(display);
+       if (!dp->done) {
+               dp->done = 1;
+               if (mode_font != None)
+                       XSetFont(display, MI_GC(mi), mode_font->fid);
+       }
+       /* (void)time(&dp->timenew); */
+#if defined(HAVE_TZSET) && (!defined(HAVE_TIMELOCAL) || (defined(BSD) && BSD >= 199306))
+       (void) tzset();
+#endif
+       dp->timeold = dp->timenew = time((time_t *) NULL);
+#if defined(HAVE_TIMELOCAL) && !(defined(BSD) && BSD >= 199306)
+       if (!dp->tzoffset)
+               dp->tzoffset = timelocal(&dp->timeold) - timegm(&dp->timeold);
+#else
+#ifdef HAVE_TZSET
+       dp->tzoffset = (int)timezone;
+#endif
+#endif
+       if (dp->tzoffset > 86400 || dp->tzoffset < -86400)
+               dp->tzoffset = 0;
+       dp->str = ctime(&dp->timeold);
+       dp->dx = (LRAND() & 1) ? 1 : -1;
+       dp->dy = (LRAND() & 1) ? 1 : -1;
+
+       timeNow = seconds();
+       timeLocal = timeNow - dp->tzoffset;
+       if (dp->popex) {
+               dp->str1pta = POPEX_STRING;
+               dp->str1ptb = dp->str1pta;
+       } else if (dp->forest) {
+               dp->str1pta = FOREST_STRING;
+               dp->str1ptb = dp->str1pta;
+       } else if (dp->hiv) {
+               dp->str1pta = HIV_STRING;
+               dp->str1ptb = dp->str1pta;
+       } else if (dp->lab) {
+               dp->str1pta = LAB_STRING;
+               dp->str1ptb = dp->str1pta;
+       } else if (dp->veg) {
+               dp->str1pta = VEG_STRING;
+               dp->str1ptb = dp->str1pta;
+       } else if (dp->y2k) {
+               if (Y2K_TIME_START >= timeLocal)
+                       dp->str1pta = Y2K_STRING;
+               else
+                       dp->str1pta = POST_Y2K_STRING;
+               dp->str1ptb = dp->str1pta;
+       } else if (dp->millennium) {
+               if (Y2001_TIME_START >= timeLocal)
+                       dp->str1pta = Y2001_STRING;
+               else
+                       dp->str1pta = POST_Y2001_STRING;
+               dp->str1ptb = dp->str1pta;
+       } else {
+               (void) strncpy(dp->str1, (dp->str + 11), 8);
+               dp->hour = (short) (dp->str1[0] - 48) * 10 + (short) (dp->str1[1] - 48);
+               if (dp->hour > 12) {
+                       dp->hour -= 12;
+                       (void) strcpy(dp->str1 + 8, " PM");
+               } else {
+                       if (dp->hour == 0)
+                               dp->hour += 12;
+                       (void) strcpy(dp->str1 + 8, " AM");
+               }
+               dp->str1[0] = (dp->hour / 10) + 48;
+               dp->str1[1] = (dp->hour % 10) + 48;
+               if (dp->str1[0] == '0')
+                       dp->str1[0] = ' ';
+               dp->str1[11] = 0;       /* terminate dp->str1 */
+               dp->str1old[11] = 0;    /* terminate dp->str1old */
+
+               (void) strncpy(dp->str2, dp->str, 11);
+               (void) strncpy(dp->str2 + 11, (dp->str + 20), 4);
+               dp->str2[15] = 0;       /* terminate dp->str2 */
+               dp->str2old[15] = 0;    /* terminate dp->str2old */
+
+               dp->str1pta = dp->str1;
+               dp->str1ptb = dp->str1old;
+       }
+       if (dp->popex) {
+               convert(PEOPLE_TIME_START + (PEOPLE_MIN / 60.0) * timeNow, dp->str2);
+               (void) strcat(dp->str2, PEOPLE_STRING);
+               dp->str2pta = dp->str2;
+               dp->str2ptb = dp->str2pta;
+       } else if (dp->forest) {
+               convert(AREA_TIME_START - (AREA_MIN / 60.0) * timeNow, dp->str2);
+               (void) strcat(dp->str2, TROPICAL_STRING);
+               (void) strcat(dp->str2, AREA_STRING);
+               dp->str2pta = dp->str2;
+               dp->str2ptb = dp->str2pta;
+       } else if (dp->hiv) {
+               convert(HIV_TIME_START + (HIV_MIN / 60.0) * timeNow, dp->str2);
+               (void) strcat(dp->str2, CASES_STRING);
+               dp->str2pta = dp->str2;
+               dp->str2ptb = dp->str2pta;
+       } else if (dp->lab) {
+               convert((LAB_MIN / 60.0) * (timeNow - timeAtLastNewYear(timeNow)),
+                       dp->str2);
+               (void) strcat(dp->str2, YEAR_STRING);
+               dp->str2pta = dp->str2;
+               dp->str2ptb = dp->str2pta;
+       } else if (dp->veg) {
+               convert((VEG_MIN / 60.0) * (timeNow - timeAtLastNewYear(timeNow)),
+                       dp->str2);
+               (void) strcat(dp->str2, YEAR_STRING);
+               dp->str2pta = dp->str2;
+       } else if (dp->y2k) {
+               dayhrminsec(Y2K_TIME_START - timeLocal, dp->tzoffset, dp->str2);
+               dp->str2pta = dp->str2;
+       } else if (dp->millennium) {
+               dayhrminsec(Y2001_TIME_START - timeLocal, dp->tzoffset, dp->str2);
+               dp->str2pta = dp->str2;
+       } else {
+               dp->str2pta = dp->str2;
+               dp->str2ptb = dp->str2old;
+       }
+
+       dp->text_height = font_height(mode_font);
+       dp->text_width1 = XTextWidth(mode_font, dp->str1pta, strlen(dp->str1pta));
+       dp->text_width2 = XTextWidth(mode_font, dp->str2pta, strlen(dp->str2pta));
+       if (dp->text_width1 > dp->text_width2) {
+               dp->text_width = dp->text_width1;
+               dp->text_start1 = 0;
+               dp->text_start2 = (dp->text_width - dp->text_width2) / 2;
+       } else {
+               dp->text_width = dp->text_width2;
+               dp->text_start1 = (dp->text_width - dp->text_width1) / 2;
+               dp->text_start2 = 0;
+       }
+       dp->maxx = dp->width - dp->text_width;
+       dp->maxy = dp->height - dp->text_height - mode_font->descent;
+       if (dp->maxx == 0)
+               dp->clockx = dp->text_start1;
+       else if (dp->maxx < 0)
+               dp->clockx = -NRAND(-dp->maxx) + dp->text_start1;
+       else
+               dp->clockx = NRAND(dp->maxx) + dp->text_start1;
+       if (dp->maxy - mode_font->ascent == 0)
+               dp->clocky = mode_font->ascent;
+       else if (dp->maxy - mode_font->ascent < 0)
+               dp->clocky = -NRAND(mode_font->ascent - dp->maxy) + mode_font->ascent;
+       else
+               dp->clocky = NRAND(dp->maxy - mode_font->ascent) + mode_font->ascent;
+
+       if (MI_NPIXELS(mi) > 2)
+               dp->color = NRAND(MI_NPIXELS(mi));
+
+       /* don't want any exposure events from XCopyPlane */
+       XSetGraphicsExposures(display, MI_GC(mi), False);
+}
+
+void
+draw_dclock(ModeInfo * mi)
+{
+       dclockstruct *dp = &dclocks[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       drawDclock(mi);
+       if (MI_NPIXELS(mi) > 2) {
+               if (++dp->color >= MI_NPIXELS(mi))
+                       dp->color = 0;
+       }
+}
+
+void
+release_dclock(ModeInfo * mi)
+{
+       if (dclocks != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       dclockstruct *dp = &dclocks[screen];
+                       Display    *display = MI_DISPLAY(mi);
+
+                       if (dp->fgGC)
+                               XFreeGC(display, dp->fgGC);
+                       if (dp->bgGC)
+                               XFreeGC(display, dp->bgGC);
+                       if (dp->pixmap)
+                               XFreePixmap(display, dp->pixmap);
+
+               }
+               (void) free((void *) dclocks);
+               dclocks = NULL;
+       }
+       if (mode_font != None) {
+               XFreeFont(MI_DISPLAY(mi), mode_font);
+               mode_font = None;
+       }
+}
+
+void
+refresh_dclock(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_dclock */
diff --git a/xlockmore-4.14/modes/decay.c b/xlockmore-4.14/modes/decay.c
new file mode 100644 (file)
index 0000000..98643e0
--- /dev/null
@@ -0,0 +1,345 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* decay --- decayscreen */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)decay.c  4.14 99/03/17 xlockmore";
+
+#endif
+
+/* xscreensaver, Copyright (c) 1992, 1993, 1994, 1996, 1997 
+ * Jamie Zawinski <jwz@jwz.org>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ */
+
+/* decayscreen
+ *
+ * Based on slidescreen program from the xscreensaver application and the
+ * decay program for Sun framebuffers.  This is the comment from the decay.c
+ * file:
+
+ * decay.c
+ *   find the screen bitmap for the console and make it "decay" by
+ *   randomly shifting random rectangles by one pixelwidth at a time.
+ *
+ *   by David Wald, 1988
+ *        rewritten by Natuerlich!
+ *   based on a similar "utility" on the Apollo ring at Yale.
+
+ * X version by
+ *
+ *  Vivek Khera <khera@cs.duke.edu>
+ *  5-AUG-1993
+ *
+ *  Hacked by jwz, 28-Nov-97 (sped up and added new motion directions)
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Decay"
+#define HACK_INIT init_decay
+#define HACK_DRAW draw_decay
+#define decay_opts xlockmore_opts
+#define DEFAULTS "*delay: 200000 \n" \
+ "*count: 6 \n" \
+ "*cycles: 30 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"    /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"    /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#include "iostuff.h"
+#include "color.h"
+
+#ifdef MODE_decay
+
+extern Bool hide;
+
+ModeSpecOpt decay_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   decay_description =
+{"decay", "init_decay", "draw_decay", "release_decay",
+ "refresh_decay", "init_decay", NULL, &decay_opts,
+ 200000, 6, 30, 1, 64, 0.3, "",
+ "Shows a decaying screen", 0, NULL};
+
+#endif
+
+#define DECAY_WIDTH   image_width
+#define DECAY_HEIGHT    image_height
+#define DECAY_BITS    image_bits
+#include "decay.xbm"
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+#define DECAY_NAME    image_name
+#include "decay.xpm"
+#define DEFAULT_XPM 1
+#endif
+
+typedef struct
+{
+       XPoint   windowsize;
+       int      mode;
+
+       XPoint   randompos, randpos;
+       XImage  *logo;
+       GC       backGC;
+       Colormap cmap;
+       int      graphics_format;
+       unsigned long black;
+       Bool     hide;
+} decaystruct;
+
+static decaystruct *   decay_info = NULL;
+
+#define SHUFFLE 0
+#define UP 1
+#define LEFT 2
+#define RIGHT 3
+#define DOWN 4
+#define UPLEFT 5
+#define DOWNLEFT 6
+#define UPRIGHT 7
+#define DOWNRIGHT 8
+#define IN 9
+#define OUT 10
+#define        DEGREE  1
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       decaystruct *dp = &decay_info[MI_SCREEN(mi)];
+
+       if (dp->hide) {
+               if  (!dp->logo)
+                       getImage(mi, &dp->logo, DECAY_WIDTH, DECAY_HEIGHT, DECAY_BITS,
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                               DEFAULT_XPM, DECAY_NAME,
+#endif
+                               &dp->graphics_format, &dp->cmap, &dp->black);
+#ifndef STANDALONE
+               if (dp->cmap != None) {
+                       setColormap(display, window, dp->cmap, MI_IS_INWINDOW(mi));
+                       if (dp->backGC == None) {
+                               XGCValues   xgcv;
+
+                               xgcv.background = dp->black;
+                               dp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+                       }
+               } else
+#endif /* STANDALONE */
+               {
+                       dp->black = MI_BLACK_PIXEL(mi);
+                       dp->backGC = MI_GC(mi);
+               }
+       }
+#ifndef STANDALONE
+       else {
+               setColormap(display, window, DefaultColormapOfScreen(MI_SCREENPTR(mi)), MI_IS_INWINDOW(mi));
+               dp->backGC = MI_GC(mi);
+       }
+#endif /* STANDALONE */
+}
+
+static void
+free_stuff(Display * display, decaystruct * dp)
+{
+       if (dp->cmap != None) {
+               if (dp->backGC != None) {
+                       XFreeGC(display, dp->backGC);
+                       dp->backGC = None;
+               }
+               XFreeColormap(display, dp->cmap);
+               dp->cmap = None;
+       }
+       dp->backGC = None;
+       if (dp->hide)
+               destroyImage(&dp->logo, &dp->graphics_format);
+}
+
+void
+init_decay (ModeInfo * mi)
+{
+       Display *display = MI_DISPLAY(mi);
+       Window window = MI_WINDOW(mi);
+       decaystruct *dp;
+       XGCValues gcv;
+       long gcflags;
+
+       char *s = "random";
+       
+       if (decay_info == NULL)
+               decay_info = (decaystruct *) calloc(MI_NUM_SCREENS(mi),
+                                               sizeof(decaystruct));
+       if(decay_info == NULL) return;
+       dp = &decay_info[MI_SCREEN(mi)];
+       
+       
+       if      (s && !strcmp(s, "shuffle")) dp->mode = SHUFFLE;
+       else if (s && !strcmp(s, "up")) dp->mode = UP;
+       else if (s && !strcmp(s, "left")) dp->mode = LEFT;
+       else if (s && !strcmp(s, "right")) dp->mode = RIGHT;
+       else if (s && !strcmp(s, "down")) dp->mode = DOWN;
+       else if (s && !strcmp(s, "upleft")) dp->mode = UPLEFT;
+       else if (s && !strcmp(s, "downleft")) dp->mode = DOWNLEFT;
+       else if (s && !strcmp(s, "upright")) dp->mode = UPRIGHT;
+       else if (s && !strcmp(s, "downright")) dp->mode = DOWNRIGHT;
+       else if (s && !strcmp(s, "in")) dp->mode = IN;
+       else if (s && !strcmp(s, "out")) dp->mode = OUT;
+       else {
+               if (s && *s && !!strcmp(s, "random"))
+                       fprintf(stderr, "%s: unknown mode %s\n", ProgramName, s);
+               dp->mode = LRAND() % (OUT+1);
+       }
+
+       if (MI_IS_FULLRANDOM(mi) && !hide)
+               dp->hide = (Bool) (LRAND() & 1);
+       else
+               dp->hide = hide;
+
+
+       dp->windowsize.x = MI_WIDTH(mi);
+       dp->windowsize.y = MI_HEIGHT(mi);
+       init_stuff(mi);
+       if (dp->hide) {
+               /* don't want any exposure events from XCopyArea */
+               XSetGraphicsExposures(display, dp->backGC, False);
+               MI_CLEARWINDOWCOLORMAP(mi, dp->backGC, dp->black);
+               dp->randompos.x =
+                       NRAND(MAX((dp->windowsize.x - dp->logo->width), 1));
+                dp->randompos.y =
+                       NRAND(MAX((dp->windowsize.y - dp->logo->height), 1));
+               if (MI_NPIXELS(mi) <= 2)
+                       XSetForeground(display, dp->backGC, MI_WHITE_PIXEL(mi));
+               else
+                       XSetForeground(display, dp->backGC, MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))));
+               (void) XPutImage(display, window, dp->backGC, dp->logo,
+                       (int) (NRAND(MAX(1, (dp->logo->width - dp->windowsize.x)))),
+                       (int) (NRAND(MAX(1, (dp->logo->height - dp->windowsize.y)))),
+                                 dp->randompos.x, dp->randompos.y,
+                                 dp->windowsize.x, dp->windowsize.y);
+
+       } else {
+               XCopyArea (MI_DISPLAY(mi), MI_ROOT_PIXMAP(mi), MI_WINDOW(mi),
+                      dp->backGC, 0, 0, MI_WIDTH(mi), MI_HEIGHT(mi),
+                      0, 0);
+               XFlush(MI_DISPLAY(mi));
+       }
+}
+
+
+/*
+ * perform one iteration of decay
+ */
+void
+draw_decay (ModeInfo * mi)
+{
+    int left, top, width, height, toleft, totop;
+
+#define L 101
+#define R 102
+#define U 103
+#define D 104
+    static int no_bias[]        = { L,L,L,L, R,R,R,R, U,U,U,U, D,D,D,D };
+    static int up_bias[]        = { L,L,L,L, R,R,R,R, U,U,U,U, U,U,D,D };
+    static int down_bias[]      = { L,L,L,L, R,R,R,R, U,U,D,D, D,D,D,D };
+    static int left_bias[]      = { L,L,L,L, L,L,R,R, U,U,U,U, D,D,D,D };
+    static int right_bias[]     = { L,L,R,R, R,R,R,R, U,U,U,U, D,D,D,D };
+
+    static int upleft_bias[]    = { L,L,L,L, L,R,R,R, U,U,U,U, U,D,D,D };
+    static int downleft_bias[]  = { L,L,L,L, L,R,R,R, U,U,U,D, D,D,D,D };
+    static int upright_bias[]   = { L,L,L,R, R,R,R,R, U,U,U,U, U,D,D,D };
+    static int downright_bias[] = { L,L,L,R, R,R,R,R, U,U,U,D, D,D,D,D };
+    static int *bias;
+
+    decaystruct * dp = &decay_info[MI_SCREEN(mi)];
+       
+    switch (dp->mode) {
+      case SHUFFLE:    bias = no_bias; break;
+      case UP:         bias = up_bias; break;
+      case LEFT:       bias = left_bias; break;
+      case RIGHT:      bias = right_bias; break;
+      case DOWN:       bias = down_bias; break;
+      case UPLEFT:     bias = upleft_bias; break;
+      case DOWNLEFT:   bias = downleft_bias; break;
+      case UPRIGHT:    bias = upright_bias; break;
+      case DOWNRIGHT:  bias = downright_bias; break;
+      case IN:         bias = no_bias; break;
+      case OUT:                bias = no_bias; break;
+      default: abort();
+    }
+
+    left = NRAND(dp->windowsize.x - 1);
+    top = NRAND(dp->windowsize.y);
+    width = NRAND(dp->windowsize.x - left);
+    height = NRAND(dp->windowsize.y - top);
+
+    toleft = left;
+    totop = top;
+
+    if (dp->mode == IN || dp->mode == OUT) {
+      int x = left+(width/2);
+      int y = top+(height/2);
+      int cx = dp->windowsize.x/2;
+      int cy = dp->windowsize.y/2;
+      if (dp->mode == IN) {
+       if      (x > cx && y > cy)   bias = upleft_bias;
+       else if (x < cx && y > cy)   bias = upright_bias;
+       else if (x < cx && y < cy)   bias = downright_bias;
+       else /* (x > cx && y < cy)*/ bias = downleft_bias;
+      } else {
+       if      (x > cx && y > cy)   bias = downright_bias;
+       else if (x < cx && y > cy)   bias = downleft_bias;
+       else if (x < cx && y < cy)   bias = upleft_bias;
+       else /* (x > cx && y < cy)*/ bias = upright_bias;
+      }
+    }
+
+    switch (bias[LRAND() % (sizeof(no_bias)/sizeof(*no_bias))]) {
+      case L: toleft = left-DEGREE; break;
+      case R: toleft = left+DEGREE; break;
+      case U: totop = top-DEGREE; break;
+      case D: totop = top+DEGREE; break;
+      default: abort(); break;
+    }
+
+    XCopyArea (MI_DISPLAY(mi), MI_WINDOW(mi), MI_WINDOW(mi),
+              dp->backGC, left, top, width, height,
+              toleft, totop);
+    XFlush(MI_DISPLAY(mi));
+       
+}
+
+void
+refresh_decay(ModeInfo * mi)
+{
+       return;
+}
+
+void
+release_decay(ModeInfo * mi)
+{
+  if (decay_info != NULL) {
+               int     screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       decaystruct *dp = &decay_info[screen];
+
+                       free_stuff(MI_DISPLAY(mi), dp);
+               }
+               (void) free((void *) decay_info);
+               decay_info = NULL;
+       }
+}
+
+#endif /* MODE_decay */
diff --git a/xlockmore-4.14/modes/deco.c b/xlockmore-4.14/modes/deco.c
new file mode 100644 (file)
index 0000000..cc9e20f
--- /dev/null
@@ -0,0 +1,186 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* deco --- art as ugly as sin */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)deco.c 4.07 97/11/24 xlockmore";
+
+#endif
+/* 
+ * Copyright (c) 1997 by Jamie Zawinski <jwz@jwz.org>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 29-Oct-97: xlock version (David Bagley <bagleyd@tux.org>)
+ * 1997: xscreensaver version Jamie Zawinski <jwz@jwz.org>
+ */
+
+/*-
+ * original copyright
+ * xscreensaver, Copyright (c) 1997 Jamie Zawinski <jwz@jwz.org>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ *
+ * Concept snarfed from Michael D. Bayne in
+ * http://www.go2net.com/internet/deep/1997/04/16/body.html
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Deco"
+#define HACK_INIT init_deco
+#define HACK_DRAW draw_deco
+#define deco_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000000 \n" \
+ "*count: -30 \n" \
+ "*cycles: 2 \n" \
+ "*size: -10 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_deco
+
+ModeSpecOpt deco_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   deco_description =
+{"deco", "init_deco", "draw_deco", "release_deco",
+ "init_deco", "init_deco", NULL, &deco_opts,
+ 1000000, -30, 2, -10, 64, 0.6, "",
+ "Shows art as ugly as sin", 0, NULL};
+
+#endif
+
+#define MINSIZE 2
+#define MINDEPTH 1
+
+typedef struct {
+       int         max_depth;
+       int         min_height;
+       int         min_width;
+       int         time;
+       int         colorindex;
+       unsigned long bordercolor;
+} decostruct;
+
+static decostruct *decos = NULL;
+
+static void
+deco(ModeInfo * mi, int x, int y, int w, int h, int depth)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       decostruct *dp = &decos[MI_SCREEN(mi)];
+
+       if ((NRAND(dp->max_depth) + 1 < depth) ||
+           (w < dp->min_width) || (h < dp->min_height)) {
+               if (w > 2 && h > 2) {
+                       if (MI_NPIXELS(mi) > 2) {
+                               XSetForeground(display, gc, MI_PIXEL(mi, dp->colorindex));
+                               if (++dp->colorindex >= MI_NPIXELS(mi))
+                                       dp->colorindex = 0;
+                       } else
+                               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                       XFillRectangle(display, window, gc, x + 1, y + 1, w - 2, h - 2);
+               }
+       } else {
+               if (LRAND() & 1) {
+                       deco(mi, x, y, w / 2, h, depth + 1);
+                       deco(mi, x + w / 2, y, w - w / 2, h, depth + 1);
+               } else {
+                       deco(mi, x, y, w, h / 2, depth + 1);
+                       deco(mi, x, y + h / 2, w, h - h / 2, depth + 1);
+               }
+       }
+}
+
+void
+init_deco(ModeInfo * mi)
+{
+       decostruct *dp;
+       int         depth = MI_COUNT(mi);
+       int         size = MI_SIZE(mi);
+
+       if (decos == NULL) {
+               if ((decos = (decostruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (decostruct))) == NULL)
+                       return;
+       }
+       dp = &decos[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) > 2) {
+               dp->bordercolor = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+               dp->colorindex = NRAND(MI_NPIXELS(mi));
+       } else
+               dp->bordercolor = MI_BLACK_PIXEL(mi);
+       if (depth < -MINDEPTH)
+               dp->max_depth = NRAND(-depth - MINDEPTH + 1) + MINDEPTH;
+       else if (depth < MINDEPTH)
+               dp->max_depth = MINDEPTH;
+       else
+               dp->max_depth = depth;
+       if (size < -MINSIZE) {
+               dp->min_width = NRAND(-size - MINSIZE + 1) + MINSIZE;
+               dp->min_height = NRAND(-size - MINSIZE + 1) + MINSIZE;
+       } else if (size < MINDEPTH)
+               dp->min_width = dp->min_height = MINSIZE;
+       else
+               dp->min_width = dp->min_height = size;
+       dp->time = 0;
+}
+
+void
+draw_deco(ModeInfo * mi)
+{
+       decostruct *dp = &decos[MI_SCREEN(mi)];
+
+       if (dp->time == 0) {
+               /* This fills up holes */
+               MI_CLEARWINDOWCOLOR(mi, dp->bordercolor);
+#ifdef SOLARIS2
+               /*
+                * if this is not done the first rectangle is sometimes messed up on
+                * Solaris2 with 24 bit TrueColor (Ultra2)
+                */
+               XDrawRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                         0, 0, MI_WIDTH(mi) / 2 + 1, MI_HEIGHT(mi) / 2 + 1);
+#endif
+               deco(mi, 0, 0, MI_WIDTH(mi), MI_HEIGHT(mi), 0);
+       }
+       if (++dp->time > MI_CYCLES(mi))
+               init_deco(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+}
+
+void
+release_deco(ModeInfo * mi)
+{
+       if (decos != NULL) {
+               (void) free((void *) decos);
+               decos = NULL;
+       }
+}
+
+#endif /* MODE_deco */
diff --git a/xlockmore-4.14/modes/demon.c b/xlockmore-4.14/modes/demon.c
new file mode 100644 (file)
index 0000000..336f8a6
--- /dev/null
@@ -0,0 +1,919 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* demon --- David Griffeath's cellular automata */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)demon.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 16-Apr-97: -neighbors 3, 9 (not sound mathematically), 12, and 8 added
+ * 30-May-96: Ron Hitchens <ron@idiom.com>
+ *            Fixed memory management that caused leaks
+ * 14-Apr-96: -neighbors 6 runtime-time option added
+ * 21-Aug-95: Coded from A.K. Dewdney's "Computer Recreations", Scientific
+ *            American Magazine" Aug 1989 pp 102-105.  Also very similar to
+ *            hodgepodge machine described in A.K. Dewdney's "Computer
+ *            Recreations", Scientific American Magazine" Aug 1988 pp 104-107.
+ *            also used life.c as a guide.
+ */
+
+/*-
+ * A cellular universe of 4 phases debris, droplets, defects, and demons.
+ */
+
+/*-
+  Grid     Number of Neigbors
+  ----     ------------------
+  Square   4 or 8
+  Hexagon  6
+  Triangle 3, 9, or 12
+*/
+
+#ifdef STANDALONE
+#define PROGCLASS "Demon"
+#define HACK_INIT init_demon
+#define HACK_DRAW draw_demon
+#define demon_opts xlockmore_opts
+#define DEFAULTS "*delay: 50000 \n" \
+ "*count: 0 \n" \
+ "*cycles: 1000 \n" \
+ "*size: -7 \n" \
+ "*ncolors: 64 \n" \
+ "*neighbors: 0 \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_demon
+
+/*-
+ * neighbors of 0 randomizes it between 3, 4, 6, 8, 9, and 12.
+ */
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+
+static int  neighbors;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".demon.neighbors", XrmoptionSepArg, (caddr_t) NULL}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int}
+};
+static OptionStruct desc[] =
+{
+       {"-neighbors num", "squares 4 or 8, hexagons 6, triangles 3, 9 or 12"}
+};
+
+ModeSpecOpt demon_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   demon_description =
+{"demon", "init_demon", "draw_demon", "release_demon",
+ "refresh_demon", "init_demon", NULL, &demon_opts,
+ 50000, 0, 1000, -7, 64, 1.0, "",
+ "Shows Griffeath's cellular automata", 0, NULL};
+
+#endif
+
+#define DEMONBITS(n,w,h)\
+  dp->pixmaps[dp->init_bits++]=\
+  XCreatePixmapFromBitmapData(display,window,(char *)n,w,h,1,0,1)
+
+#define REDRAWSTEP 2000                /* How many cells to draw per cycle */
+#define MINSTATES 2
+#define MINGRIDSIZE 24
+#define MINSIZE 4
+#define NEIGHBORKINDS 6
+
+/* Singly linked list */
+typedef struct _CellList {
+       XPoint      pt;
+       struct _CellList *next;
+} CellList;
+
+typedef struct {
+       int         generation;
+       int         xs, ys;
+       int         xb, yb;
+       int         nrows, ncols;
+       int         width, height;
+       int         states;
+       int         state;
+       int         redrawing, redrawpos;
+       int        *ncells;
+       CellList  **cellList;
+       unsigned char *oldcell, *newcell;
+       int         neighbors;
+       int         init_bits;
+       GC          stippledGC;
+       Pixmap      pixmaps[NUMSTIPPLES - 1];
+       union {
+               XPoint      hexagon[6];
+               XPoint      triangle[2][3];
+       } shape;
+} demonstruct;
+
+static char plots[2][NEIGHBORKINDS] =
+{
+       {3, 4, 6, 8, 9, 12},    /* Neighborhoods */
+       {12, 16, 18, 20, 22, 24}        /* Number of states */
+};
+
+static demonstruct *demons = NULL;
+
+static void
+drawcell(ModeInfo * mi, int col, int row, unsigned char state)
+{
+       demonstruct *dp = &demons[MI_SCREEN(mi)];
+       GC          gc;
+
+       if (!state) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+               gc = MI_GC(mi);
+       } else if (MI_NPIXELS(mi) >= NUMSTIPPLES) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi),
+                          MI_PIXEL(mi, (((int) state - 1) * MI_NPIXELS(mi) /
+                                        (dp->states - 1)) % MI_NPIXELS(mi)));
+               gc = MI_GC(mi);
+       } else {
+               XGCValues   gcv;
+
+               gcv.stipple = dp->pixmaps[(state - 1) % (NUMSTIPPLES - 1)];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), dp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = dp->stippledGC;
+       }
+       if (dp->neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               dp->shape.hexagon[0].x = dp->xb + ccol * dp->xs;
+               dp->shape.hexagon[0].y = dp->yb + crow * dp->ys;
+               if (dp->xs == 1 && dp->ys == 1)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                      gc, dp->shape.hexagon[0].x, dp->shape.hexagon[0].y);
+               else
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                           dp->shape.hexagon, 6, Convex, CoordModePrevious);
+       } else if (dp->neighbors == 4 || dp->neighbors == 8) {
+               XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+               dp->xb + dp->xs * col, dp->yb + dp->ys * row,
+               dp->xs - (dp->xs > 3), dp->ys - (dp->ys > 3));
+       } else {                /* TRI */
+               int         orient = (col + row) % 2;   /* O left 1 right */
+
+               dp->shape.triangle[orient][0].x = dp->xb + col * dp->xs;
+               dp->shape.triangle[orient][0].y = dp->yb + row * dp->ys;
+               if (dp->xs <= 3 || dp->ys <= 3)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                       ((orient) ? -1 : 1) + dp->shape.triangle[orient][0].x,
+                                      dp->shape.triangle[orient][0].y);
+               else {
+                       if (orient)
+                               dp->shape.triangle[orient][0].x += (dp->xs / 2 - 1);
+                       else
+                               dp->shape.triangle[orient][0].x -= (dp->xs / 2 - 1);
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                    dp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+
+               }
+       }
+}
+
+static void
+addtolist(ModeInfo * mi, int col, int row, unsigned char state)
+{
+       demonstruct *dp = &demons[MI_SCREEN(mi)];
+       CellList   *current;
+
+       current = dp->cellList[state];
+       dp->cellList[state] = (CellList *) malloc(sizeof (CellList));
+       dp->cellList[state]->pt.x = col;
+       dp->cellList[state]->pt.y = row;
+       dp->cellList[state]->next = current;
+       dp->ncells[state]++;
+}
+
+#ifdef DEBUG
+static void
+print_state(ModeInfo * mi, int state)
+{
+       demonstruct *dp = &demons[MI_SCREEN(mi)];
+       CellList   *locallist;
+       int         i = 0;
+
+       locallist = dp->cellList[state];
+       (void) printf("state %d\n", state);
+       while (locallist) {
+               (void) printf("%d       x %d, y %d\n", i,
+                             locallist->pt.x, locallist->pt.y);
+               locallist = locallist->next;
+               i++;
+       }
+}
+
+#endif
+
+static void
+free_state(demonstruct * dp, int state)
+{
+       CellList   *current;
+
+       while (dp->cellList[state]) {
+               current = dp->cellList[state];
+               dp->cellList[state] = dp->cellList[state]->next;
+               (void) free((void *) current);
+       }
+       dp->cellList[state] = NULL;
+       if (dp->ncells)
+               dp->ncells[state] = 0;
+}
+
+
+static void
+free_list(demonstruct * dp)
+{
+       int         state;
+
+       for (state = 0; state < dp->states; state++)
+               free_state(dp, state);
+       (void) free((void *) dp->cellList);
+       dp->cellList = NULL;
+}
+
+static void
+free_struct(demonstruct * dp)
+{
+       if (dp->cellList != NULL) {
+               free_list(dp);
+       }
+       if (dp->ncells != NULL) {
+               (void) free((void *) dp->ncells);
+               dp->ncells = NULL;
+       }
+       if (dp->oldcell != NULL) {
+               (void) free((void *) dp->oldcell);
+               dp->oldcell = NULL;
+       }
+       if (dp->newcell != NULL) {
+               (void) free((void *) dp->newcell);
+               dp->newcell = NULL;
+       }
+}
+
+static void
+draw_state(ModeInfo * mi, int state)
+{
+       demonstruct *dp = &demons[MI_SCREEN(mi)];
+       GC          gc;
+       XRectangle *rects;
+       CellList   *current;
+
+       if (!state) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+               gc = MI_GC(mi);
+       } else if (MI_NPIXELS(mi) >= NUMSTIPPLES) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi),
+                          MI_PIXEL(mi, (((int) state - 1) * MI_NPIXELS(mi) /
+                                        (dp->states - 1)) % MI_NPIXELS(mi)));
+               gc = MI_GC(mi);
+       } else {
+               XGCValues   gcv;
+
+               gcv.stipple = dp->pixmaps[(state - 1) % (NUMSTIPPLES - 1)];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), dp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = dp->stippledGC;
+       }
+       if (dp->neighbors == 6) {       /* Draw right away, slow */
+               current = dp->cellList[state];
+               while (current) {
+                       int         col, row, ccol, crow;
+
+                       col = current->pt.x;
+                       row = current->pt.y;
+                       ccol = 2 * col + !(row & 1), crow = 2 * row;
+                       dp->shape.hexagon[0].x = dp->xb + ccol * dp->xs;
+                       dp->shape.hexagon[0].y = dp->yb + crow * dp->ys;
+                       if (dp->xs == 1 && dp->ys == 1)
+                               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                              gc, dp->shape.hexagon[0].x, dp->shape.hexagon[0].y);
+                       else
+                               XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                            dp->shape.hexagon, 6, Convex, CoordModePrevious);
+                       current = current->next;
+               }
+       } else if (dp->neighbors == 4 || dp->neighbors == 8) {
+               /* Take advantage of XDrawRectangles */
+               int         ncells = 0;
+
+               /* Create Rectangle list from part of the cellList */
+               rects = (XRectangle *) malloc(dp->ncells[state] * sizeof (XRectangle));
+               current = dp->cellList[state];
+               while (current) {
+                       rects[ncells].x = dp->xb + current->pt.x * dp->xs;
+                       rects[ncells].y = dp->yb + current->pt.y * dp->ys;
+                       rects[ncells].width = dp->xs - (dp->xs > 3);
+                       rects[ncells].height = dp->ys - (dp->ys > 3);
+                       current = current->next;
+                       ncells++;
+               }
+               /* Finally get to draw */
+               XFillRectangles(MI_DISPLAY(mi), MI_WINDOW(mi), gc, rects, ncells);
+               /* Free up rects list and the appropriate part of the cellList */
+               (void) free((void *) rects);
+       } else {                /* TRI */
+               current = dp->cellList[state];
+               while (current) {
+                       int         col, row, orient;
+
+                       col = current->pt.x;
+                       row = current->pt.y;
+                       orient = (col + row) % 2;       /* O left 1 right */
+                       dp->shape.triangle[orient][0].x = dp->xb + col * dp->xs;
+                       dp->shape.triangle[orient][0].y = dp->yb + row * dp->ys;
+                       if (dp->xs <= 3 || dp->ys <= 3)
+                               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                              ((orient) ? -1 : 1) + dp->shape.triangle[orient][0].x,
+                                     dp->shape.triangle[orient][0].y);
+                       else {
+                               if (orient)
+                                       dp->shape.triangle[orient][0].x += (dp->xs / 2 - 1);
+                               else
+                                       dp->shape.triangle[orient][0].x -= (dp->xs / 2 - 1);
+                               XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                            dp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+                       }
+                       current = current->next;
+               }
+       }
+       free_state(dp, state);
+       XFlush(MI_DISPLAY(mi));
+}
+
+static void
+RandomSoup(ModeInfo * mi)
+{
+       demonstruct *dp = &demons[MI_SCREEN(mi)];
+       int         row, col, mrow = 0;
+
+       for (row = 0; row < dp->nrows; ++row) {
+               for (col = 0; col < dp->ncols; ++col) {
+                       dp->oldcell[col + mrow] =
+                               (unsigned char) LRAND() % ((unsigned char) dp->states);
+                       addtolist(mi, col, row, dp->oldcell[col + mrow]);
+               }
+               mrow += dp->ncols;
+       }
+}
+
+void
+init_demon(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         size = MI_SIZE(mi), nk;
+       demonstruct *dp;
+
+       if (demons == NULL) {
+               if ((demons = (demonstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (demonstruct))) == NULL)
+                       return;
+       }
+       dp = &demons[MI_SCREEN(mi)];
+       dp->generation = 0;
+       dp->redrawing = 0;
+       if (MI_NPIXELS(mi) < NUMSTIPPLES) {
+               if (dp->stippledGC == None) {
+                       XGCValues   gcv;
+
+                       gcv.fill_style = FillOpaqueStippled;
+                       dp->stippledGC = XCreateGC(display, window, GCFillStyle, &gcv);
+               }
+               if (dp->init_bits == 0) {
+                       int         i;
+
+                       for (i = 1; i < NUMSTIPPLES; i++)
+                               DEMONBITS(stipples[i], STIPPLESIZE, STIPPLESIZE);
+               }
+       }
+       free_struct(dp);
+
+       for (nk = 0; nk < NEIGHBORKINDS; nk++) {
+               if (neighbors == plots[0][nk]) {
+                       dp->neighbors = plots[0][nk];
+                       break;
+               }
+               if (nk == NEIGHBORKINDS - 1) {
+                       nk = NRAND(NEIGHBORKINDS);
+                       dp->neighbors = plots[0][nk];
+                       break;
+               }
+       }
+
+       dp->states = MI_COUNT(mi);
+       if (dp->states < -MINSTATES)
+               dp->states = NRAND(-dp->states - MINSTATES + 1) + MINSTATES;
+       else if (dp->states < MINSTATES)
+               dp->states = plots[1][nk];
+       dp->cellList = (CellList **) calloc(dp->states, sizeof (CellList *));
+       dp->ncells = (int *) calloc(dp->states, sizeof (int));
+
+       dp->state = 0;
+
+       dp->width = MI_WIDTH(mi);
+       dp->height = MI_HEIGHT(mi);
+
+       if (dp->neighbors == 6) {
+               int         nccols, ncrows, i;
+
+               if (dp->width < 2)
+                       dp->width = 2;
+               if (dp->height < 4)
+                       dp->height = 4;
+               if (size < -MINSIZE)
+                       dp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               dp->ys = MAX(MINSIZE, MIN(dp->width, dp->height) / MINGRIDSIZE);
+                       else
+                               dp->ys = MINSIZE;
+               } else
+                       dp->ys = MIN(size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                              MINGRIDSIZE));
+               dp->xs = dp->ys;
+               nccols = MAX(dp->width / dp->xs - 2, 2);
+               ncrows = MAX(dp->height / dp->ys - 1, 2);
+               dp->ncols = nccols / 2;
+               dp->nrows = 2 * (ncrows / 4);
+               dp->xb = (dp->width - dp->xs * nccols) / 2 + dp->xs / 2;
+               dp->yb = (dp->height - dp->ys * (ncrows / 2) * 2) / 2 + dp->ys;
+               for (i = 0; i < 6; i++) {
+                       dp->shape.hexagon[i].x = (dp->xs - 1) * hexagonUnit[i].x;
+                       dp->shape.hexagon[i].y = ((dp->ys - 1) * hexagonUnit[i].y / 2) * 4 / 3;
+               }
+       } else if (dp->neighbors == 4 || dp->neighbors == 8) {
+               if (size < -MINSIZE)
+                       dp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               dp->ys = MAX(MINSIZE, MIN(dp->width, dp->height) / MINGRIDSIZE);
+                       else
+                               dp->ys = MINSIZE;
+               } else
+                       dp->ys = MIN(size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                              MINGRIDSIZE));
+               dp->xs = dp->ys;
+               dp->ncols = MAX(dp->width / dp->xs, 2);
+               dp->nrows = MAX(dp->height / dp->ys, 2);
+               dp->xb = (dp->width - dp->xs * dp->ncols) / 2;
+               dp->yb = (dp->height - dp->ys * dp->nrows) / 2;
+       } else {                /* TRI */
+               int         orient, i;
+
+               if (dp->width < 2)
+                       dp->width = 2;
+               if (dp->height < 2)
+                       dp->height = 2;
+               if (size < -MINSIZE)
+                       dp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               dp->ys = MAX(MINSIZE, MIN(dp->width, dp->height) / MINGRIDSIZE);
+                       else
+                               dp->ys = MINSIZE;
+               } else
+                       dp->ys = MIN(size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                              MINGRIDSIZE));
+               dp->xs = (int) (1.52 * dp->ys);
+               dp->ncols = (MAX(dp->width / dp->xs - 1, 2) / 2) * 2;
+               dp->nrows = (MAX(dp->height / dp->ys - 1, 2) / 2) * 2;
+               dp->xb = (dp->width - dp->xs * dp->ncols) / 2 + dp->xs / 2;
+               dp->yb = (dp->height - dp->ys * dp->nrows) / 2 + dp->ys / 2;
+               for (orient = 0; orient < 2; orient++) {
+                       for (i = 0; i < 3; i++) {
+                               dp->shape.triangle[orient][i].x =
+                                       (dp->xs - 2) * triangleUnit[orient][i].x;
+                               dp->shape.triangle[orient][i].y =
+                                       (dp->ys - 2) * triangleUnit[orient][i].y;
+                       }
+               }
+       }
+
+       MI_CLEARWINDOW(mi);
+
+       dp->oldcell = (unsigned char *)
+               malloc(dp->ncols * dp->nrows * sizeof (unsigned char));
+
+       dp->newcell = (unsigned char *)
+               malloc(dp->ncols * dp->nrows * sizeof (unsigned char));
+
+       RandomSoup(mi);
+}
+
+void
+draw_demon(ModeInfo * mi)
+{
+       demonstruct *dp = &demons[MI_SCREEN(mi)];
+       int         i, j, k, l, mj = 0, ml;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (dp->state >= dp->states) {
+               (void) memcpy((char *) dp->newcell, (char *) dp->oldcell,
+                             dp->ncols * dp->nrows * sizeof (unsigned char));
+
+               if (dp->neighbors == 6) {
+                       for (j = 0; j < dp->nrows; j++) {
+                               for (i = 0; i < dp->ncols; i++) {
+                                       /* NE */
+                                       if (!(j & 1))
+                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                       else
+                                               k = i;
+                                       l = (!j) ? dp->nrows - 1 : j - 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* E */
+                                       k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                       l = j;
+                                       ml = mj;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* SE */
+                                       if (!(j & 1))
+                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                       else
+                                               k = i;
+                                       l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* SW */
+                                       if (j & 1)
+                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                       else
+                                               k = i;
+                                       l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* W */
+                                       k = (!i) ? dp->ncols - 1 : i - 1;
+                                       l = j;
+                                       ml = mj;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* NW */
+                                       if (j & 1)
+                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                       else
+                                               k = i;
+                                       l = (!j) ? dp->nrows - 1 : j - 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                               }
+                               mj += dp->ncols;
+                       }
+               } else if (dp->neighbors == 4 || dp->neighbors == 8) {
+                       for (j = 0; j < dp->nrows; j++) {
+                               for (i = 0; i < dp->ncols; i++) {
+                                       /* N */
+                                       k = i;
+                                       l = (!j) ? dp->nrows - 1 : j - 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* E */
+                                       k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                       l = j;
+                                       ml = mj;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* S */
+                                       k = i;
+                                       l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* W */
+                                       k = (!i) ? dp->ncols - 1 : i - 1;
+                                       l = j;
+                                       ml = mj;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                               }
+                               mj += dp->ncols;
+                       }
+                       if (dp->neighbors == 8) {
+                               mj = 0;
+                               for (j = 0; j < dp->nrows; j++) {
+                                       for (i = 0; i < dp->ncols; i++) {
+                                               /* NE */
+                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                               l = (!j) ? dp->nrows - 1 : j - 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* SE */
+                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                               l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* SW */
+                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                               l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* NW */
+                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                               l = (!j) ? dp->nrows - 1 : j - 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       }
+                                       mj += dp->ncols;
+                               }
+                       }
+               } else if (dp->neighbors == 3 || dp->neighbors == 9 ||
+                          dp->neighbors == 12) {
+                       for (j = 0; j < dp->nrows; j++) {
+                               for (i = 0; i < dp->ncols; i++) {
+                                       if ((i + j) % 2) {      /* right */
+                                               /* W */
+                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                               l = j;
+                                               ml = mj;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       } else {        /* left */
+                                               /* E */
+                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                               l = j;
+                                               ml = mj;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       }
+                                       /* N */
+                                       k = i;
+                                       l = (!j) ? dp->nrows - 1 : j - 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       /* S */
+                                       k = i;
+                                       l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                       ml = l * dp->ncols;
+                                       if (dp->oldcell[k + ml] ==
+                                           (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                               dp->newcell[i + mj] = dp->oldcell[k + ml];
+                               }
+                               mj += dp->ncols;
+                       }
+                       if (dp->neighbors == 9 || dp->neighbors == 12) {
+                               mj = 0;
+                               for (j = 0; j < dp->nrows; j++) {
+                                       for (i = 0; i < dp->ncols; i++) {
+                                               /* NN */
+                                               k = i;
+                                               if (!j)
+                                                       l = dp->nrows - 2;
+                                               else if (!(j - 1))
+                                                       l = dp->nrows - 1;
+                                               else
+                                                       l = j - 2;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* SS */
+                                               k = i;
+                                               if (j + 1 == dp->nrows)
+                                                       l = 1;
+                                               else if (j + 2 == dp->nrows)
+                                                       l = 0;
+                                               else
+                                                       l = j + 2;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* NW */
+                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                               l = (!j) ? dp->nrows - 1 : j - 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* NE */
+                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                               l = (!j) ? dp->nrows - 1 : j - 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* SW */
+                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                               l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                               /* SE */
+                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                               l = (j + 1 == dp->nrows) ? 0 : j + 1;
+                                               ml = l * dp->ncols;
+                                               if (dp->oldcell[k + ml] ==
+                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                       }
+                                       mj += dp->ncols;
+                               }
+                               if (dp->neighbors == 12) {
+                                       mj = 0;
+                                       for (j = 0; j < dp->nrows; j++) {
+                                               for (i = 0; i < dp->ncols; i++) {
+                                                       if ((i + j) % 2) {      /* right */
+                                                               /* NNW */
+                                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                                               if (!j)
+                                                                       l = dp->nrows - 2;
+                                                               else if (!(j - 1))
+                                                                       l = dp->nrows - 1;
+                                                               else
+                                                                       l = j - 2;
+                                                               ml = l * dp->ncols;
+                                                               if (dp->oldcell[k + ml] ==
+                                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                                               /* SSW */
+                                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                                               if (j + 1 == dp->nrows)
+                                                                       l = 1;
+                                                               else if (j + 2 == dp->nrows)
+                                                                       l = 0;
+                                                               else
+                                                                       l = j + 2;
+                                                               ml = l * dp->ncols;
+                                                               if (dp->oldcell[k + ml] ==
+                                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                                               /* EE */
+                                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                                               l = j;
+                                                               ml = mj;
+                                                               if (dp->oldcell[k + ml] ==
+                                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                                       } else {        /* left */
+                                                               /* NNE */
+                                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                                               if (!j)
+                                                                       l = dp->nrows - 2;
+                                                               else if (!(j - 1))
+                                                                       l = dp->nrows - 1;
+                                                               else
+                                                                       l = j - 2;
+                                                               ml = l * dp->ncols;
+                                                               if (dp->oldcell[k + ml] ==
+                                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                                               /* SSE */
+                                                               k = (i + 1 == dp->ncols) ? 0 : i + 1;
+                                                               if (j + 1 == dp->nrows)
+                                                                       l = 1;
+                                                               else if (j + 2 == dp->nrows)
+                                                                       l = 0;
+                                                               else
+                                                                       l = j + 2;
+                                                               ml = l * dp->ncols;
+                                                               if (dp->oldcell[k + ml] ==
+                                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                                               /* WW */
+                                                               k = (!i) ? dp->ncols - 1 : i - 1;
+                                                               l = j;
+                                                               ml = mj;
+                                                               if (dp->oldcell[k + ml] ==
+                                                                   (int) (dp->oldcell[i + mj] + 1) % dp->states)
+                                                                       dp->newcell[i + mj] = dp->oldcell[k + ml];
+                                                       }
+                                               }
+                                               mj += dp->ncols;
+                                       }
+                               }
+                       }
+               }
+               mj = 0;
+               for (j = 0; j < dp->nrows; j++) {
+                       for (i = 0; i < dp->ncols; i++)
+                               if (dp->oldcell[i + mj] != dp->newcell[i + mj]) {
+                                       dp->oldcell[i + mj] = dp->newcell[i + mj];
+                                       addtolist(mi, i, j, dp->oldcell[i + mj]);
+                               }
+                       mj += dp->ncols;
+               }
+               if (++dp->generation > MI_CYCLES(mi))
+                       init_demon(mi);
+               dp->state = 0;
+       } else {
+               if (dp->ncells[dp->state])
+                       draw_state(mi, dp->state);
+               dp->state++;
+       }
+       if (dp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       if (dp->oldcell[dp->redrawpos]) {
+                               drawcell(mi, dp->redrawpos % dp->ncols, dp->redrawpos / dp->ncols,
+                                        dp->oldcell[dp->redrawpos]);
+                       }
+                       if (++(dp->redrawpos) >= dp->ncols * dp->nrows) {
+                               dp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+void
+release_demon(ModeInfo * mi)
+{
+       if (demons != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       demonstruct *dp = &demons[screen];
+                       int         shade;
+
+                       if (dp->stippledGC != None) {
+                               XFreeGC(MI_DISPLAY(mi), dp->stippledGC);
+                       }
+                       for (shade = 0; shade < dp->init_bits; shade++)
+                               XFreePixmap(MI_DISPLAY(mi), dp->pixmaps[shade]);
+                       free_struct(dp);
+               }
+               (void) free((void *) demons);
+               demons = NULL;
+       }
+} void
+
+refresh_demon(ModeInfo * mi)
+{
+       demonstruct *dp = &demons[MI_SCREEN(mi)];
+
+       dp->redrawing = 1;
+       dp->redrawpos = 0;
+}
+
+#endif /* MODE_demon */
diff --git a/xlockmore-4.14/modes/dilemma.c b/xlockmore-4.14/modes/dilemma.c
new file mode 100644 (file)
index 0000000..2788c06
--- /dev/null
@@ -0,0 +1,939 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* dilemma --- Lloyd's Prisoner's Dilemma Simulation */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)dilemma.c    4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 20-Oct-97: Computing Bouts of the Prisoner's Dilemma by Alun L. Lloyd
+ *            Scientific American Magazine June 1995
+ *            Used voters.c as a guide.
+ */
+
+/*-
+ *                      Opponent's Strategy
+ *                   
+ *                      Cooperate     Defect                    
+ *                     -----------------------
+ *                    |           |           |
+ *          Cooperate |     1     |     0     |
+ * Player's           |           |           |
+ * Strategy           |-----------+-----------|
+ *                    |           |           |
+ *          Defect    |     b     |     0     |
+ *                    |           |           |
+ *                     -----------------------
+ *  
+ *                        The Payoff Matrix
+ *  
+ * An interesting value of "b" for a 8 neighbor grid is 1.85
+ * What does b stand for?  "bonus"?
+ * Cells get 1 if they and their opponent cooperates.
+ * Cells get b if they cheat and their opponent cooperates.
+ * Cells get 0 in the 2 other cases.
+ * If b is greater then a cell should always cheat except
+ * they have to live with their neighbor... so on the next go around
+ * their neighbor might not see any benefit in cooperating.
+ * Cells add up the previous results of their neighbors
+ * and decide if its their best strategy is to cheat or not to cheat.
+ *
+ * I have noticed round off errors  I have not as yet tracked them down.
+ * Try
+ * -bonus 1.99 -neighbors 12  -size 10 
+ * -bonus 241 -neighbors 6  -size 8
+ * -bonus 1.71 -neighbors 4  -size 4
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Dilemma"
+#define HACK_INIT init_dilemma
+#define HACK_DRAW draw_dilemma
+#define dilemma_opts xlockmore_opts
+#define DEFAULTS "*delay: 200000 \n" \
+ "*batchcount: -2 \n" \
+ "*cycles: 1000 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 6 \n" \
+ "*neighbors: 0 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#define SMOOTH_COLORS
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_dilemma
+
+/*-
+ * neighbors of 0 randomizes it between 3, 4, 6, 8, 9, and 12.
+ */
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+#define DEF_BONUS  "1.85"
+#define DEF_CONSCIOUS  "True"
+
+static int  neighbors;
+static float bonus;
+static Bool conscious;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".dilemma.neighbors", XrmoptionSepArg, (caddr_t) NULL},
+       {"-bonus", ".dilemma.bonus", XrmoptionSepArg, (caddr_t) NULL},
+       {"-conscious", ".dilemma.conscious", XrmoptionNoArg, (caddr_t) "on"},
+       {"+conscious", ".dilemma.conscious", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int},
+       {(caddr_t *) & bonus, "bonus", "Bonus", DEF_BONUS, t_Float},
+   {(caddr_t *) & conscious, "conscious", "Conscious", DEF_CONSCIOUS, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-neighbors num", "squares 4 or 8, hexagons 6, triangles 3, 9 or 12"},
+       {"-bonus value", "bonus for cheating... between 1.0 and 4.0"},
+       {"-/+conscious", "turn on/off self-awareness"}
+};
+
+ModeSpecOpt dilemma_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   dilemma_description =
+{"dilemma", "init_dilemma", "draw_dilemma", "release_dilemma",
+ "refresh_dilemma", "init_dilemma", NULL, &dilemma_opts,
+ 200000, -2, 1000, 0, 64, 1.0, "",
+ "Shows Lloyd's Prisoner's Dilemma simulation", 0, NULL};
+
+#endif
+
+/* Better bitmaps needed :) */
+#include "bitmaps/cooperat.xbm"        /* age > 1 then blue, age = 1 then green */
+#include "bitmaps/defect.xbm"  /* age > 1 then red, age = 1 then yellow */
+
+#define DEFECTOR 0
+#define COOPERATOR 1
+#define COLORS 4
+#define BLUE (45 * MI_NPIXELS(mi) / 64)                /* COOPERATING, was cooperating */
+#define GREEN (23 * MI_NPIXELS(mi) / 64)       /* COOPERATING, was defecting */
+#define YELLOW (MI_NPIXELS(mi) / 6)    /* DEFECTING, was cooperating */
+#define RED    0               /* DEFECTING, was defecting */
+#define MINDEFECT 1
+#define BITMAPS 2
+#define MINGRIDSIZE 16
+#define MINSIZE 10
+#define FACTOR 10
+#define NEIGHBORKINDS 6
+#define REDRAWSTEP 2000                /* How many cells to draw per cycle */
+#define ROUND_FLOAT(x,a) ((float) ((int) ((x) / (a) + 0.5)) * (a))
+
+static XImage logo[BITMAPS] =
+{
+    {0, 0, 0, XYBitmap, (char *) cooperat_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) defect_bits, LSBFirst, 8, LSBFirst, 8, 1},
+};
+
+/* Dilemma data */
+
+/* Singly linked list */
+typedef struct _CellList {
+       XPoint      pt;
+       struct _CellList *next;
+} CellList;
+
+typedef struct {
+       int         defectors;  /* portion of defectors */
+       float       pm[2][2];   /* payoff matrix */
+       unsigned long colors[2][2];
+       CellList   *cellList[COLORS];
+       char       *s, *sn;     /* cell strategies */
+       float      *payoff;
+       int         initialized;
+       int         xs, ys;     /* Size of cooperators and defectors */
+       int         xb, yb;     /* Bitmap offset for cooperators and defectors */
+       int         state;
+       int         redrawing, redrawpos;
+       int         pixelmode;
+       int         generation;
+       int         ncols, nrows;
+       int         npositions;
+       int         width, height;
+       int         neighbors;
+       union {
+               XPoint      hexagon[6];
+               XPoint      triangle[2][3];
+       } shape;
+} dilemmastruct;
+
+static char plots[NEIGHBORKINDS] =
+{
+       3, 4, 6, 8, 9, 12       /* Neighborhoods */
+};
+
+static dilemmastruct *dilemmas = NULL;
+static int  icon_width, icon_height;
+
+static void
+drawcell(ModeInfo * mi, int col, int row, unsigned long color, int bitmap,
+        Bool firstChange)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       dilemmastruct *dp = &dilemmas[MI_SCREEN(mi)];
+       unsigned long colour = (MI_NPIXELS(mi) >= COLORS) ?
+       color : MI_WHITE_PIXEL(mi);
+
+       XSetForeground(display, gc, colour);
+       if (dp->neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               dp->shape.hexagon[0].x = dp->xb + ccol * dp->xs;
+               dp->shape.hexagon[0].y = dp->yb + crow * dp->ys;
+               if (dp->xs == 1 && dp->ys == 1)
+                       XDrawPoint(display, window, gc,
+                       dp->shape.hexagon[0].x, dp->shape.hexagon[0].y);
+               else if (bitmap == BITMAPS - 1)
+                       XFillPolygon(display, window, gc,
+                           dp->shape.hexagon, 6, Convex, CoordModePrevious);
+               else {
+                       if (firstChange) {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XFillPolygon(display, window, gc,
+                                            dp->shape.hexagon, 6, Convex, CoordModePrevious);
+                               XSetForeground(display, gc, colour);
+                       }
+                       if (dp->xs <= 6 || dp->ys <= 2)
+                               XFillRectangle(display, window, gc,
+                                    dp->shape.hexagon[0].x - 3 * dp->xs / 4,
+                                              dp->shape.hexagon[0].y + dp->ys / 4, dp->xs, dp->ys);
+                       else
+                               XFillArc(display, window, gc,
+                                    dp->xb + dp->xs * ccol - 3 * dp->xs / 4,
+                                        dp->yb + dp->ys * crow + dp->ys / 4,
+                                        2 * dp->xs - 6, 2 * dp->ys - 2,
+                                        0, 23040);
+               }
+       } else if (dp->neighbors == 4 || dp->neighbors == 8) {
+               if (dp->pixelmode) {
+                       if (bitmap == BITMAPS - 1 || (dp->xs <= 2 || dp->ys <= 2))
+                               XFillRectangle(display, window, gc,
+                               dp->xb + dp->xs * col, dp->yb + dp->ys * row,
+                               dp->xs - (dp->xs > 3), dp->ys - (dp->ys > 3));
+                       else {
+                               if (firstChange) {
+                                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                                       XFillRectangle(display, window, gc,
+                                                      dp->xb + dp->xs * col, dp->yb + dp->ys * row,
+                                                      dp->xs, dp->ys);
+                                       XSetForeground(display, gc, colour);
+                               }
+                               XFillArc(display, window, gc,
+                                        dp->xb + dp->xs * col, dp->yb + dp->ys * row,
+                                        dp->xs - 1, dp->ys - 1,
+                                        0, 23040);
+                       }
+               } else
+                       (void) XPutImage(display, window, gc,
+                                        &logo[bitmap], 0, 0,
+                               dp->xb + dp->xs * col, dp->yb + dp->ys * row,
+                                        icon_width, icon_height);
+       } else {                /* TRI */
+               int         orient = (col + row) % 2;   /* O left 1 right */
+
+               dp->shape.triangle[orient][0].x = dp->xb + col * dp->xs;
+               dp->shape.triangle[orient][0].y = dp->yb + row * dp->ys;
+               if (dp->xs <= 3 || dp->ys <= 3)
+                       XDrawPoint(display, window, gc,
+                       ((orient) ? -1 : 1) + dp->shape.triangle[orient][0].x,
+                                      dp->shape.triangle[orient][0].y);
+               else {
+                       if (orient)
+                               dp->shape.triangle[orient][0].x += (dp->xs / 2 - 1);
+                       else
+                               dp->shape.triangle[orient][0].x -= (dp->xs / 2 - 1);
+                       if (bitmap == BITMAPS - 1)
+                               XFillPolygon(display, window, gc,
+                                            dp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+                       else {
+                               if (firstChange) {
+                                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                                       XFillPolygon(display, window, gc,
+                                                    dp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+                                       XSetForeground(display, gc, colour);
+                               }
+                               XFillArc(display, window, gc,
+                                    dp->xb + dp->xs * col - 4 * dp->xs / 5 +
+                                   ((orient) ? dp->xs / 3 : 3 * dp->xs / 5),
+                                        dp->yb + dp->ys * row - dp->ys / 2 + 1, dp->ys - 3, dp->ys - 3,
+                                        0, 23040);
+                       }
+               }
+       }
+}
+
+static void
+addtolist(ModeInfo * mi, int col, int row, int state)
+{
+       dilemmastruct *dp = &dilemmas[MI_SCREEN(mi)];
+       CellList   *current;
+
+       current = dp->cellList[state];
+       dp->cellList[state] = (CellList *) malloc(sizeof (CellList));
+       dp->cellList[state]->pt.x = col;
+       dp->cellList[state]->pt.y = row;
+       dp->cellList[state]->next = current;
+}
+
+#ifdef DEBUG
+static void
+print_state(ModeInfo * mi, int state)
+{
+       dilemmastruct *dp = &dilemmas[MI_SCREEN(mi)];
+       CellList   *locallist;
+       int         i = 0;
+
+       locallist = dp->cellList[state];
+       (void) printf("state %d\n", state);
+       while (locallist) {
+               (void) printf("%d x %d, y %d\n", i,
+                             locallist->pt.x, locallist->pt.y);
+               locallist = locallist->next;
+               i++;
+       }
+}
+
+#endif
+
+static void
+free_state(dilemmastruct * dp, int state)
+{
+       CellList   *current;
+
+       while (dp->cellList[state]) {
+               current = dp->cellList[state];
+               dp->cellList[state] = dp->cellList[state]->next;
+               (void) free((void *) current);
+       }
+       dp->cellList[state] = NULL;
+}
+
+
+static void
+free_list(dilemmastruct * dp)
+{
+       int         state;
+
+       for (state = 0; state < COLORS; state++)
+               free_state(dp, state);
+}
+
+static void
+free_struct(dilemmastruct * dp)
+{
+       free_list(dp);
+       if (dp->sn != NULL) {
+               (void) free((void *) dp->sn);
+               dp->sn = NULL;
+       }
+       if (dp->s != NULL) {
+               (void) free((void *) dp->s);
+               dp->s = NULL;
+       }
+}
+
+static int
+neighbor_position(dilemmastruct * dp, int col, int row, int dir)
+{
+       if (dp->neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                               break;
+                       case 60:
+                               if (!(row & 1))
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                               row = (!row) ? dp->nrows - 1 : row - 1;
+                               break;
+                       case 120:
+                               if (row & 1)
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                               row = (!row) ? dp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? dp->ncols - 1 : col - 1;
+                               break;
+                       case 240:
+                               if (row & 1)
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                               row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                               break;
+                       case 300:
+                               if (!(row & 1))
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else if (dp->neighbors == 4 || dp->neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                               break;
+                       case 45:
+                               col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                               row = (!row) ? dp->nrows - 1 : row - 1;
+                               break;
+                       case 90:
+                               row = (!row) ? dp->nrows - 1 : row - 1;
+                               break;
+                       case 135:
+                               col = (!col) ? dp->ncols - 1 : col - 1;
+                               row = (!row) ? dp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? dp->ncols - 1 : col - 1;
+                               break;
+                       case 225:
+                               col = (!col) ? dp->ncols - 1 : col - 1;
+                               row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                               break;
+                       case 270:
+                               row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                               break;
+                       case 315:
+                               col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {                /* TRI */
+               if ((col + row) % 2) {  /* right */
+                       switch (dir) {
+                               case 0:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 60:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       if (row + 1 == dp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == dp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (row + 1 == dp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == dp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 120:
+                                       row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 180:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? dp->nrows - 1 : row - 1;
+                                       break;
+                               case 240:
+                                       row = (!row) ? dp->nrows - 1 : row - 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (!row)
+                                               row = dp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = dp->nrows - 1;
+                                       else
+                                               row = row - 2;
+
+                                       break;
+                               case 300:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       if (!row)
+                                               row = dp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = dp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       row = (!row) ? dp->nrows - 1 : row - 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               } else {        /* left */
+                       switch (dir) {
+                               case 0:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? dp->nrows - 1 : row - 1;
+                                       break;
+                               case 60:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       if (!row)
+                                               row = dp->nrows - 2;
+                                       else if (row == 1)
+                                               row = dp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (!row)
+                                               row = dp->nrows - 2;
+                                       else if (row == 1)
+                                               row = dp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 120:
+                                       row = (!row) ? dp->nrows - 1 : row - 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       row = (!row) ? dp->nrows - 1 : row - 1;
+                                       break;
+                               case 180:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (!col) ? dp->ncols - 1 : col - 1;
+                                       row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 240:
+                                       row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (row + 1 == dp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == dp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 300:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       if (row + 1 == dp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == dp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (col + 1 == dp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == dp->nrows) ? 0 : row + 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               }
+       }
+
+       return row * dp->ncols + col;
+}
+
+static void
+draw_state(ModeInfo * mi, int state)
+{
+       dilemmastruct *dp = &dilemmas[MI_SCREEN(mi)];
+       CellList   *current;
+
+
+       current = dp->cellList[state];
+       while (current) {
+               int         col = current->pt.x;
+               int         row = current->pt.y;
+               int         colrow = col + row * dp->ncols;
+
+               drawcell(mi, col, row,
+                      dp->colors[(int) dp->sn[colrow]][(int) dp->s[colrow]],
+                        dp->sn[colrow], 1);
+               if (dp->s[colrow] && !dp->sn[colrow])
+                       dp->defectors--;
+               if (!dp->s[colrow] && dp->sn[colrow])
+                       dp->defectors++;
+               dp->s[colrow] = dp->sn[colrow];
+               current = current->next;
+       }
+       free_state(dp, state);
+       XFlush(MI_DISPLAY(mi));
+}
+
+void
+init_dilemma(ModeInfo * mi)
+{
+       int         size = MI_SIZE(mi);
+       dilemmastruct *dp;
+       int         i, col, row, colrow, mrow;
+
+       if (dilemmas == NULL) {
+               if ((dilemmas = (dilemmastruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (dilemmastruct))) == NULL)
+                       return;
+       }
+       dp = &dilemmas[MI_SCREEN(mi)];
+
+       dp->generation = 0;
+       dp->redrawing = 0;
+       dp->state = 0;
+       free_struct(dp);
+
+       if (!dp->initialized) { /* Genesis */
+               icon_width = cooperat_width;
+               icon_height = cooperat_height;
+               dp->initialized = 1;
+               for (i = 0; i < BITMAPS; i++) {
+                       logo[i].width = icon_width;
+                       logo[i].height = icon_height;
+                       logo[i].bytes_per_line = (icon_width + 7) / 8;
+               }
+       }
+       dp->width = MI_WIDTH(mi);
+       dp->height = MI_HEIGHT(mi);
+
+       for (i = 0; i < NEIGHBORKINDS; i++) {
+               if (neighbors == plots[i]) {
+                       dp->neighbors = neighbors;
+                       break;
+               }
+               if (i == NEIGHBORKINDS - 1) {
+#if 0
+                       dp->neighbors = plots[NRAND(NEIGHBORKINDS)];
+                       dp->neighbors = (LRAND() & 1) ? 4 : 8;
+#else
+                       dp->neighbors = 8;
+#endif
+                       break;
+               }
+       }
+
+       if (dp->neighbors == 6) {
+               int         nccols, ncrows, sides;
+
+               if (dp->width < 2)
+                       dp->width = 2;
+               if (dp->height < 4)
+                       dp->height = 4;
+               if (size < -MINSIZE)
+                       dp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               dp->ys = MAX(MINSIZE, MIN(dp->width, dp->height) / MINGRIDSIZE);
+                       else
+                               dp->ys = MINSIZE;
+               } else
+                       dp->ys = MIN(size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                              MINGRIDSIZE));
+               dp->xs = dp->ys;
+               dp->pixelmode = True;
+               nccols = MAX(dp->width / dp->xs - 2, 2);
+               ncrows = MAX(dp->height / dp->ys - 1, 2);
+               dp->ncols = nccols / 2;
+               dp->nrows = 2 * (ncrows / 4);
+               dp->xb = (dp->width - dp->xs * nccols) / 2 + dp->xs / 2;
+               dp->yb = (dp->height - dp->ys * (ncrows / 2) * 2) / 2 + dp->ys;
+               for (sides = 0; sides < 6; sides++) {
+                       dp->shape.hexagon[sides].x = (dp->xs - 1) * hexagonUnit[sides].x;
+                       dp->shape.hexagon[sides].y =
+                               ((dp->ys - 1) * hexagonUnit[sides].y / 2) * 4 / 3;
+               }
+       } else if (dp->neighbors == 4 || dp->neighbors == 8) {
+               if (dp->width < 2)
+                       dp->width = 2;
+               if (dp->height < 2)
+                       dp->height = 2;
+               if (size == 0 ||
+                   MINGRIDSIZE * size > dp->width || MINGRIDSIZE * size > dp->height) {
+                       if (dp->width > MINGRIDSIZE * icon_width &&
+                           dp->height > MINGRIDSIZE * icon_height) {
+                               dp->pixelmode = False;
+                               dp->xs = icon_width;
+                               dp->ys = icon_height;
+                       } else {
+                               dp->pixelmode = True;
+                               dp->xs = dp->ys = MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                                     MINGRIDSIZE);
+                       }
+               } else {
+                       dp->pixelmode = True;
+                       if (size < -MINSIZE)
+                               dp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+                       else if (size < MINSIZE)
+                               dp->ys = MINSIZE;
+                       else
+                               dp->ys = MIN(size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                                      MINGRIDSIZE));
+                       dp->xs = dp->ys;
+               }
+               dp->ncols = MAX(dp->width / dp->xs, 2);
+               dp->nrows = MAX(dp->height / dp->ys, 2);
+               dp->xb = (dp->width - dp->xs * dp->ncols) / 2;
+               dp->yb = (dp->height - dp->ys * dp->nrows) / 2;
+       } else {                /* TRI */
+               int         orient, sides;
+
+               if (dp->width < 2)
+                       dp->width = 2;
+               if (dp->height < 2)
+                       dp->height = 2;
+               if (size < -MINSIZE)
+                       dp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               dp->ys = MAX(MINSIZE, MIN(dp->width, dp->height) / MINGRIDSIZE);
+                       else
+                               dp->ys = MINSIZE;
+               } else
+                       dp->ys = MIN(size, MAX(MINSIZE, MIN(dp->width, dp->height) /
+                                              MINGRIDSIZE));
+               dp->xs = (int) (1.52 * dp->ys);
+               dp->pixelmode = True;
+               dp->ncols = (MAX(dp->width / dp->xs - 1, 2) / 2) * 2;
+               dp->nrows = (MAX(dp->height / dp->ys - 1, 2) / 2) * 2;
+               dp->xb = (dp->width - dp->xs * dp->ncols) / 2 + dp->xs / 2;
+               dp->yb = (dp->height - dp->ys * dp->nrows) / 2 + dp->ys / 2;
+               for (orient = 0; orient < 2; orient++) {
+                       for (sides = 0; sides < 3; sides++) {
+                               dp->shape.triangle[orient][sides].x =
+                                       (dp->xs - 2) * triangleUnit[orient][sides].x;
+                               dp->shape.triangle[orient][sides].y =
+                                       (dp->ys - 2) * triangleUnit[orient][sides].y;
+                       }
+               }
+       }
+
+       dp->npositions = dp->ncols * dp->nrows;
+
+       dp->pm[0][0] = 1, dp->pm[0][1] = 0;
+       if (bonus < 1.0 || bonus > 4.0)
+               dp->pm[1][0] = 1.85;
+       else
+               dp->pm[1][0] = bonus;
+       dp->pm[1][1] = 0;
+
+       if (MI_NPIXELS(mi) >= COLORS) {
+
+               dp->colors[0][0] = MI_PIXEL(mi, BLUE);  /* COOPERATING, was cooperating */
+               dp->colors[0][1] = MI_PIXEL(mi, GREEN);         /* COOPERATING, was defecting */
+               dp->colors[1][0] = MI_PIXEL(mi, YELLOW);        /* DEFECTING, was cooperating */
+               dp->colors[1][1] = MI_PIXEL(mi, RED);   /* DEFECTING, was defecting */
+       } else {
+               dp->colors[0][0] = MI_WHITE_PIXEL(mi);
+               dp->colors[0][1] = MI_WHITE_PIXEL(mi);
+               dp->colors[1][0] = MI_WHITE_PIXEL(mi);
+               dp->colors[1][1] = MI_WHITE_PIXEL(mi);
+       }
+       if (dp->s != NULL)
+               (void) free((void *) dp->s);
+       dp->s = (char *) calloc(dp->npositions, sizeof (char));
+
+       if (dp->sn != NULL)
+               (void) free((void *) dp->sn);
+       dp->sn = (char *) calloc(dp->npositions, sizeof (char));
+
+       if (dp->payoff != NULL)
+               (void) free((void *) dp->payoff);
+       dp->payoff = (float *) calloc(dp->npositions, sizeof (float));
+
+       MI_CLEARWINDOW(mi);
+
+       dp->defectors = MI_COUNT(mi);
+       if (dp->defectors < -MINDEFECT) {
+               dp->defectors = NRAND(-dp->defectors - MINDEFECT + 1) + MINDEFECT;
+       } else if (dp->defectors < MINDEFECT)
+               dp->defectors = MINDEFECT;
+       if (dp->defectors > dp->npositions)
+               dp->defectors = dp->npositions;
+
+       for (i = 0; i < dp->defectors; i++) {
+               do {
+                       colrow = NRAND(dp->npositions);
+               } while (dp->sn[colrow]);
+               dp->sn[colrow] = 1;
+       }
+#if 0                          /* if p was a float... */
+       mrow = 0;
+       for (row = 0; row < dp->nrows; row++) {
+               for (col = 0; col < dp->ncols; col++) {
+                       dp->sn[col + mrow] = ((float) LRAND() / MAXRAND < dp->p);
+               }
+               mrow += dp->ncols;
+       }
+#endif
+
+       dp->defectors = 0;
+
+       /* Show initial state... real important for debugging */
+       mrow = 0;
+       for (row = 0; row < dp->nrows; ++row) {
+               for (col = 0; col < dp->ncols; ++col) {
+                       addtolist(mi, col, row,
+                          dp->sn[col + mrow] * BITMAPS + dp->s[col + mrow]);
+               }
+               mrow += dp->ncols;
+       }
+}
+
+void
+draw_dilemma(ModeInfo * mi)
+{
+       dilemmastruct *dp = &dilemmas[MI_SCREEN(mi)];
+       int         col, row, mrow, colrow, n, i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (dp->state >= 2 * COLORS) {
+
+               for (col = 0; col < dp->ncols; col++) {
+                       for (row = 0; row < dp->nrows; row++) {
+                               colrow = col + row * dp->ncols;
+                               if (conscious)
+                                       dp->payoff[colrow] =
+                                               dp->pm[(int) dp->s[colrow]][(int) dp->s[colrow]];
+                               else
+                                       dp->payoff[colrow] = 0.0;
+                               for (n = 0; n < dp->neighbors; n++)
+                                       dp->payoff[colrow] +=
+                                               dp->pm[(int) dp->s[colrow]][(int)
+                                                 dp->s[neighbor_position(dp,
+                                       col, row, n * 360 / dp->neighbors)]];
+
+                       }
+               }
+               for (row = 0; row < dp->nrows; row++) {
+                       for (col = 0; col < dp->ncols; col++) {
+                               float       hp;
+                               int         position;
+
+                               colrow = col + row * dp->ncols;
+                               hp = dp->payoff[colrow];
+                               dp->sn[colrow] = dp->s[colrow];
+                               for (n = 0; n < dp->neighbors; n++) {
+                                       position = neighbor_position(dp, col, row, n * 360 / dp->neighbors);
+                                       if (ROUND_FLOAT(dp->payoff[position], 0.001) >
+                                           ROUND_FLOAT(hp, 0.001)) {
+                                               hp = dp->payoff[position];
+                                               dp->sn[colrow] = dp->s[position];
+                                       }
+                               }
+                       }
+               }
+               mrow = 0;
+               for (row = 0; row < dp->nrows; row++) {
+                       for (col = 0; col < dp->ncols; col++) {
+                               addtolist(mi, col, row,
+                                         dp->sn[col + mrow] * BITMAPS + dp->s[col + mrow]);
+                       }
+                       mrow += dp->ncols;
+               }
+
+               if (++dp->generation > MI_CYCLES(mi) ||
+                   dp->defectors == dp->npositions || dp->defectors == 0)
+                       init_dilemma(mi);
+               dp->state = 0;
+       } else {
+               if (dp->state < COLORS) {
+                       draw_state(mi, dp->state);
+               }
+               dp->state++;
+       }
+#if 1
+       if (dp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       drawcell(mi, dp->redrawpos % dp->ncols, dp->redrawpos / dp->ncols,
+                                dp->colors[(int) dp->sn[dp->redrawpos]][(int) dp->s[dp->redrawpos]],
+                                dp->sn[dp->redrawpos], 1);
+                       if (++(dp->redrawpos) >= dp->npositions) {
+                               dp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+#endif
+}
+
+void
+release_dilemma(ModeInfo * mi)
+{
+       if (dilemmas != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       dilemmastruct *dp = &dilemmas[screen];
+
+                       free_struct(dp);
+                       if (dp->s != NULL)
+                               (void) free((void *) dp->s);
+                       if (dp->sn != NULL)
+                               (void) free((void *) dp->sn);
+                       if (dp->payoff != NULL)
+                               (void) free((void *) dp->payoff);
+               }
+               (void) free((void *) dilemmas);
+               dilemmas = NULL;
+       }
+}
+
+void
+refresh_dilemma(ModeInfo * mi)
+{
+       dilemmastruct *dp = &dilemmas[MI_SCREEN(mi)];
+
+       dp->redrawing = 1;
+       dp->redrawpos = 0;
+}
+
+#endif /* MODE_dilemma */
diff --git a/xlockmore-4.14/modes/discrete.c b/xlockmore-4.14/modes/discrete.c
new file mode 100644 (file)
index 0000000..992d00f
--- /dev/null
@@ -0,0 +1,411 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* discrete --- chaotic mappings */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)discrete.c 4.10 98/04/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by Tim Auckland <Tim.Auckland@Sun.COM>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * "discrete" shows a number of fractals based on the "discrete map"
+ * type of dynamical systems.  They include a different way of looking
+ * at the HOPALONG system, an inverse julia-set iteration, the "Standard
+ * Map" and the "Bird in a Thornbush" fractal.
+ *
+ * Revision History:
+ * 31-Jul-97: Ported to xlockmore-4
+ * 08-Aug-96: Adapted from hop.c Copyright (c) 1991 by Patrick J. Naughton.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Discrete"
+#define HACK_INIT init_discrete
+#define HACK_DRAW draw_discrete
+#define discrete_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: 4096 \n" \
+ "*cycles: 2500 \n" \
+ "*ncolors: 100 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_discrete
+
+ModeSpecOpt discrete_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   discrete_description =
+{"discrete", "init_discrete", "draw_discrete", "release_discrete",
+ "refresh_discrete", "init_discrete", NULL, &discrete_opts,
+ 1000, 4096, 2500, 1, 64, 1.0, "",
+ "Shows various discrete maps", 0, NULL};
+
+#endif
+
+enum ftypes {
+       SQRT, BIRDIE, STANDARD, TRIG, CUBIC, HENON, AILUJ, HSHOE, DELOG
+};
+
+/*#define TEST STANDARD */
+
+#define BIASES 18
+static enum ftypes bias[BIASES] =
+{
+       STANDARD, STANDARD, STANDARD, STANDARD,
+       SQRT, SQRT, SQRT, SQRT,
+       BIRDIE, BIRDIE, BIRDIE,
+       AILUJ, AILUJ, AILUJ,
+       TRIG, TRIG,
+       CUBIC,
+       HENON,
+};
+
+typedef struct {
+       int         maxx;
+       int         maxy;       /* max of the screen */
+       double      a;
+       double      b;
+       double      c;
+       double      d;
+       double      e;
+       double      i;
+       double      j;          /* discrete parameters */
+       double      ic;
+       double      jc;
+       double      is;
+       double      js;
+       int         inc;
+       int         pix;
+       enum ftypes op;
+       int         count;
+       XPoint     *pointBuffer;        /* pointer for XDrawPoints */
+} discretestruct;
+
+static discretestruct *discretes = NULL;
+
+void
+init_discrete(ModeInfo * mi)
+{
+       double      range;
+       discretestruct *hp;
+
+       if (discretes == NULL) {
+               if ((discretes =
+                    (discretestruct *) calloc(MI_NUM_SCREENS(mi),
+                                          sizeof (discretestruct))) == NULL)
+                       return;
+       }
+       hp = &discretes[MI_SCREEN(mi)];
+
+
+       hp->maxx = MI_WIDTH(mi);
+       hp->maxy = MI_HEIGHT(mi);
+#ifdef TEST
+       hp->op = TEST;
+#else
+       hp->op = bias[LRAND() % BIASES];
+#endif
+       switch (hp->op) {
+               case HSHOE:
+                       hp->ic = 0;
+                       hp->jc = 0;
+                       hp->is = hp->maxx / (4);
+                       hp->js = hp->maxy / (4);
+                       hp->a = 0.5;
+                       hp->b = 0.5;
+                       hp->c = 0.2;
+                       hp->d = -1.25;
+                       hp->e = 1;
+                       hp->i = hp->j = 0.0;
+                       break;
+               case DELOG:
+                       hp->ic = 0.5;
+                       hp->jc = 0.3;
+                       hp->is = hp->maxx / 1.5;
+                       hp->js = hp->maxy / 1.5;
+                       hp->a = 2.176399;
+                       hp->i = hp->j = 0.01;
+                       break;
+               case HENON:
+                       hp->jc = ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.4;
+                       hp->ic = 1.3 * (1 - (hp->jc * hp->jc) / (0.4 * 0.4));
+                       hp->is = hp->maxx;
+                       hp->js = hp->maxy * 1.5;
+                       hp->a = 1;
+                       hp->b = 1.4;
+                       hp->c = 0.3;
+                       hp->i = hp->j = 0;
+                       break;
+               case SQRT:
+                       hp->ic = 0;
+                       hp->jc = 0;
+                       hp->is = 1;
+                       hp->js = 1;
+                       range = sqrt((double) hp->maxx * 2 * hp->maxx * 2 +
+                                    (double) hp->maxy * 2 * hp->maxy * 2) /
+                               (10.0 + LRAND() % 10);
+
+                       hp->a = (LRAND() / MAXRAND) * range - range / 2.0;
+                       hp->b = (LRAND() / MAXRAND) * range - range / 2.0;
+                       hp->c = (LRAND() / MAXRAND) * range - range / 2.0;
+                       if (!(LRAND() % 2))
+                               hp->c = 0.0;
+                       hp->i = hp->j = 0.0;
+                       break;
+               case STANDARD:
+                       hp->ic = M_PI;
+                       hp->jc = M_PI;
+                       hp->is = hp->maxx / (M_PI * 2);
+                       hp->js = hp->maxy / (M_PI * 2);
+                       hp->a = 0;      /* decay */
+                       hp->b = (LRAND() / MAXRAND) * 2.0;
+                       hp->c = 0;
+                       hp->i = M_PI;
+                       hp->j = M_PI;
+                       break;
+               case BIRDIE:
+                       hp->ic = 0;
+                       hp->jc = 0;
+                       hp->is = hp->maxx / 2;
+                       hp->js = hp->maxy / 2;
+                       hp->a = 1.99 + ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.2;
+                       hp->b = 0;
+                       hp->c = 0.8 + ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.1;
+                       hp->i = hp->j = 0;
+                       break;
+               case TRIG:
+                       hp->a = 5;
+                       hp->b = 0.5 + ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.3;
+                       hp->ic = hp->a;
+                       hp->jc = 0;
+                       hp->is = hp->maxx / (hp->b * 20);
+                       hp->js = hp->maxy / (hp->b * 20);
+                       hp->i = hp->j = 0;
+                       break;
+               case CUBIC:
+                       hp->a = 2.77;
+                       hp->b = 0.1 + ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.1;
+                       hp->ic = 0;
+                       hp->jc = 0;
+                       hp->is = hp->maxx / 4;
+                       hp->js = hp->maxy / 4;
+                       hp->i = hp->j = 0.1;
+                       break;
+               case AILUJ:
+                       {
+                               int         i;
+                               double      x, y, xn, yn;
+
+                               hp->ic = 0;
+                               hp->jc = 0;
+                               hp->is = hp->maxx / 4;
+                               hp->js = hp->maxx / 4;
+                               do {
+                                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * 1.5 - 0.5;
+                                       hp->b = ((LRAND() / MAXRAND) * 2.0 - 1.0) * 1.5;
+                                       x = y = 0;
+#define MAXITER 10
+                                       for (i = 0; i < MAXITER && x * x + y * y < 13; i++) {   /* 'Brot calc */
+                                               xn = x * x - y * y + hp->a;
+                                               yn = 2 * x * y + hp->b;
+                                               x = xn;
+                                               y = yn;
+                                       }
+                               } while (i < MAXITER);  /* wait for a connected set */
+                               hp->i = hp->j = 0.1;
+                               break;
+                       }
+       }
+       hp->pix = 0;
+       hp->inc = 0;
+
+       if (hp->pointBuffer == NULL)
+               hp->pointBuffer = (XPoint *) malloc(sizeof (XPoint) * MI_COUNT(mi));
+
+       /* Clear the background. */
+       MI_CLEARWINDOW(mi);
+
+       hp->count = 0;
+}
+
+
+void
+draw_discrete(ModeInfo * mi)
+{
+       Display    *dsp = MI_DISPLAY(mi);
+       Window      win = MI_WINDOW(mi);
+       double      oldj, oldi;
+       int         count = MI_COUNT(mi);
+       int         cycles = MI_CYCLES(mi);
+       int         k;
+       XPoint     *xp;
+       GC          gc = MI_GC(mi);
+       discretestruct *hp = &discretes[MI_SCREEN(mi)];
+
+       k = count;
+       xp = hp->pointBuffer;
+
+       hp->inc++;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(dsp, gc, MI_PIXEL(mi, hp->pix));
+               if (++hp->pix >= MI_NPIXELS(mi))
+                       hp->pix = 0;
+       }
+       while (k--) {
+               oldj = hp->j;
+               oldi = hp->i;
+               switch (hp->op) {
+                       case HSHOE:
+                               {
+                                       int         i;
+
+#if 0
+                                       if (!k) {
+                                               XSetForeground(dsp, gc, MI_BLACK_PIXEL(mi));
+                                               XFillRectangle(dsp, win, gc, 0, 0, hp->maxx, hp->maxy);
+                                               XSetForeground(dsp, gc, MI_PIXEL(mi, hp->pix));
+                                       } else
+#endif
+#define HD
+#ifdef HD
+                                       if (k < count / 4) {
+                                               hp->i = ((double) k / count) * 8 - 1;
+                                               hp->j = 1;
+                                       } else if (k < count / 2) {
+                                               hp->i = 1;
+                                               hp->j = 3 - ((double) k / count) * 8;
+                                       } else if (k < 3 * count / 4) {
+                                               hp->i = 5 - ((double) k / count) * 8;
+                                               hp->j = -1;
+                                       } else {
+                                               hp->i = -1;
+                                               hp->j = ((double) k / count) * 8 - 7;
+                                       }
+                                       for (i = 1; i < (hp->inc % 15); i++) {
+                                               oldj = hp->j;
+                                               oldi = hp->i;
+#endif
+                                               hp->i = (hp->a * oldi + hp->b) * oldj;
+                                               hp->j = (hp->e - hp->d + hp->c * oldi) * oldj * oldj - hp->c * oldi + hp->d;
+#ifdef HD
+                                       }
+#endif
+                                       break;
+                               }
+                       case DELOG:
+                               hp->j = oldi;
+                               hp->i = hp->a * oldi * (1 - oldj);
+                               break;
+                       case HENON:
+                               hp->i = oldj + hp->a - hp->b * oldi * oldi;
+                               hp->j = hp->c * oldi;
+                               break;
+                       case SQRT:
+                               if (k) {
+                                       hp->j = hp->a + hp->i;
+                                       hp->i = -oldj + (hp->i < 0
+                                       ? sqrt(fabs(hp->b * (hp->i - hp->c)))
+                                                        : -sqrt(fabs(hp->b * (hp->i - hp->c))));
+                               } else {
+                                       static int  s = 1;
+
+                                       hp->i = s * hp->inc * hp->maxx / cycles / 2;
+                                       hp->j = hp->a + hp->i;
+                                       s = -s;
+                               }
+                               break;
+                       case STANDARD:
+                               if (k) {
+                                       hp->j = (1 - hp->a) * oldj + hp->b * sin(oldi) + hp->a * hp->c;
+                                       hp->j = fmod(hp->j + 2 * M_PI, 2 * M_PI);
+                                       hp->i = oldi + hp->j;
+                                       hp->i = fmod(hp->i + 2 * M_PI, 2 * M_PI);
+                               } else {
+                                       static int  s = 1;
+
+                                       hp->j = M_PI + fmod(s * hp->inc * 2 * M_PI / (cycles - 0.5), M_PI);
+                                       hp->i = M_PI;
+                                       s = -s;
+                               }
+                               break;
+                       case BIRDIE:
+                               hp->j = oldi;
+                               hp->i = (1 - hp->c) * cos(M_PI * hp->a * oldj) + hp->c * hp->b;
+                               hp->b = oldj;
+                               break;
+                       case TRIG:
+                               {
+                                       double      r2 = oldi * oldi + oldj * oldj;
+
+                                       hp->i = hp->a + hp->b * (oldi * cos(r2) - oldj * sin(r2));
+                                       hp->j = hp->b * (oldj * cos(r2) + oldi * sin(r2));
+                               }
+                               break;
+                       case CUBIC:
+                               hp->i = oldj;
+                               hp->j = hp->a * oldj - oldj * oldj * oldj - hp->b * oldi;
+                               break;
+                       case AILUJ:
+                               hp->i = ((LRAND() < MAXRAND / 2) ? -1 : 1) *
+                                       sqrt(((oldi - hp->a) +
+                                             sqrt((oldi - hp->a) * (oldi - hp->a) + (oldj - hp->b) * (oldj - hp->b))) / 2);
+                               if (hp->i < 0.00000001 && hp->i > -0.00000001)
+                                       hp->i = (hp->i > 0.0) ? 0.00000001 : -0.00000001;
+                               hp->j = (oldj - hp->b) / (2 * hp->i);
+                               break;
+               }
+               xp->x = hp->maxx / 2 + (int) ((hp->i - hp->ic) * hp->is);
+               xp->y = hp->maxy / 2 - (int) ((hp->j - hp->jc) * hp->js);
+               xp++;
+       }
+       XDrawPoints(dsp, win, gc, hp->pointBuffer, count, CoordModeOrigin);
+       if (++hp->count > cycles) {
+               init_discrete(mi);
+       }
+}
+
+void
+release_discrete(ModeInfo * mi)
+{
+       if (discretes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       discretestruct *hp = &discretes[screen];
+
+                       if (hp->pointBuffer != NULL)
+                               (void) free((void *) hp->pointBuffer);
+               }
+               (void) free((void *) discretes);
+               discretes = NULL;
+       }
+}
+
+void
+refresh_discrete(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_discrete */
diff --git a/xlockmore-4.14/modes/drift.c b/xlockmore-4.14/modes/drift.c
new file mode 100644 (file)
index 0000000..046784a
--- /dev/null
@@ -0,0 +1,648 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* drift --- drifting recursive fractal cosmic flames */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)drift.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Jamie Zawinski <jwz@jwz.org> compatible with xscreensaver
+ * 01-Jan-97: Moved new flame to drift.  Compile time options now run time.
+ * 01-Jun-95: Updated by Scott Draves.
+ * 27-Jun-91: vary number of functions used.
+ * 24-Jun-91: fixed portability problem with integer mod (%).
+ * 06-Jun-91: Written, received from Scott Draves <spot@cs.cmu.edu>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Drift"
+#define HACK_INIT init_drift
+#define HACK_DRAW draw_drift
+#define drift_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 30 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_drift
+
+#define DEF_GROW "False"       /* Grow fractals instead of animating one at a time,
+                                  would then be like flame */
+#define DEF_LISS "False"       /* if this is defined then instead of a point
+                                  bouncing around in a high dimensional sphere, we
+                                  use lissojous figures.  Only makes sense if
+                                  grow is false. */
+
+static Bool grow;
+static Bool liss;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-grow", ".drift.grow", XrmoptionNoArg, (caddr_t) "on"},
+       {"+grow", ".drift.grow", XrmoptionNoArg, (caddr_t) "off"},
+       {"-liss", ".drift.trail", XrmoptionNoArg, (caddr_t) "on"},
+       {"+liss", ".drift.trail", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & grow, "grow", "Grow", DEF_GROW, t_Bool},
+       {(caddr_t *) & liss, "liss", "Liss", DEF_LISS, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+grow", "turn on/off growing fractals, else they are animated"},
+       {"-/+liss", "turn on/off using lissojous figures to get points"}
+};
+
+ModeSpecOpt drift_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   drift_description =
+{"drift", "init_drift", "draw_drift", "release_drift",
+ "refresh_drift", "init_drift", NULL, &drift_opts,
+ 10000, 30, 1, 1, 64, 1.0, "",
+ "Shows cosmic drifting flame fractals", 0, NULL};
+
+#endif
+
+#define MAXBATCH1      200     /* mono */
+#define MAXBATCH2      20      /* color */
+#define FUSE           10      /* discard this many initial iterations */
+#define NMAJORVARS     7
+#define MAXLEV 10
+
+typedef struct {
+       /* shape of current flame */
+       int         nxforms;
+       double      f[2][3][MAXLEV];    /* a bunch of non-homogeneous xforms */
+       int         variation[10];      /* for each xform */
+
+       /* Animation */
+       double      df[2][3][MAXLEV];
+
+       /* high-level control */
+       int         mode;       /* 0->slow/single 1->fast/many */
+       int         nfractals;  /* draw this many fractals */
+       int         major_variation;
+       int         fractal_len;        /* pts/fractal */
+       int         color;
+       int         rainbow;    /* more than one color per fractal
+                                  1-> computed by adding dimension to fractal */
+
+       int         width, height;      /* of window */
+       int         timer;
+
+       /* draw info about current flame */
+       int         fuse;       /* iterate this many before drawing */
+       int         total_points;       /* draw this many pts before fractal ends */
+       int         npoints;    /* how many we've computed but not drawn */
+       XPoint      pts[MAXBATCH1];     /* here they are */
+       unsigned long pixcol;
+       /* when drawing in color, we have a buffer per color */
+       int        *ncpoints;
+       XPoint     *cpts;
+
+       double      x, y, c;
+       int         liss_time;
+       Bool        grow, liss;
+
+       short       lasthalf;
+       long        saved_random_bits;
+       int         nbits;
+} driftstruct;
+
+static driftstruct *drifts = NULL;
+
+static short
+halfrandom(driftstruct * dp, int mv)
+{
+       unsigned long r;
+
+       if (dp->lasthalf) {
+               r = dp->lasthalf;
+               dp->lasthalf = 0;
+       } else {
+               r = LRAND();
+               dp->lasthalf = (short) (r >> 16);
+       }
+       r = r % mv;
+       return r;
+}
+
+static int
+frandom(driftstruct * dp, int n)
+{
+       int         result;
+
+       if (3 > dp->nbits) {
+               dp->saved_random_bits = LRAND();
+               dp->nbits = 31;
+       }
+       switch (n) {
+               case 2:
+                       result = (int) (dp->saved_random_bits & 1);
+                       dp->saved_random_bits >>= 1;
+                       dp->nbits -= 1;
+                       return result;
+
+               case 3:
+                       result = (int) (dp->saved_random_bits & 3);
+                       dp->saved_random_bits >>= 2;
+                       dp->nbits -= 2;
+                       if (3 == result)
+                               return frandom(dp, 3);
+                       return result;
+
+               case 4:
+                       result = (int) (dp->saved_random_bits & 3);
+                       dp->saved_random_bits >>= 2;
+                       dp->nbits -= 2;
+                       return result;
+
+               case 5:
+                       result = (int) (dp->saved_random_bits & 7);
+                       dp->saved_random_bits >>= 3;
+                       dp->nbits -= 3;
+                       if (4 < result)
+                               return frandom(dp, 5);
+                       return result;
+               default:
+                       (void) fprintf(stderr, "bad arg to frandom\n");
+       }
+       return 0;
+}
+
+#define DISTRIB_A (halfrandom(dp, 7000) + 9000)
+#define DISTRIB_B ((frandom(dp, 3) + 1) * (frandom(dp, 3) + 1) * 120000)
+#define LEN(x) (sizeof(x)/sizeof((x)[0]))
+
+static void
+initmode(ModeInfo * mi, int mode)
+{
+       driftstruct *dp = &drifts[MI_SCREEN(mi)];
+
+#define VARIATION_LEN 14
+
+       dp->mode = mode;
+
+       dp->major_variation = halfrandom(dp, VARIATION_LEN);
+       /*  0, 0, 1, 1, 2, 2, 3, 4, 4, 5, 5, 6, 6, 6 */
+       dp->major_variation = ((dp->major_variation >= VARIATION_LEN >> 1) &&
+                              (dp->major_variation < VARIATION_LEN - 1)) ?
+               (dp->major_variation + 1) >> 1 : dp->major_variation >> 1;
+
+       if (dp->grow) {
+               dp->rainbow = 0;
+               if (mode) {
+                       if (!dp->color || halfrandom(dp, 8)) {
+                               dp->nfractals = halfrandom(dp, 30) + 5;
+                               dp->fractal_len = DISTRIB_A;
+                       } else {
+                               dp->nfractals = halfrandom(dp, 5) + 5;
+                               dp->fractal_len = DISTRIB_B;
+                       }
+               } else {
+                       dp->rainbow = dp->color;
+                       dp->nfractals = 1;
+                       dp->fractal_len = DISTRIB_B;
+               }
+       } else {
+               dp->nfractals = 1;
+               dp->rainbow = dp->color;
+               dp->fractal_len = 2000000;
+       }
+       dp->fractal_len = (dp->fractal_len * MI_COUNT(mi)) / 20;
+
+       MI_CLEARWINDOW(mi);
+}
+
+static void
+pick_df_coefs(ModeInfo * mi)
+{
+       driftstruct *dp = &drifts[MI_SCREEN(mi)];
+       int         i, j, k;
+       double      r;
+
+       for (i = 0; i < dp->nxforms; i++) {
+
+               r = 1e-6;
+               for (j = 0; j < 2; j++)
+                       for (k = 0; k < 3; k++) {
+                               dp->df[j][k][i] = ((double) halfrandom(dp, 1000) / 500.0 - 1.0);
+                               r += dp->df[j][k][i] * dp->df[j][k][i];
+                       }
+               r = (3 + halfrandom(dp, 5)) * 0.01 / sqrt(r);
+               for (j = 0; j < 2; j++)
+                       for (k = 0; k < 3; k++)
+                               dp->df[j][k][i] *= r;
+       }
+}
+
+static void
+initfractal(ModeInfo * mi)
+{
+       driftstruct *dp = &drifts[MI_SCREEN(mi)];
+       int         i, j, k;
+
+#define XFORM_LEN 9
+
+       dp->fuse = FUSE;
+       dp->total_points = 0;
+
+       if (!dp->ncpoints)
+               dp->ncpoints = (int *) malloc(sizeof (int) * MI_NCOLORS(mi));
+
+       if (!dp->cpts)
+               dp->cpts = (XPoint *) malloc(MAXBATCH2 * sizeof (XPoint) * MI_NCOLORS(mi));
+       if (dp->rainbow)
+               for (i = 0; i < MI_NPIXELS(mi); i++)
+                       dp->ncpoints[i] = 0;
+       else
+               dp->npoints = 0;
+       dp->nxforms = halfrandom(dp, XFORM_LEN);
+       /* 2, 2, 2, 3, 3, 3, 4, 4, 5 */
+       dp->nxforms = (dp->nxforms >= XFORM_LEN - 1) + dp->nxforms / 3 + 2;
+
+       dp->c = dp->x = dp->y = 0.0;
+       if (dp->liss && !halfrandom(dp, 10)) {
+               dp->liss_time = 0;
+       }
+       if (!dp->grow)
+               pick_df_coefs(mi);
+       for (i = 0; i < dp->nxforms; i++) {
+               if (NMAJORVARS == dp->major_variation)
+                       dp->variation[i] = halfrandom(dp, NMAJORVARS);
+               else
+                       dp->variation[i] = dp->major_variation;
+               for (j = 0; j < 2; j++)
+                       for (k = 0; k < 3; k++) {
+                               if (dp->liss)
+                                       dp->f[j][k][i] = sin(dp->liss_time * dp->df[j][k][i]);
+                               else
+                                       dp->f[j][k][i] = ((double) halfrandom(dp, 1000) / 500.0 - 1.0);
+                       }
+       }
+       if (dp->color)
+               dp->pixcol = MI_PIXEL(mi, halfrandom(dp, MI_NPIXELS(mi)));
+       else
+               dp->pixcol = MI_WHITE_PIXEL(mi);
+
+}
+
+
+void
+init_drift(ModeInfo * mi)
+{
+       driftstruct *dp;
+
+       if (drifts == NULL) {
+               if ((drifts = (driftstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (driftstruct))) == NULL)
+                       return;
+       }
+       dp = &drifts[MI_SCREEN(mi)];
+
+       dp->width = MI_WIDTH(mi);
+       dp->height = MI_HEIGHT(mi);
+       dp->color = MI_NPIXELS(mi) > 2;
+
+       if (MI_IS_FULLRANDOM(mi)) {
+               if (NRAND(3) == 0)
+                       dp->grow = True;
+               else {
+                       dp->grow = False;
+                       dp->liss = (Bool) (LRAND() & 1);
+               }
+       } else {
+               dp->grow = grow;
+               if (dp->grow)
+                       dp->liss = False;
+               else
+                       dp->liss = liss;
+       }
+       initmode(mi, 1);
+       initfractal(mi);
+}
+
+static void
+iter(driftstruct * dp)
+{
+       int         i = frandom(dp, dp->nxforms);
+       double      nx, ny, nc;
+
+
+       if (i)
+               nc = (dp->c + 1.0) / 2.0;
+       else
+               nc = dp->c / 2.0;
+
+       nx = dp->f[0][0][i] * dp->x + dp->f[0][1][i] * dp->y + dp->f[0][2][i];
+       ny = dp->f[1][0][i] * dp->x + dp->f[1][1][i] * dp->y + dp->f[1][2][i];
+
+
+       switch (dp->variation[i]) {
+               case 1:
+                       /* sinusoidal */
+                       nx = sin(nx);
+                       ny = sin(ny);
+                       break;
+               case 2:
+                       {
+                               /* complex */
+                               double      r2 = nx * nx + ny * ny + 1e-6;
+
+                               nx = nx / r2;
+                               ny = ny / r2;
+                               break;
+                       }
+               case 3:
+                       /* bent */
+                       if (nx < 0.0)
+                               nx = nx * 2.0;
+                       if (ny < 0.0)
+                               ny = ny / 2.0;
+                       break;
+               case 4:
+                       {
+                               /* swirl */
+
+                               double      r = (nx * nx + ny * ny);    /* times k here is fun */
+                               double      c1 = sin(r);
+                               double      c2 = cos(r);
+                               double      t = nx;
+
+                               if (nx > 1e4 || nx < -1e4 || ny > 1e4 || ny < -1e4)
+                                       ny = 1e4;
+                               else
+                                       ny = c2 * t + c1 * ny;
+                               nx = c1 * nx - c2 * ny;
+                               break;
+                       }
+               case 5:
+                       {
+                               /* horseshoe */
+                               double      r, c1, c2, t;
+
+                               /* Avoid atan2: DOMAIN error message */
+                               if (nx == 0.0 && ny == 0.0)
+                                       r = 0.0;
+                               else
+                                       r = atan2(nx, ny);      /* times k here is fun */
+                               c1 = sin(r);
+                               c2 = cos(r);
+                               t = nx;
+
+                               nx = c1 * nx - c2 * ny;
+                               ny = c2 * t + c1 * ny;
+                               break;
+                       }
+               case 6:
+                       {
+                               /* drape */
+                               double      t;
+
+                               /* Avoid atan2: DOMAIN error message */
+                               if (nx == 0.0 && ny == 0.0)
+                                       t = 0.0;
+                               else
+                                       t = atan2(nx, ny) / M_PI;
+
+                               if (nx > 1e4 || nx < -1e4 || ny > 1e4 || ny < -1e4)
+                                       ny = 1e4;
+                               else
+                                       ny = sqrt(nx * nx + ny * ny) - 1.0;
+                               nx = t;
+                               break;
+                       }
+       }
+
+#if 0
+       /* here are some others */
+       {
+               /* broken */
+               if (nx > 1.0)
+                       nx = nx - 1.0;
+               if (nx < -1.0)
+                       nx = nx + 1.0;
+               if (ny > 1.0)
+                       ny = ny - 1.0;
+               if (ny < -1.0)
+                       ny = ny + 1.0;
+               break;
+       }
+       {
+               /* complex sine */
+               double      u = nx, v = ny;
+               double      ev = exp(v);
+               double      emv = exp(-v);
+
+               nx = (ev + emv) * sin(u) / 2.0;
+               ny = (ev - emv) * cos(u) / 2.0;
+       }
+       {
+
+               /* polynomial */
+               if (nx < 0)
+                       nx = -nx * nx;
+               else
+                       nx = nx * nx;
+
+               if (ny < 0)
+                       ny = -ny * ny;
+               else
+                       ny = ny * ny;
+       }
+       {
+               /* spherical */
+               double      r = 0.5 + sqrt(nx * nx + ny * ny + 1e-6);
+
+               nx = nx / r;
+               ny = ny / r;
+       }
+       {
+               nx = atan(nx) / M_PI_2
+                       ny = atan(ny) / M_PI_2
+       }
+#endif
+
+       /* how to check nan too?  some machines don't have finite().
+          don't need to check ny, it'll propogate */
+       if (nx > 1e4 || nx < -1e4) {
+               nx = halfrandom(dp, 1000) / 500.0 - 1.0;
+               ny = halfrandom(dp, 1000) / 500.0 - 1.0;
+               dp->fuse = FUSE;
+       }
+       dp->x = nx;
+       dp->y = ny;
+       dp->c = nc;
+
+}
+
+static void
+draw(ModeInfo * mi, driftstruct * dp, Drawable d)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       double      x = dp->x;
+       double      y = dp->y;
+       int         fixed_x, fixed_y, npix, c, n;
+
+       if (dp->fuse) {
+               dp->fuse--;
+               return;
+       }
+       if (!(x > -1.0 && x < 1.0 && y > -1.0 && y < 1.0))
+               return;
+
+       fixed_x = (int) ((dp->width / 2) * (x + 1.0));
+       fixed_y = (int) ((dp->height / 2) * (y + 1.0));
+
+       if (!dp->rainbow) {
+
+               dp->pts[dp->npoints].x = fixed_x;
+               dp->pts[dp->npoints].y = fixed_y;
+               dp->npoints++;
+               if (dp->npoints == MAXBATCH1) {
+                       XSetForeground(display, gc, dp->pixcol);
+                       XDrawPoints(display, d, gc, dp->pts, dp->npoints, CoordModeOrigin);
+                       dp->npoints = 0;
+               }
+       } else {
+
+               npix = MI_NPIXELS(mi);
+               c = (int) (dp->c * npix);
+
+               if (c < 0)
+                       c = 0;
+               if (c >= npix)
+                       c = npix - 1;
+               n = dp->ncpoints[c];
+               dp->cpts[c * MAXBATCH2 + n].x = fixed_x;
+               dp->cpts[c * MAXBATCH2 + n].y = fixed_y;
+               if (++dp->ncpoints[c] == MAXBATCH2) {
+                       XSetForeground(display, gc, MI_PIXEL(mi, c));
+                       XDrawPoints(display, d, gc, &(dp->cpts[c * MAXBATCH2]),
+                                   dp->ncpoints[c], CoordModeOrigin);
+                       dp->ncpoints[c] = 0;
+               }
+       }
+}
+
+static void
+draw_flush(ModeInfo * mi, driftstruct * dp, Drawable d)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+
+       if (dp->rainbow) {
+               int         npix = MI_NPIXELS(mi);
+               int         i;
+
+               for (i = 0; i < npix; i++) {
+                       if (dp->ncpoints[i]) {
+                               XSetForeground(display, gc, MI_PIXEL(mi, i));
+                               XDrawPoints(display, d, gc, &(dp->cpts[i * MAXBATCH2]),
+                                           dp->ncpoints[i], CoordModeOrigin);
+                               dp->ncpoints[i] = 0;
+                       }
+               }
+       } else {
+               if (dp->npoints)
+                       XSetForeground(display, gc, dp->pixcol);
+               XDrawPoints(display, d, gc, dp->pts,
+                           dp->npoints, CoordModeOrigin);
+               dp->npoints = 0;
+       }
+}
+
+
+void
+draw_drift(ModeInfo * mi)
+{
+       Window      window = MI_WINDOW(mi);
+       driftstruct *dp = &drifts[MI_SCREEN(mi)];
+
+       dp->timer = 3000;
+
+       MI_IS_DRAWN(mi) = True;
+
+       while (dp->timer) {
+               iter(dp);
+               draw(mi, dp, window);
+               if (dp->total_points++ > dp->fractal_len) {
+                       draw_flush(mi, dp, window);
+                       if (0 == --dp->nfractals) {
+                               initmode(mi, frandom(dp, 2));
+                       }
+                       initfractal(mi);
+               }
+               dp->timer--;
+       }
+       if (!dp->grow) {
+               int         i, j, k;
+
+               draw_flush(mi, dp, window);
+               if (dp->liss)
+                       dp->liss_time++;
+               for (i = 0; i < dp->nxforms; i++)
+                       for (j = 0; j < 2; j++)
+                               for (k = 0; k < 3; k++) {
+                                       if (dp->liss)
+                                               dp->f[j][k][i] = sin(dp->liss_time * dp->df[j][k][i]);
+                                       else {
+                                               double      t = dp->f[j][k][i] += dp->df[j][k][i];
+
+                                               if (t < -1.0 || 1.0 < t)
+                                                       dp->df[j][k][i] *= -1.0;
+                                       }
+                               }
+       }
+}
+
+void
+release_drift(ModeInfo * mi)
+{
+       if (drifts != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       driftstruct *dp = &drifts[screen];
+
+                       (void) free((void *) dp->ncpoints);
+                       (void) free((void *) dp->cpts);
+               }
+               (void) free((void *) drifts);
+               drifts = NULL;
+       }
+}
+
+void
+refresh_drift(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_drift */
diff --git a/xlockmore-4.14/modes/ext.life b/xlockmore-4.14/modes/ext.life
new file mode 100644 (file)
index 0000000..07e4ca4
--- /dev/null
@@ -0,0 +1,31 @@
+
+Drop these points in life.c, within the 'patterns' array.
+Note if the number of points > 64, one must increase points NUMPTS;
+also to fit most screens and especially the iconified window,
+one should have the size < 32x32.
+
+       {
+               1, -11,
+               0, -10, 1, -10,
+               -2, -8, -1, -8, 0, -8,
+               -2, -7, -1, -7, 0, -7,
+               -3, -4, -2, -4, -1, -4,
+               -3, -3, -2, -3,
+               -4, -2, -1, -2, 0, -2, 1, -2, 3, -2,
+               -4, -1, -3, -1, -1, -1, 3, -1,
+               -4, 0, -3, 0, -1, 0, 0, 0, 2, 0, 3, 0,
+               -4, 1, -3, 1, -2, 1,
+               -4, 2, -3, 2,
+               -4, 3,
+               -4, 4, -3, 4,
+               -3, 5, -1, 5,
+               1, 6,
+               -1, 7, 2, 7,
+               0, 8, 3, 8,
+               0, 9,
+               3, 10,
+               1, 11, 2, 11, 3, 11,
+               127
+       },
+
+points = 49; size = 8x23
diff --git a/xlockmore-4.14/modes/eyes.c b/xlockmore-4.14/modes/eyes.c
new file mode 100644 (file)
index 0000000..1532829
--- /dev/null
@@ -0,0 +1,1065 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* eyes --- follow the bouncing Grelb */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)eyes.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright 1996 by Ron Hitchens <ron@idiom.com>
+ *
+ * Adapted from the ubiquitous xeyes demo supplied by MIT with the
+ * X Window System.
+ * That code is Copyright 1991 Massachusetts Institute of Technology.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 04-Sep-97: Added interactive frobbing with mouse (copied from julia.c)
+ * 10-May-97: Compatible with xscreensaver
+ * 18-Mar-96: Changes for new hook calling conventions.  Keep per-screen
+ *            state information.  Remove global accesses.
+ * 21-Feb-96: Recoded to keep an off-screen image for each pair of eyes,
+ *            and to only paint the changed parts to the screen.
+ *            Allow the Grelb to enter from either side.
+ * 18-Feb-96: Got the code into mostly working condition.
+ * 15-Feb-96: Had a brainwave, started hacking the xeyes code.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Eyes"
+#define HACK_INIT init_eyes
+#define HACK_DRAW draw_eyes
+#define eyes_opts xlockmore_opts
+#define DEFAULTS "*delay: 20000 \n" \
+ "*count: -8 \n" \
+ "*cycles: 5 \n" \
+ "*ncolors: 200 \n" \
+ "*bitmap: \n" \
+ "*trackmouse: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_eyes
+
+#define DEF_TRACKMOUSE  "False"
+
+static Bool trackmouse;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-track", ".eyes.trackmouse", XrmoptionNoArg, (caddr_t) "on"},
+       {"+track", ".eyes.trackmouse", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & trackmouse, "trackmouse", "TrackMouse", DEF_TRACKMOUSE, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-/+trackmouse", "turn on/off the tracking of the mouse"}
+};
+
+ModeSpecOpt eyes_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   eyes_description =
+{"eyes", "init_eyes", "draw_eyes", "release_eyes",
+ "refresh_eyes", "init_eyes", NULL, &eyes_opts,
+ 20000, -8, 5, 1, 64, 1.0, "",
+ "Shows eyes following a bouncing grelb", 0, NULL};
+
+#endif
+
+/* definitions for the xlock version of xeyes */
+#define MAX_EYES               200     /* limit or uses too much memory */
+#define MIN_EYE_SIZE           50      /* smallest size eyes can be */
+#define FLY_ICON_SIZE          5       /* the size of a fly when iconic */
+#define FLY_MAX_SPEED          10      /* max (slowest) delay between steps */
+#define FLY_SIDE_LEFT          0       /* enter and leave by left side */
+#define FLY_SIDE_RIGHT         1       /* enter and leave by right side */
+#define LIFE_MIN               100     /* shortest life, cycles  */
+#define LIFE_RANGE             1000    /* range of possible lifetimes */
+#define MAX_CYCLES             10      /* max value of cycles */
+#define FRICTION               24      /* affects bounciness */
+
+/* definitions from the original MIT xeyes code */
+#define NUM_EYES               2
+#define EYE_X(n)               ((n) * 2.0)
+#define EYE_Y(n)               (0.0)
+#define EYE_OFFSET             (0.1)   /* padding between eyes */
+#define EYE_THICK              (0.175)         /* thickness of eye rim */
+#define BALL_WIDTH             (0.3)
+#define BALL_PAD               (0.05)
+#define EYE_WIDTH              (2.0 - (EYE_THICK + EYE_OFFSET) * 2)
+#define EYE_HEIGHT             EYE_WIDTH
+#define EYE_HWIDTH             (EYE_WIDTH / 2.0)
+#define EYE_HHEIGHT            (EYE_HEIGHT / 2.0)
+#define BALL_HEIGHT            BALL_WIDTH
+#define BALL_DIST              ((EYE_WIDTH - BALL_WIDTH) / 2.0 - BALL_PAD)
+#define W_MIN_X                        (-1.0 + EYE_OFFSET)
+#define W_MAX_X                        (3.0 - EYE_OFFSET)
+#define W_MIN_Y                        (-1.0 + EYE_OFFSET)
+#define W_MAX_Y                        (1.0 - EYE_OFFSET)
+
+/* ---------------------------------------------------------------------- */
+
+/* definitions of matrix math code used by xeyes */
+
+#define TPointEqual(a, b)      ((a).x == (b).x && (a).y == (b).y)
+#define XPointEqual(a, b)      ((a).x == (b).x && (a).y == (b).y)
+
+typedef struct _transform {
+       double      mx, bx;
+       double      my, by;
+} Transform;
+
+typedef struct _TPoint {
+       double      x, y;
+} TPoint;
+
+#define Xx(x,y,t)              ((int)((t)->mx * (x) + (t)->bx + 0.5))
+#define Xy(x,y,t)              ((int)((t)->my * (y) + (t)->by + 0.5))
+#define Xwidth(w,h,t)          ((int)((t)->mx * (w) + 0.5))
+#define Xheight(w,h,t)         ((int)((t)->my * (h) + 0.5))
+#define Tx(x,y,t)              ((((double) (x)) - (t)->bx) / (t)->mx)
+#define Ty(x,y,t)              ((((double) (y)) - (t)->by) / (t)->my)
+#define Twidth(w,h,t)          (((double) (w)) / (t)->mx)
+#define Theight(w,h,t)         (((double) (h)) / (t)->my)
+
+/* ---------------------------------------------------------------------- */
+
+/* aliases for vars defined in the bitmap file */
+#define FLY_WIDTH              image_width
+#define FLY_HEIGHT             image_height
+#define FLY_BITS               image_bits
+
+#include "eyes.xbm"
+
+typedef struct {               /* info about a "fly" */
+       int         x, y;
+       int         oldx, oldy;
+       int         width, height;
+       int         vx, vy;
+       int         side;
+       unsigned long pixel;
+       int         zero_y;
+} Fly;
+
+typedef struct {               /* info about a pair of eyes */
+       int         x, y;
+       int         width;
+       int         height;
+       int         xoff, yoff;
+       int         rectw, recth;
+       int         painted;
+       unsigned long time_to_die;
+       unsigned long eyelid_pixel, eyeball_pixel, pupil_pixel;
+       Pixmap      pixmap;
+       XRectangle  bbox;
+       Transform   transform;
+       TPoint      pupil[2];
+       TPoint      last_pupil[2];
+} Eyes;
+
+typedef struct {               /* per-screen info */
+       Pixmap      flypix;
+       int         flywidth, flyheight;
+       int         graphics_format;
+       GC          eyeGC;
+       GC          flyGC;
+       int         num_eyes;
+       Eyes       *eyes;
+       Fly         fly;
+       Cursor      cursor;
+       unsigned long time;
+} EyeScrInfo;
+
+/* ---------------------------------------------------------------------- */
+
+static EyeScrInfo *eye_info = NULL;
+
+static int  stuff_alloced = False;     /* is stuff here alloced */
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Fill an arc, using a tranformation matrix.  Lifted from xeyes.
+ *      The code to return the bounding box is a local addition.
+ */
+
+static void
+TFillArc(register Display * dpy, Drawable d, GC gc, Transform * t, double x, double y, double width, double height, int angle1, int angle2, XRectangle * rect)
+{
+       int         xx, xy, xw, xh;
+
+       xx = Xx(x, y, t);
+       xy = Xy(x, y, t);
+       xw = Xwidth(width, height, t);
+       xh = Xheight(width, height, t);
+       if (xw < 0) {
+               xx += xw;
+               xw = -xw;
+       }
+       if (xh < 0) {
+               xy += xh;
+               xh = -xh;
+       }
+       XFillArc(dpy, d, gc, xx, xy, xw, xh, angle1, angle2);
+
+       if (rect != NULL) {
+               rect->x = xx;
+               rect->y = xy;
+               rect->width = xw;
+               rect->height = xh;
+       }
+}
+
+
+/*-
+ *    Set a tranform matrix from the given arguments.  Lifted from xeyes.
+ */
+
+static void
+SetTransform(Transform * t, int xx1, int xx2, int xy1, int xy2, double tx1, double tx2, double ty1, double ty2)
+{
+       t->mx = ((double) xx2 - xx1) / (tx2 - tx1);
+       t->bx = ((double) xx1) - t->mx * tx1;
+       t->my = ((double) xy2 - xy1) / (ty2 - ty1);
+       t->by = ((double) xy1) - t->my * ty1;
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Given two rectangles, return the rectangle which encloses both.
+ *      Used to clculate "damage" when the pupil moves, to minimize the
+ *      number of pixels which must be copied out to the screen.
+ */
+
+static void
+join_rects(XRectangle * r1, XRectangle * r2, XRectangle * ret)
+{
+       XRectangle  tmp;
+       int         n1, n2;
+
+       /* find min x and min y */
+       tmp.x = (r1->x <= r2->x) ? r1->x : r2->x;
+       tmp.y = (r1->y <= r2->y) ? r1->y : r2->y;
+       /* find max x, plus one (just past the right side) */
+       n1 = r1->x + r1->width;
+       n2 = r2->x + r2->width;
+       /* compute width, relative to min x (left side) */
+       tmp.width = ((n1 > n2) ? n1 : n2) - tmp.x;
+       /* same for y */
+       n1 = r1->y + r1->height;
+       n2 = r2->y + r2->height;
+       tmp.height = ((n1 > n2) ? n1 : n2) - tmp.y;
+       *ret = tmp;             /* copy out result rectangle */
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Do the math to figure out where the pupil should be drawn.
+ *      This code lifted intact from the xeyes widget.
+ */
+
+#if defined( SVR4 ) || defined( SYSV ) && defined( SYSV386 )
+extern double hypot(double, double);
+
+#endif
+
+static  void 
+computePupil(int num, TPoint mouse, TPoint *ret)
+{
+       double      cx, cy;
+       double      dist;
+       double      angle;
+       double      x, y;
+       double      h;
+       double      dx, dy;
+       double      cosa, sina;
+
+       dx = mouse.x - EYE_X(num);
+       dy = mouse.y - EYE_Y(num);
+       if (dx == 0 && dy == 0) {
+               cx = EYE_X(num);
+               cy = EYE_Y(num);
+       } else {
+               /* Avoid atan2: DOMAIN error message */
+               if (dx == 0.0 && dy == 0.0)
+                       angle = 0.0;
+               else
+                       angle = atan2((double) dy, (double) dx);
+               cosa = cos(angle);
+               sina = sin(angle);
+               h = hypot(EYE_HHEIGHT * cosa, EYE_HWIDTH * sina);
+               x = (EYE_HWIDTH * EYE_HHEIGHT) * cosa / h;
+               y = (EYE_HWIDTH * EYE_HHEIGHT) * sina / h;
+               dist = BALL_DIST * hypot(x, y);
+               if (dist > hypot((double) dx, (double) dy)) {
+                       cx = dx + EYE_X(num);
+                       cy = dy + EYE_Y(num);
+               } else {
+                       cx = dist * cosa + EYE_X(num);
+                       cy = dist * sina + EYE_Y(num);
+               }
+       }
+       (*ret).x = cx;
+       (*ret).y = cy;
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Create the eye image, using the data in the structure pointed
+ *      to by "e", in the Drawable "d".  The "full" flag indicates
+ *      whether to create the full eye image, or to just paint the
+ *      pupil in a new position.
+ */
+
+static void
+make_eye(ModeInfo * mi, Drawable d, Eyes * e, int n, int full)
+{
+       EyeScrInfo *ep = &eye_info[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = ep->eyeGC;
+       XRectangle *bbox = &e->bbox;
+       XRectangle  tmp1, tmp2;
+
+       if (full) {
+               /* draw the outer (eyelid) oval */
+               XSetForeground(display, gc, e->eyelid_pixel);
+               TFillArc(display, d, gc, &e->transform,
+                        EYE_X(n) - EYE_HWIDTH - EYE_THICK,
+                        EYE_Y(n) - EYE_HHEIGHT - EYE_THICK,
+                        EYE_WIDTH + EYE_THICK * 2.0,
+                        EYE_HEIGHT + EYE_THICK * 2.0,
+                        90 * 64, 360 * 64, &tmp1);
+
+               /* draw the inner (eyeball) oval */
+               XSetForeground(display, gc, e->eyeball_pixel);
+               TFillArc(display, d, gc, &e->transform,
+                        EYE_X(n) - EYE_HWIDTH, EYE_Y(n) - EYE_HHEIGHT,
+                        EYE_WIDTH, EYE_HEIGHT, 90 * 64, 360 * 64, &tmp2);
+
+               join_rects(&tmp1, &tmp2, &tmp1);
+
+               /* draw the pupil on top of the eyeball oval */
+               XSetForeground(display, gc, e->pupil_pixel);
+               TFillArc(display, d, gc, &e->transform,
+                        e->pupil[n].x - BALL_WIDTH / 2.0,
+                        e->pupil[n].y - BALL_HEIGHT / 2.0,
+                        BALL_WIDTH, BALL_HEIGHT, 90 * 64, 360 * 64, &tmp2);
+
+               join_rects(&tmp1, &tmp2, bbox);
+       } else {
+               /* undraw the pupil */
+               XSetForeground(display, gc, e->eyeball_pixel);
+               TFillArc(display, d, gc, &e->transform,
+                        e->last_pupil[n].x - BALL_WIDTH / 2.0,
+                        e->last_pupil[n].y - BALL_HEIGHT / 2.0,
+                        BALL_WIDTH, BALL_HEIGHT, 90 * 64, 360 * 64, &tmp1);
+
+               /* draw the pupil on top of the eyeball oval */
+               XSetForeground(display, gc, e->pupil_pixel);
+               TFillArc(display, d, gc, &e->transform,
+                        e->pupil[n].x - BALL_WIDTH / 2.0,
+                        e->pupil[n].y - BALL_HEIGHT / 2.0,
+                        BALL_WIDTH, BALL_HEIGHT, 90 * 64, 360 * 64, &tmp2);
+
+               join_rects(&tmp1, &tmp2, bbox);
+       }
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Check to see if the flyer touches this pair of eyes.
+ */
+
+static      Bool
+fly_touches(Fly * f, Eyes * e, int old)
+{
+       int         x = (old) ? f->oldx : f->x;
+       int         y = (old) ? f->oldy : f->y;
+
+       if ((x + f->width) <= e->x)
+               return (False);
+       if (x >= (e->x + e->width))
+               return (False);
+       if ((y + f->height) <= e->y)
+               return (False);
+       if (y >= (e->y + e->height))
+               return (False);
+       return (True);
+}
+
+static      Bool
+fly_touches_eye(Fly * f, Eyes * e)
+{
+       if (fly_touches(f, e, True) || fly_touches(f, e, False)) {
+               return (True);
+       }
+       return (False);
+}
+
+/*-
+ *    Check to see if two pairs of eyes overlap.
+ */
+
+static      Bool
+eyes_overlap(Eyes * e1, Eyes * e2)
+{
+       if ((e1->x + e1->width) < e2->x)
+               return (False);
+       if (e1->x >= (e2->x + e2->width))
+               return (False);
+       if ((e1->y + e1->height) < e2->y)
+               return (False);
+       if (e1->y >= (e2->y + e2->height))
+               return (False);
+       return (True);
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Initialize the flyer.  Called when the window changes, and
+ *      whenever she bounces off the screen.
+ *      In the first version, the eyes followed a "fly", which was
+ *      just a flickering spot that moved at random.  That didn't
+ *      work so well.  It was replaced with a bouncing gelb, but the
+ *      name "fly" has yet to be purged.
+ */
+
+static void
+init_fly(ModeInfo * mi, Fly * f)
+{
+       EyeScrInfo *ep = &eye_info[MI_SCREEN(mi)];
+       int         win_width = MI_WIDTH(mi);
+       int         win_height = MI_HEIGHT(mi);
+
+       (void) memset((char *) f, 0, sizeof (Fly));     /* clear everything to zero */
+
+       f->side = FLY_SIDE_LEFT;
+
+       if (MI_IS_ICONIC(mi)) {
+               /* image is just a dot when iconic */
+               f->width = f->height = FLY_ICON_SIZE;
+               f->vx = NRAND(4) + 1;   /* slower when iconic */
+       } else {
+               f->width = ep->flywidth;
+               f->height = ep->flyheight;
+               f->vx = NRAND(15) + 1;  /* random horiz velocity */
+       }
+
+       f->y = NRAND(win_height);
+       if (f->y > (win_height / 2)) {
+               f->side = FLY_SIDE_RIGHT;       /* change to right side */
+               f->y -= win_height / 2;         /* start in top half */
+               f->x = win_width - f->width;    /* move to right of screen */
+               f->vx = -(f->vx);       /* flip direction */
+       }
+       f->oldx = -(f->width);  /* prevent undraw 1st time */
+
+       if (MI_NPIXELS(mi) <= 2) {
+               f->pixel = MI_WHITE_PIXEL(mi);  /* always white when mono */
+       } else {
+               f->pixel = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       }
+}
+
+/*-
+ *    Unpaint the flyer by painting the image in black.
+ */
+
+static void
+unpaint_fly(ModeInfo * mi, Fly * f)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+
+       if (MI_IS_ICONIC(mi)) {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillArc(display, window, gc, f->oldx, f->oldy,
+                        f->width, f->height, 90 * 64, 360 * 64);
+       } else {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+#ifdef FLASH
+               XFillRectangle(display, window, gc,
+                              f->oldx, f->oldy, f->width, f->height);
+#else
+               ERASE_IMAGE(display, window, gc, f->x, f->y,
+                           f->oldx, f->oldy, f->width, f->height);
+#endif
+       }
+}
+
+/*-
+ *    Paint the bouncing grelb on the screen.  If not in iconic
+ *      mode, unpaint the previous image.  When iconic, the fly
+ *      doesn't need to be undrawn, because it will always be on top
+ *      of the eyes, which are repainted before the fly is painted.
+ */
+
+static void
+paint_fly(ModeInfo * mi, Fly * f)
+{
+       EyeScrInfo *ep = &eye_info[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         x = f->x, y = f->y;
+
+       if (MI_IS_ICONIC(mi)) {
+               /* don't need to unpaint when iconic
+                * ep->flyGC has stipple set, don't use when iconic
+                */
+               XSetForeground(display, MI_GC(mi), f->pixel);
+               XFillArc(display, window, MI_GC(mi), x, y,
+                        f->width, f->height, 90 * 64, 360 * 64);
+       } else {
+               unpaint_fly(mi, f);
+               XSetForeground(display, ep->flyGC, f->pixel);
+               XSetTSOrigin(display, ep->flyGC, x, y);
+#ifdef FLASH
+               XSetFillStyle(display, ep->flyGC, FillStippled);
+#else
+               XSetFillStyle(display, ep->flyGC, FillOpaqueStippled);
+#endif
+               XFillRectangle(display, window, ep->flyGC,
+                              x, y, f->width, f->height);
+               XFlush(display);
+       }
+}
+
+/*-
+ *    Compute the new position of the fly.  The bouncy-boinginess
+ *      algorithm is borrowed from the "bounce" (soccer ball) mode.
+ */
+
+static void
+move_fly(ModeInfo * mi, Fly * f)
+{
+       int         win_width = MI_WIDTH(mi);
+       int         win_height = MI_HEIGHT(mi);
+       int         left = (f->side == FLY_SIDE_LEFT) ? -(f->width) : 0;
+       int         right = (f->side == FLY_SIDE_RIGHT) ? win_width :
+       win_width - f->width;
+       Bool        track_p = trackmouse;
+       int         cx, cy;
+
+
+       f->oldx = f->x;         /* remember position before moving, */
+       f->oldy = f->y;         /* for unpainting previous image */
+
+       if (track_p) {
+               Window      r, c;
+               int         rx, ry;
+               unsigned int m;
+
+               (void) XQueryPointer(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                    &r, &c, &rx, &ry, &cx, &cy, &m);
+               if (cx <= 0 || cy <= 0 ||
+                   cx >= MI_WIDTH(mi) - f->width - 1 ||
+                   cy >= MI_HEIGHT(mi) - f->width - 1)
+                       track_p = False;
+       }
+       if (track_p) {
+               f->x = cx;
+               f->y = cy;
+               return;
+       }
+       f->x += f->vx;          /* apply x velocity */
+
+       if (f->x > right) {
+               if (f->side == FLY_SIDE_RIGHT) {
+                       unpaint_fly(mi, f);     /* went off the edge, reset */
+                       init_fly(mi, f);
+               } else {
+                       /* Bounce off the right edge */
+                       f->x = 2 * (win_width - f->width) - f->x;
+                       f->vx = -f->vx + f->vx / FRICTION;
+               }
+       } else if (f->x < left) {
+               if (f->side == FLY_SIDE_LEFT) {
+                       unpaint_fly(mi, f);     /* went off the edge, reset */
+                       init_fly(mi, f);
+               } else {
+                       /* Bounce off the left edge */
+                       f->x = -f->x;
+                       f->vx = -f->vx + f->vx / FRICTION;
+               }
+       }
+       f->vy++;                /* gravity, accelerate in y direction */
+       f->y += f->vy;          /* apply y velocity */
+
+       if (f->y >= (win_height - f->height)) {
+               /* Bounce off the bottom edge */
+               f->y = (win_height - f->height);
+               f->vy = -f->vy + f->vy / FRICTION;
+               /* every once in a while, go apeshit to clean "high lurkers" */
+               if (NRAND(50) == 0) {
+                       f->vy *= 4;
+               }
+       } else if (f->y < 0) {
+               /* Bounce off the top edge */
+               f->y = -f->y;
+               f->vy = -f->vy + f->vy / FRICTION;
+       }
+       /* if he settles to the bottom, move him off quick */
+       if (abs(f->vy) < 2) {
+               if ((f->zero_y++) > 10) {
+                       f->vx += (f->side == FLY_SIDE_LEFT) ? -1 : 1;
+               }
+       } else {
+               f->zero_y = 0;  /* still bouncing */
+       }
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Initialize one pair of eyes
+ */
+
+static void
+create_eyes(ModeInfo * mi, Eyes * e, Eyes * eyes, int num_eyes)
+{
+       EyeScrInfo *ep = &eye_info[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         win_width = MI_WIDTH(mi);
+       int         win_height = MI_HEIGHT(mi);
+       unsigned long black_pixel = MI_BLACK_PIXEL(mi);
+       unsigned long white_pixel = MI_WHITE_PIXEL(mi);
+       Bool        iconic = MI_IS_ICONIC(mi);
+       Pixmap      pix = e->pixmap;    /* preserve pixmap handle */
+       int         w = e->width;       /* remember last w/h */
+       int         h = e->height;
+       int         npixels = MI_NPIXELS(mi);   /* num colors in colormap */
+       int         cycs = MI_CYCLES(mi);       /* affects eye lifetime */
+       int         maxw = win_width / 2;       /* widest eyes can be */
+       int         color, lid_color;
+       int         i;
+
+       (void) memset((char *) e, 0, sizeof (Eyes));    /* wipe everything */
+       e->pixmap = pix;        /* remember Pixmap handle */
+
+       /* sanity check the cycles value */
+       if (cycs < 1)
+               cycs = 1;
+       if (cycs > MAX_CYCLES)
+               cycs = MAX_CYCLES;
+       e->time_to_die = (unsigned long) LIFE_MIN + NRAND(LIFE_RANGE);
+       e->time_to_die *= (unsigned long) cycs;         /* multiply life by cycles */
+       e->time_to_die += ep->time;
+
+       e->pupil_pixel = black_pixel;   /* pupil is always black */
+
+       if (MI_NPIXELS(mi) <= 2) {
+               /* TODO: stipple the eyelid? */
+               e->eyelid_pixel = black_pixel;
+               e->eyeball_pixel = white_pixel;
+       } else {
+               lid_color = color = NRAND(npixels);
+               e->eyelid_pixel = MI_PIXEL(mi, lid_color);
+
+               while ((color = NRAND(npixels + 5)) == lid_color) {
+                       /* empty */
+               }
+               if (color >= npixels) {
+                       /* give white a little better chance */
+                       e->eyeball_pixel = white_pixel;
+               } else {
+                       e->eyeball_pixel = MI_PIXEL(mi, color);
+               }
+       }
+
+       if (iconic) {
+               /* only one pair of eyes, fills entire window */
+               e->width = win_width;
+               e->height = win_height;
+       } else {
+               if (maxw - MIN_EYE_SIZE > MIN_EYE_SIZE)
+                       e->width = NRAND(maxw - MIN_EYE_SIZE) + MIN_EYE_SIZE;
+               else
+                       e->width = NRAND(MIN_EYE_SIZE) + MIN_EYE_SIZE;
+               e->x = (win_width - e->width > 0) ? NRAND(win_width - e->width) : 0;
+               e->height = NRAND(e->width * 3 / 4) + (e->width / 4);
+               e->y = (win_height - e->height > 0) ? NRAND(win_height - e->height) : 0;
+
+               /* check for overlap with other eyes */
+               for (i = 0; i < num_eyes; i++) {
+                       if (&eyes[i] == e) {    /* that's me */
+                               continue;
+                       }
+                       if (eyes_overlap(e, &eyes[i])) {
+                               /* collision, force retry on next cycle */
+                               e->time_to_die = 0;
+                               break;
+                       }
+               }
+       }
+
+       /* If the Pixmap is smaller than the new size, make it bigger */
+       if ((e->width > w) || (e->height > h)) {
+               if (e->pixmap != None) {
+                       XFreePixmap(display, e->pixmap);
+               }
+               e->pixmap = XCreatePixmap(display, window,
+                                         e->width, e->height, MI_DEPTH(mi));
+               if (e->pixmap == None) {
+                       e->width = e->height = 0;
+                       return;
+               }
+       }
+       /* Set the transformation matrix for this set of eyes
+        * If iconic, make the eyes image one pixel shorter and
+        * skinnier, they seem to fit in the icon box better that way.
+        */
+       SetTransform(&e->transform, 0, (iconic) ? e->width - 1 : e->width,
+                    (iconic) ? e->height - 1 : e->height, 0,
+                    W_MIN_X, W_MAX_X, W_MIN_Y, W_MAX_Y);
+
+       /* clear the offscreen pixmap to background color */
+       XSetForeground(display, ep->eyeGC, black_pixel);
+       XFillRectangle(display, e->pixmap, ep->eyeGC, 0, 0, e->width, e->height);
+
+       /* make the full eye images in the offscreen Pixmap */
+       make_eye(mi, e->pixmap, e, 0, True);
+       make_eye(mi, e->pixmap, e, 1, True);
+}
+
+
+/*-
+ *    Paint an eye pair onto the screen.
+ *      This is normally only the change rectangles for each pupil,
+ *      unless in iconic mode, which always repaints the full image.
+ */
+
+static void
+paint_eyes(ModeInfo * mi, Eyes * e, Fly * f, Eyes * eyes, int num_eyes)
+{
+       EyeScrInfo *ep = &eye_info[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = ep->eyeGC;
+       Bool        iconic = MI_IS_ICONIC(mi);
+       int         focusx = (f->x + (f->width / 2)) - e->x;
+       int         focusy = (f->y + (f->height / 2)) - e->y;
+       Pixmap      pix = e->pixmap;
+       TPoint      point;
+       int         i;
+
+       if (pix == None) {
+               e->time_to_die = 0;     /* "should not happen" */
+       }
+       if (ep->time >= e->time_to_die) {
+               /* Sorry Bud, your time is up */
+               if (e->painted) {
+                       /* only unpaint it if previously painted */
+                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                       XFillRectangle(display, window, gc, e->x, e->y, e->width, e->height);
+               }
+               /* randomly place the eyes elsewhere */
+               create_eyes(mi, e, eyes, num_eyes);
+               pix = e->pixmap;        /* pixmap may have changed */
+       }
+       /* If the bouncer would intersect this pair of eyes, force the
+        * eyes to move.  This simplifies the code, because we do not
+        * have to deal with drawing the bouncer on top of the eyes.
+        * When trying to do so, there was too much annoying flashing
+        * and ghost images from the undraw.  I decided to observe the
+        * KISS principle and keep it simple.  I think the effect is
+        * better also.
+        * We must draw the flyer on the eyes when iconic, but that is
+        * easy because the eyes repaint the whole box each time.
+        */
+       if ((!iconic) && (fly_touches_eye(f, e))) {
+               e->time_to_die = 0;
+       }
+       if (e->time_to_die == 0) {
+               return;         /* collides with something */
+       }
+       /* set the point to look at and compute the pupil position  */
+       point.x = Tx(focusx, focusy, &e->transform);
+       point.y = Ty(focusx, focusy, &e->transform);
+       computePupil(0, point, &(e->pupil[0]));
+       computePupil(1, point, &(e->pupil[1]));
+
+       if (e->painted) {
+               /* if still looking at the same point, do nothing further */
+               if (TPointEqual(e->pupil[0], e->last_pupil[0]) &&
+                   TPointEqual(e->pupil[1], e->last_pupil[1])) {
+                       return;
+               }
+       }
+       for (i = 0; i < 2; i++) {
+               /* update the eye, calculates the changed rectangle */
+               make_eye(mi, pix, e, i, False);
+
+               /* Only blit the change if the full image has been painted */
+               if (e->painted) {
+                       /* copy the changed rectangle out to the screen */
+                       XCopyArea(display, pix, window, gc,
+                                 e->bbox.x, e->bbox.y,
+                                 (int) e->bbox.width, (int) e->bbox.height,
+                                 e->x + e->bbox.x, e->y + e->bbox.y);
+               }
+               /* remember where we're looking, for the next time around */
+               e->last_pupil[i] = e->pupil[i];
+       }
+
+       /* always do full paint when iconic, eliminates need to track fly */
+       if (iconic || (!e->painted)) {
+               XCopyArea(display, pix, window, gc, 0, 0,
+                         e->width, e->height, e->x, e->y);
+       }
+       /* when iconic, pretend to never paint, causes full paint each time */
+       if (!iconic) {
+               e->painted++;   /* note that a paint has been done */
+       }
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Initialization that only needs to be done once.  If the
+ *      release hook is called, this stuff may be freed and this
+ *      function will have to allocate it again next time the
+ *      init hook is called.
+ */
+
+static void
+one_time_init(ModeInfo * mi)
+{
+       if (stuff_alloced) {
+               return;         /* only once, dude */
+       }
+       if (eye_info == NULL) {
+               if ((eye_info = (EyeScrInfo *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (EyeScrInfo))) == NULL)
+                       return;
+       }
+       stuff_alloced = True;
+}
+
+static void
+free_eyes(Display * display, EyeScrInfo * ep)
+{
+       int         en;
+
+       if (ep->eyes) {
+               for (en = 0; en < ep->num_eyes; en++)
+                       if (ep->eyes[en].pixmap != None)
+                               XFreePixmap(display, ep->eyes[en].pixmap);
+               (void) free((void *) ep->eyes);
+               ep->eyes = NULL;
+       }
+}
+
+/*-
+ *    Initialize them eyes.  Called each time the window changes.
+ */
+
+void
+init_eyes(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       EyeScrInfo *ep;
+       int         i;
+
+       one_time_init(mi);
+
+       if (!stuff_alloced) {
+               /* if an alloc failed in one_time_init(), quit */
+               return;
+       }
+       ep = &eye_info[MI_SCREEN(mi)];
+
+       if (ep->flypix == None) {
+               getPixmap(mi, window, FLY_WIDTH, FLY_HEIGHT, FLY_BITS,
+                         &(ep->flywidth), &(ep->flyheight), &(ep->flypix),
+                         &(ep->graphics_format));
+               if (ep->flypix == None) {
+                       return;
+               }
+       }
+       if (ep->flyGC == None) {
+               XGCValues   gcv;
+
+               gcv.foreground = MI_BLACK_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               if ((ep->flyGC = XCreateGC(display, window,
+                                GCForeground | GCBackground, &gcv)) == None)
+                       return;
+               XSetStipple(display, ep->flyGC, ep->flypix);
+               XSetFillStyle(display, ep->flyGC, FillStippled);
+       }
+       if (ep->eyeGC == None) {
+               if ((ep->eyeGC = XCreateGC(display, window,
+                          (unsigned long) 0, (XGCValues *) NULL)) == None) {
+                       return;
+               }
+       }
+       ep->time = 0;
+       /* don't want any exposure events from XCopyArea */
+       XSetGraphicsExposures(display, ep->eyeGC, False);
+
+       free_eyes(display, ep);
+       if (MI_IS_ICONIC(mi))
+               ep->num_eyes = 1;
+       else {
+               ep->num_eyes = MI_COUNT(mi);
+               /* MAX_EYES is used or one may quickly run out of memory */
+               if (ep->num_eyes > MAX_EYES)
+                       ep->num_eyes = MAX_EYES;
+               if (ep->num_eyes < 0) {
+                       if (ep->num_eyes < -MAX_EYES)
+                               ep->num_eyes = NRAND(MAX_EYES) + 1;
+                       else
+                               ep->num_eyes = NRAND(-ep->num_eyes) + 1;        /* Add 1 so its not too boring */
+               }
+       }
+       if (!ep->eyes)
+               ep->eyes = (Eyes *) calloc(ep->num_eyes, sizeof (Eyes));
+
+       for (i = 0; i < ep->num_eyes; i++) {    /* place each eye pair */
+               /* don't assume None == 0 */
+               ep->eyes[i].pixmap = None;
+               create_eyes(mi, &(ep->eyes[i]), ep->eyes, ep->num_eyes);
+       }
+
+       init_fly(mi, &(ep->fly));       /* init the bouncer */
+
+       if (trackmouse && !ep->cursor) {        /* Create an invisible cursor */
+               Pixmap      bit;
+               XColor      black;
+
+               black.red = 0;
+               black.green = 0;
+               black.blue = 0;
+               black.flags = DoRed | DoGreen | DoBlue;
+               bit = XCreatePixmapFromBitmapData(display, window, "\000", 1, 1,
+                                                 MI_BLACK_PIXEL(mi),
+                                                 MI_BLACK_PIXEL(mi), 1);
+               ep->cursor = XCreatePixmapCursor(display, bit, bit, &black, &black,
+                                                0, 0);
+               XFreePixmap(display, bit);
+       }
+       XDefineCursor(display, window, ep->cursor);
+
+       MI_CLEARWINDOW(mi);
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Called by the mainline code periodically to update the display.
+ */
+
+void
+draw_eyes(ModeInfo * mi)
+{
+       EyeScrInfo *ep = &eye_info[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!stuff_alloced) {
+               /* if startup init didn't finish, do nothing */
+               return;
+       }
+       move_fly(mi, &(ep->fly));
+       ep->time++;
+       for (i = 0; i < ep->num_eyes; i++) {
+               paint_eyes(mi, &(ep->eyes[i]), &(ep->fly), ep->eyes, ep->num_eyes);
+       }
+
+       paint_fly(mi, &(ep->fly));
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    The display is being taken away from us.  Free up malloc'ed 
+ *      memory and X resources that we've alloc'ed.  Only called
+ *      once, we must zap everything for every screen.
+ */
+
+void
+release_eyes(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+
+       if (eye_info != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       EyeScrInfo *ep = &eye_info[screen];
+
+                       if (ep->flyGC != None)
+                               XFreeGC(display, ep->flyGC);
+                       if (ep->eyeGC != None)
+                               XFreeGC(display, ep->eyeGC);
+                       if (ep->flypix != None)
+                               XFreePixmap(display, ep->flypix);
+                       free_eyes(display, ep);
+                       if (ep->cursor)
+                               XFreeCursor(display, ep->cursor);
+               }
+               (void) free((void *) eye_info);
+       }
+       eye_info = NULL;
+       stuff_alloced = False;
+}
+
+/* ---------------------------------------------------------------------- */
+
+/*-
+ *    Called when the mainline xlock code notices possible window
+ *      damage.  This hook should take steps to repaint the entire
+ *      window (no specific damage area information is provided).
+ */
+
+void
+refresh_eyes(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       int         i;
+
+       if (!stuff_alloced) {
+               return;         /* paranoia */
+       }
+       MI_CLEARWINDOW(mi);
+
+       /* simply flag all the eyes as not painted, will repaint next time */
+       for (i = 0; i < eye_info[screen].num_eyes; i++) {
+               eye_info[screen].eyes[i].painted = False;
+       }
+}
+
+#endif /* MODE_eyes */
diff --git a/xlockmore-4.14/modes/fadeplot.c b/xlockmore-4.14/modes/fadeplot.c
new file mode 100644 (file)
index 0000000..64f7f46
--- /dev/null
@@ -0,0 +1,208 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* fadeplot --- a fading plot of sine squared */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)fadeplot.c  4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Some easy plotting stuff, by Bas van Gaalen, Holland, PD
+ *
+ * Copyright (c) 1996 by Charles Vidal
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Fadeplot"
+#define HACK_INIT init_fadeplot
+#define HACK_DRAW draw_fadeplot
+#define fadeplot_opts xlockmore_opts
+#define DEFAULTS "*delay: 30000 \n" \
+ "*count: 10 \n" \
+ "*cycles: 1500 \n" \
+ "*ncolors: 64 \n"
+#define BRIGHT_COLORS
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_fadeplot
+
+ModeSpecOpt fadeplot_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   fadeplot_description =
+{"fadeplot", "init_fadeplot", "draw_fadeplot", "release_fadeplot",
+ "refresh_fadeplot", "init_fadeplot", NULL, &fadeplot_opts,
+ 30000, 10, 1500, 1, 64, 0.6, "",
+ "Shows a fading plot of sine squared", 0, NULL};
+
+#endif
+
+#define MINSTEPS 1
+
+typedef struct {
+       XPoint      speed, step, factor, st;
+       int         temps, maxpts, nbstep;
+       int         min;
+       int         width, height;
+       int         pix;
+       int         angles;
+       int        *stab;
+       XPoint     *pts;
+} fadeplotstruct;
+
+static fadeplotstruct *fadeplots = NULL;
+
+static void
+initSintab(ModeInfo * mi)
+{
+       fadeplotstruct *fp = &fadeplots[MI_SCREEN(mi)];
+       int         i;
+       float       x;
+
+       fp->angles = NRAND(950) + 250;
+       fp->stab = (int *) malloc(fp->angles * sizeof (int));
+
+       for (i = 0; i < fp->angles; i++) {
+               x = SINF(2.0 * M_PI * i / fp->angles);
+               fp->stab[i] = (int) (x * ABS(x) * fp->min) + fp->min;
+       }
+}
+
+void
+init_fadeplot(ModeInfo * mi)
+{
+       fadeplotstruct *fp;
+
+       if (fadeplots == NULL) {
+               if ((fadeplots = (fadeplotstruct *) calloc(MI_NUM_SCREENS(mi),
+                                          sizeof (fadeplotstruct))) == NULL)
+                       return;
+       }
+       fp = &fadeplots[MI_SCREEN(mi)];
+
+       fp->width = MI_WIDTH(mi);
+       fp->height = MI_HEIGHT(mi);
+       fp->min = MAX(MIN(fp->width, fp->height) / 2, 1);
+
+       fp->speed.x = 8;
+       fp->speed.y = 10;
+       fp->step.x = 1;
+       fp->step.y = 1;
+       fp->temps = 0;
+       fp->factor.x = MAX(fp->width / (2 * fp->min), 1);
+       fp->factor.y = MAX(fp->height / (2 * fp->min), 1);
+
+       fp->nbstep = MI_COUNT(mi);
+       if (fp->nbstep < -MINSTEPS) {
+               fp->nbstep = NRAND(-fp->nbstep - MINSTEPS + 1) + MINSTEPS;
+       } else if (fp->nbstep < MINSTEPS)
+               fp->nbstep = MINSTEPS;
+
+       fp->maxpts = MI_CYCLES(mi);
+       if (fp->maxpts < 1)
+               fp->maxpts = 1;
+
+       if (fp->pts == NULL)
+               fp->pts = (XPoint *) calloc(fp->maxpts, sizeof (XPoint));
+       if (MI_NPIXELS(mi) > 2)
+               fp->pix = NRAND(MI_NPIXELS(mi));
+
+       if (fp->stab != NULL)
+               (void) free((void *) fp->stab);
+       initSintab(mi);
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_fadeplot(ModeInfo * mi)
+{
+       fadeplotstruct *fp = &fadeplots[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       int         i, j, temp;
+
+       MI_IS_DRAWN(mi) = True;
+
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       XDrawPoints(display, window, gc, fp->pts, fp->maxpts, CoordModeOrigin);
+
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, fp->pix));
+               if (++fp->pix >= MI_NPIXELS(mi))
+                       fp->pix = 0;
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       temp = 0;
+       for (j = 0; j < fp->nbstep; j++) {
+               for (i = 0; i < fp->maxpts / fp->nbstep; i++) {
+                       fp->pts[temp].x =
+                               fp->stab[(fp->st.x + fp->speed.x * j + i * fp->step.x) % fp->angles] *
+                               fp->factor.x + fp->width / 2 - fp->min;
+                       fp->pts[temp].y =
+                               fp->stab[(fp->st.y + fp->speed.y * j + i * fp->step.y) % fp->angles] *
+                               fp->factor.y + fp->height / 2 - fp->min;
+                       temp++;
+               }
+       }
+       XDrawPoints(display, window, gc, fp->pts, temp, CoordModeOrigin);
+       XFlush(display);
+       fp->st.x = (fp->st.x + fp->speed.x) % fp->angles;
+       fp->st.y = (fp->st.y + fp->speed.y) % fp->angles;
+       fp->temps++;
+       if ((fp->temps % (fp->angles / 2)) == 0) {
+               fp->temps = fp->temps % fp->angles * 5;
+               if ((fp->temps % (fp->angles)) == 0)
+                       fp->speed.y = (fp->speed.y++) % 30 + 1;
+               if ((fp->temps % (fp->angles * 2)) == 0)
+                       fp->speed.x = (fp->speed.x) % 20;
+               if ((fp->temps % (fp->angles * 3)) == 0)
+                       fp->step.y = (fp->step.y++) % 2 + 1;
+
+               MI_CLEARWINDOW(mi);
+       }
+}
+void
+refresh_fadeplot(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+void
+release_fadeplot(ModeInfo * mi)
+{
+       if (fadeplots != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       fadeplotstruct *fp = &fadeplots[screen];
+
+                       (void) free((void *) fp->pts);
+                       (void) free((void *) fp->stab);
+               }
+               (void) free((void *) fadeplots);
+               fadeplots = NULL;
+       }
+}
+
+#endif /* MODE_fadeplot */
diff --git a/xlockmore-4.14/modes/flag.c b/xlockmore-4.14/modes/flag.c
new file mode 100644 (file)
index 0000000..86a8b1c
--- /dev/null
@@ -0,0 +1,595 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* flag --- a waving flag image */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)flag.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by Charles Vidal <vidalc@club-internet.fr>
+ *         http://www.chez.com/vidalc
+ *
+ * Thanks to Bas van Gaalen, Holland, PD, for his Pascal source
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History: 
+ * 24-Oct-97: xpm and ras capability added.
+ * 13-May-97: jwz@jwz.org: turned into a standalone program.
+ *            Made it able to animate arbitrary (runtime) text or bitmaps
+ * 15-May-96: written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Flag"
+#define HACK_INIT init_flag
+#define HACK_DRAW draw_flag
+#define flag_opts xlockmore_opts
+#define DEFAULTS "*delay: 50000 \n" \
+ "*cycles: 1000 \n" \
+ "*size: -7 \n" \
+ "*ncolors: 200 \n" \
+ "*bitmap: \n" \
+ "*font: \n" \
+ "*text: \n" \
+ "*fullrandom: True \n"
+#define BRIGHT_COLORS
+#define UNIFORM_COLORS
+#define DEF_FONT "-*-helvetica-bold-r-*-240-*"
+#define DEF_TEXT ""
+#include "xlockmore.h"         /* in xscreensaver distribution */
+
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+
+/* This makes me laugh :) */
+#ifdef JWZ
+/*-
+ * 22-Jan-98: jwz: made the flag wigglier; added xpm support.
+ *            (I tried to do this by re-porting from xlockmore, but the
+ *            current xlockmore version is completely inscrutable.)
+ */
+
+#ifdef HAVE_XPM
+#include <X11/xpm.h>
+#ifndef PIXEL_ALREADY_TYPEDEFED
+#define PIXEL_ALREADY_TYPEDEFED        /* Sigh, Xmu/Drawing.h needs this... */
+#endif
+#endif
+
+#ifdef HAVE_XMU
+#ifndef VMS
+#include <X11/Xmu/Drawing.h>
+#else /* VMS */
+#include <Xmu/Drawing.h>
+#endif /* VMS */
+#endif /* HAVE_XMU */
+
+#include "images/bob.xbm"
+#include <string.h>
+#include <X11/Xutil.h>
+#else
+#include "iostuff.h"
+#endif
+
+#ifdef MODE_flag
+
+#define DEF_INVERT  "False"
+
+static Bool invert;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-invert", ".flag.invert", XrmoptionNoArg, (caddr_t) "on"},
+       {"+invert", ".flag.invert", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & invert, "invert", "Invert", DEF_INVERT, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+invert", "turn on/off inverting of flag"}
+};
+
+ModeSpecOpt flag_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   flag_description =
+{"flag", "init_flag", "draw_flag", "release_flag",
+ "refresh_flag", "init_flag", NULL, &flag_opts,
+ 50000, 1, 1000, -7, 64, 1.0, "",
+ "Shows a waving flag image", 0, NULL};
+
+#endif
+
+/* aliases for vars defined in the bitmap file */
+#define FLAG_WIDTH   image_width
+#define FLAG_HEIGHT    image_height
+#define FLAG_BITS    image_bits
+
+#include "flag.xbm"
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+#define FLAG_NAME  image_name
+#include "flag.xpm"
+#define DEFAULT_XPM 0
+#endif
+
+#if !defined( VMS ) || ( __VMS_VER >= 70000000 )
+#include <sys/utsname.h>
+#else
+#if USE_XVMSUTILS
+#if 0
+#include "../xvmsutils/utsname.h"
+#else
+#include <X11/utsname.h>
+#endif
+#endif /* USE_XVMSUTILS */
+#endif
+
+#define MINSIZE 1
+#define MAXSCALE 8
+#define MINSCALE 2
+#define MAXINITSIZE 6
+#define MININITSIZE 2
+#define MINAMP 5
+#define MAXAMP 20
+#define MAXW(fp) (MAXSCALE * (fp)->image->width + 2 * MAXAMP + (fp)->pointsize + 2 * (fp)->sofs)
+#define MAXH(fp) (MAXSCALE * (fp)->image->height+ 2 * MAXAMP + (fp)->pointsize + 2 * (fp)->sofs)
+#define MINW(fp) (MINSCALE * (fp)->image->width + 2 * MINAMP + (fp)->pointsize)
+#define MINH(fp) (MINSCALE * (fp)->image->height+ 2 * MINAMP + (fp)->pointsize)
+#define ANGLES         360
+#define IMAGE_FLAG 0
+#define MESSAGE_FLAG 1
+
+typedef struct {
+       int         samp;
+       int         sofs;
+       int         sidx;
+       int         x_flag, y_flag;
+       int         timer;
+       int         stab[ANGLES];
+       Pixmap      cache;
+       int         width, height;
+       int         pointsize;
+       float       size;
+       float       inctaille;
+       int         startcolor;
+       int         choice;
+       XImage     *image;
+       XImage     *logo;
+       Colormap    cmap;
+       unsigned long black;
+       int         graphics_format;
+       GC          backGC;
+} flagstruct;
+
+static XFontStruct *messagefont = None;
+
+static flagstruct *flags = NULL;
+
+extern XFontStruct *getFont(Display * display);
+
+static int
+random_num(int n)
+{
+       return ((int) (((float) LRAND() / MAXRAND) * (n + 1.0)));
+}
+
+static void
+initSintab(ModeInfo * mi)
+{
+       flagstruct *fp = &flags[MI_SCREEN(mi)];
+       int         i;
+
+  /*-
+   * change the periodicity of the sin formula : the maximum of the
+   * periocity seem to be 16 ( 2^4 ), after the drawing isn't good looking
+   */
+       int         periodicity = random_num(4);
+       int         puissance = 1;
+
+       /* for (i=0;i<periodicity;i++) puissance*=2; */
+       puissance <<= periodicity;
+       for (i = 0; i < ANGLES; i++)
+               fp->stab[i] = (int) (SINF(i * puissance * M_PI / ANGLES) * fp->samp) +
+                       fp->sofs;
+}
+
+static void
+affiche(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       int         x, y, xp, yp;
+       flagstruct *fp = &flags[MI_SCREEN(mi)];
+
+       for (x = 0; x < fp->image->width; x++)
+               for (y = fp->image->height - 1; y >= 0; y--) {
+                       xp = (int) (fp->size * (float) x) +
+                               fp->stab[(fp->sidx + x + y) % ANGLES];
+                       yp = (int) (fp->size * (float) y) +
+                               fp->stab[(fp->sidx + 4 * x + y + y) % ANGLES];
+                       if (MI_NPIXELS(mi) <= 2 || fp->graphics_format < IS_XPM ||
+                           fp->choice == MESSAGE_FLAG) {
+                               if (((int) !invert) ^ XGetPixel(fp->image, x, y))
+                                       XSetForeground(display, fp->backGC, fp->black);
+                               else if (MI_NPIXELS(mi) <= 2)
+                                       XSetForeground(display, fp->backGC, MI_WHITE_PIXEL(mi));
+                               else
+                                       XSetForeground(display, fp->backGC,
+                                                      MI_PIXEL(mi, (y + x + fp->sidx + fp->startcolor) %
+                                                           MI_NPIXELS(mi)));
+                       } else {
+/*
+ * PURIFY sometimes reports thousands of Array Bounds Reads and Free Memory
+ * Reads on the XGetPixel call on the next line. Appears to do this if image
+ * loaded is small.
+ */
+                               XSetForeground(display, fp->backGC, XGetPixel(fp->image, x, y));
+                       }
+                       if (fp->pointsize <= 1)
+                               XDrawPoint(display, fp->cache, fp->backGC, xp, yp);
+                       else
+#ifndef NOTHREED_EFFECT
+                               XFillRectangle(display, fp->cache, fp->backGC, xp, yp,
+                                              fp->pointsize, fp->pointsize);
+#else
+                       if (fp->pointsize < 6)
+                               XFillRectangle(display, fp->cache, fp->backGC, xp, yp,
+                                              fp->pointsize, fp->pointsize);
+                       else
+                               XFillArc(display, fp->cache, fp->backGC, xp, yp,
+                                 fp->pointsize, fp->pointsize, 0, 360 * 64);
+#endif
+               }
+}
+
+extern char *message;
+
+static void
+getText(ModeInfo * mi, XImage ** image)
+{
+       Display    *display = MI_DISPLAY(mi);
+       char       *text1, *text2;
+       char       *line, *token;
+       int         width, height;
+       int         lines;
+       int         margin = 2;
+       XCharStruct overall;
+       XGCValues   gcv;
+       GC          gc;
+       Pixmap      text_pixmap;
+
+
+       if (!message || !*message) {
+#if !defined( VMS ) || ( __VMS_VER >= 70000000 ) || defined( USE_XVMSUTILS )
+               struct utsname uts;
+
+               if (uname(&uts) < 0) {
+                       text1 = (char *) strdup("uname() failed");
+               } else {
+                       char       *s;
+
+                       if ((s = strchr(uts.nodename, '.')))
+                               *s = 0;
+                       text1 = (char *) malloc(strlen(uts.nodename) +
+                                               strlen(uts.sysname) +
+                                               strlen(uts.release) + 10);
+#ifdef AIXV3
+                       (void) sprintf(text1, "%s\n%s %s",
+                                      uts.nodename, uts.sysname, "3");
+#else
+                       (void) sprintf(text1, "%s\n%s %s",
+                                    uts.nodename, uts.sysname, uts.release);
+#endif
+               }
+#else
+               text1 = (char *) strdup("OpenVMS");     /* It says release 0 in my utsname.h */
+#endif
+       } else {
+               text1 = (char *) strdup(message);
+       }
+       while (*text1 && (text1[strlen(text1) - 1] == '\r' ||
+                         text1[strlen(text1) - 1] == '\n'))
+               text1[strlen(text1) - 1] = 0;
+       text2 = (char *) strdup(text1);
+
+
+       if (messagefont == None)
+               messagefont = getFont(display);
+
+       (void) memset(&overall, 0, sizeof (overall));
+       token = text1;
+       lines = 0;
+       while ((line = strtok(token, "\r\n"))) {
+               XCharStruct o2;
+               int         ascent, descent, direction;
+
+               token = 0;
+               (void) XTextExtents(messagefont, line, strlen(line),
+                                   &direction, &ascent, &descent, &o2);
+               overall.lbearing = MAX(overall.lbearing, o2.lbearing);
+               overall.rbearing = MAX(overall.rbearing, o2.rbearing);
+               lines++;
+       }
+
+       width = overall.lbearing + overall.rbearing + margin + margin + 1;
+       height = ((messagefont->ascent + messagefont->descent) * lines) +
+               margin + margin;
+
+       text_pixmap = XCreatePixmap(display, MI_WINDOW(mi), width, height, 1);
+
+       gcv.font = messagefont->fid;
+       gcv.foreground = 0;
+       gcv.background = 0;
+       gc = XCreateGC(display, text_pixmap,
+                      GCFont | GCForeground | GCBackground, &gcv);
+       XFillRectangle(display, text_pixmap, gc, 0, 0, width, height);
+       XSetForeground(display, gc, 1);
+
+       token = text2;
+       lines = 0;
+       while ((line = strtok(token, "\r\n"))) {
+               XCharStruct o2;
+               int         ascent, descent, direction, xoff;
+
+               token = 0;
+
+               (void) XTextExtents(messagefont, line, strlen(line),
+                                   &direction, &ascent, &descent, &o2);
+               xoff = ((overall.lbearing + overall.rbearing) -
+                       (o2.lbearing + o2.rbearing)) / 2;
+
+               (void) XDrawString(display, text_pixmap, gc,
+                                  overall.lbearing + margin + xoff,
+                                  ((messagefont->ascent * (lines + 1)) +
+                                   (messagefont->descent * lines) + margin),
+                                  line, strlen(line));
+               lines++;
+       }
+       (void) free((void *) text1);
+       (void) free((void *) text2);
+       /*XUnloadFont(display, messagefont->fid); */
+       XFreeGC(display, gc);
+
+       *image = XGetImage(display, text_pixmap, 0, 0, width, height,
+                          1L, XYPixmap);
+       XFreePixmap(display, text_pixmap);
+}
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       flagstruct *fp = &flags[MI_SCREEN(mi)];
+
+       if (!fp->logo)
+               getImage(mi, &fp->logo, FLAG_WIDTH, FLAG_HEIGHT, FLAG_BITS,
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                        DEFAULT_XPM, FLAG_NAME,
+#endif
+                        &fp->graphics_format, &fp->cmap, &fp->black);
+#ifndef STANDALONE
+       if (fp->cmap != None) {
+               setColormap(display, window, fp->cmap, MI_IS_INWINDOW(mi));
+               if (fp->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = fp->black;
+                       fp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else
+#endif /* STANDALONE */
+       {
+               fp->black = MI_BLACK_PIXEL(mi);
+               fp->backGC = MI_GC(mi);
+       }
+}
+
+static void
+free_stuff(Display * display, flagstruct * fp)
+{
+       if (fp->cmap != None) {
+               XFreeColormap(display, fp->cmap);
+               if (fp->backGC != None) {
+                       XFreeGC(display, fp->backGC);
+                       fp->backGC = None;
+               }
+               fp->cmap = None;
+       } else
+               fp->backGC = None;
+       destroyImage(&fp->logo, &fp->graphics_format);
+}
+
+void
+init_flag(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       int         size = MI_SIZE(mi);
+       flagstruct *fp;
+
+       if (flags == NULL) {
+               if ((flags = (flagstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (flagstruct))) == NULL)
+                       return;
+       }
+       fp = &flags[MI_SCREEN(mi)];
+
+       init_stuff(mi);
+
+       fp->width = MI_WIDTH(mi);
+       fp->height = MI_HEIGHT(mi);
+
+       if (fp->image) {
+               if (fp->graphics_format == IS_XBM)
+                       XFree(fp->image);
+               else
+                       (void) XDestroyImage(fp->image);
+               fp->image = NULL;
+       }
+       if (MI_IS_FULLRANDOM(mi) ||
+           (MI_BITMAP(mi) && *(MI_BITMAP(mi)) && message && *message) ||
+       ((!(MI_BITMAP(mi)) || !*(MI_BITMAP(mi))) && (!message || !*message)))
+               fp->choice = (int) (LRAND() & 1);
+       else if (MI_BITMAP(mi) && *(MI_BITMAP(mi)))
+               fp->choice = IMAGE_FLAG;
+       else
+               fp->choice = MESSAGE_FLAG;
+       if (fp->choice == MESSAGE_FLAG) {
+               getText(mi, &fp->image);
+       } else {
+               int         depth = MI_DEPTH(mi);
+
+               if (depth >= 24 && depth < 32)
+                       depth = 32;
+               if (fp->graphics_format < IS_XPM)
+                       depth = 1;
+               fp->image = XCreateImage(display, MI_VISUAL(mi), depth,
+                        (fp->graphics_format < IS_XPM) ? XYBitmap : ZPixmap,
+                                        0, fp->logo->data,
+                                        (fp->graphics_format == IS_RASTERFILE && (fp->logo->width & 1)) ?
+                                        fp->logo->width + 1 : fp->logo->width, fp->logo->height, 8, 0);
+               fp->image->byte_order = LSBFirst;
+               fp->image->bitmap_bit_order = LSBFirst;
+       }
+       fp->samp = MAXAMP;      /* Amplitude */
+       fp->sofs = 20;          /* ???????? */
+       fp->pointsize = size;
+       if (size < -MINSIZE)
+               fp->pointsize = NRAND(-size - MINSIZE + 1) + MINSIZE;
+       if (fp->pointsize < MINSIZE ||
+           fp->width <= MAXW(fp) || fp->height <= MAXH(fp))
+               fp->pointsize = MINSIZE;
+       fp->size = MAXINITSIZE; /* Initial distance between pts */
+       fp->inctaille = 0.05;
+       fp->timer = 0;
+       fp->sidx = fp->x_flag = fp->y_flag = 0;
+
+       if (fp->cache) {
+               XFreePixmap(display, fp->cache);
+       }
+       if (!(fp->cache = XCreatePixmap(display, MI_WINDOW(mi),
+                                       MAXW(fp), MAXH(fp), MI_DEPTH(mi)))) {
+               return;
+       }
+       XSetForeground(display, fp->backGC, fp->black);
+       XSetBackground(display, fp->backGC, fp->black);
+       XFillRectangle(display, fp->cache, fp->backGC,
+                      0, 0, MAXW(fp), MAXH(fp));
+       /* don't want any exposure events from XCopyArea */
+       XSetGraphicsExposures(display, fp->backGC, False);
+       if (MI_NPIXELS(mi) > 2)
+               fp->startcolor = NRAND(MI_NPIXELS(mi));
+       if (fp->width <= MAXW(fp) || fp->height <= MAXH(fp)) {
+               fp->samp = MINAMP;
+               fp->sofs = 0;
+               fp->x_flag = random_num(fp->width - MINW(fp));
+               fp->y_flag = random_num(fp->height - MINH(fp));
+       } else {
+               fp->samp = MAXAMP;
+               fp->sofs = 20;
+               fp->x_flag = random_num(fp->width - MAXW(fp));
+               fp->y_flag = random_num(fp->height - MAXH(fp));
+       }
+
+       initSintab(mi);
+
+       MI_CLEARWINDOWCOLORMAP(mi, fp->backGC, fp->black);
+}
+
+void
+draw_flag(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       flagstruct *fp = &flags[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (fp->width <= MAXW(fp) || fp->height <= MAXH(fp)) {
+               fp->size = MININITSIZE;
+               /* fp->pointsize = MINPOINTSIZE; */
+               XCopyArea(display, fp->cache, window, fp->backGC,
+                         0, 0, MINW(fp), MINH(fp), fp->x_flag, fp->y_flag);
+       } else {
+               if ((fp->size + fp->inctaille) > MAXSCALE)
+                       fp->inctaille = -fp->inctaille;
+               if ((fp->size + fp->inctaille) < MINSCALE)
+                       fp->inctaille = -fp->inctaille;
+               fp->size += fp->inctaille;
+               XCopyArea(display, fp->cache, window, fp->backGC,
+                         0, 0, MAXW(fp), MAXH(fp), fp->x_flag, fp->y_flag);
+       }
+       XSetForeground(MI_DISPLAY(mi), fp->backGC, fp->black);
+       XFillRectangle(display, fp->cache, fp->backGC,
+                      0, 0, MAXW(fp), MAXH(fp));
+       XFlush(display);
+       affiche(mi);
+       fp->sidx += 2;
+       fp->sidx %= (ANGLES * MI_NPIXELS(mi));
+       XFlush(display);
+       fp->timer++;
+       if ((MI_CYCLES(mi) > 0) && (fp->timer >= MI_CYCLES(mi)))
+               init_flag(mi);
+}
+
+void
+release_flag(ModeInfo * mi)
+{
+       if (flags != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       flagstruct *fp = &flags[screen];
+                       Display    *display = MI_DISPLAY(mi);
+
+                       if (fp->cache)
+                               XFreePixmap(display, fp->cache);
+                       if (fp->image) {
+                               if (fp->choice == IMAGE_FLAG && (fp->graphics_format == IS_XBM ||
+                                         fp->graphics_format == IS_XBMDONE))
+                                       XFree((caddr_t) fp->image);     /* Do not destroy data */
+                               else
+                                       (void) XDestroyImage(fp->image);
+                       }
+                       free_stuff(display, fp);
+               }
+               (void) free((void *) flags);
+               flags = NULL;
+       }
+       if (messagefont != None) {
+               XFreeFont(MI_DISPLAY(mi), messagefont);
+               messagefont = None;
+       }
+}
+
+void
+refresh_flag(ModeInfo * mi)
+{
+       flagstruct *fp = &flags[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOWCOLORMAP(mi, fp->backGC, fp->black);
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       /* This is needed when another program changes the colormap. */
+       free_stuff(MI_DISPLAY(mi), fp);
+       init_stuff(mi);
+#endif
+}
+
+#endif /* MODE_flag */
diff --git a/xlockmore-4.14/modes/flame.c b/xlockmore-4.14/modes/flame.c
new file mode 100644 (file)
index 0000000..68426ac
--- /dev/null
@@ -0,0 +1,348 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* flame --- recursive fractal cosmic flames */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)flame.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 11-Aug-95: Got rid of polyominal since it was crashing xlock on some
+ *            machines.
+ * 01-Jun-95: This should look more like the original with some updates by
+ *            Scott Draves.
+ * 27-Jun-91: vary number of functions used.
+ * 24-Jun-91: fixed portability problem with integer mod (%).
+ * 06-Jun-91: Written, received from Scott Draves <spot@cs.cmu.edu>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Flame"
+#define HACK_INIT init_flame
+#define HACK_DRAW draw_flame
+#define flame_opts xlockmore_opts
+#define DEFAULTS "*delay: 750000 \n" \
+ "*count: 20 \n" \
+ "*cycles: 10000 \n" \
+ "*ncolors: 200 \n"
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_flame
+
+ModeSpecOpt flame_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   flame_description =
+{"flame", "init_flame", "draw_flame", "release_flame",
+ "refresh_flame", "init_flame", NULL, &flame_opts,
+ 750000, 20, 10000, 1, 64, 1.0, "",
+ "Shows cosmic flame fractals", 0, NULL};
+
+#endif
+
+#define MAXLEV    4
+#define MAXKINDS  9
+#define MAXBATCH  12
+
+typedef struct {
+       double      f[2][3][MAXLEV];    /* three non-homogeneous transforms */
+       int         variation;
+       int         max_levels;
+       int         cur_level;
+       int         snum;
+       int         anum;
+       int         width, height;
+       int         num_points;
+       int         total_points;
+       int         pixcol;
+       int         cycles;
+       int         alt;
+       XPoint      pts[MAXBATCH];
+       short       lasthalf;
+} flamestruct;
+
+static flamestruct *flames = NULL;
+
+static short
+halfrandom(flamestruct * fp, int mv)
+{
+       unsigned long r;
+
+       if (fp->lasthalf) {
+               r = fp->lasthalf;
+               fp->lasthalf = 0;
+       } else {
+               r = LRAND();
+               fp->lasthalf = (short) (r >> 16);
+       }
+       return r % mv;
+}
+
+static      Bool
+recurse(ModeInfo * mi, flamestruct * fp,
+       register double x, register double y, register int l)
+{
+       int         i;
+       double      nx, ny;
+
+       if (l == fp->max_levels) {
+               fp->total_points++;
+               if (fp->total_points > fp->cycles)      /* how long each fractal runs */
+                       return False;
+
+               if (x > -1.0 && x < 1.0 && y > -1.0 && y < 1.0) {
+                       fp->pts[fp->num_points].x = (int) ((fp->width / 2) * (x + 1.0));
+                       fp->pts[fp->num_points].y = (int) ((fp->height / 2) * (y + 1.0));
+                       fp->num_points++;
+                       if (fp->num_points >= MAXBATCH) {       /* point buffer size */
+                               XDrawPoints(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), fp->pts,
+                                           fp->num_points, CoordModeOrigin);
+                               fp->num_points = 0;
+                       }
+               }
+       } else {
+               for (i = 0; i < fp->snum; i++) {
+                       nx = fp->f[0][0][i] * x + fp->f[0][1][i] * y + fp->f[0][2][i];
+                       ny = fp->f[1][0][i] * x + fp->f[1][1][i] * y + fp->f[1][2][i];
+                       if (i < fp->anum) {
+                               switch (fp->variation) {
+                                       case 0: /* sinusoidal */
+                                               nx = sin(nx);
+                                               ny = sin(ny);
+                                               break;
+                                       case 1: /* complex */
+                                               {
+                                                       double      r2 = nx * nx + ny * ny + 1e-6;
+
+                                                       nx = nx / r2;
+                                                       ny = ny / r2;
+                                               }
+                                               break;
+                                       case 2: /* bent */
+                                               if (nx < 0.0)
+                                                       nx = nx * 2.0;
+                                               if (ny < 0.0)
+                                                       ny = ny / 2.0;
+                                               break;
+                                       case 3: /* swirl */
+                                               {
+                                                       double      r = (nx * nx + ny * ny);    /* times k here is fun */
+                                                       double      c1 = sin(r);
+                                                       double      c2 = cos(r);
+                                                       double      t = nx;
+
+                                                       if (nx > 1e4 || nx < -1e4 || ny > 1e4 || ny < -1e4)
+                                                               ny = 1e4;
+                                                       else
+                                                               ny = c2 * t + c1 * ny;
+                                                       nx = c1 * nx - c2 * ny;
+                                               }
+                                               break;
+                                       case 4: /* horseshoe */
+                                               {
+                                                       double      r, c1,
+                                                                   c2,
+                                                                   t;
+
+                                                       /* Avoid atan2: DOMAIN error message */
+                                                       if (nx == 0.0 && ny == 0.0)
+                                                               r = 0.0;
+                                                       else
+                                                               r = atan2(nx, ny);      /* times k here is fun */
+                                                       c1 = sin(r);
+                                                       c2 = cos(r);
+                                                       t = nx;
+
+                                                       nx = c1 * nx - c2 * ny;
+                                                       ny = c2 * t + c1 * ny;
+                                               }
+                                               break;
+                                       case 5: /* drape */
+                                               {
+                                                       double      t;
+
+                                                       /* Avoid atan2: DOMAIN error message */
+                                                       if (nx == 0.0 && ny == 0.0)
+                                                               t = 0.0;
+                                                       else
+                                                               t = atan2(nx, ny) / M_PI;
+
+                                                       if (nx > 1e4 || nx < -1e4 || ny > 1e4 || ny < -1e4)
+                                                               ny = 1e4;
+                                                       else
+                                                               ny = sqrt(nx * nx + ny * ny) - 1.0;
+                                                       nx = t;
+                                               }
+                                               break;
+                                       case 6: /* broken */
+                                               if (nx > 1.0)
+                                                       nx = nx - 1.0;
+                                               if (nx < -1.0)
+                                                       nx = nx + 1.0;
+                                               if (ny > 1.0)
+                                                       ny = ny - 1.0;
+                                               if (ny < -1.0)
+                                                       ny = ny + 1.0;
+                                               break;
+                                       case 7: /* spherical */
+                                               {
+                                                       double      r = 0.5 + sqrt(nx * nx + ny * ny + 1e-6);
+
+                                                       nx = nx / r;
+                                                       ny = ny / r;
+                                               }
+                                               break;
+                                       case 8: /*  */
+                                               nx = atan(nx) / M_PI_2;
+                                               ny = atan(ny) / M_PI_2;
+                                               break;
+#if 0
+/* core dumps on some machines, why not all? */
+                                       case 9: /* complex sine */
+                                               {
+                                                       double      u = nx,
+                                                                   v = ny;
+                                                       double      ev = exp(v);
+                                                       double      emv = exp(-v);
+
+                                                       nx = (ev + emv) * sin(u) / 2.0;
+                                                       ny = (ev - emv) * cos(u) / 2.0;
+                                               }
+                                               break;
+                                       case 10:        /* polynomial */
+                                               if (nx < 0)
+                                                       nx = -nx * nx;
+                                               else
+                                                       nx = nx * nx;
+                                               if (ny < 0)
+                                                       ny = -ny * ny;
+                                               else
+                                                       ny = ny * ny;
+                                               break;
+#endif
+                                       default:
+                                               nx = sin(nx);
+                                               ny = sin(ny);
+                               }
+                       }
+                       if (!recurse(mi, fp, nx, ny, l + 1))
+                               return False;
+               }
+       }
+       return True;
+}
+
+void
+init_flame(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       flamestruct *fp;
+
+       if (flames == NULL) {
+               if ((flames = (flamestruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (flamestruct))) == NULL)
+                       return;
+       }
+       fp = &flames[MI_SCREEN(mi)];
+
+       fp->width = MI_WIDTH(mi);
+       fp->height = MI_HEIGHT(mi);
+
+       fp->max_levels = MI_COUNT(mi);
+       fp->cycles = MI_CYCLES(mi);
+
+       MI_CLEARWINDOW(mi);
+
+       if (MI_NPIXELS(mi) > 2) {
+               fp->pixcol = halfrandom(fp, MI_NPIXELS(mi));
+               XSetForeground(display, gc, MI_PIXEL(mi, fp->pixcol));
+       } else {
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       }
+       fp->variation = NRAND(MAXKINDS);
+}
+
+void
+draw_flame(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       flamestruct *fp = &flames[MI_SCREEN(mi)];
+       int         i, j, k;
+
+       if (!(fp->cur_level++ % fp->max_levels)) {
+               MI_CLEARWINDOW(mi);
+               if (MI_NPIXELS(mi) <= 2)
+                       XSetForeground(display, MI_GC(mi), MI_WHITE_PIXEL(mi));
+               fp->alt = !fp->alt;
+       } else {
+               if (MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, MI_GC(mi), MI_PIXEL(mi, fp->pixcol));
+                       if (--fp->pixcol < 0)
+                               fp->pixcol = MI_NPIXELS(mi) - 1;
+               }
+       }
+
+       MI_IS_DRAWN(mi) = True;
+
+       /* number of functions */
+       fp->snum = 2 + (fp->cur_level % (MAXLEV - 1));
+
+       /* how many of them are of alternate form */
+       if (fp->alt)
+               fp->anum = 0;
+       else
+               fp->anum = halfrandom(fp, fp->snum) + 2;
+
+       /* 6 coefs per function */
+       for (k = 0; k < fp->snum; k++) {
+               for (i = 0; i < 2; i++)
+                       for (j = 0; j < 3; j++)
+                               fp->f[i][j][k] = ((double) (LRAND() & 1023) / 512.0 - 1.0);
+       }
+       fp->num_points = 0;
+       fp->total_points = 0;
+       (void) recurse(mi, fp, 0.0, 0.0, 0);
+       XDrawPoints(display, MI_WINDOW(mi), MI_GC(mi),
+                   fp->pts, fp->num_points, CoordModeOrigin);
+}
+
+void
+release_flame(ModeInfo * mi)
+{
+       if (flames != NULL) {
+               (void) free((void *) flames);
+               flames = NULL;
+       }
+}
+
+void
+refresh_flame(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_flame */
diff --git a/xlockmore-4.14/modes/flow.c b/xlockmore-4.14/modes/flow.c
new file mode 100644 (file)
index 0000000..1c33340
--- /dev/null
@@ -0,0 +1,590 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* flow --- flow of strange bees */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)flow.c 4.13 99/02/04 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by Tim Auckland <Tim.Auckland@Sun.COM>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * "flow" shows a variety of continuous phase-space flows around strange
+ * attractors.  It includes the well-known Lorentz mask (the "Butterfly"
+ * of chaos fame), two forms of Rossler's "Folded Band" and Poincare'
+ * sections of the "Birkhoff Bagel" and Duffing's forced occilator.
+ *
+ * Revision History:
+ * 28-Jan-98: This change catches 'lost' bees in flow.c and disables them.
+ *   I chose to disable them rather than reinitialise them because
+ *   reinitialising can produce fake attractors.
+ *   This has allowed me to relax some of the parameters and initial
+ *   conditions slightly to catch some of the more extreme cases.  As a
+ *   result you may see some bees fly away at the start - these are the ones
+ *   that 'missed' the attractor.  If the bee with the camera should fly
+ *   away the mode will restart  :-)
+ * 31-Nov-98: [TDA] Added Duffing  (what a strange day that was :) DAB)
+ *   Duffing's forced oscillator has been added to the formula list and
+ *   the parameters section has been updated to display it in Poincare'
+ *   section.
+ * 30-Nov-98: [TDA] Added travelling perspective option
+ *   A more exciting point-of-view has been added to all autonomous flows.
+ *   This views the flow as seen by a particle moving with the flow.  In the
+ *   metaphor of the original code, I've attached a camera to one of the
+ *   trained bees!
+ * 30-Nov-98: [TDA] Much code cleanup.
+ * 09-Apr-97: [TDA] Ported to xlockmore-4
+ * 18-Jul-96: Adapted from swarm.c Copyright (c) 1991 by Patrick J. Naughton.
+ * 31-Aug-90: Adapted from xswarm by Jeff Butterworth. (butterwo@ncsc.org)
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Flow"
+#define HACK_INIT init_flow
+#define HACK_DRAW draw_flow
+#define flow_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+"*count: 1024 \n" \
+"*cycles: 3000 \n" \
+"*ncolors: 200 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_flow
+
+ModeSpecOpt flow_opts = { 0, NULL, 0, NULL, NULL };
+
+#ifdef USE_MODULES
+ModStruct   flow_description = {
+       "flow", "init_flow", "draw_flow", "release_flow",
+       "refresh_flow", "init_flow", NULL, &flow_opts,
+       1000, 1024, 3000, 1, 64, 1.0, "",
+       "Shows dynamic strange attractors", 0, NULL
+};
+
+#endif
+
+typedef struct {
+       double      x;
+       double      y;
+       double      z;
+} dvector;
+
+typedef struct {
+       double      a, b, c;
+} Par;
+
+/* Macros */
+#define X(t,b) (sp->p[t][b].x)
+#define Y(t,b) (sp->p[t][b].y)
+#define Z(t,b) (sp->p[t][b].z)
+#define balance_rand(v)        ((LRAND()/MAXRAND*(v))-((v)/2)) /* random around 0 */
+#define SCALE_X(A) (sp->width/2+sp->width/sp->size*(A))
+#define SCALE_Y(A) (sp->height/2+sp->height/sp->size*(A))
+#define LOST_IN_SPACE (sp->size * 10)
+#define LOST_IN_TIME  1E+40
+
+typedef struct {
+       int         width;
+       int         height;
+       int         count;
+       double      size;
+       
+       int         beecount;   /* number of bees */
+       XSegment   *csegs;          /* bee lines */
+       int        *cnsegs;
+       XSegment   *old_segs;   /* old bee lines */
+       int         nold_segs;
+       double      step;
+       dvector     centre;             /* centre */
+       struct {
+               double  depth;
+               double  height;
+       }           view;
+       dvector    *p[2];   /* bee positions x[time][bee#] */
+       struct {
+               double  theta;
+               double  dtheta;
+               double  phi;
+               double  dphi;
+       }           tumble;
+       dvector  (*ODE) (Par par, double x, double y, double z);
+       Par         par;
+} flowstruct;
+
+static flowstruct *flows = NULL;
+
+static dvector
+Lorentz(Par par, double x, double y, double z)
+{
+       dvector d;
+
+       d.x = par.a * (y - x);
+       d.y = x * (par.b - z) - y;
+       d.z = x * y - par.c * z;
+       return d;
+}
+
+static dvector
+Rossler(Par par, double x, double y, double z)
+{
+       dvector d;
+
+       d.x = -(y + par.a * z);
+       d.y = x + y * par.b;
+       d.z = par.c + z * (x - 5.7);
+       return d;
+}
+
+static dvector
+RosslerCone(Par par, double x, double y, double z)
+{
+       dvector d;
+
+       d.x = -(y + par.a * z);
+       d.y = x + y * par.b - z * z * par.c;
+       d.z = 0.2 + z * (x - 5.7);
+       return d;
+}
+
+static dvector
+Birkhoff(Par par, double x, double y, double z)
+{
+       dvector d;
+
+       d.x = -y + par.b * sin(z);
+       d.y = 0.7 * x + par.a * y * (0.1 - x * x);
+       d.z = par.c;
+       return d;
+}
+
+static dvector
+Duffing(Par par, double x, double y, double z)
+{
+       dvector d;
+
+       d.x = -par.a * x - y/2 - y * y * y/8 + par.b * cos(z);
+       d.y = 2*x;
+       d.z = par.c;
+       return d;
+}
+
+void
+init_flow(ModeInfo * mi)
+{
+       flowstruct *sp;
+       int         b;
+       double      beemult = 1;
+       dvector     range;
+       static int  allocated = 0;
+
+       if (flows == NULL) {
+               if ((flows = (flowstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (flowstruct))) == NULL)
+                       return;
+       }
+       sp = &flows[MI_SCREEN(mi)];
+
+       sp->count = 0;
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+
+       sp->tumble.theta = balance_rand(M_PI);
+       sp->tumble.phi = balance_rand(M_PI);
+       sp->tumble.dtheta = 0.002;
+       sp->tumble.dphi = 0.001;
+       sp->view.height = 0;
+       sp->view.depth = 0; /* no perspective view */
+
+       switch (NRAND(8)) {
+       case 0:
+               sp->view.depth = 10;
+               sp->view.height = 0.2;
+               beemult = 3;
+       case 1:
+               sp->ODE = Lorentz;
+               sp->step = 0.02;
+               sp->size = 60;
+               sp->centre.x = 0;
+               sp->centre.y = 0;
+               sp->centre.z = 24;
+               range.x = 5;
+               range.y = 5;
+               range.z = 1;
+               sp->par.a = 10 + balance_rand(5);
+               sp->par.b = 28 + balance_rand(5);
+               sp->par.c = 2 + balance_rand(1);
+               break;
+       case 2:
+               sp->view.depth = 10;
+               sp->view.height = 0.1;
+               beemult = 4;
+       case 3:
+               sp->ODE = Rossler;
+               sp->step = 0.05;
+               sp->size = 24;
+               sp->centre.x = 0;
+               sp->centre.y = 0;
+               sp->centre.z = 3;
+               range.x = 6;
+               range.y = 6;
+               range.z = 5;
+               sp->par.a = 2 + balance_rand(1);
+               sp->par.b = 0.2 + balance_rand(0.1);
+               sp->par.c = 0.2 + balance_rand(0.1);
+               break;
+       case 4:
+               sp->view.depth = 10;
+               sp->view.height = 0.1;
+               beemult = 3;
+       case 5:
+               sp->ODE = RosslerCone;
+               sp->step = 0.05;
+               sp->size = 24;
+               sp->centre.x = 0;
+               sp->centre.y = 0;
+               sp->centre.z = 3;
+               range.x = 6;
+               range.y = 6;
+               range.z = 6;
+               sp->par.a = 2;
+               sp->par.b = 0.2;
+               sp->par.c = 0.331 + balance_rand(0.01);
+               break;
+       case 6:
+               sp->ODE = Birkhoff;
+               sp->step = 0.04;
+               sp->size = 2.6;
+               sp->centre.x = 0;
+               sp->centre.y = 0;
+               sp->centre.z = 0;
+               range.x = 3;
+               range.y = 4;
+               range.z = 0;
+               sp->par.a = 10 + balance_rand(5);
+               sp->par.b = 0.35 + balance_rand(0.25);
+               sp->par.c = 1.57;
+               sp->tumble.theta = 0;
+               sp->tumble.phi = 0;
+               sp->tumble.dtheta = 0;
+               sp->tumble.dphi = 0;
+               break;
+       case 7:
+       default:
+               sp->ODE = Duffing;
+               sp->step = 0.02;
+               sp->size = 30;
+               sp->centre.x = 0;
+               sp->centre.y = 0;
+               sp->centre.z = 0;
+               range.x = 20;
+               range.y = 20;
+               range.z = 0;
+               sp->par.a = 0.2 + balance_rand(0.1);
+               sp->par.b = 27.0 + balance_rand(3.0);
+               sp->par.c = 1.33;
+               sp->tumble.theta = 0;
+               sp->tumble.phi = 0;
+               sp->tumble.dtheta = -NRAND(2)*sp->par.c*sp->step;
+               sp->tumble.dphi = 0;
+               beemult = 0.5;
+               break;
+       }
+
+       sp->beecount = beemult * MI_COUNT(mi);
+       if (sp->beecount < 0)   /* random variations */ 
+               sp->beecount = NRAND(-sp->beecount) + 1; /* Minimum 1 */
+
+       /* Clear the background. */
+       MI_CLEARWINDOW(mi);
+
+       if(!allocated || sp->beecount != allocated){ /* reallocate */
+               if (sp->csegs != NULL) {
+                       (void) free((void *) sp->csegs);
+                       sp->csegs = NULL;
+               }
+               if (sp->cnsegs != NULL) {
+                       (void) free((void *) sp->cnsegs);
+                       sp->cnsegs = NULL;
+               }
+               if (sp->old_segs != NULL) {
+                       (void) free((void *) sp->old_segs);
+                       sp->old_segs = NULL;
+               }
+               if (sp->p[0] != NULL) {
+                       (void) free((void *) sp->p[0]);
+                       sp->p[0] = NULL;
+               }
+               if (sp->p[1] != NULL) {
+                       (void) free((void *) sp->p[1]);
+                       sp->p[1] = NULL;
+               }
+       }
+
+       /* Allocate memory. */
+
+       if (!sp->csegs) {
+               sp->csegs = (XSegment *) malloc(sizeof (XSegment) * sp->beecount
+                                               * MI_NPIXELS(mi));
+               sp->cnsegs = (int *) malloc(sizeof (int) * MI_NPIXELS(mi));
+
+               sp->old_segs = (XSegment *) malloc(sizeof (XSegment) * sp->beecount);
+               sp->p[0] = (dvector *) malloc(sizeof (dvector) * sp->beecount);
+               sp->p[1] = (dvector *) malloc(sizeof (dvector) * sp->beecount);
+       }
+
+       /* Initialize point positions, velocities, etc. */
+
+       for (b = 0; b < sp->beecount; b++) {
+               X(1, b) = X(0, b) = balance_rand(range.x);
+               Y(1, b) = Y(0, b) = balance_rand(range.y);
+               Z(1, b) = Z(0, b) = balance_rand(range.z);
+       }
+}
+
+void
+draw_flow(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       flowstruct *sp = &flows[MI_SCREEN(mi)];
+       int         b, c, i;
+       int         col, ix;
+       double      M[3][3]; /* transformation matrix */
+
+       if(!sp->view.depth){ /* simple 3D tumble */
+               double      sint, cost, sinp, cosp;
+               sp->tumble.theta += sp->tumble.dtheta;
+               sp->tumble.phi += sp->tumble.dphi;
+               sint = sin(sp->tumble.theta);
+               cost = cos(sp->tumble.theta);
+               sinp = sin(sp->tumble.phi);
+               cosp = cos(sp->tumble.phi);
+               M[0][0]= cost; M[0][1]=-sint*cosp; M[0][2]= sint*sinp;
+               M[1][0]= sint; M[1][1]= cost*cosp; M[1][2]=-cost*sinp;
+               M[2][0]= 0;    M[2][1]= 0;         M[2][2]= 1;
+       } else { /* initialize matrix */
+               M[0][0]= 0; M[0][1]= 0; M[0][2]= 0;
+               M[1][0]= 0; M[1][1]= 0; M[1][2]= 0;
+               M[2][0]= 0; M[2][1]= 0; M[2][2]= 0;
+
+       }
+
+       for (col = 0; col < MI_NPIXELS(mi); col++)
+               sp->cnsegs[col] = 0;
+
+       MI_IS_DRAWN(mi) = True;
+
+       /* <=- Bees -=> */
+       for (b = 0; b < sp->beecount; b++) {
+               if(fabs(X(0, b)) > LOST_IN_SPACE ||
+                  fabs(Y(0, b)) > LOST_IN_SPACE ||
+                  /* if z is always invisible it's probably time */
+                  fabs(Z(0, b)) > ((sp->tumble.dphi!=0 ||
+                                                        sp->tumble.phi!=0)?LOST_IN_SPACE:LOST_IN_TIME)){
+                       if(sp->view.depth && b==0){ /* lost camera - reset */           
+                               init_flow(mi);
+                               return;
+                       }
+                       continue;
+               }
+               /* Age the arrays. */
+               X(1, b) = X(0, b);
+               Y(1, b) = Y(0, b);
+               Z(1, b) = Z(0, b);
+
+               /* 2nd order Kunge Kutta */
+               {
+                       dvector     k1, k2;
+
+                       k1 = sp->ODE(sp->par, X(1, b), Y(1, b), Z(1, b));
+                       k1.x *= sp->step;
+                       k1.y *= sp->step;
+                       k1.z *= sp->step;
+                       k2 = sp->ODE(sp->par, X(1, b) + k1.x, Y(1, b) + k1.y, Z(1, b) + k1.z);
+                       k2.x *= sp->step;
+                       k2.y *= sp->step;
+                       k2.z *= sp->step;
+                       X(0, b) = X(1, b) + (k1.x + k2.x) / 2.0;
+                       Y(0, b) = Y(1, b) + (k1.y + k2.y) / 2.0;
+                       Z(0, b) = Z(1, b) + (k1.z + k2.z) / 2.0;
+               }
+
+               /* Colour according to bee */
+               col = b % (MI_NPIXELS(mi) - 1);
+               ix = col * sp->beecount + sp->cnsegs[col];
+
+               /* Fill the segment lists. */
+
+               if(sp->view.depth) /* perspective view has special points */
+                       if(b==0){ /* point of view */
+                               sp->centre.x=X(0, b);
+                               sp->centre.y=Y(0, b);
+                               sp->centre.z=Z(0, b);
+                       }else if(b==1){ /* neighbour: used to compute local axes */
+                               double x[3], p[3], x2=0, xp=0;
+                               int j;
+
+                               /* forward */                           
+                               x[0] = X(0, 0) - X(1, 0);
+                               x[1] = Y(0, 0) - Y(1, 0);
+                               x[2] = Z(0, 0) - Z(1, 0);
+                       
+                               /* neighbour */
+                               p[0] = X(0, 1) - X(1, 0);
+                               p[1] = Y(0, 1) - Y(1, 0);
+                               p[2] = Z(0, 1) - Z(1, 0);
+
+                               for(i=0; i<3; i++){
+                                       x2+= x[i]*x[i];    /* X . X */
+                                       xp+= x[i]*p[i];    /* X . P */
+                                       M[0][i] = x[i];    /* X */
+                               }
+
+                               for(i=0; i<3; i++)               /* (X x P) x X */
+                                       M[1][i] = x2*p[i] - xp*x[i]; /* == (X . X) P - (X . P) X */
+                               
+                               M[2][0] =  x[1]*p[2] - x[2]*p[1]; /* X x P */
+                               M[2][1] = -x[0]*p[2] + x[2]*p[0];
+                               M[2][2] =  x[0]*p[1] - x[1]*p[0];
+
+                               /* normalise axes */
+                               for(j=0; j<3; j++){
+                                       double A=0;
+                                       for(i=0; i<3; i++) A+=M[j][i]*M[j][i]; /* sum squares */
+                                       A=sqrt(A);
+                                       for(i=0; i<3; i++) M[j][i]/=A;
+                               }
+
+                               X(0, 1)=X(0, 0)+M[1][0]; /* adjust neighbour */
+                               Y(0, 1)=Y(0, 0)+M[1][1];
+                               Z(0, 1)=Z(0, 0)+M[1][2];
+
+#if 0  /* display local axes for testing */
+                               X(1, b)=X(0, 0);
+                               Y(1, b)=Y(0, 0);
+                               Z(1, b)=Z(0, 0);
+                       }else if(b==2){
+                               X(0, b)=X(0, 0)+0.5*M[0][0];
+                               Y(0, b)=Y(0, 0)+0.5*M[0][1];
+                               Z(0, b)=Z(0, 0)+0.5*M[0][2];
+                               X(1, b)=X(0, 0);
+                               Y(1, b)=Y(0, 0);
+                               Z(1, b)=Z(0, 0);
+                       }else if(b==3){
+                               X(0, b)=X(0, 0)+1.5*M[2][0];
+                               Y(0, b)=Y(0, 0)+1.5*M[2][1];
+                               Z(0, b)=Z(0, 0)+1.5*M[2][2];
+                               X(1, b)=X(0, 0);
+                               Y(1, b)=Y(0, 0);
+                               Z(1, b)=Z(0, 0);
+#endif
+                       }
+               
+               for(i=0; i<2; i++){
+                       double x=X(i,b)-sp->centre.x;
+                       double y=Y(i,b)-sp->centre.y;
+                       double z=Z(i,b)-sp->centre.z;
+                       double X=M[0][0]*x + M[0][1]*y + M[0][2]*z;
+                       double Y=M[1][0]*x + M[1][1]*y + M[1][2]*z;
+                       double Z=M[2][0]*x + M[2][1]*y + M[2][2]*z+sp->view.height;
+                       double absx, absy;                              
+                       if(sp->view.depth){
+                               if(X <= 0) break;
+                               absx=SCALE_X(sp->view.depth*Y/X);
+                               absy=SCALE_Y(sp->view.depth*Z/X);
+                               if(absx < -sp->width || absx > 2*sp->width ||
+                                  absy < -sp->height || absy > 2*sp->height)
+                                       break;
+                       }else{
+                               absx=SCALE_X(X);
+                               absy=SCALE_Y(Y);
+                       }
+                       if(i){
+                               sp->csegs[ix].x1 = (short) absx;
+                               sp->csegs[ix].y1 = (short) absy;
+                       }else{
+                               sp->csegs[ix].x2 = (short) absx;
+                               sp->csegs[ix].y2 = (short) absy;
+                       }
+               }
+               if(i == 2) /* both assigned */
+                       sp->cnsegs[col]++;
+    }
+       if (sp->count) { /* erase */
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XDrawSegments(display, window, gc, sp->old_segs, sp->nold_segs);
+       }
+
+       if (MI_NPIXELS(mi) > 2){ /* render colour */
+               for (col = 0; col < MI_NPIXELS(mi); col++)
+                       if (sp->cnsegs[col] > 0) {
+                               XSetForeground(display, gc, MI_PIXEL(mi, col));
+                               XDrawSegments(display, window, gc,
+                                             sp->csegs + col * sp->beecount, sp->cnsegs[col]);
+                       }
+       } else {                /* render mono */
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               XDrawSegments(display, window, gc,
+                                         sp->csegs + col * sp->beecount, sp->cnsegs[col]);
+       }
+
+       /* Copy to erase-list */
+       for (col = 0, c = 0; col < MI_NPIXELS(mi); col++)
+               for (b = 0; b < sp->cnsegs[col]; b++)
+                       sp->old_segs[c++] = (sp->csegs + col * sp->beecount)[b];
+       sp->nold_segs = c;
+
+       if (++sp->count > MI_CYCLES(mi)) /* pick a new flow */
+               init_flow(mi);
+}
+
+void
+release_flow(ModeInfo * mi)
+{
+       if (flows != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       flowstruct *sp = &flows[screen];
+
+                       if (sp->csegs != NULL)
+                               (void) free((void *) sp->csegs);
+                       if (sp->cnsegs != NULL)
+                               (void) free((void *) sp->cnsegs);
+                       if (sp->old_segs != NULL)
+                               (void) free((void *) sp->old_segs);
+                       if (sp->p[0] != NULL)
+                               (void) free((void *) sp->p[0]);
+                       if (sp->p[1] != NULL)
+                               (void) free((void *) sp->p[1]);
+               }
+               (void) free((void *) flows);
+               flows = NULL;
+       }
+}
+
+void
+refresh_flow(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_flow */
diff --git a/xlockmore-4.14/modes/forest.c b/xlockmore-4.14/modes/forest.c
new file mode 100644 (file)
index 0000000..08f81f1
--- /dev/null
@@ -0,0 +1,221 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* forest --- binary trees in a fractal forest */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)forest.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 Pascal Pensa <pensa@aurora.unice.fr>
+ *
+ * Original idea : Guillaume Ramey <ramey@aurora.unice.fr>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ *
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Forest"
+#define HACK_INIT init_forest
+#define HACK_DRAW draw_forest
+#define forest_opts xlockmore_opts
+#define DEFAULTS "*delay: 400000 \n" \
+ "*count: 100 \n" \
+ "*cycles: 200 \n" \
+ "*ncolors: 100 \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_forest
+
+ModeSpecOpt forest_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   forest_description =
+{"forest", "init_forest", "draw_forest", "release_forest",
+ "refresh_forest", "init_forest", NULL, &forest_opts,
+ 400000, 100, 200, 1, 64, 1.0, "",
+ "Shows binary trees of a fractal forest", 0, NULL};
+
+#endif
+
+#define MINTREES   1
+
+#define MINHEIGHT  20          /* Tree height range */
+#define MAXHEIGHT  40
+
+#define MINANGLE   15          /* (degree) angle between soon */
+#define MAXANGLE   35
+#define RANDANGLE  15          /* (degree) Max random angle from default */
+
+#define REDUCE     90          /* Height % from father */
+
+#define ITERLEVEL  10          /* Tree iteration */
+
+#define COLORSPEED  2          /* Color increment */
+
+/* degree to radian */
+#define DEGTORAD(x) (((float)(x)) * M_PI / 180.0)
+
+#define RANGE_RAND(min,max) ((min) + NRAND((max) - (min)))
+
+typedef struct {
+       int         width;
+       int         height;
+       int         time;       /* up time */
+       int         ntrees;
+} foreststruct;
+
+static foreststruct *forests = NULL;
+
+static void
+draw_tree(ModeInfo * mi,
+         short int x, short int y, short int len,
+         float a, float as, short int c, short int level)
+                               /* Father's end */
+                               /* Length */
+                               /* color */
+                               /* Height level */
+                               /* Father's angle */
+                               /* Father's angle step */
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       short       x_1, y_1, x_2, y_2;
+       float       a1, a2;
+
+       /* left */
+
+       a1 = a + as + DEGTORAD(NRAND(2 * RANDANGLE) - RANDANGLE);
+
+       x_1 = x + (short) (COSF(a1) * ((float) len));
+       y_1 = y + (short) (SINF(a1) * ((float) len));
+
+       /* right */
+
+       a2 = a - as + DEGTORAD(NRAND(2 * RANDANGLE) - RANDANGLE);
+
+       x_2 = x + (short) (COSF(a2) * ((float) len));
+       y_2 = y + (short) (SINF(a2) * ((float) len));
+
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, c));
+               c = (c + COLORSPEED) % MI_NPIXELS(mi);
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       XDrawLine(display, window, gc, x, y, x_1, y_1);
+       XDrawLine(display, window, gc, x, y, x_2, y_2);
+
+       if (level < 2) {
+               XDrawLine(display, window, gc, x + 1, y, x_1 + 1, y_1);
+               XDrawLine(display, window, gc, x + 1, y, x_2 + 1, y_2);
+       }
+       len = (len * REDUCE * 10) / 1000;
+
+       if (level < ITERLEVEL) {
+               draw_tree(mi, x_1, y_1, len, a1, as, c, level + 1);
+               draw_tree(mi, x_2, y_2, len, a2, as, c, level + 1);
+       }
+}
+
+void
+init_forest(ModeInfo * mi)
+{
+       foreststruct *fp;
+
+       if (forests == NULL) {
+               if ((forests = (foreststruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (foreststruct))) == NULL)
+                       return;
+       }
+       fp = &forests[MI_SCREEN(mi)];
+
+       fp->width = MI_WIDTH(mi);
+       fp->height = MI_HEIGHT(mi);
+       fp->time = 0;
+
+       fp->ntrees = MI_COUNT(mi);
+       if (fp->ntrees < -MINTREES)
+               fp->ntrees = NRAND(-fp->ntrees - MINTREES + 1) + MINTREES;
+       else if (fp->ntrees < MINTREES)
+               fp->ntrees = MINTREES;
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_forest(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       foreststruct *fp = &forests[MI_SCREEN(mi)];
+       short       x, y, x_2, y_2, len, c = 0;
+       float       a, as;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (fp->time < fp->ntrees) {
+
+               x = RANGE_RAND(0, fp->width);
+               y = RANGE_RAND(0, fp->height + MAXHEIGHT);
+               a = -M_PI / 2.0 + DEGTORAD(NRAND(2 * RANDANGLE) - RANDANGLE);
+               as = DEGTORAD(RANGE_RAND(MINANGLE, MAXANGLE));
+               len = ((RANGE_RAND(MINHEIGHT, MAXHEIGHT) * (fp->width / 20)) / 50) + 2;
+
+               if (MI_NPIXELS(mi) > 2) {
+                       c = NRAND(MI_NPIXELS(mi));
+                       XSetForeground(display, gc, MI_PIXEL(mi, c));
+                       c = (c + COLORSPEED) % MI_NPIXELS(mi);
+               } else
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+               x_2 = x + (short) (COSF(a) * ((float) len));
+               y_2 = y + (short) (SINF(a) * ((float) len));
+
+               XDrawLine(display, MI_WINDOW(mi), gc, x, y, x_2, y_2);
+               XDrawLine(display, MI_WINDOW(mi), gc, x + 1, y, x_2 + 1, y_2);
+
+               draw_tree(mi, x_2, y_2, (len * REDUCE) / 100, a, as, c, 1);
+       }
+       if (++fp->time > MI_CYCLES(mi)) {
+               init_forest(mi);
+       }
+}
+
+void
+release_forest(ModeInfo * mi)
+{
+       if (forests != NULL) {
+               (void) free((void *) forests);
+               forests = NULL;
+       }
+}
+
+void
+refresh_forest(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_forest */
diff --git a/xlockmore-4.14/modes/galaxy.c b/xlockmore-4.14/modes/galaxy.c
new file mode 100644 (file)
index 0000000..e12980f
--- /dev/null
@@ -0,0 +1,491 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* galaxy --- spinning galaxies */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)galaxy.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Originally done by Uli Siegmund <uli@wombat.okapi.sub.org> on Amiga
+ *   for EGS in Cluster
+ * Port from Cluster/EGS to C/Intuition by Harald Backert
+ * Port to X11 and incorporation into xlockmore by Hubert Feyrer
+ *   <hubert.feyrer@rz.uni-regensburg.de>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 18-Apr-97: Memory leak fixed by Tom Schmidt <tschmidt@micron.com>
+ * 07-Apr-97: Modified by Dave Mitchell <davem@magnet.com>
+ * 23-Oct-94: Modified by David Bagley <bagleyd@tux.org>
+ *            random star sizes
+ *            colors change depending on velocity
+ * 10-Oct-94: Add colors by Hubert Feyer
+ * 30-Sep-94: Initial port by Hubert Feyer
+ * 09-Mar-94: VMS can generate a random number 0.0 which results in a
+ *            division by zero, corrected by Jouk Jansen
+ *            <joukj@hrem.stm.tudelft.nl>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Galaxy"
+#define HACK_INIT init_galaxy
+#define HACK_DRAW draw_galaxy
+#define galaxy_opts xlockmore_opts
+#define DEFAULTS "*delay: 100 \n" \
+ "*count: -5 \n" \
+ "*cycles: 250 \n" \
+ "*size: -3 \n" \
+ "*ncolors: 64 \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_galaxy
+
+static Bool tracks;
+
+#define DEF_TRACKS "False"
+
+static XrmOptionDescRec opts[] =
+{
+       {"-tracks", ".galaxy.tracks", XrmoptionNoArg, (caddr_t) "on"},
+       {"+tracks", ".galaxy.tracks", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & tracks, "tracks", "Tracks", DEF_TRACKS, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-/+tracks", "turn on/off star tracks"}
+};
+
+ModeSpecOpt galaxy_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   galaxy_description =
+{"galaxy", "init_galaxy", "draw_galaxy", "release_galaxy",
+ "refresh_galaxy", "init_galaxy", NULL, &galaxy_opts,
+ 100, -5, 250, -3, 64, 1.0, "",
+ "Shows crashing spiral galaxies", 0, NULL};
+
+#endif
+
+#define FLOATRAND ((double) LRAND() / ((double) MAXRAND))
+
+#if 0
+#define WRAP       1           /* Warp around edges */
+#define BOUNCE     1           /* Bounce from borders */
+#endif
+
+#define MINSIZE       1
+#define MINGALAXIES    1
+#define MAX_STARS    300
+#define MAX_IDELTAT    50
+/* These come originally from the Cluster-version */
+#define DEFAULT_GALAXIES  2
+#define DEFAULT_STARS    1000
+#define DEFAULT_HITITERATIONS  7500
+#define DEFAULT_IDELTAT    200 /* 0.02 */
+#define EPSILON 0.00000001
+#define sqrt_EPSILON 0.0001
+
+#define DELTAT (MAX_IDELTAT * 0.0001)
+#define GALAXYRANGESIZE  0.1
+#define GALAXYMINSIZE  0.1
+#define QCONS    0.001
+
+/*-
+ *  The following is enabled, it does not look that good for some.
+ *  (But it looks great for me.)  Maybe velocities should be measured
+ *  relative to their galaxy-centers instead of absolute.
+ */
+#if 0
+#undef NO_VELOCITY_COLORING */ /* different colors for different speeds */
+#endif
+
+#define COLORBASE  (MI_NPIXELS(mi) / COLORS)   /* Colors for stars start here */
+#define GREEN (22 * MI_NPIXELS(mi) / 64)       /* Do green stars exist? */
+#define NOTGREEN  (7 * MI_NPIXELS(mi) / 64)
+#define COLORS 8
+
+#define drawStar(x,y,size) if(size<=1) XDrawPoint(display,window,gc,x,y);\
+  else XFillArc(display,window,gc,x,y,size,size,0,23040)
+
+typedef struct {
+       double      pos[3], vel[3];
+       int         px, py;
+       int         color;
+       int         size;
+} Star;
+
+typedef struct {
+       int         mass;
+       int         nstars;
+       Star       *stars;
+       double      pos[3], vel[3];
+       int         galcol;
+} Galaxy;
+
+typedef struct {
+       struct {
+               int         left;       /* x minimum */
+               int         right;      /* x maximum */
+               int         top;        /* y minimum */
+               int         bottom;     /* y maximum */
+       } clip;
+       double      mat[3][3];  /* Movement of stars(?) */
+       double      scale;      /* Scale */
+       int         midx;       /* Middle of screen, x */
+       int         midy;       /* Middle of screen, y */
+       double      size;       /* */
+       double      diff[3];    /* */
+       Galaxy     *galaxies;   /* the Whole Universe */
+       int         ngalaxies;  /* # galaxies */
+       int         f_hititerations;    /* # iterations before restart */
+       int         step;       /* */
+} unistruct;
+
+static unistruct *universes = NULL;
+
+static void
+free_galaxies(unistruct * gp)
+{
+       if (gp->galaxies != NULL) {
+               int         i;
+
+               for (i = 0; i < gp->ngalaxies; i++) {
+                       Galaxy     *gt = &gp->galaxies[i];
+
+                       if (gt->stars != NULL)
+                               (void) free((void *) gt->stars);
+               }
+               (void) free((void *) gp->galaxies);
+               gp->galaxies = NULL;
+       }
+}
+
+static void
+startover(ModeInfo * mi)
+{
+       unistruct  *gp = &universes[MI_SCREEN(mi)];
+       int         size = (int) MI_SIZE(mi);
+       int         i, j;       /* more tmp */
+       double      w1, w2;     /* more tmp */
+       double      d, v, w, h; /* yet more tmp */
+
+       gp->step = 0;
+
+       if (MI_COUNT(mi) < -MINGALAXIES)
+               free_galaxies(gp);
+       gp->ngalaxies = MI_COUNT(mi);
+       if (gp->ngalaxies < -MINGALAXIES)
+               gp->ngalaxies = NRAND(-gp->ngalaxies - MINGALAXIES + 1) + MINGALAXIES;
+       else if (gp->ngalaxies < MINGALAXIES)
+               gp->ngalaxies = MINGALAXIES;
+       if (gp->galaxies == NULL)
+               gp->galaxies = (Galaxy *) calloc(gp->ngalaxies, sizeof (Galaxy));
+
+       for (i = 0; i < gp->ngalaxies; ++i) {
+               Galaxy     *gt = &gp->galaxies[i];
+               double      sinw1, sinw2, cosw1, cosw2;
+
+               if (MI_NPIXELS(mi) >= COLORS)
+                       do {
+                               gt->galcol = NRAND(COLORBASE) * COLORS;
+                       } while (gt->galcol + COLORBASE / 2 < GREEN + NOTGREEN &&
+                             gt->galcol + COLORBASE / 2 > GREEN - NOTGREEN);
+               else
+                       gt->galcol = 0;
+               /* Galaxies still may have some green stars but are not all green. */
+
+               if (gt->stars != NULL) {
+                       (void) free((void *) gt->stars);
+                       gt->stars = NULL;
+               }
+               gt->nstars = (NRAND(MAX_STARS / 2)) + MAX_STARS / 2;
+               gt->stars = (Star *) malloc(gt->nstars * sizeof (Star));
+               w1 = 2.0 * M_PI * FLOATRAND;
+               w2 = 2.0 * M_PI * FLOATRAND;
+               sinw1 = SINF(w1);
+               sinw2 = SINF(w2);
+               cosw1 = COSF(w1);
+               cosw2 = COSF(w2);
+
+               gp->mat[0][0] = cosw2;
+               gp->mat[0][1] = -sinw1 * sinw2;
+               gp->mat[0][2] = cosw1 * sinw2;
+               gp->mat[1][0] = 0.0;
+               gp->mat[1][1] = cosw1;
+               gp->mat[1][2] = sinw1;
+               gp->mat[2][0] = -sinw2;
+               gp->mat[2][1] = -sinw1 * cosw2;
+               gp->mat[2][2] = cosw1 * cosw2;
+
+               gt->vel[0] = FLOATRAND * 2.0 - 1.0;
+               gt->vel[1] = FLOATRAND * 2.0 - 1.0;
+               gt->vel[2] = FLOATRAND * 2.0 - 1.0;
+               gt->pos[0] = -gt->vel[0] * DELTAT *
+                       gp->f_hititerations + FLOATRAND - 0.5;
+               gt->pos[1] = -gt->vel[1] * DELTAT *
+                       gp->f_hititerations + FLOATRAND - 0.5;
+               gt->pos[2] = -gt->vel[2] * DELTAT *
+                       gp->f_hititerations + FLOATRAND - 0.5;
+
+               gt->mass = (int) (FLOATRAND * 1000.0) + 1;
+
+               gp->size = GALAXYRANGESIZE * FLOATRAND + GALAXYMINSIZE;
+
+               for (j = 0; j < gt->nstars; ++j) {
+                       Star       *st = &gt->stars[j];
+                       double      sinw, cosw;
+
+                       w = 2.0 * M_PI * FLOATRAND;
+                       sinw = SINF(w);
+                       cosw = COSF(w);
+                       d = FLOATRAND * gp->size;
+                       h = FLOATRAND * exp(-2.0 * (d / gp->size)) / 5.0 * gp->size;
+                       if (FLOATRAND < 0.5)
+                               h = -h;
+                       st->pos[0] = gp->mat[0][0] * d * cosw + gp->mat[1][0] * d * sinw +
+                               gp->mat[2][0] * h + gt->pos[0];
+                       st->pos[1] = gp->mat[0][1] * d * cosw + gp->mat[1][1] * d * sinw +
+                               gp->mat[2][1] * h + gt->pos[1];
+                       st->pos[2] = gp->mat[0][2] * d * cosw + gp->mat[1][2] * d * sinw +
+                               gp->mat[2][2] * h + gt->pos[2];
+
+                       v = sqrt(gt->mass * QCONS / sqrt(d * d + h * h));
+                       st->vel[0] = -gp->mat[0][0] * v * sinw + gp->mat[1][0] * v * cosw +
+                               gt->vel[0];
+                       st->vel[1] = -gp->mat[0][1] * v * sinw + gp->mat[1][1] * v * cosw +
+                               gt->vel[1];
+                       st->vel[2] = -gp->mat[0][2] * v * sinw + gp->mat[1][2] * v * cosw +
+                               gt->vel[2];
+
+                       st->vel[0] *= DELTAT;
+                       st->vel[1] *= DELTAT;
+                       st->vel[2] *= DELTAT;
+
+                       st->px = 0;
+                       st->py = 0;
+
+                       if (size < -MINSIZE)
+                               st->size = NRAND(-size - MINSIZE + 1) + MINSIZE;
+                       else if (size < MINSIZE)
+                               st->size = MINSIZE;
+                       else
+                               st->size = size;
+               }
+       }
+
+       MI_CLEARWINDOW(mi);
+
+#if 0
+       (void) printf("ngalaxies=%d, f_hititerations=%d\n",
+                     gp->ngalaxies, gp->f_hititerations);
+       (void) printf("f_deltat=%g\n", DELTAT);
+       (void) printf("Screen: ");
+       (void) printf("%dx%d pixel (%d-%d, %d-%d)\n",
+         (gp->clip.right - gp->clip.left), (gp->clip.bottom - gp->clip.top),
+              gp->clip.left, gp->clip.right, gp->clip.top, gp->clip.bottom);
+#endif /*0 */
+}
+
+void
+init_galaxy(ModeInfo * mi)
+{
+       unistruct  *gp;
+
+       if (universes == NULL) {
+               if ((universes = (unistruct *) calloc(MI_NUM_SCREENS(mi),
+                                               sizeof (unistruct))) == NULL)
+                       return;
+       }
+       gp = &universes[MI_SCREEN(mi)];
+
+       gp->f_hititerations = MI_CYCLES(mi);
+
+       gp->clip.left = 0;
+       gp->clip.top = 0;
+       gp->clip.right = MI_WIDTH(mi);
+       gp->clip.bottom = MI_HEIGHT(mi);
+
+       gp->scale = (double) (gp->clip.right + gp->clip.bottom) / 8.0;
+       gp->midx = gp->clip.right / 2;
+       gp->midy = gp->clip.bottom / 2;
+       startover(mi);
+}
+
+void
+draw_galaxy(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       unistruct  *gp = &universes[MI_SCREEN(mi)];
+       double      d;          /* tmp */
+       int         i, j, k;    /* more tmp */
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < gp->ngalaxies; ++i) {
+               Galaxy     *gt = &gp->galaxies[i];
+
+               for (j = 0; j < gp->galaxies[i].nstars; ++j) {
+                       Star       *st = &gt->stars[j];
+                       double      v0 = st->vel[0];
+                       double      v1 = st->vel[1];
+                       double      v2 = st->vel[2];
+
+                       for (k = 0; k < gp->ngalaxies; ++k) {
+                               Galaxy     *gtk = &gp->galaxies[k];
+                               double      d0 = gtk->pos[0] - st->pos[0];
+                               double      d1 = gtk->pos[1] - st->pos[1];
+                               double      d2 = gtk->pos[2] - st->pos[2];
+
+                               d = d0 * d0 + d1 * d1 + d2 * d2;
+                               if (d > EPSILON)
+                                       d = gt->mass / (d * sqrt(d)) * DELTAT * DELTAT * QCONS;
+                               else
+                                       d = gt->mass / (EPSILON * sqrt_EPSILON) * DELTAT * DELTAT * QCONS;
+                               v0 += d0 * d;
+                               v1 += d1 * d;
+                               v2 += d2 * d;
+                       }
+
+                       st->vel[0] = v0;
+                       st->vel[1] = v1;
+                       st->vel[2] = v2;
+
+#ifndef NO_VELOCITY_COLORING
+                       d = (v0 * v0 + v1 * v1 + v2 * v2) / (3.0 * DELTAT * DELTAT);
+                       if (d > (double) COLORBASE)
+                               st->color = gt->galcol + COLORBASE - 1;
+                       else
+                               st->color = gt->galcol + ((int) d) % COLORBASE;
+#endif
+                       st->pos[0] += v0;
+                       st->pos[1] += v1;
+                       st->pos[2] += v2;
+
+                       if (st->px >= gp->clip.left &&
+                           st->px <= gp->clip.right - st->size &&
+                           st->py >= gp->clip.top &&
+                           st->py <= gp->clip.bottom - st->size) {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               drawStar(st->px, st->py, st->size);
+                       }
+                       st->px = (int) (st->pos[0] * gp->scale) + gp->midx;
+                       st->py = (int) (st->pos[1] * gp->scale) + gp->midy;
+
+
+#ifdef WRAP
+                       if (st->px < gp->clip.left) {
+                               (void) printf("wrap l -> r\n");
+                               st->px = gp->clip.right;
+                       }
+                       if (st->px > gp->clip.right) {
+                               (void) printf("wrap r -> l\n");
+                               st->px = gp->clip.left;
+                       }
+                       if (st->py > gp->clip.bottom) {
+                               (void) printf("wrap b -> t\n");
+                               st->py = gp->clip.top;
+                       }
+                       if (st->py < gp->clip.top) {
+                               (void) printf("wrap t -> b\n");
+                               st->py = gp->clip.bottom;
+                       }
+#endif /*WRAP */
+
+
+                       if (st->px >= gp->clip.left &&
+                           st->px <= gp->clip.right - st->size &&
+                           st->py >= gp->clip.top &&
+                           st->py <= gp->clip.bottom - st->size) {
+                               if (MI_NPIXELS(mi) >= COLORS)
+#ifdef NO_VELOCITY_COLORING
+                                       XSetForeground(display, gc, MI_PIXEL(mi, gt->galcol));
+#else
+                                       XSetForeground(display, gc, MI_PIXEL(mi, st->color));
+#endif
+                               else
+                                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                               if (tracks) {
+                                       drawStar(st->px + 1, st->py, st->size);
+                               } else {
+                                       drawStar(st->px, st->py, st->size);
+                               }
+                       }
+               }
+
+               for (k = i + 1; k < gp->ngalaxies; ++k) {
+                       Galaxy     *gtk = &gp->galaxies[k];
+                       double      d0 = gtk->pos[0] - gt->pos[0];
+                       double      d1 = gtk->pos[1] - gt->pos[1];
+                       double      d2 = gtk->pos[2] - gt->pos[2];
+
+                       d = d0 * d0 + d1 * d1 + d2 * d2;
+                       if (d > EPSILON)
+                               d = gt->mass * gt->mass / (d * sqrt(d)) * DELTAT * QCONS;
+                       else
+                               d = gt->mass * gt->mass / (EPSILON * sqrt_EPSILON) * DELTAT * QCONS;
+                       d0 *= d;
+                       d1 *= d;
+                       d2 *= d;
+                       gt->vel[0] += d0 / gt->mass;
+                       gt->vel[1] += d1 / gt->mass;
+                       gt->vel[2] += d2 / gt->mass;
+                       gtk->vel[0] -= d0 / gtk->mass;
+                       gtk->vel[1] -= d1 / gtk->mass;
+                       gtk->vel[2] -= d2 / gtk->mass;
+               }
+               gt->pos[0] += gt->vel[0] * DELTAT;
+               gt->pos[1] += gt->vel[1] * DELTAT;
+               gt->pos[2] += gt->vel[2] * DELTAT;
+       }
+
+       gp->step++;
+       if (gp->step > gp->f_hititerations * 4)
+               startover(mi);
+}
+
+void
+release_galaxy(ModeInfo * mi)
+{
+       if (universes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++)
+                       free_galaxies(&universes[screen]);
+               (void) free((void *) universes);
+               universes = NULL;
+       }
+}
+
+void
+refresh_galaxy(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_galaxy */
diff --git a/xlockmore-4.14/modes/glx/Imakefile b/xlockmore-4.14/modes/glx/Imakefile
new file mode 100644 (file)
index 0000000..cb3d4c4
--- /dev/null
@@ -0,0 +1,59 @@
+#ifndef XCOMM
+#define XCOMM /**/#
+#endif
+XCOMM @(#)Sub Imakefile        xlockmore
+XCOMM
+
+#include "../../iconfig.h"
+
+UTILDIR = $(top_srcdir)/xlock/
+MODEDIR = $(top_srcdir)/modes/
+GLDIR = $(top_srcdir)/modes/glx/
+UTILOBJDIR = ../../xlock/
+MODEOBJDIR = ../
+GLOBJDIR = ./
+
+DM =
+DU = $(UTILDIR)
+DOU = $(UTILOBJDIR)
+DG = $(GLDIR)
+DOG = $(GLOBJDIR)
+OM = $(O)$(S)$(DM)
+OU = $(O)$(S)$(DOU)
+OG = $(O)$(S)$(DOG)
+CM = $(C) $(DM)
+CU = $(C) $(DU)
+CG = $(C) $(DG)
+
+XCOMM  List of object files
+#ifdef GLLibrary
+#ifdef XpmLibrary
+#ifdef Unstable
+XLOCKUNSTABLEGLOBJS = $(DOG)lament$(O)
+#endif
+#endif
+XLOCKGLOBJS = $(DOG)cage$(OG)gears$(O)$(S)\
+$(DOG)moebius$(OG)morph3d$(O)$(S)\
+$(DOG)rubik$(OG)stairs$(OG)superquadrics$(O)$(S)\
+$(DOG)buildlwo$(OG)pipes$(OG)pipeobjs$(O)$(S)\
+$(DOG)sproingies$(OG)sproingiewrap$(OG)s1_b$(O)$(S)\
+$(DOG)s1_1$(OG)s1_2$(OG)s1_3$(OG)s1_4$(OG)s1_5$(OG)s1_6$(O)$(S)\
+$(DOG)atlantis$(OG)dolphin$(OG)shark$(OG)swim$(OG)whale$(O)$(S)\
+$(DOG)bubble3d$(OG)b_draw$(OG)b_sphere$(OG)b_lockglue$(O)$(S)\
+$(XLOCKUNSTABLEGLOBJS)
+#endif
+
+XCOMM default target
+all:: $(XLOCKGLOBJS) 
+
+DependTarget()
+
+XLOCKINC = -I. -I../.. -I../../xlock
+
+DependTarget()
+LintTarget()
+
+distclean::    clean
+       $(RM) Makefile config.status config.cache config.log config.h
+
+clean.all:: distclean
diff --git a/xlockmore-4.14/modes/glx/Makefile.in b/xlockmore-4.14/modes/glx/Makefile.in
new file mode 100644 (file)
index 0000000..8f1414b
--- /dev/null
@@ -0,0 +1,418 @@
+# $Id : Makefile.in 4.04 1997/07/10 $
+#
+# xlockmore Makefile.in for autoconf (UNIX/VMS X11 support)
+############################################################
+
+# @SET_MAKE@
+
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@/
+PIXMAPDIR = @PIXMAPDIR@/
+UTILDIR = $(top_srcdir)/xlock/
+MODEDIR = $(top_srcdir)/modes/
+GLDIR = $(top_srcdir)/modes/glx/
+UTILOBJDIR = ../../xlock/
+MODEOBJDIR = ../
+GLOBJDIR = ./
+
+N =
+O = .o
+#O = .obj
+C = .c
+CX = .cc
+S = $(N) $(N)
+#S = ,
+
+DU = $(UTILDIR)
+DOU = $(UTILOBJDIR)
+DG = $(GLDIR)
+DOG = $(GLOBJDIR)
+OU = $(O)$(S)$(DOU)
+OG = $(O)$(S)$(DOG)
+CU = $(C) $(DU)
+CG = $(C) $(DG)
+CXG = $(CX) $(DG)
+
+# please define
+# C as the C source code extension
+# CX as the C++ source code extension
+# O as the object extension
+# S as the separator for object code
+
+@GL@XLOCKGLOBJS = $(DOG)cage$(OG)gears$(O)$(S)\
+@GL@$(DOG)moebius$(OG)morph3d$(O)$(S)\
+@GL@$(DOG)rubik$(OG)stairs$(OG)superquadrics$(O)$(S)\
+@GL@$(DOG)buildlwo$(OG)pipes$(OG)pipeobjs$(O)$(S)\
+@GL@$(DOG)sproingies$(OG)sproingiewrap$(OG)s1_b$(O)$(S)\
+@GL@$(DOG)s1_1$(OG)s1_2$(OG)s1_3$(OG)s1_4$(OG)s1_5$(OG)s1_6$(O)$(S)\
+@GL@$(DOG)atlantis$(OG)dolphin$(OG)shark$(OG)swim$(OG)whale$(O)$(S)\
+@GL@$(DOG)bubble3d$(OG)b_draw$(OG)b_sphere$(OG)b_lockglue$(O)
+@XPM@@GL@XLOCKXPMGLOBJS = $(DOG)lament$(O)
+@CCC@@GL@XLOCKCPPGLOBJS = $(DOG)invert$(OG)i_figureeight$(OG)i_linkage$(O)$(S)\
+@CCC@@GL@$(DOG)i_sphere$(OG)i_spline$(O)$(S)\
+@CCC@@GL@$(DOG)i_threejet$(OG)i_threejetvec$(O)$(S)\
+@CCC@@GL@$(DOG)i_twojet$(OG)i_twojetvec$(O)
+@UNSTABLE@@GL@XLOCKUNSTABLEGLOBJS =
+@UNSTABLE@@CCC@@GL@@GLTT@XLOCKUNSTABLETEXTGLOBJS = $(DOG)text3d$(O)
+@GL@XLOCKGLSRCS = $(DG)cage$(CG)gears$(C) \
+@GL@$(DG)text3d$(CXG)lament$(CG)moebius$(CG)morph3d$(C) \
+@GL@$(DG)rubik$(CG)stairs$(CG)superquadrics$(C) \
+@GL@$(DG)buildlwo$(CG)pipes$(CG)pipeobjs$(C) \
+@GL@$(DG)sproingies$(CG)sproingiewrap$(CG)s1_b$(C) \
+@GL@$(DG)s1_1$(CG)s1_2$(CG)s1_3$(CG)s1_4$(CG)s1_5$(CG)s1_6$(C) \
+@GL@$(DG)atlantis$(CG)dolphin$(CG)shark$(CG)swim$(CG)whale$(C) \
+@GL@$(DG)bubble3d$(CG)b_draw$(CG)b_sphere$(CG)b_lockglue$(CG)text3d$(CX) \
+@GL@$(DG)invert$(CG)i_figureeight$(CXG)i_linkage$(CX) \
+@GL@$(DG)i_sphere$(CXG)i_spline$(CX) \
+@GL@$(DG)i_threejet$(CXG)i_threejetvec$(CX) \
+@GL@$(DG)i_twojet$(CXG)i_twojetvec$(CX)
+# default target
+all : $(XLOCKGLOBJS) $(XLOCKXPMGLOBJS) $(XLOCKCPPGLOBJS) $(XLOCKUNSTABLEGLOBJS) $(XLOCKUNSTABLETEXTGLOBJS)
+
+# this tells GNU make not to export variables into the environment
+# But other makes do not understand its significance, so it must
+# not be the first target in the file. So it is here, before
+# any variables are created, but after the default target
+.NOEXPORT :
+
+SHELL = /bin/sh
+
+prefix = @prefix@
+exec_prefix = @exec_prefix@
+
+bindir = @bindir@
+mandir = @mandir@/man1
+xapploaddir = @APPDEFAULTS@
+
+#CC = cc -g
+#CC = cc -Ac -g
+#CC = cc -Xc -g
+#CC = acc -g
+#CC = CC -g
+#CC = gcc -g -Wall -ansi -pedantic
+#CC = gcc -g -Wall -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wwrite-strings -Waggregate-return -Wmissing-prototypes -Wstrict-prototypes
+#CC = g++ -g -Wall
+CC = @CC@
+CXX = @CXX@
+
+LINT = lint
+#LINT = alint
+
+#DEPEND = makedepend
+DEPEND = @DEPEND@
+DEPEND_FLAGS = @DEPEND_FLAGS@
+DEPEND_DEFINES = @DEPEND_DEFINES@
+
+LN_S = @LN_S@
+RM = rm -f
+RM_S = $(RM)
+ECHO = echo
+
+#BLN_S = set file/enter=[]
+#RM = delete/noconfirm/nolog
+#RM_S = set file/remove/nolog
+#ECHO = write sys$output
+
+DEFINES = -DDEF_FILESEARCHPATH=\"$(xapploaddir)/%N%C%S:$(xapploaddir)/%N%S\"
+DEFS = @DEFS@ $(DEFINES)
+XLOCKINC = -I. -I.. -I../.. -I$(UTILDIR) -I../../.. @XLOCKINC@
+CFLAGS = @CFLAGS@
+CXXFLAGS = @CXXFLAGS@
+#CXXFLAGS = $(CPPFLAGS) $(DEFS) $(XLOCKINC) $(CFLAGS) # Why ???? The rule doesn't
+#CFLAGS = -O
+#CFLAGS = -g
+
+#If you have purify, and want to use it, uncomment this definition or
+# run the make as `make PURIFY=purify'
+# or run configure with the --with-purify argument.
+PURIFY = @PURIFY@
+
+.SUFFIXES : $(C) $(CX) $(O)
+
+$(C)$(O) :
+       $(CC) -c -o $@ $(CPPFLAGS) $(DEFS) $(XLOCKINC) $(CFLAGS) $<
+
+$(CX)$(O) :
+       $(CXX) -c -o $@ $(CPPFLAGS) $(DEFS) $(XLOCKINC) $(CXXFLAGS) $<
+
+install :
+
+install-program :
+
+install-man :
+
+install-ad :
+
+uninstall :
+
+uninstall-program :
+
+uninstall-man :
+
+uninstall-ad :
+
+lint :
+
+xrdb :
+
+man :
+
+html :
+
+hlp :
+
+clean :
+       $(RM) *.o *.xlk core *~ *% *.bak *.orig *.rej make.log MakeOut *.patch
+
+distclean : clean
+       $(RM) Makefile
+
+clean.all : distclean
+
+# Adds all current dependencies to Makefile
+depend :
+       $(DEPEND) -s '# DO NOT DELETE: updated by make depend'              \
+       $(DEPEND_FLAGS) --                                                  \
+       $(XLOCKINC) $(DEFS) $(DEPEND_DEFINES) $(CFLAGS) --                  \
+       $(XLOCKGLSRCS)
+
+# Adds some dependencies to Makefile.in -- not totally accurate, but pretty
+# close.  This excludes dependencies on files in /usr/include, etc.  It tries
+# to include only dependencies on files which are themselves a part of this
+# package.
+distdepend :
+       @echo updating dependencies in `pwd`/Makefile.in... ;               \
+       $(DEPEND) -w 0 -f -                                                 \
+       -s '# DO NOT DELETE: updated by make distdepend' $(DEPEND_FLAGS) -- \
+       $(XLOCKINC) $(DEFS) $(DEPEND_DEFINES) $(CFLAGS) --                  \
+       $(XLOCKGLSRCS) |                                                    \
+       (                                                                   \
+         awk '/^#.*Id : Makefile.in/,/^# DO .*distdepend/' < Makefile.in ; \
+         sed -e 's@ \./@ @g;s@ /[^ ]*@@g;/^.*:$$/d'                        \
+             -e 's@^\.\./\.\./modes/glx@$$(GLOBJDIR)@'                     \
+             -e 's@\.\./\.\./pixmaps@$$(PIXMAPDIR)@g'                      \
+             -e 's@\.\./\.\./xlock@$$(UTILDIR)@g' ;                        \
+         echo ''                                                           \
+       ) > /tmp/distdepend.$$$$ &&                                         \
+       mv Makefile.in Makefile.in.bak &&                                   \
+       mv /tmp/distdepend.$$$$ Makefile.in
+
+##############################################################################
+#
+# DO NOT DELETE: updated by make distdepend
+
+$(GLOBJDIR)/cage.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/cage.o: ../../config.h
+$(GLOBJDIR)/cage.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/cage.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/cage.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/cage.o: e_textures.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/gears.o: ../../config.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/gears.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/text3d.o: ../../config.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/text3d.o: text3d.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/lament.o: ../../config.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/lament.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/lament.o: $(PIXMAPDIR)/lament.xpm
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/moebius.o: ../../config.h
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/moebius.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/moebius.o: e_textures.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/morph3d.o: ../../config.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/morph3d.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/rubik.o: ../../config.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/rubik.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/stairs.o: ../../config.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/stairs.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/stairs.o: e_textures.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/superquadrics.o: ../../config.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/superquadrics.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/buildlwo.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/buildlwo.o: ../../config.h
+$(GLOBJDIR)/buildlwo.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/buildlwo.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/buildlwo.o: buildlwo.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/pipes.o: ../../config.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/pipes.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/pipes.o: buildlwo.h
+$(GLOBJDIR)/pipeobjs.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/pipeobjs.o: ../../config.h
+$(GLOBJDIR)/pipeobjs.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/pipeobjs.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/pipeobjs.o: buildlwo.h
+$(GLOBJDIR)/sproingies.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/sproingies.o: ../../config.h
+$(GLOBJDIR)/sproingies.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/sproingies.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/sproingies.o: buildlwo.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/sproingiewrap.o: ../../config.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/sproingiewrap.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/s1_b.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_b.o: ../../config.h
+$(GLOBJDIR)/s1_b.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_b.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_b.o: buildlwo.h
+$(GLOBJDIR)/s1_1.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_1.o: ../../config.h
+$(GLOBJDIR)/s1_1.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_1.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_1.o: buildlwo.h
+$(GLOBJDIR)/s1_2.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_2.o: ../../config.h
+$(GLOBJDIR)/s1_2.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_2.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_2.o: buildlwo.h
+$(GLOBJDIR)/s1_3.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_3.o: ../../config.h
+$(GLOBJDIR)/s1_3.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_3.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_3.o: buildlwo.h
+$(GLOBJDIR)/s1_4.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_4.o: ../../config.h
+$(GLOBJDIR)/s1_4.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_4.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_4.o: buildlwo.h
+$(GLOBJDIR)/s1_5.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_5.o: ../../config.h
+$(GLOBJDIR)/s1_5.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_5.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_5.o: buildlwo.h
+$(GLOBJDIR)/s1_6.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/s1_6.o: ../../config.h
+$(GLOBJDIR)/s1_6.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/s1_6.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/s1_6.o: buildlwo.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/atlantis.o: ../../config.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/atlantis.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/atlantis.o: atlantis.h
+$(GLOBJDIR)/dolphin.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/dolphin.o: ../../config.h
+$(GLOBJDIR)/dolphin.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/dolphin.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/dolphin.o: atlantis.h
+$(GLOBJDIR)/shark.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/shark.o: ../../config.h
+$(GLOBJDIR)/shark.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/shark.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/shark.o: atlantis.h
+$(GLOBJDIR)/swim.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/swim.o: ../../config.h
+$(GLOBJDIR)/swim.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/swim.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/swim.o: atlantis.h
+$(GLOBJDIR)/whale.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/whale.o: ../../config.h
+$(GLOBJDIR)/whale.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/whale.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/whale.o: atlantis.h
+$(GLOBJDIR)/bubble3d.o: bubble3d.h
+$(GLOBJDIR)/bubble3d.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/bubble3d.o: ../../config.h
+$(GLOBJDIR)/bubble3d.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/bubble3d.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/b_draw.o: bubble3d.h
+$(GLOBJDIR)/b_draw.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/b_draw.o: ../../config.h
+$(GLOBJDIR)/b_draw.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/b_draw.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/b_sphere.o: bubble3d.h
+$(GLOBJDIR)/b_sphere.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/b_sphere.o: ../../config.h
+$(GLOBJDIR)/b_sphere.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/b_sphere.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/b_lockglue.o: bubble3d.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/b_lockglue.o: ../../config.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/b_lockglue.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/text3d.o: ../../config.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/text3d.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/text3d.o: text3d.h
+$(GLOBJDIR)/invert.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/invert.o: ../../config.h
+$(GLOBJDIR)/invert.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/invert.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/invert.o: $(UTILDIR)/vis.h
+$(GLOBJDIR)/invert.o: i_linkage.h
+$(GLOBJDIR)/i_figureeight.o: i_figureeight.h
+$(GLOBJDIR)/i_figureeight.o: i_threejetvec.h
+$(GLOBJDIR)/i_figureeight.o: i_threejet.h
+$(GLOBJDIR)/i_figureeight.o: i_twojet.h
+$(GLOBJDIR)/i_figureeight.o: i_twojetvec.h
+$(GLOBJDIR)/i_linkage.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/i_linkage.o: ../../config.h
+$(GLOBJDIR)/i_linkage.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/i_linkage.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/i_linkage.o: i_linkage.h
+$(GLOBJDIR)/i_linkage.o: i_threejetvec.h
+$(GLOBJDIR)/i_linkage.o: i_threejet.h
+$(GLOBJDIR)/i_linkage.o: i_twojet.h
+$(GLOBJDIR)/i_linkage.o: i_twojetvec.h
+$(GLOBJDIR)/i_linkage.o: i_figureeight.h
+$(GLOBJDIR)/i_linkage.o: i_spline.h
+$(GLOBJDIR)/i_linkage.o: i_sphere.h
+$(GLOBJDIR)/i_sphere.o: i_threejetvec.h
+$(GLOBJDIR)/i_sphere.o: i_threejet.h
+$(GLOBJDIR)/i_sphere.o: i_twojet.h
+$(GLOBJDIR)/i_sphere.o: i_twojetvec.h
+$(GLOBJDIR)/i_sphere.o: i_figureeight.h
+$(GLOBJDIR)/i_sphere.o: i_spline.h
+$(GLOBJDIR)/i_sphere.o: i_sphere.h
+$(GLOBJDIR)/i_spline.o: $(UTILDIR)/xlock.h
+$(GLOBJDIR)/i_spline.o: ../../config.h
+$(GLOBJDIR)/i_spline.o: $(UTILDIR)/mode.h
+$(GLOBJDIR)/i_spline.o: $(UTILDIR)/random.h
+$(GLOBJDIR)/i_spline.o: i_spline.h
+$(GLOBJDIR)/i_spline.o: i_threejetvec.h
+$(GLOBJDIR)/i_spline.o: i_threejet.h
+$(GLOBJDIR)/i_spline.o: i_twojet.h
+$(GLOBJDIR)/i_spline.o: i_twojetvec.h
+$(GLOBJDIR)/i_spline.o: i_evert.h
+$(GLOBJDIR)/i_threejet.o: i_threejet.h
+$(GLOBJDIR)/i_threejet.o: i_twojet.h
+$(GLOBJDIR)/i_threejetvec.o: i_threejetvec.h
+$(GLOBJDIR)/i_threejetvec.o: i_threejet.h
+$(GLOBJDIR)/i_threejetvec.o: i_twojet.h
+$(GLOBJDIR)/i_threejetvec.o: i_twojetvec.h
+$(GLOBJDIR)/i_twojet.o: i_twojet.h
+$(GLOBJDIR)/i_twojetvec.o: i_twojetvec.h
+$(GLOBJDIR)/i_twojetvec.o: i_twojet.h
+
diff --git a/xlockmore-4.14/modes/glx/atlantis.c b/xlockmore-4.14/modes/glx/atlantis.c
new file mode 100644 (file)
index 0000000..04e7892
--- /dev/null
@@ -0,0 +1,444 @@
+/* atlantis --- Shows moving 3D sea animals */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)atlantis.c   1.3 98/06/18 xlockmore";
+
+#endif
+
+/* Copyright (c) E. Lassauge, 1998. */
+
+/*
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The original code for this mode was written by Mark J. Kilgard
+ * as a demo for openGL programming.
+ * 
+ * Porting it to xlock  was possible by comparing the original Mesa's morph3d 
+ * demo with it's ported version to xlock, so thanks for Marcelo F. Vianna 
+ * (look at morph3d.c) for his indirect help.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * My e-mail address is lassauge@sagem.fr
+ *
+ * Eric Lassauge  (May-13-1998)
+ *
+ * REVISION HISTORY:
+ * 
+ * David A. Bagley - 98/06/17 : Add whalespeed option. Global options to
+ *                              initialize local variables are now:
+ *                              XLock.atlantis.cycles: 100      ! SharkSpeed
+ *                              XLock.atlantis.batchcount: 4    ! SharkNum
+ *                              XLock.atlantis.whalespeed: 250  ! WhaleSpeed
+ *                              XLock.atlantis.size: 6000       ! SharkSize
+ *                              Add random direction for whales/dolphins
+ * 
+ * E.Lassauge - 98/06/16: Use the following global options to initialize
+ *                        local variables :
+ *                              XLock.atlantis.delay: 100       ! SharkSpeed
+ *                              XLock.atlantis.batchcount: 4    ! SharkNum
+ *                              XLock.atlantis.cycles: 250      ! WhaleSpeed
+ *                              XLock.atlantis.size: 6000       ! SharkSize
+ *                        Add support for -/+ wireframe (t'was so easy to do!)
+ *
+ * TODO : 
+ *        - add a sort of background image or random bg color
+ *        - better handling of sizes and speeds
+ *        - test standalone and module modes
+ *        - purify it (!)
+ */
+
+/* Copyright (c) Mark J. Kilgard, 1994. */
+
+/**
+ * (c) Copyright 1993, 1994, Silicon Graphics, Inc.
+ * ALL RIGHTS RESERVED
+ * Permission to use, copy, modify, and distribute this software for
+ * any purpose and without fee is hereby granted, provided that the above
+ * copyright notice appear in all copies and that both the copyright notice
+ * and this permission notice appear in supporting documentation, and that
+ * the name of Silicon Graphics, Inc. not be used in advertising
+ * or publicity pertaining to distribution of the software without specific,
+ * written prior permission.
+ *
+ * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
+ * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
+ * FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
+ * GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
+ * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
+ * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
+ * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
+ * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
+ * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
+ * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * US Government Users Restricted Rights
+ * Use, duplication, or disclosure by the Government is subject to
+ * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
+ * (c)(1)(ii) of the Rights in Technical Data and Computer Software
+ * clause at DFARS 252.227-7013 and/or in similar or successor
+ * clauses in the FAR or the DOD or NASA FAR Supplement.
+ * Unpublished-- rights reserved under the copyright laws of the
+ * United States.  Contractor/manufacturer is Silicon Graphics,
+ * Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
+ *
+ * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Atlantis"
+#define HACK_INIT init_atlantis
+#define HACK_DRAW draw_atlantis
+#define atlantis_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: 4 \n" \
+ "*cycles: 100 \n" \
+ "*size: 6000 \n" \
+ "*whalespeed: 250\n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_atlantis
+
+#include "atlantis.h"
+#include <GL/glu.h>
+
+#define DEF_WHALESPEED  "250"
+static int  whalespeed;
+static XrmOptionDescRec opts[] =
+{
+     {"-whalespeed", ".atlantis.whalespeed", XrmoptionSepArg, (caddr_t) NULL}
+};
+
+static argtype vars[] =
+{
+{(caddr_t *) & whalespeed, "whalespeed", "WhaleSpeed", DEF_WHALESPEED, t_Int}
+};
+
+static OptionStruct desc[] =
+{
+       {"-whalespeed num", "speed of whales and the dolphin"}
+};
+
+ModeSpecOpt atlantis_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   atlantis_description =
+{"atlantis", "init_atlantis", "draw_atlantis", "release_atlantis",
+ "refresh_atlantis", "change_atlantis", NULL, &atlantis_opts,
+ 1000, NUM_SHARKS, SHARKSPEED, SHARKSIZE, 64, 1.0, "",
+ "Shows moving sharks/whales/dolphin", 0, NULL};
+
+#endif
+
+static atlantisstruct *atlantis = NULL;
+
+static void
+InitFishs(atlantisstruct * ap)
+{
+       int         i;
+
+       for (i = 0; i < ap->num_sharks; i++) {
+               ap->sharks[i].x = 70000.0 + NRAND(ap->sharksize);
+               ap->sharks[i].y = NRAND(ap->sharksize);
+               ap->sharks[i].z = NRAND(ap->sharksize);
+               ap->sharks[i].psi = NRAND(360) - 180.0;
+               ap->sharks[i].v = 1.0;
+       }
+
+       /* Random whae direction */
+       ap->whaledir = LRAND() & 1;
+
+       ap->dolph.x = 30000.0;
+       ap->dolph.y = 0.0;
+       ap->dolph.z = (float) (ap->sharksize);
+       ap->dolph.psi = (ap->whaledir) ? 90.0 : -90.0;
+       ap->dolph.theta = 0.0;
+       ap->dolph.v = 6.0;
+
+       ap->momWhale.x = 70000.0;
+       ap->momWhale.y = 0.0;
+       ap->momWhale.z = 0.0;
+       ap->momWhale.psi = (ap->whaledir) ? 90.0 : -90.0;
+       ap->momWhale.theta = 0.0;
+       ap->momWhale.v = 3.0;
+
+       ap->babyWhale.x = 60000.0;
+       ap->babyWhale.y = -2000.0;
+       ap->babyWhale.z = -2000.0;
+       ap->babyWhale.psi = (ap->whaledir) ? 90.0 : -90.0;
+       ap->babyWhale.theta = 0.0;
+       ap->babyWhale.v = 3.0;
+}
+
+static void
+Init(atlantisstruct * ap)
+{
+       static float ambient[] =
+       {0.1, 0.1, 0.1, 1.0};
+       static float diffuse[] =
+       {1.0, 1.0, 1.0, 1.0};
+       static float position[] =
+       {0.0, 1.0, 0.0, 0.0};
+       static float mat_shininess[] =
+       {90.0};
+       static float mat_specular[] =
+       {0.8, 0.8, 0.8, 1.0};
+       static float mat_diffuse[] =
+       {0.46, 0.66, 0.795, 1.0};
+       static float mat_ambient[] =
+       {0.0, 0.1, 0.2, 1.0};
+       static float lmodel_ambient[] =
+       {0.4, 0.4, 0.4, 1.0};
+       static float lmodel_localviewer[] =
+       {0.0};
+       float       fblue = 0.0, fgreen;
+
+       glFrontFace(GL_CW);
+
+       glDepthFunc(GL_LEQUAL);
+       glEnable(GL_DEPTH_TEST);
+
+       glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT0, GL_POSITION, position);
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lmodel_ambient);
+       glLightModelfv(GL_LIGHT_MODEL_LOCAL_VIEWER, lmodel_localviewer);
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, mat_shininess);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, mat_specular);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mat_diffuse);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, mat_ambient);
+
+       InitFishs(ap);
+
+       /* Add a little randomness */
+       fblue = ((float) (NRAND(50)) / 100.0) + 0.50;
+       fgreen = fblue * 0.56;
+       glClearColor(0.0, fgreen, fblue, 0.0);
+}
+
+static void
+Reshape(ModeInfo * mi, int width, int height)
+{
+       atlantisstruct *ap = &atlantis[MI_SCREEN(mi)];
+
+       glViewport(0, 0, ap->WinW = (GLint) width, ap->WinH = (GLint) height);
+
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       gluPerspective(400.0, (GLdouble) width / (GLdouble) height, 1.0, 2000000.0);
+       glMatrixMode(GL_MODELVIEW);
+}
+
+static void
+Animate(atlantisstruct * ap)
+{
+       int         i;
+
+       for (i = 0; i < ap->num_sharks; i++) {
+               SharkPilot(&(ap->sharks[i]), ap->sharkspeed);
+               SharkMiss(ap, i);
+       }
+       WhalePilot(&(ap->dolph), ap->whalespeed, ap->whaledir);
+       ap->dolph.phi++;
+       WhalePilot(&(ap->momWhale), ap->whalespeed, ap->whaledir);
+       ap->momWhale.phi++;
+       WhalePilot(&(ap->babyWhale), ap->whalespeed, ap->whaledir);
+       ap->babyWhale.phi++;
+}
+
+static void
+AllDisplay(atlantisstruct * ap)
+{
+       int         i;
+
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       for (i = 0; i < ap->num_sharks; i++) {
+               glPushMatrix();
+               FishTransform(&(ap->sharks[i]));
+               DrawShark(&(ap->sharks[i]), ap->wire);
+               glPopMatrix();
+       }
+
+       glPushMatrix();
+       FishTransform(&(ap->dolph));
+       DrawDolphin(&(ap->dolph), ap->wire);
+       glPopMatrix();
+
+       glPushMatrix();
+       FishTransform(&(ap->momWhale));
+       DrawWhale(&(ap->momWhale), ap->wire);
+       glPopMatrix();
+
+       glPushMatrix();
+       FishTransform(&(ap->babyWhale));
+       glScalef(0.45, 0.45, 0.3);
+       DrawWhale(&(ap->babyWhale), ap->wire);
+       glPopMatrix();
+}
+
+/*
+ *-----------------------------------------------------------------------------
+ *-----------------------------------------------------------------------------
+ *    Xlock hooks.
+ *-----------------------------------------------------------------------------
+ *-----------------------------------------------------------------------------
+ */
+
+/*
+ *-----------------------------------------------------------------------------
+ *    Initialize atlantis.  Called each time the window changes.
+ *-----------------------------------------------------------------------------
+ */
+
+void
+init_atlantis(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       atlantisstruct *ap;
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       if (atlantis == NULL) {
+               if ((atlantis = (atlantisstruct *) calloc(MI_NUM_SCREENS(mi),
+                                          sizeof (atlantisstruct))) == NULL)
+                       return;
+       }
+       ap = &atlantis[screen];
+       ap->num_sharks = MI_COUNT(mi);
+       if (ap->sharks == NULL) {
+               if ((ap->sharks = (fishRec *) calloc(ap->num_sharks,
+                                               sizeof (fishRec))) == NULL) {
+                       /* free everything up to now */
+                       (void) free((void *) atlantis);
+                       atlantis = NULL;
+                       return;
+               }
+       }
+       ap->sharkspeed = MI_CYCLES(mi);         /* has influence on the "width"
+                                                  of the movement */
+       ap->sharksize = MI_SIZE(mi);    /* has influence on the "distance"
+                                          of the sharks */
+       ap->whalespeed = whalespeed;
+       ap->wire = MI_IS_WIREFRAME(mi);
+
+       if (MI_IS_DEBUG(mi)) {
+               (void) fprintf(stderr,
+                              "%s:\n\tnum_sharks=%d\n\tsharkspeed=%.1f\n\tsharksize=%d\n\twhalespeed=%.1f\n\twireframe=%s\n",
+                              MI_NAME(mi),
+                              ap->num_sharks,
+                              ap->sharkspeed,
+                              ap->sharksize,
+                              ap->whalespeed,
+                              ap->wire ? "yes" : "no"
+                       );
+       }
+       if ((ap->glx_context = init_GL(mi)) != NULL) {
+
+               Reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+               glDrawBuffer(GL_BACK);
+               Init(ap);
+               AllDisplay(ap);
+               glXSwapBuffers(display, window);
+
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+/*
+ *-----------------------------------------------------------------------------
+ *    Called by the mainline code periodically to update the display.
+ *-----------------------------------------------------------------------------
+ */
+void
+draw_atlantis(ModeInfo * mi)
+{
+       atlantisstruct *ap = &atlantis[MI_SCREEN(mi)];
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!ap->glx_context)
+               return;
+
+       glXMakeCurrent(display, window, *(ap->glx_context));
+
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       glPushMatrix();
+
+       AllDisplay(ap);
+       Animate(ap);
+
+       glXSwapBuffers(display, window);
+}
+
+
+/*
+ *-----------------------------------------------------------------------------
+ *    The display is being taken away from us.  Free up malloc'ed 
+ *      memory and X resources that we've alloc'ed.  Only called
+ *      once, we must zap everything for every screen.
+ *-----------------------------------------------------------------------------
+ */
+
+void
+release_atlantis(ModeInfo * mi)
+{
+       int         screen;
+
+       if (atlantis != NULL) {
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       atlantisstruct *ap = &atlantis[screen];
+
+                       if (ap->sharks)
+                               (void) free((void *) ap->sharks);
+               }
+               (void) free((void *) atlantis);
+               atlantis = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+void
+refresh_atlantis(ModeInfo * mi)
+{
+}
+
+void
+change_atlantis(ModeInfo * mi)
+{
+       atlantisstruct *ap = &atlantis[MI_SCREEN(mi)];
+
+       if (!ap->glx_context)
+               return;
+
+       glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(ap->glx_context));
+       Init(ap);
+}
+
+#endif /* MODE_atlantis */
diff --git a/xlockmore-4.14/modes/glx/atlantis.h b/xlockmore-4.14/modes/glx/atlantis.h
new file mode 100644 (file)
index 0000000..b3d4d77
--- /dev/null
@@ -0,0 +1,115 @@
+#if !defined( lint ) && !defined( SABER )
+/* #ident      "@(#)atlantis.h 4.14 99/06/17 xlockmore" */
+
+#endif
+
+/*-
+ * atlantis stuff --- Shows moving 3D sea animals
+ *
+ * Copyright (c) E. Lassauge, 1998.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The original code for this mode was written by Mark J. Kilgard
+ * as a demo for openGL programming.
+ * 
+ * Porting it to xlock  was possible by comparing the original Mesa's morph3d 
+ * demo with it's ported version to xlock, so thanks for Marcelo F. Vianna 
+ * (look at morph3d.c) for his indirect help.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * My e-mail address is lassauge@sagem.fr
+ *
+ * Revision History:
+ * Eric Lassauge  (May-13-1998)
+ *
+ */
+
+/**
+ * (c) Copyright 1993, 1994, Silicon Graphics, Inc.
+ * ALL RIGHTS RESERVED
+ * Permission to use, copy, modify, and distribute this software for
+ * any purpose and without fee is hereby granted, provided that the above
+ * copyright notice appear in all copies and that both the copyright notice
+ * and this permission notice appear in supporting documentation, and that
+ * the name of Silicon Graphics, Inc. not be used in advertising
+ * or publicity pertaining to distribution of the software without specific,
+ * written prior permission.
+ *
+ * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
+ * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
+ * FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
+ * GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
+ * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
+ * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
+ * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
+ * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
+ * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
+ * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * US Government Users Restricted Rights
+ * Use, duplication, or disclosure by the Government is subject to
+ * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
+ * (c)(1)(ii) of the Rights in Technical Data and Computer Software
+ * clause at DFARS 252.227-7013 and/or in similar or successor
+ * clauses in the FAR or the DOD or NASA FAR Supplement.
+ * Unpublished-- rights reserved under the copyright laws of the
+ * United States.  Contractor/manufacturer is Silicon Graphics,
+ * Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
+ *
+ * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
+ */
+#include <GL/gl.h>
+#include <GL/glx.h>
+
+#define RAD 57.295
+#define RRAD 0.01745
+
+/* default values */
+#define NUM_SHARKS 4
+#define SHARKSPEED 100
+#define SHARKSIZE 6000
+
+typedef struct _fishRec {
+       float       x, y, z, phi, theta, psi, v;
+       float       xt, yt, zt;
+       float       htail, vtail;
+       float       dtheta;
+       int         spurt, attack;
+} fishRec;
+
+typedef struct {
+       GLint       WinH, WinW;
+       GLXContext *glx_context;
+       int         num_sharks;
+       float       sharkspeed, whalespeed;
+       int         sharksize;
+       int         wire;
+       Bool        whaledir;
+       fishRec    *sharks;
+       fishRec     momWhale;
+       fishRec     babyWhale;
+       fishRec     dolph;
+} atlantisstruct;
+
+extern void FishTransform(fishRec *);
+extern void WhalePilot(fishRec *, float, Bool);
+extern void SharkPilot(fishRec *, float);
+extern void SharkMiss(atlantisstruct *, int);
+extern void DrawWhale(fishRec *, int);
+extern void DrawShark(fishRec *, int);
+extern void DrawDolphin(fishRec *, int);
diff --git a/xlockmore-4.14/modes/glx/b_draw.c b/xlockmore-4.14/modes/glx/b_draw.c
new file mode 100644 (file)
index 0000000..18c89d9
--- /dev/null
@@ -0,0 +1,260 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)b_draw.c  4.11 98/06/16 xlockmore";
+
+#endif
+
+/*-
+ * BUBBLE3D (C) 1998 Richard W.M. Jones.
+ * b_draw.c: This code creates new bubbles, manages them and controls
+ * them as they are drawn on the screen.
+ */
+
+#include "bubble3d.h"
+
+typedef struct draw_context {
+       /* The list of bubbles currently on the screen. */
+       void      **bubble_list;
+       int         nr_bubbles;
+
+       /* When was the last time we created a new bubble? */
+       int         bubble_count;
+} draw_context;
+
+void       *
+glb_draw_init(void)
+{
+       draw_context *c;
+
+       GLfloat     mat_specular[] =
+       {1, 1, 1, 1};
+       GLfloat     mat_emission[] =
+       {0, 0, 0, 1};
+       GLfloat     mat_shininess[] =
+       {100};
+       GLfloat     ambient[] =
+       {0.5, 0.5, 0.5, 1.0};
+       GLfloat     light_position[][4] =
+       {
+               {0, -1, 0, 0},
+               {1, 1, 0, 0},
+               {-1, 0, 1, 0}};
+       GLfloat     light_diffuse[][4] =
+       {
+               {1, 1, 1, 1},
+               {1, 1, 1, 1},
+               {1, 1, 1, 1}};
+       GLfloat     light_specular[][4] =
+       {
+               {1, 1, 1, 1},
+               {1, 1, 1, 1},
+               {1, 1, 1, 1}};
+
+       /* Initialize the context. */
+       c = (struct draw_context *) malloc(sizeof (struct draw_context));
+
+       if (c == 0)
+               return 0;
+       c->bubble_list = 0;
+       c->nr_bubbles = 0;
+       c->bubble_count = glb_config.create_bubbles_every;
+
+       /* Do some GL initialization. */
+       glClearColor(glb_config.bg_colour[0],
+                    glb_config.bg_colour[1],
+                    glb_config.bg_colour[2],
+                    glb_config.bg_colour[3]);
+#if 0
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, glb_config.bubble_colour);
+#else
+       {
+               /* 
+                * E. Lassauge - 98/06/29
+                * Yeahh, cool ! Now that I know how to have random colors I 
+                * patch this pretty beautiful mode too !!
+                */
+               GLfloat     fred, fgreen, fblue;
+               GLfloat     params[4];
+
+               fred = ((float) (NRAND(100)) / 100.0);
+               fgreen = ((float) (NRAND(100)) / 100.0);
+               /* I keep more blue */
+               fblue = ((float) (NRAND(50)) / 100.0) + 0.50;
+
+               params[0] = fred;
+               params[1] = fgreen;
+               params[2] = fblue;
+               /* For the moment don't play with ALPHA channel */
+               params[3] = glb_config.bubble_colour[3];
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, params);
+       }
+#endif
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, mat_specular);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_EMISSION, mat_emission);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, mat_shininess);
+
+#if GLB_USE_BLENDING
+       glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+#endif
+
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+       glEnable(GL_LIGHT1);
+       glEnable(GL_LIGHT2);
+#if GLB_USE_BLENDING
+       glEnable(GL_BLEND);
+#else
+       glEnable(GL_DEPTH_TEST);
+#endif
+       glEnable(GL_AUTO_NORMAL);
+       glEnable(GL_NORMALIZE);
+
+#if GLB_USE_BLENDING
+       glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_TRUE);
+#endif
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT0, GL_POSITION, light_position[0]);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, light_diffuse[0]);
+       glLightfv(GL_LIGHT0, GL_SPECULAR, light_specular[0]);
+       glLightfv(GL_LIGHT1, GL_POSITION, light_position[1]);
+       glLightfv(GL_LIGHT1, GL_DIFFUSE, light_diffuse[1]);
+       glLightfv(GL_LIGHT1, GL_SPECULAR, light_specular[1]);
+       glLightfv(GL_LIGHT2, GL_POSITION, light_position[2]);
+       glLightfv(GL_LIGHT2, GL_DIFFUSE, light_diffuse[2]);
+       glLightfv(GL_LIGHT2, GL_SPECULAR, light_specular[2]);
+
+       return c;
+}
+
+static void
+delete_bubble(draw_context * c, int j)
+{
+       int         i;
+
+       glb_bubble_delete(c->bubble_list[j]);
+
+       for (i = j; i < c->nr_bubbles - 1; ++i)
+               c->bubble_list[i] = c->bubble_list[i + 1];
+
+       c->nr_bubbles--;
+}
+
+void
+glb_draw_end(void *cc)
+{
+       draw_context *c = (draw_context *) cc;
+       int         i;
+
+       for (i = 0; i < c->nr_bubbles; ++i) {
+               delete_bubble(c, i);
+               i--;
+       }
+       (void) free((void *) c->bubble_list);
+       (void) free((void *) c);
+}
+
+static int
+create_new_bubbles(draw_context * c)
+{
+       int         n, i;
+       double      r = glb_drand();
+       GLfloat     size, speed, scale_incr, x, y, z;
+       void       *b[4];
+       void      **old_bubble_list;
+
+       /* How many bubbles to make? */
+       if (r < glb_config.p_bubble_group[0])
+               n = 1;
+       else if (r < glb_config.p_bubble_group[1])
+               n = 2;
+       else if (r < glb_config.p_bubble_group[2])
+               n = 3;
+       else
+               n = 4;
+
+       /* Initial position of top-most bubble in group. */
+       x = glb_drand() * 4 - 2;
+       y = glb_config.screen_bottom;
+       z = glb_drand() * 2 - 2;
+
+       /* What size? */
+       size = glb_config.min_size
+               + glb_drand() * (glb_config.max_size - glb_config.min_size);
+
+       /* What speed? */
+       speed = glb_config.min_speed
+               + glb_drand() * (glb_config.max_speed - glb_config.min_speed);
+
+       /* Work out the scaling increment. Bubbles should increase by scale_factor
+        * as they go from bottom to top of screen.
+        */
+       scale_incr = (size * glb_config.scale_factor - size)
+               / ((glb_config.screen_top - glb_config.screen_bottom) / speed);
+
+       /* Create the bubble(s). */
+       for (i = 0; i < n; ++i) {
+               if ((b[i] = glb_bubble_new(x, y, z, size, speed, scale_incr)) == 0) {
+                       /* Out of memory - recover. */
+                       i--;
+                       while (i >= 0)
+                               glb_bubble_delete(b[i]);
+                       return 0;
+               }
+               /* Create the next bubble below the last bubble. */
+               y -= size * 3;
+       }
+
+       /* Add the bubbles to the list. */
+       c->nr_bubbles += n;
+       old_bubble_list = c->bubble_list;
+       if (c->bubble_list == 0) {
+               c->bubble_list = (void **) malloc(c->nr_bubbles * sizeof (void *));
+       } else {
+               c->bubble_list = (void **) realloc(c->bubble_list,
+                                           c->nr_bubbles * sizeof (void *));
+       }
+
+       if (c->bubble_list == 0) {
+               /* Out of memory - recover. */
+               for (i = 0; i < n; ++i)
+                       glb_bubble_delete(b[i]);
+               c->bubble_list = old_bubble_list;
+               c->nr_bubbles -= n;
+               return 0;
+       }
+       for (i = 0; i < n; ++i)
+               c->bubble_list[c->nr_bubbles - i - 1] = b[i];
+
+       return 1;
+}
+
+void
+glb_draw_step(void *cc)
+{
+       draw_context *c = (draw_context *) cc;
+       int         i;
+
+       /* Consider creating a new bubble or bubbles. */
+       if (c->nr_bubbles < glb_config.max_bubbles &&
+           c->bubble_count++ > glb_config.create_bubbles_every) {
+               if (create_new_bubbles(c))
+                       c->bubble_count = 0;
+       }
+       /* Clear the display. */
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       /* XXX Draw the background here ... */
+
+       /* Draw all the bubbles on the display. */
+       for (i = 0; i < c->nr_bubbles; ++i) {
+               void       *b = c->bubble_list[i];
+
+               glb_bubble_step(b);
+               glb_bubble_draw(b);
+
+               /* Has the bubble reached the top of the screen? */
+               if (glb_bubble_get_y(b) >= glb_config.screen_top) {
+                       delete_bubble(c, i);
+                       i--;
+               }
+       }
+}
diff --git a/xlockmore-4.14/modes/glx/b_lockglue.c b/xlockmore-4.14/modes/glx/b_lockglue.c
new file mode 100644 (file)
index 0000000..36723b0
--- /dev/null
@@ -0,0 +1,180 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)b_lockglue.c  4.11 98/06/16 xlockmore";
+
+#endif
+
+/*-
+ * BUBBLE3D (C) 1998 Richard W.M. Jones.
+ * b_lockglue.c: Glue to make this all work with xlockmore.
+ */
+
+#include "bubble3d.h"
+
+/* XXX This lot should eventually be made configurable using the
+ * options stuff below.
+ */
+struct glb_config glb_config =
+{
+#if GLB_SLOW_GL
+       2,                      /* subdivision_depth */
+#else
+       3,                      /* subdivision_depth */
+#endif
+       5,                      /* nr_nudge_axes */
+       0.3,                    /* nudge_angle_factor */
+       0.15,                   /* nudge_factor */
+       0.1,                    /* rotation_factor */
+       8,                      /* create_bubbles_every */
+       8,                      /* max_bubbles */
+       {0.7, 0.8, 0.9, 1.0},   /* p_bubble_group */
+       0.5,                    /* max_size */
+       0.1,                    /* min_size */
+       0.1,                    /* max_speed */
+       0.03,                   /* min_speed */
+       1.5,                    /* scale_factor */
+       -4,                     /* screen_bottom */
+       4,                      /* screen_top */
+#if 0
+       {0.1, 0.0, 0.4, 0.0},   /* bg_colour */
+#else
+       {0.0, 0.0, 0.0, 0.0},   /* bg_colour */
+#endif
+#if 0
+       {0.7, 0.7, 0.0, 0.3}    /* bubble_colour */
+#else
+       {0.0, 0.0, 0.7, 0.3}    /* bubble_colour */
+#endif
+};
+
+#ifdef STANDALONE
+#define PROGCLASS "Bubble3D"
+#define HACK_INIT init_bubble3d
+#define HACK_DRAW draw_bubble3d
+#define bubble3d_opts xlockmore_opts
+#include "xlockmore.h"
+#else
+#include "xlock.h"
+#include "vis.h"
+#endif
+
+#ifdef MODE_bubble3d
+
+ModeSpecOpt bubble3d_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   bubbles3d_description =
+{"bubbles3d",
+ "init_bubble3d",
+ "draw_bubble3d",
+ "release_bubble3d",
+ "change_bubble3d",
+ "init_bubble3d",
+ NULL,
+ &bubble3d_opts,
+ 1000, 1, 2, 1, 64, 1.0, "",
+ "Richard Jones's GL bubbles",
+ 0,
+ NULL
+};
+
+#endif /* USE_MODULES */
+
+struct context {
+       GLXContext *glx_context;
+       void       *draw_context;
+};
+
+static struct context *contexts = 0;
+
+static void
+init(struct context *c)
+{
+       glb_sphere_init();
+       c->draw_context = glb_draw_init();
+}
+
+static void
+reshape(int w, int h)
+{
+       glViewport(0, 0, (GLsizei) w, (GLsizei) h);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       gluPerspective(45, (GLdouble) w / (GLdouble) h, 3, 8);
+       glMatrixMode(GL_MODELVIEW);
+       glLoadIdentity();
+       glTranslatef(0, 0, -5);
+}
+
+static void
+do_display(struct context *c)
+{
+       glb_draw_step(c->draw_context);
+}
+
+void
+init_bubble3d(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         screen = MI_SCREEN(mi);
+       struct context *c;
+
+       if (contexts == 0) {
+               contexts = (struct context *) malloc(sizeof (struct context) * MI_NUM_SCREENS(mi));
+
+               if (contexts == 0)
+                       return;
+       }
+       c = &contexts[screen];
+       c->glx_context = init_GL(mi);
+       if (c->glx_context != 0) {
+               init(c);
+               reshape(MI_WIDTH(mi), MI_HEIGHT(mi));
+               do_display(c);
+               glFinish();
+               glXSwapBuffers(display, window);
+       } else
+               MI_CLEARWINDOW(mi);
+}
+
+void
+draw_bubble3d(ModeInfo * mi)
+{
+       struct context *c = &contexts[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!c->glx_context)
+               return;
+
+       glXMakeCurrent(display, window, *(c->glx_context));
+
+       do_display(c);
+
+       glFinish();
+       glXSwapBuffers(display, window);
+}
+
+void
+change_bubble3d(ModeInfo * mi)
+{
+       /* nothing */
+}
+
+void
+release_bubble3d(ModeInfo * mi)
+{
+       struct context *c = &contexts[MI_SCREEN(mi)];
+
+       if (contexts != 0) {
+               glb_draw_end(c->draw_context);
+               (void) free((void *) contexts);
+               contexts = 0;
+       }
+       FreeAllGL(mi);
+}
+
+#endif /* MODE_bubble3d */
diff --git a/xlockmore-4.14/modes/glx/b_sphere.c b/xlockmore-4.14/modes/glx/b_sphere.c
new file mode 100644 (file)
index 0000000..2f8b25f
--- /dev/null
@@ -0,0 +1,231 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)b_sphere.c  4.11 98/06/16 xlockmore";
+
+#endif
+
+/*-
+ * BUBBLE3D (C) 1998 Richard W.M. Jones.
+ * b_sphere.c: Create a list of vertices and triangles in a
+ * normalized sphere, which is then later used as the basic shape
+ * for all bubbles. This code is run once when the program starts
+ * up.
+ */
+
+#include "bubble3d.h"
+
+/* The list of vertices created. */
+typedef glb_vertex vertex;
+static vertex *vertices = 0;
+static int  nr_vertices = 0, nr_vertices_allocated = 0;
+
+/* The list of triangles created. */
+typedef glb_triangle triangle;
+static triangle *triangles = 0;
+static int  nr_triangles = 0, nr_triangles_allocated = 0;
+
+/* Have we initialized the lists yet? */
+static int  initialized = 0;
+
+#define EPSILON GLB_VERTICES_EPSILON
+
+/* Should be taken care of already... but just in case */
+#if !defined( __GNUC__ ) && !defined(__cplusplus) && !defined(c_plusplus)
+#undef inline
+#define inline                 /* */
+#endif
+static inline int
+close_enough(GLfloat * v1, GLfloat * v2)
+{
+       return fabs((double) (v1[0] - v2[0])) <= EPSILON &&
+               fabs((double) (v1[1] - v2[1])) <= EPSILON &&
+               fabs((double) (v1[2] - v2[2])) <= EPSILON;
+}
+
+#define INCR(n) ((n == 0) ? (n = 1) : (n *= 2))
+#define INCR_ALLOCATION(a, n, t) (a = (t *) realloc (a, INCR (n) * sizeof (t)))
+
+static inline GLuint
+save_vertex(GLfloat * v)
+{
+       int         i;
+
+       /* Inefficient, but we only do this a few times. Check to see if there's
+        * an existing vertex which is `close enough' to this one.
+        */
+       for (i = 0; i < nr_vertices; ++i)
+               if (close_enough(v, vertices[i]))
+                       return i;
+
+       if (nr_vertices_allocated <= nr_vertices) {
+               if (vertices == 0) {
+                       vertices = (vertex *) malloc(INCR(nr_vertices_allocated) * sizeof (vertex));
+               } else {
+                       INCR_ALLOCATION(vertices, nr_vertices_allocated, vertex);
+               }
+       }
+       vertices[nr_vertices][0] = v[0];
+       vertices[nr_vertices][1] = v[1];
+       vertices[nr_vertices][2] = v[2];
+       return nr_vertices++;
+}
+
+static inline GLuint
+save_triangle(GLuint v1, GLuint v2, GLuint v3)
+{
+       if (nr_triangles_allocated <= nr_triangles) {
+               if (triangles == 0) {
+                       triangles = (triangle *) malloc(INCR(nr_triangles_allocated) * sizeof (triangle));
+               } else {
+                       INCR_ALLOCATION(triangles, nr_triangles_allocated, triangle);
+               }
+       }
+       triangles[nr_triangles][0] = v1;
+       triangles[nr_triangles][1] = v2;
+       triangles[nr_triangles][2] = v3;
+       return nr_triangles++;
+}
+
+static inline void
+normalize(GLfloat v[3])
+{
+       GLfloat     d = (GLfloat) sqrt((double) (v[0] * v[0] + v[1] * v[1] + v[2] * v[2]));
+
+       if (d != 0) {
+               v[0] /= d;
+               v[1] /= d;
+               v[2] /= d;
+       } else {
+               v[0] = v[1] = v[2] = 0;
+       }
+}
+
+static void
+subdivide(GLfloat * v1, GLuint vi1,
+         GLfloat * v2, GLuint vi2,
+         GLfloat * v3, GLuint vi3,
+         int depth)
+{
+       int         i;
+
+       if (depth == 0) {
+               save_triangle(vi1, vi2, vi3);
+       } else {
+               GLuint      vi12, vi23, vi31;
+               GLfloat     v12[3], v23[3], v31[3];
+
+               for (i = 0; i < 3; ++i) {
+                       v12[i] = v1[i] + v2[i];
+                       v23[i] = v2[i] + v3[i];
+                       v31[i] = v3[i] + v1[i];
+               }
+               normalize(v12);
+               vi12 = save_vertex(v12);
+               normalize(v23);
+               vi23 = save_vertex(v23);
+               normalize(v31);
+               vi31 = save_vertex(v31);
+               subdivide(v1, vi1, v12, vi12, v31, vi31, depth - 1);
+               subdivide(v2, vi2, v23, vi23, v12, vi12, depth - 1);
+               subdivide(v3, vi3, v31, vi31, v23, vi23, depth - 1);
+               subdivide(v12, vi12, v23, vi23, v31, vi31, depth - 1);
+       }
+}
+
+#define ICO_X 0.525731112119133606
+#define ICO_Z 0.850650808352039932
+
+static GLfloat vdata[12][3] =
+{
+       {-ICO_X, 0, ICO_Z},
+       {ICO_X, 0, ICO_Z},
+       {-ICO_X, 0, -ICO_Z},
+       {ICO_X, 0, -ICO_Z},
+       {0, ICO_Z, ICO_X},
+       {0, ICO_Z, -ICO_X},
+       {0, -ICO_Z, ICO_X},
+       {0, -ICO_Z, -ICO_X},
+       {ICO_Z, ICO_X, 0},
+       {-ICO_Z, ICO_X, 0},
+       {ICO_Z, -ICO_X, 0},
+       {-ICO_Z, -ICO_X, 0}
+};
+
+static GLuint tindices[20][3] =
+{
+       {0, 4, 1},
+       {0, 9, 4},
+       {9, 5, 4},
+       {4, 5, 8},
+       {4, 8, 1},
+       {8, 10, 1},
+       {8, 3, 10},
+       {5, 3, 8},
+       {5, 2, 3},
+       {2, 7, 3},
+       {7, 10, 3},
+       {7, 6, 10},
+       {7, 11, 6},
+       {11, 0, 6},
+       {0, 1, 6},
+       {6, 1, 10},
+       {9, 0, 11},
+       {9, 11, 2},
+       {9, 2, 5},
+       {7, 2, 11}
+};
+
+/* Public interface: Create the sphere. */
+void
+glb_sphere_init(void)
+{
+       int         i;
+
+       if (initialized)
+               return;
+
+       for (i = 0; i < 20; ++i) {
+               subdivide(vdata[tindices[i][0]], save_vertex(vdata[tindices[i][0]]),
+                  vdata[tindices[i][1]], save_vertex(vdata[tindices[i][1]]),
+                  vdata[tindices[i][2]], save_vertex(vdata[tindices[i][2]]),
+                         glb_config.subdivision_depth);
+       }
+
+       initialized = 1;
+}
+
+/* Return the vertices list. */
+glb_vertex *
+glb_sphere_get_vertices(int *nr_vertices_ptr)
+{
+       glb_sphere_init();
+       *nr_vertices_ptr = nr_vertices;
+       return vertices;
+}
+
+/* Return the triangles list. */
+glb_triangle *
+glb_sphere_get_triangles(int *nr_triangles_ptr)
+{
+       glb_sphere_init();
+       *nr_triangles_ptr = nr_triangles;
+       return triangles;
+}
+
+/* Free up memory. */
+#if 0
+void
+glb_sphere_end(void)
+{
+       initialized = 0;
+
+       (void) free((void *) vertices);
+       (void) free((void *) triangles);
+
+       vertices = 0;
+       nr_vertices = nr_vertices_allocated = 0;
+
+       triangles = 0;
+       nr_triangles = nr_triangles_allocated = 0;
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/bubble3d.c b/xlockmore-4.14/modes/glx/bubble3d.c
new file mode 100644 (file)
index 0000000..dd5b68e
--- /dev/null
@@ -0,0 +1,264 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* bubble3d.c - 3D bubbles  */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)bubble3d.c  4.11 98/06/16 xlockmore";
+
+#endif
+
+/*-
+ * BUBBLE3D (C) 1998 Richard W.M. Jones.
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 16-Jun-98: Written.
+ *
+ * bubble.c: This code is responsible for creating and managing
+ * bubbles over their lifetime.
+ * The bubbles may be drawn inside out.
+ */
+
+#include "bubble3d.h"
+
+typedef struct bubble {
+       GLfloat    *contributions;      /* List of contributions from each
+                                        * nudge to each vertex. This list has
+                                        * length nr_vertices * nr_nudge_axes.
+                                        */
+       GLfloat     x, y, z;    /* (x,y,z) location of the bubble. */
+       GLfloat     scale;      /* Scaling factor applied to bubble. */
+       GLfloat     y_incr, scale_incr;         /* Change in y and scale each frame. */
+       GLfloat     rotx, roty, rotz;   /* Current rotation. */
+       GLfloat     rotx_incr, roty_incr, rotz_incr;    /* Amount by which we increase
+                                                        * rotation each step.
+                                                        */
+       GLfloat    *nudge_angle;        /* Current angle (radians) of each
+                                        * nudge. This list has length nr_nudge_axes.
+                                        */
+       GLfloat    *nudge_angle_incr;   /* Amount by which we increase each nudge
+                                        * angle in each frame.
+                                        */
+} bubble;
+
+/* Should be taken care of already... but just in case */
+#if !defined( __GNUC__ ) && !defined(__cplusplus) && !defined(c_plusplus)
+#undef inline
+#define inline                 /* */
+#endif
+static inline void
+normalize(GLfloat v[3])
+{
+       GLfloat     d = (GLfloat) sqrt((double) (v[0] * v[0] + v[1] * v[1] +
+                                                v[2] * v[2]));
+
+       if (d != 0) {
+               v[0] /= d;
+               v[1] /= d;
+               v[2] /= d;
+       } else {
+               v[0] = v[1] = v[2] = 0;
+       }
+}
+
+static inline GLfloat
+dotprod(GLfloat * v1, GLfloat * v2)
+{
+       return v1[0] * v2[0] + v1[1] * v2[1] + v1[2] * v2[2];
+}
+
+static inline GLfloat
+max(GLfloat a, GLfloat b)
+{
+       return a > b ? a : b;
+}
+
+/* Create a new bubble. */
+void       *
+glb_bubble_new(GLfloat x, GLfloat y, GLfloat z, GLfloat scale,
+              GLfloat y_incr, GLfloat scale_incr)
+{
+       int         i, j;
+
+       /* GLfloat axes [glb_config.nr_nudge_axes][3]; */
+       GLfloat     axes[5][3]; /* HARD CODED for SunCC */
+       int         nr_vertices;
+       glb_vertex *vertices = glb_sphere_get_vertices(&nr_vertices);
+
+       bubble     *b = (bubble *) malloc(sizeof *b);
+
+       if (b == 0)
+               return 0;
+
+       b->contributions = (GLfloat *) malloc(sizeof (GLfloat) * nr_vertices *
+                                             glb_config.nr_nudge_axes);
+       if (b->contributions == 0) {
+               (void) free((void *) b);
+               return 0;
+       }
+       b->nudge_angle = (GLfloat *) malloc(sizeof (GLfloat) * glb_config.nr_nudge_axes);
+       if (b->nudge_angle == 0) {
+               (void) free((void *) b->contributions);
+               (void) free((void *) b);
+               return 0;
+       }
+       b->nudge_angle_incr = (GLfloat *) malloc(sizeof (GLfloat) * glb_config.nr_nudge_axes);
+       if (b->nudge_angle_incr == 0) {
+               (void) free((void *) b->nudge_angle);
+               (void) free((void *) b->contributions);
+               (void) free((void *) b);
+               return 0;
+       }
+       /* Initialize primitive elements. */
+       b->x = x;
+       b->y = y;
+       b->z = z;
+       b->scale = scale;
+       b->y_incr = y_incr;
+       b->scale_incr = scale_incr;
+       b->rotx = b->roty = b->rotz = 0;
+       b->rotx_incr = glb_drand() * glb_config.rotation_factor * 2
+               - glb_config.rotation_factor;
+       b->roty_incr = glb_drand() * glb_config.rotation_factor * 2
+               - glb_config.rotation_factor;
+       b->rotz_incr = glb_drand() * glb_config.rotation_factor * 2
+               - glb_config.rotation_factor;
+
+       /* Initialize the nudge angle arrays. */
+       for (i = 0; i < glb_config.nr_nudge_axes; ++i) {
+               b->nudge_angle[i] = 0;
+               b->nudge_angle_incr[i] = glb_drand() * glb_config.nudge_angle_factor;
+       }
+
+       /* Choose some random nudge axes. */
+       for (i = 0; i < glb_config.nr_nudge_axes; ++i) {
+               axes[i][0] = glb_drand() * 2 - 1;
+               axes[i][1] = glb_drand() * 2 - 1;
+               axes[i][2] = glb_drand() * 2 - 1;
+               normalize(axes[i]);
+       }
+
+       /* Calculate the contribution that each nudge axis has on each vertex. */
+       for (i = 0; i < nr_vertices; ++i)
+               for (j = 0; j < glb_config.nr_nudge_axes; ++j)
+                       b->contributions[i * glb_config.nr_nudge_axes + j]
+                               = max(0, dotprod(vertices[i], axes[j]));
+
+       return (void *) b;
+}
+
+/* Delete a bubble and free up all memory. */
+void
+glb_bubble_delete(void *bb)
+{
+       bubble     *b = (bubble *) bb;
+
+       if (b != NULL) {
+               if (b->nudge_angle_incr) {
+                       (void) free((void *) b->nudge_angle_incr);
+                       b->nudge_angle_incr = NULL;
+               }
+               if (b->nudge_angle) {
+                       (void) free((void *) b->nudge_angle);
+                       b->nudge_angle = NULL;
+               }
+               if (b->contributions) {
+                       (void) free((void *) b->contributions);
+                       b->contributions = NULL;
+               }
+               (void) free((void *) b);
+               b = NULL;
+       }
+}
+
+/* Rotate and wobble a bubble by a single step. */
+void
+glb_bubble_step(void *bb)
+{
+       int         i;
+       bubble     *b = (bubble *) bb;
+
+       /* Update the rotation. */
+       b->rotx += b->rotx_incr;
+       b->roty += b->roty_incr;
+       b->rotz += b->rotz_incr;
+
+       /* Update the nudge angles. */
+       for (i = 0; i < glb_config.nr_nudge_axes; ++i)
+               b->nudge_angle[i] += b->nudge_angle_incr[i];
+
+       /* Move it upwards & outwards. */
+       b->y += b->y_incr;
+       b->scale += b->scale_incr;
+}
+
+/* Draw a bubble. */
+void
+glb_bubble_draw(void *bb)
+{
+       int         i, j;
+       bubble     *b = (bubble *) bb;
+       int         nr_vertices;
+       glb_vertex *vertices = glb_sphere_get_vertices(&nr_vertices);
+       int         nr_triangles;
+       glb_triangle *triangles = glb_sphere_get_triangles(&nr_triangles);
+       glb_vertex *new_vertices;
+
+       new_vertices = (glb_vertex *) malloc(sizeof (glb_vertex) * nr_vertices);
+       /* Calculate the vertices of this bubble, factoring in each nudge axis. */
+       for (i = 0; i < nr_vertices; ++i) {
+               GLfloat     s = 0;
+
+               for (j = 0; j < glb_config.nr_nudge_axes; ++j)
+                       s += ((GLfloat) cos((double) (b->nudge_angle[j])) *
+                             glb_config.nudge_factor - glb_config.nudge_factor / 2) *
+                               b->contributions[i * glb_config.nr_nudge_axes + j];
+
+               new_vertices[i][0] = vertices[i][0] * (s + 1);
+               new_vertices[i][1] = vertices[i][1] * (s + 1);
+               new_vertices[i][2] = vertices[i][2] * (s + 1);
+       }
+
+       glPushMatrix();
+
+       /* Apply translation, rotation and scalings. */
+       glTranslatef(b->x, b->y, b->z);
+
+       glRotatef(b->rotx, 1, 0, 0);
+       glRotatef(b->roty, 0, 1, 0);
+       glRotatef(b->rotz, 0, 0, 1);
+
+       glScalef(b->scale, b->scale, b->scale);
+
+       /* Draw the bubble. */
+       glBegin(GL_TRIANGLES);
+       for (i = 0; i < nr_triangles; ++i) {
+               glNormal3fv(new_vertices[triangles[i][0]]);
+               glVertex3fv(new_vertices[triangles[i][0]]);
+               glNormal3fv(new_vertices[triangles[i][1]]);
+               glVertex3fv(new_vertices[triangles[i][1]]);
+               glNormal3fv(new_vertices[triangles[i][2]]);
+               glVertex3fv(new_vertices[triangles[i][2]]);
+       }
+       glEnd();
+       glPopMatrix();
+       (void) free((void *) new_vertices);
+}
+
+/* Return y value. */
+GLfloat
+glb_bubble_get_y(void *bb)
+{
+       bubble     *b = (bubble *) bb;
+
+       return b->y;
+}
diff --git a/xlockmore-4.14/modes/glx/bubble3d.h b/xlockmore-4.14/modes/glx/bubble3d.h
new file mode 100644 (file)
index 0000000..67bec60
--- /dev/null
@@ -0,0 +1,95 @@
+#ifndef __bubbles3d_h__
+#define __bubbles3d_h__
+
+#if !defined( lint ) && !defined( SABER )
+/* #ident      "@(#)bubble3d.h 4.14 99/06/17 xlockmore" */
+
+#endif
+
+/*-
+ * Bubble3d stuff
+ *
+ * GLBUBBLES (C) 1998 Richard W.M. Jones.
+ * See xlock.c for copying information.
+ *
+ * Revision History:
+ * 17-06-99: Started log. :)
+ */
+
+#include "xlock.h"
+#include <GL/gl.h>
+#include <GL/glu.h>
+
+/* Static configuration. */
+#define GLB_SLOW_GL          1 /* Set this if you have a slow GL
+                                  * implementation. If you have an accelerated
+                                  * graphics card, set this to 0.
+                                */
+#define GLB_USE_BLENDING     0 /* Use alpha feature to create see-through
+                                  * bubbles.
+                                */
+#define GLB_VERTICES_EPSILON 0.0005    /* How close are identical vertices? */
+
+/* Configuration structure. */
+struct glb_config {
+       int         subdivision_depth;  /* Controls how many triangles are in
+                                        * each bubble. 2 and 3 are good values.
+                                        */
+       int         nr_nudge_axes;      /* Number of directions in which each
+                                        * bubble gets stretched. Values between
+                                        * 3 and 7 seem to produce good results.
+                                        */
+       GLfloat     nudge_angle_factor;         /* Max. amount of rotation in nudge angles.
+                                                * Controls the amount of `wobble' we see,
+                                                * and 0.3 seems to work well.
+                                                */
+       GLfloat     nudge_factor;       /* Max. displacement of any single nudge.
+                                        * Controls the amount of the wobble. Depends
+                                        * on NR_NUDGE_AXES, and must not exceed
+                                        * 1 / NR_NUDGE_AXES. 0.1 is good.
+                                        */
+       GLfloat     rotation_factor;    /* Max. amount by which bubbles rotate. */
+       int         create_bubbles_every;       /* How often to create new bubbles. */
+       int         max_bubbles;        /* Max. number of bubbles to create. */
+       double      p_bubble_group[4];  /* Probabilities of creating 1, 2, 3, 4
+                                        * bubbles in a group. Cumulative.
+                                        */
+       GLfloat     max_size;   /* Max. size. */
+       GLfloat     min_size;   /* Min. size of bubbles. */
+       GLfloat     max_speed;  /* Max. speed. */
+       GLfloat     min_speed;  /* Min. speed of bubbles. */
+       GLfloat     scale_factor;       /* Factor by which bubbles scale from bottom
+                                        * of screen to top. 1.5 - 2.0 are OK.
+                                        */
+       GLfloat     screen_bottom;      /* Bottom of screen. */
+       GLfloat     screen_top; /* Top of screen. */
+       GLfloat     bg_colour[4];       /* Background colour. */
+       GLfloat     bubble_colour[4];   /* Colour of the bubbles. */
+};
+
+extern struct glb_config glb_config;
+
+#define glb_drand() ((double)LRAND() / (double)MAXRAND)
+
+/*-- From glb_sphere.c. --*/
+typedef GLfloat glb_vertex[3];
+typedef GLuint glb_triangle[3];
+extern void glb_sphere_init(void);
+extern glb_vertex *glb_sphere_get_vertices(int *nr_vertices);
+extern glb_triangle *glb_sphere_get_triangles(int *nr_triangles);
+extern void glb_sphere_end(void);
+
+/*-- From glb_bubble.c. --*/
+extern void *glb_bubble_new(GLfloat x, GLfloat y, GLfloat z, GLfloat scale,
+                           GLfloat y_incr, GLfloat scale_incr);
+extern void glb_bubble_delete(void *);
+extern void glb_bubble_step(void *);
+extern void glb_bubble_draw(void *);
+extern GLfloat glb_bubble_get_y(void *);
+
+/*-- From glb_draw.c. --*/
+extern void *glb_draw_init(void);
+extern void glb_draw_step(void *);
+extern void glb_draw_end(void *);
+
+#endif /* __bubbles3d_h__ */
diff --git a/xlockmore-4.14/modes/glx/buildlwo.c b/xlockmore-4.14/modes/glx/buildlwo.c
new file mode 100644 (file)
index 0000000..56c82da
--- /dev/null
@@ -0,0 +1,100 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)buildlwo.c   4.02 97/04/20 xlockmore";
+
+#endif
+
+/*-
+ * buildlwo.c: Lightwave Object Display List Builder for OpenGL
+ *
+ * This module can be called by any GL mode wishing to use
+ * objects created in NewTek's Lightwave 3D.  The objects must
+ * first be converted to C source with my converter "lw2ogl".
+ * If other people are interested in this, I will put up a
+ * web page for it at http://www.netaxs.com/~emackey/lw2ogl/
+ *
+ * by Ed Mackey, 4/19/97
+ *
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef USE_GL
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include <GL/glu.h>
+#include "buildlwo.h"
+
+GLuint
+BuildLWO(int wireframe, struct lwo *object)
+{
+       GLuint      dl_num;
+       GLfloat    *pnts, *normals, three[3], *grab;
+       unsigned short int *pols;
+       int         p, num_pnts = 0;
+
+       dl_num = glGenLists(1);
+       if (!dl_num)
+               return (0);
+
+       pnts = object->pnts;
+       normals = object->normals;
+       pols = object->pols;
+
+       glNewList(dl_num, GL_COMPILE);
+
+       if (!pols) {
+               num_pnts = object->num_pnts;
+               glBegin(GL_POINTS);
+               for (p = 0; p < num_pnts; ++p) {
+                       three[0] = *(pnts++);
+                       three[1] = *(pnts++);
+                       three[2] = *(pnts++);
+                       glVertex3fv(three);
+               }
+               glEnd();
+       } else
+               for (;;) {
+                       if (num_pnts <= 0) {
+                               num_pnts = *pols + 2;
+                               if (num_pnts < 3)
+                                       break;
+                               if (num_pnts == 3) {
+                                       glBegin(GL_POINTS);
+                               } else if (num_pnts == 4) {
+                                       glBegin(GL_LINES);
+                               } else {
+                                       three[0] = *(normals++);
+                                       three[1] = *(normals++);
+                                       three[2] = *(normals++);
+                                       glNormal3fv(three);
+                                       if (wireframe)
+                                               glBegin(GL_LINE_LOOP);
+                                       else
+                                               glBegin(GL_POLYGON);
+                               }
+                       } else if (num_pnts == 1) {
+                               glEnd();
+                       } else {
+                               grab = pnts + ((int) (*pols) * 3);
+                               three[0] = *(grab++);
+                               three[1] = *(grab++);
+                               three[2] = *(grab++);
+                               glVertex3fv(three);
+                       }
+                       --num_pnts;
+                       ++pols;
+               }
+
+       glEndList();
+
+       return (dl_num);
+}
+
+#endif /* USE_GL */
+
+/* End of buildlwo.c */
diff --git a/xlockmore-4.14/modes/glx/buildlwo.h b/xlockmore-4.14/modes/glx/buildlwo.h
new file mode 100644 (file)
index 0000000..fd9f027
--- /dev/null
@@ -0,0 +1,24 @@
+/*-
+ * buildlwo.h: Header file for Lightwave Object Display List Builder
+ * for OpenGL
+ *
+ * by Ed Mackey, 4/19/97
+ *
+ */
+
+#ifndef __BUILD_LWO_H__
+#define __BUILD_LWO_H__
+
+struct lwo {
+       int         num_pnts;
+       GLfloat    *pnts;
+       GLfloat    *normals;
+       unsigned short int *pols;
+       GLfloat    *smoothnormals;
+};
+
+GLuint      BuildLWO(int wireframe, struct lwo *object);
+
+#endif
+
+/* End of buildlwo.h */
diff --git a/xlockmore-4.14/modes/glx/cage.c b/xlockmore-4.14/modes/glx/cage.c
new file mode 100644 (file)
index 0000000..797ac86
--- /dev/null
@@ -0,0 +1,452 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* cage --- the Impossible Cage, an Escher like scene. */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)cage.c       4.07 98/01/04 xlockmore";
+
+#endif
+
+#undef DEBUG_LISTS
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The RotateAroundU() routine was adapted from the book
+ *    "Computer Graphics Principles and Practice 
+ *     Foley - vanDam - Feiner - Hughes
+ *     Second Edition" Pag. 227, exercise 5.15.
+ * 
+ * This mode shows some interesting scenes that are impossible OR very
+ * wierd to build in the real universe. Much of the scenes are inspirated
+ * on Mauritz Cornelis Escher's works which derivated the mode's name.
+ * M.C. Escher (1898-1972) was a dutch artist and many people prefer to
+ * say he was a mathematician.
+ *
+ * Thanks goes to Brian Paul for making it possible and inexpensive to use 
+ * OpenGL at home.
+ *
+ * Since I'm not a native English speaker, my apologies for any grammatical
+ * mistake.
+ *
+ * My e-mail address is
+ * m-vianna@usa.net
+ *
+ * Marcelo F. Vianna (Jun-01-1997)
+ *
+ * Revision History:
+ * 01-Jan-98: Mode separated from escher and renamed
+ * 08-Jun-97: New scene implemented: "Impossible Cage" based in a M.C. Escher's
+ *            painting with the same name (quite similar). The first GL mode
+ *            to use texture mapping.
+ *            The "Impossible Cage" scene doesn't use DEPTH BUFFER, the 
+ *            wood planks are drawn consistently using GL_CULL_FACE, and
+ *            the painter's algorithm is used to sort the planks.
+ *            Marcelo F. Vianna.
+ * 07-Jun-97: Speed ups in Moebius Strip using GL_CULL_FACE.
+ *            Marcelo F. Vianna.
+ * 03-Jun-97: Initial Release (Only one scene: "Moebius Strip")
+ *            The Moebius Strip scene was inspirated in a M.C. Escher's
+ *            painting named Moebius Strip II in wich ants walk across a
+ *            Moebius Strip path, sometimes meeting each other and sometimes
+ *            being in "opposite faces" (note that the moebius strip has
+ *            only one face and one edge).
+ *            Marcelo F. Vianna.
+ *
+ */
+
+/*-
+ * Texture mapping is only available on RGBA contexts, Mono and color index
+ * visuals DO NOT support texture mapping in OpenGL.
+ *
+ * BUT Mesa do implements RGBA contexts in pseudo color visuals, so texture
+ * mapping shuld work on PseudoColor, DirectColor, TrueColor using Mesa. Mono
+ * is not officially supported for both OpenGL and Mesa, but seems to not crash
+ * Mesa.
+ *
+ * In real OpenGL, PseudoColor DO NOT support texture map (as far as I know).
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Cage"
+#define HACK_INIT init_cage
+#define HACK_DRAW draw_cage
+#define cage_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*wireframe: False \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+
+#endif /* !STANDALONE */
+
+#ifdef MODE_cage
+
+
+#include <GL/glu.h>
+#include "e_textures.h"
+
+ModeSpecOpt cage_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   cage_description =
+{"cage", "init_cage", "draw_cage", "release_cage",
+ "draw_cage", "change_cage", NULL, &cage_opts,
+ 1000, 1, 1, 1, 1.0, 4, "",
+ "Shows the Impossible Cage, an Escher-like GL scene", 0, NULL};
+
+#endif
+
+#define Scale4Window               0.3
+#define Scale4Iconic               0.4
+
+#define sqr(A)                     ((A)*(A))
+
+#ifndef Pi
+#define Pi                         M_PI
+#endif
+
+/*************************************************************************/
+
+typedef struct {
+       GLint       WindH, WindW;
+       GLfloat     step;
+       int         AreObjectsDefined[1];
+       GLXContext *glx_context;
+} cagestruct;
+
+static float front_shininess[] =
+{60.0};
+static float front_specular[] =
+{0.7, 0.7, 0.7, 1.0};
+static float ambient[] =
+{0.0, 0.0, 0.0, 1.0};
+static float diffuse[] =
+{1.0, 1.0, 1.0, 1.0};
+static float position0[] =
+{1.0, 1.0, 1.0, 0.0};
+static float position1[] =
+{-1.0, -1.0, 1.0, 0.0};
+static float lmodel_ambient[] =
+{0.5, 0.5, 0.5, 1.0};
+static float lmodel_twoside[] =
+{GL_TRUE};
+
+static float MaterialWhite[] =
+{0.7, 0.7, 0.7, 1.0};
+
+static cagestruct *cage = NULL;
+static GLuint objects;
+
+#define ObjWoodPlank    0
+
+#define PlankWidth      3.0
+#define PlankHeight     0.35
+#define PlankThickness  0.15
+
+static void
+draw_woodplank(cagestruct * cp)
+{
+       if (!cp->AreObjectsDefined[ObjWoodPlank]) {
+               glNewList(objects + ObjWoodPlank, GL_COMPILE_AND_EXECUTE);
+               glBegin(GL_QUADS);
+               glNormal3f(0, 0, 1);
+               glTexCoord2f(0, 0);
+               glVertex3f(-PlankWidth, -PlankHeight, PlankThickness);
+               glTexCoord2f(1, 0);
+               glVertex3f(PlankWidth, -PlankHeight, PlankThickness);
+               glTexCoord2f(1, 1);
+               glVertex3f(PlankWidth, PlankHeight, PlankThickness);
+               glTexCoord2f(0, 1);
+               glVertex3f(-PlankWidth, PlankHeight, PlankThickness);
+               glNormal3f(0, 0, -1);
+               glTexCoord2f(0, 0);
+               glVertex3f(-PlankWidth, PlankHeight, -PlankThickness);
+               glTexCoord2f(1, 0);
+               glVertex3f(PlankWidth, PlankHeight, -PlankThickness);
+               glTexCoord2f(1, 1);
+               glVertex3f(PlankWidth, -PlankHeight, -PlankThickness);
+               glTexCoord2f(0, 1);
+               glVertex3f(-PlankWidth, -PlankHeight, -PlankThickness);
+               glNormal3f(0, 1, 0);
+               glTexCoord2f(0, 0);
+               glVertex3f(-PlankWidth, PlankHeight, PlankThickness);
+               glTexCoord2f(1, 0);
+               glVertex3f(PlankWidth, PlankHeight, PlankThickness);
+               glTexCoord2f(1, 1);
+               glVertex3f(PlankWidth, PlankHeight, -PlankThickness);
+               glTexCoord2f(0, 1);
+               glVertex3f(-PlankWidth, PlankHeight, -PlankThickness);
+               glNormal3f(0, -1, 0);
+               glTexCoord2f(0, 0);
+               glVertex3f(-PlankWidth, -PlankHeight, -PlankThickness);
+               glTexCoord2f(1, 0);
+               glVertex3f(PlankWidth, -PlankHeight, -PlankThickness);
+               glTexCoord2f(1, 1);
+               glVertex3f(PlankWidth, -PlankHeight, PlankThickness);
+               glTexCoord2f(0, 1);
+               glVertex3f(-PlankWidth, -PlankHeight, PlankThickness);
+               glNormal3f(1, 0, 0);
+               glTexCoord2f(0, 0);
+               glVertex3f(PlankWidth, -PlankHeight, PlankThickness);
+               glTexCoord2f(1, 0);
+               glVertex3f(PlankWidth, -PlankHeight, -PlankThickness);
+               glTexCoord2f(1, 1);
+               glVertex3f(PlankWidth, PlankHeight, -PlankThickness);
+               glTexCoord2f(0, 1);
+               glVertex3f(PlankWidth, PlankHeight, PlankThickness);
+               glNormal3f(-1, 0, 0);
+               glTexCoord2f(0, 0);
+               glVertex3f(-PlankWidth, PlankHeight, PlankThickness);
+               glTexCoord2f(1, 0);
+               glVertex3f(-PlankWidth, PlankHeight, -PlankThickness);
+               glTexCoord2f(1, 1);
+               glVertex3f(-PlankWidth, -PlankHeight, -PlankThickness);
+               glTexCoord2f(0, 1);
+               glVertex3f(-PlankWidth, -PlankHeight, PlankThickness);
+               glEnd();
+               glEndList();
+               cp->AreObjectsDefined[ObjWoodPlank] = 1;
+#ifdef DEBUG_LISTS
+               (void) printf("WoodPlank drawn SLOWLY\n");
+#endif
+       } else {
+               glCallList(objects + ObjWoodPlank);
+#ifdef DEBUG_LISTS
+               (void) printf("WoodPlank drawn quickly\n");
+#endif
+       }
+}
+
+static void
+draw_impossiblecage(cagestruct * cp)
+{
+       glPushMatrix();
+       glRotatef(90, 0, 1, 0);
+       glTranslatef(0.0, PlankHeight - PlankWidth, -PlankThickness - PlankWidth);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(90, 0, 0, 1);
+       glTranslatef(0.0, PlankHeight - PlankWidth, PlankWidth - PlankThickness);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(90, 0, 1, 0);
+       glTranslatef(0.0, PlankWidth - PlankHeight, -PlankThickness - PlankWidth);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glTranslatef(0.0, PlankWidth - PlankHeight, 3 * PlankThickness - PlankWidth);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(90, 0, 0, 1);
+       glTranslatef(0.0, PlankWidth - PlankHeight, PlankWidth - PlankThickness);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glTranslatef(0.0, PlankWidth - PlankHeight, PlankWidth - 3 * PlankThickness);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glTranslatef(0.0, PlankHeight - PlankWidth, 3 * PlankThickness - PlankWidth);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(90, 0, 0, 1);
+       glTranslatef(0.0, PlankHeight - PlankWidth, PlankThickness - PlankWidth);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glTranslatef(0.0, PlankHeight - PlankWidth, PlankWidth - 3 * PlankThickness);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(90, 0, 1, 0);
+       glTranslatef(0.0, PlankHeight - PlankWidth, PlankWidth + PlankThickness);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(90, 0, 0, 1);
+       glTranslatef(0.0, PlankWidth - PlankHeight, PlankThickness - PlankWidth);
+       draw_woodplank(cp);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(90, 0, 1, 0);
+       glTranslatef(0.0, PlankWidth - PlankHeight, PlankWidth + PlankThickness);
+       draw_woodplank(cp);
+       glPopMatrix();
+}
+
+static void
+reshape(ModeInfo * mi, int width, int height)
+{
+       cagestruct *cp = &cage[MI_SCREEN(mi)];
+
+       glViewport(0, 0, cp->WindW = (GLint) width, cp->WindH = (GLint) height);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 15.0);
+       glMatrixMode(GL_MODELVIEW);
+       if (width >= 1024) {
+               glLineWidth(3);
+               glPointSize(3);
+       } else if (width >= 512) {
+               glLineWidth(2);
+               glPointSize(2);
+       } else {
+               glLineWidth(1);
+               glPointSize(1);
+       }
+       cp->AreObjectsDefined[ObjWoodPlank] = 0;
+}
+
+static void
+pinit(void)
+{
+       glClearDepth(1.0);
+       glClearColor(0.0, 0.0, 0.0, 1.0);
+
+       glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT0, GL_POSITION, position0);
+       glLightfv(GL_LIGHT1, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT1, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT1, GL_POSITION, position1);
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lmodel_ambient);
+       glLightModelfv(GL_LIGHT_MODEL_TWO_SIDE, lmodel_twoside);
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+       glEnable(GL_LIGHT1);
+       glEnable(GL_NORMALIZE);
+       glFrontFace(GL_CCW);
+       glCullFace(GL_BACK);
+
+       /* cage */
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialWhite);
+       glShadeModel(GL_FLAT);
+       glDisable(GL_DEPTH_TEST);
+       glEnable(GL_TEXTURE_2D);
+       glEnable(GL_CULL_FACE);
+
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+       gluBuild2DMipmaps(GL_TEXTURE_2D, 3, WoodTextureWidth, WoodTextureHeight,
+                         GL_RGB, GL_UNSIGNED_BYTE, WoodTextureData);
+       glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, front_shininess);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, front_specular);
+}
+
+void
+init_cage(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       cagestruct *cp;
+
+       if (cage == NULL) {
+               if ((cage = (cagestruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (cagestruct))) == NULL)
+                       return;
+       }
+       cp = &cage[screen];
+       cp->step = NRAND(90);
+
+       if ((cp->glx_context = init_GL(mi)) != NULL) {
+
+               reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+               glDrawBuffer(GL_BACK);
+               if (!glIsList(objects))
+                       objects = glGenLists(1);
+               pinit();
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_cage(ModeInfo * mi)
+{
+       cagestruct *cp = &cage[MI_SCREEN(mi)];
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!cp->glx_context)
+               return;
+
+       glXMakeCurrent(display, window, *(cp->glx_context));
+
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       glPushMatrix();
+
+       glTranslatef(0.0, 0.0, -10.0);
+
+       if (!MI_IS_ICONIC(mi)) {
+               glScalef(Scale4Window * cp->WindH / cp->WindW, Scale4Window, Scale4Window);
+       } else {
+               glScalef(Scale4Iconic * cp->WindH / cp->WindW, Scale4Iconic, Scale4Iconic);
+       }
+
+       /* cage */
+       glRotatef(cp->step * 100, 0, 0, 1);
+       glRotatef(25 + cos(cp->step * 5) * 6, 1, 0, 0);
+       glRotatef(204.5 - sin(cp->step * 5) * 8, 0, 1, 0);
+       draw_impossiblecage(cp);
+
+       glPopMatrix();
+
+       glFlush();
+
+       glXSwapBuffers(display, window);
+
+       cp->step += 0.025;
+}
+
+void
+change_cage(ModeInfo * mi)
+{
+       cagestruct *cp = &cage[MI_SCREEN(mi)];
+
+       if (!cp->glx_context)
+               return;
+
+       glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(cp->glx_context));
+       pinit();
+}
+
+void
+release_cage(ModeInfo * mi)
+{
+       if (cage != NULL) {
+               (void) free((void *) cage);
+               cage = NULL;
+       }
+       if (glIsList(objects)) {
+               glDeleteLists(objects, 1);
+       }
+       FreeAllGL(mi);
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/dolphin.c b/xlockmore-4.14/modes/glx/dolphin.c
new file mode 100644 (file)
index 0000000..b809ff6
--- /dev/null
@@ -0,0 +1,2069 @@
+/* atlantis --- Shows moving 3D sea animals */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)dolphin.c    1.2 98/06/16 xlockmore";
+
+#endif
+
+/* Copyright (c) E. Lassauge, 1998. */
+
+/*
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The original code for this mode was written by Mark J. Kilgard
+ * as a demo for openGL programming.
+ * 
+ * Porting it to xlock  was possible by comparing the original Mesa's morph3d 
+ * demo with it's ported version to xlock, so thanks for Marcelo F. Vianna 
+ * (look at morph3d.c) for his indirect help.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * My e-mail address is lassauge@sagem.fr
+ *
+ * Eric Lassauge  (May-13-1998)
+ *
+ */
+
+/**
+ * (c) Copyright 1993, 1994, Silicon Graphics, Inc.
+ * ALL RIGHTS RESERVED
+ * Permission to use, copy, modify, and distribute this software for
+ * any purpose and without fee is hereby granted, provided that the above
+ * copyright notice appear in all copies and that both the copyright notice
+ * and this permission notice appear in supporting documentation, and that
+ * the name of Silicon Graphics, Inc. not be used in advertising
+ * or publicity pertaining to distribution of the software without specific,
+ * written prior permission.
+ *
+ * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
+ * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
+ * FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
+ * GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
+ * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
+ * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
+ * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
+ * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
+ * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
+ * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * US Government Users Restricted Rights
+ * Use, duplication, or disclosure by the Government is subject to
+ * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
+ * (c)(1)(ii) of the Rights in Technical Data and Computer Software
+ * clause at DFARS 252.227-7013 and/or in similar or successor
+ * clauses in the FAR or the DOD or NASA FAR Supplement.
+ * Unpublished-- rights reserved under the copyright laws of the
+ * United States.  Contractor/manufacturer is Silicon Graphics,
+ * Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
+ *
+ * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_atlantis
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+
+#include "atlantis.h"
+/* *INDENT-OFF* */
+static float N001[3] = {-0.005937 ,-0.101998 ,-0.994767};
+static float N002[3] = {0.936780 ,-0.200803 ,0.286569};
+static float N003[3] = {-0.233062 ,0.972058 ,0.028007};
+#if 0
+static float N004[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N005[3] = {0.898117 ,0.360171 ,0.252315};
+static float N006[3] = {-0.915437 ,0.348456 ,0.201378};
+static float N007[3] = {0.602263 ,-0.777527 ,0.180920};
+static float N008[3] = {-0.906912 ,-0.412015 ,0.088061};
+#if 0
+static float N009[3] = {-0.015623 ,0.999878 ,0.000000};
+static float N010[3] = {0.000000 ,-0.992278 ,0.124035};
+static float N011[3] = {0.000000 ,-0.936329 ,-0.351123};
+#endif
+static float N012[3] = {0.884408 ,-0.429417 ,-0.182821};
+static float N013[3] = {0.921121 ,0.311084 ,-0.234016};
+static float N014[3] = {0.382635 ,0.877882 ,-0.287948};
+static float N015[3] = {-0.380046 ,0.888166 ,-0.258316};
+static float N016[3] = {-0.891515 ,0.392238 ,-0.226607};
+static float N017[3] = {-0.901419 ,-0.382002 ,-0.203763};
+static float N018[3] = {-0.367225 ,-0.911091 ,-0.187243};
+static float N019[3] = {0.339539 ,-0.924846 ,-0.171388};
+static float N020[3] = {0.914706 ,-0.378617 ,-0.141290};
+static float N021[3] = {0.950662 ,0.262713 ,-0.164994};
+static float N022[3] = {0.546359 ,0.801460 ,-0.243218};
+static float N023[3] = {-0.315796 ,0.917068 ,-0.243431};
+static float N024[3] = {-0.825687 ,0.532277 ,-0.186875};
+static float N025[3] = {-0.974763 ,-0.155232 ,-0.160435};
+static float N026[3] = {-0.560596 ,-0.816658 ,-0.137119};
+static float N027[3] = {0.380210 ,-0.910817 ,-0.160786};
+static float N028[3] = {0.923772 ,-0.358322 ,-0.135093};
+static float N029[3] = {0.951202 ,0.275053 ,-0.139859};
+static float N030[3] = {0.686099 ,0.702548 ,-0.188932};
+static float N031[3] = {-0.521865 ,0.826719 ,-0.210220};
+static float N032[3] = {-0.923820 ,0.346739 ,-0.162258};
+static float N033[3] = {-0.902095 ,-0.409995 ,-0.134646};
+static float N034[3] = {-0.509115 ,-0.848498 ,-0.144404};
+static float N035[3] = {0.456469 ,-0.880293 ,-0.129305};
+static float N036[3] = {0.873401 ,-0.475489 ,-0.105266};
+static float N037[3] = {0.970825 ,0.179861 ,-0.158584};
+static float N038[3] = {0.675609 ,0.714187 ,-0.183004};
+static float N039[3] = {-0.523574 ,0.830212 ,-0.191360};
+static float N040[3] = {-0.958895 ,0.230808 ,-0.165071};
+static float N041[3] = {-0.918285 ,-0.376803 ,-0.121542};
+static float N042[3] = {-0.622467 ,-0.774167 ,-0.114888};
+static float N043[3] = {0.404497 ,-0.908807 ,-0.102231};
+static float N044[3] = {0.930538 ,-0.365155 ,-0.027588};
+static float N045[3] = {0.921920 ,0.374157 ,-0.100345};
+static float N046[3] = {0.507346 ,0.860739 ,0.041562};
+static float N047[3] = {-0.394646 ,0.918815 ,-0.005730};
+static float N048[3] = {-0.925411 ,0.373024 ,-0.066837};
+static float N049[3] = {-0.945337 ,-0.322309 ,-0.049551};
+static float N050[3] = {-0.660437 ,-0.750557 ,-0.022072};
+static float N051[3] = {0.488835 ,-0.871950 ,-0.027261};
+static float N052[3] = {0.902599 ,-0.421397 ,0.087969};
+static float N053[3] = {0.938636 ,0.322606 ,0.122020};
+static float N054[3] = {0.484605 ,0.871078 ,0.079878};
+static float N055[3] = {-0.353607 ,0.931559 ,0.084619};
+static float N056[3] = {-0.867759 ,0.478564 ,0.134054};
+static float N057[3] = {-0.951583 ,-0.296030 ,0.082794};
+static float N058[3] = {-0.672355 ,-0.730209 ,0.121384};
+static float N059[3] = {0.528336 ,-0.842452 ,0.105525};
+static float N060[3] = {0.786913 ,-0.564760 ,0.248627};
+#if 0
+static float N061[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N062[3] = {0.622098 ,0.765230 ,0.165584};
+static float N063[3] = {-0.631711 ,0.767816 ,0.106773};
+static float N064[3] = {-0.687886 ,0.606351 ,0.398938};
+static float N065[3] = {-0.946327 ,-0.281623 ,0.158598};
+static float N066[3] = {-0.509549 ,-0.860437 ,0.002776};
+static float N067[3] = {0.462594 ,-0.876692 ,0.131977};
+#if 0
+static float N068[3] = {0.000000 ,-0.992278 ,0.124035};
+static float N069[3] = {0.000000 ,-0.970143 ,-0.242536};
+static float N070[3] = {0.015502 ,0.992159 ,-0.124020};
+#endif
+static float N071[3] = {0.000000 ,1.000000 ,0.000000};
+#if 0
+static float N072[3] = {0.000000 ,1.000000 ,0.000000};
+static float N073[3] = {0.000000 ,1.000000 ,0.000000};
+static float N074[3] = {0.000000 ,-1.000000 ,0.000000};
+static float N075[3] = {-0.242536 ,0.000000 ,-0.970143};
+static float N076[3] = {-0.010336 ,-0.992225 ,-0.124028};
+#endif
+static float N077[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N078[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N079[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N080[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N081[3] = {-0.571197 ,0.816173 ,0.087152};
+static float N082[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N083[3] = {-0.571197 ,0.816173 ,0.087152};
+static float N084[3] = {-0.571197 ,0.816173 ,0.087152};
+static float N085[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N086[3] = {-0.571197 ,0.816173 ,0.087152};
+static float N087[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N088[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N089[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N090[3] = {-0.880770 ,0.461448 ,0.106351};
+static float N091[3] = {0.000000 ,1.000000 ,0.000000};
+static float N092[3] = {0.000000 ,1.000000 ,0.000000};
+static float N093[3] = {0.000000 ,1.000000 ,0.000000};
+static float N094[3] = {1.000000 ,0.000000 ,0.000000};
+static float N095[3] = {-1.000000 ,0.000000 ,0.000000};
+#if 0
+static float N096[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N097[3] = {-0.697296 ,0.702881 ,0.140491};
+static float N098[3] = {0.918864 ,0.340821 ,0.198819};
+static float N099[3] = {-0.932737 ,0.201195 ,0.299202};
+static float N100[3] = {0.029517 ,0.981679 ,0.188244};
+#if 0
+static float N101[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N102[3] = {0.813521 ,-0.204936 ,0.544229};
+#if 0
+static float N103[3] = {0.000000 ,1.000000 ,0.000000};
+static float N104[3] = {0.000000 ,1.000000 ,0.000000};
+static float N105[3] = {0.000000 ,1.000000 ,0.000000};
+static float N106[3] = {0.000000 ,1.000000 ,0.000000};
+static float N107[3] = {0.000000 ,1.000000 ,0.000000};
+static float N108[3] = {0.000000 ,1.000000 ,0.000000};
+static float N109[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N110[3] = {-0.781480 ,-0.384779 ,0.491155};
+static float N111[3] = {-0.722243 ,0.384927 ,0.574627};
+static float N112[3] = {-0.752278 ,0.502679 ,0.425901};
+static float N113[3] = {0.547257 ,0.367910 ,0.751766};
+static float N114[3] = {0.725949 ,-0.232568 ,0.647233};
+static float N115[3] = {-0.747182 ,-0.660786 ,0.071280};
+static float N116[3] = {0.931519 ,0.200748 ,0.303270};
+static float N117[3] = {-0.828928 ,0.313757 ,0.463071};
+static float N118[3] = {0.902554 ,-0.370967 ,0.218587};
+static float N119[3] = {-0.879257 ,-0.441851 ,0.177973};
+static float N120[3] = {0.642327 ,0.611901 ,0.461512};
+static float N121[3] = {0.964817 ,-0.202322 ,0.167910};
+static float N122[3] = {0.000000 ,1.000000 ,0.000000};
+#if 0
+static float N123[3] = {-0.980734 ,0.041447 ,0.190900};
+static float N124[3] = {-0.980734 ,0.041447 ,0.190900};
+static float N125[3] = {-0.980734 ,0.041447 ,0.190900};
+static float N126[3] = {0.000000 ,1.000000 ,0.000000};
+static float N127[3] = {0.000000 ,1.000000 ,0.000000};
+static float N128[3] = {0.000000 ,1.000000 ,0.000000};
+static float N129[3] = {0.963250 ,0.004839 ,0.268565};
+static float N130[3] = {0.963250 ,0.004839 ,0.268565};
+static float N131[3] = {0.963250 ,0.004839 ,0.268565};
+static float N132[3] = {0.000000 ,1.000000 ,0.000000};
+static float N133[3] = {0.000000 ,1.000000 ,0.000000};
+static float N134[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float P001[3] = {5.68, -300.95, 1324.70};
+static float P002[3] = {338.69, -219.63, 9677.03};
+static float P003[3] = {12.18, 474.59, 9138.14};
+#if 0
+static float P004[3] = {-7.49, -388.91, 10896.74};
+#endif
+static float P005[3] = {487.51, 198.05, 9350.78};
+static float P006[3] = {-457.61, 68.74, 9427.85};
+static float P007[3] = {156.52, -266.72, 10311.68};
+static float P008[3] = {-185.56, -266.51, 10310.47};
+static float P009[3] = {124.39, -261.46, 1942.34};
+static float P010[3] = {-130.05, -261.46, 1946.03};
+static float P011[3] = {141.07, -320.11, 1239.38};
+static float P012[3] = {156.48, -360.12, 2073.41};
+static float P013[3] = {162.00, -175.88, 2064.44};
+static float P014[3] = {88.16, -87.72, 2064.02};
+static float P015[3] = {-65.21, -96.13, 2064.02};
+static float P016[3] = {-156.48, -180.96, 2064.44};
+static float P017[3] = {-162.00, -368.93, 2082.39};
+static float P018[3] = {-88.16, -439.22, 2082.39};
+static float P019[3] = {65.21, -440.32, 2083.39};
+static float P020[3] = {246.87, -356.02, 2576.95};
+static float P021[3] = {253.17, -111.15, 2567.15};
+static float P022[3] = {132.34, 51.41, 2559.84};
+static float P023[3] = {-97.88, 40.44, 2567.15};
+static float P024[3] = {-222.97, -117.49, 2567.15};
+static float P025[3] = {-252.22, -371.53, 2569.92};
+static float P026[3] = {-108.44, -518.19, 2586.75};
+static float P027[3] = {97.88, -524.79, 2586.75};
+static float P028[3] = {370.03, -421.19, 3419.70};
+static float P029[3] = {351.15, -16.98, 3423.17};
+static float P030[3] = {200.66, 248.46, 3430.37};
+static float P031[3] = {-148.42, 235.02, 3417.91};
+static float P032[3] = {-360.21, -30.27, 3416.84};
+static float P033[3] = {-357.90, -414.89, 3407.04};
+static float P034[3] = {-148.88, -631.35, 3409.90};
+static float P035[3] = {156.38, -632.59, 3419.70};
+static float P036[3] = {462.61, -469.21, 4431.51};
+static float P037[3] = {466.60, 102.25, 4434.98};
+static float P038[3] = {243.05, 474.34, 4562.02};
+static float P039[3] = {-191.23, 474.40, 4554.42};
+static float P040[3] = {-476.12, 111.05, 4451.11};
+static float P041[3] = {-473.36, -470.74, 4444.78};
+static float P042[3] = {-266.95, -748.41, 4447.78};
+static float P043[3] = {211.14, -749.91, 4429.73};
+static float P044[3] = {680.57, -370.27, 5943.46};
+static float P045[3] = {834.01, 363.09, 6360.63};
+static float P046[3] = {371.29, 804.51, 6486.26};
+static float P047[3] = {-291.43, 797.22, 6494.28};
+static float P048[3] = {-784.13, 370.75, 6378.01};
+static float P049[3] = {-743.29, -325.82, 5943.46};
+static float P050[3] = {-383.24, -804.77, 5943.46};
+static float P051[3] = {283.47, -846.09, 5943.46};
+static float iP001[3] = {5.68, -300.95, 1324.70};
+#if 0
+static float iP002[3] = {338.69, -219.63, 9677.03};
+static float iP003[3] = {12.18, 624.93, 8956.39};
+static float iP004[3] = {-7.49, -388.91, 10896.74};
+static float iP005[3] = {487.51, 198.05, 9350.78};
+static float iP006[3] = {-457.61, 199.04, 9353.01};
+static float iP007[3] = {156.52, -266.72, 10311.68};
+static float iP008[3] = {-185.56, -266.51, 10310.47};
+#endif
+static float iP009[3] = {124.39, -261.46, 1942.34};
+static float iP010[3] = {-130.05, -261.46, 1946.03};
+static float iP011[3] = {141.07, -320.11, 1239.38};
+static float iP012[3] = {156.48, -360.12, 2073.41};
+static float iP013[3] = {162.00, -175.88, 2064.44};
+static float iP014[3] = {88.16, -87.72, 2064.02};
+static float iP015[3] = {-65.21, -96.13, 2064.02};
+static float iP016[3] = {-156.48, -180.96, 2064.44};
+static float iP017[3] = {-162.00, -368.93, 2082.39};
+static float iP018[3] = {-88.16, -439.22, 2082.39};
+static float iP019[3] = {65.21, -440.32, 2083.39};
+static float iP020[3] = {246.87, -356.02, 2576.95};
+static float iP021[3] = {253.17, -111.15, 2567.15};
+static float iP022[3] = {132.34, 51.41, 2559.84};
+static float iP023[3] = {-97.88, 40.44, 2567.15};
+static float iP024[3] = {-222.97, -117.49, 2567.15};
+static float iP025[3] = {-252.22, -371.53, 2569.92};
+static float iP026[3] = {-108.44, -518.19, 2586.75};
+static float iP027[3] = {97.88, -524.79, 2586.75};
+static float iP028[3] = {370.03, -421.19, 3419.70};
+static float iP029[3] = {351.15, -16.98, 3423.17};
+static float iP030[3] = {200.66, 248.46, 3430.37};
+static float iP031[3] = {-148.42, 235.02, 3417.91};
+static float iP032[3] = {-360.21, -30.27, 3416.84};
+static float iP033[3] = {-357.90, -414.89, 3407.04};
+static float iP034[3] = {-148.88, -631.35, 3409.90};
+static float iP035[3] = {156.38, -632.59, 3419.70};
+static float iP036[3] = {462.61, -469.21, 4431.51};
+static float iP037[3] = {466.60, 102.25, 4434.98};
+static float iP038[3] = {243.05, 474.34, 4562.02};
+static float iP039[3] = {-191.23, 474.40, 4554.42};
+static float iP040[3] = {-476.12, 111.05, 4451.11};
+static float iP041[3] = {-473.36, -470.74, 4444.78};
+static float iP042[3] = {-266.95, -748.41, 4447.78};
+static float iP043[3] = {211.14, -749.91, 4429.73};
+static float iP044[3] = {680.57, -370.27, 5943.46};
+static float iP045[3] = {834.01, 363.09, 6360.63};
+static float iP046[3] = {371.29, 804.51, 6486.26};
+static float iP047[3] = {-291.43, 797.22, 6494.28};
+static float iP048[3] = {-784.13, 370.75, 6378.01};
+static float iP049[3] = {-743.29, -325.82, 5943.46};
+static float iP050[3] = {-383.24, -804.77, 5943.46};
+static float iP051[3] = {283.47, -846.09, 5943.46};
+static float P052[3] = {599.09, -300.15, 7894.03};
+static float P053[3] = {735.48, 306.26, 7911.92};
+static float P054[3] = {246.22, 558.53, 8460.50};
+static float P055[3] = {-230.41, 559.84, 8473.23};
+static float P056[3] = {-698.66, 320.83, 7902.59};
+static float P057[3] = {-643.29, -299.16, 7902.59};
+static float P058[3] = {-341.47, -719.30, 7902.59};
+static float P059[3] = {252.57, -756.12, 7902.59};
+static float P060[3] = {458.39, -265.31, 9355.44};
+#if 0
+static float P061[3] = {433.38, -161.90, 9503.03};
+#endif
+static float P062[3] = {224.04, 338.75, 9450.30};
+static float P063[3] = {-165.71, 341.04, 9462.35};
+static float P064[3] = {-298.11, 110.13, 10180.37};
+static float P065[3] = {-473.99, -219.71, 9355.44};
+static float P066[3] = {-211.97, -479.87, 9355.44};
+static float P067[3] = {192.86, -491.45, 9348.73};
+static float P068[3] = {-136.29, -319.84, 1228.73};
+static float P069[3] = {1111.17, -314.14, 1314.19};
+static float P070[3] = {-1167.34, -321.61, 1319.45};
+static float P071[3] = {1404.86, -306.66, 1235.45};
+static float P072[3] = {-1409.73, -314.14, 1247.66};
+static float P073[3] = {1254.01, -296.87, 1544.58};
+static float P074[3] = {-1262.09, -291.70, 1504.26};
+static float P075[3] = {965.71, -269.26, 1742.65};
+static float P076[3] = {-900.97, -276.74, 1726.07};
+static float iP068[3] = {-136.29, -319.84, 1228.73};
+static float iP069[3] = {1111.17, -314.14, 1314.19};
+static float iP070[3] = {-1167.34, -321.61, 1319.45};
+static float iP071[3] = {1404.86, -306.66, 1235.45};
+static float iP072[3] = {-1409.73, -314.14, 1247.66};
+static float iP073[3] = {1254.01, -296.87, 1544.58};
+static float iP074[3] = {-1262.09, -291.70, 1504.26};
+static float iP075[3] = {965.71, -269.26, 1742.65};
+static float iP076[3] = {-900.97, -276.74, 1726.07};
+static float P077[3] = {1058.00, -448.81, 8194.66};
+static float P078[3] = {-1016.51, -456.43, 8190.62};
+static float P079[3] = {-1515.96, -676.45, 7754.93};
+static float P080[3] = {1856.75, -830.34, 7296.56};
+static float P081[3] = {1472.16, -497.38, 7399.68};
+static float P082[3] = {-1775.26, -829.51, 7298.46};
+static float P083[3] = {911.09, -252.51, 7510.99};
+static float P084[3] = {-1451.94, -495.62, 7384.30};
+static float P085[3] = {1598.75, -669.26, 7769.90};
+static float P086[3] = {-836.53, -250.08, 7463.25};
+static float P087[3] = {722.87, -158.18, 8006.41};
+static float P088[3] = {-688.86, -162.28, 7993.89};
+static float P089[3] = {-626.92, -185.30, 8364.98};
+static float P090[3] = {647.72, -189.46, 8354.99};
+static float P091[3] = {0.00, 835.01, 5555.62};
+static float P092[3] = {0.00, 1350.18, 5220.86};
+static float P093[3] = {0.00, 1422.94, 5285.27};
+static float P094[3] = {0.00, 1296.75, 5650.19};
+static float P095[3] = {0.00, 795.63, 6493.88};
+static float iP091[3] = {0.00, 835.01, 5555.62};
+static float iP092[3] = {0.00, 1350.18, 5220.86};
+static float iP093[3] = {0.00, 1422.94, 5285.27};
+static float iP094[3] = {0.00, 1296.75, 5650.19};
+static float iP095[3] = {0.00, 795.63, 6493.88};
+#if 0
+static float P096[3] = {-447.38, -165.99, 9499.60};
+#endif
+static float P097[3] = {-194.91, -357.14, 10313.32};
+static float P098[3] = {135.35, -357.66, 10307.94};
+static float iP097[3] = {-194.91, -357.14, 10313.32};
+static float iP098[3] = {135.35, -357.66, 10307.94};
+static float P099[3] = {-380.53, -221.14, 9677.98};
+static float P100[3] = {0.00, 412.99, 9629.33};
+#if 0
+static float P101[3] = {5.70, 567.00, 7862.98};
+#endif
+static float P102[3] = {59.51, -412.55, 10677.58};
+static float iP102[3] = {59.51, -412.55, 10677.58};
+static float P103[3] = {6.50, 484.74, 9009.94};
+#if 0
+static float P104[3] = {-9.86, 567.62, 7858.65};
+#endif
+static float P105[3] = {-41.86, 476.51, 9078.17};
+#if 0
+static float P106[3] = {22.75, 568.13, 7782.83};
+static float P107[3] = {58.93, 568.42, 7775.94};
+#endif
+static float P108[3] = {49.20, 476.83, 9078.24};
+#if 0
+static float P109[3] = {99.21, 566.00, 7858.65};
+#endif
+static float P110[3] = {-187.62, -410.04, 10674.12};
+static float iP110[3] = {-187.62, -410.04, 10674.12};
+static float P111[3] = {-184.25, -318.70, 10723.88};
+static float iP111[3] = {-184.25, -318.70, 10723.88};
+static float P112[3] = {-179.61, -142.81, 10670.26};
+static float P113[3] = {57.43, -147.94, 10675.26};
+static float P114[3] = {54.06, -218.90, 10712.44};
+static float P115[3] = {-186.35, -212.09, 10713.76};
+static float P116[3] = {205.90, -84.61, 10275.97};
+static float P117[3] = {-230.96, -83.26, 10280.09};
+static float iP118[3] = {216.78, -509.17, 10098.94};
+static float iP119[3] = {-313.21, -510.79, 10102.62};
+static float P118[3] = {216.78, -509.17, 10098.94};
+static float P119[3] = {-313.21, -510.79, 10102.62};
+static float P120[3] = {217.95, 96.34, 10161.62};
+static float P121[3] = {71.99, -319.74, 10717.70};
+static float iP121[3] = {71.99, -319.74, 10717.70};
+static float P122[3] = {0.00, 602.74, 5375.84};
+static float iP122[3] = {0.00, 602.74, 5375.84};
+static float P123[3] = {-448.94, -203.14, 9499.60};
+static float P124[3] = {-442.64, -185.20, 9528.07};
+static float P125[3] = {-441.07, -148.05, 9528.07};
+static float P126[3] = {-443.43, -128.84, 9499.60};
+static float P127[3] = {-456.87, -146.78, 9466.67};
+static float P128[3] = {-453.68, -183.93, 9466.67};
+static float P129[3] = {428.43, -124.08, 9503.03};
+static float P130[3] = {419.73, -142.14, 9534.56};
+static float P131[3] = {419.92, -179.96, 9534.56};
+static float P132[3] = {431.20, -199.73, 9505.26};
+static float P133[3] = {442.28, -181.67, 9475.96};
+static float P134[3] = {442.08, -143.84, 9475.96};
+/* *INDENT-ON* */
+
+
+
+static void
+Dolphin001(GLenum cap)
+{
+       glNormal3fv(N071);
+       glBegin(cap);
+       glVertex3fv(P001);
+       glVertex3fv(P068);
+       glVertex3fv(P010);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P068);
+       glVertex3fv(P076);
+       glVertex3fv(P010);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P068);
+       glVertex3fv(P070);
+       glVertex3fv(P076);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P076);
+       glVertex3fv(P070);
+       glVertex3fv(P074);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P070);
+       glVertex3fv(P072);
+       glVertex3fv(P074);
+       glEnd();
+       glNormal3fv(N119);
+       glBegin(cap);
+       glVertex3fv(P072);
+       glVertex3fv(P070);
+       glVertex3fv(P074);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P074);
+       glVertex3fv(P070);
+       glVertex3fv(P076);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P070);
+       glVertex3fv(P068);
+       glVertex3fv(P076);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P076);
+       glVertex3fv(P068);
+       glVertex3fv(P010);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P068);
+       glVertex3fv(P001);
+       glVertex3fv(P010);
+       glEnd();
+}
+
+static void
+Dolphin002(GLenum cap)
+{
+       glNormal3fv(N071);
+       glBegin(cap);
+       glVertex3fv(P011);
+       glVertex3fv(P001);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P075);
+       glVertex3fv(P011);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P069);
+       glVertex3fv(P011);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P069);
+       glVertex3fv(P075);
+       glVertex3fv(P073);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P071);
+       glVertex3fv(P069);
+       glVertex3fv(P073);
+       glEnd();
+       glNormal3fv(N119);
+       glBegin(cap);
+       glVertex3fv(P001);
+       glVertex3fv(P011);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P009);
+       glVertex3fv(P011);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P011);
+       glVertex3fv(P069);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P069);
+       glVertex3fv(P073);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P069);
+       glVertex3fv(P071);
+       glVertex3fv(P073);
+       glEnd();
+}
+
+static void
+Dolphin003(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glEnd();
+}
+
+static void
+Dolphin004(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glEnd();
+}
+
+static void
+Dolphin005(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glEnd();
+}
+
+static void
+Dolphin006(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N093);
+       glVertex3fv(P093);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N093);
+       glVertex3fv(P093);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N091);
+       glVertex3fv(P091);
+       glNormal3fv(N095);
+       glVertex3fv(P095);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N091);
+       glVertex3fv(P091);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glNormal3fv(N095);
+       glVertex3fv(P095);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N122);
+       glVertex3fv(P122);
+       glNormal3fv(N095);
+       glVertex3fv(P095);
+       glNormal3fv(N091);
+       glVertex3fv(P091);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N122);
+       glVertex3fv(P122);
+       glNormal3fv(N091);
+       glVertex3fv(P091);
+       glNormal3fv(N095);
+       glVertex3fv(P095);
+       glEnd();
+}
+
+static void
+Dolphin007(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glEnd();
+}
+
+static void
+Dolphin008(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glEnd();
+}
+
+static void
+Dolphin009(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glEnd();
+}
+
+static void
+Dolphin010(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N080);
+       glVertex3fv(P080);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N090);
+       glVertex3fv(P090);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N080);
+       glVertex3fv(P080);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glNormal3fv(N090);
+       glVertex3fv(P090);
+       glEnd();
+}
+
+static void
+Dolphin011(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N082);
+       glVertex3fv(P082);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N088);
+       glVertex3fv(P088);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glNormal3fv(N088);
+       glVertex3fv(P088);
+       glNormal3fv(N089);
+       glVertex3fv(P089);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N088);
+       glVertex3fv(P088);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N089);
+       glVertex3fv(P089);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N089);
+       glVertex3fv(P089);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N082);
+       glVertex3fv(P082);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+}
+
+static void
+Dolphin012(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glEnd();
+}
+
+static void
+Dolphin013(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N116);
+       glVertex3fv(P116);
+       glNormal3fv(N117);
+       glVertex3fv(P117);
+       glNormal3fv(N112);
+       glVertex3fv(P112);
+       glNormal3fv(N113);
+       glVertex3fv(P113);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N114);
+       glVertex3fv(P114);
+       glNormal3fv(N113);
+       glVertex3fv(P113);
+       glNormal3fv(N112);
+       glVertex3fv(P112);
+       glNormal3fv(N115);
+       glVertex3fv(P115);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N114);
+       glVertex3fv(P114);
+       glNormal3fv(N116);
+       glVertex3fv(P116);
+       glNormal3fv(N113);
+       glVertex3fv(P113);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N114);
+       glVertex3fv(P114);
+       glNormal3fv(N007);
+       glVertex3fv(P007);
+       glNormal3fv(N116);
+       glVertex3fv(P116);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N007);
+       glVertex3fv(P007);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N116);
+       glVertex3fv(P116);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P002);
+       glVertex3fv(P007);
+       glVertex3fv(P008);
+       glVertex3fv(P099);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P007);
+       glVertex3fv(P114);
+       glVertex3fv(P115);
+       glVertex3fv(P008);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N117);
+       glVertex3fv(P117);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N117);
+       glVertex3fv(P117);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glNormal3fv(N112);
+       glVertex3fv(P112);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N112);
+       glVertex3fv(P112);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glNormal3fv(N115);
+       glVertex3fv(P115);
+       glEnd();
+}
+
+static void
+Dolphin014(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N111);
+       glVertex3fv(P111);
+       glNormal3fv(N110);
+       glVertex3fv(P110);
+       glNormal3fv(N102);
+       glVertex3fv(P102);
+       glNormal3fv(N121);
+       glVertex3fv(P121);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N111);
+       glVertex3fv(P111);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glNormal3fv(N110);
+       glVertex3fv(P110);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glNormal3fv(N119);
+       glVertex3fv(P119);
+       glNormal3fv(N110);
+       glVertex3fv(P110);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glNormal3fv(N119);
+       glVertex3fv(P119);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N119);
+       glVertex3fv(P119);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N119);
+       glVertex3fv(P119);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P098);
+       glVertex3fv(P097);
+       glVertex3fv(P111);
+       glVertex3fv(P121);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P002);
+       glVertex3fv(P099);
+       glVertex3fv(P097);
+       glVertex3fv(P098);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N110);
+       glVertex3fv(P110);
+       glNormal3fv(N119);
+       glVertex3fv(P119);
+       glNormal3fv(N118);
+       glVertex3fv(P118);
+       glNormal3fv(N102);
+       glVertex3fv(P102);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N119);
+       glVertex3fv(P119);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glNormal3fv(N118);
+       glVertex3fv(P118);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N118);
+       glVertex3fv(P118);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N118);
+       glVertex3fv(P118);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N098);
+       glVertex3fv(P098);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N118);
+       glVertex3fv(P118);
+       glNormal3fv(N098);
+       glVertex3fv(P098);
+       glNormal3fv(N102);
+       glVertex3fv(P102);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N102);
+       glVertex3fv(P102);
+       glNormal3fv(N098);
+       glVertex3fv(P098);
+       glNormal3fv(N121);
+       glVertex3fv(P121);
+       glEnd();
+}
+
+static void
+Dolphin015(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glNormal3fv(N120);
+       glVertex3fv(P120);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glNormal3fv(N117);
+       glVertex3fv(P117);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N120);
+       glVertex3fv(P120);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glNormal3fv(N117);
+       glVertex3fv(P117);
+       glNormal3fv(N116);
+       glVertex3fv(P116);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N120);
+       glVertex3fv(P120);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N120);
+       glVertex3fv(P120);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N120);
+       glVertex3fv(P120);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N120);
+       glVertex3fv(P120);
+       glNormal3fv(N116);
+       glVertex3fv(P116);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+}
+
+static void
+Dolphin016(GLenum cap)
+{
+
+       glDisable(GL_DEPTH_TEST);
+       glBegin(cap);
+       glVertex3fv(P123);
+       glVertex3fv(P124);
+       glVertex3fv(P125);
+       glVertex3fv(P126);
+       glVertex3fv(P127);
+       glVertex3fv(P128);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P129);
+       glVertex3fv(P130);
+       glVertex3fv(P131);
+       glVertex3fv(P132);
+       glVertex3fv(P133);
+       glVertex3fv(P134);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P103);
+       glVertex3fv(P105);
+       glVertex3fv(P108);
+       glEnd();
+       glEnable(GL_DEPTH_TEST);
+}
+
+void
+DrawDolphin(fishRec * fish, int wire)
+{
+       float       seg0, seg1, seg2, seg3, seg4, seg5, seg6, seg7;
+       float       pitch, thrash, chomp;
+       GLenum      cap;
+
+       fish->htail = (int) (fish->htail - (int) (10.0 * fish->v)) % 360;
+
+       thrash = 70.0 * fish->v;
+
+       seg0 = 1.0 * thrash * sin((fish->htail) * RRAD);
+       seg3 = 1.0 * thrash * sin((fish->htail) * RRAD);
+       seg1 = 2.0 * thrash * sin((fish->htail + 4.0) * RRAD);
+       seg2 = 3.0 * thrash * sin((fish->htail + 6.0) * RRAD);
+       seg4 = 4.0 * thrash * sin((fish->htail + 10.0) * RRAD);
+       seg5 = 4.5 * thrash * sin((fish->htail + 15.0) * RRAD);
+       seg6 = 5.0 * thrash * sin((fish->htail + 20.0) * RRAD);
+       seg7 = 6.0 * thrash * sin((fish->htail + 30.0) * RRAD);
+
+       pitch = fish->v * sin((fish->htail + 180.0) * RRAD);
+
+       if (fish->v > 2.0) {
+               chomp = -(fish->v - 2.0) * 200.0;
+       }
+       chomp = 100.0;
+
+       P012[1] = iP012[1] + seg5;
+       P013[1] = iP013[1] + seg5;
+       P014[1] = iP014[1] + seg5;
+       P015[1] = iP015[1] + seg5;
+       P016[1] = iP016[1] + seg5;
+       P017[1] = iP017[1] + seg5;
+       P018[1] = iP018[1] + seg5;
+       P019[1] = iP019[1] + seg5;
+
+       P020[1] = iP020[1] + seg4;
+       P021[1] = iP021[1] + seg4;
+       P022[1] = iP022[1] + seg4;
+       P023[1] = iP023[1] + seg4;
+       P024[1] = iP024[1] + seg4;
+       P025[1] = iP025[1] + seg4;
+       P026[1] = iP026[1] + seg4;
+       P027[1] = iP027[1] + seg4;
+
+       P028[1] = iP028[1] + seg2;
+       P029[1] = iP029[1] + seg2;
+       P030[1] = iP030[1] + seg2;
+       P031[1] = iP031[1] + seg2;
+       P032[1] = iP032[1] + seg2;
+       P033[1] = iP033[1] + seg2;
+       P034[1] = iP034[1] + seg2;
+       P035[1] = iP035[1] + seg2;
+
+       P036[1] = iP036[1] + seg1;
+       P037[1] = iP037[1] + seg1;
+       P038[1] = iP038[1] + seg1;
+       P039[1] = iP039[1] + seg1;
+       P040[1] = iP040[1] + seg1;
+       P041[1] = iP041[1] + seg1;
+       P042[1] = iP042[1] + seg1;
+       P043[1] = iP043[1] + seg1;
+
+       P044[1] = iP044[1] + seg0;
+       P045[1] = iP045[1] + seg0;
+       P046[1] = iP046[1] + seg0;
+       P047[1] = iP047[1] + seg0;
+       P048[1] = iP048[1] + seg0;
+       P049[1] = iP049[1] + seg0;
+       P050[1] = iP050[1] + seg0;
+       P051[1] = iP051[1] + seg0;
+
+       P009[1] = iP009[1] + seg6;
+       P010[1] = iP010[1] + seg6;
+       P075[1] = iP075[1] + seg6;
+       P076[1] = iP076[1] + seg6;
+
+       P001[1] = iP001[1] + seg7;
+       P011[1] = iP011[1] + seg7;
+       P068[1] = iP068[1] + seg7;
+       P069[1] = iP069[1] + seg7;
+       P070[1] = iP070[1] + seg7;
+       P071[1] = iP071[1] + seg7;
+       P072[1] = iP072[1] + seg7;
+       P073[1] = iP073[1] + seg7;
+       P074[1] = iP074[1] + seg7;
+
+       P091[1] = iP091[1] + seg3;
+       P092[1] = iP092[1] + seg3;
+       P093[1] = iP093[1] + seg3;
+       P094[1] = iP094[1] + seg3;
+       P095[1] = iP095[1] + seg3;
+       P122[1] = iP122[1] + seg3 * 1.5;
+
+       P097[1] = iP097[1] + chomp;
+       P098[1] = iP098[1] + chomp;
+       P102[1] = iP102[1] + chomp;
+       P110[1] = iP110[1] + chomp;
+       P111[1] = iP111[1] + chomp;
+       P121[1] = iP121[1] + chomp;
+       P118[1] = iP118[1] + chomp;
+       P119[1] = iP119[1] + chomp;
+
+       glPushMatrix();
+
+       glRotatef(pitch, 1.0, 0.0, 0.0);
+
+       glTranslatef(0.0, 0.0, 7000.0);
+
+       glRotatef(180.0, 0.0, 1.0, 0.0);
+
+       glEnable(GL_CULL_FACE);
+       cap = wire ? GL_LINE_LOOP : GL_POLYGON;
+       Dolphin014(cap);
+       Dolphin010(cap);
+       Dolphin009(cap);
+       Dolphin012(cap);
+       Dolphin013(cap);
+       Dolphin006(cap);
+       Dolphin002(cap);
+       Dolphin001(cap);
+       Dolphin003(cap);
+       Dolphin015(cap);
+       Dolphin004(cap);
+       Dolphin005(cap);
+       Dolphin007(cap);
+       Dolphin008(cap);
+       Dolphin011(cap);
+       Dolphin016(cap);
+       glDisable(GL_CULL_FACE);
+
+       glPopMatrix();
+}
+#endif
diff --git a/xlockmore-4.14/modes/glx/e_textures.h b/xlockmore-4.14/modes/glx/e_textures.h
new file mode 100644 (file)
index 0000000..7f9457e
--- /dev/null
@@ -0,0 +1,1478 @@
+static unsigned char WoodTextureWidth = 199;
+static unsigned char WoodTextureHeight = 37;
+static unsigned char WoodTextureData[] =
+{
+       84, 30, 12, 84, 26, 12, 108, 42, 28, 100, 38, 28, 108, 42, 28,
+       108, 46, 28, 100, 38, 28, 108, 46, 28, 108, 42, 28, 108, 42, 20,
+       108, 42, 28, 108, 38, 20, 108, 42, 20, 108, 42, 28, 116, 42, 28,
+       108, 42, 20, 108, 46, 28, 100, 34, 12, 108, 42, 20, 108, 42, 20,
+       108, 42, 20, 108, 38, 20, 100, 38, 20, 100, 38, 20, 108, 42, 20,
+       108, 42, 20, 108, 38, 20, 100, 38, 20, 108, 38, 20, 100, 38, 20,
+       108, 42, 20, 108, 42, 20, 108, 42, 28, 108, 42, 20, 108, 42, 20,
+       100, 38, 20, 100, 38, 20, 100, 38, 20, 108, 38, 20, 116, 50, 28,
+       108, 42, 28, 108, 42, 20, 100, 38, 20, 108, 42, 20, 108, 42, 20,
+       108, 46, 28, 108, 42, 20, 108, 42, 20, 108, 42, 20, 100, 38, 20,
+       108, 38, 20, 100, 38, 20, 108, 38, 20, 100, 38, 20, 100, 38, 20,
+       108, 38, 20, 100, 38, 20, 108, 38, 20, 100, 42, 20, 108, 42, 20,
+       108, 42, 28, 108, 42, 20, 100, 38, 20, 108, 42, 20, 100, 38, 20,
+       100, 34, 12, 100, 38, 20, 108, 38, 20, 100, 38, 20, 108, 42, 20,
+       108, 42, 20, 108, 42, 20, 100, 38, 20, 108, 38, 20, 100, 38, 20,
+       100, 34, 12, 100, 38, 20, 108, 38, 20, 100, 38, 20, 108, 42, 20,
+       100, 38, 20, 100, 34, 12, 100, 34, 12, 100, 38, 20, 108, 38, 20,
+       100, 38, 20, 108, 38, 20, 108, 42, 20, 100, 38, 20, 108, 42, 20,
+       108, 42, 28, 108, 46, 20, 108, 38, 20, 108, 42, 20, 108, 46, 28,
+       108, 46, 28, 108, 42, 20, 108, 42, 20, 108, 42, 20, 100, 38, 20,
+       108, 42, 20, 100, 38, 20, 108, 38, 20, 100, 38, 20, 108, 38, 20,
+       108, 42, 20, 108, 46, 28, 116, 50, 28, 116, 54, 36, 116, 54, 36,
+       116, 54, 28, 108, 46, 28, 108, 42, 20, 108, 42, 28, 108, 42, 20,
+       108, 42, 20, 108, 46, 28, 116, 50, 28, 116, 50, 28, 116, 50, 28,
+       116, 46, 28, 108, 42, 28, 116, 50, 36, 116, 50, 36, 100, 38, 20,
+       108, 42, 28, 108, 38, 20, 100, 38, 20, 108, 38, 20, 108, 42, 28,
+       108, 46, 28, 116, 46, 28, 108, 42, 28, 108, 42, 28, 108, 42, 20,
+       108, 46, 28, 116, 50, 28, 116, 50, 28, 116, 50, 28, 116, 50, 28,
+       108, 42, 28, 108, 42, 20, 100, 38, 20, 116, 50, 28, 108, 46, 28,
+       108, 42, 20, 108, 42, 20, 108, 46, 28, 116, 46, 28, 108, 46, 28,
+       108, 46, 28, 108, 46, 20, 108, 46, 28, 116, 46, 28, 108, 46, 28,
+       116, 50, 28, 108, 46, 28, 108, 46, 28, 108, 42, 20, 116, 46, 28,
+       108, 46, 28, 108, 42, 20, 108, 42, 28, 108, 46, 28, 116, 50, 28,
+       116, 50, 28, 116, 50, 36, 124, 54, 36, 116, 54, 36, 116, 54, 28,
+       116, 50, 28, 116, 50, 28, 108, 46, 28, 116, 46, 28, 108, 46, 28,
+       116, 50, 28, 116, 46, 28, 116, 50, 28, 116, 50, 28, 116, 50, 28,
+       116, 50, 28, 108, 46, 28, 108, 46, 20, 124, 50, 36, 116, 54, 28,
+       124, 54, 28, 116, 54, 28, 116, 54, 28, 116, 54, 28, 124, 54, 36,
+       124, 58, 36, 124, 50, 36, 116, 46, 28, 116, 46, 28, 116, 42, 28,
+       116, 50, 36, 124, 66, 44, 108, 58, 36, 84, 30, 12, 100, 42, 20,
+       116, 54, 36, 140, 82, 68, 148, 86, 68, 148, 86, 68, 156, 90, 76,
+       148, 86, 68, 156, 86, 76, 156, 86, 68, 148, 86, 68, 156, 86, 68,
+       156, 86, 68, 156, 86, 68, 156, 86, 68, 156, 90, 68, 156, 86, 68,
+       156, 90, 68, 164, 94, 76, 164, 98, 84, 164, 102, 84, 164, 102, 84,
+       164, 98, 76, 156, 94, 68, 164, 94, 76, 156, 94, 76, 164, 98, 84,
+       164, 98, 76, 164, 98, 76, 156, 94, 76, 164, 98, 76, 164, 98, 76,
+       164, 102, 84, 164, 102, 84, 172, 106, 84, 172, 106, 84, 164, 98, 76,
+       164, 94, 68, 164, 94, 68, 164, 98, 76, 172, 106, 84, 164, 98, 76,
+       164, 98, 76, 164, 94, 68, 164, 94, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 102, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 94, 68, 164, 98, 76, 164, 98, 76, 164, 102, 76,
+       164, 94, 76, 156, 94, 68, 172, 102, 84, 172, 106, 84, 172, 102, 84,
+       164, 98, 76, 164, 102, 76, 172, 102, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 102, 84, 164, 102, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 172, 102, 76, 164, 98, 76,
+       164, 94, 76, 156, 94, 68, 164, 98, 76, 164, 102, 76, 164, 98, 76,
+       164, 98, 76, 164, 94, 76, 156, 94, 68, 164, 94, 76, 164, 102, 76,
+       172, 106, 84, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 102, 76, 172, 102, 84,
+       172, 106, 84, 172, 110, 84, 180, 110, 92, 172, 110, 84, 172, 110, 84,
+     180, 114, 92, 188, 122, 100, 188, 122, 100, 188, 122, 100, 188, 118, 92,
+       180, 110, 92, 172, 106, 84, 172, 106, 84, 172, 106, 84, 180, 114, 92,
+   188, 118, 100, 188, 118, 100, 180, 118, 100, 188, 122, 108, 188, 126, 108,
+   188, 118, 100, 196, 130, 108, 204, 134, 116, 188, 126, 108, 196, 122, 108,
+    180, 118, 100, 180, 110, 92, 180, 114, 100, 180, 118, 100, 188, 118, 100,
+   188, 122, 108, 188, 118, 100, 188, 118, 100, 180, 118, 100, 188, 118, 100,
+     180, 118, 100, 180, 118, 100, 180, 118, 100, 180, 114, 92, 180, 114, 92,
+       172, 110, 92, 172, 106, 84, 180, 114, 92, 172, 106, 92, 172, 102, 84,
+       172, 106, 84, 172, 110, 92, 180, 110, 84, 172, 110, 92, 172, 106, 84,
+       172, 102, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 102, 84,
+       164, 102, 84, 164, 102, 76, 172, 106, 84, 172, 110, 92, 180, 110, 92,
+       172, 110, 84, 172, 114, 92, 180, 114, 92, 180, 110, 92, 172, 110, 92,
+       172, 106, 92, 172, 106, 84, 172, 106, 84, 164, 102, 84, 180, 114, 100,
+      180, 114, 92, 180, 118, 100, 180, 118, 100, 180, 114, 92, 172, 110, 92,
+       172, 106, 84, 172, 106, 84, 180, 110, 92, 180, 114, 92, 180, 114, 92,
+       172, 110, 92, 172, 110, 84, 172, 110, 92, 180, 114, 92, 180, 118, 100,
+   196, 126, 100, 196, 122, 108, 196, 126, 108, 196, 130, 116, 196, 134, 116,
+       204, 142, 124, 164, 106, 84, 100, 42, 20, 84, 26, 4, 132, 78, 68,
+   188, 122, 108, 188, 122, 108, 188, 126, 116, 196, 134, 116, 188, 122, 108,
+   188, 126, 108, 188, 126, 108, 188, 122, 108, 196, 126, 108, 196, 130, 108,
+   188, 126, 108, 188, 122, 100, 196, 126, 108, 196, 126, 108, 188, 126, 108,
+   196, 130, 108, 196, 130, 108, 196, 134, 116, 196, 130, 108, 196, 130, 108,
+   188, 126, 108, 196, 126, 108, 188, 126, 108, 196, 130, 108, 188, 126, 108,
+   188, 126, 108, 196, 126, 108, 188, 126, 108, 196, 130, 108, 196, 130, 108,
+   196, 134, 116, 204, 142, 116, 204, 134, 116, 196, 130, 108, 196, 130, 108,
+   188, 126, 108, 196, 126, 100, 196, 134, 108, 196, 130, 108, 188, 126, 100,
+   188, 122, 100, 188, 126, 108, 196, 126, 100, 188, 126, 108, 196, 126, 100,
+   188, 126, 100, 196, 130, 108, 204, 134, 108, 196, 134, 116, 196, 134, 108,
+   196, 130, 108, 196, 126, 108, 196, 130, 108, 196, 130, 108, 196, 130, 108,
+   188, 126, 108, 196, 126, 108, 196, 134, 108, 196, 130, 108, 196, 130, 108,
+   188, 122, 100, 196, 130, 108, 196, 130, 108, 196, 134, 108, 196, 130, 108,
+   188, 126, 100, 196, 130, 108, 196, 134, 108, 204, 134, 116, 204, 138, 116,
+   204, 138, 116, 204, 134, 116, 196, 130, 108, 196, 130, 108, 196, 134, 108,
+   204, 134, 116, 196, 134, 116, 196, 134, 108, 196, 130, 108, 196, 130, 108,
+   204, 134, 116, 204, 138, 116, 204, 138, 116, 196, 130, 108, 196, 130, 108,
+    188, 122, 100, 180, 118, 92, 188, 118, 100, 196, 130, 108, 196, 130, 108,
+   188, 126, 100, 188, 122, 100, 188, 122, 100, 204, 134, 108, 196, 134, 116,
+   204, 134, 116, 196, 134, 108, 196, 130, 108, 204, 134, 108, 204, 138, 116,
+   204, 138, 116, 212, 142, 124, 204, 142, 116, 204, 134, 116, 204, 138, 116,
+   204, 138, 116, 204, 138, 116, 204, 134, 108, 188, 126, 108, 196, 130, 108,
+   196, 126, 100, 188, 122, 100, 196, 130, 108, 204, 138, 116, 212, 146, 124,
+   204, 142, 116, 204, 138, 116, 212, 146, 124, 212, 142, 124, 204, 138, 124,
+   204, 138, 124, 204, 138, 124, 204, 138, 116, 212, 142, 124, 204, 138, 124,
+   196, 130, 116, 204, 134, 116, 204, 138, 116, 204, 138, 124, 204, 138, 116,
+   204, 138, 124, 204, 134, 116, 204, 138, 124, 212, 142, 124, 204, 138, 116,
+   196, 134, 116, 196, 130, 108, 196, 134, 116, 204, 138, 116, 204, 142, 124,
+   212, 142, 124, 204, 138, 116, 204, 138, 116, 204, 138, 116, 204, 138, 116,
+   204, 138, 124, 204, 142, 124, 204, 142, 116, 204, 138, 124, 196, 134, 108,
+   196, 134, 116, 196, 134, 116, 196, 130, 116, 196, 130, 108, 188, 126, 108,
+   196, 126, 108, 188, 130, 108, 188, 126, 108, 188, 122, 100, 180, 118, 100,
+   188, 118, 100, 188, 126, 108, 196, 130, 108, 196, 126, 108, 188, 126, 108,
+   188, 122, 100, 188, 122, 108, 188, 126, 108, 196, 126, 108, 196, 130, 108,
+   188, 126, 108, 196, 126, 108, 188, 126, 108, 196, 134, 108, 196, 134, 116,
+   196, 134, 108, 196, 130, 108, 196, 126, 108, 188, 122, 108, 188, 122, 100,
+   188, 122, 100, 196, 130, 108, 196, 130, 100, 196, 130, 108, 196, 130, 100,
+   188, 130, 108, 196, 130, 108, 196, 134, 108, 204, 138, 116, 204, 130, 108,
+   204, 134, 116, 204, 134, 116, 204, 134, 116, 204, 138, 124, 204, 146, 124,
+       156, 102, 84, 84, 26, 4, 84, 26, 4, 116, 58, 36, 164, 106, 92,
+       164, 102, 84, 164, 106, 92, 172, 110, 92, 156, 98, 84, 172, 102, 84,
+      172, 102, 84, 180, 110, 92, 180, 118, 100, 180, 118, 100, 180, 110, 92,
+       180, 110, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 172, 106, 92,
+       172, 106, 84, 172, 106, 84, 172, 106, 92, 172, 110, 92, 172, 110, 92,
+       172, 106, 84, 172, 106, 84, 164, 102, 84, 164, 102, 84, 172, 102, 76,
+       164, 102, 84, 172, 106, 84, 172, 106, 84, 172, 110, 92, 172, 110, 84,
+       180, 110, 92, 172, 110, 84, 180, 110, 92, 172, 110, 84, 172, 106, 84,
+       172, 110, 84, 180, 110, 92, 172, 106, 84, 172, 102, 84, 164, 102, 84,
+       172, 102, 76, 172, 102, 84, 172, 102, 84, 164, 102, 76, 164, 94, 76,
+       172, 102, 84, 172, 110, 92, 172, 110, 84, 172, 102, 84, 164, 98, 76,
+       172, 102, 76, 172, 106, 84, 172, 110, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 180, 114, 92, 180, 114, 92, 172, 110, 84, 172, 106, 84,
+       172, 102, 76, 172, 110, 84, 172, 110, 84, 172, 102, 84, 172, 102, 84,
+       172, 106, 84, 180, 110, 92, 172, 110, 84, 180, 118, 92, 180, 114, 92,
+       180, 110, 92, 172, 110, 84, 180, 110, 92, 180, 114, 92, 180, 118, 92,
+      188, 122, 100, 188, 118, 100, 180, 114, 92, 180, 118, 92, 180, 114, 92,
+       180, 118, 92, 188, 118, 100, 180, 118, 92, 180, 114, 92, 180, 118, 92,
+      180, 110, 84, 180, 110, 92, 180, 118, 92, 188, 122, 100, 188, 114, 100,
+     180, 114, 92, 180, 114, 92, 196, 126, 108, 188, 126, 100, 188, 122, 100,
+    188, 118, 100, 180, 118, 100, 180, 114, 92, 188, 118, 100, 188, 122, 100,
+       180, 110, 92, 172, 110, 84, 180, 110, 92, 180, 114, 92, 188, 122, 100,
+      188, 126, 100, 188, 118, 100, 180, 114, 92, 172, 110, 84, 172, 110, 92,
+      180, 114, 92, 180, 114, 92, 180, 118, 92, 188, 118, 100, 188, 122, 100,
+       188, 122, 100, 180, 106, 92, 172, 110, 92, 172, 102, 84, 172, 102, 84,
+       164, 94, 76, 164, 94, 76, 164, 98, 76, 164, 102, 84, 172, 102, 84,
+       172, 106, 84, 180, 110, 92, 180, 110, 92, 180, 110, 92, 172, 106, 92,
+       172, 106, 84, 172, 106, 92, 172, 110, 84, 164, 102, 84, 164, 98, 76,
+       164, 94, 76, 164, 98, 76, 172, 110, 92, 180, 114, 92, 180, 118, 100,
+   180, 118, 100, 188, 122, 100, 180, 122, 108, 188, 122, 100, 188, 122, 100,
+   188, 122, 100, 188, 122, 100, 188, 126, 108, 188, 122, 100, 188, 126, 108,
+     188, 122, 100, 188, 122, 100, 180, 118, 100, 180, 114, 92, 180, 114, 92,
+       180, 118, 100, 180, 110, 92, 172, 110, 92, 172, 106, 84, 180, 110, 92,
+       180, 118, 92, 180, 118, 100, 180, 114, 92, 180, 110, 92, 172, 110, 84,
+       172, 110, 92, 180, 114, 92, 180, 114, 92, 180, 118, 92, 180, 118, 92,
+       180, 114, 92, 180, 118, 92, 180, 110, 92, 180, 110, 92, 180, 114, 92,
+       172, 110, 92, 172, 106, 84, 172, 106, 84, 172, 106, 92, 172, 110, 84,
+       180, 110, 92, 180, 114, 92, 180, 118, 92, 180, 118, 92, 180, 118, 92,
+     180, 118, 92, 188, 118, 100, 188, 122, 100, 180, 114, 100, 180, 110, 92,
+       188, 114, 100, 180, 110, 92, 172, 110, 92, 180, 126, 108, 148, 98, 76,
+       84, 26, 4, 84, 26, 12, 108, 50, 36, 164, 102, 84, 164, 98, 84,
+       156, 94, 76, 164, 98, 84, 148, 86, 68, 156, 90, 76, 156, 94, 84,
+       164, 90, 76, 164, 98, 84, 172, 102, 84, 164, 94, 76, 156, 90, 68,
+       164, 94, 76, 164, 98, 84, 164, 94, 76, 164, 98, 76, 164, 98, 84,
+       164, 98, 76, 172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       164, 102, 84, 164, 94, 68, 164, 94, 76, 156, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 84, 164, 102, 84, 172, 102, 84, 164, 98, 76,
+       164, 98, 76, 172, 102, 84, 172, 106, 84, 172, 106, 84, 180, 106, 84,
+       172, 110, 84, 172, 106, 84, 164, 102, 76, 164, 98, 76, 164, 98, 76,
+       164, 102, 76, 164, 102, 76, 164, 98, 76, 164, 98, 76, 172, 106, 84,
+       180, 110, 84, 172, 106, 84, 164, 98, 76, 164, 98, 76, 172, 106, 84,
+       180, 114, 92, 172, 106, 84, 164, 102, 76, 164, 98, 76, 172, 106, 84,
+       180, 110, 92, 180, 114, 92, 180, 110, 92, 172, 106, 84, 172, 106, 84,
+       180, 114, 92, 188, 118, 100, 180, 114, 92, 172, 110, 84, 180, 114, 92,
+       180, 114, 92, 180, 114, 92, 172, 110, 92, 172, 106, 84, 164, 102, 76,
+       172, 102, 76, 164, 102, 84, 180, 110, 84, 180, 118, 92, 188, 118, 100,
+       188, 122, 100, 180, 118, 92, 180, 110, 92, 180, 110, 84, 172, 106, 92,
+     180, 114, 84, 180, 114, 100, 188, 122, 100, 188, 122, 100, 180, 114, 92,
+       172, 110, 92, 180, 114, 92, 188, 118, 92, 180, 114, 92, 180, 114, 92,
+       180, 118, 92, 164, 102, 84, 172, 102, 84, 172, 106, 84, 172, 102, 76,
+       164, 102, 76, 172, 102, 84, 172, 110, 84, 180, 114, 92, 172, 110, 84,
+       172, 102, 84, 172, 106, 84, 180, 110, 84, 180, 118, 100, 188, 118, 92,
+       180, 110, 92, 172, 106, 84, 172, 106, 84, 180, 110, 92, 188, 118, 92,
+      180, 118, 100, 180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 118, 100,
+     180, 114, 92, 188, 122, 100, 188, 126, 108, 188, 118, 100, 172, 110, 92,
+       172, 102, 84, 172, 106, 84, 180, 106, 92, 164, 98, 76, 172, 102, 84,
+       172, 106, 92, 172, 106, 84, 172, 106, 84, 172, 102, 84, 172, 102, 84,
+       172, 102, 84, 172, 106, 84, 164, 102, 84, 164, 98, 76, 164, 98, 76,
+       172, 106, 84, 172, 110, 92, 180, 114, 92, 180, 114, 92, 180, 118, 100,
+   188, 122, 100, 188, 122, 100, 188, 126, 108, 188, 122, 100, 188, 122, 100,
+    188, 122, 108, 196, 126, 108, 180, 118, 92, 188, 118, 100, 180, 118, 100,
+      180, 118, 100, 180, 114, 92, 180, 110, 92, 180, 114, 92, 180, 118, 100,
+       180, 110, 92, 172, 110, 84, 172, 106, 92, 172, 110, 92, 188, 118, 100,
+       180, 118, 100, 180, 114, 92, 172, 106, 84, 180, 110, 92, 180, 114, 92,
+       172, 110, 92, 180, 114, 92, 180, 114, 100, 180, 114, 92, 172, 110, 92,
+       172, 110, 92, 180, 114, 92, 180, 114, 92, 180, 114, 100, 180, 110, 92,
+       172, 110, 92, 172, 110, 92, 180, 114, 92, 180, 118, 92, 172, 106, 84,
+      180, 110, 84, 180, 118, 92, 188, 122, 100, 180, 118, 100, 180, 118, 92,
+       180, 118, 92, 180, 114, 92, 180, 110, 92, 180, 110, 92, 188, 118, 108,
+       188, 118, 100, 188, 122, 100, 188, 130, 108, 156, 102, 84, 84, 26, 12,
+       84, 30, 12, 108, 46, 28, 140, 82, 68, 156, 90, 76, 156, 94, 84,
+       156, 94, 84, 156, 94, 76, 164, 94, 76, 156, 90, 76, 164, 94, 76,
+       156, 94, 76, 156, 90, 68, 156, 90, 68, 164, 90, 76, 156, 90, 68,
+       148, 82, 60, 148, 78, 60, 164, 98, 76, 164, 94, 76, 156, 90, 68,
+       156, 90, 68, 156, 94, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       156, 90, 68, 148, 86, 68, 156, 90, 68, 156, 90, 68, 156, 90, 76,
+       164, 94, 68, 156, 94, 76, 156, 94, 68, 156, 90, 68, 156, 90, 68,
+       172, 102, 76, 180, 114, 92, 188, 118, 92, 172, 106, 84, 180, 106, 84,
+       172, 106, 84, 164, 98, 76, 164, 94, 68, 164, 98, 76, 172, 102, 84,
+       172, 106, 84, 172, 102, 76, 164, 98, 76, 172, 106, 84, 180, 110, 92,
+       172, 110, 84, 172, 98, 76, 164, 98, 76, 172, 106, 84, 180, 118, 92,
+       180, 106, 84, 180, 106, 84, 172, 106, 84, 172, 110, 84, 180, 110, 92,
+       180, 110, 84, 172, 102, 76, 164, 98, 76, 164, 94, 68, 172, 106, 84,
+       180, 114, 92, 172, 106, 84, 164, 98, 76, 172, 98, 76, 172, 106, 84,
+       172, 106, 84, 180, 106, 84, 180, 110, 84, 172, 110, 84, 180, 110, 92,
+       180, 110, 84, 180, 110, 92, 180, 110, 84, 172, 106, 84, 188, 118, 92,
+       188, 114, 92, 172, 106, 84, 172, 102, 76, 172, 106, 84, 188, 118, 92,
+      188, 122, 100, 188, 118, 100, 188, 118, 92, 180, 110, 92, 180, 114, 84,
+       180, 114, 92, 180, 110, 92, 172, 106, 84, 164, 98, 76, 172, 102, 76,
+       180, 106, 84, 180, 114, 84, 172, 102, 76, 164, 94, 76, 172, 106, 84,
+       180, 110, 84, 172, 106, 84, 172, 106, 84, 188, 122, 100, 188, 118, 92,
+     180, 118, 92, 188, 118, 100, 196, 122, 100, 188, 122, 100, 180, 118, 92,
+       180, 110, 84, 188, 114, 92, 172, 110, 84, 172, 106, 84, 180, 114, 92,
+       188, 114, 92, 180, 114, 92, 180, 114, 84, 180, 114, 92, 180, 110, 92,
+       180, 110, 92, 180, 110, 92, 172, 106, 84, 164, 98, 76, 172, 110, 92,
+     188, 118, 100, 180, 118, 92, 180, 110, 92, 180, 114, 100, 180, 118, 100,
+       172, 106, 84, 164, 94, 76, 164, 98, 76, 172, 102, 76, 164, 102, 84,
+       164, 102, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 172, 106, 92, 180, 118, 92, 180, 118, 100,
+       180, 114, 92, 180, 110, 92, 180, 114, 92, 180, 114, 100, 180, 118, 92,
+    180, 118, 100, 188, 122, 108, 188, 122, 100, 188, 118, 100, 180, 114, 92,
+       180, 114, 92, 172, 110, 92, 172, 110, 92, 172, 106, 84, 188, 122, 100,
+       180, 114, 100, 172, 106, 84, 172, 110, 84, 180, 114, 92, 180, 114, 92,
+       180, 110, 92, 172, 110, 92, 172, 106, 84, 172, 110, 92, 180, 114, 92,
+       180, 118, 100, 180, 114, 92, 172, 110, 92, 172, 110, 92, 180, 110, 92,
+       164, 106, 84, 172, 106, 84, 172, 110, 84, 172, 110, 92, 172, 110, 92,
+       180, 110, 84, 172, 110, 92, 172, 110, 84, 180, 110, 92, 180, 110, 92,
+       180, 114, 92, 180, 118, 92, 180, 118, 92, 180, 118, 100, 188, 118, 92,
+     188, 118, 100, 180, 110, 92, 180, 110, 92, 188, 118, 100, 188, 118, 100,
+       180, 118, 100, 180, 122, 108, 148, 90, 68, 84, 30, 12, 92, 34, 12,
+       116, 58, 44, 156, 90, 76, 156, 94, 76, 156, 94, 76, 156, 90, 76,
+       148, 86, 68, 156, 90, 76, 148, 86, 68, 156, 86, 68, 156, 86, 68,
+       156, 90, 68, 156, 90, 76, 156, 90, 68, 156, 86, 68, 148, 78, 60,
+       140, 74, 52, 148, 82, 68, 148, 82, 60, 148, 86, 68, 156, 90, 68,
+       156, 94, 76, 164, 98, 76, 164, 98, 84, 164, 98, 76, 148, 86, 68,
+       156, 86, 68, 156, 90, 68, 156, 90, 76, 156, 94, 68, 156, 94, 76,
+       164, 94, 76, 164, 98, 76, 172, 102, 76, 164, 98, 76, 172, 102, 76,
+       172, 106, 84, 180, 110, 92, 172, 106, 84, 164, 98, 76, 172, 102, 76,
+       172, 102, 84, 164, 94, 68, 164, 94, 76, 172, 102, 76, 180, 110, 84,
+       180, 110, 92, 164, 98, 76, 172, 102, 76, 172, 106, 84, 172, 102, 76,
+       164, 98, 76, 164, 98, 76, 172, 102, 76, 180, 110, 92, 180, 110, 92,
+       172, 110, 84, 172, 106, 84, 180, 106, 84, 180, 114, 84, 180, 110, 92,
+       172, 102, 84, 164, 98, 76, 156, 94, 68, 172, 106, 84, 188, 114, 92,
+       180, 110, 84, 172, 106, 84, 172, 102, 76, 172, 106, 84, 180, 110, 84,
+       172, 106, 84, 172, 106, 84, 180, 110, 84, 180, 110, 92, 180, 114, 84,
+       172, 110, 84, 172, 106, 84, 172, 106, 84, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 90, 68, 164, 98, 76, 172, 102, 84, 172, 106, 76,
+       172, 102, 76, 172, 106, 84, 172, 106, 84, 180, 110, 84, 180, 114, 92,
+       188, 114, 92, 180, 110, 84, 180, 110, 92, 180, 114, 92, 172, 106, 84,
+       180, 114, 92, 172, 106, 84, 164, 94, 68, 172, 106, 84, 180, 114, 92,
+     188, 118, 92, 196, 126, 100, 188, 122, 100, 188, 122, 100, 188, 118, 92,
+       180, 118, 92, 188, 118, 100, 188, 118, 92, 180, 114, 92, 172, 106, 84,
+       180, 114, 92, 180, 106, 84, 172, 102, 76, 172, 102, 76, 172, 106, 84,
+       172, 102, 84, 172, 106, 84, 180, 110, 84, 172, 102, 84, 164, 102, 84,
+       172, 102, 84, 164, 94, 76, 156, 90, 68, 164, 94, 76, 180, 106, 92,
+       172, 102, 84, 164, 98, 84, 180, 110, 84, 180, 110, 92, 164, 98, 84,
+       164, 94, 76, 164, 98, 76, 164, 98, 84, 172, 98, 76, 164, 102, 84,
+       164, 102, 84, 172, 102, 84, 164, 106, 84, 172, 106, 92, 172, 106, 92,
+     172, 110, 92, 180, 110, 84, 180, 118, 100, 188, 118, 100, 180, 118, 100,
+       180, 114, 92, 172, 114, 92, 180, 110, 92, 180, 110, 92, 180, 114, 92,
+      180, 118, 100, 180, 118, 92, 180, 114, 100, 180, 114, 92, 180, 110, 92,
+       172, 110, 92, 180, 110, 92, 172, 114, 92, 188, 118, 100, 180, 114, 92,
+       172, 110, 92, 172, 106, 84, 172, 110, 92, 172, 110, 92, 172, 110, 84,
+       164, 102, 84, 172, 102, 84, 172, 110, 92, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 180, 110, 92, 172, 106, 84, 172, 106, 84, 172, 110, 92,
+       180, 110, 92, 180, 114, 92, 180, 114, 92, 180, 118, 100, 180, 114, 92,
+       180, 114, 100, 180, 114, 92, 180, 114, 92, 180, 118, 92, 188, 118, 92,
+    188, 122, 92, 180, 122, 100, 188, 122, 100, 180, 122, 100, 188, 118, 100,
+   196, 122, 100, 188, 118, 100, 196, 122, 108, 180, 114, 100, 180, 114, 100,
+       180, 126, 108, 148, 98, 76, 92, 34, 12, 84, 26, 12, 116, 58, 36,
+       148, 90, 76, 148, 90, 76, 140, 82, 68, 148, 82, 68, 140, 78, 60,
+       156, 86, 68, 148, 86, 68, 156, 90, 68, 156, 90, 76, 164, 94, 76,
+       156, 90, 76, 156, 90, 68, 148, 82, 68, 148, 78, 60, 140, 78, 60,
+       156, 86, 68, 148, 86, 68, 156, 86, 68, 156, 90, 68, 156, 94, 76,
+       164, 94, 76, 156, 94, 76, 148, 86, 68, 148, 82, 60, 148, 86, 68,
+       156, 90, 68, 156, 90, 76, 156, 90, 68, 156, 90, 68, 156, 94, 76,
+       164, 102, 76, 172, 102, 84, 172, 102, 76, 172, 106, 84, 180, 110, 84,
+       180, 114, 84, 180, 110, 84, 172, 102, 76, 180, 106, 84, 172, 106, 76,
+       172, 98, 76, 164, 98, 68, 172, 106, 76, 172, 106, 84, 180, 110, 84,
+       172, 98, 76, 180, 106, 84, 180, 110, 84, 180, 110, 84, 172, 98, 76,
+       172, 98, 76, 180, 106, 84, 180, 114, 84, 188, 114, 92, 180, 110, 84,
+       180, 110, 84, 180, 110, 84, 180, 114, 92, 180, 110, 84, 172, 106, 84,
+       164, 98, 68, 164, 94, 68, 180, 106, 84, 188, 118, 92, 180, 114, 92,
+       180, 110, 84, 180, 110, 84, 180, 110, 92, 180, 110, 84, 172, 106, 76,
+       180, 106, 84, 180, 110, 84, 180, 114, 92, 188, 114, 92, 180, 110, 84,
+       180, 106, 84, 172, 106, 76, 180, 106, 84, 188, 114, 92, 180, 114, 84,
+       180, 110, 84, 180, 114, 92, 188, 118, 92, 188, 118, 92, 180, 110, 84,
+       180, 106, 84, 172, 106, 76, 180, 106, 84, 188, 114, 92, 188, 118, 92,
+       180, 118, 92, 188, 118, 92, 196, 122, 100, 172, 106, 84, 188, 114, 84,
+       172, 106, 84, 164, 98, 68, 172, 102, 76, 180, 106, 84, 180, 110, 84,
+       188, 118, 92, 188, 122, 92, 188, 114, 92, 180, 110, 92, 180, 114, 84,
+       188, 118, 92, 188, 118, 92, 180, 110, 84, 172, 102, 84, 188, 122, 92,
+       180, 110, 84, 164, 102, 76, 172, 102, 76, 172, 98, 76, 172, 102, 76,
+       172, 102, 76, 180, 106, 84, 180, 110, 92, 180, 106, 84, 180, 106, 84,
+       172, 102, 76, 164, 90, 76, 172, 98, 76, 180, 110, 92, 172, 102, 76,
+       172, 102, 84, 180, 106, 84, 180, 110, 84, 172, 102, 84, 172, 98, 76,
+       164, 94, 76, 164, 98, 76, 164, 98, 76, 172, 98, 84, 164, 98, 76,
+       164, 102, 84, 172, 106, 84, 172, 106, 84, 172, 110, 92, 180, 114, 92,
+    180, 114, 92, 188, 122, 100, 188, 122, 100, 188, 122, 100, 180, 118, 100,
+       172, 106, 92, 172, 106, 84, 164, 106, 84, 172, 106, 84, 180, 114, 92,
+       180, 110, 92, 172, 110, 84, 172, 110, 92, 180, 110, 92, 172, 110, 92,
+       180, 114, 92, 180, 114, 92, 180, 118, 92, 172, 110, 92, 172, 106, 84,
+       172, 106, 84, 172, 110, 92, 172, 106, 84, 164, 102, 84, 164, 94, 76,
+       164, 98, 76, 172, 110, 92, 180, 114, 92, 172, 106, 92, 172, 106, 92,
+       172, 110, 84, 172, 106, 92, 164, 102, 84, 172, 110, 92, 180, 110, 92,
+       172, 110, 92, 180, 114, 92, 180, 114, 92, 180, 118, 100, 180, 114, 92,
+       180, 118, 92, 180, 114, 92, 188, 114, 92, 180, 118, 92, 180, 118, 100,
+       180, 118, 92, 180, 118, 100, 188, 118, 92, 180, 118, 92, 180, 110, 92,
+       180, 106, 92, 180, 110, 92, 172, 106, 92, 172, 106, 84, 172, 114, 92,
+       140, 90, 68, 84, 26, 12, 84, 30, 12, 116, 58, 44, 156, 90, 76,
+       156, 90, 76, 148, 86, 68, 148, 86, 76, 148, 86, 68, 156, 90, 76,
+       156, 90, 76, 164, 94, 84, 164, 98, 76, 164, 94, 76, 156, 90, 68,
+       156, 86, 68, 156, 86, 60, 156, 90, 68, 156, 90, 76, 164, 94, 76,
+       156, 94, 68, 156, 94, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       156, 94, 76, 156, 94, 68, 148, 78, 60, 148, 86, 68, 156, 90, 68,
+       156, 90, 68, 148, 86, 68, 156, 86, 68, 156, 90, 68, 164, 98, 76,
+       164, 94, 68, 172, 98, 76, 180, 106, 84, 188, 118, 92, 188, 118, 92,
+       188, 118, 100, 180, 114, 92, 180, 114, 84, 180, 106, 84, 172, 102, 76,
+       172, 98, 76, 172, 106, 84, 180, 106, 84, 164, 98, 68, 172, 102, 76,
+       180, 114, 84, 196, 122, 100, 188, 118, 92, 172, 106, 76, 172, 102, 76,
+       180, 110, 84, 188, 122, 92, 188, 118, 92, 188, 114, 92, 180, 110, 84,
+       188, 114, 84, 188, 114, 92, 180, 114, 84, 180, 106, 84, 172, 102, 76,
+       164, 94, 68, 180, 110, 84, 188, 118, 92, 188, 118, 92, 188, 114, 92,
+       180, 114, 92, 188, 114, 84, 180, 114, 92, 180, 106, 84, 180, 110, 84,
+       180, 114, 84, 188, 114, 92, 180, 114, 84, 180, 110, 92, 180, 110, 84,
+       180, 106, 84, 180, 114, 84, 188, 114, 92, 188, 114, 92, 180, 114, 92,
+       188, 118, 92, 196, 122, 100, 188, 122, 92, 180, 114, 92, 188, 114, 92,
+       180, 110, 84, 180, 114, 84, 188, 118, 92, 188, 122, 92, 188, 118, 92,
+       188, 118, 92, 188, 122, 92, 188, 118, 92, 196, 122, 100, 188, 118, 92,
+      188, 114, 92, 188, 122, 100, 196, 126, 100, 188, 118, 92, 188, 114, 92,
+       188, 114, 92, 180, 114, 84, 180, 110, 84, 180, 110, 84, 188, 118, 92,
+       188, 118, 92, 188, 118, 92, 180, 114, 84, 196, 126, 100, 188, 114, 92,
+       180, 106, 84, 172, 106, 76, 172, 102, 76, 172, 102, 76, 172, 106, 76,
+       180, 110, 84, 188, 118, 92, 180, 110, 92, 180, 114, 92, 180, 106, 92,
+       164, 98, 76, 180, 106, 84, 188, 114, 100, 180, 106, 84, 180, 110, 92,
+       180, 110, 92, 188, 114, 92, 180, 110, 92, 172, 106, 84, 172, 98, 76,
+       172, 98, 76, 164, 98, 76, 164, 102, 76, 164, 102, 84, 172, 102, 84,
+      172, 106, 84, 172, 110, 92, 180, 118, 92, 180, 114, 100, 180, 118, 100,
+     188, 122, 108, 188, 126, 100, 188, 118, 100, 180, 114, 92, 172, 106, 84,
+       164, 102, 84, 172, 102, 84, 172, 110, 92, 172, 110, 92, 172, 110, 84,
+       172, 106, 92, 172, 106, 84, 172, 110, 84, 172, 110, 92, 180, 110, 92,
+       180, 114, 92, 180, 110, 92, 172, 110, 92, 172, 110, 92, 180, 110, 92,
+       172, 110, 92, 180, 110, 84, 164, 102, 84, 164, 98, 76, 156, 94, 76,
+       172, 106, 84, 180, 114, 92, 172, 106, 84, 164, 102, 84, 172, 110, 84,
+       172, 106, 84, 164, 98, 76, 172, 102, 84, 164, 106, 84, 172, 106, 84,
+       172, 106, 92, 172, 110, 92, 180, 110, 92, 180, 110, 92, 172, 110, 92,
+       180, 106, 84, 172, 110, 84, 172, 110, 84, 180, 110, 84, 172, 110, 84,
+       172, 110, 84, 172, 106, 84, 172, 106, 84, 180, 106, 92, 180, 106, 84,
+     188, 114, 100, 188, 118, 100, 180, 114, 100, 180, 126, 108, 148, 90, 68,
+       84, 30, 12, 92, 34, 12, 124, 66, 44, 156, 98, 84, 164, 102, 84,
+       164, 98, 84, 164, 98, 84, 156, 94, 76, 164, 98, 84, 164, 98, 76,
+       156, 90, 76, 156, 94, 76, 164, 94, 76, 156, 90, 76, 156, 90, 68,
+       156, 86, 68, 156, 86, 68, 164, 94, 68, 156, 90, 76, 156, 94, 68,
+       156, 90, 76, 164, 98, 76, 164, 102, 84, 172, 106, 84, 172, 106, 84,
+       172, 102, 84, 148, 82, 60, 148, 86, 68, 156, 90, 68, 156, 90, 68,
+       148, 86, 68, 148, 82, 60, 156, 86, 68, 156, 94, 68, 156, 86, 68,
+       164, 98, 68, 180, 110, 84, 188, 118, 92, 196, 122, 92, 196, 122, 100,
+       188, 118, 92, 188, 118, 92, 180, 110, 92, 172, 106, 76, 172, 106, 76,
+       180, 106, 84, 180, 106, 84, 172, 102, 76, 180, 110, 84, 188, 118, 92,
+      196, 126, 100, 188, 118, 100, 180, 110, 84, 172, 106, 84, 188, 114, 84,
+      188, 122, 100, 196, 122, 100, 188, 118, 92, 180, 114, 84, 180, 114, 92,
+       188, 118, 92, 188, 118, 92, 180, 110, 84, 180, 106, 84, 172, 102, 76,
+       180, 110, 84, 196, 122, 100, 188, 122, 92, 188, 118, 92, 188, 118, 92,
+       188, 122, 92, 188, 114, 92, 188, 114, 84, 180, 114, 92, 188, 114, 84,
+       180, 110, 92, 180, 114, 84, 188, 114, 92, 180, 114, 84, 188, 114, 92,
+       180, 114, 92, 188, 114, 92, 180, 114, 84, 180, 110, 84, 180, 110, 84,
+       188, 118, 92, 188, 114, 92, 180, 114, 84, 188, 118, 92, 180, 114, 92,
+       188, 114, 92, 188, 122, 92, 188, 118, 100, 188, 118, 92, 188, 118, 92,
+       196, 122, 100, 180, 114, 92, 188, 118, 92, 180, 110, 84, 180, 110, 84,
+    196, 130, 100, 204, 134, 108, 196, 126, 100, 188, 118, 100, 188, 122, 92,
+      188, 114, 92, 188, 114, 92, 188, 114, 92, 188, 122, 100, 196, 122, 100,
+      196, 122, 100, 188, 118, 92, 188, 118, 100, 188, 118, 92, 180, 110, 84,
+       180, 110, 84, 180, 110, 84, 172, 102, 76, 172, 102, 76, 180, 110, 84,
+       180, 110, 92, 172, 106, 84, 180, 106, 84, 172, 98, 76, 164, 94, 68,
+       172, 106, 84, 180, 110, 92, 172, 106, 84, 180, 110, 84, 180, 110, 84,
+       180, 114, 92, 180, 110, 92, 180, 110, 92, 172, 106, 84, 180, 106, 84,
+       172, 106, 84, 172, 102, 84, 172, 102, 76, 164, 102, 84, 172, 110, 92,
+     180, 114, 92, 188, 118, 100, 188, 122, 100, 188, 118, 92, 188, 126, 108,
+      188, 122, 100, 180, 118, 100, 172, 110, 92, 164, 106, 84, 172, 102, 84,
+       172, 106, 84, 180, 114, 92, 180, 110, 92, 172, 110, 92, 172, 106, 84,
+       172, 106, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 110, 92,
+       172, 110, 92, 172, 110, 92, 172, 110, 84, 180, 110, 92, 172, 114, 92,
+       180, 110, 92, 172, 106, 92, 172, 106, 84, 156, 94, 68, 172, 106, 92,
+       180, 114, 92, 172, 102, 84, 164, 102, 84, 180, 110, 92, 172, 106, 92,
+       164, 98, 76, 164, 102, 84, 172, 102, 84, 164, 102, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 110, 84, 172, 102, 84,
+       172, 106, 84, 172, 106, 84, 172, 110, 84, 172, 106, 84, 164, 106, 84,
+       172, 106, 84, 172, 102, 84, 172, 102, 84, 172, 102, 84, 180, 114, 100,
+       188, 118, 100, 180, 118, 100, 188, 126, 100, 148, 94, 76, 92, 34, 12,
+       92, 34, 12, 116, 62, 44, 156, 94, 76, 164, 94, 84, 156, 94, 76,
+       156, 94, 76, 148, 86, 68, 148, 86, 76, 148, 82, 68, 148, 78, 60,
+       148, 82, 68, 156, 90, 68, 156, 94, 76, 164, 90, 76, 156, 90, 68,
+       148, 82, 68, 148, 82, 60, 164, 94, 76, 156, 94, 76, 156, 94, 68,
+       164, 94, 76, 164, 102, 84, 164, 102, 84, 172, 102, 84, 164, 102, 84,
+       156, 90, 68, 156, 90, 68, 156, 94, 76, 156, 90, 68, 148, 86, 68,
+       148, 86, 68, 156, 90, 68, 156, 90, 68, 164, 98, 76, 172, 106, 84,
+       180, 110, 84, 180, 110, 84, 180, 114, 92, 188, 118, 92, 180, 110, 84,
+       188, 118, 92, 188, 118, 92, 180, 110, 84, 180, 106, 84, 180, 114, 84,
+       180, 114, 84, 180, 114, 92, 188, 114, 84, 180, 114, 92, 188, 114, 84,
+       188, 118, 92, 188, 114, 92, 180, 114, 92, 188, 114, 84, 180, 110, 84,
+       196, 122, 100, 188, 118, 92, 188, 114, 92, 188, 114, 92, 188, 118, 92,
+       188, 118, 92, 188, 118, 92, 180, 110, 84, 172, 106, 84, 188, 114, 92,
+    196, 122, 100, 188, 122, 100, 196, 122, 92, 196, 122, 100, 188, 122, 100,
+       188, 118, 92, 188, 122, 100, 188, 118, 92, 188, 118, 92, 188, 114, 92,
+       188, 118, 92, 188, 114, 92, 188, 118, 92, 188, 122, 92, 196, 122, 100,
+      188, 126, 100, 188, 118, 92, 180, 110, 84, 188, 114, 92, 188, 122, 100,
+      196, 126, 100, 188, 118, 100, 196, 122, 92, 188, 114, 92, 180, 114, 92,
+     196, 122, 92, 188, 122, 100, 188, 118, 92, 196, 122, 100, 196, 126, 100,
+       188, 118, 92, 188, 118, 92, 172, 98, 76, 164, 94, 68, 180, 110, 92,
+      188, 122, 92, 188, 114, 92, 180, 114, 84, 204, 130, 108, 196, 126, 100,
+       188, 118, 92, 188, 122, 92, 196, 122, 100, 188, 122, 92, 188, 122, 92,
+       188, 114, 92, 180, 114, 84, 180, 110, 84, 180, 110, 84, 180, 114, 92,
+       180, 110, 84, 172, 102, 76, 172, 102, 76, 180, 106, 84, 180, 110, 92,
+       180, 106, 84, 172, 102, 76, 172, 98, 76, 164, 94, 76, 180, 106, 84,
+       180, 110, 92, 180, 106, 84, 172, 102, 76, 172, 98, 84, 172, 102, 76,
+       180, 110, 84, 180, 110, 84, 180, 106, 84, 180, 110, 92, 180, 114, 92,
+       172, 110, 92, 172, 106, 92, 172, 106, 84, 180, 110, 92, 180, 118, 100,
+   188, 122, 100, 180, 122, 100, 188, 118, 100, 188, 126, 108, 188, 118, 100,
+       180, 114, 92, 172, 106, 84, 172, 106, 84, 172, 110, 92, 180, 114, 92,
+       180, 114, 92, 172, 114, 92, 180, 110, 92, 172, 106, 84, 164, 102, 84,
+       164, 102, 84, 172, 106, 84, 172, 106, 84, 172, 106, 92, 180, 110, 84,
+       172, 110, 92, 180, 110, 92, 172, 110, 92, 180, 110, 92, 180, 114, 92,
+       172, 114, 92, 180, 110, 92, 164, 98, 76, 172, 110, 92, 180, 114, 92,
+       172, 106, 84, 172, 106, 84, 172, 110, 92, 172, 106, 84, 164, 102, 84,
+       172, 106, 84, 172, 110, 84, 172, 106, 92, 172, 106, 84, 172, 106, 84,
+       172, 110, 92, 172, 110, 92, 180, 110, 84, 172, 106, 84, 172, 106, 84,
+       180, 110, 84, 172, 110, 84, 172, 114, 92, 172, 110, 92, 172, 110, 84,
+       172, 110, 84, 180, 106, 92, 172, 102, 84, 180, 106, 92, 172, 106, 92,
+       172, 106, 92, 180, 122, 100, 148, 98, 76, 92, 34, 12, 100, 42, 28,
+       116, 54, 36, 148, 86, 68, 148, 90, 76, 148, 86, 76, 148, 86, 76,
+       140, 78, 60, 148, 78, 60, 140, 78, 60, 148, 78, 60, 148, 78, 60,
+       148, 82, 60, 156, 86, 68, 156, 90, 68, 156, 90, 68, 156, 90, 68,
+       148, 86, 68, 172, 102, 84, 164, 102, 84, 172, 102, 84, 164, 102, 84,
+       172, 106, 84, 172, 106, 84, 164, 102, 84, 164, 98, 76, 156, 94, 76,
+       164, 98, 76, 156, 94, 76, 164, 98, 76, 164, 94, 76, 164, 94, 76,
+       156, 94, 76, 164, 98, 76, 180, 110, 84, 188, 114, 84, 188, 114, 92,
+       180, 106, 84, 188, 114, 84, 188, 118, 92, 188, 114, 92, 188, 118, 92,
+       188, 118, 92, 188, 114, 92, 180, 110, 84, 188, 114, 92, 188, 118, 92,
+       188, 114, 92, 188, 118, 92, 188, 118, 92, 188, 114, 92, 188, 118, 92,
+       188, 118, 92, 188, 118, 92, 188, 114, 92, 180, 110, 84, 196, 122, 100,
+       188, 118, 92, 180, 114, 84, 188, 114, 92, 188, 122, 92, 196, 122, 100,
+       188, 118, 92, 188, 114, 92, 180, 110, 84, 188, 118, 92, 196, 122, 100,
+       196, 122, 92, 188, 118, 92, 188, 118, 100, 196, 122, 92, 188, 118, 92,
+     196, 122, 100, 196, 122, 92, 196, 122, 100, 188, 122, 92, 196, 122, 100,
+     188, 122, 92, 196, 122, 100, 196, 122, 100, 196, 122, 100, 196, 122, 92,
+       188, 114, 92, 180, 110, 84, 188, 114, 84, 188, 118, 92, 196, 122, 92,
+       188, 118, 92, 188, 122, 92, 188, 118, 92, 188, 114, 92, 188, 118, 92,
+      196, 122, 92, 188, 118, 92, 188, 118, 92, 196, 126, 100, 204, 130, 108,
+       204, 134, 108, 188, 122, 92, 180, 106, 84, 188, 114, 92, 188, 118, 92,
+    188, 118, 92, 196, 122, 100, 204, 134, 108, 196, 130, 100, 196, 122, 100,
+      188, 122, 92, 196, 122, 100, 196, 122, 100, 188, 118, 92, 188, 114, 92,
+       188, 114, 84, 180, 110, 84, 180, 110, 84, 188, 114, 92, 180, 110, 84,
+       180, 106, 84, 180, 106, 84, 188, 114, 92, 188, 118, 92, 188, 114, 92,
+       180, 110, 92, 180, 106, 84, 172, 102, 84, 180, 110, 84, 188, 118, 92,
+       180, 106, 84, 180, 106, 84, 172, 106, 84, 180, 106, 84, 180, 106, 92,
+       188, 114, 92, 180, 110, 92, 180, 110, 84, 188, 114, 92, 188, 114, 100,
+      180, 114, 92, 172, 110, 92, 180, 114, 92, 188, 122, 100, 188, 122, 108,
+    188, 122, 100, 180, 118, 100, 188, 122, 100, 180, 118, 100, 180, 114, 92,
+       180, 110, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 172, 110, 92,
+       180, 110, 92, 172, 110, 84, 172, 106, 84, 164, 102, 84, 172, 102, 84,
+       164, 106, 84, 172, 106, 84, 180, 110, 92, 172, 114, 92, 180, 110, 92,
+       172, 110, 92, 180, 110, 92, 172, 110, 84, 172, 110, 92, 172, 110, 84,
+       180, 110, 92, 164, 102, 84, 172, 110, 92, 180, 114, 92, 180, 114, 92,
+       180, 110, 92, 172, 110, 84, 172, 110, 92, 172, 106, 84, 180, 114, 92,
+       180, 110, 92, 180, 110, 92, 172, 110, 92, 172, 110, 92, 172, 110, 84,
+       172, 110, 92, 180, 110, 92, 172, 110, 92, 180, 110, 84, 180, 114, 92,
+       180, 114, 92, 180, 114, 92, 180, 118, 92, 180, 114, 92, 180, 114, 92,
+    188, 118, 100, 188, 114, 92, 196, 122, 108, 188, 118, 100, 180, 118, 100,
+       188, 130, 108, 156, 106, 84, 100, 42, 28, 84, 30, 12, 116, 54, 36,
+       156, 90, 76, 156, 90, 76, 156, 90, 68, 156, 94, 76, 148, 86, 68,
+       164, 94, 84, 156, 94, 76, 156, 90, 76, 148, 86, 68, 148, 78, 60,
+       148, 78, 60, 148, 86, 68, 164, 94, 76, 164, 94, 76, 172, 98, 84,
+       164, 98, 76, 164, 102, 76, 172, 106, 84, 180, 110, 92, 180, 118, 100,
+       180, 118, 100, 180, 110, 92, 172, 110, 92, 164, 98, 76, 164, 94, 76,
+       164, 98, 76, 164, 98, 84, 164, 102, 76, 164, 102, 84, 172, 102, 84,
+      164, 102, 76, 188, 118, 92, 188, 122, 100, 196, 122, 100, 188, 114, 92,
+      180, 114, 92, 188, 114, 92, 196, 122, 100, 196, 122, 100, 188, 118, 92,
+       188, 114, 92, 188, 118, 92, 188, 118, 92, 188, 118, 92, 180, 110, 84,
+    196, 122, 100, 196, 122, 100, 188, 122, 92, 196, 122, 100, 196, 126, 100,
+      196, 122, 100, 188, 118, 92, 188, 118, 92, 196, 122, 100, 188, 118, 92,
+     188, 114, 92, 188, 118, 92, 196, 122, 100, 196, 126, 100, 196, 122, 100,
+       188, 118, 92, 188, 114, 84, 188, 122, 92, 196, 122, 100, 188, 122, 92,
+      188, 118, 92, 196, 122, 100, 196, 122, 92, 188, 118, 92, 196, 122, 100,
+   196, 126, 100, 196, 122, 100, 196, 126, 100, 196, 126, 100, 196, 126, 100,
+   196, 122, 100, 196, 126, 100, 196, 122, 100, 196, 126, 100, 196, 122, 100,
+    188, 118, 92, 188, 118, 100, 196, 126, 100, 196, 126, 100, 196, 122, 100,
+     196, 126, 100, 196, 122, 100, 188, 118, 92, 188, 122, 100, 196, 122, 92,
+       188, 114, 92, 188, 114, 92, 188, 122, 92, 188, 114, 92, 204, 130, 108,
+      196, 126, 100, 188, 118, 92, 188, 118, 92, 188, 118, 92, 196, 122, 100,
+    196, 126, 100, 204, 130, 108, 196, 126, 100, 196, 122, 100, 188, 118, 92,
+     196, 122, 100, 196, 126, 100, 196, 122, 100, 188, 118, 92, 188, 114, 92,
+       188, 114, 92, 188, 118, 92, 188, 118, 92, 188, 118, 92, 180, 114, 84,
+      188, 114, 92, 196, 126, 100, 196, 122, 100, 188, 114, 92, 180, 110, 84,
+       180, 106, 84, 172, 98, 76, 180, 110, 92, 188, 114, 92, 172, 102, 84,
+       196, 126, 100, 188, 114, 92, 188, 114, 92, 188, 114, 92, 188, 114, 92,
+      180, 110, 84, 188, 114, 92, 188, 114, 92, 188, 122, 100, 180, 118, 100,
+    180, 114, 92, 180, 118, 100, 188, 122, 100, 188, 126, 108, 188, 122, 100,
+    180, 118, 100, 188, 122, 100, 180, 118, 100, 180, 110, 92, 180, 114, 100,
+      180, 118, 100, 188, 118, 100, 172, 114, 92, 172, 106, 84, 172, 110, 92,
+       172, 106, 92, 172, 102, 84, 164, 102, 84, 172, 102, 76, 172, 106, 84,
+       172, 106, 92, 180, 114, 92, 180, 110, 92, 180, 114, 92, 172, 110, 92,
+       172, 110, 84, 172, 106, 84, 172, 106, 84, 172, 106, 92, 172, 110, 84,
+      172, 106, 84, 180, 110, 92, 180, 114, 92, 180, 118, 100, 180, 118, 100,
+       180, 110, 92, 172, 110, 92, 180, 110, 92, 180, 114, 92, 172, 114, 92,
+       172, 110, 92, 172, 106, 84, 172, 106, 84, 172, 106, 92, 172, 110, 84,
+       172, 106, 84, 180, 110, 84, 172, 110, 92, 180, 114, 92, 180, 114, 92,
+       180, 118, 92, 180, 118, 92, 180, 114, 92, 180, 118, 92, 188, 114, 100,
+    180, 110, 92, 188, 122, 108, 188, 122, 100, 180, 118, 108, 188, 126, 108,
+       148, 90, 76, 84, 30, 12, 92, 38, 28, 140, 78, 60, 156, 90, 68,
+       156, 90, 76, 156, 90, 68, 156, 94, 76, 164, 98, 76, 156, 94, 76,
+       164, 94, 76, 156, 94, 68, 156, 94, 76, 156, 90, 68, 156, 86, 68,
+       148, 86, 68, 156, 86, 68, 156, 94, 76, 164, 102, 76, 180, 110, 92,
+       172, 102, 84, 172, 98, 84, 172, 106, 84, 180, 114, 92, 188, 122, 100,
+       188, 114, 92, 172, 110, 92, 172, 102, 84, 164, 98, 76, 156, 90, 68,
+       156, 86, 68, 164, 94, 76, 172, 102, 84, 172, 106, 84, 180, 110, 92,
+      188, 114, 92, 196, 126, 100, 196, 126, 100, 188, 118, 92, 180, 110, 92,
+    188, 118, 92, 196, 130, 108, 196, 126, 100, 196, 122, 100, 188, 126, 100,
+     196, 126, 108, 196, 126, 100, 196, 122, 100, 180, 118, 92, 188, 114, 92,
+     188, 118, 92, 196, 122, 100, 188, 122, 100, 188, 122, 100, 188, 118, 92,
+     188, 118, 92, 188, 118, 92, 196, 126, 100, 188, 122, 100, 196, 122, 100,
+   188, 122, 100, 196, 126, 100, 196, 130, 100, 196, 126, 108, 196, 130, 100,
+   196, 122, 100, 188, 122, 100, 196, 126, 108, 196, 126, 100, 204, 130, 108,
+   196, 130, 100, 196, 130, 108, 196, 130, 108, 188, 122, 100, 196, 126, 100,
+   188, 122, 100, 196, 122, 100, 188, 122, 100, 196, 126, 100, 196, 126, 100,
+   196, 130, 100, 196, 130, 108, 196, 130, 100, 196, 126, 100, 196, 126, 100,
+   204, 130, 108, 196, 130, 100, 196, 126, 108, 188, 126, 100, 196, 122, 100,
+   196, 126, 100, 196, 130, 108, 204, 130, 108, 196, 126, 108, 196, 130, 100,
+   196, 122, 100, 188, 122, 100, 196, 126, 100, 204, 134, 108, 204, 134, 108,
+     196, 126, 100, 188, 114, 92, 188, 118, 92, 188, 122, 100, 196, 126, 100,
+   196, 130, 108, 196, 126, 108, 196, 126, 100, 196, 126, 100, 196, 126, 100,
+    188, 122, 92, 188, 122, 100, 188, 122, 100, 196, 122, 100, 188, 122, 100,
+    196, 122, 100, 188, 122, 100, 196, 122, 100, 188, 122, 100, 188, 118, 92,
+   188, 118, 100, 196, 126, 100, 188, 122, 100, 188, 122, 100, 188, 118, 100,
+       188, 118, 92, 188, 118, 92, 188, 114, 92, 188, 118, 92, 188, 122, 100,
+       188, 114, 92, 180, 114, 92, 180, 114, 84, 172, 102, 84, 172, 106, 84,
+    188, 118, 92, 188, 118, 100, 188, 122, 100, 188, 122, 100, 180, 118, 100,
+   188, 118, 100, 188, 122, 100, 188, 122, 100, 188, 118, 100, 180, 118, 100,
+       196, 130, 108, 180, 114, 92, 172, 106, 84, 172, 110, 92, 180, 114, 92,
+       172, 110, 92, 172, 106, 84, 172, 106, 84, 180, 110, 92, 180, 114, 92,
+       180, 114, 92, 180, 110, 92, 164, 102, 84, 164, 98, 84, 172, 102, 84,
+       172, 106, 84, 172, 106, 92, 172, 106, 84, 172, 106, 84, 180, 106, 92,
+       172, 106, 92, 180, 110, 92, 180, 110, 92, 172, 110, 92, 172, 102, 84,
+       172, 110, 92, 180, 114, 92, 180, 114, 100, 180, 114, 92, 172, 110, 92,
+       180, 114, 92, 172, 110, 92, 180, 114, 92, 180, 114, 92, 180, 110, 92,
+       180, 110, 92, 172, 110, 92, 180, 110, 84, 172, 110, 92, 172, 110, 92,
+       180, 110, 92, 180, 110, 92, 180, 114, 92, 180, 114, 92, 180, 118, 100,
+       180, 118, 100, 180, 114, 92, 180, 114, 92, 172, 102, 84, 172, 102, 84,
+       180, 106, 92, 164, 94, 84, 156, 94, 76, 172, 110, 100, 140, 82, 68,
+       92, 38, 28, 92, 34, 20, 124, 58, 44, 140, 78, 60, 148, 86, 68,
+       156, 90, 68, 156, 94, 76, 164, 94, 76, 148, 90, 68, 156, 90, 68,
+       164, 94, 76, 156, 94, 76, 156, 94, 76, 156, 90, 68, 148, 86, 60,
+       148, 86, 68, 156, 90, 68, 164, 94, 76, 164, 98, 76, 156, 94, 76,
+       156, 94, 76, 172, 98, 84, 180, 110, 92, 180, 118, 100, 188, 114, 100,
+       180, 114, 92, 172, 102, 84, 164, 98, 84, 164, 94, 76, 156, 94, 76,
+       156, 90, 68, 164, 94, 76, 164, 94, 76, 164, 94, 76, 164, 98, 76,
+    180, 110, 92, 196, 126, 100, 196, 126, 108, 204, 130, 100, 196, 126, 108,
+   196, 130, 108, 196, 126, 100, 188, 122, 100, 196, 122, 100, 196, 126, 100,
+    196, 126, 100, 188, 122, 100, 188, 118, 92, 196, 130, 108, 196, 134, 108,
+   204, 134, 108, 204, 134, 108, 196, 130, 108, 196, 130, 108, 196, 126, 108,
+   196, 130, 108, 196, 126, 100, 188, 126, 100, 188, 122, 100, 196, 126, 100,
+   196, 126, 100, 196, 126, 108, 196, 126, 100, 188, 126, 100, 188, 122, 100,
+   196, 126, 100, 188, 122, 100, 188, 122, 100, 188, 122, 100, 196, 122, 100,
+   196, 126, 100, 196, 126, 108, 204, 130, 108, 196, 130, 108, 196, 130, 108,
+   196, 130, 108, 196, 130, 108, 204, 130, 108, 196, 130, 108, 204, 130, 108,
+   196, 130, 108, 196, 126, 100, 188, 126, 108, 196, 126, 100, 196, 126, 108,
+   196, 130, 108, 196, 126, 100, 196, 126, 100, 196, 126, 100, 188, 126, 100,
+   196, 126, 100, 196, 126, 108, 196, 130, 100, 196, 126, 108, 188, 126, 100,
+   196, 122, 100, 188, 126, 100, 196, 130, 108, 196, 130, 108, 188, 122, 100,
+      180, 114, 92, 188, 118, 92, 188, 122, 100, 188, 122, 100, 188, 118, 92,
+    188, 122, 100, 188, 118, 100, 188, 122, 100, 188, 118, 92, 188, 118, 100,
+      188, 118, 92, 188, 122, 100, 188, 118, 92, 188, 122, 92, 188, 118, 100,
+       188, 118, 92, 188, 118, 92, 188, 118, 92, 188, 118, 100, 180, 118, 92,
+      188, 122, 100, 188, 122, 100, 188, 118, 92, 188, 118, 92, 180, 114, 92,
+      180, 114, 92, 180, 114, 92, 188, 118, 92, 196, 126, 100, 188, 118, 100,
+      188, 122, 100, 188, 118, 92, 180, 110, 84, 180, 114, 92, 188, 122, 100,
+       188, 122, 100, 180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92,
+      180, 118, 100, 180, 118, 100, 180, 114, 92, 172, 110, 92, 172, 106, 84,
+       164, 94, 76, 164, 102, 84, 180, 114, 92, 180, 118, 100, 172, 106, 84,
+       164, 98, 76, 164, 98, 84, 164, 98, 76, 164, 98, 84, 172, 102, 84,
+       172, 102, 84, 164, 98, 76, 172, 102, 84, 172, 106, 84, 180, 110, 92,
+       180, 110, 92, 180, 110, 92, 180, 110, 92, 180, 110, 92, 180, 110, 92,
+       180, 110, 92, 172, 110, 92, 180, 110, 92, 172, 106, 84, 172, 110, 92,
+       180, 118, 92, 188, 118, 100, 180, 114, 92, 180, 114, 92, 180, 114, 92,
+    180, 114, 92, 180, 118, 100, 180, 118, 100, 180, 118, 100, 180, 118, 100,
+     188, 118, 92, 180, 118, 100, 180, 118, 100, 188, 118, 100, 180, 110, 92,
+   172, 110, 100, 180, 114, 100, 180, 118, 100, 180, 118, 100, 180, 118, 100,
+     188, 122, 100, 188, 118, 100, 180, 106, 84, 172, 102, 84, 188, 114, 100,
+       164, 98, 76, 164, 98, 84, 172, 110, 100, 132, 78, 68, 92, 34, 20,
+       92, 34, 20, 132, 70, 52, 156, 90, 68, 164, 102, 76, 164, 98, 76,
+       164, 98, 84, 164, 98, 76, 156, 90, 68, 156, 94, 76, 148, 82, 60,
+       148, 86, 68, 148, 82, 60, 148, 82, 60, 148, 82, 60, 148, 78, 60,
+       148, 82, 60, 148, 86, 68, 148, 82, 68, 148, 82, 60, 156, 82, 68,
+       156, 90, 68, 164, 98, 76, 172, 102, 84, 172, 106, 84, 172, 106, 84,
+       164, 102, 76, 172, 98, 84, 164, 98, 76, 156, 90, 76, 156, 82, 60,
+       140, 78, 60, 140, 70, 52, 132, 70, 52, 156, 82, 60, 172, 98, 76,
+    188, 114, 92, 196, 122, 100, 196, 126, 100, 196, 126, 108, 196, 130, 108,
+   196, 130, 108, 196, 126, 100, 188, 126, 100, 196, 126, 100, 188, 126, 100,
+   196, 126, 100, 188, 122, 100, 196, 130, 108, 204, 130, 108, 196, 130, 108,
+   196, 130, 108, 196, 122, 100, 188, 122, 100, 196, 122, 100, 188, 126, 100,
+   196, 126, 100, 196, 122, 100, 188, 122, 100, 188, 122, 100, 196, 122, 100,
+   188, 126, 100, 188, 122, 100, 188, 122, 100, 196, 122, 100, 188, 122, 100,
+    196, 126, 100, 188, 122, 100, 188, 118, 100, 188, 118, 92, 188, 122, 100,
+   188, 126, 100, 196, 126, 100, 196, 126, 100, 196, 130, 108, 196, 126, 100,
+   196, 126, 100, 196, 126, 108, 196, 126, 100, 188, 122, 100, 196, 130, 108,
+   196, 130, 100, 196, 126, 108, 196, 126, 100, 196, 130, 108, 204, 130, 108,
+   196, 130, 108, 196, 126, 108, 196, 130, 108, 204, 134, 108, 196, 130, 108,
+   196, 130, 108, 196, 130, 108, 196, 130, 108, 204, 130, 108, 196, 134, 108,
+   204, 130, 108, 204, 134, 116, 196, 130, 108, 196, 122, 100, 188, 122, 100,
+    196, 126, 108, 196, 126, 100, 196, 126, 100, 188, 118, 100, 188, 118, 92,
+     188, 118, 92, 188, 122, 92, 188, 118, 100, 188, 122, 100, 188, 122, 100,
+    188, 122, 100, 188, 122, 100, 188, 118, 100, 188, 122, 92, 188, 118, 100,
+    188, 122, 100, 188, 122, 100, 188, 122, 100, 188, 122, 100, 188, 118, 92,
+     188, 122, 100, 188, 122, 100, 188, 118, 100, 188, 118, 92, 188, 114, 92,
+    188, 122, 100, 188, 122, 100, 188, 122, 100, 188, 118, 92, 188, 122, 100,
+     188, 122, 100, 180, 110, 92, 180, 114, 92, 188, 122, 100, 188, 122, 100,
+   188, 118, 100, 180, 118, 100, 180, 118, 100, 188, 122, 100, 188, 122, 100,
+       188, 122, 100, 180, 114, 92, 180, 110, 92, 172, 110, 92, 164, 102, 76,
+      164, 102, 84, 188, 118, 100, 180, 118, 100, 172, 106, 84, 164, 102, 84,
+       172, 110, 92, 180, 110, 92, 180, 110, 92, 180, 110, 92, 180, 110, 92,
+       172, 106, 84, 180, 110, 92, 172, 110, 92, 180, 110, 92, 180, 110, 92,
+       180, 114, 92, 180, 110, 92, 180, 114, 92, 172, 110, 92, 180, 110, 84,
+       180, 110, 92, 180, 110, 92, 172, 102, 84, 172, 106, 84, 172, 110, 92,
+       180, 110, 92, 172, 110, 92, 172, 110, 92, 172, 106, 92, 172, 110, 92,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 100,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 110, 100, 180, 114, 92,
+     180, 114, 92, 180, 114, 100, 180, 118, 92, 180, 122, 100, 188, 122, 100,
+     188, 122, 100, 188, 118, 100, 180, 110, 92, 188, 114, 100, 172, 102, 92,
+       172, 106, 92, 180, 118, 100, 132, 78, 68, 92, 34, 20, 92, 34, 20,
+       132, 74, 60, 156, 90, 68, 164, 94, 76, 148, 90, 68, 156, 86, 68,
+       156, 90, 68, 156, 90, 68, 164, 98, 84, 156, 90, 68, 156, 90, 68,
+       156, 90, 76, 156, 94, 76, 164, 98, 76, 164, 98, 84, 164, 102, 76,
+       172, 102, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84, 180, 110, 92,
+       180, 110, 92, 180, 110, 92, 180, 114, 100, 180, 114, 92, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 180, 110, 92, 164, 98, 84, 164, 94, 76,
+       156, 90, 68, 156, 90, 68, 172, 102, 84, 180, 110, 92, 188, 118, 92,
+    196, 122, 100, 196, 122, 100, 188, 122, 100, 188, 122, 100, 188, 118, 92,
+     188, 118, 100, 188, 118, 100, 180, 114, 92, 188, 114, 92, 188, 118, 100,
+    188, 118, 92, 196, 126, 100, 188, 126, 100, 196, 122, 100, 188, 122, 100,
+     180, 118, 92, 188, 118, 92, 188, 122, 100, 196, 122, 100, 196, 126, 108,
+   188, 126, 100, 188, 122, 100, 196, 122, 100, 188, 126, 100, 196, 122, 100,
+       188, 122, 100, 188, 118, 92, 180, 110, 92, 180, 114, 92, 188, 118, 92,
+       180, 114, 92, 180, 110, 84, 172, 110, 84, 180, 114, 92, 188, 114, 92,
+   188, 126, 100, 196, 126, 108, 196, 126, 100, 196, 130, 108, 196, 126, 108,
+   188, 126, 100, 188, 126, 100, 196, 122, 100, 188, 122, 100, 188, 122, 100,
+    188, 118, 92, 188, 122, 100, 188, 122, 100, 188, 126, 100, 188, 122, 100,
+    188, 118, 92, 196, 130, 108, 196, 130, 108, 196, 126, 108, 196, 126, 100,
+   196, 130, 108, 196, 130, 108, 196, 130, 108, 204, 130, 108, 196, 130, 108,
+     196, 130, 100, 196, 122, 100, 180, 118, 92, 188, 118, 92, 188, 122, 100,
+      196, 126, 100, 180, 118, 100, 188, 118, 92, 180, 118, 92, 180, 114, 92,
+       188, 118, 92, 180, 114, 92, 188, 118, 92, 180, 114, 92, 188, 114, 92,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 188, 118, 92,
+       180, 114, 92, 188, 118, 92, 188, 118, 92, 180, 110, 92, 188, 114, 92,
+       188, 122, 92, 180, 118, 92, 180, 110, 92, 180, 110, 92, 180, 118, 92,
+     196, 122, 100, 188, 118, 100, 180, 114, 92, 188, 122, 100, 188, 118, 92,
+      180, 110, 92, 180, 114, 84, 188, 118, 100, 180, 118, 92, 188, 118, 100,
+   188, 122, 100, 188, 122, 100, 188, 122, 108, 188, 122, 100, 188, 122, 100,
+       180, 114, 92, 172, 106, 84, 164, 98, 84, 156, 94, 76, 164, 94, 76,
+       164, 102, 76, 172, 102, 84, 164, 98, 76, 172, 106, 84, 188, 122, 100,
+      188, 118, 100, 188, 118, 100, 180, 114, 92, 180, 114, 92, 180, 110, 92,
+       180, 110, 92, 180, 110, 92, 172, 110, 92, 180, 110, 92, 172, 110, 92,
+       180, 110, 84, 172, 110, 92, 180, 110, 92, 172, 106, 92, 172, 110, 84,
+       172, 106, 92, 172, 102, 84, 172, 106, 84, 172, 110, 92, 172, 110, 84,
+       172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 102, 84,
+       164, 102, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 92,
+       172, 106, 84, 172, 106, 92, 180, 110, 92, 172, 110, 92, 180, 106, 92,
+       172, 110, 92, 172, 110, 92, 180, 114, 92, 180, 118, 92, 180, 118, 92,
+    188, 118, 100, 188, 114, 100, 188, 118, 100, 180, 110, 92, 180, 118, 108,
+       180, 122, 108, 132, 78, 68, 92, 34, 20, 92, 34, 20, 108, 50, 28,
+       132, 66, 52, 140, 74, 52, 132, 70, 52, 140, 74, 52, 140, 78, 60,
+       148, 86, 60, 164, 94, 76, 156, 94, 68, 156, 94, 76, 164, 98, 76,
+       164, 102, 84, 172, 106, 84, 172, 106, 84, 172, 110, 92, 172, 106, 84,
+       180, 110, 92, 180, 110, 92, 180, 114, 92, 180, 110, 92, 180, 110, 92,
+       180, 114, 92, 180, 110, 92, 180, 114, 92, 172, 106, 92, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 180, 110, 92, 180, 114, 92, 188, 114, 100,
+       188, 122, 100, 180, 110, 84, 188, 114, 92, 180, 114, 92, 188, 114, 92,
+       180, 110, 92, 180, 110, 92, 180, 110, 92, 180, 114, 92, 180, 114, 84,
+       180, 114, 92, 180, 110, 84, 180, 110, 92, 172, 110, 84, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 110, 92, 180, 110, 84,
+       180, 110, 92, 188, 118, 92, 188, 122, 100, 180, 114, 84, 180, 110, 92,
+       180, 110, 84, 180, 110, 84, 180, 110, 92, 180, 114, 92, 180, 106, 84,
+       172, 106, 84, 164, 102, 76, 172, 102, 84, 180, 110, 84, 180, 110, 84,
+       172, 110, 92, 180, 106, 84, 180, 110, 84, 180, 110, 92, 180, 118, 92,
+     188, 118, 92, 188, 118, 100, 188, 122, 100, 188, 122, 92, 188, 118, 100,
+       188, 118, 92, 180, 114, 92, 188, 118, 92, 180, 114, 92, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 188, 114, 92, 180, 114, 92, 180, 114, 92,
+       188, 114, 92, 188, 118, 92, 188, 122, 92, 188, 118, 100, 196, 122, 92,
+     188, 122, 100, 188, 118, 100, 188, 122, 92, 188, 118, 100, 188, 118, 92,
+       180, 114, 92, 172, 106, 84, 180, 110, 92, 180, 118, 92, 188, 114, 92,
+       172, 110, 84, 180, 110, 84, 180, 110, 92, 180, 110, 92, 180, 110, 84,
+       172, 110, 84, 180, 106, 84, 172, 106, 84, 172, 106, 84, 172, 102, 84,
+       172, 106, 76, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       180, 110, 84, 172, 106, 84, 172, 102, 76, 172, 106, 84, 180, 110, 84,
+       172, 106, 84, 172, 102, 84, 172, 102, 76, 180, 106, 84, 180, 114, 92,
+       188, 118, 92, 180, 114, 92, 188, 118, 92, 188, 122, 100, 180, 110, 84,
+       180, 110, 92, 188, 118, 92, 180, 114, 92, 180, 114, 92, 172, 114, 92,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 172, 110, 84, 164, 98, 84,
+       156, 94, 76, 140, 74, 52, 140, 78, 60, 148, 86, 68, 156, 90, 68,
+       156, 94, 76, 156, 98, 76, 172, 102, 84, 172, 110, 92, 172, 106, 92,
+       172, 106, 84, 172, 106, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 180, 106, 84, 172, 106, 84, 172, 102, 84, 172, 106, 84,
+       172, 102, 84, 172, 106, 84, 180, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 110, 92, 180, 110, 92, 180, 110, 92, 172, 106, 92,
+       172, 106, 84, 172, 106, 84, 172, 110, 92, 164, 102, 84, 172, 102, 84,
+       164, 106, 84, 172, 106, 84, 172, 106, 92, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 92, 172, 106, 92, 164, 102, 84, 172, 102, 84,
+       164, 106, 84, 164, 102, 84, 172, 106, 84, 172, 106, 84, 180, 110, 92,
+      180, 106, 92, 180, 110, 92, 172, 102, 92, 172, 114, 100, 180, 118, 100,
+       132, 74, 60, 92, 34, 20, 92, 34, 12, 124, 58, 44, 148, 78, 60,
+       148, 90, 68, 156, 86, 68, 156, 94, 76, 156, 94, 76, 156, 90, 68,
+       164, 98, 76, 156, 94, 76, 164, 94, 76, 156, 94, 68, 164, 94, 76,
+       164, 98, 76, 164, 98, 84, 164, 98, 76, 156, 98, 76, 164, 94, 76,
+       164, 98, 76, 164, 98, 84, 164, 98, 84, 172, 102, 76, 164, 102, 84,
+       172, 102, 84, 172, 102, 84, 172, 106, 84, 172, 106, 92, 180, 106, 84,
+       172, 106, 92, 172, 106, 84, 180, 110, 92, 180, 110, 92, 180, 114, 92,
+       180, 110, 92, 180, 106, 84, 180, 114, 92, 188, 118, 92, 188, 118, 92,
+       188, 114, 92, 188, 118, 92, 188, 118, 92, 188, 118, 100, 188, 118, 92,
+      188, 122, 100, 188, 122, 100, 188, 118, 92, 180, 118, 92, 188, 118, 92,
+       188, 118, 100, 188, 118, 92, 180, 118, 92, 188, 114, 92, 180, 118, 92,
+      188, 122, 100, 196, 130, 108, 188, 114, 92, 180, 114, 92, 180, 118, 92,
+       188, 118, 92, 188, 118, 100, 188, 118, 92, 180, 114, 92, 180, 110, 84,
+       180, 110, 92, 180, 114, 84, 180, 114, 92, 180, 114, 92, 188, 118, 92,
+     188, 118, 100, 188, 118, 92, 188, 118, 100, 188, 118, 92, 188, 118, 100,
+    188, 122, 92, 188, 122, 100, 188, 122, 100, 188, 122, 100, 188, 122, 100,
+    196, 122, 100, 188, 126, 100, 188, 122, 100, 188, 122, 92, 188, 122, 100,
+     196, 122, 100, 188, 126, 100, 196, 122, 100, 188, 118, 92, 180, 118, 92,
+    188, 118, 100, 188, 118, 92, 188, 122, 100, 188, 122, 100, 188, 122, 100,
+     188, 122, 100, 188, 122, 100, 188, 118, 92, 188, 118, 100, 180, 114, 92,
+       180, 110, 84, 180, 110, 92, 188, 118, 92, 180, 114, 92, 180, 110, 92,
+       188, 118, 92, 180, 118, 92, 188, 114, 92, 180, 114, 92, 180, 110, 92,
+       180, 110, 84, 180, 110, 84, 180, 110, 84, 180, 110, 84, 180, 110, 84,
+       180, 106, 84, 180, 110, 84, 180, 110, 92, 180, 110, 84, 180, 110, 92,
+       180, 110, 92, 172, 106, 84, 180, 110, 84, 180, 114, 92, 180, 110, 92,
+       172, 110, 84, 172, 110, 84, 180, 110, 92, 188, 118, 92, 188, 118, 92,
+       180, 114, 92, 188, 118, 100, 188, 118, 92, 180, 110, 92, 180, 114, 84,
+       188, 118, 100, 180, 114, 92, 180, 110, 92, 172, 110, 92, 172, 110, 92,
+       172, 110, 92, 172, 110, 92, 172, 102, 84, 164, 98, 76, 156, 94, 76,
+       156, 94, 68, 172, 102, 76, 172, 110, 92, 172, 110, 84, 172, 106, 92,
+       172, 110, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 180, 106, 92,
+       172, 106, 84, 172, 106, 92, 172, 102, 84, 172, 102, 84, 172, 106, 92,
+       172, 106, 84, 172, 102, 84, 172, 102, 84, 172, 102, 84, 172, 102, 84,
+       172, 106, 84, 172, 102, 84, 172, 106, 92, 172, 102, 84, 164, 98, 76,
+       164, 102, 84, 164, 102, 84, 164, 102, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 84, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 102, 84,
+       172, 102, 84, 164, 102, 84, 164, 102, 84, 164, 102, 84, 164, 98, 76,
+       172, 102, 84, 172, 102, 84, 172, 102, 84, 164, 98, 84, 164, 102, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 172, 98, 84, 172, 98, 76,
+       172, 98, 84, 164, 94, 84, 172, 110, 92, 172, 110, 100, 116, 62, 52,
+       92, 34, 12, 92, 34, 20, 148, 90, 68, 172, 106, 84, 172, 110, 92,
+       172, 106, 84, 172, 110, 84, 180, 110, 92, 164, 102, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 164, 102, 84, 172, 106, 84, 172, 106, 84,
+       172, 110, 92, 172, 106, 84, 172, 106, 92, 172, 106, 84, 172, 102, 84,
+       172, 106, 84, 172, 106, 84, 180, 110, 92, 180, 110, 92, 180, 110, 92,
+      180, 110, 92, 188, 118, 100, 188, 114, 100, 180, 114, 92, 180, 110, 92,
+       180, 110, 92, 172, 110, 92, 180, 110, 92, 172, 106, 84, 188, 118, 100,
+    188, 118, 92, 196, 122, 100, 196, 126, 108, 204, 130, 108, 188, 122, 100,
+     188, 118, 100, 180, 118, 92, 180, 114, 92, 188, 122, 100, 196, 122, 100,
+     188, 122, 100, 188, 118, 92, 180, 110, 92, 196, 122, 100, 188, 126, 100,
+   196, 126, 100, 188, 122, 100, 188, 122, 100, 196, 126, 100, 196, 126, 108,
+   196, 130, 108, 196, 130, 108, 196, 126, 100, 196, 126, 108, 196, 130, 108,
+    196, 134, 108, 204, 134, 108, 196, 130, 108, 188, 126, 108, 188, 118, 92,
+       180, 114, 92, 180, 106, 84, 180, 110, 84, 180, 114, 92, 180, 118, 92,
+     188, 118, 92, 180, 118, 92, 188, 126, 100, 188, 122, 100, 196, 126, 100,
+   196, 126, 100, 196, 126, 100, 196, 130, 108, 204, 130, 108, 196, 130, 108,
+    196, 122, 100, 188, 122, 100, 188, 118, 100, 188, 118, 92, 188, 122, 100,
+    188, 122, 100, 188, 122, 100, 188, 118, 100, 180, 118, 100, 188, 118, 92,
+      180, 114, 92, 188, 118, 92, 188, 118, 100, 188, 122, 92, 188, 122, 100,
+       196, 122, 100, 180, 118, 92, 188, 118, 92, 180, 114, 92, 172, 110, 84,
+       180, 110, 84, 180, 114, 92, 188, 118, 92, 180, 114, 92, 180, 118, 92,
+       188, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 180, 110, 92, 180, 114, 92, 180, 110, 92, 180, 114, 92,
+       180, 110, 92, 180, 114, 84, 180, 110, 92, 180, 110, 84, 180, 114, 84,
+       180, 110, 92, 180, 114, 92, 180, 114, 92, 180, 110, 84, 180, 110, 92,
+       180, 114, 84, 180, 114, 92, 180, 118, 92, 180, 110, 92, 172, 106, 84,
+       180, 110, 84, 180, 110, 84, 164, 102, 76, 172, 102, 84, 180, 110, 84,
+       172, 110, 84, 172, 106, 84, 172, 106, 84, 172, 102, 84, 172, 106, 84,
+       172, 110, 84, 172, 106, 92, 172, 106, 84, 164, 98, 76, 180, 118, 100,
+     188, 122, 100, 188, 118, 100, 188, 118, 100, 180, 114, 92, 172, 106, 92,
+       172, 106, 84, 164, 102, 84, 180, 106, 84, 172, 106, 92, 180, 110, 92,
+       172, 106, 84, 172, 102, 84, 172, 102, 84, 172, 102, 84, 172, 106, 92,
+       172, 98, 84, 164, 102, 84, 172, 102, 84, 172, 102, 84, 172, 106, 92,
+       180, 106, 84, 172, 110, 92, 180, 106, 92, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 156, 94, 76, 156, 94, 76, 156, 94, 76,
+       164, 98, 76, 164, 98, 84, 164, 98, 76, 172, 102, 84, 164, 102, 84,
+       172, 102, 84, 164, 102, 84, 164, 98, 76, 156, 94, 76, 172, 102, 84,
+       172, 102, 92, 164, 102, 84, 172, 102, 84, 164, 106, 84, 164, 106, 84,
+       164, 102, 76, 172, 102, 84, 164, 98, 76, 172, 102, 84, 172, 102, 84,
+       164, 94, 84, 172, 106, 92, 164, 106, 92, 116, 62, 52, 92, 34, 20,
+       100, 46, 28, 148, 86, 76, 164, 98, 76, 164, 98, 76, 156, 90, 76,
+       164, 98, 76, 164, 102, 84, 172, 102, 84, 172, 106, 84, 164, 102, 84,
+       164, 102, 84, 164, 98, 76, 164, 98, 84, 172, 106, 84, 172, 110, 92,
+       180, 110, 92, 172, 110, 84, 180, 110, 92, 180, 106, 92, 172, 106, 84,
+       180, 110, 92, 180, 110, 92, 180, 114, 92, 180, 110, 92, 172, 110, 92,
+       172, 106, 84, 172, 102, 84, 164, 102, 84, 172, 106, 84, 180, 106, 92,
+       180, 110, 84, 172, 106, 84, 172, 102, 84, 180, 110, 92, 172, 102, 76,
+       172, 98, 76, 172, 106, 84, 180, 106, 84, 172, 98, 76, 164, 98, 76,
+       164, 94, 76, 164, 98, 76, 172, 102, 76, 172, 110, 84, 172, 106, 84,
+       172, 98, 76, 156, 94, 68, 164, 94, 68, 164, 94, 76, 164, 98, 76,
+       164, 94, 68, 164, 94, 68, 156, 90, 68, 164, 94, 68, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 172, 102, 76, 172, 106, 84,
+       172, 106, 84, 172, 102, 76, 164, 98, 76, 172, 106, 84, 164, 98, 76,
+       148, 86, 60, 148, 82, 60, 156, 90, 68, 164, 94, 76, 164, 98, 76,
+       164, 94, 76, 172, 98, 76, 164, 98, 76, 164, 98, 76, 172, 102, 84,
+       172, 102, 76, 172, 106, 84, 172, 106, 84, 180, 110, 84, 172, 106, 84,
+       172, 102, 76, 172, 102, 76, 172, 102, 76, 172, 106, 84, 172, 106, 84,
+       172, 102, 76, 172, 102, 76, 172, 106, 84, 172, 102, 84, 172, 102, 76,
+       164, 102, 84, 172, 102, 76, 172, 106, 84, 180, 110, 84, 180, 114, 92,
+       172, 102, 76, 172, 106, 84, 172, 102, 84, 164, 94, 76, 164, 98, 76,
+       172, 102, 76, 172, 102, 84, 172, 102, 76, 164, 98, 76, 172, 98, 76,
+       164, 102, 76, 172, 102, 76, 164, 98, 76, 172, 102, 76, 164, 102, 76,
+       172, 102, 76, 172, 102, 76, 164, 102, 76, 172, 102, 76, 164, 102, 76,
+       172, 98, 76, 164, 98, 76, 164, 102, 76, 164, 98, 76, 172, 102, 84,
+       172, 102, 76, 172, 102, 76, 164, 98, 76, 172, 102, 76, 172, 102, 84,
+       172, 102, 76, 172, 102, 84, 172, 102, 76, 164, 98, 76, 164, 98, 76,
+       164, 102, 76, 156, 90, 68, 164, 94, 68, 164, 98, 76, 164, 98, 76,
+       164, 94, 76, 156, 94, 76, 156, 94, 76, 164, 94, 76, 164, 98, 76,
+       164, 102, 84, 164, 102, 76, 164, 98, 84, 164, 94, 76, 156, 90, 68,
+       156, 90, 76, 156, 94, 68, 156, 94, 76, 156, 90, 68, 156, 90, 68,
+       156, 94, 76, 156, 86, 68, 156, 90, 68, 164, 98, 76, 164, 94, 76,
+       164, 94, 76, 164, 98, 76, 172, 102, 84, 180, 114, 92, 164, 102, 76,
+       172, 102, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84, 180, 110, 92,
+       180, 110, 92, 180, 114, 92, 172, 106, 92, 180, 110, 92, 172, 110, 92,
+       180, 110, 92, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 110, 92,
+       172, 110, 84, 172, 110, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92,
+       172, 110, 92, 172, 110, 84, 172, 106, 84, 172, 102, 92, 172, 106, 84,
+       172, 106, 92, 172, 110, 92, 172, 110, 92, 172, 110, 92, 180, 106, 84,
+       172, 106, 84, 180, 106, 92, 180, 110, 92, 180, 110, 100, 172, 102, 84,
+       180, 114, 100, 172, 110, 100, 124, 66, 52, 100, 46, 28, 100, 42, 28,
+       148, 78, 68, 156, 90, 68, 156, 94, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 156, 90, 68, 148, 82, 60, 148, 82, 68, 148, 86, 60,
+       148, 82, 68, 148, 86, 60, 148, 86, 68, 156, 90, 68, 148, 86, 68,
+       156, 90, 68, 156, 90, 68, 164, 94, 76, 164, 98, 84, 164, 98, 76,
+       156, 94, 76, 164, 94, 76, 164, 98, 76, 164, 98, 76, 172, 102, 84,
+       156, 90, 68, 164, 94, 76, 164, 98, 76, 164, 94, 76, 156, 86, 68,
+       156, 94, 76, 180, 110, 92, 172, 98, 76, 172, 102, 76, 172, 102, 84,
+       164, 98, 76, 172, 98, 76, 180, 110, 84, 188, 122, 100, 188, 118, 92,
+      180, 114, 92, 188, 118, 100, 188, 118, 92, 188, 122, 100, 180, 114, 92,
+       180, 110, 92, 172, 102, 76, 172, 106, 84, 188, 118, 92, 188, 122, 100,
+      188, 122, 100, 188, 118, 92, 188, 118, 100, 188, 118, 92, 172, 102, 76,
+       172, 102, 76, 180, 106, 84, 180, 110, 92, 180, 114, 92, 188, 118, 92,
+       188, 114, 92, 180, 114, 92, 188, 114, 92, 188, 118, 100, 188, 118, 92,
+       180, 114, 92, 172, 102, 76, 164, 98, 76, 172, 102, 76, 172, 106, 84,
+       180, 110, 84, 172, 110, 84, 172, 102, 84, 172, 102, 76, 164, 98, 76,
+       172, 102, 76, 172, 106, 76, 172, 102, 84, 172, 102, 76, 172, 106, 84,
+       180, 110, 92, 180, 114, 92, 180, 110, 84, 172, 110, 84, 180, 106, 84,
+       180, 110, 92, 172, 106, 76, 172, 110, 84, 180, 110, 92, 180, 110, 84,
+       180, 106, 84, 172, 106, 84, 180, 106, 84, 172, 110, 84, 180, 110, 84,
+       172, 102, 84, 172, 102, 76, 172, 102, 76, 164, 94, 68, 164, 98, 76,
+       172, 102, 76, 164, 94, 76, 172, 102, 76, 164, 98, 76, 164, 94, 76,
+       164, 98, 76, 172, 102, 76, 172, 102, 84, 172, 102, 76, 164, 98, 76,
+       164, 102, 84, 172, 98, 76, 164, 98, 76, 172, 102, 76, 164, 98, 76,
+       156, 90, 68, 156, 90, 68, 164, 94, 76, 172, 102, 76, 172, 106, 84,
+       172, 106, 84, 164, 98, 76, 164, 98, 76, 172, 102, 76, 172, 102, 76,
+       164, 98, 76, 164, 102, 76, 164, 98, 76, 172, 102, 76, 172, 102, 84,
+       164, 94, 68, 164, 94, 76, 172, 102, 76, 164, 98, 76, 164, 102, 76,
+       164, 94, 76, 156, 90, 68, 156, 94, 76, 164, 98, 76, 156, 94, 76,
+       156, 90, 68, 156, 94, 76, 156, 90, 68, 156, 94, 76, 164, 98, 76,
+       164, 98, 76, 156, 94, 76, 156, 86, 68, 148, 86, 68, 148, 82, 60,
+       156, 86, 68, 156, 86, 68, 156, 86, 68, 156, 86, 68, 156, 82, 60,
+       148, 86, 68, 156, 86, 68, 156, 90, 76, 156, 90, 68, 156, 86, 68,
+       148, 78, 60, 148, 82, 60, 156, 86, 68, 156, 90, 76, 156, 90, 68,
+       156, 86, 68, 148, 86, 60, 156, 86, 68, 148, 86, 68, 148, 86, 68,
+       156, 90, 68, 156, 90, 68, 164, 94, 76, 156, 94, 76, 156, 86, 68,
+       156, 90, 68, 156, 90, 68, 156, 90, 76, 156, 90, 68, 156, 90, 68,
+       156, 86, 68, 148, 86, 68, 156, 86, 68, 156, 86, 68, 156, 90, 68,
+       156, 90, 76, 164, 98, 76, 164, 102, 76, 164, 102, 84, 172, 106, 84,
+       172, 102, 84, 164, 90, 76, 172, 102, 84, 172, 102, 84, 164, 102, 92,
+       164, 102, 92, 124, 70, 60, 100, 42, 28, 84, 30, 12, 132, 70, 52,
+       140, 74, 60, 148, 78, 60, 140, 74, 52, 140, 74, 60, 140, 78, 60,
+       140, 78, 60, 140, 74, 52, 148, 78, 60, 148, 82, 60, 148, 82, 60,
+       148, 82, 68, 156, 86, 60, 156, 90, 68, 156, 90, 68, 156, 90, 76,
+       148, 82, 68, 156, 90, 68, 156, 90, 68, 164, 90, 68, 156, 90, 68,
+       156, 86, 68, 156, 90, 68, 164, 90, 76, 172, 102, 84, 156, 94, 76,
+       156, 90, 68, 172, 98, 84, 164, 102, 84, 164, 94, 76, 164, 94, 76,
+       172, 102, 84, 180, 110, 84, 180, 110, 92, 188, 114, 92, 180, 110, 84,
+       180, 110, 92, 188, 114, 92, 188, 118, 92, 188, 118, 92, 180, 118, 92,
+       188, 114, 92, 188, 118, 92, 180, 118, 92, 180, 114, 92, 180, 110, 84,
+       180, 114, 92, 180, 118, 92, 188, 118, 100, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 188, 118, 92, 188, 122, 100, 180, 114, 92, 180, 114, 92,
+       180, 110, 84, 180, 114, 92, 180, 114, 92, 180, 114, 92, 172, 110, 84,
+       172, 102, 84, 172, 106, 76, 180, 110, 92, 188, 118, 92, 188, 118, 100,
+       188, 118, 92, 180, 114, 92, 180, 110, 92, 180, 114, 92, 180, 110, 84,
+       180, 106, 84, 180, 110, 92, 180, 114, 92, 180, 114, 92, 180, 110, 92,
+       180, 110, 84, 172, 110, 84, 172, 102, 84, 172, 106, 84, 180, 110, 84,
+       180, 114, 92, 180, 110, 92, 180, 114, 92, 180, 110, 84, 180, 110, 92,
+       172, 106, 84, 180, 106, 84, 180, 110, 84, 172, 110, 84, 172, 106, 84,
+       172, 106, 84, 180, 106, 84, 180, 110, 92, 180, 110, 92, 172, 106, 76,
+       172, 106, 84, 172, 106, 84, 164, 94, 76, 164, 98, 76, 172, 106, 84,
+       172, 102, 76, 172, 102, 76, 164, 102, 76, 172, 98, 76, 164, 102, 76,
+       172, 102, 84, 172, 106, 76, 172, 102, 84, 172, 102, 76, 172, 102, 76,
+       164, 102, 84, 172, 102, 76, 172, 102, 84, 172, 102, 76, 164, 94, 68,
+       164, 94, 76, 172, 102, 76, 172, 106, 84, 180, 106, 84, 172, 106, 84,
+       172, 102, 76, 172, 102, 76, 172, 106, 84, 172, 106, 84, 172, 102, 76,
+       172, 102, 76, 164, 98, 76, 172, 102, 84, 172, 106, 76, 164, 94, 76,
+       164, 98, 76, 172, 102, 76, 164, 98, 76, 172, 102, 84, 164, 98, 76,
+       156, 94, 76, 164, 102, 84, 172, 102, 84, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 156, 94, 76, 164, 94, 76, 164, 98, 76, 164, 102, 84,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 102, 84, 164, 94, 76,
+       156, 94, 76, 164, 94, 76, 156, 94, 76, 156, 90, 68, 156, 86, 68,
+       156, 90, 68, 164, 94, 76, 164, 94, 76, 156, 90, 68, 156, 86, 68,
+       156, 86, 68, 156, 94, 76, 164, 98, 76, 164, 94, 76, 156, 90, 76,
+       156, 86, 68, 148, 90, 68, 156, 90, 68, 156, 94, 68, 156, 94, 76,
+       156, 94, 76, 156, 94, 76, 156, 94, 68, 156, 94, 76, 156, 94, 76,
+       164, 94, 76, 156, 98, 76, 164, 94, 76, 156, 94, 76, 156, 90, 68,
+       156, 90, 68, 164, 94, 84, 156, 94, 76, 164, 98, 84, 164, 98, 76,
+       164, 102, 76, 156, 98, 76, 164, 98, 76, 164, 94, 68, 156, 82, 68,
+       132, 66, 44, 140, 70, 52, 148, 78, 68, 156, 90, 76, 156, 102, 84,
+       124, 66, 52, 84, 30, 12, 92, 38, 28, 132, 66, 52, 140, 74, 52,
+       132, 74, 60, 132, 66, 44, 124, 66, 44, 140, 70, 52, 140, 78, 60,
+       148, 82, 60, 148, 82, 68, 148, 86, 60, 148, 86, 68, 156, 86, 68,
+       148, 90, 68, 156, 90, 76, 156, 94, 68, 156, 94, 76, 164, 90, 68,
+       164, 94, 76, 164, 98, 76, 164, 98, 84, 172, 98, 84, 164, 98, 84,
+       172, 98, 76, 164, 102, 84, 172, 102, 84, 172, 98, 84, 164, 98, 76,
+       172, 102, 84, 180, 110, 84, 180, 110, 92, 172, 110, 92, 172, 102, 76,
+       180, 106, 92, 180, 110, 84, 180, 110, 84, 180, 110, 92, 180, 106, 84,
+       172, 102, 84, 180, 118, 92, 188, 114, 92, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 188, 114, 92, 180, 110, 92, 172, 110, 84, 188, 118, 100,
+       188, 118, 92, 188, 114, 92, 180, 114, 92, 180, 110, 84, 180, 110, 92,
+       180, 114, 92, 188, 118, 92, 188, 114, 92, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 180, 114, 92, 180, 110, 84, 172, 102, 84, 172, 102, 76,
+      172, 102, 76, 172, 110, 84, 188, 118, 100, 188, 122, 100, 188, 118, 92,
+      188, 118, 100, 188, 122, 92, 188, 122, 100, 172, 110, 84, 180, 110, 92,
+       180, 114, 84, 180, 114, 92, 188, 114, 92, 180, 118, 92, 188, 114, 92,
+       180, 118, 92, 180, 106, 84, 172, 106, 84, 180, 106, 84, 180, 114, 84,
+       180, 114, 92, 188, 114, 92, 180, 114, 92, 180, 114, 84, 172, 106, 84,
+       180, 106, 84, 172, 110, 92, 180, 110, 84, 180, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 110, 84, 180, 110, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 164, 94, 68, 164, 98, 76, 180, 106, 84, 172, 110, 84,
+       172, 102, 84, 172, 102, 84, 164, 102, 76, 172, 102, 76, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 172, 102, 84, 172, 102, 84, 172, 102, 76,
+       172, 106, 84, 172, 106, 84, 172, 102, 84, 164, 98, 76, 172, 102, 76,
+       172, 106, 84, 180, 110, 84, 180, 114, 92, 180, 110, 84, 172, 106, 84,
+       172, 106, 84, 180, 110, 92, 180, 110, 84, 172, 110, 84, 172, 102, 84,
+       172, 102, 76, 172, 106, 84, 180, 110, 84, 164, 98, 76, 164, 98, 76,
+       172, 106, 84, 164, 102, 76, 172, 102, 84, 164, 98, 84, 164, 98, 76,
+       172, 106, 84, 172, 110, 84, 172, 102, 84, 164, 102, 84, 164, 102, 84,
+       172, 106, 84, 164, 102, 84, 164, 102, 84, 172, 102, 84, 164, 102, 84,
+       156, 94, 76, 164, 98, 76, 172, 106, 84, 172, 102, 76, 164, 98, 84,
+       172, 102, 84, 164, 98, 76, 164, 94, 76, 164, 94, 76, 164, 98, 76,
+       164, 98, 84, 164, 98, 76, 164, 94, 76, 156, 94, 76, 164, 94, 76,
+       172, 102, 84, 172, 102, 84, 164, 98, 76, 164, 94, 76, 156, 86, 68,
+       156, 90, 68, 164, 94, 76, 164, 98, 84, 164, 98, 76, 164, 98, 76,
+       164, 94, 76, 164, 94, 76, 164, 98, 84, 164, 102, 76, 164, 98, 76,
+       164, 102, 84, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 94, 76,
+       164, 98, 84, 172, 102, 84, 172, 102, 84, 172, 106, 92, 164, 102, 84,
+       164, 98, 76, 156, 94, 68, 156, 90, 68, 156, 86, 68, 132, 62, 44,
+       140, 66, 52, 140, 74, 60, 156, 94, 84, 172, 110, 100, 132, 74, 60,
+       92, 38, 28, 116, 58, 44, 164, 106, 84, 180, 114, 92, 180, 114, 92,
+      172, 106, 84, 172, 106, 84, 172, 110, 92, 188, 122, 100, 188, 126, 100,
+       180, 114, 92, 180, 114, 100, 180, 114, 92, 180, 114, 92, 180, 114, 92,
+       180, 110, 92, 172, 110, 92, 180, 110, 92, 164, 102, 84, 172, 106, 84,
+       180, 106, 92, 180, 110, 92, 180, 114, 92, 180, 110, 92, 180, 114, 92,
+       180, 110, 92, 172, 110, 84, 180, 114, 92, 180, 114, 100, 180, 114, 92,
+     180, 114, 100, 188, 122, 100, 188, 122, 100, 188, 114, 92, 180, 114, 92,
+       188, 114, 92, 188, 114, 92, 188, 122, 100, 188, 114, 92, 180, 110, 84,
+       180, 110, 92, 180, 110, 84, 180, 110, 92, 180, 114, 92, 180, 114, 92,
+       180, 110, 84, 180, 110, 92, 180, 110, 84, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 180, 114, 92, 180, 110, 84, 180, 110, 92, 180, 110, 84,
+       180, 110, 92, 172, 110, 84, 172, 106, 84, 180, 106, 84, 180, 110, 84,
+       180, 110, 84, 180, 110, 84, 172, 106, 84, 172, 102, 76, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 110, 84, 180, 114, 92,
+       188, 118, 92, 188, 122, 100, 188, 114, 92, 180, 110, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 180, 110, 84, 180, 114, 92, 188, 118, 92,
+       180, 110, 92, 180, 114, 84, 180, 110, 92, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 180, 110, 84, 172, 106, 84, 172, 102, 84, 172, 106, 76,
+       172, 106, 84, 172, 106, 84, 172, 102, 76, 172, 102, 76, 172, 106, 84,
+       180, 106, 84, 172, 110, 84, 172, 102, 84, 180, 110, 84, 172, 106, 84,
+       164, 94, 68, 164, 98, 76, 172, 106, 84, 180, 110, 84, 172, 106, 84,
+       172, 102, 76, 172, 102, 76, 172, 102, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 76, 172, 102, 76, 172, 102, 84, 164, 102, 76, 172, 102, 84,
+       172, 106, 84, 172, 106, 84, 172, 102, 76, 172, 102, 84, 180, 110, 84,
+       180, 110, 92, 180, 114, 84, 180, 110, 92, 172, 106, 84, 180, 106, 84,
+       172, 110, 84, 180, 106, 84, 172, 110, 92, 180, 106, 84, 172, 106, 84,
+       180, 110, 84, 172, 106, 84, 164, 98, 76, 172, 98, 76, 180, 110, 84,
+       172, 106, 84, 172, 102, 84, 164, 98, 76, 164, 102, 84, 172, 106, 84,
+       172, 110, 92, 172, 106, 84, 172, 102, 84, 164, 102, 84, 172, 106, 84,
+       164, 98, 76, 164, 98, 76, 164, 102, 84, 164, 98, 76, 156, 90, 68,
+       156, 90, 68, 164, 98, 84, 164, 98, 84, 172, 102, 76, 172, 102, 84,
+       164, 102, 84, 164, 98, 76, 164, 98, 84, 172, 102, 84, 172, 106, 84,
+       172, 98, 84, 164, 98, 76, 164, 98, 76, 172, 98, 84, 172, 106, 84,
+       172, 106, 84, 164, 98, 84, 164, 94, 76, 156, 94, 76, 164, 98, 76,
+       164, 98, 76, 164, 102, 76, 164, 102, 84, 164, 98, 76, 164, 98, 76,
+       156, 94, 76, 164, 102, 76, 172, 102, 84, 164, 102, 84, 164, 102, 76,
+       164, 102, 84, 164, 98, 84, 164, 98, 76, 164, 98, 84, 164, 98, 84,
+       164, 98, 84, 172, 102, 84, 164, 102, 84, 172, 106, 84, 164, 102, 84,
+       164, 98, 76, 164, 98, 76, 172, 102, 84, 164, 90, 68, 164, 90, 76,
+       164, 94, 76, 164, 102, 92, 172, 114, 100, 140, 82, 68, 116, 58, 44,
+       116, 62, 52, 148, 86, 68, 164, 98, 76, 164, 102, 84, 164, 98, 76,
+       156, 94, 76, 164, 98, 76, 164, 102, 84, 172, 102, 84, 164, 102, 84,
+       164, 102, 76, 164, 102, 84, 164, 98, 84, 164, 98, 76, 164, 102, 84,
+       164, 98, 76, 164, 98, 76, 172, 102, 84, 172, 102, 84, 172, 106, 84,
+       180, 110, 84, 172, 110, 92, 180, 110, 84, 172, 106, 92, 172, 106, 84,
+       164, 90, 76, 172, 106, 84, 180, 110, 92, 172, 98, 84, 164, 98, 76,
+       172, 106, 84, 180, 110, 92, 180, 114, 92, 180, 110, 92, 180, 110, 84,
+       188, 114, 92, 188, 118, 100, 188, 114, 92, 180, 110, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 180, 110, 84, 180, 110, 84, 180, 114, 92,
+       180, 110, 84, 180, 114, 92, 180, 106, 84, 172, 110, 84, 180, 106, 84,
+       172, 106, 84, 180, 110, 84, 172, 110, 84, 180, 110, 84, 172, 110, 84,
+       172, 102, 76, 172, 102, 76, 172, 102, 76, 172, 102, 84, 172, 110, 92,
+       180, 110, 84, 172, 106, 84, 172, 102, 84, 172, 110, 84, 180, 110, 84,
+       180, 110, 84, 180, 110, 84, 172, 106, 84, 172, 106, 84, 180, 110, 84,
+       180, 110, 92, 180, 114, 92, 180, 114, 92, 172, 106, 84, 172, 102, 84,
+       172, 102, 76, 172, 106, 84, 180, 106, 84, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 180, 110, 84, 180, 110, 84, 180, 110, 92, 180, 114, 84,
+       172, 106, 84, 172, 106, 84, 172, 102, 76, 172, 102, 76, 172, 102, 84,
+       172, 102, 76, 164, 98, 76, 164, 98, 76, 172, 102, 76, 172, 106, 84,
+       172, 102, 84, 172, 102, 76, 172, 106, 84, 172, 102, 76, 156, 90, 68,
+       164, 94, 68, 172, 106, 84, 172, 106, 84, 172, 102, 76, 172, 98, 76,
+       164, 98, 76, 164, 98, 76, 172, 102, 76, 172, 102, 76, 172, 102, 84,
+       164, 102, 76, 172, 102, 76, 164, 98, 76, 172, 102, 76, 180, 106, 84,
+       172, 106, 84, 164, 102, 76, 172, 102, 76, 172, 110, 92, 180, 110, 84,
+       172, 110, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 180, 114, 84, 172, 106, 84, 180, 106, 84,
+       172, 106, 84, 164, 94, 68, 164, 98, 76, 180, 110, 84, 180, 114, 92,
+       164, 98, 84, 156, 98, 76, 164, 98, 76, 172, 106, 84, 172, 110, 92,
+       172, 106, 84, 164, 102, 76, 164, 102, 84, 156, 90, 68, 156, 90, 68,
+       156, 94, 76, 164, 102, 76, 164, 98, 76, 156, 94, 76, 164, 98, 76,
+       164, 102, 84, 164, 98, 76, 164, 98, 76, 164, 98, 84, 172, 98, 76,
+       164, 98, 84, 172, 98, 76, 172, 102, 84, 172, 106, 92, 164, 98, 76,
+       164, 94, 76, 164, 98, 76, 164, 98, 84, 172, 106, 84, 172, 102, 84,
+       164, 98, 76, 156, 90, 68, 164, 98, 76, 164, 98, 76, 164, 98, 84,
+       164, 98, 76, 164, 98, 84, 164, 102, 76, 164, 98, 84, 164, 102, 76,
+       172, 102, 84, 164, 102, 84, 164, 98, 76, 164, 98, 84, 164, 98, 76,
+       164, 98, 76, 164, 102, 76, 164, 98, 76, 164, 98, 84, 172, 98, 84,
+       164, 102, 84, 164, 102, 84, 164, 102, 84, 164, 106, 84, 172, 102, 84,
+       172, 106, 84, 172, 102, 84, 172, 102, 84, 172, 102, 92, 164, 98, 84,
+       164, 102, 92, 156, 98, 84, 132, 74, 60, 116, 62, 52, 116, 58, 44,
+       148, 86, 68, 164, 94, 76, 164, 102, 84, 164, 102, 76, 164, 98, 76,
+       164, 98, 76, 164, 102, 84, 164, 98, 76, 172, 106, 84, 172, 106, 84,
+       172, 106, 92, 172, 110, 84, 172, 110, 92, 180, 110, 92, 180, 114, 92,
+       180, 114, 92, 164, 102, 84, 172, 102, 84, 172, 106, 84, 172, 106, 92,
+       180, 110, 92, 180, 110, 92, 172, 106, 84, 172, 102, 84, 164, 98, 84,
+       180, 114, 92, 188, 122, 100, 180, 114, 92, 172, 102, 84, 180, 106, 92,
+      188, 118, 100, 188, 122, 100, 172, 102, 84, 172, 106, 84, 180, 106, 84,
+       180, 110, 84, 180, 110, 84, 180, 106, 92, 172, 102, 76, 172, 102, 84,
+       180, 110, 84, 180, 110, 84, 180, 110, 92, 180, 110, 84, 180, 114, 92,
+       180, 114, 92, 180, 110, 84, 172, 106, 84, 172, 102, 76, 164, 98, 76,
+       172, 102, 84, 172, 106, 84, 180, 110, 92, 180, 114, 92, 172, 102, 84,
+       172, 102, 84, 172, 106, 84, 172, 106, 84, 180, 106, 84, 172, 106, 84,
+       172, 102, 76, 164, 98, 76, 172, 102, 76, 172, 102, 84, 172, 106, 84,
+       180, 110, 92, 180, 110, 84, 180, 110, 84, 172, 106, 84, 172, 106, 84,
+       180, 110, 84, 180, 114, 92, 180, 114, 92, 188, 114, 92, 180, 114, 92,
+       180, 110, 92, 172, 110, 84, 172, 106, 84, 180, 114, 92, 180, 110, 92,
+       180, 110, 84, 172, 110, 84, 180, 110, 84, 172, 106, 84, 172, 106, 84,
+       172, 102, 76, 172, 102, 84, 172, 102, 84, 172, 106, 76, 164, 98, 76,
+       164, 98, 76, 172, 98, 76, 172, 102, 84, 172, 106, 84, 172, 106, 76,
+       164, 98, 76, 172, 106, 84, 172, 102, 84, 164, 94, 68, 164, 94, 76,
+       172, 102, 76, 172, 102, 76, 164, 102, 84, 172, 102, 76, 164, 98, 76,
+       172, 102, 76, 172, 102, 84, 172, 106, 84, 172, 102, 76, 172, 102, 84,
+       164, 102, 76, 172, 98, 76, 164, 102, 76, 172, 106, 84, 172, 102, 76,
+       172, 102, 76, 172, 102, 84, 180, 110, 84, 180, 110, 84, 172, 102, 84,
+       172, 102, 76, 172, 106, 84, 172, 106, 76, 172, 102, 76, 172, 102, 84,
+       172, 106, 84, 180, 110, 84, 172, 106, 84, 180, 110, 84, 172, 102, 84,
+       156, 90, 68, 164, 94, 68, 172, 110, 84, 180, 114, 92, 172, 102, 76,
+       164, 94, 76, 164, 98, 76, 164, 102, 84, 172, 106, 84, 164, 102, 84,
+       164, 98, 76, 164, 98, 84, 156, 94, 76, 164, 98, 76, 164, 98, 84,
+       164, 102, 84, 164, 98, 76, 164, 98, 84, 164, 102, 76, 164, 102, 84,
+       164, 94, 76, 164, 94, 76, 164, 98, 76, 164, 98, 84, 164, 98, 76,
+       164, 98, 76, 172, 102, 84, 172, 106, 84, 164, 98, 76, 164, 98, 76,
+       164, 94, 76, 164, 98, 76, 172, 102, 84, 172, 102, 84, 164, 94, 76,
+       156, 90, 68, 164, 98, 84, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 84, 164, 102, 84, 172, 102, 84, 164, 102, 84,
+       164, 98, 76, 164, 98, 84, 164, 98, 76, 164, 98, 76, 164, 98, 84,
+       164, 98, 76, 164, 98, 84, 172, 102, 84, 164, 102, 84, 172, 102, 84,
+       164, 98, 84, 164, 102, 76, 164, 98, 76, 164, 102, 76, 164, 98, 76,
+       172, 98, 84, 164, 98, 76, 172, 98, 84, 164, 94, 76, 164, 98, 84,
+       156, 98, 84, 124, 70, 60, 116, 58, 44, 116, 62, 44, 164, 98, 76,
+       164, 102, 84, 172, 106, 84, 164, 98, 84, 164, 102, 84, 172, 102, 84,
+       172, 106, 84, 164, 102, 84, 164, 98, 84, 164, 98, 76, 164, 102, 84,
+       172, 102, 84, 172, 106, 84, 172, 110, 84, 172, 110, 92, 180, 110, 92,
+       172, 110, 92, 180, 110, 92, 180, 110, 92, 180, 114, 92, 180, 114, 92,
+       180, 114, 92, 180, 106, 92, 164, 102, 84, 180, 106, 84, 180, 114, 100,
+     188, 118, 100, 188, 118, 100, 180, 114, 92, 180, 110, 92, 180, 118, 100,
+     188, 118, 100, 188, 114, 92, 188, 118, 100, 188, 118, 92, 188, 118, 100,
+       188, 114, 92, 188, 122, 100, 172, 106, 84, 172, 106, 84, 180, 110, 84,
+       172, 110, 92, 180, 110, 84, 172, 106, 84, 172, 110, 84, 180, 110, 84,
+       180, 114, 92, 172, 106, 84, 172, 102, 84, 172, 102, 76, 172, 106, 84,
+       180, 110, 84, 180, 114, 92, 180, 114, 92, 180, 110, 84, 172, 110, 84,
+       172, 106, 84, 180, 110, 84, 180, 114, 92, 180, 110, 84, 172, 106, 84,
+       172, 102, 76, 172, 106, 84, 172, 106, 84, 180, 110, 84, 180, 114, 92,
+       180, 114, 92, 180, 114, 92, 180, 106, 84, 172, 106, 84, 172, 106, 84,
+       180, 110, 84, 180, 114, 92, 188, 118, 92, 188, 118, 92, 180, 114, 92,
+       180, 110, 84, 172, 106, 84, 180, 106, 84, 172, 106, 84, 180, 106, 84,
+       172, 106, 84, 172, 106, 84, 172, 102, 84, 172, 102, 76, 172, 106, 84,
+       172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 102, 76, 172, 102, 84,
+       172, 102, 76, 172, 106, 84, 180, 110, 84, 180, 106, 84, 172, 102, 76,
+       172, 106, 84, 172, 106, 84, 164, 98, 76, 164, 98, 76, 172, 102, 84,
+       164, 98, 76, 172, 106, 76, 172, 102, 84, 164, 98, 76, 172, 102, 76,
+       172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 102, 76, 172, 102, 84,
+       172, 102, 76, 172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 98, 76,
+       164, 102, 84, 180, 110, 84, 172, 110, 84, 172, 102, 84, 172, 102, 76,
+       172, 106, 84, 172, 106, 84, 172, 98, 76, 172, 102, 76, 172, 106, 84,
+       172, 106, 84, 172, 102, 84, 180, 110, 84, 172, 106, 84, 156, 94, 68,
+       164, 90, 68, 172, 106, 84, 180, 110, 84, 164, 102, 84, 164, 98, 76,
+       164, 98, 76, 164, 102, 84, 172, 106, 84, 164, 98, 84, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 172, 106, 84, 172, 106, 84, 164, 98, 76,
+       164, 94, 76, 164, 98, 76, 164, 98, 84, 164, 98, 76, 164, 98, 76,
+       164, 98, 84, 172, 102, 84, 172, 98, 76, 164, 98, 76, 164, 94, 76,
+       164, 98, 76, 172, 102, 84, 164, 98, 84, 164, 94, 76, 164, 94, 76,
+       164, 94, 76, 164, 98, 84, 164, 98, 76, 164, 94, 76, 156, 86, 68,
+       164, 94, 76, 156, 94, 76, 164, 98, 76, 164, 98, 76, 164, 102, 84,
+       172, 102, 76, 164, 102, 84, 164, 102, 76, 172, 102, 84, 164, 102, 76,
+       164, 102, 84, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 84,
+       164, 102, 76, 164, 102, 84, 172, 98, 84, 164, 102, 84, 164, 98, 76,
+       164, 102, 84, 156, 98, 76, 164, 98, 76, 164, 94, 76, 164, 98, 76,
+       172, 98, 84, 172, 98, 84, 164, 90, 76, 172, 106, 92, 164, 106, 92,
+       132, 70, 60, 116, 62, 44, 116, 58, 44, 164, 98, 84, 164, 98, 76,
+       164, 98, 76, 156, 90, 68, 156, 90, 68, 164, 98, 76, 164, 102, 84,
+       164, 98, 76, 172, 106, 84, 172, 102, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 92, 172, 106, 84, 172, 110, 92, 172, 106, 84, 180, 110, 92,
+       172, 106, 84, 180, 110, 92, 180, 110, 92, 180, 114, 100, 180, 110, 92,
+       172, 106, 84, 164, 98, 76, 180, 110, 92, 180, 110, 92, 180, 114, 92,
+      188, 118, 100, 188, 118, 100, 180, 114, 92, 180, 110, 92, 180, 110, 92,
+       180, 114, 92, 188, 118, 92, 188, 118, 100, 180, 110, 84, 180, 110, 92,
+       188, 118, 92, 172, 106, 84, 180, 110, 84, 180, 114, 92, 180, 110, 92,
+       180, 110, 84, 172, 106, 84, 172, 106, 84, 180, 106, 84, 180, 110, 92,
+       172, 106, 84, 180, 110, 84, 180, 110, 92, 180, 114, 92, 180, 114, 92,
+       180, 110, 92, 180, 106, 84, 172, 110, 84, 180, 106, 84, 180, 110, 92,
+       180, 110, 84, 180, 118, 100, 188, 114, 92, 180, 114, 92, 180, 110, 92,
+      188, 122, 100, 188, 118, 92, 180, 114, 100, 180, 114, 84, 180, 110, 92,
+       180, 110, 84, 180, 110, 92, 180, 110, 84, 172, 106, 84, 172, 110, 84,
+       180, 110, 84, 180, 110, 92, 180, 110, 84, 180, 110, 92, 180, 110, 84,
+       180, 110, 92, 164, 98, 76, 172, 102, 76, 172, 106, 84, 172, 102, 76,
+       172, 102, 76, 172, 102, 76, 172, 106, 84, 180, 106, 84, 180, 110, 84,
+       180, 110, 84, 180, 110, 92, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 110, 84, 180, 114, 92, 180, 110, 92, 172, 106, 84, 180, 106, 84,
+       180, 110, 84, 172, 102, 76, 172, 102, 76, 172, 102, 76, 164, 94, 76,
+       172, 106, 84, 172, 102, 84, 172, 106, 84, 172, 102, 84, 172, 106, 84,
+       180, 110, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 180, 110, 84, 172, 106, 84, 172, 102, 76, 172, 102, 84,
+       180, 110, 84, 180, 110, 92, 172, 106, 76, 172, 102, 84, 172, 106, 84,
+       172, 106, 84, 172, 102, 76, 164, 102, 76, 180, 106, 84, 164, 98, 76,
+       164, 102, 76, 180, 110, 84, 172, 110, 84, 164, 94, 76, 156, 94, 68,
+       172, 102, 84, 172, 106, 84, 172, 106, 92, 164, 102, 84, 164, 98, 76,
+       164, 102, 84, 172, 102, 84, 164, 98, 76, 164, 98, 84, 164, 102, 84,
+       156, 90, 68, 164, 102, 84, 164, 102, 84, 156, 86, 68, 148, 86, 68,
+       172, 102, 84, 172, 110, 84, 172, 102, 84, 172, 102, 84, 172, 102, 84,
+       172, 102, 84, 164, 98, 76, 164, 94, 76, 156, 94, 76, 164, 94, 76,
+       164, 98, 76, 172, 98, 84, 164, 98, 76, 156, 90, 76, 164, 94, 76,
+       172, 98, 76, 164, 98, 84, 164, 94, 76, 156, 90, 68, 148, 90, 68,
+       156, 94, 76, 164, 94, 76, 164, 102, 84, 164, 102, 84, 164, 102, 84,
+       164, 98, 76, 164, 98, 84, 172, 106, 84, 164, 102, 84, 172, 102, 84,
+       164, 98, 76, 164, 98, 84, 164, 98, 76, 164, 102, 76, 164, 98, 84,
+       164, 94, 76, 164, 94, 76, 164, 98, 84, 164, 102, 84, 164, 102, 84,
+       164, 98, 76, 164, 94, 76, 156, 94, 76, 164, 98, 76, 164, 94, 84,
+       164, 98, 84, 156, 94, 76, 164, 106, 92, 164, 102, 92, 124, 66, 52,
+       116, 58, 44, 116, 58, 36, 164, 106, 92, 172, 106, 84, 164, 106, 84,
+       172, 102, 84, 164, 102, 84, 164, 102, 84, 164, 102, 76, 164, 98, 84,
+       172, 106, 84, 172, 106, 84, 172, 110, 92, 172, 110, 84, 172, 106, 92,
+       172, 106, 84, 172, 110, 92, 180, 114, 92, 180, 110, 92, 180, 110, 92,
+      172, 110, 92, 180, 110, 92, 188, 118, 92, 188, 118, 100, 180, 114, 100,
+      180, 114, 92, 180, 114, 92, 180, 114, 92, 188, 118, 100, 180, 114, 100,
+       180, 114, 92, 180, 114, 92, 180, 110, 92, 172, 106, 84, 188, 118, 100,
+       188, 118, 92, 188, 118, 100, 188, 118, 92, 188, 118, 92, 180, 114, 92,
+      180, 106, 92, 180, 114, 92, 188, 118, 100, 180, 114, 100, 180, 110, 92,
+       172, 106, 84, 180, 110, 92, 180, 114, 92, 180, 114, 92, 180, 110, 92,
+      172, 106, 84, 172, 106, 84, 180, 114, 92, 188, 122, 100, 188, 118, 100,
+     180, 118, 92, 188, 114, 100, 180, 118, 92, 188, 118, 100, 188, 118, 100,
+     188, 118, 100, 180, 114, 92, 180, 118, 92, 188, 118, 100, 188, 122, 100,
+      188, 118, 100, 180, 114, 92, 188, 114, 92, 180, 114, 100, 180, 114, 92,
+       180, 110, 92, 172, 106, 84, 188, 118, 92, 180, 114, 92, 172, 110, 84,
+       172, 110, 84, 172, 110, 84, 172, 110, 84, 180, 110, 84, 172, 106, 84,
+       172, 110, 84, 172, 106, 84, 180, 106, 84, 172, 106, 84, 180, 106, 84,
+       172, 102, 84, 180, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       180, 110, 84, 180, 114, 84, 180, 110, 92, 180, 110, 84, 180, 110, 92,
+       180, 110, 84, 172, 106, 84, 172, 106, 76, 172, 102, 84, 164, 102, 76,
+       164, 102, 76, 172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 102, 76,
+       172, 102, 84, 172, 106, 84, 180, 110, 84, 180, 110, 92, 172, 106, 84,
+       172, 106, 84, 172, 102, 84, 180, 106, 84, 172, 106, 84, 180, 106, 92,
+       172, 106, 84, 180, 106, 92, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 172, 110, 84, 180, 110, 84, 172, 110, 84, 172, 98, 76,
+       164, 102, 76, 172, 110, 84, 180, 118, 92, 172, 106, 84, 172, 110, 84,
+       172, 102, 84, 172, 102, 76, 164, 102, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 68, 164, 102, 84, 164, 102, 76, 164, 98, 84, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 102, 76, 164, 102, 84, 164, 98, 76,
+       164, 98, 76, 156, 98, 76, 164, 94, 76, 156, 94, 76, 164, 98, 76,
+       164, 98, 84, 164, 106, 84, 164, 98, 76, 164, 98, 76, 156, 94, 76,
+       156, 94, 76, 164, 94, 76, 164, 98, 76, 172, 102, 84, 164, 102, 84,
+       164, 94, 76, 156, 98, 76, 164, 94, 76, 164, 98, 76, 164, 98, 76,
+       164, 102, 76, 164, 94, 76, 156, 94, 76, 148, 86, 68, 164, 94, 76,
+       164, 102, 84, 164, 102, 76, 164, 94, 76, 156, 94, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 84, 164, 98, 76, 164, 98, 76, 164, 98, 84,
+       164, 94, 84, 164, 90, 76, 164, 94, 76, 164, 98, 84, 164, 98, 84,
+       164, 94, 76, 164, 94, 76, 172, 102, 84, 164, 98, 76, 172, 98, 84,
+       164, 98, 84, 172, 110, 92, 164, 102, 84, 124, 66, 52, 116, 58, 36,
+       108, 46, 28, 180, 110, 92, 180, 110, 92, 172, 110, 92, 172, 110, 84,
+       172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 110, 92,
+       172, 110, 92, 180, 110, 92, 172, 110, 92, 172, 110, 84, 172, 110, 92,
+       180, 114, 92, 180, 118, 100, 180, 110, 92, 172, 106, 84, 180, 110, 92,
+      180, 110, 92, 180, 114, 100, 188, 118, 100, 180, 114, 92, 180, 114, 92,
+      180, 114, 100, 180, 114, 92, 180, 114, 100, 180, 114, 92, 180, 110, 92,
+       180, 110, 92, 172, 106, 92, 180, 106, 84, 180, 114, 92, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 172, 110, 92,
+       180, 110, 92, 188, 118, 100, 180, 114, 92, 180, 110, 92, 172, 106, 84,
+       180, 106, 92, 180, 110, 92, 180, 114, 92, 172, 106, 92, 172, 106, 84,
+      180, 106, 92, 180, 114, 92, 188, 118, 100, 188, 118, 100, 180, 114, 92,
+    180, 110, 92, 180, 114, 100, 188, 118, 100, 188, 118, 100, 180, 118, 100,
+   188, 118, 100, 188, 118, 100, 188, 118, 100, 196, 126, 108, 188, 122, 100,
+   188, 118, 100, 188, 118, 100, 188, 122, 100, 188, 118, 100, 180, 118, 100,
+       180, 114, 92, 188, 118, 100, 180, 118, 92, 180, 110, 84, 180, 110, 92,
+       180, 114, 84, 180, 114, 92, 180, 110, 92, 180, 110, 84, 180, 110, 92,
+       180, 110, 84, 180, 110, 92, 180, 110, 92, 188, 114, 84, 180, 110, 92,
+       180, 110, 84, 188, 114, 92, 188, 114, 92, 180, 118, 92, 188, 118, 100,
+      188, 118, 92, 188, 122, 100, 188, 118, 92, 188, 118, 100, 180, 118, 92,
+       180, 106, 84, 172, 106, 84, 172, 102, 76, 172, 102, 76, 172, 102, 84,
+       172, 102, 76, 172, 106, 84, 172, 106, 84, 172, 102, 84, 164, 102, 84,
+       172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 102, 84, 172, 102, 84,
+       164, 98, 84, 172, 106, 84, 172, 110, 92, 172, 106, 84, 180, 110, 92,
+       172, 106, 84, 172, 110, 92, 180, 106, 92, 172, 110, 92, 180, 110, 84,
+       172, 114, 92, 180, 114, 92, 172, 110, 84, 172, 106, 84, 172, 106, 84,
+       180, 114, 84, 180, 118, 92, 180, 110, 84, 172, 110, 84, 172, 110, 84,
+       172, 106, 84, 164, 102, 76, 172, 102, 76, 164, 102, 76, 164, 102, 84,
+       172, 102, 76, 164, 102, 84, 164, 98, 76, 164, 98, 84, 164, 98, 76,
+       164, 102, 84, 164, 102, 84, 172, 98, 76, 164, 98, 84, 164, 98, 76,
+       164, 94, 76, 156, 94, 68, 164, 94, 76, 164, 98, 76, 164, 98, 76,
+       164, 102, 84, 172, 102, 84, 164, 102, 84, 164, 98, 76, 164, 98, 76,
+       156, 94, 76, 164, 98, 76, 164, 98, 76, 164, 102, 76, 164, 98, 76,
+       164, 98, 76, 156, 94, 76, 164, 98, 76, 164, 102, 84, 164, 98, 84,
+       164, 98, 76, 164, 94, 76, 156, 94, 68, 164, 102, 84, 172, 106, 84,
+       172, 110, 92, 172, 102, 84, 164, 102, 76, 172, 102, 84, 164, 106, 84,
+       164, 98, 84, 164, 98, 76, 164, 98, 84, 156, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 84, 164, 98, 84, 164, 94, 76,
+       164, 94, 76, 164, 94, 76, 164, 98, 84, 164, 98, 84, 164, 98, 84,
+       164, 94, 76, 156, 94, 84, 156, 94, 76, 156, 94, 76, 156, 90, 76,
+       164, 98, 84, 156, 90, 76, 116, 54, 36, 108, 46, 28, 116, 54, 36,
+       172, 110, 92, 172, 110, 92, 180, 110, 92, 172, 110, 92, 172, 106, 84,
+       172, 106, 92, 164, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       172, 110, 84, 172, 106, 92, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       180, 110, 92, 172, 106, 84, 172, 106, 84, 172, 106, 84, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 188, 114, 100, 180, 114, 92, 180, 110, 92,
+       180, 110, 92, 180, 110, 92, 180, 110, 92, 172, 106, 84, 180, 106, 92,
+       172, 110, 84, 172, 106, 92, 180, 110, 84, 180, 110, 92, 180, 110, 92,
+       180, 110, 84, 180, 110, 92, 180, 106, 84, 180, 106, 84, 180, 114, 92,
+       180, 114, 100, 180, 114, 92, 172, 106, 92, 172, 106, 84, 172, 106, 84,
+       172, 106, 92, 180, 110, 92, 172, 106, 84, 172, 102, 84, 172, 106, 84,
+       180, 114, 92, 180, 114, 100, 180, 114, 92, 180, 114, 92, 180, 110, 92,
+     180, 114, 92, 188, 122, 100, 188, 118, 100, 188, 118, 100, 180, 114, 92,
+       180, 114, 92, 180, 114, 92, 180, 110, 92, 172, 106, 92, 172, 106, 84,
+       172, 106, 84, 172, 106, 92, 172, 106, 84, 180, 110, 92, 172, 110, 84,
+       180, 114, 92, 180, 114, 92, 172, 110, 84, 172, 110, 84, 172, 110, 84,
+       180, 110, 92, 180, 114, 84, 172, 110, 84, 172, 102, 84, 172, 106, 76,
+       172, 106, 84, 180, 106, 84, 172, 106, 84, 180, 106, 84, 180, 106, 84,
+       172, 106, 84, 180, 106, 84, 180, 110, 84, 172, 110, 92, 180, 110, 84,
+       180, 110, 92, 172, 110, 84, 180, 110, 84, 172, 106, 84, 172, 106, 84,
+       172, 106, 84, 164, 102, 84, 172, 102, 76, 164, 102, 76, 172, 102, 84,
+       172, 106, 76, 172, 106, 84, 172, 102, 84, 172, 102, 84, 172, 106, 84,
+       180, 106, 84, 172, 106, 92, 172, 106, 84, 172, 102, 84, 172, 102, 84,
+       172, 102, 84, 172, 106, 84, 172, 102, 84, 172, 106, 84, 172, 106, 92,
+       180, 106, 84, 172, 106, 92, 172, 110, 84, 180, 110, 92, 180, 110, 92,
+       172, 114, 92, 180, 110, 84, 172, 114, 92, 180, 110, 84, 172, 114, 92,
+       180, 110, 92, 172, 114, 92, 180, 110, 92, 172, 106, 84, 172, 106, 84,
+       164, 106, 84, 172, 106, 84, 164, 102, 84, 172, 106, 84, 164, 98, 76,
+       164, 98, 76, 164, 98, 84, 164, 102, 76, 164, 102, 84, 164, 98, 76,
+       164, 98, 84, 164, 98, 76, 164, 98, 76, 164, 98, 76, 156, 94, 76,
+       156, 90, 76, 156, 94, 68, 156, 94, 76, 156, 94, 76, 164, 98, 76,
+       164, 102, 84, 164, 102, 76, 164, 98, 76, 156, 94, 76, 156, 94, 76,
+       156, 94, 68, 156, 90, 76, 156, 94, 76, 164, 98, 76, 164, 98, 76,
+       156, 94, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       156, 94, 76, 156, 86, 68, 156, 94, 68, 164, 98, 76, 164, 98, 76,
+       156, 94, 76, 156, 90, 68, 156, 94, 76, 164, 94, 76, 156, 98, 76,
+       164, 94, 76, 156, 98, 76, 164, 94, 76, 164, 98, 76, 156, 94, 76,
+       164, 98, 76, 156, 94, 76, 164, 94, 76, 156, 90, 76, 156, 90, 76,
+       156, 90, 76, 156, 94, 76, 164, 94, 76, 156, 90, 76, 156, 94, 76,
+       164, 98, 84, 164, 94, 76, 164, 98, 84, 156, 94, 76, 164, 102, 84,
+       156, 94, 76, 116, 58, 36, 116, 54, 36, 116, 58, 36, 180, 114, 100,
+       180, 118, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92,
+       180, 110, 92, 172, 110, 92, 180, 114, 92, 180, 114, 100, 180, 114, 92,
+       180, 114, 92, 172, 110, 92, 172, 110, 92, 180, 114, 92, 180, 118, 100,
+    180, 114, 92, 180, 114, 100, 188, 118, 100, 188, 118, 100, 188, 122, 100,
+   196, 126, 108, 188, 122, 108, 196, 126, 100, 188, 122, 108, 188, 122, 100,
+   188, 118, 100, 180, 118, 100, 188, 114, 100, 180, 118, 100, 188, 118, 100,
+   188, 118, 100, 196, 126, 108, 188, 126, 100, 196, 126, 108, 188, 122, 100,
+    180, 114, 100, 180, 114, 92, 188, 122, 100, 196, 122, 108, 196, 126, 108,
+    196, 126, 100, 188, 118, 100, 180, 114, 100, 188, 114, 92, 180, 118, 100,
+   188, 122, 100, 188, 118, 100, 188, 114, 100, 188, 118, 100, 188, 122, 100,
+   196, 122, 108, 188, 126, 108, 188, 122, 100, 196, 126, 108, 196, 130, 108,
+   196, 130, 116, 196, 130, 108, 196, 126, 108, 188, 118, 100, 180, 114, 100,
+       180, 110, 92, 172, 106, 84, 172, 106, 84, 172, 102, 84, 172, 102, 84,
+       172, 106, 84, 180, 106, 92, 180, 114, 92, 180, 114, 92, 180, 118, 92,
+       180, 118, 92, 180, 118, 92, 180, 118, 92, 188, 118, 92, 180, 118, 92,
+       180, 118, 92, 188, 118, 100, 180, 114, 84, 180, 110, 92, 188, 114, 92,
+       180, 110, 92, 188, 114, 92, 188, 118, 92, 188, 118, 100, 188, 118, 92,
+       180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 114, 92, 180, 110, 84,
+       180, 110, 92, 180, 110, 84, 180, 110, 84, 188, 118, 92, 180, 114, 92,
+       180, 114, 92, 180, 110, 84, 180, 110, 92, 180, 114, 92, 180, 114, 92,
+    188, 118, 92, 188, 118, 100, 188, 122, 100, 188, 122, 100, 188, 122, 108,
+    188, 122, 100, 188, 122, 100, 188, 122, 100, 188, 118, 100, 180, 114, 92,
+     180, 114, 92, 180, 114, 100, 188, 114, 92, 180, 118, 100, 188, 118, 100,
+   188, 118, 100, 188, 118, 100, 188, 122, 100, 180, 122, 100, 188, 118, 100,
+    188, 122, 100, 188, 122, 100, 188, 126, 108, 188, 122, 100, 180, 118, 92,
+       172, 106, 84, 172, 110, 84, 172, 106, 84, 164, 102, 84, 172, 102, 76,
+       164, 102, 76, 164, 102, 84, 172, 102, 76, 156, 94, 76, 164, 98, 76,
+       164, 98, 76, 164, 102, 84, 164, 98, 76, 164, 102, 76, 164, 98, 76,
+       156, 98, 76, 164, 98, 84, 164, 98, 76, 156, 94, 76, 164, 94, 68,
+       156, 94, 76, 156, 94, 68, 164, 94, 76, 156, 94, 76, 164, 98, 76,
+       164, 98, 84, 164, 98, 76, 156, 94, 76, 156, 90, 68, 156, 94, 76,
+       156, 90, 68, 156, 94, 76, 164, 94, 76, 156, 94, 76, 164, 94, 76,
+       156, 98, 76, 164, 98, 76, 164, 98, 84, 156, 98, 76, 156, 94, 68,
+       164, 94, 76, 164, 98, 76, 164, 102, 84, 164, 102, 84, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 156, 94, 76, 156, 94, 68,
+       156, 94, 76, 156, 94, 76, 156, 94, 76, 156, 94, 76, 156, 94, 68,
+       156, 94, 76, 172, 98, 84, 164, 98, 84, 172, 98, 76, 164, 94, 84,
+       172, 98, 84, 164, 98, 84, 164, 98, 84, 172, 98, 84, 164, 98, 84,
+       164, 98, 84, 164, 106, 84, 164, 102, 84, 172, 110, 92, 164, 98, 84,
+       124, 66, 44, 116, 58, 36, 116, 50, 36, 172, 106, 84, 164, 102, 84,
+       172, 102, 84, 164, 102, 84, 172, 102, 84, 164, 102, 84, 164, 102, 84,
+       172, 102, 84, 164, 102, 84, 172, 106, 84, 164, 106, 84, 172, 102, 84,
+       164, 102, 76, 172, 102, 84, 164, 102, 84, 172, 106, 84, 172, 102, 84,
+       180, 106, 84, 172, 110, 92, 180, 114, 92, 180, 110, 92, 180, 114, 92,
+       180, 114, 92, 180, 114, 100, 180, 114, 92, 180, 110, 92, 180, 110, 92,
+       172, 106, 84, 180, 110, 84, 172, 106, 84, 180, 110, 92, 180, 110, 92,
+       180, 118, 92, 180, 114, 100, 180, 110, 92, 180, 110, 92, 180, 106, 92,
+       172, 102, 84, 180, 114, 92, 180, 114, 92, 180, 114, 100, 180, 114, 92,
+       180, 110, 92, 180, 106, 92, 172, 106, 84, 172, 106, 84, 180, 106, 92,
+       172, 110, 92, 172, 106, 84, 180, 110, 92, 180, 110, 92, 180, 114, 92,
+      180, 110, 92, 180, 110, 92, 180, 110, 92, 188, 114, 100, 188, 122, 100,
+       188, 118, 100, 180, 110, 92, 172, 106, 84, 172, 102, 84, 164, 98, 76,
+       172, 102, 84, 172, 102, 84, 164, 102, 84, 172, 98, 76, 164, 98, 84,
+       172, 106, 84, 180, 106, 92, 180, 110, 92, 172, 106, 92, 172, 110, 84,
+       172, 106, 84, 172, 110, 92, 172, 106, 84, 172, 110, 92, 180, 106, 84,
+       172, 110, 92, 180, 110, 84, 172, 110, 92, 180, 110, 84, 180, 110, 92,
+       180, 114, 92, 180, 114, 92, 188, 114, 92, 188, 114, 92, 180, 110, 92,
+       180, 110, 92, 180, 110, 92, 180, 110, 84, 180, 110, 92, 172, 110, 84,
+       172, 106, 84, 172, 106, 92, 172, 106, 84, 180, 106, 84, 172, 106, 84,
+       172, 102, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84, 172, 106, 84,
+       180, 110, 92, 180, 110, 92, 180, 110, 92, 180, 114, 92, 180, 114, 100,
+       180, 114, 92, 180, 110, 92, 180, 110, 92, 172, 102, 84, 172, 102, 84,
+       172, 106, 84, 172, 106, 84, 172, 106, 92, 180, 110, 84, 172, 110, 92,
+       180, 110, 92, 172, 106, 92, 172, 106, 84, 172, 106, 84, 172, 110, 92,
+       180, 114, 92, 180, 110, 92, 172, 110, 92, 172, 102, 84, 172, 106, 92,
+       164, 102, 84, 172, 102, 84, 164, 102, 84, 164, 98, 84, 164, 102, 76,
+       164, 98, 84, 164, 102, 84, 164, 98, 76, 164, 98, 76, 164, 98, 84,
+       172, 102, 76, 164, 102, 84, 164, 98, 84, 164, 98, 84, 164, 98, 76,
+       172, 102, 76, 164, 102, 84, 164, 102, 76, 164, 98, 84, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 164, 94, 76, 164, 98, 76, 164, 94, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 102, 84, 164, 102, 84, 164, 98, 76, 156, 94, 76, 164, 98, 76,
+       164, 98, 84, 172, 102, 84, 164, 102, 76, 164, 98, 84, 164, 98, 76,
+       164, 98, 84, 164, 98, 76, 164, 94, 76, 164, 94, 76, 164, 94, 76,
+       156, 94, 76, 164, 94, 68, 164, 94, 76, 164, 94, 76, 156, 94, 76,
+       164, 94, 76, 164, 90, 76, 156, 94, 76, 164, 94, 76, 164, 94, 76,
+       156, 94, 76, 164, 94, 76, 164, 94, 76, 156, 94, 76, 164, 94, 76,
+       164, 102, 84, 164, 102, 84, 172, 106, 92, 156, 94, 76, 124, 62, 44,
+       116, 50, 36, 108, 50, 28, 156, 86, 68, 156, 90, 68, 148, 86, 68,
+       156, 90, 68, 148, 86, 68, 156, 90, 68, 156, 86, 68, 148, 90, 68,
+       156, 90, 68, 156, 90, 76, 156, 94, 76, 156, 90, 68, 148, 86, 68,
+       156, 86, 68, 156, 90, 68, 156, 90, 76, 148, 86, 68, 156, 86, 68,
+       156, 90, 68, 164, 90, 76, 156, 90, 68, 156, 90, 76, 164, 90, 68,
+       156, 90, 76, 164, 90, 68, 156, 90, 76, 156, 90, 68, 156, 90, 68,
+       156, 90, 76, 156, 90, 68, 156, 90, 68, 156, 90, 68, 156, 86, 76,
+       156, 86, 68, 156, 90, 76, 156, 90, 68, 156, 90, 76, 156, 90, 68,
+       164, 90, 76, 164, 94, 76, 164, 94, 76, 156, 94, 76, 156, 90, 68,
+       156, 90, 68, 156, 86, 68, 156, 86, 68, 156, 86, 68, 156, 86, 68,
+       156, 90, 68, 156, 90, 68, 156, 90, 76, 164, 90, 68, 156, 90, 76,
+       156, 90, 68, 148, 86, 68, 156, 86, 68, 164, 94, 76, 164, 94, 76,
+       156, 90, 68, 156, 90, 68, 156, 86, 68, 156, 86, 68, 156, 86, 68,
+       156, 86, 68, 156, 86, 68, 156, 86, 68, 156, 86, 68, 156, 86, 68,
+       156, 90, 68, 164, 94, 76, 156, 90, 68, 156, 94, 76, 164, 98, 76,
+       164, 94, 76, 156, 94, 68, 156, 90, 68, 156, 94, 68, 164, 94, 68,
+       156, 86, 68, 156, 86, 68, 156, 90, 68, 156, 90, 68, 164, 90, 68,
+       164, 90, 76, 164, 90, 68, 164, 90, 76, 164, 94, 76, 156, 94, 68,
+       164, 94, 68, 156, 90, 68, 156, 90, 68, 164, 90, 68, 164, 94, 76,
+       156, 90, 68, 156, 90, 68, 156, 90, 68, 156, 90, 68, 164, 90, 68,
+       156, 90, 68, 156, 90, 68, 164, 90, 68, 156, 90, 68, 156, 90, 76,
+       156, 90, 68, 156, 90, 76, 164, 90, 68, 156, 90, 68, 156, 90, 76,
+       156, 90, 68, 156, 90, 76, 156, 90, 68, 156, 90, 76, 156, 86, 68,
+       164, 90, 76, 156, 90, 68, 164, 90, 76, 156, 94, 68, 164, 94, 76,
+       156, 90, 68, 156, 90, 76, 156, 90, 68, 156, 90, 76, 156, 94, 76,
+       156, 94, 76, 156, 90, 76, 148, 86, 68, 164, 98, 84, 164, 98, 76,
+       164, 98, 76, 156, 94, 76, 164, 94, 76, 156, 94, 76, 164, 94, 76,
+       156, 94, 76, 164, 94, 76, 156, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 94, 76, 164, 98, 76, 156, 94, 76, 156, 94, 76, 164, 98, 76,
+       164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76, 164, 98, 76,
+       164, 98, 76, 156, 94, 76, 156, 94, 76, 156, 90, 68, 156, 94, 76,
+       156, 94, 76, 164, 94, 76, 156, 98, 76, 164, 98, 76, 164, 98, 84,
+       156, 94, 76, 156, 94, 76, 156, 94, 76, 164, 94, 76, 164, 98, 76,
+       164, 98, 76, 164, 94, 76, 156, 90, 76, 156, 90, 68, 156, 90, 68,
+       156, 94, 76, 156, 90, 68, 156, 90, 68, 156, 90, 68, 148, 90, 68,
+       156, 90, 68, 156, 90, 76, 156, 94, 68, 156, 90, 68, 156, 94, 76,
+       156, 90, 68, 156, 94, 76, 156, 90, 68, 156, 94, 68, 156, 82, 68,
+       156, 86, 76, 156, 90, 76, 156, 86, 76, 148, 86, 68, 156, 86, 68,
+       156, 86, 76, 156, 90, 68, 156, 94, 76, 164, 94, 84, 164, 98, 84,
+       156, 94, 76, 156, 98, 76, 148, 86, 68, 116, 54, 36, 108, 50, 28,
+       108, 50, 36, 140, 78, 60, 140, 78, 60, 148, 78, 60, 140, 78, 60,
+       140, 78, 60, 140, 78, 60, 140, 78, 60, 140, 78, 60, 148, 82, 60,
+       148, 82, 60, 148, 82, 60, 148, 78, 60, 140, 74, 52, 140, 74, 52,
+       140, 78, 60, 148, 82, 60, 140, 70, 52, 140, 74, 52, 148, 74, 60,
+       140, 78, 60, 148, 74, 60, 140, 74, 52, 140, 74, 52, 140, 78, 60,
+       140, 74, 52, 148, 78, 60, 140, 74, 60, 148, 78, 60, 148, 74, 60,
+       148, 78, 60, 148, 74, 60, 148, 78, 60, 140, 70, 52, 140, 70, 52,
+       148, 74, 60, 140, 74, 60, 148, 78, 60, 148, 78, 68, 140, 78, 60,
+       148, 78, 60, 140, 78, 60, 148, 78, 60, 148, 78, 60, 148, 74, 60,
+       140, 74, 52, 140, 74, 52, 140, 74, 52, 140, 74, 52, 140, 74, 52,
+       148, 74, 60, 148, 78, 60, 140, 78, 60, 148, 74, 60, 140, 74, 52,
+       140, 70, 52, 140, 74, 52, 140, 78, 60, 148, 78, 60, 148, 78, 60,
+       148, 78, 60, 148, 78, 60, 148, 82, 60, 140, 74, 52, 140, 74, 52,
+       140, 78, 60, 140, 74, 52, 140, 74, 52, 140, 74, 52, 140, 74, 52,
+       140, 78, 60, 140, 82, 60, 148, 82, 60, 148, 86, 68, 148, 86, 60,
+       140, 82, 60, 148, 78, 60, 140, 78, 60, 140, 78, 60, 140, 70, 52,
+       140, 70, 52, 140, 74, 52, 140, 70, 52, 140, 74, 52, 140, 70, 52,
+       140, 74, 52, 140, 74, 52, 140, 78, 60, 148, 74, 60, 140, 74, 52,
+       140, 74, 60, 140, 74, 52, 140, 74, 60, 140, 78, 60, 148, 78, 60,
+       156, 82, 60, 148, 82, 68, 156, 82, 60, 148, 82, 68, 148, 82, 60,
+       156, 82, 68, 148, 82, 60, 148, 82, 68, 148, 82, 60, 148, 82, 60,
+       148, 82, 60, 148, 82, 68, 148, 78, 60, 156, 82, 60, 148, 82, 68,
+       148, 82, 60, 156, 82, 60, 148, 82, 60, 156, 82, 68, 148, 82, 60,
+       156, 86, 68, 148, 82, 60, 156, 82, 68, 148, 82, 60, 148, 82, 68,
+       148, 82, 68, 148, 82, 68, 148, 86, 68, 148, 82, 68, 156, 86, 68,
+       148, 82, 68, 148, 82, 60, 148, 82, 68, 140, 78, 60, 148, 78, 68,
+       140, 78, 60, 148, 78, 60, 140, 78, 60, 148, 78, 60, 140, 78, 60,
+       148, 82, 60, 148, 78, 60, 140, 78, 60, 140, 78, 60, 140, 78, 60,
+       140, 78, 60, 148, 78, 60, 148, 82, 60, 140, 78, 60, 148, 78, 60,
+       140, 78, 60, 148, 78, 60, 140, 78, 60, 140, 78, 60, 148, 78, 60,
+       148, 82, 60, 140, 74, 52, 140, 78, 60, 148, 78, 60, 140, 78, 60,
+       148, 82, 60, 148, 82, 60, 148, 82, 60, 148, 82, 60, 148, 78, 60,
+       148, 78, 60, 140, 78, 60, 140, 78, 60, 148, 82, 60, 148, 82, 60,
+       148, 78, 60, 140, 78, 60, 148, 86, 60, 148, 82, 68, 148, 82, 60,
+       148, 82, 60, 140, 78, 60, 148, 82, 60, 148, 78, 60, 148, 78, 60,
+       140, 78, 60, 140, 78, 60, 140, 78, 60, 140, 78, 60, 140, 78, 60,
+       140, 78, 60, 148, 78, 60, 140, 78, 60, 148, 82, 68, 148, 82, 68,
+       148, 86, 68, 156, 82, 68, 148, 82, 68, 148, 82, 68, 148, 82, 68,
+       148, 86, 68, 148, 82, 68, 148, 78, 60, 140, 82, 60, 140, 74, 60,
+       140, 78, 60, 140, 74, 60, 116, 50, 36, 108, 50, 36, 108, 50, 28,
+       108, 42, 28, 108, 42, 20, 108, 42, 20, 108, 42, 20, 116, 46, 28,
+       108, 42, 20, 116, 46, 28, 108, 42, 20, 108, 46, 28, 108, 46, 28,
+       116, 46, 28, 108, 46, 20, 108, 42, 20, 100, 42, 20, 108, 42, 20,
+       108, 42, 28, 108, 42, 20, 116, 46, 28, 116, 46, 28, 116, 46, 28,
+       108, 42, 20, 108, 38, 20, 108, 42, 28, 116, 42, 28, 108, 42, 20,
+       116, 46, 28, 116, 46, 28, 116, 46, 28, 116, 50, 28, 108, 46, 28,
+       116, 46, 28, 108, 42, 20, 108, 42, 28, 116, 42, 28, 108, 46, 28,
+       116, 46, 28, 116, 46, 28, 108, 46, 28, 116, 42, 28, 108, 42, 20,
+       116, 46, 28, 108, 42, 20, 116, 46, 28, 108, 46, 28, 108, 42, 20,
+       116, 42, 28, 108, 38, 20, 108, 42, 28, 116, 46, 28, 108, 46, 28,
+       116, 46, 28, 108, 42, 20, 108, 42, 20, 116, 42, 28, 116, 46, 28,
+       116, 50, 28, 116, 50, 28, 116, 50, 28, 116, 46, 28, 116, 46, 28,
+       116, 46, 28, 116, 50, 28, 116, 46, 28, 116, 50, 36, 124, 50, 36,
+       116, 50, 28, 116, 46, 28, 116, 46, 28, 116, 46, 28, 116, 46, 28,
+       108, 46, 20, 108, 50, 28, 116, 50, 28, 116, 54, 28, 108, 46, 28,
+       108, 46, 20, 108, 42, 20, 108, 42, 20, 116, 50, 28, 116, 46, 28,
+       116, 46, 28, 116, 46, 28, 116, 46, 28, 108, 46, 28, 116, 46, 28,
+       116, 46, 28, 116, 46, 28, 116, 46, 28, 116, 46, 28, 116, 42, 28,
+       116, 46, 28, 116, 46, 28, 116, 50, 28, 124, 50, 36, 124, 58, 36,
+       124, 58, 36, 124, 58, 36, 124, 58, 36, 124, 58, 44, 124, 58, 36,
+       124, 58, 36, 124, 54, 36, 132, 62, 44, 124, 54, 36, 124, 58, 36,
+       124, 58, 36, 124, 58, 36, 124, 54, 44, 124, 58, 36, 132, 62, 44,
+       124, 54, 36, 124, 58, 36, 124, 58, 36, 124, 58, 36, 124, 58, 36,
+       124, 54, 36, 124, 58, 36, 124, 58, 36, 124, 58, 44, 124, 58, 36,
+       124, 58, 44, 124, 54, 36, 124, 58, 44, 124, 58, 36, 124, 58, 44,
+       124, 58, 44, 132, 62, 44, 124, 62, 44, 132, 62, 44, 124, 58, 44,
+       124, 58, 44, 124, 58, 44, 132, 62, 44, 124, 62, 44, 132, 62, 44,
+       124, 62, 44, 124, 62, 44, 124, 58, 36, 124, 58, 36, 124, 62, 44,
+       124, 62, 44, 132, 62, 44, 116, 58, 36, 124, 58, 36, 124, 58, 44,
+       124, 62, 44, 124, 62, 44, 124, 62, 44, 124, 62, 44, 124, 58, 36,
+       124, 62, 44, 124, 58, 36, 124, 62, 44, 132, 62, 44, 124, 62, 44,
+       132, 62, 44, 124, 66, 44, 132, 62, 44, 124, 62, 44, 124, 58, 36,
+       124, 58, 36, 124, 62, 44, 132, 62, 44, 124, 62, 44, 124, 62, 44,
+       124, 58, 36, 124, 62, 44, 124, 58, 36, 124, 58, 36, 124, 58, 44,
+       124, 58, 36, 124, 58, 36, 116, 58, 36, 124, 58, 36, 124, 58, 36,
+       124, 58, 36, 124, 58, 36, 124, 58, 36, 124, 58, 36, 124, 58, 36,
+       124, 58, 36, 124, 58, 36, 124, 50, 36, 124, 54, 36, 124, 54, 36,
+       124, 54, 36, 116, 54, 36, 116, 50, 36, 124, 54, 36, 124, 54, 44,
+       124, 54, 36, 116, 54, 36, 116, 54, 36, 108, 46, 28, 124, 58, 44,
+       124, 58, 44, 100, 42, 20, 108, 50, 28
+};
diff --git a/xlockmore-4.14/modes/glx/gears.c b/xlockmore-4.14/modes/glx/gears.c
new file mode 100644 (file)
index 0000000..001cebb
--- /dev/null
@@ -0,0 +1,518 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* gears --- 3D gear wheels */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)gears.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 22-Mar-97: Added support for -mono mode, and monochrome X servers.
+ *              Ed Mackey, emackey@netaxs.com
+ * 13-Mar-97: Memory leak fix by Tom Schmidt <tschmidt@micron.com>
+ * 1996: "written" by Danny Sung <dannys@ucla.edu>
+ *       Based on 3-D gear wheels by Brian Paul which is in the public domain.
+ */
+
+/*-
+ * PURIFY 3.0a on SunOS4 reports an unitialized memory read on each of
+ * the glCallList() functions below when using MesaGL 2.1.  This has
+ * been fixed in MesaGL 2.2 and later releases.
+ */
+
+/*-
+ * due to a Bug/feature in VMS X11/Intrinsic.h has to be placed before xlock.
+ * otherwise caddr_t is not defined correctly
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Gears"
+#define HACK_INIT init_gears
+#define HACK_DRAW draw_gears
+#define gears_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*cycles: 2 \n" \
+ "*wireframe: False \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_cage
+
+ModeSpecOpt gears_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   gears_description =
+{"gears", "init_gears", "draw_gears", "release_gears",
+ "draw_gears", "init_gears", NULL, &gears_opts,
+ 1000, 1, 2, 1, 4, 1.0, "",
+ "Shows GL's gears", 0, NULL};
+
+#endif
+
+typedef struct {
+       GLfloat     view_rotx, view_roty, view_rotz;
+       GLuint      gear1, gear2, gear3;
+       GLfloat     angle;
+       GLXContext *glx_context;
+       Window      window;
+#if 0
+       Window      win;
+#endif
+} gearsstruct;
+
+static gearsstruct *gears = NULL;
+
+/*-
+ * Draw a gear wheel.  You'll probably want to call this function when
+ * building a display list since we do a lot of trig here.
+ *
+ * Input:  inner_radius - radius of hole at center
+ *         outer_radius - radius at center of teeth
+ *         width - width of gear
+ *         teeth - number of teeth
+ *         tooth_depth - depth of tooth
+ *         wire - true for wireframe mode
+ */
+static void
+gear(GLfloat inner_radius, GLfloat outer_radius, GLfloat width,
+     GLint teeth, GLfloat tooth_depth, Bool wire)
+{
+       GLint       i;
+       GLfloat     r0, r1, r2;
+       GLfloat     angle, da;
+       GLfloat     u, v, len;
+
+       r0 = inner_radius;
+       r1 = outer_radius - tooth_depth / 2.0;
+       r2 = outer_radius + tooth_depth / 2.0;
+
+       da = 2.0 * M_PI / teeth / 4.0;
+
+       glShadeModel(GL_FLAT);
+
+       /* This subroutine got kind of messy when I added all the checks
+        * for wireframe mode.  A much cleaner solution that I sometimes
+        * use is to have a variable hold the value GL_LINE_LOOP when
+        * in wireframe mode, or hold the value GL_POLYGON otherwise.
+        * Then I just call glBegin(that_variable), give my polygon
+        * coordinates, and glEnd().  Pretty neat eh?  Too bad I couldn't
+        * integrate that trick here.
+        *                                  --Ed.
+        */
+
+       if (!wire)
+               glNormal3f(0.0, 0.0, 1.0);
+
+       /* draw front face */
+       if (!wire)
+               glBegin(GL_QUAD_STRIP);
+       for (i = 0; i <= teeth; i++) {
+               if (wire)
+                       glBegin(GL_LINES);
+               angle = i * 2.0 * M_PI / teeth;
+               glVertex3f(r0 * cos(angle), r0 * sin(angle), width * 0.5);
+               glVertex3f(r1 * cos(angle), r1 * sin(angle), width * 0.5);
+               if (!wire) {
+                       glVertex3f(r0 * cos(angle), r0 * sin(angle), width * 0.5);
+                       glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), width * 0.5);
+               } else {
+                       glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), width * 0.5);
+                       glVertex3f(r1 * cos(angle + 4 * da), r1 * sin(angle + 4 * da), width * 0.5);
+                       glEnd();
+               }
+       }
+       if (!wire)
+               glEnd();
+
+       /* draw front sides of teeth */
+       if (!wire)
+               glBegin(GL_QUADS);
+       da = 2.0 * M_PI / teeth / 4.0;
+       for (i = 0; i < teeth; i++) {
+               angle = i * 2.0 * M_PI / teeth;
+
+               if (wire)
+                       glBegin(GL_LINE_LOOP);
+               glVertex3f(r1 * cos(angle), r1 * sin(angle), width * 0.5);
+               glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), width * 0.5);
+               glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), width * 0.5);
+               glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), width * 0.5);
+               if (wire)
+                       glEnd();
+       }
+       if (!wire)
+               glEnd();
+
+
+       if (!wire)
+               glNormal3f(0.0, 0.0, -1.0);
+
+       /* draw back face */
+       if (!wire)
+               glBegin(GL_QUAD_STRIP);
+       for (i = 0; i <= teeth; i++) {
+               angle = i * 2.0 * M_PI / teeth;
+               if (wire)
+                       glBegin(GL_LINES);
+               glVertex3f(r1 * cos(angle), r1 * sin(angle), -width * 0.5);
+               glVertex3f(r0 * cos(angle), r0 * sin(angle), -width * 0.5);
+               if (!wire) {
+                       glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), -width * 0.5);
+                       glVertex3f(r0 * cos(angle), r0 * sin(angle), -width * 0.5);
+               } else {
+                       glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), -width * 0.5);
+                       glVertex3f(r1 * cos(angle + 4 * da), r1 * sin(angle + 4 * da), -width * 0.5);
+                       glEnd();
+               }
+       }
+       if (!wire)
+               glEnd();
+
+       /* draw back sides of teeth */
+       if (!wire)
+               glBegin(GL_QUADS);
+       da = 2.0 * M_PI / teeth / 4.0;
+       for (i = 0; i < teeth; i++) {
+               angle = i * 2.0 * M_PI / teeth;
+
+               if (wire)
+                       glBegin(GL_LINE_LOOP);
+               glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), -width * 0.5);
+               glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), -width * 0.5);
+               glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), -width * 0.5);
+               glVertex3f(r1 * cos(angle), r1 * sin(angle), -width * 0.5);
+               if (wire)
+                       glEnd();
+       }
+       if (!wire)
+               glEnd();
+
+
+       /* draw outward faces of teeth */
+       if (!wire)
+               glBegin(GL_QUAD_STRIP);
+       for (i = 0; i < teeth; i++) {
+               angle = i * 2.0 * M_PI / teeth;
+
+               if (wire)
+                       glBegin(GL_LINES);
+               glVertex3f(r1 * cos(angle), r1 * sin(angle), width * 0.5);
+               glVertex3f(r1 * cos(angle), r1 * sin(angle), -width * 0.5);
+               u = r2 * cos(angle + da) - r1 * cos(angle);
+               v = r2 * sin(angle + da) - r1 * sin(angle);
+               len = sqrt(u * u + v * v);
+               u /= len;
+               v /= len;
+               glNormal3f(v, -u, 0.0);
+               glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), width * 0.5);
+               glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), -width * 0.5);
+               glNormal3f(cos(angle), sin(angle), 0.0);
+               glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), width * 0.5);
+               glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), -width * 0.5);
+               u = r1 * cos(angle + 3 * da) - r2 * cos(angle + 2 * da);
+               v = r1 * sin(angle + 3 * da) - r2 * sin(angle + 2 * da);
+               glNormal3f(v, -u, 0.0);
+               glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), width * 0.5);
+               glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), -width * 0.5);
+               glNormal3f(cos(angle), sin(angle), 0.0);
+               if (wire)
+                       glEnd();
+       }
+
+       if (!wire) {
+               glVertex3f(r1 * cos(0), r1 * sin(0), width * 0.5);
+               glVertex3f(r1 * cos(0), r1 * sin(0), -width * 0.5);
+               glEnd();
+       }
+       if (!wire)
+               glShadeModel(GL_SMOOTH);
+
+       /* draw inside radius cylinder */
+       if (!wire)
+               glBegin(GL_QUAD_STRIP);
+       for (i = 0; i <= teeth; i++) {
+               angle = i * 2.0 * M_PI / teeth;
+               if (wire)
+                       glBegin(GL_LINES);
+               glNormal3f(-cos(angle), -sin(angle), 0.0);
+               glVertex3f(r0 * cos(angle), r0 * sin(angle), -width * 0.5);
+               glVertex3f(r0 * cos(angle), r0 * sin(angle), width * 0.5);
+               if (wire) {
+                       glVertex3f(r0 * cos(angle), r0 * sin(angle), -width * 0.5);
+                       glVertex3f(r0 * cos(angle + 4 * da), r0 * sin(angle + 4 * da), -width * 0.5);
+                       glVertex3f(r0 * cos(angle), r0 * sin(angle), width * 0.5);
+                       glVertex3f(r0 * cos(angle + 4 * da), r0 * sin(angle + 4 * da), width * 0.5);
+                       glEnd();
+               }
+       }
+       if (!wire)
+               glEnd();
+
+}
+
+static void
+draw(ModeInfo * mi)
+{
+       gearsstruct *gp = &gears[MI_SCREEN(mi)];
+       int         wire = MI_IS_WIREFRAME(mi);
+
+       if (!wire) {
+               glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+       } else {
+               glClear(GL_COLOR_BUFFER_BIT);
+       }
+
+       glPushMatrix();
+       glRotatef(gp->view_rotx, 1.0, 0.0, 0.0);
+       glRotatef(gp->view_roty, 0.0, 1.0, 0.0);
+       glRotatef(gp->view_rotz, 0.0, 0.0, 1.0);
+
+       glPushMatrix();
+       glTranslatef(-3.0, -2.0, 0.0);
+       glRotatef(gp->angle, 0.0, 0.0, 1.0);
+/* PURIFY 4.0.1 reports an unitialized memory read on the next line when using
+   * MesaGL 2.2 and -mono.  This has been fixed in MesaGL 2.3 and later. */
+       glCallList(gp->gear1);
+       glPopMatrix();
+
+       glPushMatrix();
+       glTranslatef(3.1, -2.0, 0.0);
+       glRotatef(-2.0 * gp->angle - 9.0, 0.0, 0.0, 1.0);
+       glCallList(gp->gear2);
+       glPopMatrix();
+
+       glPushMatrix();
+       glTranslatef(-3.1, 4.2, 0.0);
+       glRotatef(-2.0 * gp->angle - 25.0, 0.0, 0.0, 1.0);
+       glCallList(gp->gear3);
+       glPopMatrix();
+
+       glPopMatrix();
+}
+
+
+
+/* new window size or exposure */
+static void
+reshape(int width, int height)
+{
+       GLfloat     h = (GLfloat) height / (GLfloat) width;
+
+       glViewport(0, 0, (GLint) width, (GLint) height);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       glFrustum(-1.0, 1.0, -h, h, 5.0, 60.0);
+       glMatrixMode(GL_MODELVIEW);
+       glLoadIdentity();
+       glTranslatef(0.0, 0.0, -40.0);
+
+       /* The depth buffer will be cleared, if needed, before the
+        * next frame.  Right now we just want to black the screen.
+        */
+       glClear(GL_COLOR_BUFFER_BIT);
+
+}
+
+
+static void
+pinit(ModeInfo * mi)
+{
+       gearsstruct *gp = &gears[MI_SCREEN(mi)];
+       static GLfloat pos[4] =
+       {5.0, 5.0, 10.0, 1.0};
+       static GLfloat red[4] =
+       {0.8, 0.1, 0.0, 1.0};
+       static GLfloat green[4] =
+       {0.0, 0.8, 0.2, 1.0};
+       static GLfloat blue[4] =
+       {0.2, 0.2, 1.0, 1.0};
+       static GLfloat gray[4] =
+       {0.5, 0.5, 0.5, 1.0};
+       static GLfloat white[4] =
+       {1.0, 1.0, 1.0, 1.0};
+       int         wire = MI_IS_WIREFRAME(mi);
+       int         mono = MI_IS_MONO(mi);
+
+       if (!wire) {
+               glLightfv(GL_LIGHT0, GL_POSITION, pos);
+               glEnable(GL_CULL_FACE);
+               glEnable(GL_LIGHTING);
+               glEnable(GL_LIGHT0);
+               glEnable(GL_DEPTH_TEST);
+       }
+#if 0
+/*-
+ * Messes up on multiscreen Pseudocolor:0 StaticGray(monochrome):1
+ * 2nd time mode is run it is Grayscale on PseudoColor.
+ * The code below forces monochrome on TrueColor.
+ */
+       if (MI_IS_MONO(mi)) {
+               red[0] = red[1] = red[2] = 1.0;
+               green[0] = green[1] = green[2] = 1.0;
+               blue[0] = blue[1] = blue[2] = 1.0;
+       }
+#endif
+
+       /* make the gears */
+       gp->gear1 = glGenLists(1);
+       glNewList(gp->gear1, GL_COMPILE);
+       if (wire) {
+               if (mono)
+                       glColor4fv(white);
+               else
+                       glColor4fv(red);
+       } else {
+               if (mono)
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, gray);
+               else
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, red);
+       }
+       gear(1.0, 4.0, 1.0, 20, 0.7, wire);
+       glEndList();
+
+       gp->gear2 = glGenLists(1);
+       glNewList(gp->gear2, GL_COMPILE);
+       if (wire) {
+               if (mono)
+                       glColor4fv(white);
+               else
+                       glColor4fv(green);
+       } else {
+               if (mono)
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, gray);
+               else
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, green);
+       }
+       gear(0.5, 2.0, 2.0, 10, 0.7, wire);
+       glEndList();
+
+       gp->gear3 = glGenLists(1);
+       glNewList(gp->gear3, GL_COMPILE);
+       if (wire) {
+               if (mono)
+                       glColor4fv(white);
+               else
+                       glColor4fv(blue);
+       } else {
+               if (mono)
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, gray);
+               else
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, blue);
+       }
+       gear(1.3, 2.0, 0.5, 10, 0.7, wire);
+       glEndList();
+       if (!wire)
+               glEnable(GL_NORMALIZE);
+}
+
+void
+init_gears(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+
+       /*Colormap    cmap; */
+       /* Boolean     rgba, doublebuffer, cmap_installed; */
+       gearsstruct *gp;
+
+       if (gears == NULL) {
+               if ((gears = (gearsstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (gearsstruct))) == NULL)
+                       return;
+       }
+       gp = &gears[screen];
+
+       gp->window = MI_WINDOW(mi);
+       gp->view_rotx = NRAND(360);
+       gp->view_roty = NRAND(360);
+       gp->view_rotz = NRAND(360);
+       gp->angle = NRAND(360);
+
+       if ((gp->glx_context = init_GL(mi)) != NULL) {
+               reshape(MI_WIDTH(mi), MI_HEIGHT(mi));
+               pinit(mi);
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_gears(ModeInfo * mi)
+{
+       gearsstruct *gp = &gears[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         angle_incr = MI_CYCLES(mi) ? MI_CYCLES(mi) : 2;
+       int         rot_incr = MI_COUNT(mi) ? MI_COUNT(mi) : 1;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!gp->glx_context)
+               return;
+
+       glDrawBuffer(GL_BACK);
+
+       glXMakeCurrent(display, window, *(gp->glx_context));
+       draw(mi);
+
+       /* let's do something so we don't get bored */
+       gp->angle = (int) (gp->angle + angle_incr) % 360;
+       gp->view_rotx = (int) (gp->view_rotx + rot_incr) % 360;
+       gp->view_roty = (int) (gp->view_roty + rot_incr) % 360;
+       gp->view_rotz = (int) (gp->view_rotz + rot_incr) % 360;
+
+       glFinish();
+       glXSwapBuffers(display, window);
+}
+
+void
+release_gears(ModeInfo * mi)
+{
+       if (gears != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       gearsstruct *gp = &gears[screen];
+
+                       if (gp->glx_context) {
+                               /* Display lists MUST be freed while their glXContext is current. */
+                               glXMakeCurrent(MI_DISPLAY(mi), gp->window, *(gp->glx_context));
+
+                               if (glIsList(gp->gear1))
+                                       glDeleteLists(gp->gear1, 1);
+                               if (glIsList(gp->gear2))
+                                       glDeleteLists(gp->gear2, 1);
+                               if (glIsList(gp->gear3))
+                                       glDeleteLists(gp->gear3, 1);
+
+                       }
+               }
+               (void) free((void *) gears);
+               gears = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+
+/*********************************************************/
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/i_evert.h b/xlockmore-4.14/modes/glx/i_evert.h
new file mode 100644 (file)
index 0000000..2490ea1
--- /dev/null
@@ -0,0 +1,8 @@
+#include <GL/gl.h>
+#include <GL/glx.h>
+
+extern double scale;
+extern double width;
+extern int sphere;
+extern int torscene;
+extern double corrstart, pushstart, twiststart, untwiststart, uncorrstart;
diff --git a/xlockmore-4.14/modes/glx/i_figureeight.cc b/xlockmore-4.14/modes/glx/i_figureeight.cc
new file mode 100644 (file)
index 0000000..e9e6c47
--- /dev/null
@@ -0,0 +1,34 @@
+#include "i_figureeight.h"
+
+extern int n_strips;
+
+TwoJetVec FigureEight(
+  TwoJetVec w, TwoJetVec h, TwoJetVec bend, TwoJet form, TwoJet v
+) {
+  TwoJet height;
+  v %= 1;
+  height = (Cos (v*2) + -1) * (-1);
+  if (v > 0.25 && v < 0.75)
+    height = height*-1 + 4;
+  height = height*0.6;
+  h = h + bend*(height*height*(1/64.));
+  return 
+    w*Sin (v*2) + (h) * (Interpolate((Cos (v) + -1) * (-2), height, form))
+  ;
+}
+  
+TwoJetVec AddFigureEight(ThreeJetVec p, ThreeJet u, TwoJet v, ThreeJet form, ThreeJet scale)
+{
+  ThreeJet size = form*scale;
+  form = form*2 + form*form*-1;
+  TwoJetVec dv = AnnihilateVec(D(p, 1), 1);
+  p = AnnihilateVec(p, 1);
+  TwoJetVec du = Normalize(D(p, 0));
+  TwoJetVec h = Normalize(Cross(du, dv))*TwoJet(size);
+  TwoJetVec w = Normalize(Cross(h, du))*(TwoJet(size)*1.1);
+  return RotateZ(
+    TwoJetVec(p) +
+      FigureEight(w, h, du*D(size, 0)*(D(u, 0)^(-1)), form, v),
+    v*(1./n_strips)
+  );
+}
diff --git a/xlockmore-4.14/modes/glx/i_figureeight.h b/xlockmore-4.14/modes/glx/i_figureeight.h
new file mode 100644 (file)
index 0000000..6079e77
--- /dev/null
@@ -0,0 +1,14 @@
+#ifndef __FIGUREEIGHT
+#define __FIGUREEIGHT
+#include "i_threejetvec.h"
+#include "i_twojetvec.h"
+
+#define N_STRIPS 8
+
+TwoJetVec FigureEight(
+  TwoJetVec w, TwoJetVec h, TwoJetVec bend,
+  TwoJet form, TwoJet v
+);
+TwoJetVec AddFigureEight(ThreeJetVec p, ThreeJet u, TwoJet v, ThreeJet form, ThreeJet scale);
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/i_linkage.cc b/xlockmore-4.14/modes/glx/i_linkage.cc
new file mode 100644 (file)
index 0000000..9bff465
--- /dev/null
@@ -0,0 +1,115 @@
+#include <X11/Intrinsic.h>
+#include "xlock.h"
+
+#include "i_linkage.h"
+#include "i_threejetvec.h"
+#include "i_figureeight.h"
+#include "i_spline.h"
+#include "i_sphere.h"
+
+char *parse_parts(char *parts);
+#define        PART_POS 0x1
+#define        PART_NEG 0x2
+
+double scale = M_PI;
+int scene = 0;
+int bezier = 0;
+char *parts = NULL;
+int n_strips = N_STRIPS;
+
+void
+invert_draw(spherestruct * gp)
+{
+  double umin, vmin, umax, vmax;
+  double du, dv;
+  double time = 0.0;
+  double corrstart, pushstart, twiststart, unpushstart, uncorrstart;
+  double bendtime;
+  int binary = 0;
+  int j, k;
+
+  glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+  glPushMatrix();
+  glRotatef(gp->view_rotx, 1.0, 0.0, 0.0);
+  glRotatef(gp->view_roty, 0.0, 1.0, 0.0);
+  glRotatef(gp->view_rotz, 0.0, 0.0, 1.0);
+  
+  /* default parameters */
+
+  corrstart = 0;
+  pushstart = .1;
+  twiststart = .23;
+  unpushstart = .6;
+  uncorrstart = .93;
+
+  vmin = 0.0;
+  umin = 0.0;
+  vmax = 1.0;
+  umax = 1.0;
+  du = dv = 1./12.;
+
+  /* Simple inversion fits our needs perfectly... */
+
+  du = 0.04;
+  dv = 0.04;
+  umax = 2.0;
+  parts = "+0+1+2+3+4+5+6+7";
+  time = (cos((M_PI*gp->time)/gp->numsteps)+1.0)/2.0;
+  binary = 0;
+  
+  /* draw it here */
+  
+  if (gp->partlist == NULL)
+    gp->partlist = parse_parts(parts);
+
+  /* Need to compute */
+
+  if (gp->construction) {
+    glNewList(gp->frames+gp->time, GL_COMPILE);
+
+    if (time >= uncorrstart && uncorrstart >= 0) 
+      printScene(UnCorrugate, umin, umax, du, vmin, vmax, dv, 
+                (time - uncorrstart) / (1.0 - uncorrstart), binary);
+    else if (time >= unpushstart && unpushstart >= 0) 
+      printScene(UnPush, umin, umax, du, vmin, vmax, dv,
+                (time - unpushstart) / 
+                (((uncorrstart < 0) ? 1.0 : uncorrstart) - unpushstart), binary);
+    else if (time >= twiststart && twiststart >= 0) 
+      printScene(Twist, umin, umax, du, vmin, vmax, dv, 
+                (time - twiststart) / 
+                (((unpushstart < 0) ? 1.0 : unpushstart) - twiststart), binary);
+    else if (time >= pushstart && pushstart >= 0) 
+      printScene(PushThrough, umin, umax, du, vmin, vmax, dv,
+                (time - pushstart) / 
+                (((twiststart < 0) ? 1.0 : twiststart) - pushstart), binary);
+    else if (time >= corrstart && corrstart >= 0) 
+      printScene(Corrugate, umin, umax, du, vmin, vmax, dv,
+                (time - corrstart) / 
+                (((pushstart < 0) ? 1.0 : pushstart) - corrstart), binary);
+    glEndList();
+  }
+
+  for(j = -1; j <= 1; j += 2) {
+    for(k = 0; k < n_strips; k++) {
+      if(gp->partlist[k] & (j<0 ? PART_NEG : PART_POS)) {
+       double t = 2*M_PI * (j < 0 ? n_strips-1-k : k) / n_strips;
+       double s = sin(t), c = cos(t);
+       
+       GLdouble m[16];
+       m[0] = j*c; m[4] = -s; m[8] =  0; m[12] = 0;
+       m[1] = j*s; m[5] =  c; m[9] =  0, m[13] = 0;
+       m[2] =   0; m[6] =  0; m[10] = j; m[14] = 0;
+       m[3] =   0; m[7] =  0; m[11] = 0; m[15] = 1;
+       
+       glPushMatrix();
+       glMultMatrixd(m);
+       glCallList(gp->frames+gp->time);
+       glPopMatrix();
+      }
+    }
+  }
+
+  glPopMatrix();
+}
+
diff --git a/xlockmore-4.14/modes/glx/i_linkage.h b/xlockmore-4.14/modes/glx/i_linkage.h
new file mode 100644 (file)
index 0000000..788bcb3
--- /dev/null
@@ -0,0 +1,22 @@
+#include <GL/gl.h>
+#include <GL/glx.h>
+
+typedef struct {
+  GLfloat     view_rotx, view_roty, view_rotz;
+  GLXContext *glx_context;
+  GLuint      frames;
+  int         numsteps;
+  int         construction;
+  int         time;
+  char       *partlist;
+  int         forwards;
+} spherestruct;
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+  void invert_draw(spherestruct *gp);
+#ifdef __cplusplus
+}
+#endif
diff --git a/xlockmore-4.14/modes/glx/i_sphere.cc b/xlockmore-4.14/modes/glx/i_sphere.cc
new file mode 100644 (file)
index 0000000..09d24e9
--- /dev/null
@@ -0,0 +1,155 @@
+#include "i_threejetvec.h"
+#include "i_figureeight.h"
+#include "i_spline.h"
+#include "i_sphere.h"
+
+ThreeJetVec Arc(ThreeJet u, ThreeJet v, double xsize, double ysize, double zsize) {
+  ThreeJetVec result;
+  u = u*0.25;
+  result.x = Sin (u) * Sin (v) * xsize;
+  result.y = Sin (u) * Cos (v) * ysize;
+  result.z = Cos (u) * zsize;
+  return result;
+}
+
+ThreeJetVec Straight(ThreeJet u, ThreeJet v, double xsize, double ysize, double zsize) {
+  ThreeJetVec result;
+  u = u*0.25;
+#if 0
+  u = (u) * (-0.15915494) + 1; /* 1/2pi */
+#endif
+  result.x = Sin (v) * xsize;
+  result.y = Cos (v) * ysize;
+  result.z = Cos (u) * zsize;
+  return result;
+}
+
+ThreeJet Param1(ThreeJet x) {
+  double offset = 0;
+  x %= 4;
+  if (x > 2) { x = x+(-2); offset = 2; }
+  if (x <= 1) return x*2 + (x^2)*(-1) + offset;
+  else return (x^2) + x*(-2) + (2 + offset);
+}
+
+ThreeJet Param2(ThreeJet x) {
+  double offset = 0;
+  x %= 4;
+  if (x > 2) { x = x+(-2); offset = 2; }
+  if (x <= 1) return (x^2) + offset;
+  else return (x^2)*(-1) + x*4 + (-2 + offset);
+}
+
+static inline ThreeJet TInterp(double x) {
+  return ThreeJet(x,0,0);
+}
+
+ThreeJet UInterp(ThreeJet x) {
+  x %= 2;
+  if (x > 1)
+    x = x*(-1) + 2;
+  return (x^2)*3 + (x^3) * (-2);
+}
+
+#define FFPOW 3
+ThreeJet FFInterp(ThreeJet x) {
+  x %= 2;
+  if (x > 1)
+    x = x*(-1) + 2;
+  x = x*1.06 + -0.05;
+  if (x < 0) return ThreeJet(0, 0, 0);
+  else if (x > 1) return ThreeJet(0, 0, 0) + 1;
+  else return (x ^ (FFPOW-1)) * (FFPOW) + (x^FFPOW) * (-FFPOW+1);
+}
+
+#define FSPOW 3
+ThreeJet FSInterp(ThreeJet x) {
+  x %= 2;
+  if (x > 1)
+    x = x*(-1) + 2;
+  return ((x ^ (FSPOW-1)) * (FSPOW) + (x^FSPOW) * (-FSPOW+1)) * (-0.2);
+}
+
+ThreeJetVec Stage0(ThreeJet u, ThreeJet v) {
+  return Straight(u, v, 1, 1, 1);
+}
+
+ThreeJetVec Stage1(ThreeJet u, ThreeJet v) {
+  return Arc(u, v, 1, 1, 1);
+}
+
+ThreeJetVec Stage2(ThreeJet u, ThreeJet v) {
+  return InterpolateVec(
+    Arc(Param1(u), v, 0.9, 0.9, -1),
+    Arc(Param2(u), v, 1, 1, 0.5), 
+    UInterp(u));
+}
+
+ThreeJetVec Stage3(ThreeJet u, ThreeJet v) {
+  return InterpolateVec(
+    Arc(Param1(u), v,-0.9,-0.9,-1), 
+    Arc(Param2(u), v,-1, 1,-0.5),
+    UInterp(u));
+}
+
+ThreeJetVec Stage4(ThreeJet u, ThreeJet v) {
+  return Arc(u, v, -1,-1, -1);
+}
+
+ThreeJetVec Scene01(ThreeJet u, ThreeJet v, double t) {
+  return InterpolateVec(Stage0(u,v), Stage1(u,v), TInterp(t));
+}
+
+ThreeJetVec Scene12(ThreeJet u, ThreeJet v, double t) {
+  return InterpolateVec(Stage1(u,v), Stage2(u,v), TInterp(t));
+}
+
+ThreeJetVec Scene23(ThreeJet u, ThreeJet v, double t) {
+  t = TInterp(t) * 0.5;
+  double tt = (u <= 1) ? t : -t;
+  return InterpolateVec(
+    RotateZ(Arc(Param1(u), v, 0.9, 0.9,-1), ThreeJet(tt,0,0)),
+    RotateY(Arc(Param2(u), v, 1, 1, 0.5), ThreeJet(t,0,0)),
+    UInterp(u)
+  );
+}
+
+ThreeJetVec Scene34(ThreeJet u, ThreeJet v, double t) {
+  return InterpolateVec(Stage3(u,v), Stage4(u,v), TInterp(t));
+}
+
+TwoJetVec BendIn(ThreeJet u, ThreeJet v, double t) {
+  t = TInterp(t);
+  return AddFigureEight(
+    Scene01(u, ThreeJet(0, 0, 1), t),
+    u, v, ThreeJet(0, 0, 0), FSInterp(u));
+}
+TwoJetVec Corrugate(ThreeJet u, ThreeJet v, double t) {
+  t = TInterp(t);
+  return AddFigureEight(
+    Stage1(u, ThreeJet(0, 0, 1)),
+    u, v, FFInterp(u) * ThreeJet(t,0,0), FSInterp(u));
+}
+TwoJetVec PushThrough(ThreeJet u, ThreeJet v, double t) {
+  return AddFigureEight(
+    Scene12(u,ThreeJet(0, 0, 1),t),
+    u, v, FFInterp(u), FSInterp(u));
+}
+TwoJetVec Twist(ThreeJet u, ThreeJet v, double t) {
+  return AddFigureEight(
+    Scene23(u,ThreeJet(0, 0, 1),t),
+    u, v, FFInterp(u), FSInterp(u));
+}
+
+TwoJetVec UnPush(ThreeJet u, ThreeJet v, double t) {
+  return AddFigureEight(
+    Scene34(u,ThreeJet(0, 0, 1),t),
+    u, v, FFInterp(u), FSInterp(u));
+}
+
+TwoJetVec UnCorrugate(ThreeJet u, ThreeJet v, double t) {
+  t = TInterp((t) * (-1) + 1);
+  return AddFigureEight(
+    Stage4(u,ThreeJet(0, 0, 1)),
+    u, v, FFInterp(u) * ThreeJet(t,0,0), FSInterp(u));
+}
diff --git a/xlockmore-4.14/modes/glx/i_sphere.h b/xlockmore-4.14/modes/glx/i_sphere.h
new file mode 100644 (file)
index 0000000..804076f
--- /dev/null
@@ -0,0 +1,8 @@
+#include "i_twojetvec.h"
+#include "i_threejetvec.h"
+TwoJetVec Corrugate(ThreeJet u, ThreeJet v, double t);
+TwoJetVec PushThrough(ThreeJet u, ThreeJet v, double t);
+TwoJetVec Twist(ThreeJet u, ThreeJet v, double t);
+TwoJetVec UnPush(ThreeJet u, ThreeJet v, double t);
+TwoJetVec UnCorrugate(ThreeJet u, ThreeJet v, double t);
+TwoJetVec BendIn(ThreeJet u, ThreeJet v, double t);
diff --git a/xlockmore-4.14/modes/glx/i_spline.cc b/xlockmore-4.14/modes/glx/i_spline.cc
new file mode 100644 (file)
index 0000000..dcc6203
--- /dev/null
@@ -0,0 +1,308 @@
+#define XLOCK 1
+#ifdef XLOCK
+#include "xlock.h"
+#endif
+
+#include "i_spline.h"
+#include "i_evert.h"
+extern "C" {
+#include <math.h>
+}
+
+extern int bezier;
+extern char *parts;
+extern int n_strips;
+
+void print_point (FILE *fp, TwoJetVec p, double ps, double pus, double pvs, double puvs, int binary)
+{
+  if(bezier) {
+    float xyz[3];
+    xyz[0] = double(p.x)*ps + p.x.df_du()*pus/3. + p.x.df_dv()*pvs/3.
+             + p.x.d2f_dudv()*puvs/9.;
+    xyz[1] = double(p.y)*ps + p.y.df_du()*pus/3. + p.y.df_dv()*pvs/3.
+             + p.y.d2f_dudv()*puvs/9.;
+    xyz[2] = double(p.z)*ps + p.z.df_du()*pus/3. + p.z.df_dv()*pvs/3.
+             + p.z.d2f_dudv()*puvs/9.;
+    if (binary) {
+      fwrite(&xyz, sizeof(float), 3, fp);
+    } else {
+      fprintf(fp, "%g %g %g\n", xyz[0], xyz[1], xyz[2]);
+    }
+  }
+  else{
+    double x= double(p.x)*ps ;
+    double y= double(p.y)*ps ;
+    double z= double(p.z)*ps ;
+    double nx= p.y.df_du()*p.z.df_dv()-p.z.df_du()*p.y.df_dv();
+    double ny= p.z.df_du()*p.x.df_dv()-p.x.df_du()*p.z.df_dv();
+    double nz= p.x.df_du()*p.y.df_dv()-p.y.df_du()*p.x.df_dv();
+    double s = nx*nx + ny*ny + nz*nz;
+    if(s > 0) s = sqrt(1/s);
+    fprintf(fp, "%f %f %f    %f %f %f\n", x, y, z, nx*s, ny*s, nz*s);
+  }
+}
+
+void printMesh(FILE *fp, TwoJetVec p, int binary)
+{
+    double x= double(p.x) ;
+    double y= double(p.y) ;
+    double z= double(p.z) ;
+    double nx= p.y.df_du()*p.z.df_dv()-p.z.df_du()*p.y.df_dv();
+    double ny= p.z.df_du()*p.x.df_dv()-p.x.df_du()*p.z.df_dv();
+    double nz= p.x.df_du()*p.y.df_dv()-p.y.df_du()*p.x.df_dv();
+    double s = nx*nx + ny*ny + nz*nz;
+    if(s > 0) s = sqrt(1/s);
+#ifdef XLOCK
+    glNormal3d(nx*s, ny*s, nz*s);
+    glVertex3d(x, y, z);
+#else    
+    fprintf(fp, "%f %f %f    %f %f %f\n", x, y, z, nx*s, ny*s, nz*s);
+#endif
+}
+
+void printSpline(FILE *fp, TwoJetVec v00, TwoJetVec v01,
+                          TwoJetVec v10, TwoJetVec v11,
+                          double us, double vs,
+                          double s0, double s1, double t0, double t1, int binary) {
+    if (bezier) {
+    print_point(fp, v00, 1, 0, 0, 0, binary);
+    print_point(fp, v00, 1, us, 0, 0, binary);
+    print_point(fp, v10, 1,-us, 0, 0, binary);
+    print_point(fp, v10, 1, 0, 0, 0, binary);
+  
+    print_point(fp, v00, 1, 0, vs, 0, binary);
+    print_point(fp, v00, 1, us, vs, us*vs, binary);
+    print_point(fp, v10, 1,-us, vs,-us*vs, binary);
+    print_point(fp, v10, 1, 0, vs, 0, binary);
+  
+    print_point(fp, v01, 1, 0,-vs, 0, binary);
+    print_point(fp, v01, 1, us,-vs,-us*vs, binary);
+    print_point(fp, v11, 1,-us,-vs, us*vs, binary);
+    print_point(fp, v11, 1, 0,-vs, 0, binary);
+  
+    print_point(fp, v01, 1, 0, 0, 0, binary);
+    print_point(fp, v01, 1, us, 0, 0, binary);
+    print_point(fp, v11, 1,-us, 0, 0, binary);
+    print_point(fp, v11, 1, 0, 0, 0, binary);
+  
+    if (binary) {
+      float sts[8] = {s0,t0, s1,t0, s0,t1, s1,t1};
+      fwrite(&sts, sizeof(float), 8, fp);
+    } else {
+      fprintf(fp, "%g %g  %g %g  %g %g  %g %g\n\n",
+       s0,t0,  s1,t0,  s0,t1, s1,t1);
+    }
+  }
+  else {
+    print_point(fp, v00, 1, us, vs, us*vs, binary);
+    print_point(fp, v10, 1, us, vs, us*vs, binary);
+    print_point(fp, v11, 1, us, vs, us*vs, binary);
+    print_point(fp, v01, 1, us, vs, us*vs, binary);
+    if(!binary)
+       fputc('\n', fp);
+  }
+}
+
+static inline double sqr(double x) {
+  return x*x;
+}
+static inline double calcSpeedV(TwoJetVec v) {
+  return sqrt(sqr(v.x.df_dv()) + sqr(v.y.df_dv()) + sqr(v.z.df_dv()));
+}
+static inline double calcSpeedU(TwoJetVec v) {
+  return sqrt(sqr(v.x.df_du()) + sqr(v.y.df_du()) + sqr(v.z.df_du()));
+}
+
+#define        PART_POS 0x1
+#define        PART_NEG 0x2
+
+char *parse_parts(char *parts)
+{
+    /* Construct matrices to replicate standard unit (u=0..1, v=0..1) into
+     * complete sphere.
+     */
+    char *partlist = (char *)calloc(n_strips, sizeof(char));
+    char *cp, *ncp, sign;
+    int bits, j;
+
+    for(cp = parts; *cp; ) {
+       while((sign = *cp++) == ' ' || sign == ',')
+           ;
+       if(sign == '+')
+           bits = PART_POS;
+       else if(sign == '-')
+           bits = PART_NEG;
+       else {
+           bits = PART_POS|PART_NEG;
+           cp--;
+       }
+       if(*cp == '*') {
+           for(j = 0; j < n_strips; j++)
+               partlist[j] |= bits;
+           cp++;
+       } else {
+           j = strtol(cp, &ncp, 0);
+           if(cp == ncp) {
+               fprintf(stderr,
+"evert -parts: expected string with alternating signs and strip numbers\n");
+               return NULL;
+           }
+           if(j < 0 || j >= n_strips) {
+               fprintf(stderr,
+"evert -parts: bad strip number %d; must be in range 0..%d\n", j, n_strips-1);
+               return NULL;
+           }
+           partlist[j] |= bits;
+           cp = ncp;
+       }
+    }
+    return partlist;
+}
+
+void printScene(
+               SurfaceTimeFunction *func,
+               double umin, double umax, double adu,
+               double vmin, double vmax, double adv,
+               double t, int binary
+               ) 
+     
+{
+  static TwoJetVec **values;
+  int j, k;
+  int jmax = (int) (fabs(umax-umin)/adu+.5);
+  int kmax = (int) (fabs(vmax-vmin)/adv+.5);
+  double u, v, du, dv;
+  FILE *fp = stdout;
+
+  if(jmax == 0) jmax = 1;
+  du = (umax-umin) / jmax;
+  if(kmax == 0) kmax = 1;
+  dv = (vmax-vmin) / kmax;
+  values = (TwoJetVec **) calloc(jmax+1, sizeof(TwoJetVec *));
+  double *speedv = (double *) calloc(jmax+1, sizeof(double));
+  double **speedu = (double **) calloc(jmax+1, sizeof(double *));
+  for (j = 0; j <= jmax; j++) {
+    u = umin + j*du;
+    values[j] = (TwoJetVec *) calloc(kmax+1, sizeof(TwoJetVec));
+    speedu[j] = (double *) calloc(kmax+1, sizeof(double));
+    speedv[j] = calcSpeedV((*func)(ThreeJet(u, 1, 0), ThreeJet(0, 0, 1), t));
+    if(speedv[j] == 0) {
+      /* Perturb a bit, hoping to avoid degeneracy */
+      u += (u<1) ? 1e-9 : -1e-9;
+      speedv[j] = calcSpeedV((*func)(ThreeJet(u, 1, 0), ThreeJet(0, 0, 1), t));
+    }
+    for (k = 0; k <= kmax; k++) {
+      v = vmin + k*dv;
+      values[j][k] = (*func)(
+       ThreeJet(u, 1, 0),
+       ThreeJet(v, 0, 1),
+       t
+      );
+      speedu[j][k] = calcSpeedU(values[j][k]);
+    }
+  }
+/*
+  fprintf(fp, "Declare \"speeds\" \"varying float\"\n");
+  fprintf(fp, "Declare \"speedt\" \"varying float\"\n");
+*/
+#ifndef XLOCK
+  if(parts != NULL) {
+    /* Construct matrices to replicate standard unit (u=0..1, v=0..1) into
+     * complete sphere.
+     */
+    char *partlist = parse_parts(parts);
+
+    if(partlist == NULL)
+       return;
+
+    fprintf(fp, "{ INST transforms { TLIST\n");
+    for(j = -1; j <= 1; j += 2) {
+       for(k = 0; k < n_strips; k++) {
+         if(partlist[k] & (j<0 ? PART_NEG : PART_POS)) {
+           double t = 2*M_PI * (j < 0 ? n_strips-1-k : k) / n_strips;
+           double s = sin(t), c = cos(t);
+
+           fprintf(fp, "# %c%d of %d\n", j<0 ? '-' : '+', k, n_strips);
+           fprintf(fp, "\t%10f %10f %10f %10f\n", j*c, -s,          0., 0.);
+           fprintf(fp, "\t%10f %10f %10f %10f\n", j*s,  c,          0., 0.);
+           fprintf(fp, "\t%10f %10f %10f %10f\n", 0.,   0., (double)j, 0.);
+           fprintf(fp, "\t%10f %10f %10f %10f\n", 0.,   0.,         0., 1.);
+         }
+       }
+    }
+    fprintf(fp, "}\ngeom ");
+  }
+#endif
+
+  if(bezier) {
+    fprintf(fp, "{ STBBP%s\n", binary ? " BINARY" : "");
+    for (j = 0; j < jmax; j++) {
+      u = umin + j*du;
+      for (k = 0; k < kmax; k++) {
+       v = vmin + k*dv;
+       printSpline(fp, values[j][k], values[j][k+1],
+                 values[j+1][k], values[j+1][k+1],
+                 du, dv,
+                 umin+j*du, umin+(j+1)*du,  vmin+k*dv, vmin+(k+1)*dv, binary);
+      }
+    }
+  } 
+  else {
+    int nu = kmax+1, nv = jmax+1;
+#ifndef XLOCK
+    fprintf(fp, "{ NMESH%s\n", binary ? " BINARY" : "");
+
+    if(binary) {
+       fwrite(&nu, sizeof(int), 1, stdout);
+       fwrite(&nv, sizeof(int), 1, stdout);
+    } else {
+       fprintf(fp, "%d %d\n", nu, nv);
+    }
+#endif
+
+#ifdef XLOCK
+    for(j = 1; j <= jmax; j++) {
+        glBegin(GL_QUAD_STRIP);
+        for(k = 0; k <= kmax; k++) {
+           printMesh(fp, values[j-1][k], binary);
+           printMesh(fp, values[j][k], binary);
+       }
+       glEnd();
+#else
+    for(j = 0; j <= jmax; j++) {
+        for(k = 0; k <= kmax; k++)
+           printMesh(fp, values[j][k], binary);
+
+       if(!binary)
+           fputc('\n', fp);
+#endif
+
+    }
+  }
+
+#ifndef XLOCK
+  if(parts)
+    fprintf(fp, " }\n");
+  fprintf(fp, "}\n");
+#endif
+
+  for (j = 0; j <= jmax; j++) {
+    if (values[j] != NULL) {
+      (void) free((void *) values[j]);
+      values[j] = NULL;
+    }
+    if (speedu[j] != NULL) {
+      (void) free((void *) speedu[j]);
+      speedu[j] = NULL;
+    }
+  }
+  (void) free((void *) values);
+  (void) free((void *) speedu);
+  (void) free((void *) speedv);
+}
+
+void impossible(char *msg) {
+  fprintf(stderr, "%s\n", msg);
+  exit(1);
+}
+
diff --git a/xlockmore-4.14/modes/glx/i_spline.h b/xlockmore-4.14/modes/glx/i_spline.h
new file mode 100644 (file)
index 0000000..c91ab8c
--- /dev/null
@@ -0,0 +1,17 @@
+#ifndef __SPLINE
+#define __SPLINE
+#include "i_threejetvec.h"
+#include "i_twojetvec.h"
+
+typedef TwoJetVec SurfaceTimeFunction(ThreeJet u, ThreeJet v, double t);
+
+void print_point (FILE *fp, TwoJetVec p, double ps, double pus, double pvs, double puvs);
+void printSpline(FILE *fp, TwoJetVec v00, TwoJetVec v01, TwoJetVec v10, TwoJetVec v11, double us, double vs, double s0,double s1,double t0,double t1);
+void printScene(
+  SurfaceTimeFunction *func,
+  double umin, double umax, double du,
+  double vmin, double vmax, double dv,
+  double t, int binary
+);        
+void impossible(char *msg);
+#endif
diff --git a/xlockmore-4.14/modes/glx/i_threejet.cc b/xlockmore-4.14/modes/glx/i_threejet.cc
new file mode 100644 (file)
index 0000000..586ca40
--- /dev/null
@@ -0,0 +1,140 @@
+#include "i_threejet.h"
+
+ThreeJet operator+(const ThreeJet x, const ThreeJet y) {
+  ThreeJet result;
+  result.f = x.f + y.f;
+  result.fu = x.fu + y.fu;
+  result.fv = x.fv + y.fv;
+  result.fuu = x.fuu + y.fuu;
+  result.fuv = x.fuv + y.fuv;
+  result.fvv = x.fvv + y.fvv;
+  result.fuuv = x.fuuv + y.fuuv;
+  result.fuvv = x.fuvv + y.fuvv;
+  return result;
+}
+
+ThreeJet operator*(const ThreeJet x, const ThreeJet y) {
+  ThreeJet result;
+  result.f = x.f*y.f;
+  result.fu = x.f*y.fu + x.fu*y.f;
+  result.fv = x.f*y.fv + x.fv*y.f;
+  result.fuu = x.f*y.fuu + 2*x.fu*y.fu + x.fuu*y.f;
+  result.fuv = x.f*y.fuv + x.fu*y.fv + x.fv*y.fu + x.fuv*y.f;
+  result.fvv = x.f*y.fvv + 2*x.fv*y.fv + x.fvv*y.f;
+  result.fuuv = x.f*y.fuuv + 2*x.fu*y.fuv + x.fv*y.fuu
+           + 2*x.fuv*y.fu + x.fuu*y.fv + x.fuuv*y.f;
+  result.fuvv = x.f*y.fuvv + 2*x.fv*y.fuv + x.fu*y.fvv
+           + 2*x.fuv*y.fv + x.fvv*y.fu + x.fuvv*y.f;
+  return result;
+}
+
+ThreeJet operator+(const ThreeJet x, double d) {
+  ThreeJet result;
+  result = x;
+  result.f += d;
+  return result;
+}
+
+ThreeJet operator*(const ThreeJet x, double d) {
+  ThreeJet result;
+  result.f = d*x.f;
+  result.fu = d*x.fu;
+  result.fv = d*x.fv;
+  result.fuu = d*x.fuu;
+  result.fuv = d*x.fuv;
+  result.fvv = d*x.fvv;
+  result.fuuv = d*x.fuuv;
+  result.fuvv = d*x.fuvv;
+  return result;
+}
+
+ThreeJet Sin(const ThreeJet x) {
+  ThreeJet result;
+  ThreeJet t = x*double(2*M_PI);
+  double s = sin(t.f);
+  double c = cos(t.f);
+  result.f = s;
+  result.fu = c*t.fu;
+  result.fv = c*t.fv;
+  result.fuu = c*t.fuu - s*t.fu*t.fu;
+  result.fuv = c*t.fuv - s*t.fu*t.fv;
+  result.fvv = c*t.fvv - s*t.fv*t.fv;
+  result.fuuv = c*t.fuuv - s*(2*t.fu*t.fuv + t.fv*t.fuu) - c*t.fu*t.fu*t.fv;
+  result.fuvv = c*t.fuvv - s*(2*t.fv*t.fuv + t.fu*t.fvv) - c*t.fu*t.fv*t.fv;
+  return result;
+}
+
+ThreeJet Cos(const ThreeJet x) {
+  ThreeJet result;
+  ThreeJet t = x*double(2*M_PI);
+  double s = cos(t.f);
+  double c = -sin(t.f);
+  result.f = s;
+  result.fu = c*t.fu;
+  result.fv = c*t.fv;
+  result.fuu = c*t.fuu - s*t.fu*t.fu;
+  result.fuv = c*t.fuv - s*t.fu*t.fv;
+  result.fvv = c*t.fvv - s*t.fv*t.fv;
+  result.fuuv = c*t.fuuv - s*(2*t.fu*t.fuv + t.fv*t.fuu) - c*t.fu*t.fu*t.fv;
+  result.fuvv = c*t.fuvv - s*(2*t.fv*t.fuv + t.fu*t.fvv) - c*t.fu*t.fv*t.fv;
+  return result;
+}
+
+ThreeJet operator^(const ThreeJet x, double n) {
+  double x0 = pow(x.f, n);
+  double x1 = (x.f == 0) ? 0 : n * x0/x.f;
+  double x2 = (x.f == 0) ? 0 : (n-1) * x1/x.f;
+  double x3 = (x.f == 0) ? 0 : (n-2) * x2/x.f;
+  ThreeJet result;
+  result.f = x0;
+  result.fu = x1*x.fu;
+  result.fv = x1*x.fv;
+  result.fuu = x1*x.fuu + x2*x.fu*x.fu;
+  result.fuv = x1*x.fuv + x2*x.fu*x.fv;
+  result.fvv = x1*x.fvv + x2*x.fv*x.fv;
+  result.fuuv = x1*x.fuuv + x2*(2*x.fu*x.fuv + x.fv*x.fuu) + x3*x.fu*x.fu*x.fv;
+  result.fuvv = x1*x.fuvv + x2*(2*x.fv*x.fuv + x.fu*x.fvv) + x3*x.fu*x.fv*x.fv;
+  return result;
+}
+
+TwoJet D(const ThreeJet x, int index) {
+  TwoJet result;
+  if (index == 0) {
+    result.f = x.fu;
+    result.fu = x.fuu;
+    result.fv = x.fuv;
+    result.fuv = x.fuuv;
+  } else if (index == 1) {
+    result.f = x.fv;
+    result.fu = x.fuv;
+    result.fv = x.fvv;
+    result.fuv = x.fuvv;
+  } else {
+    result.f = result.fu = result.fv =
+    result.fuv = 0;
+  }
+  return result;
+}
+
+ThreeJet Annihilate(const ThreeJet x, int index) {
+  ThreeJet result = ThreeJet(x.f,0,0);
+  if (index == 0) {
+    result.fv = x.fv;
+    result.fvv = x.fvv;
+  } else if (index == 1) {
+    result.fu = x.fu;
+    result.fuu = x.fuu;
+  }
+  return result;
+}
+
+ThreeJet Interpolate(const ThreeJet v1, const ThreeJet v2, const ThreeJet weight) {
+  return (v1) * ((weight) * (-1) + 1) + v2*weight;
+}
+
+void printJet(const ThreeJet v) {
+ printf("%f (%f %f)\n",
+  v.f,
+  v.fu, v.fv
+ );
+}
diff --git a/xlockmore-4.14/modes/glx/i_threejet.h b/xlockmore-4.14/modes/glx/i_threejet.h
new file mode 100644 (file)
index 0000000..59e4672
--- /dev/null
@@ -0,0 +1,46 @@
+#ifndef __THREEJET
+#define __THREEJET
+#include "i_twojet.h"
+
+#define DIM 2
+class ThreeJet {
+  double f;
+  double fu, fv;
+  double fuu, fuv, fvv;
+  double fuuv, fuvv;
+
+  ThreeJet(double d, double du, double dv, double duu, double duv, double dvv,
+   double duuv, double duvv)
+   { f = d; fu = du; fv = dv; fuu = duu; fuv = duv; fvv = dvv;
+     fuuv = duuv; fuvv = duvv; }
+  public:
+  ThreeJet() {}
+  ThreeJet(double d, double du, double dv)
+   { f = d; fu = du; fv = dv; fuu = fuv = fvv = fuuv = fuvv = 0;}
+  operator TwoJet() { return TwoJet(f, fu, fv, fuv); }
+  operator double() { return f; }
+  operator<(double d) { return f < d; }
+  operator<(int d) { return f < d; }
+  operator>(double d) { return f > d; }
+  operator>(int d) { return f > d; }
+  operator<=(double d) { return f <= d; }
+  operator<=(int d) { return f <= d; }
+  operator>=(double d) { return f >= d; }
+  void operator %=(double d)
+   { f = fmod(f, d); if (f < 0) f += d; }
+  friend ThreeJet operator+(const ThreeJet x, const ThreeJet y);
+  friend ThreeJet operator*(const ThreeJet x, const ThreeJet y);
+  friend ThreeJet operator+(const ThreeJet x, double d);
+  friend ThreeJet operator+(const ThreeJet x, int d) {return x+double(d);}
+  friend ThreeJet operator*(const ThreeJet x, double d);
+  friend ThreeJet operator*(const ThreeJet x, int d) {return x*double(d);}
+  friend ThreeJet Sin(const ThreeJet x);
+  friend ThreeJet Cos(const ThreeJet x);
+  friend ThreeJet operator^(const ThreeJet x, double n);
+  friend ThreeJet Annihilate(const ThreeJet x, int index);
+  friend ThreeJet Interpolate(const ThreeJet v1, const ThreeJet v2, const ThreeJet weight);
+  friend void printJet(const ThreeJet);
+  friend class TwoJet D(const class ThreeJet x, int index);
+};
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/i_threejetvec.cc b/xlockmore-4.14/modes/glx/i_threejetvec.cc
new file mode 100644 (file)
index 0000000..9cfcf35
--- /dev/null
@@ -0,0 +1,104 @@
+#include "i_threejetvec.h"
+ThreeJetVec operator+(ThreeJetVec v, ThreeJetVec w) {
+  ThreeJetVec result;
+  result.x = v.x + w.x;
+  result.y = v.y + w.y;
+  result.z = v.z + w.z;
+  return result;
+}
+
+ThreeJetVec operator*(ThreeJetVec v, ThreeJet  a) {
+  ThreeJetVec result;
+  result.x = v.x*a;
+  result.y = v.y*a;
+  result.z = v.z*a;
+  return result;
+}
+
+ThreeJetVec operator*(ThreeJetVec v, double a) {
+  ThreeJetVec result;
+  result.x = v.x*a;
+  result.y = v.y*a;
+  result.z = v.z*a;
+  return result;
+}
+
+ThreeJetVec AnnihilateVec(ThreeJetVec v, int index) {
+  ThreeJetVec result;
+  result.x = Annihilate(v.x, index);
+  result.y = Annihilate(v.y, index);
+  result.z = Annihilate(v.z, index);
+  return result;
+}
+
+TwoJetVec D(ThreeJetVec x, int index) {
+  TwoJetVec result;
+  result.x = D(x.x, index);
+  result.y = D(x.y, index);
+  result.z = D(x.z, index);
+  return result;
+}
+
+ThreeJetVec Cross(ThreeJetVec v, ThreeJetVec w) {
+  ThreeJetVec result;
+  result.x = v.y*w.z + v.z*w.y*-1;
+  result.y = v.z*w.x + v.x*w.z*-1;
+  result.z = v.x*w.y + v.y*w.x*-1;
+  return result;
+}
+
+ThreeJet Dot(ThreeJetVec v, ThreeJetVec w) {
+  return v.x*w.x + v.y*w.y + v.z*w.z;
+}
+
+ThreeJetVec Normalize(ThreeJetVec v) {
+  ThreeJet a;
+  a = Dot(v,v);
+  if (a > 0)
+    a = a^-0.5;
+  else
+    a = ThreeJet(0, 0, 0);
+  return v*a;
+}
+
+ThreeJetVec RotateZ(ThreeJetVec v, ThreeJet angle) {
+  ThreeJetVec result;
+  ThreeJet s,c;
+  s = Sin (angle);
+  c = Cos (angle);
+  result.x =          v.x*c + v.y*s;
+  result.y = v.x*s*-1 + v.y*c;
+  result.z = v.z;
+  return result;
+}
+
+ThreeJetVec RotateY(ThreeJetVec v, ThreeJet angle) {
+  ThreeJetVec result;
+  ThreeJet s, c;
+  s = Sin (angle);
+  c = Cos (angle);
+  result.x = v.x*c + v.z*s*-1;
+  result.y = v.y;
+  result.z = v.x*s + v.z*c    ;
+  return result;
+}
+
+ThreeJetVec RotateX(ThreeJetVec v, ThreeJet angle) {
+  ThreeJetVec result;
+  ThreeJet s,c;
+  s = Sin (angle);
+  c = Cos (angle);
+  result.x = v.x;
+  result.y = v.y*c + v.z*s;
+  result.z = v.y*s*-1 + v.z*c;
+  return result;
+}
+
+ThreeJetVec InterpolateVec(ThreeJetVec v1, ThreeJetVec v2, ThreeJet weight) {
+  return (v1) * (weight*-1 + 1) + v2*weight;
+}
+
+ThreeJet Length(ThreeJetVec v)
+{
+  return (v.x^2 + v.y^2) ^ (.5);
+}
diff --git a/xlockmore-4.14/modes/glx/i_threejetvec.h b/xlockmore-4.14/modes/glx/i_threejetvec.h
new file mode 100644 (file)
index 0000000..a57bde1
--- /dev/null
@@ -0,0 +1,25 @@
+#ifndef __THREEJETVEC
+#define __THREEJETVEC
+#include "i_threejet.h"
+#include "i_twojetvec.h"
+struct ThreeJetVec {
+  ThreeJet x;
+  ThreeJet y;
+  ThreeJet z;
+  operator TwoJetVec() { return TwoJetVec(x,y,z); }
+};
+
+ThreeJetVec operator+(ThreeJetVec v, ThreeJetVec w);
+ThreeJetVec operator*(ThreeJetVec v, ThreeJet  a);
+ThreeJetVec operator*(ThreeJetVec v, double a);
+ThreeJetVec AnnihilateVec(ThreeJetVec v, int index);
+ThreeJetVec Cross(ThreeJetVec v, ThreeJetVec w);
+ThreeJet Dot(ThreeJetVec v, ThreeJetVec w);
+TwoJetVec D(ThreeJetVec x, int index);
+ThreeJetVec Normalize(ThreeJetVec v);
+ThreeJetVec RotateZ(ThreeJetVec v, ThreeJet angle);
+ThreeJetVec RotateY(ThreeJetVec v, ThreeJet angle);
+ThreeJetVec RotateX(ThreeJetVec v, ThreeJet angle);
+ThreeJetVec InterpolateVec(ThreeJetVec v1, ThreeJetVec v2, ThreeJet weight);
+ThreeJet Length(ThreeJetVec v);
+#endif
diff --git a/xlockmore-4.14/modes/glx/i_twojet.cc b/xlockmore-4.14/modes/glx/i_twojet.cc
new file mode 100644 (file)
index 0000000..c11bda8
--- /dev/null
@@ -0,0 +1,58 @@
+#include "i_twojet.h"
+
+TwoJet operator+(const TwoJet x, const TwoJet y) {
+  return TwoJet(x.f+y.f, x.fu+y.fu, x.fv+y.fv, x.fuv + y.fuv);
+}
+
+TwoJet operator*(const TwoJet x, const TwoJet y) {
+  return TwoJet(
+    x.f*y.f,
+    x.f*y.fu + x.fu*y.f,
+    x.f*y.fv + x.fv*y.f,
+    x.f*y.fuv + x.fu*y.fv + x.fv*y.fu + x.fuv*y.f
+  );
+}
+
+TwoJet operator+(const TwoJet x, double d) {
+  return TwoJet( x.f + d, x.fu, x.fv, x.fuv);
+}
+
+TwoJet operator*(const TwoJet x, double d) {
+  return TwoJet( d*x.f, d*x.fu, d*x.fv, d*x.fuv);
+}
+
+TwoJet Sin(const TwoJet x) {
+  TwoJet t = x*double(2*M_PI);
+  double s = sin(t.f);
+  double c = cos(t.f);
+  return TwoJet(s, c*t.fu, c*t.fv, c*t.fuv - s*t.fu*t.fv);
+}
+
+TwoJet Cos(const TwoJet x) {
+  TwoJet t = x*double(2*M_PI);
+  double s = cos(t.f);
+  double c = -sin(t.f);
+  return TwoJet(s, c*t.fu, c*t.fv, c*t.fuv - s*t.fu*t.fv);
+}
+
+TwoJet operator^(const TwoJet x, double n) {
+  double x0 = pow(x.f, n);
+  double x1 = (x.f == 0) ? 0 : n * x0/x.f;
+  double x2 = (x.f == 0) ? 0 : (n-1)*x1/x.f;
+  return TwoJet(x0, x1*x.fu, x1*x.fv, x1*x.fuv + x2*x.fu*x.fv);
+}
+
+TwoJet Annihilate(const TwoJet x, int index) {
+  return TwoJet(x.f, index == 1 ? x.fu : 0, index == 0 ? x.fv : 0, 0);
+}
+
+TwoJet Interpolate(const TwoJet v1, const TwoJet v2, const TwoJet weight) {
+  return (v1) * ((weight) * (-1) + 1) + v2*weight;
+}
+
+void printJet(const TwoJet v) {
+ printf("%f (%f %f)\n",
+  v.f,
+  v.fu, v.fv
+ );
+}
diff --git a/xlockmore-4.14/modes/glx/i_twojet.h b/xlockmore-4.14/modes/glx/i_twojet.h
new file mode 100644 (file)
index 0000000..f2936c1
--- /dev/null
@@ -0,0 +1,89 @@
+#ifndef __TWOJET
+#define __TWOJET
+#include <math.h>
+extern "C" {
+#include <stdio.h>
+#include <stdlib.h>
+}
+
+class ThreeJet;
+class TwoJet D(const class ThreeJet x, int index);
+class TwoJet {
+  public: /* this is a hack, but needed for now */
+  double f;
+  double fu, fv;
+  double fuv;
+
+  TwoJet() {}
+  TwoJet(double d, double du, double dv)
+   { f = d; fu = du; fv = dv; fuv = 0; }
+  TwoJet(double d, double du, double dv, double duv)
+   { f = d; fu = du; fv = dv; fuv = duv; }
+  operator double() { return f; }
+  operator<(double d) { return f < d; }
+  operator>(double d) { return f > d; }
+  operator>(int d) { return f > d; }
+  operator<=(double d) { return f <= d; }
+  operator>=(double d) { return f >= d; }
+  double df_du() { return fu; }
+  double df_dv() { return fv; }
+  double d2f_dudv() { return fuv; }
+  void operator +=(TwoJet x)
+   { f += x.f; fu += x.fu; fv += x.fv; fuv += x.fuv; }
+  void operator +=(double d)
+   { f += d; }
+  void operator *=(TwoJet x)
+   {
+     fuv = f*x.fuv + fu*x.fv + fv*x.fu + fuv*x.f;
+     fu = f*x.fu + fu*x.f;
+     fv = f*x.fv + fv*x.f;
+     f *= x.f;
+   }
+  void operator *=(double d)
+   { f *= d; fu *= d; fv *= d; fuv *= d; }
+  void operator %=(double d)
+   { f = fmod(f, d); if (f < 0) f += d; }
+  void operator ^=(double n)
+   {
+    if (f > 0) {
+     double x0 = pow(f, n);
+     double x1 = n * x0/f;
+     double x2 = (n-1)*x1/f;
+     fuv = x1*fuv + x2*fu*fv;
+     fu = x1*fu;
+     fv = x1*fv;
+     f = x0;
+    }
+   }
+  void Annihilate(int index)
+   { if (index == 0) fu = 0;
+     else if (index == 1) fv = 0;
+     fuv = 0;
+   }
+  void TakeSin() {
+   *this *= 2*M_PI;
+   double s = sin(f), c = cos(f);
+   f = s; fu = fu*c; fv = fv*c; fuv = c*fuv - s*fu*fv;
+  }
+  void TakeCos() {
+   *this *= 2*M_PI;
+   double s = cos(f), c = -sin(f);
+   f = s; fu = fu*c; fv = fv*c; fuv = c*fuv - s*fu*fv;
+  }
+  
+  friend TwoJet operator+(const TwoJet x, const TwoJet y);
+  friend TwoJet operator*(const TwoJet x, const TwoJet y);
+  friend TwoJet operator+(const TwoJet x, double d);
+  friend TwoJet operator+(const TwoJet x, int d) {return x+double(d);}
+  friend TwoJet operator*(const TwoJet x, double d);
+  friend TwoJet operator*(const TwoJet x, int d) {return x*double(d);}
+  friend TwoJet Sin(const TwoJet x);
+  friend TwoJet Cos(const TwoJet x);
+  friend TwoJet operator^(const TwoJet x, double n);
+  friend TwoJet Annihilate(const TwoJet x, int index);
+  friend TwoJet Interpolate(const TwoJet v1, const TwoJet v2, const TwoJet weight);
+  friend void printJet(const TwoJet);
+  friend class TwoJet D(const class ThreeJet x, int index);
+};
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/i_twojetvec.cc b/xlockmore-4.14/modes/glx/i_twojetvec.cc
new file mode 100644 (file)
index 0000000..48e05b0
--- /dev/null
@@ -0,0 +1,96 @@
+#include "i_twojetvec.h"
+TwoJetVec operator+(TwoJetVec v, TwoJetVec w) {
+  TwoJetVec result;
+  result.x = v.x + w.x;
+  result.y = v.y + w.y;
+  result.z = v.z + w.z;
+  return result;
+}
+
+TwoJetVec operator*(TwoJetVec v, TwoJet  a) {
+  TwoJetVec result;
+  result.x = v.x*a;
+  result.y = v.y*a;
+  result.z = v.z*a;
+  return result;
+}
+
+TwoJetVec operator*(TwoJetVec v, double a) {
+  TwoJetVec result;
+  result.x = v.x*a;
+  result.y = v.y*a;
+  result.z = v.z*a;
+  return result;
+}
+
+TwoJetVec AnnihilateVec(TwoJetVec v, int index) {
+  TwoJetVec result;
+  result.x = Annihilate(v.x, index);
+  result.y = Annihilate(v.y, index);
+  result.z = Annihilate(v.z, index);
+  return result;
+}
+
+TwoJetVec Cross(TwoJetVec v, TwoJetVec w) {
+  TwoJetVec result;
+  result.x = v.y*w.z + v.z*w.y*-1;
+  result.y = v.z*w.x + v.x*w.z*-1;
+  result.z = v.x*w.y + v.y*w.x*-1;
+  return result;
+}
+
+TwoJet Dot(TwoJetVec v, TwoJetVec w) {
+  return v.x*w.x + v.y*w.y + v.z*w.z;
+}
+
+TwoJetVec Normalize(TwoJetVec v) {
+  TwoJet a;
+  a = Dot(v,v);
+  if (a > 0)
+    a = a^-0.5;
+  else
+    a = TwoJet(0, 0, 0);
+  return v*a;
+}
+
+TwoJetVec RotateZ(TwoJetVec v, TwoJet angle) {
+  TwoJetVec result;
+  TwoJet s,c;
+  s = Sin (angle);
+  c = Cos (angle);
+  result.x =          v.x*c + v.y*s;
+  result.y = v.x*s*-1 + v.y*c;
+  result.z = v.z;
+  return result;
+}
+
+TwoJetVec RotateY(TwoJetVec v, TwoJet angle) {
+  TwoJetVec result;
+  TwoJet s, c;
+  s = Sin (angle);
+  c = Cos (angle);
+  result.x = v.x*c + v.z*s*-1;
+  result.y = v.y;
+  result.z = v.x*s + v.z*c    ;
+  return result;
+}
+
+TwoJetVec RotateX(TwoJetVec v, TwoJet angle) {
+  TwoJetVec result;
+  TwoJet s,c;
+  s = Sin (angle);
+  c = Cos (angle);
+  result.x = v.x;
+  result.y = v.y*c + v.z*s;
+  result.z = v.y*s*-1 + v.z*c;
+  return result;
+}
+
+TwoJetVec InterpolateVec(TwoJetVec v1, TwoJetVec v2, TwoJet weight) {
+  return (v1) * (weight*-1 + 1) + v2*weight;
+}
+
+TwoJet Length(TwoJetVec v)
+{
+  return (v.x^2 + v.y^2) ^ (.5);
+}
diff --git a/xlockmore-4.14/modes/glx/i_twojetvec.h b/xlockmore-4.14/modes/glx/i_twojetvec.h
new file mode 100644 (file)
index 0000000..e578fa4
--- /dev/null
@@ -0,0 +1,24 @@
+#ifndef __TWOJETVEC
+#define __TWOJETVEC
+#include "i_twojet.h"
+struct TwoJetVec {
+  TwoJet x;
+  TwoJet y;
+  TwoJet z;
+  TwoJetVec() {}
+  TwoJetVec(TwoJet a, TwoJet b, TwoJet c) { x = a; y = b; z = c; }
+};
+
+TwoJetVec operator+(TwoJetVec v, TwoJetVec w);
+TwoJetVec operator*(TwoJetVec v, TwoJet  a);
+TwoJetVec operator*(TwoJetVec v, double a);
+TwoJetVec AnnihilateVec(TwoJetVec v, int index);
+TwoJetVec Cross(TwoJetVec v, TwoJetVec w);
+TwoJet Dot(TwoJetVec v, TwoJetVec w);
+TwoJetVec Normalize(TwoJetVec v);
+TwoJetVec RotateZ(TwoJetVec v, TwoJet angle);
+TwoJetVec RotateY(TwoJetVec v, TwoJet angle);
+TwoJetVec RotateX(TwoJetVec v, TwoJet angle);
+TwoJetVec InterpolateVec(TwoJetVec v1, TwoJetVec v2, TwoJet weight);
+TwoJet Length(TwoJetVec v);
+#endif
diff --git a/xlockmore-4.14/modes/glx/invert.c b/xlockmore-4.14/modes/glx/invert.c
new file mode 100644 (file)
index 0000000..3059d2c
--- /dev/null
@@ -0,0 +1,185 @@
+/*-
+ * invert.c - Sphere inversion
+ *
+ * See xlock.c for copying information.
+ *
+ * Revision History:
+ *
+ * Tim Rowley (code from the Geometry Center <URL:http://www.geom.umn.edu/>
+ *
+ * This is a sphere eversion of William P. Thurston which was the subject
+ * of the Geometry Center film "Outside In".  The code is based on the
+ * software which was used to create the RIB files for the film.
+ * Trying to figure it out from the full eversion is difficult.  If you get
+ * a chance to look at the original film, it leads up the eversion nicely.
+ * There is more information about the eversion, including the script from
+ * the film, at: http://www.geom.umn.edu/docs/outreach/oi/
+ *
+ * Demonstration of turning a sphere inside out without creating
+ * any kinks (two surfaces can occupy the same space at the same time).
+ * 
+ */
+
+/*-
+ * due to a Bug/feature in VMS X11/Intrinsic.h has to be placed before xlock.
+ * otherwise caddr_t is not defined correctly
+ */
+#include <X11/Intrinsic.h>
+#include "xlock.h"
+#include "vis.h"
+
+#ifdef MODE_invert
+
+#include "i_linkage.h"
+#define STEPS 75
+
+ModeSpecOpt invert_opts =
+{0, NULL, 0, NULL, NULL};
+
+static spherestruct *spheres = NULL;
+
+/* new window size or exposure */
+static void
+reshape(int width, int height)
+{
+  GLfloat     h = (GLfloat) height / (GLfloat) width;
+  
+  glViewport(0, 0, (GLint) width, (GLint) height);
+  glMatrixMode(GL_PROJECTION);
+  glLoadIdentity();
+  glFrustum(-1.0, 1.0, -h, h, 5.0, 60.0);
+  glMatrixMode(GL_MODELVIEW);
+  glLoadIdentity();
+  glTranslatef(0.0, 0.0, -10.0);
+  
+  /* The depth buffer will be cleared, if needed, before the
+   * next frame.  Right now we just want to black the screen.
+   */
+  glClear(GL_COLOR_BUFFER_BIT);
+}
+
+
+static void
+pinit(ModeInfo * mi)
+{
+/*
+  GLfloat front_mat[] = {.8, .7, .4, 1.0};
+  GLfloat back_mat[] = {.508, .333, .774, 1.0};
+  */
+
+  GLfloat front_ambient[] = {.16, .14, .08, 1.0};
+  GLfloat front_diffuse[] = {.56, .49, .28, 1.0};
+  GLfloat front_specular[] = {1, 1, 0.8, 1.0};
+
+  GLfloat back_ambient[] = {.1016, .0666, .1548, 1.0};
+  GLfloat back_diffuse[] = {.254, .166, .387, 1.0};
+  GLfloat back_specular[] = {.4, .2, .5, 1.0};
+
+  /* spherestruct *gp = &spheres[MI_SCREEN(mi)]; */
+  static GLfloat pos[4] =
+  {5.0, 5.0, 10.0, 0.0};
+  
+  glLightfv(GL_LIGHT0, GL_POSITION, pos);
+  glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_TRUE);
+  glEnable(GL_LIGHTING);
+  glEnable(GL_LIGHT0);
+  glEnable(GL_DEPTH_TEST);
+  glShadeModel(GL_SMOOTH);
+
+  glMaterialfv(GL_FRONT, GL_AMBIENT, front_ambient);
+  glMaterialfv(GL_FRONT, GL_DIFFUSE, front_diffuse);
+  glMaterialfv(GL_FRONT, GL_SPECULAR, front_specular);
+  glMaterialf(GL_FRONT, GL_SHININESS, 32.0);
+
+  glMaterialfv(GL_BACK, GL_AMBIENT, back_ambient);
+  glMaterialfv(GL_BACK, GL_DIFFUSE, back_diffuse);
+  glMaterialfv(GL_BACK, GL_SPECULAR, back_specular);
+  glMaterialf(GL_BACK, GL_SHININESS, 38.0);
+}
+
+void
+init_invert(ModeInfo * mi)
+{
+  int         screen = MI_SCREEN(mi);
+
+  spherestruct *gp;
+  
+  if (spheres == NULL) {
+    if ((spheres = (spherestruct *) calloc(MI_NUM_SCREENS(mi),
+                                          sizeof (spherestruct))) == NULL)
+      return;
+  }
+  
+  gp = &spheres[screen];
+  gp->time = 0;
+  gp->construction = 1;
+  gp->partlist = NULL;
+  gp->numsteps = STEPS;
+  gp->view_rotx = NRAND(360);
+  gp->view_roty = NRAND(360);
+  gp->view_rotz = NRAND(360);
+  gp->glx_context = init_GL(mi);
+  gp->frames = glGenLists(STEPS);
+  
+  reshape(MI_WIDTH(mi), MI_HEIGHT(mi));
+  pinit(mi);
+}
+
+void
+draw_invert(ModeInfo * mi)
+{
+  spherestruct *gp = &spheres[MI_SCREEN(mi)];
+  Display    *display = MI_DISPLAY(mi);
+  Window      window = MI_WINDOW(mi);
+  /* int         angle_incr = MI_CYCLES(mi) ? MI_CYCLES(mi) : 2; */
+  int         rot_incr = MI_COUNT(mi) ? MI_COUNT(mi) : 1;
+  
+  glDrawBuffer(GL_BACK);
+  
+  glXMakeCurrent(display, window, *(gp->glx_context));
+  invert_draw(gp);
+
+  /* let's do something so we don't get bored */
+  if (gp->time == STEPS-1)
+    gp->construction = 0;
+  if (gp->time == STEPS-1)
+    gp->forwards = 0;
+  if (gp->time == 0)
+    gp->forwards = 1;
+  if (gp->forwards)
+    gp->time++;
+  else
+    gp->time--;
+  gp->view_rotx = (int) (gp->view_rotx + rot_incr) % 360;
+  gp->view_roty = (int) (gp->view_roty + rot_incr) % 360;
+  gp->view_rotz = (int) (gp->view_rotz + rot_incr) % 360;
+  
+  glFinish();
+  glXSwapBuffers(display, window);
+}
+
+void
+release_invert(ModeInfo * mi)
+{
+  if (spheres != NULL) {
+    int         screen;
+    
+    for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+      spherestruct *gp = &spheres[screen];
+      
+      /* Display lists MUST be freed while their glXContext is current. */
+      glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(gp->glx_context));
+
+      glDeleteLists(gp->frames, STEPS);
+      free(gp->partlist);
+      /* Don't destroy the glXContext.  init_GL does that. */
+    }
+    (void) free((void *) spheres);
+    spheres = NULL;
+  }
+}
+
+
+/*********************************************************/
+
+#endif /* MODE_invert */
diff --git a/xlockmore-4.14/modes/glx/lament.c b/xlockmore-4.14/modes/glx/lament.c
new file mode 100644 (file)
index 0000000..96d7760
--- /dev/null
@@ -0,0 +1,2508 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* lament --- Shows Lemarchand's Box */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)lament.c       4.12 98/09/15 xlockmore";
+
+#endif
+
+/* xscreensaver, Copyright (c) 1998 Jamie Zawinski <jwz@jwz.org>
+
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ */
+
+/* Animates Lemarchand's Box, the Lament Configuration.  By jwz, 25-Jul-98.
+
+   TODO:
+
+   *  The "gold" color isn't quite right; it looks more like "yellow" than
+   "gold" to me.
+
+   *  For some reason, the interior surfaces are shinier than the exterior
+   surfaces.  I don't understand why, but this should be remedied.
+
+   *  Perhaps use a slightly-bumpy or oily texture for the interior surfaces?
+
+   *  Some of the edges don't line up perfectly (since the images are not
+   perfectly symetrical.)  Something should be done about this; either
+   making the edges overlap slightly (instead of leaving gaps) or fixing
+   the images so that the edges may be symmetrical.
+
+   *  I want the gold leaf to seem to be raised up from the surface, but I
+   think this isn't possible with OpenGL.  Supposedly, OpenGL only 
+   supports Gouraud shading (interpolating edge normals from face normals,
+   and shading smoothly) but bump-maps only work with Phong shading
+   (computing a normal for each rendered pixel.)
+
+   *  As far as I can tell, OpenGL doesn't do shadows.  As a result, the
+   forward-facing interior walls are drawn bright, not dark.  If it was
+   casting shadows properly, it wouldn't matter so much that the edges
+   don't quite line up, because the lines would be black, and thus not
+   visible.  But the edges don't match up, and so the bright interior
+   faces show through, and that sucks.
+
+   But apparently there are tricky ways around this:
+   http://reality.sgi.com/opengl/tips/rts/
+   I think these techniques require GLUT, however, which isn't 
+   (currently) required by any other xscreensaver hacks.
+
+   *  There should be strange lighting effects playing across the surface:
+   electric sparks, or little glittery blobs of light.  
+   http://reality.sgi.com/opengl/tips/lensflare/ might provide guidance.
+
+   *  Need to add some more modes, to effect the transition from the cube
+   shapes to the "spike" or "leviathan" shapes.  I have extensive notes
+   on how these transformations occur, but unfortunately, due to camera
+   trickery, the transitions require dematerializations which do not
+   preserve object volume.  But I suppose that's allowed, in
+   non-Euclidian or hyperdimensional spaces (since the extra mass could
+   simply be rotated along the axis to which one cannot point.)
+
+   The other hard thing about this is that the "leviathan" shapes contain
+   a much larger number of facets, and I modelled this whole thing by 
+   hand, since I don't have any 3d-object-editing tools that I know how
+   to use (or that look like they would take any less than several months
+   to become even marginally proficient with...)
+
+   *  Perhaps there should be a table top, on which it casts a shadow?
+   And then multiple light sources (for multiple shadows)?
+
+   *  Needs music.  ("Hellraiser Themes" by Coil: TORSO CD161; also
+   duplicated on the "Unnatural History 2" compilation, WORLN M04699.)
+
+   *  I'm not totally happy with the spinning motion; I like the
+   acceleration and deceleration, but it often feels like it's going too
+   fast, or not naturally enough, or something.
+
+   *  However, the motion is better than that used by gears, superquadrics,
+   etc.; so maybe I should make them all share the same motion code.
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS      "Lament"
+#define HACK_INIT      init_lament
+#define HACK_DRAW      draw_lament
+#define lament_opts    xlockmore_opts
+#define DEFAULTS       "*delay:        10000   \n"     \
+                       "*wireframe:    False   \n"     \
+                       "*texture:      True    \n"
+#include "xlockmore.h"
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_lament
+
+#undef HAVE_XPM
+#define HAVE_XPM
+#undef countof
+#define countof(x) ((int)(sizeof((x))/sizeof((*x))))
+
+#define DEF_TEXTURE "True"
+
+static Bool do_texture;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-texture", ".lament.texture", XrmoptionNoArg, (caddr_t) "on"},
+       {"+texture", ".lament.texture", XrmoptionNoArg, (caddr_t) "off"},
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & do_texture, "texture", "Texture", DEF_TEXTURE, t_Bool},
+};
+
+static OptionStruct desc[] =
+{
+       {"-/+texture", "turn on/off texturing"}
+};
+
+ModeSpecOpt lament_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+
+#if USE_XPMINC
+#include <xpm.h>
+#else
+#include <X11/xpm.h>           /* Normal spot */
+#endif
+#ifdef STANDALONE
+#include "../images/lament.xpm"
+#else
+#include "pixmaps/lament.xpm"
+#endif
+
+
+#define RANDSIGN() ((LRAND() & 1) ? 1 : -1)
+#define FLOATRAND(a) (((double)LRAND() / (double)MAXRAND) * a)
+
+typedef enum {
+       LAMENT_BOX,
+
+       LAMENT_STAR_OUT,
+       LAMENT_STAR_ROT,
+       LAMENT_STAR_ROT_IN,
+       LAMENT_STAR_ROT_OUT,
+       LAMENT_STAR_UNROT,
+       LAMENT_STAR_IN,
+
+       LAMENT_TETRA_UNE,
+       LAMENT_TETRA_USW,
+       LAMENT_TETRA_DWN,
+       LAMENT_TETRA_DSE,
+
+       LAMENT_LID_OPEN,
+       LAMENT_LID_CLOSE,
+       LAMENT_LID_ZOOM,
+
+       LAMENT_TASER_OUT,
+       LAMENT_TASER_SLIDE,
+       LAMENT_TASER_SLIDE_IN,
+       LAMENT_TASER_IN
+
+} lament_type;
+
+static GLfloat exterior_color[] =
+{0.70, 0.60, 0.00, 1.00};
+static GLfloat interior_color[] =
+{0.25, 0.25, 0.20, 1.00};
+
+
+typedef struct {
+       GLXContext *glx_context;
+
+       GLuint      box;        /* display list IDs */
+       GLuint      star1, star2;
+       GLuint      tetra_une, tetra_usw, tetra_dwn, tetra_dse, tetra_mid;
+       GLuint      lid_0, lid_1, lid_2, lid_3, lid_4;
+       GLuint      taser_base, taser_lifter, taser_slider;
+
+       GLfloat     rotx, roty, rotz;   /* current object rotation */
+       GLfloat     dx, dy, dz; /* current rotational velocity */
+       GLfloat     ddx, ddy, ddz;      /* current rotational acceleration */
+       GLfloat     d_max;      /* max velocity */
+       XImage     *texture;    /* image bits */
+       GLuint      texids[6];  /* texture map IDs */
+       lament_type type;       /* which mode of the object is current */
+
+       int         anim_pause; /* countdown before animating again */
+       GLfloat     anim_r, anim_y, anim_z;     /* relative position during anims */
+
+} lament_configuration;
+
+static lament_configuration *lcs = NULL;
+
+#define FACE_N 3
+#define FACE_S 2
+#define FACE_E 0
+#define FACE_W 4
+#define FACE_U 5
+#define FACE_D 1
+
+#ifdef HAVE_XPM
+static      Bool
+bigendian(void)
+{
+       union {
+               int         i;
+               char        c[sizeof (int)];
+       } u;
+
+       u.i = 1;
+       return !u.c[0];
+}
+#endif /* HAVE_XPM */
+
+
+static void
+parse_image_data(ModeInfo * mi)
+{
+#ifdef HAVE_XPM
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+
+       /* All we want to do is get RGB data out of the XPM file built in to this
+          program.  This is a pain, because there is no way  (as of XPM version
+          4.6, at least) to get libXpm to make an XImage without also allocating
+          colors with XAllocColor.  So, instead, we create an XpmImage and parse
+          out the RGB values of the pixels ourselves; and construct an XImage
+          by hand.  Regardless of the depth of the visual we're using, this
+          XImage will have 32 bits per pixel, 8 each per R, G, and B.  We put
+          0xFF in the fourth slot, as GL will interpret that as "alpha".
+        */
+       XpmImage    xpm_image;
+       XpmInfo     *xpm_info = NULL;
+       int         result;
+       int         x, y, i;
+       int         bpl, wpl;
+       XColor      colors[255];
+
+       result = XpmCreateXpmImageFromData(lament_faces, &xpm_image, xpm_info);
+       if (result != XpmSuccess) {
+               (void) fprintf(stderr, "unable to parse xpm data (%d).\n", result);
+               return;
+       }
+       lc->texture = XCreateImage(MI_DISPLAY(mi), MI_VISUAL(mi), 32, ZPixmap, 0, 0,
+                                  xpm_image.width, xpm_image.height, 32, 0);
+
+       bpl = lc->texture->bytes_per_line;
+       wpl = bpl / 4;
+
+       lc->texture->data = (char *) malloc(xpm_image.height * bpl);
+
+       /* Parse the colors in the XPM into RGB values. */
+       for (i = 0; i < xpm_image.ncolors; i++)
+               if (!XParseColor(MI_DISPLAY(mi), MI_COLORMAP(mi),
+                                xpm_image.colorTable[i].c_color,
+                                &colors[i])) {
+                       (void) fprintf(stderr, "unparsable color: %s\n",
+                                      xpm_image.colorTable[i].c_color);
+                       return;
+               }
+       /* Translate the XpmImage to an RGB XImage. */
+       {
+               int         rpos, gpos, bpos, apos;     /* bitfield positions */
+
+               /* Note that unlike X, which is endianness-agnostic (since any XImage
+                  can have its own specific bit ordering, with the server reversing
+                  things as necessary) OpenGL pretends everything is client-side, so
+                  we need to pack things in the right order for the client machine.
+                */
+               if (bigendian())
+                       rpos = 24, gpos = 16, bpos = 8, apos = 0;
+               else
+                       rpos = 0, gpos = 8, bpos = 16, apos = 24;
+
+               for (y = 0; y < xpm_image.height; y++) {
+                       int         y2 = (xpm_image.height - 1 - y);    /* Texture maps are upside down. */
+
+                       unsigned int *oline = (unsigned int *) (lc->texture->data + (y * bpl));
+                       unsigned int *iline = (unsigned int *) (xpm_image.data + (y2 * wpl));
+
+                       for (x = 0; x < xpm_image.width; x++) {
+                               XColor     *c = &colors[iline[x]];
+
+                               /* pack it as RGBA */
+                               oline[x] = (((c->red >> 8) << rpos) |
+                                           ((c->green >> 8) << gpos) |
+                                           ((c->blue >> 8) << bpos) |
+                                           (0xFF << apos));
+                       }
+               }
+       }
+
+       /* I sure hope these only free the contents, and not the args. */
+       XpmFreeXpmImage(&xpm_image);
+       XpmFreeXpmInfo(xpm_info);
+
+#else /* !HAVE_XPM */
+       (void) fprintf(stderr, "not compiled with XPM support.\n");
+       return;
+#endif /* !HAVE_XPM */
+}
+\f
+
+
+/* Computing normal vectors (thanks to Nat Friedman <ndf@mit.edu>)
+ */
+
+typedef struct vector {
+       GLfloat     x, y, z;
+} vector;
+
+typedef struct plane {
+       vector      p1, p2, p3;
+} plane;
+
+static void
+vector_set(vector * v, GLfloat x, GLfloat y, GLfloat z)
+{
+       v->x = x;
+       v->y = y;
+       v->z = z;
+}
+
+static void
+vector_cross(vector v1, vector v2, vector * v3)
+{
+       v3->x = (v1.y * v2.z) - (v1.z * v2.y);
+       v3->y = (v1.z * v2.x) - (v1.x * v2.z);
+       v3->z = (v1.x * v2.y) - (v1.y * v2.x);
+}
+
+static void
+vector_subtract(vector v1, vector v2, vector * res)
+{
+       res->x = v1.x - v2.x;
+       res->y = v1.y - v2.y;
+       res->z = v1.z - v2.z;
+}
+
+static void
+plane_normal(plane p, vector * n)
+{
+       vector      v1, v2;
+
+       vector_subtract(p.p1, p.p2, &v1);
+       vector_subtract(p.p1, p.p3, &v2);
+       vector_cross(v2, v1, n);
+}
+
+static void
+do_normal(GLfloat x1, GLfloat y1, GLfloat z1,
+         GLfloat x2, GLfloat y2, GLfloat z2,
+         GLfloat x3, GLfloat y3, GLfloat z3)
+{
+       plane       plane;
+       vector      n;
+
+       vector_set(&plane.p1, x1, y1, z1);
+       vector_set(&plane.p2, x2, y2, z2);
+       vector_set(&plane.p3, x3, y3, z3);
+       plane_normal(plane, &n);
+       n.x = -n.x;
+       n.y = -n.y;
+       n.z = -n.z;
+
+       glNormal3f(n.x, n.y, n.z);
+
+#ifdef DEBUG
+       /* Draw a line in the direction of this face's normal. */
+       {
+               GLfloat     ax = n.x > 0 ? n.x : -n.x;
+               GLfloat     ay = n.y > 0 ? n.y : -n.y;
+               GLfloat     az = n.z > 0 ? n.z : -n.z;
+               GLfloat     mx = (x1 + x2 + x3) / 3;
+               GLfloat     my = (y1 + y2 + y3) / 3;
+               GLfloat     mz = (z1 + z2 + z3) / 3;
+               GLfloat     xx, yy, zz;
+
+               GLfloat     max = ax > ay ? ax : ay;
+
+               if (az > max)
+                       max = az;
+               max *= 2;
+               xx = n.x / max;
+               yy = n.y / max;
+               zz = n.z / max;
+
+               glBegin(GL_LINE_LOOP);
+               glVertex3f(mx, my, mz);
+               glVertex3f(mx + xx, my + yy, mz + zz);
+               glEnd();
+       }
+#endif /* DEBUG */
+}
+\f
+
+
+/* Shorthand utilities for making faces, with proper normals.
+ */
+
+static void
+face3(GLint texture, GLfloat * color, Bool wire,
+                 GLfloat s1, GLfloat t1, GLfloat x1, GLfloat y1, GLfloat z1,
+                 GLfloat s2, GLfloat t2, GLfloat x2, GLfloat y2, GLfloat z2,
+                 GLfloat s3, GLfloat t3, GLfloat x3, GLfloat y3, GLfloat z3)
+{
+#ifdef HAVE_GLBINDTEXTURE
+       glBindTexture(GL_TEXTURE_2D, texture);
+#endif /* HAVE_GLBINDTEXTURE */
+       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, color);
+       do_normal(x1, y1, z1, x2, y2, z2, x3, y3, z3);
+       glBegin(wire ? GL_LINE_LOOP : GL_TRIANGLES);
+       glTexCoord2f(s1, t1);
+       glVertex3f(x1, y1, z1);
+       glTexCoord2f(s2, t2);
+       glVertex3f(x2, y2, z2);
+       glTexCoord2f(s3, t3);
+       glVertex3f(x3, y3, z3);
+       glEnd();
+}
+
+static void
+face4(GLint texture, GLfloat * color, Bool wire,
+                 GLfloat s1, GLfloat t1, GLfloat x1, GLfloat y1, GLfloat z1,
+                 GLfloat s2, GLfloat t2, GLfloat x2, GLfloat y2, GLfloat z2,
+                 GLfloat s3, GLfloat t3, GLfloat x3, GLfloat y3, GLfloat z3,
+                 GLfloat s4, GLfloat t4, GLfloat x4, GLfloat y4, GLfloat z4)
+{
+#ifdef HAVE_GLBINDTEXTURE
+       glBindTexture(GL_TEXTURE_2D, texture);
+#endif /* HAVE_GLBINDTEXTURE */
+       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, color);
+       do_normal(x1, y1, z1, x2, y2, z2, x3, y3, z3);
+       glBegin(wire ? GL_LINE_LOOP : GL_QUADS);
+       glTexCoord2f(s1, t1);
+       glVertex3f(x1, y1, z1);
+       glTexCoord2f(s2, t2);
+       glVertex3f(x2, y2, z2);
+       glTexCoord2f(s3, t3);
+       glVertex3f(x3, y3, z3);
+       glTexCoord2f(s4, t4);
+       glVertex3f(x4, y4, z4);
+       glEnd();
+}
+
+static void
+face5(GLint texture, GLfloat * color, Bool wire,
+                 GLfloat s1, GLfloat t1, GLfloat x1, GLfloat y1, GLfloat z1,
+                 GLfloat s2, GLfloat t2, GLfloat x2, GLfloat y2, GLfloat z2,
+                 GLfloat s3, GLfloat t3, GLfloat x3, GLfloat y3, GLfloat z3,
+                 GLfloat s4, GLfloat t4, GLfloat x4, GLfloat y4, GLfloat z4,
+                 GLfloat s5, GLfloat t5, GLfloat x5, GLfloat y5, GLfloat z5)
+{
+#ifdef HAVE_GLBINDTEXTURE
+       glBindTexture(GL_TEXTURE_2D, texture);
+#endif /* HAVE_GLBINDTEXTURE */
+       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, color);
+       do_normal(x1, y1, z1, x2, y2, z2, x3, y3, z3);
+       glBegin(wire ? GL_LINE_LOOP : GL_POLYGON);
+       glTexCoord2f(s1, t1);
+       glVertex3f(x1, y1, z1);
+       glTexCoord2f(s2, t2);
+       glVertex3f(x2, y2, z2);
+       glTexCoord2f(s3, t3);
+       glVertex3f(x3, y3, z3);
+       glTexCoord2f(s4, t4);
+       glVertex3f(x4, y4, z4);
+       glTexCoord2f(s5, t5);
+       glVertex3f(x5, y5, z5);
+       glEnd();
+}
+\f
+
+
+/* Creating object models
+ */
+
+static void
+box(ModeInfo * mi, Bool wire)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+
+       glNewList(lc->box, GL_COMPILE);
+       glShadeModel(GL_SMOOTH);
+
+       /* N */
+       face4(lc->texids[FACE_N], exterior_color, wire,
+             0.0, 0.0, -0.5, 0.5, 0.5,
+             1.0, 0.0, 0.5, 0.5, 0.5,
+             1.0, 1.0, 0.5, 0.5, -0.5,
+             0.0, 1.0, -0.5, 0.5, -0.5);
+
+       /* S */
+       face4(lc->texids[FACE_S], exterior_color, wire,
+             0.0, 0.0, -0.5, -0.5, -0.5,
+             1.0, 0.0, 0.5, -0.5, -0.5,
+             1.0, 1.0, 0.5, -0.5, 0.5,
+             0.0, 1.0, -0.5, -0.5, 0.5);
+
+       /* E */
+       face4(lc->texids[FACE_E], exterior_color, wire,
+             0.0, 0.0, 0.5, -0.5, -0.5,
+             1.0, 0.0, 0.5, 0.5, -0.5,
+             1.0, 1.0, 0.5, 0.5, 0.5,
+             0.0, 1.0, 0.5, -0.5, 0.5);
+
+       /* W */
+       face4(lc->texids[FACE_W], exterior_color, wire,
+             1.0, 1.0, -0.5, -0.5, 0.5,
+             0.0, 1.0, -0.5, 0.5, 0.5,
+             0.0, 0.0, -0.5, 0.5, -0.5,
+             1.0, 0.0, -0.5, -0.5, -0.5);
+
+       /* U */
+       face4(lc->texids[FACE_U], exterior_color, wire,
+             1.0, 0.0, 0.5, -0.5, 0.5,
+             1.0, 1.0, 0.5, 0.5, 0.5,
+             0.0, 1.0, -0.5, 0.5, 0.5,
+             0.0, 0.0, -0.5, -0.5, 0.5);
+
+       /* D */
+       face4(lc->texids[FACE_D], exterior_color, wire,
+             0.0, 1.0, -0.5, -0.5, -0.5,
+             0.0, 0.0, -0.5, 0.5, -0.5,
+             1.0, 0.0, 0.5, 0.5, -0.5,
+             1.0, 1.0, 0.5, -0.5, -0.5);
+
+       glEndList();
+}
+
+
+static void
+star(ModeInfo * mi, Bool top, Bool wire)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+       int         i;
+
+       int         points[][2] =
+       {
+               {  77,  74 }, {  60,  98 }, {   0,  71 }, {   0,   0 },    /* L1 */
+               {  60,  98 }, {  55, 127 }, {   0, 127 }, {   0,  71 },    /* L2 */
+               {  55, 127 }, {  60, 154 }, {   0, 179 }, {   0, 127 },    /* L3 */
+               {  60, 154 }, {  76, 176 }, {   0, 255 }, {   0, 179 },    /* L4 */
+               {  76, 176 }, { 100, 193 }, {  74, 255 }, {   0, 255 },    /* B1 */
+               { 100, 193 }, { 127, 198 }, { 127, 255 }, {  74, 255 },    /* B2 */
+               { 127, 198 }, { 151, 193 }, { 180, 255 }, { 127, 255 },    /* B3 */
+               { 151, 193 }, { 178, 177 }, { 255, 255 }, { 180, 255 },    /* B4 */
+               { 178, 177 }, { 193, 155 }, { 255, 181 }, { 255, 255 },    /* R4 */
+               { 193, 155 }, { 199, 127 }, { 255, 127 }, { 255, 181 },    /* R3 */
+               { 199, 127 }, { 194,  99 }, { 255,  74 }, { 255, 127 },    /* R2 */
+               { 194,  99 }, { 179,  76 }, { 255,   0 }, { 255,  74 },    /* R1 */
+               { 179,  76 }, { 155,  60 }, { 180,   0 }, { 255,   0 },    /* T4 */
+               { 155,  60 }, { 126,  55 }, { 126,   0 }, { 180,   0 },    /* T3 */
+               { 126,  55 }, { 100,  60 }, {  75,   0 }, { 126,   0 },    /* T2 */
+               { 100,  60 }, {  77,  74 }, {   0,   0 }, {  75,   0 },    /* T1 */
+       };
+
+       for (i = 0; i < countof(points); i++)
+               points[i][1] = 255 - points[i][1];
+
+       if (top)
+               glNewList(lc->star1, GL_COMPILE);
+       else
+               glNewList(lc->star2, GL_COMPILE);
+
+       if (!top)
+               glRotatef(-180.0, 1.0, 0.0, 0.0);
+
+       for (i = 0; i < countof(points) / 4; i += 2) {
+               int         j, k;
+
+               /* Top face.
+                */
+
+               GLfloat     s[4], t[4], x[4], y[4], z[4];
+
+               for (j = 3, k = 0; j >= 0; j--, k++) {
+                       GLfloat     xx = points[(i * 4) + j][0] / 255.0L;
+                       GLfloat     yy = points[(i * 4) + j][1] / 255.0L;
+
+                       s[k] = xx;
+                       t[k] = yy;
+                       x[k] = xx - 0.5;
+                       y[k] = yy - 0.5;
+                       z[k] = 0.5;
+               }
+               face4(lc->texids[top ? FACE_U : FACE_D], exterior_color, wire,
+                     s[0], t[0], x[0], y[0], z[0],
+                     s[1], t[1], x[1], y[1], z[1],
+                     s[2], t[2], x[2], y[2], z[2],
+                     s[3], t[3], x[3], y[3], z[3]);
+
+               /* Bottom face.
+                */
+               for (j = 0, k = 0; j < 4; j++, k++) {
+                       GLfloat     xx = points[(i * 4) + j][0] / 255.0L;
+                       GLfloat     yy = points[(i * 4) + j][1] / 255.0L;
+
+                       s[k] = xx;
+                       t[k] = 1.0 - yy;
+                       x[k] = xx - 0.5;
+                       y[k] = yy - 0.5;
+                       z[k] = -0.5;
+               }
+               face4(lc->texids[top ? FACE_U : FACE_D], exterior_color, wire,
+                     s[0], t[0], x[0], y[0], z[0],
+                     s[1], t[1], x[1], y[1], z[1],
+                     s[2], t[2], x[2], y[2], z[2],
+                     s[3], t[3], x[3], y[3], z[3]);
+
+               /* Connecting faces.
+                */
+               for (j = 3; j >= 0; j--) {
+                       int         l = (j == 0 ? 3 : j - 1);
+                       Bool        front_p = (j == 3);
+                       GLfloat     x1 = points[(i * 4) + j][0] / 255.0L;
+                       GLfloat     y1 = points[(i * 4) + j][1] / 255.0L;
+                       GLfloat     x2 = points[(i * 4) + l][0] / 255.0L;
+                       GLfloat     y2 = points[(i * 4) + l][1] / 255.0L;
+
+                       GLfloat     tx1 = 0.0, tx2 = 1.0, ty1 = 0.0, ty2 = 1.0;
+
+                       int         texture = 0;
+                       int         facing = i / 4;
+
+                       facing = (facing + j + 5) % 4;
+
+                       switch (facing) {
+                               case 0:
+                                       texture = FACE_W;
+                                       if (top) {
+                                               tx1 = 1.0 - y1;
+                                               tx2 = 1.0 - y2;
+                                               ty1 = 0.0;
+                                               ty2 = 1.0;
+                                       } else {
+                                               tx1 = y1;
+                                               tx2 = y2;
+                                               ty1 = 1.0;
+                                               ty2 = 0.0;
+                                       }
+                                       break;
+                               case 1:
+                                       texture = top ? FACE_S : FACE_N;
+                                       tx1 = x1;
+                                       tx2 = x2;
+                                       ty1 = 0.0;
+                                       ty2 = 1.0;
+                                       break;
+                               case 2:
+                                       texture = FACE_E;
+                                       if (top) {
+                                               tx1 = y1;
+                                               tx2 = y2;
+                                               ty1 = 0.0;
+                                               ty2 = 1.0;
+                                       } else {
+                                               tx1 = 1.0 - y1;
+                                               tx2 = 1.0 - y2;
+                                               ty1 = 1.0;
+                                               ty2 = 0.0;
+                                       }
+                                       break;
+                               case 3:
+                                       texture = top ? FACE_N : FACE_S;
+                                       tx1 = x1;
+                                       tx2 = x2;
+                                       ty1 = 1.0;
+                                       ty2 = 0.0;
+                                       break;
+                       }
+
+                       x1 -= 0.5;
+                       x2 -= 0.5;
+                       y1 -= 0.5;
+                       y2 -= 0.5;
+
+                       face4(front_p ? lc->texids[texture] : 0,
+                             front_p ? exterior_color : interior_color,
+                             wire,
+                             tx1, ty2, x1, y1, 0.5,
+                             tx1, ty1, x1, y1, -0.5,
+                             tx2, ty1, x2, y2, -0.5,
+                             tx2, ty2, x2, y2, 0.5);
+               }
+       }
+
+
+       /* Central core top cap.
+        */
+#ifdef HAVE_GLBINDTEXTURE
+       glBindTexture(GL_TEXTURE_2D, lc->texids[top ? FACE_U : FACE_D]);
+#endif /* HAVE_GLBINDTEXTURE */
+       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, exterior_color);
+
+       i = 1;
+       do_normal(points[i + 0][0], points[i + 0][1], 0,
+                 points[i + 4][0], points[i + 4][1], 0,
+                 points[i + 8][0], points[i + 8][1], 0);
+       glBegin(wire ? GL_LINE_LOOP : GL_POLYGON);
+       for (i = 1; i < countof(points); i += 4) {
+               GLfloat     x = points[i][0] / 255.0L;
+               GLfloat     y = points[i][1] / 255.0L;
+
+               glTexCoord2f(x, y);
+               glVertex3f(x - 0.5, y - 0.5, 0.5);
+       }
+       glEnd();
+
+
+       /* Central core bottom cap.
+        */
+#ifdef HAVE_GLBINDTEXTURE
+       glBindTexture(GL_TEXTURE_2D, 0);
+#endif /* HAVE_GLBINDTEXTURE */
+       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, interior_color);
+
+/* Range changed from "countof(points) - 3" to avoid Stack array bounds read */
+       i = countof(points) - 9;
+       do_normal(points[i + 0][0], points[i + 0][1], 0,
+                 points[i + 4][0], points[i + 4][1], 0,
+                 points[i + 8][0], points[i + 8][1], 0);
+
+       glBegin(wire ? GL_LINE_LOOP : GL_POLYGON);
+       for (i = countof(points) - 3; i >= 0; i -= 4) {
+               GLfloat     x = points[i][0] / 255.0L;
+               GLfloat     y = points[i][1] / 255.0L;
+
+               glVertex3f(x - 0.5, y - 0.5, 0);
+       }
+       glEnd();
+
+
+       /* Central core walls.
+        */
+       for (i = 1; i < countof(points); i += 4) {
+
+               GLfloat     x1 = points[i - 1][0] / 255.0L;
+               GLfloat     y1 = points[i - 1][1] / 255.0L;
+               GLfloat     x2 = points[i][0] / 255.0L;
+               GLfloat     y2 = points[i][1] / 255.0L;
+
+               face4(0, interior_color, wire,
+                     0.0, 0.0, x1 - 0.5, y1 - 0.5, 0.5,
+                     0.0, 0.0, x1 - 0.5, y1 - 0.5, 0.0,
+                     0.0, 0.0, x2 - 0.5, y2 - 0.5, 0.0,
+                     0.0, 0.0, x2 - 0.5, y2 - 0.5, 0.5);
+       }
+
+       glEndList();
+}
+
+
+static void
+tetra(ModeInfo * mi, Bool wire)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+
+       glNewList(lc->tetra_une, GL_COMPILE);
+       {
+               glShadeModel(GL_SMOOTH);
+
+               /* Ua */
+               face3(lc->texids[FACE_U], exterior_color, wire,
+                     1.0, 0.0, 0.5, -0.5, 0.5,
+                     1.0, 1.0, 0.5, 0.5, 0.5,
+                     0.0, 1.0, -0.5, 0.5, 0.5);
+
+               /* Na */
+               face3(lc->texids[FACE_N], exterior_color, wire,
+                     0.0, 0.0, -0.5, 0.5, 0.5,
+                     1.0, 0.0, 0.5, 0.5, 0.5,
+                     1.0, 1.0, 0.5, 0.5, -0.5);
+
+               /* Eb */
+               face3(lc->texids[FACE_E], exterior_color, wire,
+                     1.0, 0.0, 0.5, 0.5, -0.5,
+                     1.0, 1.0, 0.5, 0.5, 0.5,
+                     0.0, 1.0, 0.5, -0.5, 0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, 0.5, 0.5, -0.5,
+                     0.0, 0.0, 0.5, -0.5, 0.5,
+                     0.0, 0.0, -0.5, 0.5, 0.5);
+       }
+       glEndList();
+
+       glNewList(lc->tetra_usw, GL_COMPILE);
+       {
+               /* Ub */
+               face3(lc->texids[FACE_U], exterior_color, wire,
+                     0.0, 1.0, -0.5, 0.5, 0.5,
+                     0.0, 0.0, -0.5, -0.5, 0.5,
+                     1.0, 0.0, 0.5, -0.5, 0.5);
+
+               /* Sb */
+               face3(lc->texids[FACE_S], exterior_color, wire,
+                     1.0, 1.0, 0.5, -0.5, 0.5,
+                     0.0, 1.0, -0.5, -0.5, 0.5,
+                     0.0, 0.0, -0.5, -0.5, -0.5);
+
+               /* Wb */
+               face3(lc->texids[FACE_W], exterior_color, wire,
+                     1.0, 0.0, -0.5, -0.5, -0.5,
+                     1.0, 1.0, -0.5, -0.5, 0.5,
+                     0.0, 1.0, -0.5, 0.5, 0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, -0.5, -0.5, -0.5,
+                     0.0, 0.0, -0.5, 0.5, 0.5,
+                     0.0, 0.0, 0.5, -0.5, 0.5);
+       }
+       glEndList();
+
+       glNewList(lc->tetra_dwn, GL_COMPILE);
+       {
+               /* Db */
+               face3(lc->texids[FACE_D], exterior_color, wire,
+                     0.0, 1.0, -0.5, -0.5, -0.5,
+                     0.0, 0.0, -0.5, 0.5, -0.5,
+                     1.0, 0.0, 0.5, 0.5, -0.5);
+
+               /* Wa */
+               face3(lc->texids[FACE_W], exterior_color, wire,
+                     0.0, 1.0, -0.5, 0.5, 0.5,
+                     0.0, 0.0, -0.5, 0.5, -0.5,
+                     1.0, 0.0, -0.5, -0.5, -0.5);
+
+               /* Nb */
+               face3(lc->texids[FACE_N], exterior_color, wire,
+                     1.0, 1.0, 0.5, 0.5, -0.5,
+                     0.0, 1.0, -0.5, 0.5, -0.5,
+                     0.0, 0.0, -0.5, 0.5, 0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, 0.5, 0.5, -0.5,
+                     0.0, 0.0, -0.5, 0.5, 0.5,
+                     0.0, 0.0, -0.5, -0.5, -0.5);
+       }
+       glEndList();
+
+       glNewList(lc->tetra_dse, GL_COMPILE);
+       {
+               /* Sa */
+               face3(lc->texids[FACE_S], exterior_color, wire,
+                     0.0, 0.0, -0.5, -0.5, -0.5,
+                     1.0, 0.0, 0.5, -0.5, -0.5,
+                     1.0, 1.0, 0.5, -0.5, 0.5);
+
+               /* Ea */
+               face3(lc->texids[FACE_E], exterior_color, wire,
+                     0.0, 1.0, 0.5, -0.5, 0.5,
+                     0.0, 0.0, 0.5, -0.5, -0.5,
+                     1.0, 0.0, 0.5, 0.5, -0.5);
+
+               /* Da */
+               face3(lc->texids[FACE_D], exterior_color, wire,
+                     1.0, 0.0, 0.5, 0.5, -0.5,
+                     1.0, 1.0, 0.5, -0.5, -0.5,
+                     0.0, 1.0, -0.5, -0.5, -0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, 0.5, -0.5, 0.5,
+                     0.0, 0.0, 0.5, 0.5, -0.5,
+                     0.0, 0.0, -0.5, -0.5, -0.5);
+       }
+       glEndList();
+
+       glNewList(lc->tetra_mid, GL_COMPILE);
+       {
+               face3(0, interior_color, wire,
+                     0.0, 0.0, 0.5, -0.5, 0.5,
+                     0.0, 0.0, 0.5, 0.5, -0.5,
+                     0.0, 0.0, -0.5, 0.5, 0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, -0.5, 0.5, 0.5,
+                     0.0, 0.0, -0.5, -0.5, -0.5,
+                     0.0, 0.0, 0.5, -0.5, 0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, -0.5, 0.5, 0.5,
+                     0.0, 0.0, 0.5, 0.5, -0.5,
+                     0.0, 0.0, -0.5, -0.5, -0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, 0.5, 0.5, -0.5,
+                     0.0, 0.0, 0.5, -0.5, 0.5,
+                     0.0, 0.0, -0.5, -0.5, -0.5);
+
+               face3(0, interior_color, wire,
+                     0.0, 0.0, 0.5, -0.5, 0.5,
+                     0.0, 0.0, 0.5, 0.5, -0.5,
+                     0.0, 0.0, -0.5, -0.5, -0.5);
+       }
+       glEndList();
+
+}
+
+static void
+lid(ModeInfo * mi, Bool wire)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+       int         i;
+
+       int         points[][2] =
+       {
+               {128, 20},
+               {21, 129},
+               {0, 129},
+               {0, 0},
+               {128, 0},       /* L1 */
+               {21, 129},
+               {127, 234},
+               {127, 255},
+               {0, 255},
+               {0, 129},       /* L2 */
+               {127, 234},
+               {233, 127},
+               {255, 127},
+               {255, 255},
+               {127, 255},     /* R2 */
+               {233, 127},
+               {128, 20},
+               {128, 0},
+               {255, 0},
+               {255, 127},     /* R1 */
+       };
+
+       for (i = 0; i < countof(points); i++)
+               points[i][1] = 255 - points[i][1];
+
+       glNewList(lc->lid_0, GL_COMPILE);
+       glShadeModel(GL_SMOOTH);
+
+       /* N */
+       face4(lc->texids[FACE_N], exterior_color, wire,
+             0.0, 0.0, -0.5, 0.5, 0.5,
+             1.0, 0.0, 0.5, 0.5, 0.5,
+             1.0, 1.0, 0.5, 0.5, -0.5,
+             0.0, 1.0, -0.5, 0.5, -0.5);
+
+       /* S */
+       face4(lc->texids[FACE_S], exterior_color, wire,
+             0.0, 0.0, -0.5, -0.5, -0.5,
+             1.0, 0.0, 0.5, -0.5, -0.5,
+             1.0, 1.0, 0.5, -0.5, 0.5,
+             0.0, 1.0, -0.5, -0.5, 0.5);
+
+       /* E */
+       face4(lc->texids[FACE_E], exterior_color, wire,
+             0.0, 0.0, 0.5, -0.5, -0.5,
+             1.0, 0.0, 0.5, 0.5, -0.5,
+             1.0, 1.0, 0.5, 0.5, 0.5,
+             0.0, 1.0, 0.5, -0.5, 0.5);
+
+       /* U */
+       face4(lc->texids[FACE_U], exterior_color, wire,
+             1.0, 0.0, 0.5, -0.5, 0.5,
+             1.0, 1.0, 0.5, 0.5, 0.5,
+             0.0, 1.0, -0.5, 0.5, 0.5,
+             0.0, 0.0, -0.5, -0.5, 0.5);
+
+       /* D */
+       face4(lc->texids[FACE_D], exterior_color, wire,
+             0.0, 1.0, -0.5, -0.5, -0.5,
+             0.0, 0.0, -0.5, 0.5, -0.5,
+             1.0, 0.0, 0.5, 0.5, -0.5,
+             1.0, 1.0, 0.5, -0.5, -0.5);
+
+       /* W -- lid_0 */
+       for (i = 0; i < countof(points) / 5; i++) {
+               int         j;
+               GLfloat     s[5], t[5], x[5], y[5], z[5];
+
+               for (j = 0; j < 5; j++) {
+                       GLfloat     xx = points[(i * 5) + j][0] / 255.0L;
+                       GLfloat     yy = points[(i * 5) + j][1] / 255.0L;
+
+                       s[j] = 1.0 - xx;
+                       t[j] = yy;
+                       x[j] = -0.5;
+                       y[j] = xx - 0.5;
+                       z[j] = yy - 0.5;
+               }
+               face5(lc->texids[FACE_W], exterior_color, wire,
+                     s[0], t[0], x[0], y[0], z[0],
+                     s[1], t[1], x[1], y[1], z[1],
+                     s[2], t[2], x[2], y[2], z[2],
+                     s[3], t[3], x[3], y[3], z[3],
+                     s[4], t[4], x[4], y[4], z[4]);
+       }
+       glEndList();
+
+
+       /* W -- lid_1 through lid_4 */
+       for (i = 0; i < 4; i++) {
+               GLfloat     x1, y1, x2, y2, x3, y3;
+
+               glNewList(lc->lid_1 + i, GL_COMPILE);
+               glShadeModel(GL_SMOOTH);
+
+               x1 = points[(i * 5) + 1][0] / 255.0L;
+               y1 = points[(i * 5) + 1][1] / 255.0L;
+               x2 = points[(i * 5)][0] / 255.0L;
+               y2 = points[(i * 5)][1] / 255.0L;
+               x3 = 0.5;
+               y3 = 0.5;
+
+               /* Outer surface */
+               face3(lc->texids[FACE_W], exterior_color, wire,
+                     1.0 - x1, y1, -0.5, x1 - 0.5, y1 - 0.5,
+                     1.0 - x2, y2, -0.5, x2 - 0.5, y2 - 0.5,
+                     1.0 - x3, y3, -0.5, x3 - 0.5, y3 - 0.5);
+
+               /* Inner surface */
+               face3(0, interior_color, wire,
+                     0.0, 0.0, -0.48, x2 - 0.5, y2 - 0.5,
+                     0.0, 0.0, -0.48, x1 - 0.5, y1 - 0.5,
+                     0.0, 0.0, -0.48, x3 - 0.5, y3 - 0.5);
+
+               /* Lip 1 */
+               face4(0, interior_color, wire,
+                     0.0, 0.0, -0.5, x1 - 0.5, y1 - 0.5,
+                     0.0, 0.0, -0.5, x3 - 0.5, y3 - 0.5,
+                     0.0, 0.0, -0.48, x3 - 0.5, y3 - 0.5,
+                     0.0, 0.0, -0.48, x1 - 0.5, y1 - 0.5);
+
+               /* Lip 2 */
+               face4(0, interior_color, wire,
+                     0.0, 0.0, -0.48, x2 - 0.5, y2 - 0.5,
+                     0.0, 0.0, -0.48, x3 - 0.5, y3 - 0.5,
+                     0.0, 0.0, -0.5, x3 - 0.5, y3 - 0.5,
+                     0.0, 0.0, -0.5, x2 - 0.5, y2 - 0.5);
+
+               glEndList();
+       }
+}
+
+static void
+taser(ModeInfo * mi, Bool wire)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+       int         i;
+
+       int         slider_face_points[][2] =
+       {
+               {86, 58},
+               {38, 106},
+               {70, 106},
+               {118, 58},
+               {-1, -1},       /* a */
+               {136, 58},
+               {184, 106},
+               {216, 106},
+               {168, 58},
+               {-1, -1},       /* b */
+               {38, 106},
+               {0, 144},
+               {0, 190},
+               {60, 190},
+               {108, 106},     /* c */
+               {144, 106},
+               {194, 190},
+               {254, 190},
+               {254, 144},
+               {216, 106},     /* d */
+               {98, 124},
+               {60, 190},
+               {92, 190},
+               {126, 158},
+               {126, 124},     /* e */
+               {126, 124},
+               {126, 158},
+               {160, 190},
+               {194, 190},
+               {154, 124},     /* f */
+               {22, 190},
+               {22, 254},
+               {60, 254},
+               {60, 190},
+               {-1, -1},       /* g */
+               {194, 190},
+               {194, 254},
+               {230, 254},
+               {230, 190},
+               {-1, -1},       /* h */
+               {60, 190},
+               {60, 210},
+               {92, 210},
+               {92, 190},
+               {-1, -1},       /* i */
+               {160, 190},
+               {160, 210},
+               {194, 210},
+               {194, 190},
+               {-1, -1},       /* j */
+               {110, 172},
+               {92, 190},
+               {110, 190},
+               {-1, -1},
+               {-1, -1},       /* k */
+               {140, 172},
+               {140, 190},
+               {160, 190},
+               {-1, -1},
+               {-1, -1},       /* l */
+               {110, 172},
+               {140, 172},
+               {126, 156},
+               {-1, -1},
+               {-1, -1},       /* m */
+       };
+
+       int         body_face_points[][2] =
+       {
+               {0, 0},
+               {0, 58},
+               {254, 58},
+               {254, 0},
+               {-1, -1},       /* A */
+               {0, 58},
+               {0, 144},
+               {86, 58},
+               {-1, -1},
+               {-1, -1},       /* B */
+               {168, 58},
+               {254, 144},
+               {254, 58},
+               {-1, -1},
+               {-1, -1},       /* C */
+               {118, 58},
+               {70, 106},
+               {184, 106},
+               {136, 58},
+               {-1, -1},       /* F */
+               {108, 106},
+               {98, 124},
+               {154, 124},
+               {144, 106},
+               {-1, -1},       /* G */
+       };
+
+       int         lifter_face_points[][2] =
+       {
+               {0, 190},
+               {0, 254},
+               {22, 254},
+               {22, 190},
+               {-1, -1},       /* D */
+               {230, 190},
+               {230, 254},
+               {254, 254},
+               {254, 190},
+               {-1, -1},       /* E */
+               {60, 210},
+               {60, 254},
+               {194, 254},
+               {194, 210},
+               {-1, -1},       /* H */
+               {92, 190},
+               {92, 210},
+               {160, 210},
+               {160, 190},
+               {-1, -1},       /* I */
+               {110, 172},
+               {110, 190},
+               {140, 190},
+               {140, 172},
+               {-1, -1},       /* J */
+       };
+
+       int         body_perimiter_points[][2] =
+       {
+               {0, 144},
+               {86, 59},
+               {119, 58},
+               {71, 107},
+               {108, 107},
+               {98, 124},
+               {155, 124},
+               {144, 107},
+               {185, 106},
+               {136, 59},
+               {169, 59},
+               {255, 145},
+               {255, 0},
+               {0, 0},
+       };
+
+       int         slider_perimiter_points[][2] =
+       {
+               {86, 58},
+               {0, 144},
+               {0, 190},
+               {22, 190},
+               {22, 254},
+               {60, 254},
+               {60, 210},
+               {92, 210},
+               {92, 190},
+               {110, 190},
+               {110, 172},
+               {140, 172},
+               {140, 190},
+               {160, 190},
+               {160, 210},
+               {194, 210},
+               {194, 254},
+               {230, 254},
+               {230, 190},
+               {254, 190},
+               {254, 144},
+               {168, 58},
+               {136, 58},
+               {184, 106},
+               {144, 106},
+               {154, 124},
+               {98, 124},
+               {108, 106},
+               {70, 106},
+               {118, 58},
+       };
+
+       int         lifter_perimiter_points_1[][2] =
+       {
+               {0, 189},
+               {0, 254},
+               {22, 255},
+               {23, 190},
+       };
+
+       int         lifter_perimiter_points_2[][2] =
+       {
+               {230, 254},
+               {255, 255},
+               {254, 190},
+               {230, 190},
+       };
+
+       int         lifter_perimiter_points_3[][2] =
+       {
+               {60, 254},
+               {194, 254},
+               {194, 211},
+               {160, 210},
+               {160, 190},
+               {140, 191},
+               {141, 172},
+               {111, 172},
+               {110, 190},
+               {93, 190},
+               {92, 210},
+               {60, 211},
+       };
+
+       for (i = 0; i < countof(slider_face_points); i++)
+               slider_face_points[i][1] = 255 - slider_face_points[i][1];
+       for (i = 0; i < countof(body_face_points); i++)
+               body_face_points[i][1] = 255 - body_face_points[i][1];
+       for (i = 0; i < countof(lifter_face_points); i++)
+               lifter_face_points[i][1] = 255 - lifter_face_points[i][1];
+       for (i = 0; i < countof(body_perimiter_points); i++)
+               body_perimiter_points[i][1] = 255 - body_perimiter_points[i][1];
+       for (i = 0; i < countof(slider_perimiter_points); i++)
+               slider_perimiter_points[i][1] = 255 - slider_perimiter_points[i][1];
+       for (i = 0; i < countof(lifter_perimiter_points_1); i++)
+               lifter_perimiter_points_1[i][1] = 255 - lifter_perimiter_points_1[i][1];
+       for (i = 0; i < countof(lifter_perimiter_points_2); i++)
+               lifter_perimiter_points_2[i][1] = 255 - lifter_perimiter_points_2[i][1];
+       for (i = 0; i < countof(lifter_perimiter_points_3); i++)
+               lifter_perimiter_points_3[i][1] = 255 - lifter_perimiter_points_3[i][1];
+
+       /* -------------------------------------------------------------------- */
+
+       glNewList(lc->taser_base, GL_COMPILE);
+       glShadeModel(GL_SMOOTH);
+
+       /* N */
+       face4(lc->texids[FACE_N], exterior_color, wire,
+             0.0, 0.0, -0.5, 0.5, 0.5,
+             0.75, 0.0, 0.25, 0.5, 0.5,
+             0.75, 0.75, 0.25, 0.5, -0.25,
+             0.0, 0.75, -0.5, 0.5, -0.25);
+
+       /* S */
+       face4(lc->texids[FACE_S], exterior_color, wire,
+             0.0, 0.25, -0.5, -0.5, -0.25,
+             0.75, 0.25, 0.25, -0.5, -0.25,
+             0.75, 1.0, 0.25, -0.5, 0.5,
+             0.0, 1.0, -0.5, -0.5, 0.5);
+
+       /* interior E */
+       face4(0, interior_color, wire,
+             0.0, 0.0, 0.25, -0.5, -0.25,
+             1.0, 0.0, 0.25, 0.5, -0.25,
+             1.0, 1.0, 0.25, 0.5, 0.5,
+             0.0, 1.0, 0.25, -0.5, 0.5);
+
+       /* W */
+       face4(lc->texids[FACE_W], exterior_color, wire,
+             1.0, 1.0, -0.5, -0.5, 0.5,
+             0.0, 1.0, -0.5, 0.5, 0.5,
+             0.0, 0.25, -0.5, 0.5, -0.25,
+             1.0, 0.25, -0.5, -0.5, -0.25);
+
+       /* U */
+       face4(lc->texids[FACE_U], exterior_color, wire,
+             0.75, 0.0, 0.25, -0.5, 0.5,
+             0.75, 1.0, 0.25, 0.5, 0.5,
+             0.0, 1.0, -0.5, 0.5, 0.5,
+             0.0, 0.0, -0.5, -0.5, 0.5);
+
+       /* interior D */
+       face4(0, interior_color, wire,
+             0.0, 1.0, -0.5, -0.5, -0.25,
+             0.0, 0.0, -0.5, 0.5, -0.25,
+             1.0, 0.0, 0.25, 0.5, -0.25,
+             1.0, 1.0, 0.25, -0.5, -0.25);
+
+       /* Top face */
+       for (i = 0; i < countof(body_face_points) / 5; i++) {
+               int         j;
+
+#ifdef HAVE_GLBINDTEXTURE
+               glBindTexture(GL_TEXTURE_2D, lc->texids[FACE_E]);
+#endif /* HAVE_GLBINDTEXTURE */
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, exterior_color);
+
+               do_normal(0, body_face_points[(i * 5) + 0][0], body_face_points[(i * 5) + 0][1],
+                         0, body_face_points[(i * 5) + 1][0], body_face_points[(i * 5) + 1][1],
+                         0, body_face_points[(i * 5) + 2][0], body_face_points[(i * 5) + 2][1]
+                       );
+               glBegin(wire ? GL_LINE_LOOP : GL_POLYGON);
+               for (j = 0; j < 5; j++) {
+                       int         ix = body_face_points[(i * 5) + j][0];
+                       int         iy = body_face_points[(i * 5) + j][1];
+                       GLfloat     x, y;
+
+                       if (ix == -1)   /* these are padding: ignore them */
+                               continue;
+                       x = ix / 255.0L;
+                       y = iy / 255.0L;
+                       glTexCoord2f(x, y);
+                       glVertex3f(0.5, x - 0.5, y - 0.5);
+               }
+               glEnd();
+       }
+
+       /* Side walls */
+       for (i = 0; i < countof(body_perimiter_points); i++) {
+               int         j = (i + 1 >= countof(body_perimiter_points) ? 0 : i + 1);
+               GLfloat     x1 = body_perimiter_points[i][0] / 255.0;
+               GLfloat     y1 = body_perimiter_points[i][1] / 255.0;
+               GLfloat     x2 = body_perimiter_points[j][0] / 255.0;
+               GLfloat     y2 = body_perimiter_points[j][1] / 255.0;
+               int         texture = -1;
+               GLfloat     s1 = 0, t1 = 0, s2 = 0, t2 = 0, s3 = 0, t3 = 0,
+                           s4 = 0, t4 = 0;
+
+               if (i == 11) {
+                       texture = lc->texids[FACE_N];
+                       s1 = 1.0;
+                       t1 = 0.0;
+                       s2 = 1.0;
+                       t2 = 0.568;
+                       s3 = 0.75, t3 = 0.568;
+                       s4 = 0.75;
+                       t4 = 0.0;
+               } else if (i == 12) {
+                       texture = lc->texids[FACE_U];
+                       s1 = 1.0;
+                       t1 = 0.0;
+                       s2 = 1.0;
+                       t2 = 1.0;
+                       s3 = 0.75, t3 = 1.0;
+                       s4 = 0.75;
+                       t4 = 0.0;
+               } else if (i == 13) {
+                       texture = lc->texids[FACE_S];
+                       s1 = 1.0;
+                       t1 = 0.437;
+                       s2 = 1.0;
+                       t2 = 1.0;
+                       s3 = 0.75;
+                       t3 = 1.0;
+                       s4 = 0.75;
+                       t4 = 0.437;
+               }
+               face4((texture == -1 ? 0 : texture),
+                     (texture == -1 ? interior_color : exterior_color),
+                     wire,
+                     s1, t1, 0.5, x2 - 0.5, y2 - 0.5,
+                     s2, t2, 0.5, x1 - 0.5, y1 - 0.5,
+                     s3, t3, 0.25, x1 - 0.5, y1 - 0.5,
+                     s4, t4, 0.25, x2 - 0.5, y2 - 0.5);
+       }
+
+       glEndList();
+
+       /* -------------------------------------------------------------------- */
+
+       glNewList(lc->taser_lifter, GL_COMPILE);
+       glShadeModel(GL_SMOOTH);
+
+       /* N */
+       face4(lc->texids[FACE_N], exterior_color, wire,
+             0.0, 0.75, -0.5, 0.5, -0.25,
+             0.75, 0.75, 0.25, 0.5, -0.25,
+             0.75, 1.0, 0.25, 0.5, -0.5,
+             0.0, 1.0, -0.5, 0.5, -0.5);
+
+       /* S */
+       face4(lc->texids[FACE_S], exterior_color, wire,
+             0.0, 0.0, -0.5, -0.5, -0.5,
+             0.75, 0.0, 0.25, -0.5, -0.5,
+             0.75, 0.25, 0.25, -0.5, -0.25,
+             0.0, 0.25, -0.5, -0.5, -0.25);
+
+       /* interior E */
+       face4(0, interior_color, wire,
+             0.0, 1.0, 0.25, -0.5, -0.5,
+             1.0, 1.0, 0.25, 0.5, -0.5,
+             1.0, 0.0, 0.25, 0.5, -0.25,
+             0.0, 0.0, 0.25, -0.5, -0.25);
+
+       /* W */
+       face4(lc->texids[FACE_W], exterior_color, wire,
+             1.0, 0.25, -0.5, -0.5, -0.25,
+             0.0, 0.25, -0.5, 0.5, -0.25,
+             0.0, 0.0, -0.5, 0.5, -0.5,
+             1.0, 0.0, -0.5, -0.5, -0.5);
+
+       /* interior U */
+       face4(0, interior_color, wire,
+             1.0, 0.0, 0.25, -0.5, -0.25,
+             1.0, 1.0, 0.25, 0.5, -0.25,
+             0.0, 1.0, -0.5, 0.5, -0.25,
+             0.0, 0.0, -0.5, -0.5, -0.25);
+
+       /* D */
+       face4(lc->texids[FACE_D], exterior_color, wire,
+             0.0, 1.0, -0.5, -0.5, -0.5,
+             0.0, 0.0, -0.5, 0.5, -0.5,
+             0.75, 0.0, 0.25, 0.5, -0.5,
+             0.75, 1.0, 0.25, -0.5, -0.5);
+
+
+       /* Top face */
+       for (i = 0; i < countof(lifter_face_points) / 5; i++) {
+               int         j;
+
+#ifdef HAVE_GLBINDTEXTURE
+               glBindTexture(GL_TEXTURE_2D, lc->texids[FACE_E]);
+#endif /* HAVE_GLBINDTEXTURE */
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, exterior_color);
+
+               do_normal(
+                                0, lifter_face_points[(i * 5) + 0][0], lifter_face_points[(i * 5) + 0][1],
+                                0, lifter_face_points[(i * 5) + 1][0], lifter_face_points[(i * 5) + 1][1],
+                                0, lifter_face_points[(i * 5) + 2][0], lifter_face_points[(i * 5) + 2][1]);
+
+               glBegin(wire ? GL_LINE_LOOP : GL_POLYGON);
+               for (j = 0; j < 5; j++) {
+                       int         ix = lifter_face_points[(i * 5) + j][0];
+                       int         iy = lifter_face_points[(i * 5) + j][1];
+                       GLfloat     x, y;
+
+                       if (ix == -1)   /* these are padding: ignore them */
+                               continue;
+                       x = ix / 255.0L;
+                       y = iy / 255.0L;
+                       glTexCoord2f(x, y);
+                       glVertex3f(0.5, x - 0.5, y - 0.5);
+               }
+               glEnd();
+       }
+
+       /* Side walls */
+       for (i = 0; i < countof(lifter_perimiter_points_1); i++) {
+               int         j = (i + 1 >= countof(lifter_perimiter_points_1) ? 0 : i + 1);
+               GLfloat     x1 = lifter_perimiter_points_1[i][0] / 255.0;
+               GLfloat     y1 = lifter_perimiter_points_1[i][1] / 255.0;
+               GLfloat     x2 = lifter_perimiter_points_1[j][0] / 255.0;
+               GLfloat     y2 = lifter_perimiter_points_1[j][1] / 255.0;
+               int         texture = -1;
+               GLfloat     s1 = 0, t1 = 0, s2 = 0, t2 = 0, s3 = 0, t3 = 0,
+                           s4 = 0, t4 = 0;
+
+               if (i == 0) {
+                       texture = lc->texids[FACE_S];
+                       s1 = 1.0;
+                       t1 = 0.0;
+                       s2 = 1.0;
+                       t2 = 0.26;
+                       s3 = 0.75, t3 = 0.26;
+                       s4 = 0.75;
+                       t4 = 0.0;
+               } else if (i == 1) {
+                       texture = lc->texids[FACE_D];
+                       s1 = 1.0;
+                       t1 = 0.914;
+                       s2 = 1.0;
+                       t2 = 1.0;
+                       s3 = 0.75;
+                       t3 = 1.0;
+                       s4 = 0.75;
+                       t4 = 0.914;
+               }
+               face4((texture == -1 ? 0 : texture),
+                     (texture == -1 ? interior_color : exterior_color),
+                     wire,
+                     s1, t1, 0.5, x2 - 0.5, y2 - 0.5,
+                     s2, t2, 0.5, x1 - 0.5, y1 - 0.5,
+                     s3, t3, 0.25, x1 - 0.5, y1 - 0.5,
+                     s4, t4, 0.25, x2 - 0.5, y2 - 0.5);
+       }
+
+       for (i = 0; i < countof(lifter_perimiter_points_2); i++) {
+               int         j = (i + 1 >= countof(lifter_perimiter_points_2) ? 0 : i + 1);
+               GLfloat     x1 = lifter_perimiter_points_2[i][0] / 255.0;
+               GLfloat     y1 = lifter_perimiter_points_2[i][1] / 255.0;
+               GLfloat     x2 = lifter_perimiter_points_2[j][0] / 255.0;
+               GLfloat     y2 = lifter_perimiter_points_2[j][1] / 255.0;
+               int         texture = -1;
+               GLfloat     s1 = 0, t1 = 0, s2 = 0, t2 = 0, s3 = 0, t3 = 0,
+                           s4 = 0, t4 = 0;
+
+               if (i == 0) {
+                       texture = lc->texids[FACE_D];
+                       s1 = 1.0;
+                       t1 = 0.0;
+                       s2 = 1.0;
+                       t2 = 0.095;
+                       s3 = 0.75;
+                       t3 = 0.095;
+                       s4 = 0.75;
+                       t4 = 0.0;
+               } else if (i == 1) {
+                       texture = lc->texids[FACE_N];
+                       s1 = 1.0;
+                       t1 = 0.745;
+                       s2 = 1.0;
+                       t2 = 1.0;
+                       s3 = 0.75;
+                       t3 = 1.0;
+                       s4 = 0.75;
+                       t4 = 0.745;
+               }
+               face4((texture == -1 ? 0 : texture),
+                     (texture == -1 ? interior_color : exterior_color),
+                     wire,
+                     s1, t1, 0.5, x2 - 0.5, y2 - 0.5,
+                     s2, t2, 0.5, x1 - 0.5, y1 - 0.5,
+                     s3, t3, 0.25, x1 - 0.5, y1 - 0.5,
+                     s4, t4, 0.25, x2 - 0.5, y2 - 0.5);
+       }
+
+       for (i = 0; i < countof(lifter_perimiter_points_3); i++) {
+               int         j = (i + 1 >= countof(lifter_perimiter_points_3) ? 0 : i + 1);
+               GLfloat     x1 = lifter_perimiter_points_3[i][0] / 255.0;
+               GLfloat     y1 = lifter_perimiter_points_3[i][1] / 255.0;
+               GLfloat     x2 = lifter_perimiter_points_3[j][0] / 255.0;
+               GLfloat     y2 = lifter_perimiter_points_3[j][1] / 255.0;
+               int         texture = -1;
+               GLfloat     s1 = 0, t1 = 0, s2 = 0, t2 = 0, s3 = 0, t3 = 0,
+                           s4 = 0, t4 = 0;
+
+               if (i == 0) {
+                       texture = lc->texids[FACE_D];
+                       s1 = 1.0;
+                       t1 = 0.235;
+                       s2 = 1.0;
+                       t2 = 0.765;
+                       s3 = 0.75;
+                       t3 = 0.765;
+                       s4 = 0.75;
+                       t4 = 0.235;
+               }
+               face4((texture == -1 ? 0 : texture),
+                     (texture == -1 ? interior_color : exterior_color),
+                     wire,
+                     s1, t1, 0.5, x2 - 0.5, y2 - 0.5,
+                     s2, t2, 0.5, x1 - 0.5, y1 - 0.5,
+                     s3, t3, 0.25, x1 - 0.5, y1 - 0.5,
+                     s4, t4, 0.25, x2 - 0.5, y2 - 0.5);
+       }
+
+       glEndList();
+
+       /* -------------------------------------------------------------------- */
+
+       glNewList(lc->taser_slider, GL_COMPILE);
+       glShadeModel(GL_SMOOTH);
+
+       /* Top face */
+       for (i = 0; i < countof(slider_face_points) / 5; i++) {
+               int         j;
+
+#ifdef HAVE_GLBINDTEXTURE
+               glBindTexture(GL_TEXTURE_2D, lc->texids[FACE_E]);
+#endif /* HAVE_GLBINDTEXTURE */
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, exterior_color);
+
+               do_normal(
+                                0, slider_face_points[(i * 5) + 0][0], slider_face_points[(i * 5) + 0][1],
+                                0, slider_face_points[(i * 5) + 1][0], slider_face_points[(i * 5) + 1][1],
+                                0, slider_face_points[(i * 5) + 2][0], slider_face_points[(i * 5) + 2][1]);
+               glBegin(wire ? GL_LINE_LOOP : GL_POLYGON);
+               for (j = 0; j < 5; j++) {
+                       int         ix = slider_face_points[(i * 5) + j][0];
+                       int         iy = slider_face_points[(i * 5) + j][1];
+                       GLfloat     x, y;
+
+                       if (ix == -1)   /* these are padding: ignore them */
+                               continue;
+                       x = ix / 255.0L;
+                       y = iy / 255.0L;
+                       glTexCoord2f(x, y);
+                       glVertex3f(0.5, x - 0.5, y - 0.5);
+               }
+               glEnd();
+       }
+
+       /* Bottom face */
+       for (i = countof(slider_face_points) / 5 - 1; i >= 0; i--) {
+               int         j;
+
+#ifdef HAVE_GLBINDTEXTURE
+               glBindTexture(GL_TEXTURE_2D, 0);
+#endif /* HAVE_GLBINDTEXTURE */
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, interior_color);
+
+               do_normal(
+                                0, slider_face_points[(i * 5) + 2][0], slider_face_points[(i * 5) + 2][1],
+                                0, slider_face_points[(i * 5) + 1][0], slider_face_points[(i * 5) + 1][1],
+                                0, slider_face_points[(i * 5) + 0][0], slider_face_points[(i * 5) + 0][1]);
+               glBegin(wire ? GL_LINE_LOOP : GL_POLYGON);
+               for (j = 4; j >= 0; j--) {
+                       int         ix = slider_face_points[(i * 5) + j][0];
+                       int         iy = slider_face_points[(i * 5) + j][1];
+                       GLfloat     x, y;
+
+                       if (ix == -1)   /* these are padding: ignore them */
+                               continue;
+                       x = ix / 255.0L;
+                       y = iy / 255.0L;
+                       glTexCoord2f(x, y);
+                       glVertex3f(0.25, x - 0.5, y - 0.5);
+               }
+               glEnd();
+       }
+
+       /* Side walls */
+       for (i = 0; i < countof(slider_perimiter_points); i++) {
+               int         j = (i + 1 >= countof(slider_perimiter_points) ? 0 : i + 1);
+               GLfloat     x1 = slider_perimiter_points[i][0] / 255.0;
+               GLfloat     y1 = slider_perimiter_points[i][1] / 255.0;
+               GLfloat     x2 = slider_perimiter_points[j][0] / 255.0;
+               GLfloat     y2 = slider_perimiter_points[j][1] / 255.0;
+               int         texture = -1;
+               GLfloat     s1 = 0, t1 = 0, s2 = 0, t2 = 0, s3 = 0, t3 = 0,
+                           s4 = 0, t4 = 0;
+
+               if (i == 1) {
+                       texture = lc->texids[FACE_S];
+                       s1 = 1.0;
+                       t1 = 0.255;
+                       s2 = 1.0;
+                       t2 = 0.435;
+                       s3 = 0.75;
+                       t3 = 0.435;
+                       s4 = 0.75;
+                       t4 = 0.255;
+               } else if (i == 4) {
+                       texture = lc->texids[FACE_D];
+                       s1 = 1.0;
+                       t1 = 0.758;
+                       s2 = 1.0;
+                       t2 = 0.915;
+                       s3 = 0.75;
+                       t3 = 0.915;
+                       s4 = 0.75;
+                       t4 = 0.758;
+               } else if (i == 16) {
+                       texture = lc->texids[FACE_D];
+                       s1 = 1.0;
+                       t1 = 0.095;
+                       s2 = 1.0;
+                       t2 = 0.24;
+                       s3 = 0.75;
+                       t3 = 0.24;
+                       s4 = 0.75;
+                       t4 = 0.095;
+               } else if (i == 19) {
+                       texture = lc->texids[FACE_N];
+                       s1 = 1.0;
+                       t1 = 0.568;
+                       s2 = 1.0;
+                       t2 = 0.742;
+                       s3 = 0.75;
+                       t3 = 0.742;
+                       s4 = 0.75;
+                       t4 = 0.568;
+               }
+               face4((texture == -1 ? 0 : texture),
+                     (texture == -1 ? interior_color : exterior_color),
+                     wire,
+                     s1, t1, 0.5, x2 - 0.5, y2 - 0.5,
+                     s2, t2, 0.5, x1 - 0.5, y1 - 0.5,
+                     s3, t3, 0.25, x1 - 0.5, y1 - 0.5,
+                     s4, t4, 0.25, x2 - 0.5, y2 - 0.5);
+       }
+
+       glEndList();
+}
+\f
+
+
+/* Rendering and animating object models
+ */
+
+static void
+draw(ModeInfo * mi)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+       Bool        wire = MI_IS_WIREFRAME(mi);
+
+       if (!wire)
+               glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+       else
+               glClear(GL_COLOR_BUFFER_BIT);
+
+       glPushMatrix();
+       {
+               GLfloat     x = lc->rotx;
+               GLfloat     y = lc->roty;
+               GLfloat     z = lc->rotz;
+
+#if 0
+               x = 0.75;
+               y = 0;
+               z = 0;
+#endif
+
+               if (x < 0)
+                       x = 1 - (x + 1);
+               if (y < 0)
+                       y = 1 - (y + 1);
+               if (z < 0)
+                       z = 1 - (z + 1);
+
+               /* Make into the screen be +Y right be +X, and up be +Z. */
+               glRotatef(-90.0, 1.0, 0.0, 0.0);
+
+               /* Scale it up. */
+               glScalef(4.0, 4.0, 4.0);
+
+#ifdef DEBUG
+               glPushMatrix();
+               {
+                       /* Shift to the upper left, and draw the vanilla box. */
+                       glTranslatef(-0.6, 0.0, 0.6);
+
+                       /* Apply rotation to the object. */
+                       glRotatef(x * 360, 1.0, 0.0, 0.0);
+                       glRotatef(y * 360, 0.0, 1.0, 0.0);
+                       glRotatef(z * 360, 0.0, 0.0, 1.0);
+
+                       /* Draw it. */
+                       glCallList(lc->box);
+               }
+               glPopMatrix();
+
+               /* Shift to the lower right, and draw the animated object. */
+               glTranslatef(0.6, 0.0, -0.6);
+#endif /* DEBUG */
+
+
+               glPushMatrix();
+               {
+                       /* Apply rotation to the object. */
+                       glRotatef(x * 360, 1.0, 0.0, 0.0);
+                       glRotatef(y * 360, 0.0, 1.0, 0.0);
+                       glRotatef(z * 360, 0.0, 0.0, 1.0);
+
+                       switch (lc->type) {
+                               case LAMENT_BOX:
+                                       glCallList(lc->box);
+                                       break;
+
+                               case LAMENT_STAR_OUT:
+                               case LAMENT_STAR_ROT:
+                               case LAMENT_STAR_ROT_IN:
+                               case LAMENT_STAR_ROT_OUT:
+                               case LAMENT_STAR_UNROT:
+                               case LAMENT_STAR_IN:
+                                       glTranslatef(0.0, 0.0, lc->anim_z / 2);
+                                       glRotatef(lc->anim_r / 2, 0.0, 0.0, 1.0);
+                                       glCallList(lc->star1);
+
+                                       glTranslatef(0.0, 0.0, -lc->anim_z);
+                                       glRotatef(-lc->anim_r, 0.0, 0.0, 1.0);
+                                       glCallList(lc->star2);
+                                       break;
+
+                               case LAMENT_TETRA_UNE:
+                               case LAMENT_TETRA_USW:
+                               case LAMENT_TETRA_DWN:
+                               case LAMENT_TETRA_DSE:
+                                       {
+                                               unsigned int         magic;
+                                               GLfloat     tx, ty, tz;
+
+                                               switch (lc->type) {
+                                                       case LAMENT_TETRA_UNE:
+                                                               magic = lc->tetra_une;
+                                                               tx = 1.0;
+                                                               ty = 1.0;
+                                                               tz = 1.0;
+                                                               break;
+                                                       case LAMENT_TETRA_USW:
+                                                               magic = lc->tetra_usw;
+                                                               tx = 1.0;
+                                                               ty = 1.0;
+                                                               tz = -1.0;
+                                                               break;
+                                                       case LAMENT_TETRA_DWN:
+                                                               magic = lc->tetra_dwn;
+                                                               tx = 1.0;
+                                                               ty = -1.0;
+                                                               tz = 1.0;
+                                                               break;
+                                                       case LAMENT_TETRA_DSE:
+                                                               magic = lc->tetra_dse;
+                                                               tx = -1.0;
+                                                               ty = 1.0;
+                                                               tz = 1.0;
+                                                               break;
+                                                       default:
+                                                               abort();
+                                                               break;
+                                               }
+                                               glCallList(lc->tetra_mid);
+                                               if (magic != lc->tetra_une)
+                                                       glCallList(lc->tetra_une);
+                                               if (magic != lc->tetra_usw)
+                                                       glCallList(lc->tetra_usw);
+                                               if (magic != lc->tetra_dwn)
+                                                       glCallList(lc->tetra_dwn);
+                                               if (magic != lc->tetra_dse)
+                                                       glCallList(lc->tetra_dse);
+                                               glRotatef(lc->anim_r, tx, ty, tz);
+                                               glCallList(magic);
+                                       }
+                                       break;
+
+                               case LAMENT_LID_OPEN:
+                               case LAMENT_LID_CLOSE:
+                               case LAMENT_LID_ZOOM:
+                                       {
+                                               GLfloat     d = 0.417;
+
+                                               glTranslatef(lc->anim_z, 0.0, 0.0);
+
+                                               glCallList(lc->lid_0);
+
+                                               glPushMatrix();
+                                               glTranslatef(-0.5, -d, 0.0);
+                                               glRotatef(-lc->anim_r, 0.0, -1.0, -1.0);
+                                               glTranslatef(0.5, d, 0.0);
+                                               glCallList(lc->lid_1);
+                                               glPopMatrix();
+                                               glPushMatrix();
+                                               glTranslatef(-0.5, -d, 0.0);
+                                               glRotatef(lc->anim_r, 0.0, -1.0, 1.0);
+                                               glTranslatef(0.5, d, 0.0);
+                                               glCallList(lc->lid_2);
+                                               glPopMatrix();
+                                               glPushMatrix();
+                                               glTranslatef(-0.5, d, 0.0);
+                                               glRotatef(lc->anim_r, 0.0, -1.0, -1.0);
+                                               glTranslatef(0.5, -d, 0.0);
+                                               glCallList(lc->lid_3);
+                                               glPopMatrix();
+                                               glPushMatrix();
+                                               glTranslatef(-0.5, d, 0.0);
+                                               glRotatef(-lc->anim_r, 0.0, -1.0, 1.0);
+                                               glTranslatef(0.5, -d, 0.0);
+                                               glCallList(lc->lid_4);
+                                               glPopMatrix();
+                                       }
+                                       break;
+
+                               case LAMENT_TASER_OUT:
+                               case LAMENT_TASER_SLIDE:
+                               case LAMENT_TASER_SLIDE_IN:
+                               case LAMENT_TASER_IN:
+
+                                       glTranslatef(-lc->anim_z / 2, 0.0, 0.0);
+                                       glCallList(lc->taser_base);
+
+                                       glTranslatef(lc->anim_z, 0.0, 0.0);
+                                       glCallList(lc->taser_lifter);
+
+                                       glTranslatef(0.0, 0.0, lc->anim_y);
+                                       glCallList(lc->taser_slider);
+                                       break;
+
+                               default:
+                                       abort();
+                                       break;
+                       }
+               }
+               glPopMatrix();
+
+       }
+       glPopMatrix();
+}
+
+
+static void
+animate(ModeInfo * mi)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+       int         pause1 = 10;
+
+/*  int pause2 = 60; */
+       int         pause3 = 120;
+
+       switch (lc->type) {
+               case LAMENT_BOX:
+                       {
+                               /* Rather than just picking states randomly, pick an ordering randomly,
+                                  do it, and then re-randomize.  That way one can be assured of seeing
+                                  all states in a short time period, though not always in the same
+                                  order (it's frustrating to see it pick the same state 5x in a row.)
+                                */
+                               static lament_type states[] =
+                               {
+                                       LAMENT_STAR_OUT, LAMENT_STAR_OUT,
+                                       LAMENT_TETRA_UNE, LAMENT_TETRA_USW,
+                                       LAMENT_TETRA_DWN, LAMENT_TETRA_DSE,
+                                       LAMENT_LID_OPEN, LAMENT_LID_OPEN, LAMENT_LID_OPEN,
+                                       LAMENT_TASER_OUT, LAMENT_TASER_OUT,
+                                       LAMENT_BOX, LAMENT_BOX, LAMENT_BOX, LAMENT_BOX, LAMENT_BOX,
+                                       LAMENT_BOX, LAMENT_BOX, LAMENT_BOX, LAMENT_BOX, LAMENT_BOX,
+                               };
+                               static int  state = countof(states);
+
+                               if (state < countof(states)) {
+                                       lc->type = states[state++];
+                               } else {
+                                       int         i;
+
+                                       state = 0;
+                                       for (i = 0; i < countof(states); i++) {
+                                               int         a = LRAND() % countof(states);
+                                               lament_type swap = states[a];
+
+                                               states[a] = states[i];
+                                               states[i] = swap;
+                                       }
+                               }
+
+                               if (lc->type == LAMENT_BOX)
+                                       lc->anim_pause = pause3;
+
+                               lc->anim_r = 0.0;
+                               lc->anim_y = 0.0;
+                               lc->anim_z = 0.0;
+                       }
+                       break;
+
+                       /* -------------------------------------------------------------- */
+
+               case LAMENT_STAR_OUT:
+                       lc->anim_z += 0.01;
+                       if (lc->anim_z >= 1.0) {
+                               lc->anim_z = 1.0;
+                               lc->type = LAMENT_STAR_ROT;
+                               lc->anim_pause = pause1;
+                       }
+                       break;
+
+               case LAMENT_STAR_ROT:
+                       lc->anim_r += 1.0;
+                       if (lc->anim_r >= 45.0) {
+                               lc->anim_r = 45.0;
+                               lc->type = LAMENT_STAR_ROT_IN;
+                               lc->anim_pause = pause1;
+                       }
+                       break;
+
+               case LAMENT_STAR_ROT_IN:
+                       lc->anim_z -= 0.01;
+                       if (lc->anim_z <= 0.0) {
+                               lc->anim_z = 0.0;
+                               lc->type = LAMENT_STAR_ROT_OUT;
+                               lc->anim_pause = pause3 * (1 + (LRAND() % 4) + (LRAND() % 4));
+                       }
+                       break;
+
+               case LAMENT_STAR_ROT_OUT:
+                       lc->anim_z += 0.01;
+                       if (lc->anim_z >= 1.0) {
+                               lc->anim_z = 1.0;
+                               lc->type = LAMENT_STAR_UNROT;
+                               lc->anim_pause = pause1;
+                       }
+                       break;
+
+               case LAMENT_STAR_UNROT:
+                       lc->anim_r -= 1.0;
+                       if (lc->anim_r <= 0.0) {
+                               lc->anim_r = 0.0;
+                               lc->type = LAMENT_STAR_IN;
+                               lc->anim_pause = pause1;
+                       }
+                       break;
+
+               case LAMENT_STAR_IN:
+                       lc->anim_z -= 0.01;
+                       if (lc->anim_z <= 0.0) {
+                               lc->anim_z = 0.0;
+                               lc->type = LAMENT_BOX;
+                               lc->anim_pause = pause3;
+                       }
+                       break;
+
+                       /* -------------------------------------------------------------- */
+
+               case LAMENT_TETRA_UNE:
+               case LAMENT_TETRA_USW:
+               case LAMENT_TETRA_DWN:
+               case LAMENT_TETRA_DSE:
+
+                       lc->anim_r += 1.0;
+                       if (lc->anim_r >= 360.0) {
+                               lc->anim_r = 0.0;
+                               lc->type = LAMENT_BOX;
+                               lc->anim_pause = pause3;
+                       } else if (lc->anim_r > 119.0 && lc->anim_r <= 120.0) {
+                               lc->anim_r = 120.0;
+                               lc->anim_pause = pause1;
+                       } else if (lc->anim_r > 239.0 && lc->anim_r <= 240.0) {
+                               lc->anim_r = 240.0;
+                               lc->anim_pause = pause1;
+                       }
+                       break;
+
+                       /* -------------------------------------------------------------- */
+
+               case LAMENT_LID_OPEN:
+                       lc->anim_r += 1.0;
+
+                       if (lc->anim_r >= 112.0) {
+                               GLfloat     hysteresis = 0.05;
+
+                               lc->anim_r = 112.0;
+                               lc->anim_z = 0.0;
+                               lc->anim_pause = pause3;
+
+                               if (lc->rotx >= -hysteresis &&
+                                   lc->rotx <= hysteresis &&
+                                   ((lc->rotz >= (0.25 - hysteresis) &&
+                                     lc->rotz <= (0.25 + hysteresis)) ||
+                                    (lc->rotz >= (-0.25 - hysteresis) &&
+                                     lc->rotz <= (-0.25 + hysteresis)))) {
+                                       lc->type = LAMENT_LID_ZOOM;
+                                       lc->rotx = 0.00;
+                                       lc->rotz = (lc->rotz < 0 ? -0.25 : 0.25);
+                               } else {
+                                       lc->type = LAMENT_LID_CLOSE;
+                               }
+                       }
+                       break;
+
+               case LAMENT_LID_CLOSE:
+                       lc->anim_r -= 1.0;
+                       if (lc->anim_r <= 0.0) {
+                               lc->anim_r = 0.0;
+                               lc->type = LAMENT_BOX;
+                               lc->anim_pause = pause3;
+                       }
+                       break;
+
+               case LAMENT_LID_ZOOM:
+                       lc->anim_z -= 0.1;
+                       if (lc->anim_z < -50.0) {
+                               lc->anim_r = 0.0;
+                               lc->anim_z = 0.0;
+                               lc->rotx = FLOATRAND(1.0) * RANDSIGN();
+                               lc->roty = FLOATRAND(1.0) * RANDSIGN();
+                               lc->rotz = FLOATRAND(1.0) * RANDSIGN();
+                               lc->type = LAMENT_BOX;
+                       }
+                       break;
+
+                       /* -------------------------------------------------------------- */
+
+               case LAMENT_TASER_OUT:
+                       lc->anim_z += 0.0025;
+                       if (lc->anim_z >= 0.25) {
+                               lc->anim_z = 0.25;
+                               lc->type = LAMENT_TASER_SLIDE;
+                               lc->anim_pause = pause1 * (1 + (LRAND() % 5) + (LRAND() % 5));
+                       }
+                       break;
+
+               case LAMENT_TASER_SLIDE:
+                       lc->anim_y += 0.0025;
+                       if (lc->anim_y >= 0.23) {
+                               lc->anim_y = 0.23;
+                               lc->type = LAMENT_TASER_SLIDE_IN;
+                               lc->anim_pause = pause3 * (1 + (LRAND() % 5) + (LRAND() % 5));
+                       }
+                       break;
+
+               case LAMENT_TASER_SLIDE_IN:
+                       lc->anim_y -= 0.0025;
+                       if (lc->anim_y <= 0.0) {
+                               lc->anim_y = 0.0;
+                               lc->type = LAMENT_TASER_IN;
+                               lc->anim_pause = pause1;
+                       }
+                       break;
+
+               case LAMENT_TASER_IN:
+                       lc->anim_z -= 0.0025;
+                       if (lc->anim_z <= 0.0) {
+                               lc->anim_z = 0.0;
+                               lc->type = LAMENT_BOX;
+                               lc->anim_pause = pause3;
+                       }
+                       break;
+
+               default:
+                       abort();
+                       break;
+       }
+}
+
+
+static void
+rotate(GLfloat * pos, GLfloat * v, GLfloat * dv, GLfloat max_v)
+{
+       double      ppos = *pos;
+
+       /* tick position */
+       if (ppos < 0)
+               ppos = -(ppos + *v);
+       else
+               ppos += *v;
+
+       if (ppos > 1.0)
+               ppos -= 1.0;
+       else if (ppos < 0)
+               ppos += 1.0;
+
+       if (ppos < 0)
+               abort();
+       if (ppos > 1.0)
+               abort();
+       *pos = (*pos > 0 ? ppos : -ppos);
+
+       /* accelerate */
+       *v += *dv;
+
+       /* clamp velocity */
+       if (*v > max_v || *v < -max_v) {
+               *dv = -*dv;
+       }
+       /* If it stops, start it going in the other direction. */
+       else if (*v < 0) {
+               if (LRAND() % 4) {
+                       *v = 0;
+
+                       /* keep going in the same direction */
+                       if (LRAND() % 2)
+                               *dv = 0;
+                       else if (*dv < 0)
+                               *dv = -*dv;
+               } else {
+                       /* reverse gears */
+                       *v = -*v;
+                       *dv = -*dv;
+                       *pos = -*pos;
+               }
+       }
+       /* Alter direction of rotational acceleration randomly. */
+       if (!(LRAND() % 120))
+               *dv = -*dv;
+
+       /* Change acceleration very occasionally. */
+       if (!(LRAND() % 200)) {
+               if (*dv == 0)
+                       *dv = 0.00001;
+               else if (LRAND() & 1)
+                       *dv *= 1.2;
+               else
+                       *dv *= 0.8;
+       }
+}
+\f
+
+
+/* Window management, etc
+ */
+
+static void
+reshape(int width, int height)
+{
+       int         target_size = 180;
+       int         win_size = (width > height ? height : width);
+       GLfloat     h = (GLfloat) height / (GLfloat) width;
+
+       glViewport(0, 0, (GLint) width, (GLint) height);
+
+/*  glViewport(-600, -600, 1800, 1800); */
+
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       glFrustum(-1.0, 1.0, -h, h, 5.0, 60.0);
+       glMatrixMode(GL_MODELVIEW);
+       glLoadIdentity();
+       glTranslatef(0.0, 0.0, -40.0);
+
+       /* This scale makes the box take up most of the window */
+       glScalef(2.0, 2.0, 2.0);
+
+       /* But if the window is more than a little larger than our target size,
+          scale the object back down, so that the bits drawn on the screen end
+          up rougly target_size across (actually it ends up a little larger.)
+          Note that the image-map bits we have are 128x128.  Therefore, if the
+          image is magnified a lot, it looks pretty blocky.  So it's better to
+          have a 128x128 animation on a 1280x1024 screen that looks good, than
+          a 1024x1024 animation that looks really pixellated.
+        */
+       if (win_size > target_size * 1.5) {
+               GLfloat     ratio = ((GLfloat) target_size / (GLfloat) win_size);
+
+               ratio *= 2.0;
+               glScalef(ratio, ratio, ratio);
+       }
+       /* The depth buffer will be cleared, if needed, before the
+        * next frame.  Right now we just want to black the screen.
+        */
+       glClear(GL_COLOR_BUFFER_BIT);
+}
+
+
+static void
+gl_init(ModeInfo * mi)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+       Bool        wire = MI_IS_WIREFRAME(mi);
+
+       if (wire)
+               do_texture = False;
+
+       if (!wire) {
+               static GLfloat pos0[] =
+               {-4.0, 2.0, 5.0, 1.0};
+               static GLfloat pos1[] =
+               {12.0, 5.0, 1.0, 1.0};
+               static GLfloat local[] =
+               {0.0};
+               static GLfloat ambient[] =
+               {0.3, 0.3, 0.3, 1.0};
+               static GLfloat spec[] =
+               {1.0, 1.0, 1.0, 1.0};
+               static GLfloat shine[] =
+               {100.0};
+
+               glLightfv(GL_LIGHT0, GL_POSITION, pos0);
+               glLightfv(GL_LIGHT1, GL_POSITION, pos1);
+
+               glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+               glLightfv(GL_LIGHT1, GL_AMBIENT, ambient);
+
+               glLightfv(GL_LIGHT0, GL_SPECULAR, spec);
+               glLightfv(GL_LIGHT1, GL_SPECULAR, spec);
+
+               glLightModelfv(GL_LIGHT_MODEL_LOCAL_VIEWER, local);
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, exterior_color);
+               glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+               glMaterialfv(GL_FRONT, GL_SHININESS, shine);
+
+               glEnable(GL_LIGHTING);
+               glEnable(GL_LIGHT0);
+               glEnable(GL_LIGHT1);
+               glDisable(GL_LIGHT1);
+
+               glEnable(GL_DEPTH_TEST);
+               glEnable(GL_TEXTURE_2D);
+               glEnable(GL_NORMALIZE);
+               glEnable(GL_CULL_FACE);
+       }
+       if (do_texture) {
+#ifdef HAVE_GLBINDTEXTURE
+               int         i;
+#if ((MESA_MAJOR_VERSION < 3 ) || (( MESA_MAJOR_VERSION == 3 ) && (MESA_MINOR_VERSION == 0 )))
+               /* E.Lassauge - 11/23/98
+                * It looks like there's a bug in MESA (up to 3.1beta1) for the
+                * "Default" texture (named '0'). For this texture
+                * I added a glBindTexture and the same glTexParameteri
+                * as for the specific textures. Now it does'nt core
+                * anymore.
+                * 
+                * 22-mar-99 for latest version of Mesa this codes wipes
+                * out the structure on the sides of the cube. Leaving the code
+                * out did not crash the mode on my VMS system.
+                *      Jouk
+                */
+               glBindTexture(GL_TEXTURE_2D, 0);
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, interior_color);
+               glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
+               glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);
+               glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+               glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+               glTexGeni(GL_S, GL_TEXTURE_GEN_MODE, GL_OBJECT_LINEAR);
+               glTexGeni(GL_T, GL_TEXTURE_GEN_MODE, GL_OBJECT_LINEAR);
+#endif /* MESA */
+
+               for (i = 0; i < 6; i++)
+                       glGenTextures(1, &lc->texids[i]);
+
+               parse_image_data(mi);
+
+               glPixelStorei(GL_UNPACK_ALIGNMENT, 4);
+               glPixelStorei(GL_UNPACK_ROW_LENGTH, lc->texture->width);
+
+               for (i = 0; i < 6; i++) {
+                       int         height = lc->texture->width;        /* assume square */
+
+                       glBindTexture(GL_TEXTURE_2D, lc->texids[i]);
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, exterior_color);
+                       glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA,
+                                    lc->texture->width, height, 0,
+                                    GL_RGBA, GL_UNSIGNED_BYTE,
+                                    (lc->texture->data +
+                               (lc->texture->bytes_per_line * height * i)));
+
+                       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
+                       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);
+                       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+                       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+                       glTexGeni(GL_S, GL_TEXTURE_GEN_MODE, GL_OBJECT_LINEAR);
+                       glTexGeni(GL_T, GL_TEXTURE_GEN_MODE, GL_OBJECT_LINEAR);
+               }
+
+#else /* !HAVE_GLBINDTEXTURE */
+               (void) fprintf(stderr,
+               "this version of GL does not support multiple texture maps.\n"
+                              "\tGet OpenGL 1.1.\n");
+               return;
+#endif /* !HAVE_GLBINDTEXTURE */
+       }
+       lc->box = glGenLists(16);
+       lc->star1 = lc->box + 1;
+       lc->star2 = lc->box + 2;
+       lc->tetra_une = lc->box + 3;
+       lc->tetra_usw = lc->box + 4;
+       lc->tetra_dwn = lc->box + 5;
+       lc->tetra_dse = lc->box + 6;
+       lc->tetra_mid = lc->box + 7;
+       lc->lid_0 = lc->box + 8;
+       lc->lid_1 = lc->box + 9;
+       lc->lid_2 = lc->box + 10;
+       lc->lid_3 = lc->box + 11;
+       lc->lid_4 = lc->box + 12;
+       lc->taser_base = lc->box + 13;
+       lc->taser_lifter = lc->box + 14;
+       lc->taser_slider = lc->box + 15;
+
+       box(mi, wire);
+       star(mi, True, wire);
+       star(mi, False, wire);
+       tetra(mi, wire);
+       lid(mi, wire);
+       taser(mi, wire);
+}
+
+
+void
+init_lament(ModeInfo * mi)
+{
+       lament_configuration *lc;
+
+       if (!lcs) {
+               lcs = (lament_configuration *)
+                       calloc(MI_NUM_SCREENS(mi), sizeof (lament_configuration));
+               if (!lcs) {
+                       (void) fprintf(stderr, "out of memory\n");
+                       return;
+               }
+       }
+       lc = &lcs[MI_SCREEN(mi)];
+
+       lc->rotx = FLOATRAND(1.0) * RANDSIGN();
+       lc->roty = FLOATRAND(1.0) * RANDSIGN();
+       lc->rotz = FLOATRAND(1.0) * RANDSIGN();
+
+       /* bell curve from 0-1.5 degrees, avg 0.75 */
+       lc->dx = (FLOATRAND(1) + FLOATRAND(1) + FLOATRAND(1)) / (360 * 2);
+       lc->dy = (FLOATRAND(1) + FLOATRAND(1) + FLOATRAND(1)) / (360 * 2);
+       lc->dz = (FLOATRAND(1) + FLOATRAND(1) + FLOATRAND(1)) / (360 * 2);
+
+       lc->d_max = lc->dx * 2;
+
+       lc->ddx = 0.00006 + FLOATRAND(0.00003);
+       lc->ddy = 0.00006 + FLOATRAND(0.00003);
+       lc->ddz = 0.00006 + FLOATRAND(0.00003);
+
+       lc->ddx = 0.00001;
+       lc->ddy = 0.00001;
+       lc->ddz = 0.00001;
+
+       lc->type = LAMENT_BOX;
+       lc->anim_pause = 300 + (LRAND() % 100);
+
+       if ((lc->glx_context = init_GL(mi)) != NULL) {
+               reshape(MI_WIDTH(mi), MI_HEIGHT(mi));
+               gl_init(mi);
+       }
+}
+
+
+void
+draw_lament(ModeInfo * mi)
+{
+       static int  tick = 0;
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       if (!lc->glx_context)
+               return;
+
+       glDrawBuffer(GL_BACK);
+
+       glXMakeCurrent(display, window, *(lc->glx_context));
+       draw(mi);
+       glFinish();
+       glXSwapBuffers(display, window);
+
+       if (lc->type != LAMENT_LID_ZOOM) {
+               rotate(&lc->rotx, &lc->dx, &lc->ddx, lc->d_max);
+               rotate(&lc->roty, &lc->dy, &lc->ddy, lc->d_max);
+               rotate(&lc->rotz, &lc->dz, &lc->ddz, lc->d_max);
+       }
+       if (lc->anim_pause)
+               lc->anim_pause--;
+       else
+               animate(mi);
+
+       if (++tick > 500) {
+               tick = 0;
+               reshape(MI_WIDTH(mi), MI_HEIGHT(mi));
+       }
+}
+
+void
+change_lament(ModeInfo * mi)
+{
+       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+
+       if (!lc->glx_context)
+               return;
+       /* probably something needs to be added here */
+}
+
+void
+release_lament(ModeInfo * mi)
+{
+       if (lcs != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       lament_configuration *lc = &lcs[MI_SCREEN(mi)];
+
+                       if (lc->texture)
+                               XDestroyImage(lc->texture);
+                       if (lc->glx_context) {
+                               glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(lc->glx_context));
+
+                               if (glIsList(lc->box))
+                                       glDeleteLists(lc->box, 16);
+                       }
+               }
+               (void) free((void *) lcs);
+               lcs = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/moebius.c b/xlockmore-4.14/modes/glx/moebius.c
new file mode 100644 (file)
index 0000000..b9d3ecf
--- /dev/null
@@ -0,0 +1,709 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* moebius --- Moebius Strip II, an Escher-like GL scene with ants. */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)moebius.c    4.08 97/01/04 xlockmore";
+
+#endif
+
+#undef DEBUG_LISTS
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The RotateAroundU() routine was adapted from the book
+ *    "Computer Graphics Principles and Practice 
+ *     Foley - vanDam - Feiner - Hughes
+ *     Second Edition" Pag. 227, exercise 5.15.
+ * 
+ * This mode shows some interesting scenes that are impossible OR very
+ * wierd to build in the real universe. Much of the scenes are inspirated
+ * on Mauritz Cornelis Escher's works which derivated the mode's name.
+ * M.C. Escher (1898-1972) was a dutch artist and many people prefer to
+ * say he was a mathematician.
+ *
+ * Thanks goes to Brian Paul for making it possible and inexpensive to use 
+ * OpenGL at home.
+ *
+ * Since I'm not a native English speaker, my apologies for any grammatical
+ * mistake.
+ *
+ * My e-mail address is
+ * m-vianna@usa.net
+ *
+ * Marcelo F. Vianna (Jun-01-1997)
+ *
+ * Revision History:
+ * 01-Jan-98: Mode separated from escher and renamed
+ * 08-Jun-97: New scene implemented: "Impossible Cage" based in a M.C. Escher's
+ *            painting with the same name (quite similar). The first GL mode
+ *            to use texture mapping.
+ *            The "Impossible Cage" scene doesn't use DEPTH BUFFER, the 
+ *            wood planks are drawn consistently using GL_CULL_FACE, and
+ *            the painter's algorithm is used to sort the planks.
+ *            Marcelo F. Vianna.
+ * 07-Jun-97: Speed ups in Moebius Strip using GL_CULL_FACE.
+ *            Marcelo F. Vianna.
+ * 03-Jun-97: Initial Release (Only one scene: "Moebius Strip")
+ *            The Moebius Strip scene was inspirated in a M.C. Escher's
+ *            painting named Moebius Strip II in wich ants walk across a
+ *            Moebius Strip path, sometimes meeting each other and sometimes
+ *            being in "opposite faces" (note that the moebius strip has
+ *            only one face and one edge).
+ *            Marcelo F. Vianna.
+ *
+ */
+
+/*-
+ * Texture mapping is only available on RGBA contexts, Mono and color index
+ * visuals DO NOT support texture mapping in OpenGL.
+ *
+ * BUT Mesa do implements RGBA contexts in pseudo color visuals, so texture
+ * mapping shuld work on PseudoColor, DirectColor, TrueColor using Mesa. Mono
+ * is not officially supported for both OpenGL and Mesa, but seems to not crash
+ * Mesa.
+ *
+ * In real OpenGL, PseudoColor DO NOT support texture map (as far as I know).
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Moebius"
+#define HACK_INIT init_moebius
+#define HACK_DRAW draw_moebius
+#define moebius_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_moebius
+
+
+#include <GL/glu.h>
+#include "e_textures.h"
+
+#define DEF_SOLIDMOEBIUS  "False"
+#define DEF_NOANTS  "False"
+
+static int  solidmoebius;
+static int  noants;
+
+static XrmOptionDescRec opts[] =
+{
+  {"-solidmoebius", ".moebius.solidmoebius", XrmoptionNoArg, (caddr_t) "on"},
+ {"+solidmoebius", ".moebius.solidmoebius", XrmoptionNoArg, (caddr_t) "off"},
+       {"-noants", ".moebius.noants", XrmoptionNoArg, (caddr_t) "on"},
+       {"+noants", ".moebius.noants", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & solidmoebius, "solidmoebius", "Solidmoebius", DEF_SOLIDMOEBIUS, t_Bool},
+       {(caddr_t *) & noants, "noants", "Noants", DEF_NOANTS, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+solidmoebius", "select between a SOLID or a NET Moebius Strip"},
+       {"-/+noants", "turn on/off walking ants"}
+};
+
+ModeSpecOpt moebius_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   moebius_description =
+{"moebius", "init_moebius", "draw_moebius", "release_moebius",
+ "draw_moebius", "change_moebius", NULL, &moebius_opts,
+ 1000, 1, 1, 1, 4, 1.0, "",
+ "Shows Moebius Strip II, an Escher-like GL scene with ants", 0, NULL};
+
+#endif
+
+#define Scale4Window               0.3
+#define Scale4Iconic               0.4
+
+#define sqr(A)                     ((A)*(A))
+
+#ifndef Pi
+#define Pi                         M_PI
+#endif
+
+/*************************************************************************/
+
+typedef struct {
+       GLint       WindH, WindW;
+       GLfloat     step;
+       GLfloat     ant_position;
+       int         AreObjectsDefined[2];
+       GLXContext *glx_context;
+} moebiusstruct;
+
+static float front_shininess[] =
+{60.0};
+static float front_specular[] =
+{0.7, 0.7, 0.7, 1.0};
+static float ambient[] =
+{0.0, 0.0, 0.0, 1.0};
+static float diffuse[] =
+{1.0, 1.0, 1.0, 1.0};
+static float position0[] =
+{1.0, 1.0, 1.0, 0.0};
+static float position1[] =
+{-1.0, -1.0, 1.0, 0.0};
+static float lmodel_ambient[] =
+{0.5, 0.5, 0.5, 1.0};
+static float lmodel_twoside[] =
+{GL_TRUE};
+
+static float MaterialRed[] =
+{0.7, 0.0, 0.0, 1.0};
+static float MaterialGreen[] =
+{0.1, 0.5, 0.2, 1.0};
+static float MaterialBlue[] =
+{0.0, 0.0, 0.7, 1.0};
+static float MaterialCyan[] =
+{0.2, 0.5, 0.7, 1.0};
+static float MaterialYellow[] =
+{0.7, 0.7, 0.0, 1.0};
+static float MaterialMagenta[] =
+{0.6, 0.2, 0.5, 1.0};
+static float MaterialWhite[] =
+{0.7, 0.7, 0.7, 1.0};
+static float MaterialGray[] =
+{0.2, 0.2, 0.2, 1.0};
+static float MaterialGray5[] =
+{0.5, 0.5, 0.5, 1.0};
+static float MaterialGray6[] =
+{0.6, 0.6, 0.6, 1.0};
+static float MaterialGray8[] =
+{0.8, 0.8, 0.8, 1.0};
+
+static moebiusstruct *moebius = NULL;
+static GLuint objects;
+
+#define NUM_SCENES      2
+
+#define ObjMoebiusStrip 0
+#define ObjAntBody      1
+
+static void
+mySphere(float radius)
+{
+       GLUquadricObj *quadObj;
+
+       quadObj = gluNewQuadric();
+       gluQuadricDrawStyle(quadObj, (GLenum) GLU_FILL);
+       gluSphere(quadObj, radius, 16, 16);
+       gluDeleteQuadric(quadObj);
+}
+
+static void
+myCone(float radius)
+{
+       GLUquadricObj *quadObj;
+
+       quadObj = gluNewQuadric();
+       gluQuadricDrawStyle(quadObj, (GLenum) GLU_FILL);
+       gluCylinder(quadObj, radius, 0, radius * 3, 8, 1);
+       gluDeleteQuadric(quadObj);
+}
+
+static void
+draw_moebius_ant(moebiusstruct * mp, float *Material, int mono)
+{
+       static float ant_step = 0;
+       float       cos1 = cos(ant_step);
+       float       cos2 = cos(ant_step + 2 * Pi / 3);
+       float       cos3 = cos(ant_step + 4 * Pi / 3);
+       float       sin1 = sin(ant_step);
+       float       sin2 = sin(ant_step + 2 * Pi / 3);
+       float       sin3 = sin(ant_step + 4 * Pi / 3);
+
+       if (mono)
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray5);
+       else
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, Material);
+       if (!mp->AreObjectsDefined[ObjAntBody]) {
+               glNewList(objects + ObjAntBody, GL_COMPILE_AND_EXECUTE);
+               glEnable(GL_CULL_FACE);
+               glPushMatrix();
+               glScalef(1, 1.3, 1);
+               mySphere(0.18);
+               glScalef(1, 1 / 1.3, 1);
+               glTranslatef(0.00, 0.30, 0.00);
+               mySphere(0.2);
+
+               glTranslatef(-0.05, 0.17, 0.05);
+               glRotatef(-90, 1, 0, 0);
+               glRotatef(-25, 0, 1, 0);
+               myCone(0.05);
+               glTranslatef(0.00, 0.10, 0.00);
+               myCone(0.05);
+               glRotatef(25, 0, 1, 0);
+               glRotatef(90, 1, 0, 0);
+
+               glScalef(1, 1.3, 1);
+               glTranslatef(0.15, -0.65, 0.05);
+               mySphere(0.25);
+               glScalef(1, 1 / 1.3, 1);
+               glPopMatrix();
+               glDisable(GL_CULL_FACE);
+               glEndList();
+               mp->AreObjectsDefined[ObjAntBody] = 1;
+#ifdef DEBUG_LISTS
+               (void) printf("Ant drawn SLOWLY\n");
+#endif
+       } else {
+               glCallList(objects + ObjAntBody);
+#ifdef DEBUG_LISTS
+               (void) printf("Ant drawn quickly\n");
+#endif
+       }
+
+       glDisable(GL_LIGHTING);
+       /* ANTENNAS */
+       glBegin(GL_LINES);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, 0.30, 0.00);
+       glColor3fv(MaterialGray);
+       glVertex3f(0.40, 0.70, 0.40);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, 0.30, 0.00);
+       glColor3fv(MaterialGray);
+       glVertex3f(0.40, 0.70, -0.40);
+       glEnd();
+       glBegin(GL_POINTS);
+       if (mono)
+               glColor3fv(MaterialGray6);
+       else
+               glColor3fv(MaterialRed);
+       glVertex3f(0.40, 0.70, 0.40);
+       glVertex3f(0.40, 0.70, -0.40);
+       glEnd();
+
+       /* LEFT-FRONT ARM */
+       glBegin(GL_LINE_STRIP);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, 0.05, 0.18);
+       glVertex3f(0.35 + 0.05 * cos1, 0.15, 0.25);
+       glColor3fv(MaterialGray);
+       glVertex3f(-0.20 + 0.05 * cos1, 0.25 + 0.1 * sin1, 0.45);
+       glEnd();
+
+       /* LEFT-CENTER ARM */
+       glBegin(GL_LINE_STRIP);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, 0.00, 0.18);
+       glVertex3f(0.35 + 0.05 * cos2, 0.00, 0.25);
+       glColor3fv(MaterialGray);
+       glVertex3f(-0.20 + 0.05 * cos2, 0.00 + 0.1 * sin2, 0.45);
+       glEnd();
+
+       /* LEFT-BACK ARM */
+       glBegin(GL_LINE_STRIP);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, -0.05, 0.18);
+       glVertex3f(0.35 + 0.05 * cos3, -0.15, 0.25);
+       glColor3fv(MaterialGray);
+       glVertex3f(-0.20 + 0.05 * cos3, -0.25 + 0.1 * sin3, 0.45);
+       glEnd();
+
+       /* RIGHT-FRONT ARM */
+       glBegin(GL_LINE_STRIP);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, 0.05, -0.18);
+       glVertex3f(0.35 - 0.05 * sin1, 0.15, -0.25);
+       glColor3fv(MaterialGray);
+       glVertex3f(-0.20 - 0.05 * sin1, 0.25 + 0.1 * cos1, -0.45);
+       glEnd();
+
+       /* RIGHT-CENTER ARM */
+       glBegin(GL_LINE_STRIP);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, 0.00, -0.18);
+       glVertex3f(0.35 - 0.05 * sin2, 0.00, -0.25);
+       glColor3fv(MaterialGray);
+       glVertex3f(-0.20 - 0.05 * sin2, 0.00 + 0.1 * cos2, -0.45);
+       glEnd();
+
+       /* RIGHT-BACK ARM */
+       glBegin(GL_LINE_STRIP);
+       if (mono)
+               glColor3fv(MaterialGray5);
+       else
+               glColor3fv(Material);
+       glVertex3f(0.00, -0.05, -0.18);
+       glVertex3f(0.35 - 0.05 * sin3, -0.15, -0.25);
+       glColor3fv(MaterialGray);
+       glVertex3f(-0.20 - 0.05 * sin3, -0.25 + 0.1 * cos3, -0.45);
+       glEnd();
+
+       glBegin(GL_POINTS);
+       if (mono)
+               glColor3fv(MaterialGray8);
+       else
+               glColor3fv(MaterialMagenta);
+       glVertex3f(-0.20 + 0.05 * cos1, 0.25 + 0.1 * sin1, 0.45);
+       glVertex3f(-0.20 + 0.05 * cos2, 0.00 + 0.1 * sin2, 0.45);
+       glVertex3f(-0.20 + 0.05 * cos3, -0.25 + 0.1 * sin3, 0.45);
+       glVertex3f(-0.20 - 0.05 * sin1, 0.25 + 0.1 * cos1, -0.45);
+       glVertex3f(-0.20 - 0.05 * sin2, 0.00 + 0.1 * cos2, -0.45);
+       glVertex3f(-0.20 - 0.05 * sin3, -0.25 + 0.1 * cos3, -0.45);
+       glEnd();
+
+       glEnable(GL_LIGHTING);
+
+       ant_step += 0.3;
+}
+
+static void
+RotateAaroundU(float Ax, float Ay, float Az,
+              float Ux, float Uy, float Uz,
+              float *Cx, float *Cy, float *Cz,
+              float Theta)
+{
+       float       cosO = cos(Theta);
+       float       sinO = sin(Theta);
+       float       one_cosO = 1 - cosO;
+       float       Ux2 = sqr(Ux);
+       float       Uy2 = sqr(Uy);
+       float       Uz2 = sqr(Uz);
+       float       UxUy = Ux * Uy;
+       float       UxUz = Ux * Uz;
+       float       UyUz = Uy * Uz;
+
+       *Cx = (Ux2 + cosO * (1 - Ux2)) * Ax + (UxUy * one_cosO - Uz * sinO) * Ay + (UxUz * one_cosO + Uy * sinO) * Az;
+       *Cy = (UxUy * one_cosO + Uz * sinO) * Ax + (Uy2 + cosO * (1 - Uy2)) * Ay + (UyUz * one_cosO - Ux * sinO) * Az;
+       *Cz = (UxUz * one_cosO - Uy * sinO) * Ax + (UyUz * one_cosO + Ux * sinO) * Ay + (Uz2 + cosO * (1 - Uz2)) * Az;
+}
+
+#define MoebiusDivisions 40
+#define MoebiusTransversals 4
+static void
+draw_moebius_strip(ModeInfo * mi)
+{
+       GLfloat     Phi, Theta;
+       GLfloat     cPhi, sPhi;
+       moebiusstruct *mp = &moebius[MI_SCREEN(mi)];
+       int         i, j;
+       int         mono = MI_IS_MONO(mi);
+
+       float       Cx, Cy, Cz;
+
+       if (!mp->AreObjectsDefined[ObjMoebiusStrip]) {
+               glNewList(objects + ObjMoebiusStrip, GL_COMPILE_AND_EXECUTE);
+
+               if (solidmoebius) {
+                       glBegin(GL_QUAD_STRIP);
+                       Phi = 0;
+                       i = 0;
+                       while (i < (MoebiusDivisions * 2 + 1)) {
+                               Theta = Phi / 2;
+                               cPhi = cos(Phi);
+                               sPhi = sin(Phi);
+
+                               i++;
+                               if (mono)
+                                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialWhite);
+                               else if (i % 2)
+                                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialRed);
+                               else
+                                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+
+                               RotateAaroundU(cPhi, sPhi, 0, -sPhi, cPhi, 0, &Cx, &Cy, &Cz, Theta);
+                               glNormal3f(Cx, Cy, Cz);
+                               RotateAaroundU(0, 0, 1, -sPhi, cPhi, 0, &Cx, &Cy, &Cz, Theta);
+                               glVertex3f(cPhi * 3 + Cx, sPhi * 3 + Cy, +Cz);
+                               glVertex3f(cPhi * 3 - Cx, sPhi * 3 - Cy, -Cz);
+
+                               Phi += Pi / MoebiusDivisions;
+                       }
+                       glEnd();
+               } else {
+                       for (j = -MoebiusTransversals; j < MoebiusTransversals; j++) {
+                               glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
+                               glBegin(GL_QUAD_STRIP);
+                               Phi = 0;
+                               i = 0;
+                               while (i < (MoebiusDivisions * 2 + 1)) {
+                                       Theta = Phi / 2;
+                                       cPhi = cos(Phi);
+                                       sPhi = sin(Phi);
+
+                                       RotateAaroundU(cPhi, sPhi, 0, -sPhi, cPhi, 0, &Cx, &Cy, &Cz, Theta);
+                                       glNormal3f(Cx, Cy, Cz);
+                                       RotateAaroundU(0, 0, 1, -sPhi, cPhi, 0, &Cx, &Cy, &Cz, Theta);
+                                       j++;
+                                       if (j == MoebiusTransversals || mono)
+                                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialWhite);
+                                       else if (i % 2)
+                                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialRed);
+                                       else
+                                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+                                       glVertex3f(cPhi * 3 + Cx / MoebiusTransversals * j, sPhi * 3 + Cy / MoebiusTransversals * j, +Cz / MoebiusTransversals * j);
+                                       j--;
+                                       if (j == -MoebiusTransversals || mono)
+                                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialWhite);
+                                       else if (i % 2)
+                                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialRed);
+                                       else
+                                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+                                       glVertex3f(cPhi * 3 + Cx / MoebiusTransversals * j, sPhi * 3 + Cy / MoebiusTransversals * j, +Cz / MoebiusTransversals * j);
+
+                                       Phi += Pi / MoebiusDivisions;
+                                       i++;
+                               }
+                               glEnd();
+                       }
+                       glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
+               }
+
+               glEndList();
+               mp->AreObjectsDefined[ObjMoebiusStrip] = 1;
+#ifdef DEBUG_LISTS
+               (void) printf("Strip drawn SLOWLY\n");
+#endif
+       } else {
+               glCallList(objects + ObjMoebiusStrip);
+#ifdef DEBUG_LISTS
+               (void) printf("Strip drawn quickly\n");
+#endif
+       }
+
+       if (!noants) {
+               /* DRAW BLUE ANT */
+               glPushMatrix();
+               glRotatef(mp->ant_position + 180, 0, 0, 1);
+               glTranslatef(3, 0, 0);
+               glRotatef(mp->ant_position / 2 + 90, 0, 1, 0);
+               glTranslatef(0.28, 0, -0.45);
+               draw_moebius_ant(mp, MaterialYellow, mono);
+               glPopMatrix();
+
+               /* DRAW YELLOW ANT */
+               glPushMatrix();
+               glRotatef(mp->ant_position, 0, 0, 1);
+               glTranslatef(3, 0, 0);
+               glRotatef(mp->ant_position / 2, 0, 1, 0);
+               glTranslatef(0.28, 0, -0.45);
+               draw_moebius_ant(mp, MaterialBlue, mono);
+               glPopMatrix();
+
+               /* DRAW GREEN ANT */
+               glPushMatrix();
+               glRotatef(-mp->ant_position, 0, 0, 1);
+               glTranslatef(3, 0, 0);
+               glRotatef(-mp->ant_position / 2, 0, 1, 0);
+               glTranslatef(0.28, 0, 0.45);
+               glRotatef(180, 1, 0, 0);
+               draw_moebius_ant(mp, MaterialGreen, mono);
+               glPopMatrix();
+
+               /* DRAW CYAN ANT */
+               glPushMatrix();
+               glRotatef(-mp->ant_position + 180, 0, 0, 1);
+               glTranslatef(3, 0, 0);
+               glRotatef(-mp->ant_position / 2 + 90, 0, 1, 0);
+               glTranslatef(0.28, 0, 0.45);
+               glRotatef(180, 1, 0, 0);
+               draw_moebius_ant(mp, MaterialCyan, mono);
+               glPopMatrix();
+       }
+       mp->ant_position += 1;
+}
+#undef MoebiusDivisions
+#undef MoebiusTransversals
+
+static void
+reshape(ModeInfo * mi, int width, int height)
+{
+       moebiusstruct *mp = &moebius[MI_SCREEN(mi)];
+
+       glViewport(0, 0, mp->WindW = (GLint) width, mp->WindH = (GLint) height);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 15.0);
+       glMatrixMode(GL_MODELVIEW);
+       if (width >= 1024) {
+               glLineWidth(3);
+               glPointSize(3);
+       } else if (width >= 512) {
+               glLineWidth(2);
+               glPointSize(2);
+       } else {
+               glLineWidth(1);
+               glPointSize(1);
+       }
+       mp->AreObjectsDefined[ObjMoebiusStrip] = 0;
+       mp->AreObjectsDefined[ObjAntBody] = 0;
+}
+
+static void
+pinit(void)
+{
+       glClearDepth(1.0);
+       glClearColor(0.0, 0.0, 0.0, 1.0);
+
+       glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT0, GL_POSITION, position0);
+       glLightfv(GL_LIGHT1, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT1, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT1, GL_POSITION, position1);
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lmodel_ambient);
+       glLightModelfv(GL_LIGHT_MODEL_TWO_SIDE, lmodel_twoside);
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+       glEnable(GL_LIGHT1);
+       glEnable(GL_NORMALIZE);
+       glFrontFace(GL_CCW);
+       glCullFace(GL_BACK);
+
+       /* moebius */
+       glShadeModel(GL_SMOOTH);
+       glEnable(GL_DEPTH_TEST);
+       glDisable(GL_TEXTURE_2D);
+       glDisable(GL_CULL_FACE);
+
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+       gluBuild2DMipmaps(GL_TEXTURE_2D, 3, WoodTextureWidth, WoodTextureHeight,
+                         GL_RGB, GL_UNSIGNED_BYTE, WoodTextureData);
+       glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, front_shininess);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, front_specular);
+}
+
+void
+init_moebius(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       moebiusstruct *mp;
+
+       if (moebius == NULL) {
+               if ((moebius = (moebiusstruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (moebiusstruct))) == NULL)
+                       return;
+       }
+       mp = &moebius[screen];
+       mp->step = NRAND(90);
+       mp->ant_position = NRAND(90);
+
+       if ((mp->glx_context = init_GL(mi)) != NULL) {
+
+               reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+               glDrawBuffer(GL_BACK);
+               if (!glIsList(objects))
+                       objects = glGenLists(3);
+               pinit();
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_moebius(ModeInfo * mi)
+{
+       moebiusstruct *mp = &moebius[MI_SCREEN(mi)];
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!mp->glx_context)
+               return;
+
+       glXMakeCurrent(display, window, *(mp->glx_context));
+
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       glPushMatrix();
+
+       glTranslatef(0.0, 0.0, -10.0);
+
+       if (!MI_IS_ICONIC(mi)) {
+               glScalef(Scale4Window * mp->WindH / mp->WindW, Scale4Window, Scale4Window);
+       } else {
+               glScalef(Scale4Iconic * mp->WindH / mp->WindW, Scale4Iconic, Scale4Iconic);
+       }
+
+       /* moebius */
+       glRotatef(mp->step * 100, 1, 0, 0);
+       glRotatef(mp->step * 95, 0, 1, 0);
+       glRotatef(mp->step * 90, 0, 0, 1);
+       draw_moebius_strip(mi);
+
+       glPopMatrix();
+
+       glFlush();
+
+       glXSwapBuffers(display, window);
+
+       mp->step += 0.025;
+}
+
+void
+change_moebius(ModeInfo * mi)
+{
+       moebiusstruct *mp = &moebius[MI_SCREEN(mi)];
+
+       if (!mp->glx_context)
+               return;
+
+       glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(mp->glx_context));
+       pinit();
+}
+
+void
+release_moebius(ModeInfo * mi)
+{
+       if (moebius != NULL) {
+               (void) free((void *) moebius);
+               moebius = NULL;
+       }
+       if (glIsList(objects)) {
+               glDeleteLists(objects, 3);
+       }
+       FreeAllGL(mi);
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/morph3d.c b/xlockmore-4.14/modes/glx/morph3d.c
new file mode 100644 (file)
index 0000000..a488822
--- /dev/null
@@ -0,0 +1,891 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* morph3d --- Shows 3D morphing objects */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)morph3d.c    4.07 97/11/24 xlockmore";
+
+#endif
+
+#undef DEBUG_CULL_FACE
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The original code for this mode was written by Marcelo Fernandes Vianna 
+ * (me...) and was inspired on a WindowsNT(R)'s screen saver (Flower Box).
+ * It was written from scratch and it was not based on any other source code. 
+ * 
+ * Porting it to xlock (the final objective of this code since the moment I 
+ * decided to create it) was possible by comparing the original Mesa's gear 
+ * demo with it's ported version to xlock, so thanks for Danny Sung (look at
+ * gear.c) for his indirect help.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * If you are interested in the original version of this program (not a xlock
+ * mode, please refer to the Mesa package (ftp iris.ssec.wisc.edu on /pub/Mesa)
+ *
+ * Since I'm not a native English speaker, my apologies for any grammatical
+ * mistake.
+ *
+ * My e-mail address is
+ * m-vianna@usa.net
+ *
+ * Marcelo F. Vianna (Feb-13-1997)
+ *
+ * Revision History:
+ * 27-Jul-97: Speed ups by Marcelo F. Vianna.
+ * 08-May-97: Speed ups by Marcelo F. Vianna.
+ *
+ */
+
+/*-
+ * PURIFY 3.0a on SunOS4 reports an unitialized memory read on each of
+ * the glCallList() functions below when using MesaGL 2.1.  This has
+ * been fixed in MesaGL 2.2 and later releases.
+ */
+
+/*-
+ * due to a Bug/feature in VMS X11/Intrinsic.h has to be placed before xlock.
+ * otherwise caddr_t is not defined correctly
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Morph3d"
+#define HACK_INIT init_morph3d
+#define HACK_DRAW draw_morph3d
+#define morph3d_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: 0 \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_moebius
+
+ModeSpecOpt morph3d_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   morph3d_description =
+{"morph3d", "init_morph3d", "draw_morph3d", "release_morph3d",
+ "draw_morph3d", "change_morph3d", NULL, &morph3d_opts,
+ 1000, 0, 1, 1, 4, 1.0, "",
+ "Shows GL morphing polyhedra", 0, NULL};
+
+#endif
+
+#define Scale4Window               0.3
+#define Scale4Iconic               1.0
+
+#define VectMul(X1,Y1,Z1,X2,Y2,Z2) (Y1)*(Z2)-(Z1)*(Y2),(Z1)*(X2)-(X1)*(Z2),(X1)*(Y2)-(Y1)*(X2)
+#define sqr(A)                     ((A)*(A))
+
+/* Increasing this values produces better image quality, the price is speed. */
+#define tetradivisions             23
+#define cubedivisions              20
+#define octadivisions              21
+#define dodecadivisions            10
+#define icodivisions               15
+
+#define tetraangle                 109.47122063449069174
+#define cubeangle                  90.000000000000000000
+#define octaangle                  109.47122063449069174
+#define dodecaangle                63.434948822922009981
+#define icoangle                   41.810314895778596167
+
+#ifndef Pi
+#define Pi                         M_PI
+#endif
+#define SQRT2                      1.4142135623730951455
+#define SQRT3                      1.7320508075688771932
+#define SQRT5                      2.2360679774997898051
+#define SQRT6                      2.4494897427831778813
+#define SQRT15                     3.8729833462074170214
+#define cossec36_2                 0.8506508083520399322
+#define cos72                      0.3090169943749474241
+#define sin72                      0.9510565162951535721
+#define cos36                      0.8090169943749474241
+#define sin36                      0.5877852522924731292
+
+/*************************************************************************/
+
+typedef struct {
+       GLint       WindH, WindW;
+       GLfloat     step;
+       GLfloat     seno;
+       int         object;
+       int         edgedivisions;
+       int         VisibleSpikes;
+       void        (*draw_object) (ModeInfo * mi);
+       float       Magnitude;
+       float      *MaterialColor[20];
+       GLXContext *glx_context;
+} morph3dstruct;
+
+static float front_shininess[] =
+{60.0};
+static float front_specular[] =
+{0.7, 0.7, 0.7, 1.0};
+static float ambient[] =
+{0.0, 0.0, 0.0, 1.0};
+static float diffuse[] =
+{1.0, 1.0, 1.0, 1.0};
+static float position0[] =
+{1.0, 1.0, 1.0, 0.0};
+static float position1[] =
+{-1.0, -1.0, 1.0, 0.0};
+static float lmodel_ambient[] =
+{0.5, 0.5, 0.5, 1.0};
+static float lmodel_twoside[] =
+{GL_TRUE};
+
+static float MaterialRed[] =
+{0.7, 0.0, 0.0, 1.0};
+static float MaterialGreen[] =
+{0.1, 0.5, 0.2, 1.0};
+static float MaterialBlue[] =
+{0.0, 0.0, 0.7, 1.0};
+static float MaterialCyan[] =
+{0.2, 0.5, 0.7, 1.0};
+static float MaterialYellow[] =
+{0.7, 0.7, 0.0, 1.0};
+static float MaterialMagenta[] =
+{0.6, 0.2, 0.5, 1.0};
+static float MaterialWhite[] =
+{0.7, 0.7, 0.7, 1.0};
+static float MaterialGray[] =
+{0.5, 0.5, 0.5, 1.0};
+
+static morph3dstruct *morph3d = NULL;
+
+#define TRIANGLE(Edge, Amp, Divisions, Z, VS)                                                                    \
+{                                                                                                                \
+  GLfloat   Xf,Yf,Xa,Yb,Xf2,Yf2,Yf_2,Yb2,Yb_2;                                                                   \
+  GLfloat   Factor=0.0,Factor1,Factor2;                                                                          \
+  GLfloat   VertX,VertY,VertZ,NeiAX,NeiAY,NeiAZ,NeiBX,NeiBY,NeiBZ;                                               \
+  GLfloat   Ax,Ay;                                                                                               \
+  int       Ri,Ti;                                                                                               \
+  GLfloat   Vr=(Edge)*SQRT3/3;                                                                                   \
+  GLfloat   AmpVr2=(Amp)/sqr(Vr);                                                                                \
+  GLfloat   Zf=(Edge)*(Z);                                                                                       \
+                                                                                                                 \
+  Ax=(Edge)*(+0.5/(Divisions)), Ay=(Edge)*(-SQRT3/(2*Divisions));                                                \
+                                                                                                                 \
+  Yf=Vr+Ay; Yb=Yf+0.001;                                                                                         \
+  for (Ri=1; Ri<=(Divisions); Ri++) {                                                                            \
+    glBegin(GL_TRIANGLE_STRIP);                                                                                  \
+    Xf=(float)Ri*Ax; Xa=Xf+0.001;                                                                                \
+    Yf2=sqr(Yf); Yf_2=sqr(Yf-Ay);                                                                                \
+    Yb2=sqr(Yb); Yb_2=sqr(Yb-Ay);                                                                                \
+    for (Ti=0; Ti<Ri; Ti++) {                                                                                    \
+      Factor=1-(((Xf2=sqr(Xf))+Yf2)*AmpVr2);                                                                     \
+      Factor1=1-((sqr(Xa)+Yf2)*AmpVr2);                                                                          \
+      Factor2=1-((Xf2+Yb2)*AmpVr2);                                                                              \
+      VertX=Factor*Xf;        VertY=Factor*Yf;        VertZ=Factor*Zf;                                           \
+      NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Yf-VertY; NeiAZ=Factor1*Zf-VertZ;                                    \
+      NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                    \
+      glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                             \
+      glVertex3f(VertX, VertY, VertZ);                                                                           \
+                                                                                                                 \
+      Xf-=Ax; Yf-=Ay; Xa-=Ax; Yb-=Ay;                                                                            \
+                                                                                                                 \
+      Factor=1-(((Xf2=sqr(Xf))+Yf_2)*AmpVr2);                                                                    \
+      Factor1=1-((sqr(Xa)+Yf_2)*AmpVr2);                                                                         \
+      Factor2=1-((Xf2+Yb_2)*AmpVr2);                                                                             \
+      VertX=Factor*Xf;        VertY=Factor*Yf;        VertZ=Factor*Zf;                                           \
+      NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Yf-VertY; NeiAZ=Factor1*Zf-VertZ;                                    \
+      NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                    \
+      glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                             \
+      glVertex3f(VertX, VertY, VertZ);                                                                           \
+                                                                                                                 \
+      Xf-=Ax; Yf+=Ay; Xa-=Ax; Yb+=Ay;                                                                            \
+    }                                                                                                            \
+    Factor=1-(((Xf2=sqr(Xf))+(Yf2=sqr(Yf)))*AmpVr2);                                                             \
+    Factor1=1-((sqr(Xa)+Yf2)*AmpVr2);                                                                            \
+    Factor2=1-((Xf2+sqr(Yb))*AmpVr2);                                                                            \
+    VertX=Factor*Xf;        VertY=Factor*Yf;        VertZ=Factor*Zf;                                             \
+    NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Yf-VertY; NeiAZ=Factor1*Zf-VertZ;                                      \
+    NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                      \
+    glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                               \
+    glVertex3f(VertX, VertY, VertZ);                                                                             \
+    Yf+=Ay; Yb+=Ay;                                                                                              \
+    glEnd();                                                                                                     \
+  }                                                                                                              \
+  VS=(Factor<0);                                                                                                 \
+}
+
+#define SQUARE(Edge, Amp, Divisions, Z, VS)                                                                      \
+{                                                                                                                \
+  int       Xi,Yi;                                                                                               \
+  GLfloat   Xf,Yf,Y,Xf2,Yf2,Y2,Xa,Xa2,Yb;                                                                        \
+  GLfloat   Factor=0.0,Factor1,Factor2;                                                                          \
+  GLfloat   VertX,VertY,VertZ,NeiAX,NeiAY,NeiAZ,NeiBX,NeiBY,NeiBZ;                                               \
+  GLfloat   Zf=(Edge)*(Z);                                                                                       \
+  GLfloat   AmpVr2=(Amp)/sqr((Edge)*SQRT2/2);                                                                    \
+                                                                                                                 \
+  for (Yi=0; Yi<(Divisions); Yi++) {                                                                             \
+    Yf=-((Edge)/2.0) + ((float)Yi)/(Divisions)*(Edge);                                                           \
+    Yf2=sqr(Yf);                                                                                                 \
+    Y=Yf+1.0/(Divisions)*(Edge);                                                                                 \
+    Y2=sqr(Y);                                                                                                   \
+    glBegin(GL_QUAD_STRIP);                                                                                      \
+    for (Xi=0; Xi<=(Divisions); Xi++) {                                                                          \
+      Xf=-((Edge)/2.0) + ((float)Xi)/(Divisions)*(Edge);                                                         \
+      Xf2=sqr(Xf);                                                                                               \
+                                                                                                                 \
+      Xa=Xf+0.001; Yb=Y+0.001;                                                                                   \
+      Factor=1-((Xf2+Y2)*AmpVr2);                                                                                \
+      Factor1=1-(((Xa2=sqr(Xa))+Y2)*AmpVr2);                                                                     \
+      Factor2=1-((Xf2+sqr(Yb))*AmpVr2);                                                                          \
+      VertX=Factor*Xf;        VertY=Factor*Y;         VertZ=Factor*Zf;                                           \
+      NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Y-VertY;  NeiAZ=Factor1*Zf-VertZ;                                    \
+      NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                    \
+      glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                             \
+      glVertex3f(VertX, VertY, VertZ);                                                                           \
+                                                                                                                 \
+      Yb=Yf+0.001;                                                                                               \
+      Factor=1-((Xf2+Yf2)*AmpVr2);                                                                               \
+      Factor1=1-((Xa2+Yf2)*AmpVr2);                                                                              \
+      Factor2=1-((Xf2+sqr(Yb))*AmpVr2);                                                                          \
+      VertX=Factor*Xf;        VertY=Factor*Yf;        VertZ=Factor*Zf;                                           \
+      NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Yf-VertY; NeiAZ=Factor1*Zf-VertZ;                                    \
+      NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                    \
+      glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                             \
+      glVertex3f(VertX, VertY, VertZ);                                                                           \
+    }                                                                                                            \
+    glEnd();                                                                                                     \
+  }                                                                                                              \
+  VS=(Factor<0);                                                                                                 \
+}
+
+#define PENTAGON(Edge, Amp, Divisions, Z, VS)                                                                    \
+{                                                                                                                \
+  int       Ri,Ti,Fi;                                                                                            \
+  GLfloat   Xf,Yf,Xa,Yb,Xf2,Yf2;                                                                                 \
+  GLfloat   Factor=0.0,Factor1,Factor2;                                                                          \
+  GLfloat   VertX,VertY,VertZ,NeiAX,NeiAY,NeiAZ,NeiBX,NeiBY,NeiBZ;                                               \
+  GLfloat   Zf=(Edge)*(Z);                                                                                       \
+  GLfloat   AmpVr2=(Amp)/sqr((Edge)*cossec36_2);                                                                 \
+                                                                                                                 \
+  static    GLfloat x[6],y[6];                                                                                   \
+  static    int arrayninit=1;                                                                                    \
+                                                                                                                 \
+  if (arrayninit) {                                                                                              \
+    for(Fi=0;Fi<6;Fi++) {                                                                                        \
+      x[Fi]=-cos( Fi*2*Pi/5 + Pi/10 )/(Divisions)*cossec36_2*(Edge);                                             \
+      y[Fi]=sin( Fi*2*Pi/5 + Pi/10 )/(Divisions)*cossec36_2*(Edge);                                              \
+    }                                                                                                            \
+    arrayninit=0;                                                                                                \
+  }                                                                                                              \
+                                                                                                                 \
+  for (Ri=1; Ri<=(Divisions); Ri++) {                                                                            \
+    for (Fi=0; Fi<5; Fi++) {                                                                                     \
+      glBegin(GL_TRIANGLE_STRIP);                                                                                \
+      for (Ti=0; Ti<Ri; Ti++) {                                                                                  \
+        Xf=(float)(Ri-Ti)*x[Fi] + (float)Ti*x[Fi+1];                                                             \
+        Yf=(float)(Ri-Ti)*y[Fi] + (float)Ti*y[Fi+1];                                                             \
+        Xa=Xf+0.001; Yb=Yf+0.001;                                                                                \
+       Factor=1-(((Xf2=sqr(Xf))+(Yf2=sqr(Yf)))*AmpVr2);                                                         \
+       Factor1=1-((sqr(Xa)+Yf2)*AmpVr2);                                                                        \
+       Factor2=1-((Xf2+sqr(Yb))*AmpVr2);                                                                        \
+        VertX=Factor*Xf;        VertY=Factor*Yf;        VertZ=Factor*Zf;                                         \
+        NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Yf-VertY; NeiAZ=Factor1*Zf-VertZ;                                  \
+        NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                  \
+        glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                           \
+       glVertex3f(VertX, VertY, VertZ);                                                                         \
+                                                                                                                 \
+        Xf-=x[Fi]; Yf-=y[Fi]; Xa-=x[Fi]; Yb-=y[Fi];                                                              \
+                                                                                                                 \
+       Factor=1-(((Xf2=sqr(Xf))+(Yf2=sqr(Yf)))*AmpVr2);                                                         \
+       Factor1=1-((sqr(Xa)+Yf2)*AmpVr2);                                                                        \
+       Factor2=1-((Xf2+sqr(Yb))*AmpVr2);                                                                        \
+        VertX=Factor*Xf;        VertY=Factor*Yf;        VertZ=Factor*Zf;                                         \
+        NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Yf-VertY; NeiAZ=Factor1*Zf-VertZ;                                  \
+        NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                  \
+        glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                           \
+       glVertex3f(VertX, VertY, VertZ);                                                                         \
+                                                                                                                 \
+      }                                                                                                          \
+      Xf=(float)Ri*x[Fi+1];                                                                                      \
+      Yf=(float)Ri*y[Fi+1];                                                                                      \
+      Xa=Xf+0.001; Yb=Yf+0.001;                                                                                  \
+      Factor=1-(((Xf2=sqr(Xf))+(Yf2=sqr(Yf)))*AmpVr2);                                                           \
+      Factor1=1-((sqr(Xa)+Yf2)*AmpVr2);                                                                          \
+      Factor2=1-((Xf2+sqr(Yb))*AmpVr2);                                                                          \
+      VertX=Factor*Xf;        VertY=Factor*Yf;        VertZ=Factor*Zf;                                           \
+      NeiAX=Factor1*Xa-VertX; NeiAY=Factor1*Yf-VertY; NeiAZ=Factor1*Zf-VertZ;                                    \
+      NeiBX=Factor2*Xf-VertX; NeiBY=Factor2*Yb-VertY; NeiBZ=Factor2*Zf-VertZ;                                    \
+      glNormal3f(VectMul(NeiAX, NeiAY, NeiAZ, NeiBX, NeiBY, NeiBZ));                                             \
+      glVertex3f(VertX, VertY, VertZ);                                                                           \
+      glEnd();                                                                                                   \
+    }                                                                                                            \
+  }                                                                                                              \
+  VS=(Factor<0);                                                                                             \
+}
+
+static void
+draw_tetra(ModeInfo * mi)
+{
+       GLuint      list;
+
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[0]);
+
+       list = glGenLists(1);
+       glNewList(list, GL_COMPILE_AND_EXECUTE);
+       TRIANGLE(2, mp->seno, mp->edgedivisions, 0.5 / SQRT6, mp->VisibleSpikes);
+       glEndList();
+
+       glPushMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-tetraangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[1]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + tetraangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[2]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + tetraangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[3]);
+       glCallList(list);
+
+       glDeleteLists(list, 1);
+}
+
+static void
+draw_cube(ModeInfo * mi)
+{
+       GLuint      list;
+
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[0]);
+
+       list = glGenLists(1);
+       glNewList(list, GL_COMPILE_AND_EXECUTE);
+       SQUARE(2, mp->seno, mp->edgedivisions, 0.5, mp->VisibleSpikes)
+               glEndList();
+
+       glRotatef(cubeangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[1]);
+       glCallList(list);
+       glRotatef(cubeangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[2]);
+       glCallList(list);
+       glRotatef(cubeangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[3]);
+       glCallList(list);
+       glRotatef(cubeangle, 0, 1, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[4]);
+       glCallList(list);
+       glRotatef(2 * cubeangle, 0, 1, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[5]);
+       glCallList(list);
+
+       glDeleteLists(list, 1);
+}
+
+static void
+draw_octa(ModeInfo * mi)
+{
+       GLuint      list;
+
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[0]);
+
+       list = glGenLists(1);
+       glNewList(list, GL_COMPILE_AND_EXECUTE);
+       TRIANGLE(2, mp->seno, mp->edgedivisions, 1 / SQRT6, mp->VisibleSpikes);
+       glEndList();
+
+       glPushMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-180 + octaangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[1]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-octaangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[2]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-octaangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[3]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[4]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-180 + octaangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[5]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-octaangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[6]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-octaangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[7]);
+       glCallList(list);
+
+       glDeleteLists(list, 1);
+}
+
+static void
+draw_dodeca(ModeInfo * mi)
+{
+       GLuint      list;
+
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+#define TAU ((SQRT5+1)/2)
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[0]);
+
+       list = glGenLists(1);
+       glNewList(list, GL_COMPILE_AND_EXECUTE);
+       PENTAGON(1, mp->seno, mp->edgedivisions, sqr(TAU) * sqrt((TAU + 2) / 5) / 2, mp->VisibleSpikes);
+       glEndList();
+
+       glPushMatrix();
+       glRotatef(180, 0, 0, 1);
+       glPushMatrix();
+       glRotatef(-dodecaangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[1]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(-dodecaangle, cos72, sin72, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[2]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(-dodecaangle, cos72, -sin72, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[3]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(dodecaangle, cos36, -sin36, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[4]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(dodecaangle, cos36, sin36, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[5]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[6]);
+       glCallList(list);
+       glRotatef(180, 0, 0, 1);
+       glPushMatrix();
+       glRotatef(-dodecaangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[7]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(-dodecaangle, cos72, sin72, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[8]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(-dodecaangle, cos72, -sin72, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[9]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(dodecaangle, cos36, -sin36, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[10]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(dodecaangle, cos36, sin36, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[11]);
+       glCallList(list);
+
+       glDeleteLists(list, 1);
+}
+
+static void
+draw_icosa(ModeInfo * mi)
+{
+       GLuint      list;
+
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[0]);
+
+       list = glGenLists(1);
+       glNewList(list, GL_COMPILE_AND_EXECUTE);
+       TRIANGLE(1.5, mp->seno, mp->edgedivisions, (3 * SQRT3 + SQRT15) / 12, mp->VisibleSpikes);
+       glEndList();
+
+       glPushMatrix();
+
+       glPushMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-icoangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[1]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[2]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[3]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[4]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[5]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-icoangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[6]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[7]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[8]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-icoangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[9]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[10]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-icoangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[11]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[12]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[13]);
+       glCallList(list);
+       glPopMatrix();
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[14]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[15]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-icoangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[16]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[17]);
+       glCallList(list);
+       glPushMatrix();
+       glRotatef(180, 0, 1, 0);
+       glRotatef(-180 + icoangle, 0.5, -SQRT3 / 2, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[18]);
+       glCallList(list);
+       glPopMatrix();
+       glRotatef(180, 0, 0, 1);
+       glRotatef(-icoangle, 1, 0, 0);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mp->MaterialColor[19]);
+       glCallList(list);
+
+       glDeleteLists(list, 1);
+}
+
+static void
+reshape(ModeInfo * mi, int width, int height)
+{
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+       glViewport(0, 0, mp->WindW = (GLint) width, mp->WindH = (GLint) height);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 15.0);
+       glMatrixMode(GL_MODELVIEW);
+}
+
+static void
+pinit(ModeInfo * mi)
+{
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+       glClearDepth(1.0);
+       glClearColor(0.0, 0.0, 0.0, 1.0);
+       glColor3f(1.0, 1.0, 1.0);
+
+       glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT0, GL_POSITION, position0);
+       glLightfv(GL_LIGHT1, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT1, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT1, GL_POSITION, position1);
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lmodel_ambient);
+       glLightModelfv(GL_LIGHT_MODEL_TWO_SIDE, lmodel_twoside);
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+       glEnable(GL_LIGHT1);
+       glEnable(GL_DEPTH_TEST);
+       glEnable(GL_NORMALIZE);
+
+       glShadeModel(GL_SMOOTH);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, front_shininess);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, front_specular);
+
+       switch (mp->object) {
+               case 2:
+                       mp->draw_object = draw_cube;
+                       mp->MaterialColor[0] = MaterialRed;
+                       mp->MaterialColor[1] = MaterialGreen;
+                       mp->MaterialColor[2] = MaterialCyan;
+                       mp->MaterialColor[3] = MaterialMagenta;
+                       mp->MaterialColor[4] = MaterialYellow;
+                       mp->MaterialColor[5] = MaterialBlue;
+                       mp->edgedivisions = cubedivisions;
+                       mp->Magnitude = 2.0;
+                       break;
+               case 3:
+                       mp->draw_object = draw_octa;
+                       mp->MaterialColor[0] = MaterialRed;
+                       mp->MaterialColor[1] = MaterialGreen;
+                       mp->MaterialColor[2] = MaterialBlue;
+                       mp->MaterialColor[3] = MaterialWhite;
+                       mp->MaterialColor[4] = MaterialCyan;
+                       mp->MaterialColor[5] = MaterialMagenta;
+                       mp->MaterialColor[6] = MaterialGray;
+                       mp->MaterialColor[7] = MaterialYellow;
+                       mp->edgedivisions = octadivisions;
+                       mp->Magnitude = 2.5;
+                       break;
+               case 4:
+                       mp->draw_object = draw_dodeca;
+                       mp->MaterialColor[0] = MaterialRed;
+                       mp->MaterialColor[1] = MaterialGreen;
+                       mp->MaterialColor[2] = MaterialCyan;
+                       mp->MaterialColor[3] = MaterialBlue;
+                       mp->MaterialColor[4] = MaterialMagenta;
+                       mp->MaterialColor[5] = MaterialYellow;
+                       mp->MaterialColor[6] = MaterialGreen;
+                       mp->MaterialColor[7] = MaterialCyan;
+                       mp->MaterialColor[8] = MaterialRed;
+                       mp->MaterialColor[9] = MaterialMagenta;
+                       mp->MaterialColor[10] = MaterialBlue;
+                       mp->MaterialColor[11] = MaterialYellow;
+                       mp->edgedivisions = dodecadivisions;
+                       mp->Magnitude = 2.0;
+                       break;
+               case 5:
+                       mp->draw_object = draw_icosa;
+                       mp->MaterialColor[0] = MaterialRed;
+                       mp->MaterialColor[1] = MaterialGreen;
+                       mp->MaterialColor[2] = MaterialBlue;
+                       mp->MaterialColor[3] = MaterialCyan;
+                       mp->MaterialColor[4] = MaterialYellow;
+                       mp->MaterialColor[5] = MaterialMagenta;
+                       mp->MaterialColor[6] = MaterialRed;
+                       mp->MaterialColor[7] = MaterialGreen;
+                       mp->MaterialColor[8] = MaterialBlue;
+                       mp->MaterialColor[9] = MaterialWhite;
+                       mp->MaterialColor[10] = MaterialCyan;
+                       mp->MaterialColor[11] = MaterialYellow;
+                       mp->MaterialColor[12] = MaterialMagenta;
+                       mp->MaterialColor[13] = MaterialRed;
+                       mp->MaterialColor[14] = MaterialGreen;
+                       mp->MaterialColor[15] = MaterialBlue;
+                       mp->MaterialColor[16] = MaterialCyan;
+                       mp->MaterialColor[17] = MaterialYellow;
+                       mp->MaterialColor[18] = MaterialMagenta;
+                       mp->MaterialColor[19] = MaterialGray;
+                       mp->edgedivisions = icodivisions;
+                       mp->Magnitude = 2.5;
+                       break;
+               default:
+                       mp->draw_object = draw_tetra;
+                       mp->MaterialColor[0] = MaterialRed;
+                       mp->MaterialColor[1] = MaterialGreen;
+                       mp->MaterialColor[2] = MaterialBlue;
+                       mp->MaterialColor[3] = MaterialWhite;
+                       mp->edgedivisions = tetradivisions;
+                       mp->Magnitude = 2.5;
+                       break;
+       }
+       if (MI_IS_MONO(mi)) {
+               int         loop;
+
+               for (loop = 0; loop < 20; loop++)
+                       mp->MaterialColor[loop] = MaterialGray;
+       }
+}
+
+void
+init_morph3d(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       morph3dstruct *mp;
+
+       if (morph3d == NULL) {
+               if ((morph3d = (morph3dstruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (morph3dstruct))) == NULL)
+                       return;
+       }
+       mp = &morph3d[screen];
+       mp->step = NRAND(90);
+       mp->VisibleSpikes = 1;
+
+       if ((mp->glx_context = init_GL(mi)) != NULL) {
+
+               reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+               mp->object = MI_COUNT(mi);
+               if (mp->object <= 0 || mp->object > 5)
+                       mp->object = NRAND(5) + 1;
+               pinit(mi);
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_morph3d(ModeInfo * mi)
+{
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!mp->glx_context)
+               return;
+
+       glDrawBuffer(GL_BACK);
+       glXMakeCurrent(display, window, *(mp->glx_context));
+
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       glPushMatrix();
+
+       glTranslatef(0.0, 0.0, -10.0);
+
+       if (!MI_IS_ICONIC(mi)) {
+               glScalef(Scale4Window * mp->WindH / mp->WindW, Scale4Window, Scale4Window);
+               glTranslatef(2.5 * mp->WindW / mp->WindH * sin(mp->step * 1.11), 2.5 * cos(mp->step * 1.25 * 1.11), 0);
+       } else {
+               glScalef(Scale4Iconic * mp->WindH / mp->WindW, Scale4Iconic, Scale4Iconic);
+       }
+
+       glRotatef(mp->step * 100, 1, 0, 0);
+       glRotatef(mp->step * 95, 0, 1, 0);
+       glRotatef(mp->step * 90, 0, 0, 1);
+
+       mp->seno = (sin(mp->step) + 1.0 / 3.0) * (4.0 / 5.0) * mp->Magnitude;
+
+       if (mp->VisibleSpikes) {
+#ifdef DEBUG_CULL_FACE
+               int         loop;
+
+               for (loop = 0; loop < 20; loop++)
+                       mp->MaterialColor[loop] = MaterialGray;
+#endif
+               glDisable(GL_CULL_FACE);
+       } else {
+#ifdef DEBUG_CULL_FACE
+               int         loop;
+
+               for (loop = 0; loop < 20; loop++)
+                       mp->MaterialColor[loop] = MaterialWhite;
+#endif
+               glEnable(GL_CULL_FACE);
+       }
+
+       mp->draw_object(mi);
+
+       glPopMatrix();
+
+       glFlush();
+
+       glXSwapBuffers(display, window);
+
+       mp->step += 0.05;
+}
+
+void
+change_morph3d(ModeInfo * mi)
+{
+       morph3dstruct *mp = &morph3d[MI_SCREEN(mi)];
+
+       if (!mp->glx_context)
+               return;
+
+       mp->object = (mp->object) % 5 + 1;
+       pinit(mi);
+}
+
+void
+release_morph3d(ModeInfo * mi)
+{
+       if (morph3d != NULL) {
+               (void) free((void *) morph3d);
+               morph3d = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/pipeobjs.c b/xlockmore-4.14/modes/glx/pipeobjs.c
new file mode 100644 (file)
index 0000000..3e2179e
--- /dev/null
@@ -0,0 +1,3267 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)pipeobjs.c   4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points, polygons, and normal vectors to render objects for pipes.
+ *
+ * Generated by lw2ogl.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_pipes
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat BigValve_PNTS[] =
+{
+       (GLfloat) 0.756788, (GLfloat) 0.614672, (GLfloat) - 0.000000,
+       (GLfloat) 0.779498, (GLfloat) 0.599497, (GLfloat) - 0.000000,
+       (GLfloat) 0.794672, (GLfloat) 0.576788, (GLfloat) - 0.000000,
+       (GLfloat) 0.800000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) 0.794672, (GLfloat) 0.523212, (GLfloat) - 0.000000,
+       (GLfloat) 0.779498, (GLfloat) 0.500503, (GLfloat) - 0.000000,
+       (GLfloat) 0.756788, (GLfloat) 0.485328, (GLfloat) - 0.000000,
+       (GLfloat) 0.730000, (GLfloat) 0.480000, (GLfloat) - 0.000000,
+       (GLfloat) 0.703212, (GLfloat) 0.485328, (GLfloat) - 0.000000,
+       (GLfloat) 0.680503, (GLfloat) 0.500503, (GLfloat) - 0.000000,
+       (GLfloat) 0.665328, (GLfloat) 0.523212, (GLfloat) - 0.000000,
+       (GLfloat) 0.660000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) 0.665328, (GLfloat) 0.576788, (GLfloat) - 0.000000,
+       (GLfloat) 0.680503, (GLfloat) 0.599497, (GLfloat) - 0.000000,
+       (GLfloat) 0.703212, (GLfloat) 0.614672, (GLfloat) - 0.000000,
+       (GLfloat) 0.730000, (GLfloat) 0.620000, (GLfloat) - 0.000000,
+       (GLfloat) 0.756788, (GLfloat) 0.602861, (GLfloat) 0.119916,
+       (GLfloat) 0.779498, (GLfloat) 0.587978, (GLfloat) 0.116956,
+       (GLfloat) 0.794672, (GLfloat) 0.565705, (GLfloat) 0.112526,
+       (GLfloat) 0.800000, (GLfloat) 0.539432, (GLfloat) 0.107300,
+       (GLfloat) 0.794672, (GLfloat) 0.513159, (GLfloat) 0.102074,
+       (GLfloat) 0.779498, (GLfloat) 0.490886, (GLfloat) 0.097643,
+       (GLfloat) 0.756788, (GLfloat) 0.476003, (GLfloat) 0.094683,
+       (GLfloat) 0.730000, (GLfloat) 0.470777, (GLfloat) 0.093643,
+       (GLfloat) 0.703212, (GLfloat) 0.476003, (GLfloat) 0.094683,
+       (GLfloat) 0.680503, (GLfloat) 0.490886, (GLfloat) 0.097643,
+       (GLfloat) 0.665328, (GLfloat) 0.513159, (GLfloat) 0.102074,
+       (GLfloat) 0.660000, (GLfloat) 0.539432, (GLfloat) 0.107300,
+       (GLfloat) 0.665328, (GLfloat) 0.565705, (GLfloat) 0.112526,
+       (GLfloat) 0.680503, (GLfloat) 0.587978, (GLfloat) 0.116956,
+       (GLfloat) 0.703212, (GLfloat) 0.602861, (GLfloat) 0.119916,
+       (GLfloat) 0.730000, (GLfloat) 0.608087, (GLfloat) 0.120956,
+       (GLfloat) 0.756788, (GLfloat) 0.567882, (GLfloat) 0.235225,
+       (GLfloat) 0.779498, (GLfloat) 0.553863, (GLfloat) 0.229418,
+       (GLfloat) 0.794672, (GLfloat) 0.532882, (GLfloat) 0.220727,
+       (GLfloat) 0.800000, (GLfloat) 0.508134, (GLfloat) 0.210476,
+       (GLfloat) 0.794672, (GLfloat) 0.483385, (GLfloat) 0.200225,
+       (GLfloat) 0.779498, (GLfloat) 0.462404, (GLfloat) 0.191534,
+       (GLfloat) 0.756788, (GLfloat) 0.448385, (GLfloat) 0.185727,
+       (GLfloat) 0.730000, (GLfloat) 0.443462, (GLfloat) 0.183688,
+       (GLfloat) 0.703212, (GLfloat) 0.448385, (GLfloat) 0.185727,
+       (GLfloat) 0.680503, (GLfloat) 0.462404, (GLfloat) 0.191534,
+       (GLfloat) 0.665328, (GLfloat) 0.483385, (GLfloat) 0.200225,
+       (GLfloat) 0.660000, (GLfloat) 0.508134, (GLfloat) 0.210476,
+       (GLfloat) 0.665328, (GLfloat) 0.532882, (GLfloat) 0.220727,
+       (GLfloat) 0.680503, (GLfloat) 0.553863, (GLfloat) 0.229418,
+       (GLfloat) 0.703212, (GLfloat) 0.567882, (GLfloat) 0.235225,
+       (GLfloat) 0.730000, (GLfloat) 0.572805, (GLfloat) 0.237264,
+       (GLfloat) 0.756788, (GLfloat) 0.511081, (GLfloat) 0.341493,
+       (GLfloat) 0.779498, (GLfloat) 0.498464, (GLfloat) 0.333063,
+       (GLfloat) 0.794672, (GLfloat) 0.479582, (GLfloat) 0.320446,
+       (GLfloat) 0.800000, (GLfloat) 0.457308, (GLfloat) 0.305564,
+       (GLfloat) 0.794672, (GLfloat) 0.435035, (GLfloat) 0.290681,
+       (GLfloat) 0.779498, (GLfloat) 0.416153, (GLfloat) 0.278064,
+       (GLfloat) 0.756788, (GLfloat) 0.403536, (GLfloat) 0.269634,
+       (GLfloat) 0.730000, (GLfloat) 0.399105, (GLfloat) 0.266674,
+       (GLfloat) 0.703212, (GLfloat) 0.403536, (GLfloat) 0.269634,
+       (GLfloat) 0.680503, (GLfloat) 0.416153, (GLfloat) 0.278064,
+       (GLfloat) 0.665328, (GLfloat) 0.435035, (GLfloat) 0.290681,
+       (GLfloat) 0.660000, (GLfloat) 0.457308, (GLfloat) 0.305564,
+       (GLfloat) 0.665328, (GLfloat) 0.479582, (GLfloat) 0.320446,
+       (GLfloat) 0.680503, (GLfloat) 0.498464, (GLfloat) 0.333063,
+       (GLfloat) 0.703212, (GLfloat) 0.511081, (GLfloat) 0.341493,
+       (GLfloat) 0.730000, (GLfloat) 0.515511, (GLfloat) 0.344454,
+       (GLfloat) 0.756788, (GLfloat) 0.434638, (GLfloat) 0.434638,
+       (GLfloat) 0.779498, (GLfloat) 0.423909, (GLfloat) 0.423909,
+       (GLfloat) 0.794672, (GLfloat) 0.407851, (GLfloat) 0.407851,
+       (GLfloat) 0.800000, (GLfloat) 0.388909, (GLfloat) 0.388909,
+       (GLfloat) 0.794672, (GLfloat) 0.369967, (GLfloat) 0.369967,
+       (GLfloat) 0.779498, (GLfloat) 0.353909, (GLfloat) 0.353909,
+       (GLfloat) 0.756788, (GLfloat) 0.343179, (GLfloat) 0.343179,
+       (GLfloat) 0.730000, (GLfloat) 0.339411, (GLfloat) 0.339411,
+       (GLfloat) 0.703212, (GLfloat) 0.343179, (GLfloat) 0.343179,
+       (GLfloat) 0.680503, (GLfloat) 0.353909, (GLfloat) 0.353909,
+       (GLfloat) 0.665328, (GLfloat) 0.369967, (GLfloat) 0.369967,
+       (GLfloat) 0.660000, (GLfloat) 0.388909, (GLfloat) 0.388909,
+       (GLfloat) 0.665328, (GLfloat) 0.407851, (GLfloat) 0.407851,
+       (GLfloat) 0.680503, (GLfloat) 0.423909, (GLfloat) 0.423909,
+       (GLfloat) 0.703212, (GLfloat) 0.434638, (GLfloat) 0.434638,
+       (GLfloat) 0.730000, (GLfloat) 0.438406, (GLfloat) 0.438406,
+       (GLfloat) 0.756788, (GLfloat) 0.341493, (GLfloat) 0.511081,
+       (GLfloat) 0.779498, (GLfloat) 0.333063, (GLfloat) 0.498464,
+       (GLfloat) 0.794672, (GLfloat) 0.320446, (GLfloat) 0.479582,
+       (GLfloat) 0.800000, (GLfloat) 0.305564, (GLfloat) 0.457308,
+       (GLfloat) 0.794672, (GLfloat) 0.290681, (GLfloat) 0.435035,
+       (GLfloat) 0.779498, (GLfloat) 0.278064, (GLfloat) 0.416153,
+       (GLfloat) 0.756788, (GLfloat) 0.269634, (GLfloat) 0.403536,
+       (GLfloat) 0.730000, (GLfloat) 0.266674, (GLfloat) 0.399105,
+       (GLfloat) 0.703212, (GLfloat) 0.269634, (GLfloat) 0.403536,
+       (GLfloat) 0.680503, (GLfloat) 0.278064, (GLfloat) 0.416153,
+       (GLfloat) 0.665328, (GLfloat) 0.290681, (GLfloat) 0.435035,
+       (GLfloat) 0.660000, (GLfloat) 0.305564, (GLfloat) 0.457308,
+       (GLfloat) 0.665328, (GLfloat) 0.320446, (GLfloat) 0.479582,
+       (GLfloat) 0.680503, (GLfloat) 0.333063, (GLfloat) 0.498464,
+       (GLfloat) 0.703212, (GLfloat) 0.341493, (GLfloat) 0.511081,
+       (GLfloat) 0.730000, (GLfloat) 0.344454, (GLfloat) 0.515511,
+       (GLfloat) 0.756788, (GLfloat) 0.235225, (GLfloat) 0.567882,
+       (GLfloat) 0.779498, (GLfloat) 0.229418, (GLfloat) 0.553863,
+       (GLfloat) 0.794672, (GLfloat) 0.220727, (GLfloat) 0.532882,
+       (GLfloat) 0.800000, (GLfloat) 0.210476, (GLfloat) 0.508134,
+       (GLfloat) 0.794672, (GLfloat) 0.200225, (GLfloat) 0.483385,
+       (GLfloat) 0.779498, (GLfloat) 0.191534, (GLfloat) 0.462404,
+       (GLfloat) 0.756788, (GLfloat) 0.185727, (GLfloat) 0.448385,
+       (GLfloat) 0.730000, (GLfloat) 0.183688, (GLfloat) 0.443462,
+       (GLfloat) 0.703212, (GLfloat) 0.185727, (GLfloat) 0.448385,
+       (GLfloat) 0.680503, (GLfloat) 0.191534, (GLfloat) 0.462404,
+       (GLfloat) 0.665328, (GLfloat) 0.200225, (GLfloat) 0.483385,
+       (GLfloat) 0.660000, (GLfloat) 0.210476, (GLfloat) 0.508134,
+       (GLfloat) 0.665328, (GLfloat) 0.220727, (GLfloat) 0.532882,
+       (GLfloat) 0.680503, (GLfloat) 0.229418, (GLfloat) 0.553863,
+       (GLfloat) 0.703212, (GLfloat) 0.235225, (GLfloat) 0.567882,
+       (GLfloat) 0.730000, (GLfloat) 0.237264, (GLfloat) 0.572805,
+       (GLfloat) 0.756788, (GLfloat) 0.119916, (GLfloat) 0.602861,
+       (GLfloat) 0.779498, (GLfloat) 0.116956, (GLfloat) 0.587978,
+       (GLfloat) 0.794672, (GLfloat) 0.112526, (GLfloat) 0.565705,
+       (GLfloat) 0.800000, (GLfloat) 0.107300, (GLfloat) 0.539432,
+       (GLfloat) 0.794672, (GLfloat) 0.102074, (GLfloat) 0.513159,
+       (GLfloat) 0.779498, (GLfloat) 0.097643, (GLfloat) 0.490886,
+       (GLfloat) 0.756788, (GLfloat) 0.094683, (GLfloat) 0.476003,
+       (GLfloat) 0.730000, (GLfloat) 0.093643, (GLfloat) 0.470777,
+       (GLfloat) 0.703212, (GLfloat) 0.094683, (GLfloat) 0.476003,
+       (GLfloat) 0.680503, (GLfloat) 0.097643, (GLfloat) 0.490886,
+       (GLfloat) 0.665328, (GLfloat) 0.102074, (GLfloat) 0.513159,
+       (GLfloat) 0.660000, (GLfloat) 0.107300, (GLfloat) 0.539432,
+       (GLfloat) 0.665328, (GLfloat) 0.112526, (GLfloat) 0.565705,
+       (GLfloat) 0.680503, (GLfloat) 0.116956, (GLfloat) 0.587978,
+       (GLfloat) 0.703212, (GLfloat) 0.119916, (GLfloat) 0.602861,
+       (GLfloat) 0.730000, (GLfloat) 0.120956, (GLfloat) 0.608087,
+       (GLfloat) 0.756788, (GLfloat) 0.000000, (GLfloat) 0.614672,
+       (GLfloat) 0.779498, (GLfloat) 0.000000, (GLfloat) 0.599497,
+       (GLfloat) 0.794672, (GLfloat) 0.000000, (GLfloat) 0.576788,
+       (GLfloat) 0.800000, (GLfloat) 0.000000, (GLfloat) 0.550000,
+       (GLfloat) 0.794672, (GLfloat) 0.000000, (GLfloat) 0.523212,
+       (GLfloat) 0.779498, (GLfloat) 0.000000, (GLfloat) 0.500503,
+       (GLfloat) 0.756788, (GLfloat) 0.000000, (GLfloat) 0.485328,
+       (GLfloat) 0.730000, (GLfloat) 0.000000, (GLfloat) 0.480000,
+       (GLfloat) 0.703212, (GLfloat) 0.000000, (GLfloat) 0.485328,
+       (GLfloat) 0.680503, (GLfloat) 0.000000, (GLfloat) 0.500503,
+       (GLfloat) 0.665328, (GLfloat) 0.000000, (GLfloat) 0.523212,
+       (GLfloat) 0.660000, (GLfloat) 0.000000, (GLfloat) 0.550000,
+       (GLfloat) 0.665328, (GLfloat) 0.000000, (GLfloat) 0.576788,
+       (GLfloat) 0.680503, (GLfloat) 0.000000, (GLfloat) 0.599497,
+       (GLfloat) 0.703212, (GLfloat) 0.000000, (GLfloat) 0.614672,
+       (GLfloat) 0.730000, (GLfloat) 0.000000, (GLfloat) 0.620000,
+       (GLfloat) 0.756788, (GLfloat) - 0.119916, (GLfloat) 0.602861,
+       (GLfloat) 0.779498, (GLfloat) - 0.116956, (GLfloat) 0.587978,
+       (GLfloat) 0.794672, (GLfloat) - 0.112526, (GLfloat) 0.565705,
+       (GLfloat) 0.800000, (GLfloat) - 0.107300, (GLfloat) 0.539432,
+       (GLfloat) 0.794672, (GLfloat) - 0.102074, (GLfloat) 0.513159,
+       (GLfloat) 0.779498, (GLfloat) - 0.097643, (GLfloat) 0.490886,
+       (GLfloat) 0.756788, (GLfloat) - 0.094683, (GLfloat) 0.476003,
+       (GLfloat) 0.730000, (GLfloat) - 0.093643, (GLfloat) 0.470777,
+       (GLfloat) 0.703212, (GLfloat) - 0.094683, (GLfloat) 0.476003,
+       (GLfloat) 0.680503, (GLfloat) - 0.097643, (GLfloat) 0.490886,
+       (GLfloat) 0.665328, (GLfloat) - 0.102074, (GLfloat) 0.513159,
+       (GLfloat) 0.660000, (GLfloat) - 0.107300, (GLfloat) 0.539432,
+       (GLfloat) 0.665328, (GLfloat) - 0.112526, (GLfloat) 0.565705,
+       (GLfloat) 0.680503, (GLfloat) - 0.116956, (GLfloat) 0.587978,
+       (GLfloat) 0.703212, (GLfloat) - 0.119916, (GLfloat) 0.602861,
+       (GLfloat) 0.730000, (GLfloat) - 0.120956, (GLfloat) 0.608087,
+       (GLfloat) 0.756788, (GLfloat) - 0.235225, (GLfloat) 0.567882,
+       (GLfloat) 0.779498, (GLfloat) - 0.229418, (GLfloat) 0.553863,
+       (GLfloat) 0.794672, (GLfloat) - 0.220727, (GLfloat) 0.532882,
+       (GLfloat) 0.800000, (GLfloat) - 0.210476, (GLfloat) 0.508134,
+       (GLfloat) 0.794672, (GLfloat) - 0.200225, (GLfloat) 0.483385,
+       (GLfloat) 0.779498, (GLfloat) - 0.191534, (GLfloat) 0.462404,
+       (GLfloat) 0.756788, (GLfloat) - 0.185727, (GLfloat) 0.448385,
+       (GLfloat) 0.730000, (GLfloat) - 0.183688, (GLfloat) 0.443462,
+       (GLfloat) 0.703212, (GLfloat) - 0.185727, (GLfloat) 0.448385,
+       (GLfloat) 0.680503, (GLfloat) - 0.191534, (GLfloat) 0.462404,
+       (GLfloat) 0.665328, (GLfloat) - 0.200225, (GLfloat) 0.483385,
+       (GLfloat) 0.660000, (GLfloat) - 0.210476, (GLfloat) 0.508134,
+       (GLfloat) 0.665328, (GLfloat) - 0.220727, (GLfloat) 0.532882,
+       (GLfloat) 0.680503, (GLfloat) - 0.229418, (GLfloat) 0.553863,
+       (GLfloat) 0.703212, (GLfloat) - 0.235225, (GLfloat) 0.567882,
+       (GLfloat) 0.730000, (GLfloat) - 0.237264, (GLfloat) 0.572805,
+       (GLfloat) 0.756788, (GLfloat) - 0.341493, (GLfloat) 0.511081,
+       (GLfloat) 0.779498, (GLfloat) - 0.333063, (GLfloat) 0.498464,
+       (GLfloat) 0.794672, (GLfloat) - 0.320446, (GLfloat) 0.479582,
+       (GLfloat) 0.800000, (GLfloat) - 0.305564, (GLfloat) 0.457308,
+       (GLfloat) 0.794672, (GLfloat) - 0.290681, (GLfloat) 0.435035,
+       (GLfloat) 0.779498, (GLfloat) - 0.278064, (GLfloat) 0.416153,
+       (GLfloat) 0.756788, (GLfloat) - 0.269634, (GLfloat) 0.403536,
+       (GLfloat) 0.730000, (GLfloat) - 0.266674, (GLfloat) 0.399105,
+       (GLfloat) 0.703212, (GLfloat) - 0.269634, (GLfloat) 0.403536,
+       (GLfloat) 0.680503, (GLfloat) - 0.278064, (GLfloat) 0.416153,
+       (GLfloat) 0.665328, (GLfloat) - 0.290681, (GLfloat) 0.435035,
+       (GLfloat) 0.660000, (GLfloat) - 0.305564, (GLfloat) 0.457308,
+       (GLfloat) 0.665328, (GLfloat) - 0.320446, (GLfloat) 0.479582,
+       (GLfloat) 0.680503, (GLfloat) - 0.333063, (GLfloat) 0.498464,
+       (GLfloat) 0.703212, (GLfloat) - 0.341493, (GLfloat) 0.511081,
+       (GLfloat) 0.730000, (GLfloat) - 0.344454, (GLfloat) 0.515511,
+       (GLfloat) 0.756788, (GLfloat) - 0.434638, (GLfloat) 0.434638,
+       (GLfloat) 0.779498, (GLfloat) - 0.423909, (GLfloat) 0.423909,
+       (GLfloat) 0.794672, (GLfloat) - 0.407851, (GLfloat) 0.407851,
+       (GLfloat) 0.800000, (GLfloat) - 0.388909, (GLfloat) 0.388909,
+       (GLfloat) 0.794672, (GLfloat) - 0.369967, (GLfloat) 0.369967,
+       (GLfloat) 0.779498, (GLfloat) - 0.353909, (GLfloat) 0.353909,
+       (GLfloat) 0.756788, (GLfloat) - 0.343179, (GLfloat) 0.343179,
+       (GLfloat) 0.730000, (GLfloat) - 0.339411, (GLfloat) 0.339411,
+       (GLfloat) 0.703212, (GLfloat) - 0.343179, (GLfloat) 0.343179,
+       (GLfloat) 0.680503, (GLfloat) - 0.353909, (GLfloat) 0.353909,
+       (GLfloat) 0.665328, (GLfloat) - 0.369967, (GLfloat) 0.369967,
+       (GLfloat) 0.660000, (GLfloat) - 0.388909, (GLfloat) 0.388909,
+       (GLfloat) 0.665328, (GLfloat) - 0.407851, (GLfloat) 0.407851,
+       (GLfloat) 0.680503, (GLfloat) - 0.423909, (GLfloat) 0.423909,
+       (GLfloat) 0.703212, (GLfloat) - 0.434638, (GLfloat) 0.434638,
+       (GLfloat) 0.730000, (GLfloat) - 0.438406, (GLfloat) 0.438406,
+       (GLfloat) 0.756788, (GLfloat) - 0.511081, (GLfloat) 0.341493,
+       (GLfloat) 0.779498, (GLfloat) - 0.498464, (GLfloat) 0.333063,
+       (GLfloat) 0.794672, (GLfloat) - 0.479582, (GLfloat) 0.320446,
+       (GLfloat) 0.800000, (GLfloat) - 0.457308, (GLfloat) 0.305564,
+       (GLfloat) 0.794672, (GLfloat) - 0.435035, (GLfloat) 0.290681,
+       (GLfloat) 0.779498, (GLfloat) - 0.416153, (GLfloat) 0.278064,
+       (GLfloat) 0.756788, (GLfloat) - 0.403536, (GLfloat) 0.269634,
+       (GLfloat) 0.730000, (GLfloat) - 0.399105, (GLfloat) 0.266674,
+       (GLfloat) 0.703212, (GLfloat) - 0.403536, (GLfloat) 0.269634,
+       (GLfloat) 0.680503, (GLfloat) - 0.416153, (GLfloat) 0.278064,
+       (GLfloat) 0.665328, (GLfloat) - 0.435035, (GLfloat) 0.290681,
+       (GLfloat) 0.660000, (GLfloat) - 0.457308, (GLfloat) 0.305564,
+       (GLfloat) 0.665328, (GLfloat) - 0.479582, (GLfloat) 0.320446,
+       (GLfloat) 0.680503, (GLfloat) - 0.498464, (GLfloat) 0.333063,
+       (GLfloat) 0.703212, (GLfloat) - 0.511081, (GLfloat) 0.341493,
+       (GLfloat) 0.730000, (GLfloat) - 0.515511, (GLfloat) 0.344454,
+       (GLfloat) 0.756788, (GLfloat) - 0.567882, (GLfloat) 0.235225,
+       (GLfloat) 0.779498, (GLfloat) - 0.553863, (GLfloat) 0.229418,
+       (GLfloat) 0.794672, (GLfloat) - 0.532882, (GLfloat) 0.220727,
+       (GLfloat) 0.800000, (GLfloat) - 0.508134, (GLfloat) 0.210476,
+       (GLfloat) 0.794672, (GLfloat) - 0.483385, (GLfloat) 0.200225,
+       (GLfloat) 0.779498, (GLfloat) - 0.462404, (GLfloat) 0.191534,
+       (GLfloat) 0.756788, (GLfloat) - 0.448385, (GLfloat) 0.185727,
+       (GLfloat) 0.730000, (GLfloat) - 0.443462, (GLfloat) 0.183688,
+       (GLfloat) 0.703212, (GLfloat) - 0.448385, (GLfloat) 0.185727,
+       (GLfloat) 0.680503, (GLfloat) - 0.462404, (GLfloat) 0.191534,
+       (GLfloat) 0.665328, (GLfloat) - 0.483385, (GLfloat) 0.200225,
+       (GLfloat) 0.660000, (GLfloat) - 0.508134, (GLfloat) 0.210476,
+       (GLfloat) 0.665328, (GLfloat) - 0.532882, (GLfloat) 0.220727,
+       (GLfloat) 0.680503, (GLfloat) - 0.553863, (GLfloat) 0.229418,
+       (GLfloat) 0.703212, (GLfloat) - 0.567882, (GLfloat) 0.235225,
+       (GLfloat) 0.730000, (GLfloat) - 0.572805, (GLfloat) 0.237264,
+       (GLfloat) 0.756788, (GLfloat) - 0.602861, (GLfloat) 0.119916,
+       (GLfloat) 0.779498, (GLfloat) - 0.587978, (GLfloat) 0.116956,
+       (GLfloat) 0.794672, (GLfloat) - 0.565705, (GLfloat) 0.112526,
+       (GLfloat) 0.800000, (GLfloat) - 0.539432, (GLfloat) 0.107300,
+       (GLfloat) 0.794672, (GLfloat) - 0.513159, (GLfloat) 0.102074,
+       (GLfloat) 0.779498, (GLfloat) - 0.490886, (GLfloat) 0.097643,
+       (GLfloat) 0.756788, (GLfloat) - 0.476003, (GLfloat) 0.094683,
+       (GLfloat) 0.730000, (GLfloat) - 0.470777, (GLfloat) 0.093643,
+       (GLfloat) 0.703212, (GLfloat) - 0.476003, (GLfloat) 0.094683,
+       (GLfloat) 0.680503, (GLfloat) - 0.490886, (GLfloat) 0.097643,
+       (GLfloat) 0.665328, (GLfloat) - 0.513159, (GLfloat) 0.102074,
+       (GLfloat) 0.660000, (GLfloat) - 0.539432, (GLfloat) 0.107300,
+       (GLfloat) 0.665328, (GLfloat) - 0.565705, (GLfloat) 0.112526,
+       (GLfloat) 0.680503, (GLfloat) - 0.587978, (GLfloat) 0.116956,
+       (GLfloat) 0.703212, (GLfloat) - 0.602861, (GLfloat) 0.119916,
+       (GLfloat) 0.730000, (GLfloat) - 0.608087, (GLfloat) 0.120956,
+       (GLfloat) 0.756788, (GLfloat) - 0.614672, (GLfloat) 0.000000,
+       (GLfloat) 0.779498, (GLfloat) - 0.599497, (GLfloat) 0.000000,
+       (GLfloat) 0.794672, (GLfloat) - 0.576788, (GLfloat) 0.000000,
+       (GLfloat) 0.800000, (GLfloat) - 0.550000, (GLfloat) 0.000000,
+       (GLfloat) 0.794672, (GLfloat) - 0.523212, (GLfloat) 0.000000,
+       (GLfloat) 0.779498, (GLfloat) - 0.500503, (GLfloat) 0.000000,
+       (GLfloat) 0.756788, (GLfloat) - 0.485328, (GLfloat) 0.000000,
+       (GLfloat) 0.730000, (GLfloat) - 0.480000, (GLfloat) 0.000000,
+       (GLfloat) 0.703212, (GLfloat) - 0.485328, (GLfloat) 0.000000,
+       (GLfloat) 0.680503, (GLfloat) - 0.500503, (GLfloat) 0.000000,
+       (GLfloat) 0.665328, (GLfloat) - 0.523212, (GLfloat) 0.000000,
+       (GLfloat) 0.660000, (GLfloat) - 0.550000, (GLfloat) 0.000000,
+       (GLfloat) 0.665328, (GLfloat) - 0.576788, (GLfloat) 0.000000,
+       (GLfloat) 0.680503, (GLfloat) - 0.599497, (GLfloat) 0.000000,
+       (GLfloat) 0.703212, (GLfloat) - 0.614672, (GLfloat) 0.000000,
+       (GLfloat) 0.730000, (GLfloat) - 0.620000, (GLfloat) 0.000000,
+       (GLfloat) 0.756788, (GLfloat) - 0.602861, (GLfloat) - 0.119916,
+       (GLfloat) 0.779498, (GLfloat) - 0.587978, (GLfloat) - 0.116956,
+       (GLfloat) 0.794672, (GLfloat) - 0.565705, (GLfloat) - 0.112526,
+       (GLfloat) 0.800000, (GLfloat) - 0.539432, (GLfloat) - 0.107300,
+       (GLfloat) 0.794672, (GLfloat) - 0.513159, (GLfloat) - 0.102074,
+       (GLfloat) 0.779498, (GLfloat) - 0.490886, (GLfloat) - 0.097643,
+       (GLfloat) 0.756788, (GLfloat) - 0.476003, (GLfloat) - 0.094683,
+       (GLfloat) 0.730000, (GLfloat) - 0.470777, (GLfloat) - 0.093643,
+       (GLfloat) 0.703212, (GLfloat) - 0.476003, (GLfloat) - 0.094683,
+       (GLfloat) 0.680503, (GLfloat) - 0.490886, (GLfloat) - 0.097643,
+       (GLfloat) 0.665328, (GLfloat) - 0.513159, (GLfloat) - 0.102074,
+       (GLfloat) 0.660000, (GLfloat) - 0.539432, (GLfloat) - 0.107300,
+       (GLfloat) 0.665328, (GLfloat) - 0.565705, (GLfloat) - 0.112526,
+       (GLfloat) 0.680503, (GLfloat) - 0.587978, (GLfloat) - 0.116956,
+       (GLfloat) 0.703212, (GLfloat) - 0.602861, (GLfloat) - 0.119916,
+       (GLfloat) 0.730000, (GLfloat) - 0.608087, (GLfloat) - 0.120956,
+       (GLfloat) 0.756788, (GLfloat) - 0.567882, (GLfloat) - 0.235225,
+       (GLfloat) 0.779498, (GLfloat) - 0.553863, (GLfloat) - 0.229418,
+       (GLfloat) 0.794672, (GLfloat) - 0.532882, (GLfloat) - 0.220727,
+       (GLfloat) 0.800000, (GLfloat) - 0.508134, (GLfloat) - 0.210476,
+       (GLfloat) 0.794672, (GLfloat) - 0.483385, (GLfloat) - 0.200225,
+       (GLfloat) 0.779498, (GLfloat) - 0.462404, (GLfloat) - 0.191534,
+       (GLfloat) 0.756788, (GLfloat) - 0.448385, (GLfloat) - 0.185727,
+       (GLfloat) 0.730000, (GLfloat) - 0.443462, (GLfloat) - 0.183688,
+       (GLfloat) 0.703212, (GLfloat) - 0.448385, (GLfloat) - 0.185727,
+       (GLfloat) 0.680503, (GLfloat) - 0.462404, (GLfloat) - 0.191534,
+       (GLfloat) 0.665328, (GLfloat) - 0.483385, (GLfloat) - 0.200225,
+       (GLfloat) 0.660000, (GLfloat) - 0.508134, (GLfloat) - 0.210476,
+       (GLfloat) 0.665328, (GLfloat) - 0.532882, (GLfloat) - 0.220727,
+       (GLfloat) 0.680503, (GLfloat) - 0.553863, (GLfloat) - 0.229418,
+       (GLfloat) 0.703212, (GLfloat) - 0.567882, (GLfloat) - 0.235225,
+       (GLfloat) 0.730000, (GLfloat) - 0.572805, (GLfloat) - 0.237264,
+       (GLfloat) 0.756788, (GLfloat) - 0.511081, (GLfloat) - 0.341493,
+       (GLfloat) 0.779498, (GLfloat) - 0.498464, (GLfloat) - 0.333063,
+       (GLfloat) 0.794672, (GLfloat) - 0.479582, (GLfloat) - 0.320446,
+       (GLfloat) 0.800000, (GLfloat) - 0.457308, (GLfloat) - 0.305564,
+       (GLfloat) 0.794672, (GLfloat) - 0.435035, (GLfloat) - 0.290681,
+       (GLfloat) 0.779498, (GLfloat) - 0.416153, (GLfloat) - 0.278064,
+       (GLfloat) 0.756788, (GLfloat) - 0.403536, (GLfloat) - 0.269634,
+       (GLfloat) 0.730000, (GLfloat) - 0.399105, (GLfloat) - 0.266674,
+       (GLfloat) 0.703212, (GLfloat) - 0.403536, (GLfloat) - 0.269634,
+       (GLfloat) 0.680503, (GLfloat) - 0.416153, (GLfloat) - 0.278064,
+       (GLfloat) 0.665328, (GLfloat) - 0.435035, (GLfloat) - 0.290681,
+       (GLfloat) 0.660000, (GLfloat) - 0.457308, (GLfloat) - 0.305564,
+       (GLfloat) 0.665328, (GLfloat) - 0.479582, (GLfloat) - 0.320446,
+       (GLfloat) 0.680503, (GLfloat) - 0.498464, (GLfloat) - 0.333063,
+       (GLfloat) 0.703212, (GLfloat) - 0.511081, (GLfloat) - 0.341493,
+       (GLfloat) 0.730000, (GLfloat) - 0.515511, (GLfloat) - 0.344454,
+       (GLfloat) 0.756788, (GLfloat) - 0.434638, (GLfloat) - 0.434638,
+       (GLfloat) 0.779498, (GLfloat) - 0.423909, (GLfloat) - 0.423909,
+       (GLfloat) 0.794672, (GLfloat) - 0.407851, (GLfloat) - 0.407851,
+       (GLfloat) 0.800000, (GLfloat) - 0.388909, (GLfloat) - 0.388909,
+       (GLfloat) 0.794672, (GLfloat) - 0.369967, (GLfloat) - 0.369967,
+       (GLfloat) 0.779498, (GLfloat) - 0.353909, (GLfloat) - 0.353909,
+       (GLfloat) 0.756788, (GLfloat) - 0.343179, (GLfloat) - 0.343179,
+       (GLfloat) 0.730000, (GLfloat) - 0.339411, (GLfloat) - 0.339411,
+       (GLfloat) 0.703212, (GLfloat) - 0.343179, (GLfloat) - 0.343179,
+       (GLfloat) 0.680503, (GLfloat) - 0.353909, (GLfloat) - 0.353909,
+       (GLfloat) 0.665328, (GLfloat) - 0.369967, (GLfloat) - 0.369967,
+       (GLfloat) 0.660000, (GLfloat) - 0.388909, (GLfloat) - 0.388909,
+       (GLfloat) 0.665328, (GLfloat) - 0.407851, (GLfloat) - 0.407851,
+       (GLfloat) 0.680503, (GLfloat) - 0.423909, (GLfloat) - 0.423909,
+       (GLfloat) 0.703212, (GLfloat) - 0.434638, (GLfloat) - 0.434638,
+       (GLfloat) 0.730000, (GLfloat) - 0.438406, (GLfloat) - 0.438406,
+       (GLfloat) 0.756788, (GLfloat) - 0.341493, (GLfloat) - 0.511081,
+       (GLfloat) 0.779498, (GLfloat) - 0.333063, (GLfloat) - 0.498464,
+       (GLfloat) 0.794672, (GLfloat) - 0.320446, (GLfloat) - 0.479582,
+       (GLfloat) 0.800000, (GLfloat) - 0.305564, (GLfloat) - 0.457308,
+       (GLfloat) 0.794672, (GLfloat) - 0.290681, (GLfloat) - 0.435035,
+       (GLfloat) 0.779498, (GLfloat) - 0.278064, (GLfloat) - 0.416153,
+       (GLfloat) 0.756788, (GLfloat) - 0.269634, (GLfloat) - 0.403536,
+       (GLfloat) 0.730000, (GLfloat) - 0.266674, (GLfloat) - 0.399105,
+       (GLfloat) 0.703212, (GLfloat) - 0.269634, (GLfloat) - 0.403536,
+       (GLfloat) 0.680503, (GLfloat) - 0.278064, (GLfloat) - 0.416153,
+       (GLfloat) 0.665328, (GLfloat) - 0.290681, (GLfloat) - 0.435035,
+       (GLfloat) 0.660000, (GLfloat) - 0.305564, (GLfloat) - 0.457308,
+       (GLfloat) 0.665328, (GLfloat) - 0.320446, (GLfloat) - 0.479582,
+       (GLfloat) 0.680503, (GLfloat) - 0.333063, (GLfloat) - 0.498464,
+       (GLfloat) 0.703212, (GLfloat) - 0.341493, (GLfloat) - 0.511081,
+       (GLfloat) 0.730000, (GLfloat) - 0.344454, (GLfloat) - 0.515511,
+       (GLfloat) 0.756788, (GLfloat) - 0.235225, (GLfloat) - 0.567882,
+       (GLfloat) 0.779498, (GLfloat) - 0.229418, (GLfloat) - 0.553863,
+       (GLfloat) 0.794672, (GLfloat) - 0.220727, (GLfloat) - 0.532882,
+       (GLfloat) 0.800000, (GLfloat) - 0.210476, (GLfloat) - 0.508134,
+       (GLfloat) 0.794672, (GLfloat) - 0.200225, (GLfloat) - 0.483385,
+       (GLfloat) 0.779498, (GLfloat) - 0.191534, (GLfloat) - 0.462404,
+       (GLfloat) 0.756788, (GLfloat) - 0.185727, (GLfloat) - 0.448385,
+       (GLfloat) 0.730000, (GLfloat) - 0.183688, (GLfloat) - 0.443462,
+       (GLfloat) 0.703212, (GLfloat) - 0.185727, (GLfloat) - 0.448385,
+       (GLfloat) 0.680503, (GLfloat) - 0.191534, (GLfloat) - 0.462404,
+       (GLfloat) 0.665328, (GLfloat) - 0.200225, (GLfloat) - 0.483385,
+       (GLfloat) 0.660000, (GLfloat) - 0.210476, (GLfloat) - 0.508134,
+       (GLfloat) 0.665328, (GLfloat) - 0.220727, (GLfloat) - 0.532882,
+       (GLfloat) 0.680503, (GLfloat) - 0.229418, (GLfloat) - 0.553863,
+       (GLfloat) 0.703212, (GLfloat) - 0.235225, (GLfloat) - 0.567882,
+       (GLfloat) 0.730000, (GLfloat) - 0.237264, (GLfloat) - 0.572805,
+       (GLfloat) 0.756788, (GLfloat) - 0.119916, (GLfloat) - 0.602861,
+       (GLfloat) 0.779498, (GLfloat) - 0.116956, (GLfloat) - 0.587978,
+       (GLfloat) 0.794672, (GLfloat) - 0.112526, (GLfloat) - 0.565705,
+       (GLfloat) 0.800000, (GLfloat) - 0.107300, (GLfloat) - 0.539432,
+       (GLfloat) 0.794672, (GLfloat) - 0.102074, (GLfloat) - 0.513159,
+       (GLfloat) 0.779498, (GLfloat) - 0.097643, (GLfloat) - 0.490885,
+       (GLfloat) 0.756788, (GLfloat) - 0.094683, (GLfloat) - 0.476003,
+       (GLfloat) 0.730000, (GLfloat) - 0.093643, (GLfloat) - 0.470777,
+       (GLfloat) 0.703212, (GLfloat) - 0.094683, (GLfloat) - 0.476003,
+       (GLfloat) 0.680503, (GLfloat) - 0.097643, (GLfloat) - 0.490885,
+       (GLfloat) 0.665328, (GLfloat) - 0.102074, (GLfloat) - 0.513159,
+       (GLfloat) 0.660000, (GLfloat) - 0.107300, (GLfloat) - 0.539432,
+       (GLfloat) 0.665328, (GLfloat) - 0.112526, (GLfloat) - 0.565705,
+       (GLfloat) 0.680503, (GLfloat) - 0.116956, (GLfloat) - 0.587978,
+       (GLfloat) 0.703212, (GLfloat) - 0.119916, (GLfloat) - 0.602861,
+       (GLfloat) 0.730000, (GLfloat) - 0.120956, (GLfloat) - 0.608087,
+       (GLfloat) 0.756788, (GLfloat) - 0.000000, (GLfloat) - 0.614672,
+       (GLfloat) 0.779498, (GLfloat) - 0.000000, (GLfloat) - 0.599497,
+       (GLfloat) 0.794672, (GLfloat) - 0.000000, (GLfloat) - 0.576788,
+       (GLfloat) 0.800000, (GLfloat) - 0.000000, (GLfloat) - 0.550000,
+       (GLfloat) 0.794672, (GLfloat) - 0.000000, (GLfloat) - 0.523212,
+       (GLfloat) 0.779498, (GLfloat) - 0.000000, (GLfloat) - 0.500503,
+       (GLfloat) 0.756788, (GLfloat) - 0.000000, (GLfloat) - 0.485328,
+       (GLfloat) 0.730000, (GLfloat) - 0.000000, (GLfloat) - 0.480000,
+       (GLfloat) 0.703212, (GLfloat) - 0.000000, (GLfloat) - 0.485328,
+       (GLfloat) 0.680503, (GLfloat) - 0.000000, (GLfloat) - 0.500503,
+       (GLfloat) 0.665328, (GLfloat) - 0.000000, (GLfloat) - 0.523212,
+       (GLfloat) 0.660000, (GLfloat) - 0.000000, (GLfloat) - 0.550000,
+       (GLfloat) 0.665328, (GLfloat) - 0.000000, (GLfloat) - 0.576788,
+       (GLfloat) 0.680503, (GLfloat) - 0.000000, (GLfloat) - 0.599497,
+       (GLfloat) 0.703212, (GLfloat) - 0.000000, (GLfloat) - 0.614672,
+       (GLfloat) 0.730000, (GLfloat) - 0.000000, (GLfloat) - 0.620000,
+       (GLfloat) 0.756788, (GLfloat) 0.119916, (GLfloat) - 0.602861,
+       (GLfloat) 0.779498, (GLfloat) 0.116956, (GLfloat) - 0.587978,
+       (GLfloat) 0.794672, (GLfloat) 0.112526, (GLfloat) - 0.565705,
+       (GLfloat) 0.800000, (GLfloat) 0.107300, (GLfloat) - 0.539432,
+       (GLfloat) 0.794672, (GLfloat) 0.102074, (GLfloat) - 0.513159,
+       (GLfloat) 0.779498, (GLfloat) 0.097643, (GLfloat) - 0.490886,
+       (GLfloat) 0.756788, (GLfloat) 0.094683, (GLfloat) - 0.476003,
+       (GLfloat) 0.730000, (GLfloat) 0.093643, (GLfloat) - 0.470777,
+       (GLfloat) 0.703212, (GLfloat) 0.094683, (GLfloat) - 0.476003,
+       (GLfloat) 0.680503, (GLfloat) 0.097643, (GLfloat) - 0.490886,
+       (GLfloat) 0.665328, (GLfloat) 0.102074, (GLfloat) - 0.513159,
+       (GLfloat) 0.660000, (GLfloat) 0.107300, (GLfloat) - 0.539432,
+       (GLfloat) 0.665328, (GLfloat) 0.112526, (GLfloat) - 0.565705,
+       (GLfloat) 0.680503, (GLfloat) 0.116956, (GLfloat) - 0.587978,
+       (GLfloat) 0.703212, (GLfloat) 0.119916, (GLfloat) - 0.602861,
+       (GLfloat) 0.730000, (GLfloat) 0.120956, (GLfloat) - 0.608087,
+       (GLfloat) 0.756788, (GLfloat) 0.235225, (GLfloat) - 0.567882,
+       (GLfloat) 0.779498, (GLfloat) 0.229418, (GLfloat) - 0.553863,
+       (GLfloat) 0.794672, (GLfloat) 0.220727, (GLfloat) - 0.532882,
+       (GLfloat) 0.800000, (GLfloat) 0.210476, (GLfloat) - 0.508134,
+       (GLfloat) 0.794672, (GLfloat) 0.200225, (GLfloat) - 0.483385,
+       (GLfloat) 0.779498, (GLfloat) 0.191534, (GLfloat) - 0.462404,
+       (GLfloat) 0.756788, (GLfloat) 0.185727, (GLfloat) - 0.448385,
+       (GLfloat) 0.730000, (GLfloat) 0.183688, (GLfloat) - 0.443462,
+       (GLfloat) 0.703212, (GLfloat) 0.185727, (GLfloat) - 0.448385,
+       (GLfloat) 0.680503, (GLfloat) 0.191534, (GLfloat) - 0.462404,
+       (GLfloat) 0.665328, (GLfloat) 0.200225, (GLfloat) - 0.483385,
+       (GLfloat) 0.660000, (GLfloat) 0.210476, (GLfloat) - 0.508134,
+       (GLfloat) 0.665328, (GLfloat) 0.220727, (GLfloat) - 0.532882,
+       (GLfloat) 0.680503, (GLfloat) 0.229418, (GLfloat) - 0.553863,
+       (GLfloat) 0.703212, (GLfloat) 0.235225, (GLfloat) - 0.567882,
+       (GLfloat) 0.730000, (GLfloat) 0.237264, (GLfloat) - 0.572805,
+       (GLfloat) 0.756788, (GLfloat) 0.341493, (GLfloat) - 0.511081,
+       (GLfloat) 0.779498, (GLfloat) 0.333063, (GLfloat) - 0.498464,
+       (GLfloat) 0.794672, (GLfloat) 0.320446, (GLfloat) - 0.479582,
+       (GLfloat) 0.800000, (GLfloat) 0.305564, (GLfloat) - 0.457308,
+       (GLfloat) 0.794672, (GLfloat) 0.290681, (GLfloat) - 0.435035,
+       (GLfloat) 0.779498, (GLfloat) 0.278064, (GLfloat) - 0.416153,
+       (GLfloat) 0.756788, (GLfloat) 0.269634, (GLfloat) - 0.403536,
+       (GLfloat) 0.730000, (GLfloat) 0.266674, (GLfloat) - 0.399105,
+       (GLfloat) 0.703212, (GLfloat) 0.269634, (GLfloat) - 0.403536,
+       (GLfloat) 0.680503, (GLfloat) 0.278064, (GLfloat) - 0.416153,
+       (GLfloat) 0.665328, (GLfloat) 0.290681, (GLfloat) - 0.435035,
+       (GLfloat) 0.660000, (GLfloat) 0.305564, (GLfloat) - 0.457308,
+       (GLfloat) 0.665328, (GLfloat) 0.320446, (GLfloat) - 0.479582,
+       (GLfloat) 0.680503, (GLfloat) 0.333063, (GLfloat) - 0.498464,
+       (GLfloat) 0.703212, (GLfloat) 0.341493, (GLfloat) - 0.511081,
+       (GLfloat) 0.730000, (GLfloat) 0.344454, (GLfloat) - 0.515511,
+       (GLfloat) 0.756788, (GLfloat) 0.434638, (GLfloat) - 0.434638,
+       (GLfloat) 0.779498, (GLfloat) 0.423909, (GLfloat) - 0.423909,
+       (GLfloat) 0.794672, (GLfloat) 0.407851, (GLfloat) - 0.407851,
+       (GLfloat) 0.800000, (GLfloat) 0.388909, (GLfloat) - 0.388909,
+       (GLfloat) 0.794672, (GLfloat) 0.369967, (GLfloat) - 0.369967,
+       (GLfloat) 0.779498, (GLfloat) 0.353909, (GLfloat) - 0.353909,
+       (GLfloat) 0.756788, (GLfloat) 0.343179, (GLfloat) - 0.343179,
+       (GLfloat) 0.730000, (GLfloat) 0.339411, (GLfloat) - 0.339411,
+       (GLfloat) 0.703212, (GLfloat) 0.343179, (GLfloat) - 0.343179,
+       (GLfloat) 0.680503, (GLfloat) 0.353909, (GLfloat) - 0.353909,
+       (GLfloat) 0.665328, (GLfloat) 0.369967, (GLfloat) - 0.369967,
+       (GLfloat) 0.660000, (GLfloat) 0.388909, (GLfloat) - 0.388909,
+       (GLfloat) 0.665328, (GLfloat) 0.407851, (GLfloat) - 0.407851,
+       (GLfloat) 0.680503, (GLfloat) 0.423909, (GLfloat) - 0.423909,
+       (GLfloat) 0.703212, (GLfloat) 0.434638, (GLfloat) - 0.434638,
+       (GLfloat) 0.730000, (GLfloat) 0.438406, (GLfloat) - 0.438406,
+       (GLfloat) 0.756788, (GLfloat) 0.511081, (GLfloat) - 0.341493,
+       (GLfloat) 0.779498, (GLfloat) 0.498464, (GLfloat) - 0.333063,
+       (GLfloat) 0.794672, (GLfloat) 0.479582, (GLfloat) - 0.320446,
+       (GLfloat) 0.800000, (GLfloat) 0.457308, (GLfloat) - 0.305564,
+       (GLfloat) 0.794672, (GLfloat) 0.435035, (GLfloat) - 0.290681,
+       (GLfloat) 0.779498, (GLfloat) 0.416153, (GLfloat) - 0.278064,
+       (GLfloat) 0.756788, (GLfloat) 0.403536, (GLfloat) - 0.269634,
+       (GLfloat) 0.730000, (GLfloat) 0.399105, (GLfloat) - 0.266674,
+       (GLfloat) 0.703212, (GLfloat) 0.403536, (GLfloat) - 0.269634,
+       (GLfloat) 0.680503, (GLfloat) 0.416153, (GLfloat) - 0.278064,
+       (GLfloat) 0.665328, (GLfloat) 0.435035, (GLfloat) - 0.290681,
+       (GLfloat) 0.660000, (GLfloat) 0.457308, (GLfloat) - 0.305564,
+       (GLfloat) 0.665328, (GLfloat) 0.479582, (GLfloat) - 0.320446,
+       (GLfloat) 0.680503, (GLfloat) 0.498464, (GLfloat) - 0.333063,
+       (GLfloat) 0.703212, (GLfloat) 0.511081, (GLfloat) - 0.341493,
+       (GLfloat) 0.730000, (GLfloat) 0.515511, (GLfloat) - 0.344454,
+       (GLfloat) 0.756788, (GLfloat) 0.567882, (GLfloat) - 0.235225,
+       (GLfloat) 0.779498, (GLfloat) 0.553863, (GLfloat) - 0.229418,
+       (GLfloat) 0.794672, (GLfloat) 0.532882, (GLfloat) - 0.220727,
+       (GLfloat) 0.800000, (GLfloat) 0.508134, (GLfloat) - 0.210476,
+       (GLfloat) 0.794672, (GLfloat) 0.483385, (GLfloat) - 0.200225,
+       (GLfloat) 0.779498, (GLfloat) 0.462404, (GLfloat) - 0.191534,
+       (GLfloat) 0.756788, (GLfloat) 0.448385, (GLfloat) - 0.185727,
+       (GLfloat) 0.730000, (GLfloat) 0.443462, (GLfloat) - 0.183688,
+       (GLfloat) 0.703212, (GLfloat) 0.448385, (GLfloat) - 0.185727,
+       (GLfloat) 0.680503, (GLfloat) 0.462404, (GLfloat) - 0.191534,
+       (GLfloat) 0.665328, (GLfloat) 0.483385, (GLfloat) - 0.200225,
+       (GLfloat) 0.660000, (GLfloat) 0.508134, (GLfloat) - 0.210476,
+       (GLfloat) 0.665328, (GLfloat) 0.532882, (GLfloat) - 0.220727,
+       (GLfloat) 0.680503, (GLfloat) 0.553863, (GLfloat) - 0.229418,
+       (GLfloat) 0.703212, (GLfloat) 0.567882, (GLfloat) - 0.235225,
+       (GLfloat) 0.730000, (GLfloat) 0.572805, (GLfloat) - 0.237264,
+       (GLfloat) 0.756788, (GLfloat) 0.602861, (GLfloat) - 0.119916,
+       (GLfloat) 0.779498, (GLfloat) 0.587978, (GLfloat) - 0.116956,
+       (GLfloat) 0.794672, (GLfloat) 0.565705, (GLfloat) - 0.112526,
+       (GLfloat) 0.800000, (GLfloat) 0.539432, (GLfloat) - 0.107300,
+       (GLfloat) 0.794672, (GLfloat) 0.513159, (GLfloat) - 0.102074,
+       (GLfloat) 0.779498, (GLfloat) 0.490885, (GLfloat) - 0.097643,
+       (GLfloat) 0.756788, (GLfloat) 0.476003, (GLfloat) - 0.094683,
+       (GLfloat) 0.730000, (GLfloat) 0.470777, (GLfloat) - 0.093643,
+       (GLfloat) 0.703212, (GLfloat) 0.476003, (GLfloat) - 0.094683,
+       (GLfloat) 0.680503, (GLfloat) 0.490885, (GLfloat) - 0.097643,
+       (GLfloat) 0.665328, (GLfloat) 0.513159, (GLfloat) - 0.102074,
+       (GLfloat) 0.660000, (GLfloat) 0.539432, (GLfloat) - 0.107300,
+       (GLfloat) 0.665328, (GLfloat) 0.565705, (GLfloat) - 0.112526,
+       (GLfloat) 0.680503, (GLfloat) 0.587978, (GLfloat) - 0.116956,
+       (GLfloat) 0.703212, (GLfloat) 0.602861, (GLfloat) - 0.119916,
+       (GLfloat) 0.730000, (GLfloat) 0.608087, (GLfloat) - 0.120956,
+       (GLfloat) 0.420000, (GLfloat) - 0.000000, (GLfloat) - 0.200000,
+       (GLfloat) 0.420000, (GLfloat) 0.051764, (GLfloat) - 0.193185,
+       (GLfloat) 0.420000, (GLfloat) 0.100000, (GLfloat) - 0.173205,
+       (GLfloat) 0.420000, (GLfloat) 0.141421, (GLfloat) - 0.141421,
+       (GLfloat) 0.420000, (GLfloat) 0.173205, (GLfloat) - 0.100000,
+       (GLfloat) 0.420000, (GLfloat) 0.193185, (GLfloat) - 0.051764,
+       (GLfloat) 0.420000, (GLfloat) 0.200000, (GLfloat) - 0.000000,
+       (GLfloat) 0.420000, (GLfloat) 0.193185, (GLfloat) 0.051764,
+       (GLfloat) 0.420000, (GLfloat) 0.173205, (GLfloat) 0.100000,
+       (GLfloat) 0.420000, (GLfloat) 0.141421, (GLfloat) 0.141421,
+       (GLfloat) 0.420000, (GLfloat) 0.100000, (GLfloat) 0.173205,
+       (GLfloat) 0.420000, (GLfloat) 0.051764, (GLfloat) 0.193185,
+       (GLfloat) 0.420000, (GLfloat) 0.000000, (GLfloat) 0.200000,
+       (GLfloat) 0.420000, (GLfloat) - 0.051764, (GLfloat) 0.193185,
+       (GLfloat) 0.420000, (GLfloat) - 0.100000, (GLfloat) 0.173205,
+       (GLfloat) 0.420000, (GLfloat) - 0.141421, (GLfloat) 0.141421,
+       (GLfloat) 0.420000, (GLfloat) - 0.173205, (GLfloat) 0.100000,
+       (GLfloat) 0.420000, (GLfloat) - 0.193185, (GLfloat) 0.051764,
+       (GLfloat) 0.420000, (GLfloat) - 0.200000, (GLfloat) 0.000000,
+       (GLfloat) 0.420000, (GLfloat) - 0.193185, (GLfloat) - 0.051764,
+       (GLfloat) 0.420000, (GLfloat) - 0.173205, (GLfloat) - 0.100000,
+       (GLfloat) 0.420000, (GLfloat) - 0.141421, (GLfloat) - 0.141421,
+       (GLfloat) 0.420000, (GLfloat) - 0.100000, (GLfloat) - 0.173205,
+       (GLfloat) 0.420000, (GLfloat) - 0.051764, (GLfloat) - 0.193185,
+       (GLfloat) 0.540000, (GLfloat) - 0.000000, (GLfloat) - 0.200000,
+       (GLfloat) 0.540000, (GLfloat) 0.051764, (GLfloat) - 0.193185,
+       (GLfloat) 0.540000, (GLfloat) 0.100000, (GLfloat) - 0.173205,
+       (GLfloat) 0.540000, (GLfloat) 0.141421, (GLfloat) - 0.141421,
+       (GLfloat) 0.540000, (GLfloat) 0.173205, (GLfloat) - 0.100000,
+       (GLfloat) 0.540000, (GLfloat) 0.193185, (GLfloat) - 0.051764,
+       (GLfloat) 0.540000, (GLfloat) 0.200000, (GLfloat) - 0.000000,
+       (GLfloat) 0.540000, (GLfloat) 0.193185, (GLfloat) 0.051764,
+       (GLfloat) 0.540000, (GLfloat) 0.173205, (GLfloat) 0.100000,
+       (GLfloat) 0.540000, (GLfloat) 0.141421, (GLfloat) 0.141421,
+       (GLfloat) 0.540000, (GLfloat) 0.100000, (GLfloat) 0.173205,
+       (GLfloat) 0.540000, (GLfloat) 0.051764, (GLfloat) 0.193185,
+       (GLfloat) 0.540000, (GLfloat) 0.000000, (GLfloat) 0.200000,
+       (GLfloat) 0.540000, (GLfloat) - 0.051764, (GLfloat) 0.193185,
+       (GLfloat) 0.540000, (GLfloat) - 0.100000, (GLfloat) 0.173205,
+       (GLfloat) 0.540000, (GLfloat) - 0.141421, (GLfloat) 0.141421,
+       (GLfloat) 0.540000, (GLfloat) - 0.173205, (GLfloat) 0.100000,
+       (GLfloat) 0.540000, (GLfloat) - 0.193185, (GLfloat) 0.051764,
+       (GLfloat) 0.540000, (GLfloat) - 0.200000, (GLfloat) 0.000000,
+       (GLfloat) 0.540000, (GLfloat) - 0.193185, (GLfloat) - 0.051764,
+       (GLfloat) 0.540000, (GLfloat) - 0.173205, (GLfloat) - 0.100000,
+       (GLfloat) 0.540000, (GLfloat) - 0.141421, (GLfloat) - 0.141421,
+       (GLfloat) 0.540000, (GLfloat) - 0.100000, (GLfloat) - 0.173205,
+       (GLfloat) 0.540000, (GLfloat) - 0.051764, (GLfloat) - 0.193185,
+       (GLfloat) 0.790000, (GLfloat) 0.060000, (GLfloat) - 0.000000,
+       (GLfloat) 0.785433, (GLfloat) 0.060000, (GLfloat) - 0.022961,
+       (GLfloat) 0.772426, (GLfloat) 0.060000, (GLfloat) - 0.042426,
+       (GLfloat) 0.752961, (GLfloat) 0.060000, (GLfloat) - 0.055433,
+       (GLfloat) 0.730000, (GLfloat) 0.060000, (GLfloat) - 0.060000,
+       (GLfloat) 0.707039, (GLfloat) 0.060000, (GLfloat) - 0.055433,
+       (GLfloat) 0.687574, (GLfloat) 0.060000, (GLfloat) - 0.042426,
+       (GLfloat) 0.674567, (GLfloat) 0.060000, (GLfloat) - 0.022961,
+       (GLfloat) 0.670000, (GLfloat) 0.060000, (GLfloat) - 0.000000,
+       (GLfloat) 0.674567, (GLfloat) 0.060000, (GLfloat) 0.022961,
+       (GLfloat) 0.687574, (GLfloat) 0.060000, (GLfloat) 0.042426,
+       (GLfloat) 0.707039, (GLfloat) 0.060000, (GLfloat) 0.055433,
+       (GLfloat) 0.730000, (GLfloat) 0.060000, (GLfloat) 0.060000,
+       (GLfloat) 0.752961, (GLfloat) 0.060000, (GLfloat) 0.055433,
+       (GLfloat) 0.772426, (GLfloat) 0.060000, (GLfloat) 0.042426,
+       (GLfloat) 0.785433, (GLfloat) 0.060000, (GLfloat) 0.022961,
+       (GLfloat) 0.790000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) 0.785433, (GLfloat) 0.550000, (GLfloat) - 0.022961,
+       (GLfloat) 0.772426, (GLfloat) 0.550000, (GLfloat) - 0.042426,
+       (GLfloat) 0.752961, (GLfloat) 0.550000, (GLfloat) - 0.055433,
+       (GLfloat) 0.730000, (GLfloat) 0.550000, (GLfloat) - 0.060000,
+       (GLfloat) 0.707039, (GLfloat) 0.550000, (GLfloat) - 0.055433,
+       (GLfloat) 0.687574, (GLfloat) 0.550000, (GLfloat) - 0.042426,
+       (GLfloat) 0.674567, (GLfloat) 0.550000, (GLfloat) - 0.022961,
+       (GLfloat) 0.670000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) 0.674567, (GLfloat) 0.550000, (GLfloat) 0.022961,
+       (GLfloat) 0.687574, (GLfloat) 0.550000, (GLfloat) 0.042426,
+       (GLfloat) 0.707039, (GLfloat) 0.550000, (GLfloat) 0.055433,
+       (GLfloat) 0.730000, (GLfloat) 0.550000, (GLfloat) 0.060000,
+       (GLfloat) 0.752961, (GLfloat) 0.550000, (GLfloat) 0.055433,
+       (GLfloat) 0.772426, (GLfloat) 0.550000, (GLfloat) 0.042426,
+       (GLfloat) 0.785433, (GLfloat) 0.550000, (GLfloat) 0.022961,
+       (GLfloat) 0.790000, (GLfloat) 0.000000, (GLfloat) 0.060000,
+       (GLfloat) 0.785433, (GLfloat) 0.022961, (GLfloat) 0.060000,
+       (GLfloat) 0.772426, (GLfloat) 0.042426, (GLfloat) 0.060000,
+       (GLfloat) 0.752961, (GLfloat) 0.055433, (GLfloat) 0.060000,
+       (GLfloat) 0.707039, (GLfloat) 0.055433, (GLfloat) 0.060000,
+       (GLfloat) 0.687574, (GLfloat) 0.042426, (GLfloat) 0.060000,
+       (GLfloat) 0.674567, (GLfloat) 0.022961, (GLfloat) 0.060000,
+       (GLfloat) 0.670000, (GLfloat) 0.000000, (GLfloat) 0.060000,
+       (GLfloat) 0.674567, (GLfloat) - 0.022961, (GLfloat) 0.060000,
+       (GLfloat) 0.687574, (GLfloat) - 0.042426, (GLfloat) 0.060000,
+       (GLfloat) 0.707039, (GLfloat) - 0.055433, (GLfloat) 0.060000,
+       (GLfloat) 0.730000, (GLfloat) - 0.060000, (GLfloat) 0.060000,
+       (GLfloat) 0.752961, (GLfloat) - 0.055433, (GLfloat) 0.060000,
+       (GLfloat) 0.772426, (GLfloat) - 0.042426, (GLfloat) 0.060000,
+       (GLfloat) 0.785433, (GLfloat) - 0.022961, (GLfloat) 0.060000,
+       (GLfloat) 0.790000, (GLfloat) 0.000000, (GLfloat) 0.550000,
+       (GLfloat) 0.785433, (GLfloat) 0.022961, (GLfloat) 0.550000,
+       (GLfloat) 0.772426, (GLfloat) 0.042426, (GLfloat) 0.550000,
+       (GLfloat) 0.752961, (GLfloat) 0.055433, (GLfloat) 0.550000,
+       (GLfloat) 0.730000, (GLfloat) 0.060000, (GLfloat) 0.550000,
+       (GLfloat) 0.707039, (GLfloat) 0.055433, (GLfloat) 0.550000,
+       (GLfloat) 0.687574, (GLfloat) 0.042426, (GLfloat) 0.550000,
+       (GLfloat) 0.674567, (GLfloat) 0.022961, (GLfloat) 0.550000,
+       (GLfloat) 0.670000, (GLfloat) 0.000000, (GLfloat) 0.550000,
+       (GLfloat) 0.674567, (GLfloat) - 0.022961, (GLfloat) 0.550000,
+       (GLfloat) 0.687574, (GLfloat) - 0.042426, (GLfloat) 0.550000,
+       (GLfloat) 0.707039, (GLfloat) - 0.055433, (GLfloat) 0.550000,
+       (GLfloat) 0.730000, (GLfloat) - 0.060000, (GLfloat) 0.550000,
+       (GLfloat) 0.752961, (GLfloat) - 0.055433, (GLfloat) 0.550000,
+       (GLfloat) 0.772426, (GLfloat) - 0.042426, (GLfloat) 0.550000,
+       (GLfloat) 0.785433, (GLfloat) - 0.022961, (GLfloat) 0.550000,
+       (GLfloat) 0.790000, (GLfloat) - 0.060000, (GLfloat) 0.000000,
+       (GLfloat) 0.785433, (GLfloat) - 0.060000, (GLfloat) 0.022961,
+       (GLfloat) 0.772426, (GLfloat) - 0.060000, (GLfloat) 0.042426,
+       (GLfloat) 0.752961, (GLfloat) - 0.060000, (GLfloat) 0.055433,
+       (GLfloat) 0.707039, (GLfloat) - 0.060000, (GLfloat) 0.055433,
+       (GLfloat) 0.687574, (GLfloat) - 0.060000, (GLfloat) 0.042426,
+       (GLfloat) 0.674567, (GLfloat) - 0.060000, (GLfloat) 0.022961,
+       (GLfloat) 0.670000, (GLfloat) - 0.060000, (GLfloat) 0.000000,
+       (GLfloat) 0.674567, (GLfloat) - 0.060000, (GLfloat) - 0.022961,
+       (GLfloat) 0.687574, (GLfloat) - 0.060000, (GLfloat) - 0.042426,
+       (GLfloat) 0.707039, (GLfloat) - 0.060000, (GLfloat) - 0.055433,
+       (GLfloat) 0.730000, (GLfloat) - 0.060000, (GLfloat) - 0.060000,
+       (GLfloat) 0.752961, (GLfloat) - 0.060000, (GLfloat) - 0.055433,
+       (GLfloat) 0.772426, (GLfloat) - 0.060000, (GLfloat) - 0.042426,
+       (GLfloat) 0.785433, (GLfloat) - 0.060000, (GLfloat) - 0.022961,
+       (GLfloat) 0.790000, (GLfloat) - 0.550000, (GLfloat) 0.000000,
+       (GLfloat) 0.785433, (GLfloat) - 0.550000, (GLfloat) 0.022961,
+       (GLfloat) 0.772426, (GLfloat) - 0.550000, (GLfloat) 0.042426,
+       (GLfloat) 0.752961, (GLfloat) - 0.550000, (GLfloat) 0.055433,
+       (GLfloat) 0.730000, (GLfloat) - 0.550000, (GLfloat) 0.060000,
+       (GLfloat) 0.707039, (GLfloat) - 0.550000, (GLfloat) 0.055433,
+       (GLfloat) 0.687574, (GLfloat) - 0.550000, (GLfloat) 0.042426,
+       (GLfloat) 0.674567, (GLfloat) - 0.550000, (GLfloat) 0.022961,
+       (GLfloat) 0.670000, (GLfloat) - 0.550000, (GLfloat) 0.000000,
+       (GLfloat) 0.674567, (GLfloat) - 0.550000, (GLfloat) - 0.022961,
+       (GLfloat) 0.687574, (GLfloat) - 0.550000, (GLfloat) - 0.042426,
+       (GLfloat) 0.707039, (GLfloat) - 0.550000, (GLfloat) - 0.055433,
+       (GLfloat) 0.730000, (GLfloat) - 0.550000, (GLfloat) - 0.060000,
+       (GLfloat) 0.752961, (GLfloat) - 0.550000, (GLfloat) - 0.055433,
+       (GLfloat) 0.772426, (GLfloat) - 0.550000, (GLfloat) - 0.042426,
+       (GLfloat) 0.785433, (GLfloat) - 0.550000, (GLfloat) - 0.022961,
+       (GLfloat) 0.790000, (GLfloat) - 0.000000, (GLfloat) - 0.060000,
+       (GLfloat) 0.785433, (GLfloat) - 0.022961, (GLfloat) - 0.060000,
+       (GLfloat) 0.772426, (GLfloat) - 0.042426, (GLfloat) - 0.060000,
+       (GLfloat) 0.752961, (GLfloat) - 0.055433, (GLfloat) - 0.060000,
+       (GLfloat) 0.707039, (GLfloat) - 0.055433, (GLfloat) - 0.060000,
+       (GLfloat) 0.687574, (GLfloat) - 0.042426, (GLfloat) - 0.060000,
+       (GLfloat) 0.674567, (GLfloat) - 0.022961, (GLfloat) - 0.060000,
+       (GLfloat) 0.670000, (GLfloat) - 0.000000, (GLfloat) - 0.060000,
+       (GLfloat) 0.674567, (GLfloat) 0.022961, (GLfloat) - 0.060000,
+       (GLfloat) 0.687574, (GLfloat) 0.042426, (GLfloat) - 0.060000,
+       (GLfloat) 0.707039, (GLfloat) 0.055433, (GLfloat) - 0.060000,
+       (GLfloat) 0.752961, (GLfloat) 0.055433, (GLfloat) - 0.060000,
+       (GLfloat) 0.772426, (GLfloat) 0.042426, (GLfloat) - 0.060000,
+       (GLfloat) 0.785433, (GLfloat) 0.022961, (GLfloat) - 0.060000,
+       (GLfloat) 0.790000, (GLfloat) - 0.000000, (GLfloat) - 0.550000,
+       (GLfloat) 0.785433, (GLfloat) - 0.022961, (GLfloat) - 0.550000,
+       (GLfloat) 0.772426, (GLfloat) - 0.042426, (GLfloat) - 0.550000,
+       (GLfloat) 0.752961, (GLfloat) - 0.055433, (GLfloat) - 0.550000,
+       (GLfloat) 0.730000, (GLfloat) - 0.060000, (GLfloat) - 0.550000,
+       (GLfloat) 0.707039, (GLfloat) - 0.055433, (GLfloat) - 0.550000,
+       (GLfloat) 0.687574, (GLfloat) - 0.042426, (GLfloat) - 0.550000,
+       (GLfloat) 0.674567, (GLfloat) - 0.022961, (GLfloat) - 0.550000,
+       (GLfloat) 0.670000, (GLfloat) - 0.000000, (GLfloat) - 0.550000,
+       (GLfloat) 0.674567, (GLfloat) 0.022961, (GLfloat) - 0.550000,
+       (GLfloat) 0.687574, (GLfloat) 0.042426, (GLfloat) - 0.550000,
+       (GLfloat) 0.707039, (GLfloat) 0.055433, (GLfloat) - 0.550000,
+       (GLfloat) 0.730000, (GLfloat) 0.060000, (GLfloat) - 0.550000,
+       (GLfloat) 0.752961, (GLfloat) 0.055433, (GLfloat) - 0.550000,
+       (GLfloat) 0.772426, (GLfloat) 0.042426, (GLfloat) - 0.550000,
+       (GLfloat) 0.785433, (GLfloat) 0.022961, (GLfloat) - 0.550000,
+       (GLfloat) 0.540000, (GLfloat) 0.000000, (GLfloat) - 0.100000,
+       (GLfloat) 0.540000, (GLfloat) 0.038268, (GLfloat) - 0.092388,
+       (GLfloat) 0.540000, (GLfloat) 0.070711, (GLfloat) - 0.070711,
+       (GLfloat) 0.540000, (GLfloat) 0.092388, (GLfloat) - 0.038268,
+       (GLfloat) 0.540000, (GLfloat) 0.100000, (GLfloat) - 0.000000,
+       (GLfloat) 0.540000, (GLfloat) 0.092388, (GLfloat) 0.038268,
+       (GLfloat) 0.540000, (GLfloat) 0.070711, (GLfloat) 0.070711,
+       (GLfloat) 0.540000, (GLfloat) 0.038268, (GLfloat) 0.092388,
+       (GLfloat) 0.540000, (GLfloat) 0.000000, (GLfloat) 0.100000,
+       (GLfloat) 0.540000, (GLfloat) - 0.038268, (GLfloat) 0.092388,
+       (GLfloat) 0.540000, (GLfloat) - 0.070711, (GLfloat) 0.070711,
+       (GLfloat) 0.540000, (GLfloat) - 0.092388, (GLfloat) 0.038268,
+       (GLfloat) 0.540000, (GLfloat) - 0.100000, (GLfloat) 0.000000,
+       (GLfloat) 0.540000, (GLfloat) - 0.092388, (GLfloat) - 0.038268,
+       (GLfloat) 0.540000, (GLfloat) - 0.070711, (GLfloat) - 0.070711,
+       (GLfloat) 0.540000, (GLfloat) - 0.038268, (GLfloat) - 0.092388,
+       (GLfloat) 0.800000, (GLfloat) 0.000000, (GLfloat) - 0.100000,
+       (GLfloat) 0.800000, (GLfloat) 0.038268, (GLfloat) - 0.092388,
+       (GLfloat) 0.800000, (GLfloat) 0.070711, (GLfloat) - 0.070711,
+       (GLfloat) 0.800000, (GLfloat) 0.092388, (GLfloat) - 0.038268,
+       (GLfloat) 0.800000, (GLfloat) 0.100000, (GLfloat) - 0.000000,
+       (GLfloat) 0.800000, (GLfloat) 0.092388, (GLfloat) 0.038268,
+       (GLfloat) 0.800000, (GLfloat) 0.070711, (GLfloat) 0.070711,
+       (GLfloat) 0.800000, (GLfloat) 0.038268, (GLfloat) 0.092388,
+       (GLfloat) 0.800000, (GLfloat) 0.000000, (GLfloat) 0.100000,
+       (GLfloat) 0.800000, (GLfloat) - 0.038268, (GLfloat) 0.092388,
+       (GLfloat) 0.800000, (GLfloat) - 0.070711, (GLfloat) 0.070711,
+       (GLfloat) 0.800000, (GLfloat) - 0.092388, (GLfloat) 0.038268,
+       (GLfloat) 0.800000, (GLfloat) - 0.100000, (GLfloat) 0.000000,
+       (GLfloat) 0.800000, (GLfloat) - 0.092388, (GLfloat) - 0.038268,
+       (GLfloat) 0.800000, (GLfloat) - 0.070711, (GLfloat) - 0.070711,
+       (GLfloat) 0.800000, (GLfloat) - 0.038268, (GLfloat) - 0.092388,
+};
+
+static GLfloat BigValve_normals[] =
+{
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.195090, (GLfloat) - 0.980785,
+       (GLfloat) - 0.000000, (GLfloat) 0.555570, (GLfloat) - 0.831470,
+       (GLfloat) - 0.000000, (GLfloat) 0.831470, (GLfloat) - 0.555570,
+       (GLfloat) - 0.000000, (GLfloat) 0.980785, (GLfloat) - 0.195090,
+       (GLfloat) - 0.000000, (GLfloat) 0.980785, (GLfloat) 0.195090,
+       (GLfloat) - 0.000000, (GLfloat) 0.831470, (GLfloat) 0.555570,
+       (GLfloat) - 0.000000, (GLfloat) 0.555570, (GLfloat) 0.831470,
+       (GLfloat) - 0.000000, (GLfloat) 0.195090, (GLfloat) 0.980785,
+       (GLfloat) - 0.000000, (GLfloat) - 0.195090, (GLfloat) 0.980785,
+       (GLfloat) - 0.000000, (GLfloat) - 0.555570, (GLfloat) 0.831470,
+       (GLfloat) - 0.000000, (GLfloat) - 0.831470, (GLfloat) 0.555570,
+       (GLfloat) - 0.000000, (GLfloat) - 0.980785, (GLfloat) 0.195090,
+       (GLfloat) 0.000000, (GLfloat) - 0.980785, (GLfloat) - 0.195090,
+       (GLfloat) 0.000000, (GLfloat) - 0.831470, (GLfloat) - 0.555570,
+       (GLfloat) 0.000000, (GLfloat) - 0.555570, (GLfloat) - 0.831470,
+       (GLfloat) 0.000000, (GLfloat) - 0.195090, (GLfloat) - 0.980785,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.980785, (GLfloat) - 0.195092, (GLfloat) - 0.000000,
+       (GLfloat) 0.831470, (GLfloat) - 0.555569, (GLfloat) - 0.000000,
+       (GLfloat) 0.555569, (GLfloat) - 0.831470, (GLfloat) - 0.000000,
+       (GLfloat) 0.195091, (GLfloat) - 0.980785, (GLfloat) - 0.000000,
+       (GLfloat) - 0.195090, (GLfloat) - 0.980785, (GLfloat) - 0.000000,
+       (GLfloat) - 0.555570, (GLfloat) - 0.831469, (GLfloat) - 0.000000,
+       (GLfloat) - 0.831469, (GLfloat) - 0.555571, (GLfloat) - 0.000000,
+       (GLfloat) - 0.980785, (GLfloat) - 0.195089, (GLfloat) 0.000000,
+       (GLfloat) - 0.980785, (GLfloat) 0.195089, (GLfloat) - 0.000000,
+       (GLfloat) - 0.831469, (GLfloat) 0.555571, (GLfloat) - 0.000000,
+       (GLfloat) - 0.555570, (GLfloat) 0.831469, (GLfloat) - 0.000000,
+       (GLfloat) - 0.195090, (GLfloat) 0.980785, (GLfloat) - 0.000000,
+       (GLfloat) 0.195091, (GLfloat) 0.980785, (GLfloat) 0.000000,
+       (GLfloat) 0.555569, (GLfloat) 0.831470, (GLfloat) 0.000000,
+       (GLfloat) 0.831470, (GLfloat) 0.555569, (GLfloat) 0.000000,
+       (GLfloat) 0.980785, (GLfloat) 0.195092, (GLfloat) - 0.000000,
+       (GLfloat) 0.980785, (GLfloat) 0.000000, (GLfloat) 0.195092,
+       (GLfloat) 0.831470, (GLfloat) 0.000000, (GLfloat) 0.555569,
+       (GLfloat) 0.555569, (GLfloat) 0.000000, (GLfloat) 0.831470,
+       (GLfloat) 0.195091, (GLfloat) 0.000000, (GLfloat) 0.980785,
+       (GLfloat) - 0.195090, (GLfloat) 0.000000, (GLfloat) 0.980785,
+       (GLfloat) - 0.555570, (GLfloat) 0.000000, (GLfloat) 0.831469,
+       (GLfloat) - 0.831469, (GLfloat) 0.000000, (GLfloat) 0.555571,
+       (GLfloat) - 0.980785, (GLfloat) 0.000000, (GLfloat) 0.195089,
+       (GLfloat) - 0.980785, (GLfloat) - 0.000000, (GLfloat) - 0.195089,
+       (GLfloat) - 0.831469, (GLfloat) - 0.000000, (GLfloat) - 0.555571,
+       (GLfloat) - 0.555570, (GLfloat) - 0.000000, (GLfloat) - 0.831469,
+       (GLfloat) - 0.195090, (GLfloat) - 0.000000, (GLfloat) - 0.980785,
+       (GLfloat) 0.195091, (GLfloat) 0.000000, (GLfloat) - 0.980785,
+       (GLfloat) 0.555569, (GLfloat) 0.000000, (GLfloat) - 0.831470,
+       (GLfloat) 0.831470, (GLfloat) 0.000000, (GLfloat) - 0.555569,
+       (GLfloat) 0.980785, (GLfloat) - 0.000000, (GLfloat) - 0.195092,
+       (GLfloat) 0.980785, (GLfloat) 0.195092, (GLfloat) - 0.000000,
+       (GLfloat) 0.831470, (GLfloat) 0.555569, (GLfloat) - 0.000000,
+       (GLfloat) 0.555569, (GLfloat) 0.831470, (GLfloat) - 0.000000,
+       (GLfloat) 0.195091, (GLfloat) 0.980785, (GLfloat) - 0.000000,
+       (GLfloat) - 0.195090, (GLfloat) 0.980785, (GLfloat) - 0.000000,
+       (GLfloat) - 0.555570, (GLfloat) 0.831469, (GLfloat) - 0.000000,
+       (GLfloat) - 0.831469, (GLfloat) 0.555571, (GLfloat) - 0.000000,
+       (GLfloat) - 0.980785, (GLfloat) 0.195089, (GLfloat) - 0.000000,
+       (GLfloat) - 0.980785, (GLfloat) - 0.195089, (GLfloat) 0.000000,
+       (GLfloat) - 0.831469, (GLfloat) - 0.555571, (GLfloat) 0.000000,
+       (GLfloat) - 0.555570, (GLfloat) - 0.831469, (GLfloat) 0.000000,
+       (GLfloat) - 0.195090, (GLfloat) - 0.980785, (GLfloat) 0.000000,
+       (GLfloat) 0.195091, (GLfloat) - 0.980785, (GLfloat) - 0.000000,
+       (GLfloat) 0.555569, (GLfloat) - 0.831470, (GLfloat) - 0.000000,
+       (GLfloat) 0.831470, (GLfloat) - 0.555569, (GLfloat) - 0.000000,
+       (GLfloat) 0.980785, (GLfloat) - 0.195092, (GLfloat) 0.000000,
+       (GLfloat) 0.980785, (GLfloat) 0.000000, (GLfloat) - 0.195092,
+       (GLfloat) 0.831470, (GLfloat) 0.000000, (GLfloat) - 0.555569,
+       (GLfloat) 0.555569, (GLfloat) 0.000000, (GLfloat) - 0.831470,
+       (GLfloat) 0.195091, (GLfloat) 0.000000, (GLfloat) - 0.980785,
+       (GLfloat) - 0.195090, (GLfloat) 0.000000, (GLfloat) - 0.980785,
+       (GLfloat) - 0.555570, (GLfloat) 0.000000, (GLfloat) - 0.831469,
+       (GLfloat) - 0.831469, (GLfloat) 0.000000, (GLfloat) - 0.555571,
+       (GLfloat) - 0.980785, (GLfloat) 0.000000, (GLfloat) - 0.195089,
+       (GLfloat) - 0.980785, (GLfloat) 0.000000, (GLfloat) 0.195089,
+       (GLfloat) - 0.831469, (GLfloat) 0.000000, (GLfloat) 0.555571,
+       (GLfloat) - 0.555570, (GLfloat) 0.000000, (GLfloat) 0.831469,
+       (GLfloat) - 0.195090, (GLfloat) 0.000000, (GLfloat) 0.980785,
+       (GLfloat) 0.195091, (GLfloat) - 0.000000, (GLfloat) 0.980785,
+       (GLfloat) 0.555569, (GLfloat) - 0.000000, (GLfloat) 0.831470,
+       (GLfloat) 0.831470, (GLfloat) - 0.000000, (GLfloat) 0.555569,
+       (GLfloat) 0.980785, (GLfloat) - 0.000000, (GLfloat) 0.195092,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.130526, (GLfloat) - 0.991445,
+       (GLfloat) - 0.000000, (GLfloat) 0.382684, (GLfloat) - 0.923880,
+       (GLfloat) - 0.000000, (GLfloat) 0.608761, (GLfloat) - 0.793353,
+       (GLfloat) - 0.000000, (GLfloat) 0.793353, (GLfloat) - 0.608761,
+       (GLfloat) - 0.000000, (GLfloat) 0.923880, (GLfloat) - 0.382684,
+       (GLfloat) - 0.000000, (GLfloat) 0.991445, (GLfloat) - 0.130526,
+       (GLfloat) - 0.000000, (GLfloat) 0.991445, (GLfloat) 0.130526,
+       (GLfloat) - 0.000000, (GLfloat) 0.923880, (GLfloat) 0.382684,
+       (GLfloat) - 0.000000, (GLfloat) 0.793353, (GLfloat) 0.608761,
+       (GLfloat) - 0.000000, (GLfloat) 0.608761, (GLfloat) 0.793353,
+       (GLfloat) - 0.000000, (GLfloat) 0.382684, (GLfloat) 0.923880,
+       (GLfloat) - 0.000000, (GLfloat) 0.130526, (GLfloat) 0.991445,
+       (GLfloat) - 0.000000, (GLfloat) - 0.130526, (GLfloat) 0.991445,
+       (GLfloat) - 0.000000, (GLfloat) - 0.382684, (GLfloat) 0.923880,
+       (GLfloat) - 0.000000, (GLfloat) - 0.608761, (GLfloat) 0.793353,
+       (GLfloat) - 0.000000, (GLfloat) - 0.793353, (GLfloat) 0.608761,
+       (GLfloat) - 0.000000, (GLfloat) - 0.923880, (GLfloat) 0.382684,
+       (GLfloat) - 0.000000, (GLfloat) - 0.991445, (GLfloat) 0.130526,
+       (GLfloat) 0.000000, (GLfloat) - 0.991445, (GLfloat) - 0.130526,
+       (GLfloat) 0.000000, (GLfloat) - 0.923880, (GLfloat) - 0.382684,
+       (GLfloat) 0.000000, (GLfloat) - 0.793353, (GLfloat) - 0.608761,
+       (GLfloat) 0.000000, (GLfloat) - 0.608761, (GLfloat) - 0.793353,
+       (GLfloat) 0.000000, (GLfloat) - 0.382684, (GLfloat) - 0.923880,
+       (GLfloat) 0.000000, (GLfloat) - 0.130526, (GLfloat) - 0.991445,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.194185, (GLfloat) 0.976241, (GLfloat) 0.096151,
+       (GLfloat) - 0.194185, (GLfloat) 0.976241, (GLfloat) 0.096151,
+       (GLfloat) - 0.553718, (GLfloat) 0.828695, (GLfloat) 0.081619,
+       (GLfloat) - 0.830228, (GLfloat) 0.554740, (GLfloat) 0.054637,
+       (GLfloat) - 0.980604, (GLfloat) 0.195054, (GLfloat) 0.019211,
+       (GLfloat) - 0.980605, (GLfloat) - 0.195053, (GLfloat) - 0.019211,
+       (GLfloat) - 0.830227, (GLfloat) - 0.554741, (GLfloat) - 0.054637,
+       (GLfloat) - 0.553717, (GLfloat) - 0.828695, (GLfloat) - 0.081619,
+       (GLfloat) - 0.194187, (GLfloat) - 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) 0.194188, (GLfloat) - 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) 0.553716, (GLfloat) - 0.828696, (GLfloat) - 0.081619,
+       (GLfloat) 0.830227, (GLfloat) - 0.554741, (GLfloat) - 0.054637,
+       (GLfloat) 0.980604, (GLfloat) - 0.195053, (GLfloat) - 0.019211,
+       (GLfloat) 0.980604, (GLfloat) 0.195054, (GLfloat) 0.019211,
+       (GLfloat) 0.830228, (GLfloat) 0.554740, (GLfloat) 0.054637,
+       (GLfloat) 0.553717, (GLfloat) 0.828695, (GLfloat) 0.081619,
+       (GLfloat) 0.194186, (GLfloat) 0.938725, (GLfloat) 0.284759,
+       (GLfloat) - 0.194185, (GLfloat) 0.938725, (GLfloat) 0.284759,
+       (GLfloat) - 0.553717, (GLfloat) 0.796849, (GLfloat) 0.241721,
+       (GLfloat) - 0.830228, (GLfloat) 0.533421, (GLfloat) 0.161812,
+       (GLfloat) - 0.980604, (GLfloat) 0.187558, (GLfloat) 0.056895,
+       (GLfloat) - 0.980604, (GLfloat) - 0.187558, (GLfloat) - 0.056895,
+       (GLfloat) - 0.830227, (GLfloat) - 0.533422, (GLfloat) - 0.161812,
+       (GLfloat) - 0.553717, (GLfloat) - 0.796849, (GLfloat) - 0.241722,
+       (GLfloat) - 0.194186, (GLfloat) - 0.938725, (GLfloat) - 0.284759,
+       (GLfloat) 0.194187, (GLfloat) - 0.938724, (GLfloat) - 0.284759,
+       (GLfloat) 0.553716, (GLfloat) - 0.796849, (GLfloat) - 0.241722,
+       (GLfloat) 0.830227, (GLfloat) - 0.533422, (GLfloat) - 0.161812,
+       (GLfloat) 0.980604, (GLfloat) - 0.187558, (GLfloat) - 0.056895,
+       (GLfloat) 0.980604, (GLfloat) 0.187558, (GLfloat) 0.056895,
+       (GLfloat) 0.830228, (GLfloat) 0.533421, (GLfloat) 0.161811,
+       (GLfloat) 0.553716, (GLfloat) 0.796850, (GLfloat) 0.241722,
+       (GLfloat) 0.194186, (GLfloat) 0.865134, (GLfloat) 0.462423,
+       (GLfloat) - 0.194185, (GLfloat) 0.865134, (GLfloat) 0.462424,
+       (GLfloat) - 0.553717, (GLfloat) 0.734380, (GLfloat) 0.392534,
+       (GLfloat) - 0.830228, (GLfloat) 0.491604, (GLfloat) 0.262768,
+       (GLfloat) - 0.980604, (GLfloat) 0.172854, (GLfloat) 0.092393,
+       (GLfloat) - 0.980604, (GLfloat) - 0.172854, (GLfloat) - 0.092393,
+       (GLfloat) - 0.830227, (GLfloat) - 0.491605, (GLfloat) - 0.262768,
+       (GLfloat) - 0.553717, (GLfloat) - 0.734380, (GLfloat) - 0.392534,
+       (GLfloat) - 0.194187, (GLfloat) - 0.865134, (GLfloat) - 0.462424,
+       (GLfloat) 0.194187, (GLfloat) - 0.865134, (GLfloat) - 0.462423,
+       (GLfloat) 0.553716, (GLfloat) - 0.734381, (GLfloat) - 0.392534,
+       (GLfloat) 0.830227, (GLfloat) - 0.491605, (GLfloat) - 0.262768,
+       (GLfloat) 0.980604, (GLfloat) - 0.172854, (GLfloat) - 0.092393,
+       (GLfloat) 0.980604, (GLfloat) 0.172854, (GLfloat) 0.092393,
+       (GLfloat) 0.830228, (GLfloat) 0.491604, (GLfloat) 0.262768,
+       (GLfloat) 0.553716, (GLfloat) 0.734381, (GLfloat) 0.392535,
+       (GLfloat) 0.194186, (GLfloat) 0.758296, (GLfloat) 0.622317,
+       (GLfloat) - 0.194186, (GLfloat) 0.758296, (GLfloat) 0.622318,
+       (GLfloat) - 0.553717, (GLfloat) 0.643690, (GLfloat) 0.528263,
+       (GLfloat) - 0.830228, (GLfloat) 0.430895, (GLfloat) 0.353626,
+       (GLfloat) - 0.980604, (GLfloat) 0.151508, (GLfloat) 0.124340,
+       (GLfloat) - 0.980604, (GLfloat) - 0.151508, (GLfloat) - 0.124339,
+       (GLfloat) - 0.830227, (GLfloat) - 0.430895, (GLfloat) - 0.353627,
+       (GLfloat) - 0.553717, (GLfloat) - 0.643690, (GLfloat) - 0.528263,
+       (GLfloat) - 0.194186, (GLfloat) - 0.758296, (GLfloat) - 0.622317,
+       (GLfloat) 0.194186, (GLfloat) - 0.758296, (GLfloat) - 0.622318,
+       (GLfloat) 0.553716, (GLfloat) - 0.643690, (GLfloat) - 0.528263,
+       (GLfloat) 0.830227, (GLfloat) - 0.430895, (GLfloat) - 0.353627,
+       (GLfloat) 0.980604, (GLfloat) - 0.151508, (GLfloat) - 0.124339,
+       (GLfloat) 0.980604, (GLfloat) 0.151508, (GLfloat) 0.124340,
+       (GLfloat) 0.830228, (GLfloat) 0.430895, (GLfloat) 0.353626,
+       (GLfloat) 0.553716, (GLfloat) 0.643690, (GLfloat) 0.528263,
+       (GLfloat) 0.194186, (GLfloat) 0.622317, (GLfloat) 0.758296,
+       (GLfloat) - 0.194185, (GLfloat) 0.622318, (GLfloat) 0.758296,
+       (GLfloat) - 0.553717, (GLfloat) 0.528263, (GLfloat) 0.643690,
+       (GLfloat) - 0.830228, (GLfloat) 0.353626, (GLfloat) 0.430895,
+       (GLfloat) - 0.980604, (GLfloat) 0.124339, (GLfloat) 0.151508,
+       (GLfloat) - 0.980604, (GLfloat) - 0.124339, (GLfloat) - 0.151508,
+       (GLfloat) - 0.830227, (GLfloat) - 0.353627, (GLfloat) - 0.430895,
+       (GLfloat) - 0.553717, (GLfloat) - 0.528262, (GLfloat) - 0.643689,
+       (GLfloat) - 0.194187, (GLfloat) - 0.622317, (GLfloat) - 0.758296,
+       (GLfloat) 0.194187, (GLfloat) - 0.622317, (GLfloat) - 0.758296,
+       (GLfloat) 0.553716, (GLfloat) - 0.528263, (GLfloat) - 0.643690,
+       (GLfloat) 0.830227, (GLfloat) - 0.353627, (GLfloat) - 0.430895,
+       (GLfloat) 0.980604, (GLfloat) - 0.124339, (GLfloat) - 0.151508,
+       (GLfloat) 0.980604, (GLfloat) 0.124340, (GLfloat) 0.151508,
+       (GLfloat) 0.830228, (GLfloat) 0.353626, (GLfloat) 0.430895,
+       (GLfloat) 0.553716, (GLfloat) 0.528263, (GLfloat) 0.643690,
+       (GLfloat) 0.194186, (GLfloat) 0.462423, (GLfloat) 0.865134,
+       (GLfloat) - 0.194185, (GLfloat) 0.462424, (GLfloat) 0.865134,
+       (GLfloat) - 0.553717, (GLfloat) 0.392534, (GLfloat) 0.734380,
+       (GLfloat) - 0.830228, (GLfloat) 0.262768, (GLfloat) 0.491604,
+       (GLfloat) - 0.980604, (GLfloat) 0.092393, (GLfloat) 0.172855,
+       (GLfloat) - 0.980604, (GLfloat) - 0.092392, (GLfloat) - 0.172854,
+       (GLfloat) - 0.830227, (GLfloat) - 0.262768, (GLfloat) - 0.491605,
+       (GLfloat) - 0.553717, (GLfloat) - 0.392534, (GLfloat) - 0.734380,
+       (GLfloat) - 0.194186, (GLfloat) - 0.462424, (GLfloat) - 0.865134,
+       (GLfloat) 0.194187, (GLfloat) - 0.462423, (GLfloat) - 0.865134,
+       (GLfloat) 0.553716, (GLfloat) - 0.392535, (GLfloat) - 0.734381,
+       (GLfloat) 0.830227, (GLfloat) - 0.262768, (GLfloat) - 0.491605,
+       (GLfloat) 0.980604, (GLfloat) - 0.092392, (GLfloat) - 0.172854,
+       (GLfloat) 0.980604, (GLfloat) 0.092393, (GLfloat) 0.172855,
+       (GLfloat) 0.830228, (GLfloat) 0.262768, (GLfloat) 0.491604,
+       (GLfloat) 0.553716, (GLfloat) 0.392535, (GLfloat) 0.734381,
+       (GLfloat) 0.194185, (GLfloat) 0.284759, (GLfloat) 0.938725,
+       (GLfloat) - 0.194185, (GLfloat) 0.284759, (GLfloat) 0.938725,
+       (GLfloat) - 0.553718, (GLfloat) 0.241721, (GLfloat) 0.796848,
+       (GLfloat) - 0.830228, (GLfloat) 0.161812, (GLfloat) 0.533422,
+       (GLfloat) - 0.980604, (GLfloat) 0.056895, (GLfloat) 0.187558,
+       (GLfloat) - 0.980604, (GLfloat) - 0.056895, (GLfloat) - 0.187558,
+       (GLfloat) - 0.830227, (GLfloat) - 0.161812, (GLfloat) - 0.533423,
+       (GLfloat) - 0.553717, (GLfloat) - 0.241722, (GLfloat) - 0.796849,
+       (GLfloat) - 0.194187, (GLfloat) - 0.284759, (GLfloat) - 0.938725,
+       (GLfloat) 0.194188, (GLfloat) - 0.284759, (GLfloat) - 0.938724,
+       (GLfloat) 0.553716, (GLfloat) - 0.241722, (GLfloat) - 0.796849,
+       (GLfloat) 0.830227, (GLfloat) - 0.161812, (GLfloat) - 0.533423,
+       (GLfloat) 0.980604, (GLfloat) - 0.056895, (GLfloat) - 0.187557,
+       (GLfloat) 0.980604, (GLfloat) 0.056895, (GLfloat) 0.187558,
+       (GLfloat) 0.830228, (GLfloat) 0.161812, (GLfloat) 0.533422,
+       (GLfloat) 0.553717, (GLfloat) 0.241722, (GLfloat) 0.796849,
+       (GLfloat) 0.194186, (GLfloat) 0.096151, (GLfloat) 0.976241,
+       (GLfloat) - 0.194186, (GLfloat) 0.096151, (GLfloat) 0.976241,
+       (GLfloat) - 0.553717, (GLfloat) 0.081619, (GLfloat) 0.828695,
+       (GLfloat) - 0.830228, (GLfloat) 0.054637, (GLfloat) 0.554740,
+       (GLfloat) - 0.980604, (GLfloat) 0.019211, (GLfloat) 0.195054,
+       (GLfloat) - 0.980604, (GLfloat) - 0.019211, (GLfloat) - 0.195054,
+       (GLfloat) - 0.830227, (GLfloat) - 0.054637, (GLfloat) - 0.554741,
+       (GLfloat) - 0.553717, (GLfloat) - 0.081619, (GLfloat) - 0.828695,
+       (GLfloat) - 0.194187, (GLfloat) - 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) 0.194187, (GLfloat) - 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) 0.553716, (GLfloat) - 0.081619, (GLfloat) - 0.828696,
+       (GLfloat) 0.830227, (GLfloat) - 0.054637, (GLfloat) - 0.554741,
+       (GLfloat) 0.980604, (GLfloat) - 0.019211, (GLfloat) - 0.195054,
+       (GLfloat) 0.980604, (GLfloat) 0.019211, (GLfloat) 0.195054,
+       (GLfloat) 0.830228, (GLfloat) 0.054637, (GLfloat) 0.554740,
+       (GLfloat) 0.553716, (GLfloat) 0.081619, (GLfloat) 0.828696,
+       (GLfloat) 0.194185, (GLfloat) - 0.096151, (GLfloat) 0.976241,
+       (GLfloat) - 0.194185, (GLfloat) - 0.096151, (GLfloat) 0.976241,
+       (GLfloat) - 0.553718, (GLfloat) - 0.081619, (GLfloat) 0.828695,
+       (GLfloat) - 0.830228, (GLfloat) - 0.054637, (GLfloat) 0.554740,
+       (GLfloat) - 0.980604, (GLfloat) - 0.019211, (GLfloat) 0.195054,
+       (GLfloat) - 0.980605, (GLfloat) 0.019211, (GLfloat) - 0.195053,
+       (GLfloat) - 0.830227, (GLfloat) 0.054637, (GLfloat) - 0.554741,
+       (GLfloat) - 0.553717, (GLfloat) 0.081619, (GLfloat) - 0.828695,
+       (GLfloat) - 0.194187, (GLfloat) 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) 0.194188, (GLfloat) 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) 0.553716, (GLfloat) 0.081619, (GLfloat) - 0.828696,
+       (GLfloat) 0.830227, (GLfloat) 0.054637, (GLfloat) - 0.554741,
+       (GLfloat) 0.980604, (GLfloat) 0.019211, (GLfloat) - 0.195053,
+       (GLfloat) 0.980604, (GLfloat) - 0.019211, (GLfloat) 0.195054,
+       (GLfloat) 0.830228, (GLfloat) - 0.054637, (GLfloat) 0.554740,
+       (GLfloat) 0.553717, (GLfloat) - 0.081619, (GLfloat) 0.828695,
+       (GLfloat) 0.194186, (GLfloat) - 0.284759, (GLfloat) 0.938725,
+       (GLfloat) - 0.194185, (GLfloat) - 0.284759, (GLfloat) 0.938725,
+       (GLfloat) - 0.553717, (GLfloat) - 0.241721, (GLfloat) 0.796849,
+       (GLfloat) - 0.830228, (GLfloat) - 0.161812, (GLfloat) 0.533421,
+       (GLfloat) - 0.980604, (GLfloat) - 0.056895, (GLfloat) 0.187558,
+       (GLfloat) - 0.980604, (GLfloat) 0.056895, (GLfloat) - 0.187558,
+       (GLfloat) - 0.830227, (GLfloat) 0.161812, (GLfloat) - 0.533422,
+       (GLfloat) - 0.553717, (GLfloat) 0.241722, (GLfloat) - 0.796849,
+       (GLfloat) - 0.194186, (GLfloat) 0.284759, (GLfloat) - 0.938725,
+       (GLfloat) 0.194187, (GLfloat) 0.284759, (GLfloat) - 0.938724,
+       (GLfloat) 0.553716, (GLfloat) 0.241722, (GLfloat) - 0.796849,
+       (GLfloat) 0.830227, (GLfloat) 0.161812, (GLfloat) - 0.533422,
+       (GLfloat) 0.980604, (GLfloat) 0.056895, (GLfloat) - 0.187558,
+       (GLfloat) 0.980604, (GLfloat) - 0.056895, (GLfloat) 0.187558,
+       (GLfloat) 0.830228, (GLfloat) - 0.161811, (GLfloat) 0.533421,
+       (GLfloat) 0.553716, (GLfloat) - 0.241722, (GLfloat) 0.796850,
+       (GLfloat) 0.194186, (GLfloat) - 0.462423, (GLfloat) 0.865134,
+       (GLfloat) - 0.194185, (GLfloat) - 0.462424, (GLfloat) 0.865134,
+       (GLfloat) - 0.553717, (GLfloat) - 0.392534, (GLfloat) 0.734380,
+       (GLfloat) - 0.830228, (GLfloat) - 0.262768, (GLfloat) 0.491604,
+       (GLfloat) - 0.980604, (GLfloat) - 0.092393, (GLfloat) 0.172854,
+       (GLfloat) - 0.980604, (GLfloat) 0.092393, (GLfloat) - 0.172854,
+       (GLfloat) - 0.830227, (GLfloat) 0.262768, (GLfloat) - 0.491605,
+       (GLfloat) - 0.553717, (GLfloat) 0.392534, (GLfloat) - 0.734380,
+       (GLfloat) - 0.194187, (GLfloat) 0.462424, (GLfloat) - 0.865134,
+       (GLfloat) 0.194187, (GLfloat) 0.462423, (GLfloat) - 0.865134,
+       (GLfloat) 0.553716, (GLfloat) 0.392534, (GLfloat) - 0.734381,
+       (GLfloat) 0.830227, (GLfloat) 0.262768, (GLfloat) - 0.491605,
+       (GLfloat) 0.980604, (GLfloat) 0.092393, (GLfloat) - 0.172854,
+       (GLfloat) 0.980604, (GLfloat) - 0.092393, (GLfloat) 0.172854,
+       (GLfloat) 0.830228, (GLfloat) - 0.262768, (GLfloat) 0.491604,
+       (GLfloat) 0.553716, (GLfloat) - 0.392535, (GLfloat) 0.734381,
+       (GLfloat) 0.194186, (GLfloat) - 0.622317, (GLfloat) 0.758296,
+       (GLfloat) - 0.194186, (GLfloat) - 0.622318, (GLfloat) 0.758296,
+       (GLfloat) - 0.553717, (GLfloat) - 0.528263, (GLfloat) 0.643690,
+       (GLfloat) - 0.830228, (GLfloat) - 0.353626, (GLfloat) 0.430895,
+       (GLfloat) - 0.980604, (GLfloat) - 0.124340, (GLfloat) 0.151508,
+       (GLfloat) - 0.980604, (GLfloat) 0.124339, (GLfloat) - 0.151508,
+       (GLfloat) - 0.830227, (GLfloat) 0.353627, (GLfloat) - 0.430895,
+       (GLfloat) - 0.553717, (GLfloat) 0.528263, (GLfloat) - 0.643690,
+       (GLfloat) - 0.194186, (GLfloat) 0.622317, (GLfloat) - 0.758296,
+       (GLfloat) 0.194186, (GLfloat) 0.622318, (GLfloat) - 0.758296,
+       (GLfloat) 0.553716, (GLfloat) 0.528263, (GLfloat) - 0.643690,
+       (GLfloat) 0.830227, (GLfloat) 0.353627, (GLfloat) - 0.430895,
+       (GLfloat) 0.980604, (GLfloat) 0.124339, (GLfloat) - 0.151508,
+       (GLfloat) 0.980604, (GLfloat) - 0.124340, (GLfloat) 0.151508,
+       (GLfloat) 0.830228, (GLfloat) - 0.353626, (GLfloat) 0.430895,
+       (GLfloat) 0.553716, (GLfloat) - 0.528263, (GLfloat) 0.643690,
+       (GLfloat) 0.194186, (GLfloat) - 0.758296, (GLfloat) 0.622317,
+       (GLfloat) - 0.194185, (GLfloat) - 0.758296, (GLfloat) 0.622318,
+       (GLfloat) - 0.553717, (GLfloat) - 0.643690, (GLfloat) 0.528263,
+       (GLfloat) - 0.830228, (GLfloat) - 0.430895, (GLfloat) 0.353626,
+       (GLfloat) - 0.980604, (GLfloat) - 0.151508, (GLfloat) 0.124339,
+       (GLfloat) - 0.980604, (GLfloat) 0.151508, (GLfloat) - 0.124339,
+       (GLfloat) - 0.830227, (GLfloat) 0.430895, (GLfloat) - 0.353627,
+       (GLfloat) - 0.553717, (GLfloat) 0.643689, (GLfloat) - 0.528262,
+       (GLfloat) - 0.194187, (GLfloat) 0.758296, (GLfloat) - 0.622317,
+       (GLfloat) 0.194187, (GLfloat) 0.758296, (GLfloat) - 0.622317,
+       (GLfloat) 0.553716, (GLfloat) 0.643690, (GLfloat) - 0.528263,
+       (GLfloat) 0.830227, (GLfloat) 0.430895, (GLfloat) - 0.353627,
+       (GLfloat) 0.980604, (GLfloat) 0.151508, (GLfloat) - 0.124339,
+       (GLfloat) 0.980604, (GLfloat) - 0.151508, (GLfloat) 0.124340,
+       (GLfloat) 0.830228, (GLfloat) - 0.430895, (GLfloat) 0.353626,
+       (GLfloat) 0.553716, (GLfloat) - 0.643690, (GLfloat) 0.528263,
+       (GLfloat) 0.194186, (GLfloat) - 0.865134, (GLfloat) 0.462423,
+       (GLfloat) - 0.194185, (GLfloat) - 0.865134, (GLfloat) 0.462424,
+       (GLfloat) - 0.553717, (GLfloat) - 0.734380, (GLfloat) 0.392534,
+       (GLfloat) - 0.830228, (GLfloat) - 0.491604, (GLfloat) 0.262768,
+       (GLfloat) - 0.980604, (GLfloat) - 0.172855, (GLfloat) 0.092393,
+       (GLfloat) - 0.980604, (GLfloat) 0.172854, (GLfloat) - 0.092393,
+       (GLfloat) - 0.830227, (GLfloat) 0.491605, (GLfloat) - 0.262768,
+       (GLfloat) - 0.553717, (GLfloat) 0.734380, (GLfloat) - 0.392534,
+       (GLfloat) - 0.194186, (GLfloat) 0.865134, (GLfloat) - 0.462424,
+       (GLfloat) 0.194187, (GLfloat) 0.865134, (GLfloat) - 0.462423,
+       (GLfloat) 0.553716, (GLfloat) 0.734381, (GLfloat) - 0.392535,
+       (GLfloat) 0.830228, (GLfloat) 0.491605, (GLfloat) - 0.262768,
+       (GLfloat) 0.980604, (GLfloat) 0.172854, (GLfloat) - 0.092393,
+       (GLfloat) 0.980604, (GLfloat) - 0.172855, (GLfloat) 0.092393,
+       (GLfloat) 0.830228, (GLfloat) - 0.491604, (GLfloat) 0.262768,
+       (GLfloat) 0.553716, (GLfloat) - 0.734381, (GLfloat) 0.392535,
+       (GLfloat) 0.194185, (GLfloat) - 0.938725, (GLfloat) 0.284759,
+       (GLfloat) - 0.194185, (GLfloat) - 0.938725, (GLfloat) 0.284759,
+       (GLfloat) - 0.553718, (GLfloat) - 0.796848, (GLfloat) 0.241721,
+       (GLfloat) - 0.830228, (GLfloat) - 0.533422, (GLfloat) 0.161812,
+       (GLfloat) - 0.980604, (GLfloat) - 0.187558, (GLfloat) 0.056895,
+       (GLfloat) - 0.980605, (GLfloat) 0.187557, (GLfloat) - 0.056895,
+       (GLfloat) - 0.830227, (GLfloat) 0.533423, (GLfloat) - 0.161812,
+       (GLfloat) - 0.553717, (GLfloat) 0.796849, (GLfloat) - 0.241722,
+       (GLfloat) - 0.194187, (GLfloat) 0.938725, (GLfloat) - 0.284759,
+       (GLfloat) 0.194188, (GLfloat) 0.938724, (GLfloat) - 0.284759,
+       (GLfloat) 0.553716, (GLfloat) 0.796849, (GLfloat) - 0.241722,
+       (GLfloat) 0.830227, (GLfloat) 0.533423, (GLfloat) - 0.161812,
+       (GLfloat) 0.980604, (GLfloat) 0.187557, (GLfloat) - 0.056895,
+       (GLfloat) 0.980604, (GLfloat) - 0.187558, (GLfloat) 0.056895,
+       (GLfloat) 0.830228, (GLfloat) - 0.533422, (GLfloat) 0.161812,
+       (GLfloat) 0.553717, (GLfloat) - 0.796849, (GLfloat) 0.241722,
+       (GLfloat) 0.194186, (GLfloat) - 0.976241, (GLfloat) 0.096151,
+       (GLfloat) - 0.194186, (GLfloat) - 0.976241, (GLfloat) 0.096151,
+       (GLfloat) - 0.553717, (GLfloat) - 0.828695, (GLfloat) 0.081619,
+       (GLfloat) - 0.830228, (GLfloat) - 0.554740, (GLfloat) 0.054637,
+       (GLfloat) - 0.980604, (GLfloat) - 0.195054, (GLfloat) 0.019211,
+       (GLfloat) - 0.980604, (GLfloat) 0.195054, (GLfloat) - 0.019211,
+       (GLfloat) - 0.830227, (GLfloat) 0.554741, (GLfloat) - 0.054637,
+       (GLfloat) - 0.553717, (GLfloat) 0.828695, (GLfloat) - 0.081619,
+       (GLfloat) - 0.194187, (GLfloat) 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) 0.194187, (GLfloat) 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) 0.553716, (GLfloat) 0.828696, (GLfloat) - 0.081619,
+       (GLfloat) 0.830227, (GLfloat) 0.554741, (GLfloat) - 0.054637,
+       (GLfloat) 0.980604, (GLfloat) 0.195054, (GLfloat) - 0.019211,
+       (GLfloat) 0.980604, (GLfloat) - 0.195054, (GLfloat) 0.019211,
+       (GLfloat) 0.830228, (GLfloat) - 0.554740, (GLfloat) 0.054637,
+       (GLfloat) 0.553716, (GLfloat) - 0.828696, (GLfloat) 0.081619,
+       (GLfloat) 0.194185, (GLfloat) - 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) - 0.194185, (GLfloat) - 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) - 0.553718, (GLfloat) - 0.828695, (GLfloat) - 0.081619,
+       (GLfloat) - 0.830228, (GLfloat) - 0.554740, (GLfloat) - 0.054637,
+       (GLfloat) - 0.980604, (GLfloat) - 0.195054, (GLfloat) - 0.019211,
+       (GLfloat) - 0.980605, (GLfloat) 0.195053, (GLfloat) 0.019211,
+       (GLfloat) - 0.830227, (GLfloat) 0.554741, (GLfloat) 0.054637,
+       (GLfloat) - 0.553717, (GLfloat) 0.828695, (GLfloat) 0.081619,
+       (GLfloat) - 0.194187, (GLfloat) 0.976241, (GLfloat) 0.096151,
+       (GLfloat) 0.194188, (GLfloat) 0.976241, (GLfloat) 0.096151,
+       (GLfloat) 0.553716, (GLfloat) 0.828696, (GLfloat) 0.081619,
+       (GLfloat) 0.830227, (GLfloat) 0.554741, (GLfloat) 0.054637,
+       (GLfloat) 0.980604, (GLfloat) 0.195053, (GLfloat) 0.019211,
+       (GLfloat) 0.980604, (GLfloat) - 0.195054, (GLfloat) - 0.019211,
+       (GLfloat) 0.830228, (GLfloat) - 0.554740, (GLfloat) - 0.054637,
+       (GLfloat) 0.553717, (GLfloat) - 0.828695, (GLfloat) - 0.081619,
+       (GLfloat) 0.194186, (GLfloat) - 0.938725, (GLfloat) - 0.284759,
+       (GLfloat) - 0.194185, (GLfloat) - 0.938725, (GLfloat) - 0.284759,
+       (GLfloat) - 0.553717, (GLfloat) - 0.796849, (GLfloat) - 0.241721,
+       (GLfloat) - 0.830228, (GLfloat) - 0.533421, (GLfloat) - 0.161812,
+       (GLfloat) - 0.980604, (GLfloat) - 0.187558, (GLfloat) - 0.056895,
+       (GLfloat) - 0.980604, (GLfloat) 0.187558, (GLfloat) 0.056895,
+       (GLfloat) - 0.830227, (GLfloat) 0.533422, (GLfloat) 0.161812,
+       (GLfloat) - 0.553717, (GLfloat) 0.796849, (GLfloat) 0.241722,
+       (GLfloat) - 0.194186, (GLfloat) 0.938725, (GLfloat) 0.284759,
+       (GLfloat) 0.194187, (GLfloat) 0.938724, (GLfloat) 0.284759,
+       (GLfloat) 0.553716, (GLfloat) 0.796849, (GLfloat) 0.241722,
+       (GLfloat) 0.830227, (GLfloat) 0.533422, (GLfloat) 0.161812,
+       (GLfloat) 0.980604, (GLfloat) 0.187558, (GLfloat) 0.056895,
+       (GLfloat) 0.980604, (GLfloat) - 0.187558, (GLfloat) - 0.056895,
+       (GLfloat) 0.830228, (GLfloat) - 0.533421, (GLfloat) - 0.161811,
+       (GLfloat) 0.553716, (GLfloat) - 0.796850, (GLfloat) - 0.241722,
+       (GLfloat) 0.194186, (GLfloat) - 0.865134, (GLfloat) - 0.462423,
+       (GLfloat) - 0.194185, (GLfloat) - 0.865134, (GLfloat) - 0.462424,
+       (GLfloat) - 0.553717, (GLfloat) - 0.734380, (GLfloat) - 0.392534,
+       (GLfloat) - 0.830228, (GLfloat) - 0.491604, (GLfloat) - 0.262768,
+       (GLfloat) - 0.980604, (GLfloat) - 0.172854, (GLfloat) - 0.092393,
+       (GLfloat) - 0.980604, (GLfloat) 0.172854, (GLfloat) 0.092393,
+       (GLfloat) - 0.830227, (GLfloat) 0.491605, (GLfloat) 0.262768,
+       (GLfloat) - 0.553717, (GLfloat) 0.734380, (GLfloat) 0.392534,
+       (GLfloat) - 0.194187, (GLfloat) 0.865134, (GLfloat) 0.462424,
+       (GLfloat) 0.194187, (GLfloat) 0.865134, (GLfloat) 0.462423,
+       (GLfloat) 0.553716, (GLfloat) 0.734381, (GLfloat) 0.392534,
+       (GLfloat) 0.830227, (GLfloat) 0.491605, (GLfloat) 0.262768,
+       (GLfloat) 0.980604, (GLfloat) 0.172854, (GLfloat) 0.092393,
+       (GLfloat) 0.980604, (GLfloat) - 0.172854, (GLfloat) - 0.092393,
+       (GLfloat) 0.830228, (GLfloat) - 0.491604, (GLfloat) - 0.262768,
+       (GLfloat) 0.553716, (GLfloat) - 0.734381, (GLfloat) - 0.392535,
+       (GLfloat) 0.194186, (GLfloat) - 0.758296, (GLfloat) - 0.622317,
+       (GLfloat) - 0.194186, (GLfloat) - 0.758296, (GLfloat) - 0.622318,
+       (GLfloat) - 0.553717, (GLfloat) - 0.643690, (GLfloat) - 0.528263,
+       (GLfloat) - 0.830228, (GLfloat) - 0.430895, (GLfloat) - 0.353626,
+       (GLfloat) - 0.980604, (GLfloat) - 0.151508, (GLfloat) - 0.124340,
+       (GLfloat) - 0.980604, (GLfloat) 0.151508, (GLfloat) 0.124339,
+       (GLfloat) - 0.830227, (GLfloat) 0.430895, (GLfloat) 0.353627,
+       (GLfloat) - 0.553717, (GLfloat) 0.643690, (GLfloat) 0.528263,
+       (GLfloat) - 0.194186, (GLfloat) 0.758296, (GLfloat) 0.622317,
+       (GLfloat) 0.194186, (GLfloat) 0.758296, (GLfloat) 0.622318,
+       (GLfloat) 0.553716, (GLfloat) 0.643690, (GLfloat) 0.528263,
+       (GLfloat) 0.830227, (GLfloat) 0.430895, (GLfloat) 0.353627,
+       (GLfloat) 0.980604, (GLfloat) 0.151508, (GLfloat) 0.124339,
+       (GLfloat) 0.980604, (GLfloat) - 0.151508, (GLfloat) - 0.124340,
+       (GLfloat) 0.830228, (GLfloat) - 0.430895, (GLfloat) - 0.353626,
+       (GLfloat) 0.553716, (GLfloat) - 0.643690, (GLfloat) - 0.528263,
+       (GLfloat) 0.194186, (GLfloat) - 0.622317, (GLfloat) - 0.758296,
+       (GLfloat) - 0.194185, (GLfloat) - 0.622318, (GLfloat) - 0.758296,
+       (GLfloat) - 0.553717, (GLfloat) - 0.528263, (GLfloat) - 0.643690,
+       (GLfloat) - 0.830228, (GLfloat) - 0.353626, (GLfloat) - 0.430895,
+       (GLfloat) - 0.980604, (GLfloat) - 0.124339, (GLfloat) - 0.151508,
+       (GLfloat) - 0.980604, (GLfloat) 0.124339, (GLfloat) 0.151508,
+       (GLfloat) - 0.830227, (GLfloat) 0.353627, (GLfloat) 0.430895,
+       (GLfloat) - 0.553717, (GLfloat) 0.528262, (GLfloat) 0.643689,
+       (GLfloat) - 0.194187, (GLfloat) 0.622317, (GLfloat) 0.758296,
+       (GLfloat) 0.194187, (GLfloat) 0.622317, (GLfloat) 0.758296,
+       (GLfloat) 0.553716, (GLfloat) 0.528263, (GLfloat) 0.643690,
+       (GLfloat) 0.830227, (GLfloat) 0.353627, (GLfloat) 0.430895,
+       (GLfloat) 0.980604, (GLfloat) 0.124339, (GLfloat) 0.151508,
+       (GLfloat) 0.980604, (GLfloat) - 0.124340, (GLfloat) - 0.151508,
+       (GLfloat) 0.830228, (GLfloat) - 0.353626, (GLfloat) - 0.430895,
+       (GLfloat) 0.553716, (GLfloat) - 0.528263, (GLfloat) - 0.643690,
+       (GLfloat) 0.194186, (GLfloat) - 0.462423, (GLfloat) - 0.865134,
+       (GLfloat) - 0.194185, (GLfloat) - 0.462424, (GLfloat) - 0.865134,
+       (GLfloat) - 0.553717, (GLfloat) - 0.392534, (GLfloat) - 0.734380,
+       (GLfloat) - 0.830228, (GLfloat) - 0.262768, (GLfloat) - 0.491604,
+       (GLfloat) - 0.980604, (GLfloat) - 0.092393, (GLfloat) - 0.172855,
+       (GLfloat) - 0.980604, (GLfloat) 0.092393, (GLfloat) 0.172854,
+       (GLfloat) - 0.830227, (GLfloat) 0.262768, (GLfloat) 0.491605,
+       (GLfloat) - 0.553717, (GLfloat) 0.392534, (GLfloat) 0.734380,
+       (GLfloat) - 0.194186, (GLfloat) 0.462424, (GLfloat) 0.865134,
+       (GLfloat) 0.194187, (GLfloat) 0.462423, (GLfloat) 0.865134,
+       (GLfloat) 0.553716, (GLfloat) 0.392535, (GLfloat) 0.734381,
+       (GLfloat) 0.830228, (GLfloat) 0.262768, (GLfloat) 0.491605,
+       (GLfloat) 0.980604, (GLfloat) 0.092393, (GLfloat) 0.172854,
+       (GLfloat) 0.980604, (GLfloat) - 0.092393, (GLfloat) - 0.172855,
+       (GLfloat) 0.830228, (GLfloat) - 0.262768, (GLfloat) - 0.491604,
+       (GLfloat) 0.553716, (GLfloat) - 0.392535, (GLfloat) - 0.734381,
+       (GLfloat) 0.194185, (GLfloat) - 0.284759, (GLfloat) - 0.938725,
+       (GLfloat) - 0.194185, (GLfloat) - 0.284759, (GLfloat) - 0.938725,
+       (GLfloat) - 0.553718, (GLfloat) - 0.241721, (GLfloat) - 0.796848,
+       (GLfloat) - 0.830228, (GLfloat) - 0.161812, (GLfloat) - 0.533422,
+       (GLfloat) - 0.980604, (GLfloat) - 0.056895, (GLfloat) - 0.187558,
+       (GLfloat) - 0.980605, (GLfloat) 0.056895, (GLfloat) 0.187557,
+       (GLfloat) - 0.830227, (GLfloat) 0.161812, (GLfloat) 0.533422,
+       (GLfloat) - 0.553716, (GLfloat) 0.241722, (GLfloat) 0.796849,
+       (GLfloat) - 0.194187, (GLfloat) 0.284759, (GLfloat) 0.938725,
+       (GLfloat) 0.194188, (GLfloat) 0.284759, (GLfloat) 0.938724,
+       (GLfloat) 0.553716, (GLfloat) 0.241722, (GLfloat) 0.796850,
+       (GLfloat) 0.830227, (GLfloat) 0.161812, (GLfloat) 0.533423,
+       (GLfloat) 0.980604, (GLfloat) 0.056895, (GLfloat) 0.187557,
+       (GLfloat) 0.980604, (GLfloat) - 0.056895, (GLfloat) - 0.187558,
+       (GLfloat) 0.830228, (GLfloat) - 0.161812, (GLfloat) - 0.533422,
+       (GLfloat) 0.553717, (GLfloat) - 0.241722, (GLfloat) - 0.796849,
+       (GLfloat) 0.194186, (GLfloat) - 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) - 0.194186, (GLfloat) - 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) - 0.553717, (GLfloat) - 0.081619, (GLfloat) - 0.828695,
+       (GLfloat) - 0.830228, (GLfloat) - 0.054637, (GLfloat) - 0.554740,
+       (GLfloat) - 0.980604, (GLfloat) - 0.019211, (GLfloat) - 0.195054,
+       (GLfloat) - 0.980604, (GLfloat) 0.019211, (GLfloat) 0.195054,
+       (GLfloat) - 0.830227, (GLfloat) 0.054637, (GLfloat) 0.554741,
+       (GLfloat) - 0.553717, (GLfloat) 0.081619, (GLfloat) 0.828695,
+       (GLfloat) - 0.194187, (GLfloat) 0.096151, (GLfloat) 0.976241,
+       (GLfloat) 0.194187, (GLfloat) 0.096151, (GLfloat) 0.976241,
+       (GLfloat) 0.553716, (GLfloat) 0.081620, (GLfloat) 0.828696,
+       (GLfloat) 0.830227, (GLfloat) 0.054637, (GLfloat) 0.554741,
+       (GLfloat) 0.980604, (GLfloat) 0.019211, (GLfloat) 0.195054,
+       (GLfloat) 0.980604, (GLfloat) - 0.019211, (GLfloat) - 0.195054,
+       (GLfloat) 0.830228, (GLfloat) - 0.054637, (GLfloat) - 0.554740,
+       (GLfloat) 0.553716, (GLfloat) - 0.081619, (GLfloat) - 0.828696,
+       (GLfloat) 0.194185, (GLfloat) 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) - 0.194185, (GLfloat) 0.096151, (GLfloat) - 0.976241,
+       (GLfloat) - 0.553718, (GLfloat) 0.081619, (GLfloat) - 0.828695,
+       (GLfloat) - 0.830228, (GLfloat) 0.054637, (GLfloat) - 0.554740,
+       (GLfloat) - 0.980604, (GLfloat) 0.019211, (GLfloat) - 0.195054,
+       (GLfloat) - 0.980605, (GLfloat) - 0.019211, (GLfloat) 0.195053,
+       (GLfloat) - 0.830227, (GLfloat) - 0.054637, (GLfloat) 0.554741,
+       (GLfloat) - 0.553717, (GLfloat) - 0.081619, (GLfloat) 0.828695,
+       (GLfloat) - 0.194187, (GLfloat) - 0.096151, (GLfloat) 0.976241,
+       (GLfloat) 0.194188, (GLfloat) - 0.096151, (GLfloat) 0.976241,
+       (GLfloat) 0.553716, (GLfloat) - 0.081619, (GLfloat) 0.828696,
+       (GLfloat) 0.830227, (GLfloat) - 0.054637, (GLfloat) 0.554741,
+       (GLfloat) 0.980604, (GLfloat) - 0.019211, (GLfloat) 0.195053,
+       (GLfloat) 0.980604, (GLfloat) 0.019211, (GLfloat) - 0.195054,
+       (GLfloat) 0.830228, (GLfloat) 0.054637, (GLfloat) - 0.554740,
+       (GLfloat) 0.553717, (GLfloat) 0.081619, (GLfloat) - 0.828695,
+       (GLfloat) 0.194186, (GLfloat) 0.284759, (GLfloat) - 0.938725,
+       (GLfloat) - 0.194185, (GLfloat) 0.284759, (GLfloat) - 0.938725,
+       (GLfloat) - 0.553717, (GLfloat) 0.241721, (GLfloat) - 0.796849,
+       (GLfloat) - 0.830228, (GLfloat) 0.161812, (GLfloat) - 0.533421,
+       (GLfloat) - 0.980604, (GLfloat) 0.056895, (GLfloat) - 0.187558,
+       (GLfloat) - 0.980604, (GLfloat) - 0.056895, (GLfloat) 0.187558,
+       (GLfloat) - 0.830227, (GLfloat) - 0.161812, (GLfloat) 0.533422,
+       (GLfloat) - 0.553717, (GLfloat) - 0.241722, (GLfloat) 0.796849,
+       (GLfloat) - 0.194186, (GLfloat) - 0.284759, (GLfloat) 0.938725,
+       (GLfloat) 0.194187, (GLfloat) - 0.284759, (GLfloat) 0.938724,
+       (GLfloat) 0.553716, (GLfloat) - 0.241722, (GLfloat) 0.796849,
+       (GLfloat) 0.830227, (GLfloat) - 0.161812, (GLfloat) 0.533422,
+       (GLfloat) 0.980604, (GLfloat) - 0.056895, (GLfloat) 0.187558,
+       (GLfloat) 0.980604, (GLfloat) 0.056895, (GLfloat) - 0.187558,
+       (GLfloat) 0.830228, (GLfloat) 0.161811, (GLfloat) - 0.533421,
+       (GLfloat) 0.553716, (GLfloat) 0.241722, (GLfloat) - 0.796850,
+       (GLfloat) 0.194186, (GLfloat) 0.462423, (GLfloat) - 0.865134,
+       (GLfloat) - 0.194185, (GLfloat) 0.462424, (GLfloat) - 0.865134,
+       (GLfloat) - 0.553717, (GLfloat) 0.392534, (GLfloat) - 0.734380,
+       (GLfloat) - 0.830228, (GLfloat) 0.262768, (GLfloat) - 0.491604,
+       (GLfloat) - 0.980604, (GLfloat) 0.092393, (GLfloat) - 0.172854,
+       (GLfloat) - 0.980604, (GLfloat) - 0.092393, (GLfloat) 0.172854,
+       (GLfloat) - 0.830227, (GLfloat) - 0.262768, (GLfloat) 0.491605,
+       (GLfloat) - 0.553717, (GLfloat) - 0.392534, (GLfloat) 0.734380,
+       (GLfloat) - 0.194187, (GLfloat) - 0.462424, (GLfloat) 0.865134,
+       (GLfloat) 0.194187, (GLfloat) - 0.462423, (GLfloat) 0.865134,
+       (GLfloat) 0.553716, (GLfloat) - 0.392534, (GLfloat) 0.734381,
+       (GLfloat) 0.830227, (GLfloat) - 0.262768, (GLfloat) 0.491605,
+       (GLfloat) 0.980604, (GLfloat) - 0.092393, (GLfloat) 0.172854,
+       (GLfloat) 0.980604, (GLfloat) 0.092393, (GLfloat) - 0.172854,
+       (GLfloat) 0.830228, (GLfloat) 0.262768, (GLfloat) - 0.491604,
+       (GLfloat) 0.553716, (GLfloat) 0.392535, (GLfloat) - 0.734381,
+       (GLfloat) 0.194186, (GLfloat) 0.622317, (GLfloat) - 0.758296,
+       (GLfloat) - 0.194186, (GLfloat) 0.622318, (GLfloat) - 0.758296,
+       (GLfloat) - 0.553717, (GLfloat) 0.528263, (GLfloat) - 0.643690,
+       (GLfloat) - 0.830228, (GLfloat) 0.353626, (GLfloat) - 0.430895,
+       (GLfloat) - 0.980604, (GLfloat) 0.124340, (GLfloat) - 0.151508,
+       (GLfloat) - 0.980604, (GLfloat) - 0.124339, (GLfloat) 0.151508,
+       (GLfloat) - 0.830227, (GLfloat) - 0.353627, (GLfloat) 0.430895,
+       (GLfloat) - 0.553717, (GLfloat) - 0.528263, (GLfloat) 0.643690,
+       (GLfloat) - 0.194186, (GLfloat) - 0.622317, (GLfloat) 0.758296,
+       (GLfloat) 0.194186, (GLfloat) - 0.622318, (GLfloat) 0.758296,
+       (GLfloat) 0.553716, (GLfloat) - 0.528263, (GLfloat) 0.643690,
+       (GLfloat) 0.830227, (GLfloat) - 0.353627, (GLfloat) 0.430895,
+       (GLfloat) 0.980604, (GLfloat) - 0.124339, (GLfloat) 0.151508,
+       (GLfloat) 0.980604, (GLfloat) 0.124340, (GLfloat) - 0.151508,
+       (GLfloat) 0.830228, (GLfloat) 0.353626, (GLfloat) - 0.430895,
+       (GLfloat) 0.553716, (GLfloat) 0.528263, (GLfloat) - 0.643690,
+       (GLfloat) 0.194186, (GLfloat) 0.758296, (GLfloat) - 0.622317,
+       (GLfloat) - 0.194185, (GLfloat) 0.758296, (GLfloat) - 0.622318,
+       (GLfloat) - 0.553717, (GLfloat) 0.643690, (GLfloat) - 0.528263,
+       (GLfloat) - 0.830228, (GLfloat) 0.430895, (GLfloat) - 0.353626,
+       (GLfloat) - 0.980604, (GLfloat) 0.151508, (GLfloat) - 0.124339,
+       (GLfloat) - 0.980604, (GLfloat) - 0.151508, (GLfloat) 0.124339,
+       (GLfloat) - 0.830227, (GLfloat) - 0.430895, (GLfloat) 0.353627,
+       (GLfloat) - 0.553717, (GLfloat) - 0.643689, (GLfloat) 0.528262,
+       (GLfloat) - 0.194187, (GLfloat) - 0.758296, (GLfloat) 0.622317,
+       (GLfloat) 0.194187, (GLfloat) - 0.758296, (GLfloat) 0.622317,
+       (GLfloat) 0.553716, (GLfloat) - 0.643690, (GLfloat) 0.528263,
+       (GLfloat) 0.830227, (GLfloat) - 0.430895, (GLfloat) 0.353627,
+       (GLfloat) 0.980604, (GLfloat) - 0.151508, (GLfloat) 0.124339,
+       (GLfloat) 0.980604, (GLfloat) 0.151508, (GLfloat) - 0.124340,
+       (GLfloat) 0.830228, (GLfloat) 0.430895, (GLfloat) - 0.353626,
+       (GLfloat) 0.553716, (GLfloat) 0.643690, (GLfloat) - 0.528263,
+       (GLfloat) 0.194186, (GLfloat) 0.865134, (GLfloat) - 0.462423,
+       (GLfloat) - 0.194185, (GLfloat) 0.865134, (GLfloat) - 0.462424,
+       (GLfloat) - 0.553717, (GLfloat) 0.734380, (GLfloat) - 0.392534,
+       (GLfloat) - 0.830228, (GLfloat) 0.491604, (GLfloat) - 0.262768,
+       (GLfloat) - 0.980604, (GLfloat) 0.172855, (GLfloat) - 0.092393,
+       (GLfloat) - 0.980604, (GLfloat) - 0.172854, (GLfloat) 0.092393,
+       (GLfloat) - 0.830227, (GLfloat) - 0.491605, (GLfloat) 0.262768,
+       (GLfloat) - 0.553717, (GLfloat) - 0.734380, (GLfloat) 0.392534,
+       (GLfloat) - 0.194186, (GLfloat) - 0.865134, (GLfloat) 0.462424,
+       (GLfloat) 0.194187, (GLfloat) - 0.865134, (GLfloat) 0.462423,
+       (GLfloat) 0.553716, (GLfloat) - 0.734381, (GLfloat) 0.392535,
+       (GLfloat) 0.830228, (GLfloat) - 0.491605, (GLfloat) 0.262768,
+       (GLfloat) 0.980604, (GLfloat) - 0.172854, (GLfloat) 0.092393,
+       (GLfloat) 0.980604, (GLfloat) 0.172855, (GLfloat) - 0.092393,
+       (GLfloat) 0.830228, (GLfloat) 0.491604, (GLfloat) - 0.262768,
+       (GLfloat) 0.553716, (GLfloat) 0.734381, (GLfloat) - 0.392535,
+       (GLfloat) 0.194185, (GLfloat) 0.938725, (GLfloat) - 0.284759,
+       (GLfloat) - 0.194185, (GLfloat) 0.938725, (GLfloat) - 0.284759,
+       (GLfloat) - 0.553718, (GLfloat) 0.796848, (GLfloat) - 0.241721,
+       (GLfloat) - 0.830228, (GLfloat) 0.533422, (GLfloat) - 0.161812,
+       (GLfloat) - 0.980604, (GLfloat) 0.187558, (GLfloat) - 0.056895,
+       (GLfloat) - 0.980605, (GLfloat) - 0.187557, (GLfloat) 0.056895,
+       (GLfloat) - 0.830227, (GLfloat) - 0.533422, (GLfloat) 0.161812,
+       (GLfloat) - 0.553716, (GLfloat) - 0.796849, (GLfloat) 0.241722,
+       (GLfloat) - 0.194187, (GLfloat) - 0.938725, (GLfloat) 0.284759,
+       (GLfloat) 0.194188, (GLfloat) - 0.938724, (GLfloat) 0.284759,
+       (GLfloat) 0.553716, (GLfloat) - 0.796850, (GLfloat) 0.241722,
+       (GLfloat) 0.830227, (GLfloat) - 0.533423, (GLfloat) 0.161812,
+       (GLfloat) 0.980604, (GLfloat) - 0.187557, (GLfloat) 0.056895,
+       (GLfloat) 0.980604, (GLfloat) 0.187558, (GLfloat) - 0.056895,
+       (GLfloat) 0.830228, (GLfloat) 0.533422, (GLfloat) - 0.161812,
+       (GLfloat) 0.553717, (GLfloat) 0.796849, (GLfloat) - 0.241722,
+       (GLfloat) 0.194186, (GLfloat) 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) - 0.194186, (GLfloat) 0.976241, (GLfloat) - 0.096151,
+       (GLfloat) - 0.553717, (GLfloat) 0.828695, (GLfloat) - 0.081619,
+       (GLfloat) - 0.830228, (GLfloat) 0.554740, (GLfloat) - 0.054637,
+       (GLfloat) - 0.980604, (GLfloat) 0.195054, (GLfloat) - 0.019211,
+       (GLfloat) - 0.980604, (GLfloat) - 0.195054, (GLfloat) 0.019211,
+       (GLfloat) - 0.830227, (GLfloat) - 0.554741, (GLfloat) 0.054637,
+       (GLfloat) - 0.553717, (GLfloat) - 0.828695, (GLfloat) 0.081619,
+       (GLfloat) - 0.194187, (GLfloat) - 0.976241, (GLfloat) 0.096151,
+       (GLfloat) 0.194187, (GLfloat) - 0.976241, (GLfloat) 0.096151,
+       (GLfloat) 0.553716, (GLfloat) - 0.828696, (GLfloat) 0.081620,
+       (GLfloat) 0.830227, (GLfloat) - 0.554741, (GLfloat) 0.054637,
+       (GLfloat) 0.980604, (GLfloat) - 0.195054, (GLfloat) 0.019211,
+       (GLfloat) 0.980604, (GLfloat) 0.195054, (GLfloat) - 0.019211,
+       (GLfloat) 0.830228, (GLfloat) 0.554740, (GLfloat) - 0.054637,
+       (GLfloat) 0.553716, (GLfloat) 0.828696, (GLfloat) - 0.081619,
+};
+
+static unsigned short int BigValve_POLS[] =
+{
+       16, 684, 685, 686, 687, 688, 689, 690, 691, 692, 693, 694, 695, 696, 697, 698, 699, 1, 4, 700,
+       701, 685, 684, 1, 4, 701, 702, 686, 685, 1, 4, 702, 703, 687, 686, 1, 4, 703, 704, 688,
+       687, 1, 4, 704, 705, 689, 688, 1, 4, 705, 706, 690, 689, 1, 4, 706, 707, 691, 690, 1,
+       4, 707, 708, 692, 691, 1, 4, 708, 709, 693, 692, 1, 4, 709, 710, 694, 693, 1, 4, 710,
+       711, 695, 694, 1, 4, 711, 712, 696, 695, 1, 4, 712, 713, 697, 696, 1, 4, 713, 714, 698,
+       697, 1, 4, 714, 715, 699, 698, 1, 4, 715, 700, 684, 699, 1, 16, 700, 715, 714, 713, 712,
+       711, 710, 709, 708, 707, 706, 705, 704, 703, 702, 701, 1, 4, 668, 669, 655, 654, 1, 4, 669,
+       670, 656, 655, 1, 4, 670, 671, 657, 656, 1, 4, 671, 672, 634, 657, 1, 4, 672, 673, 658,
+       634, 1, 4, 673, 674, 659, 658, 1, 4, 674, 675, 660, 659, 1, 4, 675, 676, 661, 660, 1,
+       4, 676, 677, 662, 661, 1, 4, 677, 678, 663, 662, 1, 4, 678, 679, 664, 663, 1, 4, 679,
+       680, 564, 664, 1, 4, 680, 681, 665, 564, 1, 4, 681, 682, 666, 665, 1, 4, 682, 683, 667,
+       666, 1, 4, 683, 668, 654, 667, 1, 4, 638, 639, 624, 623, 1, 4, 639, 640, 625, 624, 1,
+       4, 640, 641, 626, 625, 1, 4, 641, 642, 603, 626, 1, 4, 642, 643, 627, 603, 1, 4, 643,
+       644, 628, 627, 1, 4, 644, 645, 629, 628, 1, 4, 645, 646, 630, 629, 1, 4, 646, 647, 631,
+       630, 1, 4, 647, 648, 632, 631, 1, 4, 648, 649, 633, 632, 1, 4, 649, 650, 634, 633, 1,
+       4, 650, 651, 635, 634, 1, 4, 651, 652, 636, 635, 1, 4, 652, 653, 637, 636, 1, 4, 653,
+       638, 623, 637, 1, 4, 607, 608, 593, 592, 1, 4, 608, 609, 594, 593, 1, 4, 609, 610, 595,
+       594, 1, 4, 610, 611, 572, 595, 1, 4, 611, 612, 596, 572, 1, 4, 612, 613, 597, 596, 1,
+       4, 613, 614, 598, 597, 1, 4, 614, 615, 599, 598, 1, 4, 615, 616, 600, 599, 1, 4, 616,
+       617, 601, 600, 1, 4, 617, 618, 602, 601, 1, 4, 618, 619, 603, 602, 1, 4, 619, 620, 604,
+       603, 1, 4, 620, 621, 605, 604, 1, 4, 621, 622, 606, 605, 1, 4, 622, 607, 592, 606, 1,
+       4, 576, 577, 561, 560, 1, 4, 577, 578, 562, 561, 1, 4, 578, 579, 563, 562, 1, 4, 579,
+       580, 564, 563, 1, 4, 580, 581, 565, 564, 1, 4, 581, 582, 566, 565, 1, 4, 582, 583, 567,
+       566, 1, 4, 583, 584, 568, 567, 1, 4, 584, 585, 569, 568, 1, 4, 585, 586, 570, 569, 1,
+       4, 586, 587, 571, 570, 1, 4, 587, 588, 572, 571, 1, 4, 588, 589, 573, 572, 1, 4, 589,
+       590, 574, 573, 1, 4, 590, 591, 575, 574, 1, 4, 591, 576, 560, 575, 1, 24, 512, 513, 514,
+       515, 516, 517, 518, 519, 520, 521, 522, 523, 524, 525, 526, 527, 528, 529, 530, 531, 532, 533, 534,
+       535, 1, 4, 536, 537, 513, 512, 1, 4, 537, 538, 514, 513, 1, 4, 538, 539, 515, 514, 1,
+       4, 539, 540, 516, 515, 1, 4, 540, 541, 517, 516, 1, 4, 541, 542, 518, 517, 1, 4, 542,
+       543, 519, 518, 1, 4, 543, 544, 520, 519, 1, 4, 544, 545, 521, 520, 1, 4, 545, 546, 522,
+       521, 1, 4, 546, 547, 523, 522, 1, 4, 547, 548, 524, 523, 1, 4, 548, 549, 525, 524, 1,
+       4, 549, 550, 526, 525, 1, 4, 550, 551, 527, 526, 1, 4, 551, 552, 528, 527, 1, 4, 552,
+       553, 529, 528, 1, 4, 553, 554, 530, 529, 1, 4, 554, 555, 531, 530, 1, 4, 555, 556, 532,
+       531, 1, 4, 556, 557, 533, 532, 1, 4, 557, 558, 534, 533, 1, 4, 558, 559, 535, 534, 1,
+       4, 559, 536, 512, 535, 1, 24, 536, 559, 558, 557, 556, 555, 554, 553, 552, 551, 550, 549, 548,
+       547, 546, 545, 544, 543, 542, 541, 540, 539, 538, 537, 1, 4, 16, 31, 15, 0, 1, 4, 31,
+    30, 14, 15, 1, 4, 30, 29, 13, 14, 1, 4, 29, 28, 12, 13, 1, 4, 28, 27, 11,
+       12, 1, 4, 27, 26, 10, 11, 1, 4, 26, 25, 9, 10, 1, 4, 25, 24, 8, 9, 1,
+       4, 24, 23, 7, 8, 1, 4, 23, 22, 6, 7, 1, 4, 22, 21, 5, 6, 1, 4, 21,
+       20, 4, 5, 1, 4, 20, 19, 3, 4, 1, 4, 19, 18, 2, 3, 1, 4, 18, 17, 1,
+       2, 1, 4, 17, 16, 0, 1, 1, 4, 32, 47, 31, 16, 1, 4, 47, 46, 30, 31, 1,
+     4, 46, 45, 29, 30, 1, 4, 45, 44, 28, 29, 1, 4, 44, 43, 27, 28, 1, 4, 43,
+    42, 26, 27, 1, 4, 42, 41, 25, 26, 1, 4, 41, 40, 24, 25, 1, 4, 40, 39, 23,
+     24, 1, 4, 39, 38, 22, 23, 1, 4, 38, 37, 21, 22, 1, 4, 37, 36, 20, 21, 1,
+     4, 36, 35, 19, 20, 1, 4, 35, 34, 18, 19, 1, 4, 34, 33, 17, 18, 1, 4, 33,
+    32, 16, 17, 1, 4, 48, 63, 47, 32, 1, 4, 63, 62, 46, 47, 1, 4, 62, 61, 45,
+     46, 1, 4, 61, 60, 44, 45, 1, 4, 60, 59, 43, 44, 1, 4, 59, 58, 42, 43, 1,
+     4, 58, 57, 41, 42, 1, 4, 57, 56, 40, 41, 1, 4, 56, 55, 39, 40, 1, 4, 55,
+    54, 38, 39, 1, 4, 54, 53, 37, 38, 1, 4, 53, 52, 36, 37, 1, 4, 52, 51, 35,
+     36, 1, 4, 51, 50, 34, 35, 1, 4, 50, 49, 33, 34, 1, 4, 49, 48, 32, 33, 1,
+     4, 64, 79, 63, 48, 1, 4, 79, 78, 62, 63, 1, 4, 78, 77, 61, 62, 1, 4, 77,
+    76, 60, 61, 1, 4, 76, 75, 59, 60, 1, 4, 75, 74, 58, 59, 1, 4, 74, 73, 57,
+     58, 1, 4, 73, 72, 56, 57, 1, 4, 72, 71, 55, 56, 1, 4, 71, 70, 54, 55, 1,
+     4, 70, 69, 53, 54, 1, 4, 69, 68, 52, 53, 1, 4, 68, 67, 51, 52, 1, 4, 67,
+    66, 50, 51, 1, 4, 66, 65, 49, 50, 1, 4, 65, 64, 48, 49, 1, 4, 80, 95, 79,
+     64, 1, 4, 95, 94, 78, 79, 1, 4, 94, 93, 77, 78, 1, 4, 93, 92, 76, 77, 1,
+     4, 92, 91, 75, 76, 1, 4, 91, 90, 74, 75, 1, 4, 90, 89, 73, 74, 1, 4, 89,
+    88, 72, 73, 1, 4, 88, 87, 71, 72, 1, 4, 87, 86, 70, 71, 1, 4, 86, 85, 69,
+     70, 1, 4, 85, 84, 68, 69, 1, 4, 84, 83, 67, 68, 1, 4, 83, 82, 66, 67, 1,
+   4, 82, 81, 65, 66, 1, 4, 81, 80, 64, 65, 1, 4, 96, 111, 95, 80, 1, 4, 111,
+       110, 94, 95, 1, 4, 110, 109, 93, 94, 1, 4, 109, 108, 92, 93, 1, 4, 108, 107, 91,
+92, 1, 4, 107, 106, 90, 91, 1, 4, 106, 105, 89, 90, 1, 4, 105, 104, 88, 89, 1,
+       4, 104, 103, 87, 88, 1, 4, 103, 102, 86, 87, 1, 4, 102, 101, 85, 86, 1, 4, 101,
+  100, 84, 85, 1, 4, 100, 99, 83, 84, 1, 4, 99, 98, 82, 83, 1, 4, 98, 97, 81,
+       82, 1, 4, 97, 96, 80, 81, 1, 4, 112, 127, 111, 96, 1, 4, 127, 126, 110, 111, 1,
+       4, 126, 125, 109, 110, 1, 4, 125, 124, 108, 109, 1, 4, 124, 123, 107, 108, 1, 4, 123,
+       122, 106, 107, 1, 4, 122, 121, 105, 106, 1, 4, 121, 120, 104, 105, 1, 4, 120, 119, 103,
+       104, 1, 4, 119, 118, 102, 103, 1, 4, 118, 117, 101, 102, 1, 4, 117, 116, 100, 101, 1,
+       4, 116, 115, 99, 100, 1, 4, 115, 114, 98, 99, 1, 4, 114, 113, 97, 98, 1, 4, 113,
+       112, 96, 97, 1, 4, 128, 143, 127, 112, 1, 4, 143, 142, 126, 127, 1, 4, 142, 141, 125,
+       126, 1, 4, 141, 140, 124, 125, 1, 4, 140, 139, 123, 124, 1, 4, 139, 138, 122, 123, 1,
+       4, 138, 137, 121, 122, 1, 4, 137, 136, 120, 121, 1, 4, 136, 135, 119, 120, 1, 4, 135,
+       134, 118, 119, 1, 4, 134, 133, 117, 118, 1, 4, 133, 132, 116, 117, 1, 4, 132, 131, 115,
+       116, 1, 4, 131, 130, 114, 115, 1, 4, 130, 129, 113, 114, 1, 4, 129, 128, 112, 113, 1,
+       4, 144, 159, 143, 128, 1, 4, 159, 158, 142, 143, 1, 4, 158, 157, 141, 142, 1, 4, 157,
+       156, 140, 141, 1, 4, 156, 155, 139, 140, 1, 4, 155, 154, 138, 139, 1, 4, 154, 153, 137,
+       138, 1, 4, 153, 152, 136, 137, 1, 4, 152, 151, 135, 136, 1, 4, 151, 150, 134, 135, 1,
+       4, 150, 149, 133, 134, 1, 4, 149, 148, 132, 133, 1, 4, 148, 147, 131, 132, 1, 4, 147,
+       146, 130, 131, 1, 4, 146, 145, 129, 130, 1, 4, 145, 144, 128, 129, 1, 4, 160, 175, 159,
+       144, 1, 4, 175, 174, 158, 159, 1, 4, 174, 173, 157, 158, 1, 4, 173, 172, 156, 157, 1,
+       4, 172, 171, 155, 156, 1, 4, 171, 170, 154, 155, 1, 4, 170, 169, 153, 154, 1, 4, 169,
+       168, 152, 153, 1, 4, 168, 167, 151, 152, 1, 4, 167, 166, 150, 151, 1, 4, 166, 165, 149,
+       150, 1, 4, 165, 164, 148, 149, 1, 4, 164, 163, 147, 148, 1, 4, 163, 162, 146, 147, 1,
+       4, 162, 161, 145, 146, 1, 4, 161, 160, 144, 145, 1, 4, 176, 191, 175, 160, 1, 4, 191,
+       190, 174, 175, 1, 4, 190, 189, 173, 174, 1, 4, 189, 188, 172, 173, 1, 4, 188, 187, 171,
+       172, 1, 4, 187, 186, 170, 171, 1, 4, 186, 185, 169, 170, 1, 4, 185, 184, 168, 169, 1,
+       4, 184, 183, 167, 168, 1, 4, 183, 182, 166, 167, 1, 4, 182, 181, 165, 166, 1, 4, 181,
+       180, 164, 165, 1, 4, 180, 179, 163, 164, 1, 4, 179, 178, 162, 163, 1, 4, 178, 177, 161,
+       162, 1, 4, 177, 176, 160, 161, 1, 4, 192, 207, 191, 176, 1, 4, 207, 206, 190, 191, 1,
+       4, 206, 205, 189, 190, 1, 4, 205, 204, 188, 189, 1, 4, 204, 203, 187, 188, 1, 4, 203,
+       202, 186, 187, 1, 4, 202, 201, 185, 186, 1, 4, 201, 200, 184, 185, 1, 4, 200, 199, 183,
+       184, 1, 4, 199, 198, 182, 183, 1, 4, 198, 197, 181, 182, 1, 4, 197, 196, 180, 181, 1,
+       4, 196, 195, 179, 180, 1, 4, 195, 194, 178, 179, 1, 4, 194, 193, 177, 178, 1, 4, 193,
+       192, 176, 177, 1, 4, 208, 223, 207, 192, 1, 4, 223, 222, 206, 207, 1, 4, 222, 221, 205,
+       206, 1, 4, 221, 220, 204, 205, 1, 4, 220, 219, 203, 204, 1, 4, 219, 218, 202, 203, 1,
+       4, 218, 217, 201, 202, 1, 4, 217, 216, 200, 201, 1, 4, 216, 215, 199, 200, 1, 4, 215,
+       214, 198, 199, 1, 4, 214, 213, 197, 198, 1, 4, 213, 212, 196, 197, 1, 4, 212, 211, 195,
+       196, 1, 4, 211, 210, 194, 195, 1, 4, 210, 209, 193, 194, 1, 4, 209, 208, 192, 193, 1,
+       4, 224, 239, 223, 208, 1, 4, 239, 238, 222, 223, 1, 4, 238, 237, 221, 222, 1, 4, 237,
+       236, 220, 221, 1, 4, 236, 235, 219, 220, 1, 4, 235, 234, 218, 219, 1, 4, 234, 233, 217,
+       218, 1, 4, 233, 232, 216, 217, 1, 4, 232, 231, 215, 216, 1, 4, 231, 230, 214, 215, 1,
+       4, 230, 229, 213, 214, 1, 4, 229, 228, 212, 213, 1, 4, 228, 227, 211, 212, 1, 4, 227,
+       226, 210, 211, 1, 4, 226, 225, 209, 210, 1, 4, 225, 224, 208, 209, 1, 4, 240, 255, 239,
+       224, 1, 4, 255, 254, 238, 239, 1, 4, 254, 253, 237, 238, 1, 4, 253, 252, 236, 237, 1,
+       4, 252, 251, 235, 236, 1, 4, 251, 250, 234, 235, 1, 4, 250, 249, 233, 234, 1, 4, 249,
+       248, 232, 233, 1, 4, 248, 247, 231, 232, 1, 4, 247, 246, 230, 231, 1, 4, 246, 245, 229,
+       230, 1, 4, 245, 244, 228, 229, 1, 4, 244, 243, 227, 228, 1, 4, 243, 242, 226, 227, 1,
+       4, 242, 241, 225, 226, 1, 4, 241, 240, 224, 225, 1, 4, 256, 271, 255, 240, 1, 4, 271,
+       270, 254, 255, 1, 4, 270, 269, 253, 254, 1, 4, 269, 268, 252, 253, 1, 4, 268, 267, 251,
+       252, 1, 4, 267, 266, 250, 251, 1, 4, 266, 265, 249, 250, 1, 4, 265, 264, 248, 249, 1,
+       4, 264, 263, 247, 248, 1, 4, 263, 262, 246, 247, 1, 4, 262, 261, 245, 246, 1, 4, 261,
+       260, 244, 245, 1, 4, 260, 259, 243, 244, 1, 4, 259, 258, 242, 243, 1, 4, 258, 257, 241,
+       242, 1, 4, 257, 256, 240, 241, 1, 4, 272, 287, 271, 256, 1, 4, 287, 286, 270, 271, 1,
+       4, 286, 285, 269, 270, 1, 4, 285, 284, 268, 269, 1, 4, 284, 283, 267, 268, 1, 4, 283,
+       282, 266, 267, 1, 4, 282, 281, 265, 266, 1, 4, 281, 280, 264, 265, 1, 4, 280, 279, 263,
+       264, 1, 4, 279, 278, 262, 263, 1, 4, 278, 277, 261, 262, 1, 4, 277, 276, 260, 261, 1,
+       4, 276, 275, 259, 260, 1, 4, 275, 274, 258, 259, 1, 4, 274, 273, 257, 258, 1, 4, 273,
+       272, 256, 257, 1, 4, 288, 303, 287, 272, 1, 4, 303, 302, 286, 287, 1, 4, 302, 301, 285,
+       286, 1, 4, 301, 300, 284, 285, 1, 4, 300, 299, 283, 284, 1, 4, 299, 298, 282, 283, 1,
+       4, 298, 297, 281, 282, 1, 4, 297, 296, 280, 281, 1, 4, 296, 295, 279, 280, 1, 4, 295,
+       294, 278, 279, 1, 4, 294, 293, 277, 278, 1, 4, 293, 292, 276, 277, 1, 4, 292, 291, 275,
+       276, 1, 4, 291, 290, 274, 275, 1, 4, 290, 289, 273, 274, 1, 4, 289, 288, 272, 273, 1,
+       4, 304, 319, 303, 288, 1, 4, 319, 318, 302, 303, 1, 4, 318, 317, 301, 302, 1, 4, 317,
+       316, 300, 301, 1, 4, 316, 315, 299, 300, 1, 4, 315, 314, 298, 299, 1, 4, 314, 313, 297,
+       298, 1, 4, 313, 312, 296, 297, 1, 4, 312, 311, 295, 296, 1, 4, 311, 310, 294, 295, 1,
+       4, 310, 309, 293, 294, 1, 4, 309, 308, 292, 293, 1, 4, 308, 307, 291, 292, 1, 4, 307,
+       306, 290, 291, 1, 4, 306, 305, 289, 290, 1, 4, 305, 304, 288, 289, 1, 4, 320, 335, 319,
+       304, 1, 4, 335, 334, 318, 319, 1, 4, 334, 333, 317, 318, 1, 4, 333, 332, 316, 317, 1,
+       4, 332, 331, 315, 316, 1, 4, 331, 330, 314, 315, 1, 4, 330, 329, 313, 314, 1, 4, 329,
+       328, 312, 313, 1, 4, 328, 327, 311, 312, 1, 4, 327, 326, 310, 311, 1, 4, 326, 325, 309,
+       310, 1, 4, 325, 324, 308, 309, 1, 4, 324, 323, 307, 308, 1, 4, 323, 322, 306, 307, 1,
+       4, 322, 321, 305, 306, 1, 4, 321, 320, 304, 305, 1, 4, 336, 351, 335, 320, 1, 4, 351,
+       350, 334, 335, 1, 4, 350, 349, 333, 334, 1, 4, 349, 348, 332, 333, 1, 4, 348, 347, 331,
+       332, 1, 4, 347, 346, 330, 331, 1, 4, 346, 345, 329, 330, 1, 4, 345, 344, 328, 329, 1,
+       4, 344, 343, 327, 328, 1, 4, 343, 342, 326, 327, 1, 4, 342, 341, 325, 326, 1, 4, 341,
+       340, 324, 325, 1, 4, 340, 339, 323, 324, 1, 4, 339, 338, 322, 323, 1, 4, 338, 337, 321,
+       322, 1, 4, 337, 336, 320, 321, 1, 4, 352, 367, 351, 336, 1, 4, 367, 366, 350, 351, 1,
+       4, 366, 365, 349, 350, 1, 4, 365, 364, 348, 349, 1, 4, 364, 363, 347, 348, 1, 4, 363,
+       362, 346, 347, 1, 4, 362, 361, 345, 346, 1, 4, 361, 360, 344, 345, 1, 4, 360, 359, 343,
+       344, 1, 4, 359, 358, 342, 343, 1, 4, 358, 357, 341, 342, 1, 4, 357, 356, 340, 341, 1,
+       4, 356, 355, 339, 340, 1, 4, 355, 354, 338, 339, 1, 4, 354, 353, 337, 338, 1, 4, 353,
+       352, 336, 337, 1, 4, 368, 383, 367, 352, 1, 4, 383, 382, 366, 367, 1, 4, 382, 381, 365,
+       366, 1, 4, 381, 380, 364, 365, 1, 4, 380, 379, 363, 364, 1, 4, 379, 378, 362, 363, 1,
+       4, 378, 377, 361, 362, 1, 4, 377, 376, 360, 361, 1, 4, 376, 375, 359, 360, 1, 4, 375,
+       374, 358, 359, 1, 4, 374, 373, 357, 358, 1, 4, 373, 372, 356, 357, 1, 4, 372, 371, 355,
+       356, 1, 4, 371, 370, 354, 355, 1, 4, 370, 369, 353, 354, 1, 4, 369, 368, 352, 353, 1,
+       4, 384, 399, 383, 368, 1, 4, 399, 398, 382, 383, 1, 4, 398, 397, 381, 382, 1, 4, 397,
+       396, 380, 381, 1, 4, 396, 395, 379, 380, 1, 4, 395, 394, 378, 379, 1, 4, 394, 393, 377,
+       378, 1, 4, 393, 392, 376, 377, 1, 4, 392, 391, 375, 376, 1, 4, 391, 390, 374, 375, 1,
+       4, 390, 389, 373, 374, 1, 4, 389, 388, 372, 373, 1, 4, 388, 387, 371, 372, 1, 4, 387,
+       386, 370, 371, 1, 4, 386, 385, 369, 370, 1, 4, 385, 384, 368, 369, 1, 4, 400, 415, 399,
+       384, 1, 4, 415, 414, 398, 399, 1, 4, 414, 413, 397, 398, 1, 4, 413, 412, 396, 397, 1,
+       4, 412, 411, 395, 396, 1, 4, 411, 410, 394, 395, 1, 4, 410, 409, 393, 394, 1, 4, 409,
+       408, 392, 393, 1, 4, 408, 407, 391, 392, 1, 4, 407, 406, 390, 391, 1, 4, 406, 405, 389,
+       390, 1, 4, 405, 404, 388, 389, 1, 4, 404, 403, 387, 388, 1, 4, 403, 402, 386, 387, 1,
+       4, 402, 401, 385, 386, 1, 4, 401, 400, 384, 385, 1, 4, 416, 431, 415, 400, 1, 4, 431,
+       430, 414, 415, 1, 4, 430, 429, 413, 414, 1, 4, 429, 428, 412, 413, 1, 4, 428, 427, 411,
+       412, 1, 4, 427, 426, 410, 411, 1, 4, 426, 425, 409, 410, 1, 4, 425, 424, 408, 409, 1,
+       4, 424, 423, 407, 408, 1, 4, 423, 422, 406, 407, 1, 4, 422, 421, 405, 406, 1, 4, 421,
+       420, 404, 405, 1, 4, 420, 419, 403, 404, 1, 4, 419, 418, 402, 403, 1, 4, 418, 417, 401,
+       402, 1, 4, 417, 416, 400, 401, 1, 4, 432, 447, 431, 416, 1, 4, 447, 446, 430, 431, 1,
+       4, 446, 445, 429, 430, 1, 4, 445, 444, 428, 429, 1, 4, 444, 443, 427, 428, 1, 4, 443,
+       442, 426, 427, 1, 4, 442, 441, 425, 426, 1, 4, 441, 440, 424, 425, 1, 4, 440, 439, 423,
+       424, 1, 4, 439, 438, 422, 423, 1, 4, 438, 437, 421, 422, 1, 4, 437, 436, 420, 421, 1,
+       4, 436, 435, 419, 420, 1, 4, 435, 434, 418, 419, 1, 4, 434, 433, 417, 418, 1, 4, 433,
+       432, 416, 417, 1, 4, 448, 463, 447, 432, 1, 4, 463, 462, 446, 447, 1, 4, 462, 461, 445,
+       446, 1, 4, 461, 460, 444, 445, 1, 4, 460, 459, 443, 444, 1, 4, 459, 458, 442, 443, 1,
+       4, 458, 457, 441, 442, 1, 4, 457, 456, 440, 441, 1, 4, 456, 455, 439, 440, 1, 4, 455,
+       454, 438, 439, 1, 4, 454, 453, 437, 438, 1, 4, 453, 452, 436, 437, 1, 4, 452, 451, 435,
+       436, 1, 4, 451, 450, 434, 435, 1, 4, 450, 449, 433, 434, 1, 4, 449, 448, 432, 433, 1,
+       4, 464, 479, 463, 448, 1, 4, 479, 478, 462, 463, 1, 4, 478, 477, 461, 462, 1, 4, 477,
+       476, 460, 461, 1, 4, 476, 475, 459, 460, 1, 4, 475, 474, 458, 459, 1, 4, 474, 473, 457,
+       458, 1, 4, 473, 472, 456, 457, 1, 4, 472, 471, 455, 456, 1, 4, 471, 470, 454, 455, 1,
+       4, 470, 469, 453, 454, 1, 4, 469, 468, 452, 453, 1, 4, 468, 467, 451, 452, 1, 4, 467,
+       466, 450, 451, 1, 4, 466, 465, 449, 450, 1, 4, 465, 464, 448, 449, 1, 4, 480, 495, 479,
+       464, 1, 4, 495, 494, 478, 479, 1, 4, 494, 493, 477, 478, 1, 4, 493, 492, 476, 477, 1,
+       4, 492, 491, 475, 476, 1, 4, 491, 490, 474, 475, 1, 4, 490, 489, 473, 474, 1, 4, 489,
+       488, 472, 473, 1, 4, 488, 487, 471, 472, 1, 4, 487, 486, 470, 471, 1, 4, 486, 485, 469,
+       470, 1, 4, 485, 484, 468, 469, 1, 4, 484, 483, 467, 468, 1, 4, 483, 482, 466, 467, 1,
+       4, 482, 481, 465, 466, 1, 4, 481, 480, 464, 465, 1, 4, 496, 511, 495, 480, 1, 4, 511,
+       510, 494, 495, 1, 4, 510, 509, 493, 494, 1, 4, 509, 508, 492, 493, 1, 4, 508, 507, 491,
+       492, 1, 4, 507, 506, 490, 491, 1, 4, 506, 505, 489, 490, 1, 4, 505, 504, 488, 489, 1,
+       4, 504, 503, 487, 488, 1, 4, 503, 502, 486, 487, 1, 4, 502, 501, 485, 486, 1, 4, 501,
+       500, 484, 485, 1, 4, 500, 499, 483, 484, 1, 4, 499, 498, 482, 483, 1, 4, 498, 497, 481,
+       482, 1, 4, 497, 496, 480, 481, 1, 4, 0, 15, 511, 496, 1, 4, 15, 14, 510, 511, 1,
+4, 14, 13, 509, 510, 1, 4, 13, 12, 508, 509, 1, 4, 12, 11, 507, 508, 1, 4, 11,
+  10, 506, 507, 1, 4, 10, 9, 505, 506, 1, 4, 9, 8, 504, 505, 1, 4, 8, 7, 503,
+    504, 1, 4, 7, 6, 502, 503, 1, 4, 6, 5, 501, 502, 1, 4, 5, 4, 500, 501, 1,
+      4, 4, 3, 499, 500, 1, 4, 3, 2, 498, 499, 1, 4, 2, 1, 497, 498, 1, 4, 1,
+       0, 496, 497, 1,
+       0
+};
+
+struct lwo  LWO_BigValve =
+{
+       716,                    /* number of points */
+       BigValve_PNTS, BigValve_normals, BigValve_POLS, 0L
+};
+
+static GLfloat Bolts3D_PNTS[] =
+{
+       (GLfloat) - 0.160704, (GLfloat) 0.399000, (GLfloat) 0.600000,
+       (GLfloat) - 0.160704, (GLfloat) 0.399000, (GLfloat) - 0.500000,
+       (GLfloat) - 0.400000, (GLfloat) 0.160257, (GLfloat) 0.600000,
+       (GLfloat) - 0.400000, (GLfloat) 0.160257, (GLfloat) - 0.500000,
+       (GLfloat) - 0.400000, (GLfloat) - 0.170369, (GLfloat) 0.600000,
+       (GLfloat) - 0.400000, (GLfloat) - 0.170369, (GLfloat) - 0.500000,
+       (GLfloat) - 0.153738, (GLfloat) - 0.400000, (GLfloat) 0.600000,
+       (GLfloat) - 0.153738, (GLfloat) - 0.400000, (GLfloat) - 0.500000,
+       (GLfloat) 0.176887, (GLfloat) - 0.400000, (GLfloat) 0.600000,
+       (GLfloat) 0.176887, (GLfloat) - 0.400000, (GLfloat) - 0.500000,
+       (GLfloat) 0.400000, (GLfloat) - 0.163403, (GLfloat) 0.600000,
+       (GLfloat) 0.400000, (GLfloat) - 0.163403, (GLfloat) - 0.500000,
+       (GLfloat) 0.400000, (GLfloat) 0.167223, (GLfloat) 0.600000,
+       (GLfloat) 0.400000, (GLfloat) 0.167223, (GLfloat) - 0.500000,
+       (GLfloat) 0.169922, (GLfloat) 0.399000, (GLfloat) 0.600000,
+       (GLfloat) 0.169922, (GLfloat) 0.399000, (GLfloat) - 0.500000,
+       (GLfloat) - 0.160704, (GLfloat) 0.399000, (GLfloat) 0.500000,
+       (GLfloat) - 0.160704, (GLfloat) 0.399000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.400000, (GLfloat) 0.160257, (GLfloat) - 0.600000,
+       (GLfloat) - 0.400000, (GLfloat) 0.160257, (GLfloat) 0.500000,
+       (GLfloat) - 0.400000, (GLfloat) - 0.170369, (GLfloat) - 0.600000,
+       (GLfloat) - 0.400000, (GLfloat) - 0.170369, (GLfloat) 0.500000,
+       (GLfloat) - 0.153738, (GLfloat) - 0.400000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.153738, (GLfloat) - 0.400000, (GLfloat) 0.500000,
+       (GLfloat) 0.176887, (GLfloat) - 0.400000, (GLfloat) 0.500000,
+       (GLfloat) 0.176887, (GLfloat) - 0.400000, (GLfloat) - 0.600000,
+       (GLfloat) 0.400000, (GLfloat) - 0.163403, (GLfloat) 0.500000,
+       (GLfloat) 0.400000, (GLfloat) - 0.163403, (GLfloat) - 0.600000,
+       (GLfloat) 0.400000, (GLfloat) 0.167223, (GLfloat) - 0.600000,
+       (GLfloat) 0.400000, (GLfloat) 0.167223, (GLfloat) 0.500000,
+       (GLfloat) 0.169922, (GLfloat) 0.399000, (GLfloat) - 0.600000,
+       (GLfloat) 0.169922, (GLfloat) 0.399000, (GLfloat) 0.500000,
+};
+
+static GLfloat Bolts3D_normals[] =
+{
+       (GLfloat) 0.000000, (GLfloat) 1.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.709703, (GLfloat) 0.704502, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.727535, (GLfloat) - 0.686070, (GLfloat) - 0.000000,
+       (GLfloat) 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.681980, (GLfloat) - 0.731370, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.706289, (GLfloat) 0.707924, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 1.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.709703, (GLfloat) 0.704502, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.727535, (GLfloat) - 0.686070, (GLfloat) - 0.000000,
+       (GLfloat) 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.681980, (GLfloat) - 0.731370, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.706289, (GLfloat) 0.707924, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+};
+
+static unsigned short int Bolts3D_POLS[] =
+{
+      4, 16, 31, 14, 0, 1, 4, 31, 29, 12, 14, 1, 4, 29, 26, 10, 12, 1, 4, 26,
+       24, 8, 10, 1, 4, 24, 23, 6, 8, 1, 4, 23, 21, 4, 6, 1, 4, 21, 19, 2,
+       4, 1, 4, 19, 16, 0, 2, 1, 8, 14, 12, 10, 8, 6, 4, 2, 0, 1, 4, 17,
+      30, 15, 1, 1, 4, 30, 28, 13, 15, 1, 4, 28, 27, 11, 13, 1, 4, 27, 25, 9,
+       11, 1, 4, 25, 22, 7, 9, 1, 4, 22, 20, 5, 7, 1, 4, 20, 18, 3, 5, 1,
+       4, 18, 17, 1, 3, 1, 8, 30, 17, 18, 20, 22, 25, 27, 28, 1,
+       0
+};
+
+struct lwo  LWO_Bolts3D =
+{
+       32,                     /* number of points */
+       Bolts3D_PNTS, Bolts3D_normals, Bolts3D_POLS, 0L
+};
+
+static GLfloat GuageConnector_PNTS[] =
+{
+       (GLfloat) 0.200000, (GLfloat) 0.400000, (GLfloat) - 0.000000,
+       (GLfloat) 0.200000, (GLfloat) 0.800000, (GLfloat) - 0.000000,
+       (GLfloat) 0.193185, (GLfloat) 0.400000, (GLfloat) - 0.051764,
+       (GLfloat) 0.193185, (GLfloat) 0.800000, (GLfloat) - 0.051764,
+       (GLfloat) 0.173205, (GLfloat) 0.400000, (GLfloat) - 0.100000,
+       (GLfloat) 0.173205, (GLfloat) 0.800000, (GLfloat) - 0.100000,
+       (GLfloat) 0.141421, (GLfloat) 0.800000, (GLfloat) - 0.141421,
+       (GLfloat) 0.141421, (GLfloat) 0.400000, (GLfloat) - 0.141421,
+       (GLfloat) 0.100000, (GLfloat) 0.400000, (GLfloat) - 0.173205,
+       (GLfloat) 0.100000, (GLfloat) 0.800000, (GLfloat) - 0.173205,
+       (GLfloat) 0.051764, (GLfloat) 0.800000, (GLfloat) - 0.193185,
+       (GLfloat) 0.051764, (GLfloat) 0.400000, (GLfloat) - 0.193185,
+       (GLfloat) 0.000000, (GLfloat) 0.800000, (GLfloat) - 0.200000,
+       (GLfloat) 0.000000, (GLfloat) 0.400000, (GLfloat) - 0.200000,
+       (GLfloat) - 0.051764, (GLfloat) 0.800000, (GLfloat) - 0.193185,
+       (GLfloat) - 0.051764, (GLfloat) 0.400000, (GLfloat) - 0.193185,
+       (GLfloat) - 0.100000, (GLfloat) 0.800000, (GLfloat) - 0.173205,
+       (GLfloat) - 0.100000, (GLfloat) 0.400000, (GLfloat) - 0.173205,
+       (GLfloat) - 0.141421, (GLfloat) 0.400000, (GLfloat) - 0.141421,
+       (GLfloat) - 0.141421, (GLfloat) 0.800000, (GLfloat) - 0.141421,
+       (GLfloat) - 0.173205, (GLfloat) 0.800000, (GLfloat) - 0.100000,
+       (GLfloat) - 0.173205, (GLfloat) 0.400000, (GLfloat) - 0.100000,
+       (GLfloat) - 0.193185, (GLfloat) 0.400000, (GLfloat) - 0.051764,
+       (GLfloat) - 0.193185, (GLfloat) 0.800000, (GLfloat) - 0.051764,
+       (GLfloat) - 0.200000, (GLfloat) 0.400000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.200000, (GLfloat) 0.800000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.193185, (GLfloat) 0.400000, (GLfloat) 0.051764,
+       (GLfloat) - 0.193185, (GLfloat) 0.800000, (GLfloat) 0.051764,
+       (GLfloat) - 0.173205, (GLfloat) 0.400000, (GLfloat) 0.100000,
+       (GLfloat) - 0.173205, (GLfloat) 0.800000, (GLfloat) 0.100000,
+       (GLfloat) - 0.141421, (GLfloat) 0.800000, (GLfloat) 0.141421,
+       (GLfloat) - 0.141421, (GLfloat) 0.400000, (GLfloat) 0.141421,
+       (GLfloat) - 0.100000, (GLfloat) 0.800000, (GLfloat) 0.173205,
+       (GLfloat) - 0.100000, (GLfloat) 0.400000, (GLfloat) 0.173205,
+       (GLfloat) - 0.051764, (GLfloat) 0.800000, (GLfloat) 0.193185,
+       (GLfloat) - 0.051764, (GLfloat) 0.400000, (GLfloat) 0.193185,
+       (GLfloat) - 0.000000, (GLfloat) 0.800000, (GLfloat) 0.200000,
+       (GLfloat) - 0.000000, (GLfloat) 0.400000, (GLfloat) 0.200000,
+       (GLfloat) 0.051764, (GLfloat) 0.800000, (GLfloat) 0.193185,
+       (GLfloat) 0.051764, (GLfloat) 0.400000, (GLfloat) 0.193185,
+       (GLfloat) 0.100000, (GLfloat) 0.400000, (GLfloat) 0.173205,
+       (GLfloat) 0.100000, (GLfloat) 0.800000, (GLfloat) 0.173205,
+       (GLfloat) 0.141421, (GLfloat) 0.400000, (GLfloat) 0.141421,
+       (GLfloat) 0.141421, (GLfloat) 0.800000, (GLfloat) 0.141421,
+       (GLfloat) 0.173205, (GLfloat) 0.800000, (GLfloat) 0.100000,
+       (GLfloat) 0.173205, (GLfloat) 0.400000, (GLfloat) 0.100000,
+       (GLfloat) 0.193185, (GLfloat) 0.400000, (GLfloat) 0.051764,
+       (GLfloat) 0.193185, (GLfloat) 0.800000, (GLfloat) 0.051764,
+       (GLfloat) 0.200000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) 0.193185, (GLfloat) 0.550000, (GLfloat) - 0.051764,
+       (GLfloat) 0.173205, (GLfloat) 0.550000, (GLfloat) - 0.100000,
+       (GLfloat) 0.141421, (GLfloat) 0.550000, (GLfloat) - 0.141421,
+       (GLfloat) 0.100000, (GLfloat) 0.550000, (GLfloat) - 0.173205,
+       (GLfloat) 0.051764, (GLfloat) 0.550000, (GLfloat) - 0.193185,
+       (GLfloat) 0.000000, (GLfloat) 0.550000, (GLfloat) - 0.200000,
+       (GLfloat) - 0.051764, (GLfloat) 0.550000, (GLfloat) - 0.193185,
+       (GLfloat) - 0.100000, (GLfloat) 0.550000, (GLfloat) - 0.173205,
+       (GLfloat) - 0.141421, (GLfloat) 0.550000, (GLfloat) - 0.141421,
+       (GLfloat) - 0.173205, (GLfloat) 0.550000, (GLfloat) - 0.100000,
+       (GLfloat) - 0.193185, (GLfloat) 0.550000, (GLfloat) - 0.051764,
+       (GLfloat) - 0.200000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.193185, (GLfloat) 0.550000, (GLfloat) 0.051764,
+       (GLfloat) - 0.173205, (GLfloat) 0.550000, (GLfloat) 0.100000,
+       (GLfloat) - 0.141421, (GLfloat) 0.550000, (GLfloat) 0.141421,
+       (GLfloat) - 0.100000, (GLfloat) 0.550000, (GLfloat) 0.173205,
+       (GLfloat) - 0.051764, (GLfloat) 0.550000, (GLfloat) 0.193185,
+       (GLfloat) - 0.000000, (GLfloat) 0.550000, (GLfloat) 0.200000,
+       (GLfloat) 0.051764, (GLfloat) 0.550000, (GLfloat) 0.193185,
+       (GLfloat) 0.100000, (GLfloat) 0.550000, (GLfloat) 0.173205,
+       (GLfloat) 0.141421, (GLfloat) 0.550000, (GLfloat) 0.141421,
+       (GLfloat) 0.173205, (GLfloat) 0.550000, (GLfloat) 0.100000,
+       (GLfloat) 0.193185, (GLfloat) 0.550000, (GLfloat) 0.051764,
+       (GLfloat) 0.150000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) 0.144889, (GLfloat) 0.550000, (GLfloat) - 0.038823,
+       (GLfloat) 0.129904, (GLfloat) 0.550000, (GLfloat) - 0.075000,
+       (GLfloat) 0.106066, (GLfloat) 0.550000, (GLfloat) - 0.106066,
+       (GLfloat) 0.075000, (GLfloat) 0.550000, (GLfloat) - 0.129904,
+       (GLfloat) 0.038823, (GLfloat) 0.550000, (GLfloat) - 0.144889,
+       (GLfloat) 0.000000, (GLfloat) 0.550000, (GLfloat) - 0.150000,
+       (GLfloat) - 0.038823, (GLfloat) 0.550000, (GLfloat) - 0.144889,
+       (GLfloat) - 0.075000, (GLfloat) 0.550000, (GLfloat) - 0.129904,
+       (GLfloat) - 0.106066, (GLfloat) 0.550000, (GLfloat) - 0.106066,
+       (GLfloat) - 0.129904, (GLfloat) 0.550000, (GLfloat) - 0.075000,
+       (GLfloat) - 0.144889, (GLfloat) 0.550000, (GLfloat) - 0.038823,
+       (GLfloat) - 0.150000, (GLfloat) 0.550000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.144889, (GLfloat) 0.550000, (GLfloat) 0.038823,
+       (GLfloat) - 0.129904, (GLfloat) 0.550000, (GLfloat) 0.075000,
+       (GLfloat) - 0.106066, (GLfloat) 0.550000, (GLfloat) 0.106066,
+       (GLfloat) - 0.075000, (GLfloat) 0.550000, (GLfloat) 0.129904,
+       (GLfloat) - 0.038823, (GLfloat) 0.550000, (GLfloat) 0.144889,
+       (GLfloat) - 0.000000, (GLfloat) 0.550000, (GLfloat) 0.150000,
+       (GLfloat) 0.038823, (GLfloat) 0.550000, (GLfloat) 0.144889,
+       (GLfloat) 0.075000, (GLfloat) 0.550000, (GLfloat) 0.129904,
+       (GLfloat) 0.106066, (GLfloat) 0.550000, (GLfloat) 0.106066,
+       (GLfloat) 0.129904, (GLfloat) 0.550000, (GLfloat) 0.075000,
+       (GLfloat) 0.144889, (GLfloat) 0.550000, (GLfloat) 0.038823,
+       (GLfloat) 0.150000, (GLfloat) 0.800000, (GLfloat) - 0.000000,
+       (GLfloat) 0.144889, (GLfloat) 0.800000, (GLfloat) - 0.038823,
+       (GLfloat) 0.129904, (GLfloat) 0.800000, (GLfloat) - 0.075000,
+       (GLfloat) 0.106066, (GLfloat) 0.800000, (GLfloat) - 0.106066,
+       (GLfloat) 0.075000, (GLfloat) 0.800000, (GLfloat) - 0.129904,
+       (GLfloat) 0.038823, (GLfloat) 0.800000, (GLfloat) - 0.144889,
+       (GLfloat) 0.000000, (GLfloat) 0.800000, (GLfloat) - 0.150000,
+       (GLfloat) - 0.038823, (GLfloat) 0.800000, (GLfloat) - 0.144889,
+       (GLfloat) - 0.075000, (GLfloat) 0.800000, (GLfloat) - 0.129904,
+       (GLfloat) - 0.106066, (GLfloat) 0.800000, (GLfloat) - 0.106066,
+       (GLfloat) - 0.129904, (GLfloat) 0.800000, (GLfloat) - 0.075000,
+       (GLfloat) - 0.144889, (GLfloat) 0.800000, (GLfloat) - 0.038823,
+       (GLfloat) - 0.150000, (GLfloat) 0.800000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.144889, (GLfloat) 0.800000, (GLfloat) 0.038823,
+       (GLfloat) - 0.129904, (GLfloat) 0.800000, (GLfloat) 0.075000,
+       (GLfloat) - 0.106066, (GLfloat) 0.800000, (GLfloat) 0.106066,
+       (GLfloat) - 0.075000, (GLfloat) 0.800000, (GLfloat) 0.129904,
+       (GLfloat) - 0.038823, (GLfloat) 0.800000, (GLfloat) 0.144889,
+       (GLfloat) - 0.000000, (GLfloat) 0.800000, (GLfloat) 0.150000,
+       (GLfloat) 0.038823, (GLfloat) 0.800000, (GLfloat) 0.144889,
+       (GLfloat) 0.075000, (GLfloat) 0.800000, (GLfloat) 0.129904,
+       (GLfloat) 0.106066, (GLfloat) 0.800000, (GLfloat) 0.106066,
+       (GLfloat) 0.129904, (GLfloat) 0.800000, (GLfloat) 0.075000,
+       (GLfloat) 0.144889, (GLfloat) 0.800000, (GLfloat) 0.038823,
+       (GLfloat) 0.200000, (GLfloat) 0.875988, (GLfloat) - 0.000000,
+       (GLfloat) 0.193185, (GLfloat) 0.872346, (GLfloat) - 0.051764,
+       (GLfloat) 0.191342, (GLfloat) 0.871360, (GLfloat) - 0.056214,
+       (GLfloat) 0.173205, (GLfloat) 0.865859, (GLfloat) - 0.100000,
+       (GLfloat) 0.141421, (GLfloat) 0.856217, (GLfloat) - 0.141421,
+       (GLfloat) 0.100000, (GLfloat) 0.843652, (GLfloat) - 0.173205,
+       (GLfloat) 0.097545, (GLfloat) 0.842907, (GLfloat) - 0.174222,
+       (GLfloat) 0.051764, (GLfloat) 0.838398, (GLfloat) - 0.193185,
+       (GLfloat) 0.000000, (GLfloat) 0.833300, (GLfloat) - 0.200000,
+       (GLfloat) - 0.051764, (GLfloat) 0.838398, (GLfloat) - 0.193185,
+       (GLfloat) - 0.097545, (GLfloat) 0.842907, (GLfloat) - 0.174222,
+       (GLfloat) - 0.100000, (GLfloat) 0.843652, (GLfloat) - 0.173205,
+       (GLfloat) - 0.141421, (GLfloat) 0.856217, (GLfloat) - 0.141421,
+       (GLfloat) - 0.173205, (GLfloat) 0.865859, (GLfloat) - 0.100000,
+       (GLfloat) - 0.191342, (GLfloat) 0.871360, (GLfloat) - 0.056214,
+       (GLfloat) - 0.193185, (GLfloat) 0.872346, (GLfloat) - 0.051764,
+       (GLfloat) - 0.200000, (GLfloat) 0.875988, (GLfloat) - 0.000000,
+       (GLfloat) - 0.193185, (GLfloat) 0.872346, (GLfloat) 0.051764,
+       (GLfloat) - 0.173205, (GLfloat) 0.865859, (GLfloat) 0.100000,
+       (GLfloat) - 0.191342, (GLfloat) 0.871360, (GLfloat) 0.056214,
+       (GLfloat) - 0.141421, (GLfloat) 0.856217, (GLfloat) 0.141421,
+       (GLfloat) - 0.100000, (GLfloat) 0.843652, (GLfloat) 0.173205,
+       (GLfloat) - 0.051764, (GLfloat) 0.838398, (GLfloat) 0.193185,
+       (GLfloat) - 0.097545, (GLfloat) 0.842907, (GLfloat) 0.174222,
+       (GLfloat) - 0.000000, (GLfloat) 0.833300, (GLfloat) 0.200000,
+       (GLfloat) 0.051764, (GLfloat) 0.838398, (GLfloat) 0.193185,
+       (GLfloat) 0.100000, (GLfloat) 0.843652, (GLfloat) 0.173205,
+       (GLfloat) 0.097545, (GLfloat) 0.842907, (GLfloat) 0.174222,
+       (GLfloat) 0.141421, (GLfloat) 0.856217, (GLfloat) 0.141421,
+       (GLfloat) 0.173205, (GLfloat) 0.865859, (GLfloat) 0.100000,
+       (GLfloat) 0.193185, (GLfloat) 0.872346, (GLfloat) 0.051764,
+       (GLfloat) 0.191342, (GLfloat) 0.871360, (GLfloat) 0.056214,
+};
+
+static GLfloat GuageConnector_normals[] =
+{
+       (GLfloat) 0.991445, (GLfloat) 0.000000, (GLfloat) - 0.130526,
+       (GLfloat) 0.923880, (GLfloat) 0.000000, (GLfloat) - 0.382683,
+       (GLfloat) 0.793353, (GLfloat) 0.000000, (GLfloat) - 0.608761,
+       (GLfloat) 0.608761, (GLfloat) 0.000000, (GLfloat) - 0.793353,
+       (GLfloat) 0.382683, (GLfloat) 0.000000, (GLfloat) - 0.923880,
+       (GLfloat) 0.130526, (GLfloat) 0.000000, (GLfloat) - 0.991445,
+       (GLfloat) - 0.130526, (GLfloat) - 0.000000, (GLfloat) - 0.991445,
+       (GLfloat) - 0.382683, (GLfloat) - 0.000000, (GLfloat) - 0.923880,
+       (GLfloat) - 0.608761, (GLfloat) - 0.000000, (GLfloat) - 0.793353,
+       (GLfloat) - 0.793353, (GLfloat) - 0.000000, (GLfloat) - 0.608761,
+       (GLfloat) - 0.923880, (GLfloat) - 0.000000, (GLfloat) - 0.382683,
+       (GLfloat) - 0.991445, (GLfloat) - 0.000000, (GLfloat) - 0.130526,
+       (GLfloat) - 0.991445, (GLfloat) 0.000000, (GLfloat) 0.130526,
+       (GLfloat) - 0.923880, (GLfloat) 0.000000, (GLfloat) 0.382683,
+       (GLfloat) - 0.793353, (GLfloat) 0.000000, (GLfloat) 0.608761,
+       (GLfloat) - 0.608761, (GLfloat) 0.000000, (GLfloat) 0.793353,
+       (GLfloat) - 0.382683, (GLfloat) 0.000000, (GLfloat) 0.923880,
+       (GLfloat) - 0.130526, (GLfloat) 0.000000, (GLfloat) 0.991445,
+       (GLfloat) 0.130526, (GLfloat) 0.000000, (GLfloat) 0.991445,
+       (GLfloat) 0.382683, (GLfloat) 0.000000, (GLfloat) 0.923880,
+       (GLfloat) 0.608761, (GLfloat) 0.000000, (GLfloat) 0.793353,
+       (GLfloat) 0.793353, (GLfloat) 0.000000, (GLfloat) 0.608761,
+       (GLfloat) 0.923880, (GLfloat) 0.000000, (GLfloat) 0.382683,
+       (GLfloat) 0.991445, (GLfloat) 0.000000, (GLfloat) 0.130526,
+       (GLfloat) 0.991445, (GLfloat) 0.000000, (GLfloat) - 0.130526,
+       (GLfloat) 0.923880, (GLfloat) 0.000000, (GLfloat) - 0.382684,
+       (GLfloat) 0.793353, (GLfloat) 0.000000, (GLfloat) - 0.608761,
+       (GLfloat) 0.608761, (GLfloat) 0.000000, (GLfloat) - 0.793353,
+       (GLfloat) 0.382684, (GLfloat) 0.000000, (GLfloat) - 0.923880,
+       (GLfloat) 0.130526, (GLfloat) 0.000000, (GLfloat) - 0.991445,
+       (GLfloat) - 0.130526, (GLfloat) 0.000000, (GLfloat) - 0.991445,
+       (GLfloat) - 0.382684, (GLfloat) 0.000000, (GLfloat) - 0.923880,
+       (GLfloat) - 0.608761, (GLfloat) 0.000000, (GLfloat) - 0.793353,
+       (GLfloat) - 0.793353, (GLfloat) 0.000000, (GLfloat) - 0.608761,
+       (GLfloat) - 0.923880, (GLfloat) 0.000000, (GLfloat) - 0.382684,
+       (GLfloat) - 0.991445, (GLfloat) 0.000000, (GLfloat) - 0.130526,
+       (GLfloat) - 0.991445, (GLfloat) 0.000000, (GLfloat) 0.130526,
+       (GLfloat) - 0.923880, (GLfloat) 0.000000, (GLfloat) 0.382684,
+       (GLfloat) - 0.793353, (GLfloat) 0.000000, (GLfloat) 0.608761,
+       (GLfloat) - 0.608761, (GLfloat) 0.000000, (GLfloat) 0.793353,
+       (GLfloat) - 0.382684, (GLfloat) 0.000000, (GLfloat) 0.923880,
+       (GLfloat) - 0.130526, (GLfloat) 0.000000, (GLfloat) 0.991445,
+       (GLfloat) 0.130526, (GLfloat) - 0.000000, (GLfloat) 0.991445,
+       (GLfloat) 0.382684, (GLfloat) - 0.000000, (GLfloat) 0.923880,
+       (GLfloat) 0.608761, (GLfloat) - 0.000000, (GLfloat) 0.793353,
+       (GLfloat) 0.793353, (GLfloat) - 0.000000, (GLfloat) 0.608761,
+       (GLfloat) 0.923880, (GLfloat) - 0.000000, (GLfloat) 0.382684,
+       (GLfloat) 0.991445, (GLfloat) - 0.000000, (GLfloat) 0.130526,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.991445, (GLfloat) 0.000000, (GLfloat) - 0.130526,
+       (GLfloat) 0.923880, (GLfloat) 0.000000, (GLfloat) - 0.382684,
+       (GLfloat) 0.793353, (GLfloat) 0.000000, (GLfloat) - 0.608761,
+       (GLfloat) 0.608761, (GLfloat) 0.000000, (GLfloat) - 0.793353,
+       (GLfloat) 0.382684, (GLfloat) 0.000000, (GLfloat) - 0.923880,
+       (GLfloat) 0.130526, (GLfloat) 0.000000, (GLfloat) - 0.991445,
+       (GLfloat) - 0.130526, (GLfloat) 0.000000, (GLfloat) - 0.991445,
+       (GLfloat) - 0.382684, (GLfloat) 0.000000, (GLfloat) - 0.923880,
+       (GLfloat) - 0.608761, (GLfloat) 0.000000, (GLfloat) - 0.793353,
+       (GLfloat) - 0.793353, (GLfloat) 0.000000, (GLfloat) - 0.608761,
+       (GLfloat) - 0.923880, (GLfloat) 0.000000, (GLfloat) - 0.382684,
+       (GLfloat) - 0.991445, (GLfloat) 0.000000, (GLfloat) - 0.130526,
+       (GLfloat) - 0.991445, (GLfloat) 0.000000, (GLfloat) 0.130526,
+       (GLfloat) - 0.923880, (GLfloat) 0.000000, (GLfloat) 0.382684,
+       (GLfloat) - 0.793353, (GLfloat) 0.000000, (GLfloat) 0.608761,
+       (GLfloat) - 0.608761, (GLfloat) 0.000000, (GLfloat) 0.793353,
+       (GLfloat) - 0.382684, (GLfloat) 0.000000, (GLfloat) 0.923880,
+       (GLfloat) - 0.130526, (GLfloat) 0.000000, (GLfloat) 0.991445,
+       (GLfloat) 0.130526, (GLfloat) - 0.000000, (GLfloat) 0.991445,
+       (GLfloat) 0.382684, (GLfloat) - 0.000000, (GLfloat) 0.923880,
+       (GLfloat) 0.608761, (GLfloat) - 0.000000, (GLfloat) 0.793353,
+       (GLfloat) 0.793353, (GLfloat) - 0.000000, (GLfloat) 0.608761,
+       (GLfloat) 0.923880, (GLfloat) - 0.000000, (GLfloat) 0.382684,
+       (GLfloat) 0.991445, (GLfloat) - 0.000000, (GLfloat) 0.130526,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+};
+
+static unsigned short int GuageConnector_POLS[] =
+{
+    4, 1, 120, 121, 3, 1, 5, 3, 121, 122, 123, 5, 1, 4, 5, 123, 124, 6, 1, 4,
+6, 124, 125, 9, 1, 5, 9, 125, 126, 127, 10, 1, 4, 10, 127, 128, 12, 1, 4, 14,
+       12, 128, 129, 1, 5, 16, 14, 129, 130, 131, 1, 4, 19, 16, 131, 132, 1, 4, 20, 19,
+       132, 133, 1, 5, 23, 20, 133, 134, 135, 1, 4, 25, 23, 135, 136, 1, 4, 25, 136, 137,
+       27, 1, 5, 27, 137, 139, 138, 29, 1, 4, 29, 138, 140, 30, 1, 4, 30, 140, 141, 32,
+       1, 5, 32, 141, 143, 142, 34, 1, 4, 34, 142, 144, 36, 1, 4, 38, 36, 144, 145, 1,
+       5, 41, 38, 145, 147, 146, 1, 4, 43, 41, 146, 148, 1, 4, 44, 43, 148, 149, 1, 5,
+47, 44, 149, 151, 150, 1, 4, 1, 47, 150, 120, 1, 4, 96, 97, 73, 72, 1, 4, 97,
+ 98, 74, 73, 1, 4, 98, 99, 75, 74, 1, 4, 99, 100, 76, 75, 1, 4, 100, 101, 77,
+76, 1, 4, 101, 102, 78, 77, 1, 4, 102, 103, 79, 78, 1, 4, 103, 104, 80, 79, 1,
+       4, 104, 105, 81, 80, 1, 4, 105, 106, 82, 81, 1, 4, 106, 107, 83, 82, 1, 4, 107,
+       108, 84, 83, 1, 4, 108, 109, 85, 84, 1, 4, 109, 110, 86, 85, 1, 4, 110, 111, 87,
+86, 1, 4, 111, 112, 88, 87, 1, 4, 112, 113, 89, 88, 1, 4, 113, 114, 90, 89, 1,
+       4, 114, 115, 91, 90, 1, 4, 115, 116, 92, 91, 1, 4, 116, 117, 93, 92, 1, 4, 117,
+  118, 94, 93, 1, 4, 118, 119, 95, 94, 1, 4, 119, 96, 72, 95, 1, 24, 1, 3, 5,
+6, 9, 10, 12, 14, 16, 19, 20, 23, 25, 27, 29, 30, 32, 34, 36, 38, 41, 43, 44,
+       47, 1, 4, 48, 49, 2, 0, 1, 4, 49, 50, 4, 2, 1, 4, 50, 51, 7, 4, 1,
+       4, 51, 52, 8, 7, 1, 4, 52, 53, 11, 8, 1, 4, 53, 54, 13, 11, 1, 4, 54,
+    55, 15, 13, 1, 4, 55, 56, 17, 15, 1, 4, 56, 57, 18, 17, 1, 4, 57, 58, 21,
+     18, 1, 4, 58, 59, 22, 21, 1, 4, 59, 60, 24, 22, 1, 4, 60, 61, 26, 24, 1,
+     4, 61, 62, 28, 26, 1, 4, 62, 63, 31, 28, 1, 4, 63, 64, 33, 31, 1, 4, 64,
+    65, 35, 33, 1, 4, 65, 66, 37, 35, 1, 4, 66, 67, 39, 37, 1, 4, 67, 68, 40,
+     39, 1, 4, 68, 69, 42, 40, 1, 4, 69, 70, 45, 42, 1, 4, 70, 71, 46, 45, 1,
+ 4, 71, 48, 0, 46, 1, 24, 48, 71, 70, 69, 68, 67, 66, 65, 64, 63, 62, 61, 60,
+       59, 58, 57, 56, 55, 54, 53, 52, 51, 50, 49, 1,
+       0
+};
+
+struct lwo  LWO_GuageConnector =
+{
+       152,                    /* number of points */
+       GuageConnector_PNTS, GuageConnector_normals, GuageConnector_POLS, 0L
+};
+
+static GLfloat GuageDial_PNTS[] =
+{
+       (GLfloat) 0.000000, (GLfloat) 0.050000, (GLfloat) 0.300000,
+       (GLfloat) 0.019134, (GLfloat) 0.046194, (GLfloat) 0.300000,
+       (GLfloat) 0.035355, (GLfloat) 0.035355, (GLfloat) 0.300000,
+       (GLfloat) 0.046194, (GLfloat) 0.019134, (GLfloat) 0.300000,
+       (GLfloat) 0.050000, (GLfloat) - 0.000000, (GLfloat) 0.300000,
+       (GLfloat) 0.046194, (GLfloat) - 0.019134, (GLfloat) 0.300000,
+       (GLfloat) 0.035355, (GLfloat) - 0.035400, (GLfloat) 0.275000,
+       (GLfloat) 0.035355, (GLfloat) - 0.035400, (GLfloat) 0.300000,
+       (GLfloat) 0.019134, (GLfloat) - 0.046200, (GLfloat) 0.300000,
+       (GLfloat) 0.000000, (GLfloat) - 0.050000, (GLfloat) 0.300000,
+       (GLfloat) - 0.019134, (GLfloat) - 0.046200, (GLfloat) 0.300000,
+       (GLfloat) - 0.035355, (GLfloat) - 0.035400, (GLfloat) 0.275000,
+       (GLfloat) - 0.035355, (GLfloat) - 0.035400, (GLfloat) 0.300000,
+       (GLfloat) - 0.046194, (GLfloat) - 0.019134, (GLfloat) 0.300000,
+       (GLfloat) - 0.050000, (GLfloat) - 0.000000, (GLfloat) 0.300000,
+       (GLfloat) - 0.046194, (GLfloat) 0.019134, (GLfloat) 0.300000,
+       (GLfloat) - 0.035355, (GLfloat) 0.035355, (GLfloat) 0.300000,
+       (GLfloat) - 0.019134, (GLfloat) 0.046194, (GLfloat) 0.300000,
+       (GLfloat) 0.000000, (GLfloat) 0.050000, (GLfloat) 0.200000,
+       (GLfloat) 0.019134, (GLfloat) 0.046194, (GLfloat) 0.200000,
+       (GLfloat) 0.035355, (GLfloat) 0.035355, (GLfloat) 0.200000,
+       (GLfloat) 0.046194, (GLfloat) 0.019134, (GLfloat) 0.200000,
+       (GLfloat) 0.050000, (GLfloat) - 0.000000, (GLfloat) 0.200000,
+       (GLfloat) 0.046194, (GLfloat) - 0.019134, (GLfloat) 0.200000,
+       (GLfloat) 0.035355, (GLfloat) - 0.035355, (GLfloat) 0.200000,
+       (GLfloat) 0.019134, (GLfloat) - 0.046194, (GLfloat) 0.200000,
+       (GLfloat) 0.000000, (GLfloat) - 0.050000, (GLfloat) 0.200000,
+       (GLfloat) - 0.019134, (GLfloat) - 0.046194, (GLfloat) 0.200000,
+       (GLfloat) - 0.035355, (GLfloat) - 0.035355, (GLfloat) 0.200000,
+       (GLfloat) - 0.046194, (GLfloat) - 0.019134, (GLfloat) 0.200000,
+       (GLfloat) - 0.050000, (GLfloat) - 0.000000, (GLfloat) 0.200000,
+       (GLfloat) - 0.046194, (GLfloat) 0.019134, (GLfloat) 0.200000,
+       (GLfloat) - 0.035355, (GLfloat) 0.035355, (GLfloat) 0.200000,
+       (GLfloat) - 0.019134, (GLfloat) 0.046194, (GLfloat) 0.200000,
+       (GLfloat) 0.000000, (GLfloat) - 0.373300, (GLfloat) 0.275000,
+};
+
+static GLfloat GuageDial_normals[] =
+{
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.195089, (GLfloat) 0.980786, (GLfloat) 0.000000,
+       (GLfloat) 0.555570, (GLfloat) 0.831470, (GLfloat) 0.000000,
+       (GLfloat) 0.831470, (GLfloat) 0.555570, (GLfloat) 0.000000,
+       (GLfloat) 0.980785, (GLfloat) 0.195090, (GLfloat) 0.000000,
+       (GLfloat) 0.980785, (GLfloat) - 0.195090, (GLfloat) - 0.000000,
+       (GLfloat) 0.831470, (GLfloat) - 0.555570, (GLfloat) - 0.000248,
+       (GLfloat) 0.555570, (GLfloat) - 0.831470, (GLfloat) - 0.000051,
+       (GLfloat) 0.195089, (GLfloat) - 0.980786, (GLfloat) - 0.000000,
+       (GLfloat) - 0.195089, (GLfloat) - 0.980786, (GLfloat) - 0.000060,
+       (GLfloat) - 0.555570, (GLfloat) - 0.831470, (GLfloat) - 0.000371,
+       (GLfloat) - 0.831470, (GLfloat) - 0.555570, (GLfloat) - 0.000000,
+       (GLfloat) - 0.980785, (GLfloat) - 0.195090, (GLfloat) - 0.000000,
+       (GLfloat) - 0.980785, (GLfloat) 0.195090, (GLfloat) - 0.000000,
+       (GLfloat) - 0.831470, (GLfloat) 0.555570, (GLfloat) - 0.000000,
+       (GLfloat) - 0.555570, (GLfloat) 0.831470, (GLfloat) - 0.000000,
+       (GLfloat) - 0.195089, (GLfloat) 0.980786, (GLfloat) - 0.000000,
+};
+
+static unsigned short int GuageDial_POLS[] =
+{
+       3, 11, 6, 34, 1, 16, 0, 1, 2, 3, 4, 5, 7, 8, 9, 10, 12, 13, 14, 15,
+       16, 17, 1, 4, 18, 19, 1, 0, 1, 4, 19, 20, 2, 1, 1, 4, 20, 21, 3, 2,
+       1, 4, 21, 22, 4, 3, 1, 4, 22, 23, 5, 4, 1, 4, 23, 24, 7, 5, 1, 4,
+       24, 25, 8, 7, 1, 4, 25, 26, 9, 8, 1, 4, 26, 27, 10, 9, 1, 4, 27, 28,
+    12, 10, 1, 4, 28, 29, 13, 12, 1, 4, 29, 30, 14, 13, 1, 4, 30, 31, 15, 14,
+       1, 4, 31, 32, 16, 15, 1, 4, 32, 33, 17, 16, 1, 4, 33, 18, 0, 17, 1,
+       0
+};
+
+struct lwo  LWO_GuageDial =
+{
+       35,                     /* number of points */
+       GuageDial_PNTS, GuageDial_normals, GuageDial_POLS, 0L
+};
+
+static GLfloat GuageFace_PNTS[] =
+{
+       (GLfloat) 0.000000, (GLfloat) 1.783300, (GLfloat) 0.200000,
+       (GLfloat) - 0.087791, (GLfloat) 1.774653, (GLfloat) 0.200000,
+       (GLfloat) - 0.172208, (GLfloat) 1.749046, (GLfloat) 0.200000,
+       (GLfloat) - 0.250007, (GLfloat) 1.707461, (GLfloat) 0.200000,
+       (GLfloat) - 0.318198, (GLfloat) 1.651498, (GLfloat) 0.200000,
+       (GLfloat) - 0.374161, (GLfloat) 1.583307, (GLfloat) 0.200000,
+       (GLfloat) - 0.415746, (GLfloat) 1.505508, (GLfloat) 0.200000,
+       (GLfloat) - 0.441353, (GLfloat) 1.421091, (GLfloat) 0.200000,
+       (GLfloat) - 0.450000, (GLfloat) 1.333300, (GLfloat) 0.200000,
+       (GLfloat) - 0.441353, (GLfloat) 1.245509, (GLfloat) 0.200000,
+       (GLfloat) - 0.415746, (GLfloat) 1.161092, (GLfloat) 0.200000,
+       (GLfloat) - 0.374161, (GLfloat) 1.083293, (GLfloat) 0.200000,
+       (GLfloat) - 0.318198, (GLfloat) 1.015102, (GLfloat) 0.200000,
+       (GLfloat) - 0.250007, (GLfloat) 0.959139, (GLfloat) 0.200000,
+       (GLfloat) - 0.172208, (GLfloat) 0.917554, (GLfloat) 0.200000,
+       (GLfloat) - 0.087791, (GLfloat) 0.891947, (GLfloat) 0.200000,
+       (GLfloat) 0.000000, (GLfloat) 0.883300, (GLfloat) 0.200000,
+       (GLfloat) 0.087791, (GLfloat) 0.891947, (GLfloat) 0.200000,
+       (GLfloat) 0.172208, (GLfloat) 0.917554, (GLfloat) 0.200000,
+       (GLfloat) 0.250007, (GLfloat) 0.959139, (GLfloat) 0.200000,
+       (GLfloat) 0.318198, (GLfloat) 1.015102, (GLfloat) 0.200000,
+       (GLfloat) 0.374161, (GLfloat) 1.083293, (GLfloat) 0.200000,
+       (GLfloat) 0.415746, (GLfloat) 1.161092, (GLfloat) 0.200000,
+       (GLfloat) 0.441353, (GLfloat) 1.245509, (GLfloat) 0.200000,
+       (GLfloat) 0.450000, (GLfloat) 1.333300, (GLfloat) 0.200000,
+       (GLfloat) 0.441353, (GLfloat) 1.421091, (GLfloat) 0.200000,
+       (GLfloat) 0.415746, (GLfloat) 1.505508, (GLfloat) 0.200000,
+       (GLfloat) 0.374161, (GLfloat) 1.583307, (GLfloat) 0.200000,
+       (GLfloat) 0.318198, (GLfloat) 1.651498, (GLfloat) 0.200000,
+       (GLfloat) 0.250007, (GLfloat) 1.707461, (GLfloat) 0.200000,
+       (GLfloat) 0.172208, (GLfloat) 1.749046, (GLfloat) 0.200000,
+       (GLfloat) 0.087791, (GLfloat) 1.774653, (GLfloat) 0.200000,
+};
+
+static GLfloat GuageFace_normals[] =
+{
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+};
+
+static unsigned short int GuageFace_POLS[] =
+{
+32, 0, 31, 30, 29, 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14,
+       13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 1,
+       0
+};
+
+struct lwo  LWO_GuageFace =
+{
+       32,                     /* number of points */
+       GuageFace_PNTS, GuageFace_normals, GuageFace_POLS, 0L
+};
+
+static GLfloat GuageHead_PNTS[] =
+{
+       (GLfloat) 0.000000, (GLfloat) 1.833300, (GLfloat) 0.333330,
+       (GLfloat) 0.097545, (GLfloat) 1.823693, (GLfloat) 0.333330,
+       (GLfloat) 0.191342, (GLfloat) 1.795240, (GLfloat) 0.333330,
+       (GLfloat) 0.277785, (GLfloat) 1.749035, (GLfloat) 0.333330,
+       (GLfloat) 0.353553, (GLfloat) 1.686853, (GLfloat) 0.333330,
+       (GLfloat) 0.415735, (GLfloat) 1.611085, (GLfloat) 0.333330,
+       (GLfloat) 0.461940, (GLfloat) 1.524642, (GLfloat) 0.333330,
+       (GLfloat) 0.490393, (GLfloat) 1.430845, (GLfloat) 0.333330,
+       (GLfloat) 0.500000, (GLfloat) 1.333300, (GLfloat) 0.333330,
+       (GLfloat) 0.490393, (GLfloat) 1.235755, (GLfloat) 0.333330,
+       (GLfloat) 0.461940, (GLfloat) 1.141958, (GLfloat) 0.333330,
+       (GLfloat) 0.415735, (GLfloat) 1.055515, (GLfloat) 0.333330,
+       (GLfloat) 0.353553, (GLfloat) 0.979747, (GLfloat) 0.333330,
+       (GLfloat) 0.277785, (GLfloat) 0.917565, (GLfloat) 0.333330,
+       (GLfloat) 0.191342, (GLfloat) 0.871360, (GLfloat) 0.333330,
+       (GLfloat) 0.097545, (GLfloat) 0.842907, (GLfloat) 0.333330,
+       (GLfloat) 0.000000, (GLfloat) 0.833300, (GLfloat) 0.333330,
+       (GLfloat) - 0.097545, (GLfloat) 0.842907, (GLfloat) 0.333330,
+       (GLfloat) - 0.191342, (GLfloat) 0.871360, (GLfloat) 0.333330,
+       (GLfloat) - 0.277785, (GLfloat) 0.917565, (GLfloat) 0.333330,
+       (GLfloat) - 0.353553, (GLfloat) 0.979747, (GLfloat) 0.333330,
+       (GLfloat) - 0.415735, (GLfloat) 1.055515, (GLfloat) 0.333330,
+       (GLfloat) - 0.461940, (GLfloat) 1.141958, (GLfloat) 0.333330,
+       (GLfloat) - 0.490393, (GLfloat) 1.235755, (GLfloat) 0.333330,
+       (GLfloat) - 0.500000, (GLfloat) 1.333300, (GLfloat) 0.333330,
+       (GLfloat) - 0.490393, (GLfloat) 1.430845, (GLfloat) 0.333330,
+       (GLfloat) - 0.461940, (GLfloat) 1.524642, (GLfloat) 0.333330,
+       (GLfloat) - 0.415735, (GLfloat) 1.611085, (GLfloat) 0.333330,
+       (GLfloat) - 0.353553, (GLfloat) 1.686853, (GLfloat) 0.333330,
+       (GLfloat) - 0.277785, (GLfloat) 1.749035, (GLfloat) 0.333330,
+       (GLfloat) - 0.191342, (GLfloat) 1.795240, (GLfloat) 0.333330,
+       (GLfloat) - 0.097545, (GLfloat) 1.823693, (GLfloat) 0.333330,
+       (GLfloat) 0.000000, (GLfloat) 1.833300, (GLfloat) - 0.333330,
+       (GLfloat) 0.097545, (GLfloat) 1.823693, (GLfloat) - 0.333330,
+       (GLfloat) 0.191342, (GLfloat) 1.795240, (GLfloat) - 0.333330,
+       (GLfloat) 0.277785, (GLfloat) 1.749035, (GLfloat) - 0.333330,
+       (GLfloat) 0.353553, (GLfloat) 1.686853, (GLfloat) - 0.333330,
+       (GLfloat) 0.415735, (GLfloat) 1.611085, (GLfloat) - 0.333330,
+       (GLfloat) 0.461940, (GLfloat) 1.524642, (GLfloat) - 0.333330,
+       (GLfloat) 0.490393, (GLfloat) 1.430845, (GLfloat) - 0.333330,
+       (GLfloat) 0.500000, (GLfloat) 1.333300, (GLfloat) - 0.333330,
+       (GLfloat) 0.490393, (GLfloat) 1.235755, (GLfloat) - 0.333330,
+       (GLfloat) 0.461940, (GLfloat) 1.141958, (GLfloat) - 0.333330,
+       (GLfloat) 0.415735, (GLfloat) 1.055515, (GLfloat) - 0.333330,
+       (GLfloat) 0.353553, (GLfloat) 0.979747, (GLfloat) - 0.333330,
+       (GLfloat) 0.277785, (GLfloat) 0.917565, (GLfloat) - 0.333330,
+       (GLfloat) 0.191342, (GLfloat) 0.871360, (GLfloat) - 0.333330,
+       (GLfloat) 0.097545, (GLfloat) 0.842907, (GLfloat) - 0.333330,
+       (GLfloat) 0.000000, (GLfloat) 0.833300, (GLfloat) - 0.333330,
+       (GLfloat) - 0.097545, (GLfloat) 0.842907, (GLfloat) - 0.333330,
+       (GLfloat) - 0.191342, (GLfloat) 0.871360, (GLfloat) - 0.333330,
+       (GLfloat) - 0.277785, (GLfloat) 0.917565, (GLfloat) - 0.333330,
+       (GLfloat) - 0.353553, (GLfloat) 0.979747, (GLfloat) - 0.333330,
+       (GLfloat) - 0.415735, (GLfloat) 1.055515, (GLfloat) - 0.333330,
+       (GLfloat) - 0.461940, (GLfloat) 1.141958, (GLfloat) - 0.333330,
+       (GLfloat) - 0.490393, (GLfloat) 1.235755, (GLfloat) - 0.333330,
+       (GLfloat) - 0.500000, (GLfloat) 1.333300, (GLfloat) - 0.333330,
+       (GLfloat) - 0.490393, (GLfloat) 1.430845, (GLfloat) - 0.333330,
+       (GLfloat) - 0.461940, (GLfloat) 1.524642, (GLfloat) - 0.333330,
+       (GLfloat) - 0.415735, (GLfloat) 1.611085, (GLfloat) - 0.333330,
+       (GLfloat) - 0.353553, (GLfloat) 1.686853, (GLfloat) - 0.333330,
+       (GLfloat) - 0.277785, (GLfloat) 1.749035, (GLfloat) - 0.333330,
+       (GLfloat) - 0.191342, (GLfloat) 1.795240, (GLfloat) - 0.333330,
+       (GLfloat) - 0.097545, (GLfloat) 1.823693, (GLfloat) - 0.333330,
+       (GLfloat) 0.087791, (GLfloat) 1.774653, (GLfloat) 0.333330,
+       (GLfloat) 0.000000, (GLfloat) 1.783300, (GLfloat) 0.333330,
+       (GLfloat) 0.172208, (GLfloat) 1.749046, (GLfloat) 0.333330,
+       (GLfloat) 0.250007, (GLfloat) 1.707461, (GLfloat) 0.333330,
+       (GLfloat) 0.318198, (GLfloat) 1.651498, (GLfloat) 0.333330,
+       (GLfloat) 0.374161, (GLfloat) 1.583307, (GLfloat) 0.333330,
+       (GLfloat) 0.415746, (GLfloat) 1.505508, (GLfloat) 0.333330,
+       (GLfloat) 0.441353, (GLfloat) 1.421091, (GLfloat) 0.333330,
+       (GLfloat) 0.450000, (GLfloat) 1.333300, (GLfloat) 0.333330,
+       (GLfloat) 0.441353, (GLfloat) 1.245509, (GLfloat) 0.333330,
+       (GLfloat) 0.415746, (GLfloat) 1.161092, (GLfloat) 0.333330,
+       (GLfloat) 0.374161, (GLfloat) 1.083293, (GLfloat) 0.333330,
+       (GLfloat) 0.318198, (GLfloat) 1.015102, (GLfloat) 0.333330,
+       (GLfloat) 0.250007, (GLfloat) 0.959139, (GLfloat) 0.333330,
+       (GLfloat) 0.172208, (GLfloat) 0.917554, (GLfloat) 0.333330,
+       (GLfloat) 0.087791, (GLfloat) 0.891947, (GLfloat) 0.333330,
+       (GLfloat) 0.000000, (GLfloat) 0.883300, (GLfloat) 0.333330,
+       (GLfloat) - 0.087791, (GLfloat) 0.891947, (GLfloat) 0.333330,
+       (GLfloat) - 0.172208, (GLfloat) 0.917554, (GLfloat) 0.333330,
+       (GLfloat) - 0.250007, (GLfloat) 0.959139, (GLfloat) 0.333330,
+       (GLfloat) - 0.318198, (GLfloat) 1.015102, (GLfloat) 0.333330,
+       (GLfloat) - 0.374161, (GLfloat) 1.083293, (GLfloat) 0.333330,
+       (GLfloat) - 0.415746, (GLfloat) 1.161092, (GLfloat) 0.333330,
+       (GLfloat) - 0.441353, (GLfloat) 1.245509, (GLfloat) 0.333330,
+       (GLfloat) - 0.450000, (GLfloat) 1.333300, (GLfloat) 0.333330,
+       (GLfloat) - 0.441353, (GLfloat) 1.421091, (GLfloat) 0.333330,
+       (GLfloat) - 0.415746, (GLfloat) 1.505508, (GLfloat) 0.333330,
+       (GLfloat) - 0.374161, (GLfloat) 1.583307, (GLfloat) 0.333330,
+       (GLfloat) - 0.318198, (GLfloat) 1.651498, (GLfloat) 0.333330,
+       (GLfloat) - 0.250007, (GLfloat) 1.707461, (GLfloat) 0.333330,
+       (GLfloat) - 0.172208, (GLfloat) 1.749046, (GLfloat) 0.333330,
+       (GLfloat) - 0.087791, (GLfloat) 1.774653, (GLfloat) 0.333330,
+       (GLfloat) 0.000000, (GLfloat) 1.783300, (GLfloat) 0.200000,
+       (GLfloat) - 0.087791, (GLfloat) 1.774653, (GLfloat) 0.200000,
+       (GLfloat) - 0.172208, (GLfloat) 1.749046, (GLfloat) 0.200000,
+       (GLfloat) - 0.250007, (GLfloat) 1.707461, (GLfloat) 0.200000,
+       (GLfloat) - 0.318198, (GLfloat) 1.651498, (GLfloat) 0.200000,
+       (GLfloat) - 0.374161, (GLfloat) 1.583307, (GLfloat) 0.200000,
+       (GLfloat) - 0.415746, (GLfloat) 1.505508, (GLfloat) 0.200000,
+       (GLfloat) - 0.441353, (GLfloat) 1.421091, (GLfloat) 0.200000,
+       (GLfloat) - 0.450000, (GLfloat) 1.333300, (GLfloat) 0.200000,
+       (GLfloat) - 0.441353, (GLfloat) 1.245509, (GLfloat) 0.200000,
+       (GLfloat) - 0.415746, (GLfloat) 1.161092, (GLfloat) 0.200000,
+       (GLfloat) - 0.374161, (GLfloat) 1.083293, (GLfloat) 0.200000,
+       (GLfloat) - 0.318198, (GLfloat) 1.015102, (GLfloat) 0.200000,
+       (GLfloat) - 0.250007, (GLfloat) 0.959139, (GLfloat) 0.200000,
+       (GLfloat) - 0.172208, (GLfloat) 0.917554, (GLfloat) 0.200000,
+       (GLfloat) - 0.087791, (GLfloat) 0.891947, (GLfloat) 0.200000,
+       (GLfloat) 0.000000, (GLfloat) 0.883300, (GLfloat) 0.200000,
+       (GLfloat) 0.087791, (GLfloat) 0.891947, (GLfloat) 0.200000,
+       (GLfloat) 0.172208, (GLfloat) 0.917554, (GLfloat) 0.200000,
+       (GLfloat) 0.250007, (GLfloat) 0.959139, (GLfloat) 0.200000,
+       (GLfloat) 0.318198, (GLfloat) 1.015102, (GLfloat) 0.200000,
+       (GLfloat) 0.374161, (GLfloat) 1.083293, (GLfloat) 0.200000,
+       (GLfloat) 0.415746, (GLfloat) 1.161092, (GLfloat) 0.200000,
+       (GLfloat) 0.441353, (GLfloat) 1.245509, (GLfloat) 0.200000,
+       (GLfloat) 0.450000, (GLfloat) 1.333300, (GLfloat) 0.200000,
+       (GLfloat) 0.441353, (GLfloat) 1.421091, (GLfloat) 0.200000,
+       (GLfloat) 0.415746, (GLfloat) 1.505508, (GLfloat) 0.200000,
+       (GLfloat) 0.374161, (GLfloat) 1.583307, (GLfloat) 0.200000,
+       (GLfloat) 0.318198, (GLfloat) 1.651498, (GLfloat) 0.200000,
+       (GLfloat) 0.250007, (GLfloat) 1.707461, (GLfloat) 0.200000,
+       (GLfloat) 0.172208, (GLfloat) 1.749046, (GLfloat) 0.200000,
+       (GLfloat) 0.087791, (GLfloat) 1.774653, (GLfloat) 0.200000,
+};
+
+static GLfloat GuageHead_normals[] =
+{
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.098017, (GLfloat) - 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) 0.290285, (GLfloat) - 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) 0.471397, (GLfloat) - 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) 0.634393, (GLfloat) - 0.773010, (GLfloat) - 0.000000,
+       (GLfloat) 0.773011, (GLfloat) - 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) 0.881921, (GLfloat) - 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) 0.956940, (GLfloat) - 0.290284, (GLfloat) - 0.000000,
+       (GLfloat) 0.995185, (GLfloat) - 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) 0.995185, (GLfloat) 0.098017, (GLfloat) 0.000000,
+       (GLfloat) 0.956940, (GLfloat) 0.290284, (GLfloat) 0.000000,
+       (GLfloat) 0.881921, (GLfloat) 0.471397, (GLfloat) 0.000000,
+       (GLfloat) 0.773011, (GLfloat) 0.634393, (GLfloat) 0.000000,
+       (GLfloat) 0.634393, (GLfloat) 0.773011, (GLfloat) 0.000000,
+       (GLfloat) 0.471397, (GLfloat) 0.881921, (GLfloat) 0.000000,
+       (GLfloat) 0.290285, (GLfloat) 0.956940, (GLfloat) 0.000000,
+       (GLfloat) 0.098017, (GLfloat) 0.995185, (GLfloat) 0.000000,
+       (GLfloat) - 0.098017, (GLfloat) 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) - 0.290285, (GLfloat) 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) - 0.471397, (GLfloat) 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) - 0.634393, (GLfloat) 0.773011, (GLfloat) - 0.000000,
+       (GLfloat) - 0.773011, (GLfloat) 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) - 0.881921, (GLfloat) 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) - 0.956940, (GLfloat) 0.290284, (GLfloat) - 0.000000,
+       (GLfloat) - 0.995185, (GLfloat) 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) - 0.995185, (GLfloat) - 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) - 0.956940, (GLfloat) - 0.290284, (GLfloat) - 0.000000,
+       (GLfloat) - 0.881921, (GLfloat) - 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) - 0.773011, (GLfloat) - 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) - 0.634393, (GLfloat) - 0.773010, (GLfloat) - 0.000000,
+       (GLfloat) - 0.471397, (GLfloat) - 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) - 0.290285, (GLfloat) - 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) - 0.098017, (GLfloat) - 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) 0.098017, (GLfloat) 0.995185, (GLfloat) 0.000000,
+       (GLfloat) 0.290285, (GLfloat) 0.956940, (GLfloat) 0.000000,
+       (GLfloat) 0.471397, (GLfloat) 0.881921, (GLfloat) 0.000000,
+       (GLfloat) 0.634393, (GLfloat) 0.773011, (GLfloat) 0.000000,
+       (GLfloat) 0.773011, (GLfloat) 0.634393, (GLfloat) 0.000000,
+       (GLfloat) 0.881921, (GLfloat) 0.471397, (GLfloat) 0.000000,
+       (GLfloat) 0.956940, (GLfloat) 0.290284, (GLfloat) 0.000000,
+       (GLfloat) 0.995185, (GLfloat) 0.098017, (GLfloat) 0.000000,
+       (GLfloat) 0.995185, (GLfloat) - 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) 0.956940, (GLfloat) - 0.290284, (GLfloat) - 0.000000,
+       (GLfloat) 0.881921, (GLfloat) - 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) 0.773011, (GLfloat) - 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) 0.634393, (GLfloat) - 0.773010, (GLfloat) - 0.000000,
+       (GLfloat) 0.471396, (GLfloat) - 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) 0.290285, (GLfloat) - 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) 0.098017, (GLfloat) - 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) - 0.098017, (GLfloat) - 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) - 0.290285, (GLfloat) - 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) - 0.471396, (GLfloat) - 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) - 0.634393, (GLfloat) - 0.773010, (GLfloat) - 0.000000,
+       (GLfloat) - 0.773011, (GLfloat) - 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) - 0.881921, (GLfloat) - 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) - 0.956940, (GLfloat) - 0.290284, (GLfloat) - 0.000000,
+       (GLfloat) - 0.995185, (GLfloat) - 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) - 0.995185, (GLfloat) 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) - 0.956940, (GLfloat) 0.290284, (GLfloat) - 0.000000,
+       (GLfloat) - 0.881921, (GLfloat) 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) - 0.773011, (GLfloat) 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) - 0.634393, (GLfloat) 0.773011, (GLfloat) - 0.000000,
+       (GLfloat) - 0.471397, (GLfloat) 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) - 0.290285, (GLfloat) 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) - 0.098017, (GLfloat) 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+};
+
+static unsigned short int GuageHead_POLS[] =
+{
+       3, 67, 3, 4, 1, 3, 68, 67, 4, 1, 3, 68, 4, 5, 1, 3, 69, 68, 5, 1,
+       3, 70, 69, 5, 1, 3, 70, 5, 6, 1, 3, 70, 6, 7, 1, 3, 71, 70, 7, 1,
+       3, 71, 7, 8, 1, 3, 72, 71, 8, 1, 3, 73, 72, 8, 1, 3, 73, 8, 9, 1,
+       3, 74, 73, 9, 1, 3, 74, 9, 10, 1, 3, 74, 10, 11, 1, 3, 75, 74, 11, 1,
+      3, 76, 75, 11, 1, 3, 76, 11, 12, 1, 3, 76, 12, 13, 1, 3, 77, 76, 13, 1,
+      3, 78, 77, 13, 1, 3, 78, 13, 14, 1, 3, 78, 14, 15, 1, 3, 79, 78, 15, 1,
+      3, 79, 15, 16, 1, 3, 80, 79, 16, 1, 3, 81, 80, 16, 1, 3, 81, 16, 17, 1,
+      3, 82, 81, 17, 1, 3, 82, 17, 18, 1, 3, 82, 18, 19, 1, 3, 83, 82, 19, 1,
+      3, 84, 83, 19, 1, 3, 84, 19, 20, 1, 3, 84, 20, 21, 1, 3, 85, 84, 21, 1,
+      3, 86, 85, 21, 1, 3, 86, 21, 22, 1, 3, 86, 22, 23, 1, 3, 87, 86, 23, 1,
+      3, 87, 23, 24, 1, 3, 88, 87, 24, 1, 3, 89, 88, 24, 1, 3, 89, 24, 25, 1,
+      3, 90, 89, 25, 1, 3, 90, 25, 26, 1, 3, 90, 26, 27, 1, 3, 91, 90, 27, 1,
+      3, 92, 91, 27, 1, 3, 92, 27, 28, 1, 3, 93, 92, 28, 1, 3, 93, 28, 29, 1,
+       3, 2, 3, 67, 1, 3, 2, 67, 66, 1, 3, 1, 2, 66, 1, 3, 1, 66, 64, 1,
+       3, 1, 64, 65, 1, 3, 0, 1, 65, 1, 3, 31, 0, 65, 1, 3, 31, 65, 95, 1,
+      3, 31, 95, 94, 1, 3, 30, 31, 94, 1, 3, 30, 94, 93, 1, 3, 93, 29, 30, 1,
+     4, 96, 97, 95, 65, 1, 4, 97, 98, 94, 95, 1, 4, 98, 99, 93, 94, 1, 4, 99,
+       100, 92, 93, 1, 4, 100, 101, 91, 92, 1, 4, 101, 102, 90, 91, 1, 4, 102, 103, 89,
+90, 1, 4, 103, 104, 88, 89, 1, 4, 104, 105, 87, 88, 1, 4, 105, 106, 86, 87, 1,
+       4, 106, 107, 85, 86, 1, 4, 107, 108, 84, 85, 1, 4, 108, 109, 83, 84, 1, 4, 109,
+       110, 82, 83, 1, 4, 110, 111, 81, 82, 1, 4, 111, 112, 80, 81, 1, 4, 112, 113, 79,
+80, 1, 4, 113, 114, 78, 79, 1, 4, 114, 115, 77, 78, 1, 4, 115, 116, 76, 77, 1,
+       4, 116, 117, 75, 76, 1, 4, 117, 118, 74, 75, 1, 4, 118, 119, 73, 74, 1, 4, 119,
+       120, 72, 73, 1, 4, 120, 121, 71, 72, 1, 4, 121, 122, 70, 71, 1, 4, 122, 123, 69,
+70, 1, 4, 123, 124, 68, 69, 1, 4, 124, 125, 67, 68, 1, 4, 125, 126, 66, 67, 1,
+    4, 126, 127, 64, 66, 1, 4, 127, 96, 65, 64, 1, 4, 32, 33, 1, 0, 1, 4, 33,
+       34, 2, 1, 1, 4, 34, 35, 3, 2, 1, 4, 35, 36, 4, 3, 1, 4, 36, 37, 5,
+       4, 1, 4, 37, 38, 6, 5, 1, 4, 38, 39, 7, 6, 1, 4, 39, 40, 8, 7, 1,
+       4, 40, 41, 9, 8, 1, 4, 41, 42, 10, 9, 1, 4, 42, 43, 11, 10, 1, 4, 43,
+    44, 12, 11, 1, 4, 44, 45, 13, 12, 1, 4, 45, 46, 14, 13, 1, 4, 46, 47, 15,
+     14, 1, 4, 47, 48, 16, 15, 1, 4, 48, 49, 17, 16, 1, 4, 49, 50, 18, 17, 1,
+     4, 50, 51, 19, 18, 1, 4, 51, 52, 20, 19, 1, 4, 52, 53, 21, 20, 1, 4, 53,
+    54, 22, 21, 1, 4, 54, 55, 23, 22, 1, 4, 55, 56, 24, 23, 1, 4, 56, 57, 25,
+     24, 1, 4, 57, 58, 26, 25, 1, 4, 58, 59, 27, 26, 1, 4, 59, 60, 28, 27, 1,
+     4, 60, 61, 29, 28, 1, 4, 61, 62, 30, 29, 1, 4, 62, 63, 31, 30, 1, 4, 63,
+32, 0, 31, 1, 32, 32, 63, 62, 61, 60, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50,
+       49, 48, 47, 46, 45, 44, 43, 42, 41, 40, 39, 38, 37, 36, 35, 34, 33, 1,
+       0
+};
+
+struct lwo  LWO_GuageHead =
+{
+       128,                    /* number of points */
+       GuageHead_PNTS, GuageHead_normals, GuageHead_POLS, 0L
+};
+
+static GLfloat PipeBetweenBolts_PNTS[] =
+{
+       (GLfloat) 0.000000, (GLfloat) 0.500000, (GLfloat) 0.500000,
+       (GLfloat) 0.129410, (GLfloat) 0.482963, (GLfloat) 0.500000,
+       (GLfloat) 0.250000, (GLfloat) 0.433013, (GLfloat) 0.500000,
+       (GLfloat) 0.353553, (GLfloat) 0.353553, (GLfloat) 0.500000,
+       (GLfloat) 0.433013, (GLfloat) 0.250000, (GLfloat) 0.500000,
+       (GLfloat) 0.482963, (GLfloat) 0.129410, (GLfloat) 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.500000,
+       (GLfloat) 0.482963, (GLfloat) - 0.129410, (GLfloat) 0.500000,
+       (GLfloat) 0.433013, (GLfloat) - 0.250000, (GLfloat) 0.500000,
+       (GLfloat) 0.353553, (GLfloat) - 0.353553, (GLfloat) 0.500000,
+       (GLfloat) 0.250000, (GLfloat) - 0.433013, (GLfloat) 0.500000,
+       (GLfloat) 0.129410, (GLfloat) - 0.482963, (GLfloat) 0.500000,
+       (GLfloat) 0.000000, (GLfloat) - 0.500000, (GLfloat) 0.500000,
+       (GLfloat) - 0.129410, (GLfloat) - 0.482963, (GLfloat) 0.500000,
+       (GLfloat) - 0.250000, (GLfloat) - 0.433013, (GLfloat) 0.500000,
+       (GLfloat) - 0.353553, (GLfloat) - 0.353553, (GLfloat) 0.500000,
+       (GLfloat) - 0.433013, (GLfloat) - 0.250000, (GLfloat) 0.500000,
+       (GLfloat) - 0.482963, (GLfloat) - 0.129410, (GLfloat) 0.500000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) 0.500000,
+       (GLfloat) - 0.482963, (GLfloat) 0.129410, (GLfloat) 0.500000,
+       (GLfloat) - 0.433013, (GLfloat) 0.250000, (GLfloat) 0.500000,
+       (GLfloat) - 0.353553, (GLfloat) 0.353553, (GLfloat) 0.500000,
+       (GLfloat) - 0.250000, (GLfloat) 0.433013, (GLfloat) 0.500000,
+       (GLfloat) - 0.129410, (GLfloat) 0.482963, (GLfloat) 0.500000,
+       (GLfloat) 0.000000, (GLfloat) 0.500000, (GLfloat) - 0.500000,
+       (GLfloat) 0.129410, (GLfloat) 0.482963, (GLfloat) - 0.500000,
+       (GLfloat) 0.250000, (GLfloat) 0.433013, (GLfloat) - 0.500000,
+       (GLfloat) 0.353553, (GLfloat) 0.353553, (GLfloat) - 0.500000,
+       (GLfloat) 0.433013, (GLfloat) 0.250000, (GLfloat) - 0.500000,
+       (GLfloat) 0.482963, (GLfloat) 0.129410, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.500000,
+       (GLfloat) 0.482963, (GLfloat) - 0.129410, (GLfloat) - 0.500000,
+       (GLfloat) 0.433013, (GLfloat) - 0.250000, (GLfloat) - 0.500000,
+       (GLfloat) 0.353553, (GLfloat) - 0.353553, (GLfloat) - 0.500000,
+       (GLfloat) 0.250000, (GLfloat) - 0.433013, (GLfloat) - 0.500000,
+       (GLfloat) 0.129410, (GLfloat) - 0.482963, (GLfloat) - 0.500000,
+       (GLfloat) 0.000000, (GLfloat) - 0.500000, (GLfloat) - 0.500000,
+       (GLfloat) - 0.129410, (GLfloat) - 0.482963, (GLfloat) - 0.500000,
+       (GLfloat) - 0.250000, (GLfloat) - 0.433013, (GLfloat) - 0.500000,
+       (GLfloat) - 0.353553, (GLfloat) - 0.353553, (GLfloat) - 0.500000,
+       (GLfloat) - 0.433013, (GLfloat) - 0.250000, (GLfloat) - 0.500000,
+       (GLfloat) - 0.482963, (GLfloat) - 0.129410, (GLfloat) - 0.500000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.500000,
+       (GLfloat) - 0.482963, (GLfloat) 0.129410, (GLfloat) - 0.500000,
+       (GLfloat) - 0.433013, (GLfloat) 0.250000, (GLfloat) - 0.500000,
+       (GLfloat) - 0.353553, (GLfloat) 0.353553, (GLfloat) - 0.500000,
+       (GLfloat) - 0.250000, (GLfloat) 0.433013, (GLfloat) - 0.500000,
+       (GLfloat) - 0.129410, (GLfloat) 0.482963, (GLfloat) - 0.500000,
+};
+
+static GLfloat PipeBetweenBolts_normals[] =
+{
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.130526, (GLfloat) 0.991445, (GLfloat) 0.000000,
+       (GLfloat) 0.382683, (GLfloat) 0.923880, (GLfloat) 0.000000,
+       (GLfloat) 0.608761, (GLfloat) 0.793353, (GLfloat) 0.000000,
+       (GLfloat) 0.793353, (GLfloat) 0.608761, (GLfloat) 0.000000,
+       (GLfloat) 0.923880, (GLfloat) 0.382683, (GLfloat) 0.000000,
+       (GLfloat) 0.991445, (GLfloat) 0.130526, (GLfloat) 0.000000,
+       (GLfloat) 0.991445, (GLfloat) - 0.130526, (GLfloat) - 0.000000,
+       (GLfloat) 0.923880, (GLfloat) - 0.382683, (GLfloat) - 0.000000,
+       (GLfloat) 0.793353, (GLfloat) - 0.608761, (GLfloat) - 0.000000,
+       (GLfloat) 0.608761, (GLfloat) - 0.793353, (GLfloat) - 0.000000,
+       (GLfloat) 0.382683, (GLfloat) - 0.923880, (GLfloat) - 0.000000,
+       (GLfloat) 0.130526, (GLfloat) - 0.991445, (GLfloat) - 0.000000,
+       (GLfloat) - 0.130526, (GLfloat) - 0.991445, (GLfloat) - 0.000000,
+       (GLfloat) - 0.382683, (GLfloat) - 0.923880, (GLfloat) - 0.000000,
+       (GLfloat) - 0.608761, (GLfloat) - 0.793353, (GLfloat) - 0.000000,
+       (GLfloat) - 0.793353, (GLfloat) - 0.608761, (GLfloat) - 0.000000,
+       (GLfloat) - 0.923880, (GLfloat) - 0.382683, (GLfloat) - 0.000000,
+       (GLfloat) - 0.991445, (GLfloat) - 0.130526, (GLfloat) - 0.000000,
+       (GLfloat) - 0.991445, (GLfloat) 0.130526, (GLfloat) - 0.000000,
+       (GLfloat) - 0.923880, (GLfloat) 0.382683, (GLfloat) - 0.000000,
+       (GLfloat) - 0.793353, (GLfloat) 0.608761, (GLfloat) - 0.000000,
+       (GLfloat) - 0.608761, (GLfloat) 0.793353, (GLfloat) - 0.000000,
+       (GLfloat) - 0.382683, (GLfloat) 0.923880, (GLfloat) - 0.000000,
+       (GLfloat) - 0.130526, (GLfloat) 0.991445, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+};
+
+static unsigned short int PipeBetweenBolts_POLS[] =
+{
+       24, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
+       19, 20, 21, 22, 23, 1, 4, 24, 25, 1, 0, 1, 4, 25, 26, 2, 1, 1, 4, 26,
+       27, 3, 2, 1, 4, 27, 28, 4, 3, 1, 4, 28, 29, 5, 4, 1, 4, 29, 30, 6,
+       5, 1, 4, 30, 31, 7, 6, 1, 4, 31, 32, 8, 7, 1, 4, 32, 33, 9, 8, 1,
+      4, 33, 34, 10, 9, 1, 4, 34, 35, 11, 10, 1, 4, 35, 36, 12, 11, 1, 4, 36,
+    37, 13, 12, 1, 4, 37, 38, 14, 13, 1, 4, 38, 39, 15, 14, 1, 4, 39, 40, 16,
+     15, 1, 4, 40, 41, 17, 16, 1, 4, 41, 42, 18, 17, 1, 4, 42, 43, 19, 18, 1,
+     4, 43, 44, 20, 19, 1, 4, 44, 45, 21, 20, 1, 4, 45, 46, 22, 21, 1, 4, 46,
+  47, 23, 22, 1, 4, 47, 24, 0, 23, 1, 24, 24, 47, 46, 45, 44, 43, 42, 41, 40,
+       39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 29, 28, 27, 26, 25, 1,
+       0
+};
+
+struct lwo  LWO_PipeBetweenBolts =
+{
+       48,                     /* number of points */
+   PipeBetweenBolts_PNTS, PipeBetweenBolts_normals, PipeBetweenBolts_POLS, 0L
+};
+
+static GLfloat ElbowBolts_PNTS[] =
+{
+       (GLfloat) 0.273122, (GLfloat) - 0.600000, (GLfloat) - 0.403061,
+       (GLfloat) 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) 0.273122, (GLfloat) - 0.600000, (GLfloat) - 0.333061,
+       (GLfloat) 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.600000,
+       (GLfloat) 0.212500, (GLfloat) - 0.600000, (GLfloat) - 0.298061,
+       (GLfloat) 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) 0.151878, (GLfloat) - 0.600000, (GLfloat) - 0.333061,
+       (GLfloat) 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) 0.151878, (GLfloat) - 0.600000, (GLfloat) - 0.403061,
+       (GLfloat) 0.212500, (GLfloat) - 0.600000, (GLfloat) - 0.438061,
+       (GLfloat) 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.600000,
+       (GLfloat) 0.273122, (GLfloat) - 0.660000, (GLfloat) - 0.403061,
+       (GLfloat) 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) 0.273122, (GLfloat) - 0.660000, (GLfloat) - 0.333061,
+       (GLfloat) 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.660000,
+       (GLfloat) 0.212500, (GLfloat) - 0.660000, (GLfloat) - 0.298061,
+       (GLfloat) 0.151878, (GLfloat) - 0.660000, (GLfloat) - 0.333061,
+       (GLfloat) 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) 0.151878, (GLfloat) - 0.660000, (GLfloat) - 0.403061,
+       (GLfloat) 0.212500, (GLfloat) - 0.660000, (GLfloat) - 0.438061,
+       (GLfloat) 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.660000,
+       (GLfloat) 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) 0.273122, (GLfloat) - 0.460000, (GLfloat) - 0.403061,
+       (GLfloat) 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) 0.273122, (GLfloat) - 0.460000, (GLfloat) - 0.333061,
+       (GLfloat) 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.460000,
+       (GLfloat) 0.212500, (GLfloat) - 0.460000, (GLfloat) - 0.298061,
+       (GLfloat) 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) 0.151878, (GLfloat) - 0.460000, (GLfloat) - 0.333061,
+       (GLfloat) 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) 0.151878, (GLfloat) - 0.460000, (GLfloat) - 0.403061,
+       (GLfloat) 0.212500, (GLfloat) - 0.460000, (GLfloat) - 0.438061,
+       (GLfloat) 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.460000,
+       (GLfloat) 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) 0.273122, (GLfloat) - 0.520000, (GLfloat) - 0.403061,
+       (GLfloat) 0.273122, (GLfloat) - 0.520000, (GLfloat) - 0.333061,
+       (GLfloat) 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.520000,
+       (GLfloat) 0.212500, (GLfloat) - 0.520000, (GLfloat) - 0.298061,
+       (GLfloat) 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) 0.151878, (GLfloat) - 0.520000, (GLfloat) - 0.333061,
+       (GLfloat) 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) 0.151878, (GLfloat) - 0.520000, (GLfloat) - 0.403061,
+       (GLfloat) 0.212500, (GLfloat) - 0.520000, (GLfloat) - 0.438061,
+       (GLfloat) 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.520000,
+       (GLfloat) 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) 0.485622, (GLfloat) - 0.460000, (GLfloat) 0.035000,
+       (GLfloat) 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.460000,
+       (GLfloat) 0.425000, (GLfloat) - 0.460000, (GLfloat) 0.070000,
+       (GLfloat) 0.364378, (GLfloat) - 0.460000, (GLfloat) 0.035000,
+       (GLfloat) 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) 0.364378, (GLfloat) - 0.460000, (GLfloat) - 0.035000,
+       (GLfloat) 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.460000,
+       (GLfloat) 0.425000, (GLfloat) - 0.460000, (GLfloat) - 0.070000,
+       (GLfloat) 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) 0.485622, (GLfloat) - 0.460000, (GLfloat) - 0.035000,
+       (GLfloat) 0.485622, (GLfloat) - 0.520000, (GLfloat) 0.035000,
+       (GLfloat) 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.520000,
+       (GLfloat) 0.425000, (GLfloat) - 0.520000, (GLfloat) 0.070000,
+       (GLfloat) 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) 0.364378, (GLfloat) - 0.520000, (GLfloat) 0.035000,
+       (GLfloat) 0.364378, (GLfloat) - 0.520000, (GLfloat) - 0.035000,
+       (GLfloat) 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.520000,
+       (GLfloat) 0.425000, (GLfloat) - 0.520000, (GLfloat) - 0.070000,
+       (GLfloat) 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) 0.485622, (GLfloat) - 0.520000, (GLfloat) - 0.035000,
+       (GLfloat) 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) 0.485622, (GLfloat) - 0.600000, (GLfloat) 0.035000,
+       (GLfloat) 0.425000, (GLfloat) - 0.600000, (GLfloat) 0.070000,
+       (GLfloat) 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.600000,
+       (GLfloat) 0.364378, (GLfloat) - 0.600000, (GLfloat) 0.035000,
+       (GLfloat) 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) 0.364378, (GLfloat) - 0.600000, (GLfloat) - 0.035000,
+       (GLfloat) 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.600000,
+       (GLfloat) 0.425000, (GLfloat) - 0.600000, (GLfloat) - 0.070000,
+       (GLfloat) 0.485622, (GLfloat) - 0.600000, (GLfloat) - 0.035000,
+       (GLfloat) 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) 0.485622, (GLfloat) - 0.660000, (GLfloat) 0.035000,
+       (GLfloat) 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) 0.425000, (GLfloat) - 0.660000, (GLfloat) 0.070000,
+       (GLfloat) 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.660000,
+       (GLfloat) 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) 0.364378, (GLfloat) - 0.660000, (GLfloat) 0.035000,
+       (GLfloat) 0.364378, (GLfloat) - 0.660000, (GLfloat) - 0.035000,
+       (GLfloat) 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.660000,
+       (GLfloat) 0.425000, (GLfloat) - 0.660000, (GLfloat) - 0.070000,
+       (GLfloat) 0.485622, (GLfloat) - 0.660000, (GLfloat) - 0.035000,
+       (GLfloat) 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.460000,
+       (GLfloat) 0.212500, (GLfloat) - 0.460000, (GLfloat) 0.438061,
+       (GLfloat) 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) 0.151878, (GLfloat) - 0.460000, (GLfloat) 0.403061,
+       (GLfloat) 0.151878, (GLfloat) - 0.460000, (GLfloat) 0.333061,
+       (GLfloat) 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) 0.212500, (GLfloat) - 0.460000, (GLfloat) 0.298061,
+       (GLfloat) 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.460000,
+       (GLfloat) 0.273122, (GLfloat) - 0.460000, (GLfloat) 0.333061,
+       (GLfloat) 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) 0.273122, (GLfloat) - 0.460000, (GLfloat) 0.403061,
+       (GLfloat) 0.212500, (GLfloat) - 0.520000, (GLfloat) 0.438061,
+       (GLfloat) 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.520000,
+       (GLfloat) 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) 0.151878, (GLfloat) - 0.520000, (GLfloat) 0.403061,
+       (GLfloat) 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) 0.151878, (GLfloat) - 0.520000, (GLfloat) 0.333061,
+       (GLfloat) 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.520000,
+       (GLfloat) 0.212500, (GLfloat) - 0.520000, (GLfloat) 0.298061,
+       (GLfloat) 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) 0.273122, (GLfloat) - 0.520000, (GLfloat) 0.333061,
+       (GLfloat) 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) 0.273122, (GLfloat) - 0.520000, (GLfloat) 0.403061,
+       (GLfloat) 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.600000,
+       (GLfloat) 0.212500, (GLfloat) - 0.600000, (GLfloat) 0.438061,
+       (GLfloat) 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) 0.151878, (GLfloat) - 0.600000, (GLfloat) 0.403061,
+       (GLfloat) 0.151878, (GLfloat) - 0.600000, (GLfloat) 0.333061,
+       (GLfloat) 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.600000,
+       (GLfloat) 0.212500, (GLfloat) - 0.600000, (GLfloat) 0.298061,
+       (GLfloat) 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) 0.273122, (GLfloat) - 0.600000, (GLfloat) 0.333061,
+       (GLfloat) 0.273122, (GLfloat) - 0.600000, (GLfloat) 0.403061,
+       (GLfloat) 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) 0.212500, (GLfloat) - 0.660000, (GLfloat) 0.438061,
+       (GLfloat) 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.660000,
+       (GLfloat) 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) 0.151878, (GLfloat) - 0.660000, (GLfloat) 0.403061,
+       (GLfloat) 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) 0.151878, (GLfloat) - 0.660000, (GLfloat) 0.333061,
+       (GLfloat) 0.212500, (GLfloat) - 0.660000, (GLfloat) 0.298061,
+       (GLfloat) 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.660000,
+       (GLfloat) 0.273122, (GLfloat) - 0.660000, (GLfloat) 0.333061,
+       (GLfloat) 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) 0.273122, (GLfloat) - 0.660000, (GLfloat) 0.403061,
+       (GLfloat) 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.460000, (GLfloat) 0.403061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.460000, (GLfloat) 0.333061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.460000, (GLfloat) 0.298061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.460000, (GLfloat) 0.333061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.460000, (GLfloat) 0.403061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.460000, (GLfloat) 0.438061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.520000, (GLfloat) 0.403061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.520000, (GLfloat) 0.333061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.520000, (GLfloat) 0.298061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.520000, (GLfloat) 0.333061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.520000, (GLfloat) 0.403061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.520000, (GLfloat) 0.438061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.600000, (GLfloat) 0.403061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.600000, (GLfloat) 0.333061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.600000, (GLfloat) 0.298061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.600000, (GLfloat) 0.333061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.600000, (GLfloat) 0.403061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.600000, (GLfloat) 0.438061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.660000, (GLfloat) 0.403061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.660000, (GLfloat) 0.333061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.298061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.660000, (GLfloat) 0.298061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.660000, (GLfloat) 0.333061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.660000, (GLfloat) 0.403061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.438061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.660000, (GLfloat) 0.438061,
+       (GLfloat) - 0.485622, (GLfloat) - 0.460000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) - 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.460000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.460000, (GLfloat) - 0.070000,
+       (GLfloat) - 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.460000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.460000, (GLfloat) 0.035000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.460000, (GLfloat) 0.070000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.460000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.460000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.460000, (GLfloat) 0.035000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.520000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.520000, (GLfloat) - 0.070000,
+       (GLfloat) - 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.520000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.520000, (GLfloat) 0.035000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.520000, (GLfloat) 0.070000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.520000, (GLfloat) 0.035000,
+       (GLfloat) - 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.600000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.600000, (GLfloat) - 0.070000,
+       (GLfloat) - 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.600000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.600000, (GLfloat) 0.035000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.600000, (GLfloat) 0.070000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.600000, (GLfloat) 0.035000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.660000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.485622, (GLfloat) 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.660000, (GLfloat) - 0.070000,
+       (GLfloat) - 0.425000, (GLfloat) 0.070000, (GLfloat) - 0.660000,
+       (GLfloat) - 0.364378, (GLfloat) 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.660000, (GLfloat) - 0.035000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.660000, (GLfloat) 0.035000,
+       (GLfloat) - 0.364378, (GLfloat) - 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.070000, (GLfloat) - 0.660000,
+       (GLfloat) - 0.425000, (GLfloat) - 0.660000, (GLfloat) 0.070000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.660000, (GLfloat) 0.035000,
+       (GLfloat) - 0.485622, (GLfloat) - 0.035000, (GLfloat) - 0.660000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.460000, (GLfloat) - 0.438061,
+       (GLfloat) - 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.460000, (GLfloat) - 0.403061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.460000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.460000, (GLfloat) - 0.298061,
+       (GLfloat) - 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.460000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.273122, (GLfloat) - 0.460000, (GLfloat) - 0.403061,
+       (GLfloat) - 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.460000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.520000, (GLfloat) - 0.438061,
+       (GLfloat) - 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.520000, (GLfloat) - 0.403061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.520000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.520000, (GLfloat) - 0.298061,
+       (GLfloat) - 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.520000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.520000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.520000, (GLfloat) - 0.403061,
+       (GLfloat) - 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.600000, (GLfloat) - 0.438061,
+       (GLfloat) - 0.151878, (GLfloat) - 0.600000, (GLfloat) - 0.403061,
+       (GLfloat) - 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.600000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.212500, (GLfloat) - 0.600000, (GLfloat) - 0.298061,
+       (GLfloat) - 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.600000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.600000, (GLfloat) - 0.403061,
+       (GLfloat) - 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.600000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.660000, (GLfloat) - 0.438061,
+       (GLfloat) - 0.212500, (GLfloat) 0.438061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.660000, (GLfloat) - 0.403061,
+       (GLfloat) - 0.151878, (GLfloat) 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.151878, (GLfloat) - 0.660000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.151878, (GLfloat) 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.212500, (GLfloat) - 0.660000, (GLfloat) - 0.298061,
+       (GLfloat) - 0.212500, (GLfloat) 0.298061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.660000, (GLfloat) - 0.333061,
+       (GLfloat) - 0.273122, (GLfloat) 0.333061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.273122, (GLfloat) 0.403061, (GLfloat) - 0.660000,
+       (GLfloat) - 0.273122, (GLfloat) - 0.660000, (GLfloat) - 0.403061,
+};
+
+static GLfloat ElbowBolts_normals[] =
+{
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866026, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.499999, (GLfloat) 0.866026, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) - 0.499999, (GLfloat) - 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) - 0.866026, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.866025, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.866025, (GLfloat) 0.000000,
+       (GLfloat) 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866026,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.499999, (GLfloat) 0.000000, (GLfloat) - 0.866026,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866026,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866026,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866026,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866026,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.499999, (GLfloat) 0.000000, (GLfloat) 0.866026,
+       (GLfloat) - 1.000000, (GLfloat) - 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866026,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866026,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) 0.000000,
+       (GLfloat) 1.000000, (GLfloat) 0.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866026,
+       (GLfloat) - 0.500000, (GLfloat) 0.000000, (GLfloat) 0.866025,
+       (GLfloat) - 1.000000, (GLfloat) 0.000000, (GLfloat) 0.000000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.866025,
+       (GLfloat) 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+};
+
+static unsigned short int ElbowBolts_POLS[] =
+{
+       6, 241, 242, 245, 246, 248, 251, 1, 4, 253, 254, 242, 241, 1, 4, 254, 257, 245, 242, 1,
+       4, 257, 258, 246, 245, 1, 4, 258, 260, 248, 246, 1, 4, 260, 262, 251, 248, 1, 4, 262,
+       253, 241, 251, 1, 6, 253, 262, 260, 258, 257, 254, 1, 6, 264, 267, 268, 271, 273, 275, 1,
+       4, 277, 279, 267, 264, 1, 4, 279, 281, 268, 267, 1, 4, 281, 283, 271, 268, 1, 4, 283,
+       285, 273, 271, 1, 4, 285, 286, 275, 273, 1, 4, 286, 277, 264, 275, 1, 6, 277, 286, 285,
+       283, 281, 279, 1, 6, 193, 194, 196, 199, 201, 202, 1, 4, 205, 206, 194, 193, 1, 4, 206,
+       208, 196, 194, 1, 4, 208, 210, 199, 196, 1, 4, 210, 213, 201, 199, 1, 4, 213, 214, 202,
+       201, 1, 4, 214, 205, 193, 202, 1, 6, 205, 214, 213, 210, 208, 206, 1, 6, 216, 219, 221,
+       223, 225, 227, 1, 4, 229, 231, 219, 216, 1, 4, 231, 232, 221, 219, 1, 4, 232, 235, 223,
+       221, 1, 4, 235, 236, 225, 223, 1, 4, 236, 239, 227, 225, 1, 4, 239, 229, 216, 227, 1,
+       6, 229, 239, 236, 235, 232, 231, 1, 6, 145, 147, 148, 150, 152, 155, 1, 4, 157, 158, 147,
+       145, 1, 4, 158, 161, 148, 147, 1, 4, 161, 162, 150, 148, 1, 4, 162, 165, 152, 150, 1,
+       4, 165, 167, 155, 152, 1, 4, 167, 157, 145, 155, 1, 6, 157, 167, 165, 162, 161, 158, 1,
+       6, 169, 171, 173, 174, 177, 178, 1, 4, 181, 182, 171, 169, 1, 4, 182, 184, 173, 171, 1,
+       4, 184, 187, 174, 173, 1, 4, 187, 189, 177, 174, 1, 4, 189, 190, 178, 177, 1, 4, 190,
+       181, 169, 178, 1, 6, 181, 190, 189, 187, 184, 182, 1, 6, 96, 98, 101, 103, 105, 106, 1,
+       4, 109, 110, 98, 96, 1, 4, 110, 112, 101, 98, 1, 4, 112, 114, 103, 101, 1, 4, 114,
+       116, 105, 103, 1, 4, 116, 118, 106, 105, 1, 4, 118, 109, 96, 106, 1, 6, 109, 118, 116,
+       114, 112, 110, 1, 6, 120, 122, 125, 126, 128, 131, 1, 4, 133, 134, 122, 120, 1, 4, 134,
+       136, 125, 122, 1, 4, 136, 139, 126, 125, 1, 4, 139, 141, 128, 126, 1, 4, 141, 143, 131,
+       128, 1, 4, 143, 133, 120, 131, 1, 6, 133, 143, 141, 139, 136, 134, 1, 6, 48, 50, 53,
+    54, 56, 58, 1, 4, 61, 62, 50, 48, 1, 4, 62, 64, 53, 50, 1, 4, 64, 67, 54,
+     53, 1, 4, 67, 68, 56, 54, 1, 4, 68, 70, 58, 56, 1, 4, 70, 61, 48, 58, 1,
+   6, 61, 70, 68, 67, 64, 62, 1, 6, 72, 75, 77, 78, 80, 83, 1, 4, 85, 87, 75,
+     72, 1, 4, 87, 88, 77, 75, 1, 4, 88, 91, 78, 77, 1, 4, 91, 92, 80, 78, 1,
+    4, 92, 95, 83, 80, 1, 4, 95, 85, 72, 83, 1, 6, 85, 95, 92, 91, 88, 87, 1,
+    6, 24, 26, 28, 30, 32, 35, 1, 4, 36, 39, 26, 24, 1, 4, 39, 40, 28, 26, 1,
+     4, 40, 42, 30, 28, 1, 4, 42, 44, 32, 30, 1, 4, 44, 47, 35, 32, 1, 4, 47,
+       36, 24, 35, 1, 6, 36, 47, 44, 42, 40, 39, 1, 6, 1, 2, 4, 6, 8, 11, 1,
+       4, 13, 15, 2, 1, 1, 4, 15, 16, 4, 2, 1, 4, 16, 19, 6, 4, 1, 4, 19,
+       20, 8, 6, 1, 4, 20, 23, 11, 8, 1, 4, 23, 13, 1, 11, 1, 6, 13, 23, 20,
+       19, 16, 15, 1, 6, 240, 243, 244, 247, 249, 250, 1, 4, 252, 255, 243, 240, 1, 4, 255,
+       256, 244, 243, 1, 4, 256, 259, 247, 244, 1, 4, 259, 261, 249, 247, 1, 4, 261, 263, 250,
+       249, 1, 4, 263, 252, 240, 250, 1, 6, 252, 263, 261, 259, 256, 255, 1, 6, 265, 266, 269,
+       270, 272, 274, 1, 4, 276, 278, 266, 265, 1, 4, 278, 280, 269, 266, 1, 4, 280, 282, 270,
+       269, 1, 4, 282, 284, 272, 270, 1, 4, 284, 287, 274, 272, 1, 4, 287, 276, 265, 274, 1,
+       6, 276, 287, 284, 282, 280, 278, 1, 6, 192, 195, 197, 198, 200, 203, 1, 4, 204, 207, 195,
+       192, 1, 4, 207, 209, 197, 195, 1, 4, 209, 211, 198, 197, 1, 4, 211, 212, 200, 198, 1,
+       4, 212, 215, 203, 200, 1, 4, 215, 204, 192, 203, 1, 6, 204, 215, 212, 211, 209, 207, 1,
+       6, 217, 218, 220, 222, 224, 226, 1, 4, 228, 230, 218, 217, 1, 4, 230, 233, 220, 218, 1,
+       4, 233, 234, 222, 220, 1, 4, 234, 237, 224, 222, 1, 4, 237, 238, 226, 224, 1, 4, 238,
+       228, 217, 226, 1, 6, 228, 238, 237, 234, 233, 230, 1, 6, 144, 146, 149, 151, 153, 154, 1,
+       4, 156, 159, 146, 144, 1, 4, 159, 160, 149, 146, 1, 4, 160, 163, 151, 149, 1, 4, 163,
+       164, 153, 151, 1, 4, 164, 166, 154, 153, 1, 4, 166, 156, 144, 154, 1, 6, 156, 166, 164,
+       163, 160, 159, 1, 6, 168, 170, 172, 175, 176, 179, 1, 4, 180, 183, 170, 168, 1, 4, 183,
+       185, 172, 170, 1, 4, 185, 186, 175, 172, 1, 4, 186, 188, 176, 175, 1, 4, 188, 191, 179,
+       176, 1, 4, 191, 180, 168, 179, 1, 6, 180, 191, 188, 186, 185, 183, 1, 6, 97, 99, 100,
+       102, 104, 107, 1, 4, 108, 111, 99, 97, 1, 4, 111, 113, 100, 99, 1, 4, 113, 115, 102,
+       100, 1, 4, 115, 117, 104, 102, 1, 4, 117, 119, 107, 104, 1, 4, 119, 108, 97, 107, 1,
+       6, 108, 119, 117, 115, 113, 111, 1, 6, 121, 123, 124, 127, 129, 130, 1, 4, 132, 135, 123,
+       121, 1, 4, 135, 137, 124, 123, 1, 4, 137, 138, 127, 124, 1, 4, 138, 140, 129, 127, 1,
+       4, 140, 142, 130, 129, 1, 4, 142, 132, 121, 130, 1, 6, 132, 142, 140, 138, 137, 135, 1,
+    6, 49, 51, 52, 55, 57, 59, 1, 4, 60, 63, 51, 49, 1, 4, 63, 65, 52, 51, 1,
+     4, 65, 66, 55, 52, 1, 4, 66, 69, 57, 55, 1, 4, 69, 71, 59, 57, 1, 4, 71,
+   60, 49, 59, 1, 6, 60, 71, 69, 66, 65, 63, 1, 6, 73, 74, 76, 79, 81, 82, 1,
+     4, 84, 86, 74, 73, 1, 4, 86, 89, 76, 74, 1, 4, 89, 90, 79, 76, 1, 4, 90,
+    93, 81, 79, 1, 4, 93, 94, 82, 81, 1, 4, 94, 84, 73, 82, 1, 6, 84, 94, 93,
+    90, 89, 86, 1, 6, 25, 27, 29, 31, 33, 34, 1, 4, 37, 38, 27, 25, 1, 4, 38,
+    41, 29, 27, 1, 4, 41, 43, 31, 29, 1, 4, 43, 45, 33, 31, 1, 4, 45, 46, 34,
+       33, 1, 4, 46, 37, 25, 34, 1, 6, 37, 46, 45, 43, 41, 38, 1, 6, 0, 3, 5,
+       7, 9, 10, 1, 4, 12, 14, 3, 0, 1, 4, 14, 17, 5, 3, 1, 4, 17, 18, 7,
+       5, 1, 4, 18, 21, 9, 7, 1, 4, 21, 22, 10, 9, 1, 4, 22, 12, 0, 10, 1,
+       6, 12, 22, 21, 18, 17, 14, 1,
+       0
+};
+
+struct lwo  LWO_ElbowBolts =
+{
+       288,                    /* number of points */
+       ElbowBolts_PNTS, ElbowBolts_normals, ElbowBolts_POLS, 0L
+};
+
+static GLfloat ElbowCoins_PNTS[] =
+{
+       (GLfloat) 0.000000, (GLfloat) - 0.520000, (GLfloat) - 0.500000,
+       (GLfloat) 0.097545, (GLfloat) - 0.520000, (GLfloat) - 0.490393,
+       (GLfloat) 0.191342, (GLfloat) - 0.520000, (GLfloat) - 0.461940,
+       (GLfloat) 0.277785, (GLfloat) - 0.520000, (GLfloat) - 0.415735,
+       (GLfloat) 0.353553, (GLfloat) - 0.520000, (GLfloat) - 0.353553,
+       (GLfloat) 0.415735, (GLfloat) - 0.520000, (GLfloat) - 0.277785,
+       (GLfloat) 0.461940, (GLfloat) - 0.520000, (GLfloat) - 0.191342,
+       (GLfloat) 0.490393, (GLfloat) - 0.520000, (GLfloat) - 0.097545,
+       (GLfloat) 0.500000, (GLfloat) - 0.520000, (GLfloat) - 0.000000,
+       (GLfloat) 0.490393, (GLfloat) - 0.520000, (GLfloat) 0.097545,
+       (GLfloat) 0.461940, (GLfloat) - 0.520000, (GLfloat) 0.191342,
+       (GLfloat) 0.415735, (GLfloat) - 0.520000, (GLfloat) 0.277785,
+       (GLfloat) 0.353553, (GLfloat) - 0.520000, (GLfloat) 0.353553,
+       (GLfloat) 0.277785, (GLfloat) - 0.520000, (GLfloat) 0.415735,
+       (GLfloat) 0.191342, (GLfloat) - 0.520000, (GLfloat) 0.461940,
+       (GLfloat) 0.097545, (GLfloat) - 0.520000, (GLfloat) 0.490393,
+       (GLfloat) 0.000000, (GLfloat) - 0.520000, (GLfloat) 0.500000,
+       (GLfloat) - 0.097545, (GLfloat) - 0.520000, (GLfloat) 0.490393,
+       (GLfloat) - 0.191342, (GLfloat) - 0.520000, (GLfloat) 0.461940,
+       (GLfloat) - 0.277785, (GLfloat) - 0.520000, (GLfloat) 0.415735,
+       (GLfloat) - 0.353553, (GLfloat) - 0.520000, (GLfloat) 0.353553,
+       (GLfloat) - 0.415735, (GLfloat) - 0.520000, (GLfloat) 0.277785,
+       (GLfloat) - 0.461940, (GLfloat) - 0.520000, (GLfloat) 0.191342,
+       (GLfloat) - 0.490393, (GLfloat) - 0.520000, (GLfloat) 0.097545,
+       (GLfloat) - 0.500000, (GLfloat) - 0.520000, (GLfloat) 0.000000,
+       (GLfloat) - 0.490393, (GLfloat) - 0.520000, (GLfloat) - 0.097545,
+       (GLfloat) - 0.461940, (GLfloat) - 0.520000, (GLfloat) - 0.191342,
+       (GLfloat) - 0.415735, (GLfloat) - 0.520000, (GLfloat) - 0.277785,
+       (GLfloat) - 0.353553, (GLfloat) - 0.520000, (GLfloat) - 0.353553,
+       (GLfloat) - 0.277785, (GLfloat) - 0.520000, (GLfloat) - 0.415735,
+       (GLfloat) - 0.191342, (GLfloat) - 0.520000, (GLfloat) - 0.461940,
+       (GLfloat) - 0.097545, (GLfloat) - 0.520000, (GLfloat) - 0.490393,
+       (GLfloat) 0.000000, (GLfloat) - 0.600000, (GLfloat) - 0.500000,
+       (GLfloat) 0.097545, (GLfloat) - 0.600000, (GLfloat) - 0.490393,
+       (GLfloat) 0.191342, (GLfloat) - 0.600000, (GLfloat) - 0.461940,
+       (GLfloat) 0.277785, (GLfloat) - 0.600000, (GLfloat) - 0.415735,
+       (GLfloat) 0.353553, (GLfloat) - 0.600000, (GLfloat) - 0.353553,
+       (GLfloat) 0.415735, (GLfloat) - 0.600000, (GLfloat) - 0.277785,
+       (GLfloat) 0.461940, (GLfloat) - 0.600000, (GLfloat) - 0.191342,
+       (GLfloat) 0.490393, (GLfloat) - 0.600000, (GLfloat) - 0.097545,
+       (GLfloat) 0.500000, (GLfloat) - 0.600000, (GLfloat) - 0.000000,
+       (GLfloat) 0.490393, (GLfloat) - 0.600000, (GLfloat) 0.097545,
+       (GLfloat) 0.461940, (GLfloat) - 0.600000, (GLfloat) 0.191342,
+       (GLfloat) 0.415735, (GLfloat) - 0.600000, (GLfloat) 0.277785,
+       (GLfloat) 0.353553, (GLfloat) - 0.600000, (GLfloat) 0.353553,
+       (GLfloat) 0.277785, (GLfloat) - 0.600000, (GLfloat) 0.415735,
+       (GLfloat) 0.191342, (GLfloat) - 0.600000, (GLfloat) 0.461940,
+       (GLfloat) 0.097545, (GLfloat) - 0.600000, (GLfloat) 0.490393,
+       (GLfloat) 0.000000, (GLfloat) - 0.600000, (GLfloat) 0.500000,
+       (GLfloat) - 0.097545, (GLfloat) - 0.600000, (GLfloat) 0.490393,
+       (GLfloat) - 0.191342, (GLfloat) - 0.600000, (GLfloat) 0.461940,
+       (GLfloat) - 0.277785, (GLfloat) - 0.600000, (GLfloat) 0.415735,
+       (GLfloat) - 0.353553, (GLfloat) - 0.600000, (GLfloat) 0.353553,
+       (GLfloat) - 0.415735, (GLfloat) - 0.600000, (GLfloat) 0.277785,
+       (GLfloat) - 0.461940, (GLfloat) - 0.600000, (GLfloat) 0.191342,
+       (GLfloat) - 0.490393, (GLfloat) - 0.600000, (GLfloat) 0.097545,
+       (GLfloat) - 0.500000, (GLfloat) - 0.600000, (GLfloat) 0.000000,
+       (GLfloat) - 0.490393, (GLfloat) - 0.600000, (GLfloat) - 0.097545,
+       (GLfloat) - 0.461940, (GLfloat) - 0.600000, (GLfloat) - 0.191342,
+       (GLfloat) - 0.415735, (GLfloat) - 0.600000, (GLfloat) - 0.277785,
+       (GLfloat) - 0.353553, (GLfloat) - 0.600000, (GLfloat) - 0.353553,
+       (GLfloat) - 0.277785, (GLfloat) - 0.600000, (GLfloat) - 0.415735,
+       (GLfloat) - 0.191342, (GLfloat) - 0.600000, (GLfloat) - 0.461940,
+       (GLfloat) - 0.097545, (GLfloat) - 0.600000, (GLfloat) - 0.490393,
+       (GLfloat) 0.000000, (GLfloat) 0.500000, (GLfloat) - 0.520000,
+       (GLfloat) 0.097545, (GLfloat) 0.490393, (GLfloat) - 0.520000,
+       (GLfloat) 0.191342, (GLfloat) 0.461940, (GLfloat) - 0.520000,
+       (GLfloat) 0.277785, (GLfloat) 0.415735, (GLfloat) - 0.520000,
+       (GLfloat) 0.353553, (GLfloat) 0.353553, (GLfloat) - 0.520000,
+       (GLfloat) 0.415735, (GLfloat) 0.277785, (GLfloat) - 0.520000,
+       (GLfloat) 0.461940, (GLfloat) 0.191342, (GLfloat) - 0.520000,
+       (GLfloat) 0.490393, (GLfloat) 0.097545, (GLfloat) - 0.520000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.520000,
+       (GLfloat) 0.490393, (GLfloat) - 0.097545, (GLfloat) - 0.520000,
+       (GLfloat) 0.461940, (GLfloat) - 0.191342, (GLfloat) - 0.520000,
+       (GLfloat) 0.415735, (GLfloat) - 0.277785, (GLfloat) - 0.520000,
+       (GLfloat) 0.353553, (GLfloat) - 0.353553, (GLfloat) - 0.520000,
+       (GLfloat) 0.277785, (GLfloat) - 0.415735, (GLfloat) - 0.520000,
+       (GLfloat) 0.191342, (GLfloat) - 0.461940, (GLfloat) - 0.520000,
+       (GLfloat) 0.097545, (GLfloat) - 0.490393, (GLfloat) - 0.520000,
+       (GLfloat) 0.000000, (GLfloat) - 0.500000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.097545, (GLfloat) - 0.490393, (GLfloat) - 0.520000,
+       (GLfloat) - 0.191342, (GLfloat) - 0.461940, (GLfloat) - 0.520000,
+       (GLfloat) - 0.277785, (GLfloat) - 0.415735, (GLfloat) - 0.520000,
+       (GLfloat) - 0.353553, (GLfloat) - 0.353553, (GLfloat) - 0.520000,
+       (GLfloat) - 0.415735, (GLfloat) - 0.277785, (GLfloat) - 0.520000,
+       (GLfloat) - 0.461940, (GLfloat) - 0.191342, (GLfloat) - 0.520000,
+       (GLfloat) - 0.490393, (GLfloat) - 0.097545, (GLfloat) - 0.520000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.520000,
+       (GLfloat) - 0.490393, (GLfloat) 0.097545, (GLfloat) - 0.520000,
+       (GLfloat) - 0.461940, (GLfloat) 0.191342, (GLfloat) - 0.520000,
+       (GLfloat) - 0.415735, (GLfloat) 0.277785, (GLfloat) - 0.520000,
+       (GLfloat) - 0.353553, (GLfloat) 0.353553, (GLfloat) - 0.520000,
+       (GLfloat) - 0.277785, (GLfloat) 0.415735, (GLfloat) - 0.520000,
+       (GLfloat) - 0.191342, (GLfloat) 0.461940, (GLfloat) - 0.520000,
+       (GLfloat) - 0.097545, (GLfloat) 0.490393, (GLfloat) - 0.520000,
+       (GLfloat) 0.000000, (GLfloat) 0.500000, (GLfloat) - 0.600000,
+       (GLfloat) 0.097545, (GLfloat) 0.490393, (GLfloat) - 0.600000,
+       (GLfloat) 0.191342, (GLfloat) 0.461940, (GLfloat) - 0.600000,
+       (GLfloat) 0.277785, (GLfloat) 0.415735, (GLfloat) - 0.600000,
+       (GLfloat) 0.353553, (GLfloat) 0.353553, (GLfloat) - 0.600000,
+       (GLfloat) 0.415735, (GLfloat) 0.277785, (GLfloat) - 0.600000,
+       (GLfloat) 0.461940, (GLfloat) 0.191342, (GLfloat) - 0.600000,
+       (GLfloat) 0.490393, (GLfloat) 0.097545, (GLfloat) - 0.600000,
+       (GLfloat) 0.500000, (GLfloat) 0.000000, (GLfloat) - 0.600000,
+       (GLfloat) 0.490393, (GLfloat) - 0.097545, (GLfloat) - 0.600000,
+       (GLfloat) 0.461940, (GLfloat) - 0.191342, (GLfloat) - 0.600000,
+       (GLfloat) 0.415735, (GLfloat) - 0.277785, (GLfloat) - 0.600000,
+       (GLfloat) 0.353553, (GLfloat) - 0.353553, (GLfloat) - 0.600000,
+       (GLfloat) 0.277785, (GLfloat) - 0.415735, (GLfloat) - 0.600000,
+       (GLfloat) 0.191342, (GLfloat) - 0.461940, (GLfloat) - 0.600000,
+       (GLfloat) 0.097545, (GLfloat) - 0.490393, (GLfloat) - 0.600000,
+       (GLfloat) 0.000000, (GLfloat) - 0.500000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.097545, (GLfloat) - 0.490393, (GLfloat) - 0.600000,
+       (GLfloat) - 0.191342, (GLfloat) - 0.461940, (GLfloat) - 0.600000,
+       (GLfloat) - 0.277785, (GLfloat) - 0.415735, (GLfloat) - 0.600000,
+       (GLfloat) - 0.353553, (GLfloat) - 0.353553, (GLfloat) - 0.600000,
+       (GLfloat) - 0.415735, (GLfloat) - 0.277785, (GLfloat) - 0.600000,
+       (GLfloat) - 0.461940, (GLfloat) - 0.191342, (GLfloat) - 0.600000,
+       (GLfloat) - 0.490393, (GLfloat) - 0.097545, (GLfloat) - 0.600000,
+       (GLfloat) - 0.500000, (GLfloat) - 0.000000, (GLfloat) - 0.600000,
+       (GLfloat) - 0.490393, (GLfloat) 0.097545, (GLfloat) - 0.600000,
+       (GLfloat) - 0.461940, (GLfloat) 0.191342, (GLfloat) - 0.600000,
+       (GLfloat) - 0.415735, (GLfloat) 0.277785, (GLfloat) - 0.600000,
+       (GLfloat) - 0.353553, (GLfloat) 0.353553, (GLfloat) - 0.600000,
+       (GLfloat) - 0.277785, (GLfloat) 0.415735, (GLfloat) - 0.600000,
+       (GLfloat) - 0.191342, (GLfloat) 0.461940, (GLfloat) - 0.600000,
+       (GLfloat) - 0.097545, (GLfloat) 0.490393, (GLfloat) - 0.600000,
+};
+
+static GLfloat ElbowCoins_normals[] =
+{
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) 1.000000,
+       (GLfloat) 0.098017, (GLfloat) 0.995185, (GLfloat) 0.000000,
+       (GLfloat) 0.290285, (GLfloat) 0.956940, (GLfloat) 0.000000,
+       (GLfloat) 0.471397, (GLfloat) 0.881921, (GLfloat) 0.000000,
+       (GLfloat) 0.634393, (GLfloat) 0.773010, (GLfloat) 0.000000,
+       (GLfloat) 0.773010, (GLfloat) 0.634393, (GLfloat) 0.000000,
+       (GLfloat) 0.881921, (GLfloat) 0.471397, (GLfloat) 0.000000,
+       (GLfloat) 0.956940, (GLfloat) 0.290285, (GLfloat) 0.000000,
+       (GLfloat) 0.995185, (GLfloat) 0.098017, (GLfloat) 0.000000,
+       (GLfloat) 0.995185, (GLfloat) - 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) 0.956940, (GLfloat) - 0.290285, (GLfloat) - 0.000000,
+       (GLfloat) 0.881921, (GLfloat) - 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) 0.773010, (GLfloat) - 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) 0.634393, (GLfloat) - 0.773010, (GLfloat) - 0.000000,
+       (GLfloat) 0.471397, (GLfloat) - 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) 0.290285, (GLfloat) - 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) 0.098017, (GLfloat) - 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) - 0.098017, (GLfloat) - 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) - 0.290285, (GLfloat) - 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) - 0.471397, (GLfloat) - 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) - 0.634393, (GLfloat) - 0.773010, (GLfloat) - 0.000000,
+       (GLfloat) - 0.773010, (GLfloat) - 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) - 0.881921, (GLfloat) - 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) - 0.956940, (GLfloat) - 0.290285, (GLfloat) - 0.000000,
+       (GLfloat) - 0.995185, (GLfloat) - 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) - 0.995185, (GLfloat) 0.098017, (GLfloat) - 0.000000,
+       (GLfloat) - 0.956940, (GLfloat) 0.290285, (GLfloat) - 0.000000,
+       (GLfloat) - 0.881921, (GLfloat) 0.471397, (GLfloat) - 0.000000,
+       (GLfloat) - 0.773010, (GLfloat) 0.634393, (GLfloat) - 0.000000,
+       (GLfloat) - 0.634393, (GLfloat) 0.773010, (GLfloat) - 0.000000,
+       (GLfloat) - 0.471397, (GLfloat) 0.881921, (GLfloat) - 0.000000,
+       (GLfloat) - 0.290285, (GLfloat) 0.956940, (GLfloat) - 0.000000,
+       (GLfloat) - 0.098017, (GLfloat) 0.995185, (GLfloat) - 0.000000,
+       (GLfloat) - 0.000000, (GLfloat) 0.000000, (GLfloat) - 1.000000,
+       (GLfloat) - 0.000000, (GLfloat) 1.000000, (GLfloat) - 0.000000,
+       (GLfloat) 0.098017, (GLfloat) 0.000000, (GLfloat) - 0.995185,
+       (GLfloat) 0.290285, (GLfloat) 0.000000, (GLfloat) - 0.956940,
+       (GLfloat) 0.471397, (GLfloat) 0.000000, (GLfloat) - 0.881921,
+       (GLfloat) 0.634393, (GLfloat) 0.000000, (GLfloat) - 0.773010,
+       (GLfloat) 0.773010, (GLfloat) 0.000000, (GLfloat) - 0.634393,
+       (GLfloat) 0.881921, (GLfloat) 0.000000, (GLfloat) - 0.471397,
+       (GLfloat) 0.956940, (GLfloat) 0.000000, (GLfloat) - 0.290285,
+       (GLfloat) 0.995185, (GLfloat) 0.000000, (GLfloat) - 0.098017,
+       (GLfloat) 0.995185, (GLfloat) 0.000000, (GLfloat) 0.098017,
+       (GLfloat) 0.956940, (GLfloat) 0.000000, (GLfloat) 0.290285,
+       (GLfloat) 0.881921, (GLfloat) 0.000000, (GLfloat) 0.471397,
+       (GLfloat) 0.773010, (GLfloat) 0.000000, (GLfloat) 0.634393,
+       (GLfloat) 0.634393, (GLfloat) 0.000000, (GLfloat) 0.773010,
+       (GLfloat) 0.471397, (GLfloat) 0.000000, (GLfloat) 0.881921,
+       (GLfloat) 0.290285, (GLfloat) 0.000000, (GLfloat) 0.956940,
+       (GLfloat) 0.098017, (GLfloat) 0.000000, (GLfloat) 0.995185,
+       (GLfloat) - 0.098017, (GLfloat) 0.000000, (GLfloat) 0.995185,
+       (GLfloat) - 0.290285, (GLfloat) 0.000000, (GLfloat) 0.956940,
+       (GLfloat) - 0.471397, (GLfloat) 0.000000, (GLfloat) 0.881921,
+       (GLfloat) - 0.634393, (GLfloat) 0.000000, (GLfloat) 0.773010,
+       (GLfloat) - 0.773010, (GLfloat) 0.000000, (GLfloat) 0.634393,
+       (GLfloat) - 0.881921, (GLfloat) 0.000000, (GLfloat) 0.471397,
+       (GLfloat) - 0.956940, (GLfloat) 0.000000, (GLfloat) 0.290285,
+       (GLfloat) - 0.995185, (GLfloat) - 0.000000, (GLfloat) 0.098017,
+       (GLfloat) - 0.995185, (GLfloat) - 0.000000, (GLfloat) - 0.098017,
+       (GLfloat) - 0.956940, (GLfloat) - 0.000000, (GLfloat) - 0.290285,
+       (GLfloat) - 0.881921, (GLfloat) - 0.000000, (GLfloat) - 0.471397,
+       (GLfloat) - 0.773010, (GLfloat) - 0.000000, (GLfloat) - 0.634393,
+       (GLfloat) - 0.634393, (GLfloat) - 0.000000, (GLfloat) - 0.773010,
+       (GLfloat) - 0.471397, (GLfloat) - 0.000000, (GLfloat) - 0.881921,
+       (GLfloat) - 0.290285, (GLfloat) - 0.000000, (GLfloat) - 0.956940,
+       (GLfloat) - 0.098017, (GLfloat) - 0.000000, (GLfloat) - 0.995185,
+       (GLfloat) - 0.000000, (GLfloat) - 1.000000, (GLfloat) - 0.000000,
+};
+
+static unsigned short int ElbowCoins_POLS[] =
+{
+       32, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82,
+ 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 1, 4, 96, 97, 65, 64, 1,
+   4, 97, 98, 66, 65, 1, 4, 98, 99, 67, 66, 1, 4, 99, 100, 68, 67, 1, 4, 100,
+       101, 69, 68, 1, 4, 101, 102, 70, 69, 1, 4, 102, 103, 71, 70, 1, 4, 103, 104, 72,
+71, 1, 4, 104, 105, 73, 72, 1, 4, 105, 106, 74, 73, 1, 4, 106, 107, 75, 74, 1,
+       4, 107, 108, 76, 75, 1, 4, 108, 109, 77, 76, 1, 4, 109, 110, 78, 77, 1, 4, 110,
+       111, 79, 78, 1, 4, 111, 112, 80, 79, 1, 4, 112, 113, 81, 80, 1, 4, 113, 114, 82,
+81, 1, 4, 114, 115, 83, 82, 1, 4, 115, 116, 84, 83, 1, 4, 116, 117, 85, 84, 1,
+       4, 117, 118, 86, 85, 1, 4, 118, 119, 87, 86, 1, 4, 119, 120, 88, 87, 1, 4, 120,
+       121, 89, 88, 1, 4, 121, 122, 90, 89, 1, 4, 122, 123, 91, 90, 1, 4, 123, 124, 92,
+91, 1, 4, 124, 125, 93, 92, 1, 4, 125, 126, 94, 93, 1, 4, 126, 127, 95, 94, 1,
+       4, 127, 96, 64, 95, 1, 32, 96, 127, 126, 125, 124, 123, 122, 121, 120, 119, 118, 117, 116,
+       115, 114, 113, 112, 111, 110, 109, 108, 107, 106, 105, 104, 103, 102, 101, 100, 99, 98, 97, 1,
+       32, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
+   19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 1, 4, 32, 33, 1, 0, 1,
+       4, 33, 34, 2, 1, 1, 4, 34, 35, 3, 2, 1, 4, 35, 36, 4, 3, 1, 4, 36,
+       37, 5, 4, 1, 4, 37, 38, 6, 5, 1, 4, 38, 39, 7, 6, 1, 4, 39, 40, 8,
+       7, 1, 4, 40, 41, 9, 8, 1, 4, 41, 42, 10, 9, 1, 4, 42, 43, 11, 10, 1,
+     4, 43, 44, 12, 11, 1, 4, 44, 45, 13, 12, 1, 4, 45, 46, 14, 13, 1, 4, 46,
+    47, 15, 14, 1, 4, 47, 48, 16, 15, 1, 4, 48, 49, 17, 16, 1, 4, 49, 50, 18,
+     17, 1, 4, 50, 51, 19, 18, 1, 4, 51, 52, 20, 19, 1, 4, 52, 53, 21, 20, 1,
+     4, 53, 54, 22, 21, 1, 4, 54, 55, 23, 22, 1, 4, 55, 56, 24, 23, 1, 4, 56,
+    57, 25, 24, 1, 4, 57, 58, 26, 25, 1, 4, 58, 59, 27, 26, 1, 4, 59, 60, 28,
+     27, 1, 4, 60, 61, 29, 28, 1, 4, 61, 62, 30, 29, 1, 4, 62, 63, 31, 30, 1,
+ 4, 63, 32, 0, 31, 1, 32, 32, 63, 62, 61, 60, 59, 58, 57, 56, 55, 54, 53, 52,
+51, 50, 49, 48, 47, 46, 45, 44, 43, 42, 41, 40, 39, 38, 37, 36, 35, 34, 33, 1,
+       0
+};
+
+struct lwo  LWO_ElbowCoins =
+{
+       128,                    /* number of points */
+       ElbowCoins_PNTS, ElbowCoins_normals, ElbowCoins_POLS, 0L
+};
+
+#endif /* MODE_pipes */
+
+/* End of pipeobjs.c */
diff --git a/xlockmore-4.14/modes/glx/pipes.c b/xlockmore-4.14/modes/glx/pipes.c
new file mode 100644 (file)
index 0000000..35af28a
--- /dev/null
@@ -0,0 +1,1037 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* pipes --- 3D selfbuiding pipe system */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)pipes.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * This program was inspired on a WindowsNT(R)'s screen saver. It was written 
+ * from scratch and it was not based on any other source code.
+ *
+ * ==========================================================================
+ * The routine myElbow is derivated from the doughnut routine from the MesaGL
+ * library (more especifically the Mesaaux library) written by Brian Paul.
+ * ==========================================================================
+ *
+ * Thanks goes to Brian Paul for making it possible and inexpensive to use
+ * OpenGL at home.
+ *
+ * Since I'm not a native English speaker, my apologies for any grammatical
+ * mistake.
+ *
+ * My e-mail addresses is
+ * m-vianna@usa.net
+ *
+ * Marcelo F. Vianna (Apr-09-1997)
+ *
+ * Revision History:
+ * 29-Apr-97: Factory equipment by Ed Mackey.  Productive day today, eh?
+ * 29-Apr-97: Less tight turns Jeff Epler <jepler@inetnebr.com>
+ * 29-Apr-97: Efficiency speed-ups by Marcelo F. Vianna
+ */
+
+/*-
+ * due to a Bug/feature in VMS X11/Intrinsic.h has to be placed before xlock.
+ * otherwise caddr_t is not defined correctly
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Pipes"
+#define HACK_INIT init_pipes
+#define HACK_DRAW draw_pipes
+#define pipes_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: 2 \n" \
+ "*cycles: 5 \n" \
+ "*size: 500 \n" \
+ "*fisheye: True \n" \
+ "*tightturns: False \n" \
+ "*rotatepipes: True \n" \
+ "*noBuffer: True \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_pipes
+
+#include <GL/glu.h>
+#include "buildlwo.h"
+
+#define DEF_FACTORY     "2"
+#define DEF_FISHEYE     "True"
+#define DEF_TIGHTTURNS  "False"
+#define DEF_ROTATEPIPES "True"
+#define NofSysTypes     3
+
+static int  factory;
+static Bool fisheye, tightturns, rotatepipes;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-factory", ".pipes.factory", XrmoptionSepArg, (caddr_t) NULL},
+       {"-fisheye", ".pipes.fisheye", XrmoptionNoArg, (caddr_t) "on"},
+       {"+fisheye", ".pipes.fisheye", XrmoptionNoArg, (caddr_t) "off"},
+       {"-tightturns", ".pipes.tightturns", XrmoptionNoArg, (caddr_t) "on"},
+       {"+tightturns", ".pipes.tightturns", XrmoptionNoArg, (caddr_t) "off"},
+      {"-rotatepipes", ".pipes.rotatepipes", XrmoptionNoArg, (caddr_t) "on"},
+      {"+rotatepipes", ".pipes.rotatepipes", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & factory, "factory", "Factory", DEF_FACTORY, t_Int},
+       {(caddr_t *) & fisheye, "fisheye", "Fisheye", DEF_FISHEYE, t_Bool},
+       {(caddr_t *) & tightturns, "tightturns", "Tightturns", DEF_TIGHTTURNS, t_Bool},
+       {(caddr_t *) & rotatepipes, "rotatepipes", "Rotatepipes", DEF_ROTATEPIPES, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-factory num", "how much extra equipment in pipes (0 for none)"},
+       {"-/+fisheye", "turn on/off zoomed-in view of pipes"},
+       {"-/+tightturns", "turn on/off tight turns"},
+       {"-/+rotatepipes", "turn on/off pipe system rotation per screenful"}
+};
+
+ModeSpecOpt pipes_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   pipes_description =
+{"pipes", "init_pipes", "draw_pipes", "release_pipes",
+#if defined( MESA ) && defined( SLOW )
+ "draw_pipes",
+#else
+ "change_pipes",
+#endif
+ "change_pipes", NULL, &pipes_opts,
+ 1000, 2, 5, 500, 4, 1.0, "",
+ "Shows a selfbuilding pipe system", 0, NULL};
+
+#endif
+
+#define Scale4Window               0.1
+#define Scale4Iconic               0.07
+
+#define one_third                  0.3333333333333333333
+
+#define dirNone -1
+#define dirUP 0
+#define dirDOWN 1
+#define dirLEFT 2
+#define dirRIGHT 3
+#define dirNEAR 4
+#define dirFAR 5
+
+#define HCELLS 33
+#define VCELLS 25
+#define DEFINEDCOLORS 7
+#define elbowradius 0.5
+
+/*************************************************************************/
+
+typedef struct {
+#if defined( MESA ) && defined( SLOW )
+       int         flip;
+#endif
+       GLint       WindH, WindW;
+       int         Cells[HCELLS][VCELLS][HCELLS];
+       int         usedcolors[DEFINEDCOLORS];
+       int         directions[6];
+       int         ndirections;
+       int         nowdir, olddir;
+       int         system_number;
+       int         counter;
+       int         PX, PY, PZ;
+       int         number_of_systems;
+       int         system_type;
+       int         system_length;
+       int         turncounter;
+       Window      window;
+       float      *system_color;
+       GLfloat     initial_rotation;
+       GLuint      valve, bolts, betweenbolts, elbowbolts, elbowcoins;
+       GLuint      guagehead, guageface, guagedial, guageconnector;
+       GLXContext *glx_context;
+} pipesstruct;
+
+extern struct lwo LWO_BigValve, LWO_PipeBetweenBolts, LWO_Bolts3D;
+extern struct lwo LWO_GuageHead, LWO_GuageFace, LWO_GuageDial, LWO_GuageConnector;
+extern struct lwo LWO_ElbowBolts, LWO_ElbowCoins;
+
+static float front_shininess[] =
+{60.0};
+static float front_specular[] =
+{0.7, 0.7, 0.7, 1.0};
+static float ambient0[] =
+{0.4, 0.4, 0.4, 1.0};
+static float diffuse0[] =
+{1.0, 1.0, 1.0, 1.0};
+static float ambient1[] =
+{0.2, 0.2, 0.2, 1.0};
+static float diffuse1[] =
+{0.5, 0.5, 0.5, 1.0};
+static float position0[] =
+{1.0, 1.0, 1.0, 0.0};
+static float position1[] =
+{-1.0, -1.0, 1.0, 0.0};
+static float lmodel_ambient[] =
+{0.5, 0.5, 0.5, 1.0};
+static float lmodel_twoside[] =
+{GL_TRUE};
+
+static float MaterialRed[] =
+{0.7, 0.0, 0.0, 1.0};
+static float MaterialGreen[] =
+{0.1, 0.5, 0.2, 1.0};
+static float MaterialBlue[] =
+{0.0, 0.0, 0.7, 1.0};
+static float MaterialCyan[] =
+{0.2, 0.5, 0.7, 1.0};
+static float MaterialYellow[] =
+{0.7, 0.7, 0.0, 1.0};
+static float MaterialMagenta[] =
+{0.6, 0.2, 0.5, 1.0};
+static float MaterialWhite[] =
+{0.7, 0.7, 0.7, 1.0};
+static float MaterialGray[] =
+{0.2, 0.2, 0.2, 1.0};
+
+static pipesstruct *pipes = NULL;
+
+
+static void
+MakeTube(int direction)
+{
+       float       an;
+       float       SINan_3, COSan_3;
+
+       /*dirUP    = 00000000 */
+       /*dirDOWN  = 00000001 */
+       /*dirLEFT  = 00000010 */
+       /*dirRIGHT = 00000011 */
+       /*dirNEAR  = 00000100 */
+       /*dirFAR   = 00000101 */
+
+       if (!(direction & 4)) {
+               glRotatef(90.0, (direction & 2) ? 0.0 : 1.0,
+                         (direction & 2) ? 1.0 : 0.0, 0.0);
+       }
+       glBegin(GL_QUAD_STRIP);
+       for (an = 0.0; an <= 2.0 * M_PI; an += M_PI / 12.0) {
+               glNormal3f((COSan_3 = cos(an) / 3.0), (SINan_3 = sin(an) / 3.0), 0.0);
+               glVertex3f(COSan_3, SINan_3, one_third);
+               glVertex3f(COSan_3, SINan_3, -one_third);
+       }
+       glEnd();
+}
+
+static void
+mySphere(float radius)
+{
+       GLUquadricObj *quadObj;
+
+       quadObj = gluNewQuadric();
+       gluQuadricDrawStyle(quadObj, (GLenum) GLU_FILL);
+       gluSphere(quadObj, radius, 16, 16);
+       gluDeleteQuadric(quadObj);
+}
+
+static void
+myElbow(ModeInfo * mi, int bolted)
+{
+#define nsides 25
+#define rings 25
+#define r one_third
+#define R one_third
+
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+
+       int         i, j;
+       GLfloat     p0[3], p1[3], p2[3], p3[3];
+       GLfloat     n0[3], n1[3], n2[3], n3[3];
+       GLfloat     COSphi, COSphi1, COStheta, COStheta1;
+       GLfloat     _SINtheta, _SINtheta1;
+
+       for (i = 0; i <= rings / 4; i++) {
+               GLfloat     theta, theta1;
+
+               theta = (GLfloat) i *2.0 * M_PI / rings;
+
+               theta1 = (GLfloat) (i + 1) * 2.0 * M_PI / rings;
+               for (j = 0; j < nsides; j++) {
+                       GLfloat     phi, phi1;
+
+                       phi = (GLfloat) j *2.0 * M_PI / nsides;
+
+                       phi1 = (GLfloat) (j + 1) * 2.0 * M_PI / nsides;
+
+                       p0[0] = (COStheta = cos(theta)) * (R + r * (COSphi = cos(phi)));
+                       p0[1] = (_SINtheta = -sin(theta)) * (R + r * COSphi);
+
+                       p1[0] = (COStheta1 = cos(theta1)) * (R + r * COSphi);
+                       p1[1] = (_SINtheta1 = -sin(theta1)) * (R + r * COSphi);
+
+                       p2[0] = COStheta1 * (R + r * (COSphi1 = cos(phi1)));
+                       p2[1] = _SINtheta1 * (R + r * COSphi1);
+
+                       p3[0] = COStheta * (R + r * COSphi1);
+                       p3[1] = _SINtheta * (R + r * COSphi1);
+
+                       n0[0] = COStheta * COSphi;
+                       n0[1] = _SINtheta * COSphi;
+
+                       n1[0] = COStheta1 * COSphi;
+                       n1[1] = _SINtheta1 * COSphi;
+
+                       n2[0] = COStheta1 * COSphi1;
+                       n2[1] = _SINtheta1 * COSphi1;
+
+                       n3[0] = COStheta * COSphi1;
+                       n3[1] = _SINtheta * COSphi1;
+
+                       p0[2] = p1[2] = r * (n0[2] = n1[2] = sin(phi));
+                       p2[2] = p3[2] = r * (n2[2] = n3[2] = sin(phi1));
+
+                       glBegin(GL_QUADS);
+                       glNormal3fv(n3);
+                       glVertex3fv(p3);
+                       glNormal3fv(n2);
+                       glVertex3fv(p2);
+                       glNormal3fv(n1);
+                       glVertex3fv(p1);
+                       glNormal3fv(n0);
+                       glVertex3fv(p0);
+                       glEnd();
+               }
+       }
+
+       if (factory > 0 && bolted) {
+               /* Bolt the elbow onto the pipe system */
+               glFrontFace(GL_CW);
+               glPushMatrix();
+               glRotatef(90.0, 0.0, 0.0, -1.0);
+               glRotatef(90.0, 0.0, 1.0, 0.0);
+               glTranslatef(0.0, one_third, one_third);
+               glCallList(pp->elbowcoins);
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+               glCallList(pp->elbowbolts);
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, pp->system_color);
+               glPopMatrix();
+               glFrontFace(GL_CCW);
+       }
+#undef r
+#undef R
+#undef nsides
+#undef rings
+}
+
+static void
+FindNeighbors(ModeInfo * mi)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+
+       pp->ndirections = 0;
+       pp->directions[dirUP] = (!pp->Cells[pp->PX][pp->PY + 1][pp->PZ]) ? 1 : 0;
+       pp->ndirections += pp->directions[dirUP];
+       pp->directions[dirDOWN] = (!pp->Cells[pp->PX][pp->PY - 1][pp->PZ]) ? 1 : 0;
+       pp->ndirections += pp->directions[dirDOWN];
+       pp->directions[dirLEFT] = (!pp->Cells[pp->PX - 1][pp->PY][pp->PZ]) ? 1 : 0;
+       pp->ndirections += pp->directions[dirLEFT];
+       pp->directions[dirRIGHT] = (!pp->Cells[pp->PX + 1][pp->PY][pp->PZ]) ? 1 : 0;
+       pp->ndirections += pp->directions[dirRIGHT];
+       pp->directions[dirFAR] = (!pp->Cells[pp->PX][pp->PY][pp->PZ - 1]) ? 1 : 0;
+       pp->ndirections += pp->directions[dirFAR];
+       pp->directions[dirNEAR] = (!pp->Cells[pp->PX][pp->PY][pp->PZ + 1]) ? 1 : 0;
+       pp->ndirections += pp->directions[dirNEAR];
+}
+
+static int
+SelectNeighbor(ModeInfo * mi)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+       int         dirlist[6];
+       int         i, j;
+
+       for (i = 0, j = 0; i < 6; i++) {
+               if (pp->directions[i]) {
+                       dirlist[j] = i;
+                       j++;
+               }
+       }
+
+       return dirlist[NRAND(pp->ndirections)];
+}
+
+static void
+MakeValve(ModeInfo * mi, int newdir)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+
+       /* There is a glPopMatrix() right after this subroutine returns. */
+       switch (newdir) {
+               case dirUP:
+               case dirDOWN:
+                       glRotatef(90.0, 1.0, 0.0, 0.0);
+                       glRotatef(NRAND(3) * 90.0, 0.0, 0.0, 1.0);
+                       break;
+               case dirLEFT:
+               case dirRIGHT:
+                       glRotatef(90.0, 0.0, -1.0, 0.0);
+                       glRotatef((NRAND(3) * 90.0) - 90.0, 0.0, 0.0, 1.0);
+                       break;
+               case dirNEAR:
+               case dirFAR:
+                       glRotatef(NRAND(4) * 90.0, 0.0, 0.0, 1.0);
+                       break;
+       }
+       glFrontFace(GL_CW);
+       glCallList(pp->betweenbolts);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+       glCallList(pp->bolts);
+       if (!MI_IS_MONO(mi)) {
+               if (pp->system_color == MaterialRed) {
+                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, NRAND(2) ? MaterialYellow : MaterialBlue);
+               } else if (pp->system_color == MaterialBlue) {
+                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, NRAND(2) ? MaterialRed : MaterialYellow);
+               } else if (pp->system_color == MaterialYellow) {
+                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, NRAND(2) ? MaterialBlue : MaterialRed);
+               } else {
+                       switch ((NRAND(3))) {
+                               case 0:
+                                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialRed);
+                                       break;
+                               case 1:
+                                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialBlue);
+                                       break;
+                               case 2:
+                                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialYellow);
+                       }
+               }
+       }
+       glRotatef((GLfloat) (NRAND(90)), 1.0, 0.0, 0.0);
+       glCallList(pp->valve);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, pp->system_color);
+       glFrontFace(GL_CCW);
+}
+
+static int
+MakeGuage(ModeInfo * mi, int newdir)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+
+       /* Can't have a guage on a vertical pipe. */
+       if ((newdir == dirUP) || (newdir == dirDOWN))
+               return (0);
+
+       /* Is there space above this pipe for a guage? */
+       if (!pp->directions[dirUP])
+               return (0);
+
+       /* Yes!  Mark the space as used. */
+       pp->Cells[pp->PX][pp->PY + 1][pp->PZ] = 1;
+
+       glFrontFace(GL_CW);
+       glPushMatrix();
+       if ((newdir == dirLEFT) || (newdir == dirRIGHT))
+               glRotatef(90.0, 0.0, 1.0, 0.0);
+       glCallList(pp->betweenbolts);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+       glCallList(pp->bolts);
+       glPopMatrix();
+
+       glCallList(pp->guageconnector);
+       glPushMatrix();
+       glTranslatef(0.0, 1.33333, 0.0);
+       /* Do not change the above to 1 + ONE_THIRD, because */
+       /* the object really is centered on 1.3333300000. */
+       glRotatef(NRAND(270) + 45.0, 0.0, 0.0, -1.0);
+       /* Random rotation for the dial.  I love it. */
+       glCallList(pp->guagedial);
+       glPopMatrix();
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, pp->system_color);
+       glCallList(pp->guagehead);
+
+       /* GuageFace is drawn last, in case of low-res depth buffers. */
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialWhite);
+       glCallList(pp->guageface);
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, pp->system_color);
+       glFrontFace(GL_CCW);
+
+       return (1);
+}
+
+static void
+MakeShape(ModeInfo * mi, int newdir)
+{
+       switch (NRAND(2)) {
+               case 1:
+                       if (!MakeGuage(mi, newdir))
+                               MakeTube(newdir);
+                       break;
+               default:
+                       MakeValve(mi, newdir);
+                       break;
+       }
+}
+
+static void
+reshape(ModeInfo * mi, int width, int height)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+
+       glViewport(0, 0, pp->WindW = (GLint) width, pp->WindH = (GLint) height);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       /*glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 15.0); */
+       gluPerspective(65.0, (GLfloat) width / (GLfloat) height, 0.1, 20.0);
+       glMatrixMode(GL_MODELVIEW);
+}
+
+static void
+pinit(ModeInfo * mi, int zera)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+       int         X, Y, Z;
+
+       glClearDepth(1.0);
+       glClearColor(0.0, 0.0, 0.0, 1.0);
+       glColor3f(1.0, 1.0, 1.0);
+
+       glLightfv(GL_LIGHT0, GL_AMBIENT, ambient0);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse0);
+       glLightfv(GL_LIGHT0, GL_POSITION, position0);
+       glLightfv(GL_LIGHT1, GL_AMBIENT, ambient1);
+       glLightfv(GL_LIGHT1, GL_DIFFUSE, diffuse1);
+       glLightfv(GL_LIGHT1, GL_POSITION, position1);
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lmodel_ambient);
+       glLightModelfv(GL_LIGHT_MODEL_TWO_SIDE, lmodel_twoside);
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+       glEnable(GL_LIGHT1);
+       glEnable(GL_DEPTH_TEST);
+       glEnable(GL_NORMALIZE);
+       glEnable(GL_CULL_FACE);
+
+       glShadeModel(GL_SMOOTH);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, front_shininess);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, front_specular);
+
+       if (zera) {
+               pp->system_number = 1;
+               glDrawBuffer(GL_FRONT_AND_BACK);
+               glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+               (void) memset(pp->Cells, 0, sizeof (pp->Cells));
+               for (X = 0; X < HCELLS; X++) {
+                       for (Y = 0; Y < VCELLS; Y++) {
+                               pp->Cells[X][Y][0] = 1;
+                               pp->Cells[X][Y][HCELLS - 1] = 1;
+                               pp->Cells[0][Y][X] = 1;
+                               pp->Cells[HCELLS - 1][Y][X] = 1;
+                       }
+               }
+               for (X = 0; X < HCELLS; X++) {
+                       for (Z = 0; Z < HCELLS; Z++) {
+                               pp->Cells[X][0][Z] = 1;
+                               pp->Cells[X][VCELLS - 1][Z] = 1;
+                       }
+               }
+               (void) memset(pp->usedcolors, 0, sizeof (pp->usedcolors));
+               if ((pp->initial_rotation += 10.0) > 45.0) {
+                       pp->initial_rotation -= 90.0;
+               }
+       }
+       pp->counter = 0;
+       pp->turncounter = 0;
+
+       if (!MI_IS_MONO(mi)) {
+               int         collist[DEFINEDCOLORS];
+               int         i, j, lower = 1000;
+
+               /* Avoid repeating colors on the same screen unless necessary */
+               for (i = 0; i < DEFINEDCOLORS; i++) {
+                       if (lower > pp->usedcolors[i])
+                               lower = pp->usedcolors[i];
+               }
+               for (i = 0, j = 0; i < DEFINEDCOLORS; i++) {
+                       if (pp->usedcolors[i] == lower) {
+                               collist[j] = i;
+                               j++;
+                       }
+               }
+               i = collist[NRAND(j)];
+               pp->usedcolors[i]++;
+               switch (i) {
+                       case 0:
+                               pp->system_color = MaterialRed;
+                               break;
+                       case 1:
+                               pp->system_color = MaterialGreen;
+                               break;
+                       case 2:
+                               pp->system_color = MaterialBlue;
+                               break;
+                       case 3:
+                               pp->system_color = MaterialCyan;
+                               break;
+                       case 4:
+                               pp->system_color = MaterialYellow;
+                               break;
+                       case 5:
+                               pp->system_color = MaterialMagenta;
+                               break;
+                       case 6:
+                               pp->system_color = MaterialWhite;
+                               break;
+               }
+       } else {
+               pp->system_color = MaterialGray;
+       }
+
+       do {
+               pp->PX = NRAND((HCELLS - 1)) + 1;
+               pp->PY = NRAND((VCELLS - 1)) + 1;
+               pp->PZ = NRAND((HCELLS - 1)) + 1;
+       } while (pp->Cells[pp->PX][pp->PY][pp->PZ] ||
+                (pp->Cells[pp->PX + 1][pp->PY][pp->PZ] && pp->Cells[pp->PX - 1][pp->PY][pp->PZ] &&
+                 pp->Cells[pp->PX][pp->PY + 1][pp->PZ] && pp->Cells[pp->PX][pp->PY - 1][pp->PZ] &&
+                 pp->Cells[pp->PX][pp->PY][pp->PZ + 1] && pp->Cells[pp->PX][pp->PY][pp->PZ - 1]));
+       pp->Cells[pp->PX][pp->PY][pp->PZ] = 1;
+       pp->olddir = dirNone;
+
+       FindNeighbors(mi);
+
+       pp->nowdir = SelectNeighbor(mi);
+}
+
+void
+init_pipes(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       pipesstruct *pp;
+
+       if (pipes == NULL) {
+               if ((pipes = (pipesstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (pipesstruct))) == NULL)
+                       return;
+       }
+       pp = &pipes[screen];
+
+       pp->window = MI_WINDOW(mi);
+       if ((pp->glx_context = init_GL(mi)) != NULL) {
+
+               reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+               pp->initial_rotation = -10.0;
+               pinit(mi, 1);
+
+               if (factory > 0) {
+                       pp->valve = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_BigValve);
+                       pp->bolts = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_Bolts3D);
+                       pp->betweenbolts = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_PipeBetweenBolts);
+
+                       pp->elbowbolts = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_ElbowBolts);
+                       pp->elbowcoins = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_ElbowCoins);
+
+                       pp->guagehead = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_GuageHead);
+                       pp->guageface = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_GuageFace);
+                       pp->guagedial = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_GuageDial);
+                       pp->guageconnector = BuildLWO(MI_IS_WIREFRAME(mi), &LWO_GuageConnector);
+               }
+               /* else they are all 0, thanks to calloc(). */
+
+               if (MI_COUNT(mi) < 1 || MI_COUNT(mi) > NofSysTypes + 1) {
+                       pp->system_type = NRAND(NofSysTypes) + 1;
+               } else {
+                       pp->system_type = MI_COUNT(mi);
+               }
+
+               if (MI_CYCLES(mi) > 0 && MI_CYCLES(mi) < 11) {
+                       pp->number_of_systems = MI_CYCLES(mi);
+               } else {
+                       pp->number_of_systems = 5;
+               }
+
+               if (MI_SIZE(mi) < 10) {
+                       pp->system_length = 10;
+               } else if (MI_SIZE(mi) > 1000) {
+                       pp->system_length = 1000;
+               } else {
+                       pp->system_length = MI_SIZE(mi);
+               }
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_pipes(ModeInfo * mi)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       int         newdir;
+       int         OPX, OPY, OPZ;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!pp->glx_context)
+               return;
+
+       glXMakeCurrent(display, window, *(pp->glx_context));
+
+#if defined( MESA ) && defined( SLOW )
+       glDrawBuffer(GL_BACK);
+#else
+       glDrawBuffer(GL_FRONT);
+#endif
+       glPushMatrix();
+
+       glTranslatef(0.0, 0.0, fisheye ? -3.8 : -4.8);
+       if (rotatepipes)
+               glRotatef(pp->initial_rotation, 0.0, 1.0, 0.0);
+
+       if (!MI_IS_ICONIC(mi)) {
+               /* Width/height ratio handled by gluPerspective() now. */
+               glScalef(Scale4Window, Scale4Window, Scale4Window);
+       } else {
+               glScalef(Scale4Iconic, Scale4Iconic, Scale4Iconic);
+       }
+
+       FindNeighbors(mi);
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, pp->system_color);
+
+       /* If it's the begining of a system, draw a sphere */
+       if (pp->olddir == dirNone) {
+               glPushMatrix();
+               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0);
+               mySphere(0.6);
+               glPopMatrix();
+       }
+       /* Check for stop conditions */
+       if (pp->ndirections == 0 || pp->counter > pp->system_length) {
+               glPushMatrix();
+               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0);
+               /* Finish the system with another sphere */
+               mySphere(0.6);
+#if defined( MESA ) && defined( SLOW )
+               glXSwapBuffers(display, window);
+#endif
+               glPopMatrix();
+
+               /* If the maximum number of system was drawn, restart (clearing the screen), */
+               /* else start a new system. */
+               if (++pp->system_number > pp->number_of_systems) {
+                       (void) sleep(1);
+                       pinit(mi, 1);
+               } else {
+                       pinit(mi, 0);
+               }
+
+               glPopMatrix();
+               return;
+       }
+       pp->counter++;
+       pp->turncounter++;
+
+       /* Do will the direction change? if so, determine the new one */
+       newdir = pp->nowdir;
+       if (!pp->directions[newdir]) {  /* cannot proceed in the current direction */
+               newdir = SelectNeighbor(mi);
+       } else {
+               if (tightturns) {
+                       /* random change (20% chance) */
+                       if ((pp->counter > 1) && (NRAND(100) < 20)) {
+                               newdir = SelectNeighbor(mi);
+                       }
+               } else {
+                       /* Chance to turn increases after each length of pipe drawn */
+                       if ((pp->counter > 1) && NRAND(50) < NRAND(pp->turncounter + 1)) {
+                               newdir = SelectNeighbor(mi);
+                               pp->turncounter = 0;
+                       }
+               }
+       }
+
+       /* Has the direction changed? */
+       if (newdir == pp->nowdir) {
+               /* If not, draw the cell's center pipe */
+               glPushMatrix();
+               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0);
+               /* Chance of factory shape here, if enabled. */
+               if ((pp->counter > 1) && (NRAND(100) < factory)) {
+                       MakeShape(mi, newdir);
+               } else {
+                       MakeTube(newdir);
+               }
+               glPopMatrix();
+       } else {
+               /* If so, draw the cell's center elbow/sphere */
+               int         sysT = pp->system_type;
+
+               if (sysT == NofSysTypes + 1) {
+                       sysT = ((pp->system_number - 1) % NofSysTypes) + 1;
+               }
+               glPushMatrix();
+
+               switch (sysT) {
+                       case 1:
+                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0);
+                               mySphere(elbowradius);
+                               break;
+                       case 2:
+                       case 3:
+                               switch (pp->nowdir) {
+                                       case dirUP:
+                                               switch (newdir) {
+                                                       case dirLEFT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               glRotatef(180.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                                       case dirRIGHT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               glRotatef(180.0, 1.0, 0.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirFAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(90.0, 0.0, 1.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 0.0, 1.0);
+                                                               break;
+                                                       case dirNEAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(90.0, 0.0, 1.0, 0.0);
+                                                               glRotatef(180.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                               }
+                                               break;
+                                       case dirDOWN:
+                                               switch (newdir) {
+                                                       case dirLEFT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               break;
+                                                       case dirRIGHT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               glRotatef(180.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirFAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(270.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirNEAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(90.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                               }
+                                               break;
+                                       case dirLEFT:
+                                               switch (newdir) {
+                                                       case dirUP:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               glRotatef(180.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirDOWN:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               glRotatef(180.0, 1.0, 0.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirFAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(270.0, 1.0, 0.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirNEAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(270.0, 1.0, 0.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 0.0, 1.0);
+                                                               break;
+                                               }
+                                               break;
+                                       case dirRIGHT:
+                                               switch (newdir) {
+                                                       case dirUP:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               break;
+                                                       case dirDOWN:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0);
+                                                               glRotatef(180.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                                       case dirFAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(270.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                                       case dirNEAR:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(90.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                               }
+                                               break;
+                                       case dirNEAR:
+                                               switch (newdir) {
+                                                       case dirLEFT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(270.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                                       case dirRIGHT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(270.0, 1.0, 0.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirUP:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(270.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirDOWN:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0 - (one_third));
+                                                               glRotatef(90.0, 0.0, 1.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 0.0, 1.0);
+                                                               break;
+                                               }
+                                               break;
+                                       case dirFAR:
+                                               switch (newdir) {
+                                                       case dirUP:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 + (one_third), (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(90.0, 0.0, 1.0, 0.0);
+                                                               break;
+                                                       case dirDOWN:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0, (pp->PY - 12) / 3.0 * 4.0 - (one_third), (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(90.0, 0.0, 1.0, 0.0);
+                                                               glRotatef(180.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                                       case dirLEFT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 - (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(90.0, 1.0, 0.0, 0.0);
+                                                               break;
+                                                       case dirRIGHT:
+                                                               glTranslatef((pp->PX - 16) / 3.0 * 4.0 + (one_third), (pp->PY - 12) / 3.0 * 4.0, (pp->PZ - 16) / 3.0 * 4.0 + (one_third));
+                                                               glRotatef(270.0, 1.0, 0.0, 0.0);
+                                                               glRotatef(180.0, 0.0, 0.0, 1.0);
+                                                               break;
+                                               }
+                                               break;
+                               }
+                               myElbow(mi, (sysT == 2));
+                               break;
+               }
+               glPopMatrix();
+       }
+
+       OPX = pp->PX;
+       OPY = pp->PY;
+       OPZ = pp->PZ;
+       pp->olddir = pp->nowdir;
+       pp->nowdir = newdir;
+       switch (pp->nowdir) {
+               case dirUP:
+                       pp->PY++;
+                       break;
+               case dirDOWN:
+                       pp->PY--;
+                       break;
+               case dirLEFT:
+                       pp->PX--;
+                       break;
+               case dirRIGHT:
+                       pp->PX++;
+                       break;
+               case dirNEAR:
+                       pp->PZ++;
+                       break;
+               case dirFAR:
+                       pp->PZ--;
+                       break;
+       }
+       pp->Cells[pp->PX][pp->PY][pp->PZ] = 1;
+
+       /* Cells'face pipe */
+       glTranslatef(((pp->PX + OPX) / 2.0 - 16) / 3.0 * 4.0, ((pp->PY + OPY) / 2.0 - 12) / 3.0 * 4.0, ((pp->PZ + OPZ) / 2.0 - 16) / 3.0 * 4.0);
+       MakeTube(newdir);
+
+       glPopMatrix();
+
+       glFlush();
+
+#if defined( MESA ) && defined( SLOW )
+       pp->flip = !pp->flip;
+       if (pp->flip)
+               glXSwapBuffers(display, window);
+#endif
+}
+
+void
+change_pipes(ModeInfo * mi)
+{
+       pipesstruct *pp = &pipes[MI_SCREEN(mi)];
+
+       if (!pp->glx_context)
+               return;
+
+       glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(pp->glx_context));
+       pinit(mi, 1);
+}
+
+void
+release_pipes(ModeInfo * mi)
+{
+       if (pipes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       pipesstruct *pp = &pipes[screen];
+
+                       if (pp->glx_context) {
+
+                               /* Display lists MUST be freed while their glXContext is current. */
+                               glXMakeCurrent(MI_DISPLAY(mi), pp->window, *(pp->glx_context));
+
+                               if (pp->valve)
+                                       glDeleteLists(pp->valve, 1);
+                               if (pp->bolts)
+                                       glDeleteLists(pp->bolts, 1);
+                               if (pp->betweenbolts)
+                                       glDeleteLists(pp->betweenbolts, 1);
+
+                               if (pp->elbowbolts)
+                                       glDeleteLists(pp->elbowbolts, 1);
+                               if (pp->elbowcoins)
+                                       glDeleteLists(pp->elbowcoins, 1);
+
+                               if (pp->guagehead)
+                                       glDeleteLists(pp->guagehead, 1);
+                               if (pp->guageface)
+                                       glDeleteLists(pp->guageface, 1);
+                               if (pp->guagedial)
+                                       glDeleteLists(pp->guagedial, 1);
+                               if (pp->guageconnector)
+                                       glDeleteLists(pp->guageconnector, 1);
+                       }
+               }
+
+               (void) free((void *) pipes);
+               pipes = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/rubik.c b/xlockmore-4.14/modes/glx/rubik.c
new file mode 100644 (file)
index 0000000..ba0d9c0
--- /dev/null
@@ -0,0 +1,2040 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* rubik --- Shows a auto-solving Rubik's cube */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)rubik.c      4.14 99/04/27 xlockmore";
+
+#endif
+
+#undef DEBUG_LISTS
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * This mode shows an auto-solving rubik's cube "puzzle". If somebody
+ * intends to make a game or something based on this code, please let me
+ * know first, my e-mail address is provided in this comment. Marcelo.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * Since I'm not a native English speaker, my apologies for any grammatical
+ * mistake.
+ *
+ * My e-mail address is
+ * m-vianna@usa.net
+ *
+ * Marcelo F. Vianna (Jul-31-1997)
+ *
+ * Revision History:
+ * 27-Apr-99: LxMxN stuff added.
+ * 26-Sep-98: Added some more movement (the cube does not stay in the screen
+ *            center anymore. Also fixed the scale problem imediatelly after
+ *            shuffling when the puzzle is solved.
+ * 08-Aug-97: Now has some internals from xrubik by David Bagley
+ *            This should make it easier to add features.
+ * 02-Aug-97: Now behaves more like puzzle.c: first show the cube being
+ *            shuffled and then being solved. A mode specific option was added:
+ *            "+/-hideshuffling" to provide the original behavior (in which
+ *            only the solution is shown).
+ *            The color labels corners are now rounded.
+ *            Optimized the cubit() routine using glLists.
+ * 01-Aug-97: Shuffling now avoids movements that undoes the previous movement
+ *            and three consecutive identical moves (which is pretty stupid).
+ *            improved the "cycles" option in replacement of David's hack,
+ *            now rp->anglestep is a GLfloat, so this option selects the
+ *            "exact" number of frames that a rotation (movement) takes to
+ *            complete.
+ * 30-Jul-97: Initial release, there is no algorithm to solve the puzzle,
+ *            instead, it randomly shuffle the cube and then make the
+ *            movements in the reverse order.
+ *            The mode was written in 1 day (I got sick and had the day off).
+ *            There was not much to do since I could not leave home... :)
+ *
+ */
+
+/*-
+ * Color labels mapping:
+ * =====================
+ *
+ *                       +------------+
+ *                       |0-->        |
+ *                       ||           |
+ *                       |v           |
+ *                       |   TOP(0)   |
+ *                       |            |
+ *                       |            |
+ *                       |           8|
+ *           +-----------+------------+-----------+
+ *           |0-->       |0-->        |0-->       |
+ *           ||          ||           ||          |
+ *           |v          |v           |v          |
+ *           |  LEFT(1)  |  FRONT(2)  |  RIGHT(3) |
+ *           |           |            |           |
+ *           |           |            |           |
+ *           |          8|           8|          8|
+ *           +-----------+------------+-----------+
+ *                       |0-->        |
+ *                       ||           |
+ *                       |v           |
+ *                       |  BOTTOM(4) |
+ *                       |            |
+ *                       |            |
+ *                       |           8|         +---+---+---+
+ *                       +------------+         |   |   |   |
+ *                       |0-->        |         | 0 | 1 | 2 |
+ *                       ||           |         |---+---+---+
+ *                       |v           |         |  xxxxx(N) |
+ *                       |   BACK(5)  |         | 3 | 4 | 5 |
+ *                       |            |         +---+---+---+
+ *                       |            |         |   |   |   |
+ *                       |           8|         | 6 | 7 | 8 |
+ *                       +------------+         +---+---+---+
+ *
+ *  Map to 3d
+ *  FRONT  => X, Y
+ *  BACK   => X, Y
+ *  LEFT   => Z, Y
+ *  RIGHT  => Z, Y
+ *  TOP    => X, Z
+ *  BOTTOM => X, Z
+ */
+
+/*-
+ * PURIFY 3.0a on SunOS4 reports an unitialized memory read on each of
+ * the glCallList() functions below when using MesaGL 2.1.  This has
+ * been fixed in MesaGL 2.2 and later releases.
+ */
+
+/*-
+ * due to a Bug/feature in VMS X11/Intrinsic.h has to be placed before xlock.
+ * otherwise caddr_t is not defined correctly
+ */
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Rubik"
+#define HACK_INIT init_rubik
+#define HACK_DRAW draw_rubik
+#define rubik_opts xlockmore_opts
+#define DEFAULTS "*delay: 40000 \n" \
+ "*count: -30 \n" \
+ "*cycles: 5 \n" \
+ "*size: -6 \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_rubik
+
+#define DEF_SIZEX     "0"
+#define DEF_SIZEY     "0"
+#define DEF_SIZEZ     "0"
+#define DEF_HIDESHUFFLING     "False"
+
+static int sizex;
+static int sizey;
+static int sizez;
+static Bool hideshuffling;
+
+static XrmOptionDescRec opts[] =
+{
+        {"-sizex", ".rubik.sizex", XrmoptionSepArg, (caddr_t) NULL},
+        {"-sizey", ".rubik.sizey", XrmoptionSepArg, (caddr_t) NULL},
+        {"-sizez", ".rubik.sizez", XrmoptionSepArg, (caddr_t) NULL},
+       {"-hideshuffling", ".rubik.hideshuffling", XrmoptionNoArg, (caddr_t) "on"},
+       {"+hideshuffling", ".rubik.hideshuffling", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & sizex, "sizex", "SizeX", DEF_SIZEX, t_Int},
+       {(caddr_t *) & sizey, "sizey", "SizeY", DEF_SIZEY, t_Int},
+       {(caddr_t *) & sizez, "sizez", "SizeZ", DEF_SIZEZ, t_Int},
+       {(caddr_t *) & hideshuffling, "hideshuffling", "Hideshuffling", DEF_HIDESHUFFLING, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-sizex num", "number of cubies along x axis (overrides size)"},
+       {"-sizey num", "number of cubies along y axis (overrides size)"},
+       {"-sizez num", "number of cubies along z axis (overrides size)"},
+       {"-/+hideshuffling", "turn on/off hidden shuffle phase"}
+};
+
+ModeSpecOpt rubik_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   rubik_description =
+{"rubik", "init_rubik", "draw_rubik", "release_rubik",
+ "draw_rubik", "change_rubik", NULL, &rubik_opts,
+ 10000, -30, 5, -6, 4, 1.0, "",
+ "Shows an auto-solving Rubik's Cube", 0, NULL};
+
+#endif
+
+#define VectMul(X1,Y1,Z1,X2,Y2,Z2) (Y1)*(Z2)-(Z1)*(Y2),(Z1)*(X2)-(X1)*(Z2),(X1)*(Y2)-(Y1)*(X2)
+#define sqr(A)                     ((A)*(A))
+
+#ifndef Pi
+#define Pi                         M_PI
+#endif
+
+
+#define ACTION_SOLVE    1
+#define ACTION_SHUFFLE  0
+
+#define DELAY_AFTER_SHUFFLING  5
+#define DELAY_AFTER_SOLVING   20
+
+/*************************************************************************/
+
+#define MINSIZE 2
+#define MAXSIZEX (rp->sizex)
+#define MAXSIZEY (rp->sizey)
+#define MAXSIZEZ (rp->sizez)
+#define AVSIZE ((rp->sizex+rp->sizey+rp->sizez)/3.0)     /* Use of this should be minimized */
+#define MAXMAXSIZE (MAX(MAXSIZEX,MAX(MAXSIZEY,MAXSIZEZ)))
+#define MAXSIZEXY (MAXSIZEX*MAXSIZEY)
+#define MAXSIZEYZ (MAXSIZEY*MAXSIZEZ)
+#define MAXSIZEZX (MAXSIZEZ*MAXSIZEX)
+#define LASTX (MAXSIZEX-1)
+#define LASTY (MAXSIZEY-1)
+#define LASTZ (MAXSIZEZ-1)
+/* These are not likely to change but... */
+#define FIRSTX 0
+#define FIRSTY 0
+#define FIRSTZ 0
+
+#define Scale4Window               (0.9/AVSIZE)
+#define Scale4Iconic               (2.1/AVSIZE)
+
+#define MAXORIENT 4            /* Number of orientations of a square */
+#define MAXFACES 6             /* Number of faces */
+
+/* Directions relative to the face of a cubie */
+#define TOP 0
+#define RIGHT 1
+#define BOTTOM 2
+#define LEFT 3
+#define CW (MAXORIENT+1)
+#define HALF (MAXORIENT+2)
+#define CCW (2*MAXORIENT-1)
+
+#define TOP_FACE 0
+#define LEFT_FACE 1
+#define FRONT_FACE 2
+#define RIGHT_FACE 3
+#define BOTTOM_FACE 4
+#define BACK_FACE 5
+#define NO_FACE (MAXFACES)
+#define NO_ROTATION (2*MAXORIENT)
+#define NO_DEPTH MAXMAXSIZE
+
+#define REVX(a) (MAXSIZEX - a - 1)
+#define REVY(a) (MAXSIZEY - a - 1)
+#define REVZ(a) (MAXSIZEZ - a - 1)
+
+typedef struct _RubikLoc {
+       int         face;
+       int         rotation;   /* Not used yet */
+} RubikLoc;
+
+typedef struct _RubikRowNext {
+       int         face, direction, sideFace;
+} RubikRowNext;
+
+typedef struct _RubikMove {
+       int         face, direction;
+       int         position;
+} RubikMove;
+
+typedef struct _RubikSlice {
+       int         face, rotation;
+       int         depth;
+} RubikSlice;
+
+/*-
+ * Pick a face and a direction on face the next face and orientation
+ * is then known.
+ */
+static RubikLoc slideNextRow[MAXFACES][MAXORIENT] =
+{
+       {
+               {5, TOP},
+               {3, RIGHT},
+               {2, TOP},
+               {1, LEFT}},
+       {
+               {0, RIGHT},
+               {2, TOP},
+               {4, LEFT},
+               {5, BOTTOM}},
+       {
+               {0, TOP},
+               {3, TOP},
+               {4, TOP},
+               {1, TOP}},
+       {
+               {0, LEFT},
+               {5, BOTTOM},
+               {4, RIGHT},
+               {2, TOP}},
+       {
+               {2, TOP},
+               {3, LEFT},
+               {5, TOP},
+               {1, RIGHT}},
+       {
+               {4, TOP},
+               {3, BOTTOM},
+               {0, TOP},
+               {1, BOTTOM}}
+};
+
+/*-
+ * Examine cubie 0 on each face, its 4 movements (well only 2 since the
+ * other 2 will be opposites) and translate it into slice movements).
+ * CW = DEEP Depth CCW == SHALLOW Depth with reference to faces 0, 1, and 2
+ */
+static RubikLoc rotateSlice[MAXFACES][MAXORIENT / 2] =
+{
+       {
+               {1, CCW},
+               {2, CW},
+       },
+       {
+               {2, CW},
+               {0, CCW},
+       },
+       {
+               {1, CCW},
+               {0, CCW},
+       },
+       {
+               {2, CCW},
+               {0, CCW},
+       },
+       {
+               {1, CCW},
+               {2, CCW},
+       },
+       {
+               {1, CCW},
+               {0, CW},
+       }
+};
+
+/*-
+ * Rotate face clockwise by a number of orients, then the top of the
+ * face then points to this face
+ */
+static int  rowToRotate[MAXFACES][MAXORIENT] =
+{
+       {3, 2, 1, 5},
+       {2, 4, 5, 0},
+       {3, 4, 1, 0},
+       {5, 4, 2, 0},
+       {3, 5, 1, 2},
+       {3, 0, 1, 4}
+};
+
+/* 
+ * This translates a clockwise move to something more manageable
+ */
+static RubikRowNext rotateToRow[MAXFACES] =    /*CW to min face */
+{
+       {1, LEFT, TOP},
+       {0, BOTTOM, RIGHT},
+       {0, RIGHT, BOTTOM},
+       {0, TOP, LEFT},
+       {1, RIGHT, BOTTOM},
+       {0, LEFT, TOP}
+};
+
+typedef struct {
+       GLint       WindH, WindW;
+       GLfloat     step;
+       RubikMove  *moves;
+       int         storedmoves;
+       int         degreeTurn;
+       int         shufflingmoves;
+       int         sizex, sizey, sizez;
+       float       avsize, avsizeSq;
+       int         action;
+       int         done;
+       GLfloat     anglestep;
+       RubikLoc   *cubeLoc[MAXFACES];
+       RubikLoc   *rowLoc[MAXORIENT];
+       RubikMove   movement;
+       GLfloat     rotatestep;
+       GLfloat     PX, PY, VX, VY;
+       GLXContext *glx_context;
+       int         AreObjectsDefined[1];
+} rubikstruct;
+
+static float front_shininess[] =
+{60.0};
+static float front_specular[] =
+{0.7, 0.7, 0.7, 1.0};
+static float ambient[] =
+{0.0, 0.0, 0.0, 1.0};
+static float diffuse[] =
+{1.0, 1.0, 1.0, 1.0};
+static float position0[] =
+{1.0, 1.0, 1.0, 0.0};
+static float position1[] =
+{-1.0, -1.0, 1.0, 0.0};
+static float lmodel_ambient[] =
+{0.5, 0.5, 0.5, 1.0};
+static float lmodel_twoside[] =
+{GL_TRUE};
+
+static float MaterialRed[] =
+{0.5, 0.0, 0.0, 1.0};
+static float MaterialGreen[] =
+{0.0, 0.5, 0.0, 1.0};
+static float MaterialBlue[] =
+{0.0, 0.0, 0.5, 1.0};
+static float MaterialYellow[] =
+{0.7, 0.7, 0.0, 1.0};
+static float MaterialOrange[] =
+{0.9, 0.45, 0.36, 1.0};
+
+#if 0
+static float MaterialMagenta[] =
+{0.7, 0.0, 0.7, 1.0};
+static float MaterialCyan[] =
+{0.0, 0.7, 0.7, 1.0};
+
+#endif
+static float MaterialWhite[] =
+{0.8, 0.8, 0.8, 1.0};
+static float MaterialGray[] =
+{0.2, 0.2, 0.2, 1.0};
+static float MaterialGray3[] =
+{0.3, 0.3, 0.3, 1.0};
+static float MaterialGray4[] =
+{0.4, 0.4, 0.4, 1.0};
+static float MaterialGray5[] =
+{0.5, 0.5, 0.5, 1.0};
+static float MaterialGray6[] =
+{0.6, 0.6, 0.6, 1.0};
+static float MaterialGray7[] =
+{0.7, 0.7, 0.7, 1.0};
+
+static rubikstruct *rubik = NULL;
+static GLuint objects = 0;
+
+#define ObjCubit        0
+
+static void
+pickcolor(int C, int mono)
+{
+       switch (C) {
+               case TOP_FACE:
+                       if (mono)
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray3);
+                       else
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialRed);
+                       break;
+               case LEFT_FACE:
+                       if (mono)
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray6);
+                       else
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialYellow);
+                       break;
+               case FRONT_FACE:
+                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialWhite);
+                       break;
+               case RIGHT_FACE:
+                       if (mono)
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray4);
+                       else
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGreen);
+                       break;
+               case BOTTOM_FACE:
+                       if (mono)
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray7);
+                       else
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialOrange);
+                       break;
+               case BACK_FACE:
+                       if (mono)
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray5);
+                       else
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialBlue);
+                       break;
+#if 0
+                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialCyan);
+                       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialMagenta);
+#endif
+       }
+}
+
+static void
+faceSizes(rubikstruct * rp, int face, int * sizeOfRow, int * sizeOfColumn)
+{
+       switch (face) {
+               case 0: /* TOP */
+               case 4: /* BOTTOM */
+                       *sizeOfRow = MAXSIZEX;
+                       *sizeOfColumn = MAXSIZEZ;
+                       break;
+               case 1: /* LEFT */
+               case 3: /* RIGHT */
+                       *sizeOfRow = MAXSIZEZ;
+                       *sizeOfColumn = MAXSIZEY;
+                       break;
+               case 2: /* FRONT */
+               case 5: /* BACK */
+                       *sizeOfRow = MAXSIZEX;
+                       *sizeOfColumn = MAXSIZEY;
+                       break;
+       }
+}
+
+static Bool
+checkFaceSquare(rubikstruct * rp, int face)
+{
+       int sizeOfRow, sizeOfColumn;
+
+       faceSizes(rp, face, &sizeOfRow, &sizeOfColumn);
+       return (sizeOfRow == sizeOfColumn);
+       /* Cubes can be made square with a 4x2 face where 90 degree turns
+         * should be permitted but that is kind of complicated for me.
+         * This can be done in 2 ways where the side of the cubies are
+         * the same size and one where one side (the side with half the
+         * number of cubies) is twice the size of the other.  The first is
+         * complicated because faces of cubies can go under other faces.
+         * The second way is similar to "banded cubes" where scotch tape
+         * restricts the moves of some cubes.  Here you have to keep track
+         * of the restrictions and show banded cubies graphically as one
+         * cube.
+         */
+}
+
+static int
+sizeFace(rubikstruct * rp, int face)
+{
+       int sizeOfRow, sizeOfColumn;
+
+       faceSizes(rp, face, &sizeOfRow, &sizeOfColumn);
+       return (sizeOfRow * sizeOfColumn);
+}
+
+static int
+sizeRow(rubikstruct * rp, int face)
+{
+       int sizeOfRow, sizeOfColumn;
+
+       faceSizes(rp, face, &sizeOfRow, &sizeOfColumn);
+       return sizeOfRow;
+}
+
+static void
+draw_cubit(ModeInfo * mi,
+          int back, int front, int left, int right, int bottom, int top)
+{
+       rubikstruct *rp = &rubik[MI_SCREEN(mi)];
+       int         mono = MI_IS_MONO(mi);
+
+       if (!rp->AreObjectsDefined[ObjCubit]) {
+               glNewList(objects + ObjCubit, GL_COMPILE_AND_EXECUTE);
+               glBegin(GL_QUADS);
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+               glNormal3f(0.00, 0.00, 1.00);
+               glVertex3f(-0.45, -0.45, 0.50);
+               glVertex3f(0.45, -0.45, 0.50);
+               glVertex3f(0.45, 0.45, 0.50);
+               glVertex3f(-0.45, 0.45, 0.50);
+               glNormal3f(0.00, 0.00, -1.00);
+               glVertex3f(-0.45, 0.45, -0.50);
+               glVertex3f(0.45, 0.45, -0.50);
+               glVertex3f(0.45, -0.45, -0.50);
+               glVertex3f(-0.45, -0.45, -0.50);
+               glNormal3f(-1.00, 0.00, 0.00);
+               glVertex3f(-0.50, -0.45, 0.45);
+               glVertex3f(-0.50, 0.45, 0.45);
+               glVertex3f(-0.50, 0.45, -0.45);
+               glVertex3f(-0.50, -0.45, -0.45);
+               glNormal3f(1.00, 0.00, 0.00);
+               glVertex3f(0.50, -0.45, -0.45);
+               glVertex3f(0.50, 0.45, -0.45);
+               glVertex3f(0.50, 0.45, 0.45);
+               glVertex3f(0.50, -0.45, 0.45);
+               glNormal3f(0.00, -1.00, 0.00);
+               glVertex3f(0.45, -0.50, -0.45);
+               glVertex3f(0.45, -0.50, 0.45);
+               glVertex3f(-0.45, -0.50, 0.45);
+               glVertex3f(-0.45, -0.50, -0.45);
+               glNormal3f(0.00, 1.00, 0.00);
+               glVertex3f(-0.45, 0.50, -0.45);
+               glVertex3f(-0.45, 0.50, 0.45);
+               glVertex3f(0.45, 0.50, 0.45);
+               glVertex3f(0.45, 0.50, -0.45);
+               glNormal3f(-1.00, -1.00, 0.00);
+               glVertex3f(-0.45, -0.50, -0.45);
+               glVertex3f(-0.45, -0.50, 0.45);
+               glVertex3f(-0.50, -0.45, 0.45);
+               glVertex3f(-0.50, -0.45, -0.45);
+               glNormal3f(1.00, 1.00, 0.00);
+               glVertex3f(0.45, 0.50, -0.45);
+               glVertex3f(0.45, 0.50, 0.45);
+               glVertex3f(0.50, 0.45, 0.45);
+               glVertex3f(0.50, 0.45, -0.45);
+               glNormal3f(-1.00, 1.00, 0.00);
+               glVertex3f(-0.50, 0.45, -0.45);
+               glVertex3f(-0.50, 0.45, 0.45);
+               glVertex3f(-0.45, 0.50, 0.45);
+               glVertex3f(-0.45, 0.50, -0.45);
+               glNormal3f(1.00, -1.00, 0.00);
+               glVertex3f(0.50, -0.45, -0.45);
+               glVertex3f(0.50, -0.45, 0.45);
+               glVertex3f(0.45, -0.50, 0.45);
+               glVertex3f(0.45, -0.50, -0.45);
+               glNormal3f(0.00, -1.00, -1.00);
+               glVertex3f(-0.45, -0.45, -0.50);
+               glVertex3f(0.45, -0.45, -0.50);
+               glVertex3f(0.45, -0.50, -0.45);
+               glVertex3f(-0.45, -0.50, -0.45);
+               glNormal3f(0.00, 1.00, 1.00);
+               glVertex3f(-0.45, 0.45, 0.50);
+               glVertex3f(0.45, 0.45, 0.50);
+               glVertex3f(0.45, 0.50, 0.45);
+               glVertex3f(-0.45, 0.50, 0.45);
+               glNormal3f(0.00, -1.00, 1.00);
+               glVertex3f(-0.45, -0.50, 0.45);
+               glVertex3f(0.45, -0.50, 0.45);
+               glVertex3f(0.45, -0.45, 0.50);
+               glVertex3f(-0.45, -0.45, 0.50);
+               glNormal3f(0.00, 1.00, -1.00);
+               glVertex3f(-0.45, 0.50, -0.45);
+               glVertex3f(0.45, 0.50, -0.45);
+               glVertex3f(0.45, 0.45, -0.50);
+               glVertex3f(-0.45, 0.45, -0.50);
+               glNormal3f(-1.00, 0.00, -1.00);
+               glVertex3f(-0.50, -0.45, -0.45);
+               glVertex3f(-0.50, 0.45, -0.45);
+               glVertex3f(-0.45, 0.45, -0.50);
+               glVertex3f(-0.45, -0.45, -0.50);
+               glNormal3f(1.00, 0.00, 1.00);
+               glVertex3f(0.50, -0.45, 0.45);
+               glVertex3f(0.50, 0.45, 0.45);
+               glVertex3f(0.45, 0.45, 0.50);
+               glVertex3f(0.45, -0.45, 0.50);
+               glNormal3f(1.00, 0.00, -1.00);
+               glVertex3f(0.45, -0.45, -0.50);
+               glVertex3f(0.45, 0.45, -0.50);
+               glVertex3f(0.50, 0.45, -0.45);
+               glVertex3f(0.50, -0.45, -0.45);
+               glNormal3f(-1.00, 0.00, 1.00);
+               glVertex3f(-0.45, -0.45, 0.50);
+               glVertex3f(-0.45, 0.45, 0.50);
+               glVertex3f(-0.50, 0.45, 0.45);
+               glVertex3f(-0.50, -0.45, 0.45);
+               glEnd();
+               glBegin(GL_TRIANGLES);
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialGray);
+               glNormal3f(1.00, 1.00, 1.00);
+               glVertex3f(0.45, 0.45, 0.50);
+               glVertex3f(0.50, 0.45, 0.45);
+               glVertex3f(0.45, 0.50, 0.45);
+               glNormal3f(-1.00, -1.00, -1.00);
+               glVertex3f(-0.45, -0.50, -0.45);
+               glVertex3f(-0.50, -0.45, -0.45);
+               glVertex3f(-0.45, -0.45, -0.50);
+               glNormal3f(-1.00, 1.00, 1.00);
+               glVertex3f(-0.45, 0.45, 0.50);
+               glVertex3f(-0.45, 0.50, 0.45);
+               glVertex3f(-0.50, 0.45, 0.45);
+               glNormal3f(1.00, -1.00, -1.00);
+               glVertex3f(0.50, -0.45, -0.45);
+               glVertex3f(0.45, -0.50, -0.45);
+               glVertex3f(0.45, -0.45, -0.50);
+               glNormal3f(1.00, -1.00, 1.00);
+               glVertex3f(0.45, -0.45, 0.50);
+               glVertex3f(0.45, -0.50, 0.45);
+               glVertex3f(0.50, -0.45, 0.45);
+               glNormal3f(-1.00, 1.00, -1.00);
+               glVertex3f(-0.50, 0.45, -0.45);
+               glVertex3f(-0.45, 0.50, -0.45);
+               glVertex3f(-0.45, 0.45, -0.50);
+               glNormal3f(-1.00, -1.00, 1.00);
+               glVertex3f(-0.45, -0.45, 0.50);
+               glVertex3f(-0.50, -0.45, 0.45);
+               glVertex3f(-0.45, -0.50, 0.45);
+               glNormal3f(1.00, 1.00, -1.00);
+               glVertex3f(0.50, 0.45, -0.45);
+               glVertex3f(0.45, 0.45, -0.50);
+               glVertex3f(0.45, 0.50, -0.45);
+               glEnd();
+               glEndList();
+               rp->AreObjectsDefined[ObjCubit] = 1;
+#ifdef DEBUG_LISTS
+               (void) printf("Cubit drawn SLOWLY\n");
+#endif
+       } else {
+               glCallList(objects + ObjCubit);
+#ifdef DEBUG_LISTS
+               (void) printf("Cubit drawn quickly\n");
+#endif
+       }
+
+       if (back != NO_FACE) {
+               glBegin(GL_POLYGON);
+               pickcolor(back, mono);
+               glNormal3f(0.00, 0.00, -1.00);
+               glVertex3f(-0.35, 0.40, -0.51);
+               glVertex3f(0.35, 0.40, -0.51);
+               glVertex3f(0.40, 0.35, -0.51);
+               glVertex3f(0.40, -0.35, -0.51);
+               glVertex3f(0.35, -0.40, -0.51);
+               glVertex3f(-0.35, -0.40, -0.51);
+               glVertex3f(-0.40, -0.35, -0.51);
+               glVertex3f(-0.40, 0.35, -0.51);
+               glEnd();
+       }
+       if (front != NO_FACE) {
+               glBegin(GL_POLYGON);
+               pickcolor(front, mono);
+               glNormal3f(0.00, 0.00, 1.00);
+               glVertex3f(-0.35, -0.40, 0.51);
+               glVertex3f(0.35, -0.40, 0.51);
+               glVertex3f(0.40, -0.35, 0.51);
+               glVertex3f(0.40, 0.35, 0.51);
+               glVertex3f(0.35, 0.40, 0.51);
+               glVertex3f(-0.35, 0.40, 0.51);
+               glVertex3f(-0.40, 0.35, 0.51);
+               glVertex3f(-0.40, -0.35, 0.51);
+               glEnd();
+       }
+       if (left != NO_FACE) {
+               glBegin(GL_POLYGON);
+               pickcolor(left, mono);
+               glNormal3f(-1.00, 0.00, 0.00);
+               glVertex3f(-0.51, -0.35, 0.40);
+               glVertex3f(-0.51, 0.35, 0.40);
+               glVertex3f(-0.51, 0.40, 0.35);
+               glVertex3f(-0.51, 0.40, -0.35);
+               glVertex3f(-0.51, 0.35, -0.40);
+               glVertex3f(-0.51, -0.35, -0.40);
+               glVertex3f(-0.51, -0.40, -0.35);
+               glVertex3f(-0.51, -0.40, 0.35);
+               glEnd();
+       }
+       if (right != NO_FACE) {
+               glBegin(GL_POLYGON);
+               pickcolor(right, mono);
+               glNormal3f(1.00, 0.00, 0.00);
+               glVertex3f(0.51, -0.35, -0.40);
+               glVertex3f(0.51, 0.35, -0.40);
+               glVertex3f(0.51, 0.40, -0.35);
+               glVertex3f(0.51, 0.40, 0.35);
+               glVertex3f(0.51, 0.35, 0.40);
+               glVertex3f(0.51, -0.35, 0.40);
+               glVertex3f(0.51, -0.40, 0.35);
+               glVertex3f(0.51, -0.40, -0.35);
+               glEnd();
+       }
+       if (bottom != NO_FACE) {
+               glBegin(GL_POLYGON);
+               pickcolor(bottom, mono);
+               glNormal3f(0.00, -1.00, 0.00);
+               glVertex3f(0.40, -0.51, -0.35);
+               glVertex3f(0.40, -0.51, 0.35);
+               glVertex3f(0.35, -0.51, 0.40);
+               glVertex3f(-0.35, -0.51, 0.40);
+               glVertex3f(-0.40, -0.51, 0.35);
+               glVertex3f(-0.40, -0.51, -0.35);
+               glVertex3f(-0.35, -0.51, -0.40);
+               glVertex3f(0.35, -0.51, -0.40);
+               glEnd();
+       }
+       if (top != NO_FACE) {
+               glBegin(GL_POLYGON);
+               pickcolor(top, mono);
+               glNormal3f(0.00, 1.00, 0.00);
+               glVertex3f(-0.40, 0.51, -0.35);
+               glVertex3f(-0.40, 0.51, 0.35);
+               glVertex3f(-0.35, 0.51, 0.40);
+               glVertex3f(0.35, 0.51, 0.40);
+               glVertex3f(0.40, 0.51, 0.35);
+               glVertex3f(0.40, 0.51, -0.35);
+               glVertex3f(0.35, 0.51, -0.40);
+               glVertex3f(-0.35, 0.51, -0.40);
+               glEnd();
+       }
+}
+
+/* Convert move to weird general notation */
+static void
+convertMove(rubikstruct * rp, RubikMove move, RubikSlice * slice)
+{
+       RubikLoc    plane;
+       int         sizeOfRow, sizeOfColumn;
+
+       plane = rotateSlice[(int) move.face][move.direction % 2];
+       (*slice).face = plane.face;
+       (*slice).rotation = plane.rotation;
+
+       faceSizes(rp, move.face, &sizeOfRow, &sizeOfColumn);
+       if (plane.face == 1 || /* VERTICAL */
+           (plane.face == 2 && (move.face == 1 || move.face == 3))) {
+               if ((*slice).rotation == CW)
+                       (*slice).depth = sizeOfRow - 1 - move.position %
+                               sizeOfRow;
+               else
+                       (*slice).depth = move.position % sizeOfRow;
+       } else { /* (plane.face == 0 ||  *//* HORIZONTAL *//*
+                    (plane.face == 2 && (move.face == 0 || move.face == 4))) */
+               if ((*slice).rotation == CW)
+                       (*slice).depth = sizeOfColumn - 1 - move.position /
+                               sizeOfRow;
+               else
+                       (*slice).depth = move.position / sizeOfRow;
+       }
+       /* If (*slice).depth = 0 then face 0, face 1, or face 2 moves */
+       if (move.direction / 2)
+               (*slice).rotation = ((*slice).rotation == CW) ? CCW : CW;
+}
+
+/* Assume for the moment that the size is at least 2 */
+static void
+draw_cube(ModeInfo * mi)
+{
+#define S1 1
+#define SX ((GLint)S1*(MAXSIZEX-1))
+#define SY ((GLint)S1*(MAXSIZEY-1))
+#define SZ ((GLint)S1*(MAXSIZEZ-1))
+#define HALFX (((GLfloat)MAXSIZEX-1.0)/2.0)
+#define HALFY (((GLfloat)MAXSIZEY-1.0)/2.0)
+#define HALFZ (((GLfloat)MAXSIZEZ-1.0)/2.0)
+#define MIDX(a) (((GLfloat)(2*a-MAXSIZEX+1))/2.0)
+#define MIDY(a) (((GLfloat)(2*a-MAXSIZEY+1))/2.0)
+#define MIDZ(a) (((GLfloat)(2*a-MAXSIZEZ+1))/2.0)
+       rubikstruct *rp = &rubik[MI_SCREEN(mi)];
+       RubikSlice  slice;
+       GLfloat     rotatestep;
+       int         i, j, k;
+
+       if (rp->movement.face == NO_FACE) {
+               slice.face = NO_FACE;
+               slice.rotation = NO_ROTATION;
+               slice.depth = NO_DEPTH;
+       } else {
+               convertMove(rp, rp->movement, &slice);
+       }
+       rotatestep = (slice.rotation == CCW) ? rp->rotatestep : -rp->rotatestep;
+
+
+/*-
+ * The glRotatef() routine transforms the coordinate system for every future
+ * vertex specification (this is not so simple, but by now comprehending this
+ * is sufficient). So if you want to rotate the inner slice, you can draw
+ * one slice, rotate the anglestep for the centerslice, draw the inner slice,
+ * rotate reversely and draw the other slice.
+ * There is a sequence for drawing cubies for each axis being moved...
+ */
+       switch (slice.face) {
+               case NO_FACE:
+               case TOP_FACE:  /* BOTTOM_FACE too */
+                       glPushMatrix();
+                       if (slice.depth == MAXSIZEY - 1)
+                               glRotatef(rotatestep, 0, HALFY, 0);
+
+                       glTranslatef(-HALFX, -HALFY, -HALFZ);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                  rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * LASTZ].face, NO_FACE);
+                       for (k = 1; k < MAXSIZEZ - 1; k++) {
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * LASTY].face, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                       }
+                       glTranslatef(0, 0, S1);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * LASTY].face,
+                                  rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       for (i = 1; i < MAXSIZEX - 1; i++) {
+                               glTranslatef(S1, 0, -SZ);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][i + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * LASTZ].face, NO_FACE);
+                               for (k = 1; k < MAXSIZEZ - 1; k++) {
+                                       glTranslatef(0, 0, S1);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                               }
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * LASTY].face,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       }
+                       glTranslatef(1, 0, -SZ);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * LASTY].face,
+                                  rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * LASTZ].face, NO_FACE);
+                       for (k = 1; k < MAXSIZEZ - 1; k++) {
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * LASTY].face,
+                                          rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                       }
+                       glTranslatef(0, 0, S1);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * LASTY].face,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * LASTY].face,
+                                  rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       glPopMatrix();
+                       for (j = 1; j < MAXSIZEY - 1; j++) {
+                               glPushMatrix();
+                               if (slice.depth == REVY(j))
+                                       glRotatef(rotatestep, 0, HALFY, 0);
+                               glTranslatef(-HALFX, MIDY(j), -HALFZ);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * j].face, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                          NO_FACE, NO_FACE);
+                               for (k = 1; k < MAXSIZEZ - 1; k++) {
+                                       glTranslatef(0, 0, S1);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * REVY(j)].face,
+                                          rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                          NO_FACE, NO_FACE);
+                               for (i = 1; i < MAXSIZEX - 1; i++) {
+                                       glTranslatef(1, 0, -SZ);
+                                       draw_cubit(mi,
+                                                  rp->cubeLoc[BACK_FACE][i + MAXSIZEX * j].face, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                                       /* Center */
+                                       glTranslatef(0, 0, SZ);
+                                       draw_cubit(mi,
+                                                  NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * REVY(j)].face,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(S1, 0, -SZ);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * j].face, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * REVY(j)].face,
+                                          NO_FACE, NO_FACE);
+                               for (k = 1; k < MAXSIZEZ - 1; k++) {
+                                       glTranslatef(0, 0, S1);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * REVY(j)].face,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * REVY(j)].face,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * REVY(j)].face,
+                                          NO_FACE, NO_FACE);
+                               glPopMatrix();
+                       }
+                       if (slice.depth == 0)
+                               glRotatef(rotatestep, 0, HALFY, 0);
+
+                       glTranslatef(-HALFX, HALFY, -HALFZ);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * FIRSTZ].face);
+                       for (k = 1; k < MAXSIZEZ - 1; k++) {
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * k].face);
+                       }
+                       glTranslatef(0, 0, S1);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * FIRSTY].face,
+                                  rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * LASTZ].face);
+                       for (i = 1; i < MAXSIZEX - 1; i++) {
+                               glTranslatef(S1, 0, -SZ);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][i + MAXSIZEX * LASTY].face, NO_FACE,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * FIRSTZ].face);
+                               for (k = 1; k < MAXSIZEZ - 1; k++) {
+                                       glTranslatef(0, 0, S1);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * k].face);
+                               }
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * FIRSTY].face,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * LASTZ].face);
+                       }
+                       glTranslatef(S1, 0, -SZ);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * LASTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * FIRSTZ].face);
+                       for (k = 1; k < MAXSIZEZ - 1; k++) {
+                               glTranslatef(0, 0, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * FIRSTY].face,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * k].face);
+                       }
+                       glTranslatef(0, 0, S1);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * LASTZ].face);
+                       break;
+               case LEFT_FACE: /* RIGHT_FACE too */
+                       /* rotatestep is negative because the RIGHT face is the default here */
+                       glPushMatrix();
+                       if (slice.depth == 0)
+                               glRotatef(-rotatestep, HALFX, 0, 0);
+
+                       glTranslatef(-HALFX, -HALFY, -HALFZ);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                  rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * LASTZ].face, NO_FACE);
+                       for (j = 1; j < MAXSIZEY - 1; j++) {
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * j].face, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                          NO_FACE, NO_FACE);
+                       }
+                       glTranslatef(0, S1, 0);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * FIRSTZ].face);
+                       for (k = 1; k < MAXSIZEZ - 1; k++) {
+                               glTranslatef(0, -SY, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * LASTY].face, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                               for (j = 1; j < MAXSIZEY - 1; j++) {
+                                       glTranslatef(0, S1, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * k].face);
+                       }
+                       glTranslatef(0, -SY, S1);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * LASTY].face,
+                                  rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       for (j = 1; j < MAXSIZEY - 1; j++) {
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * REVY(j)].face,
+                                          rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                          NO_FACE, NO_FACE);
+                       }
+                       glTranslatef(0, S1, 0);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * FIRSTY].face,
+                                  rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * LASTZ].face);
+                       glPopMatrix();
+                       for (i = 1; i < MAXSIZEX - 1; i++) {
+                               glPushMatrix();
+                               if (slice.depth == i)
+                                       glRotatef(-rotatestep, HALFX, 0, 0);
+                               glTranslatef(MIDX(i), -HALFY, -HALFZ);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][i + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * LASTZ].face, NO_FACE);
+                               for (j = 1; j < MAXSIZEY - 1; j++) {
+                                       glTranslatef(0, S1, 0);
+                                       draw_cubit(mi,
+                                                  rp->cubeLoc[BACK_FACE][i + MAXSIZEX * j].face, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][i + MAXSIZEX * LASTY].face, NO_FACE,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * FIRSTZ].face);
+                               for (k = 1; k < MAXSIZEZ - 1; k++) {
+                                       glTranslatef(0, -SY, S1);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                                       /* Center */
+                                       glTranslatef(0, SY, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * k].face);
+                               }
+                               glTranslatef(0, -SY, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * LASTY].face,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                               for (j = 1; j < MAXSIZEY - 1; j++) {
+                                       glTranslatef(0, S1, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * REVY(j)].face,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * FIRSTY].face,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * LASTZ].face);
+                               glPopMatrix();
+                       }
+                       if (slice.depth == MAXSIZEX - 1)
+                               glRotatef(-rotatestep, HALFX, 0, 0);
+                       glTranslatef(HALFX, -HALFY, -HALFZ);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * LASTY].face,
+                                  rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * LASTZ].face, NO_FACE);
+                       for (j = 1; j < MAXSIZEY - 1; j++) {
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * j].face, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * REVY(j)].face,
+                                          NO_FACE, NO_FACE);
+                       }
+                       glTranslatef(0, S1, 0);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * LASTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * FIRSTZ].face);
+                       for (k = 1; k < MAXSIZEZ - 1; k++) {
+                               glTranslatef(0, -SY, S1);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * LASTY].face,
+                                          rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                               for (j = 1; j < MAXSIZEY - 1; j++) {
+                                       glTranslatef(0, S1, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * REVY(j)].face,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * FIRSTY].face,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * k].face);
+                       }
+                       glTranslatef(0, -SY, S1);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * LASTY].face,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * LASTY].face,
+                                  rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       for (j = 1; j < MAXSIZEY - 1; j++) {
+                               glTranslatef(0, S1, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * REVY(j)].face,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * REVY(j)].face,
+                                          NO_FACE, NO_FACE);
+                       }
+                       glTranslatef(0, S1, 0);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * LASTZ].face);
+                       break;
+               case FRONT_FACE:        /* BACK_FACE too */
+                       glPushMatrix();
+                       if (slice.depth == MAXSIZEZ - 1)
+                               glRotatef(rotatestep, 0, 0, HALFZ);
+
+                       glTranslatef(-HALFX, -HALFY, -HALFZ);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                  rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * LASTZ].face, NO_FACE);
+                       for (i = 1; i < MAXSIZEX - 1; i++) {
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][i + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * LASTZ].face, NO_FACE);
+                       }
+                       glTranslatef(S1, 0, 0);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * LASTY].face,
+                                  rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * LASTZ].face, NO_FACE);
+                       for (j = 1; j < MAXSIZEY - 1; j++) {
+                               glTranslatef(-SX, S1, 0);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * j].face, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                          NO_FACE, NO_FACE);
+                               for (i = 1; i < MAXSIZEX - 1; i++) {
+                                       glTranslatef(S1, 0, 0);
+                                       draw_cubit(mi,
+                                                  rp->cubeLoc[BACK_FACE][i + MAXSIZEX * j].face, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * j].face, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * REVY(j)].face,
+                                          NO_FACE, NO_FACE);
+                       }
+                       glTranslatef(-SX, S1, 0);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][FIRSTX + MAXSIZEX * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[LEFT_FACE][FIRSTZ + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * FIRSTZ].face);
+                       for (i = 1; i < MAXSIZEX - 1; i++) {
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          rp->cubeLoc[BACK_FACE][i + MAXSIZEX * LASTY].face, NO_FACE,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * FIRSTZ].face);
+                       }
+                       glTranslatef(S1, 0, 0);
+                       draw_cubit(mi,
+                                  rp->cubeLoc[BACK_FACE][LASTX + MAXSIZEX * LASTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][LASTZ + MAXSIZEZ * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * FIRSTZ].face);
+                       glPopMatrix();
+                       for (k = 1; k < MAXSIZEZ - 1; k++) {
+                               glPushMatrix();
+                               if (slice.depth == REVZ(k))
+                                       glRotatef(rotatestep, 0, 0, HALFZ);
+                               glTranslatef(-HALFX, -HALFY, MIDZ(k));
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * LASTY].face, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                               for (i = 1; i < MAXSIZEX - 1; i++) {
+                                       glTranslatef(S1, 0, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                               }
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * LASTY].face,
+                                          rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * REVZ(k)].face, NO_FACE);
+                               for (j = 1; j < MAXSIZEY - 1; j++) {
+                                       glTranslatef(-SX, S1, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                                       /* Center */
+                                       glTranslatef(SX, 0, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * REVY(j)].face,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(-SX, S1, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[LEFT_FACE][k + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * k].face);
+                               for (i = 1; i < MAXSIZEX - 1; i++) {
+                                       glTranslatef(S1, 0, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * k].face);
+                               }
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][REVZ(k) + MAXSIZEZ * FIRSTY].face,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * k].face);
+                               glPopMatrix();
+                       }
+                       if (slice.depth == 0)
+                               glRotatef(rotatestep, 0, 0, HALFZ);
+                       glTranslatef(-HALFX, -HALFY, HALFZ);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * LASTY].face,
+                                  rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * LASTY].face, NO_FACE,
+                                  rp->cubeLoc[BOTTOM_FACE][FIRSTX + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       for (i = 1; i < MAXSIZEX - 1; i++) {
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * LASTY].face,
+                                          NO_FACE, NO_FACE,
+                                          rp->cubeLoc[BOTTOM_FACE][i + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       }
+                       glTranslatef(S1, 0, 0);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * LASTY].face,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * LASTY].face,
+                                  rp->cubeLoc[BOTTOM_FACE][LASTX + MAXSIZEX * FIRSTZ].face, NO_FACE);
+                       for (j = 1; j < MAXSIZEY - 1; j++) {
+                               glTranslatef(-SX, S1, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * REVY(j)].face,
+                                          rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * REVY(j)].face, NO_FACE,
+                                          NO_FACE, NO_FACE);
+                               for (i = 1; i < MAXSIZEX - 1; i++) {
+                                       glTranslatef(S1, 0, 0);
+                                       draw_cubit(mi,
+                                                  NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * REVY(j)].face,
+                                                  NO_FACE, NO_FACE,
+                                                  NO_FACE, NO_FACE);
+                               }
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * REVY(j)].face,
+                                          NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * REVY(j)].face,
+                                          NO_FACE, NO_FACE);
+                       }
+                       glTranslatef(-SX, S1, 0);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][FIRSTX + MAXSIZEX * FIRSTY].face,
+                                  rp->cubeLoc[LEFT_FACE][LASTZ + MAXSIZEZ * FIRSTY].face, NO_FACE,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][FIRSTX + MAXSIZEX * LASTZ].face);
+                       for (i = 1; i < MAXSIZEX - 1; i++) {
+                               glTranslatef(S1, 0, 0);
+                               draw_cubit(mi,
+                                          NO_FACE, rp->cubeLoc[FRONT_FACE][i + MAXSIZEX * FIRSTY].face,
+                                          NO_FACE, NO_FACE,
+                                          NO_FACE, rp->cubeLoc[TOP_FACE][i + MAXSIZEX * LASTZ].face);
+                       }
+                       glTranslatef(S1, 0, 0);
+                       draw_cubit(mi,
+                                  NO_FACE, rp->cubeLoc[FRONT_FACE][LASTX + MAXSIZEX * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[RIGHT_FACE][FIRSTZ + MAXSIZEZ * FIRSTY].face,
+                                  NO_FACE, rp->cubeLoc[TOP_FACE][LASTX + MAXSIZEX * LASTZ].face);
+                       break;
+       }
+#undef S1
+}
+
+/* From David Bagley's xrubik.  Used by permission. ;)  */
+static void
+readRC(rubikstruct * rp, int face, int dir, int h, int orient, int size)
+{
+       int         g, sizeOfRow;
+
+       sizeOfRow = sizeRow(rp, face);
+       if (dir == TOP || dir == BOTTOM)
+               for (g = 0; g < size; g++)
+                       rp->rowLoc[orient][g] =
+                               rp->cubeLoc[face][g * sizeOfRow + h];
+       else                    /* dir == RIGHT || dir == LEFT */
+               for (g = 0; g < size; g++)
+                       rp->rowLoc[orient][g] =
+                               rp->cubeLoc[face][h * sizeOfRow + g];
+}
+
+static void
+rotateRC(rubikstruct * rp, int rotate, int orient, int size)
+{
+       int         g;
+
+       for (g = 0; g < size; g++)
+               rp->rowLoc[orient][g].rotation =
+                       (rp->rowLoc[orient][g].rotation + rotate) % MAXORIENT;
+}
+
+static void
+reverseRC(rubikstruct * rp, int orient, int size)
+{
+       int         g;
+       RubikLoc    temp;
+
+       for (g = 0; g < size / 2; g++) {
+               temp = rp->rowLoc[orient][size - 1 - g];
+               rp->rowLoc[orient][size - 1 - g] = rp->rowLoc[orient][g];
+               rp->rowLoc[orient][g] = temp;
+       }
+}
+
+static void
+writeRC(rubikstruct * rp, int face, int dir, int h, int orient, int size)
+{
+       int         g, position, sizeOfRow;
+
+       sizeOfRow = sizeRow(rp, face);
+       if (dir == TOP || dir == BOTTOM) {
+               for (g = 0; g < size; g++) {
+                       position = g * sizeOfRow + h;
+                       rp->cubeLoc[face][position] = rp->rowLoc[orient][g];
+                       /* DrawSquare(face, position); */
+               }
+       } else {                /* dir == RIGHT || dir == LEFT */
+               for (g = 0; g < size; g++) {
+                       position = h * sizeOfRow + g;
+                       rp->cubeLoc[face][position] = rp->rowLoc[orient][g];
+                       /* DrawSquare(face, position); */
+               }
+       }
+}
+
+static void
+rotateFace(rubikstruct * rp, int face, int direction)
+{
+       int         position, i, j, sizeOfRow, sizeOfColumn, sizeOnPlane;
+       RubikLoc   *faceLoc = NULL;
+
+       faceSizes(rp, face, &sizeOfRow, &sizeOfColumn);
+       sizeOnPlane = sizeOfRow * sizeOfColumn;
+       if ((faceLoc = (RubikLoc *) malloc(sizeOnPlane * sizeof (RubikLoc))) == NULL)
+               (void) fprintf(stderr,
+                "Could not allocate memory for rubik face position info\n");
+       /* Read Face */
+       for (position = 0; position < sizeOnPlane; position++)
+               faceLoc[position] = rp->cubeLoc[face][position];
+       /* Write Face */
+       for (position = 0; position < sizeOnPlane; position++) {
+               i = position % sizeOfRow;
+               j = position / sizeOfRow;
+               if (direction == CW)
+                       rp->cubeLoc[face][position] =
+                               faceLoc[(sizeOfRow - i - 1) * sizeOfRow + j];
+               else if (direction == CCW)
+                       rp->cubeLoc[face][position] =
+                               faceLoc[i * sizeOfRow + sizeOfColumn - j - 1];
+               else /* (direction == HALF) */
+                       rp->cubeLoc[face][position] =
+                               faceLoc[sizeOfRow - i - 1 + (sizeOfColumn - j - 1) * sizeOfRow];
+               rp->cubeLoc[face][position].rotation =
+                       (rp->cubeLoc[face][position].rotation +
+                               direction - MAXORIENT) % MAXORIENT;
+               /* DrawSquare(face, position); */
+       }
+       if (faceLoc != NULL)
+               (void) free((void *) faceLoc);
+}
+
+/* Yeah this is big and ugly */
+static void
+slideRC(rubikstruct * rp, int face, int direction, int h, int sizeOnOppAxis,
+       int *newFace, int *newDirection, int *newH,
+       int *rotate, Bool *reverse)
+{
+       *newFace = slideNextRow[face][direction].face;
+       *rotate = slideNextRow[face][direction].rotation;
+       *newDirection = (*rotate + direction) % MAXORIENT;
+       switch (*rotate) {
+               case TOP:
+                       *newH = h;
+                       *reverse = False;
+                       break;
+               case RIGHT:
+                       if (*newDirection == TOP || *newDirection == BOTTOM) {
+                               *newH = sizeOnOppAxis - 1 - h;
+                               *reverse = False;
+                       } else {        /* *newDirection == RIGHT || *newDirection == LEFT */
+                               *newH = h;
+                               *reverse = True;
+                       }
+                               break;
+               case BOTTOM:
+                       *newH = sizeOnOppAxis - 1 - h;
+                       *reverse = True;
+                       break;
+               case LEFT:
+                       if (*newDirection == TOP || *newDirection == BOTTOM) {
+                               *newH = h;
+                               *reverse = True;
+                       } else {        /* *newDirection == RIGHT || *newDirection == LEFT */
+                               *newH = sizeOnOppAxis - 1 - h;
+                               *reverse = False;
+                       }
+                       break;
+               default:
+                       (void) printf("slideRC: rotate %d\n", *rotate);
+       }
+}
+
+static void
+moveRubik(rubikstruct * rp, int face, int direction, int position)
+{
+       int         newFace, newDirection, rotate, reverse = False;
+       int         h, k, newH = 0;
+       int         i, j, sizeOfRow, sizeOfColumn, sizeOnAxis, sizeOnOppAxis;
+
+       faceSizes(rp, face, &sizeOfRow, &sizeOfColumn);
+       if (direction == CW || direction == CCW) {
+               direction = (direction == CCW) ?
+                       (rotateToRow[face].direction + 2) % MAXORIENT :
+                       rotateToRow[face].direction;
+               if (rotateToRow[face].sideFace == RIGHT) {
+                       i = j = sizeOfColumn - 1;
+               } else if (rotateToRow[face].sideFace == BOTTOM) {
+                       i = j = sizeOfRow - 1;
+               } else {
+                       i = j = 0;
+               }
+               face = rotateToRow[face].face;
+               position = j * sizeOfRow + i;
+       }
+       i = position % sizeOfRow;
+       j = position / sizeOfRow;
+       h = (direction == TOP || direction == BOTTOM) ? i : j;
+       if (direction == TOP || direction == BOTTOM) {
+               sizeOnAxis = sizeOfColumn;
+               sizeOnOppAxis = sizeOfRow;
+       } else {
+               sizeOnAxis = sizeOfRow;
+               sizeOnOppAxis = sizeOfColumn;
+       }
+       /* rotate sides CW or CCW or HALF) */
+
+       if (h == sizeOnOppAxis - 1) {
+               newDirection = (direction == TOP || direction == BOTTOM) ?
+                       TOP : RIGHT;
+               if (rp->degreeTurn == 180)
+                       rotateFace(rp, rowToRotate[face][newDirection], HALF);
+               else if (direction == TOP || direction == RIGHT)
+                       rotateFace(rp, rowToRotate[face][newDirection], CW);
+               else            /* direction == BOTTOM || direction == LEFT */
+                       rotateFace(rp, rowToRotate[face][newDirection], CCW);
+       }
+       if (h == 0) {
+               newDirection = (direction == TOP || direction == BOTTOM) ?
+                       BOTTOM : LEFT;
+               if (rp->degreeTurn == 180)
+                       rotateFace(rp, rowToRotate[face][newDirection], HALF);
+               else if (direction == TOP || direction == RIGHT)
+                       rotateFace(rp, rowToRotate[face][newDirection], CCW);
+               else            /* direction == BOTTOM  || direction == LEFT */
+                       rotateFace(rp, rowToRotate[face][newDirection], CW);
+       }
+       /* Slide rows or columns */
+       readRC(rp, face, direction, h, 0, sizeOnAxis);
+       if (rp->degreeTurn == 180) {
+               int sizeOnDepthAxis;
+
+               slideRC(rp, face, direction, h, sizeOnOppAxis,
+                       &newFace, &newDirection, &newH, &rotate, &reverse);
+               sizeOnDepthAxis = sizeFace(rp, newFace) / sizeOnOppAxis;
+               readRC(rp, newFace, newDirection, newH, 1, sizeOnDepthAxis);
+               rotateRC(rp, rotate, 0, sizeOnAxis);
+               if (reverse == True)
+                       reverseRC(rp, 0, sizeOnAxis);
+               face = newFace;
+               direction = newDirection;
+               h = newH;
+               for (k = 2; k <= MAXORIENT + 1; k++) {
+                       slideRC(rp, face, direction, h, sizeOnOppAxis,
+                               &newFace, &newDirection, &newH, &rotate, &reverse);
+                       if (k != MAXORIENT && k != MAXORIENT + 1)
+                               readRC(rp, newFace, newDirection, newH, k,
+                                       (k % 2) ? sizeOnDepthAxis : sizeOnAxis);
+                       rotateRC(rp, rotate, k - 2,
+                                       (k % 2) ? sizeOnDepthAxis : sizeOnAxis);
+                       if (k != MAXORIENT + 1)
+                               rotateRC(rp, rotate, k - 1,
+                                       (k % 2) ? sizeOnAxis : sizeOnDepthAxis);
+                       if (reverse == True) {
+                               reverseRC(rp, k - 2,
+                                       (k % 2) ? sizeOnDepthAxis : sizeOnAxis);
+                               if (k != MAXORIENT + 1)
+                                       reverseRC(rp, k - 1,
+                                               (k % 2) ? sizeOnAxis : sizeOnDepthAxis);
+                       }
+                       writeRC(rp, newFace, newDirection, newH, k - 2,
+                               (k % 2) ? sizeOnDepthAxis : sizeOnAxis);
+                       face = newFace;
+                       direction = newDirection;
+                       h = newH;
+               }
+       } else {
+               for (k = 1; k <= MAXORIENT; k++) {
+                       slideRC(rp, face, direction, h, sizeOnOppAxis,
+                               &newFace, &newDirection, &newH, &rotate, &reverse);
+                       if (k != MAXORIENT)
+                               readRC(rp, newFace, newDirection, newH, k, sizeOnAxis);
+                       rotateRC(rp, rotate, k - 1, sizeOnAxis);
+                       if (reverse == True)
+                               reverseRC(rp, k - 1, sizeOnAxis);
+                       writeRC(rp, newFace, newDirection, newH, k - 1, sizeOnAxis);
+                       face = newFace;
+                       direction = newDirection;
+                       h = newH;
+               }
+       }
+}
+
+#ifdef DEBUG
+void
+printCube(rubikstruct * rp)
+{
+       int         face, position, sizeOfRow, sizeOfColumn;
+
+       for (face = 0; face < MAXFACES; face++) {
+               faceSizes(rp, face, &sizeOfRow, &sizeOfColumn);
+               for (position = 0; position < sizeOfRow * sizeOfColumn; position++) {
+                       (void) printf("%d %d  ", rp->cubeLoc[face][position].face,
+                                     rp->cubeLoc[face][position].rotation);
+                       if (!((position + 1) % sizeOfRow))
+                               (void) printf("\n");
+               }
+               (void) printf("\n");
+       }
+       (void) printf("\n");
+}
+
+#endif
+
+static void
+evalmovement(ModeInfo * mi, RubikMove movement)
+{
+       rubikstruct *rp = &rubik[MI_SCREEN(mi)];
+
+#ifdef DEBUG
+       printCube(rp);
+#endif
+       if (movement.face < 0 || movement.face >= MAXFACES)
+               return;
+
+       moveRubik(rp, movement.face, movement.direction, movement.position);
+
+}
+
+static      Bool
+compare_moves(rubikstruct * rp, RubikMove move1, RubikMove move2, Bool opp)
+{
+       RubikSlice  slice1, slice2;
+
+       convertMove(rp, move1, &slice1);
+       convertMove(rp, move2, &slice2);
+       if (slice1.face == slice2.face &&
+           slice1.depth == slice2.depth) {
+               if (slice1.rotation == slice2.rotation) {       /* CW or CCW */
+                       if (!opp)
+                               return True;
+               } else {
+                       if (opp)
+                               return True;
+               }
+       }
+       return False;
+}
+
+static void
+shuffle(ModeInfo * mi)
+{
+       rubikstruct *rp = &rubik[MI_SCREEN(mi)];
+       int         i, face, position;
+       RubikMove   move;
+
+       if (sizex)
+               i = sizex;
+       else
+               i = MI_SIZE(mi);
+       if (i < -MINSIZE)
+               i = NRAND(-i - MINSIZE + 1) + MINSIZE;
+       else if (i < MINSIZE)
+               i = MINSIZE;
+
+       if (LRAND() % 2 && !sizey && !sizez) { /* Make normal (NxNxN) cubes more likely */
+               MAXSIZEX = MAXSIZEY = MAXSIZEZ = i;
+       } else {
+               MAXSIZEX = i;
+               if (sizey)
+                       i = sizey;
+               else
+                       i = MI_SIZE(mi);
+               if (i < -MINSIZE)
+                       i = NRAND(-i - MINSIZE + 1) + MINSIZE;
+               else if (i < MINSIZE)
+                       i = MINSIZE;
+               if (LRAND() % 2 && !sizez) { /* Make more MxNxN more likely than LxMxN */
+                       MAXSIZEY = MAXSIZEZ = i;
+               } else {
+                       MAXSIZEY = i;
+                       if (sizez)
+                               i = sizez;
+                       else
+                               i = MI_SIZE(mi);
+                       if (i < -MINSIZE)
+                               i = NRAND(-i - MINSIZE + 1) + MINSIZE;
+                       else if (i < MINSIZE)
+                               i = MINSIZE;
+                       MAXSIZEZ = i;
+               }
+       }
+
+       for (face = 0; face < MAXFACES; face++) {
+               if (rp->cubeLoc[face] != NULL)
+                       (void) free((void *) rp->cubeLoc[face]);
+               if ((rp->cubeLoc[face] =
+                 (RubikLoc *) malloc(sizeFace(rp, face) * sizeof (RubikLoc))) == NULL)
+                       (void) fprintf(stderr,
+                               "Could not allocate memory for rubik cube position info\n");
+               for (position = 0; position < sizeFace(rp, face); position++) {
+                       rp->cubeLoc[face][position].face = face;
+                       rp->cubeLoc[face][position].rotation = TOP;
+               }
+       }
+       for (i = 0; i < MAXORIENT; i++) {
+               if (rp->rowLoc[i] != NULL)
+                       (void) free((void *) rp->rowLoc[i]);
+               /* The following is reused so make it the biggest size */
+               if ((rp->rowLoc[i] =
+                    (RubikLoc *) malloc(MAXMAXSIZE * sizeof (RubikLoc))) == NULL)
+                       (void) fprintf(stderr,
+                                      "Could not allocate memory for rubik row position info\n");
+       }
+       rp->storedmoves = MI_COUNT(mi);
+       if (rp->storedmoves < 0) {
+               if (rp->moves != NULL)
+                       (void) free((void *) rp->moves);
+               rp->moves = NULL;
+               rp->storedmoves = NRAND(-rp->storedmoves) + 1;
+       }
+       if ((rp->storedmoves) && (rp->moves == NULL))
+               if ((rp->moves =
+                    (RubikMove *) calloc(rp->storedmoves + 1, sizeof (RubikMove))) == NULL)
+                       (void) fprintf(stderr,
+                       "Could not allocate memory for rubik move buffer\n");
+
+       if (MI_CYCLES(mi) <= 1) {
+               rp->anglestep = 90.0;
+       } else {
+               rp->anglestep = 90.0 / (GLfloat) (MI_CYCLES(mi));
+       }
+
+       for (i = 0; i < rp->storedmoves; i++) {
+               int         condition;
+
+               do {
+                       move.face = NRAND(6);
+                       move.direction = NRAND(4);      /* Exclude CW and CCW, its ok */
+                       move.position = NRAND(sizeFace(rp, move.face));
+
+                       condition = 1;
+                       if (i > 0) {    /* avoid immediate undoing moves */
+                               if (compare_moves(rp, move, rp->moves[i - 1], True))
+                                       condition = 0;
+                               if (rp->degreeTurn == 180 &&
+                                   compare_moves(rp, move, rp->moves[i - 1], False))
+                                       condition = 0;
+                       }
+                       if (i > 1)      /* avoid 3 consecutive identical moves */
+                               if (compare_moves(rp, move, rp->moves[i - 1], False) &&
+                                   compare_moves(rp, move, rp->moves[i - 2], False))
+                                       condition = 0;
+                       /*
+                        * Still some silly moves being made....
+                        */
+               } while (!condition);
+               if (hideshuffling)
+                       evalmovement(mi, move);
+               rp->moves[i] = move;
+       }
+       rp->VX = 0.05;
+       if (NRAND(100) < 50)
+               rp->VX *= -1;
+       rp->VY = 0.05;
+       if (NRAND(100) < 50)
+               rp->VY *= -1;
+       rp->movement.face = NO_FACE;
+       rp->rotatestep = 0;
+       rp->action = hideshuffling ? ACTION_SOLVE : ACTION_SHUFFLE;
+       rp->shufflingmoves = 0;
+       rp->done = 0;
+}
+
+static void
+reshape(ModeInfo * mi, int width, int height)
+{
+       rubikstruct *rp = &rubik[MI_SCREEN(mi)];
+
+       glViewport(0, 0, rp->WindW = (GLint) width, rp->WindH = (GLint) height);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 15.0);
+       glMatrixMode(GL_MODELVIEW);
+
+       rp->AreObjectsDefined[ObjCubit] = 0;
+}
+
+static void
+pinit(ModeInfo * mi)
+{
+       glClearDepth(1.0);
+       glClearColor(0.0, 0.0, 0.0, 1.0);
+       glColor3f(1.0, 1.0, 1.0);
+
+       glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT0, GL_POSITION, position0);
+       glLightfv(GL_LIGHT1, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT1, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT1, GL_POSITION, position1);
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lmodel_ambient);
+       glLightModelfv(GL_LIGHT_MODEL_TWO_SIDE, lmodel_twoside);
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+       glEnable(GL_LIGHT1);
+       glEnable(GL_DEPTH_TEST);
+       glEnable(GL_NORMALIZE);
+       glEnable(GL_CULL_FACE);
+
+       glShadeModel(GL_FLAT);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, front_shininess);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, front_specular);
+
+       shuffle(mi);
+}
+
+void
+init_rubik(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       rubikstruct *rp;
+
+       if (rubik == NULL) {
+               if ((rubik = (rubikstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (rubikstruct))) == NULL)
+                       return;
+       }
+       rp = &rubik[screen];
+       rp->step = NRAND(90);
+       rp->PX = ((float) LRAND() / (float) MAXRAND) * 2.0 - 1.0;
+       rp->PY = ((float) LRAND() / (float) MAXRAND) * 2.0 - 1.0;
+
+       if ((rp->glx_context = init_GL(mi)) != NULL) {
+
+               reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+               objects = glGenLists(1);
+               pinit(mi);
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_rubik(ModeInfo * mi)
+{
+       int         bounced = 0;
+
+       rubikstruct *rp = &rubik[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!rp->glx_context)
+               return;
+
+       glDrawBuffer(GL_BACK);
+       glXMakeCurrent(display, window, *(rp->glx_context));
+
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       glPushMatrix();
+
+       glTranslatef(0.0, 0.0, -10.0);
+
+       rp->PX += rp->VX;
+       rp->PY += rp->VY;
+
+       if (rp->PY < -1) {
+               rp->PY += (-1) - (rp->PY);
+               rp->VY = -rp->VY;
+               bounced = 1;
+       }
+       if (rp->PY > 1) {
+               rp->PY -= (rp->PY) - 1;
+               rp->VY = -rp->VY;
+               bounced = 1;
+       }
+       if (rp->PX < -1) {
+               rp->PX += (-1) - (rp->PX);
+               rp->VX = -rp->VX;
+               bounced = 1;
+       }
+       if (rp->PX > 1) {
+               rp->PX -= (rp->PX) - 1;
+               rp->VX = -rp->VX;
+               bounced = 1;
+       }
+       if (bounced) {
+               rp->VX += ((float) LRAND() / (float) MAXRAND) * 0.02 - 0.01;
+               rp->VX += ((float) LRAND() / (float) MAXRAND) * 0.02 - 0.01;
+               if (rp->VX > 0.06)
+                       rp->VX = 0.06;
+               if (rp->VY > 0.06)
+                       rp->VY = 0.06;
+               if (rp->VX < -0.06)
+                       rp->VX = -0.06;
+               if (rp->VY < -0.06)
+                       rp->VY = -0.06;
+       }
+       if (!MI_IS_ICONIC(mi)) {
+               glTranslatef(rp->PX, rp->PY, 0);
+               glScalef(Scale4Window * rp->WindH / rp->WindW, Scale4Window, Scale4Window);
+       } else {
+               glScalef(Scale4Iconic * rp->WindH / rp->WindW, Scale4Iconic, Scale4Iconic);
+       }
+
+       glRotatef(rp->step * 100, 1, 0, 0);
+       glRotatef(rp->step * 95, 0, 1, 0);
+       glRotatef(rp->step * 90, 0, 0, 1);
+
+       draw_cube(mi);
+       glXSwapBuffers(display, window);
+
+       if (rp->action == ACTION_SHUFFLE) {
+               if (rp->done) {
+                       if (++rp->rotatestep > DELAY_AFTER_SHUFFLING) {
+                               rp->movement.face = NO_FACE;
+                               rp->rotatestep = 0;
+                               rp->action = ACTION_SOLVE;
+                               rp->done = 0;
+                       }
+               } else {
+                       if (rp->movement.face == NO_FACE) {
+                               if (rp->shufflingmoves < rp->storedmoves) {
+                                       rp->rotatestep = 0;
+                                       rp->movement = rp->moves[rp->shufflingmoves];
+                               } else {
+                                       rp->rotatestep = 0;
+                                       rp->done = 1;
+                               }
+                       } else {
+                               if (rp->rotatestep == 0) {
+                                       if (rp->movement.direction == CW || rp->movement.direction == CCW)
+                                               rp->degreeTurn = (checkFaceSquare(rp, rp->movement.face)) ? 90 : 180;
+                                       else
+                                               rp->degreeTurn = (checkFaceSquare(rp, rowToRotate[rp->movement.face][rp->movement.direction])) ? 90 : 180;
+                               }
+                               rp->rotatestep += rp->anglestep;
+                               if (rp->rotatestep > rp->degreeTurn) {
+                                       evalmovement(mi, rp->movement);
+                                       rp->shufflingmoves++;
+                                       rp->movement.face = NO_FACE;
+                               }
+                       }
+               }
+       } else {
+               if (rp->done) {
+                       if (++rp->rotatestep > DELAY_AFTER_SOLVING)
+                               shuffle(mi);
+               } else {
+                       if (rp->movement.face == NO_FACE) {
+                               if (rp->storedmoves > 0) {
+                                       rp->rotatestep = 0;
+                                       rp->movement = rp->moves[rp->storedmoves - 1];
+                                       rp->movement.direction = (rp->movement.direction +
+                                               (MAXORIENT / 2)) % MAXORIENT;
+                               } else {
+                                       rp->rotatestep = 0;
+                                       rp->done = 1;
+                               }
+                       } else {
+                               if (rp->rotatestep == 0) {
+                                       if (rp->movement.direction == CW || rp->movement.direction == CCW)
+                                               rp->degreeTurn = (checkFaceSquare(rp, rp->movement.face)) ? 90 : 180;
+                                       else
+                                               rp->degreeTurn = (checkFaceSquare(rp, rowToRotate[rp->movement.face][rp->movement.direction])) ? 90 : 180;
+                               }
+                               rp->rotatestep += rp->anglestep;
+                               if (rp->rotatestep > rp->degreeTurn) {
+                                       evalmovement(mi, rp->movement);
+                                       rp->storedmoves--;
+                                       rp->movement.face = NO_FACE;
+                               }
+                       }
+               }
+       }
+
+       glPopMatrix();
+
+       glFlush();
+
+       rp->step += 0.05;
+}
+
+void
+change_rubik(ModeInfo * mi)
+{
+       rubikstruct *rp = &rubik[MI_SCREEN(mi)];
+
+       if (!rp->glx_context)
+               return;
+       pinit(mi);
+}
+
+void
+release_rubik(ModeInfo * mi)
+{
+       if (rubik != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       rubikstruct *rp = &rubik[screen];
+                       int         i;
+
+                       for (i = 0; i < MAXFACES; i++)
+                               if (rp->cubeLoc[i] != NULL)
+                                       (void) free((void *) rp->cubeLoc[i]);
+                       for (i = 0; i < MAXORIENT; i++)
+                               if (rp->rowLoc[i] != NULL)
+                                       (void) free((void *) rp->rowLoc[i]);
+                       if (rp->moves != NULL)
+                               (void) free((void *) rp->moves);
+               }
+               (void) free((void *) rubik);
+               rubik = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/s1_1.c b/xlockmore-4.14/modes/glx/s1_1.c
new file mode 100644 (file)
index 0000000..fb3001f
--- /dev/null
@@ -0,0 +1,1057 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)s1_1.c       4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points, polygons, and normal vectors to render "s1_1" in 3D.
+ *
+ * Generated by lw2ogl.  Link this with your program but do
+ * not edit by hand.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_sproingies
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat s1_1_PNTS[] =
+{
+       (GLfloat) 0.332422, (GLfloat) 0.132531, (GLfloat) - 0.332422,
+       (GLfloat) 0.332422, (GLfloat) 0.132531, (GLfloat) - 0.667578,
+       (GLfloat) 0.667578, (GLfloat) 0.132531, (GLfloat) - 0.332422,
+       (GLfloat) 0.667578, (GLfloat) 0.132531, (GLfloat) - 0.667578,
+       (GLfloat) 0.638667, (GLfloat) 0.007537, (GLfloat) - 0.638667,
+       (GLfloat) 0.361333, (GLfloat) 0.007537, (GLfloat) - 0.638667,
+       (GLfloat) 0.361333, (GLfloat) 0.007537, (GLfloat) - 0.361333,
+       (GLfloat) 0.638667, (GLfloat) 0.007537, (GLfloat) - 0.361333,
+       (GLfloat) 0.653656, (GLfloat) 0.494688, (GLfloat) - 0.653656,
+       (GLfloat) 0.346344, (GLfloat) 0.494688, (GLfloat) - 0.653656,
+       (GLfloat) 0.346344, (GLfloat) 0.494688, (GLfloat) - 0.346344,
+       (GLfloat) 0.653656, (GLfloat) 0.494688, (GLfloat) - 0.346344,
+       (GLfloat) 0.667578, (GLfloat) 0.838781, (GLfloat) - 0.667578,
+       (GLfloat) 0.667578, (GLfloat) 0.838781, (GLfloat) - 0.332422,
+       (GLfloat) 0.638667, (GLfloat) 0.958463, (GLfloat) - 0.361333,
+       (GLfloat) 0.638667, (GLfloat) 0.958463, (GLfloat) - 0.638667,
+       (GLfloat) 0.332422, (GLfloat) 0.838781, (GLfloat) - 0.332422,
+       (GLfloat) 0.361333, (GLfloat) 0.958463, (GLfloat) - 0.361333,
+       (GLfloat) 0.332422, (GLfloat) 0.838781, (GLfloat) - 0.667578,
+       (GLfloat) 0.361333, (GLfloat) 0.958463, (GLfloat) - 0.638667,
+       (GLfloat) 0.738539, (GLfloat) 0.926712, (GLfloat) - 0.500000,
+       (GLfloat) 0.714805, (GLfloat) 0.686547, (GLfloat) - 0.500000,
+       (GLfloat) 0.728516, (GLfloat) 0.838781, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.926712, (GLfloat) - 0.261461,
+       (GLfloat) 0.674539, (GLfloat) 0.926104, (GLfloat) - 0.325461,
+       (GLfloat) 0.500000, (GLfloat) 0.976924, (GLfloat) - 0.500000,
+       (GLfloat) 0.677562, (GLfloat) 0.965162, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.926712, (GLfloat) - 0.738539,
+       (GLfloat) 0.674539, (GLfloat) 0.926104, (GLfloat) - 0.674539,
+       (GLfloat) 0.500000, (GLfloat) 0.686547, (GLfloat) - 0.285195,
+       (GLfloat) 0.500000, (GLfloat) 0.838781, (GLfloat) - 0.271484,
+       (GLfloat) 0.261461, (GLfloat) 0.926712, (GLfloat) - 0.500000,
+       (GLfloat) 0.325461, (GLfloat) 0.926104, (GLfloat) - 0.325461,
+       (GLfloat) 0.500000, (GLfloat) 0.965162, (GLfloat) - 0.322437,
+       (GLfloat) 0.285195, (GLfloat) 0.686547, (GLfloat) - 0.500000,
+       (GLfloat) 0.271484, (GLfloat) 0.838781, (GLfloat) - 0.500000,
+       (GLfloat) 0.325461, (GLfloat) 0.926104, (GLfloat) - 0.674539,
+       (GLfloat) 0.322437, (GLfloat) 0.965162, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.686547, (GLfloat) - 0.714805,
+       (GLfloat) 0.500000, (GLfloat) 0.838781, (GLfloat) - 0.728516,
+       (GLfloat) 0.500000, (GLfloat) 0.965162, (GLfloat) - 0.677562,
+       (GLfloat) 0.657523, (GLfloat) 0.686547, (GLfloat) - 0.657523,
+       (GLfloat) 0.714805, (GLfloat) 0.295922, (GLfloat) - 0.500000,
+       (GLfloat) 0.709531, (GLfloat) 0.494688, (GLfloat) - 0.500000,
+       (GLfloat) 0.657523, (GLfloat) 0.686547, (GLfloat) - 0.342477,
+       (GLfloat) 0.342477, (GLfloat) 0.686547, (GLfloat) - 0.657523,
+       (GLfloat) 0.500000, (GLfloat) 0.295922, (GLfloat) - 0.714805,
+       (GLfloat) 0.500000, (GLfloat) 0.494688, (GLfloat) - 0.709531,
+       (GLfloat) 0.500000, (GLfloat) 0.295922, (GLfloat) - 0.285195,
+       (GLfloat) 0.500000, (GLfloat) 0.494688, (GLfloat) - 0.290469,
+       (GLfloat) 0.342477, (GLfloat) 0.686547, (GLfloat) - 0.342477,
+       (GLfloat) 0.285195, (GLfloat) 0.295922, (GLfloat) - 0.500000,
+       (GLfloat) 0.290469, (GLfloat) 0.494688, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.039819, (GLfloat) - 0.738539,
+       (GLfloat) 0.500000, (GLfloat) 0.132531, (GLfloat) - 0.728516,
+       (GLfloat) 0.657523, (GLfloat) 0.295922, (GLfloat) - 0.657523,
+       (GLfloat) 0.342477, (GLfloat) 0.295922, (GLfloat) - 0.657523,
+       (GLfloat) 0.342477, (GLfloat) 0.295922, (GLfloat) - 0.342477,
+       (GLfloat) 0.261461, (GLfloat) 0.039819, (GLfloat) - 0.500000,
+       (GLfloat) 0.271484, (GLfloat) 0.132531, (GLfloat) - 0.500000,
+       (GLfloat) 0.657523, (GLfloat) 0.295922, (GLfloat) - 0.342477,
+       (GLfloat) 0.500000, (GLfloat) 0.039819, (GLfloat) - 0.261461,
+       (GLfloat) 0.500000, (GLfloat) 0.132531, (GLfloat) - 0.271484,
+       (GLfloat) 0.738539, (GLfloat) 0.039819, (GLfloat) - 0.500000,
+       (GLfloat) 0.728516, (GLfloat) 0.132531, (GLfloat) - 0.500000,
+       (GLfloat) 0.674539, (GLfloat) 0.040427, (GLfloat) - 0.674539,
+       (GLfloat) 0.500000, (GLfloat) - 0.010924, (GLfloat) - 0.500000,
+       (GLfloat) 0.677562, (GLfloat) 0.000839, (GLfloat) - 0.500000,
+       (GLfloat) 0.674539, (GLfloat) 0.040427, (GLfloat) - 0.325461,
+       (GLfloat) 0.325461, (GLfloat) 0.040427, (GLfloat) - 0.674539,
+       (GLfloat) 0.500000, (GLfloat) 0.000839, (GLfloat) - 0.677562,
+       (GLfloat) 0.325461, (GLfloat) 0.040427, (GLfloat) - 0.325461,
+       (GLfloat) 0.322437, (GLfloat) 0.000839, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.000839, (GLfloat) - 0.322437,
+       (GLfloat) 0.721812, (GLfloat) 0.890313, (GLfloat) - 0.595062,
+       (GLfloat) 0.706063, (GLfloat) 0.769563, (GLfloat) - 0.588313,
+       (GLfloat) 0.713281, (GLfloat) 0.838781, (GLfloat) - 0.591406,
+       (GLfloat) 0.721812, (GLfloat) 0.890313, (GLfloat) - 0.404938,
+       (GLfloat) 0.737656, (GLfloat) 0.890313, (GLfloat) - 0.500000,
+       (GLfloat) 0.706000, (GLfloat) 0.949319, (GLfloat) - 0.587500,
+       (GLfloat) 0.722453, (GLfloat) 0.926408, (GLfloat) - 0.595141,
+       (GLfloat) 0.595062, (GLfloat) 0.890313, (GLfloat) - 0.721812,
+       (GLfloat) 0.674281, (GLfloat) 0.890313, (GLfloat) - 0.674281,
+       (GLfloat) 0.595062, (GLfloat) 0.890313, (GLfloat) - 0.278187,
+       (GLfloat) 0.674281, (GLfloat) 0.890313, (GLfloat) - 0.325719,
+       (GLfloat) 0.706000, (GLfloat) 0.949319, (GLfloat) - 0.412500,
+       (GLfloat) 0.722453, (GLfloat) 0.926408, (GLfloat) - 0.404859,
+       (GLfloat) 0.706063, (GLfloat) 0.769563, (GLfloat) - 0.411687,
+       (GLfloat) 0.713281, (GLfloat) 0.838781, (GLfloat) - 0.408594,
+       (GLfloat) 0.590500, (GLfloat) 0.971195, (GLfloat) - 0.409500,
+       (GLfloat) 0.664625, (GLfloat) 0.962948, (GLfloat) - 0.417500,
+       (GLfloat) 0.721500, (GLfloat) 0.950535, (GLfloat) - 0.500000,
+       (GLfloat) 0.587500, (GLfloat) 0.949319, (GLfloat) - 0.294000,
+       (GLfloat) 0.660875, (GLfloat) 0.948104, (GLfloat) - 0.339125,
+       (GLfloat) 0.587500, (GLfloat) 0.949319, (GLfloat) - 0.706000,
+       (GLfloat) 0.660875, (GLfloat) 0.948104, (GLfloat) - 0.660875,
+       (GLfloat) 0.590500, (GLfloat) 0.971195, (GLfloat) - 0.590500,
+       (GLfloat) 0.664625, (GLfloat) 0.962948, (GLfloat) - 0.582500,
+       (GLfloat) 0.588313, (GLfloat) 0.769563, (GLfloat) - 0.293938,
+       (GLfloat) 0.591406, (GLfloat) 0.838781, (GLfloat) - 0.286719,
+       (GLfloat) 0.404938, (GLfloat) 0.890313, (GLfloat) - 0.278187,
+       (GLfloat) 0.500000, (GLfloat) 0.890313, (GLfloat) - 0.262344,
+       (GLfloat) 0.595141, (GLfloat) 0.926408, (GLfloat) - 0.277547,
+       (GLfloat) 0.278187, (GLfloat) 0.890313, (GLfloat) - 0.404938,
+       (GLfloat) 0.325719, (GLfloat) 0.890313, (GLfloat) - 0.325719,
+       (GLfloat) 0.412500, (GLfloat) 0.949319, (GLfloat) - 0.294000,
+       (GLfloat) 0.404859, (GLfloat) 0.926408, (GLfloat) - 0.277547,
+       (GLfloat) 0.411687, (GLfloat) 0.769563, (GLfloat) - 0.293938,
+       (GLfloat) 0.408594, (GLfloat) 0.838781, (GLfloat) - 0.286719,
+       (GLfloat) 0.409500, (GLfloat) 0.971195, (GLfloat) - 0.409500,
+       (GLfloat) 0.417500, (GLfloat) 0.962948, (GLfloat) - 0.335375,
+       (GLfloat) 0.500000, (GLfloat) 0.950535, (GLfloat) - 0.278500,
+       (GLfloat) 0.294000, (GLfloat) 0.949319, (GLfloat) - 0.412500,
+       (GLfloat) 0.339125, (GLfloat) 0.948104, (GLfloat) - 0.339125,
+       (GLfloat) 0.582500, (GLfloat) 0.962948, (GLfloat) - 0.335375,
+       (GLfloat) 0.293938, (GLfloat) 0.769563, (GLfloat) - 0.411687,
+       (GLfloat) 0.286719, (GLfloat) 0.838781, (GLfloat) - 0.408594,
+       (GLfloat) 0.278187, (GLfloat) 0.890313, (GLfloat) - 0.595062,
+       (GLfloat) 0.262344, (GLfloat) 0.890313, (GLfloat) - 0.500000,
+       (GLfloat) 0.277547, (GLfloat) 0.926408, (GLfloat) - 0.404859,
+       (GLfloat) 0.404938, (GLfloat) 0.890313, (GLfloat) - 0.721812,
+       (GLfloat) 0.325719, (GLfloat) 0.890313, (GLfloat) - 0.674281,
+       (GLfloat) 0.294000, (GLfloat) 0.949319, (GLfloat) - 0.587500,
+       (GLfloat) 0.277547, (GLfloat) 0.926408, (GLfloat) - 0.595141,
+       (GLfloat) 0.293938, (GLfloat) 0.769563, (GLfloat) - 0.588313,
+       (GLfloat) 0.286719, (GLfloat) 0.838781, (GLfloat) - 0.591406,
+       (GLfloat) 0.409500, (GLfloat) 0.971195, (GLfloat) - 0.590500,
+       (GLfloat) 0.335375, (GLfloat) 0.962948, (GLfloat) - 0.582500,
+       (GLfloat) 0.278500, (GLfloat) 0.950535, (GLfloat) - 0.500000,
+       (GLfloat) 0.412500, (GLfloat) 0.949319, (GLfloat) - 0.706000,
+       (GLfloat) 0.339125, (GLfloat) 0.948104, (GLfloat) - 0.660875,
+       (GLfloat) 0.335375, (GLfloat) 0.962948, (GLfloat) - 0.417500,
+       (GLfloat) 0.411687, (GLfloat) 0.769563, (GLfloat) - 0.706063,
+       (GLfloat) 0.408594, (GLfloat) 0.838781, (GLfloat) - 0.713281,
+       (GLfloat) 0.500000, (GLfloat) 0.890313, (GLfloat) - 0.737656,
+       (GLfloat) 0.404859, (GLfloat) 0.926408, (GLfloat) - 0.722453,
+       (GLfloat) 0.595141, (GLfloat) 0.926408, (GLfloat) - 0.722453,
+       (GLfloat) 0.588313, (GLfloat) 0.769563, (GLfloat) - 0.706063,
+       (GLfloat) 0.591406, (GLfloat) 0.838781, (GLfloat) - 0.713281,
+       (GLfloat) 0.582500, (GLfloat) 0.962948, (GLfloat) - 0.664625,
+       (GLfloat) 0.500000, (GLfloat) 0.950535, (GLfloat) - 0.721500,
+       (GLfloat) 0.417500, (GLfloat) 0.962948, (GLfloat) - 0.664625,
+       (GLfloat) 0.500000, (GLfloat) 0.973972, (GLfloat) - 0.402250,
+       (GLfloat) 0.597750, (GLfloat) 0.973972, (GLfloat) - 0.500000,
+       (GLfloat) 0.402250, (GLfloat) 0.973972, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.973972, (GLfloat) - 0.597750,
+       (GLfloat) 0.661906, (GLfloat) 0.769563, (GLfloat) - 0.661906,
+       (GLfloat) 0.696875, (GLfloat) 0.593625, (GLfloat) - 0.584375,
+       (GLfloat) 0.700484, (GLfloat) 0.686547, (GLfloat) - 0.585922,
+       (GLfloat) 0.720781, (GLfloat) 0.769563, (GLfloat) - 0.500000,
+       (GLfloat) 0.696875, (GLfloat) 0.393625, (GLfloat) - 0.584375,
+       (GLfloat) 0.695563, (GLfloat) 0.494688, (GLfloat) - 0.583813,
+       (GLfloat) 0.696875, (GLfloat) 0.593625, (GLfloat) - 0.415625,
+       (GLfloat) 0.710938, (GLfloat) 0.593625, (GLfloat) - 0.500000,
+       (GLfloat) 0.584375, (GLfloat) 0.593625, (GLfloat) - 0.696875,
+       (GLfloat) 0.654688, (GLfloat) 0.593625, (GLfloat) - 0.654688,
+       (GLfloat) 0.584375, (GLfloat) 0.593625, (GLfloat) - 0.303125,
+       (GLfloat) 0.654688, (GLfloat) 0.593625, (GLfloat) - 0.345313,
+       (GLfloat) 0.700484, (GLfloat) 0.686547, (GLfloat) - 0.414078,
+       (GLfloat) 0.696875, (GLfloat) 0.393625, (GLfloat) - 0.415625,
+       (GLfloat) 0.695563, (GLfloat) 0.494688, (GLfloat) - 0.416187,
+       (GLfloat) 0.661906, (GLfloat) 0.769563, (GLfloat) - 0.338094,
+       (GLfloat) 0.338094, (GLfloat) 0.769563, (GLfloat) - 0.661906,
+       (GLfloat) 0.415625, (GLfloat) 0.593625, (GLfloat) - 0.696875,
+       (GLfloat) 0.414078, (GLfloat) 0.686547, (GLfloat) - 0.700484,
+       (GLfloat) 0.500000, (GLfloat) 0.769563, (GLfloat) - 0.720781,
+       (GLfloat) 0.415625, (GLfloat) 0.393625, (GLfloat) - 0.696875,
+       (GLfloat) 0.416187, (GLfloat) 0.494688, (GLfloat) - 0.695563,
+       (GLfloat) 0.500000, (GLfloat) 0.593625, (GLfloat) - 0.710938,
+       (GLfloat) 0.303125, (GLfloat) 0.593625, (GLfloat) - 0.584375,
+       (GLfloat) 0.345313, (GLfloat) 0.593625, (GLfloat) - 0.654688,
+       (GLfloat) 0.585922, (GLfloat) 0.686547, (GLfloat) - 0.700484,
+       (GLfloat) 0.584375, (GLfloat) 0.393625, (GLfloat) - 0.696875,
+       (GLfloat) 0.583813, (GLfloat) 0.494688, (GLfloat) - 0.695563,
+       (GLfloat) 0.500000, (GLfloat) 0.769563, (GLfloat) - 0.279219,
+       (GLfloat) 0.415625, (GLfloat) 0.593625, (GLfloat) - 0.303125,
+       (GLfloat) 0.414078, (GLfloat) 0.686547, (GLfloat) - 0.299516,
+       (GLfloat) 0.338094, (GLfloat) 0.769563, (GLfloat) - 0.338094,
+       (GLfloat) 0.585922, (GLfloat) 0.686547, (GLfloat) - 0.299516,
+       (GLfloat) 0.584375, (GLfloat) 0.393625, (GLfloat) - 0.303125,
+       (GLfloat) 0.583813, (GLfloat) 0.494688, (GLfloat) - 0.304437,
+       (GLfloat) 0.500000, (GLfloat) 0.593625, (GLfloat) - 0.289063,
+       (GLfloat) 0.303125, (GLfloat) 0.593625, (GLfloat) - 0.415625,
+       (GLfloat) 0.345313, (GLfloat) 0.593625, (GLfloat) - 0.345313,
+       (GLfloat) 0.415625, (GLfloat) 0.393625, (GLfloat) - 0.303125,
+       (GLfloat) 0.416187, (GLfloat) 0.494688, (GLfloat) - 0.304437,
+       (GLfloat) 0.279219, (GLfloat) 0.769563, (GLfloat) - 0.500000,
+       (GLfloat) 0.299516, (GLfloat) 0.686547, (GLfloat) - 0.585922,
+       (GLfloat) 0.299516, (GLfloat) 0.686547, (GLfloat) - 0.414078,
+       (GLfloat) 0.303125, (GLfloat) 0.393625, (GLfloat) - 0.415625,
+       (GLfloat) 0.304437, (GLfloat) 0.494688, (GLfloat) - 0.416187,
+       (GLfloat) 0.289063, (GLfloat) 0.593625, (GLfloat) - 0.500000,
+       (GLfloat) 0.303125, (GLfloat) 0.393625, (GLfloat) - 0.584375,
+       (GLfloat) 0.304437, (GLfloat) 0.494688, (GLfloat) - 0.583813,
+       (GLfloat) 0.411687, (GLfloat) 0.207062, (GLfloat) - 0.706063,
+       (GLfloat) 0.404938, (GLfloat) 0.077813, (GLfloat) - 0.721812,
+       (GLfloat) 0.408594, (GLfloat) 0.132531, (GLfloat) - 0.713281,
+       (GLfloat) 0.588313, (GLfloat) 0.207062, (GLfloat) - 0.706063,
+       (GLfloat) 0.500000, (GLfloat) 0.207062, (GLfloat) - 0.720781,
+       (GLfloat) 0.414078, (GLfloat) 0.295922, (GLfloat) - 0.700484,
+       (GLfloat) 0.293938, (GLfloat) 0.207062, (GLfloat) - 0.588313,
+       (GLfloat) 0.338094, (GLfloat) 0.207062, (GLfloat) - 0.661906,
+       (GLfloat) 0.706063, (GLfloat) 0.207062, (GLfloat) - 0.588313,
+       (GLfloat) 0.661906, (GLfloat) 0.207062, (GLfloat) - 0.661906,
+       (GLfloat) 0.585922, (GLfloat) 0.295922, (GLfloat) - 0.700484,
+       (GLfloat) 0.595062, (GLfloat) 0.077813, (GLfloat) - 0.721812,
+       (GLfloat) 0.591406, (GLfloat) 0.132531, (GLfloat) - 0.713281,
+       (GLfloat) 0.500000, (GLfloat) 0.393625, (GLfloat) - 0.710938,
+       (GLfloat) 0.654688, (GLfloat) 0.393625, (GLfloat) - 0.654688,
+       (GLfloat) 0.345313, (GLfloat) 0.393625, (GLfloat) - 0.654688,
+       (GLfloat) 0.299516, (GLfloat) 0.295922, (GLfloat) - 0.585922,
+       (GLfloat) 0.293938, (GLfloat) 0.207062, (GLfloat) - 0.411687,
+       (GLfloat) 0.279219, (GLfloat) 0.207062, (GLfloat) - 0.500000,
+       (GLfloat) 0.278187, (GLfloat) 0.077813, (GLfloat) - 0.595062,
+       (GLfloat) 0.286719, (GLfloat) 0.132531, (GLfloat) - 0.591406,
+       (GLfloat) 0.289063, (GLfloat) 0.393625, (GLfloat) - 0.500000,
+       (GLfloat) 0.345313, (GLfloat) 0.393625, (GLfloat) - 0.345313,
+       (GLfloat) 0.299516, (GLfloat) 0.295922, (GLfloat) - 0.414078,
+       (GLfloat) 0.278187, (GLfloat) 0.077813, (GLfloat) - 0.404938,
+       (GLfloat) 0.286719, (GLfloat) 0.132531, (GLfloat) - 0.408594,
+       (GLfloat) 0.411687, (GLfloat) 0.207062, (GLfloat) - 0.293938,
+       (GLfloat) 0.338094, (GLfloat) 0.207062, (GLfloat) - 0.338094,
+       (GLfloat) 0.414078, (GLfloat) 0.295922, (GLfloat) - 0.299516,
+       (GLfloat) 0.588313, (GLfloat) 0.207062, (GLfloat) - 0.293938,
+       (GLfloat) 0.500000, (GLfloat) 0.207062, (GLfloat) - 0.279219,
+       (GLfloat) 0.404938, (GLfloat) 0.077813, (GLfloat) - 0.278187,
+       (GLfloat) 0.408594, (GLfloat) 0.132531, (GLfloat) - 0.286719,
+       (GLfloat) 0.500000, (GLfloat) 0.393625, (GLfloat) - 0.289063,
+       (GLfloat) 0.654688, (GLfloat) 0.393625, (GLfloat) - 0.345313,
+       (GLfloat) 0.585922, (GLfloat) 0.295922, (GLfloat) - 0.299516,
+       (GLfloat) 0.595062, (GLfloat) 0.077813, (GLfloat) - 0.278187,
+       (GLfloat) 0.591406, (GLfloat) 0.132531, (GLfloat) - 0.286719,
+       (GLfloat) 0.706063, (GLfloat) 0.207062, (GLfloat) - 0.411687,
+       (GLfloat) 0.661906, (GLfloat) 0.207062, (GLfloat) - 0.338094,
+       (GLfloat) 0.700484, (GLfloat) 0.295922, (GLfloat) - 0.414078,
+       (GLfloat) 0.720781, (GLfloat) 0.207062, (GLfloat) - 0.500000,
+       (GLfloat) 0.721812, (GLfloat) 0.077813, (GLfloat) - 0.404938,
+       (GLfloat) 0.713281, (GLfloat) 0.132531, (GLfloat) - 0.408594,
+       (GLfloat) 0.710938, (GLfloat) 0.393625, (GLfloat) - 0.500000,
+       (GLfloat) 0.700484, (GLfloat) 0.295922, (GLfloat) - 0.585922,
+       (GLfloat) 0.721812, (GLfloat) 0.077813, (GLfloat) - 0.595062,
+       (GLfloat) 0.713281, (GLfloat) 0.132531, (GLfloat) - 0.591406,
+       (GLfloat) 0.737656, (GLfloat) 0.077813, (GLfloat) - 0.500000,
+       (GLfloat) 0.706000, (GLfloat) 0.016681, (GLfloat) - 0.412500,
+       (GLfloat) 0.722453, (GLfloat) 0.040123, (GLfloat) - 0.404859,
+       (GLfloat) 0.674281, (GLfloat) 0.077813, (GLfloat) - 0.325719,
+       (GLfloat) 0.674281, (GLfloat) 0.077813, (GLfloat) - 0.674281,
+       (GLfloat) 0.706000, (GLfloat) 0.016681, (GLfloat) - 0.587500,
+       (GLfloat) 0.722453, (GLfloat) 0.040123, (GLfloat) - 0.595141,
+       (GLfloat) 0.590500, (GLfloat) - 0.005194, (GLfloat) - 0.590500,
+       (GLfloat) 0.664625, (GLfloat) 0.003052, (GLfloat) - 0.582500,
+       (GLfloat) 0.721500, (GLfloat) 0.015465, (GLfloat) - 0.500000,
+       (GLfloat) 0.587500, (GLfloat) 0.016681, (GLfloat) - 0.706000,
+       (GLfloat) 0.660875, (GLfloat) 0.017896, (GLfloat) - 0.660875,
+       (GLfloat) 0.587500, (GLfloat) 0.016681, (GLfloat) - 0.294000,
+       (GLfloat) 0.660875, (GLfloat) 0.017896, (GLfloat) - 0.339125,
+       (GLfloat) 0.590500, (GLfloat) - 0.005194, (GLfloat) - 0.409500,
+       (GLfloat) 0.664625, (GLfloat) 0.003052, (GLfloat) - 0.417500,
+       (GLfloat) 0.500000, (GLfloat) 0.077813, (GLfloat) - 0.737656,
+       (GLfloat) 0.595141, (GLfloat) 0.040123, (GLfloat) - 0.722453,
+       (GLfloat) 0.325719, (GLfloat) 0.077813, (GLfloat) - 0.674281,
+       (GLfloat) 0.412500, (GLfloat) 0.016681, (GLfloat) - 0.706000,
+       (GLfloat) 0.404859, (GLfloat) 0.040123, (GLfloat) - 0.722453,
+       (GLfloat) 0.409500, (GLfloat) - 0.005194, (GLfloat) - 0.590500,
+       (GLfloat) 0.417500, (GLfloat) 0.003052, (GLfloat) - 0.664625,
+       (GLfloat) 0.500000, (GLfloat) 0.015465, (GLfloat) - 0.721500,
+       (GLfloat) 0.294000, (GLfloat) 0.016681, (GLfloat) - 0.587500,
+       (GLfloat) 0.339125, (GLfloat) 0.017896, (GLfloat) - 0.660875,
+       (GLfloat) 0.582500, (GLfloat) 0.003052, (GLfloat) - 0.664625,
+       (GLfloat) 0.262344, (GLfloat) 0.077813, (GLfloat) - 0.500000,
+       (GLfloat) 0.277547, (GLfloat) 0.040123, (GLfloat) - 0.595141,
+       (GLfloat) 0.325719, (GLfloat) 0.077813, (GLfloat) - 0.325719,
+       (GLfloat) 0.294000, (GLfloat) 0.016681, (GLfloat) - 0.412500,
+       (GLfloat) 0.277547, (GLfloat) 0.040123, (GLfloat) - 0.404859,
+       (GLfloat) 0.409500, (GLfloat) - 0.005194, (GLfloat) - 0.409500,
+       (GLfloat) 0.335375, (GLfloat) 0.003052, (GLfloat) - 0.417500,
+       (GLfloat) 0.278500, (GLfloat) 0.015465, (GLfloat) - 0.500000,
+       (GLfloat) 0.412500, (GLfloat) 0.016681, (GLfloat) - 0.294000,
+       (GLfloat) 0.339125, (GLfloat) 0.017896, (GLfloat) - 0.339125,
+       (GLfloat) 0.335375, (GLfloat) 0.003052, (GLfloat) - 0.582500,
+       (GLfloat) 0.500000, (GLfloat) 0.077813, (GLfloat) - 0.262344,
+       (GLfloat) 0.404859, (GLfloat) 0.040123, (GLfloat) - 0.277547,
+       (GLfloat) 0.595141, (GLfloat) 0.040123, (GLfloat) - 0.277547,
+       (GLfloat) 0.582500, (GLfloat) 0.003052, (GLfloat) - 0.335375,
+       (GLfloat) 0.500000, (GLfloat) 0.015465, (GLfloat) - 0.278500,
+       (GLfloat) 0.417500, (GLfloat) 0.003052, (GLfloat) - 0.335375,
+       (GLfloat) 0.500000, (GLfloat) - 0.007972, (GLfloat) - 0.597750,
+       (GLfloat) 0.597750, (GLfloat) - 0.007972, (GLfloat) - 0.500000,
+       (GLfloat) 0.402250, (GLfloat) - 0.007972, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) - 0.007972, (GLfloat) - 0.402250,
+};
+
+static GLfloat s1_1_normals[] =
+{
+       (GLfloat) 0.844155, (GLfloat) - 0.175691, (GLfloat) - 0.506493,
+       (GLfloat) 0.844155, (GLfloat) - 0.175690, (GLfloat) - 0.506493,
+       (GLfloat) 0.971634, (GLfloat) - 0.172349, (GLfloat) - 0.161939,
+       (GLfloat) 0.971634, (GLfloat) - 0.172348, (GLfloat) - 0.161939,
+       (GLfloat) 0.985737, (GLfloat) - 0.023907, (GLfloat) - 0.166587,
+       (GLfloat) 0.986237, (GLfloat) - 0.017860, (GLfloat) - 0.164373,
+       (GLfloat) 0.856157, (GLfloat) - 0.009890, (GLfloat) - 0.516621,
+       (GLfloat) 0.857379, (GLfloat) - 0.016331, (GLfloat) - 0.514427,
+       (GLfloat) 0.844155, (GLfloat) - 0.175690, (GLfloat) 0.506493,
+       (GLfloat) 0.844155, (GLfloat) - 0.175690, (GLfloat) 0.506493,
+       (GLfloat) 0.856157, (GLfloat) - 0.009889, (GLfloat) 0.516621,
+       (GLfloat) 0.857379, (GLfloat) - 0.016331, (GLfloat) 0.514427,
+       (GLfloat) 0.985737, (GLfloat) - 0.023907, (GLfloat) 0.166587,
+       (GLfloat) 0.986237, (GLfloat) - 0.017860, (GLfloat) 0.164373,
+       (GLfloat) 0.971634, (GLfloat) - 0.172348, (GLfloat) 0.161939,
+       (GLfloat) 0.971634, (GLfloat) - 0.172348, (GLfloat) 0.161939,
+       (GLfloat) 0.283621, (GLfloat) 0.936578, (GLfloat) 0.205866,
+       (GLfloat) 0.264056, (GLfloat) 0.947923, (GLfloat) 0.178092,
+       (GLfloat) 0.315105, (GLfloat) 0.946548, (GLfloat) 0.068965,
+       (GLfloat) 0.304029, (GLfloat) 0.949849, (GLfloat) 0.073162,
+       (GLfloat) 0.783125, (GLfloat) 0.607180, (GLfloat) 0.134346,
+       (GLfloat) 0.804111, (GLfloat) 0.575131, (GLfloat) 0.150431,
+       (GLfloat) 0.650208, (GLfloat) 0.649088, (GLfloat) 0.394860,
+       (GLfloat) 0.665312, (GLfloat) 0.617634, (GLfloat) 0.419391,
+       (GLfloat) 0.264056, (GLfloat) 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) 0.283621, (GLfloat) 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) 0.650207, (GLfloat) 0.649089, (GLfloat) - 0.394860,
+       (GLfloat) 0.665311, (GLfloat) 0.617634, (GLfloat) - 0.419391,
+       (GLfloat) 0.804111, (GLfloat) 0.575131, (GLfloat) - 0.150431,
+       (GLfloat) 0.783125, (GLfloat) 0.607180, (GLfloat) - 0.134346,
+       (GLfloat) 0.304029, (GLfloat) 0.949849, (GLfloat) - 0.073162,
+       (GLfloat) 0.315105, (GLfloat) 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) 0.506493, (GLfloat) - 0.175691, (GLfloat) 0.844155,
+       (GLfloat) 0.506493, (GLfloat) - 0.175691, (GLfloat) 0.844155,
+       (GLfloat) 0.161939, (GLfloat) - 0.172349, (GLfloat) 0.971633,
+       (GLfloat) 0.161939, (GLfloat) - 0.172349, (GLfloat) 0.971633,
+       (GLfloat) 0.166587, (GLfloat) - 0.023907, (GLfloat) 0.985737,
+       (GLfloat) 0.164373, (GLfloat) - 0.017860, (GLfloat) 0.986237,
+       (GLfloat) 0.516622, (GLfloat) - 0.009888, (GLfloat) 0.856157,
+       (GLfloat) 0.514427, (GLfloat) - 0.016331, (GLfloat) 0.857379,
+       (GLfloat) - 0.506493, (GLfloat) - 0.175691, (GLfloat) 0.844155,
+       (GLfloat) - 0.506493, (GLfloat) - 0.175691, (GLfloat) 0.844155,
+       (GLfloat) - 0.516622, (GLfloat) - 0.009887, (GLfloat) 0.856157,
+       (GLfloat) - 0.514427, (GLfloat) - 0.016331, (GLfloat) 0.857379,
+       (GLfloat) - 0.166587, (GLfloat) - 0.023907, (GLfloat) 0.985737,
+       (GLfloat) - 0.164373, (GLfloat) - 0.017860, (GLfloat) 0.986237,
+       (GLfloat) - 0.161939, (GLfloat) - 0.172349, (GLfloat) 0.971633,
+       (GLfloat) - 0.161939, (GLfloat) - 0.172349, (GLfloat) 0.971633,
+       (GLfloat) - 0.205866, (GLfloat) 0.936578, (GLfloat) 0.283621,
+       (GLfloat) - 0.178092, (GLfloat) 0.947923, (GLfloat) 0.264055,
+       (GLfloat) - 0.068965, (GLfloat) 0.946548, (GLfloat) 0.315105,
+       (GLfloat) - 0.073162, (GLfloat) 0.949849, (GLfloat) 0.304029,
+       (GLfloat) - 0.134346, (GLfloat) 0.607180, (GLfloat) 0.783125,
+       (GLfloat) - 0.150431, (GLfloat) 0.575131, (GLfloat) 0.804111,
+       (GLfloat) - 0.394861, (GLfloat) 0.649087, (GLfloat) 0.650209,
+       (GLfloat) - 0.419390, (GLfloat) 0.617634, (GLfloat) 0.665312,
+       (GLfloat) 0.178092, (GLfloat) 0.947923, (GLfloat) 0.264056,
+       (GLfloat) 0.205866, (GLfloat) 0.936578, (GLfloat) 0.283621,
+       (GLfloat) 0.394861, (GLfloat) 0.649087, (GLfloat) 0.650208,
+       (GLfloat) 0.419390, (GLfloat) 0.617634, (GLfloat) 0.665312,
+       (GLfloat) 0.150431, (GLfloat) 0.575131, (GLfloat) 0.804111,
+       (GLfloat) 0.134346, (GLfloat) 0.607180, (GLfloat) 0.783125,
+       (GLfloat) 0.073162, (GLfloat) 0.949849, (GLfloat) 0.304029,
+       (GLfloat) 0.068965, (GLfloat) 0.946548, (GLfloat) 0.315105,
+       (GLfloat) - 0.844155, (GLfloat) - 0.175691, (GLfloat) 0.506493,
+       (GLfloat) - 0.844155, (GLfloat) - 0.175691, (GLfloat) 0.506493,
+       (GLfloat) - 0.971633, (GLfloat) - 0.172349, (GLfloat) 0.161939,
+       (GLfloat) - 0.971633, (GLfloat) - 0.172349, (GLfloat) 0.161939,
+       (GLfloat) - 0.985737, (GLfloat) - 0.023907, (GLfloat) 0.166587,
+       (GLfloat) - 0.986237, (GLfloat) - 0.017860, (GLfloat) 0.164373,
+       (GLfloat) - 0.856157, (GLfloat) - 0.009887, (GLfloat) 0.516622,
+       (GLfloat) - 0.857379, (GLfloat) - 0.016331, (GLfloat) 0.514427,
+       (GLfloat) - 0.844155, (GLfloat) - 0.175691, (GLfloat) - 0.506493,
+       (GLfloat) - 0.844155, (GLfloat) - 0.175691, (GLfloat) - 0.506493,
+       (GLfloat) - 0.856157, (GLfloat) - 0.009888, (GLfloat) - 0.516622,
+       (GLfloat) - 0.857379, (GLfloat) - 0.016331, (GLfloat) - 0.514427,
+       (GLfloat) - 0.985737, (GLfloat) - 0.023907, (GLfloat) - 0.166587,
+       (GLfloat) - 0.986237, (GLfloat) - 0.017860, (GLfloat) - 0.164373,
+       (GLfloat) - 0.971633, (GLfloat) - 0.172349, (GLfloat) - 0.161939,
+       (GLfloat) - 0.971633, (GLfloat) - 0.172349, (GLfloat) - 0.161939,
+       (GLfloat) - 0.283621, (GLfloat) 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) - 0.264056, (GLfloat) 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) - 0.315105, (GLfloat) 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) - 0.304029, (GLfloat) 0.949849, (GLfloat) - 0.073162,
+       (GLfloat) - 0.783125, (GLfloat) 0.607180, (GLfloat) - 0.134346,
+       (GLfloat) - 0.804111, (GLfloat) 0.575131, (GLfloat) - 0.150431,
+       (GLfloat) - 0.650208, (GLfloat) 0.649087, (GLfloat) - 0.394861,
+       (GLfloat) - 0.665312, (GLfloat) 0.617634, (GLfloat) - 0.419390,
+       (GLfloat) - 0.264055, (GLfloat) 0.947923, (GLfloat) 0.178092,
+       (GLfloat) - 0.283621, (GLfloat) 0.936578, (GLfloat) 0.205866,
+       (GLfloat) - 0.650209, (GLfloat) 0.649087, (GLfloat) 0.394861,
+       (GLfloat) - 0.665312, (GLfloat) 0.617634, (GLfloat) 0.419390,
+       (GLfloat) - 0.804111, (GLfloat) 0.575131, (GLfloat) 0.150431,
+       (GLfloat) - 0.783125, (GLfloat) 0.607180, (GLfloat) 0.134346,
+       (GLfloat) - 0.304029, (GLfloat) 0.949849, (GLfloat) 0.073162,
+       (GLfloat) - 0.315105, (GLfloat) 0.946548, (GLfloat) 0.068965,
+       (GLfloat) - 0.506493, (GLfloat) - 0.175690, (GLfloat) - 0.844155,
+       (GLfloat) - 0.506493, (GLfloat) - 0.175690, (GLfloat) - 0.844155,
+       (GLfloat) - 0.161939, (GLfloat) - 0.172348, (GLfloat) - 0.971634,
+       (GLfloat) - 0.161939, (GLfloat) - 0.172348, (GLfloat) - 0.971634,
+       (GLfloat) - 0.166587, (GLfloat) - 0.023907, (GLfloat) - 0.985737,
+       (GLfloat) - 0.164373, (GLfloat) - 0.017860, (GLfloat) - 0.986237,
+       (GLfloat) - 0.516621, (GLfloat) - 0.009889, (GLfloat) - 0.856157,
+       (GLfloat) - 0.514427, (GLfloat) - 0.016331, (GLfloat) - 0.857379,
+       (GLfloat) 0.506493, (GLfloat) - 0.175690, (GLfloat) - 0.844155,
+       (GLfloat) 0.506493, (GLfloat) - 0.175691, (GLfloat) - 0.844155,
+       (GLfloat) 0.516621, (GLfloat) - 0.009890, (GLfloat) - 0.856157,
+       (GLfloat) 0.514427, (GLfloat) - 0.016331, (GLfloat) - 0.857379,
+       (GLfloat) 0.166587, (GLfloat) - 0.023907, (GLfloat) - 0.985737,
+       (GLfloat) 0.164373, (GLfloat) - 0.017860, (GLfloat) - 0.986237,
+       (GLfloat) 0.161939, (GLfloat) - 0.172349, (GLfloat) - 0.971634,
+       (GLfloat) 0.161939, (GLfloat) - 0.172348, (GLfloat) - 0.971634,
+       (GLfloat) 0.205866, (GLfloat) 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) 0.178092, (GLfloat) 0.947923, (GLfloat) - 0.264056,
+       (GLfloat) 0.068965, (GLfloat) 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) 0.073162, (GLfloat) 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) 0.134346, (GLfloat) 0.607180, (GLfloat) - 0.783125,
+       (GLfloat) 0.150431, (GLfloat) 0.575131, (GLfloat) - 0.804111,
+       (GLfloat) 0.394860, (GLfloat) 0.649089, (GLfloat) - 0.650207,
+       (GLfloat) 0.419391, (GLfloat) 0.617634, (GLfloat) - 0.665311,
+       (GLfloat) - 0.178092, (GLfloat) 0.947923, (GLfloat) - 0.264056,
+       (GLfloat) - 0.205866, (GLfloat) 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) - 0.394860, (GLfloat) 0.649088, (GLfloat) - 0.650208,
+       (GLfloat) - 0.419391, (GLfloat) 0.617634, (GLfloat) - 0.665312,
+       (GLfloat) - 0.150431, (GLfloat) 0.575131, (GLfloat) - 0.804111,
+       (GLfloat) - 0.134346, (GLfloat) 0.607180, (GLfloat) - 0.783125,
+       (GLfloat) - 0.073162, (GLfloat) 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) - 0.068965, (GLfloat) 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) 0.135802, (GLfloat) 0.982944, (GLfloat) 0.124011,
+       (GLfloat) 0.124011, (GLfloat) 0.982944, (GLfloat) 0.135802,
+       (GLfloat) 0.043834, (GLfloat) 0.993006, (GLfloat) 0.109621,
+       (GLfloat) 0.039656, (GLfloat) 0.992607, (GLfloat) 0.114709,
+       (GLfloat) 0.030163, (GLfloat) 0.998998, (GLfloat) 0.033079,
+       (GLfloat) 0.033079, (GLfloat) 0.998998, (GLfloat) 0.030163,
+       (GLfloat) 0.109621, (GLfloat) 0.993006, (GLfloat) 0.043834,
+       (GLfloat) 0.114709, (GLfloat) 0.992607, (GLfloat) 0.039656,
+       (GLfloat) - 0.124011, (GLfloat) 0.982944, (GLfloat) 0.135803,
+       (GLfloat) - 0.135803, (GLfloat) 0.982944, (GLfloat) 0.124011,
+       (GLfloat) - 0.109621, (GLfloat) 0.993006, (GLfloat) 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) 0.992607, (GLfloat) 0.039656,
+       (GLfloat) - 0.033079, (GLfloat) 0.998998, (GLfloat) 0.030163,
+       (GLfloat) - 0.030163, (GLfloat) 0.998998, (GLfloat) 0.033079,
+       (GLfloat) - 0.043834, (GLfloat) 0.993006, (GLfloat) 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) 0.992607, (GLfloat) 0.114709,
+       (GLfloat) - 0.135802, (GLfloat) 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) - 0.124011, (GLfloat) 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) - 0.043834, (GLfloat) 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) - 0.030163, (GLfloat) 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) - 0.033079, (GLfloat) 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) - 0.109621, (GLfloat) 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) 0.124011, (GLfloat) 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) 0.135802, (GLfloat) 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) 0.109621, (GLfloat) 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) 0.114709, (GLfloat) 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) 0.033079, (GLfloat) 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) 0.030163, (GLfloat) 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) 0.043834, (GLfloat) 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) 0.039656, (GLfloat) 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) 0.852125, (GLfloat) - 0.111720, (GLfloat) - 0.511275,
+       (GLfloat) 0.852125, (GLfloat) - 0.111718, (GLfloat) - 0.511276,
+       (GLfloat) 0.855252, (GLfloat) - 0.072245, (GLfloat) - 0.513151,
+       (GLfloat) 0.855252, (GLfloat) - 0.072244, (GLfloat) - 0.513152,
+       (GLfloat) 0.983916, (GLfloat) - 0.070836, (GLfloat) - 0.163986,
+       (GLfloat) 0.983916, (GLfloat) - 0.070836, (GLfloat) - 0.163986,
+       (GLfloat) 0.980457, (GLfloat) - 0.109554, (GLfloat) - 0.163409,
+       (GLfloat) 0.980457, (GLfloat) - 0.109553, (GLfloat) - 0.163410,
+       (GLfloat) 0.857405, (GLfloat) - 0.014299, (GLfloat) - 0.514444,
+       (GLfloat) 0.857405, (GLfloat) - 0.014300, (GLfloat) - 0.514443,
+       (GLfloat) 0.986297, (GLfloat) - 0.014019, (GLfloat) - 0.164382,
+       (GLfloat) 0.986297, (GLfloat) - 0.014019, (GLfloat) - 0.164382,
+       (GLfloat) 0.985564, (GLfloat) - 0.041017, (GLfloat) - 0.164261,
+       (GLfloat) 0.985564, (GLfloat) - 0.041017, (GLfloat) - 0.164260,
+       (GLfloat) 0.856742, (GLfloat) - 0.041836, (GLfloat) - 0.514045,
+       (GLfloat) 0.856742, (GLfloat) - 0.041836, (GLfloat) - 0.514045,
+       (GLfloat) 0.857405, (GLfloat) - 0.014299, (GLfloat) 0.514443,
+       (GLfloat) 0.857405, (GLfloat) - 0.014299, (GLfloat) 0.514444,
+       (GLfloat) 0.856742, (GLfloat) - 0.041836, (GLfloat) 0.514045,
+       (GLfloat) 0.856742, (GLfloat) - 0.041836, (GLfloat) 0.514045,
+       (GLfloat) 0.985564, (GLfloat) - 0.041017, (GLfloat) 0.164260,
+       (GLfloat) 0.985564, (GLfloat) - 0.041017, (GLfloat) 0.164261,
+       (GLfloat) 0.986297, (GLfloat) - 0.014019, (GLfloat) 0.164382,
+       (GLfloat) 0.986297, (GLfloat) - 0.014019, (GLfloat) 0.164382,
+       (GLfloat) 0.852125, (GLfloat) - 0.111719, (GLfloat) 0.511275,
+       (GLfloat) 0.852125, (GLfloat) - 0.111718, (GLfloat) 0.511276,
+       (GLfloat) 0.980457, (GLfloat) - 0.109553, (GLfloat) 0.163410,
+       (GLfloat) 0.980457, (GLfloat) - 0.109554, (GLfloat) 0.163409,
+       (GLfloat) 0.983916, (GLfloat) - 0.070836, (GLfloat) 0.163986,
+       (GLfloat) 0.983916, (GLfloat) - 0.070836, (GLfloat) 0.163986,
+       (GLfloat) 0.855252, (GLfloat) - 0.072244, (GLfloat) 0.513152,
+       (GLfloat) 0.855252, (GLfloat) - 0.072245, (GLfloat) 0.513151,
+       (GLfloat) - 0.511275, (GLfloat) - 0.111719, (GLfloat) - 0.852125,
+       (GLfloat) - 0.511276, (GLfloat) - 0.111718, (GLfloat) - 0.852125,
+       (GLfloat) - 0.513151, (GLfloat) - 0.072245, (GLfloat) - 0.855252,
+       (GLfloat) - 0.513152, (GLfloat) - 0.072244, (GLfloat) - 0.855252,
+       (GLfloat) - 0.163986, (GLfloat) - 0.070836, (GLfloat) - 0.983916,
+       (GLfloat) - 0.163986, (GLfloat) - 0.070836, (GLfloat) - 0.983916,
+       (GLfloat) - 0.163409, (GLfloat) - 0.109554, (GLfloat) - 0.980457,
+       (GLfloat) - 0.163410, (GLfloat) - 0.109553, (GLfloat) - 0.980457,
+       (GLfloat) - 0.514444, (GLfloat) - 0.014299, (GLfloat) - 0.857405,
+       (GLfloat) - 0.514443, (GLfloat) - 0.014299, (GLfloat) - 0.857405,
+       (GLfloat) - 0.164382, (GLfloat) - 0.014019, (GLfloat) - 0.986297,
+       (GLfloat) - 0.164382, (GLfloat) - 0.014019, (GLfloat) - 0.986297,
+       (GLfloat) - 0.164261, (GLfloat) - 0.041017, (GLfloat) - 0.985564,
+       (GLfloat) - 0.164260, (GLfloat) - 0.041017, (GLfloat) - 0.985564,
+       (GLfloat) - 0.514045, (GLfloat) - 0.041836, (GLfloat) - 0.856742,
+       (GLfloat) - 0.514045, (GLfloat) - 0.041836, (GLfloat) - 0.856742,
+       (GLfloat) 0.514443, (GLfloat) - 0.014300, (GLfloat) - 0.857405,
+       (GLfloat) 0.514444, (GLfloat) - 0.014299, (GLfloat) - 0.857405,
+       (GLfloat) 0.514045, (GLfloat) - 0.041836, (GLfloat) - 0.856742,
+       (GLfloat) 0.514045, (GLfloat) - 0.041836, (GLfloat) - 0.856742,
+       (GLfloat) 0.164260, (GLfloat) - 0.041017, (GLfloat) - 0.985564,
+       (GLfloat) 0.164261, (GLfloat) - 0.041017, (GLfloat) - 0.985564,
+       (GLfloat) 0.164382, (GLfloat) - 0.014019, (GLfloat) - 0.986297,
+       (GLfloat) 0.164382, (GLfloat) - 0.014019, (GLfloat) - 0.986297,
+       (GLfloat) 0.511275, (GLfloat) - 0.111720, (GLfloat) - 0.852125,
+       (GLfloat) 0.511276, (GLfloat) - 0.111718, (GLfloat) - 0.852125,
+       (GLfloat) 0.163410, (GLfloat) - 0.109553, (GLfloat) - 0.980457,
+       (GLfloat) 0.163409, (GLfloat) - 0.109554, (GLfloat) - 0.980457,
+       (GLfloat) 0.163986, (GLfloat) - 0.070836, (GLfloat) - 0.983916,
+       (GLfloat) 0.163986, (GLfloat) - 0.070836, (GLfloat) - 0.983916,
+       (GLfloat) 0.513152, (GLfloat) - 0.072244, (GLfloat) - 0.855252,
+       (GLfloat) 0.513151, (GLfloat) - 0.072245, (GLfloat) - 0.855252,
+       (GLfloat) - 0.511275, (GLfloat) - 0.111719, (GLfloat) 0.852125,
+       (GLfloat) - 0.511275, (GLfloat) - 0.111719, (GLfloat) 0.852125,
+       (GLfloat) - 0.163410, (GLfloat) - 0.109554, (GLfloat) 0.980457,
+       (GLfloat) - 0.163409, (GLfloat) - 0.109555, (GLfloat) 0.980457,
+       (GLfloat) - 0.163986, (GLfloat) - 0.070835, (GLfloat) 0.983916,
+       (GLfloat) - 0.163986, (GLfloat) - 0.070835, (GLfloat) 0.983916,
+       (GLfloat) - 0.513151, (GLfloat) - 0.072244, (GLfloat) 0.855252,
+       (GLfloat) - 0.513151, (GLfloat) - 0.072245, (GLfloat) 0.855252,
+       (GLfloat) 0.511275, (GLfloat) - 0.111719, (GLfloat) 0.852125,
+       (GLfloat) 0.511275, (GLfloat) - 0.111719, (GLfloat) 0.852125,
+       (GLfloat) 0.513151, (GLfloat) - 0.072245, (GLfloat) 0.855252,
+       (GLfloat) 0.513151, (GLfloat) - 0.072244, (GLfloat) 0.855252,
+       (GLfloat) 0.163986, (GLfloat) - 0.070835, (GLfloat) 0.983916,
+       (GLfloat) 0.163986, (GLfloat) - 0.070835, (GLfloat) 0.983916,
+       (GLfloat) 0.163409, (GLfloat) - 0.109555, (GLfloat) 0.980457,
+       (GLfloat) 0.163410, (GLfloat) - 0.109554, (GLfloat) 0.980457,
+       (GLfloat) 0.514444, (GLfloat) - 0.014299, (GLfloat) 0.857405,
+       (GLfloat) 0.514443, (GLfloat) - 0.014299, (GLfloat) 0.857405,
+       (GLfloat) 0.164383, (GLfloat) - 0.014019, (GLfloat) 0.986297,
+       (GLfloat) 0.164383, (GLfloat) - 0.014019, (GLfloat) 0.986297,
+       (GLfloat) 0.164261, (GLfloat) - 0.041017, (GLfloat) 0.985564,
+       (GLfloat) 0.164261, (GLfloat) - 0.041017, (GLfloat) 0.985564,
+       (GLfloat) 0.514045, (GLfloat) - 0.041836, (GLfloat) 0.856742,
+       (GLfloat) 0.514045, (GLfloat) - 0.041836, (GLfloat) 0.856742,
+       (GLfloat) - 0.514443, (GLfloat) - 0.014299, (GLfloat) 0.857405,
+       (GLfloat) - 0.514443, (GLfloat) - 0.014299, (GLfloat) 0.857405,
+       (GLfloat) - 0.514045, (GLfloat) - 0.041836, (GLfloat) 0.856742,
+       (GLfloat) - 0.514045, (GLfloat) - 0.041836, (GLfloat) 0.856742,
+       (GLfloat) - 0.164261, (GLfloat) - 0.041017, (GLfloat) 0.985564,
+       (GLfloat) - 0.164261, (GLfloat) - 0.041017, (GLfloat) 0.985564,
+       (GLfloat) - 0.164383, (GLfloat) - 0.014019, (GLfloat) 0.986297,
+       (GLfloat) - 0.164383, (GLfloat) - 0.014019, (GLfloat) 0.986297,
+       (GLfloat) - 0.852125, (GLfloat) - 0.111719, (GLfloat) - 0.511275,
+       (GLfloat) - 0.852125, (GLfloat) - 0.111719, (GLfloat) - 0.511275,
+       (GLfloat) - 0.980457, (GLfloat) - 0.109554, (GLfloat) - 0.163410,
+       (GLfloat) - 0.980457, (GLfloat) - 0.109555, (GLfloat) - 0.163409,
+       (GLfloat) - 0.983916, (GLfloat) - 0.070835, (GLfloat) - 0.163986,
+       (GLfloat) - 0.983916, (GLfloat) - 0.070835, (GLfloat) - 0.163986,
+       (GLfloat) - 0.855252, (GLfloat) - 0.072244, (GLfloat) - 0.513151,
+       (GLfloat) - 0.855252, (GLfloat) - 0.072245, (GLfloat) - 0.513151,
+       (GLfloat) - 0.852125, (GLfloat) - 0.111719, (GLfloat) 0.511275,
+       (GLfloat) - 0.852125, (GLfloat) - 0.111719, (GLfloat) 0.511275,
+       (GLfloat) - 0.855252, (GLfloat) - 0.072245, (GLfloat) 0.513151,
+       (GLfloat) - 0.855252, (GLfloat) - 0.072244, (GLfloat) 0.513151,
+       (GLfloat) - 0.983916, (GLfloat) - 0.070835, (GLfloat) 0.163986,
+       (GLfloat) - 0.983916, (GLfloat) - 0.070835, (GLfloat) 0.163986,
+       (GLfloat) - 0.980457, (GLfloat) - 0.109555, (GLfloat) 0.163409,
+       (GLfloat) - 0.980457, (GLfloat) - 0.109554, (GLfloat) 0.163410,
+       (GLfloat) - 0.857405, (GLfloat) - 0.014299, (GLfloat) 0.514443,
+       (GLfloat) - 0.857405, (GLfloat) - 0.014299, (GLfloat) 0.514443,
+       (GLfloat) - 0.986297, (GLfloat) - 0.014019, (GLfloat) 0.164383,
+       (GLfloat) - 0.986297, (GLfloat) - 0.014019, (GLfloat) 0.164383,
+       (GLfloat) - 0.985564, (GLfloat) - 0.041017, (GLfloat) 0.164261,
+       (GLfloat) - 0.985564, (GLfloat) - 0.041017, (GLfloat) 0.164261,
+       (GLfloat) - 0.856742, (GLfloat) - 0.041836, (GLfloat) 0.514045,
+       (GLfloat) - 0.856742, (GLfloat) - 0.041836, (GLfloat) 0.514045,
+       (GLfloat) - 0.857405, (GLfloat) - 0.014299, (GLfloat) - 0.514443,
+       (GLfloat) - 0.857405, (GLfloat) - 0.014299, (GLfloat) - 0.514444,
+       (GLfloat) - 0.856742, (GLfloat) - 0.041836, (GLfloat) - 0.514045,
+       (GLfloat) - 0.856742, (GLfloat) - 0.041836, (GLfloat) - 0.514045,
+       (GLfloat) - 0.985564, (GLfloat) - 0.041017, (GLfloat) - 0.164261,
+       (GLfloat) - 0.985564, (GLfloat) - 0.041017, (GLfloat) - 0.164261,
+       (GLfloat) - 0.986297, (GLfloat) - 0.014019, (GLfloat) - 0.164383,
+       (GLfloat) - 0.986297, (GLfloat) - 0.014019, (GLfloat) - 0.164383,
+       (GLfloat) - 0.511714, (GLfloat) 0.103845, (GLfloat) - 0.852857,
+       (GLfloat) - 0.511715, (GLfloat) 0.103844, (GLfloat) - 0.852857,
+       (GLfloat) - 0.163545, (GLfloat) 0.101829, (GLfloat) - 0.981267,
+       (GLfloat) - 0.163544, (GLfloat) 0.101829, (GLfloat) - 0.981267,
+       (GLfloat) - 0.164038, (GLfloat) 0.066199, (GLfloat) - 0.984230,
+       (GLfloat) - 0.164039, (GLfloat) 0.066198, (GLfloat) - 0.984230,
+       (GLfloat) - 0.513322, (GLfloat) 0.067516, (GLfloat) - 0.855536,
+       (GLfloat) - 0.513322, (GLfloat) 0.067517, (GLfloat) - 0.855536,
+       (GLfloat) 0.511714, (GLfloat) 0.103845, (GLfloat) - 0.852857,
+       (GLfloat) 0.511715, (GLfloat) 0.103844, (GLfloat) - 0.852857,
+       (GLfloat) 0.513322, (GLfloat) 0.067517, (GLfloat) - 0.855536,
+       (GLfloat) 0.513322, (GLfloat) 0.067516, (GLfloat) - 0.855536,
+       (GLfloat) 0.164038, (GLfloat) 0.066199, (GLfloat) - 0.984230,
+       (GLfloat) 0.164039, (GLfloat) 0.066198, (GLfloat) - 0.984230,
+       (GLfloat) 0.163544, (GLfloat) 0.101829, (GLfloat) - 0.981267,
+       (GLfloat) 0.163545, (GLfloat) 0.101829, (GLfloat) - 0.981267,
+       (GLfloat) 0.514446, (GLfloat) 0.013998, (GLfloat) - 0.857409,
+       (GLfloat) 0.514445, (GLfloat) 0.013999, (GLfloat) - 0.857409,
+       (GLfloat) 0.164383, (GLfloat) 0.013724, (GLfloat) - 0.986301,
+       (GLfloat) 0.164383, (GLfloat) 0.013724, (GLfloat) - 0.986301,
+       (GLfloat) 0.164274, (GLfloat) 0.039013, (GLfloat) - 0.985643,
+       (GLfloat) 0.164273, (GLfloat) 0.039013, (GLfloat) - 0.985643,
+       (GLfloat) 0.514088, (GLfloat) 0.039792, (GLfloat) - 0.856814,
+       (GLfloat) 0.514088, (GLfloat) 0.039792, (GLfloat) - 0.856814,
+       (GLfloat) - 0.514445, (GLfloat) 0.013999, (GLfloat) - 0.857409,
+       (GLfloat) - 0.514446, (GLfloat) 0.013998, (GLfloat) - 0.857409,
+       (GLfloat) - 0.514088, (GLfloat) 0.039792, (GLfloat) - 0.856814,
+       (GLfloat) - 0.514088, (GLfloat) 0.039792, (GLfloat) - 0.856814,
+       (GLfloat) - 0.164273, (GLfloat) 0.039013, (GLfloat) - 0.985643,
+       (GLfloat) - 0.164274, (GLfloat) 0.039013, (GLfloat) - 0.985643,
+       (GLfloat) - 0.164383, (GLfloat) 0.013724, (GLfloat) - 0.986301,
+       (GLfloat) - 0.164383, (GLfloat) 0.013724, (GLfloat) - 0.986301,
+       (GLfloat) - 0.852857, (GLfloat) 0.103845, (GLfloat) - 0.511714,
+       (GLfloat) - 0.852857, (GLfloat) 0.103845, (GLfloat) - 0.511714,
+       (GLfloat) - 0.855536, (GLfloat) 0.067516, (GLfloat) - 0.513322,
+       (GLfloat) - 0.855536, (GLfloat) 0.067516, (GLfloat) - 0.513322,
+       (GLfloat) - 0.984230, (GLfloat) 0.066198, (GLfloat) - 0.164038,
+       (GLfloat) - 0.984230, (GLfloat) 0.066198, (GLfloat) - 0.164039,
+       (GLfloat) - 0.981266, (GLfloat) 0.101830, (GLfloat) - 0.163544,
+       (GLfloat) - 0.981266, (GLfloat) 0.101829, (GLfloat) - 0.163545,
+       (GLfloat) - 0.857409, (GLfloat) 0.013998, (GLfloat) - 0.514446,
+       (GLfloat) - 0.857409, (GLfloat) 0.013999, (GLfloat) - 0.514445,
+       (GLfloat) - 0.986301, (GLfloat) 0.013724, (GLfloat) - 0.164383,
+       (GLfloat) - 0.986301, (GLfloat) 0.013724, (GLfloat) - 0.164383,
+       (GLfloat) - 0.985643, (GLfloat) 0.039013, (GLfloat) - 0.164274,
+       (GLfloat) - 0.985643, (GLfloat) 0.039013, (GLfloat) - 0.164274,
+       (GLfloat) - 0.856814, (GLfloat) 0.039792, (GLfloat) - 0.514088,
+       (GLfloat) - 0.856814, (GLfloat) 0.039792, (GLfloat) - 0.514088,
+       (GLfloat) - 0.857409, (GLfloat) 0.013999, (GLfloat) 0.514445,
+       (GLfloat) - 0.857409, (GLfloat) 0.013998, (GLfloat) 0.514446,
+       (GLfloat) - 0.856814, (GLfloat) 0.039792, (GLfloat) 0.514088,
+       (GLfloat) - 0.856814, (GLfloat) 0.039792, (GLfloat) 0.514088,
+       (GLfloat) - 0.985643, (GLfloat) 0.039013, (GLfloat) 0.164274,
+       (GLfloat) - 0.985643, (GLfloat) 0.039013, (GLfloat) 0.164274,
+       (GLfloat) - 0.986301, (GLfloat) 0.013724, (GLfloat) 0.164383,
+       (GLfloat) - 0.986301, (GLfloat) 0.013724, (GLfloat) 0.164383,
+       (GLfloat) - 0.852857, (GLfloat) 0.103845, (GLfloat) 0.511714,
+       (GLfloat) - 0.852857, (GLfloat) 0.103845, (GLfloat) 0.511714,
+       (GLfloat) - 0.981266, (GLfloat) 0.101829, (GLfloat) 0.163545,
+       (GLfloat) - 0.981266, (GLfloat) 0.101830, (GLfloat) 0.163544,
+       (GLfloat) - 0.984230, (GLfloat) 0.066198, (GLfloat) 0.164038,
+       (GLfloat) - 0.984230, (GLfloat) 0.066198, (GLfloat) 0.164039,
+       (GLfloat) - 0.855536, (GLfloat) 0.067516, (GLfloat) 0.513322,
+       (GLfloat) - 0.855536, (GLfloat) 0.067516, (GLfloat) 0.513322,
+       (GLfloat) - 0.511714, (GLfloat) 0.103845, (GLfloat) 0.852857,
+       (GLfloat) - 0.511714, (GLfloat) 0.103845, (GLfloat) 0.852857,
+       (GLfloat) - 0.513322, (GLfloat) 0.067516, (GLfloat) 0.855536,
+       (GLfloat) - 0.513322, (GLfloat) 0.067516, (GLfloat) 0.855536,
+       (GLfloat) - 0.164038, (GLfloat) 0.066198, (GLfloat) 0.984230,
+       (GLfloat) - 0.164039, (GLfloat) 0.066198, (GLfloat) 0.984230,
+       (GLfloat) - 0.163544, (GLfloat) 0.101830, (GLfloat) 0.981266,
+       (GLfloat) - 0.163545, (GLfloat) 0.101829, (GLfloat) 0.981266,
+       (GLfloat) - 0.514446, (GLfloat) 0.013998, (GLfloat) 0.857409,
+       (GLfloat) - 0.514445, (GLfloat) 0.013999, (GLfloat) 0.857409,
+       (GLfloat) - 0.164383, (GLfloat) 0.013724, (GLfloat) 0.986301,
+       (GLfloat) - 0.164383, (GLfloat) 0.013724, (GLfloat) 0.986301,
+       (GLfloat) - 0.164274, (GLfloat) 0.039013, (GLfloat) 0.985643,
+       (GLfloat) - 0.164274, (GLfloat) 0.039013, (GLfloat) 0.985643,
+       (GLfloat) - 0.514088, (GLfloat) 0.039792, (GLfloat) 0.856814,
+       (GLfloat) - 0.514088, (GLfloat) 0.039792, (GLfloat) 0.856814,
+       (GLfloat) 0.514445, (GLfloat) 0.013999, (GLfloat) 0.857409,
+       (GLfloat) 0.514446, (GLfloat) 0.013998, (GLfloat) 0.857409,
+       (GLfloat) 0.514088, (GLfloat) 0.039792, (GLfloat) 0.856814,
+       (GLfloat) 0.514088, (GLfloat) 0.039792, (GLfloat) 0.856814,
+       (GLfloat) 0.164274, (GLfloat) 0.039013, (GLfloat) 0.985643,
+       (GLfloat) 0.164274, (GLfloat) 0.039013, (GLfloat) 0.985643,
+       (GLfloat) 0.164383, (GLfloat) 0.013724, (GLfloat) 0.986301,
+       (GLfloat) 0.164383, (GLfloat) 0.013724, (GLfloat) 0.986301,
+       (GLfloat) 0.511714, (GLfloat) 0.103845, (GLfloat) 0.852857,
+       (GLfloat) 0.511714, (GLfloat) 0.103845, (GLfloat) 0.852857,
+       (GLfloat) 0.163545, (GLfloat) 0.101829, (GLfloat) 0.981266,
+       (GLfloat) 0.163544, (GLfloat) 0.101830, (GLfloat) 0.981266,
+       (GLfloat) 0.164038, (GLfloat) 0.066198, (GLfloat) 0.984230,
+       (GLfloat) 0.164039, (GLfloat) 0.066198, (GLfloat) 0.984230,
+       (GLfloat) 0.513322, (GLfloat) 0.067516, (GLfloat) 0.855536,
+       (GLfloat) 0.513322, (GLfloat) 0.067516, (GLfloat) 0.855536,
+       (GLfloat) 0.852857, (GLfloat) 0.103845, (GLfloat) 0.511714,
+       (GLfloat) 0.852857, (GLfloat) 0.103844, (GLfloat) 0.511715,
+       (GLfloat) 0.855536, (GLfloat) 0.067517, (GLfloat) 0.513322,
+       (GLfloat) 0.855536, (GLfloat) 0.067516, (GLfloat) 0.513322,
+       (GLfloat) 0.984230, (GLfloat) 0.066199, (GLfloat) 0.164038,
+       (GLfloat) 0.984230, (GLfloat) 0.066198, (GLfloat) 0.164039,
+       (GLfloat) 0.981267, (GLfloat) 0.101829, (GLfloat) 0.163544,
+       (GLfloat) 0.981267, (GLfloat) 0.101829, (GLfloat) 0.163545,
+       (GLfloat) 0.857409, (GLfloat) 0.013998, (GLfloat) 0.514446,
+       (GLfloat) 0.857409, (GLfloat) 0.013999, (GLfloat) 0.514445,
+       (GLfloat) 0.986301, (GLfloat) 0.013724, (GLfloat) 0.164383,
+       (GLfloat) 0.986301, (GLfloat) 0.013724, (GLfloat) 0.164383,
+       (GLfloat) 0.985643, (GLfloat) 0.039013, (GLfloat) 0.164274,
+       (GLfloat) 0.985643, (GLfloat) 0.039013, (GLfloat) 0.164273,
+       (GLfloat) 0.856814, (GLfloat) 0.039792, (GLfloat) 0.514088,
+       (GLfloat) 0.856814, (GLfloat) 0.039792, (GLfloat) 0.514088,
+       (GLfloat) 0.857409, (GLfloat) 0.013999, (GLfloat) - 0.514445,
+       (GLfloat) 0.857409, (GLfloat) 0.013998, (GLfloat) - 0.514446,
+       (GLfloat) 0.856814, (GLfloat) 0.039792, (GLfloat) - 0.514088,
+       (GLfloat) 0.856814, (GLfloat) 0.039792, (GLfloat) - 0.514088,
+       (GLfloat) 0.985643, (GLfloat) 0.039013, (GLfloat) - 0.164273,
+       (GLfloat) 0.985643, (GLfloat) 0.039013, (GLfloat) - 0.164274,
+       (GLfloat) 0.986301, (GLfloat) 0.013724, (GLfloat) - 0.164383,
+       (GLfloat) 0.986301, (GLfloat) 0.013724, (GLfloat) - 0.164383,
+       (GLfloat) 0.852857, (GLfloat) 0.103845, (GLfloat) - 0.511714,
+       (GLfloat) 0.852857, (GLfloat) 0.103844, (GLfloat) - 0.511715,
+       (GLfloat) 0.981267, (GLfloat) 0.101829, (GLfloat) - 0.163545,
+       (GLfloat) 0.981267, (GLfloat) 0.101829, (GLfloat) - 0.163544,
+       (GLfloat) 0.984230, (GLfloat) 0.066199, (GLfloat) - 0.164038,
+       (GLfloat) 0.984230, (GLfloat) 0.066198, (GLfloat) - 0.164039,
+       (GLfloat) 0.855536, (GLfloat) 0.067516, (GLfloat) - 0.513322,
+       (GLfloat) 0.855536, (GLfloat) 0.067517, (GLfloat) - 0.513322,
+       (GLfloat) 0.845633, (GLfloat) 0.165745, (GLfloat) 0.507379,
+       (GLfloat) 0.845633, (GLfloat) 0.165745, (GLfloat) 0.507379,
+       (GLfloat) 0.973270, (GLfloat) 0.162582, (GLfloat) 0.162211,
+       (GLfloat) 0.973270, (GLfloat) 0.162582, (GLfloat) 0.162212,
+       (GLfloat) 0.985759, (GLfloat) 0.022905, (GLfloat) 0.166594,
+       (GLfloat) 0.986250, (GLfloat) 0.017105, (GLfloat) 0.164375,
+       (GLfloat) 0.856160, (GLfloat) 0.009467, (GLfloat) 0.516625,
+       (GLfloat) 0.857388, (GLfloat) 0.015640, (GLfloat) 0.514433,
+       (GLfloat) 0.845633, (GLfloat) 0.165745, (GLfloat) - 0.507380,
+       (GLfloat) 0.845633, (GLfloat) 0.165745, (GLfloat) - 0.507379,
+       (GLfloat) 0.856160, (GLfloat) 0.009468, (GLfloat) - 0.516624,
+       (GLfloat) 0.857388, (GLfloat) 0.015640, (GLfloat) - 0.514433,
+       (GLfloat) 0.985759, (GLfloat) 0.022905, (GLfloat) - 0.166594,
+       (GLfloat) 0.986250, (GLfloat) 0.017105, (GLfloat) - 0.164375,
+       (GLfloat) 0.973270, (GLfloat) 0.162582, (GLfloat) - 0.162211,
+       (GLfloat) 0.973270, (GLfloat) 0.162582, (GLfloat) - 0.162212,
+       (GLfloat) 0.283621, (GLfloat) - 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) 0.264056, (GLfloat) - 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) 0.315105, (GLfloat) - 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) 0.304029, (GLfloat) - 0.949849, (GLfloat) - 0.073162,
+       (GLfloat) 0.789686, (GLfloat) - 0.598377, (GLfloat) - 0.135427,
+       (GLfloat) 0.809934, (GLfloat) - 0.566659, (GLfloat) - 0.151344,
+       (GLfloat) 0.656717, (GLfloat) - 0.640092, (GLfloat) - 0.398754,
+       (GLfloat) 0.671170, (GLfloat) - 0.608876, (GLfloat) - 0.422849,
+       (GLfloat) 0.264055, (GLfloat) - 0.947923, (GLfloat) 0.178092,
+       (GLfloat) 0.283621, (GLfloat) - 0.936578, (GLfloat) 0.205866,
+       (GLfloat) 0.656718, (GLfloat) - 0.640092, (GLfloat) 0.398754,
+       (GLfloat) 0.671170, (GLfloat) - 0.608876, (GLfloat) 0.422849,
+       (GLfloat) 0.809934, (GLfloat) - 0.566659, (GLfloat) 0.151344,
+       (GLfloat) 0.789686, (GLfloat) - 0.598377, (GLfloat) 0.135427,
+       (GLfloat) 0.304029, (GLfloat) - 0.949849, (GLfloat) 0.073162,
+       (GLfloat) 0.315105, (GLfloat) - 0.946548, (GLfloat) 0.068965,
+       (GLfloat) 0.507379, (GLfloat) 0.165745, (GLfloat) - 0.845633,
+       (GLfloat) 0.507380, (GLfloat) 0.165745, (GLfloat) - 0.845633,
+       (GLfloat) 0.162211, (GLfloat) 0.162582, (GLfloat) - 0.973270,
+       (GLfloat) 0.162212, (GLfloat) 0.162582, (GLfloat) - 0.973270,
+       (GLfloat) 0.166594, (GLfloat) 0.022905, (GLfloat) - 0.985759,
+       (GLfloat) 0.164375, (GLfloat) 0.017105, (GLfloat) - 0.986250,
+       (GLfloat) 0.516624, (GLfloat) 0.009468, (GLfloat) - 0.856160,
+       (GLfloat) 0.514433, (GLfloat) 0.015640, (GLfloat) - 0.857388,
+       (GLfloat) - 0.507379, (GLfloat) 0.165745, (GLfloat) - 0.845633,
+       (GLfloat) - 0.507379, (GLfloat) 0.165745, (GLfloat) - 0.845633,
+       (GLfloat) - 0.516625, (GLfloat) 0.009467, (GLfloat) - 0.856160,
+       (GLfloat) - 0.514433, (GLfloat) 0.015640, (GLfloat) - 0.857388,
+       (GLfloat) - 0.166594, (GLfloat) 0.022905, (GLfloat) - 0.985759,
+       (GLfloat) - 0.164375, (GLfloat) 0.017105, (GLfloat) - 0.986250,
+       (GLfloat) - 0.162211, (GLfloat) 0.162582, (GLfloat) - 0.973270,
+       (GLfloat) - 0.162212, (GLfloat) 0.162582, (GLfloat) - 0.973270,
+       (GLfloat) - 0.205866, (GLfloat) - 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) - 0.178092, (GLfloat) - 0.947923, (GLfloat) - 0.264055,
+       (GLfloat) - 0.068965, (GLfloat) - 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) - 0.073162, (GLfloat) - 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) - 0.135427, (GLfloat) - 0.598377, (GLfloat) - 0.789686,
+       (GLfloat) - 0.151344, (GLfloat) - 0.566659, (GLfloat) - 0.809934,
+       (GLfloat) - 0.398754, (GLfloat) - 0.640092, (GLfloat) - 0.656718,
+       (GLfloat) - 0.422849, (GLfloat) - 0.608876, (GLfloat) - 0.671170,
+       (GLfloat) 0.178092, (GLfloat) - 0.947923, (GLfloat) - 0.264056,
+       (GLfloat) 0.205866, (GLfloat) - 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) 0.398754, (GLfloat) - 0.640092, (GLfloat) - 0.656717,
+       (GLfloat) 0.422849, (GLfloat) - 0.608876, (GLfloat) - 0.671170,
+       (GLfloat) 0.151344, (GLfloat) - 0.566659, (GLfloat) - 0.809934,
+       (GLfloat) 0.135427, (GLfloat) - 0.598377, (GLfloat) - 0.789686,
+       (GLfloat) 0.073162, (GLfloat) - 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) 0.068965, (GLfloat) - 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) - 0.845633, (GLfloat) 0.165746, (GLfloat) - 0.507379,
+       (GLfloat) - 0.845632, (GLfloat) 0.165746, (GLfloat) - 0.507380,
+       (GLfloat) - 0.973270, (GLfloat) 0.162582, (GLfloat) - 0.162211,
+       (GLfloat) - 0.973270, (GLfloat) 0.162582, (GLfloat) - 0.162212,
+       (GLfloat) - 0.985759, (GLfloat) 0.022905, (GLfloat) - 0.166594,
+       (GLfloat) - 0.986250, (GLfloat) 0.017105, (GLfloat) - 0.164375,
+       (GLfloat) - 0.856160, (GLfloat) 0.009467, (GLfloat) - 0.516625,
+       (GLfloat) - 0.857388, (GLfloat) 0.015640, (GLfloat) - 0.514433,
+       (GLfloat) - 0.845633, (GLfloat) 0.165746, (GLfloat) 0.507379,
+       (GLfloat) - 0.845632, (GLfloat) 0.165746, (GLfloat) 0.507380,
+       (GLfloat) - 0.856159, (GLfloat) 0.009466, (GLfloat) 0.516625,
+       (GLfloat) - 0.857388, (GLfloat) 0.015640, (GLfloat) 0.514433,
+       (GLfloat) - 0.985759, (GLfloat) 0.022905, (GLfloat) 0.166594,
+       (GLfloat) - 0.986250, (GLfloat) 0.017105, (GLfloat) 0.164375,
+       (GLfloat) - 0.973270, (GLfloat) 0.162582, (GLfloat) 0.162211,
+       (GLfloat) - 0.973270, (GLfloat) 0.162582, (GLfloat) 0.162212,
+       (GLfloat) - 0.283620, (GLfloat) - 0.936578, (GLfloat) 0.205866,
+       (GLfloat) - 0.264055, (GLfloat) - 0.947923, (GLfloat) 0.178091,
+       (GLfloat) - 0.315105, (GLfloat) - 0.946548, (GLfloat) 0.068965,
+       (GLfloat) - 0.304029, (GLfloat) - 0.949849, (GLfloat) 0.073162,
+       (GLfloat) - 0.789686, (GLfloat) - 0.598377, (GLfloat) 0.135427,
+       (GLfloat) - 0.809934, (GLfloat) - 0.566659, (GLfloat) 0.151344,
+       (GLfloat) - 0.656718, (GLfloat) - 0.640090, (GLfloat) 0.398755,
+       (GLfloat) - 0.671170, (GLfloat) - 0.608876, (GLfloat) 0.422848,
+       (GLfloat) - 0.264055, (GLfloat) - 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) - 0.283620, (GLfloat) - 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) - 0.656718, (GLfloat) - 0.640091, (GLfloat) - 0.398755,
+       (GLfloat) - 0.671170, (GLfloat) - 0.608876, (GLfloat) - 0.422848,
+       (GLfloat) - 0.809934, (GLfloat) - 0.566659, (GLfloat) - 0.151344,
+       (GLfloat) - 0.789686, (GLfloat) - 0.598377, (GLfloat) - 0.135427,
+       (GLfloat) - 0.304029, (GLfloat) - 0.949849, (GLfloat) - 0.073163,
+       (GLfloat) - 0.315105, (GLfloat) - 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) - 0.507380, (GLfloat) 0.165746, (GLfloat) 0.845632,
+       (GLfloat) - 0.507379, (GLfloat) 0.165746, (GLfloat) 0.845633,
+       (GLfloat) - 0.162211, (GLfloat) 0.162582, (GLfloat) 0.973270,
+       (GLfloat) - 0.162212, (GLfloat) 0.162582, (GLfloat) 0.973270,
+       (GLfloat) - 0.166594, (GLfloat) 0.022905, (GLfloat) 0.985759,
+       (GLfloat) - 0.164375, (GLfloat) 0.017105, (GLfloat) 0.986250,
+       (GLfloat) - 0.516625, (GLfloat) 0.009466, (GLfloat) 0.856159,
+       (GLfloat) - 0.514433, (GLfloat) 0.015640, (GLfloat) 0.857388,
+       (GLfloat) 0.507380, (GLfloat) 0.165746, (GLfloat) 0.845632,
+       (GLfloat) 0.507379, (GLfloat) 0.165746, (GLfloat) 0.845633,
+       (GLfloat) 0.516625, (GLfloat) 0.009467, (GLfloat) 0.856160,
+       (GLfloat) 0.514433, (GLfloat) 0.015640, (GLfloat) 0.857388,
+       (GLfloat) 0.166594, (GLfloat) 0.022905, (GLfloat) 0.985759,
+       (GLfloat) 0.164375, (GLfloat) 0.017105, (GLfloat) 0.986250,
+       (GLfloat) 0.162211, (GLfloat) 0.162582, (GLfloat) 0.973270,
+       (GLfloat) 0.162212, (GLfloat) 0.162582, (GLfloat) 0.973270,
+       (GLfloat) 0.205866, (GLfloat) - 0.936578, (GLfloat) 0.283620,
+       (GLfloat) 0.178092, (GLfloat) - 0.947923, (GLfloat) 0.264055,
+       (GLfloat) 0.068965, (GLfloat) - 0.946548, (GLfloat) 0.315105,
+       (GLfloat) 0.073163, (GLfloat) - 0.949849, (GLfloat) 0.304029,
+       (GLfloat) 0.135427, (GLfloat) - 0.598377, (GLfloat) 0.789686,
+       (GLfloat) 0.151344, (GLfloat) - 0.566659, (GLfloat) 0.809934,
+       (GLfloat) 0.398755, (GLfloat) - 0.640091, (GLfloat) 0.656718,
+       (GLfloat) 0.422848, (GLfloat) - 0.608876, (GLfloat) 0.671170,
+       (GLfloat) - 0.178091, (GLfloat) - 0.947923, (GLfloat) 0.264055,
+       (GLfloat) - 0.205866, (GLfloat) - 0.936578, (GLfloat) 0.283620,
+       (GLfloat) - 0.398755, (GLfloat) - 0.640090, (GLfloat) 0.656718,
+       (GLfloat) - 0.422848, (GLfloat) - 0.608876, (GLfloat) 0.671170,
+       (GLfloat) - 0.151344, (GLfloat) - 0.566659, (GLfloat) 0.809934,
+       (GLfloat) - 0.135427, (GLfloat) - 0.598377, (GLfloat) 0.789686,
+       (GLfloat) - 0.073162, (GLfloat) - 0.949849, (GLfloat) 0.304029,
+       (GLfloat) - 0.068965, (GLfloat) - 0.946548, (GLfloat) 0.315105,
+       (GLfloat) 0.135802, (GLfloat) - 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) 0.124011, (GLfloat) - 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) 0.043834, (GLfloat) - 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) 0.039656, (GLfloat) - 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) 0.030163, (GLfloat) - 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) 0.033079, (GLfloat) - 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) 0.109621, (GLfloat) - 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) 0.114709, (GLfloat) - 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) - 0.124011, (GLfloat) - 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) - 0.135802, (GLfloat) - 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) - 0.109621, (GLfloat) - 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) - 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) - 0.033079, (GLfloat) - 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) - 0.030163, (GLfloat) - 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) - 0.043834, (GLfloat) - 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) - 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) - 0.135802, (GLfloat) - 0.982944, (GLfloat) 0.124011,
+       (GLfloat) - 0.124011, (GLfloat) - 0.982944, (GLfloat) 0.135802,
+       (GLfloat) - 0.043834, (GLfloat) - 0.993006, (GLfloat) 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) - 0.992607, (GLfloat) 0.114709,
+       (GLfloat) - 0.030163, (GLfloat) - 0.998998, (GLfloat) 0.033079,
+       (GLfloat) - 0.033079, (GLfloat) - 0.998998, (GLfloat) 0.030163,
+       (GLfloat) - 0.109621, (GLfloat) - 0.993006, (GLfloat) 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) - 0.992607, (GLfloat) 0.039656,
+       (GLfloat) 0.124011, (GLfloat) - 0.982944, (GLfloat) 0.135802,
+       (GLfloat) 0.135802, (GLfloat) - 0.982944, (GLfloat) 0.124011,
+       (GLfloat) 0.109621, (GLfloat) - 0.993006, (GLfloat) 0.043834,
+       (GLfloat) 0.114709, (GLfloat) - 0.992607, (GLfloat) 0.039656,
+       (GLfloat) 0.033079, (GLfloat) - 0.998998, (GLfloat) 0.030163,
+       (GLfloat) 0.030163, (GLfloat) - 0.998998, (GLfloat) 0.033079,
+       (GLfloat) 0.043834, (GLfloat) - 0.993006, (GLfloat) 0.109621,
+       (GLfloat) 0.039656, (GLfloat) - 0.992607, (GLfloat) 0.114709,
+};
+
+static unsigned short int s1_1_POLS[] =
+{
+      3, 12, 76, 74, 1, 3, 12, 74, 82, 1, 3, 76, 22, 78, 1, 3, 78, 74, 76, 1,
+      3, 78, 20, 80, 1, 3, 80, 74, 78, 1, 3, 80, 28, 82, 1, 3, 82, 74, 80, 1,
+      3, 13, 84, 77, 1, 3, 13, 77, 88, 1, 3, 84, 24, 86, 1, 3, 86, 77, 84, 1,
+      3, 86, 20, 78, 1, 3, 78, 77, 86, 1, 3, 78, 22, 88, 1, 3, 88, 77, 78, 1,
+      3, 14, 90, 85, 1, 3, 14, 85, 93, 1, 3, 26, 91, 85, 1, 3, 26, 85, 90, 1,
+      3, 20, 86, 85, 1, 3, 20, 85, 91, 1, 3, 86, 24, 93, 1, 3, 93, 85, 86, 1,
+      3, 15, 95, 79, 1, 3, 15, 79, 97, 1, 3, 95, 28, 80, 1, 3, 80, 79, 95, 1,
+      3, 20, 91, 79, 1, 3, 20, 79, 80, 1, 3, 26, 97, 79, 1, 3, 26, 79, 91, 1,
+    3, 13, 99, 83, 1, 3, 13, 83, 84, 1, 3, 99, 30, 101, 1, 3, 101, 83, 99, 1,
+3, 101, 23, 102, 1, 3, 102, 83, 101, 1, 3, 102, 24, 84, 1, 3, 84, 83, 102, 1,
+       3, 16, 104, 100, 1, 3, 16, 100, 108, 1, 3, 104, 32, 106, 1, 3, 106, 100, 104, 1,
+       3, 106, 23, 101, 1, 3, 101, 100, 106, 1, 3, 101, 30, 108, 1, 3, 108, 100, 101, 1,
+       3, 17, 110, 105, 1, 3, 17, 105, 113, 1, 3, 33, 111, 105, 1, 3, 33, 105, 110, 1,
+       3, 23, 106, 105, 1, 3, 23, 105, 111, 1, 3, 106, 32, 113, 1, 3, 113, 105, 106, 1,
+   3, 14, 93, 92, 1, 3, 14, 92, 114, 1, 3, 93, 24, 102, 1, 3, 102, 92, 93, 1,
+  3, 23, 111, 92, 1, 3, 23, 92, 102, 1, 3, 33, 114, 92, 1, 3, 33, 92, 111, 1,
+       3, 16, 116, 103, 1, 3, 16, 103, 104, 1, 3, 116, 35, 118, 1, 3, 118, 103, 116, 1,
+       3, 118, 31, 119, 1, 3, 119, 103, 118, 1, 3, 119, 32, 104, 1, 3, 104, 103, 119, 1,
+       3, 18, 121, 117, 1, 3, 18, 117, 125, 1, 3, 121, 36, 123, 1, 3, 123, 117, 121, 1,
+       3, 123, 31, 118, 1, 3, 118, 117, 123, 1, 3, 118, 35, 125, 1, 3, 125, 117, 118, 1,
+       3, 19, 127, 122, 1, 3, 19, 122, 130, 1, 3, 37, 128, 122, 1, 3, 37, 122, 127, 1,
+       3, 31, 123, 122, 1, 3, 31, 122, 128, 1, 3, 123, 36, 130, 1, 3, 130, 122, 123, 1,
+       3, 17, 113, 112, 1, 3, 17, 112, 131, 1, 3, 113, 32, 119, 1, 3, 119, 112, 113, 1,
+       3, 31, 128, 112, 1, 3, 31, 112, 119, 1, 3, 37, 131, 112, 1, 3, 37, 112, 128, 1,
+       3, 18, 133, 120, 1, 3, 18, 120, 121, 1, 3, 133, 39, 134, 1, 3, 134, 120, 133, 1,
+       3, 134, 27, 135, 1, 3, 135, 120, 134, 1, 3, 135, 36, 121, 1, 3, 121, 120, 135, 1,
+   3, 12, 82, 81, 1, 3, 12, 81, 138, 1, 3, 82, 28, 136, 1, 3, 136, 81, 82, 1,
+       3, 136, 27, 134, 1, 3, 134, 81, 136, 1, 3, 134, 39, 138, 1, 3, 138, 81, 134, 1,
+   3, 15, 139, 94, 1, 3, 15, 94, 95, 1, 3, 40, 140, 94, 1, 3, 40, 94, 139, 1,
+  3, 27, 136, 94, 1, 3, 27, 94, 140, 1, 3, 136, 28, 95, 1, 3, 95, 94, 136, 1,
+       3, 19, 130, 129, 1, 3, 19, 129, 141, 1, 3, 130, 36, 135, 1, 3, 135, 129, 130, 1,
+       3, 27, 140, 129, 1, 3, 27, 129, 135, 1, 3, 40, 141, 129, 1, 3, 40, 129, 140, 1,
+ 3, 14, 114, 89, 1, 3, 14, 89, 90, 1, 3, 114, 33, 142, 1, 3, 142, 89, 114, 1,
+  3, 25, 143, 89, 1, 3, 25, 89, 142, 1, 3, 143, 26, 90, 1, 3, 90, 89, 143, 1,
+       3, 17, 131, 109, 1, 3, 17, 109, 110, 1, 3, 131, 37, 144, 1, 3, 144, 109, 131, 1,
+       3, 25, 142, 109, 1, 3, 25, 109, 144, 1, 3, 142, 33, 110, 1, 3, 110, 109, 142, 1,
+       3, 19, 141, 126, 1, 3, 19, 126, 127, 1, 3, 141, 40, 145, 1, 3, 145, 126, 141, 1,
+       3, 25, 144, 126, 1, 3, 25, 126, 145, 1, 3, 144, 37, 127, 1, 3, 127, 126, 144, 1,
+   3, 15, 97, 96, 1, 3, 15, 96, 139, 1, 3, 97, 26, 143, 1, 3, 143, 96, 97, 1,
+3, 25, 145, 96, 1, 3, 25, 96, 143, 1, 3, 145, 40, 139, 1, 3, 139, 96, 145, 1,
+  3, 76, 12, 146, 1, 3, 146, 75, 76, 1, 3, 41, 148, 75, 1, 3, 41, 75, 146, 1,
+ 3, 148, 21, 149, 1, 3, 149, 75, 148, 1, 3, 22, 76, 75, 1, 3, 22, 75, 149, 1,
+3, 8, 151, 147, 1, 3, 8, 147, 155, 1, 3, 151, 43, 153, 1, 3, 153, 147, 151, 1,
+       3, 21, 148, 147, 1, 3, 21, 147, 153, 1, 3, 148, 41, 155, 1, 3, 155, 147, 148, 1,
+       3, 11, 157, 152, 1, 3, 11, 152, 160, 1, 3, 157, 44, 158, 1, 3, 158, 152, 157, 1,
+       3, 21, 153, 152, 1, 3, 21, 152, 158, 1, 3, 153, 43, 160, 1, 3, 160, 152, 153, 1,
+   3, 161, 13, 88, 1, 3, 88, 87, 161, 1, 3, 22, 149, 87, 1, 3, 22, 87, 88, 1,
+3, 149, 21, 158, 1, 3, 158, 87, 149, 1, 3, 44, 161, 87, 1, 3, 44, 87, 158, 1,
+       3, 133, 18, 162, 1, 3, 162, 132, 133, 1, 3, 45, 164, 132, 1, 3, 45, 132, 162, 1,
+       3, 164, 38, 165, 1, 3, 165, 132, 164, 1, 3, 39, 133, 132, 1, 3, 39, 132, 165, 1,
+3, 9, 167, 163, 1, 3, 9, 163, 170, 1, 3, 167, 47, 168, 1, 3, 168, 163, 167, 1,
+       3, 38, 164, 163, 1, 3, 38, 163, 168, 1, 3, 164, 45, 170, 1, 3, 170, 163, 164, 1,
+3, 8, 155, 154, 1, 3, 8, 154, 173, 1, 3, 155, 41, 171, 1, 3, 171, 154, 155, 1,
+       3, 38, 168, 154, 1, 3, 38, 154, 171, 1, 3, 168, 47, 173, 1, 3, 173, 154, 168, 1,
+       3, 146, 12, 138, 1, 3, 138, 137, 146, 1, 3, 39, 165, 137, 1, 3, 39, 137, 138, 1,
+       3, 165, 38, 171, 1, 3, 171, 137, 165, 1, 3, 41, 146, 137, 1, 3, 41, 137, 171, 1,
+       3, 177, 16, 108, 1, 3, 108, 107, 177, 1, 3, 30, 174, 107, 1, 3, 30, 107, 108, 1,
+       3, 174, 29, 176, 1, 3, 176, 107, 174, 1, 3, 50, 177, 107, 1, 3, 50, 107, 176, 1,
+  3, 99, 13, 161, 1, 3, 161, 98, 99, 1, 3, 44, 178, 98, 1, 3, 44, 98, 161, 1,
+ 3, 178, 29, 174, 1, 3, 174, 98, 178, 1, 3, 30, 99, 98, 1, 3, 30, 98, 174, 1,
+       3, 11, 180, 156, 1, 3, 11, 156, 157, 1, 3, 180, 49, 181, 1, 3, 181, 156, 180, 1,
+       3, 29, 178, 156, 1, 3, 29, 156, 181, 1, 3, 178, 44, 157, 1, 3, 157, 156, 178, 1,
+       3, 10, 183, 175, 1, 3, 10, 175, 185, 1, 3, 183, 50, 176, 1, 3, 176, 175, 183, 1,
+       3, 29, 181, 175, 1, 3, 29, 175, 176, 1, 3, 181, 49, 185, 1, 3, 185, 175, 181, 1,
+       3, 162, 18, 125, 1, 3, 125, 124, 162, 1, 3, 35, 186, 124, 1, 3, 35, 124, 125, 1,
+       3, 186, 34, 187, 1, 3, 187, 124, 186, 1, 3, 45, 162, 124, 1, 3, 45, 124, 187, 1,
+       3, 116, 16, 177, 1, 3, 177, 115, 116, 1, 3, 50, 188, 115, 1, 3, 50, 115, 177, 1,
+       3, 188, 34, 186, 1, 3, 186, 115, 188, 1, 3, 35, 116, 115, 1, 3, 35, 115, 186, 1,
+       3, 10, 190, 182, 1, 3, 10, 182, 183, 1, 3, 190, 52, 191, 1, 3, 191, 182, 190, 1,
+       3, 34, 188, 182, 1, 3, 34, 182, 191, 1, 3, 188, 50, 183, 1, 3, 183, 182, 188, 1,
+3, 9, 170, 169, 1, 3, 9, 169, 193, 1, 3, 170, 45, 187, 1, 3, 187, 169, 170, 1,
+       3, 34, 191, 169, 1, 3, 34, 169, 187, 1, 3, 191, 52, 193, 1, 3, 193, 169, 191, 1,
+       3, 201, 1, 196, 1, 3, 196, 194, 201, 1, 3, 54, 198, 194, 1, 3, 54, 194, 196, 1,
+       3, 198, 46, 199, 1, 3, 199, 194, 198, 1, 3, 56, 201, 194, 1, 3, 56, 194, 199, 1,
+       3, 206, 3, 203, 1, 3, 203, 197, 206, 1, 3, 55, 204, 197, 1, 3, 55, 197, 203, 1,
+       3, 204, 46, 198, 1, 3, 198, 197, 204, 1, 3, 54, 206, 197, 1, 3, 54, 197, 198, 1,
+3, 8, 173, 172, 1, 3, 8, 172, 208, 1, 3, 173, 47, 207, 1, 3, 207, 172, 173, 1,
+       3, 46, 204, 172, 1, 3, 46, 172, 207, 1, 3, 204, 55, 208, 1, 3, 208, 172, 204, 1,
+3, 9, 209, 166, 1, 3, 9, 166, 167, 1, 3, 209, 56, 199, 1, 3, 199, 166, 209, 1,
+       3, 46, 207, 166, 1, 3, 46, 166, 199, 1, 3, 207, 47, 167, 1, 3, 167, 166, 207, 1,
+       3, 214, 1, 201, 1, 3, 201, 200, 214, 1, 3, 56, 210, 200, 1, 3, 56, 200, 201, 1,
+       3, 210, 51, 212, 1, 3, 212, 200, 210, 1, 3, 59, 214, 200, 1, 3, 59, 200, 212, 1,
+3, 9, 193, 192, 1, 3, 9, 192, 209, 1, 3, 193, 52, 215, 1, 3, 215, 192, 193, 1,
+       3, 51, 210, 192, 1, 3, 51, 192, 215, 1, 3, 210, 56, 209, 1, 3, 209, 192, 210, 1,
+       3, 10, 216, 189, 1, 3, 10, 189, 190, 1, 3, 216, 57, 217, 1, 3, 217, 189, 216, 1,
+       3, 51, 215, 189, 1, 3, 51, 189, 217, 1, 3, 215, 52, 190, 1, 3, 190, 189, 215, 1,
+       3, 221, 0, 219, 1, 3, 219, 211, 221, 1, 3, 59, 212, 211, 1, 3, 59, 211, 219, 1,
+       3, 212, 51, 217, 1, 3, 217, 211, 212, 1, 3, 57, 221, 211, 1, 3, 57, 211, 217, 1,
+       3, 226, 0, 221, 1, 3, 221, 220, 226, 1, 3, 57, 222, 220, 1, 3, 57, 220, 221, 1,
+       3, 222, 48, 224, 1, 3, 224, 220, 222, 1, 3, 62, 226, 220, 1, 3, 62, 220, 224, 1,
+       3, 10, 185, 184, 1, 3, 10, 184, 216, 1, 3, 185, 49, 227, 1, 3, 227, 184, 185, 1,
+       3, 48, 222, 184, 1, 3, 48, 184, 227, 1, 3, 222, 57, 216, 1, 3, 216, 184, 222, 1,
+       3, 11, 228, 179, 1, 3, 11, 179, 180, 1, 3, 228, 60, 229, 1, 3, 229, 179, 228, 1,
+       3, 48, 227, 179, 1, 3, 48, 179, 229, 1, 3, 227, 49, 180, 1, 3, 180, 179, 227, 1,
+       3, 233, 2, 231, 1, 3, 231, 223, 233, 1, 3, 62, 224, 223, 1, 3, 62, 223, 231, 1,
+       3, 224, 48, 229, 1, 3, 229, 223, 224, 1, 3, 60, 233, 223, 1, 3, 60, 223, 229, 1,
+       3, 237, 2, 233, 1, 3, 233, 232, 237, 1, 3, 60, 234, 232, 1, 3, 60, 232, 233, 1,
+       3, 234, 42, 235, 1, 3, 235, 232, 234, 1, 3, 64, 237, 232, 1, 3, 64, 232, 235, 1,
+       3, 11, 160, 159, 1, 3, 11, 159, 228, 1, 3, 160, 43, 238, 1, 3, 238, 159, 160, 1,
+       3, 42, 234, 159, 1, 3, 42, 159, 238, 1, 3, 234, 60, 228, 1, 3, 228, 159, 234, 1,
+3, 8, 208, 150, 1, 3, 8, 150, 151, 1, 3, 208, 55, 239, 1, 3, 239, 150, 208, 1,
+       3, 42, 238, 150, 1, 3, 42, 150, 239, 1, 3, 238, 43, 151, 1, 3, 151, 150, 238, 1,
+       3, 203, 3, 241, 1, 3, 241, 202, 203, 1, 3, 64, 235, 202, 1, 3, 64, 202, 241, 1,
+       3, 235, 42, 239, 1, 3, 239, 202, 235, 1, 3, 55, 203, 202, 1, 3, 55, 202, 239, 1,
+3, 2, 237, 236, 1, 3, 2, 236, 245, 1, 3, 237, 64, 242, 1, 3, 242, 236, 237, 1,
+       3, 242, 63, 244, 1, 3, 244, 236, 242, 1, 3, 244, 68, 245, 1, 3, 245, 236, 244, 1,
+3, 3, 246, 240, 1, 3, 3, 240, 241, 1, 3, 246, 65, 248, 1, 3, 248, 240, 246, 1,
+       3, 248, 63, 242, 1, 3, 242, 240, 248, 1, 3, 242, 64, 241, 1, 3, 241, 240, 242, 1,
+3, 4, 250, 247, 1, 3, 4, 247, 253, 1, 3, 67, 251, 247, 1, 3, 67, 247, 250, 1,
+       3, 63, 248, 247, 1, 3, 63, 247, 251, 1, 3, 248, 65, 253, 1, 3, 253, 247, 248, 1,
+3, 7, 255, 243, 1, 3, 7, 243, 257, 1, 3, 255, 68, 244, 1, 3, 244, 243, 255, 1,
+       3, 63, 251, 243, 1, 3, 63, 243, 244, 1, 3, 67, 257, 243, 1, 3, 67, 243, 251, 1,
+3, 3, 206, 205, 1, 3, 3, 205, 246, 1, 3, 206, 54, 258, 1, 3, 258, 205, 206, 1,
+       3, 258, 53, 259, 1, 3, 259, 205, 258, 1, 3, 259, 65, 246, 1, 3, 246, 205, 259, 1,
+3, 1, 260, 195, 1, 3, 1, 195, 196, 1, 3, 260, 69, 262, 1, 3, 262, 195, 260, 1,
+       3, 262, 53, 258, 1, 3, 258, 195, 262, 1, 3, 258, 54, 196, 1, 3, 196, 195, 258, 1,
+3, 5, 264, 261, 1, 3, 5, 261, 267, 1, 3, 70, 265, 261, 1, 3, 70, 261, 264, 1,
+       3, 53, 262, 261, 1, 3, 53, 261, 265, 1, 3, 262, 69, 267, 1, 3, 267, 261, 262, 1,
+3, 4, 253, 252, 1, 3, 4, 252, 268, 1, 3, 253, 65, 259, 1, 3, 259, 252, 253, 1,
+       3, 53, 265, 252, 1, 3, 53, 252, 259, 1, 3, 70, 268, 252, 1, 3, 70, 252, 265, 1,
+3, 1, 214, 213, 1, 3, 1, 213, 260, 1, 3, 214, 59, 269, 1, 3, 269, 213, 214, 1,
+       3, 269, 58, 270, 1, 3, 270, 213, 269, 1, 3, 270, 69, 260, 1, 3, 260, 213, 270, 1,
+3, 0, 271, 218, 1, 3, 0, 218, 219, 1, 3, 271, 71, 273, 1, 3, 273, 218, 271, 1,
+       3, 273, 58, 269, 1, 3, 269, 218, 273, 1, 3, 269, 59, 219, 1, 3, 219, 218, 269, 1,
+3, 6, 275, 272, 1, 3, 6, 272, 278, 1, 3, 72, 276, 272, 1, 3, 72, 272, 275, 1,
+       3, 58, 273, 272, 1, 3, 58, 272, 276, 1, 3, 273, 71, 278, 1, 3, 278, 272, 273, 1,
+3, 5, 267, 266, 1, 3, 5, 266, 279, 1, 3, 267, 69, 270, 1, 3, 270, 266, 267, 1,
+       3, 58, 276, 266, 1, 3, 58, 266, 270, 1, 3, 72, 279, 266, 1, 3, 72, 266, 276, 1,
+3, 0, 226, 225, 1, 3, 0, 225, 271, 1, 3, 226, 62, 280, 1, 3, 280, 225, 226, 1,
+       3, 280, 61, 281, 1, 3, 281, 225, 280, 1, 3, 281, 71, 271, 1, 3, 271, 225, 281, 1,
+3, 2, 245, 230, 1, 3, 2, 230, 231, 1, 3, 245, 68, 282, 1, 3, 282, 230, 245, 1,
+       3, 282, 61, 280, 1, 3, 280, 230, 282, 1, 3, 280, 62, 231, 1, 3, 231, 230, 280, 1,
+3, 7, 283, 254, 1, 3, 7, 254, 255, 1, 3, 73, 284, 254, 1, 3, 73, 254, 283, 1,
+       3, 61, 282, 254, 1, 3, 61, 254, 284, 1, 3, 282, 68, 255, 1, 3, 255, 254, 282, 1,
+3, 6, 278, 277, 1, 3, 6, 277, 285, 1, 3, 278, 71, 281, 1, 3, 281, 277, 278, 1,
+       3, 61, 284, 277, 1, 3, 61, 277, 281, 1, 3, 73, 285, 277, 1, 3, 73, 277, 284, 1,
+3, 4, 268, 249, 1, 3, 4, 249, 250, 1, 3, 268, 70, 286, 1, 3, 286, 249, 268, 1,
+       3, 66, 287, 249, 1, 3, 66, 249, 286, 1, 3, 287, 67, 250, 1, 3, 250, 249, 287, 1,
+3, 5, 279, 263, 1, 3, 5, 263, 264, 1, 3, 279, 72, 288, 1, 3, 288, 263, 279, 1,
+       3, 66, 286, 263, 1, 3, 66, 263, 288, 1, 3, 286, 70, 264, 1, 3, 264, 263, 286, 1,
+3, 6, 285, 274, 1, 3, 6, 274, 275, 1, 3, 285, 73, 289, 1, 3, 289, 274, 285, 1,
+       3, 66, 288, 274, 1, 3, 66, 274, 289, 1, 3, 288, 72, 275, 1, 3, 275, 274, 288, 1,
+3, 7, 257, 256, 1, 3, 7, 256, 283, 1, 3, 257, 67, 287, 1, 3, 287, 256, 257, 1,
+       3, 66, 289, 256, 1, 3, 66, 256, 287, 1, 3, 289, 73, 283, 1, 3, 283, 256, 289, 1,
+
+       0
+};
+
+struct lwo  LWO_s1_1 =
+{
+       290,                    /* number of points */
+       s1_1_PNTS, s1_1_normals, s1_1_POLS, 0L
+};
+
+#endif /* MODE_sproingies */
+
+/* End of s1_1.c */
diff --git a/xlockmore-4.14/modes/glx/s1_2.c b/xlockmore-4.14/modes/glx/s1_2.c
new file mode 100644 (file)
index 0000000..1517acf
--- /dev/null
@@ -0,0 +1,1057 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)s1_2.c       4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points, polygons, and normal vectors to render "s1_2" in 3D.
+ *
+ * Generated by lw2ogl.  Link this with your program but do
+ * not edit by hand.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_sproingies
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat s1_2_PNTS[] =
+{
+       (GLfloat) 0.316229, (GLfloat) 0.114342, (GLfloat) - 0.309219,
+       (GLfloat) 0.316229, (GLfloat) 0.114342, (GLfloat) - 0.690781,
+       (GLfloat) 0.697100, (GLfloat) 0.103031, (GLfloat) - 0.309219,
+       (GLfloat) 0.697100, (GLfloat) 0.103031, (GLfloat) - 0.690781,
+       (GLfloat) 0.638667, (GLfloat) 0.007537, (GLfloat) - 0.638667,
+       (GLfloat) 0.361333, (GLfloat) 0.007537, (GLfloat) - 0.638667,
+       (GLfloat) 0.361333, (GLfloat) 0.007537, (GLfloat) - 0.361333,
+       (GLfloat) 0.638667, (GLfloat) 0.007537, (GLfloat) - 0.361333,
+       (GLfloat) 0.813840, (GLfloat) 0.310563, (GLfloat) - 0.755750,
+       (GLfloat) 0.308193, (GLfloat) 0.377118, (GLfloat) - 0.755750,
+       (GLfloat) 0.308193, (GLfloat) 0.377118, (GLfloat) - 0.244250,
+       (GLfloat) 0.813840, (GLfloat) 0.310563, (GLfloat) - 0.244250,
+       (GLfloat) 0.865458, (GLfloat) 0.513412, (GLfloat) - 0.690781,
+       (GLfloat) 0.865458, (GLfloat) 0.513412, (GLfloat) - 0.309219,
+       (GLfloat) 0.858509, (GLfloat) 0.615264, (GLfloat) - 0.361333,
+       (GLfloat) 0.858509, (GLfloat) 0.615264, (GLfloat) - 0.638667,
+       (GLfloat) 0.500319, (GLfloat) 0.618731, (GLfloat) - 0.309219,
+       (GLfloat) 0.596285, (GLfloat) 0.705555, (GLfloat) - 0.361333,
+       (GLfloat) 0.500319, (GLfloat) 0.618731, (GLfloat) - 0.690781,
+       (GLfloat) 0.596285, (GLfloat) 0.705555, (GLfloat) - 0.638667,
+       (GLfloat) 0.945338, (GLfloat) 0.554869, (GLfloat) - 0.500000,
+       (GLfloat) 0.927845, (GLfloat) 0.404808, (GLfloat) - 0.500000,
+       (GLfloat) 0.931847, (GLfloat) 0.494263, (GLfloat) - 0.500000,
+       (GLfloat) 0.716506, (GLfloat) 0.632271, (GLfloat) - 0.258297,
+       (GLfloat) 0.883750, (GLfloat) 0.575062, (GLfloat) - 0.323141,
+       (GLfloat) 0.733407, (GLfloat) 0.677865, (GLfloat) - 0.500000,
+       (GLfloat) 0.897467, (GLfloat) 0.608935, (GLfloat) - 0.500000,
+       (GLfloat) 0.716506, (GLfloat) 0.632271, (GLfloat) - 0.741703,
+       (GLfloat) 0.883750, (GLfloat) 0.575062, (GLfloat) - 0.676859,
+       (GLfloat) 0.622584, (GLfloat) 0.465571, (GLfloat) - 0.187109,
+       (GLfloat) 0.682889, (GLfloat) 0.566071, (GLfloat) - 0.239844,
+       (GLfloat) 0.487673, (GLfloat) 0.709673, (GLfloat) - 0.500000,
+       (GLfloat) 0.548866, (GLfloat) 0.688331, (GLfloat) - 0.323141,
+       (GLfloat) 0.729578, (GLfloat) 0.666743, (GLfloat) - 0.322437,
+       (GLfloat) 0.317323, (GLfloat) 0.526334, (GLfloat) - 0.500000,
+       (GLfloat) 0.433930, (GLfloat) 0.637880, (GLfloat) - 0.500000,
+       (GLfloat) 0.548866, (GLfloat) 0.688331, (GLfloat) - 0.676859,
+       (GLfloat) 0.561689, (GLfloat) 0.724552, (GLfloat) - 0.500000,
+       (GLfloat) 0.622584, (GLfloat) 0.465571, (GLfloat) - 0.812891,
+       (GLfloat) 0.682889, (GLfloat) 0.566071, (GLfloat) - 0.760156,
+       (GLfloat) 0.729578, (GLfloat) 0.666743, (GLfloat) - 0.677562,
+       (GLfloat) 0.846442, (GLfloat) 0.421012, (GLfloat) - 0.729453,
+       (GLfloat) 0.835067, (GLfloat) 0.192357, (GLfloat) - 0.500000,
+       (GLfloat) 0.905776, (GLfloat) 0.298462, (GLfloat) - 0.500000,
+       (GLfloat) 0.846442, (GLfloat) 0.421012, (GLfloat) - 0.270547,
+       (GLfloat) 0.398726, (GLfloat) 0.510130, (GLfloat) - 0.729453,
+       (GLfloat) 0.523830, (GLfloat) 0.217409, (GLfloat) - 0.812891,
+       (GLfloat) 0.561017, (GLfloat) 0.343841, (GLfloat) - 0.848750,
+       (GLfloat) 0.523830, (GLfloat) 0.217409, (GLfloat) - 0.187109,
+       (GLfloat) 0.561017, (GLfloat) 0.343841, (GLfloat) - 0.151250,
+       (GLfloat) 0.398726, (GLfloat) 0.510130, (GLfloat) - 0.270547,
+       (GLfloat) 0.212593, (GLfloat) 0.242461, (GLfloat) - 0.500000,
+       (GLfloat) 0.216258, (GLfloat) 0.389219, (GLfloat) - 0.500000,
+       (GLfloat) 0.500666, (GLfloat) 0.037435, (GLfloat) - 0.741703,
+       (GLfloat) 0.506665, (GLfloat) 0.108686, (GLfloat) - 0.760156,
+       (GLfloat) 0.752070, (GLfloat) 0.199038, (GLfloat) - 0.729453,
+       (GLfloat) 0.295589, (GLfloat) 0.235781, (GLfloat) - 0.729453,
+       (GLfloat) 0.295589, (GLfloat) 0.235781, (GLfloat) - 0.270547,
+       (GLfloat) 0.259010, (GLfloat) 0.038206, (GLfloat) - 0.500000,
+       (GLfloat) 0.246980, (GLfloat) 0.116398, (GLfloat) - 0.500000,
+       (GLfloat) 0.752070, (GLfloat) 0.199038, (GLfloat) - 0.270547,
+       (GLfloat) 0.500666, (GLfloat) 0.037435, (GLfloat) - 0.258297,
+       (GLfloat) 0.506665, (GLfloat) 0.108686, (GLfloat) - 0.239844,
+       (GLfloat) 0.742322, (GLfloat) 0.036664, (GLfloat) - 0.500000,
+       (GLfloat) 0.766349, (GLfloat) 0.100974, (GLfloat) - 0.500000,
+       (GLfloat) 0.677491, (GLfloat) 0.037477, (GLfloat) - 0.676859,
+       (GLfloat) 0.500000, (GLfloat) - 0.010924, (GLfloat) - 0.500000,
+       (GLfloat) 0.677562, (GLfloat) 0.000839, (GLfloat) - 0.500000,
+       (GLfloat) 0.677491, (GLfloat) 0.037477, (GLfloat) - 0.323141,
+       (GLfloat) 0.323842, (GLfloat) 0.038608, (GLfloat) - 0.676859,
+       (GLfloat) 0.500000, (GLfloat) 0.000839, (GLfloat) - 0.677562,
+       (GLfloat) 0.323842, (GLfloat) 0.038608, (GLfloat) - 0.323141,
+       (GLfloat) 0.322437, (GLfloat) 0.000839, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) 0.000839, (GLfloat) - 0.322437,
+       (GLfloat) 0.925000, (GLfloat) 0.532253, (GLfloat) - 0.600125,
+       (GLfloat) 0.911045, (GLfloat) 0.457192, (GLfloat) - 0.613625,
+       (GLfloat) 0.915250, (GLfloat) 0.499050, (GLfloat) - 0.604062,
+       (GLfloat) 0.925000, (GLfloat) 0.532253, (GLfloat) - 0.399875,
+       (GLfloat) 0.940858, (GLfloat) 0.527164, (GLfloat) - 0.500000,
+       (GLfloat) 0.919197, (GLfloat) 0.584697, (GLfloat) - 0.587500,
+       (GLfloat) 0.929810, (GLfloat) 0.559801, (GLfloat) - 0.596406,
+       (GLfloat) 0.798138, (GLfloat) 0.572966, (GLfloat) - 0.733625,
+       (GLfloat) 0.877427, (GLfloat) 0.547520, (GLfloat) - 0.683563,
+       (GLfloat) 0.798138, (GLfloat) 0.572966, (GLfloat) - 0.266375,
+       (GLfloat) 0.877427, (GLfloat) 0.547520, (GLfloat) - 0.316437,
+       (GLfloat) 0.919197, (GLfloat) 0.584697, (GLfloat) - 0.412500,
+       (GLfloat) 0.929810, (GLfloat) 0.559801, (GLfloat) - 0.403594,
+       (GLfloat) 0.911045, (GLfloat) 0.457192, (GLfloat) - 0.386375,
+       (GLfloat) 0.915250, (GLfloat) 0.499050, (GLfloat) - 0.395938,
+       (GLfloat) 0.817112, (GLfloat) 0.642984, (GLfloat) - 0.409500,
+       (GLfloat) 0.884513, (GLfloat) 0.611054, (GLfloat) - 0.417500,
+       (GLfloat) 0.934249, (GLfloat) 0.580800, (GLfloat) - 0.500000,
+       (GLfloat) 0.807153, (GLfloat) 0.623277, (GLfloat) - 0.294000,
+       (GLfloat) 0.876135, (GLfloat) 0.598240, (GLfloat) - 0.339125,
+       (GLfloat) 0.807153, (GLfloat) 0.623277, (GLfloat) - 0.706000,
+       (GLfloat) 0.876135, (GLfloat) 0.598240, (GLfloat) - 0.660875,
+       (GLfloat) 0.817112, (GLfloat) 0.642984, (GLfloat) - 0.590500,
+       (GLfloat) 0.884513, (GLfloat) 0.611054, (GLfloat) - 0.582500,
+       (GLfloat) 0.764624, (GLfloat) 0.492766, (GLfloat) - 0.234875,
+       (GLfloat) 0.782472, (GLfloat) 0.537348, (GLfloat) - 0.257187,
+       (GLfloat) 0.607846, (GLfloat) 0.634036, (GLfloat) - 0.266375,
+       (GLfloat) 0.702992, (GLfloat) 0.603501, (GLfloat) - 0.249687,
+       (GLfloat) 0.807680, (GLfloat) 0.601112, (GLfloat) - 0.274594,
+       (GLfloat) 0.480984, (GLfloat) 0.674750, (GLfloat) - 0.399875,
+       (GLfloat) 0.528557, (GLfloat) 0.659482, (GLfloat) - 0.316437,
+       (GLfloat) 0.641688, (GLfloat) 0.680252, (GLfloat) - 0.294000,
+       (GLfloat) 0.625134, (GLfloat) 0.662855, (GLfloat) - 0.274594,
+       (GLfloat) 0.544994, (GLfloat) 0.546127, (GLfloat) - 0.234875,
+       (GLfloat) 0.583305, (GLfloat) 0.594795, (GLfloat) - 0.257187,
+       (GLfloat) 0.645973, (GLfloat) 0.701912, (GLfloat) - 0.409500,
+       (GLfloat) 0.650852, (GLfloat) 0.691510, (GLfloat) - 0.335375,
+       (GLfloat) 0.724816, (GLfloat) 0.652913, (GLfloat) - 0.278500,
+       (GLfloat) 0.529644, (GLfloat) 0.718831, (GLfloat) - 0.412500,
+       (GLfloat) 0.571915, (GLfloat) 0.702991, (GLfloat) - 0.339125,
+       (GLfloat) 0.806863, (GLfloat) 0.637791, (GLfloat) - 0.335375,
+       (GLfloat) 0.398573, (GLfloat) 0.581701, (GLfloat) - 0.386375,
+       (GLfloat) 0.450527, (GLfloat) 0.633092, (GLfloat) - 0.395938,
+       (GLfloat) 0.480984, (GLfloat) 0.674750, (GLfloat) - 0.600125,
+       (GLfloat) 0.465127, (GLfloat) 0.679839, (GLfloat) - 0.500000,
+       (GLfloat) 0.503003, (GLfloat) 0.704166, (GLfloat) - 0.403594,
+       (GLfloat) 0.607846, (GLfloat) 0.634036, (GLfloat) - 0.733625,
+       (GLfloat) 0.528557, (GLfloat) 0.659482, (GLfloat) - 0.683563,
+       (GLfloat) 0.529644, (GLfloat) 0.718831, (GLfloat) - 0.587500,
+       (GLfloat) 0.503003, (GLfloat) 0.704166, (GLfloat) - 0.596406,
+       (GLfloat) 0.398573, (GLfloat) 0.581701, (GLfloat) - 0.613625,
+       (GLfloat) 0.450527, (GLfloat) 0.633092, (GLfloat) - 0.604062,
+       (GLfloat) 0.645973, (GLfloat) 0.701912, (GLfloat) - 0.590500,
+       (GLfloat) 0.573201, (GLfloat) 0.718247, (GLfloat) - 0.582500,
+       (GLfloat) 0.515384, (GLfloat) 0.725027, (GLfloat) - 0.500000,
+       (GLfloat) 0.641688, (GLfloat) 0.680252, (GLfloat) - 0.706000,
+       (GLfloat) 0.571915, (GLfloat) 0.702991, (GLfloat) - 0.660875,
+       (GLfloat) 0.573201, (GLfloat) 0.718247, (GLfloat) - 0.417500,
+       (GLfloat) 0.544994, (GLfloat) 0.546127, (GLfloat) - 0.765125,
+       (GLfloat) 0.583305, (GLfloat) 0.594795, (GLfloat) - 0.742813,
+       (GLfloat) 0.702992, (GLfloat) 0.603501, (GLfloat) - 0.750313,
+       (GLfloat) 0.625134, (GLfloat) 0.662855, (GLfloat) - 0.725406,
+       (GLfloat) 0.807680, (GLfloat) 0.601112, (GLfloat) - 0.725406,
+       (GLfloat) 0.764624, (GLfloat) 0.492766, (GLfloat) - 0.765125,
+       (GLfloat) 0.782472, (GLfloat) 0.537348, (GLfloat) - 0.742813,
+       (GLfloat) 0.806863, (GLfloat) 0.637791, (GLfloat) - 0.664625,
+       (GLfloat) 0.724816, (GLfloat) 0.652913, (GLfloat) - 0.721500,
+       (GLfloat) 0.650852, (GLfloat) 0.691510, (GLfloat) - 0.664625,
+       (GLfloat) 0.732447, (GLfloat) 0.675074, (GLfloat) - 0.402250,
+       (GLfloat) 0.824871, (GLfloat) 0.643250, (GLfloat) - 0.500000,
+       (GLfloat) 0.640022, (GLfloat) 0.706898, (GLfloat) - 0.500000,
+       (GLfloat) 0.732447, (GLfloat) 0.675074, (GLfloat) - 0.597750,
+       (GLfloat) 0.856137, (GLfloat) 0.470533, (GLfloat) - 0.708313,
+       (GLfloat) 0.899707, (GLfloat) 0.356231, (GLfloat) - 0.635000,
+       (GLfloat) 0.907494, (GLfloat) 0.408859, (GLfloat) - 0.625156,
+       (GLfloat) 0.929348, (GLfloat) 0.452746, (GLfloat) - 0.500000,
+       (GLfloat) 0.851860, (GLfloat) 0.246808, (GLfloat) - 0.635000,
+       (GLfloat) 0.882792, (GLfloat) 0.301487, (GLfloat) - 0.639500,
+       (GLfloat) 0.899707, (GLfloat) 0.356231, (GLfloat) - 0.365000,
+       (GLfloat) 0.921826, (GLfloat) 0.352648, (GLfloat) - 0.500000,
+       (GLfloat) 0.722756, (GLfloat) 0.384892, (GLfloat) - 0.815000,
+       (GLfloat) 0.833350, (GLfloat) 0.366979, (GLfloat) - 0.747500,
+       (GLfloat) 0.722756, (GLfloat) 0.384892, (GLfloat) - 0.185000,
+       (GLfloat) 0.833350, (GLfloat) 0.366979, (GLfloat) - 0.252500,
+       (GLfloat) 0.907494, (GLfloat) 0.408859, (GLfloat) - 0.374844,
+       (GLfloat) 0.851860, (GLfloat) 0.246808, (GLfloat) - 0.365000,
+       (GLfloat) 0.882792, (GLfloat) 0.301487, (GLfloat) - 0.360500,
+       (GLfloat) 0.856137, (GLfloat) 0.470533, (GLfloat) - 0.291687,
+       (GLfloat) 0.453481, (GLfloat) 0.568361, (GLfloat) - 0.708313,
+       (GLfloat) 0.457330, (GLfloat) 0.427884, (GLfloat) - 0.815000,
+       (GLfloat) 0.500479, (GLfloat) 0.489876, (GLfloat) - 0.792031,
+       (GLfloat) 0.654809, (GLfloat) 0.519447, (GLfloat) - 0.784063,
+       (GLfloat) 0.405397, (GLfloat) 0.294044, (GLfloat) - 0.815000,
+       (GLfloat) 0.423113, (GLfloat) 0.361992, (GLfloat) - 0.825500,
+       (GLfloat) 0.590043, (GLfloat) 0.406388, (GLfloat) - 0.837500,
+       (GLfloat) 0.280379, (GLfloat) 0.456545, (GLfloat) - 0.635000,
+       (GLfloat) 0.346736, (GLfloat) 0.445797, (GLfloat) - 0.747500,
+       (GLfloat) 0.744688, (GLfloat) 0.441266, (GLfloat) - 0.792031,
+       (GLfloat) 0.673275, (GLfloat) 0.265703, (GLfloat) - 0.815000,
+       (GLfloat) 0.698920, (GLfloat) 0.325689, (GLfloat) - 0.825500,
+       (GLfloat) 0.654809, (GLfloat) 0.519447, (GLfloat) - 0.215937,
+       (GLfloat) 0.457330, (GLfloat) 0.427884, (GLfloat) - 0.185000,
+       (GLfloat) 0.500479, (GLfloat) 0.489876, (GLfloat) - 0.207969,
+       (GLfloat) 0.453481, (GLfloat) 0.568361, (GLfloat) - 0.291687,
+       (GLfloat) 0.744688, (GLfloat) 0.441266, (GLfloat) - 0.207969,
+       (GLfloat) 0.673275, (GLfloat) 0.265703, (GLfloat) - 0.185000,
+       (GLfloat) 0.698920, (GLfloat) 0.325689, (GLfloat) - 0.174500,
+       (GLfloat) 0.590043, (GLfloat) 0.406388, (GLfloat) - 0.162500,
+       (GLfloat) 0.280379, (GLfloat) 0.456545, (GLfloat) - 0.365000,
+       (GLfloat) 0.346736, (GLfloat) 0.445797, (GLfloat) - 0.252500,
+       (GLfloat) 0.405397, (GLfloat) 0.294044, (GLfloat) - 0.185000,
+       (GLfloat) 0.423113, (GLfloat) 0.361992, (GLfloat) - 0.174500,
+       (GLfloat) 0.380271, (GLfloat) 0.586148, (GLfloat) - 0.500000,
+       (GLfloat) 0.337674, (GLfloat) 0.522283, (GLfloat) - 0.625156,
+       (GLfloat) 0.337674, (GLfloat) 0.522283, (GLfloat) - 0.374844,
+       (GLfloat) 0.226812, (GLfloat) 0.312938, (GLfloat) - 0.365000,
+       (GLfloat) 0.239242, (GLfloat) 0.386194, (GLfloat) - 0.360500,
+       (GLfloat) 0.258260, (GLfloat) 0.460127, (GLfloat) - 0.500000,
+       (GLfloat) 0.226812, (GLfloat) 0.312938, (GLfloat) - 0.635000,
+       (GLfloat) 0.239242, (GLfloat) 0.386194, (GLfloat) - 0.639500,
+       (GLfloat) 0.400082, (GLfloat) 0.165542, (GLfloat) - 0.765125,
+       (GLfloat) 0.402616, (GLfloat) 0.069508, (GLfloat) - 0.733625,
+       (GLfloat) 0.402791, (GLfloat) 0.111771, (GLfloat) - 0.742813,
+       (GLfloat) 0.626577, (GLfloat) 0.153203, (GLfloat) - 0.765125,
+       (GLfloat) 0.513329, (GLfloat) 0.159372, (GLfloat) - 0.784063,
+       (GLfloat) 0.399335, (GLfloat) 0.227430, (GLfloat) - 0.792031,
+       (GLfloat) 0.249085, (GLfloat) 0.173768, (GLfloat) - 0.613625,
+       (GLfloat) 0.305709, (GLfloat) 0.170683, (GLfloat) - 0.708313,
+       (GLfloat) 0.777574, (GLfloat) 0.144976, (GLfloat) - 0.613625,
+       (GLfloat) 0.720950, (GLfloat) 0.148061, (GLfloat) - 0.708313,
+       (GLfloat) 0.648325, (GLfloat) 0.207388, (GLfloat) - 0.792031,
+       (GLfloat) 0.602715, (GLfloat) 0.067041, (GLfloat) - 0.733625,
+       (GLfloat) 0.610539, (GLfloat) 0.105601, (GLfloat) - 0.742813,
+       (GLfloat) 0.539336, (GLfloat) 0.279873, (GLfloat) - 0.837500,
+       (GLfloat) 0.784890, (GLfloat) 0.253894, (GLfloat) - 0.747500,
+       (GLfloat) 0.293781, (GLfloat) 0.305853, (GLfloat) - 0.747500,
+       (GLfloat) 0.233342, (GLfloat) 0.240791, (GLfloat) - 0.625156,
+       (GLfloat) 0.249085, (GLfloat) 0.173768, (GLfloat) - 0.386375,
+       (GLfloat) 0.230210, (GLfloat) 0.174796, (GLfloat) - 0.500000,
+       (GLfloat) 0.269217, (GLfloat) 0.071154, (GLfloat) - 0.600125,
+       (GLfloat) 0.264292, (GLfloat) 0.115884, (GLfloat) - 0.604062,
+       (GLfloat) 0.204489, (GLfloat) 0.315300, (GLfloat) - 0.500000,
+       (GLfloat) 0.293781, (GLfloat) 0.305853, (GLfloat) - 0.252500,
+       (GLfloat) 0.233342, (GLfloat) 0.240791, (GLfloat) - 0.374844,
+       (GLfloat) 0.269217, (GLfloat) 0.071154, (GLfloat) - 0.399875,
+       (GLfloat) 0.264292, (GLfloat) 0.115884, (GLfloat) - 0.395938,
+       (GLfloat) 0.400082, (GLfloat) 0.165542, (GLfloat) - 0.234875,
+       (GLfloat) 0.305709, (GLfloat) 0.170683, (GLfloat) - 0.291687,
+       (GLfloat) 0.399335, (GLfloat) 0.227430, (GLfloat) - 0.207969,
+       (GLfloat) 0.626577, (GLfloat) 0.153203, (GLfloat) - 0.234875,
+       (GLfloat) 0.513329, (GLfloat) 0.159372, (GLfloat) - 0.215937,
+       (GLfloat) 0.402616, (GLfloat) 0.069508, (GLfloat) - 0.266375,
+       (GLfloat) 0.402791, (GLfloat) 0.111771, (GLfloat) - 0.257187,
+       (GLfloat) 0.539336, (GLfloat) 0.279873, (GLfloat) - 0.162500,
+       (GLfloat) 0.784890, (GLfloat) 0.253894, (GLfloat) - 0.252500,
+       (GLfloat) 0.648325, (GLfloat) 0.207388, (GLfloat) - 0.207969,
+       (GLfloat) 0.602715, (GLfloat) 0.067041, (GLfloat) - 0.266375,
+       (GLfloat) 0.610539, (GLfloat) 0.105601, (GLfloat) - 0.257187,
+       (GLfloat) 0.777574, (GLfloat) 0.144976, (GLfloat) - 0.386375,
+       (GLfloat) 0.720950, (GLfloat) 0.148061, (GLfloat) - 0.291687,
+       (GLfloat) 0.814318, (GLfloat) 0.194027, (GLfloat) - 0.374844,
+       (GLfloat) 0.796449, (GLfloat) 0.143948, (GLfloat) - 0.500000,
+       (GLfloat) 0.736115, (GLfloat) 0.065395, (GLfloat) - 0.399875,
+       (GLfloat) 0.749037, (GLfloat) 0.101488, (GLfloat) - 0.395938,
+       (GLfloat) 0.874183, (GLfloat) 0.244447, (GLfloat) - 0.500000,
+       (GLfloat) 0.814318, (GLfloat) 0.194027, (GLfloat) - 0.625156,
+       (GLfloat) 0.736115, (GLfloat) 0.065395, (GLfloat) - 0.600125,
+       (GLfloat) 0.749037, (GLfloat) 0.101488, (GLfloat) - 0.604062,
+       (GLfloat) 0.752790, (GLfloat) 0.065190, (GLfloat) - 0.500000,
+       (GLfloat) 0.706000, (GLfloat) 0.016681, (GLfloat) - 0.412500,
+       (GLfloat) 0.726029, (GLfloat) 0.037019, (GLfloat) - 0.403594,
+       (GLfloat) 0.686090, (GLfloat) 0.066012, (GLfloat) - 0.316437,
+       (GLfloat) 0.686090, (GLfloat) 0.066012, (GLfloat) - 0.683563,
+       (GLfloat) 0.706000, (GLfloat) 0.016681, (GLfloat) - 0.587500,
+       (GLfloat) 0.726029, (GLfloat) 0.037019, (GLfloat) - 0.596406,
+       (GLfloat) 0.590500, (GLfloat) - 0.005194, (GLfloat) - 0.590500,
+       (GLfloat) 0.664625, (GLfloat) 0.003052, (GLfloat) - 0.582500,
+       (GLfloat) 0.721500, (GLfloat) 0.015465, (GLfloat) - 0.500000,
+       (GLfloat) 0.587500, (GLfloat) 0.016681, (GLfloat) - 0.706000,
+       (GLfloat) 0.660875, (GLfloat) 0.017896, (GLfloat) - 0.660875,
+       (GLfloat) 0.587500, (GLfloat) 0.016681, (GLfloat) - 0.294000,
+       (GLfloat) 0.660875, (GLfloat) 0.017896, (GLfloat) - 0.339125,
+       (GLfloat) 0.590500, (GLfloat) - 0.005194, (GLfloat) - 0.409500,
+       (GLfloat) 0.664625, (GLfloat) 0.003052, (GLfloat) - 0.417500,
+       (GLfloat) 0.502666, (GLfloat) 0.068274, (GLfloat) - 0.750313,
+       (GLfloat) 0.597054, (GLfloat) 0.037430, (GLfloat) - 0.725406,
+       (GLfloat) 0.319242, (GLfloat) 0.070537, (GLfloat) - 0.683563,
+       (GLfloat) 0.412500, (GLfloat) 0.016681, (GLfloat) - 0.706000,
+       (GLfloat) 0.404279, (GLfloat) 0.038047, (GLfloat) - 0.725406,
+       (GLfloat) 0.409500, (GLfloat) - 0.005194, (GLfloat) - 0.590500,
+       (GLfloat) 0.417500, (GLfloat) 0.003052, (GLfloat) - 0.664625,
+       (GLfloat) 0.500000, (GLfloat) 0.015465, (GLfloat) - 0.721500,
+       (GLfloat) 0.294000, (GLfloat) 0.016681, (GLfloat) - 0.587500,
+       (GLfloat) 0.339125, (GLfloat) 0.017896, (GLfloat) - 0.660875,
+       (GLfloat) 0.582500, (GLfloat) 0.003052, (GLfloat) - 0.664625,
+       (GLfloat) 0.252542, (GLfloat) 0.071359, (GLfloat) - 0.500000,
+       (GLfloat) 0.275304, (GLfloat) 0.038459, (GLfloat) - 0.596406,
+       (GLfloat) 0.319242, (GLfloat) 0.070537, (GLfloat) - 0.316437,
+       (GLfloat) 0.294000, (GLfloat) 0.016681, (GLfloat) - 0.412500,
+       (GLfloat) 0.275304, (GLfloat) 0.038459, (GLfloat) - 0.403594,
+       (GLfloat) 0.409500, (GLfloat) - 0.005194, (GLfloat) - 0.409500,
+       (GLfloat) 0.335375, (GLfloat) 0.003052, (GLfloat) - 0.417500,
+       (GLfloat) 0.278500, (GLfloat) 0.015465, (GLfloat) - 0.500000,
+       (GLfloat) 0.412500, (GLfloat) 0.016681, (GLfloat) - 0.294000,
+       (GLfloat) 0.339125, (GLfloat) 0.017896, (GLfloat) - 0.339125,
+       (GLfloat) 0.335375, (GLfloat) 0.003052, (GLfloat) - 0.582500,
+       (GLfloat) 0.502666, (GLfloat) 0.068274, (GLfloat) - 0.249687,
+       (GLfloat) 0.404279, (GLfloat) 0.038047, (GLfloat) - 0.274594,
+       (GLfloat) 0.597054, (GLfloat) 0.037430, (GLfloat) - 0.274594,
+       (GLfloat) 0.582500, (GLfloat) 0.003052, (GLfloat) - 0.335375,
+       (GLfloat) 0.500000, (GLfloat) 0.015465, (GLfloat) - 0.278500,
+       (GLfloat) 0.417500, (GLfloat) 0.003052, (GLfloat) - 0.335375,
+       (GLfloat) 0.500000, (GLfloat) - 0.007972, (GLfloat) - 0.597750,
+       (GLfloat) 0.597750, (GLfloat) - 0.007972, (GLfloat) - 0.500000,
+       (GLfloat) 0.402250, (GLfloat) - 0.007972, (GLfloat) - 0.500000,
+       (GLfloat) 0.500000, (GLfloat) - 0.007972, (GLfloat) - 0.402250,
+};
+
+static GLfloat s1_2_normals[] =
+{
+       (GLfloat) 0.838584, (GLfloat) - 0.185505, (GLfloat) - 0.512216,
+       (GLfloat) 0.838560, (GLfloat) - 0.185860, (GLfloat) - 0.512127,
+       (GLfloat) 0.951437, (GLfloat) - 0.260566, (GLfloat) - 0.163932,
+       (GLfloat) 0.951618, (GLfloat) - 0.260024, (GLfloat) - 0.163738,
+       (GLfloat) 0.973663, (GLfloat) - 0.157463, (GLfloat) - 0.164880,
+       (GLfloat) 0.975548, (GLfloat) - 0.148474, (GLfloat) - 0.162053,
+       (GLfloat) 0.859322, (GLfloat) - 0.074133, (GLfloat) - 0.506033,
+       (GLfloat) 0.859277, (GLfloat) - 0.081888, (GLfloat) - 0.504914,
+       (GLfloat) 0.838560, (GLfloat) - 0.185860, (GLfloat) 0.512127,
+       (GLfloat) 0.838584, (GLfloat) - 0.185505, (GLfloat) 0.512216,
+       (GLfloat) 0.859322, (GLfloat) - 0.074133, (GLfloat) 0.506034,
+       (GLfloat) 0.859277, (GLfloat) - 0.081888, (GLfloat) 0.504914,
+       (GLfloat) 0.973663, (GLfloat) - 0.157463, (GLfloat) 0.164880,
+       (GLfloat) 0.975548, (GLfloat) - 0.148474, (GLfloat) 0.162053,
+       (GLfloat) 0.951618, (GLfloat) - 0.260024, (GLfloat) 0.163738,
+       (GLfloat) 0.951437, (GLfloat) - 0.260566, (GLfloat) 0.163932,
+       (GLfloat) 0.573088, (GLfloat) 0.793214, (GLfloat) 0.205867,
+       (GLfloat) 0.558283, (GLfloat) 0.810311, (GLfloat) 0.178092,
+       (GLfloat) 0.606103, (GLfloat) 0.792390, (GLfloat) 0.068965,
+       (GLfloat) 0.596705, (GLfloat) 0.799118, (GLfloat) 0.073163,
+       (GLfloat) 0.896389, (GLfloat) 0.425982, (GLfloat) 0.122582,
+       (GLfloat) 0.910488, (GLfloat) 0.389376, (GLfloat) 0.139274,
+       (GLfloat) 0.787435, (GLfloat) 0.503715, (GLfloat) 0.355272,
+       (GLfloat) 0.794681, (GLfloat) 0.474299, (GLfloat) 0.378844,
+       (GLfloat) 0.558283, (GLfloat) 0.810311, (GLfloat) - 0.178092,
+       (GLfloat) 0.573088, (GLfloat) 0.793214, (GLfloat) - 0.205866,
+       (GLfloat) 0.787434, (GLfloat) 0.503716, (GLfloat) - 0.355272,
+       (GLfloat) 0.794681, (GLfloat) 0.474299, (GLfloat) - 0.378844,
+       (GLfloat) 0.910488, (GLfloat) 0.389376, (GLfloat) - 0.139274,
+       (GLfloat) 0.896389, (GLfloat) 0.425982, (GLfloat) - 0.122583,
+       (GLfloat) 0.596705, (GLfloat) 0.799118, (GLfloat) - 0.073163,
+       (GLfloat) 0.606103, (GLfloat) 0.792390, (GLfloat) - 0.068965,
+       (GLfloat) 0.528377, (GLfloat) - 0.013430, (GLfloat) 0.848903,
+       (GLfloat) 0.532136, (GLfloat) - 0.007543, (GLfloat) 0.846625,
+       (GLfloat) 0.209439, (GLfloat) 0.141946, (GLfloat) 0.967464,
+       (GLfloat) 0.218070, (GLfloat) 0.152719, (GLfloat) 0.963910,
+       (GLfloat) 0.237428, (GLfloat) 0.197257, (GLfloat) 0.951166,
+       (GLfloat) 0.225804, (GLfloat) 0.180417, (GLfloat) 0.957320,
+       (GLfloat) 0.549711, (GLfloat) 0.076255, (GLfloat) 0.831867,
+       (GLfloat) 0.550775, (GLfloat) 0.056452, (GLfloat) 0.832742,
+       (GLfloat) - 0.393177, (GLfloat) 0.417558, (GLfloat) 0.819181,
+       (GLfloat) - 0.379656, (GLfloat) 0.429289, (GLfloat) 0.819495,
+       (GLfloat) - 0.366688, (GLfloat) 0.451901, (GLfloat) 0.813219,
+       (GLfloat) - 0.369492, (GLfloat) 0.449132, (GLfloat) 0.813484,
+       (GLfloat) - 0.064014, (GLfloat) 0.313584, (GLfloat) 0.947400,
+       (GLfloat) - 0.066684, (GLfloat) 0.310439, (GLfloat) 0.948252,
+       (GLfloat) - 0.086424, (GLfloat) 0.278029, (GLfloat) 0.956677,
+       (GLfloat) - 0.074037, (GLfloat) 0.290647, (GLfloat) 0.953962,
+       (GLfloat) 0.110270, (GLfloat) 0.952576, (GLfloat) 0.283620,
+       (GLfloat) 0.140226, (GLfloat) 0.954260, (GLfloat) 0.264054,
+       (GLfloat) 0.237331, (GLfloat) 0.918949, (GLfloat) 0.314972,
+       (GLfloat) 0.245773, (GLfloat) 0.920155, (GLfloat) 0.304813,
+       (GLfloat) 0.105329, (GLfloat) 0.694128, (GLfloat) 0.712104,
+       (GLfloat) 0.087202, (GLfloat) 0.678641, (GLfloat) 0.729275,
+       (GLfloat) - 0.104644, (GLfloat) 0.803491, (GLfloat) 0.586048,
+       (GLfloat) - 0.129358, (GLfloat) 0.790652, (GLfloat) 0.598444,
+       (GLfloat) 0.490179, (GLfloat) 0.834739, (GLfloat) 0.250869,
+       (GLfloat) 0.486736, (GLfloat) 0.825366, (GLfloat) 0.286109,
+       (GLfloat) 0.575458, (GLfloat) 0.546427, (GLfloat) 0.608494,
+       (GLfloat) 0.582377, (GLfloat) 0.582433, (GLfloat) 0.567105,
+       (GLfloat) 0.347588, (GLfloat) 0.580631, (GLfloat) 0.736241,
+       (GLfloat) 0.339131, (GLfloat) 0.624243, (GLfloat) 0.703783,
+       (GLfloat) 0.378417, (GLfloat) 0.874281, (GLfloat) 0.304028,
+       (GLfloat) 0.373374, (GLfloat) 0.872526, (GLfloat) 0.315104,
+       (GLfloat) - 0.678225, (GLfloat) 0.555239, (GLfloat) 0.481373,
+       (GLfloat) - 0.681792, (GLfloat) 0.544639, (GLfloat) 0.488393,
+       (GLfloat) - 0.792737, (GLfloat) 0.589393, (GLfloat) 0.155511,
+       (GLfloat) - 0.790738, (GLfloat) 0.592627, (GLfloat) 0.153380,
+       (GLfloat) - 0.787611, (GLfloat) 0.595240, (GLfloat) 0.159243,
+       (GLfloat) - 0.781477, (GLfloat) 0.604504, (GLfloat) 0.154495,
+       (GLfloat) - 0.659940, (GLfloat) 0.576523, (GLfloat) 0.481768,
+       (GLfloat) - 0.666748, (GLfloat) 0.561105, (GLfloat) 0.490519,
+       (GLfloat) - 0.678225, (GLfloat) 0.555239, (GLfloat) - 0.481374,
+       (GLfloat) - 0.681792, (GLfloat) 0.544639, (GLfloat) - 0.488393,
+       (GLfloat) - 0.666748, (GLfloat) 0.561105, (GLfloat) - 0.490519,
+       (GLfloat) - 0.659940, (GLfloat) 0.576523, (GLfloat) - 0.481768,
+       (GLfloat) - 0.787611, (GLfloat) 0.595240, (GLfloat) - 0.159243,
+       (GLfloat) - 0.781477, (GLfloat) 0.604504, (GLfloat) - 0.154495,
+       (GLfloat) - 0.790738, (GLfloat) 0.592627, (GLfloat) - 0.153380,
+       (GLfloat) - 0.792737, (GLfloat) 0.589393, (GLfloat) - 0.155511,
+       (GLfloat) 0.036752, (GLfloat) 0.977890, (GLfloat) - 0.205867,
+       (GLfloat) 0.058945, (GLfloat) 0.982247, (GLfloat) - 0.178091,
+       (GLfloat) 0.010229, (GLfloat) 0.997567, (GLfloat) - 0.068965,
+       (GLfloat) 0.021776, (GLfloat) 0.997082, (GLfloat) - 0.073162,
+       (GLfloat) - 0.480804, (GLfloat) 0.867725, (GLfloat) - 0.126022,
+       (GLfloat) - 0.442857, (GLfloat) 0.886381, (GLfloat) - 0.134932,
+       (GLfloat) - 0.305505, (GLfloat) 0.879128, (GLfloat) - 0.365788,
+       (GLfloat) - 0.350437, (GLfloat) 0.860755, (GLfloat) - 0.369182,
+       (GLfloat) 0.058946, (GLfloat) 0.982247, (GLfloat) 0.178091,
+       (GLfloat) 0.036752, (GLfloat) 0.977890, (GLfloat) 0.205867,
+       (GLfloat) - 0.350437, (GLfloat) 0.860755, (GLfloat) 0.369182,
+       (GLfloat) - 0.305505, (GLfloat) 0.879128, (GLfloat) 0.365788,
+       (GLfloat) - 0.480804, (GLfloat) 0.867725, (GLfloat) 0.126022,
+       (GLfloat) - 0.442857, (GLfloat) 0.886381, (GLfloat) 0.134932,
+       (GLfloat) 0.021776, (GLfloat) 0.997082, (GLfloat) 0.073162,
+       (GLfloat) 0.010229, (GLfloat) 0.997567, (GLfloat) 0.068965,
+       (GLfloat) - 0.393178, (GLfloat) 0.417557, (GLfloat) - 0.819181,
+       (GLfloat) - 0.379655, (GLfloat) 0.429290, (GLfloat) - 0.819495,
+       (GLfloat) - 0.074037, (GLfloat) 0.290648, (GLfloat) - 0.953961,
+       (GLfloat) - 0.086424, (GLfloat) 0.278030, (GLfloat) - 0.956677,
+       (GLfloat) - 0.064013, (GLfloat) 0.313585, (GLfloat) - 0.947400,
+       (GLfloat) - 0.066684, (GLfloat) 0.310439, (GLfloat) - 0.948252,
+       (GLfloat) - 0.369492, (GLfloat) 0.449132, (GLfloat) - 0.813484,
+       (GLfloat) - 0.366688, (GLfloat) 0.451901, (GLfloat) - 0.813219,
+       (GLfloat) 0.532135, (GLfloat) - 0.007544, (GLfloat) - 0.846626,
+       (GLfloat) 0.528378, (GLfloat) - 0.013430, (GLfloat) - 0.848903,
+       (GLfloat) 0.550775, (GLfloat) 0.056452, (GLfloat) - 0.832742,
+       (GLfloat) 0.549711, (GLfloat) 0.076255, (GLfloat) - 0.831867,
+       (GLfloat) 0.225804, (GLfloat) 0.180419, (GLfloat) - 0.957320,
+       (GLfloat) 0.237428, (GLfloat) 0.197257, (GLfloat) - 0.951166,
+       (GLfloat) 0.209439, (GLfloat) 0.141946, (GLfloat) - 0.967464,
+       (GLfloat) 0.218070, (GLfloat) 0.152720, (GLfloat) - 0.963910,
+       (GLfloat) 0.490179, (GLfloat) 0.834739, (GLfloat) - 0.250870,
+       (GLfloat) 0.486736, (GLfloat) 0.825366, (GLfloat) - 0.286109,
+       (GLfloat) 0.373374, (GLfloat) 0.872526, (GLfloat) - 0.315104,
+       (GLfloat) 0.378417, (GLfloat) 0.874281, (GLfloat) - 0.304029,
+       (GLfloat) 0.339131, (GLfloat) 0.624243, (GLfloat) - 0.703783,
+       (GLfloat) 0.347588, (GLfloat) 0.580630, (GLfloat) - 0.736241,
+       (GLfloat) 0.582377, (GLfloat) 0.582434, (GLfloat) - 0.567105,
+       (GLfloat) 0.575458, (GLfloat) 0.546427, (GLfloat) - 0.608494,
+       (GLfloat) 0.140225, (GLfloat) 0.954260, (GLfloat) - 0.264055,
+       (GLfloat) 0.110270, (GLfloat) 0.952576, (GLfloat) - 0.283620,
+       (GLfloat) - 0.104644, (GLfloat) 0.803491, (GLfloat) - 0.586047,
+       (GLfloat) - 0.129358, (GLfloat) 0.790652, (GLfloat) - 0.598444,
+       (GLfloat) 0.087202, (GLfloat) 0.678640, (GLfloat) - 0.729276,
+       (GLfloat) 0.105329, (GLfloat) 0.694128, (GLfloat) - 0.712104,
+       (GLfloat) 0.237332, (GLfloat) 0.918949, (GLfloat) - 0.314972,
+       (GLfloat) 0.245773, (GLfloat) 0.920155, (GLfloat) - 0.304813,
+       (GLfloat) 0.448419, (GLfloat) 0.885179, (GLfloat) 0.124011,
+       (GLfloat) 0.437269, (GLfloat) 0.889018, (GLfloat) 0.135803,
+       (GLfloat) 0.364737, (GLfloat) 0.924635, (GLfloat) 0.109622,
+       (GLfloat) 0.360657, (GLfloat) 0.925618, (GLfloat) 0.114709,
+       (GLfloat) 0.353761, (GLfloat) 0.934751, (GLfloat) 0.033079,
+       (GLfloat) 0.356519, (GLfloat) 0.933801, (GLfloat) 0.030163,
+       (GLfloat) 0.426940, (GLfloat) 0.903217, (GLfloat) 0.043834,
+       (GLfloat) 0.431621, (GLfloat) 0.901183, (GLfloat) 0.039656,
+       (GLfloat) 0.202761, (GLfloat) 0.969766, (GLfloat) 0.135803,
+       (GLfloat) 0.191612, (GLfloat) 0.973605, (GLfloat) 0.124011,
+       (GLfloat) 0.219643, (GLfloat) 0.974595, (GLfloat) 0.043834,
+       (GLfloat) 0.214702, (GLfloat) 0.975874, (GLfloat) 0.039656,
+       (GLfloat) 0.293965, (GLfloat) 0.955340, (GLfloat) 0.030163,
+       (GLfloat) 0.296722, (GLfloat) 0.954391, (GLfloat) 0.033079,
+       (GLfloat) 0.281846, (GLfloat) 0.953177, (GLfloat) 0.109622,
+       (GLfloat) 0.285665, (GLfloat) 0.951439, (GLfloat) 0.114709,
+       (GLfloat) 0.191612, (GLfloat) 0.973605, (GLfloat) - 0.124011,
+       (GLfloat) 0.202761, (GLfloat) 0.969766, (GLfloat) - 0.135803,
+       (GLfloat) 0.281846, (GLfloat) 0.953177, (GLfloat) - 0.109622,
+       (GLfloat) 0.285665, (GLfloat) 0.951439, (GLfloat) - 0.114709,
+       (GLfloat) 0.296722, (GLfloat) 0.954391, (GLfloat) - 0.033079,
+       (GLfloat) 0.293965, (GLfloat) 0.955340, (GLfloat) - 0.030163,
+       (GLfloat) 0.219643, (GLfloat) 0.974595, (GLfloat) - 0.043834,
+       (GLfloat) 0.214702, (GLfloat) 0.975874, (GLfloat) - 0.039656,
+       (GLfloat) 0.437270, (GLfloat) 0.889018, (GLfloat) - 0.135802,
+       (GLfloat) 0.448419, (GLfloat) 0.885179, (GLfloat) - 0.124011,
+       (GLfloat) 0.426940, (GLfloat) 0.903217, (GLfloat) - 0.043834,
+       (GLfloat) 0.431621, (GLfloat) 0.901183, (GLfloat) - 0.039656,
+       (GLfloat) 0.356519, (GLfloat) 0.933801, (GLfloat) - 0.030163,
+       (GLfloat) 0.353761, (GLfloat) 0.934751, (GLfloat) - 0.033079,
+       (GLfloat) 0.364737, (GLfloat) 0.924635, (GLfloat) - 0.109622,
+       (GLfloat) 0.360657, (GLfloat) 0.925618, (GLfloat) - 0.114709,
+       (GLfloat) 0.865947, (GLfloat) 0.016137, (GLfloat) - 0.499875,
+       (GLfloat) 0.868761, (GLfloat) 0.025708, (GLfloat) - 0.494564,
+       (GLfloat) 0.864411, (GLfloat) 0.044558, (GLfloat) - 0.500808,
+       (GLfloat) 0.867101, (GLfloat) 0.054429, (GLfloat) - 0.495149,
+       (GLfloat) 0.986611, (GLfloat) - 0.030929, (GLfloat) - 0.160132,
+       (GLfloat) 0.986294, (GLfloat) - 0.033936, (GLfloat) - 0.161472,
+       (GLfloat) 0.985351, (GLfloat) - 0.059326, (GLfloat) - 0.159886,
+       (GLfloat) 0.984981, (GLfloat) - 0.062150, (GLfloat) - 0.161092,
+       (GLfloat) 0.832885, (GLfloat) - 0.213353, (GLfloat) - 0.510669,
+       (GLfloat) 0.832050, (GLfloat) - 0.215053, (GLfloat) - 0.511318,
+       (GLfloat) 0.946090, (GLfloat) - 0.280224, (GLfloat) - 0.162447,
+       (GLfloat) 0.946491, (GLfloat) - 0.279128, (GLfloat) - 0.161996,
+       (GLfloat) 0.980117, (GLfloat) - 0.113104, (GLfloat) - 0.163030,
+       (GLfloat) 0.979875, (GLfloat) - 0.114395, (GLfloat) - 0.163582,
+       (GLfloat) 0.859139, (GLfloat) - 0.037704, (GLfloat) - 0.510352,
+       (GLfloat) 0.860908, (GLfloat) - 0.032422, (GLfloat) - 0.507727,
+       (GLfloat) 0.832885, (GLfloat) - 0.213353, (GLfloat) 0.510669,
+       (GLfloat) 0.832049, (GLfloat) - 0.215054, (GLfloat) 0.511318,
+       (GLfloat) 0.860908, (GLfloat) - 0.032422, (GLfloat) 0.507727,
+       (GLfloat) 0.859138, (GLfloat) - 0.037705, (GLfloat) 0.510352,
+       (GLfloat) 0.980117, (GLfloat) - 0.113104, (GLfloat) 0.163030,
+       (GLfloat) 0.979875, (GLfloat) - 0.114395, (GLfloat) 0.163582,
+       (GLfloat) 0.946491, (GLfloat) - 0.279128, (GLfloat) 0.161996,
+       (GLfloat) 0.946090, (GLfloat) - 0.280224, (GLfloat) 0.162447,
+       (GLfloat) 0.868761, (GLfloat) 0.025708, (GLfloat) 0.494563,
+       (GLfloat) 0.865947, (GLfloat) 0.016137, (GLfloat) 0.499875,
+       (GLfloat) 0.985351, (GLfloat) - 0.059326, (GLfloat) 0.159886,
+       (GLfloat) 0.984981, (GLfloat) - 0.062149, (GLfloat) 0.161092,
+       (GLfloat) 0.986294, (GLfloat) - 0.033936, (GLfloat) 0.161472,
+       (GLfloat) 0.986611, (GLfloat) - 0.030929, (GLfloat) 0.160132,
+       (GLfloat) 0.864411, (GLfloat) 0.044558, (GLfloat) 0.500808,
+       (GLfloat) 0.867101, (GLfloat) 0.054428, (GLfloat) 0.495149,
+       (GLfloat) - 0.329624, (GLfloat) 0.568782, (GLfloat) - 0.753548,
+       (GLfloat) - 0.303532, (GLfloat) 0.584080, (GLfloat) - 0.752808,
+       (GLfloat) - 0.337233, (GLfloat) 0.584915, (GLfloat) - 0.737664,
+       (GLfloat) - 0.311968, (GLfloat) 0.599454, (GLfloat) - 0.737110,
+       (GLfloat) - 0.032356, (GLfloat) 0.486520, (GLfloat) - 0.873070,
+       (GLfloat) - 0.057628, (GLfloat) 0.467531, (GLfloat) - 0.882096,
+       (GLfloat) - 0.019804, (GLfloat) 0.465587, (GLfloat) - 0.884780,
+       (GLfloat) - 0.045819, (GLfloat) 0.445898, (GLfloat) - 0.893910,
+       (GLfloat) - 0.451403, (GLfloat) 0.351833, (GLfloat) - 0.820029,
+       (GLfloat) - 0.442643, (GLfloat) 0.360683, (GLfloat) - 0.820960,
+       (GLfloat) - 0.125959, (GLfloat) 0.231940, (GLfloat) - 0.964540,
+       (GLfloat) - 0.133424, (GLfloat) 0.223158, (GLfloat) - 0.965608,
+       (GLfloat) - 0.071940, (GLfloat) 0.416419, (GLfloat) - 0.906322,
+       (GLfloat) - 0.089763, (GLfloat) 0.400364, (GLfloat) - 0.911949,
+       (GLfloat) - 0.381140, (GLfloat) 0.522054, (GLfloat) - 0.763015,
+       (GLfloat) - 0.362693, (GLfloat) 0.535129, (GLfloat) - 0.762949,
+       (GLfloat) 0.514033, (GLfloat) - 0.052564, (GLfloat) - 0.856158,
+       (GLfloat) 0.512829, (GLfloat) - 0.054517, (GLfloat) - 0.856758,
+       (GLfloat) 0.539192, (GLfloat) 0.146366, (GLfloat) - 0.829367,
+       (GLfloat) 0.531981, (GLfloat) 0.133703, (GLfloat) - 0.836133,
+       (GLfloat) 0.204167, (GLfloat) 0.278037, (GLfloat) - 0.938622,
+       (GLfloat) 0.217587, (GLfloat) 0.294489, (GLfloat) - 0.930555,
+       (GLfloat) 0.177512, (GLfloat) 0.093824, (GLfloat) - 0.979636,
+       (GLfloat) 0.182065, (GLfloat) 0.100184, (GLfloat) - 0.978170,
+       (GLfloat) 0.561737, (GLfloat) 0.205535, (GLfloat) - 0.801378,
+       (GLfloat) 0.550517, (GLfloat) 0.186829, (GLfloat) - 0.813650,
+       (GLfloat) 0.237090, (GLfloat) 0.326380, (GLfloat) - 0.915022,
+       (GLfloat) 0.257400, (GLfloat) 0.348104, (GLfloat) - 0.901426,
+       (GLfloat) 0.225204, (GLfloat) 0.351522, (GLfloat) - 0.908689,
+       (GLfloat) 0.244915, (GLfloat) 0.372788, (GLfloat) - 0.895012,
+       (GLfloat) 0.553162, (GLfloat) 0.233132, (GLfloat) - 0.799789,
+       (GLfloat) 0.542289, (GLfloat) 0.214487, (GLfloat) - 0.812354,
+       (GLfloat) - 0.303532, (GLfloat) 0.584080, (GLfloat) 0.752808,
+       (GLfloat) - 0.329624, (GLfloat) 0.568782, (GLfloat) 0.753548,
+       (GLfloat) - 0.019804, (GLfloat) 0.465588, (GLfloat) 0.884780,
+       (GLfloat) - 0.045820, (GLfloat) 0.445898, (GLfloat) 0.893910,
+       (GLfloat) - 0.057628, (GLfloat) 0.467531, (GLfloat) 0.882096,
+       (GLfloat) - 0.032356, (GLfloat) 0.486520, (GLfloat) 0.873070,
+       (GLfloat) - 0.337233, (GLfloat) 0.584915, (GLfloat) 0.737664,
+       (GLfloat) - 0.311968, (GLfloat) 0.599453, (GLfloat) 0.737110,
+       (GLfloat) 0.561737, (GLfloat) 0.205535, (GLfloat) 0.801378,
+       (GLfloat) 0.550517, (GLfloat) 0.186829, (GLfloat) 0.813650,
+       (GLfloat) 0.542289, (GLfloat) 0.214487, (GLfloat) 0.812354,
+       (GLfloat) 0.553162, (GLfloat) 0.233132, (GLfloat) 0.799789,
+       (GLfloat) 0.225204, (GLfloat) 0.351522, (GLfloat) 0.908689,
+       (GLfloat) 0.244915, (GLfloat) 0.372788, (GLfloat) 0.895012,
+       (GLfloat) 0.257400, (GLfloat) 0.348104, (GLfloat) 0.901426,
+       (GLfloat) 0.237091, (GLfloat) 0.326380, (GLfloat) 0.915021,
+       (GLfloat) 0.512829, (GLfloat) - 0.054517, (GLfloat) 0.856758,
+       (GLfloat) 0.514033, (GLfloat) - 0.052564, (GLfloat) 0.856158,
+       (GLfloat) 0.177512, (GLfloat) 0.093824, (GLfloat) 0.979636,
+       (GLfloat) 0.182065, (GLfloat) 0.100184, (GLfloat) 0.978170,
+       (GLfloat) 0.217587, (GLfloat) 0.294488, (GLfloat) 0.930555,
+       (GLfloat) 0.204167, (GLfloat) 0.278037, (GLfloat) 0.938622,
+       (GLfloat) 0.539192, (GLfloat) 0.146365, (GLfloat) 0.829367,
+       (GLfloat) 0.531981, (GLfloat) 0.133703, (GLfloat) 0.836133,
+       (GLfloat) - 0.451403, (GLfloat) 0.351833, (GLfloat) 0.820029,
+       (GLfloat) - 0.442643, (GLfloat) 0.360683, (GLfloat) 0.820960,
+       (GLfloat) - 0.362693, (GLfloat) 0.535129, (GLfloat) 0.762949,
+       (GLfloat) - 0.381140, (GLfloat) 0.522054, (GLfloat) 0.763015,
+       (GLfloat) - 0.071940, (GLfloat) 0.416419, (GLfloat) 0.906322,
+       (GLfloat) - 0.089763, (GLfloat) 0.400364, (GLfloat) 0.911949,
+       (GLfloat) - 0.133424, (GLfloat) 0.223158, (GLfloat) 0.965608,
+       (GLfloat) - 0.125959, (GLfloat) 0.231940, (GLfloat) 0.964540,
+       (GLfloat) - 0.574082, (GLfloat) 0.688221, (GLfloat) - 0.443601,
+       (GLfloat) - 0.590248, (GLfloat) 0.678175, (GLfloat) - 0.437821,
+       (GLfloat) - 0.687359, (GLfloat) 0.712967, (GLfloat) - 0.138621,
+       (GLfloat) - 0.682813, (GLfloat) 0.716686, (GLfloat) - 0.141874,
+       (GLfloat) - 0.682597, (GLfloat) 0.718360, (GLfloat) - 0.134243,
+       (GLfloat) - 0.678253, (GLfloat) 0.721849, (GLfloat) - 0.137502,
+       (GLfloat) - 0.574037, (GLfloat) 0.696240, (GLfloat) - 0.430966,
+       (GLfloat) - 0.589571, (GLfloat) 0.686777, (GLfloat) - 0.425139,
+       (GLfloat) - 0.574082, (GLfloat) 0.688221, (GLfloat) 0.443601,
+       (GLfloat) - 0.590248, (GLfloat) 0.678175, (GLfloat) 0.437821,
+       (GLfloat) - 0.589571, (GLfloat) 0.686777, (GLfloat) 0.425139,
+       (GLfloat) - 0.574037, (GLfloat) 0.696240, (GLfloat) 0.430966,
+       (GLfloat) - 0.682597, (GLfloat) 0.718360, (GLfloat) 0.134243,
+       (GLfloat) - 0.678253, (GLfloat) 0.721849, (GLfloat) 0.137502,
+       (GLfloat) - 0.682813, (GLfloat) 0.716686, (GLfloat) 0.141874,
+       (GLfloat) - 0.687359, (GLfloat) 0.712967, (GLfloat) 0.138621,
+       (GLfloat) - 0.741041, (GLfloat) 0.473108, (GLfloat) 0.476473,
+       (GLfloat) - 0.742406, (GLfloat) 0.464975, (GLfloat) 0.482319,
+       (GLfloat) - 0.850293, (GLfloat) 0.503676, (GLfloat) 0.152681,
+       (GLfloat) - 0.849127, (GLfloat) 0.506180, (GLfloat) 0.150879,
+       (GLfloat) - 0.738717, (GLfloat) 0.659007, (GLfloat) 0.141447,
+       (GLfloat) - 0.736283, (GLfloat) 0.662408, (GLfloat) 0.138214,
+       (GLfloat) - 0.631960, (GLfloat) 0.635245, (GLfloat) 0.443948,
+       (GLfloat) - 0.643540, (GLfloat) 0.626686, (GLfloat) 0.439455,
+       (GLfloat) - 0.741041, (GLfloat) 0.473108, (GLfloat) - 0.476473,
+       (GLfloat) - 0.742406, (GLfloat) 0.464975, (GLfloat) - 0.482319,
+       (GLfloat) - 0.631960, (GLfloat) 0.635245, (GLfloat) - 0.443948,
+       (GLfloat) - 0.643541, (GLfloat) 0.626686, (GLfloat) - 0.439455,
+       (GLfloat) - 0.738717, (GLfloat) 0.659007, (GLfloat) - 0.141447,
+       (GLfloat) - 0.736283, (GLfloat) 0.662408, (GLfloat) - 0.138214,
+       (GLfloat) - 0.849127, (GLfloat) 0.506180, (GLfloat) - 0.150879,
+       (GLfloat) - 0.850293, (GLfloat) 0.503676, (GLfloat) - 0.152681,
+       (GLfloat) - 0.489320, (GLfloat) - 0.355167, (GLfloat) - 0.796506,
+       (GLfloat) - 0.498398, (GLfloat) - 0.341072, (GLfloat) - 0.797038,
+       (GLfloat) - 0.172289, (GLfloat) - 0.401583, (GLfloat) - 0.899471,
+       (GLfloat) - 0.163102, (GLfloat) - 0.385135, (GLfloat) - 0.908333,
+       (GLfloat) - 0.182727, (GLfloat) - 0.410657, (GLfloat) - 0.893293,
+       (GLfloat) - 0.172422, (GLfloat) - 0.394484, (GLfloat) - 0.902581,
+       (GLfloat) - 0.506086, (GLfloat) - 0.336560, (GLfloat) - 0.794106,
+       (GLfloat) - 0.496896, (GLfloat) - 0.351037, (GLfloat) - 0.793642,
+       (GLfloat) 0.421643, (GLfloat) - 0.514114, (GLfloat) - 0.746930,
+       (GLfloat) 0.435781, (GLfloat) - 0.498195, (GLfloat) - 0.749598,
+       (GLfloat) 0.399104, (GLfloat) - 0.548391, (GLfloat) - 0.734836,
+       (GLfloat) 0.414969, (GLfloat) - 0.532774, (GLfloat) - 0.737532,
+       (GLfloat) 0.122126, (GLfloat) - 0.459168, (GLfloat) - 0.879915,
+       (GLfloat) 0.107835, (GLfloat) - 0.476533, (GLfloat) - 0.872518,
+       (GLfloat) 0.135473, (GLfloat) - 0.437168, (GLfloat) - 0.889118,
+       (GLfloat) 0.122726, (GLfloat) - 0.454818, (GLfloat) - 0.882088,
+       (GLfloat) 0.451859, (GLfloat) - 0.350279, (GLfloat) - 0.820444,
+       (GLfloat) 0.459996, (GLfloat) - 0.340221, (GLfloat) - 0.820154,
+       (GLfloat) 0.139327, (GLfloat) - 0.217141, (GLfloat) - 0.966146,
+       (GLfloat) 0.132987, (GLfloat) - 0.225779, (GLfloat) - 0.965059,
+       (GLfloat) 0.121571, (GLfloat) - 0.389814, (GLfloat) - 0.912834,
+       (GLfloat) 0.109716, (GLfloat) - 0.404550, (GLfloat) - 0.907910,
+       (GLfloat) 0.409974, (GLfloat) - 0.496912, (GLfloat) - 0.764852,
+       (GLfloat) 0.423414, (GLfloat) - 0.483036, (GLfloat) - 0.766418,
+       (GLfloat) - 0.517051, (GLfloat) 0.005478, (GLfloat) - 0.855937,
+       (GLfloat) - 0.518557, (GLfloat) 0.003075, (GLfloat) - 0.855038,
+       (GLfloat) - 0.515705, (GLfloat) - 0.236965, (GLfloat) - 0.823344,
+       (GLfloat) - 0.521517, (GLfloat) - 0.225403, (GLfloat) - 0.822930,
+       (GLfloat) - 0.189726, (GLfloat) - 0.318770, (GLfloat) - 0.928649,
+       (GLfloat) - 0.181223, (GLfloat) - 0.305795, (GLfloat) - 0.934691,
+       (GLfloat) - 0.179422, (GLfloat) - 0.111097, (GLfloat) - 0.977479,
+       (GLfloat) - 0.175584, (GLfloat) - 0.105473, (GLfloat) - 0.978798,
+       (GLfloat) - 0.822110, (GLfloat) - 0.303411, (GLfloat) - 0.481743,
+       (GLfloat) - 0.821692, (GLfloat) - 0.296307, (GLfloat) - 0.486851,
+       (GLfloat) - 0.829019, (GLfloat) - 0.285105, (GLfloat) - 0.481086,
+       (GLfloat) - 0.828324, (GLfloat) - 0.278227, (GLfloat) - 0.486280,
+       (GLfloat) - 0.955809, (GLfloat) - 0.248857, (GLfloat) - 0.156521,
+       (GLfloat) - 0.955462, (GLfloat) - 0.251102, (GLfloat) - 0.155051,
+       (GLfloat) - 0.949299, (GLfloat) - 0.272604, (GLfloat) - 0.156583,
+       (GLfloat) - 0.948870, (GLfloat) - 0.274919, (GLfloat) - 0.155132,
+       (GLfloat) - 0.850734, (GLfloat) 0.112614, (GLfloat) - 0.513391,
+       (GLfloat) - 0.850654, (GLfloat) 0.112793, (GLfloat) - 0.513484,
+       (GLfloat) - 0.974222, (GLfloat) 0.155109, (GLfloat) - 0.163808,
+       (GLfloat) - 0.974191, (GLfloat) 0.155230, (GLfloat) - 0.163874,
+       (GLfloat) - 0.980876, (GLfloat) - 0.109137, (GLfloat) - 0.161159,
+       (GLfloat) - 0.980855, (GLfloat) - 0.110647, (GLfloat) - 0.160255,
+       (GLfloat) - 0.853630, (GLfloat) - 0.150462, (GLfloat) - 0.498675,
+       (GLfloat) - 0.852599, (GLfloat) - 0.145646, (GLfloat) - 0.501859,
+       (GLfloat) - 0.850734, (GLfloat) 0.112614, (GLfloat) 0.513391,
+       (GLfloat) - 0.850654, (GLfloat) 0.112793, (GLfloat) 0.513484,
+       (GLfloat) - 0.852599, (GLfloat) - 0.145647, (GLfloat) 0.501859,
+       (GLfloat) - 0.853630, (GLfloat) - 0.150462, (GLfloat) 0.498676,
+       (GLfloat) - 0.980876, (GLfloat) - 0.109137, (GLfloat) 0.161159,
+       (GLfloat) - 0.980855, (GLfloat) - 0.110647, (GLfloat) 0.160255,
+       (GLfloat) - 0.974191, (GLfloat) 0.155230, (GLfloat) 0.163874,
+       (GLfloat) - 0.974222, (GLfloat) 0.155109, (GLfloat) 0.163808,
+       (GLfloat) - 0.821692, (GLfloat) - 0.296307, (GLfloat) 0.486851,
+       (GLfloat) - 0.822110, (GLfloat) - 0.303411, (GLfloat) 0.481743,
+       (GLfloat) - 0.949299, (GLfloat) - 0.272604, (GLfloat) 0.156583,
+       (GLfloat) - 0.948870, (GLfloat) - 0.274919, (GLfloat) 0.155132,
+       (GLfloat) - 0.955462, (GLfloat) - 0.251102, (GLfloat) 0.155051,
+       (GLfloat) - 0.955809, (GLfloat) - 0.248857, (GLfloat) 0.156520,
+       (GLfloat) - 0.829019, (GLfloat) - 0.285105, (GLfloat) 0.481086,
+       (GLfloat) - 0.828324, (GLfloat) - 0.278227, (GLfloat) 0.486280,
+       (GLfloat) - 0.498398, (GLfloat) - 0.341071, (GLfloat) 0.797038,
+       (GLfloat) - 0.489320, (GLfloat) - 0.355167, (GLfloat) 0.796507,
+       (GLfloat) - 0.506086, (GLfloat) - 0.336560, (GLfloat) 0.794106,
+       (GLfloat) - 0.496896, (GLfloat) - 0.351037, (GLfloat) 0.793642,
+       (GLfloat) - 0.182728, (GLfloat) - 0.410657, (GLfloat) 0.893293,
+       (GLfloat) - 0.172423, (GLfloat) - 0.394484, (GLfloat) 0.902581,
+       (GLfloat) - 0.163101, (GLfloat) - 0.385135, (GLfloat) 0.908333,
+       (GLfloat) - 0.172289, (GLfloat) - 0.401584, (GLfloat) 0.899470,
+       (GLfloat) - 0.518557, (GLfloat) 0.003076, (GLfloat) 0.855038,
+       (GLfloat) - 0.517051, (GLfloat) 0.005478, (GLfloat) 0.855937,
+       (GLfloat) - 0.179422, (GLfloat) - 0.111097, (GLfloat) 0.977479,
+       (GLfloat) - 0.175584, (GLfloat) - 0.105473, (GLfloat) 0.978798,
+       (GLfloat) - 0.181223, (GLfloat) - 0.305795, (GLfloat) 0.934691,
+       (GLfloat) - 0.189727, (GLfloat) - 0.318770, (GLfloat) 0.928649,
+       (GLfloat) - 0.521517, (GLfloat) - 0.225402, (GLfloat) 0.822930,
+       (GLfloat) - 0.515705, (GLfloat) - 0.236965, (GLfloat) 0.823344,
+       (GLfloat) 0.451859, (GLfloat) - 0.350279, (GLfloat) 0.820444,
+       (GLfloat) 0.459996, (GLfloat) - 0.340221, (GLfloat) 0.820154,
+       (GLfloat) 0.423414, (GLfloat) - 0.483036, (GLfloat) 0.766418,
+       (GLfloat) 0.409975, (GLfloat) - 0.496912, (GLfloat) 0.764853,
+       (GLfloat) 0.121571, (GLfloat) - 0.389814, (GLfloat) 0.912834,
+       (GLfloat) 0.109716, (GLfloat) - 0.404550, (GLfloat) 0.907911,
+       (GLfloat) 0.132987, (GLfloat) - 0.225779, (GLfloat) 0.965059,
+       (GLfloat) 0.139327, (GLfloat) - 0.217140, (GLfloat) 0.966146,
+       (GLfloat) 0.435780, (GLfloat) - 0.498195, (GLfloat) 0.749598,
+       (GLfloat) 0.421643, (GLfloat) - 0.514113, (GLfloat) 0.746930,
+       (GLfloat) 0.135473, (GLfloat) - 0.437169, (GLfloat) 0.889118,
+       (GLfloat) 0.122726, (GLfloat) - 0.454818, (GLfloat) 0.882088,
+       (GLfloat) 0.107835, (GLfloat) - 0.476534, (GLfloat) 0.872518,
+       (GLfloat) 0.122126, (GLfloat) - 0.459168, (GLfloat) 0.879915,
+       (GLfloat) 0.399104, (GLfloat) - 0.548391, (GLfloat) 0.734836,
+       (GLfloat) 0.414969, (GLfloat) - 0.532773, (GLfloat) 0.737532,
+       (GLfloat) 0.709825, (GLfloat) - 0.548164, (GLfloat) 0.442339,
+       (GLfloat) 0.706858, (GLfloat) - 0.559116, (GLfloat) 0.433291,
+       (GLfloat) 0.678133, (GLfloat) - 0.593660, (GLfloat) 0.433248,
+       (GLfloat) 0.674632, (GLfloat) - 0.604835, (GLfloat) 0.423140,
+       (GLfloat) 0.774649, (GLfloat) - 0.617973, (GLfloat) 0.134272,
+       (GLfloat) 0.777074, (GLfloat) - 0.614312, (GLfloat) 0.137026,
+       (GLfloat) 0.811265, (GLfloat) - 0.568214, (GLfloat) 0.137773,
+       (GLfloat) 0.813383, (GLfloat) - 0.564575, (GLfloat) 0.140223,
+       (GLfloat) 0.750611, (GLfloat) - 0.453426, (GLfloat) 0.480612,
+       (GLfloat) 0.748687, (GLfloat) - 0.462619, (GLfloat) 0.474817,
+       (GLfloat) 0.853444, (GLfloat) - 0.499176, (GLfloat) 0.149855,
+       (GLfloat) 0.854917, (GLfloat) - 0.496116, (GLfloat) 0.151614,
+       (GLfloat) 0.791852, (GLfloat) - 0.594634, (GLfloat) 0.139213,
+       (GLfloat) 0.794008, (GLfloat) - 0.591177, (GLfloat) 0.141637,
+       (GLfloat) 0.694144, (GLfloat) - 0.562907, (GLfloat) 0.448664,
+       (GLfloat) 0.690998, (GLfloat) - 0.573547, (GLfloat) 0.439961,
+       (GLfloat) 0.750611, (GLfloat) - 0.453426, (GLfloat) - 0.480612,
+       (GLfloat) 0.748687, (GLfloat) - 0.462620, (GLfloat) - 0.474817,
+       (GLfloat) 0.690999, (GLfloat) - 0.573546, (GLfloat) - 0.439961,
+       (GLfloat) 0.694144, (GLfloat) - 0.562907, (GLfloat) - 0.448664,
+       (GLfloat) 0.791852, (GLfloat) - 0.594634, (GLfloat) - 0.139213,
+       (GLfloat) 0.794008, (GLfloat) - 0.591177, (GLfloat) - 0.141637,
+       (GLfloat) 0.854917, (GLfloat) - 0.496116, (GLfloat) - 0.151614,
+       (GLfloat) 0.853444, (GLfloat) - 0.499176, (GLfloat) - 0.149855,
+       (GLfloat) 0.706858, (GLfloat) - 0.559116, (GLfloat) - 0.433291,
+       (GLfloat) 0.709825, (GLfloat) - 0.548164, (GLfloat) - 0.442339,
+       (GLfloat) 0.811265, (GLfloat) - 0.568214, (GLfloat) - 0.137773,
+       (GLfloat) 0.813383, (GLfloat) - 0.564575, (GLfloat) - 0.140223,
+       (GLfloat) 0.777074, (GLfloat) - 0.614312, (GLfloat) - 0.137026,
+       (GLfloat) 0.774649, (GLfloat) - 0.617973, (GLfloat) - 0.134272,
+       (GLfloat) 0.678133, (GLfloat) - 0.593660, (GLfloat) - 0.433248,
+       (GLfloat) 0.674631, (GLfloat) - 0.604835, (GLfloat) - 0.423139,
+       (GLfloat) 0.805725, (GLfloat) - 0.334902, (GLfloat) 0.488515,
+       (GLfloat) 0.805089, (GLfloat) - 0.341176, (GLfloat) 0.485212,
+       (GLfloat) 0.923877, (GLfloat) - 0.350079, (GLfloat) 0.154583,
+       (GLfloat) 0.924516, (GLfloat) - 0.347968, (GLfloat) 0.155526,
+       (GLfloat) 0.927012, (GLfloat) - 0.340158, (GLfloat) 0.157929,
+       (GLfloat) 0.924342, (GLfloat) - 0.348817, (GLfloat) 0.154657,
+       (GLfloat) 0.800744, (GLfloat) - 0.354688, (GLfloat) 0.482707,
+       (GLfloat) 0.801658, (GLfloat) - 0.348585, (GLfloat) 0.485626,
+       (GLfloat) 0.805725, (GLfloat) - 0.334902, (GLfloat) - 0.488516,
+       (GLfloat) 0.805089, (GLfloat) - 0.341176, (GLfloat) - 0.485212,
+       (GLfloat) 0.801658, (GLfloat) - 0.348585, (GLfloat) - 0.485626,
+       (GLfloat) 0.800744, (GLfloat) - 0.354688, (GLfloat) - 0.482707,
+       (GLfloat) 0.927012, (GLfloat) - 0.340158, (GLfloat) - 0.157929,
+       (GLfloat) 0.924342, (GLfloat) - 0.348818, (GLfloat) - 0.154657,
+       (GLfloat) 0.924516, (GLfloat) - 0.347968, (GLfloat) - 0.155526,
+       (GLfloat) 0.923877, (GLfloat) - 0.350079, (GLfloat) - 0.154583,
+       (GLfloat) 0.283621, (GLfloat) - 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) 0.264056, (GLfloat) - 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) 0.315105, (GLfloat) - 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) 0.304029, (GLfloat) - 0.949849, (GLfloat) - 0.073162,
+       (GLfloat) 0.681274, (GLfloat) - 0.722487, (GLfloat) - 0.117805,
+       (GLfloat) 0.706887, (GLfloat) - 0.694350, (GLfloat) - 0.134864,
+       (GLfloat) 0.560017, (GLfloat) - 0.754527, (GLfloat) - 0.342154,
+       (GLfloat) 0.577334, (GLfloat) - 0.729313, (GLfloat) - 0.367135,
+       (GLfloat) 0.264055, (GLfloat) - 0.947923, (GLfloat) 0.178092,
+       (GLfloat) 0.283621, (GLfloat) - 0.936578, (GLfloat) 0.205866,
+       (GLfloat) 0.560017, (GLfloat) - 0.754527, (GLfloat) 0.342155,
+       (GLfloat) 0.577334, (GLfloat) - 0.729313, (GLfloat) 0.367135,
+       (GLfloat) 0.706888, (GLfloat) - 0.694350, (GLfloat) 0.134864,
+       (GLfloat) 0.681274, (GLfloat) - 0.722487, (GLfloat) 0.117805,
+       (GLfloat) 0.304029, (GLfloat) - 0.949849, (GLfloat) 0.073162,
+       (GLfloat) 0.315105, (GLfloat) - 0.946548, (GLfloat) 0.068965,
+       (GLfloat) 0.484153, (GLfloat) - 0.303994, (GLfloat) - 0.820478,
+       (GLfloat) 0.489225, (GLfloat) - 0.294821, (GLfloat) - 0.820816,
+       (GLfloat) 0.156385, (GLfloat) - 0.248336, (GLfloat) - 0.955967,
+       (GLfloat) 0.151648, (GLfloat) - 0.258100, (GLfloat) - 0.954142,
+       (GLfloat) 0.160268, (GLfloat) - 0.275037, (GLfloat) - 0.947981,
+       (GLfloat) 0.153877, (GLfloat) - 0.291476, (GLfloat) - 0.944120,
+       (GLfloat) 0.481923, (GLfloat) - 0.335378, (GLfloat) - 0.809489,
+       (GLfloat) 0.489881, (GLfloat) - 0.318876, (GLfloat) - 0.811378,
+       (GLfloat) - 0.511124, (GLfloat) - 0.173861, (GLfloat) - 0.841739,
+       (GLfloat) - 0.507919, (GLfloat) - 0.180984, (GLfloat) - 0.842177,
+       (GLfloat) - 0.502437, (GLfloat) - 0.243295, (GLfloat) - 0.829678,
+       (GLfloat) - 0.501146, (GLfloat) - 0.246358, (GLfloat) - 0.829554,
+       (GLfloat) - 0.162122, (GLfloat) - 0.255565, (GLfloat) - 0.953102,
+       (GLfloat) - 0.162682, (GLfloat) - 0.257426, (GLfloat) - 0.952505,
+       (GLfloat) - 0.167026, (GLfloat) - 0.217710, (GLfloat) - 0.961616,
+       (GLfloat) - 0.163395, (GLfloat) - 0.208930, (GLfloat) - 0.964184,
+       (GLfloat) - 0.205866, (GLfloat) - 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) - 0.178092, (GLfloat) - 0.947923, (GLfloat) - 0.264055,
+       (GLfloat) - 0.068965, (GLfloat) - 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) - 0.073162, (GLfloat) - 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) - 0.124478, (GLfloat) - 0.692921, (GLfloat) - 0.710188,
+       (GLfloat) - 0.138779, (GLfloat) - 0.668059, (GLfloat) - 0.731052,
+       (GLfloat) - 0.361212, (GLfloat) - 0.721974, (GLfloat) - 0.590152,
+       (GLfloat) - 0.383785, (GLfloat) - 0.697396, (GLfloat) - 0.605267,
+       (GLfloat) 0.178092, (GLfloat) - 0.947923, (GLfloat) - 0.264056,
+       (GLfloat) 0.205866, (GLfloat) - 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) 0.341480, (GLfloat) - 0.751054, (GLfloat) - 0.565075,
+       (GLfloat) 0.372366, (GLfloat) - 0.719604, (GLfloat) - 0.586101,
+       (GLfloat) 0.138114, (GLfloat) - 0.672674, (GLfloat) - 0.726935,
+       (GLfloat) 0.117913, (GLfloat) - 0.706722, (GLfloat) - 0.697597,
+       (GLfloat) 0.073162, (GLfloat) - 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) 0.068965, (GLfloat) - 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) - 0.850324, (GLfloat) - 0.141983, (GLfloat) - 0.506744,
+       (GLfloat) - 0.849870, (GLfloat) - 0.138328, (GLfloat) - 0.508515,
+       (GLfloat) - 0.979216, (GLfloat) - 0.120924, (GLfloat) - 0.162831,
+       (GLfloat) - 0.979161, (GLfloat) - 0.122085, (GLfloat) - 0.162295,
+       (GLfloat) - 0.968183, (GLfloat) - 0.188900, (GLfloat) - 0.164128,
+       (GLfloat) - 0.966893, (GLfloat) - 0.198288, (GLfloat) - 0.160620,
+       (GLfloat) - 0.836326, (GLfloat) - 0.225408, (GLfloat) - 0.499751,
+       (GLfloat) - 0.836389, (GLfloat) - 0.213159, (GLfloat) - 0.504991,
+       (GLfloat) - 0.850324, (GLfloat) - 0.141983, (GLfloat) 0.506744,
+       (GLfloat) - 0.849870, (GLfloat) - 0.138328, (GLfloat) 0.508515,
+       (GLfloat) - 0.836389, (GLfloat) - 0.213159, (GLfloat) 0.504991,
+       (GLfloat) - 0.836326, (GLfloat) - 0.225408, (GLfloat) 0.499751,
+       (GLfloat) - 0.968183, (GLfloat) - 0.188900, (GLfloat) 0.164128,
+       (GLfloat) - 0.966894, (GLfloat) - 0.198288, (GLfloat) 0.160620,
+       (GLfloat) - 0.979161, (GLfloat) - 0.122085, (GLfloat) 0.162295,
+       (GLfloat) - 0.979216, (GLfloat) - 0.120924, (GLfloat) 0.162831,
+       (GLfloat) - 0.283620, (GLfloat) - 0.936578, (GLfloat) 0.205866,
+       (GLfloat) - 0.264055, (GLfloat) - 0.947923, (GLfloat) 0.178091,
+       (GLfloat) - 0.315105, (GLfloat) - 0.946548, (GLfloat) 0.068965,
+       (GLfloat) - 0.304029, (GLfloat) - 0.949849, (GLfloat) 0.073162,
+       (GLfloat) - 0.727074, (GLfloat) - 0.675149, (GLfloat) 0.124651,
+       (GLfloat) - 0.751597, (GLfloat) - 0.644138, (GLfloat) 0.142086,
+       (GLfloat) - 0.595577, (GLfloat) - 0.717790, (GLfloat) 0.360647,
+       (GLfloat) - 0.614268, (GLfloat) - 0.686473, (GLfloat) 0.389139,
+       (GLfloat) - 0.264055, (GLfloat) - 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) - 0.283620, (GLfloat) - 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) - 0.595576, (GLfloat) - 0.717790, (GLfloat) - 0.360646,
+       (GLfloat) - 0.614268, (GLfloat) - 0.686473, (GLfloat) - 0.389139,
+       (GLfloat) - 0.751597, (GLfloat) - 0.644138, (GLfloat) - 0.142087,
+       (GLfloat) - 0.727074, (GLfloat) - 0.675149, (GLfloat) - 0.124651,
+       (GLfloat) - 0.304029, (GLfloat) - 0.949849, (GLfloat) - 0.073163,
+       (GLfloat) - 0.315105, (GLfloat) - 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) - 0.511124, (GLfloat) - 0.173862, (GLfloat) 0.841739,
+       (GLfloat) - 0.507920, (GLfloat) - 0.180984, (GLfloat) 0.842177,
+       (GLfloat) - 0.167026, (GLfloat) - 0.217709, (GLfloat) 0.961616,
+       (GLfloat) - 0.163395, (GLfloat) - 0.208930, (GLfloat) 0.964184,
+       (GLfloat) - 0.162682, (GLfloat) - 0.257426, (GLfloat) 0.952505,
+       (GLfloat) - 0.162122, (GLfloat) - 0.255564, (GLfloat) 0.953102,
+       (GLfloat) - 0.501146, (GLfloat) - 0.246358, (GLfloat) 0.829554,
+       (GLfloat) - 0.502437, (GLfloat) - 0.243295, (GLfloat) 0.829677,
+       (GLfloat) 0.484153, (GLfloat) - 0.303994, (GLfloat) 0.820478,
+       (GLfloat) 0.489225, (GLfloat) - 0.294820, (GLfloat) 0.820816,
+       (GLfloat) 0.489881, (GLfloat) - 0.318876, (GLfloat) 0.811378,
+       (GLfloat) 0.481923, (GLfloat) - 0.335378, (GLfloat) 0.809489,
+       (GLfloat) 0.160269, (GLfloat) - 0.275036, (GLfloat) 0.947982,
+       (GLfloat) 0.153877, (GLfloat) - 0.291476, (GLfloat) 0.944120,
+       (GLfloat) 0.151647, (GLfloat) - 0.258100, (GLfloat) 0.954142,
+       (GLfloat) 0.156385, (GLfloat) - 0.248335, (GLfloat) 0.955967,
+       (GLfloat) 0.205866, (GLfloat) - 0.936578, (GLfloat) 0.283620,
+       (GLfloat) 0.178092, (GLfloat) - 0.947923, (GLfloat) 0.264055,
+       (GLfloat) 0.068965, (GLfloat) - 0.946548, (GLfloat) 0.315105,
+       (GLfloat) 0.073163, (GLfloat) - 0.949849, (GLfloat) 0.304029,
+       (GLfloat) 0.117913, (GLfloat) - 0.706722, (GLfloat) 0.697597,
+       (GLfloat) 0.138114, (GLfloat) - 0.672674, (GLfloat) 0.726935,
+       (GLfloat) 0.341480, (GLfloat) - 0.751053, (GLfloat) 0.565076,
+       (GLfloat) 0.372365, (GLfloat) - 0.719604, (GLfloat) 0.586101,
+       (GLfloat) - 0.178091, (GLfloat) - 0.947923, (GLfloat) 0.264055,
+       (GLfloat) - 0.205866, (GLfloat) - 0.936578, (GLfloat) 0.283620,
+       (GLfloat) - 0.361213, (GLfloat) - 0.721973, (GLfloat) 0.590152,
+       (GLfloat) - 0.383785, (GLfloat) - 0.697396, (GLfloat) 0.605267,
+       (GLfloat) - 0.138779, (GLfloat) - 0.668060, (GLfloat) 0.731052,
+       (GLfloat) - 0.124478, (GLfloat) - 0.692921, (GLfloat) 0.710188,
+       (GLfloat) - 0.073162, (GLfloat) - 0.949849, (GLfloat) 0.304029,
+       (GLfloat) - 0.068965, (GLfloat) - 0.946548, (GLfloat) 0.315105,
+       (GLfloat) 0.135802, (GLfloat) - 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) 0.124011, (GLfloat) - 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) 0.043834, (GLfloat) - 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) 0.039656, (GLfloat) - 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) 0.030163, (GLfloat) - 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) 0.033079, (GLfloat) - 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) 0.109621, (GLfloat) - 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) 0.114709, (GLfloat) - 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) - 0.124011, (GLfloat) - 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) - 0.135802, (GLfloat) - 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) - 0.109621, (GLfloat) - 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) - 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) - 0.033079, (GLfloat) - 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) - 0.030163, (GLfloat) - 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) - 0.043834, (GLfloat) - 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) - 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) - 0.135802, (GLfloat) - 0.982944, (GLfloat) 0.124011,
+       (GLfloat) - 0.124011, (GLfloat) - 0.982944, (GLfloat) 0.135802,
+       (GLfloat) - 0.043834, (GLfloat) - 0.993006, (GLfloat) 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) - 0.992607, (GLfloat) 0.114709,
+       (GLfloat) - 0.030163, (GLfloat) - 0.998998, (GLfloat) 0.033079,
+       (GLfloat) - 0.033079, (GLfloat) - 0.998998, (GLfloat) 0.030163,
+       (GLfloat) - 0.109621, (GLfloat) - 0.993006, (GLfloat) 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) - 0.992607, (GLfloat) 0.039656,
+       (GLfloat) 0.124011, (GLfloat) - 0.982944, (GLfloat) 0.135802,
+       (GLfloat) 0.135802, (GLfloat) - 0.982944, (GLfloat) 0.124011,
+       (GLfloat) 0.109621, (GLfloat) - 0.993006, (GLfloat) 0.043834,
+       (GLfloat) 0.114709, (GLfloat) - 0.992607, (GLfloat) 0.039656,
+       (GLfloat) 0.033079, (GLfloat) - 0.998998, (GLfloat) 0.030163,
+       (GLfloat) 0.030163, (GLfloat) - 0.998998, (GLfloat) 0.033079,
+       (GLfloat) 0.043834, (GLfloat) - 0.993006, (GLfloat) 0.109621,
+       (GLfloat) 0.039656, (GLfloat) - 0.992607, (GLfloat) 0.114709,
+};
+
+static unsigned short int s1_2_POLS[] =
+{
+      3, 12, 76, 74, 1, 3, 12, 74, 82, 1, 3, 22, 78, 74, 1, 3, 22, 74, 76, 1,
+      3, 78, 20, 80, 1, 3, 80, 74, 78, 1, 3, 80, 28, 82, 1, 3, 82, 74, 80, 1,
+      3, 13, 84, 77, 1, 3, 13, 77, 88, 1, 3, 84, 24, 86, 1, 3, 86, 77, 84, 1,
+      3, 86, 20, 78, 1, 3, 78, 77, 86, 1, 3, 22, 88, 77, 1, 3, 22, 77, 78, 1,
+      3, 14, 90, 85, 1, 3, 14, 85, 93, 1, 3, 26, 91, 85, 1, 3, 26, 85, 90, 1,
+      3, 20, 86, 85, 1, 3, 20, 85, 91, 1, 3, 86, 24, 93, 1, 3, 93, 85, 86, 1,
+      3, 15, 95, 79, 1, 3, 15, 79, 97, 1, 3, 95, 28, 80, 1, 3, 80, 79, 95, 1,
+      3, 20, 91, 79, 1, 3, 20, 79, 80, 1, 3, 26, 97, 79, 1, 3, 26, 79, 91, 1,
+    3, 13, 99, 83, 1, 3, 13, 83, 84, 1, 3, 99, 30, 101, 1, 3, 101, 83, 99, 1,
+   3, 23, 102, 83, 1, 3, 23, 83, 101, 1, 3, 24, 84, 83, 1, 3, 24, 83, 102, 1,
+       3, 108, 16, 104, 1, 3, 104, 100, 108, 1, 3, 32, 106, 100, 1, 3, 32, 100, 104, 1,
+       3, 106, 23, 101, 1, 3, 101, 100, 106, 1, 3, 30, 108, 100, 1, 3, 30, 100, 101, 1,
+       3, 17, 110, 105, 1, 3, 17, 105, 113, 1, 3, 110, 33, 111, 1, 3, 111, 105, 110, 1,
+       3, 23, 106, 105, 1, 3, 23, 105, 111, 1, 3, 106, 32, 113, 1, 3, 113, 105, 106, 1,
+   3, 114, 14, 93, 1, 3, 93, 92, 114, 1, 3, 24, 102, 92, 1, 3, 24, 92, 93, 1,
+  3, 23, 111, 92, 1, 3, 23, 92, 102, 1, 3, 33, 114, 92, 1, 3, 33, 92, 111, 1,
+       3, 104, 16, 116, 1, 3, 116, 103, 104, 1, 3, 35, 118, 103, 1, 3, 35, 103, 116, 1,
+       3, 118, 31, 119, 1, 3, 119, 103, 118, 1, 3, 32, 104, 103, 1, 3, 32, 103, 119, 1,
+       3, 125, 18, 121, 1, 3, 121, 117, 125, 1, 3, 36, 123, 117, 1, 3, 36, 117, 121, 1,
+       3, 123, 31, 118, 1, 3, 118, 117, 123, 1, 3, 35, 125, 117, 1, 3, 35, 117, 118, 1,
+       3, 19, 127, 122, 1, 3, 19, 122, 130, 1, 3, 37, 128, 122, 1, 3, 37, 122, 127, 1,
+       3, 128, 31, 123, 1, 3, 123, 122, 128, 1, 3, 36, 130, 122, 1, 3, 36, 122, 123, 1,
+       3, 17, 113, 112, 1, 3, 17, 112, 131, 1, 3, 32, 119, 112, 1, 3, 32, 112, 113, 1,
+       3, 119, 31, 128, 1, 3, 128, 112, 119, 1, 3, 37, 131, 112, 1, 3, 37, 112, 128, 1,
+       3, 121, 18, 133, 1, 3, 133, 120, 121, 1, 3, 39, 134, 120, 1, 3, 39, 120, 133, 1,
+       3, 134, 27, 135, 1, 3, 135, 120, 134, 1, 3, 36, 121, 120, 1, 3, 36, 120, 135, 1,
+    3, 12, 82, 81, 1, 3, 12, 81, 138, 1, 3, 28, 136, 81, 1, 3, 28, 81, 82, 1,
+3, 27, 134, 81, 1, 3, 27, 81, 136, 1, 3, 134, 39, 138, 1, 3, 138, 81, 134, 1,
+  3, 95, 15, 139, 1, 3, 139, 94, 95, 1, 3, 40, 140, 94, 1, 3, 40, 94, 139, 1,
+   3, 27, 136, 94, 1, 3, 27, 94, 140, 1, 3, 28, 95, 94, 1, 3, 28, 94, 136, 1,
+       3, 19, 130, 129, 1, 3, 19, 129, 141, 1, 3, 130, 36, 135, 1, 3, 135, 129, 130, 1,
+       3, 27, 140, 129, 1, 3, 27, 129, 135, 1, 3, 140, 40, 141, 1, 3, 141, 129, 140, 1,
+ 3, 14, 114, 89, 1, 3, 14, 89, 90, 1, 3, 114, 33, 142, 1, 3, 142, 89, 114, 1,
+  3, 25, 143, 89, 1, 3, 25, 89, 142, 1, 3, 143, 26, 90, 1, 3, 90, 89, 143, 1,
+       3, 17, 131, 109, 1, 3, 17, 109, 110, 1, 3, 131, 37, 144, 1, 3, 144, 109, 131, 1,
+       3, 25, 142, 109, 1, 3, 25, 109, 144, 1, 3, 142, 33, 110, 1, 3, 110, 109, 142, 1,
+       3, 19, 141, 126, 1, 3, 19, 126, 127, 1, 3, 141, 40, 145, 1, 3, 145, 126, 141, 1,
+       3, 25, 144, 126, 1, 3, 25, 126, 145, 1, 3, 144, 37, 127, 1, 3, 127, 126, 144, 1,
+   3, 15, 97, 96, 1, 3, 15, 96, 139, 1, 3, 97, 26, 143, 1, 3, 143, 96, 97, 1,
+3, 25, 145, 96, 1, 3, 25, 96, 143, 1, 3, 145, 40, 139, 1, 3, 139, 96, 145, 1,
+ 3, 12, 146, 75, 1, 3, 12, 75, 76, 1, 3, 146, 41, 148, 1, 3, 148, 75, 146, 1,
+  3, 21, 149, 75, 1, 3, 21, 75, 148, 1, 3, 149, 22, 76, 1, 3, 76, 75, 149, 1,
+       3, 155, 8, 151, 1, 3, 151, 147, 155, 1, 3, 43, 153, 147, 1, 3, 43, 147, 151, 1,
+       3, 153, 21, 148, 1, 3, 148, 147, 153, 1, 3, 41, 155, 147, 1, 3, 41, 147, 148, 1,
+       3, 160, 11, 157, 1, 3, 157, 152, 160, 1, 3, 44, 158, 152, 1, 3, 44, 152, 157, 1,
+       3, 158, 21, 153, 1, 3, 153, 152, 158, 1, 3, 43, 160, 152, 1, 3, 43, 152, 153, 1,
+   3, 13, 88, 87, 1, 3, 13, 87, 161, 1, 3, 88, 22, 149, 1, 3, 149, 87, 88, 1,
+3, 21, 158, 87, 1, 3, 21, 87, 149, 1, 3, 158, 44, 161, 1, 3, 161, 87, 158, 1,
+       3, 18, 162, 132, 1, 3, 18, 132, 133, 1, 3, 162, 45, 164, 1, 3, 164, 132, 162, 1,
+       3, 38, 165, 132, 1, 3, 38, 132, 164, 1, 3, 165, 39, 133, 1, 3, 133, 132, 165, 1,
+       3, 170, 9, 167, 1, 3, 167, 163, 170, 1, 3, 47, 168, 163, 1, 3, 47, 163, 167, 1,
+       3, 168, 38, 164, 1, 3, 164, 163, 168, 1, 3, 45, 170, 163, 1, 3, 45, 163, 164, 1,
+3, 8, 155, 154, 1, 3, 8, 154, 173, 1, 3, 155, 41, 171, 1, 3, 171, 154, 155, 1,
+       3, 38, 168, 154, 1, 3, 38, 154, 171, 1, 3, 168, 47, 173, 1, 3, 173, 154, 168, 1,
+       3, 146, 12, 138, 1, 3, 138, 137, 146, 1, 3, 39, 165, 137, 1, 3, 39, 137, 138, 1,
+       3, 165, 38, 171, 1, 3, 171, 137, 165, 1, 3, 41, 146, 137, 1, 3, 41, 137, 171, 1,
+       3, 16, 108, 107, 1, 3, 16, 107, 177, 1, 3, 108, 30, 174, 1, 3, 174, 107, 108, 1,
+       3, 29, 176, 107, 1, 3, 29, 107, 174, 1, 3, 176, 50, 177, 1, 3, 177, 107, 176, 1,
+  3, 99, 13, 161, 1, 3, 161, 98, 99, 1, 3, 44, 178, 98, 1, 3, 44, 98, 161, 1,
+ 3, 178, 29, 174, 1, 3, 174, 98, 178, 1, 3, 30, 99, 98, 1, 3, 30, 98, 174, 1,
+       3, 11, 180, 156, 1, 3, 11, 156, 157, 1, 3, 180, 49, 181, 1, 3, 181, 156, 180, 1,
+       3, 29, 178, 156, 1, 3, 29, 156, 181, 1, 3, 178, 44, 157, 1, 3, 157, 156, 178, 1,
+       3, 185, 10, 183, 1, 3, 183, 175, 185, 1, 3, 50, 176, 175, 1, 3, 50, 175, 183, 1,
+       3, 176, 29, 181, 1, 3, 181, 175, 176, 1, 3, 49, 185, 175, 1, 3, 49, 175, 181, 1,
+       3, 162, 18, 125, 1, 3, 125, 124, 162, 1, 3, 35, 186, 124, 1, 3, 35, 124, 125, 1,
+       3, 186, 34, 187, 1, 3, 187, 124, 186, 1, 3, 45, 162, 124, 1, 3, 45, 124, 187, 1,
+       3, 116, 16, 177, 1, 3, 177, 115, 116, 1, 3, 50, 188, 115, 1, 3, 50, 115, 177, 1,
+       3, 188, 34, 186, 1, 3, 186, 115, 188, 1, 3, 35, 116, 115, 1, 3, 35, 115, 186, 1,
+       3, 183, 10, 190, 1, 3, 190, 182, 183, 1, 3, 52, 191, 182, 1, 3, 52, 182, 190, 1,
+       3, 191, 34, 188, 1, 3, 188, 182, 191, 1, 3, 188, 50, 183, 1, 3, 183, 182, 188, 1,
+       3, 193, 9, 170, 1, 3, 170, 169, 193, 1, 3, 170, 45, 187, 1, 3, 187, 169, 170, 1,
+       3, 187, 34, 191, 1, 3, 191, 169, 187, 1, 3, 52, 193, 169, 1, 3, 52, 169, 191, 1,
+3, 1, 196, 194, 1, 3, 1, 194, 201, 1, 3, 54, 198, 194, 1, 3, 54, 194, 196, 1,
+       3, 198, 46, 199, 1, 3, 199, 194, 198, 1, 3, 199, 56, 201, 1, 3, 201, 194, 199, 1,
+3, 3, 203, 197, 1, 3, 3, 197, 206, 1, 3, 203, 55, 204, 1, 3, 204, 197, 203, 1,
+       3, 46, 198, 197, 1, 3, 46, 197, 204, 1, 3, 198, 54, 206, 1, 3, 206, 197, 198, 1,
+       3, 208, 8, 173, 1, 3, 173, 172, 208, 1, 3, 47, 207, 172, 1, 3, 47, 172, 173, 1,
+       3, 207, 46, 204, 1, 3, 204, 172, 207, 1, 3, 55, 208, 172, 1, 3, 55, 172, 204, 1,
+3, 9, 209, 166, 1, 3, 9, 166, 167, 1, 3, 56, 199, 166, 1, 3, 56, 166, 209, 1,
+       3, 46, 207, 166, 1, 3, 46, 166, 199, 1, 3, 207, 47, 167, 1, 3, 167, 166, 207, 1,
+3, 1, 201, 200, 1, 3, 1, 200, 214, 1, 3, 201, 56, 210, 1, 3, 210, 200, 201, 1,
+       3, 51, 212, 200, 1, 3, 51, 200, 210, 1, 3, 212, 59, 214, 1, 3, 214, 200, 212, 1,
+       3, 209, 9, 193, 1, 3, 193, 192, 209, 1, 3, 52, 215, 192, 1, 3, 52, 192, 193, 1,
+       3, 215, 51, 210, 1, 3, 210, 192, 215, 1, 3, 56, 209, 192, 1, 3, 56, 192, 210, 1,
+       3, 190, 10, 216, 1, 3, 216, 189, 190, 1, 3, 57, 217, 189, 1, 3, 57, 189, 216, 1,
+       3, 217, 51, 215, 1, 3, 215, 189, 217, 1, 3, 52, 190, 189, 1, 3, 52, 189, 215, 1,
+3, 0, 219, 211, 1, 3, 0, 211, 221, 1, 3, 219, 59, 212, 1, 3, 212, 211, 219, 1,
+       3, 51, 217, 211, 1, 3, 51, 211, 212, 1, 3, 217, 57, 221, 1, 3, 221, 211, 217, 1,
+3, 0, 221, 220, 1, 3, 0, 220, 226, 1, 3, 221, 57, 222, 1, 3, 222, 220, 221, 1,
+       3, 222, 48, 224, 1, 3, 224, 220, 222, 1, 3, 62, 226, 220, 1, 3, 62, 220, 224, 1,
+       3, 10, 185, 184, 1, 3, 10, 184, 216, 1, 3, 185, 49, 227, 1, 3, 227, 184, 185, 1,
+       3, 48, 222, 184, 1, 3, 48, 184, 227, 1, 3, 57, 216, 184, 1, 3, 57, 184, 222, 1,
+       3, 180, 11, 228, 1, 3, 228, 179, 180, 1, 3, 60, 229, 179, 1, 3, 60, 179, 228, 1,
+       3, 229, 48, 227, 1, 3, 227, 179, 229, 1, 3, 49, 180, 179, 1, 3, 49, 179, 227, 1,
+3, 2, 231, 223, 1, 3, 2, 223, 233, 1, 3, 231, 62, 224, 1, 3, 224, 223, 231, 1,
+       3, 48, 229, 223, 1, 3, 48, 223, 224, 1, 3, 229, 60, 233, 1, 3, 233, 223, 229, 1,
+3, 2, 233, 232, 1, 3, 2, 232, 237, 1, 3, 233, 60, 234, 1, 3, 234, 232, 233, 1,
+       3, 42, 235, 232, 1, 3, 42, 232, 234, 1, 3, 235, 64, 237, 1, 3, 237, 232, 235, 1,
+       3, 228, 11, 160, 1, 3, 160, 159, 228, 1, 3, 43, 238, 159, 1, 3, 43, 159, 160, 1,
+       3, 238, 42, 234, 1, 3, 234, 159, 238, 1, 3, 60, 228, 159, 1, 3, 60, 159, 234, 1,
+       3, 151, 8, 208, 1, 3, 208, 150, 151, 1, 3, 55, 239, 150, 1, 3, 55, 150, 208, 1,
+       3, 239, 42, 238, 1, 3, 238, 150, 239, 1, 3, 43, 151, 150, 1, 3, 43, 150, 238, 1,
+3, 3, 241, 202, 1, 3, 3, 202, 203, 1, 3, 241, 64, 235, 1, 3, 235, 202, 241, 1,
+       3, 42, 239, 202, 1, 3, 42, 202, 235, 1, 3, 239, 55, 203, 1, 3, 203, 202, 239, 1,
+       3, 245, 2, 237, 1, 3, 237, 236, 245, 1, 3, 64, 242, 236, 1, 3, 64, 236, 237, 1,
+       3, 242, 63, 244, 1, 3, 244, 236, 242, 1, 3, 68, 245, 236, 1, 3, 68, 236, 244, 1,
+       3, 241, 3, 246, 1, 3, 246, 240, 241, 1, 3, 65, 248, 240, 1, 3, 65, 240, 246, 1,
+       3, 248, 63, 242, 1, 3, 242, 240, 248, 1, 3, 64, 241, 240, 1, 3, 64, 240, 242, 1,
+3, 4, 250, 247, 1, 3, 4, 247, 253, 1, 3, 67, 251, 247, 1, 3, 67, 247, 250, 1,
+       3, 63, 248, 247, 1, 3, 63, 247, 251, 1, 3, 248, 65, 253, 1, 3, 253, 247, 248, 1,
+3, 7, 255, 243, 1, 3, 7, 243, 257, 1, 3, 255, 68, 244, 1, 3, 244, 243, 255, 1,
+       3, 63, 251, 243, 1, 3, 63, 243, 244, 1, 3, 67, 257, 243, 1, 3, 67, 243, 251, 1,
+       3, 246, 3, 206, 1, 3, 206, 205, 246, 1, 3, 54, 258, 205, 1, 3, 54, 205, 206, 1,
+       3, 258, 53, 259, 1, 3, 259, 205, 258, 1, 3, 65, 246, 205, 1, 3, 65, 205, 259, 1,
+       3, 196, 1, 260, 1, 3, 260, 195, 196, 1, 3, 69, 262, 195, 1, 3, 69, 195, 260, 1,
+       3, 53, 258, 195, 1, 3, 53, 195, 262, 1, 3, 258, 54, 196, 1, 3, 196, 195, 258, 1,
+3, 5, 264, 261, 1, 3, 5, 261, 267, 1, 3, 70, 265, 261, 1, 3, 70, 261, 264, 1,
+       3, 53, 262, 261, 1, 3, 53, 261, 265, 1, 3, 262, 69, 267, 1, 3, 267, 261, 262, 1,
+3, 4, 253, 252, 1, 3, 4, 252, 268, 1, 3, 253, 65, 259, 1, 3, 259, 252, 253, 1,
+       3, 53, 265, 252, 1, 3, 53, 252, 259, 1, 3, 70, 268, 252, 1, 3, 70, 252, 265, 1,
+       3, 260, 1, 214, 1, 3, 214, 213, 260, 1, 3, 59, 269, 213, 1, 3, 59, 213, 214, 1,
+       3, 269, 58, 270, 1, 3, 270, 213, 269, 1, 3, 69, 260, 213, 1, 3, 69, 213, 270, 1,
+       3, 219, 0, 271, 1, 3, 271, 218, 219, 1, 3, 71, 273, 218, 1, 3, 71, 218, 271, 1,
+       3, 273, 58, 269, 1, 3, 269, 218, 273, 1, 3, 59, 219, 218, 1, 3, 59, 218, 269, 1,
+3, 6, 275, 272, 1, 3, 6, 272, 278, 1, 3, 72, 276, 272, 1, 3, 72, 272, 275, 1,
+       3, 58, 273, 272, 1, 3, 58, 272, 276, 1, 3, 273, 71, 278, 1, 3, 278, 272, 273, 1,
+3, 5, 267, 266, 1, 3, 5, 266, 279, 1, 3, 267, 69, 270, 1, 3, 270, 266, 267, 1,
+       3, 58, 276, 266, 1, 3, 58, 266, 270, 1, 3, 72, 279, 266, 1, 3, 72, 266, 276, 1,
+       3, 271, 0, 226, 1, 3, 226, 225, 271, 1, 3, 226, 62, 280, 1, 3, 280, 225, 226, 1,
+       3, 61, 281, 225, 1, 3, 61, 225, 280, 1, 3, 71, 271, 225, 1, 3, 71, 225, 281, 1,
+       3, 231, 2, 245, 1, 3, 245, 230, 231, 1, 3, 68, 282, 230, 1, 3, 68, 230, 245, 1,
+       3, 282, 61, 280, 1, 3, 280, 230, 282, 1, 3, 62, 231, 230, 1, 3, 62, 230, 280, 1,
+3, 7, 283, 254, 1, 3, 7, 254, 255, 1, 3, 73, 284, 254, 1, 3, 73, 254, 283, 1,
+       3, 61, 282, 254, 1, 3, 61, 254, 284, 1, 3, 282, 68, 255, 1, 3, 255, 254, 282, 1,
+3, 6, 278, 277, 1, 3, 6, 277, 285, 1, 3, 278, 71, 281, 1, 3, 281, 277, 278, 1,
+       3, 61, 284, 277, 1, 3, 61, 277, 281, 1, 3, 73, 285, 277, 1, 3, 73, 277, 284, 1,
+3, 4, 268, 249, 1, 3, 4, 249, 250, 1, 3, 268, 70, 286, 1, 3, 286, 249, 268, 1,
+       3, 66, 287, 249, 1, 3, 66, 249, 286, 1, 3, 287, 67, 250, 1, 3, 250, 249, 287, 1,
+3, 5, 279, 263, 1, 3, 5, 263, 264, 1, 3, 279, 72, 288, 1, 3, 288, 263, 279, 1,
+       3, 66, 286, 263, 1, 3, 66, 263, 288, 1, 3, 286, 70, 264, 1, 3, 264, 263, 286, 1,
+3, 6, 285, 274, 1, 3, 6, 274, 275, 1, 3, 285, 73, 289, 1, 3, 289, 274, 285, 1,
+       3, 66, 288, 274, 1, 3, 66, 274, 289, 1, 3, 288, 72, 275, 1, 3, 275, 274, 288, 1,
+3, 7, 257, 256, 1, 3, 7, 256, 283, 1, 3, 257, 67, 287, 1, 3, 287, 256, 257, 1,
+       3, 66, 289, 256, 1, 3, 66, 256, 287, 1, 3, 289, 73, 283, 1, 3, 283, 256, 289, 1,
+
+       0
+};
+
+struct lwo  LWO_s1_2 =
+{
+       290,                    /* number of points */
+       s1_2_PNTS, s1_2_normals, s1_2_POLS, 0L
+};
+
+#endif /* MODE_sproingies */
+
+/* End of s1_2.c */
diff --git a/xlockmore-4.14/modes/glx/s1_3.c b/xlockmore-4.14/modes/glx/s1_3.c
new file mode 100644 (file)
index 0000000..8bf3039
--- /dev/null
@@ -0,0 +1,1057 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)s1_3.c       4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points, polygons, and normal vectors to render "s1_3" in 3D.
+ *
+ * Generated by lw2ogl.  Link this with your program but do
+ * not edit by hand.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_sproingies
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat s1_3_PNTS[] =
+{
+       (GLfloat) 0.386176, (GLfloat) 0.201223, (GLfloat) - 0.326853,
+       (GLfloat) 0.386176, (GLfloat) 0.201223, (GLfloat) - 0.673147,
+       (GLfloat) 0.704261, (GLfloat) 0.116939, (GLfloat) - 0.326853,
+       (GLfloat) 0.704261, (GLfloat) 0.116939, (GLfloat) - 0.673147,
+       (GLfloat) 0.642426, (GLfloat) 0.035438, (GLfloat) - 0.638667,
+       (GLfloat) 0.369306, (GLfloat) 0.083596, (GLfloat) - 0.638667,
+       (GLfloat) 0.369306, (GLfloat) 0.083596, (GLfloat) - 0.361333,
+       (GLfloat) 0.642426, (GLfloat) 0.035438, (GLfloat) - 0.361333,
+       (GLfloat) 0.845007, (GLfloat) 0.268518, (GLfloat) - 0.678159,
+       (GLfloat) 0.620074, (GLfloat) 0.472355, (GLfloat) - 0.678159,
+       (GLfloat) 0.620074, (GLfloat) 0.472355, (GLfloat) - 0.321841,
+       (GLfloat) 0.845007, (GLfloat) 0.268518, (GLfloat) - 0.321841,
+       (GLfloat) 1.115671, (GLfloat) 0.352342, (GLfloat) - 0.673147,
+       (GLfloat) 1.115671, (GLfloat) 0.352342, (GLfloat) - 0.326853,
+       (GLfloat) 1.204957, (GLfloat) 0.421449, (GLfloat) - 0.361333,
+       (GLfloat) 1.204957, (GLfloat) 0.421449, (GLfloat) - 0.638667,
+       (GLfloat) 0.937575, (GLfloat) 0.636550, (GLfloat) - 0.326853,
+       (GLfloat) 1.066291, (GLfloat) 0.661627, (GLfloat) - 0.361333,
+       (GLfloat) 0.937575, (GLfloat) 0.636550, (GLfloat) - 0.673147,
+       (GLfloat) 1.066291, (GLfloat) 0.661627, (GLfloat) - 0.638667,
+       (GLfloat) 1.227578, (GLfloat) 0.320768, (GLfloat) - 0.500000,
+       (GLfloat) 1.017091, (GLfloat) 0.274757, (GLfloat) - 0.500000,
+       (GLfloat) 1.148052, (GLfloat) 0.300668, (GLfloat) - 0.500000,
+       (GLfloat) 1.107591, (GLfloat) 0.526937, (GLfloat) - 0.260702,
+       (GLfloat) 1.194861, (GLfloat) 0.375780, (GLfloat) - 0.324904,
+       (GLfloat) 1.151611, (GLfloat) 0.550768, (GLfloat) - 0.500000,
+       (GLfloat) 1.230206, (GLfloat) 0.391113, (GLfloat) - 0.500000,
+       (GLfloat) 1.107591, (GLfloat) 0.526937, (GLfloat) - 0.739298,
+       (GLfloat) 1.194861, (GLfloat) 0.375780, (GLfloat) - 0.675096,
+       (GLfloat) 0.885754, (GLfloat) 0.445570, (GLfloat) - 0.261655,
+       (GLfloat) 1.026623, (GLfloat) 0.494446, (GLfloat) - 0.263891,
+       (GLfloat) 0.987605, (GLfloat) 0.733106, (GLfloat) - 0.500000,
+       (GLfloat) 1.019270, (GLfloat) 0.677486, (GLfloat) - 0.324904,
+       (GLfloat) 1.141425, (GLfloat) 0.544887, (GLfloat) - 0.322437,
+       (GLfloat) 0.754416, (GLfloat) 0.616383, (GLfloat) - 0.500000,
+       (GLfloat) 0.905194, (GLfloat) 0.688224, (GLfloat) - 0.500000,
+       (GLfloat) 1.019270, (GLfloat) 0.677486, (GLfloat) - 0.675096,
+       (GLfloat) 1.052644, (GLfloat) 0.698661, (GLfloat) - 0.500000,
+       (GLfloat) 0.885754, (GLfloat) 0.445570, (GLfloat) - 0.738345,
+       (GLfloat) 1.026623, (GLfloat) 0.494446, (GLfloat) - 0.736109,
+       (GLfloat) 1.141425, (GLfloat) 0.544887, (GLfloat) - 0.677562,
+       (GLfloat) 0.982068, (GLfloat) 0.320307, (GLfloat) - 0.674787,
+       (GLfloat) 0.801608, (GLfloat) 0.169177, (GLfloat) - 0.500000,
+       (GLfloat) 0.885904, (GLfloat) 0.231457, (GLfloat) - 0.500000,
+       (GLfloat) 0.982068, (GLfloat) 0.320307, (GLfloat) - 0.325213,
+       (GLfloat) 0.789439, (GLfloat) 0.570833, (GLfloat) - 0.674787,
+       (GLfloat) 0.617093, (GLfloat) 0.264045, (GLfloat) - 0.738345,
+       (GLfloat) 0.732540, (GLfloat) 0.370437, (GLfloat) - 0.742944,
+       (GLfloat) 0.617093, (GLfloat) 0.264045, (GLfloat) - 0.261655,
+       (GLfloat) 0.732540, (GLfloat) 0.370437, (GLfloat) - 0.257056,
+       (GLfloat) 0.789439, (GLfloat) 0.570833, (GLfloat) - 0.325213,
+       (GLfloat) 0.432577, (GLfloat) 0.358913, (GLfloat) - 0.500000,
+       (GLfloat) 0.579177, (GLfloat) 0.509417, (GLfloat) - 0.500000,
+       (GLfloat) 0.513237, (GLfloat) 0.088956, (GLfloat) - 0.739298,
+       (GLfloat) 0.545218, (GLfloat) 0.159081, (GLfloat) - 0.736109,
+       (GLfloat) 0.752404, (GLfloat) 0.194475, (GLfloat) - 0.674787,
+       (GLfloat) 0.481782, (GLfloat) 0.333615, (GLfloat) - 0.674787,
+       (GLfloat) 0.481782, (GLfloat) 0.333615, (GLfloat) - 0.325213,
+       (GLfloat) 0.279139, (GLfloat) 0.132156, (GLfloat) - 0.500000,
+       (GLfloat) 0.328343, (GLfloat) 0.216547, (GLfloat) - 0.500000,
+       (GLfloat) 0.752404, (GLfloat) 0.194475, (GLfloat) - 0.325213,
+       (GLfloat) 0.513237, (GLfloat) 0.088956, (GLfloat) - 0.260702,
+       (GLfloat) 0.545218, (GLfloat) 0.159081, (GLfloat) - 0.263891,
+       (GLfloat) 0.747335, (GLfloat) 0.045755, (GLfloat) - 0.500000,
+       (GLfloat) 0.762094, (GLfloat) 0.101615, (GLfloat) - 0.500000,
+       (GLfloat) 0.684631, (GLfloat) 0.057942, (GLfloat) - 0.675096,
+       (GLfloat) 0.502661, (GLfloat) 0.041337, (GLfloat) - 0.500000,
+       (GLfloat) 0.679568, (GLfloat) 0.022087, (GLfloat) - 0.500000,
+       (GLfloat) 0.684631, (GLfloat) 0.057942, (GLfloat) - 0.324904,
+       (GLfloat) 0.342054, (GLfloat) 0.121167, (GLfloat) - 0.675096,
+       (GLfloat) 0.504703, (GLfloat) 0.052920, (GLfloat) - 0.677562,
+       (GLfloat) 0.342054, (GLfloat) 0.121167, (GLfloat) - 0.324904,
+       (GLfloat) 0.329838, (GLfloat) 0.083754, (GLfloat) - 0.500000,
+       (GLfloat) 0.504703, (GLfloat) 0.052920, (GLfloat) - 0.322437,
+       (GLfloat) 1.188046, (GLfloat) 0.322006, (GLfloat) - 0.596277,
+       (GLfloat) 1.077742, (GLfloat) 0.301825, (GLfloat) - 0.594388,
+       (GLfloat) 1.139957, (GLfloat) 0.313586, (GLfloat) - 0.594444,
+       (GLfloat) 1.188046, (GLfloat) 0.322006, (GLfloat) - 0.403722,
+       (GLfloat) 1.196159, (GLfloat) 0.308395, (GLfloat) - 0.500000,
+       (GLfloat) 1.230706, (GLfloat) 0.358565, (GLfloat) - 0.587500,
+       (GLfloat) 1.219224, (GLfloat) 0.334520, (GLfloat) - 0.595444,
+       (GLfloat) 1.123141, (GLfloat) 0.430895, (GLfloat) - 0.724648,
+       (GLfloat) 1.163707, (GLfloat) 0.362839, (GLfloat) - 0.676509,
+       (GLfloat) 1.123141, (GLfloat) 0.430895, (GLfloat) - 0.275352,
+       (GLfloat) 1.163707, (GLfloat) 0.362839, (GLfloat) - 0.323491,
+       (GLfloat) 1.230706, (GLfloat) 0.358565, (GLfloat) - 0.412500,
+       (GLfloat) 1.219224, (GLfloat) 0.334520, (GLfloat) - 0.404556,
+       (GLfloat) 1.077742, (GLfloat) 0.301825, (GLfloat) - 0.405612,
+       (GLfloat) 1.139957, (GLfloat) 0.313586, (GLfloat) - 0.405556,
+       (GLfloat) 1.191900, (GLfloat) 0.469528, (GLfloat) - 0.409500,
+       (GLfloat) 1.221821, (GLfloat) 0.401211, (GLfloat) - 0.417500,
+       (GLfloat) 1.239508, (GLfloat) 0.345749, (GLfloat) - 0.500000,
+       (GLfloat) 1.171456, (GLfloat) 0.461189, (GLfloat) - 0.294000,
+       (GLfloat) 1.207091, (GLfloat) 0.397037, (GLfloat) - 0.339125,
+       (GLfloat) 1.171456, (GLfloat) 0.461189, (GLfloat) - 0.706000,
+       (GLfloat) 1.207091, (GLfloat) 0.397037, (GLfloat) - 0.660875,
+       (GLfloat) 1.191900, (GLfloat) 0.469528, (GLfloat) - 0.590500,
+       (GLfloat) 1.221821, (GLfloat) 0.401211, (GLfloat) - 0.582500,
+       (GLfloat) 1.011218, (GLfloat) 0.399402, (GLfloat) - 0.279763,
+       (GLfloat) 1.075195, (GLfloat) 0.416935, (GLfloat) - 0.279631,
+       (GLfloat) 1.025784, (GLfloat) 0.594229, (GLfloat) - 0.275352,
+       (GLfloat) 1.074463, (GLfloat) 0.512562, (GLfloat) - 0.259306,
+       (GLfloat) 1.155185, (GLfloat) 0.444556, (GLfloat) - 0.276838,
+       (GLfloat) 0.960879, (GLfloat) 0.703118, (GLfloat) - 0.403722,
+       (GLfloat) 0.985218, (GLfloat) 0.662285, (GLfloat) - 0.323491,
+       (GLfloat) 1.083956, (GLfloat) 0.612743, (GLfloat) - 0.294000,
+       (GLfloat) 1.059471, (GLfloat) 0.609015, (GLfloat) - 0.276838,
+       (GLfloat) 0.911431, (GLfloat) 0.545768, (GLfloat) - 0.279763,
+       (GLfloat) 0.978052, (GLfloat) 0.571957, (GLfloat) - 0.279631,
+       (GLfloat) 1.101400, (GLfloat) 0.626279, (GLfloat) - 0.409500,
+       (GLfloat) 1.098258, (GLfloat) 0.615227, (GLfloat) - 0.335375,
+       (GLfloat) 1.128758, (GLfloat) 0.537574, (GLfloat) - 0.278500,
+       (GLfloat) 1.024706, (GLfloat) 0.715367, (GLfloat) - 0.412500,
+       (GLfloat) 1.046216, (GLfloat) 0.675680, (GLfloat) - 0.339125,
+       (GLfloat) 1.180758, (GLfloat) 0.472333, (GLfloat) - 0.335375,
+       (GLfloat) 0.844907, (GLfloat) 0.643346, (GLfloat) - 0.405612,
+       (GLfloat) 0.913289, (GLfloat) 0.675305, (GLfloat) - 0.405556,
+       (GLfloat) 0.960879, (GLfloat) 0.703118, (GLfloat) - 0.596277,
+       (GLfloat) 0.952766, (GLfloat) 0.716730, (GLfloat) - 0.500000,
+       (GLfloat) 0.995432, (GLfloat) 0.719051, (GLfloat) - 0.404556,
+       (GLfloat) 1.025784, (GLfloat) 0.594229, (GLfloat) - 0.724648,
+       (GLfloat) 0.985218, (GLfloat) 0.662285, (GLfloat) - 0.676509,
+       (GLfloat) 1.024706, (GLfloat) 0.715367, (GLfloat) - 0.587500,
+       (GLfloat) 0.995432, (GLfloat) 0.719051, (GLfloat) - 0.595444,
+       (GLfloat) 0.844907, (GLfloat) 0.643346, (GLfloat) - 0.594388,
+       (GLfloat) 0.913289, (GLfloat) 0.675305, (GLfloat) - 0.594444,
+       (GLfloat) 1.101400, (GLfloat) 0.626279, (GLfloat) - 0.590500,
+       (GLfloat) 1.057196, (GLfloat) 0.686350, (GLfloat) - 0.582500,
+       (GLfloat) 1.018008, (GLfloat) 0.729398, (GLfloat) - 0.500000,
+       (GLfloat) 1.083956, (GLfloat) 0.612743, (GLfloat) - 0.706000,
+       (GLfloat) 1.046216, (GLfloat) 0.675680, (GLfloat) - 0.660875,
+       (GLfloat) 1.057196, (GLfloat) 0.686350, (GLfloat) - 0.417500,
+       (GLfloat) 0.911431, (GLfloat) 0.545768, (GLfloat) - 0.720237,
+       (GLfloat) 0.978052, (GLfloat) 0.571957, (GLfloat) - 0.720369,
+       (GLfloat) 1.074463, (GLfloat) 0.512562, (GLfloat) - 0.740694,
+       (GLfloat) 1.059471, (GLfloat) 0.609015, (GLfloat) - 0.723162,
+       (GLfloat) 1.155185, (GLfloat) 0.444556, (GLfloat) - 0.723162,
+       (GLfloat) 1.011218, (GLfloat) 0.399402, (GLfloat) - 0.720237,
+       (GLfloat) 1.075195, (GLfloat) 0.416935, (GLfloat) - 0.720369,
+       (GLfloat) 1.180758, (GLfloat) 0.472333, (GLfloat) - 0.664625,
+       (GLfloat) 1.128758, (GLfloat) 0.537574, (GLfloat) - 0.721500,
+       (GLfloat) 1.098258, (GLfloat) 0.615227, (GLfloat) - 0.664625,
+       (GLfloat) 1.149055, (GLfloat) 0.549292, (GLfloat) - 0.402250,
+       (GLfloat) 1.197930, (GLfloat) 0.464638, (GLfloat) - 0.500000,
+       (GLfloat) 1.100180, (GLfloat) 0.633946, (GLfloat) - 0.500000,
+       (GLfloat) 1.149055, (GLfloat) 0.549292, (GLfloat) - 0.597750,
+       (GLfloat) 1.052796, (GLfloat) 0.338416, (GLfloat) - 0.673044,
+       (GLfloat) 0.938670, (GLfloat) 0.265970, (GLfloat) - 0.596525,
+       (GLfloat) 1.008335, (GLfloat) 0.286145, (GLfloat) - 0.595338,
+       (GLfloat) 1.086058, (GLfloat) 0.289628, (GLfloat) - 0.500000,
+       (GLfloat) 0.826297, (GLfloat) 0.209826, (GLfloat) - 0.596525,
+       (GLfloat) 0.875679, (GLfloat) 0.240722, (GLfloat) - 0.597178,
+       (GLfloat) 0.938670, (GLfloat) 0.265970, (GLfloat) - 0.403475,
+       (GLfloat) 0.948068, (GLfloat) 0.255539, (GLfloat) - 0.500000,
+       (GLfloat) 0.863485, (GLfloat) 0.349410, (GLfloat) - 0.725225,
+       (GLfloat) 0.910476, (GLfloat) 0.297260, (GLfloat) - 0.676962,
+       (GLfloat) 0.863485, (GLfloat) 0.349410, (GLfloat) - 0.274775,
+       (GLfloat) 0.910476, (GLfloat) 0.297260, (GLfloat) - 0.323037,
+       (GLfloat) 1.008335, (GLfloat) 0.286145, (GLfloat) - 0.404662,
+       (GLfloat) 0.826297, (GLfloat) 0.209826, (GLfloat) - 0.403475,
+       (GLfloat) 0.875679, (GLfloat) 0.240722, (GLfloat) - 0.402822,
+       (GLfloat) 1.052796, (GLfloat) 0.338416, (GLfloat) - 0.326956,
+       (GLfloat) 0.869854, (GLfloat) 0.606754, (GLfloat) - 0.673044,
+       (GLfloat) 0.750708, (GLfloat) 0.474572, (GLfloat) - 0.725225,
+       (GLfloat) 0.833218, (GLfloat) 0.513896, (GLfloat) - 0.722456,
+       (GLfloat) 0.961325, (GLfloat) 0.472585, (GLfloat) - 0.735969,
+       (GLfloat) 0.601974, (GLfloat) 0.366500, (GLfloat) - 0.725225,
+       (GLfloat) 0.671195, (GLfloat) 0.426029, (GLfloat) - 0.726748,
+       (GLfloat) 0.807096, (GLfloat) 0.411991, (GLfloat) - 0.741313,
+       (GLfloat) 0.675523, (GLfloat) 0.558012, (GLfloat) - 0.596525,
+       (GLfloat) 0.703717, (GLfloat) 0.526722, (GLfloat) - 0.676962,
+       (GLfloat) 0.938289, (GLfloat) 0.377245, (GLfloat) - 0.722456,
+       (GLfloat) 0.736568, (GLfloat) 0.272496, (GLfloat) - 0.725225,
+       (GLfloat) 0.793886, (GLfloat) 0.314845, (GLfloat) - 0.726748,
+       (GLfloat) 0.961325, (GLfloat) 0.472585, (GLfloat) - 0.264031,
+       (GLfloat) 0.750708, (GLfloat) 0.474572, (GLfloat) - 0.274775,
+       (GLfloat) 0.833218, (GLfloat) 0.513896, (GLfloat) - 0.277544,
+       (GLfloat) 0.869854, (GLfloat) 0.606754, (GLfloat) - 0.326956,
+       (GLfloat) 0.938289, (GLfloat) 0.377245, (GLfloat) - 0.277544,
+       (GLfloat) 0.736568, (GLfloat) 0.272496, (GLfloat) - 0.274775,
+       (GLfloat) 0.793886, (GLfloat) 0.314845, (GLfloat) - 0.273252,
+       (GLfloat) 0.807096, (GLfloat) 0.411991, (GLfloat) - 0.258687,
+       (GLfloat) 0.675523, (GLfloat) 0.558012, (GLfloat) - 0.403475,
+       (GLfloat) 0.703717, (GLfloat) 0.526722, (GLfloat) - 0.323037,
+       (GLfloat) 0.601974, (GLfloat) 0.366500, (GLfloat) - 0.274775,
+       (GLfloat) 0.671195, (GLfloat) 0.426029, (GLfloat) - 0.273252,
+       (GLfloat) 0.836591, (GLfloat) 0.655543, (GLfloat) - 0.500000,
+       (GLfloat) 0.763171, (GLfloat) 0.604996, (GLfloat) - 0.595338,
+       (GLfloat) 0.763171, (GLfloat) 0.604996, (GLfloat) - 0.404662,
+       (GLfloat) 0.512245, (GLfloat) 0.429169, (GLfloat) - 0.403475,
+       (GLfloat) 0.589401, (GLfloat) 0.500151, (GLfloat) - 0.402822,
+       (GLfloat) 0.666125, (GLfloat) 0.568442, (GLfloat) - 0.500000,
+       (GLfloat) 0.512245, (GLfloat) 0.429169, (GLfloat) - 0.596525,
+       (GLfloat) 0.589401, (GLfloat) 0.500151, (GLfloat) - 0.597178,
+       (GLfloat) 0.495371, (GLfloat) 0.238512, (GLfloat) - 0.720237,
+       (GLfloat) 0.432817, (GLfloat) 0.138665, (GLfloat) - 0.724648,
+       (GLfloat) 0.458468, (GLfloat) 0.182068, (GLfloat) - 0.720369,
+       (GLfloat) 0.656244, (GLfloat) 0.179386, (GLfloat) - 0.720237,
+       (GLfloat) 0.575807, (GLfloat) 0.208949, (GLfloat) - 0.735969,
+       (GLfloat) 0.543287, (GLfloat) 0.301992, (GLfloat) - 0.722456,
+       (GLfloat) 0.388123, (GLfloat) 0.277930, (GLfloat) - 0.594388,
+       (GLfloat) 0.428341, (GLfloat) 0.263148, (GLfloat) - 0.673044,
+       (GLfloat) 0.763492, (GLfloat) 0.139968, (GLfloat) - 0.594388,
+       (GLfloat) 0.723274, (GLfloat) 0.154750, (GLfloat) - 0.673044,
+       (GLfloat) 0.690899, (GLfloat) 0.226098, (GLfloat) - 0.722456,
+       (GLfloat) 0.617440, (GLfloat) 0.099959, (GLfloat) - 0.724648,
+       (GLfloat) 0.631969, (GLfloat) 0.136095, (GLfloat) - 0.720369,
+       (GLfloat) 0.669271, (GLfloat) 0.319498, (GLfloat) - 0.741313,
+       (GLfloat) 0.792649, (GLfloat) 0.233327, (GLfloat) - 0.676962,
+       (GLfloat) 0.545894, (GLfloat) 0.405668, (GLfloat) - 0.676962,
+       (GLfloat) 0.444878, (GLfloat) 0.352588, (GLfloat) - 0.595338,
+       (GLfloat) 0.388123, (GLfloat) 0.277930, (GLfloat) - 0.405612,
+       (GLfloat) 0.374717, (GLfloat) 0.282857, (GLfloat) - 0.500000,
+       (GLfloat) 0.309735, (GLfloat) 0.164469, (GLfloat) - 0.596277,
+       (GLfloat) 0.342801, (GLfloat) 0.212716, (GLfloat) - 0.594444,
+       (GLfloat) 0.501029, (GLfloat) 0.437003, (GLfloat) - 0.500000,
+       (GLfloat) 0.545894, (GLfloat) 0.405668, (GLfloat) - 0.323037,
+       (GLfloat) 0.444878, (GLfloat) 0.352588, (GLfloat) - 0.404662,
+       (GLfloat) 0.309735, (GLfloat) 0.164469, (GLfloat) - 0.403722,
+       (GLfloat) 0.342801, (GLfloat) 0.212716, (GLfloat) - 0.405556,
+       (GLfloat) 0.495371, (GLfloat) 0.238512, (GLfloat) - 0.279763,
+       (GLfloat) 0.428341, (GLfloat) 0.263148, (GLfloat) - 0.326956,
+       (GLfloat) 0.543287, (GLfloat) 0.301992, (GLfloat) - 0.277544,
+       (GLfloat) 0.656244, (GLfloat) 0.179386, (GLfloat) - 0.279763,
+       (GLfloat) 0.575807, (GLfloat) 0.208949, (GLfloat) - 0.264031,
+       (GLfloat) 0.432817, (GLfloat) 0.138665, (GLfloat) - 0.275352,
+       (GLfloat) 0.458468, (GLfloat) 0.182068, (GLfloat) - 0.279631,
+       (GLfloat) 0.669271, (GLfloat) 0.319498, (GLfloat) - 0.258687,
+       (GLfloat) 0.792649, (GLfloat) 0.233327, (GLfloat) - 0.323037,
+       (GLfloat) 0.690899, (GLfloat) 0.226098, (GLfloat) - 0.277544,
+       (GLfloat) 0.617440, (GLfloat) 0.099959, (GLfloat) - 0.275352,
+       (GLfloat) 0.631969, (GLfloat) 0.136095, (GLfloat) - 0.279631,
+       (GLfloat) 0.763492, (GLfloat) 0.139968, (GLfloat) - 0.405612,
+       (GLfloat) 0.723274, (GLfloat) 0.154750, (GLfloat) - 0.326956,
+       (GLfloat) 0.789307, (GLfloat) 0.175501, (GLfloat) - 0.404662,
+       (GLfloat) 0.776898, (GLfloat) 0.135041, (GLfloat) - 0.500000,
+       (GLfloat) 0.740522, (GLfloat) 0.074155, (GLfloat) - 0.403722,
+       (GLfloat) 0.747636, (GLfloat) 0.105446, (GLfloat) - 0.405556,
+       (GLfloat) 0.837513, (GLfloat) 0.201992, (GLfloat) - 0.500000,
+       (GLfloat) 0.789307, (GLfloat) 0.175501, (GLfloat) - 0.595338,
+       (GLfloat) 0.740522, (GLfloat) 0.074155, (GLfloat) - 0.596277,
+       (GLfloat) 0.747636, (GLfloat) 0.105446, (GLfloat) - 0.594444,
+       (GLfloat) 0.755907, (GLfloat) 0.070930, (GLfloat) - 0.500000,
+       (GLfloat) 0.710325, (GLfloat) 0.032750, (GLfloat) - 0.412500,
+       (GLfloat) 0.731601, (GLfloat) 0.048967, (GLfloat) - 0.404556,
+       (GLfloat) 0.694366, (GLfloat) 0.083832, (GLfloat) - 0.323491,
+       (GLfloat) 0.694366, (GLfloat) 0.083832, (GLfloat) - 0.676509,
+       (GLfloat) 0.710325, (GLfloat) 0.032750, (GLfloat) - 0.587500,
+       (GLfloat) 0.731601, (GLfloat) 0.048967, (GLfloat) - 0.595444,
+       (GLfloat) 0.592781, (GLfloat) 0.031264, (GLfloat) - 0.590500,
+       (GLfloat) 0.667212, (GLfloat) 0.026513, (GLfloat) - 0.582500,
+       (GLfloat) 0.725378, (GLfloat) 0.028862, (GLfloat) - 0.500000,
+       (GLfloat) 0.593625, (GLfloat) 0.053327, (GLfloat) - 0.706000,
+       (GLfloat) 0.666096, (GLfloat) 0.041783, (GLfloat) - 0.660875,
+       (GLfloat) 0.593625, (GLfloat) 0.053327, (GLfloat) - 0.294000,
+       (GLfloat) 0.666096, (GLfloat) 0.041783, (GLfloat) - 0.339125,
+       (GLfloat) 0.592781, (GLfloat) 0.031264, (GLfloat) - 0.409500,
+       (GLfloat) 0.667212, (GLfloat) 0.026513, (GLfloat) - 0.417500,
+       (GLfloat) 0.525128, (GLfloat) 0.119312, (GLfloat) - 0.740694,
+       (GLfloat) 0.606658, (GLfloat) 0.072023, (GLfloat) - 0.723162,
+       (GLfloat) 0.355891, (GLfloat) 0.154793, (GLfloat) - 0.676509,
+       (GLfloat) 0.421284, (GLfloat) 0.083716, (GLfloat) - 0.706000,
+       (GLfloat) 0.419921, (GLfloat) 0.106487, (GLfloat) - 0.723162,
+       (GLfloat) 0.414531, (GLfloat) 0.062694, (GLfloat) - 0.590500,
+       (GLfloat) 0.423841, (GLfloat) 0.069426, (GLfloat) - 0.664625,
+       (GLfloat) 0.507243, (GLfloat) 0.067325, (GLfloat) - 0.721500,
+       (GLfloat) 0.304584, (GLfloat) 0.104293, (GLfloat) - 0.587500,
+       (GLfloat) 0.349234, (GLfloat) 0.097654, (GLfloat) - 0.660875,
+       (GLfloat) 0.586334, (GLfloat) 0.040774, (GLfloat) - 0.664625,
+       (GLfloat) 0.294350, (GLfloat) 0.167695, (GLfloat) - 0.500000,
+       (GLfloat) 0.294978, (GLfloat) 0.129544, (GLfloat) - 0.595444,
+       (GLfloat) 0.355891, (GLfloat) 0.154793, (GLfloat) - 0.323491,
+       (GLfloat) 0.304584, (GLfloat) 0.104293, (GLfloat) - 0.412500,
+       (GLfloat) 0.294978, (GLfloat) 0.129544, (GLfloat) - 0.404556,
+       (GLfloat) 0.414531, (GLfloat) 0.062694, (GLfloat) - 0.409500,
+       (GLfloat) 0.342964, (GLfloat) 0.083687, (GLfloat) - 0.417500,
+       (GLfloat) 0.289108, (GLfloat) 0.105788, (GLfloat) - 0.500000,
+       (GLfloat) 0.421284, (GLfloat) 0.083716, (GLfloat) - 0.294000,
+       (GLfloat) 0.349234, (GLfloat) 0.097654, (GLfloat) - 0.339125,
+       (GLfloat) 0.342964, (GLfloat) 0.083687, (GLfloat) - 0.582500,
+       (GLfloat) 0.525128, (GLfloat) 0.119312, (GLfloat) - 0.259306,
+       (GLfloat) 0.419921, (GLfloat) 0.106487, (GLfloat) - 0.276838,
+       (GLfloat) 0.606658, (GLfloat) 0.072023, (GLfloat) - 0.276838,
+       (GLfloat) 0.586334, (GLfloat) 0.040774, (GLfloat) - 0.335375,
+       (GLfloat) 0.507243, (GLfloat) 0.067325, (GLfloat) - 0.278500,
+       (GLfloat) 0.423841, (GLfloat) 0.069426, (GLfloat) - 0.335375,
+       (GLfloat) 0.503173, (GLfloat) 0.044243, (GLfloat) - 0.597750,
+       (GLfloat) 0.599438, (GLfloat) 0.027269, (GLfloat) - 0.500000,
+       (GLfloat) 0.406908, (GLfloat) 0.061217, (GLfloat) - 0.500000,
+       (GLfloat) 0.503173, (GLfloat) 0.044243, (GLfloat) - 0.402250,
+};
+
+static GLfloat s1_3_normals[] =
+{
+       (GLfloat) 0.156072, (GLfloat) - 0.866199, (GLfloat) - 0.474700,
+       (GLfloat) 0.133323, (GLfloat) - 0.866325, (GLfloat) - 0.481359,
+       (GLfloat) 0.156764, (GLfloat) - 0.975995, (GLfloat) - 0.151191,
+       (GLfloat) 0.165110, (GLfloat) - 0.975177, (GLfloat) - 0.147543,
+       (GLfloat) 0.361485, (GLfloat) - 0.917862, (GLfloat) - 0.163883,
+       (GLfloat) 0.371348, (GLfloat) - 0.914502, (GLfloat) - 0.160580,
+       (GLfloat) 0.350149, (GLfloat) - 0.787582, (GLfloat) - 0.507060,
+       (GLfloat) 0.331724, (GLfloat) - 0.792390, (GLfloat) - 0.511934,
+       (GLfloat) 0.156072, (GLfloat) - 0.866199, (GLfloat) 0.474700,
+       (GLfloat) 0.133323, (GLfloat) - 0.866325, (GLfloat) 0.481359,
+       (GLfloat) 0.331724, (GLfloat) - 0.792390, (GLfloat) 0.511934,
+       (GLfloat) 0.350149, (GLfloat) - 0.787582, (GLfloat) 0.507061,
+       (GLfloat) 0.361485, (GLfloat) - 0.917862, (GLfloat) 0.163883,
+       (GLfloat) 0.371348, (GLfloat) - 0.914502, (GLfloat) 0.160580,
+       (GLfloat) 0.165110, (GLfloat) - 0.975177, (GLfloat) 0.147543,
+       (GLfloat) 0.156764, (GLfloat) - 0.975995, (GLfloat) 0.151191,
+       (GLfloat) 0.952910, (GLfloat) 0.222669, (GLfloat) 0.205865,
+       (GLfloat) 0.952953, (GLfloat) 0.245285, (GLfloat) 0.178091,
+       (GLfloat) 0.977287, (GLfloat) 0.200386, (GLfloat) 0.068964,
+       (GLfloat) 0.974607, (GLfloat) 0.211631, (GLfloat) 0.073163,
+       (GLfloat) 0.910741, (GLfloat) - 0.389976, (GLfloat) 0.135901,
+       (GLfloat) 0.891878, (GLfloat) - 0.425931, (GLfloat) 0.152106,
+       (GLfloat) 0.882467, (GLfloat) - 0.235214, (GLfloat) 0.407340,
+       (GLfloat) 0.868268, (GLfloat) - 0.279083, (GLfloat) 0.410151,
+       (GLfloat) 0.952953, (GLfloat) 0.245285, (GLfloat) - 0.178091,
+       (GLfloat) 0.952910, (GLfloat) 0.222669, (GLfloat) - 0.205865,
+       (GLfloat) 0.868268, (GLfloat) - 0.279083, (GLfloat) - 0.410151,
+       (GLfloat) 0.882468, (GLfloat) - 0.235213, (GLfloat) - 0.407340,
+       (GLfloat) 0.891878, (GLfloat) - 0.425931, (GLfloat) - 0.152106,
+       (GLfloat) 0.910741, (GLfloat) - 0.389976, (GLfloat) - 0.135901,
+       (GLfloat) 0.974607, (GLfloat) 0.211631, (GLfloat) - 0.073163,
+       (GLfloat) 0.977287, (GLfloat) 0.200386, (GLfloat) - 0.068964,
+       (GLfloat) 0.086707, (GLfloat) - 0.551974, (GLfloat) 0.829341,
+       (GLfloat) 0.062265, (GLfloat) - 0.551355, (GLfloat) 0.831944,
+       (GLfloat) - 0.014960, (GLfloat) - 0.207986, (GLfloat) 0.978017,
+       (GLfloat) - 0.026687, (GLfloat) - 0.208021, (GLfloat) 0.977760,
+       (GLfloat) 0.102710, (GLfloat) - 0.133733, (GLfloat) 0.985681,
+       (GLfloat) 0.099775, (GLfloat) - 0.134244, (GLfloat) 0.985913,
+       (GLfloat) 0.231521, (GLfloat) - 0.464011, (GLfloat) 0.855039,
+       (GLfloat) 0.236951, (GLfloat) - 0.462930, (GLfloat) 0.854137,
+       (GLfloat) - 0.295570, (GLfloat) 0.436154, (GLfloat) 0.849946,
+       (GLfloat) - 0.280583, (GLfloat) 0.437172, (GLfloat) 0.854490,
+       (GLfloat) - 0.178752, (GLfloat) 0.492834, (GLfloat) 0.851565,
+       (GLfloat) - 0.184330, (GLfloat) 0.491982, (GLfloat) 0.850868,
+       (GLfloat) - 0.033888, (GLfloat) 0.173633, (GLfloat) 0.984227,
+       (GLfloat) - 0.032872, (GLfloat) 0.173792, (GLfloat) 0.984234,
+       (GLfloat) - 0.140362, (GLfloat) 0.111822, (GLfloat) 0.983765,
+       (GLfloat) - 0.136701, (GLfloat) 0.111911, (GLfloat) 0.984271,
+       (GLfloat) 0.725871, (GLfloat) 0.640449, (GLfloat) 0.250870,
+       (GLfloat) 0.717328, (GLfloat) 0.635281, (GLfloat) 0.286109,
+       (GLfloat) 0.785252, (GLfloat) 0.532999, (GLfloat) 0.315105,
+       (GLfloat) 0.786013, (GLfloat) 0.538285, (GLfloat) 0.304028,
+       (GLfloat) 0.473766, (GLfloat) 0.428968, (GLfloat) 0.769111,
+       (GLfloat) 0.445991, (GLfloat) 0.427917, (GLfloat) 0.786117,
+       (GLfloat) 0.380921, (GLfloat) 0.670539, (GLfloat) 0.636613,
+       (GLfloat) 0.351469, (GLfloat) 0.675507, (GLfloat) 0.648198,
+       (GLfloat) 0.909972, (GLfloat) 0.319731, (GLfloat) 0.264053,
+       (GLfloat) 0.914034, (GLfloat) 0.290005, (GLfloat) 0.283618,
+       (GLfloat) 0.764793, (GLfloat) - 0.009035, (GLfloat) 0.644213,
+       (GLfloat) 0.748359, (GLfloat) - 0.049564, (GLfloat) 0.661439,
+       (GLfloat) 0.584615, (GLfloat) 0.165625, (GLfloat) 0.794225,
+       (GLfloat) 0.606922, (GLfloat) 0.199970, (GLfloat) 0.769193,
+       (GLfloat) 0.856780, (GLfloat) 0.408314, (GLfloat) 0.314973,
+       (GLfloat) 0.856353, (GLfloat) 0.416833, (GLfloat) 0.304811,
+       (GLfloat) - 0.450621, (GLfloat) 0.737913, (GLfloat) 0.502419,
+       (GLfloat) - 0.436449, (GLfloat) 0.741403, (GLfloat) 0.509739,
+       (GLfloat) - 0.507433, (GLfloat) 0.846833, (GLfloat) 0.159329,
+       (GLfloat) - 0.502539, (GLfloat) 0.849165, (GLfloat) 0.162398,
+       (GLfloat) - 0.409636, (GLfloat) 0.897074, (GLfloat) 0.165699,
+       (GLfloat) - 0.419809, (GLfloat) 0.893103, (GLfloat) 0.161638,
+       (GLfloat) - 0.332199, (GLfloat) 0.791771, (GLfloat) 0.512584,
+       (GLfloat) - 0.350779, (GLfloat) 0.787278, (GLfloat) 0.507097,
+       (GLfloat) - 0.436449, (GLfloat) 0.741403, (GLfloat) - 0.509738,
+       (GLfloat) - 0.450621, (GLfloat) 0.737913, (GLfloat) - 0.502419,
+       (GLfloat) - 0.332198, (GLfloat) 0.791771, (GLfloat) - 0.512584,
+       (GLfloat) - 0.350779, (GLfloat) 0.787278, (GLfloat) - 0.507097,
+       (GLfloat) - 0.419809, (GLfloat) 0.893103, (GLfloat) - 0.161638,
+       (GLfloat) - 0.409636, (GLfloat) 0.897074, (GLfloat) - 0.165699,
+       (GLfloat) - 0.507433, (GLfloat) 0.846833, (GLfloat) - 0.159329,
+       (GLfloat) - 0.502539, (GLfloat) 0.849165, (GLfloat) - 0.162398,
+       (GLfloat) 0.669290, (GLfloat) 0.713912, (GLfloat) - 0.205866,
+       (GLfloat) 0.688897, (GLfloat) 0.702641, (GLfloat) - 0.178093,
+       (GLfloat) 0.661903, (GLfloat) 0.745850, (GLfloat) - 0.074780,
+       (GLfloat) 0.670351, (GLfloat) 0.738996, (GLfloat) - 0.067190,
+       (GLfloat) 0.158706, (GLfloat) 0.978584, (GLfloat) - 0.131091,
+       (GLfloat) 0.119709, (GLfloat) 0.981678, (GLfloat) - 0.148253,
+       (GLfloat) 0.261869, (GLfloat) 0.885538, (GLfloat) - 0.383728,
+       (GLfloat) 0.223051, (GLfloat) 0.883291, (GLfloat) - 0.412366,
+       (GLfloat) 0.688897, (GLfloat) 0.702640, (GLfloat) 0.178092,
+       (GLfloat) 0.669290, (GLfloat) 0.713912, (GLfloat) 0.205867,
+       (GLfloat) 0.261868, (GLfloat) 0.885538, (GLfloat) 0.383728,
+       (GLfloat) 0.223050, (GLfloat) 0.883291, (GLfloat) 0.412366,
+       (GLfloat) 0.119709, (GLfloat) 0.981678, (GLfloat) 0.148253,
+       (GLfloat) 0.158706, (GLfloat) 0.978584, (GLfloat) 0.131091,
+       (GLfloat) 0.661903, (GLfloat) 0.745850, (GLfloat) 0.074780,
+       (GLfloat) 0.670351, (GLfloat) 0.738996, (GLfloat) 0.067190,
+       (GLfloat) - 0.295570, (GLfloat) 0.436154, (GLfloat) - 0.849946,
+       (GLfloat) - 0.280583, (GLfloat) 0.437172, (GLfloat) - 0.854490,
+       (GLfloat) - 0.136701, (GLfloat) 0.111911, (GLfloat) - 0.984271,
+       (GLfloat) - 0.140362, (GLfloat) 0.111822, (GLfloat) - 0.983765,
+       (GLfloat) - 0.033889, (GLfloat) 0.173633, (GLfloat) - 0.984227,
+       (GLfloat) - 0.032872, (GLfloat) 0.173792, (GLfloat) - 0.984234,
+       (GLfloat) - 0.184329, (GLfloat) 0.491983, (GLfloat) - 0.850868,
+       (GLfloat) - 0.178752, (GLfloat) 0.492834, (GLfloat) - 0.851565,
+       (GLfloat) 0.062265, (GLfloat) - 0.551355, (GLfloat) - 0.831944,
+       (GLfloat) 0.086707, (GLfloat) - 0.551973, (GLfloat) - 0.829342,
+       (GLfloat) 0.231522, (GLfloat) - 0.464010, (GLfloat) - 0.855039,
+       (GLfloat) 0.236951, (GLfloat) - 0.462929, (GLfloat) - 0.854137,
+       (GLfloat) 0.099774, (GLfloat) - 0.134244, (GLfloat) - 0.985913,
+       (GLfloat) 0.102710, (GLfloat) - 0.133733, (GLfloat) - 0.985681,
+       (GLfloat) - 0.014960, (GLfloat) - 0.207986, (GLfloat) - 0.978017,
+       (GLfloat) - 0.026687, (GLfloat) - 0.208021, (GLfloat) - 0.977760,
+       (GLfloat) 0.914034, (GLfloat) 0.290005, (GLfloat) - 0.283618,
+       (GLfloat) 0.909972, (GLfloat) 0.319730, (GLfloat) - 0.264054,
+       (GLfloat) 0.856780, (GLfloat) 0.408314, (GLfloat) - 0.314973,
+       (GLfloat) 0.856353, (GLfloat) 0.416833, (GLfloat) - 0.304811,
+       (GLfloat) 0.606923, (GLfloat) 0.199970, (GLfloat) - 0.769193,
+       (GLfloat) 0.584616, (GLfloat) 0.165625, (GLfloat) - 0.794224,
+       (GLfloat) 0.764793, (GLfloat) - 0.009035, (GLfloat) - 0.644213,
+       (GLfloat) 0.748360, (GLfloat) - 0.049564, (GLfloat) - 0.661439,
+       (GLfloat) 0.725871, (GLfloat) 0.640449, (GLfloat) - 0.250871,
+       (GLfloat) 0.717328, (GLfloat) 0.635281, (GLfloat) - 0.286109,
+       (GLfloat) 0.380922, (GLfloat) 0.670539, (GLfloat) - 0.636613,
+       (GLfloat) 0.351469, (GLfloat) 0.675507, (GLfloat) - 0.648197,
+       (GLfloat) 0.445992, (GLfloat) 0.427917, (GLfloat) - 0.786116,
+       (GLfloat) 0.473767, (GLfloat) 0.428968, (GLfloat) - 0.769111,
+       (GLfloat) 0.786013, (GLfloat) 0.538285, (GLfloat) - 0.304029,
+       (GLfloat) 0.785252, (GLfloat) 0.532999, (GLfloat) - 0.315105,
+       (GLfloat) 0.919156, (GLfloat) 0.373864, (GLfloat) 0.124010,
+       (GLfloat) 0.913260, (GLfloat) 0.384076, (GLfloat) 0.135802,
+       (GLfloat) 0.881886, (GLfloat) 0.458542, (GLfloat) 0.109621,
+       (GLfloat) 0.879452, (GLfloat) 0.461960, (GLfloat) 0.114709,
+       (GLfloat) 0.880239, (GLfloat) 0.473377, (GLfloat) 0.033080,
+       (GLfloat) 0.881697, (GLfloat) 0.470851, (GLfloat) 0.030163,
+       (GLfloat) 0.914779, (GLfloat) 0.401569, (GLfloat) 0.043834,
+       (GLfloat) 0.916978, (GLfloat) 0.396963, (GLfloat) 0.039657,
+       (GLfloat) 0.789250, (GLfloat) 0.598868, (GLfloat) 0.135802,
+       (GLfloat) 0.783354, (GLfloat) 0.609080, (GLfloat) 0.124010,
+       (GLfloat) 0.805159, (GLfloat) 0.591437, (GLfloat) 0.043834,
+       (GLfloat) 0.802269, (GLfloat) 0.595644, (GLfloat) 0.039656,
+       (GLfloat) 0.848617, (GLfloat) 0.528147, (GLfloat) 0.030163,
+       (GLfloat) 0.850075, (GLfloat) 0.525621, (GLfloat) 0.033079,
+       (GLfloat) 0.838052, (GLfloat) 0.534464, (GLfloat) 0.109621,
+       (GLfloat) 0.839795, (GLfloat) 0.530647, (GLfloat) 0.114709,
+       (GLfloat) 0.783354, (GLfloat) 0.609080, (GLfloat) - 0.124010,
+       (GLfloat) 0.789250, (GLfloat) 0.598868, (GLfloat) - 0.135802,
+       (GLfloat) 0.838052, (GLfloat) 0.534464, (GLfloat) - 0.109621,
+       (GLfloat) 0.839795, (GLfloat) 0.530647, (GLfloat) - 0.114709,
+       (GLfloat) 0.850075, (GLfloat) 0.525621, (GLfloat) - 0.033079,
+       (GLfloat) 0.848617, (GLfloat) 0.528147, (GLfloat) - 0.030163,
+       (GLfloat) 0.805159, (GLfloat) 0.591437, (GLfloat) - 0.043834,
+       (GLfloat) 0.802269, (GLfloat) 0.595644, (GLfloat) - 0.039656,
+       (GLfloat) 0.913260, (GLfloat) 0.384076, (GLfloat) - 0.135802,
+       (GLfloat) 0.919156, (GLfloat) 0.373864, (GLfloat) - 0.124010,
+       (GLfloat) 0.914779, (GLfloat) 0.401569, (GLfloat) - 0.043834,
+       (GLfloat) 0.916978, (GLfloat) 0.396963, (GLfloat) - 0.039657,
+       (GLfloat) 0.881697, (GLfloat) 0.470851, (GLfloat) - 0.030163,
+       (GLfloat) 0.880239, (GLfloat) 0.473377, (GLfloat) - 0.033080,
+       (GLfloat) 0.881886, (GLfloat) 0.458542, (GLfloat) - 0.109621,
+       (GLfloat) 0.879452, (GLfloat) 0.461960, (GLfloat) - 0.114709,
+       (GLfloat) 0.190919, (GLfloat) - 0.865460, (GLfloat) - 0.463172,
+       (GLfloat) 0.162958, (GLfloat) - 0.864281, (GLfloat) - 0.475881,
+       (GLfloat) 0.232098, (GLfloat) - 0.863386, (GLfloat) - 0.447991,
+       (GLfloat) 0.201152, (GLfloat) - 0.862208, (GLfloat) - 0.464904,
+       (GLfloat) 0.208595, (GLfloat) - 0.967433, (GLfloat) - 0.143393,
+       (GLfloat) 0.220092, (GLfloat) - 0.966009, (GLfloat) - 0.135597,
+       (GLfloat) 0.173391, (GLfloat) - 0.973662, (GLfloat) - 0.148045,
+       (GLfloat) 0.183752, (GLfloat) - 0.972679, (GLfloat) - 0.141883,
+       (GLfloat) 0.370543, (GLfloat) - 0.826392, (GLfloat) - 0.423998,
+       (GLfloat) 0.337718, (GLfloat) - 0.831172, (GLfloat) - 0.441702,
+       (GLfloat) 0.357949, (GLfloat) - 0.923976, (GLfloat) - 0.134692,
+       (GLfloat) 0.370172, (GLfloat) - 0.920284, (GLfloat) - 0.126690,
+       (GLfloat) 0.265644, (GLfloat) - 0.954091, (GLfloat) - 0.138357,
+       (GLfloat) 0.277857, (GLfloat) - 0.951799, (GLfloat) - 0.129901,
+       (GLfloat) 0.288098, (GLfloat) - 0.854015, (GLfloat) - 0.433195,
+       (GLfloat) 0.255240, (GLfloat) - 0.854757, (GLfloat) - 0.451932,
+       (GLfloat) 0.370543, (GLfloat) - 0.826392, (GLfloat) 0.423998,
+       (GLfloat) 0.337718, (GLfloat) - 0.831172, (GLfloat) 0.441701,
+       (GLfloat) 0.255240, (GLfloat) - 0.854757, (GLfloat) 0.451932,
+       (GLfloat) 0.288099, (GLfloat) - 0.854015, (GLfloat) 0.433195,
+       (GLfloat) 0.265644, (GLfloat) - 0.954091, (GLfloat) 0.138357,
+       (GLfloat) 0.277857, (GLfloat) - 0.951799, (GLfloat) 0.129901,
+       (GLfloat) 0.370172, (GLfloat) - 0.920284, (GLfloat) 0.126690,
+       (GLfloat) 0.357949, (GLfloat) - 0.923976, (GLfloat) 0.134692,
+       (GLfloat) 0.162958, (GLfloat) - 0.864281, (GLfloat) 0.475881,
+       (GLfloat) 0.190920, (GLfloat) - 0.865460, (GLfloat) 0.463172,
+       (GLfloat) 0.173391, (GLfloat) - 0.973662, (GLfloat) 0.148045,
+       (GLfloat) 0.183752, (GLfloat) - 0.972679, (GLfloat) 0.141883,
+       (GLfloat) 0.220093, (GLfloat) - 0.966009, (GLfloat) 0.135597,
+       (GLfloat) 0.208595, (GLfloat) - 0.967433, (GLfloat) 0.143394,
+       (GLfloat) 0.232098, (GLfloat) - 0.863386, (GLfloat) 0.447991,
+       (GLfloat) 0.201153, (GLfloat) - 0.862208, (GLfloat) 0.464904,
+       (GLfloat) - 0.220569, (GLfloat) 0.498423, (GLfloat) - 0.838406,
+       (GLfloat) - 0.196440, (GLfloat) 0.495475, (GLfloat) - 0.846118,
+       (GLfloat) - 0.216090, (GLfloat) 0.523731, (GLfloat) - 0.824021,
+       (GLfloat) - 0.187439, (GLfloat) 0.518039, (GLfloat) - 0.834567,
+       (GLfloat) - 0.035834, (GLfloat) 0.186611, (GLfloat) - 0.981780,
+       (GLfloat) - 0.049583, (GLfloat) 0.189912, (GLfloat) - 0.980548,
+       (GLfloat) - 0.057093, (GLfloat) 0.164206, (GLfloat) - 0.984772,
+       (GLfloat) - 0.067095, (GLfloat) 0.165750, (GLfloat) - 0.983883,
+       (GLfloat) - 0.313656, (GLfloat) 0.500321, (GLfloat) - 0.807031,
+       (GLfloat) - 0.288105, (GLfloat) 0.497578, (GLfloat) - 0.818176,
+       (GLfloat) - 0.079226, (GLfloat) 0.180632, (GLfloat) - 0.980355,
+       (GLfloat) - 0.092817, (GLfloat) 0.182734, (GLfloat) - 0.978771,
+       (GLfloat) - 0.045426, (GLfloat) 0.193014, (GLfloat) - 0.980144,
+       (GLfloat) - 0.060897, (GLfloat) 0.196689, (GLfloat) - 0.978573,
+       (GLfloat) - 0.250277, (GLfloat) 0.526446, (GLfloat) - 0.812537,
+       (GLfloat) - 0.220552, (GLfloat) 0.520843, (GLfloat) - 0.824669,
+       (GLfloat) 0.247012, (GLfloat) - 0.528860, (GLfloat) - 0.811968,
+       (GLfloat) 0.280618, (GLfloat) - 0.529785, (GLfloat) - 0.800363,
+       (GLfloat) 0.197390, (GLfloat) - 0.535630, (GLfloat) - 0.821059,
+       (GLfloat) 0.231067, (GLfloat) - 0.540483, (GLfloat) - 0.809003,
+       (GLfloat) 0.104568, (GLfloat) - 0.158183, (GLfloat) - 0.981857,
+       (GLfloat) 0.094460, (GLfloat) - 0.156029, (GLfloat) - 0.983225,
+       (GLfloat) 0.111854, (GLfloat) - 0.162201, (GLfloat) - 0.980398,
+       (GLfloat) 0.101426, (GLfloat) - 0.160983, (GLfloat) - 0.981732,
+       (GLfloat) 0.117566, (GLfloat) - 0.537019, (GLfloat) - 0.835338,
+       (GLfloat) 0.146549, (GLfloat) - 0.540970, (GLfloat) - 0.828175,
+       (GLfloat) 0.055888, (GLfloat) - 0.173264, (GLfloat) - 0.983288,
+       (GLfloat) 0.045018, (GLfloat) - 0.171643, (GLfloat) - 0.984130,
+       (GLfloat) 0.088354, (GLfloat) - 0.160681, (GLfloat) - 0.983044,
+       (GLfloat) 0.078052, (GLfloat) - 0.158368, (GLfloat) - 0.984290,
+       (GLfloat) 0.157434, (GLfloat) - 0.535002, (GLfloat) - 0.830053,
+       (GLfloat) 0.189212, (GLfloat) - 0.540730, (GLfloat) - 0.819640,
+       (GLfloat) - 0.196440, (GLfloat) 0.495475, (GLfloat) 0.846118,
+       (GLfloat) - 0.220568, (GLfloat) 0.498423, (GLfloat) 0.838406,
+       (GLfloat) - 0.057093, (GLfloat) 0.164206, (GLfloat) 0.984772,
+       (GLfloat) - 0.067095, (GLfloat) 0.165750, (GLfloat) 0.983883,
+       (GLfloat) - 0.049583, (GLfloat) 0.189912, (GLfloat) 0.980548,
+       (GLfloat) - 0.035834, (GLfloat) 0.186611, (GLfloat) 0.981780,
+       (GLfloat) - 0.216090, (GLfloat) 0.523731, (GLfloat) 0.824021,
+       (GLfloat) - 0.187439, (GLfloat) 0.518039, (GLfloat) 0.834567,
+       (GLfloat) 0.117567, (GLfloat) - 0.537019, (GLfloat) 0.835337,
+       (GLfloat) 0.146549, (GLfloat) - 0.540970, (GLfloat) 0.828176,
+       (GLfloat) 0.189212, (GLfloat) - 0.540730, (GLfloat) 0.819640,
+       (GLfloat) 0.157434, (GLfloat) - 0.535002, (GLfloat) 0.830053,
+       (GLfloat) 0.088354, (GLfloat) - 0.160681, (GLfloat) 0.983044,
+       (GLfloat) 0.078052, (GLfloat) - 0.158368, (GLfloat) 0.984290,
+       (GLfloat) 0.045018, (GLfloat) - 0.171643, (GLfloat) 0.984130,
+       (GLfloat) 0.055888, (GLfloat) - 0.173264, (GLfloat) 0.983288,
+       (GLfloat) 0.280617, (GLfloat) - 0.529785, (GLfloat) 0.800363,
+       (GLfloat) 0.247012, (GLfloat) - 0.528861, (GLfloat) 0.811968,
+       (GLfloat) 0.111853, (GLfloat) - 0.162201, (GLfloat) 0.980398,
+       (GLfloat) 0.101425, (GLfloat) - 0.160983, (GLfloat) 0.981732,
+       (GLfloat) 0.094460, (GLfloat) - 0.156028, (GLfloat) 0.983225,
+       (GLfloat) 0.104568, (GLfloat) - 0.158182, (GLfloat) 0.981857,
+       (GLfloat) 0.197390, (GLfloat) - 0.535630, (GLfloat) 0.821059,
+       (GLfloat) 0.231068, (GLfloat) - 0.540483, (GLfloat) 0.809003,
+       (GLfloat) - 0.313656, (GLfloat) 0.500320, (GLfloat) 0.807031,
+       (GLfloat) - 0.288106, (GLfloat) 0.497578, (GLfloat) 0.818175,
+       (GLfloat) - 0.220552, (GLfloat) 0.520843, (GLfloat) 0.824669,
+       (GLfloat) - 0.250276, (GLfloat) 0.526446, (GLfloat) 0.812537,
+       (GLfloat) - 0.045425, (GLfloat) 0.193015, (GLfloat) 0.980144,
+       (GLfloat) - 0.060896, (GLfloat) 0.196690, (GLfloat) 0.978573,
+       (GLfloat) - 0.092818, (GLfloat) 0.182733, (GLfloat) 0.978771,
+       (GLfloat) - 0.079226, (GLfloat) 0.180631, (GLfloat) 0.980355,
+       (GLfloat) - 0.349743, (GLfloat) 0.793198, (GLfloat) - 0.498515,
+       (GLfloat) - 0.370416, (GLfloat) 0.791707, (GLfloat) - 0.485790,
+       (GLfloat) - 0.425027, (GLfloat) 0.892201, (GLfloat) - 0.152739,
+       (GLfloat) - 0.418180, (GLfloat) 0.894483, (GLfloat) - 0.158197,
+       (GLfloat) - 0.425590, (GLfloat) 0.893099, (GLfloat) - 0.145761,
+       (GLfloat) - 0.418336, (GLfloat) 0.895388, (GLfloat) - 0.152561,
+       (GLfloat) - 0.348153, (GLfloat) 0.802874, (GLfloat) - 0.483924,
+       (GLfloat) - 0.370992, (GLfloat) 0.802293, (GLfloat) - 0.467643,
+       (GLfloat) - 0.349743, (GLfloat) 0.793198, (GLfloat) 0.498515,
+       (GLfloat) - 0.370416, (GLfloat) 0.791707, (GLfloat) 0.485790,
+       (GLfloat) - 0.370992, (GLfloat) 0.802293, (GLfloat) 0.467643,
+       (GLfloat) - 0.348153, (GLfloat) 0.802874, (GLfloat) 0.483924,
+       (GLfloat) - 0.425590, (GLfloat) 0.893099, (GLfloat) 0.145761,
+       (GLfloat) - 0.418336, (GLfloat) 0.895388, (GLfloat) 0.152561,
+       (GLfloat) - 0.418180, (GLfloat) 0.894483, (GLfloat) 0.158197,
+       (GLfloat) - 0.425027, (GLfloat) 0.892201, (GLfloat) 0.152739,
+       (GLfloat) - 0.497325, (GLfloat) 0.745242, (GLfloat) 0.444165,
+       (GLfloat) - 0.479548, (GLfloat) 0.747889, (GLfloat) 0.459017,
+       (GLfloat) - 0.556394, (GLfloat) 0.819599, (GLfloat) 0.136684,
+       (GLfloat) - 0.551239, (GLfloat) 0.822088, (GLfloat) 0.142503,
+       (GLfloat) - 0.465768, (GLfloat) 0.872611, (GLfloat) 0.147004,
+       (GLfloat) - 0.472480, (GLfloat) 0.870146, (GLfloat) 0.140027,
+       (GLfloat) - 0.394421, (GLfloat) 0.789665, (GLfloat) 0.469959,
+       (GLfloat) - 0.416499, (GLfloat) 0.788420, (GLfloat) 0.452684,
+       (GLfloat) - 0.479547, (GLfloat) 0.747889, (GLfloat) - 0.459017,
+       (GLfloat) - 0.497325, (GLfloat) 0.745242, (GLfloat) - 0.444165,
+       (GLfloat) - 0.394421, (GLfloat) 0.789665, (GLfloat) - 0.469959,
+       (GLfloat) - 0.416498, (GLfloat) 0.788420, (GLfloat) - 0.452684,
+       (GLfloat) - 0.472480, (GLfloat) 0.870146, (GLfloat) - 0.140027,
+       (GLfloat) - 0.465768, (GLfloat) 0.872611, (GLfloat) - 0.147004,
+       (GLfloat) - 0.556394, (GLfloat) 0.819599, (GLfloat) - 0.136684,
+       (GLfloat) - 0.551239, (GLfloat) 0.822088, (GLfloat) - 0.142503,
+       (GLfloat) - 0.459423, (GLfloat) 0.314205, (GLfloat) - 0.830786,
+       (GLfloat) - 0.469135, (GLfloat) 0.308642, (GLfloat) - 0.827438,
+       (GLfloat) - 0.156023, (GLfloat) 0.098476, (GLfloat) - 0.982832,
+       (GLfloat) - 0.151547, (GLfloat) 0.101367, (GLfloat) - 0.983239,
+       (GLfloat) - 0.168365, (GLfloat) 0.083796, (GLfloat) - 0.982157,
+       (GLfloat) - 0.160419, (GLfloat) 0.086730, (GLfloat) - 0.983231,
+       (GLfloat) - 0.460048, (GLfloat) 0.328491, (GLfloat) - 0.824894,
+       (GLfloat) - 0.469062, (GLfloat) 0.325364, (GLfloat) - 0.821048,
+       (GLfloat) 0.495554, (GLfloat) - 0.246920, (GLfloat) - 0.832741,
+       (GLfloat) 0.477125, (GLfloat) - 0.265003, (GLfloat) - 0.837929,
+       (GLfloat) 0.446738, (GLfloat) - 0.363453, (GLfloat) - 0.817512,
+       (GLfloat) 0.441753, (GLfloat) - 0.366614, (GLfloat) - 0.818809,
+       (GLfloat) 0.138045, (GLfloat) - 0.145699, (GLfloat) - 0.979651,
+       (GLfloat) 0.135385, (GLfloat) - 0.146968, (GLfloat) - 0.979832,
+       (GLfloat) 0.154178, (GLfloat) - 0.091800, (GLfloat) - 0.983769,
+       (GLfloat) 0.160344, (GLfloat) - 0.086930, (GLfloat) - 0.983226,
+       (GLfloat) 0.316237, (GLfloat) - 0.497953, (GLfloat) - 0.807488,
+       (GLfloat) 0.343267, (GLfloat) - 0.493329, (GLfloat) - 0.799246,
+       (GLfloat) 0.113533, (GLfloat) - 0.172349, (GLfloat) - 0.978471,
+       (GLfloat) 0.101829, (GLfloat) - 0.173041, (GLfloat) - 0.979636,
+       (GLfloat) 0.123751, (GLfloat) - 0.168767, (GLfloat) - 0.977856,
+       (GLfloat) 0.114456, (GLfloat) - 0.171068, (GLfloat) - 0.978589,
+       (GLfloat) 0.385418, (GLfloat) - 0.444520, (GLfloat) - 0.808613,
+       (GLfloat) 0.397936, (GLfloat) - 0.439743, (GLfloat) - 0.805154,
+       (GLfloat) - 0.398435, (GLfloat) 0.428657, (GLfloat) - 0.810865,
+       (GLfloat) - 0.386943, (GLfloat) 0.429063, (GLfloat) - 0.816198,
+       (GLfloat) - 0.443045, (GLfloat) 0.369548, (GLfloat) - 0.816790,
+       (GLfloat) - 0.444436, (GLfloat) 0.369300, (GLfloat) - 0.816146,
+       (GLfloat) - 0.163680, (GLfloat) 0.101509, (GLfloat) - 0.981277,
+       (GLfloat) - 0.158806, (GLfloat) 0.102320, (GLfloat) - 0.981994,
+       (GLfloat) - 0.135291, (GLfloat) 0.136613, (GLfloat) - 0.981343,
+       (GLfloat) - 0.139056, (GLfloat) 0.136609, (GLfloat) - 0.980817,
+       (GLfloat) - 0.727675, (GLfloat) 0.496263, (GLfloat) - 0.473510,
+       (GLfloat) - 0.726249, (GLfloat) 0.505128, (GLfloat) - 0.466270,
+       (GLfloat) - 0.710606, (GLfloat) 0.534378, (GLfloat) - 0.457688,
+       (GLfloat) - 0.711650, (GLfloat) 0.528248, (GLfloat) - 0.463150,
+       (GLfloat) - 0.787870, (GLfloat) 0.599385, (GLfloat) - 0.141417,
+       (GLfloat) - 0.788753, (GLfloat) 0.597790, (GLfloat) - 0.143234,
+       (GLfloat) - 0.812157, (GLfloat) 0.564556, (GLfloat) - 0.147234,
+       (GLfloat) - 0.810846, (GLfloat) 0.567072, (GLfloat) - 0.144768,
+       (GLfloat) - 0.599894, (GLfloat) 0.659162, (GLfloat) - 0.453468,
+       (GLfloat) - 0.607958, (GLfloat) 0.656733, (GLfloat) - 0.446194,
+       (GLfloat) - 0.673258, (GLfloat) 0.726567, (GLfloat) - 0.137198,
+       (GLfloat) - 0.671022, (GLfloat) 0.728096, (GLfloat) - 0.140020,
+       (GLfloat) - 0.744575, (GLfloat) 0.652826, (GLfloat) - 0.139376,
+       (GLfloat) - 0.744638, (GLfloat) 0.652728, (GLfloat) - 0.139500,
+       (GLfloat) - 0.673012, (GLfloat) 0.585174, (GLfloat) - 0.452357,
+       (GLfloat) - 0.673042, (GLfloat) 0.585047, (GLfloat) - 0.452476,
+       (GLfloat) - 0.599894, (GLfloat) 0.659162, (GLfloat) 0.453468,
+       (GLfloat) - 0.607958, (GLfloat) 0.656733, (GLfloat) 0.446194,
+       (GLfloat) - 0.673012, (GLfloat) 0.585174, (GLfloat) 0.452357,
+       (GLfloat) - 0.673042, (GLfloat) 0.585047, (GLfloat) 0.452476,
+       (GLfloat) - 0.744638, (GLfloat) 0.652728, (GLfloat) 0.139500,
+       (GLfloat) - 0.744575, (GLfloat) 0.652826, (GLfloat) 0.139376,
+       (GLfloat) - 0.671022, (GLfloat) 0.728096, (GLfloat) 0.140020,
+       (GLfloat) - 0.673258, (GLfloat) 0.726567, (GLfloat) 0.137198,
+       (GLfloat) - 0.727676, (GLfloat) 0.496263, (GLfloat) 0.473510,
+       (GLfloat) - 0.726250, (GLfloat) 0.505128, (GLfloat) 0.466269,
+       (GLfloat) - 0.810846, (GLfloat) 0.567072, (GLfloat) 0.144768,
+       (GLfloat) - 0.812157, (GLfloat) 0.564556, (GLfloat) 0.147234,
+       (GLfloat) - 0.787870, (GLfloat) 0.599385, (GLfloat) 0.141417,
+       (GLfloat) - 0.788753, (GLfloat) 0.597789, (GLfloat) 0.143234,
+       (GLfloat) - 0.711650, (GLfloat) 0.528248, (GLfloat) 0.463150,
+       (GLfloat) - 0.710607, (GLfloat) 0.534378, (GLfloat) 0.457688,
+       (GLfloat) - 0.459423, (GLfloat) 0.314205, (GLfloat) 0.830786,
+       (GLfloat) - 0.469134, (GLfloat) 0.308642, (GLfloat) 0.827438,
+       (GLfloat) - 0.469062, (GLfloat) 0.325364, (GLfloat) 0.821048,
+       (GLfloat) - 0.460048, (GLfloat) 0.328491, (GLfloat) 0.824894,
+       (GLfloat) - 0.168365, (GLfloat) 0.083796, (GLfloat) 0.982157,
+       (GLfloat) - 0.160419, (GLfloat) 0.086730, (GLfloat) 0.983231,
+       (GLfloat) - 0.151547, (GLfloat) 0.101367, (GLfloat) 0.983239,
+       (GLfloat) - 0.156023, (GLfloat) 0.098476, (GLfloat) 0.982832,
+       (GLfloat) - 0.386943, (GLfloat) 0.429064, (GLfloat) 0.816198,
+       (GLfloat) - 0.398435, (GLfloat) 0.428657, (GLfloat) 0.810865,
+       (GLfloat) - 0.135291, (GLfloat) 0.136613, (GLfloat) 0.981343,
+       (GLfloat) - 0.139055, (GLfloat) 0.136609, (GLfloat) 0.980817,
+       (GLfloat) - 0.158806, (GLfloat) 0.102320, (GLfloat) 0.981994,
+       (GLfloat) - 0.163680, (GLfloat) 0.101509, (GLfloat) 0.981277,
+       (GLfloat) - 0.443045, (GLfloat) 0.369548, (GLfloat) 0.816790,
+       (GLfloat) - 0.444437, (GLfloat) 0.369300, (GLfloat) 0.816145,
+       (GLfloat) 0.316237, (GLfloat) - 0.497952, (GLfloat) 0.807488,
+       (GLfloat) 0.343268, (GLfloat) - 0.493329, (GLfloat) 0.799246,
+       (GLfloat) 0.397936, (GLfloat) - 0.439744, (GLfloat) 0.805154,
+       (GLfloat) 0.385418, (GLfloat) - 0.444521, (GLfloat) 0.808613,
+       (GLfloat) 0.123751, (GLfloat) - 0.168768, (GLfloat) 0.977856,
+       (GLfloat) 0.114455, (GLfloat) - 0.171068, (GLfloat) 0.978589,
+       (GLfloat) 0.101830, (GLfloat) - 0.173040, (GLfloat) 0.979637,
+       (GLfloat) 0.113533, (GLfloat) - 0.172348, (GLfloat) 0.978471,
+       (GLfloat) 0.477126, (GLfloat) - 0.265003, (GLfloat) 0.837929,
+       (GLfloat) 0.495553, (GLfloat) - 0.246921, (GLfloat) 0.832741,
+       (GLfloat) 0.154178, (GLfloat) - 0.091800, (GLfloat) 0.983769,
+       (GLfloat) 0.160344, (GLfloat) - 0.086930, (GLfloat) 0.983226,
+       (GLfloat) 0.135385, (GLfloat) - 0.146968, (GLfloat) 0.979832,
+       (GLfloat) 0.138045, (GLfloat) - 0.145699, (GLfloat) 0.979651,
+       (GLfloat) 0.446739, (GLfloat) - 0.363453, (GLfloat) 0.817512,
+       (GLfloat) 0.441753, (GLfloat) - 0.366614, (GLfloat) 0.818809,
+       (GLfloat) 0.786198, (GLfloat) - 0.394047, (GLfloat) 0.476047,
+       (GLfloat) 0.792547, (GLfloat) - 0.363224, (GLfloat) 0.489834,
+       (GLfloat) 0.707476, (GLfloat) - 0.538845, (GLfloat) 0.457301,
+       (GLfloat) 0.711142, (GLfloat) - 0.529032, (GLfloat) 0.463037,
+       (GLfloat) 0.801588, (GLfloat) - 0.580242, (GLfloat) 0.144141,
+       (GLfloat) 0.799043, (GLfloat) - 0.584300, (GLfloat) 0.141857,
+       (GLfloat) 0.903357, (GLfloat) - 0.400085, (GLfloat) 0.154524,
+       (GLfloat) 0.898654, (GLfloat) - 0.412515, (GLfloat) 0.149172,
+       (GLfloat) 0.471890, (GLfloat) - 0.763546, (GLfloat) 0.440814,
+       (GLfloat) 0.497278, (GLfloat) - 0.754424, (GLfloat) 0.428437,
+       (GLfloat) 0.515315, (GLfloat) - 0.846316, (GLfloat) 0.134909,
+       (GLfloat) 0.524719, (GLfloat) - 0.841405, (GLfloat) 0.129258,
+       (GLfloat) 0.671646, (GLfloat) - 0.728471, (GLfloat) 0.134984,
+       (GLfloat) 0.668271, (GLfloat) - 0.731195, (GLfloat) 0.136994,
+       (GLfloat) 0.610971, (GLfloat) - 0.657561, (GLfloat) 0.440826,
+       (GLfloat) 0.601302, (GLfloat) - 0.663396, (GLfloat) 0.445356,
+       (GLfloat) 0.497278, (GLfloat) - 0.754424, (GLfloat) - 0.428437,
+       (GLfloat) 0.471890, (GLfloat) - 0.763546, (GLfloat) - 0.440814,
+       (GLfloat) 0.610971, (GLfloat) - 0.657561, (GLfloat) - 0.440826,
+       (GLfloat) 0.601301, (GLfloat) - 0.663396, (GLfloat) - 0.445356,
+       (GLfloat) 0.668271, (GLfloat) - 0.731195, (GLfloat) - 0.136994,
+       (GLfloat) 0.671646, (GLfloat) - 0.728471, (GLfloat) - 0.134984,
+       (GLfloat) 0.515315, (GLfloat) - 0.846316, (GLfloat) - 0.134909,
+       (GLfloat) 0.524719, (GLfloat) - 0.841405, (GLfloat) - 0.129258,
+       (GLfloat) 0.792547, (GLfloat) - 0.363225, (GLfloat) - 0.489834,
+       (GLfloat) 0.786198, (GLfloat) - 0.394046, (GLfloat) - 0.476047,
+       (GLfloat) 0.903357, (GLfloat) - 0.400085, (GLfloat) - 0.154524,
+       (GLfloat) 0.898654, (GLfloat) - 0.412515, (GLfloat) - 0.149172,
+       (GLfloat) 0.799043, (GLfloat) - 0.584299, (GLfloat) - 0.141858,
+       (GLfloat) 0.801588, (GLfloat) - 0.580242, (GLfloat) - 0.144141,
+       (GLfloat) 0.707476, (GLfloat) - 0.538845, (GLfloat) - 0.457301,
+       (GLfloat) 0.711142, (GLfloat) - 0.529031, (GLfloat) - 0.463037,
+       (GLfloat) 0.844921, (GLfloat) - 0.202233, (GLfloat) 0.495188,
+       (GLfloat) 0.846624, (GLfloat) - 0.162790, (GLfloat) 0.506682,
+       (GLfloat) 0.967461, (GLfloat) - 0.195075, (GLfloat) 0.161136,
+       (GLfloat) 0.965076, (GLfloat) - 0.210256, (GLfloat) 0.156272,
+       (GLfloat) 0.933716, (GLfloat) - 0.317920, (GLfloat) 0.164623,
+       (GLfloat) 0.928870, (GLfloat) - 0.334244, (GLfloat) 0.159632,
+       (GLfloat) 0.801028, (GLfloat) - 0.328506, (GLfloat) 0.500438,
+       (GLfloat) 0.805814, (GLfloat) - 0.302226, (GLfloat) 0.509238,
+       (GLfloat) 0.844921, (GLfloat) - 0.202233, (GLfloat) - 0.495188,
+       (GLfloat) 0.846624, (GLfloat) - 0.162790, (GLfloat) - 0.506682,
+       (GLfloat) 0.805814, (GLfloat) - 0.302226, (GLfloat) - 0.509238,
+       (GLfloat) 0.801028, (GLfloat) - 0.328507, (GLfloat) - 0.500438,
+       (GLfloat) 0.933716, (GLfloat) - 0.317920, (GLfloat) - 0.164623,
+       (GLfloat) 0.928870, (GLfloat) - 0.334244, (GLfloat) - 0.159632,
+       (GLfloat) 0.965076, (GLfloat) - 0.210256, (GLfloat) - 0.156272,
+       (GLfloat) 0.967461, (GLfloat) - 0.195075, (GLfloat) - 0.161136,
+       (GLfloat) 0.116677, (GLfloat) - 0.971600, (GLfloat) - 0.205866,
+       (GLfloat) 0.095439, (GLfloat) - 0.979375, (GLfloat) - 0.178092,
+       (GLfloat) 0.145951, (GLfloat) - 0.986885, (GLfloat) - 0.068965,
+       (GLfloat) 0.134470, (GLfloat) - 0.988213, (GLfloat) - 0.073162,
+       (GLfloat) 0.572548, (GLfloat) - 0.810794, (GLfloat) - 0.121664,
+       (GLfloat) 0.603894, (GLfloat) - 0.784891, (GLfloat) - 0.138773,
+       (GLfloat) 0.437036, (GLfloat) - 0.822210, (GLfloat) - 0.364650,
+       (GLfloat) 0.472429, (GLfloat) - 0.800503, (GLfloat) - 0.368789,
+       (GLfloat) 0.095438, (GLfloat) - 0.979375, (GLfloat) 0.178092,
+       (GLfloat) 0.116677, (GLfloat) - 0.971600, (GLfloat) 0.205866,
+       (GLfloat) 0.472430, (GLfloat) - 0.800503, (GLfloat) 0.368789,
+       (GLfloat) 0.437036, (GLfloat) - 0.822210, (GLfloat) 0.364650,
+       (GLfloat) 0.603894, (GLfloat) - 0.784891, (GLfloat) 0.138773,
+       (GLfloat) 0.572548, (GLfloat) - 0.810794, (GLfloat) 0.121664,
+       (GLfloat) 0.134470, (GLfloat) - 0.988213, (GLfloat) 0.073162,
+       (GLfloat) 0.145951, (GLfloat) - 0.986885, (GLfloat) 0.068965,
+       (GLfloat) 0.531733, (GLfloat) - 0.073239, (GLfloat) - 0.843739,
+       (GLfloat) 0.511681, (GLfloat) - 0.104754, (GLfloat) - 0.852766,
+       (GLfloat) 0.176179, (GLfloat) 0.024438, (GLfloat) - 0.984055,
+       (GLfloat) 0.188717, (GLfloat) 0.040307, (GLfloat) - 0.981204,
+       (GLfloat) 0.150895, (GLfloat) - 0.104293, (GLfloat) - 0.983033,
+       (GLfloat) 0.147932, (GLfloat) - 0.109363, (GLfloat) - 0.982932,
+       (GLfloat) 0.481880, (GLfloat) - 0.227373, (GLfloat) - 0.846223,
+       (GLfloat) 0.480166, (GLfloat) - 0.230321, (GLfloat) - 0.846400,
+       (GLfloat) - 0.443443, (GLfloat) 0.349023, (GLfloat) - 0.825555,
+       (GLfloat) - 0.447255, (GLfloat) 0.345654, (GLfloat) - 0.824916,
+       (GLfloat) - 0.494732, (GLfloat) 0.167751, (GLfloat) - 0.852701,
+       (GLfloat) - 0.499143, (GLfloat) 0.160727, (GLfloat) - 0.851483,
+       (GLfloat) - 0.167121, (GLfloat) 0.020158, (GLfloat) - 0.985730,
+       (GLfloat) - 0.166487, (GLfloat) 0.021208, (GLfloat) - 0.985815,
+       (GLfloat) - 0.129817, (GLfloat) 0.178023, (GLfloat) - 0.975426,
+       (GLfloat) - 0.132948, (GLfloat) 0.174752, (GLfloat) - 0.975595,
+       (GLfloat) - 0.353563, (GLfloat) - 0.901143, (GLfloat) - 0.250869,
+       (GLfloat) - 0.351628, (GLfloat) - 0.891347, (GLfloat) - 0.286110,
+       (GLfloat) - 0.232284, (GLfloat) - 0.920192, (GLfloat) - 0.315104,
+       (GLfloat) - 0.236990, (GLfloat) - 0.922714, (GLfloat) - 0.304029,
+       (GLfloat) - 0.244093, (GLfloat) - 0.592931, (GLfloat) - 0.767366,
+       (GLfloat) - 0.249996, (GLfloat) - 0.572960, (GLfloat) - 0.780525,
+       (GLfloat) - 0.510472, (GLfloat) - 0.553764, (GLfloat) - 0.657848,
+       (GLfloat) - 0.520671, (GLfloat) - 0.533495, (GLfloat) - 0.666547,
+       (GLfloat) 0.010781, (GLfloat) - 0.964447, (GLfloat) - 0.264055,
+       (GLfloat) 0.040104, (GLfloat) - 0.958098, (GLfloat) - 0.283621,
+       (GLfloat) 0.223629, (GLfloat) - 0.775786, (GLfloat) - 0.590040,
+       (GLfloat) 0.262682, (GLfloat) - 0.745474, (GLfloat) - 0.612590,
+       (GLfloat) 0.033849, (GLfloat) - 0.640593, (GLfloat) - 0.767134,
+       (GLfloat) 0.004138, (GLfloat) - 0.677809, (GLfloat) - 0.735226,
+       (GLfloat) - 0.092889, (GLfloat) - 0.948124, (GLfloat) - 0.304029,
+       (GLfloat) - 0.096449, (GLfloat) - 0.944143, (GLfloat) - 0.315104,
+       (GLfloat) - 0.719211, (GLfloat) 0.510808, (GLfloat) - 0.470968,
+       (GLfloat) - 0.720697, (GLfloat) 0.504519, (GLfloat) - 0.475454,
+       (GLfloat) - 0.811897, (GLfloat) 0.564936, (GLfloat) - 0.147209,
+       (GLfloat) - 0.813044, (GLfloat) 0.562871, (GLfloat) - 0.148783,
+       (GLfloat) - 0.910433, (GLfloat) 0.380820, (GLfloat) - 0.161519,
+       (GLfloat) - 0.907768, (GLfloat) 0.388545, (GLfloat) - 0.158079,
+       (GLfloat) - 0.804000, (GLfloat) 0.309508, (GLfloat) - 0.507729,
+       (GLfloat) - 0.801647, (GLfloat) 0.326768, (GLfloat) - 0.500584,
+       (GLfloat) - 0.720697, (GLfloat) 0.504519, (GLfloat) 0.475454,
+       (GLfloat) - 0.719210, (GLfloat) 0.510808, (GLfloat) 0.470968,
+       (GLfloat) - 0.804000, (GLfloat) 0.309509, (GLfloat) 0.507729,
+       (GLfloat) - 0.801647, (GLfloat) 0.326768, (GLfloat) 0.500585,
+       (GLfloat) - 0.907768, (GLfloat) 0.388545, (GLfloat) 0.158079,
+       (GLfloat) - 0.910433, (GLfloat) 0.380820, (GLfloat) 0.161519,
+       (GLfloat) - 0.811897, (GLfloat) 0.564936, (GLfloat) 0.147209,
+       (GLfloat) - 0.813044, (GLfloat) 0.562871, (GLfloat) 0.148783,
+       (GLfloat) - 0.441947, (GLfloat) - 0.873099, (GLfloat) 0.205867,
+       (GLfloat) - 0.424648, (GLfloat) - 0.887670, (GLfloat) 0.178091,
+       (GLfloat) - 0.474684, (GLfloat) - 0.877450, (GLfloat) 0.068965,
+       (GLfloat) - 0.464350, (GLfloat) - 0.882625, (GLfloat) 0.073162,
+       (GLfloat) - 0.909934, (GLfloat) - 0.390292, (GLfloat) 0.140328,
+       (GLfloat) - 0.923715, (GLfloat) - 0.349249, (GLfloat) 0.157405,
+       (GLfloat) - 0.775101, (GLfloat) - 0.483039, (GLfloat) 0.407299,
+       (GLfloat) - 0.785487, (GLfloat) - 0.436754, (GLfloat) 0.438470,
+       (GLfloat) - 0.424649, (GLfloat) - 0.887669, (GLfloat) - 0.178092,
+       (GLfloat) - 0.441947, (GLfloat) - 0.873099, (GLfloat) - 0.205866,
+       (GLfloat) - 0.775100, (GLfloat) - 0.483039, (GLfloat) - 0.407299,
+       (GLfloat) - 0.785487, (GLfloat) - 0.436754, (GLfloat) - 0.438470,
+       (GLfloat) - 0.923715, (GLfloat) - 0.349249, (GLfloat) - 0.157405,
+       (GLfloat) - 0.909934, (GLfloat) - 0.390292, (GLfloat) - 0.140328,
+       (GLfloat) - 0.464350, (GLfloat) - 0.882625, (GLfloat) - 0.073162,
+       (GLfloat) - 0.474684, (GLfloat) - 0.877450, (GLfloat) - 0.068965,
+       (GLfloat) - 0.447255, (GLfloat) 0.345654, (GLfloat) 0.824916,
+       (GLfloat) - 0.443443, (GLfloat) 0.349023, (GLfloat) 0.825555,
+       (GLfloat) - 0.129817, (GLfloat) 0.178023, (GLfloat) 0.975426,
+       (GLfloat) - 0.132949, (GLfloat) 0.174752, (GLfloat) 0.975595,
+       (GLfloat) - 0.166487, (GLfloat) 0.021208, (GLfloat) 0.985815,
+       (GLfloat) - 0.167121, (GLfloat) 0.020158, (GLfloat) 0.985730,
+       (GLfloat) - 0.494732, (GLfloat) 0.167753, (GLfloat) 0.852701,
+       (GLfloat) - 0.499144, (GLfloat) 0.160728, (GLfloat) 0.851482,
+       (GLfloat) 0.531733, (GLfloat) - 0.073239, (GLfloat) 0.843739,
+       (GLfloat) 0.511681, (GLfloat) - 0.104754, (GLfloat) 0.852765,
+       (GLfloat) 0.480166, (GLfloat) - 0.230321, (GLfloat) 0.846400,
+       (GLfloat) 0.481881, (GLfloat) - 0.227371, (GLfloat) 0.846223,
+       (GLfloat) 0.150895, (GLfloat) - 0.104294, (GLfloat) 0.983033,
+       (GLfloat) 0.147933, (GLfloat) - 0.109363, (GLfloat) 0.982932,
+       (GLfloat) 0.188717, (GLfloat) 0.040307, (GLfloat) 0.981204,
+       (GLfloat) 0.176179, (GLfloat) 0.024438, (GLfloat) 0.984055,
+       (GLfloat) 0.040104, (GLfloat) - 0.958098, (GLfloat) 0.283620,
+       (GLfloat) 0.010781, (GLfloat) - 0.964447, (GLfloat) 0.264055,
+       (GLfloat) - 0.096449, (GLfloat) - 0.944143, (GLfloat) 0.315104,
+       (GLfloat) - 0.092889, (GLfloat) - 0.948124, (GLfloat) 0.304029,
+       (GLfloat) 0.004138, (GLfloat) - 0.677808, (GLfloat) 0.735227,
+       (GLfloat) 0.033849, (GLfloat) - 0.640593, (GLfloat) 0.767135,
+       (GLfloat) 0.223629, (GLfloat) - 0.775785, (GLfloat) 0.590040,
+       (GLfloat) 0.262682, (GLfloat) - 0.745474, (GLfloat) 0.612591,
+       (GLfloat) - 0.353563, (GLfloat) - 0.901143, (GLfloat) 0.250868,
+       (GLfloat) - 0.351627, (GLfloat) - 0.891347, (GLfloat) 0.286109,
+       (GLfloat) - 0.510472, (GLfloat) - 0.553764, (GLfloat) 0.657848,
+       (GLfloat) - 0.520671, (GLfloat) - 0.533495, (GLfloat) 0.666547,
+       (GLfloat) - 0.249996, (GLfloat) - 0.572959, (GLfloat) 0.780525,
+       (GLfloat) - 0.244093, (GLfloat) - 0.592931, (GLfloat) 0.767367,
+       (GLfloat) - 0.236991, (GLfloat) - 0.922714, (GLfloat) 0.304029,
+       (GLfloat) - 0.232284, (GLfloat) - 0.920192, (GLfloat) 0.315104,
+       (GLfloat) - 0.036947, (GLfloat) - 0.991593, (GLfloat) - 0.124011,
+       (GLfloat) - 0.048560, (GLfloat) - 0.989545, (GLfloat) - 0.135802,
+       (GLfloat) - 0.129266, (GLfloat) - 0.985532, (GLfloat) - 0.109621,
+       (GLfloat) - 0.133311, (GLfloat) - 0.984414, (GLfloat) - 0.114709,
+       (GLfloat) - 0.143769, (GLfloat) - 0.989058, (GLfloat) - 0.033079,
+       (GLfloat) - 0.140897, (GLfloat) - 0.989565, (GLfloat) - 0.030163,
+       (GLfloat) - 0.064478, (GLfloat) - 0.996956, (GLfloat) - 0.043834,
+       (GLfloat) - 0.059398, (GLfloat) - 0.997446, (GLfloat) - 0.039656,
+       (GLfloat) - 0.292813, (GLfloat) - 0.946477, (GLfloat) - 0.135802,
+       (GLfloat) - 0.304426, (GLfloat) - 0.944429, (GLfloat) - 0.124011,
+       (GLfloat) - 0.280390, (GLfloat) - 0.958885, (GLfloat) - 0.043834,
+       (GLfloat) - 0.285331, (GLfloat) - 0.957608, (GLfloat) - 0.039656,
+       (GLfloat) - 0.206051, (GLfloat) - 0.978076, (GLfloat) - 0.030163,
+       (GLfloat) - 0.203179, (GLfloat) - 0.978583, (GLfloat) - 0.033079,
+       (GLfloat) - 0.215602, (GLfloat) - 0.970309, (GLfloat) - 0.109621,
+       (GLfloat) - 0.211418, (GLfloat) - 0.970641, (GLfloat) - 0.114709,
+       (GLfloat) - 0.304426, (GLfloat) - 0.944429, (GLfloat) 0.124011,
+       (GLfloat) - 0.292813, (GLfloat) - 0.946477, (GLfloat) 0.135803,
+       (GLfloat) - 0.215602, (GLfloat) - 0.970309, (GLfloat) 0.109621,
+       (GLfloat) - 0.211418, (GLfloat) - 0.970641, (GLfloat) 0.114709,
+       (GLfloat) - 0.203179, (GLfloat) - 0.978583, (GLfloat) 0.033079,
+       (GLfloat) - 0.206051, (GLfloat) - 0.978076, (GLfloat) 0.030163,
+       (GLfloat) - 0.280390, (GLfloat) - 0.958885, (GLfloat) 0.043834,
+       (GLfloat) - 0.285331, (GLfloat) - 0.957608, (GLfloat) 0.039656,
+       (GLfloat) - 0.048560, (GLfloat) - 0.989545, (GLfloat) 0.135802,
+       (GLfloat) - 0.036947, (GLfloat) - 0.991593, (GLfloat) 0.124011,
+       (GLfloat) - 0.064478, (GLfloat) - 0.996956, (GLfloat) 0.043834,
+       (GLfloat) - 0.059398, (GLfloat) - 0.997446, (GLfloat) 0.039656,
+       (GLfloat) - 0.140897, (GLfloat) - 0.989565, (GLfloat) 0.030163,
+       (GLfloat) - 0.143769, (GLfloat) - 0.989058, (GLfloat) 0.033079,
+       (GLfloat) - 0.129266, (GLfloat) - 0.985532, (GLfloat) 0.109621,
+       (GLfloat) - 0.133311, (GLfloat) - 0.984414, (GLfloat) 0.114709,
+};
+
+static unsigned short int s1_3_POLS[] =
+{
+      3, 82, 12, 76, 1, 3, 76, 74, 82, 1, 3, 22, 78, 74, 1, 3, 22, 74, 76, 1,
+      3, 78, 20, 80, 1, 3, 80, 74, 78, 1, 3, 28, 82, 74, 1, 3, 28, 74, 80, 1,
+      3, 88, 13, 84, 1, 3, 84, 77, 88, 1, 3, 24, 86, 77, 1, 3, 24, 77, 84, 1,
+      3, 86, 20, 78, 1, 3, 78, 77, 86, 1, 3, 22, 88, 77, 1, 3, 22, 77, 78, 1,
+      3, 14, 90, 85, 1, 3, 14, 85, 93, 1, 3, 26, 91, 85, 1, 3, 26, 85, 90, 1,
+      3, 20, 86, 85, 1, 3, 20, 85, 91, 1, 3, 24, 93, 85, 1, 3, 24, 85, 86, 1,
+      3, 15, 95, 79, 1, 3, 15, 79, 97, 1, 3, 28, 80, 79, 1, 3, 28, 79, 95, 1,
+      3, 20, 91, 79, 1, 3, 20, 79, 80, 1, 3, 26, 97, 79, 1, 3, 26, 79, 91, 1,
+    3, 13, 99, 83, 1, 3, 13, 83, 84, 1, 3, 99, 30, 101, 1, 3, 101, 83, 99, 1,
+  3, 23, 102, 83, 1, 3, 23, 83, 101, 1, 3, 102, 24, 84, 1, 3, 84, 83, 102, 1,
+       3, 108, 16, 104, 1, 3, 104, 100, 108, 1, 3, 32, 106, 100, 1, 3, 32, 100, 104, 1,
+       3, 106, 23, 101, 1, 3, 101, 100, 106, 1, 3, 30, 108, 100, 1, 3, 30, 100, 101, 1,
+       3, 113, 17, 110, 1, 3, 110, 105, 113, 1, 3, 33, 111, 105, 1, 3, 33, 105, 110, 1,
+       3, 23, 106, 105, 1, 3, 23, 105, 111, 1, 3, 106, 32, 113, 1, 3, 113, 105, 106, 1,
+   3, 14, 93, 92, 1, 3, 14, 92, 114, 1, 3, 93, 24, 102, 1, 3, 102, 92, 93, 1,
+3, 23, 111, 92, 1, 3, 23, 92, 102, 1, 3, 111, 33, 114, 1, 3, 114, 92, 111, 1,
+       3, 16, 116, 103, 1, 3, 16, 103, 104, 1, 3, 116, 35, 118, 1, 3, 118, 103, 116, 1,
+       3, 31, 119, 103, 1, 3, 31, 103, 118, 1, 3, 119, 32, 104, 1, 3, 104, 103, 119, 1,
+       3, 18, 121, 117, 1, 3, 18, 117, 125, 1, 3, 121, 36, 123, 1, 3, 123, 117, 121, 1,
+       3, 31, 118, 117, 1, 3, 31, 117, 123, 1, 3, 118, 35, 125, 1, 3, 125, 117, 118, 1,
+       3, 19, 127, 122, 1, 3, 19, 122, 130, 1, 3, 127, 37, 128, 1, 3, 128, 122, 127, 1,
+       3, 31, 123, 122, 1, 3, 31, 122, 128, 1, 3, 123, 36, 130, 1, 3, 130, 122, 123, 1,
+       3, 17, 113, 112, 1, 3, 17, 112, 131, 1, 3, 113, 32, 119, 1, 3, 119, 112, 113, 1,
+       3, 31, 128, 112, 1, 3, 31, 112, 119, 1, 3, 128, 37, 131, 1, 3, 131, 112, 128, 1,
+       3, 121, 18, 133, 1, 3, 133, 120, 121, 1, 3, 39, 134, 120, 1, 3, 39, 120, 133, 1,
+       3, 134, 27, 135, 1, 3, 135, 120, 134, 1, 3, 36, 121, 120, 1, 3, 36, 120, 135, 1,
+   3, 12, 82, 81, 1, 3, 12, 81, 138, 1, 3, 82, 28, 136, 1, 3, 136, 81, 82, 1,
+3, 27, 134, 81, 1, 3, 27, 81, 136, 1, 3, 134, 39, 138, 1, 3, 138, 81, 134, 1,
+ 3, 15, 139, 94, 1, 3, 15, 94, 95, 1, 3, 139, 40, 140, 1, 3, 140, 94, 139, 1,
+  3, 27, 136, 94, 1, 3, 27, 94, 140, 1, 3, 136, 28, 95, 1, 3, 95, 94, 136, 1,
+       3, 141, 19, 130, 1, 3, 130, 129, 141, 1, 3, 130, 36, 135, 1, 3, 135, 129, 130, 1,
+       3, 27, 140, 129, 1, 3, 27, 129, 135, 1, 3, 40, 141, 129, 1, 3, 40, 129, 140, 1,
+ 3, 14, 114, 89, 1, 3, 14, 89, 90, 1, 3, 114, 33, 142, 1, 3, 142, 89, 114, 1,
+  3, 25, 143, 89, 1, 3, 25, 89, 142, 1, 3, 143, 26, 90, 1, 3, 90, 89, 143, 1,
+       3, 17, 131, 109, 1, 3, 17, 109, 110, 1, 3, 131, 37, 144, 1, 3, 144, 109, 131, 1,
+       3, 25, 142, 109, 1, 3, 25, 109, 144, 1, 3, 142, 33, 110, 1, 3, 110, 109, 142, 1,
+       3, 19, 141, 126, 1, 3, 19, 126, 127, 1, 3, 141, 40, 145, 1, 3, 145, 126, 141, 1,
+       3, 25, 144, 126, 1, 3, 25, 126, 145, 1, 3, 144, 37, 127, 1, 3, 127, 126, 144, 1,
+   3, 15, 97, 96, 1, 3, 15, 96, 139, 1, 3, 97, 26, 143, 1, 3, 143, 96, 97, 1,
+3, 25, 145, 96, 1, 3, 25, 96, 143, 1, 3, 145, 40, 139, 1, 3, 139, 96, 145, 1,
+ 3, 12, 146, 75, 1, 3, 12, 75, 76, 1, 3, 146, 41, 148, 1, 3, 148, 75, 146, 1,
+  3, 21, 149, 75, 1, 3, 21, 75, 148, 1, 3, 149, 22, 76, 1, 3, 76, 75, 149, 1,
+       3, 155, 8, 151, 1, 3, 151, 147, 155, 1, 3, 43, 153, 147, 1, 3, 43, 147, 151, 1,
+       3, 153, 21, 148, 1, 3, 148, 147, 153, 1, 3, 41, 155, 147, 1, 3, 41, 147, 148, 1,
+       3, 160, 11, 157, 1, 3, 157, 152, 160, 1, 3, 44, 158, 152, 1, 3, 44, 152, 157, 1,
+       3, 158, 21, 153, 1, 3, 153, 152, 158, 1, 3, 43, 160, 152, 1, 3, 43, 152, 153, 1,
+   3, 13, 88, 87, 1, 3, 13, 87, 161, 1, 3, 88, 22, 149, 1, 3, 149, 87, 88, 1,
+3, 21, 158, 87, 1, 3, 21, 87, 149, 1, 3, 158, 44, 161, 1, 3, 161, 87, 158, 1,
+       3, 18, 162, 132, 1, 3, 18, 132, 133, 1, 3, 162, 45, 164, 1, 3, 164, 132, 162, 1,
+       3, 38, 165, 132, 1, 3, 38, 132, 164, 1, 3, 165, 39, 133, 1, 3, 133, 132, 165, 1,
+       3, 170, 9, 167, 1, 3, 167, 163, 170, 1, 3, 47, 168, 163, 1, 3, 47, 163, 167, 1,
+       3, 168, 38, 164, 1, 3, 164, 163, 168, 1, 3, 45, 170, 163, 1, 3, 45, 163, 164, 1,
+3, 8, 155, 154, 1, 3, 8, 154, 173, 1, 3, 155, 41, 171, 1, 3, 171, 154, 155, 1,
+       3, 38, 168, 154, 1, 3, 38, 154, 171, 1, 3, 168, 47, 173, 1, 3, 173, 154, 168, 1,
+       3, 146, 12, 138, 1, 3, 138, 137, 146, 1, 3, 39, 165, 137, 1, 3, 39, 137, 138, 1,
+       3, 165, 38, 171, 1, 3, 171, 137, 165, 1, 3, 41, 146, 137, 1, 3, 41, 137, 171, 1,
+       3, 16, 108, 107, 1, 3, 16, 107, 177, 1, 3, 108, 30, 174, 1, 3, 174, 107, 108, 1,
+       3, 29, 176, 107, 1, 3, 29, 107, 174, 1, 3, 176, 50, 177, 1, 3, 177, 107, 176, 1,
+  3, 99, 13, 161, 1, 3, 161, 98, 99, 1, 3, 44, 178, 98, 1, 3, 44, 98, 161, 1,
+ 3, 178, 29, 174, 1, 3, 174, 98, 178, 1, 3, 30, 99, 98, 1, 3, 30, 98, 174, 1,
+       3, 11, 180, 156, 1, 3, 11, 156, 157, 1, 3, 180, 49, 181, 1, 3, 181, 156, 180, 1,
+       3, 29, 178, 156, 1, 3, 29, 156, 181, 1, 3, 178, 44, 157, 1, 3, 157, 156, 178, 1,
+       3, 185, 10, 183, 1, 3, 183, 175, 185, 1, 3, 50, 176, 175, 1, 3, 50, 175, 183, 1,
+       3, 176, 29, 181, 1, 3, 181, 175, 176, 1, 3, 49, 185, 175, 1, 3, 49, 175, 181, 1,
+       3, 162, 18, 125, 1, 3, 125, 124, 162, 1, 3, 35, 186, 124, 1, 3, 35, 124, 125, 1,
+       3, 186, 34, 187, 1, 3, 187, 124, 186, 1, 3, 45, 162, 124, 1, 3, 45, 124, 187, 1,
+       3, 116, 16, 177, 1, 3, 177, 115, 116, 1, 3, 50, 188, 115, 1, 3, 50, 115, 177, 1,
+       3, 188, 34, 186, 1, 3, 186, 115, 188, 1, 3, 35, 116, 115, 1, 3, 35, 115, 186, 1,
+       3, 10, 190, 182, 1, 3, 10, 182, 183, 1, 3, 190, 52, 191, 1, 3, 191, 182, 190, 1,
+       3, 34, 188, 182, 1, 3, 34, 182, 191, 1, 3, 188, 50, 183, 1, 3, 183, 182, 188, 1,
+3, 9, 170, 169, 1, 3, 9, 169, 193, 1, 3, 170, 45, 187, 1, 3, 187, 169, 170, 1,
+       3, 34, 191, 169, 1, 3, 34, 169, 187, 1, 3, 191, 52, 193, 1, 3, 193, 169, 191, 1,
+       3, 201, 1, 196, 1, 3, 196, 194, 201, 1, 3, 54, 198, 194, 1, 3, 54, 194, 196, 1,
+       3, 198, 46, 199, 1, 3, 199, 194, 198, 1, 3, 56, 201, 194, 1, 3, 56, 194, 199, 1,
+3, 3, 203, 197, 1, 3, 3, 197, 206, 1, 3, 203, 55, 204, 1, 3, 204, 197, 203, 1,
+       3, 46, 198, 197, 1, 3, 46, 197, 204, 1, 3, 198, 54, 206, 1, 3, 206, 197, 198, 1,
+       3, 208, 8, 173, 1, 3, 173, 172, 208, 1, 3, 47, 207, 172, 1, 3, 47, 172, 173, 1,
+       3, 207, 46, 204, 1, 3, 204, 172, 207, 1, 3, 55, 208, 172, 1, 3, 55, 172, 204, 1,
+3, 9, 209, 166, 1, 3, 9, 166, 167, 1, 3, 209, 56, 199, 1, 3, 199, 166, 209, 1,
+       3, 46, 207, 166, 1, 3, 46, 166, 199, 1, 3, 207, 47, 167, 1, 3, 167, 166, 207, 1,
+       3, 214, 1, 201, 1, 3, 201, 200, 214, 1, 3, 56, 210, 200, 1, 3, 56, 200, 201, 1,
+       3, 210, 51, 212, 1, 3, 212, 200, 210, 1, 3, 59, 214, 200, 1, 3, 59, 200, 212, 1,
+       3, 209, 9, 193, 1, 3, 193, 192, 209, 1, 3, 52, 215, 192, 1, 3, 52, 192, 193, 1,
+       3, 51, 210, 192, 1, 3, 51, 192, 215, 1, 3, 210, 56, 209, 1, 3, 209, 192, 210, 1,
+       3, 190, 10, 216, 1, 3, 216, 189, 190, 1, 3, 216, 57, 217, 1, 3, 217, 189, 216, 1,
+       3, 51, 215, 189, 1, 3, 51, 189, 217, 1, 3, 52, 190, 189, 1, 3, 52, 189, 215, 1,
+       3, 221, 0, 219, 1, 3, 219, 211, 221, 1, 3, 59, 212, 211, 1, 3, 59, 211, 219, 1,
+       3, 212, 51, 217, 1, 3, 217, 211, 212, 1, 3, 57, 221, 211, 1, 3, 57, 211, 217, 1,
+       3, 226, 0, 221, 1, 3, 221, 220, 226, 1, 3, 57, 222, 220, 1, 3, 57, 220, 221, 1,
+       3, 222, 48, 224, 1, 3, 224, 220, 222, 1, 3, 62, 226, 220, 1, 3, 62, 220, 224, 1,
+       3, 10, 185, 184, 1, 3, 10, 184, 216, 1, 3, 185, 49, 227, 1, 3, 227, 184, 185, 1,
+       3, 48, 222, 184, 1, 3, 48, 184, 227, 1, 3, 222, 57, 216, 1, 3, 216, 184, 222, 1,
+       3, 180, 11, 228, 1, 3, 228, 179, 180, 1, 3, 60, 229, 179, 1, 3, 60, 179, 228, 1,
+       3, 229, 48, 227, 1, 3, 227, 179, 229, 1, 3, 49, 180, 179, 1, 3, 49, 179, 227, 1,
+3, 2, 231, 223, 1, 3, 2, 223, 233, 1, 3, 231, 62, 224, 1, 3, 224, 223, 231, 1,
+       3, 48, 229, 223, 1, 3, 48, 223, 224, 1, 3, 229, 60, 233, 1, 3, 233, 223, 229, 1,
+3, 2, 233, 232, 1, 3, 2, 232, 237, 1, 3, 233, 60, 234, 1, 3, 234, 232, 233, 1,
+       3, 42, 235, 232, 1, 3, 42, 232, 234, 1, 3, 235, 64, 237, 1, 3, 237, 232, 235, 1,
+       3, 11, 160, 159, 1, 3, 11, 159, 228, 1, 3, 160, 43, 238, 1, 3, 238, 159, 160, 1,
+       3, 42, 234, 159, 1, 3, 42, 159, 238, 1, 3, 234, 60, 228, 1, 3, 228, 159, 234, 1,
+3, 8, 208, 150, 1, 3, 8, 150, 151, 1, 3, 208, 55, 239, 1, 3, 239, 150, 208, 1,
+       3, 42, 238, 150, 1, 3, 42, 150, 239, 1, 3, 238, 43, 151, 1, 3, 151, 150, 238, 1,
+3, 3, 241, 202, 1, 3, 3, 202, 203, 1, 3, 241, 64, 235, 1, 3, 235, 202, 241, 1,
+       3, 42, 239, 202, 1, 3, 42, 202, 235, 1, 3, 239, 55, 203, 1, 3, 203, 202, 239, 1,
+       3, 245, 2, 237, 1, 3, 237, 236, 245, 1, 3, 64, 242, 236, 1, 3, 64, 236, 237, 1,
+       3, 242, 63, 244, 1, 3, 244, 236, 242, 1, 3, 68, 245, 236, 1, 3, 68, 236, 244, 1,
+       3, 241, 3, 246, 1, 3, 246, 240, 241, 1, 3, 65, 248, 240, 1, 3, 65, 240, 246, 1,
+       3, 248, 63, 242, 1, 3, 242, 240, 248, 1, 3, 64, 241, 240, 1, 3, 64, 240, 242, 1,
+3, 4, 250, 247, 1, 3, 4, 247, 253, 1, 3, 67, 251, 247, 1, 3, 67, 247, 250, 1,
+       3, 63, 248, 247, 1, 3, 63, 247, 251, 1, 3, 65, 253, 247, 1, 3, 65, 247, 248, 1,
+3, 7, 255, 243, 1, 3, 7, 243, 257, 1, 3, 68, 244, 243, 1, 3, 68, 243, 255, 1,
+       3, 63, 251, 243, 1, 3, 63, 243, 244, 1, 3, 67, 257, 243, 1, 3, 67, 243, 251, 1,
+       3, 246, 3, 206, 1, 3, 206, 205, 246, 1, 3, 54, 258, 205, 1, 3, 54, 205, 206, 1,
+       3, 258, 53, 259, 1, 3, 259, 205, 258, 1, 3, 65, 246, 205, 1, 3, 65, 205, 259, 1,
+3, 1, 260, 195, 1, 3, 1, 195, 196, 1, 3, 260, 69, 262, 1, 3, 262, 195, 260, 1,
+       3, 53, 258, 195, 1, 3, 53, 195, 262, 1, 3, 258, 54, 196, 1, 3, 196, 195, 258, 1,
+       3, 267, 5, 264, 1, 3, 264, 261, 267, 1, 3, 70, 265, 261, 1, 3, 70, 261, 264, 1,
+       3, 53, 262, 261, 1, 3, 53, 261, 265, 1, 3, 262, 69, 267, 1, 3, 267, 261, 262, 1,
+3, 4, 253, 252, 1, 3, 4, 252, 268, 1, 3, 253, 65, 259, 1, 3, 259, 252, 253, 1,
+       3, 53, 265, 252, 1, 3, 53, 252, 259, 1, 3, 70, 268, 252, 1, 3, 70, 252, 265, 1,
+3, 1, 214, 213, 1, 3, 1, 213, 260, 1, 3, 214, 59, 269, 1, 3, 269, 213, 214, 1,
+       3, 58, 270, 213, 1, 3, 58, 213, 269, 1, 3, 270, 69, 260, 1, 3, 260, 213, 270, 1,
+3, 0, 271, 218, 1, 3, 0, 218, 219, 1, 3, 271, 71, 273, 1, 3, 273, 218, 271, 1,
+       3, 58, 269, 218, 1, 3, 58, 218, 273, 1, 3, 269, 59, 219, 1, 3, 219, 218, 269, 1,
+3, 6, 275, 272, 1, 3, 6, 272, 278, 1, 3, 72, 276, 272, 1, 3, 72, 272, 275, 1,
+       3, 58, 273, 272, 1, 3, 58, 272, 276, 1, 3, 273, 71, 278, 1, 3, 278, 272, 273, 1,
+3, 5, 267, 266, 1, 3, 5, 266, 279, 1, 3, 267, 69, 270, 1, 3, 270, 266, 267, 1,
+       3, 58, 276, 266, 1, 3, 58, 266, 270, 1, 3, 72, 279, 266, 1, 3, 72, 266, 276, 1,
+3, 0, 226, 225, 1, 3, 0, 225, 271, 1, 3, 226, 62, 280, 1, 3, 280, 225, 226, 1,
+       3, 61, 281, 225, 1, 3, 61, 225, 280, 1, 3, 281, 71, 271, 1, 3, 271, 225, 281, 1,
+       3, 231, 2, 245, 1, 3, 245, 230, 231, 1, 3, 68, 282, 230, 1, 3, 68, 230, 245, 1,
+       3, 282, 61, 280, 1, 3, 280, 230, 282, 1, 3, 62, 231, 230, 1, 3, 62, 230, 280, 1,
+3, 7, 283, 254, 1, 3, 7, 254, 255, 1, 3, 73, 284, 254, 1, 3, 73, 254, 283, 1,
+       3, 61, 282, 254, 1, 3, 61, 254, 284, 1, 3, 282, 68, 255, 1, 3, 255, 254, 282, 1,
+       3, 285, 6, 278, 1, 3, 278, 277, 285, 1, 3, 278, 71, 281, 1, 3, 281, 277, 278, 1,
+       3, 61, 284, 277, 1, 3, 61, 277, 281, 1, 3, 73, 285, 277, 1, 3, 73, 277, 284, 1,
+3, 4, 268, 249, 1, 3, 4, 249, 250, 1, 3, 268, 70, 286, 1, 3, 286, 249, 268, 1,
+       3, 66, 287, 249, 1, 3, 66, 249, 286, 1, 3, 287, 67, 250, 1, 3, 250, 249, 287, 1,
+3, 5, 279, 263, 1, 3, 5, 263, 264, 1, 3, 279, 72, 288, 1, 3, 288, 263, 279, 1,
+       3, 66, 286, 263, 1, 3, 66, 263, 288, 1, 3, 286, 70, 264, 1, 3, 264, 263, 286, 1,
+3, 6, 285, 274, 1, 3, 6, 274, 275, 1, 3, 285, 73, 289, 1, 3, 289, 274, 285, 1,
+       3, 66, 288, 274, 1, 3, 66, 274, 289, 1, 3, 288, 72, 275, 1, 3, 275, 274, 288, 1,
+3, 7, 257, 256, 1, 3, 7, 256, 283, 1, 3, 257, 67, 287, 1, 3, 287, 256, 257, 1,
+       3, 66, 289, 256, 1, 3, 66, 256, 287, 1, 3, 289, 73, 283, 1, 3, 283, 256, 289, 1,
+
+       0
+};
+
+struct lwo  LWO_s1_3 =
+{
+       290,                    /* number of points */
+       s1_3_PNTS, s1_3_normals, s1_3_POLS, 0L
+};
+
+#endif /* MODE_sproingies */
+
+/* End of s1_3.c */
diff --git a/xlockmore-4.14/modes/glx/s1_4.c b/xlockmore-4.14/modes/glx/s1_4.c
new file mode 100644 (file)
index 0000000..cfff3a6
--- /dev/null
@@ -0,0 +1,1057 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)s1_4.c       4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points, polygons, and normal vectors to render "s1_4" in 3D.
+ *
+ * Generated by lw2ogl.  Link this with your program but do
+ * not edit by hand.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_sproingies
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat s1_4_PNTS[] =
+{
+       (GLfloat) 0.691977, (GLfloat) 0.424648, (GLfloat) - 0.335934,
+       (GLfloat) 0.691977, (GLfloat) 0.424648, (GLfloat) - 0.664066,
+       (GLfloat) 0.910107, (GLfloat) 0.206343, (GLfloat) - 0.335934,
+       (GLfloat) 0.910107, (GLfloat) 0.206343, (GLfloat) - 0.664066,
+       (GLfloat) 0.820528, (GLfloat) 0.154011, (GLfloat) - 0.638667,
+       (GLfloat) 0.608078, (GLfloat) 0.332278, (GLfloat) - 0.638667,
+       (GLfloat) 0.608078, (GLfloat) 0.332278, (GLfloat) - 0.361333,
+       (GLfloat) 0.820528, (GLfloat) 0.154011, (GLfloat) - 0.361333,
+       (GLfloat) 1.065609, (GLfloat) 0.289676, (GLfloat) - 0.638205,
+       (GLfloat) 1.074101, (GLfloat) 0.505017, (GLfloat) - 0.638205,
+       (GLfloat) 1.074101, (GLfloat) 0.505017, (GLfloat) - 0.361795,
+       (GLfloat) 1.065609, (GLfloat) 0.289676, (GLfloat) - 0.361795,
+       (GLfloat) 1.235562, (GLfloat) 0.083949, (GLfloat) - 0.664066,
+       (GLfloat) 1.235562, (GLfloat) 0.083949, (GLfloat) - 0.335934,
+       (GLfloat) 1.331736, (GLfloat) 0.017726, (GLfloat) - 0.361333,
+       (GLfloat) 1.331736, (GLfloat) 0.017726, (GLfloat) - 0.638667,
+       (GLfloat) 1.431839, (GLfloat) 0.331232, (GLfloat) - 0.335934,
+       (GLfloat) 1.517309, (GLfloat) 0.223825, (GLfloat) - 0.361333,
+       (GLfloat) 1.431839, (GLfloat) 0.331232, (GLfloat) - 0.664066,
+       (GLfloat) 1.517309, (GLfloat) 0.223825, (GLfloat) - 0.638667,
+       (GLfloat) 1.243033, (GLfloat) - 0.034453, (GLfloat) - 0.500000,
+       (GLfloat) 1.136909, (GLfloat) 0.161755, (GLfloat) - 0.500000,
+       (GLfloat) 1.199875, (GLfloat) 0.038989, (GLfloat) - 0.500000,
+       (GLfloat) 1.400739, (GLfloat) 0.142695, (GLfloat) - 0.261940,
+       (GLfloat) 1.284897, (GLfloat) 0.013483, (GLfloat) - 0.325812,
+       (GLfloat) 1.438241, (GLfloat) 0.108423, (GLfloat) - 0.500000,
+       (GLfloat) 1.310688, (GLfloat) - 0.015661, (GLfloat) - 0.500000,
+       (GLfloat) 1.400739, (GLfloat) 0.142695, (GLfloat) - 0.738060,
+       (GLfloat) 1.284897, (GLfloat) 0.013483, (GLfloat) - 0.674188,
+       (GLfloat) 1.216443, (GLfloat) 0.317256, (GLfloat) - 0.300040,
+       (GLfloat) 1.333700, (GLfloat) 0.207591, (GLfloat) - 0.276273,
+       (GLfloat) 1.558444, (GLfloat) 0.319842, (GLfloat) - 0.500000,
+       (GLfloat) 1.515677, (GLfloat) 0.272720, (GLfloat) - 0.325812,
+       (GLfloat) 1.429500, (GLfloat) 0.116294, (GLfloat) - 0.322437,
+       (GLfloat) 1.295978, (GLfloat) 0.472757, (GLfloat) - 0.500000,
+       (GLfloat) 1.467526, (GLfloat) 0.376193, (GLfloat) - 0.500000,
+       (GLfloat) 1.515677, (GLfloat) 0.272720, (GLfloat) - 0.674188,
+       (GLfloat) 1.548313, (GLfloat) 0.248248, (GLfloat) - 0.500000,
+       (GLfloat) 1.216443, (GLfloat) 0.317256, (GLfloat) - 0.699960,
+       (GLfloat) 1.333700, (GLfloat) 0.207591, (GLfloat) - 0.723727,
+       (GLfloat) 1.429500, (GLfloat) 0.116294, (GLfloat) - 0.677562,
+       (GLfloat) 1.158118, (GLfloat) 0.203222, (GLfloat) - 0.646637,
+       (GLfloat) 0.998811, (GLfloat) 0.235426, (GLfloat) - 0.500000,
+       (GLfloat) 1.064065, (GLfloat) 0.250523, (GLfloat) - 0.500000,
+       (GLfloat) 1.158118, (GLfloat) 0.203222, (GLfloat) - 0.353363,
+       (GLfloat) 1.274769, (GLfloat) 0.431290, (GLfloat) - 0.646637,
+       (GLfloat) 0.920924, (GLfloat) 0.379919, (GLfloat) - 0.699960,
+       (GLfloat) 1.069855, (GLfloat) 0.397346, (GLfloat) - 0.688461,
+       (GLfloat) 0.920924, (GLfloat) 0.379919, (GLfloat) - 0.300040,
+       (GLfloat) 1.069855, (GLfloat) 0.397346, (GLfloat) - 0.311539,
+       (GLfloat) 1.274769, (GLfloat) 0.431290, (GLfloat) - 0.353363,
+       (GLfloat) 0.843038, (GLfloat) 0.524412, (GLfloat) - 0.500000,
+       (GLfloat) 1.075645, (GLfloat) 0.544169, (GLfloat) - 0.500000,
+       (GLfloat) 0.735693, (GLfloat) 0.265534, (GLfloat) - 0.738060,
+       (GLfloat) 0.801042, (GLfloat) 0.315496, (GLfloat) - 0.723727,
+       (GLfloat) 0.978041, (GLfloat) 0.273957, (GLfloat) - 0.646637,
+       (GLfloat) 0.863808, (GLfloat) 0.485881, (GLfloat) - 0.646637,
+       (GLfloat) 0.863808, (GLfloat) 0.485881, (GLfloat) - 0.353363,
+       (GLfloat) 0.555594, (GLfloat) 0.419060, (GLfloat) - 0.500000,
+       (GLfloat) 0.652318, (GLfloat) 0.464340, (GLfloat) - 0.500000,
+       (GLfloat) 0.978041, (GLfloat) 0.273957, (GLfloat) - 0.353363,
+       (GLfloat) 0.735693, (GLfloat) 0.265534, (GLfloat) - 0.261940,
+       (GLfloat) 0.801042, (GLfloat) 0.315496, (GLfloat) - 0.276273,
+       (GLfloat) 0.915792, (GLfloat) 0.112008, (GLfloat) - 0.500000,
+       (GLfloat) 0.949767, (GLfloat) 0.166652, (GLfloat) - 0.500000,
+       (GLfloat) 0.867858, (GLfloat) 0.153664, (GLfloat) - 0.674188,
+       (GLfloat) 0.702437, (GLfloat) 0.229003, (GLfloat) - 0.500000,
+       (GLfloat) 0.846018, (GLfloat) 0.123878, (GLfloat) - 0.500000,
+       (GLfloat) 0.867858, (GLfloat) 0.153664, (GLfloat) - 0.325812,
+       (GLfloat) 0.604310, (GLfloat) 0.378335, (GLfloat) - 0.674188,
+       (GLfloat) 0.709997, (GLfloat) 0.238013, (GLfloat) - 0.677562,
+       (GLfloat) 0.604310, (GLfloat) 0.378335, (GLfloat) - 0.325812,
+       (GLfloat) 0.573976, (GLfloat) 0.352148, (GLfloat) - 0.500000,
+       (GLfloat) 0.709997, (GLfloat) 0.238013, (GLfloat) - 0.322437,
+       (GLfloat) 1.231827, (GLfloat) 0.004686, (GLfloat) - 0.594296,
+       (GLfloat) 1.178115, (GLfloat) 0.109780, (GLfloat) - 0.584482,
+       (GLfloat) 1.208797, (GLfloat) 0.050229, (GLfloat) - 0.589491,
+       (GLfloat) 1.231827, (GLfloat) 0.004686, (GLfloat) - 0.405704,
+       (GLfloat) 1.221734, (GLfloat) - 0.007055, (GLfloat) - 0.500000,
+       (GLfloat) 1.279887, (GLfloat) - 0.026194, (GLfloat) - 0.587500,
+       (GLfloat) 1.253444, (GLfloat) - 0.022303, (GLfloat) - 0.594949,
+       (GLfloat) 1.312568, (GLfloat) 0.098620, (GLfloat) - 0.720025,
+       (GLfloat) 1.262105, (GLfloat) 0.039911, (GLfloat) - 0.672877,
+       (GLfloat) 1.312568, (GLfloat) 0.098620, (GLfloat) - 0.279975,
+       (GLfloat) 1.262105, (GLfloat) 0.039911, (GLfloat) - 0.327123,
+       (GLfloat) 1.279887, (GLfloat) - 0.026194, (GLfloat) - 0.412500,
+       (GLfloat) 1.253444, (GLfloat) - 0.022303, (GLfloat) - 0.405051,
+       (GLfloat) 1.178115, (GLfloat) 0.109780, (GLfloat) - 0.415518,
+       (GLfloat) 1.208797, (GLfloat) 0.050229, (GLfloat) - 0.410509,
+       (GLfloat) 1.373428, (GLfloat) 0.045002, (GLfloat) - 0.409500,
+       (GLfloat) 1.317700, (GLfloat) - 0.004566, (GLfloat) - 0.417500,
+       (GLfloat) 1.270418, (GLfloat) - 0.038526, (GLfloat) - 0.500000,
+       (GLfloat) 1.359179, (GLfloat) 0.061869, (GLfloat) - 0.294000,
+       (GLfloat) 1.309178, (GLfloat) 0.008154, (GLfloat) - 0.339125,
+       (GLfloat) 1.359179, (GLfloat) 0.061869, (GLfloat) - 0.706000,
+       (GLfloat) 1.309178, (GLfloat) 0.008154, (GLfloat) - 0.660875,
+       (GLfloat) 1.373428, (GLfloat) 0.045002, (GLfloat) - 0.590500,
+       (GLfloat) 1.317700, (GLfloat) - 0.004566, (GLfloat) - 0.582500,
+       (GLfloat) 1.236552, (GLfloat) 0.195985, (GLfloat) - 0.302876,
+       (GLfloat) 1.280170, (GLfloat) 0.140150, (GLfloat) - 0.291188,
+       (GLfloat) 1.433681, (GLfloat) 0.239521, (GLfloat) - 0.279975,
+       (GLfloat) 1.373124, (GLfloat) 0.169070, (GLfloat) - 0.264259,
+       (GLfloat) 1.337615, (GLfloat) 0.072243, (GLfloat) - 0.277994,
+       (GLfloat) 1.514422, (GLfloat) 0.333454, (GLfloat) - 0.405704,
+       (GLfloat) 1.484144, (GLfloat) 0.298229, (GLfloat) - 0.327123,
+       (GLfloat) 1.476277, (GLfloat) 0.191919, (GLfloat) - 0.294000,
+       (GLfloat) 1.463411, (GLfloat) 0.213552, (GLfloat) - 0.277994,
+       (GLfloat) 1.324207, (GLfloat) 0.325294, (GLfloat) - 0.302876,
+       (GLfloat) 1.387230, (GLfloat) 0.275032, (GLfloat) - 0.291188,
+       (GLfloat) 1.494540, (GLfloat) 0.179511, (GLfloat) - 0.409500,
+       (GLfloat) 1.483059, (GLfloat) 0.179084, (GLfloat) - 0.335375,
+       (GLfloat) 1.418631, (GLfloat) 0.126081, (GLfloat) - 0.278500,
+       (GLfloat) 1.555568, (GLfloat) 0.279982, (GLfloat) - 0.412500,
+       (GLfloat) 1.524471, (GLfloat) 0.247261, (GLfloat) - 0.339125,
+       (GLfloat) 1.372652, (GLfloat) 0.056465, (GLfloat) - 0.335375,
+       (GLfloat) 1.382643, (GLfloat) 0.411500, (GLfloat) - 0.415518,
+       (GLfloat) 1.458604, (GLfloat) 0.364953, (GLfloat) - 0.410509,
+       (GLfloat) 1.514422, (GLfloat) 0.333454, (GLfloat) - 0.594296,
+       (GLfloat) 1.524515, (GLfloat) 0.345196, (GLfloat) - 0.500000,
+       (GLfloat) 1.547582, (GLfloat) 0.308099, (GLfloat) - 0.405051,
+       (GLfloat) 1.433681, (GLfloat) 0.239521, (GLfloat) - 0.720025,
+       (GLfloat) 1.484144, (GLfloat) 0.298229, (GLfloat) - 0.672877,
+       (GLfloat) 1.555568, (GLfloat) 0.279982, (GLfloat) - 0.587500,
+       (GLfloat) 1.547582, (GLfloat) 0.308099, (GLfloat) - 0.594949,
+       (GLfloat) 1.382643, (GLfloat) 0.411500, (GLfloat) - 0.584482,
+       (GLfloat) 1.458604, (GLfloat) 0.364953, (GLfloat) - 0.589491,
+       (GLfloat) 1.494540, (GLfloat) 0.179511, (GLfloat) - 0.590500,
+       (GLfloat) 1.538011, (GLfloat) 0.240115, (GLfloat) - 0.582500,
+       (GLfloat) 1.566843, (GLfloat) 0.290687, (GLfloat) - 0.500000,
+       (GLfloat) 1.476277, (GLfloat) 0.191919, (GLfloat) - 0.706000,
+       (GLfloat) 1.524471, (GLfloat) 0.247261, (GLfloat) - 0.660875,
+       (GLfloat) 1.538011, (GLfloat) 0.240115, (GLfloat) - 0.417500,
+       (GLfloat) 1.324207, (GLfloat) 0.325294, (GLfloat) - 0.697124,
+       (GLfloat) 1.387230, (GLfloat) 0.275032, (GLfloat) - 0.708812,
+       (GLfloat) 1.373124, (GLfloat) 0.169070, (GLfloat) - 0.735741,
+       (GLfloat) 1.463411, (GLfloat) 0.213552, (GLfloat) - 0.722006,
+       (GLfloat) 1.337615, (GLfloat) 0.072243, (GLfloat) - 0.722006,
+       (GLfloat) 1.236552, (GLfloat) 0.195985, (GLfloat) - 0.697124,
+       (GLfloat) 1.280170, (GLfloat) 0.140150, (GLfloat) - 0.708812,
+       (GLfloat) 1.372652, (GLfloat) 0.056465, (GLfloat) - 0.664625,
+       (GLfloat) 1.418631, (GLfloat) 0.126081, (GLfloat) - 0.721500,
+       (GLfloat) 1.483059, (GLfloat) 0.179084, (GLfloat) - 0.664625,
+       (GLfloat) 1.436048, (GLfloat) 0.110398, (GLfloat) - 0.402250,
+       (GLfloat) 1.370641, (GLfloat) 0.037756, (GLfloat) - 0.500000,
+       (GLfloat) 1.501456, (GLfloat) 0.183040, (GLfloat) - 0.500000,
+       (GLfloat) 1.436048, (GLfloat) 0.110398, (GLfloat) - 0.597750,
+       (GLfloat) 1.200029, (GLfloat) 0.142107, (GLfloat) - 0.654883,
+       (GLfloat) 1.103513, (GLfloat) 0.226037, (GLfloat) - 0.576713,
+       (GLfloat) 1.142211, (GLfloat) 0.172121, (GLfloat) - 0.579984,
+       (GLfloat) 1.170811, (GLfloat) 0.099004, (GLfloat) - 0.500000,
+       (GLfloat) 1.027452, (GLfloat) 0.263727, (GLfloat) - 0.576713,
+       (GLfloat) 1.064451, (GLfloat) 0.260311, (GLfloat) - 0.575384,
+       (GLfloat) 1.103513, (GLfloat) 0.226037, (GLfloat) - 0.423287,
+       (GLfloat) 1.100538, (GLfloat) 0.216006, (GLfloat) - 0.500000,
+       (GLfloat) 1.127320, (GLfloat) 0.306289, (GLfloat) - 0.678998,
+       (GLfloat) 1.112441, (GLfloat) 0.256132, (GLfloat) - 0.640641,
+       (GLfloat) 1.127320, (GLfloat) 0.306289, (GLfloat) - 0.321002,
+       (GLfloat) 1.112441, (GLfloat) 0.256132, (GLfloat) - 0.359359,
+       (GLfloat) 1.142211, (GLfloat) 0.172121, (GLfloat) - 0.420016,
+       (GLfloat) 1.027452, (GLfloat) 0.263727, (GLfloat) - 0.423287,
+       (GLfloat) 1.064451, (GLfloat) 0.260311, (GLfloat) - 0.424615,
+       (GLfloat) 1.200029, (GLfloat) 0.142107, (GLfloat) - 0.345117,
+       (GLfloat) 1.360730, (GLfloat) 0.379173, (GLfloat) - 0.654883,
+       (GLfloat) 1.163029, (GLfloat) 0.426667, (GLfloat) - 0.678998,
+       (GLfloat) 1.248257, (GLfloat) 0.379456, (GLfloat) - 0.686629,
+       (GLfloat) 1.280379, (GLfloat) 0.260640, (GLfloat) - 0.711204,
+       (GLfloat) 0.979330, (GLfloat) 0.456830, (GLfloat) - 0.678998,
+       (GLfloat) 1.072171, (GLfloat) 0.456076, (GLfloat) - 0.675897,
+       (GLfloat) 1.145175, (GLfloat) 0.366478, (GLfloat) - 0.691783,
+       (GLfloat) 1.186836, (GLfloat) 0.506919, (GLfloat) - 0.576713,
+       (GLfloat) 1.177908, (GLfloat) 0.476825, (GLfloat) - 0.640641,
+       (GLfloat) 1.184630, (GLfloat) 0.255055, (GLfloat) - 0.686629,
+       (GLfloat) 1.008203, (GLfloat) 0.340968, (GLfloat) - 0.678998,
+       (GLfloat) 1.067539, (GLfloat) 0.338617, (GLfloat) - 0.675897,
+       (GLfloat) 1.280379, (GLfloat) 0.260640, (GLfloat) - 0.288796,
+       (GLfloat) 1.163029, (GLfloat) 0.426667, (GLfloat) - 0.321002,
+       (GLfloat) 1.248257, (GLfloat) 0.379456, (GLfloat) - 0.313371,
+       (GLfloat) 1.360730, (GLfloat) 0.379173, (GLfloat) - 0.345117,
+       (GLfloat) 1.184630, (GLfloat) 0.255055, (GLfloat) - 0.313371,
+       (GLfloat) 1.008203, (GLfloat) 0.340968, (GLfloat) - 0.321002,
+       (GLfloat) 1.067539, (GLfloat) 0.338617, (GLfloat) - 0.324103,
+       (GLfloat) 1.145175, (GLfloat) 0.366478, (GLfloat) - 0.308217,
+       (GLfloat) 1.186836, (GLfloat) 0.506919, (GLfloat) - 0.423287,
+       (GLfloat) 1.177908, (GLfloat) 0.476825, (GLfloat) - 0.359359,
+       (GLfloat) 0.979330, (GLfloat) 0.456830, (GLfloat) - 0.321002,
+       (GLfloat) 1.072171, (GLfloat) 0.456076, (GLfloat) - 0.324103,
+       (GLfloat) 1.389948, (GLfloat) 0.422275, (GLfloat) - 0.500000,
+       (GLfloat) 1.290676, (GLfloat) 0.462390, (GLfloat) - 0.579984,
+       (GLfloat) 1.290676, (GLfloat) 0.462390, (GLfloat) - 0.420016,
+       (GLfloat) 0.960081, (GLfloat) 0.534071, (GLfloat) - 0.423287,
+       (GLfloat) 1.075259, (GLfloat) 0.534381, (GLfloat) - 0.424615,
+       (GLfloat) 1.189812, (GLfloat) 0.516951, (GLfloat) - 0.500000,
+       (GLfloat) 0.960081, (GLfloat) 0.534071, (GLfloat) - 0.576713,
+       (GLfloat) 1.075259, (GLfloat) 0.534381, (GLfloat) - 0.575384,
+       (GLfloat) 0.808756, (GLfloat) 0.407522, (GLfloat) - 0.697124,
+       (GLfloat) 0.693423, (GLfloat) 0.349037, (GLfloat) - 0.720025,
+       (GLfloat) 0.741552, (GLfloat) 0.375033, (GLfloat) - 0.708812,
+       (GLfloat) 0.901933, (GLfloat) 0.290859, (GLfloat) - 0.697124,
+       (GLfloat) 0.855345, (GLfloat) 0.349190, (GLfloat) - 0.711204,
+       (GLfloat) 0.889770, (GLfloat) 0.437716, (GLfloat) - 0.686629,
+       (GLfloat) 0.746638, (GLfloat) 0.485298, (GLfloat) - 0.584482,
+       (GLfloat) 0.769932, (GLfloat) 0.456132, (GLfloat) - 0.654883,
+       (GLfloat) 0.964051, (GLfloat) 0.213083, (GLfloat) - 0.584482,
+       (GLfloat) 0.940757, (GLfloat) 0.242249, (GLfloat) - 0.654883,
+       (GLfloat) 0.952079, (GLfloat) 0.322122, (GLfloat) - 0.686629,
+       (GLfloat) 0.830643, (GLfloat) 0.226200, (GLfloat) - 0.720025,
+       (GLfloat) 0.860532, (GLfloat) 0.255958, (GLfloat) - 0.708812,
+       (GLfloat) 0.993766, (GLfloat) 0.398899, (GLfloat) - 0.691783,
+       (GLfloat) 1.020234, (GLfloat) 0.292692, (GLfloat) - 0.640641,
+       (GLfloat) 0.967299, (GLfloat) 0.505105, (GLfloat) - 0.640641,
+       (GLfloat) 0.848231, (GLfloat) 0.514780, (GLfloat) - 0.579984,
+       (GLfloat) 0.746638, (GLfloat) 0.485298, (GLfloat) - 0.415518,
+       (GLfloat) 0.738873, (GLfloat) 0.495020, (GLfloat) - 0.500000,
+       (GLfloat) 0.601944, (GLfloat) 0.430927, (GLfloat) - 0.594296,
+       (GLfloat) 0.662233, (GLfloat) 0.454417, (GLfloat) - 0.589491,
+       (GLfloat) 0.957675, (GLfloat) 0.543726, (GLfloat) - 0.500000,
+       (GLfloat) 0.967299, (GLfloat) 0.505105, (GLfloat) - 0.359359,
+       (GLfloat) 0.848231, (GLfloat) 0.514780, (GLfloat) - 0.420016,
+       (GLfloat) 0.601944, (GLfloat) 0.430927, (GLfloat) - 0.405704,
+       (GLfloat) 0.662233, (GLfloat) 0.454417, (GLfloat) - 0.410509,
+       (GLfloat) 0.808756, (GLfloat) 0.407522, (GLfloat) - 0.302876,
+       (GLfloat) 0.769932, (GLfloat) 0.456132, (GLfloat) - 0.345117,
+       (GLfloat) 0.889770, (GLfloat) 0.437716, (GLfloat) - 0.313371,
+       (GLfloat) 0.901933, (GLfloat) 0.290859, (GLfloat) - 0.302876,
+       (GLfloat) 0.855345, (GLfloat) 0.349190, (GLfloat) - 0.288796,
+       (GLfloat) 0.693423, (GLfloat) 0.349037, (GLfloat) - 0.279975,
+       (GLfloat) 0.741552, (GLfloat) 0.375033, (GLfloat) - 0.291188,
+       (GLfloat) 0.993766, (GLfloat) 0.398899, (GLfloat) - 0.308217,
+       (GLfloat) 1.020234, (GLfloat) 0.292692, (GLfloat) - 0.359359,
+       (GLfloat) 0.952079, (GLfloat) 0.322122, (GLfloat) - 0.313371,
+       (GLfloat) 0.830643, (GLfloat) 0.226200, (GLfloat) - 0.279975,
+       (GLfloat) 0.860532, (GLfloat) 0.255958, (GLfloat) - 0.291188,
+       (GLfloat) 0.964051, (GLfloat) 0.213083, (GLfloat) - 0.415518,
+       (GLfloat) 0.940757, (GLfloat) 0.242249, (GLfloat) - 0.345117,
+       (GLfloat) 0.993618, (GLfloat) 0.245059, (GLfloat) - 0.420016,
+       (GLfloat) 0.971816, (GLfloat) 0.203361, (GLfloat) - 0.500000,
+       (GLfloat) 0.922122, (GLfloat) 0.144310, (GLfloat) - 0.405704,
+       (GLfloat) 0.939852, (GLfloat) 0.176575, (GLfloat) - 0.410509,
+       (GLfloat) 1.029858, (GLfloat) 0.254072, (GLfloat) - 0.500000,
+       (GLfloat) 0.993618, (GLfloat) 0.245059, (GLfloat) - 0.579984,
+       (GLfloat) 0.922122, (GLfloat) 0.144310, (GLfloat) - 0.594296,
+       (GLfloat) 0.939852, (GLfloat) 0.176575, (GLfloat) - 0.589491,
+       (GLfloat) 0.933557, (GLfloat) 0.134073, (GLfloat) - 0.500000,
+       (GLfloat) 0.877985, (GLfloat) 0.117734, (GLfloat) - 0.412500,
+       (GLfloat) 0.903840, (GLfloat) 0.122594, (GLfloat) - 0.405051,
+       (GLfloat) 0.887817, (GLfloat) 0.175019, (GLfloat) - 0.327123,
+       (GLfloat) 0.887817, (GLfloat) 0.175019, (GLfloat) - 0.672877,
+       (GLfloat) 0.877985, (GLfloat) 0.117734, (GLfloat) - 0.587500,
+       (GLfloat) 0.903840, (GLfloat) 0.122594, (GLfloat) - 0.594949,
+       (GLfloat) 0.775446, (GLfloat) 0.175219, (GLfloat) - 0.590500,
+       (GLfloat) 0.837530, (GLfloat) 0.133890, (GLfloat) - 0.582500,
+       (GLfloat) 0.889078, (GLfloat) 0.106840, (GLfloat) - 0.500000,
+       (GLfloat) 0.787209, (GLfloat) 0.193905, (GLfloat) - 0.706000,
+       (GLfloat) 0.844199, (GLfloat) 0.147671, (GLfloat) - 0.660875,
+       (GLfloat) 0.787209, (GLfloat) 0.193905, (GLfloat) - 0.294000,
+       (GLfloat) 0.844199, (GLfloat) 0.147671, (GLfloat) - 0.339125,
+       (GLfloat) 0.775446, (GLfloat) 0.175219, (GLfloat) - 0.409500,
+       (GLfloat) 0.837530, (GLfloat) 0.133890, (GLfloat) - 0.417500,
+       (GLfloat) 0.762033, (GLfloat) 0.287619, (GLfloat) - 0.735741,
+       (GLfloat) 0.807717, (GLfloat) 0.204533, (GLfloat) - 0.722006,
+       (GLfloat) 0.636249, (GLfloat) 0.400218, (GLfloat) - 0.672877,
+       (GLfloat) 0.653151, (GLfloat) 0.306393, (GLfloat) - 0.706000,
+       (GLfloat) 0.664060, (GLfloat) 0.327000, (GLfloat) - 0.722006,
+       (GLfloat) 0.636792, (GLfloat) 0.291564, (GLfloat) - 0.590500,
+       (GLfloat) 0.648221, (GLfloat) 0.292739, (GLfloat) - 0.664625,
+       (GLfloat) 0.719399, (GLfloat) 0.249218, (GLfloat) - 0.721500,
+       (GLfloat) 0.562375, (GLfloat) 0.382563, (GLfloat) - 0.587500,
+       (GLfloat) 0.597724, (GLfloat) 0.354488, (GLfloat) - 0.660875,
+       (GLfloat) 0.774619, (GLfloat) 0.186679, (GLfloat) - 0.664625,
+       (GLfloat) 0.590509, (GLfloat) 0.441164, (GLfloat) - 0.500000,
+       (GLfloat) 0.567937, (GLfloat) 0.408940, (GLfloat) - 0.594949,
+       (GLfloat) 0.636249, (GLfloat) 0.400218, (GLfloat) - 0.327123,
+       (GLfloat) 0.562375, (GLfloat) 0.382563, (GLfloat) - 0.412500,
+       (GLfloat) 0.567937, (GLfloat) 0.408940, (GLfloat) - 0.405051,
+       (GLfloat) 0.636792, (GLfloat) 0.291564, (GLfloat) - 0.409500,
+       (GLfloat) 0.585310, (GLfloat) 0.345528, (GLfloat) - 0.417500,
+       (GLfloat) 0.549720, (GLfloat) 0.391595, (GLfloat) - 0.500000,
+       (GLfloat) 0.653151, (GLfloat) 0.306393, (GLfloat) - 0.294000,
+       (GLfloat) 0.597724, (GLfloat) 0.354488, (GLfloat) - 0.339125,
+       (GLfloat) 0.585310, (GLfloat) 0.345528, (GLfloat) - 0.582500,
+       (GLfloat) 0.762033, (GLfloat) 0.287619, (GLfloat) - 0.264259,
+       (GLfloat) 0.664060, (GLfloat) 0.327000, (GLfloat) - 0.277994,
+       (GLfloat) 0.807717, (GLfloat) 0.204533, (GLfloat) - 0.277994,
+       (GLfloat) 0.774619, (GLfloat) 0.186679, (GLfloat) - 0.335375,
+       (GLfloat) 0.719399, (GLfloat) 0.249218, (GLfloat) - 0.278500,
+       (GLfloat) 0.648221, (GLfloat) 0.292739, (GLfloat) - 0.335375,
+       (GLfloat) 0.704334, (GLfloat) 0.231264, (GLfloat) - 0.597750,
+       (GLfloat) 0.779215, (GLfloat) 0.168431, (GLfloat) - 0.500000,
+       (GLfloat) 0.629453, (GLfloat) 0.294096, (GLfloat) - 0.500000,
+       (GLfloat) 0.704334, (GLfloat) 0.231264, (GLfloat) - 0.402250,
+};
+
+static GLfloat s1_4_normals[] =
+{
+       (GLfloat) - 0.797489, (GLfloat) - 0.388285, (GLfloat) - 0.461786,
+       (GLfloat) - 0.806184, (GLfloat) - 0.357959, (GLfloat) - 0.471096,
+       (GLfloat) - 0.893364, (GLfloat) - 0.424111, (GLfloat) - 0.148429,
+       (GLfloat) - 0.889195, (GLfloat) - 0.434532, (GLfloat) - 0.143226,
+       (GLfloat) - 0.778943, (GLfloat) - 0.605569, (GLfloat) - 0.162894,
+       (GLfloat) - 0.772426, (GLfloat) - 0.614820, (GLfloat) - 0.159231,
+       (GLfloat) - 0.666558, (GLfloat) - 0.549876, (GLfloat) - 0.503327,
+       (GLfloat) - 0.677911, (GLfloat) - 0.530666, (GLfloat) - 0.508753,
+       (GLfloat) - 0.797489, (GLfloat) - 0.388284, (GLfloat) 0.461786,
+       (GLfloat) - 0.806184, (GLfloat) - 0.357959, (GLfloat) 0.471097,
+       (GLfloat) - 0.677911, (GLfloat) - 0.530666, (GLfloat) 0.508753,
+       (GLfloat) - 0.666558, (GLfloat) - 0.549876, (GLfloat) 0.503327,
+       (GLfloat) - 0.778943, (GLfloat) - 0.605569, (GLfloat) 0.162893,
+       (GLfloat) - 0.772426, (GLfloat) - 0.614820, (GLfloat) 0.159231,
+       (GLfloat) - 0.889195, (GLfloat) - 0.434532, (GLfloat) 0.143226,
+       (GLfloat) - 0.893364, (GLfloat) - 0.424111, (GLfloat) 0.148429,
+       (GLfloat) 0.506235, (GLfloat) - 0.837464, (GLfloat) 0.205866,
+       (GLfloat) 0.527758, (GLfloat) - 0.830515, (GLfloat) 0.178091,
+       (GLfloat) 0.492576, (GLfloat) - 0.867532, (GLfloat) 0.068965,
+       (GLfloat) 0.502441, (GLfloat) - 0.861510, (GLfloat) 0.073162,
+       (GLfloat) - 0.106119, (GLfloat) - 0.984780, (GLfloat) 0.137644,
+       (GLfloat) - 0.145376, (GLfloat) - 0.977399, (GLfloat) 0.153482,
+       (GLfloat) 0.021131, (GLfloat) - 0.914284, (GLfloat) 0.404523,
+       (GLfloat) - 0.012401, (GLfloat) - 0.903702, (GLfloat) 0.427982,
+       (GLfloat) 0.527757, (GLfloat) - 0.830515, (GLfloat) - 0.178092,
+       (GLfloat) 0.506235, (GLfloat) - 0.837464, (GLfloat) - 0.205866,
+       (GLfloat) 0.021132, (GLfloat) - 0.914284, (GLfloat) - 0.404523,
+       (GLfloat) - 0.012401, (GLfloat) - 0.903702, (GLfloat) - 0.427983,
+       (GLfloat) - 0.145376, (GLfloat) - 0.977399, (GLfloat) - 0.153482,
+       (GLfloat) - 0.106119, (GLfloat) - 0.984780, (GLfloat) - 0.137645,
+       (GLfloat) 0.502441, (GLfloat) - 0.861510, (GLfloat) - 0.073162,
+       (GLfloat) 0.492576, (GLfloat) - 0.867532, (GLfloat) - 0.068965,
+       (GLfloat) - 0.548436, (GLfloat) - 0.209256, (GLfloat) 0.809586,
+       (GLfloat) - 0.557133, (GLfloat) - 0.173326, (GLfloat) 0.812134,
+       (GLfloat) - 0.281454, (GLfloat) 0.011196, (GLfloat) 0.959509,
+       (GLfloat) - 0.287811, (GLfloat) 0.033884, (GLfloat) 0.957087,
+       (GLfloat) - 0.161493, (GLfloat) - 0.079455, (GLfloat) 0.983670,
+       (GLfloat) - 0.160469, (GLfloat) - 0.081504, (GLfloat) 0.983670,
+       (GLfloat) - 0.417652, (GLfloat) - 0.317957, (GLfloat) 0.851158,
+       (GLfloat) - 0.412553, (GLfloat) - 0.327906, (GLfloat) 0.849869,
+       (GLfloat) 0.183686, (GLfloat) 0.514678, (GLfloat) 0.837476,
+       (GLfloat) 0.191133, (GLfloat) 0.514047, (GLfloat) 0.836196,
+       (GLfloat) 0.305019, (GLfloat) 0.420960, (GLfloat) 0.854258,
+       (GLfloat) 0.309443, (GLfloat) 0.419398, (GLfloat) 0.853434,
+       (GLfloat) 0.070662, (GLfloat) 0.160554, (GLfloat) 0.984494,
+       (GLfloat) 0.072116, (GLfloat) 0.157712, (GLfloat) 0.984848,
+       (GLfloat) - 0.043552, (GLfloat) 0.248570, (GLfloat) 0.967634,
+       (GLfloat) - 0.045553, (GLfloat) 0.254642, (GLfloat) 0.965962,
+       (GLfloat) 0.833765, (GLfloat) - 0.473703, (GLfloat) 0.283620,
+       (GLfloat) 0.823611, (GLfloat) - 0.501937, (GLfloat) 0.264054,
+       (GLfloat) 0.753164, (GLfloat) - 0.577527, (GLfloat) 0.314971,
+       (GLfloat) 0.750976, (GLfloat) - 0.585768, (GLfloat) 0.304813,
+       (GLfloat) 0.524744, (GLfloat) - 0.282162, (GLfloat) 0.803137,
+       (GLfloat) 0.515479, (GLfloat) - 0.259037, (GLfloat) 0.816812,
+       (GLfloat) 0.731077, (GLfloat) - 0.100383, (GLfloat) 0.674870,
+       (GLfloat) 0.725771, (GLfloat) - 0.074391, (GLfloat) 0.683903,
+       (GLfloat) 0.576854, (GLfloat) - 0.777370, (GLfloat) 0.250869,
+       (GLfloat) 0.569572, (GLfloat) - 0.770539, (GLfloat) 0.286108,
+       (GLfloat) 0.204307, (GLfloat) - 0.721596, (GLfloat) 0.661481,
+       (GLfloat) 0.158422, (GLfloat) - 0.717392, (GLfloat) 0.678418,
+       (GLfloat) 0.308874, (GLfloat) - 0.483661, (GLfloat) 0.818944,
+       (GLfloat) 0.351163, (GLfloat) - 0.495655, (GLfloat) 0.794362,
+       (GLfloat) 0.653090, (GLfloat) - 0.688670, (GLfloat) 0.314971,
+       (GLfloat) 0.661058, (GLfloat) - 0.685633, (GLfloat) 0.304812,
+       (GLfloat) 0.403257, (GLfloat) 0.770775, (GLfloat) 0.493244,
+       (GLfloat) 0.393266, (GLfloat) 0.772882, (GLfloat) 0.497991,
+       (GLfloat) 0.471763, (GLfloat) 0.867363, (GLfloat) 0.158497,
+       (GLfloat) 0.475196, (GLfloat) 0.865916, (GLfloat) 0.156134,
+       (GLfloat) 0.590364, (GLfloat) 0.790041, (GLfloat) 0.165246,
+       (GLfloat) 0.597402, (GLfloat) 0.785461, (GLfloat) 0.161746,
+       (GLfloat) 0.528711, (GLfloat) 0.679696, (GLfloat) 0.508407,
+       (GLfloat) 0.514728, (GLfloat) 0.686399, (GLfloat) 0.513723,
+       (GLfloat) 0.403257, (GLfloat) 0.770775, (GLfloat) - 0.493244,
+       (GLfloat) 0.393266, (GLfloat) 0.772882, (GLfloat) - 0.497991,
+       (GLfloat) 0.514728, (GLfloat) 0.686399, (GLfloat) - 0.513723,
+       (GLfloat) 0.528711, (GLfloat) 0.679696, (GLfloat) - 0.508407,
+       (GLfloat) 0.590364, (GLfloat) 0.790041, (GLfloat) - 0.165246,
+       (GLfloat) 0.597402, (GLfloat) 0.785461, (GLfloat) - 0.161746,
+       (GLfloat) 0.475196, (GLfloat) 0.865916, (GLfloat) - 0.156134,
+       (GLfloat) 0.471763, (GLfloat) 0.867363, (GLfloat) - 0.158497,
+       (GLfloat) 0.885792, (GLfloat) - 0.415923, (GLfloat) - 0.205866,
+       (GLfloat) 0.881131, (GLfloat) - 0.438054, (GLfloat) - 0.178091,
+       (GLfloat) 0.914268, (GLfloat) - 0.399196, (GLfloat) - 0.068966,
+       (GLfloat) 0.909310, (GLfloat) - 0.409637, (GLfloat) - 0.073163,
+       (GLfloat) 0.961663, (GLfloat) 0.236259, (GLfloat) - 0.139234,
+       (GLfloat) 0.949193, (GLfloat) 0.273441, (GLfloat) - 0.155762,
+       (GLfloat) 0.901801, (GLfloat) 0.090517, (GLfloat) - 0.422565,
+       (GLfloat) 0.894672, (GLfloat) 0.141897, (GLfloat) - 0.423589,
+       (GLfloat) 0.881131, (GLfloat) - 0.438054, (GLfloat) 0.178091,
+       (GLfloat) 0.885792, (GLfloat) - 0.415923, (GLfloat) 0.205866,
+       (GLfloat) 0.894672, (GLfloat) 0.141897, (GLfloat) 0.423589,
+       (GLfloat) 0.901801, (GLfloat) 0.090518, (GLfloat) 0.422565,
+       (GLfloat) 0.949193, (GLfloat) 0.273441, (GLfloat) 0.155762,
+       (GLfloat) 0.961663, (GLfloat) 0.236259, (GLfloat) 0.139234,
+       (GLfloat) 0.909310, (GLfloat) - 0.409637, (GLfloat) 0.073163,
+       (GLfloat) 0.914268, (GLfloat) - 0.399196, (GLfloat) 0.068966,
+       (GLfloat) 0.191133, (GLfloat) 0.514047, (GLfloat) - 0.836196,
+       (GLfloat) 0.183686, (GLfloat) 0.514678, (GLfloat) - 0.837476,
+       (GLfloat) - 0.045553, (GLfloat) 0.254642, (GLfloat) - 0.965962,
+       (GLfloat) - 0.043552, (GLfloat) 0.248570, (GLfloat) - 0.967634,
+       (GLfloat) 0.070662, (GLfloat) 0.160554, (GLfloat) - 0.984494,
+       (GLfloat) 0.072116, (GLfloat) 0.157712, (GLfloat) - 0.984848,
+       (GLfloat) 0.305019, (GLfloat) 0.420960, (GLfloat) - 0.854258,
+       (GLfloat) 0.309443, (GLfloat) 0.419398, (GLfloat) - 0.853434,
+       (GLfloat) - 0.557133, (GLfloat) - 0.173326, (GLfloat) - 0.812134,
+       (GLfloat) - 0.548436, (GLfloat) - 0.209256, (GLfloat) - 0.809586,
+       (GLfloat) - 0.417652, (GLfloat) - 0.317957, (GLfloat) - 0.851158,
+       (GLfloat) - 0.412553, (GLfloat) - 0.327906, (GLfloat) - 0.849869,
+       (GLfloat) - 0.160469, (GLfloat) - 0.081504, (GLfloat) - 0.983670,
+       (GLfloat) - 0.161493, (GLfloat) - 0.079455, (GLfloat) - 0.983670,
+       (GLfloat) - 0.281454, (GLfloat) 0.011196, (GLfloat) - 0.959509,
+       (GLfloat) - 0.287811, (GLfloat) 0.033884, (GLfloat) - 0.957088,
+       (GLfloat) 0.576854, (GLfloat) - 0.777370, (GLfloat) - 0.250869,
+       (GLfloat) 0.569572, (GLfloat) - 0.770539, (GLfloat) - 0.286108,
+       (GLfloat) 0.653090, (GLfloat) - 0.688670, (GLfloat) - 0.314971,
+       (GLfloat) 0.661058, (GLfloat) - 0.685633, (GLfloat) - 0.304812,
+       (GLfloat) 0.351164, (GLfloat) - 0.495655, (GLfloat) - 0.794362,
+       (GLfloat) 0.308874, (GLfloat) - 0.483661, (GLfloat) - 0.818944,
+       (GLfloat) 0.204308, (GLfloat) - 0.721597, (GLfloat) - 0.661480,
+       (GLfloat) 0.158422, (GLfloat) - 0.717393, (GLfloat) - 0.678418,
+       (GLfloat) 0.823611, (GLfloat) - 0.501936, (GLfloat) - 0.264055,
+       (GLfloat) 0.833765, (GLfloat) - 0.473703, (GLfloat) - 0.283621,
+       (GLfloat) 0.731077, (GLfloat) - 0.100384, (GLfloat) - 0.674869,
+       (GLfloat) 0.725771, (GLfloat) - 0.074392, (GLfloat) - 0.683902,
+       (GLfloat) 0.515479, (GLfloat) - 0.259037, (GLfloat) - 0.816812,
+       (GLfloat) 0.524744, (GLfloat) - 0.282163, (GLfloat) - 0.803136,
+       (GLfloat) 0.753164, (GLfloat) - 0.577527, (GLfloat) - 0.314971,
+       (GLfloat) 0.750976, (GLfloat) - 0.585768, (GLfloat) - 0.304813,
+       (GLfloat) 0.639601, (GLfloat) - 0.758638, (GLfloat) 0.124011,
+       (GLfloat) 0.647491, (GLfloat) - 0.749875, (GLfloat) 0.135802,
+       (GLfloat) 0.708617, (GLfloat) - 0.697026, (GLfloat) 0.109621,
+       (GLfloat) 0.711116, (GLfloat) - 0.693654, (GLfloat) 0.114709,
+       (GLfloat) 0.722217, (GLfloat) - 0.690875, (GLfloat) 0.033080,
+       (GLfloat) 0.720265, (GLfloat) - 0.693043, (GLfloat) 0.030163,
+       (GLfloat) 0.664597, (GLfloat) - 0.745915, (GLfloat) 0.043834,
+       (GLfloat) 0.660896, (GLfloat) - 0.749429, (GLfloat) 0.039656,
+       (GLfloat) 0.813450, (GLfloat) - 0.565559, (GLfloat) 0.135803,
+       (GLfloat) 0.821340, (GLfloat) - 0.556796, (GLfloat) 0.124011,
+       (GLfloat) 0.811298, (GLfloat) - 0.582987, (GLfloat) 0.043835,
+       (GLfloat) 0.814407, (GLfloat) - 0.578938, (GLfloat) 0.039656,
+       (GLfloat) 0.764534, (GLfloat) - 0.643877, (GLfloat) 0.030163,
+       (GLfloat) 0.762583, (GLfloat) - 0.646044, (GLfloat) 0.033079,
+       (GLfloat) 0.767278, (GLfloat) - 0.631876, (GLfloat) 0.109621,
+       (GLfloat) 0.764186, (GLfloat) - 0.634714, (GLfloat) 0.114709,
+       (GLfloat) 0.821340, (GLfloat) - 0.556796, (GLfloat) - 0.124011,
+       (GLfloat) 0.813450, (GLfloat) - 0.565559, (GLfloat) - 0.135803,
+       (GLfloat) 0.767278, (GLfloat) - 0.631876, (GLfloat) - 0.109621,
+       (GLfloat) 0.764186, (GLfloat) - 0.634714, (GLfloat) - 0.114709,
+       (GLfloat) 0.762583, (GLfloat) - 0.646044, (GLfloat) - 0.033079,
+       (GLfloat) 0.764534, (GLfloat) - 0.643877, (GLfloat) - 0.030163,
+       (GLfloat) 0.811298, (GLfloat) - 0.582987, (GLfloat) - 0.043835,
+       (GLfloat) 0.814407, (GLfloat) - 0.578938, (GLfloat) - 0.039656,
+       (GLfloat) 0.647491, (GLfloat) - 0.749875, (GLfloat) - 0.135802,
+       (GLfloat) 0.639601, (GLfloat) - 0.758638, (GLfloat) - 0.124011,
+       (GLfloat) 0.664597, (GLfloat) - 0.745915, (GLfloat) - 0.043834,
+       (GLfloat) 0.660896, (GLfloat) - 0.749429, (GLfloat) - 0.039656,
+       (GLfloat) 0.720265, (GLfloat) - 0.693043, (GLfloat) - 0.030163,
+       (GLfloat) 0.722217, (GLfloat) - 0.690875, (GLfloat) - 0.033080,
+       (GLfloat) 0.708617, (GLfloat) - 0.697026, (GLfloat) - 0.109621,
+       (GLfloat) 0.711116, (GLfloat) - 0.693654, (GLfloat) - 0.114709,
+       (GLfloat) - 0.795834, (GLfloat) - 0.416890, (GLfloat) - 0.439148,
+       (GLfloat) - 0.804928, (GLfloat) - 0.376107, (GLfloat) - 0.458949,
+       (GLfloat) - 0.777496, (GLfloat) - 0.478056, (GLfloat) - 0.408610,
+       (GLfloat) - 0.791178, (GLfloat) - 0.423850, (GLfloat) - 0.440894,
+       (GLfloat) - 0.871703, (GLfloat) - 0.470947, (GLfloat) - 0.135440,
+       (GLfloat) - 0.863971, (GLfloat) - 0.488878, (GLfloat) - 0.120637,
+       (GLfloat) - 0.890766, (GLfloat) - 0.431382, (GLfloat) - 0.142987,
+       (GLfloat) - 0.885536, (GLfloat) - 0.445027, (GLfloat) - 0.133330,
+       (GLfloat) - 0.626883, (GLfloat) - 0.701314, (GLfloat) - 0.339376,
+       (GLfloat) - 0.543140, (GLfloat) - 0.727904, (GLfloat) - 0.418515,
+       (GLfloat) - 0.684101, (GLfloat) - 0.722860, (GLfloat) - 0.097361,
+       (GLfloat) - 0.656897, (GLfloat) - 0.743919, (GLfloat) - 0.122761,
+       (GLfloat) - 0.823965, (GLfloat) - 0.552405, (GLfloat) - 0.126218,
+       (GLfloat) - 0.810821, (GLfloat) - 0.575485, (GLfloat) - 0.106707,
+       (GLfloat) - 0.722436, (GLfloat) - 0.581233, (GLfloat) - 0.374506,
+       (GLfloat) - 0.749781, (GLfloat) - 0.512777, (GLfloat) - 0.418197,
+       (GLfloat) - 0.543140, (GLfloat) - 0.727904, (GLfloat) 0.418515,
+       (GLfloat) - 0.626883, (GLfloat) - 0.701314, (GLfloat) 0.339376,
+       (GLfloat) - 0.749781, (GLfloat) - 0.512777, (GLfloat) 0.418197,
+       (GLfloat) - 0.722436, (GLfloat) - 0.581233, (GLfloat) 0.374506,
+       (GLfloat) - 0.823965, (GLfloat) - 0.552405, (GLfloat) 0.126218,
+       (GLfloat) - 0.810821, (GLfloat) - 0.575485, (GLfloat) 0.106707,
+       (GLfloat) - 0.684101, (GLfloat) - 0.722860, (GLfloat) 0.097361,
+       (GLfloat) - 0.656897, (GLfloat) - 0.743919, (GLfloat) 0.122761,
+       (GLfloat) - 0.804928, (GLfloat) - 0.376106, (GLfloat) 0.458949,
+       (GLfloat) - 0.795834, (GLfloat) - 0.416890, (GLfloat) 0.439148,
+       (GLfloat) - 0.890766, (GLfloat) - 0.431382, (GLfloat) 0.142986,
+       (GLfloat) - 0.885536, (GLfloat) - 0.445027, (GLfloat) 0.133330,
+       (GLfloat) - 0.863971, (GLfloat) - 0.488878, (GLfloat) 0.120637,
+       (GLfloat) - 0.871703, (GLfloat) - 0.470947, (GLfloat) 0.135440,
+       (GLfloat) - 0.777496, (GLfloat) - 0.478056, (GLfloat) 0.408610,
+       (GLfloat) - 0.791178, (GLfloat) - 0.423850, (GLfloat) 0.440894,
+       (GLfloat) 0.229002, (GLfloat) 0.499702, (GLfloat) - 0.835378,
+       (GLfloat) 0.231853, (GLfloat) 0.486589, (GLfloat) - 0.842304,
+       (GLfloat) 0.233876, (GLfloat) 0.516110, (GLfloat) - 0.823973,
+       (GLfloat) 0.237238, (GLfloat) 0.494666, (GLfloat) - 0.836076,
+       (GLfloat) 0.010383, (GLfloat) 0.206054, (GLfloat) - 0.978486,
+       (GLfloat) 0.010515, (GLfloat) 0.204402, (GLfloat) - 0.978831,
+       (GLfloat) - 0.008079, (GLfloat) 0.222043, (GLfloat) - 0.975003,
+       (GLfloat) - 0.007459, (GLfloat) 0.217610, (GLfloat) - 0.976007,
+       (GLfloat) 0.144536, (GLfloat) 0.600180, (GLfloat) - 0.786698,
+       (GLfloat) 0.157013, (GLfloat) 0.570113, (GLfloat) - 0.806423,
+       (GLfloat) 0.037521, (GLfloat) 0.196979, (GLfloat) - 0.979689,
+       (GLfloat) 0.033902, (GLfloat) 0.207800, (GLfloat) - 0.977584,
+       (GLfloat) 0.024105, (GLfloat) 0.197695, (GLfloat) - 0.979967,
+       (GLfloat) 0.023654, (GLfloat) 0.201010, (GLfloat) - 0.979303,
+       (GLfloat) 0.210423, (GLfloat) 0.553707, (GLfloat) - 0.805687,
+       (GLfloat) 0.216765, (GLfloat) 0.524423, (GLfloat) - 0.823404,
+       (GLfloat) - 0.387850, (GLfloat) - 0.484551, (GLfloat) - 0.784081,
+       (GLfloat) - 0.344102, (GLfloat) - 0.564354, (GLfloat) - 0.750399,
+       (GLfloat) - 0.507279, (GLfloat) - 0.348613, (GLfloat) - 0.788123,
+       (GLfloat) - 0.488679, (GLfloat) - 0.433878, (GLfloat) - 0.756930,
+       (GLfloat) - 0.209869, (GLfloat) - 0.143196, (GLfloat) - 0.967187,
+       (GLfloat) - 0.216489, (GLfloat) - 0.097461, (GLfloat) - 0.971408,
+       (GLfloat) - 0.125932, (GLfloat) - 0.202782, (GLfloat) - 0.971092,
+       (GLfloat) - 0.140256, (GLfloat) - 0.165750, (GLfloat) - 0.976143,
+       (GLfloat) - 0.549569, (GLfloat) - 0.208003, (GLfloat) - 0.809141,
+       (GLfloat) - 0.543770, (GLfloat) - 0.257592, (GLfloat) - 0.798724,
+       (GLfloat) - 0.260213, (GLfloat) - 0.033756, (GLfloat) - 0.964961,
+       (GLfloat) - 0.263665, (GLfloat) - 0.004051, (GLfloat) - 0.964606,
+       (GLfloat) - 0.243217, (GLfloat) - 0.082726, (GLfloat) - 0.966438,
+       (GLfloat) - 0.245939, (GLfloat) - 0.044154, (GLfloat) - 0.968279,
+       (GLfloat) - 0.539327, (GLfloat) - 0.261873, (GLfloat) - 0.800343,
+       (GLfloat) - 0.532344, (GLfloat) - 0.329385, (GLfloat) - 0.779818,
+       (GLfloat) 0.231853, (GLfloat) 0.486589, (GLfloat) 0.842304,
+       (GLfloat) 0.229002, (GLfloat) 0.499702, (GLfloat) 0.835378,
+       (GLfloat) - 0.008079, (GLfloat) 0.222044, (GLfloat) 0.975003,
+       (GLfloat) - 0.007460, (GLfloat) 0.217609, (GLfloat) 0.976008,
+       (GLfloat) 0.010515, (GLfloat) 0.204402, (GLfloat) 0.978830,
+       (GLfloat) 0.010383, (GLfloat) 0.206054, (GLfloat) 0.978486,
+       (GLfloat) 0.233876, (GLfloat) 0.516110, (GLfloat) 0.823973,
+       (GLfloat) 0.237238, (GLfloat) 0.494666, (GLfloat) 0.836076,
+       (GLfloat) - 0.549569, (GLfloat) - 0.208003, (GLfloat) 0.809141,
+       (GLfloat) - 0.543770, (GLfloat) - 0.257592, (GLfloat) 0.798724,
+       (GLfloat) - 0.532344, (GLfloat) - 0.329384, (GLfloat) 0.779818,
+       (GLfloat) - 0.539327, (GLfloat) - 0.261873, (GLfloat) 0.800343,
+       (GLfloat) - 0.243217, (GLfloat) - 0.082726, (GLfloat) 0.966438,
+       (GLfloat) - 0.245939, (GLfloat) - 0.044154, (GLfloat) 0.968279,
+       (GLfloat) - 0.263665, (GLfloat) - 0.004051, (GLfloat) 0.964606,
+       (GLfloat) - 0.260214, (GLfloat) - 0.033755, (GLfloat) 0.964961,
+       (GLfloat) - 0.344101, (GLfloat) - 0.564354, (GLfloat) 0.750399,
+       (GLfloat) - 0.387850, (GLfloat) - 0.484551, (GLfloat) 0.784081,
+       (GLfloat) - 0.125932, (GLfloat) - 0.202782, (GLfloat) 0.971093,
+       (GLfloat) - 0.140255, (GLfloat) - 0.165749, (GLfloat) 0.976143,
+       (GLfloat) - 0.216489, (GLfloat) - 0.097462, (GLfloat) 0.971408,
+       (GLfloat) - 0.209869, (GLfloat) - 0.143196, (GLfloat) 0.967187,
+       (GLfloat) - 0.507278, (GLfloat) - 0.348612, (GLfloat) 0.788123,
+       (GLfloat) - 0.488678, (GLfloat) - 0.433878, (GLfloat) 0.756930,
+       (GLfloat) 0.144536, (GLfloat) 0.600181, (GLfloat) 0.786697,
+       (GLfloat) 0.157013, (GLfloat) 0.570113, (GLfloat) 0.806423,
+       (GLfloat) 0.216765, (GLfloat) 0.524422, (GLfloat) 0.823404,
+       (GLfloat) 0.210423, (GLfloat) 0.553707, (GLfloat) 0.805687,
+       (GLfloat) 0.024105, (GLfloat) 0.197695, (GLfloat) 0.979967,
+       (GLfloat) 0.023654, (GLfloat) 0.201010, (GLfloat) 0.979304,
+       (GLfloat) 0.033902, (GLfloat) 0.207800, (GLfloat) 0.977584,
+       (GLfloat) 0.037522, (GLfloat) 0.196978, (GLfloat) 0.979690,
+       (GLfloat) 0.429831, (GLfloat) 0.754772, (GLfloat) - 0.495545,
+       (GLfloat) 0.445178, (GLfloat) 0.753116, (GLfloat) - 0.484389,
+       (GLfloat) 0.504382, (GLfloat) 0.849100, (GLfloat) - 0.156932,
+       (GLfloat) 0.509098, (GLfloat) 0.847167, (GLfloat) - 0.152075,
+       (GLfloat) 0.473721, (GLfloat) 0.868820, (GLfloat) - 0.144012,
+       (GLfloat) 0.467781, (GLfloat) 0.870761, (GLfloat) - 0.151512,
+       (GLfloat) 0.426275, (GLfloat) 0.776501, (GLfloat) - 0.464043,
+       (GLfloat) 0.405841, (GLfloat) 0.776082, (GLfloat) - 0.482690,
+       (GLfloat) 0.445178, (GLfloat) 0.753116, (GLfloat) 0.484389,
+       (GLfloat) 0.429830, (GLfloat) 0.754772, (GLfloat) 0.495545,
+       (GLfloat) 0.426275, (GLfloat) 0.776501, (GLfloat) 0.464043,
+       (GLfloat) 0.405841, (GLfloat) 0.776082, (GLfloat) 0.482690,
+       (GLfloat) 0.467781, (GLfloat) 0.870761, (GLfloat) 0.151512,
+       (GLfloat) 0.473721, (GLfloat) 0.868820, (GLfloat) 0.144012,
+       (GLfloat) 0.504382, (GLfloat) 0.849100, (GLfloat) 0.156932,
+       (GLfloat) 0.509098, (GLfloat) 0.847167, (GLfloat) 0.152075,
+       (GLfloat) 0.229278, (GLfloat) 0.880155, (GLfloat) 0.415643,
+       (GLfloat) 0.209637, (GLfloat) 0.873049, (GLfloat) 0.440270,
+       (GLfloat) 0.229791, (GLfloat) 0.963838, (GLfloat) 0.134951,
+       (GLfloat) 0.235661, (GLfloat) 0.963590, (GLfloat) 0.126323,
+       (GLfloat) 0.380317, (GLfloat) 0.913635, (GLfloat) 0.143628,
+       (GLfloat) 0.386968, (GLfloat) 0.912260, (GLfloat) 0.134303,
+       (GLfloat) 0.360099, (GLfloat) 0.823680, (GLfloat) 0.438041,
+       (GLfloat) 0.336980, (GLfloat) 0.819830, (GLfloat) 0.462950,
+       (GLfloat) 0.229278, (GLfloat) 0.880155, (GLfloat) - 0.415643,
+       (GLfloat) 0.209637, (GLfloat) 0.873049, (GLfloat) - 0.440270,
+       (GLfloat) 0.336980, (GLfloat) 0.819830, (GLfloat) - 0.462951,
+       (GLfloat) 0.360099, (GLfloat) 0.823680, (GLfloat) - 0.438041,
+       (GLfloat) 0.380318, (GLfloat) 0.913635, (GLfloat) - 0.143628,
+       (GLfloat) 0.386968, (GLfloat) 0.912260, (GLfloat) - 0.134303,
+       (GLfloat) 0.235661, (GLfloat) 0.963590, (GLfloat) - 0.126323,
+       (GLfloat) 0.229791, (GLfloat) 0.963838, (GLfloat) - 0.134951,
+       (GLfloat) - 0.140641, (GLfloat) 0.581880, (GLfloat) - 0.801022,
+       (GLfloat) - 0.142183, (GLfloat) 0.582121, (GLfloat) - 0.800574,
+       (GLfloat) 0.051917, (GLfloat) 0.273318, (GLfloat) - 0.960522,
+       (GLfloat) 0.034217, (GLfloat) 0.274901, (GLfloat) - 0.960864,
+       (GLfloat) 0.048940, (GLfloat) 0.249448, (GLfloat) - 0.967151,
+       (GLfloat) 0.029460, (GLfloat) 0.256714, (GLfloat) - 0.966038,
+       (GLfloat) - 0.118911, (GLfloat) 0.595461, (GLfloat) - 0.794536,
+       (GLfloat) - 0.119035, (GLfloat) 0.595511, (GLfloat) - 0.794479,
+       (GLfloat) 0.515773, (GLfloat) - 0.229138, (GLfloat) - 0.825515,
+       (GLfloat) 0.492630, (GLfloat) - 0.312368, (GLfloat) - 0.812245,
+       (GLfloat) 0.432249, (GLfloat) - 0.426645, (GLfloat) - 0.794440,
+       (GLfloat) 0.467347, (GLfloat) - 0.336981, (GLfloat) - 0.817332,
+       (GLfloat) 0.202207, (GLfloat) - 0.074217, (GLfloat) - 0.976526,
+       (GLfloat) 0.254570, (GLfloat) - 0.084963, (GLfloat) - 0.963315,
+       (GLfloat) 0.231800, (GLfloat) - 0.012060, (GLfloat) - 0.972689,
+       (GLfloat) 0.278802, (GLfloat) - 0.009127, (GLfloat) - 0.960305,
+       (GLfloat) 0.001969, (GLfloat) - 0.610219, (GLfloat) - 0.792230,
+       (GLfloat) 0.016464, (GLfloat) - 0.619478, (GLfloat) - 0.784841,
+       (GLfloat) 0.038477, (GLfloat) - 0.206205, (GLfloat) - 0.977752,
+       (GLfloat) 0.042684, (GLfloat) - 0.210618, (GLfloat) - 0.976636,
+       (GLfloat) 0.147830, (GLfloat) - 0.145929, (GLfloat) - 0.978188,
+       (GLfloat) 0.187657, (GLfloat) - 0.166867, (GLfloat) - 0.967957,
+       (GLfloat) 0.332157, (GLfloat) - 0.490109, (GLfloat) - 0.805894,
+       (GLfloat) 0.291047, (GLfloat) - 0.549638, (GLfloat) - 0.783064,
+       (GLfloat) 0.018324, (GLfloat) 0.624772, (GLfloat) - 0.780593,
+       (GLfloat) 0.031411, (GLfloat) 0.609093, (GLfloat) - 0.792477,
+       (GLfloat) - 0.068754, (GLfloat) 0.615108, (GLfloat) - 0.785439,
+       (GLfloat) - 0.063190, (GLfloat) 0.611137, (GLfloat) - 0.788999,
+       (GLfloat) 0.050001, (GLfloat) 0.227113, (GLfloat) - 0.972584,
+       (GLfloat) 0.031314, (GLfloat) 0.240630, (GLfloat) - 0.970112,
+       (GLfloat) 0.046887, (GLfloat) 0.207201, (GLfloat) - 0.977174,
+       (GLfloat) 0.034344, (GLfloat) 0.223544, (GLfloat) - 0.974089,
+       (GLfloat) - 0.289358, (GLfloat) 0.846699, (GLfloat) - 0.446512,
+       (GLfloat) - 0.282981, (GLfloat) 0.846581, (GLfloat) - 0.450803,
+       (GLfloat) - 0.237609, (GLfloat) 0.869708, (GLfloat) - 0.432607,
+       (GLfloat) - 0.232787, (GLfloat) 0.868834, (GLfloat) - 0.436964,
+       (GLfloat) - 0.269102, (GLfloat) 0.953677, (GLfloat) - 0.134480,
+       (GLfloat) - 0.270832, (GLfloat) 0.953476, (GLfloat) - 0.132414,
+       (GLfloat) - 0.330792, (GLfloat) 0.933242, (GLfloat) - 0.140129,
+       (GLfloat) - 0.333075, (GLfloat) 0.932754, (GLfloat) - 0.137953,
+       (GLfloat) 0.010415, (GLfloat) 0.905793, (GLfloat) - 0.423593,
+       (GLfloat) 0.002305, (GLfloat) 0.910958, (GLfloat) - 0.412492,
+       (GLfloat) - 0.003726, (GLfloat) 0.991671, (GLfloat) - 0.128743,
+       (GLfloat) - 0.001231, (GLfloat) 0.992167, (GLfloat) - 0.124913,
+       (GLfloat) - 0.164759, (GLfloat) 0.977931, (GLfloat) - 0.128473,
+       (GLfloat) - 0.164919, (GLfloat) 0.977933, (GLfloat) - 0.128255,
+       (GLfloat) - 0.141914, (GLfloat) 0.895522, (GLfloat) - 0.421783,
+       (GLfloat) - 0.142144, (GLfloat) 0.895607, (GLfloat) - 0.421525,
+       (GLfloat) 0.010415, (GLfloat) 0.905793, (GLfloat) 0.423593,
+       (GLfloat) 0.002305, (GLfloat) 0.910958, (GLfloat) 0.412492,
+       (GLfloat) - 0.142144, (GLfloat) 0.895607, (GLfloat) 0.421525,
+       (GLfloat) - 0.141914, (GLfloat) 0.895522, (GLfloat) 0.421783,
+       (GLfloat) - 0.164759, (GLfloat) 0.977931, (GLfloat) 0.128473,
+       (GLfloat) - 0.164919, (GLfloat) 0.977933, (GLfloat) 0.128255,
+       (GLfloat) - 0.003726, (GLfloat) 0.991671, (GLfloat) 0.128743,
+       (GLfloat) - 0.001231, (GLfloat) 0.992167, (GLfloat) 0.124913,
+       (GLfloat) - 0.282980, (GLfloat) 0.846581, (GLfloat) 0.450803,
+       (GLfloat) - 0.289358, (GLfloat) 0.846699, (GLfloat) 0.446512,
+       (GLfloat) - 0.330792, (GLfloat) 0.933242, (GLfloat) 0.140129,
+       (GLfloat) - 0.333075, (GLfloat) 0.932754, (GLfloat) 0.137953,
+       (GLfloat) - 0.270832, (GLfloat) 0.953476, (GLfloat) 0.132414,
+       (GLfloat) - 0.269102, (GLfloat) 0.953677, (GLfloat) 0.134480,
+       (GLfloat) - 0.237609, (GLfloat) 0.869708, (GLfloat) 0.432607,
+       (GLfloat) - 0.232787, (GLfloat) 0.868834, (GLfloat) 0.436964,
+       (GLfloat) - 0.140641, (GLfloat) 0.581880, (GLfloat) 0.801022,
+       (GLfloat) - 0.142183, (GLfloat) 0.582121, (GLfloat) 0.800574,
+       (GLfloat) - 0.119034, (GLfloat) 0.595511, (GLfloat) 0.794479,
+       (GLfloat) - 0.118911, (GLfloat) 0.595461, (GLfloat) 0.794536,
+       (GLfloat) 0.048939, (GLfloat) 0.249448, (GLfloat) 0.967151,
+       (GLfloat) 0.029461, (GLfloat) 0.256714, (GLfloat) 0.966038,
+       (GLfloat) 0.034217, (GLfloat) 0.274901, (GLfloat) 0.960863,
+       (GLfloat) 0.051918, (GLfloat) 0.273319, (GLfloat) 0.960521,
+       (GLfloat) 0.031411, (GLfloat) 0.609093, (GLfloat) 0.792477,
+       (GLfloat) 0.018324, (GLfloat) 0.624772, (GLfloat) 0.780593,
+       (GLfloat) 0.046887, (GLfloat) 0.207200, (GLfloat) 0.977174,
+       (GLfloat) 0.034344, (GLfloat) 0.223543, (GLfloat) 0.974089,
+       (GLfloat) 0.031314, (GLfloat) 0.240631, (GLfloat) 0.970111,
+       (GLfloat) 0.050002, (GLfloat) 0.227113, (GLfloat) 0.972584,
+       (GLfloat) - 0.068754, (GLfloat) 0.615108, (GLfloat) 0.785440,
+       (GLfloat) - 0.063191, (GLfloat) 0.611137, (GLfloat) 0.788999,
+       (GLfloat) 0.001969, (GLfloat) - 0.610219, (GLfloat) 0.792230,
+       (GLfloat) 0.016464, (GLfloat) - 0.619478, (GLfloat) 0.784841,
+       (GLfloat) 0.332157, (GLfloat) - 0.490109, (GLfloat) 0.805894,
+       (GLfloat) 0.291047, (GLfloat) - 0.549638, (GLfloat) 0.783064,
+       (GLfloat) 0.147831, (GLfloat) - 0.145929, (GLfloat) 0.978188,
+       (GLfloat) 0.187656, (GLfloat) - 0.166866, (GLfloat) 0.967957,
+       (GLfloat) 0.042684, (GLfloat) - 0.210618, (GLfloat) 0.976636,
+       (GLfloat) 0.038477, (GLfloat) - 0.206204, (GLfloat) 0.977752,
+       (GLfloat) 0.515773, (GLfloat) - 0.229138, (GLfloat) 0.825515,
+       (GLfloat) 0.492630, (GLfloat) - 0.312368, (GLfloat) 0.812245,
+       (GLfloat) 0.231801, (GLfloat) - 0.012059, (GLfloat) 0.972689,
+       (GLfloat) 0.278802, (GLfloat) - 0.009127, (GLfloat) 0.960305,
+       (GLfloat) 0.254571, (GLfloat) - 0.084963, (GLfloat) 0.963315,
+       (GLfloat) 0.202207, (GLfloat) - 0.074217, (GLfloat) 0.976527,
+       (GLfloat) 0.467347, (GLfloat) - 0.336981, (GLfloat) 0.817332,
+       (GLfloat) 0.432250, (GLfloat) - 0.426645, (GLfloat) 0.794440,
+       (GLfloat) 0.731946, (GLfloat) - 0.508941, (GLfloat) 0.453029,
+       (GLfloat) 0.760718, (GLfloat) - 0.438585, (GLfloat) 0.478489,
+       (GLfloat) 0.696013, (GLfloat) - 0.585025, (GLfloat) 0.416308,
+       (GLfloat) 0.630794, (GLfloat) - 0.620580, (GLfloat) 0.465810,
+       (GLfloat) 0.757142, (GLfloat) - 0.637420, (GLfloat) 0.142942,
+       (GLfloat) 0.737097, (GLfloat) - 0.663598, (GLfloat) 0.127771,
+       (GLfloat) 0.847507, (GLfloat) - 0.509047, (GLfloat) 0.150342,
+       (GLfloat) 0.834151, (GLfloat) - 0.533962, (GLfloat) 0.138115,
+       (GLfloat) - 0.068175, (GLfloat) - 0.903325, (GLfloat) 0.423504,
+       (GLfloat) - 0.038664, (GLfloat) - 0.911816, (GLfloat) 0.408775,
+       (GLfloat) - 0.102320, (GLfloat) - 0.986404, (GLfloat) 0.128602,
+       (GLfloat) - 0.086898, (GLfloat) - 0.988753, (GLfloat) 0.121719,
+       (GLfloat) 0.488656, (GLfloat) - 0.861887, (GLfloat) 0.135524,
+       (GLfloat) 0.510932, (GLfloat) - 0.850761, (GLfloat) 0.123102,
+       (GLfloat) 0.415769, (GLfloat) - 0.794938, (GLfloat) 0.441826,
+       (GLfloat) 0.471036, (GLfloat) - 0.782278, (GLfloat) 0.407634,
+       (GLfloat) - 0.038664, (GLfloat) - 0.911816, (GLfloat) - 0.408775,
+       (GLfloat) - 0.068174, (GLfloat) - 0.903325, (GLfloat) - 0.423504,
+       (GLfloat) 0.415769, (GLfloat) - 0.794938, (GLfloat) - 0.441826,
+       (GLfloat) 0.471037, (GLfloat) - 0.782278, (GLfloat) - 0.407634,
+       (GLfloat) 0.510932, (GLfloat) - 0.850761, (GLfloat) - 0.123102,
+       (GLfloat) 0.488656, (GLfloat) - 0.861887, (GLfloat) - 0.135524,
+       (GLfloat) - 0.102320, (GLfloat) - 0.986404, (GLfloat) - 0.128602,
+       (GLfloat) - 0.086898, (GLfloat) - 0.988753, (GLfloat) - 0.121719,
+       (GLfloat) 0.760718, (GLfloat) - 0.438585, (GLfloat) - 0.478489,
+       (GLfloat) 0.731946, (GLfloat) - 0.508941, (GLfloat) - 0.453029,
+       (GLfloat) 0.847507, (GLfloat) - 0.509047, (GLfloat) - 0.150343,
+       (GLfloat) 0.834151, (GLfloat) - 0.533962, (GLfloat) - 0.138115,
+       (GLfloat) 0.737097, (GLfloat) - 0.663599, (GLfloat) - 0.127771,
+       (GLfloat) 0.757142, (GLfloat) - 0.637420, (GLfloat) - 0.142942,
+       (GLfloat) 0.630794, (GLfloat) - 0.620580, (GLfloat) - 0.465810,
+       (GLfloat) 0.696012, (GLfloat) - 0.585025, (GLfloat) - 0.416309,
+       (GLfloat) 0.774435, (GLfloat) - 0.417338, (GLfloat) 0.475479,
+       (GLfloat) 0.793442, (GLfloat) - 0.363272, (GLfloat) 0.488348,
+       (GLfloat) 0.884471, (GLfloat) - 0.440088, (GLfloat) 0.155030,
+       (GLfloat) 0.875885, (GLfloat) - 0.459272, (GLfloat) 0.147967,
+       (GLfloat) 0.768156, (GLfloat) - 0.618465, (GLfloat) 0.165642,
+       (GLfloat) 0.757446, (GLfloat) - 0.632850, (GLfloat) 0.160551,
+       (GLfloat) 0.645602, (GLfloat) - 0.572394, (GLfloat) 0.505533,
+       (GLfloat) 0.663605, (GLfloat) - 0.543212, (GLfloat) 0.514343,
+       (GLfloat) 0.774435, (GLfloat) - 0.417338, (GLfloat) - 0.475479,
+       (GLfloat) 0.793442, (GLfloat) - 0.363271, (GLfloat) - 0.488348,
+       (GLfloat) 0.663604, (GLfloat) - 0.543213, (GLfloat) - 0.514343,
+       (GLfloat) 0.645602, (GLfloat) - 0.572394, (GLfloat) - 0.505533,
+       (GLfloat) 0.768156, (GLfloat) - 0.618465, (GLfloat) - 0.165643,
+       (GLfloat) 0.757446, (GLfloat) - 0.632850, (GLfloat) - 0.160551,
+       (GLfloat) 0.875885, (GLfloat) - 0.459272, (GLfloat) - 0.147967,
+       (GLfloat) 0.884471, (GLfloat) - 0.440088, (GLfloat) - 0.155030,
+       (GLfloat) - 0.384755, (GLfloat) - 0.899768, (GLfloat) - 0.205866,
+       (GLfloat) - 0.407035, (GLfloat) - 0.895883, (GLfloat) - 0.178092,
+       (GLfloat) - 0.367045, (GLfloat) - 0.927643, (GLfloat) - 0.068965,
+       (GLfloat) - 0.377652, (GLfloat) - 0.923053, (GLfloat) - 0.073163,
+       (GLfloat) 0.147492, (GLfloat) - 0.980758, (GLfloat) - 0.127908,
+       (GLfloat) 0.187942, (GLfloat) - 0.971451, (GLfloat) - 0.144776,
+       (GLfloat) 0.017404, (GLfloat) - 0.922933, (GLfloat) - 0.384567,
+       (GLfloat) 0.060977, (GLfloat) - 0.919535, (GLfloat) - 0.388250,
+       (GLfloat) - 0.407035, (GLfloat) - 0.895883, (GLfloat) 0.178092,
+       (GLfloat) - 0.384755, (GLfloat) - 0.899768, (GLfloat) 0.205866,
+       (GLfloat) 0.060977, (GLfloat) - 0.919535, (GLfloat) 0.388250,
+       (GLfloat) 0.017405, (GLfloat) - 0.922933, (GLfloat) 0.384568,
+       (GLfloat) 0.187942, (GLfloat) - 0.971451, (GLfloat) 0.144776,
+       (GLfloat) 0.147492, (GLfloat) - 0.980758, (GLfloat) 0.127908,
+       (GLfloat) - 0.377652, (GLfloat) - 0.923053, (GLfloat) 0.073163,
+       (GLfloat) - 0.367045, (GLfloat) - 0.927643, (GLfloat) 0.068965,
+       (GLfloat) 0.525096, (GLfloat) - 0.217383, (GLfloat) - 0.822811,
+       (GLfloat) 0.542855, (GLfloat) - 0.154089, (GLfloat) - 0.825569,
+       (GLfloat) 0.263018, (GLfloat) 0.047234, (GLfloat) - 0.963634,
+       (GLfloat) 0.298263, (GLfloat) 0.059374, (GLfloat) - 0.952635,
+       (GLfloat) 0.152826, (GLfloat) - 0.078814, (GLfloat) - 0.985105,
+       (GLfloat) 0.157225, (GLfloat) - 0.076313, (GLfloat) - 0.984610,
+       (GLfloat) 0.407888, (GLfloat) - 0.328946, (GLfloat) - 0.851717,
+       (GLfloat) 0.393565, (GLfloat) - 0.338248, (GLfloat) - 0.854807,
+       (GLfloat) - 0.131636, (GLfloat) 0.588079, (GLfloat) - 0.798019,
+       (GLfloat) - 0.131727, (GLfloat) 0.588071, (GLfloat) - 0.798011,
+       (GLfloat) - 0.280070, (GLfloat) 0.459269, (GLfloat) - 0.842990,
+       (GLfloat) - 0.285882, (GLfloat) 0.456692, (GLfloat) - 0.842439,
+       (GLfloat) - 0.064116, (GLfloat) 0.179568, (GLfloat) - 0.981654,
+       (GLfloat) - 0.067311, (GLfloat) 0.177967, (GLfloat) - 0.981732,
+       (GLfloat) 0.071348, (GLfloat) 0.308885, (GLfloat) - 0.948419,
+       (GLfloat) 0.056168, (GLfloat) 0.305937, (GLfloat) - 0.950393,
+       (GLfloat) - 0.756765, (GLfloat) - 0.603631, (GLfloat) - 0.250870,
+       (GLfloat) - 0.750192, (GLfloat) - 0.596115, (GLfloat) - 0.286110,
+       (GLfloat) - 0.661260, (GLfloat) - 0.680768, (GLfloat) - 0.315104,
+       (GLfloat) - 0.666597, (GLfloat) - 0.680599, (GLfloat) - 0.304029,
+       (GLfloat) - 0.487239, (GLfloat) - 0.360038, (GLfloat) - 0.795595,
+       (GLfloat) - 0.481713, (GLfloat) - 0.339088, (GLfloat) - 0.808067,
+       (GLfloat) - 0.706427, (GLfloat) - 0.186136, (GLfloat) - 0.682872,
+       (GLfloat) - 0.704353, (GLfloat) - 0.163662, (GLfloat) - 0.690726,
+       (GLfloat) - 0.472887, (GLfloat) - 0.840626, (GLfloat) - 0.264056,
+       (GLfloat) - 0.444319, (GLfloat) - 0.849789, (GLfloat) - 0.283620,
+       (GLfloat) - 0.155246, (GLfloat) - 0.767829, (GLfloat) - 0.621561,
+       (GLfloat) - 0.107581, (GLfloat) - 0.759164, (GLfloat) - 0.641947,
+       (GLfloat) - 0.262880, (GLfloat) - 0.545316, (GLfloat) - 0.795943,
+       (GLfloat) - 0.306478, (GLfloat) - 0.563718, (GLfloat) - 0.767002,
+       (GLfloat) - 0.550890, (GLfloat) - 0.772860, (GLfloat) - 0.314972,
+       (GLfloat) - 0.559203, (GLfloat) - 0.770962, (GLfloat) - 0.304813,
+       (GLfloat) - 0.296632, (GLfloat) 0.840312, (GLfloat) - 0.453745,
+       (GLfloat) - 0.291339, (GLfloat) 0.841021, (GLfloat) - 0.455856,
+       (GLfloat) - 0.347498, (GLfloat) 0.926752, (GLfloat) - 0.142743,
+       (GLfloat) - 0.349577, (GLfloat) 0.926172, (GLfloat) - 0.141427,
+       (GLfloat) - 0.528222, (GLfloat) 0.834354, (GLfloat) - 0.157592,
+       (GLfloat) - 0.534297, (GLfloat) 0.830965, (GLfloat) - 0.154997,
+       (GLfloat) - 0.477964, (GLfloat) 0.727109, (GLfloat) - 0.492812,
+       (GLfloat) - 0.464577, (GLfloat) 0.733270, (GLfloat) - 0.496471,
+       (GLfloat) - 0.296632, (GLfloat) 0.840312, (GLfloat) 0.453745,
+       (GLfloat) - 0.291339, (GLfloat) 0.841021, (GLfloat) 0.455856,
+       (GLfloat) - 0.464577, (GLfloat) 0.733270, (GLfloat) 0.496471,
+       (GLfloat) - 0.477964, (GLfloat) 0.727109, (GLfloat) 0.492812,
+       (GLfloat) - 0.528222, (GLfloat) 0.834354, (GLfloat) 0.157592,
+       (GLfloat) - 0.534297, (GLfloat) 0.830965, (GLfloat) 0.154997,
+       (GLfloat) - 0.349577, (GLfloat) 0.926172, (GLfloat) 0.141427,
+       (GLfloat) - 0.347498, (GLfloat) 0.926752, (GLfloat) 0.142743,
+       (GLfloat) - 0.819286, (GLfloat) - 0.535153, (GLfloat) 0.205866,
+       (GLfloat) - 0.811591, (GLfloat) - 0.556420, (GLfloat) 0.178092,
+       (GLfloat) - 0.849813, (GLfloat) - 0.522553, (GLfloat) 0.068965,
+       (GLfloat) - 0.843450, (GLfloat) - 0.532202, (GLfloat) 0.073162,
+       (GLfloat) - 0.975674, (GLfloat) 0.164943, (GLfloat) 0.144407,
+       (GLfloat) - 0.965143, (GLfloat) 0.206428, (GLfloat) 0.160894,
+       (GLfloat) - 0.906538, (GLfloat) 0.014845, (GLfloat) 0.421862,
+       (GLfloat) - 0.890094, (GLfloat) 0.060087, (GLfloat) 0.451800,
+       (GLfloat) - 0.811591, (GLfloat) - 0.556419, (GLfloat) - 0.178092,
+       (GLfloat) - 0.819286, (GLfloat) - 0.535153, (GLfloat) - 0.205865,
+       (GLfloat) - 0.906538, (GLfloat) 0.014844, (GLfloat) - 0.421862,
+       (GLfloat) - 0.890094, (GLfloat) 0.060087, (GLfloat) - 0.451800,
+       (GLfloat) - 0.965143, (GLfloat) 0.206428, (GLfloat) - 0.160894,
+       (GLfloat) - 0.975674, (GLfloat) 0.164943, (GLfloat) - 0.144407,
+       (GLfloat) - 0.843450, (GLfloat) - 0.532202, (GLfloat) - 0.073162,
+       (GLfloat) - 0.849813, (GLfloat) - 0.522553, (GLfloat) - 0.068965,
+       (GLfloat) - 0.131727, (GLfloat) 0.588071, (GLfloat) 0.798011,
+       (GLfloat) - 0.131636, (GLfloat) 0.588079, (GLfloat) 0.798019,
+       (GLfloat) 0.071348, (GLfloat) 0.308886, (GLfloat) 0.948419,
+       (GLfloat) 0.056168, (GLfloat) 0.305937, (GLfloat) 0.950393,
+       (GLfloat) - 0.067311, (GLfloat) 0.177967, (GLfloat) 0.981732,
+       (GLfloat) - 0.064116, (GLfloat) 0.179568, (GLfloat) 0.981654,
+       (GLfloat) - 0.280070, (GLfloat) 0.459269, (GLfloat) 0.842990,
+       (GLfloat) - 0.285882, (GLfloat) 0.456692, (GLfloat) 0.842439,
+       (GLfloat) 0.542855, (GLfloat) - 0.154089, (GLfloat) 0.825569,
+       (GLfloat) 0.525096, (GLfloat) - 0.217383, (GLfloat) 0.822811,
+       (GLfloat) 0.393565, (GLfloat) - 0.338248, (GLfloat) 0.854807,
+       (GLfloat) 0.407888, (GLfloat) - 0.328946, (GLfloat) 0.851717,
+       (GLfloat) 0.152826, (GLfloat) - 0.078814, (GLfloat) 0.985105,
+       (GLfloat) 0.157225, (GLfloat) - 0.076313, (GLfloat) 0.984610,
+       (GLfloat) 0.298263, (GLfloat) 0.059374, (GLfloat) 0.952635,
+       (GLfloat) 0.263018, (GLfloat) 0.047234, (GLfloat) 0.963634,
+       (GLfloat) - 0.444319, (GLfloat) - 0.849789, (GLfloat) 0.283620,
+       (GLfloat) - 0.472887, (GLfloat) - 0.840626, (GLfloat) 0.264055,
+       (GLfloat) - 0.550890, (GLfloat) - 0.772861, (GLfloat) 0.314972,
+       (GLfloat) - 0.559203, (GLfloat) - 0.770962, (GLfloat) 0.304813,
+       (GLfloat) - 0.306478, (GLfloat) - 0.563718, (GLfloat) 0.767003,
+       (GLfloat) - 0.262880, (GLfloat) - 0.545316, (GLfloat) 0.795943,
+       (GLfloat) - 0.155245, (GLfloat) - 0.767828, (GLfloat) 0.621562,
+       (GLfloat) - 0.107581, (GLfloat) - 0.759164, (GLfloat) 0.641947,
+       (GLfloat) - 0.756765, (GLfloat) - 0.603631, (GLfloat) 0.250869,
+       (GLfloat) - 0.750192, (GLfloat) - 0.596115, (GLfloat) 0.286110,
+       (GLfloat) - 0.706427, (GLfloat) - 0.186135, (GLfloat) 0.682873,
+       (GLfloat) - 0.704352, (GLfloat) - 0.163662, (GLfloat) 0.690726,
+       (GLfloat) - 0.481713, (GLfloat) - 0.339088, (GLfloat) 0.808067,
+       (GLfloat) - 0.487239, (GLfloat) - 0.360037, (GLfloat) 0.795595,
+       (GLfloat) - 0.666597, (GLfloat) - 0.680599, (GLfloat) 0.304029,
+       (GLfloat) - 0.661260, (GLfloat) - 0.680768, (GLfloat) 0.315104,
+       (GLfloat) - 0.527794, (GLfloat) - 0.840271, (GLfloat) - 0.124011,
+       (GLfloat) - 0.536826, (GLfloat) - 0.832691, (GLfloat) - 0.135802,
+       (GLfloat) - 0.604714, (GLfloat) - 0.788863, (GLfloat) - 0.109621,
+       (GLfloat) - 0.607657, (GLfloat) - 0.785872, (GLfloat) - 0.114709,
+       (GLfloat) - 0.619037, (GLfloat) - 0.784665, (GLfloat) - 0.033079,
+       (GLfloat) - 0.616803, (GLfloat) - 0.786539, (GLfloat) - 0.030163,
+       (GLfloat) - 0.554318, (GLfloat) - 0.831150, (GLfloat) - 0.043834,
+       (GLfloat) - 0.550163, (GLfloat) - 0.834115, (GLfloat) - 0.039656,
+       (GLfloat) - 0.726822, (GLfloat) - 0.673266, (GLfloat) - 0.135802,
+       (GLfloat) - 0.735855, (GLfloat) - 0.665687, (GLfloat) - 0.124011,
+       (GLfloat) - 0.722267, (GLfloat) - 0.690224, (GLfloat) - 0.043834,
+       (GLfloat) - 0.725908, (GLfloat) - 0.686648, (GLfloat) - 0.039656,
+       (GLfloat) - 0.667483, (GLfloat) - 0.744014, (GLfloat) - 0.030163,
+       (GLfloat) - 0.665249, (GLfloat) - 0.745888, (GLfloat) - 0.033079,
+       (GLfloat) - 0.671871, (GLfloat) - 0.732511, (GLfloat) - 0.109621,
+       (GLfloat) - 0.668414, (GLfloat) - 0.734891, (GLfloat) - 0.114709,
+       (GLfloat) - 0.735855, (GLfloat) - 0.665687, (GLfloat) 0.124011,
+       (GLfloat) - 0.726822, (GLfloat) - 0.673266, (GLfloat) 0.135802,
+       (GLfloat) - 0.671871, (GLfloat) - 0.732511, (GLfloat) 0.109621,
+       (GLfloat) - 0.668414, (GLfloat) - 0.734891, (GLfloat) 0.114709,
+       (GLfloat) - 0.665249, (GLfloat) - 0.745888, (GLfloat) 0.033079,
+       (GLfloat) - 0.667483, (GLfloat) - 0.744014, (GLfloat) 0.030163,
+       (GLfloat) - 0.722267, (GLfloat) - 0.690224, (GLfloat) 0.043834,
+       (GLfloat) - 0.725908, (GLfloat) - 0.686648, (GLfloat) 0.039656,
+       (GLfloat) - 0.536826, (GLfloat) - 0.832691, (GLfloat) 0.135802,
+       (GLfloat) - 0.527794, (GLfloat) - 0.840271, (GLfloat) 0.124011,
+       (GLfloat) - 0.554318, (GLfloat) - 0.831150, (GLfloat) 0.043834,
+       (GLfloat) - 0.550163, (GLfloat) - 0.834115, (GLfloat) 0.039656,
+       (GLfloat) - 0.616803, (GLfloat) - 0.786539, (GLfloat) 0.030163,
+       (GLfloat) - 0.619037, (GLfloat) - 0.784665, (GLfloat) 0.033079,
+       (GLfloat) - 0.604714, (GLfloat) - 0.788863, (GLfloat) 0.109621,
+       (GLfloat) - 0.607657, (GLfloat) - 0.785872, (GLfloat) 0.114709,
+};
+
+static unsigned short int s1_4_POLS[] =
+{
+      3, 82, 12, 76, 1, 3, 76, 74, 82, 1, 3, 22, 78, 74, 1, 3, 22, 74, 76, 1,
+      3, 78, 20, 80, 1, 3, 80, 74, 78, 1, 3, 28, 82, 74, 1, 3, 28, 74, 80, 1,
+      3, 88, 13, 84, 1, 3, 84, 77, 88, 1, 3, 24, 86, 77, 1, 3, 24, 77, 84, 1,
+      3, 86, 20, 78, 1, 3, 78, 77, 86, 1, 3, 22, 88, 77, 1, 3, 22, 77, 78, 1,
+      3, 14, 90, 85, 1, 3, 14, 85, 93, 1, 3, 26, 91, 85, 1, 3, 26, 85, 90, 1,
+      3, 20, 86, 85, 1, 3, 20, 85, 91, 1, 3, 86, 24, 93, 1, 3, 93, 85, 86, 1,
+      3, 15, 95, 79, 1, 3, 15, 79, 97, 1, 3, 95, 28, 80, 1, 3, 80, 79, 95, 1,
+      3, 20, 91, 79, 1, 3, 20, 79, 80, 1, 3, 26, 97, 79, 1, 3, 26, 79, 91, 1,
+    3, 13, 99, 83, 1, 3, 13, 83, 84, 1, 3, 99, 30, 101, 1, 3, 101, 83, 99, 1,
+  3, 23, 102, 83, 1, 3, 23, 83, 101, 1, 3, 102, 24, 84, 1, 3, 84, 83, 102, 1,
+       3, 16, 104, 100, 1, 3, 16, 100, 108, 1, 3, 104, 32, 106, 1, 3, 106, 100, 104, 1,
+       3, 106, 23, 101, 1, 3, 101, 100, 106, 1, 3, 30, 108, 100, 1, 3, 30, 100, 101, 1,
+       3, 17, 110, 105, 1, 3, 17, 105, 113, 1, 3, 110, 33, 111, 1, 3, 111, 105, 110, 1,
+       3, 23, 106, 105, 1, 3, 23, 105, 111, 1, 3, 106, 32, 113, 1, 3, 113, 105, 106, 1,
+  3, 114, 14, 93, 1, 3, 93, 92, 114, 1, 3, 93, 24, 102, 1, 3, 102, 92, 93, 1,
+3, 23, 111, 92, 1, 3, 23, 92, 102, 1, 3, 111, 33, 114, 1, 3, 114, 92, 111, 1,
+       3, 104, 16, 116, 1, 3, 116, 103, 104, 1, 3, 35, 118, 103, 1, 3, 35, 103, 116, 1,
+       3, 118, 31, 119, 1, 3, 119, 103, 118, 1, 3, 32, 104, 103, 1, 3, 32, 103, 119, 1,
+       3, 125, 18, 121, 1, 3, 121, 117, 125, 1, 3, 36, 123, 117, 1, 3, 36, 117, 121, 1,
+       3, 123, 31, 118, 1, 3, 118, 117, 123, 1, 3, 35, 125, 117, 1, 3, 35, 117, 118, 1,
+       3, 19, 127, 122, 1, 3, 19, 122, 130, 1, 3, 37, 128, 122, 1, 3, 37, 122, 127, 1,
+       3, 31, 123, 122, 1, 3, 31, 122, 128, 1, 3, 36, 130, 122, 1, 3, 36, 122, 123, 1,
+       3, 17, 113, 112, 1, 3, 17, 112, 131, 1, 3, 32, 119, 112, 1, 3, 32, 112, 113, 1,
+       3, 31, 128, 112, 1, 3, 31, 112, 119, 1, 3, 37, 131, 112, 1, 3, 37, 112, 128, 1,
+       3, 18, 133, 120, 1, 3, 18, 120, 121, 1, 3, 39, 134, 120, 1, 3, 39, 120, 133, 1,
+       3, 134, 27, 135, 1, 3, 135, 120, 134, 1, 3, 135, 36, 121, 1, 3, 121, 120, 135, 1,
+   3, 12, 82, 81, 1, 3, 12, 81, 138, 1, 3, 82, 28, 136, 1, 3, 136, 81, 82, 1,
+3, 27, 134, 81, 1, 3, 27, 81, 136, 1, 3, 134, 39, 138, 1, 3, 138, 81, 134, 1,
+3, 95, 15, 139, 1, 3, 139, 94, 95, 1, 3, 139, 40, 140, 1, 3, 140, 94, 139, 1,
+  3, 27, 136, 94, 1, 3, 27, 94, 140, 1, 3, 136, 28, 95, 1, 3, 95, 94, 136, 1,
+       3, 19, 130, 129, 1, 3, 19, 129, 141, 1, 3, 130, 36, 135, 1, 3, 135, 129, 130, 1,
+       3, 27, 140, 129, 1, 3, 27, 129, 135, 1, 3, 140, 40, 141, 1, 3, 141, 129, 140, 1,
+ 3, 14, 114, 89, 1, 3, 14, 89, 90, 1, 3, 114, 33, 142, 1, 3, 142, 89, 114, 1,
+  3, 25, 143, 89, 1, 3, 25, 89, 142, 1, 3, 143, 26, 90, 1, 3, 90, 89, 143, 1,
+       3, 17, 131, 109, 1, 3, 17, 109, 110, 1, 3, 131, 37, 144, 1, 3, 144, 109, 131, 1,
+       3, 25, 142, 109, 1, 3, 25, 109, 144, 1, 3, 142, 33, 110, 1, 3, 110, 109, 142, 1,
+       3, 19, 141, 126, 1, 3, 19, 126, 127, 1, 3, 141, 40, 145, 1, 3, 145, 126, 141, 1,
+       3, 25, 144, 126, 1, 3, 25, 126, 145, 1, 3, 144, 37, 127, 1, 3, 127, 126, 144, 1,
+   3, 15, 97, 96, 1, 3, 15, 96, 139, 1, 3, 97, 26, 143, 1, 3, 143, 96, 97, 1,
+3, 25, 145, 96, 1, 3, 25, 96, 143, 1, 3, 145, 40, 139, 1, 3, 139, 96, 145, 1,
+ 3, 12, 146, 75, 1, 3, 12, 75, 76, 1, 3, 146, 41, 148, 1, 3, 148, 75, 146, 1,
+  3, 21, 149, 75, 1, 3, 21, 75, 148, 1, 3, 149, 22, 76, 1, 3, 76, 75, 149, 1,
+3, 8, 151, 147, 1, 3, 8, 147, 155, 1, 3, 151, 43, 153, 1, 3, 153, 147, 151, 1,
+       3, 153, 21, 148, 1, 3, 148, 147, 153, 1, 3, 41, 155, 147, 1, 3, 41, 147, 148, 1,
+       3, 11, 157, 152, 1, 3, 11, 152, 160, 1, 3, 44, 158, 152, 1, 3, 44, 152, 157, 1,
+       3, 158, 21, 153, 1, 3, 153, 152, 158, 1, 3, 153, 43, 160, 1, 3, 160, 152, 153, 1,
+   3, 13, 88, 87, 1, 3, 13, 87, 161, 1, 3, 88, 22, 149, 1, 3, 149, 87, 88, 1,
+3, 21, 158, 87, 1, 3, 21, 87, 149, 1, 3, 158, 44, 161, 1, 3, 161, 87, 158, 1,
+       3, 18, 162, 132, 1, 3, 18, 132, 133, 1, 3, 162, 45, 164, 1, 3, 164, 132, 162, 1,
+       3, 38, 165, 132, 1, 3, 38, 132, 164, 1, 3, 165, 39, 133, 1, 3, 133, 132, 165, 1,
+       3, 170, 9, 167, 1, 3, 167, 163, 170, 1, 3, 47, 168, 163, 1, 3, 47, 163, 167, 1,
+       3, 168, 38, 164, 1, 3, 164, 163, 168, 1, 3, 45, 170, 163, 1, 3, 45, 163, 164, 1,
+3, 8, 155, 154, 1, 3, 8, 154, 173, 1, 3, 155, 41, 171, 1, 3, 171, 154, 155, 1,
+       3, 38, 168, 154, 1, 3, 38, 154, 171, 1, 3, 168, 47, 173, 1, 3, 173, 154, 168, 1,
+       3, 146, 12, 138, 1, 3, 138, 137, 146, 1, 3, 39, 165, 137, 1, 3, 39, 137, 138, 1,
+       3, 165, 38, 171, 1, 3, 171, 137, 165, 1, 3, 41, 146, 137, 1, 3, 41, 137, 171, 1,
+       3, 16, 108, 107, 1, 3, 16, 107, 177, 1, 3, 108, 30, 174, 1, 3, 174, 107, 108, 1,
+       3, 29, 176, 107, 1, 3, 29, 107, 174, 1, 3, 176, 50, 177, 1, 3, 177, 107, 176, 1,
+  3, 99, 13, 161, 1, 3, 161, 98, 99, 1, 3, 44, 178, 98, 1, 3, 44, 98, 161, 1,
+ 3, 178, 29, 174, 1, 3, 174, 98, 178, 1, 3, 30, 99, 98, 1, 3, 30, 98, 174, 1,
+       3, 11, 180, 156, 1, 3, 11, 156, 157, 1, 3, 180, 49, 181, 1, 3, 181, 156, 180, 1,
+       3, 29, 178, 156, 1, 3, 29, 156, 181, 1, 3, 178, 44, 157, 1, 3, 157, 156, 178, 1,
+       3, 185, 10, 183, 1, 3, 183, 175, 185, 1, 3, 50, 176, 175, 1, 3, 50, 175, 183, 1,
+       3, 176, 29, 181, 1, 3, 181, 175, 176, 1, 3, 49, 185, 175, 1, 3, 49, 175, 181, 1,
+       3, 18, 125, 124, 1, 3, 18, 124, 162, 1, 3, 125, 35, 186, 1, 3, 186, 124, 125, 1,
+       3, 34, 187, 124, 1, 3, 34, 124, 186, 1, 3, 187, 45, 162, 1, 3, 162, 124, 187, 1,
+       3, 16, 177, 115, 1, 3, 16, 115, 116, 1, 3, 177, 50, 188, 1, 3, 188, 115, 177, 1,
+       3, 34, 186, 115, 1, 3, 34, 115, 188, 1, 3, 186, 35, 116, 1, 3, 116, 115, 186, 1,
+       3, 183, 10, 190, 1, 3, 190, 182, 183, 1, 3, 52, 191, 182, 1, 3, 52, 182, 190, 1,
+       3, 191, 34, 188, 1, 3, 188, 182, 191, 1, 3, 50, 183, 182, 1, 3, 50, 182, 188, 1,
+       3, 193, 9, 170, 1, 3, 170, 169, 193, 1, 3, 45, 187, 169, 1, 3, 45, 169, 170, 1,
+       3, 187, 34, 191, 1, 3, 191, 169, 187, 1, 3, 52, 193, 169, 1, 3, 52, 169, 191, 1,
+       3, 201, 1, 196, 1, 3, 196, 194, 201, 1, 3, 54, 198, 194, 1, 3, 54, 194, 196, 1,
+       3, 198, 46, 199, 1, 3, 199, 194, 198, 1, 3, 56, 201, 194, 1, 3, 56, 194, 199, 1,
+       3, 206, 3, 203, 1, 3, 203, 197, 206, 1, 3, 55, 204, 197, 1, 3, 55, 197, 203, 1,
+       3, 46, 198, 197, 1, 3, 46, 197, 204, 1, 3, 198, 54, 206, 1, 3, 206, 197, 198, 1,
+       3, 208, 8, 173, 1, 3, 173, 172, 208, 1, 3, 47, 207, 172, 1, 3, 47, 172, 173, 1,
+       3, 207, 46, 204, 1, 3, 204, 172, 207, 1, 3, 204, 55, 208, 1, 3, 208, 172, 204, 1,
+3, 9, 209, 166, 1, 3, 9, 166, 167, 1, 3, 209, 56, 199, 1, 3, 199, 166, 209, 1,
+       3, 46, 207, 166, 1, 3, 46, 166, 199, 1, 3, 207, 47, 167, 1, 3, 167, 166, 207, 1,
+3, 1, 201, 200, 1, 3, 1, 200, 214, 1, 3, 201, 56, 210, 1, 3, 210, 200, 201, 1,
+       3, 51, 212, 200, 1, 3, 51, 200, 210, 1, 3, 212, 59, 214, 1, 3, 214, 200, 212, 1,
+       3, 209, 9, 193, 1, 3, 193, 192, 209, 1, 3, 193, 52, 215, 1, 3, 215, 192, 193, 1,
+       3, 215, 51, 210, 1, 3, 210, 192, 215, 1, 3, 56, 209, 192, 1, 3, 56, 192, 210, 1,
+       3, 190, 10, 216, 1, 3, 216, 189, 190, 1, 3, 57, 217, 189, 1, 3, 57, 189, 216, 1,
+       3, 217, 51, 215, 1, 3, 215, 189, 217, 1, 3, 215, 52, 190, 1, 3, 190, 189, 215, 1,
+3, 0, 219, 211, 1, 3, 0, 211, 221, 1, 3, 219, 59, 212, 1, 3, 212, 211, 219, 1,
+       3, 51, 217, 211, 1, 3, 51, 211, 212, 1, 3, 217, 57, 221, 1, 3, 221, 211, 217, 1,
+       3, 226, 0, 221, 1, 3, 221, 220, 226, 1, 3, 57, 222, 220, 1, 3, 57, 220, 221, 1,
+       3, 222, 48, 224, 1, 3, 224, 220, 222, 1, 3, 62, 226, 220, 1, 3, 62, 220, 224, 1,
+       3, 10, 185, 184, 1, 3, 10, 184, 216, 1, 3, 185, 49, 227, 1, 3, 227, 184, 185, 1,
+       3, 48, 222, 184, 1, 3, 48, 184, 227, 1, 3, 222, 57, 216, 1, 3, 216, 184, 222, 1,
+       3, 180, 11, 228, 1, 3, 228, 179, 180, 1, 3, 228, 60, 229, 1, 3, 229, 179, 228, 1,
+       3, 229, 48, 227, 1, 3, 227, 179, 229, 1, 3, 49, 180, 179, 1, 3, 49, 179, 227, 1,
+       3, 233, 2, 231, 1, 3, 231, 223, 233, 1, 3, 231, 62, 224, 1, 3, 224, 223, 231, 1,
+       3, 48, 229, 223, 1, 3, 48, 223, 224, 1, 3, 60, 233, 223, 1, 3, 60, 223, 229, 1,
+3, 2, 233, 232, 1, 3, 2, 232, 237, 1, 3, 60, 234, 232, 1, 3, 60, 232, 233, 1,
+       3, 42, 235, 232, 1, 3, 42, 232, 234, 1, 3, 235, 64, 237, 1, 3, 237, 232, 235, 1,
+       3, 11, 160, 159, 1, 3, 11, 159, 228, 1, 3, 160, 43, 238, 1, 3, 238, 159, 160, 1,
+       3, 42, 234, 159, 1, 3, 42, 159, 238, 1, 3, 234, 60, 228, 1, 3, 228, 159, 234, 1,
+3, 8, 208, 150, 1, 3, 8, 150, 151, 1, 3, 208, 55, 239, 1, 3, 239, 150, 208, 1,
+       3, 42, 238, 150, 1, 3, 42, 150, 239, 1, 3, 238, 43, 151, 1, 3, 151, 150, 238, 1,
+3, 3, 241, 202, 1, 3, 3, 202, 203, 1, 3, 241, 64, 235, 1, 3, 235, 202, 241, 1,
+       3, 42, 239, 202, 1, 3, 42, 202, 235, 1, 3, 55, 203, 202, 1, 3, 55, 202, 239, 1,
+       3, 245, 2, 237, 1, 3, 237, 236, 245, 1, 3, 64, 242, 236, 1, 3, 64, 236, 237, 1,
+       3, 242, 63, 244, 1, 3, 244, 236, 242, 1, 3, 68, 245, 236, 1, 3, 68, 236, 244, 1,
+       3, 241, 3, 246, 1, 3, 246, 240, 241, 1, 3, 65, 248, 240, 1, 3, 65, 240, 246, 1,
+       3, 248, 63, 242, 1, 3, 242, 240, 248, 1, 3, 64, 241, 240, 1, 3, 64, 240, 242, 1,
+3, 4, 250, 247, 1, 3, 4, 247, 253, 1, 3, 67, 251, 247, 1, 3, 67, 247, 250, 1,
+       3, 63, 248, 247, 1, 3, 63, 247, 251, 1, 3, 65, 253, 247, 1, 3, 65, 247, 248, 1,
+3, 7, 255, 243, 1, 3, 7, 243, 257, 1, 3, 68, 244, 243, 1, 3, 68, 243, 255, 1,
+       3, 63, 251, 243, 1, 3, 63, 243, 244, 1, 3, 67, 257, 243, 1, 3, 67, 243, 251, 1,
+3, 3, 206, 205, 1, 3, 3, 205, 246, 1, 3, 54, 258, 205, 1, 3, 54, 205, 206, 1,
+       3, 258, 53, 259, 1, 3, 259, 205, 258, 1, 3, 65, 246, 205, 1, 3, 65, 205, 259, 1,
+3, 1, 260, 195, 1, 3, 1, 195, 196, 1, 3, 260, 69, 262, 1, 3, 262, 195, 260, 1,
+       3, 53, 258, 195, 1, 3, 53, 195, 262, 1, 3, 258, 54, 196, 1, 3, 196, 195, 258, 1,
+       3, 267, 5, 264, 1, 3, 264, 261, 267, 1, 3, 70, 265, 261, 1, 3, 70, 261, 264, 1,
+       3, 53, 262, 261, 1, 3, 53, 261, 265, 1, 3, 262, 69, 267, 1, 3, 267, 261, 262, 1,
+3, 4, 253, 252, 1, 3, 4, 252, 268, 1, 3, 253, 65, 259, 1, 3, 259, 252, 253, 1,
+       3, 53, 265, 252, 1, 3, 53, 252, 259, 1, 3, 265, 70, 268, 1, 3, 268, 252, 265, 1,
+       3, 260, 1, 214, 1, 3, 214, 213, 260, 1, 3, 59, 269, 213, 1, 3, 59, 213, 214, 1,
+       3, 269, 58, 270, 1, 3, 270, 213, 269, 1, 3, 69, 260, 213, 1, 3, 69, 213, 270, 1,
+       3, 219, 0, 271, 1, 3, 271, 218, 219, 1, 3, 71, 273, 218, 1, 3, 71, 218, 271, 1,
+       3, 273, 58, 269, 1, 3, 269, 218, 273, 1, 3, 59, 219, 218, 1, 3, 59, 218, 269, 1,
+3, 6, 275, 272, 1, 3, 6, 272, 278, 1, 3, 72, 276, 272, 1, 3, 72, 272, 275, 1,
+       3, 58, 273, 272, 1, 3, 58, 272, 276, 1, 3, 273, 71, 278, 1, 3, 278, 272, 273, 1,
+3, 5, 267, 266, 1, 3, 5, 266, 279, 1, 3, 267, 69, 270, 1, 3, 270, 266, 267, 1,
+       3, 58, 276, 266, 1, 3, 58, 266, 270, 1, 3, 72, 279, 266, 1, 3, 72, 266, 276, 1,
+3, 0, 226, 225, 1, 3, 0, 225, 271, 1, 3, 226, 62, 280, 1, 3, 280, 225, 226, 1,
+       3, 61, 281, 225, 1, 3, 61, 225, 280, 1, 3, 281, 71, 271, 1, 3, 271, 225, 281, 1,
+3, 2, 245, 230, 1, 3, 2, 230, 231, 1, 3, 68, 282, 230, 1, 3, 68, 230, 245, 1,
+       3, 282, 61, 280, 1, 3, 280, 230, 282, 1, 3, 62, 231, 230, 1, 3, 62, 230, 280, 1,
+3, 7, 283, 254, 1, 3, 7, 254, 255, 1, 3, 283, 73, 284, 1, 3, 284, 254, 283, 1,
+       3, 61, 282, 254, 1, 3, 61, 254, 284, 1, 3, 282, 68, 255, 1, 3, 255, 254, 282, 1,
+       3, 285, 6, 278, 1, 3, 278, 277, 285, 1, 3, 278, 71, 281, 1, 3, 281, 277, 278, 1,
+       3, 61, 284, 277, 1, 3, 61, 277, 281, 1, 3, 73, 285, 277, 1, 3, 73, 277, 284, 1,
+3, 4, 268, 249, 1, 3, 4, 249, 250, 1, 3, 268, 70, 286, 1, 3, 286, 249, 268, 1,
+       3, 66, 287, 249, 1, 3, 66, 249, 286, 1, 3, 287, 67, 250, 1, 3, 250, 249, 287, 1,
+3, 5, 279, 263, 1, 3, 5, 263, 264, 1, 3, 279, 72, 288, 1, 3, 288, 263, 279, 1,
+       3, 66, 286, 263, 1, 3, 66, 263, 288, 1, 3, 286, 70, 264, 1, 3, 264, 263, 286, 1,
+3, 6, 285, 274, 1, 3, 6, 274, 275, 1, 3, 285, 73, 289, 1, 3, 289, 274, 285, 1,
+       3, 66, 288, 274, 1, 3, 66, 274, 289, 1, 3, 288, 72, 275, 1, 3, 275, 274, 288, 1,
+3, 7, 257, 256, 1, 3, 7, 256, 283, 1, 3, 257, 67, 287, 1, 3, 287, 256, 257, 1,
+       3, 66, 289, 256, 1, 3, 66, 256, 287, 1, 3, 289, 73, 283, 1, 3, 283, 256, 289, 1,
+
+       0
+};
+
+struct lwo  LWO_s1_4 =
+{
+       290,                    /* number of points */
+       s1_4_PNTS, s1_4_normals, s1_4_POLS, 0L
+};
+
+#endif /* MODE_sproingies */
+
+/* End of s1_4.c */
diff --git a/xlockmore-4.14/modes/glx/s1_5.c b/xlockmore-4.14/modes/glx/s1_5.c
new file mode 100644 (file)
index 0000000..f858d66
--- /dev/null
@@ -0,0 +1,1057 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)s1_5.c       4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points, polygons, and normal vectors to render "s1_5" in 3D.
+ *
+ * Generated by lw2ogl.  Link this with your program but do
+ * not edit by hand.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_sproingies
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat s1_5_PNTS[] =
+{
+       (GLfloat) 1.333479, (GLfloat) - 0.188456, (GLfloat) - 0.340079,
+       (GLfloat) 1.333479, (GLfloat) - 0.188456, (GLfloat) - 0.659921,
+       (GLfloat) 1.633195, (GLfloat) - 0.090616, (GLfloat) - 0.340079,
+       (GLfloat) 1.633195, (GLfloat) - 0.090616, (GLfloat) - 0.659921,
+       (GLfloat) 1.670754, (GLfloat) - 0.221475, (GLfloat) - 0.638667,
+       (GLfloat) 1.402870, (GLfloat) - 0.293254, (GLfloat) - 0.638667,
+       (GLfloat) 1.402870, (GLfloat) - 0.293254, (GLfloat) - 0.361333,
+       (GLfloat) 1.670754, (GLfloat) - 0.221475, (GLfloat) - 0.361333,
+       (GLfloat) 1.332183, (GLfloat) 0.266938, (GLfloat) - 0.619965,
+       (GLfloat) 1.190836, (GLfloat) 0.100363, (GLfloat) - 0.619965,
+       (GLfloat) 1.190836, (GLfloat) 0.100363, (GLfloat) - 0.380035,
+       (GLfloat) 1.332183, (GLfloat) 0.266938, (GLfloat) - 0.380035,
+       (GLfloat) 0.995497, (GLfloat) 0.593044, (GLfloat) - 0.659921,
+       (GLfloat) 0.995497, (GLfloat) 0.593044, (GLfloat) - 0.340079,
+       (GLfloat) 0.874620, (GLfloat) 0.619745, (GLfloat) - 0.361333,
+       (GLfloat) 0.874620, (GLfloat) 0.619745, (GLfloat) - 0.638667,
+       (GLfloat) 0.974692, (GLfloat) 0.281188, (GLfloat) - 0.340079,
+       (GLfloat) 0.874620, (GLfloat) 0.342412, (GLfloat) - 0.361333,
+       (GLfloat) 0.974692, (GLfloat) 0.281188, (GLfloat) - 0.659921,
+       (GLfloat) 0.874620, (GLfloat) 0.342412, (GLfloat) - 0.638667,
+       (GLfloat) 0.906869, (GLfloat) 0.713633, (GLfloat) - 0.500000,
+       (GLfloat) 1.161726, (GLfloat) 0.497346, (GLfloat) - 0.500000,
+       (GLfloat) 0.999280, (GLfloat) 0.649745, (GLfloat) - 0.500000,
+       (GLfloat) 0.905451, (GLfloat) 0.476683, (GLfloat) - 0.262505,
+       (GLfloat) 0.907098, (GLfloat) 0.650057, (GLfloat) - 0.326227,
+       (GLfloat) 0.856159, (GLfloat) 0.481079, (GLfloat) - 0.500000,
+       (GLfloat) 0.867922, (GLfloat) 0.658641, (GLfloat) - 0.500000,
+       (GLfloat) 0.905451, (GLfloat) 0.476683, (GLfloat) - 0.737495,
+       (GLfloat) 0.907098, (GLfloat) 0.650057, (GLfloat) - 0.673773,
+       (GLfloat) 1.114357, (GLfloat) 0.334395, (GLfloat) - 0.317564,
+       (GLfloat) 0.985095, (GLfloat) 0.437116, (GLfloat) - 0.281926,
+       (GLfloat) 0.904032, (GLfloat) 0.239732, (GLfloat) - 0.500000,
+       (GLfloat) 0.905018, (GLfloat) 0.303308, (GLfloat) - 0.326227,
+       (GLfloat) 0.867922, (GLfloat) 0.481079, (GLfloat) - 0.322437,
+       (GLfloat) 1.066987, (GLfloat) 0.171444, (GLfloat) - 0.500000,
+       (GLfloat) 0.970910, (GLfloat) 0.224487, (GLfloat) - 0.500000,
+       (GLfloat) 0.905018, (GLfloat) 0.303308, (GLfloat) - 0.673773,
+       (GLfloat) 0.867922, (GLfloat) 0.303516, (GLfloat) - 0.500000,
+       (GLfloat) 1.114357, (GLfloat) 0.334395, (GLfloat) - 0.682436,
+       (GLfloat) 0.985095, (GLfloat) 0.437116, (GLfloat) - 0.718074,
+       (GLfloat) 0.867922, (GLfloat) 0.481079, (GLfloat) - 0.677562,
+       (GLfloat) 1.149095, (GLfloat) 0.453892, (GLfloat) - 0.633787,
+       (GLfloat) 1.544380, (GLfloat) 0.092162, (GLfloat) - 0.500000,
+       (GLfloat) 1.357882, (GLfloat) 0.297224, (GLfloat) - 0.500000,
+       (GLfloat) 1.149095, (GLfloat) 0.453892, (GLfloat) - 0.366213,
+       (GLfloat) 1.079619, (GLfloat) 0.214898, (GLfloat) - 0.633787,
+       (GLfloat) 1.391060, (GLfloat) 0.010509, (GLfloat) - 0.682436,
+       (GLfloat) 1.261509, (GLfloat) 0.183650, (GLfloat) - 0.663589,
+       (GLfloat) 1.391060, (GLfloat) 0.010509, (GLfloat) - 0.317564,
+       (GLfloat) 1.261509, (GLfloat) 0.183650, (GLfloat) - 0.336411,
+       (GLfloat) 1.079619, (GLfloat) 0.214898, (GLfloat) - 0.366213,
+       (GLfloat) 1.237741, (GLfloat) - 0.071143, (GLfloat) - 0.500000,
+       (GLfloat) 1.165137, (GLfloat) 0.070077, (GLfloat) - 0.500000,
+       (GLfloat) 1.526344, (GLfloat) - 0.226473, (GLfloat) - 0.737495,
+       (GLfloat) 1.483337, (GLfloat) - 0.139536, (GLfloat) - 0.718074,
+       (GLfloat) 1.503495, (GLfloat) 0.070388, (GLfloat) - 0.633787,
+       (GLfloat) 1.278626, (GLfloat) - 0.049369, (GLfloat) - 0.633787,
+       (GLfloat) 1.278626, (GLfloat) - 0.049369, (GLfloat) - 0.366213,
+       (GLfloat) 1.297571, (GLfloat) - 0.288968, (GLfloat) - 0.500000,
+       (GLfloat) 1.278985, (GLfloat) - 0.206245, (GLfloat) - 0.500000,
+       (GLfloat) 1.503495, (GLfloat) 0.070388, (GLfloat) - 0.366213,
+       (GLfloat) 1.526344, (GLfloat) - 0.226473, (GLfloat) - 0.262505,
+       (GLfloat) 1.483337, (GLfloat) - 0.139536, (GLfloat) - 0.281926,
+       (GLfloat) 1.755118, (GLfloat) - 0.163978, (GLfloat) - 0.500000,
+       (GLfloat) 1.687689, (GLfloat) - 0.072827, (GLfloat) - 0.500000,
+       (GLfloat) 1.693578, (GLfloat) - 0.180157, (GLfloat) - 0.673773,
+       (GLfloat) 1.541590, (GLfloat) - 0.275196, (GLfloat) - 0.500000,
+       (GLfloat) 1.710058, (GLfloat) - 0.217878, (GLfloat) - 0.500000,
+       (GLfloat) 1.693578, (GLfloat) - 0.180157, (GLfloat) - 0.326227,
+       (GLfloat) 1.358796, (GLfloat) - 0.271614, (GLfloat) - 0.673773,
+       (GLfloat) 1.538546, (GLfloat) - 0.263835, (GLfloat) - 0.677562,
+       (GLfloat) 1.358796, (GLfloat) - 0.271614, (GLfloat) - 0.326227,
+       (GLfloat) 1.367033, (GLfloat) - 0.309791, (GLfloat) - 0.500000,
+       (GLfloat) 1.538546, (GLfloat) - 0.263835, (GLfloat) - 0.322437,
+       (GLfloat) 0.944384, (GLfloat) 0.679375, (GLfloat) - 0.593392,
+       (GLfloat) 1.071585, (GLfloat) 0.569561, (GLfloat) - 0.579959,
+       (GLfloat) 0.998334, (GLfloat) 0.635570, (GLfloat) - 0.587230,
+       (GLfloat) 0.944384, (GLfloat) 0.679375, (GLfloat) - 0.406608,
+       (GLfloat) 0.944762, (GLfloat) 0.694795, (GLfloat) - 0.500000,
+       (GLfloat) 0.883764, (GLfloat) 0.687079, (GLfloat) - 0.587500,
+       (GLfloat) 0.907078, (GLfloat) 0.697653, (GLfloat) - 0.594723,
+       (GLfloat) 0.941357, (GLfloat) 0.556014, (GLfloat) - 0.717914,
+       (GLfloat) 0.943249, (GLfloat) 0.633115, (GLfloat) - 0.671218,
+       (GLfloat) 0.941357, (GLfloat) 0.556014, (GLfloat) - 0.282086,
+       (GLfloat) 0.943249, (GLfloat) 0.633115, (GLfloat) - 0.328782,
+       (GLfloat) 0.883764, (GLfloat) 0.687079, (GLfloat) - 0.412500,
+       (GLfloat) 0.907078, (GLfloat) 0.697653, (GLfloat) - 0.405277,
+       (GLfloat) 1.071585, (GLfloat) 0.569561, (GLfloat) - 0.420041,
+       (GLfloat) 0.998334, (GLfloat) 0.635570, (GLfloat) - 0.412770,
+       (GLfloat) 0.861889, (GLfloat) 0.571579, (GLfloat) - 0.409500,
+       (GLfloat) 0.870135, (GLfloat) 0.645704, (GLfloat) - 0.417500,
+       (GLfloat) 0.882548, (GLfloat) 0.702579, (GLfloat) - 0.500000,
+       (GLfloat) 0.883764, (GLfloat) 0.568579, (GLfloat) - 0.294000,
+       (GLfloat) 0.884979, (GLfloat) 0.641954, (GLfloat) - 0.339125,
+       (GLfloat) 0.883764, (GLfloat) 0.568579, (GLfloat) - 0.706000,
+       (GLfloat) 0.884979, (GLfloat) 0.641954, (GLfloat) - 0.660875,
+       (GLfloat) 0.861889, (GLfloat) 0.571579, (GLfloat) - 0.590500,
+       (GLfloat) 0.870135, (GLfloat) 0.645704, (GLfloat) - 0.582500,
+       (GLfloat) 1.056455, (GLfloat) 0.468757, (GLfloat) - 0.313428,
+       (GLfloat) 0.990769, (GLfloat) 0.522168, (GLfloat) - 0.296464,
+       (GLfloat) 0.936818, (GLfloat) 0.370973, (GLfloat) - 0.282086,
+       (GLfloat) 0.939088, (GLfloat) 0.463494, (GLfloat) - 0.266520,
+       (GLfloat) 0.906322, (GLfloat) 0.571188, (GLfloat) - 0.278521,
+       (GLfloat) 0.933792, (GLfloat) 0.247612, (GLfloat) - 0.406608,
+       (GLfloat) 0.934927, (GLfloat) 0.293873, (GLfloat) - 0.328782,
+       (GLfloat) 0.883764, (GLfloat) 0.393579, (GLfloat) - 0.294000,
+       (GLfloat) 0.905187, (GLfloat) 0.382177, (GLfloat) - 0.278521,
+       (GLfloat) 1.033759, (GLfloat) 0.317550, (GLfloat) - 0.313428,
+       (GLfloat) 0.979421, (GLfloat) 0.352064, (GLfloat) - 0.296464,
+       (GLfloat) 0.861889, (GLfloat) 0.390579, (GLfloat) - 0.409500,
+       (GLfloat) 0.870135, (GLfloat) 0.398579, (GLfloat) - 0.335375,
+       (GLfloat) 0.882548, (GLfloat) 0.481079, (GLfloat) - 0.278500,
+       (GLfloat) 0.883764, (GLfloat) 0.275079, (GLfloat) - 0.412500,
+       (GLfloat) 0.884979, (GLfloat) 0.320204, (GLfloat) - 0.339125,
+       (GLfloat) 0.870135, (GLfloat) 0.563579, (GLfloat) - 0.335375,
+       (GLfloat) 1.018628, (GLfloat) 0.216746, (GLfloat) - 0.420041,
+       (GLfloat) 0.971855, (GLfloat) 0.238662, (GLfloat) - 0.412770,
+       (GLfloat) 0.933792, (GLfloat) 0.247612, (GLfloat) - 0.593392,
+       (GLfloat) 0.933414, (GLfloat) 0.232192, (GLfloat) - 0.500000,
+       (GLfloat) 0.904430, (GLfloat) 0.255712, (GLfloat) - 0.405277,
+       (GLfloat) 0.936818, (GLfloat) 0.370973, (GLfloat) - 0.717914,
+       (GLfloat) 0.934927, (GLfloat) 0.293873, (GLfloat) - 0.671218,
+       (GLfloat) 0.883764, (GLfloat) 0.275079, (GLfloat) - 0.587500,
+       (GLfloat) 0.904430, (GLfloat) 0.255712, (GLfloat) - 0.594723,
+       (GLfloat) 1.018628, (GLfloat) 0.216746, (GLfloat) - 0.579959,
+       (GLfloat) 0.971855, (GLfloat) 0.238662, (GLfloat) - 0.587230,
+       (GLfloat) 0.861889, (GLfloat) 0.390579, (GLfloat) - 0.590500,
+       (GLfloat) 0.870135, (GLfloat) 0.316454, (GLfloat) - 0.582500,
+       (GLfloat) 0.882548, (GLfloat) 0.259579, (GLfloat) - 0.500000,
+       (GLfloat) 0.883764, (GLfloat) 0.393579, (GLfloat) - 0.706000,
+       (GLfloat) 0.884979, (GLfloat) 0.320204, (GLfloat) - 0.660875,
+       (GLfloat) 0.870135, (GLfloat) 0.316454, (GLfloat) - 0.417500,
+       (GLfloat) 1.033759, (GLfloat) 0.317550, (GLfloat) - 0.686572,
+       (GLfloat) 0.979421, (GLfloat) 0.352064, (GLfloat) - 0.703536,
+       (GLfloat) 0.939088, (GLfloat) 0.463494, (GLfloat) - 0.733480,
+       (GLfloat) 0.905187, (GLfloat) 0.382177, (GLfloat) - 0.721479,
+       (GLfloat) 0.906322, (GLfloat) 0.571188, (GLfloat) - 0.721479,
+       (GLfloat) 1.056455, (GLfloat) 0.468757, (GLfloat) - 0.686572,
+       (GLfloat) 0.990769, (GLfloat) 0.522168, (GLfloat) - 0.703536,
+       (GLfloat) 0.870135, (GLfloat) 0.563579, (GLfloat) - 0.664625,
+       (GLfloat) 0.882548, (GLfloat) 0.481079, (GLfloat) - 0.721500,
+       (GLfloat) 0.870135, (GLfloat) 0.398579, (GLfloat) - 0.664625,
+       (GLfloat) 0.859111, (GLfloat) 0.481079, (GLfloat) - 0.402250,
+       (GLfloat) 0.859111, (GLfloat) 0.578829, (GLfloat) - 0.500000,
+       (GLfloat) 0.859111, (GLfloat) 0.383329, (GLfloat) - 0.500000,
+       (GLfloat) 0.859111, (GLfloat) 0.481079, (GLfloat) - 0.597750,
+       (GLfloat) 1.065911, (GLfloat) 0.531759, (GLfloat) - 0.646592,
+       (GLfloat) 1.253715, (GLfloat) 0.391468, (GLfloat) - 0.567669,
+       (GLfloat) 1.158568, (GLfloat) 0.486483, (GLfloat) - 0.572975,
+       (GLfloat) 1.073477, (GLfloat) 0.582162, (GLfloat) - 0.500000,
+       (GLfloat) 1.446226, (GLfloat) 0.186168, (GLfloat) - 0.567669,
+       (GLfloat) 1.351457, (GLfloat) 0.289652, (GLfloat) - 0.565436,
+       (GLfloat) 1.253715, (GLfloat) 0.391468, (GLfloat) - 0.432331,
+       (GLfloat) 1.258403, (GLfloat) 0.400600, (GLfloat) - 0.500000,
+       (GLfloat) 1.216209, (GLfloat) 0.318418, (GLfloat) - 0.657894,
+       (GLfloat) 1.239650, (GLfloat) 0.364075, (GLfloat) - 0.624059,
+       (GLfloat) 1.216209, (GLfloat) 0.318418, (GLfloat) - 0.342106,
+       (GLfloat) 1.239650, (GLfloat) 0.364075, (GLfloat) - 0.375941,
+       (GLfloat) 1.158568, (GLfloat) 0.486483, (GLfloat) - 0.427025,
+       (GLfloat) 1.446226, (GLfloat) 0.186168, (GLfloat) - 0.432331,
+       (GLfloat) 1.351457, (GLfloat) 0.289652, (GLfloat) - 0.434564,
+       (GLfloat) 1.065911, (GLfloat) 0.531759, (GLfloat) - 0.353408,
+       (GLfloat) 1.024302, (GLfloat) 0.254547, (GLfloat) - 0.646592,
+       (GLfloat) 1.159950, (GLfloat) 0.208844, (GLfloat) - 0.657894,
+       (GLfloat) 1.095409, (GLfloat) 0.269215, (GLfloat) - 0.670274,
+       (GLfloat) 1.045107, (GLfloat) 0.393153, (GLfloat) - 0.699898,
+       (GLfloat) 1.280017, (GLfloat) 0.059132, (GLfloat) - 0.657894,
+       (GLfloat) 1.222960, (GLfloat) 0.138221, (GLfloat) - 0.652683,
+       (GLfloat) 1.188080, (GLfloat) 0.263631, (GLfloat) - 0.669172,
+       (GLfloat) 1.122445, (GLfloat) 0.135794, (GLfloat) - 0.567669,
+       (GLfloat) 1.136509, (GLfloat) 0.163187, (GLfloat) - 0.624059,
+       (GLfloat) 1.133305, (GLfloat) 0.399575, (GLfloat) - 0.670274,
+       (GLfloat) 1.379742, (GLfloat) 0.135354, (GLfloat) - 0.657894,
+       (GLfloat) 1.300058, (GLfloat) 0.229080, (GLfloat) - 0.652683,
+       (GLfloat) 1.045107, (GLfloat) 0.393153, (GLfloat) - 0.300102,
+       (GLfloat) 1.159950, (GLfloat) 0.208844, (GLfloat) - 0.342106,
+       (GLfloat) 1.095409, (GLfloat) 0.269215, (GLfloat) - 0.329726,
+       (GLfloat) 1.024302, (GLfloat) 0.254547, (GLfloat) - 0.353408,
+       (GLfloat) 1.133305, (GLfloat) 0.399575, (GLfloat) - 0.329726,
+       (GLfloat) 1.379742, (GLfloat) 0.135354, (GLfloat) - 0.342106,
+       (GLfloat) 1.300058, (GLfloat) 0.229080, (GLfloat) - 0.347317,
+       (GLfloat) 1.188080, (GLfloat) 0.263631, (GLfloat) - 0.330828,
+       (GLfloat) 1.122445, (GLfloat) 0.135794, (GLfloat) - 0.432331,
+       (GLfloat) 1.136509, (GLfloat) 0.163187, (GLfloat) - 0.375941,
+       (GLfloat) 1.280017, (GLfloat) 0.059132, (GLfloat) - 0.342106,
+       (GLfloat) 1.222960, (GLfloat) 0.138221, (GLfloat) - 0.347317,
+       (GLfloat) 1.016736, (GLfloat) 0.204145, (GLfloat) - 0.500000,
+       (GLfloat) 1.070145, (GLfloat) 0.182308, (GLfloat) - 0.572975,
+       (GLfloat) 1.070145, (GLfloat) 0.182308, (GLfloat) - 0.427025,
+       (GLfloat) 1.213533, (GLfloat) 0.008318, (GLfloat) - 0.432331,
+       (GLfloat) 1.171562, (GLfloat) 0.077649, (GLfloat) - 0.434564,
+       (GLfloat) 1.117756, (GLfloat) 0.126662, (GLfloat) - 0.500000,
+       (GLfloat) 1.213533, (GLfloat) 0.008318, (GLfloat) - 0.567669,
+       (GLfloat) 1.171562, (GLfloat) 0.077649, (GLfloat) - 0.565436,
+       (GLfloat) 1.370721, (GLfloat) - 0.099359, (GLfloat) - 0.686572,
+       (GLfloat) 1.420971, (GLfloat) - 0.216460, (GLfloat) - 0.717914,
+       (GLfloat) 1.401596, (GLfloat) - 0.166219, (GLfloat) - 0.703536,
+       (GLfloat) 1.515124, (GLfloat) - 0.041541, (GLfloat) - 0.686572,
+       (GLfloat) 1.442923, (GLfloat) - 0.070450, (GLfloat) - 0.699898,
+       (GLfloat) 1.329732, (GLfloat) - 0.022152, (GLfloat) - 0.670274,
+       (GLfloat) 1.274453, (GLfloat) - 0.137904, (GLfloat) - 0.579959,
+       (GLfloat) 1.310553, (GLfloat) - 0.123450, (GLfloat) - 0.646592,
+       (GLfloat) 1.611392, (GLfloat) - 0.002996, (GLfloat) - 0.579959,
+       (GLfloat) 1.575292, (GLfloat) - 0.017451, (GLfloat) - 0.646592,
+       (GLfloat) 1.452388, (GLfloat) 0.043170, (GLfloat) - 0.670274,
+       (GLfloat) 1.599377, (GLfloat) - 0.164832, (GLfloat) - 0.717914,
+       (GLfloat) 1.565078, (GLfloat) - 0.112852, (GLfloat) - 0.703536,
+       (GLfloat) 1.329879, (GLfloat) 0.097243, (GLfloat) - 0.669172,
+       (GLfloat) 1.421294, (GLfloat) 0.167113, (GLfloat) - 0.624059,
+       (GLfloat) 1.238464, (GLfloat) 0.027373, (GLfloat) - 0.624059,
+       (GLfloat) 1.247962, (GLfloat) - 0.065700, (GLfloat) - 0.572975,
+       (GLfloat) 1.274453, (GLfloat) - 0.137904, (GLfloat) - 0.420041,
+       (GLfloat) 1.262419, (GLfloat) - 0.142723, (GLfloat) - 0.500000,
+       (GLfloat) 1.302034, (GLfloat) - 0.250880, (GLfloat) - 0.593392,
+       (GLfloat) 1.292609, (GLfloat) - 0.201797, (GLfloat) - 0.587230,
+       (GLfloat) 1.205222, (GLfloat) 0.001966, (GLfloat) - 0.500000,
+       (GLfloat) 1.238464, (GLfloat) 0.027373, (GLfloat) - 0.375941,
+       (GLfloat) 1.247962, (GLfloat) - 0.065700, (GLfloat) - 0.427025,
+       (GLfloat) 1.302034, (GLfloat) - 0.250880, (GLfloat) - 0.406608,
+       (GLfloat) 1.292609, (GLfloat) - 0.201797, (GLfloat) - 0.412770,
+       (GLfloat) 1.370721, (GLfloat) - 0.099359, (GLfloat) - 0.313428,
+       (GLfloat) 1.310553, (GLfloat) - 0.123450, (GLfloat) - 0.353408,
+       (GLfloat) 1.329732, (GLfloat) - 0.022152, (GLfloat) - 0.329726,
+       (GLfloat) 1.515124, (GLfloat) - 0.041541, (GLfloat) - 0.313428,
+       (GLfloat) 1.442923, (GLfloat) - 0.070450, (GLfloat) - 0.300102,
+       (GLfloat) 1.420971, (GLfloat) - 0.216460, (GLfloat) - 0.282086,
+       (GLfloat) 1.401596, (GLfloat) - 0.166219, (GLfloat) - 0.296464,
+       (GLfloat) 1.329879, (GLfloat) 0.097243, (GLfloat) - 0.330828,
+       (GLfloat) 1.421294, (GLfloat) 0.167113, (GLfloat) - 0.375941,
+       (GLfloat) 1.452388, (GLfloat) 0.043170, (GLfloat) - 0.329726,
+       (GLfloat) 1.599377, (GLfloat) - 0.164832, (GLfloat) - 0.282086,
+       (GLfloat) 1.565078, (GLfloat) - 0.112852, (GLfloat) - 0.296464,
+       (GLfloat) 1.611392, (GLfloat) - 0.002996, (GLfloat) - 0.420041,
+       (GLfloat) 1.575292, (GLfloat) - 0.017451, (GLfloat) - 0.353408,
+       (GLfloat) 1.534158, (GLfloat) 0.086718, (GLfloat) - 0.427025,
+       (GLfloat) 1.623426, (GLfloat) 0.001822, (GLfloat) - 0.500000,
+       (GLfloat) 1.718314, (GLfloat) - 0.130413, (GLfloat) - 0.406608,
+       (GLfloat) 1.674065, (GLfloat) - 0.077274, (GLfloat) - 0.412770,
+       (GLfloat) 1.454536, (GLfloat) 0.192520, (GLfloat) - 0.500000,
+       (GLfloat) 1.534158, (GLfloat) 0.086718, (GLfloat) - 0.572975,
+       (GLfloat) 1.718314, (GLfloat) - 0.130413, (GLfloat) - 0.593392,
+       (GLfloat) 1.674065, (GLfloat) - 0.077274, (GLfloat) - 0.587230,
+       (GLfloat) 1.733181, (GLfloat) - 0.126110, (GLfloat) - 0.500000,
+       (GLfloat) 1.733426, (GLfloat) - 0.195216, (GLfloat) - 0.412500,
+       (GLfloat) 1.739610, (GLfloat) - 0.167898, (GLfloat) - 0.405277,
+       (GLfloat) 1.673712, (GLfloat) - 0.143320, (GLfloat) - 0.328782,
+       (GLfloat) 1.673712, (GLfloat) - 0.143320, (GLfloat) - 0.671218,
+       (GLfloat) 1.733426, (GLfloat) - 0.195216, (GLfloat) - 0.587500,
+       (GLfloat) 1.739610, (GLfloat) - 0.167898, (GLfloat) - 0.594723,
+       (GLfloat) 1.627523, (GLfloat) - 0.246239, (GLfloat) - 0.590500,
+       (GLfloat) 1.696988, (GLfloat) - 0.219088, (GLfloat) - 0.582500,
+       (GLfloat) 1.748713, (GLfloat) - 0.192378, (GLfloat) - 0.500000,
+       (GLfloat) 1.618964, (GLfloat) - 0.225886, (GLfloat) - 0.706000,
+       (GLfloat) 1.689524, (GLfloat) - 0.205721, (GLfloat) - 0.660875,
+       (GLfloat) 1.618964, (GLfloat) - 0.225886, (GLfloat) - 0.294000,
+       (GLfloat) 1.689524, (GLfloat) - 0.205721, (GLfloat) - 0.339125,
+       (GLfloat) 1.627523, (GLfloat) - 0.246239, (GLfloat) - 0.409500,
+       (GLfloat) 1.696988, (GLfloat) - 0.219088, (GLfloat) - 0.417500,
+       (GLfloat) 1.510174, (GLfloat) - 0.190646, (GLfloat) - 0.733480,
+       (GLfloat) 1.617509, (GLfloat) - 0.201252, (GLfloat) - 0.721479,
+       (GLfloat) 1.346635, (GLfloat) - 0.237972, (GLfloat) - 0.671218,
+       (GLfloat) 1.449927, (GLfloat) - 0.271179, (GLfloat) - 0.706000,
+       (GLfloat) 1.435022, (GLfloat) - 0.251106, (GLfloat) - 0.721479,
+       (GLfloat) 1.452691, (GLfloat) - 0.293085, (GLfloat) - 0.590500,
+       (GLfloat) 1.458284, (GLfloat) - 0.283049, (GLfloat) - 0.664625,
+       (GLfloat) 1.534760, (GLfloat) - 0.249706, (GLfloat) - 0.721500,
+       (GLfloat) 1.335465, (GLfloat) - 0.301849, (GLfloat) - 0.587500,
+       (GLfloat) 1.378738, (GLfloat) - 0.288996, (GLfloat) - 0.660875,
+       (GLfloat) 1.617662, (GLfloat) - 0.240344, (GLfloat) - 0.664625,
+       (GLfloat) 1.287166, (GLfloat) - 0.255182, (GLfloat) - 0.500000,
+       (GLfloat) 1.312921, (GLfloat) - 0.284460, (GLfloat) - 0.594723,
+       (GLfloat) 1.346635, (GLfloat) - 0.237972, (GLfloat) - 0.328782,
+       (GLfloat) 1.335465, (GLfloat) - 0.301849, (GLfloat) - 0.412500,
+       (GLfloat) 1.312921, (GLfloat) - 0.284460, (GLfloat) - 0.405277,
+       (GLfloat) 1.452691, (GLfloat) - 0.293085, (GLfloat) - 0.409500,
+       (GLfloat) 1.378957, (GLfloat) - 0.304305, (GLfloat) - 0.417500,
+       (GLfloat) 1.320807, (GLfloat) - 0.307035, (GLfloat) - 0.500000,
+       (GLfloat) 1.449927, (GLfloat) - 0.271179, (GLfloat) - 0.294000,
+       (GLfloat) 1.378738, (GLfloat) - 0.288996, (GLfloat) - 0.339125,
+       (GLfloat) 1.378957, (GLfloat) - 0.304305, (GLfloat) - 0.582500,
+       (GLfloat) 1.510174, (GLfloat) - 0.190646, (GLfloat) - 0.266520,
+       (GLfloat) 1.435022, (GLfloat) - 0.251106, (GLfloat) - 0.278521,
+       (GLfloat) 1.617509, (GLfloat) - 0.201252, (GLfloat) - 0.278521,
+       (GLfloat) 1.617662, (GLfloat) - 0.240344, (GLfloat) - 0.335375,
+       (GLfloat) 1.534760, (GLfloat) - 0.249706, (GLfloat) - 0.278500,
+       (GLfloat) 1.458284, (GLfloat) - 0.283049, (GLfloat) - 0.335375,
+       (GLfloat) 1.540826, (GLfloat) - 0.272345, (GLfloat) - 0.597750,
+       (GLfloat) 1.635245, (GLfloat) - 0.247046, (GLfloat) - 0.500000,
+       (GLfloat) 1.446407, (GLfloat) - 0.297645, (GLfloat) - 0.500000,
+       (GLfloat) 1.540826, (GLfloat) - 0.272345, (GLfloat) - 0.402250,
+};
+
+static GLfloat s1_5_normals[] =
+{
+       (GLfloat) 0.600201, (GLfloat) 0.679955, (GLfloat) - 0.421211,
+       (GLfloat) 0.608958, (GLfloat) 0.677912, (GLfloat) - 0.411832,
+       (GLfloat) 0.631502, (GLfloat) 0.764222, (GLfloat) - 0.131036,
+       (GLfloat) 0.633915, (GLfloat) 0.762655, (GLfloat) - 0.128491,
+       (GLfloat) 0.439368, (GLfloat) 0.885949, (GLfloat) - 0.148491,
+       (GLfloat) 0.440253, (GLfloat) 0.885591, (GLfloat) - 0.148004,
+       (GLfloat) 0.401172, (GLfloat) 0.784782, (GLfloat) - 0.472417,
+       (GLfloat) 0.401344, (GLfloat) 0.784757, (GLfloat) - 0.472314,
+       (GLfloat) 0.608958, (GLfloat) 0.677912, (GLfloat) 0.411832,
+       (GLfloat) 0.600202, (GLfloat) 0.679955, (GLfloat) 0.421211,
+       (GLfloat) 0.401173, (GLfloat) 0.784782, (GLfloat) 0.472416,
+       (GLfloat) 0.401344, (GLfloat) 0.784757, (GLfloat) 0.472314,
+       (GLfloat) 0.440253, (GLfloat) 0.885591, (GLfloat) 0.148004,
+       (GLfloat) 0.439368, (GLfloat) 0.885949, (GLfloat) 0.148491,
+       (GLfloat) 0.631502, (GLfloat) 0.764222, (GLfloat) 0.131036,
+       (GLfloat) 0.633915, (GLfloat) 0.762655, (GLfloat) 0.128491,
+       (GLfloat) - 0.936578, (GLfloat) 0.283620, (GLfloat) 0.205866,
+       (GLfloat) - 0.947923, (GLfloat) 0.264055, (GLfloat) 0.178092,
+       (GLfloat) - 0.946548, (GLfloat) 0.315105, (GLfloat) 0.068965,
+       (GLfloat) - 0.949849, (GLfloat) 0.304029, (GLfloat) 0.073162,
+       (GLfloat) - 0.446501, (GLfloat) 0.882153, (GLfloat) 0.149808,
+       (GLfloat) - 0.408128, (GLfloat) 0.897939, (GLfloat) 0.164731,
+       (GLfloat) - 0.523643, (GLfloat) 0.729794, (GLfloat) 0.439543,
+       (GLfloat) - 0.481115, (GLfloat) 0.743166, (GLfloat) 0.465009,
+       (GLfloat) - 0.947923, (GLfloat) 0.264056, (GLfloat) - 0.178092,
+       (GLfloat) - 0.936578, (GLfloat) 0.283620, (GLfloat) - 0.205866,
+       (GLfloat) - 0.523644, (GLfloat) 0.729794, (GLfloat) - 0.439543,
+       (GLfloat) - 0.481115, (GLfloat) 0.743165, (GLfloat) - 0.465009,
+       (GLfloat) - 0.408128, (GLfloat) 0.897939, (GLfloat) - 0.164732,
+       (GLfloat) - 0.446501, (GLfloat) 0.882153, (GLfloat) - 0.149808,
+       (GLfloat) - 0.949849, (GLfloat) 0.304029, (GLfloat) - 0.073162,
+       (GLfloat) - 0.946548, (GLfloat) 0.315105, (GLfloat) - 0.068965,
+       (GLfloat) 0.509419, (GLfloat) 0.426080, (GLfloat) 0.747629,
+       (GLfloat) 0.498886, (GLfloat) 0.439986, (GLfloat) 0.746676,
+       (GLfloat) 0.381490, (GLfloat) 0.130964, (GLfloat) 0.915048,
+       (GLfloat) 0.367056, (GLfloat) 0.145561, (GLfloat) 0.918739,
+       (GLfloat) 0.169535, (GLfloat) 0.163155, (GLfloat) 0.971925,
+       (GLfloat) 0.178255, (GLfloat) 0.158993, (GLfloat) 0.971054,
+       (GLfloat) 0.289187, (GLfloat) 0.493355, (GLfloat) 0.820349,
+       (GLfloat) 0.295492, (GLfloat) 0.489598, (GLfloat) 0.820352,
+       (GLfloat) 0.072844, (GLfloat) - 0.526213, (GLfloat) 0.847227,
+       (GLfloat) 0.057982, (GLfloat) - 0.518213, (GLfloat) 0.853284,
+       (GLfloat) - 0.086528, (GLfloat) - 0.515478, (GLfloat) 0.852523,
+       (GLfloat) - 0.089419, (GLfloat) - 0.514364, (GLfloat) 0.852898,
+       (GLfloat) 0.052047, (GLfloat) - 0.167008, (GLfloat) 0.984581,
+       (GLfloat) 0.051822, (GLfloat) - 0.166918, (GLfloat) 0.984608,
+       (GLfloat) 0.242298, (GLfloat) - 0.179154, (GLfloat) 0.953517,
+       (GLfloat) 0.225634, (GLfloat) - 0.167006, (GLfloat) 0.959791,
+       (GLfloat) - 0.936578, (GLfloat) - 0.205866, (GLfloat) 0.283621,
+       (GLfloat) - 0.947923, (GLfloat) - 0.178092, (GLfloat) 0.264055,
+       (GLfloat) - 0.946548, (GLfloat) - 0.068965, (GLfloat) 0.315105,
+       (GLfloat) - 0.949849, (GLfloat) - 0.073162, (GLfloat) 0.304029,
+       (GLfloat) - 0.624880, (GLfloat) - 0.128758, (GLfloat) 0.770030,
+       (GLfloat) - 0.585268, (GLfloat) - 0.149307, (GLfloat) 0.796975,
+       (GLfloat) - 0.702251, (GLfloat) - 0.367360, (GLfloat) 0.609828,
+       (GLfloat) - 0.666949, (GLfloat) - 0.398310, (GLfloat) 0.629705,
+       (GLfloat) - 0.947923, (GLfloat) 0.178092, (GLfloat) 0.264055,
+       (GLfloat) - 0.936578, (GLfloat) 0.205866, (GLfloat) 0.283621,
+       (GLfloat) - 0.567140, (GLfloat) 0.430351, (GLfloat) 0.702247,
+       (GLfloat) - 0.540648, (GLfloat) 0.447171, (GLfloat) 0.712557,
+       (GLfloat) - 0.547735, (GLfloat) 0.144705, (GLfloat) 0.824043,
+       (GLfloat) - 0.571109, (GLfloat) 0.150867, (GLfloat) 0.806892,
+       (GLfloat) - 0.949849, (GLfloat) 0.073162, (GLfloat) 0.304029,
+       (GLfloat) - 0.946548, (GLfloat) 0.068965, (GLfloat) 0.315105,
+       (GLfloat) - 0.119299, (GLfloat) - 0.854945, (GLfloat) 0.504814,
+       (GLfloat) - 0.127336, (GLfloat) - 0.851794, (GLfloat) 0.508166,
+       (GLfloat) - 0.198715, (GLfloat) - 0.967024, (GLfloat) 0.159301,
+       (GLfloat) - 0.201251, (GLfloat) - 0.966323, (GLfloat) 0.160367,
+       (GLfloat) - 0.255603, (GLfloat) - 0.953134, (GLfloat) 0.161871,
+       (GLfloat) - 0.245412, (GLfloat) - 0.956309, (GLfloat) 0.158892,
+       (GLfloat) - 0.220327, (GLfloat) - 0.834921, (GLfloat) 0.504344,
+       (GLfloat) - 0.208789, (GLfloat) - 0.839323, (GLfloat) 0.501940,
+       (GLfloat) - 0.127336, (GLfloat) - 0.851794, (GLfloat) - 0.508166,
+       (GLfloat) - 0.119299, (GLfloat) - 0.854945, (GLfloat) - 0.504814,
+       (GLfloat) - 0.220327, (GLfloat) - 0.834921, (GLfloat) - 0.504344,
+       (GLfloat) - 0.208789, (GLfloat) - 0.839323, (GLfloat) - 0.501940,
+       (GLfloat) - 0.245412, (GLfloat) - 0.956309, (GLfloat) - 0.158892,
+       (GLfloat) - 0.255603, (GLfloat) - 0.953134, (GLfloat) - 0.161871,
+       (GLfloat) - 0.198715, (GLfloat) - 0.967024, (GLfloat) - 0.159301,
+       (GLfloat) - 0.201251, (GLfloat) - 0.966323, (GLfloat) - 0.160367,
+       (GLfloat) - 0.936578, (GLfloat) - 0.283621, (GLfloat) - 0.205866,
+       (GLfloat) - 0.947923, (GLfloat) - 0.264056, (GLfloat) - 0.178092,
+       (GLfloat) - 0.946548, (GLfloat) - 0.315105, (GLfloat) - 0.068965,
+       (GLfloat) - 0.949849, (GLfloat) - 0.304029, (GLfloat) - 0.073162,
+       (GLfloat) - 0.700995, (GLfloat) - 0.702740, (GLfloat) - 0.121503,
+       (GLfloat) - 0.672056, (GLfloat) - 0.727490, (GLfloat) - 0.138204,
+       (GLfloat) - 0.726368, (GLfloat) - 0.580019, (GLfloat) - 0.368737,
+       (GLfloat) - 0.700623, (GLfloat) - 0.608968, (GLfloat) - 0.371867,
+       (GLfloat) - 0.947923, (GLfloat) - 0.264056, (GLfloat) 0.178092,
+       (GLfloat) - 0.936578, (GLfloat) - 0.283621, (GLfloat) 0.205866,
+       (GLfloat) - 0.700623, (GLfloat) - 0.608968, (GLfloat) 0.371867,
+       (GLfloat) - 0.726368, (GLfloat) - 0.580019, (GLfloat) 0.368738,
+       (GLfloat) - 0.672055, (GLfloat) - 0.727490, (GLfloat) 0.138204,
+       (GLfloat) - 0.700994, (GLfloat) - 0.702740, (GLfloat) 0.121503,
+       (GLfloat) - 0.949849, (GLfloat) - 0.304029, (GLfloat) 0.073162,
+       (GLfloat) - 0.946548, (GLfloat) - 0.315105, (GLfloat) 0.068965,
+       (GLfloat) 0.072844, (GLfloat) - 0.526213, (GLfloat) - 0.847227,
+       (GLfloat) 0.057982, (GLfloat) - 0.518214, (GLfloat) - 0.853284,
+       (GLfloat) 0.225635, (GLfloat) - 0.167007, (GLfloat) - 0.959790,
+       (GLfloat) 0.242298, (GLfloat) - 0.179154, (GLfloat) - 0.953517,
+       (GLfloat) 0.052045, (GLfloat) - 0.167008, (GLfloat) - 0.984581,
+       (GLfloat) 0.051820, (GLfloat) - 0.166918, (GLfloat) - 0.984608,
+       (GLfloat) - 0.089420, (GLfloat) - 0.514364, (GLfloat) - 0.852897,
+       (GLfloat) - 0.086529, (GLfloat) - 0.515478, (GLfloat) - 0.852523,
+       (GLfloat) 0.498887, (GLfloat) 0.439986, (GLfloat) - 0.746675,
+       (GLfloat) 0.509419, (GLfloat) 0.426080, (GLfloat) - 0.747628,
+       (GLfloat) 0.289186, (GLfloat) 0.493355, (GLfloat) - 0.820349,
+       (GLfloat) 0.295491, (GLfloat) 0.489598, (GLfloat) - 0.820353,
+       (GLfloat) 0.178253, (GLfloat) 0.158994, (GLfloat) - 0.971054,
+       (GLfloat) 0.169534, (GLfloat) 0.163155, (GLfloat) - 0.971925,
+       (GLfloat) 0.381491, (GLfloat) 0.130963, (GLfloat) - 0.915048,
+       (GLfloat) 0.367056, (GLfloat) 0.145561, (GLfloat) - 0.918739,
+       (GLfloat) - 0.936578, (GLfloat) 0.205866, (GLfloat) - 0.283621,
+       (GLfloat) - 0.947923, (GLfloat) 0.178092, (GLfloat) - 0.264056,
+       (GLfloat) - 0.946548, (GLfloat) 0.068965, (GLfloat) - 0.315105,
+       (GLfloat) - 0.949849, (GLfloat) 0.073162, (GLfloat) - 0.304029,
+       (GLfloat) - 0.547736, (GLfloat) 0.144705, (GLfloat) - 0.824043,
+       (GLfloat) - 0.571109, (GLfloat) 0.150867, (GLfloat) - 0.806892,
+       (GLfloat) - 0.567141, (GLfloat) 0.430351, (GLfloat) - 0.702246,
+       (GLfloat) - 0.540648, (GLfloat) 0.447171, (GLfloat) - 0.712557,
+       (GLfloat) - 0.947923, (GLfloat) - 0.178092, (GLfloat) - 0.264056,
+       (GLfloat) - 0.936578, (GLfloat) - 0.205866, (GLfloat) - 0.283621,
+       (GLfloat) - 0.702251, (GLfloat) - 0.367360, (GLfloat) - 0.609828,
+       (GLfloat) - 0.666949, (GLfloat) - 0.398310, (GLfloat) - 0.629705,
+       (GLfloat) - 0.585269, (GLfloat) - 0.149307, (GLfloat) - 0.796974,
+       (GLfloat) - 0.624880, (GLfloat) - 0.128758, (GLfloat) - 0.770030,
+       (GLfloat) - 0.949849, (GLfloat) - 0.073162, (GLfloat) - 0.304029,
+       (GLfloat) - 0.946548, (GLfloat) - 0.068965, (GLfloat) - 0.315105,
+       (GLfloat) - 0.982944, (GLfloat) 0.135802, (GLfloat) 0.124011,
+       (GLfloat) - 0.982944, (GLfloat) 0.124011, (GLfloat) 0.135802,
+       (GLfloat) - 0.993006, (GLfloat) 0.043834, (GLfloat) 0.109621,
+       (GLfloat) - 0.992607, (GLfloat) 0.039656, (GLfloat) 0.114709,
+       (GLfloat) - 0.998998, (GLfloat) 0.030163, (GLfloat) 0.033079,
+       (GLfloat) - 0.998998, (GLfloat) 0.033079, (GLfloat) 0.030163,
+       (GLfloat) - 0.993006, (GLfloat) 0.109621, (GLfloat) 0.043834,
+       (GLfloat) - 0.992607, (GLfloat) 0.114709, (GLfloat) 0.039656,
+       (GLfloat) - 0.982944, (GLfloat) - 0.124011, (GLfloat) 0.135803,
+       (GLfloat) - 0.982944, (GLfloat) - 0.135802, (GLfloat) 0.124011,
+       (GLfloat) - 0.993006, (GLfloat) - 0.109621, (GLfloat) 0.043834,
+       (GLfloat) - 0.992607, (GLfloat) - 0.114709, (GLfloat) 0.039656,
+       (GLfloat) - 0.998998, (GLfloat) - 0.033079, (GLfloat) 0.030163,
+       (GLfloat) - 0.998998, (GLfloat) - 0.030163, (GLfloat) 0.033079,
+       (GLfloat) - 0.993006, (GLfloat) - 0.043834, (GLfloat) 0.109621,
+       (GLfloat) - 0.992607, (GLfloat) - 0.039656, (GLfloat) 0.114709,
+       (GLfloat) - 0.982944, (GLfloat) - 0.135802, (GLfloat) - 0.124011,
+       (GLfloat) - 0.982944, (GLfloat) - 0.124011, (GLfloat) - 0.135802,
+       (GLfloat) - 0.993006, (GLfloat) - 0.043834, (GLfloat) - 0.109621,
+       (GLfloat) - 0.992607, (GLfloat) - 0.039656, (GLfloat) - 0.114709,
+       (GLfloat) - 0.998998, (GLfloat) - 0.030163, (GLfloat) - 0.033079,
+       (GLfloat) - 0.998998, (GLfloat) - 0.033079, (GLfloat) - 0.030163,
+       (GLfloat) - 0.993006, (GLfloat) - 0.109621, (GLfloat) - 0.043834,
+       (GLfloat) - 0.992607, (GLfloat) - 0.114709, (GLfloat) - 0.039656,
+       (GLfloat) - 0.982944, (GLfloat) 0.124011, (GLfloat) - 0.135802,
+       (GLfloat) - 0.982944, (GLfloat) 0.135802, (GLfloat) - 0.124011,
+       (GLfloat) - 0.993006, (GLfloat) 0.109621, (GLfloat) - 0.043834,
+       (GLfloat) - 0.992607, (GLfloat) 0.114709, (GLfloat) - 0.039656,
+       (GLfloat) - 0.998998, (GLfloat) 0.033079, (GLfloat) - 0.030163,
+       (GLfloat) - 0.998998, (GLfloat) 0.030163, (GLfloat) - 0.033079,
+       (GLfloat) - 0.993006, (GLfloat) 0.043834, (GLfloat) - 0.109621,
+       (GLfloat) - 0.992607, (GLfloat) 0.039656, (GLfloat) - 0.114709,
+       (GLfloat) 0.642600, (GLfloat) 0.650149, (GLfloat) - 0.405429,
+       (GLfloat) 0.629315, (GLfloat) 0.651735, (GLfloat) - 0.423326,
+       (GLfloat) 0.650102, (GLfloat) 0.622930, (GLfloat) - 0.435116,
+       (GLfloat) 0.644794, (GLfloat) 0.639958, (GLfloat) - 0.417963,
+       (GLfloat) 0.686498, (GLfloat) 0.714292, (GLfloat) - 0.136042,
+       (GLfloat) 0.690339, (GLfloat) 0.711978, (GLfloat) - 0.128528,
+       (GLfloat) 0.670965, (GLfloat) 0.730702, (GLfloat) - 0.126017,
+       (GLfloat) 0.667564, (GLfloat) 0.732887, (GLfloat) - 0.131284,
+       (GLfloat) 0.646461, (GLfloat) 0.595725, (GLfloat) - 0.476656,
+       (GLfloat) 0.646365, (GLfloat) 0.610461, (GLfloat) - 0.457766,
+       (GLfloat) 0.713253, (GLfloat) 0.686364, (GLfloat) - 0.142034,
+       (GLfloat) 0.714947, (GLfloat) 0.683066, (GLfloat) - 0.149235,
+       (GLfloat) 0.700923, (GLfloat) 0.700421, (GLfloat) - 0.134601,
+       (GLfloat) 0.703355, (GLfloat) 0.696368, (GLfloat) - 0.142698,
+       (GLfloat) 0.650658, (GLfloat) 0.606520, (GLfloat) - 0.456922,
+       (GLfloat) 0.648063, (GLfloat) 0.624636, (GLfloat) - 0.435712,
+       (GLfloat) 0.646461, (GLfloat) 0.595725, (GLfloat) 0.476655,
+       (GLfloat) 0.646365, (GLfloat) 0.610461, (GLfloat) 0.457766,
+       (GLfloat) 0.648063, (GLfloat) 0.624636, (GLfloat) 0.435712,
+       (GLfloat) 0.650658, (GLfloat) 0.606520, (GLfloat) 0.456922,
+       (GLfloat) 0.700923, (GLfloat) 0.700421, (GLfloat) 0.134601,
+       (GLfloat) 0.703355, (GLfloat) 0.696368, (GLfloat) 0.142698,
+       (GLfloat) 0.714947, (GLfloat) 0.683066, (GLfloat) 0.149235,
+       (GLfloat) 0.713253, (GLfloat) 0.686364, (GLfloat) 0.142034,
+       (GLfloat) 0.642600, (GLfloat) 0.650149, (GLfloat) 0.405428,
+       (GLfloat) 0.629314, (GLfloat) 0.651735, (GLfloat) 0.423326,
+       (GLfloat) 0.667564, (GLfloat) 0.732887, (GLfloat) 0.131284,
+       (GLfloat) 0.670965, (GLfloat) 0.730702, (GLfloat) 0.126017,
+       (GLfloat) 0.686498, (GLfloat) 0.714292, (GLfloat) 0.136042,
+       (GLfloat) 0.690339, (GLfloat) 0.711978, (GLfloat) 0.128528,
+       (GLfloat) 0.650102, (GLfloat) 0.622930, (GLfloat) 0.435116,
+       (GLfloat) 0.644795, (GLfloat) 0.639958, (GLfloat) 0.417963,
+       (GLfloat) - 0.056496, (GLfloat) - 0.528883, (GLfloat) - 0.846813,
+       (GLfloat) - 0.064290, (GLfloat) - 0.519887, (GLfloat) - 0.851812,
+       (GLfloat) - 0.173805, (GLfloat) - 0.513816, (GLfloat) - 0.840110,
+       (GLfloat) - 0.175837, (GLfloat) - 0.508498, (GLfloat) - 0.842918,
+       (GLfloat) 0.089052, (GLfloat) - 0.185853, (GLfloat) - 0.978534,
+       (GLfloat) 0.093599, (GLfloat) - 0.208853, (GLfloat) - 0.973458,
+       (GLfloat) 0.164361, (GLfloat) - 0.176843, (GLfloat) - 0.970418,
+       (GLfloat) 0.176320, (GLfloat) - 0.196482, (GLfloat) - 0.964524,
+       (GLfloat) - 0.389065, (GLfloat) - 0.390805, (GLfloat) - 0.834206,
+       (GLfloat) - 0.391186, (GLfloat) - 0.409817, (GLfloat) - 0.824029,
+       (GLfloat) - 0.093477, (GLfloat) - 0.154476, (GLfloat) - 0.983565,
+       (GLfloat) - 0.093921, (GLfloat) - 0.156341, (GLfloat) - 0.983228,
+       (GLfloat) 0.000626, (GLfloat) - 0.183607, (GLfloat) - 0.983000,
+       (GLfloat) - 0.000487, (GLfloat) - 0.201385, (GLfloat) - 0.979512,
+       (GLfloat) - 0.285892, (GLfloat) - 0.471460, (GLfloat) - 0.834261,
+       (GLfloat) - 0.285514, (GLfloat) - 0.475831, (GLfloat) - 0.831905,
+       (GLfloat) 0.435732, (GLfloat) 0.380700, (GLfloat) - 0.815601,
+       (GLfloat) 0.428982, (GLfloat) 0.354155, (GLfloat) - 0.830993,
+       (GLfloat) 0.473609, (GLfloat) 0.392091, (GLfloat) - 0.788643,
+       (GLfloat) 0.469979, (GLfloat) 0.356952, (GLfloat) - 0.807283,
+       (GLfloat) 0.244505, (GLfloat) 0.073495, (GLfloat) - 0.966859,
+       (GLfloat) 0.248781, (GLfloat) 0.107298, (GLfloat) - 0.962598,
+       (GLfloat) 0.172068, (GLfloat) 0.089497, (GLfloat) - 0.981011,
+       (GLfloat) 0.177919, (GLfloat) 0.109952, (GLfloat) - 0.977883,
+       (GLfloat) 0.511512, (GLfloat) 0.425325, (GLfloat) - 0.746629,
+       (GLfloat) 0.520411, (GLfloat) 0.400470, (GLfloat) - 0.754185,
+       (GLfloat) 0.360534, (GLfloat) 0.109169, (GLfloat) - 0.926336,
+       (GLfloat) 0.349374, (GLfloat) 0.135180, (GLfloat) - 0.927181,
+       (GLfloat) 0.311593, (GLfloat) 0.086000, (GLfloat) - 0.946316,
+       (GLfloat) 0.308233, (GLfloat) 0.120081, (GLfloat) - 0.943702,
+       (GLfloat) 0.500412, (GLfloat) 0.409092, (GLfloat) - 0.763041,
+       (GLfloat) 0.503536, (GLfloat) 0.376115, (GLfloat) - 0.777811,
+       (GLfloat) - 0.064290, (GLfloat) - 0.519886, (GLfloat) 0.851813,
+       (GLfloat) - 0.056496, (GLfloat) - 0.528883, (GLfloat) 0.846813,
+       (GLfloat) 0.164361, (GLfloat) - 0.176843, (GLfloat) 0.970418,
+       (GLfloat) 0.176319, (GLfloat) - 0.196482, (GLfloat) 0.964524,
+       (GLfloat) 0.093599, (GLfloat) - 0.208853, (GLfloat) 0.973458,
+       (GLfloat) 0.089052, (GLfloat) - 0.185852, (GLfloat) 0.978534,
+       (GLfloat) - 0.173805, (GLfloat) - 0.513817, (GLfloat) 0.840110,
+       (GLfloat) - 0.175837, (GLfloat) - 0.508498, (GLfloat) 0.842918,
+       (GLfloat) 0.511512, (GLfloat) 0.425325, (GLfloat) 0.746629,
+       (GLfloat) 0.520411, (GLfloat) 0.400470, (GLfloat) 0.754186,
+       (GLfloat) 0.503536, (GLfloat) 0.376115, (GLfloat) 0.777810,
+       (GLfloat) 0.500412, (GLfloat) 0.409092, (GLfloat) 0.763041,
+       (GLfloat) 0.311592, (GLfloat) 0.086000, (GLfloat) 0.946316,
+       (GLfloat) 0.308233, (GLfloat) 0.120080, (GLfloat) 0.943702,
+       (GLfloat) 0.349373, (GLfloat) 0.135180, (GLfloat) 0.927181,
+       (GLfloat) 0.360533, (GLfloat) 0.109169, (GLfloat) 0.926336,
+       (GLfloat) 0.428982, (GLfloat) 0.354155, (GLfloat) 0.830993,
+       (GLfloat) 0.435731, (GLfloat) 0.380700, (GLfloat) 0.815602,
+       (GLfloat) 0.172068, (GLfloat) 0.089497, (GLfloat) 0.981011,
+       (GLfloat) 0.177918, (GLfloat) 0.109951, (GLfloat) 0.977883,
+       (GLfloat) 0.248781, (GLfloat) 0.107298, (GLfloat) 0.962598,
+       (GLfloat) 0.244505, (GLfloat) 0.073494, (GLfloat) 0.966859,
+       (GLfloat) 0.473609, (GLfloat) 0.392091, (GLfloat) 0.788643,
+       (GLfloat) 0.469979, (GLfloat) 0.356951, (GLfloat) 0.807283,
+       (GLfloat) - 0.389065, (GLfloat) - 0.390805, (GLfloat) 0.834206,
+       (GLfloat) - 0.391186, (GLfloat) - 0.409816, (GLfloat) 0.824029,
+       (GLfloat) - 0.285514, (GLfloat) - 0.475832, (GLfloat) 0.831905,
+       (GLfloat) - 0.285892, (GLfloat) - 0.471460, (GLfloat) 0.834261,
+       (GLfloat) 0.000626, (GLfloat) - 0.183607, (GLfloat) 0.983000,
+       (GLfloat) - 0.000486, (GLfloat) - 0.201385, (GLfloat) 0.979512,
+       (GLfloat) - 0.093921, (GLfloat) - 0.156340, (GLfloat) 0.983228,
+       (GLfloat) - 0.093477, (GLfloat) - 0.154476, (GLfloat) 0.983565,
+       (GLfloat) - 0.306817, (GLfloat) - 0.816247, (GLfloat) - 0.489494,
+       (GLfloat) - 0.306526, (GLfloat) - 0.816474, (GLfloat) - 0.489298,
+       (GLfloat) - 0.401007, (GLfloat) - 0.903402, (GLfloat) - 0.151850,
+       (GLfloat) - 0.400054, (GLfloat) - 0.903928, (GLfloat) - 0.151230,
+       (GLfloat) - 0.539523, (GLfloat) - 0.829080, (GLfloat) - 0.146769,
+       (GLfloat) - 0.536423, (GLfloat) - 0.831619, (GLfloat) - 0.143741,
+       (GLfloat) - 0.439125, (GLfloat) - 0.764873, (GLfloat) - 0.471315,
+       (GLfloat) - 0.443186, (GLfloat) - 0.759550, (GLfloat) - 0.476099,
+       (GLfloat) - 0.306817, (GLfloat) - 0.816247, (GLfloat) 0.489494,
+       (GLfloat) - 0.306526, (GLfloat) - 0.816474, (GLfloat) 0.489298,
+       (GLfloat) - 0.443186, (GLfloat) - 0.759550, (GLfloat) 0.476099,
+       (GLfloat) - 0.439125, (GLfloat) - 0.764873, (GLfloat) 0.471315,
+       (GLfloat) - 0.539523, (GLfloat) - 0.829080, (GLfloat) 0.146769,
+       (GLfloat) - 0.536423, (GLfloat) - 0.831619, (GLfloat) 0.143741,
+       (GLfloat) - 0.400054, (GLfloat) - 0.903928, (GLfloat) 0.151230,
+       (GLfloat) - 0.401007, (GLfloat) - 0.903402, (GLfloat) 0.151850,
+       (GLfloat) - 0.663042, (GLfloat) - 0.578347, (GLfloat) 0.475278,
+       (GLfloat) - 0.658558, (GLfloat) - 0.599157, (GLfloat) 0.455315,
+       (GLfloat) - 0.758279, (GLfloat) - 0.634927, (GLfloat) 0.147920,
+       (GLfloat) - 0.753882, (GLfloat) - 0.642163, (GLfloat) 0.138885,
+       (GLfloat) - 0.655091, (GLfloat) - 0.742671, (GLfloat) 0.138907,
+       (GLfloat) - 0.649182, (GLfloat) - 0.746545, (GLfloat) 0.145716,
+       (GLfloat) - 0.547340, (GLfloat) - 0.690985, (GLfloat) 0.472185,
+       (GLfloat) - 0.565022, (GLfloat) - 0.687356, (GLfloat) 0.456390,
+       (GLfloat) - 0.658558, (GLfloat) - 0.599157, (GLfloat) - 0.455315,
+       (GLfloat) - 0.663042, (GLfloat) - 0.578347, (GLfloat) - 0.475278,
+       (GLfloat) - 0.565022, (GLfloat) - 0.687356, (GLfloat) - 0.456390,
+       (GLfloat) - 0.547340, (GLfloat) - 0.690985, (GLfloat) - 0.472185,
+       (GLfloat) - 0.655091, (GLfloat) - 0.742671, (GLfloat) - 0.138907,
+       (GLfloat) - 0.649182, (GLfloat) - 0.746545, (GLfloat) - 0.145716,
+       (GLfloat) - 0.758279, (GLfloat) - 0.634927, (GLfloat) - 0.147920,
+       (GLfloat) - 0.753882, (GLfloat) - 0.642163, (GLfloat) - 0.138885,
+       (GLfloat) - 0.531808, (GLfloat) - 0.030854, (GLfloat) - 0.846303,
+       (GLfloat) - 0.547325, (GLfloat) - 0.021478, (GLfloat) - 0.836644,
+       (GLfloat) - 0.214400, (GLfloat) 0.129290, (GLfloat) - 0.968151,
+       (GLfloat) - 0.232550, (GLfloat) 0.136923, (GLfloat) - 0.962898,
+       (GLfloat) - 0.234685, (GLfloat) 0.079911, (GLfloat) - 0.968781,
+       (GLfloat) - 0.210181, (GLfloat) 0.075599, (GLfloat) - 0.974735,
+       (GLfloat) - 0.528653, (GLfloat) - 0.081793, (GLfloat) - 0.844888,
+       (GLfloat) - 0.538319, (GLfloat) - 0.109397, (GLfloat) - 0.835610,
+       (GLfloat) 0.375279, (GLfloat) 0.445115, (GLfloat) - 0.813043,
+       (GLfloat) 0.363044, (GLfloat) 0.448595, (GLfloat) - 0.816677,
+       (GLfloat) 0.362957, (GLfloat) 0.428038, (GLfloat) - 0.827675,
+       (GLfloat) 0.375627, (GLfloat) 0.426947, (GLfloat) - 0.822570,
+       (GLfloat) 0.060176, (GLfloat) 0.247143, (GLfloat) - 0.967109,
+       (GLfloat) 0.080139, (GLfloat) 0.245230, (GLfloat) - 0.966147,
+       (GLfloat) 0.077981, (GLfloat) 0.282100, (GLfloat) - 0.956211,
+       (GLfloat) 0.061364, (GLfloat) 0.287374, (GLfloat) - 0.955851,
+       (GLfloat) 0.394264, (GLfloat) 0.386154, (GLfloat) - 0.833931,
+       (GLfloat) 0.391969, (GLfloat) 0.379827, (GLfloat) - 0.837909,
+       (GLfloat) 0.108284, (GLfloat) 0.149184, (GLfloat) - 0.982863,
+       (GLfloat) 0.106809, (GLfloat) 0.145488, (GLfloat) - 0.983578,
+       (GLfloat) 0.087165, (GLfloat) 0.199761, (GLfloat) - 0.975960,
+       (GLfloat) 0.069423, (GLfloat) 0.198484, (GLfloat) - 0.977642,
+       (GLfloat) 0.378360, (GLfloat) 0.405238, (GLfloat) - 0.832242,
+       (GLfloat) 0.371158, (GLfloat) 0.404730, (GLfloat) - 0.835725,
+       (GLfloat) - 0.478648, (GLfloat) - 0.265386, (GLfloat) - 0.836939,
+       (GLfloat) - 0.486707, (GLfloat) - 0.296995, (GLfloat) - 0.821529,
+       (GLfloat) - 0.514523, (GLfloat) - 0.162550, (GLfloat) - 0.841929,
+       (GLfloat) - 0.525278, (GLfloat) - 0.195128, (GLfloat) - 0.828256,
+       (GLfloat) - 0.217558, (GLfloat) - 0.004195, (GLfloat) - 0.976038,
+       (GLfloat) - 0.206190, (GLfloat) 0.022881, (GLfloat) - 0.978244,
+       (GLfloat) - 0.182077, (GLfloat) - 0.080752, (GLfloat) - 0.979963,
+       (GLfloat) - 0.175153, (GLfloat) - 0.061621, (GLfloat) - 0.982611,
+       (GLfloat) - 0.843975, (GLfloat) - 0.195207, (GLfloat) - 0.499600,
+       (GLfloat) - 0.842535, (GLfloat) - 0.181717, (GLfloat) - 0.507064,
+       (GLfloat) - 0.827895, (GLfloat) - 0.272019, (GLfloat) - 0.490506,
+       (GLfloat) - 0.826118, (GLfloat) - 0.254451, (GLfloat) - 0.502777,
+       (GLfloat) - 0.933235, (GLfloat) - 0.321752, (GLfloat) - 0.159836,
+       (GLfloat) - 0.932223, (GLfloat) - 0.327025, (GLfloat) - 0.154968,
+       (GLfloat) - 0.954881, (GLfloat) - 0.249025, (GLfloat) - 0.161829,
+       (GLfloat) - 0.954307, (GLfloat) - 0.253099, (GLfloat) - 0.158871,
+       (GLfloat) - 0.754729, (GLfloat) - 0.466616, (GLfloat) - 0.461144,
+       (GLfloat) - 0.755670, (GLfloat) - 0.441894, (GLfloat) - 0.483419,
+       (GLfloat) - 0.851851, (GLfloat) - 0.501342, (GLfloat) - 0.151677,
+       (GLfloat) - 0.848780, (GLfloat) - 0.509248, (GLfloat) - 0.142264,
+       (GLfloat) - 0.902458, (GLfloat) - 0.401405, (GLfloat) - 0.156347,
+       (GLfloat) - 0.900638, (GLfloat) - 0.408254, (GLfloat) - 0.148931,
+       (GLfloat) - 0.801108, (GLfloat) - 0.337187, (GLfloat) - 0.494500,
+       (GLfloat) - 0.802422, (GLfloat) - 0.359565, (GLfloat) - 0.476269,
+       (GLfloat) - 0.754729, (GLfloat) - 0.466616, (GLfloat) 0.461144,
+       (GLfloat) - 0.755670, (GLfloat) - 0.441893, (GLfloat) 0.483419,
+       (GLfloat) - 0.802422, (GLfloat) - 0.359565, (GLfloat) 0.476269,
+       (GLfloat) - 0.801108, (GLfloat) - 0.337187, (GLfloat) 0.494500,
+       (GLfloat) - 0.902457, (GLfloat) - 0.401405, (GLfloat) 0.156348,
+       (GLfloat) - 0.900638, (GLfloat) - 0.408254, (GLfloat) 0.148931,
+       (GLfloat) - 0.848780, (GLfloat) - 0.509248, (GLfloat) 0.142264,
+       (GLfloat) - 0.851851, (GLfloat) - 0.501342, (GLfloat) 0.151677,
+       (GLfloat) - 0.842535, (GLfloat) - 0.181718, (GLfloat) 0.507064,
+       (GLfloat) - 0.843975, (GLfloat) - 0.195207, (GLfloat) 0.499600,
+       (GLfloat) - 0.954881, (GLfloat) - 0.249025, (GLfloat) 0.161829,
+       (GLfloat) - 0.954306, (GLfloat) - 0.253099, (GLfloat) 0.158871,
+       (GLfloat) - 0.932223, (GLfloat) - 0.327025, (GLfloat) 0.154968,
+       (GLfloat) - 0.933235, (GLfloat) - 0.321752, (GLfloat) 0.159836,
+       (GLfloat) - 0.827895, (GLfloat) - 0.272019, (GLfloat) 0.490506,
+       (GLfloat) - 0.826118, (GLfloat) - 0.254451, (GLfloat) 0.502777,
+       (GLfloat) - 0.547325, (GLfloat) - 0.021478, (GLfloat) 0.836644,
+       (GLfloat) - 0.531808, (GLfloat) - 0.030854, (GLfloat) 0.846303,
+       (GLfloat) - 0.538320, (GLfloat) - 0.109397, (GLfloat) 0.835610,
+       (GLfloat) - 0.528653, (GLfloat) - 0.081793, (GLfloat) 0.844888,
+       (GLfloat) - 0.210181, (GLfloat) 0.075599, (GLfloat) 0.974735,
+       (GLfloat) - 0.234685, (GLfloat) 0.079911, (GLfloat) 0.968781,
+       (GLfloat) - 0.214400, (GLfloat) 0.129290, (GLfloat) 0.968151,
+       (GLfloat) - 0.232550, (GLfloat) 0.136923, (GLfloat) 0.962898,
+       (GLfloat) - 0.486707, (GLfloat) - 0.296995, (GLfloat) 0.821529,
+       (GLfloat) - 0.478647, (GLfloat) - 0.265386, (GLfloat) 0.836939,
+       (GLfloat) - 0.182076, (GLfloat) - 0.080752, (GLfloat) 0.979963,
+       (GLfloat) - 0.175152, (GLfloat) - 0.061621, (GLfloat) 0.982611,
+       (GLfloat) - 0.206190, (GLfloat) 0.022882, (GLfloat) 0.978244,
+       (GLfloat) - 0.217558, (GLfloat) - 0.004194, (GLfloat) 0.976038,
+       (GLfloat) - 0.514523, (GLfloat) - 0.162550, (GLfloat) 0.841928,
+       (GLfloat) - 0.525277, (GLfloat) - 0.195127, (GLfloat) 0.828257,
+       (GLfloat) 0.394264, (GLfloat) 0.386154, (GLfloat) 0.833931,
+       (GLfloat) 0.391969, (GLfloat) 0.379827, (GLfloat) 0.837909,
+       (GLfloat) 0.378360, (GLfloat) 0.405238, (GLfloat) 0.832241,
+       (GLfloat) 0.371157, (GLfloat) 0.404730, (GLfloat) 0.835725,
+       (GLfloat) 0.069422, (GLfloat) 0.198484, (GLfloat) 0.977642,
+       (GLfloat) 0.087165, (GLfloat) 0.199761, (GLfloat) 0.975960,
+       (GLfloat) 0.106809, (GLfloat) 0.145488, (GLfloat) 0.983578,
+       (GLfloat) 0.108284, (GLfloat) 0.149183, (GLfloat) 0.982863,
+       (GLfloat) 0.375279, (GLfloat) 0.445115, (GLfloat) 0.813043,
+       (GLfloat) 0.363044, (GLfloat) 0.448594, (GLfloat) 0.816678,
+       (GLfloat) 0.061364, (GLfloat) 0.287374, (GLfloat) 0.955851,
+       (GLfloat) 0.077981, (GLfloat) 0.282099, (GLfloat) 0.956211,
+       (GLfloat) 0.060176, (GLfloat) 0.247143, (GLfloat) 0.967109,
+       (GLfloat) 0.080138, (GLfloat) 0.245229, (GLfloat) 0.966147,
+       (GLfloat) 0.375627, (GLfloat) 0.426947, (GLfloat) 0.822570,
+       (GLfloat) 0.362957, (GLfloat) 0.428038, (GLfloat) 0.827675,
+       (GLfloat) 0.646717, (GLfloat) 0.598054, (GLfloat) 0.473381,
+       (GLfloat) 0.647128, (GLfloat) 0.592930, (GLfloat) 0.479227,
+       (GLfloat) 0.644233, (GLfloat) 0.592287, (GLfloat) 0.483900,
+       (GLfloat) 0.644394, (GLfloat) 0.596473, (GLfloat) 0.478515,
+       (GLfloat) 0.743754, (GLfloat) 0.650774, (GLfloat) 0.152720,
+       (GLfloat) 0.743300, (GLfloat) 0.651663, (GLfloat) 0.151130,
+       (GLfloat) 0.748383, (GLfloat) 0.646124, (GLfloat) 0.149823,
+       (GLfloat) 0.749100, (GLfloat) 0.644879, (GLfloat) 0.151594,
+       (GLfloat) 0.643063, (GLfloat) 0.599196, (GLfloat) 0.476900,
+       (GLfloat) 0.642570, (GLfloat) 0.593487, (GLfloat) 0.484641,
+       (GLfloat) 0.726590, (GLfloat) 0.670731, (GLfloat) 0.148951,
+       (GLfloat) 0.727257, (GLfloat) 0.669291, (GLfloat) 0.152139,
+       (GLfloat) 0.736367, (GLfloat) 0.659214, (GLfloat) 0.152315,
+       (GLfloat) 0.736367, (GLfloat) 0.659216, (GLfloat) 0.152312,
+       (GLfloat) 0.642386, (GLfloat) 0.594552, (GLfloat) 0.483578,
+       (GLfloat) 0.642311, (GLfloat) 0.593780, (GLfloat) 0.484626,
+       (GLfloat) 0.642570, (GLfloat) 0.593487, (GLfloat) - 0.484641,
+       (GLfloat) 0.643063, (GLfloat) 0.599196, (GLfloat) - 0.476900,
+       (GLfloat) 0.642386, (GLfloat) 0.594552, (GLfloat) - 0.483577,
+       (GLfloat) 0.642311, (GLfloat) 0.593780, (GLfloat) - 0.484626,
+       (GLfloat) 0.736367, (GLfloat) 0.659216, (GLfloat) - 0.152312,
+       (GLfloat) 0.736367, (GLfloat) 0.659214, (GLfloat) - 0.152315,
+       (GLfloat) 0.726590, (GLfloat) 0.670731, (GLfloat) - 0.148951,
+       (GLfloat) 0.727257, (GLfloat) 0.669291, (GLfloat) - 0.152139,
+       (GLfloat) 0.646717, (GLfloat) 0.598054, (GLfloat) - 0.473381,
+       (GLfloat) 0.647128, (GLfloat) 0.592931, (GLfloat) - 0.479227,
+       (GLfloat) 0.749100, (GLfloat) 0.644879, (GLfloat) - 0.151594,
+       (GLfloat) 0.748383, (GLfloat) 0.646124, (GLfloat) - 0.149823,
+       (GLfloat) 0.743754, (GLfloat) 0.650774, (GLfloat) - 0.152720,
+       (GLfloat) 0.743300, (GLfloat) 0.651663, (GLfloat) - 0.151130,
+       (GLfloat) 0.644394, (GLfloat) 0.596473, (GLfloat) - 0.478515,
+       (GLfloat) 0.644234, (GLfloat) 0.592287, (GLfloat) - 0.483900,
+       (GLfloat) 0.648818, (GLfloat) 0.595244, (GLfloat) 0.474046,
+       (GLfloat) 0.647885, (GLfloat) 0.598960, (GLfloat) 0.470630,
+       (GLfloat) 0.751896, (GLfloat) 0.641953, (GLfloat) 0.150159,
+       (GLfloat) 0.751280, (GLfloat) 0.642895, (GLfloat) 0.149213,
+       (GLfloat) 0.855755, (GLfloat) 0.491872, (GLfloat) 0.160454,
+       (GLfloat) 0.854316, (GLfloat) 0.494902, (GLfloat) 0.158798,
+       (GLfloat) 0.746074, (GLfloat) 0.437172, (GLfloat) 0.502249,
+       (GLfloat) 0.745147, (GLfloat) 0.441097, (GLfloat) 0.500189,
+       (GLfloat) 0.647885, (GLfloat) 0.598960, (GLfloat) - 0.470630,
+       (GLfloat) 0.648818, (GLfloat) 0.595244, (GLfloat) - 0.474046,
+       (GLfloat) 0.746074, (GLfloat) 0.437172, (GLfloat) - 0.502249,
+       (GLfloat) 0.745147, (GLfloat) 0.441097, (GLfloat) - 0.500189,
+       (GLfloat) 0.854316, (GLfloat) 0.494902, (GLfloat) - 0.158798,
+       (GLfloat) 0.855755, (GLfloat) 0.491872, (GLfloat) - 0.160454,
+       (GLfloat) 0.751896, (GLfloat) 0.641953, (GLfloat) - 0.150159,
+       (GLfloat) 0.751280, (GLfloat) 0.642895, (GLfloat) - 0.149213,
+       (GLfloat) 0.516361, (GLfloat) - 0.831259, (GLfloat) - 0.205866,
+       (GLfloat) 0.500398, (GLfloat) - 0.847281, (GLfloat) - 0.178091,
+       (GLfloat) 0.549353, (GLfloat) - 0.832739, (GLfloat) - 0.068965,
+       (GLfloat) 0.539508, (GLfloat) - 0.838796, (GLfloat) - 0.073163,
+       (GLfloat) 0.955872, (GLfloat) - 0.254974, (GLfloat) - 0.145934,
+       (GLfloat) 0.962750, (GLfloat) - 0.217125, (GLfloat) - 0.161151,
+       (GLfloat) 0.832302, (GLfloat) - 0.349186, (GLfloat) - 0.430515,
+       (GLfloat) 0.834893, (GLfloat) - 0.309370, (GLfloat) - 0.455242,
+       (GLfloat) 0.500398, (GLfloat) - 0.847281, (GLfloat) 0.178091,
+       (GLfloat) 0.516361, (GLfloat) - 0.831259, (GLfloat) 0.205867,
+       (GLfloat) 0.832302, (GLfloat) - 0.349186, (GLfloat) 0.430515,
+       (GLfloat) 0.834893, (GLfloat) - 0.309369, (GLfloat) 0.455242,
+       (GLfloat) 0.962750, (GLfloat) - 0.217125, (GLfloat) 0.161151,
+       (GLfloat) 0.955872, (GLfloat) - 0.254973, (GLfloat) 0.145934,
+       (GLfloat) 0.539508, (GLfloat) - 0.838796, (GLfloat) 0.073163,
+       (GLfloat) 0.549353, (GLfloat) - 0.832739, (GLfloat) 0.068965,
+       (GLfloat) 0.365166, (GLfloat) 0.464177, (GLfloat) - 0.806966,
+       (GLfloat) 0.373210, (GLfloat) 0.459657, (GLfloat) - 0.805872,
+       (GLfloat) 0.064151, (GLfloat) 0.318725, (GLfloat) - 0.945674,
+       (GLfloat) 0.075117, (GLfloat) 0.311589, (GLfloat) - 0.947243,
+       (GLfloat) 0.127864, (GLfloat) 0.159455, (GLfloat) - 0.978890,
+       (GLfloat) 0.122956, (GLfloat) 0.165169, (GLfloat) - 0.978571,
+       (GLfloat) 0.446081, (GLfloat) 0.299065, (GLfloat) - 0.843547,
+       (GLfloat) 0.442539, (GLfloat) 0.302925, (GLfloat) - 0.844035,
+       (GLfloat) - 0.541197, (GLfloat) 0.047754, (GLfloat) - 0.839539,
+       (GLfloat) - 0.545743, (GLfloat) 0.029212, (GLfloat) - 0.837443,
+       (GLfloat) - 0.504199, (GLfloat) - 0.116458, (GLfloat) - 0.855699,
+       (GLfloat) - 0.503751, (GLfloat) - 0.117103, (GLfloat) - 0.855875,
+       (GLfloat) - 0.180218, (GLfloat) 0.028848, (GLfloat) - 0.983203,
+       (GLfloat) - 0.179757, (GLfloat) 0.028254, (GLfloat) - 0.983305,
+       (GLfloat) - 0.230218, (GLfloat) 0.184662, (GLfloat) - 0.955458,
+       (GLfloat) - 0.218138, (GLfloat) 0.174858, (GLfloat) - 0.960125,
+       (GLfloat) 0.043553, (GLfloat) - 0.957947, (GLfloat) - 0.283621,
+       (GLfloat) 0.073317, (GLfloat) - 0.961717, (GLfloat) - 0.264055,
+       (GLfloat) 0.178370, (GLfloat) - 0.932145, (GLfloat) - 0.315104,
+       (GLfloat) 0.175170, (GLfloat) - 0.936420, (GLfloat) - 0.304029,
+       (GLfloat) 0.021724, (GLfloat) - 0.600335, (GLfloat) - 0.799453,
+       (GLfloat) - 0.006371, (GLfloat) - 0.568607, (GLfloat) - 0.822585,
+       (GLfloat) - 0.212402, (GLfloat) - 0.727671, (GLfloat) - 0.652212,
+       (GLfloat) - 0.248701, (GLfloat) - 0.700487, (GLfloat) - 0.668929,
+       (GLfloat) 0.430757, (GLfloat) - 0.866899, (GLfloat) - 0.250869,
+       (GLfloat) 0.427975, (GLfloat) - 0.857309, (GLfloat) - 0.286110,
+       (GLfloat) 0.561354, (GLfloat) - 0.442015, (GLfloat) - 0.699646,
+       (GLfloat) 0.571558, (GLfloat) - 0.412112, (GLfloat) - 0.709567,
+       (GLfloat) 0.286734, (GLfloat) - 0.470609, (GLfloat) - 0.834453,
+       (GLfloat) 0.281923, (GLfloat) - 0.498471, (GLfloat) - 0.819784,
+       (GLfloat) 0.316508, (GLfloat) - 0.898548, (GLfloat) - 0.304029,
+       (GLfloat) 0.311600, (GLfloat) - 0.896446, (GLfloat) - 0.315104,
+       (GLfloat) - 0.857077, (GLfloat) - 0.113037, (GLfloat) - 0.502635,
+       (GLfloat) - 0.855920, (GLfloat) - 0.100677, (GLfloat) - 0.507214,
+       (GLfloat) - 0.973550, (GLfloat) - 0.162756, (GLfloat) - 0.160346,
+       (GLfloat) - 0.972585, (GLfloat) - 0.166359, (GLfloat) - 0.162491,
+       (GLfloat) - 0.942363, (GLfloat) - 0.290210, (GLfloat) - 0.166522,
+       (GLfloat) - 0.940343, (GLfloat) - 0.298398, (GLfloat) - 0.163441,
+       (GLfloat) - 0.819387, (GLfloat) - 0.257298, (GLfloat) - 0.512252,
+       (GLfloat) - 0.820563, (GLfloat) - 0.245585, (GLfloat) - 0.516105,
+       (GLfloat) - 0.857077, (GLfloat) - 0.113037, (GLfloat) 0.502635,
+       (GLfloat) - 0.855920, (GLfloat) - 0.100677, (GLfloat) 0.507214,
+       (GLfloat) - 0.820564, (GLfloat) - 0.245585, (GLfloat) 0.516104,
+       (GLfloat) - 0.819387, (GLfloat) - 0.257297, (GLfloat) 0.512252,
+       (GLfloat) - 0.942363, (GLfloat) - 0.290210, (GLfloat) 0.166522,
+       (GLfloat) - 0.940343, (GLfloat) - 0.298398, (GLfloat) 0.163441,
+       (GLfloat) - 0.973550, (GLfloat) - 0.162756, (GLfloat) 0.160346,
+       (GLfloat) - 0.972585, (GLfloat) - 0.166359, (GLfloat) 0.162491,
+       (GLfloat) - 0.031552, (GLfloat) - 0.978072, (GLfloat) 0.205866,
+       (GLfloat) - 0.009717, (GLfloat) - 0.983966, (GLfloat) 0.178091,
+       (GLfloat) - 0.059383, (GLfloat) - 0.995850, (GLfloat) 0.068965,
+       (GLfloat) - 0.047830, (GLfloat) - 0.996172, (GLfloat) 0.073163,
+       (GLfloat) - 0.608137, (GLfloat) - 0.782136, (GLfloat) 0.135767,
+       (GLfloat) - 0.575039, (GLfloat) - 0.805344, (GLfloat) 0.144053,
+       (GLfloat) - 0.440882, (GLfloat) - 0.803158, (GLfloat) 0.400699,
+       (GLfloat) - 0.474682, (GLfloat) - 0.782654, (GLfloat) 0.402654,
+       (GLfloat) - 0.009717, (GLfloat) - 0.983966, (GLfloat) - 0.178092,
+       (GLfloat) - 0.031552, (GLfloat) - 0.978072, (GLfloat) - 0.205866,
+       (GLfloat) - 0.474681, (GLfloat) - 0.782654, (GLfloat) - 0.402654,
+       (GLfloat) - 0.440881, (GLfloat) - 0.803159, (GLfloat) - 0.400699,
+       (GLfloat) - 0.608137, (GLfloat) - 0.782136, (GLfloat) - 0.135767,
+       (GLfloat) - 0.575039, (GLfloat) - 0.805344, (GLfloat) - 0.144053,
+       (GLfloat) - 0.047830, (GLfloat) - 0.996172, (GLfloat) - 0.073163,
+       (GLfloat) - 0.059383, (GLfloat) - 0.995850, (GLfloat) - 0.068965,
+       (GLfloat) - 0.545743, (GLfloat) 0.029212, (GLfloat) 0.837443,
+       (GLfloat) - 0.541197, (GLfloat) 0.047754, (GLfloat) 0.839539,
+       (GLfloat) - 0.218137, (GLfloat) 0.174858, (GLfloat) 0.960125,
+       (GLfloat) - 0.230218, (GLfloat) 0.184662, (GLfloat) 0.955458,
+       (GLfloat) - 0.180219, (GLfloat) 0.028850, (GLfloat) 0.983203,
+       (GLfloat) - 0.179757, (GLfloat) 0.028256, (GLfloat) 0.983305,
+       (GLfloat) - 0.503751, (GLfloat) - 0.117102, (GLfloat) 0.855875,
+       (GLfloat) - 0.504199, (GLfloat) - 0.116456, (GLfloat) 0.855699,
+       (GLfloat) 0.373209, (GLfloat) 0.459657, (GLfloat) 0.805872,
+       (GLfloat) 0.365166, (GLfloat) 0.464177, (GLfloat) 0.806966,
+       (GLfloat) 0.446081, (GLfloat) 0.299065, (GLfloat) 0.843547,
+       (GLfloat) 0.442539, (GLfloat) 0.302926, (GLfloat) 0.844035,
+       (GLfloat) 0.122955, (GLfloat) 0.165170, (GLfloat) 0.978571,
+       (GLfloat) 0.127864, (GLfloat) 0.159456, (GLfloat) 0.978889,
+       (GLfloat) 0.064151, (GLfloat) 0.318724, (GLfloat) 0.945674,
+       (GLfloat) 0.075117, (GLfloat) 0.311589, (GLfloat) 0.947243,
+       (GLfloat) 0.430757, (GLfloat) - 0.866899, (GLfloat) 0.250868,
+       (GLfloat) 0.427975, (GLfloat) - 0.857309, (GLfloat) 0.286110,
+       (GLfloat) 0.311600, (GLfloat) - 0.896446, (GLfloat) 0.315104,
+       (GLfloat) 0.316508, (GLfloat) - 0.898548, (GLfloat) 0.304029,
+       (GLfloat) 0.281923, (GLfloat) - 0.498471, (GLfloat) 0.819784,
+       (GLfloat) 0.286734, (GLfloat) - 0.470608, (GLfloat) 0.834453,
+       (GLfloat) 0.561354, (GLfloat) - 0.442014, (GLfloat) 0.699647,
+       (GLfloat) 0.571558, (GLfloat) - 0.412112, (GLfloat) 0.709567,
+       (GLfloat) 0.073318, (GLfloat) - 0.961717, (GLfloat) 0.264055,
+       (GLfloat) 0.043553, (GLfloat) - 0.957947, (GLfloat) 0.283620,
+       (GLfloat) - 0.212402, (GLfloat) - 0.727670, (GLfloat) 0.652213,
+       (GLfloat) - 0.248701, (GLfloat) - 0.700487, (GLfloat) 0.668929,
+       (GLfloat) - 0.006371, (GLfloat) - 0.568606, (GLfloat) 0.822585,
+       (GLfloat) 0.021725, (GLfloat) - 0.600335, (GLfloat) 0.799453,
+       (GLfloat) 0.175170, (GLfloat) - 0.936420, (GLfloat) 0.304028,
+       (GLfloat) 0.178370, (GLfloat) - 0.932145, (GLfloat) 0.315104,
+       (GLfloat) 0.385580, (GLfloat) - 0.914303, (GLfloat) - 0.124011,
+       (GLfloat) 0.374190, (GLfloat) - 0.917355, (GLfloat) - 0.135802,
+       (GLfloat) 0.299349, (GLfloat) - 0.947826, (GLfloat) - 0.109621,
+       (GLfloat) 0.295210, (GLfloat) - 0.948521, (GLfloat) - 0.114709,
+       (GLfloat) 0.287695, (GLfloat) - 0.957151, (GLfloat) - 0.033079,
+       (GLfloat) 0.290512, (GLfloat) - 0.956396, (GLfloat) - 0.030163,
+       (GLfloat) 0.362895, (GLfloat) - 0.930799, (GLfloat) - 0.043834,
+       (GLfloat) 0.367706, (GLfloat) - 0.929096, (GLfloat) - 0.039656,
+       (GLfloat) 0.134619, (GLfloat) - 0.981547, (GLfloat) - 0.135802,
+       (GLfloat) 0.123230, (GLfloat) - 0.984599, (GLfloat) - 0.124011,
+       (GLfloat) 0.151123, (GLfloat) - 0.987543, (GLfloat) - 0.043834,
+       (GLfloat) 0.146105, (GLfloat) - 0.988474, (GLfloat) - 0.039656,
+       (GLfloat) 0.226607, (GLfloat) - 0.973519, (GLfloat) - 0.030163,
+       (GLfloat) 0.229424, (GLfloat) - 0.972764, (GLfloat) - 0.033079,
+       (GLfloat) 0.214669, (GLfloat) - 0.970516, (GLfloat) - 0.109621,
+       (GLfloat) 0.218601, (GLfloat) - 0.969049, (GLfloat) - 0.114709,
+       (GLfloat) 0.123230, (GLfloat) - 0.984599, (GLfloat) 0.124011,
+       (GLfloat) 0.134619, (GLfloat) - 0.981547, (GLfloat) 0.135802,
+       (GLfloat) 0.214669, (GLfloat) - 0.970516, (GLfloat) 0.109621,
+       (GLfloat) 0.218601, (GLfloat) - 0.969049, (GLfloat) 0.114709,
+       (GLfloat) 0.229424, (GLfloat) - 0.972764, (GLfloat) 0.033079,
+       (GLfloat) 0.226607, (GLfloat) - 0.973519, (GLfloat) 0.030163,
+       (GLfloat) 0.151123, (GLfloat) - 0.987543, (GLfloat) 0.043834,
+       (GLfloat) 0.146105, (GLfloat) - 0.988474, (GLfloat) 0.039656,
+       (GLfloat) 0.374190, (GLfloat) - 0.917355, (GLfloat) 0.135803,
+       (GLfloat) 0.385580, (GLfloat) - 0.914303, (GLfloat) 0.124011,
+       (GLfloat) 0.362895, (GLfloat) - 0.930799, (GLfloat) 0.043834,
+       (GLfloat) 0.367706, (GLfloat) - 0.929096, (GLfloat) 0.039656,
+       (GLfloat) 0.290512, (GLfloat) - 0.956396, (GLfloat) 0.030163,
+       (GLfloat) 0.287695, (GLfloat) - 0.957151, (GLfloat) 0.033079,
+       (GLfloat) 0.299349, (GLfloat) - 0.947826, (GLfloat) 0.109621,
+       (GLfloat) 0.295210, (GLfloat) - 0.948521, (GLfloat) 0.114709,
+};
+
+static unsigned short int s1_5_POLS[] =
+{
+      3, 12, 76, 74, 1, 3, 12, 74, 82, 1, 3, 76, 22, 78, 1, 3, 78, 74, 76, 1,
+      3, 20, 80, 74, 1, 3, 20, 74, 78, 1, 3, 80, 28, 82, 1, 3, 82, 74, 80, 1,
+      3, 13, 84, 77, 1, 3, 13, 77, 88, 1, 3, 84, 24, 86, 1, 3, 86, 77, 84, 1,
+      3, 20, 78, 77, 1, 3, 20, 77, 86, 1, 3, 78, 22, 88, 1, 3, 88, 77, 78, 1,
+      3, 14, 90, 85, 1, 3, 14, 85, 93, 1, 3, 26, 91, 85, 1, 3, 26, 85, 90, 1,
+      3, 20, 86, 85, 1, 3, 20, 85, 91, 1, 3, 86, 24, 93, 1, 3, 93, 85, 86, 1,
+      3, 15, 95, 79, 1, 3, 15, 79, 97, 1, 3, 95, 28, 80, 1, 3, 80, 79, 95, 1,
+      3, 20, 91, 79, 1, 3, 20, 79, 80, 1, 3, 26, 97, 79, 1, 3, 26, 79, 91, 1,
+    3, 13, 99, 83, 1, 3, 13, 83, 84, 1, 3, 99, 30, 101, 1, 3, 101, 83, 99, 1,
+  3, 23, 102, 83, 1, 3, 23, 83, 101, 1, 3, 102, 24, 84, 1, 3, 84, 83, 102, 1,
+       3, 108, 16, 104, 1, 3, 104, 100, 108, 1, 3, 32, 106, 100, 1, 3, 32, 100, 104, 1,
+       3, 106, 23, 101, 1, 3, 101, 100, 106, 1, 3, 30, 108, 100, 1, 3, 30, 100, 101, 1,
+       3, 17, 110, 105, 1, 3, 17, 105, 113, 1, 3, 33, 111, 105, 1, 3, 33, 105, 110, 1,
+       3, 23, 106, 105, 1, 3, 23, 105, 111, 1, 3, 106, 32, 113, 1, 3, 113, 105, 106, 1,
+   3, 14, 93, 92, 1, 3, 14, 92, 114, 1, 3, 93, 24, 102, 1, 3, 102, 92, 93, 1,
+3, 102, 23, 111, 1, 3, 111, 92, 102, 1, 3, 33, 114, 92, 1, 3, 33, 92, 111, 1,
+       3, 16, 116, 103, 1, 3, 16, 103, 104, 1, 3, 116, 35, 118, 1, 3, 118, 103, 116, 1,
+       3, 31, 119, 103, 1, 3, 31, 103, 118, 1, 3, 119, 32, 104, 1, 3, 104, 103, 119, 1,
+       3, 18, 121, 117, 1, 3, 18, 117, 125, 1, 3, 121, 36, 123, 1, 3, 123, 117, 121, 1,
+       3, 31, 118, 117, 1, 3, 31, 117, 123, 1, 3, 118, 35, 125, 1, 3, 125, 117, 118, 1,
+       3, 19, 127, 122, 1, 3, 19, 122, 130, 1, 3, 37, 128, 122, 1, 3, 37, 122, 127, 1,
+       3, 31, 123, 122, 1, 3, 31, 122, 128, 1, 3, 36, 130, 122, 1, 3, 36, 122, 123, 1,
+       3, 17, 113, 112, 1, 3, 17, 112, 131, 1, 3, 32, 119, 112, 1, 3, 32, 112, 113, 1,
+       3, 31, 128, 112, 1, 3, 31, 112, 119, 1, 3, 37, 131, 112, 1, 3, 37, 112, 128, 1,
+       3, 121, 18, 133, 1, 3, 133, 120, 121, 1, 3, 39, 134, 120, 1, 3, 39, 120, 133, 1,
+       3, 134, 27, 135, 1, 3, 135, 120, 134, 1, 3, 36, 121, 120, 1, 3, 36, 120, 135, 1,
+   3, 12, 82, 81, 1, 3, 12, 81, 138, 1, 3, 82, 28, 136, 1, 3, 136, 81, 82, 1,
+3, 27, 134, 81, 1, 3, 27, 81, 136, 1, 3, 134, 39, 138, 1, 3, 138, 81, 134, 1,
+   3, 15, 139, 94, 1, 3, 15, 94, 95, 1, 3, 40, 140, 94, 1, 3, 40, 94, 139, 1,
+3, 140, 27, 136, 1, 3, 136, 94, 140, 1, 3, 136, 28, 95, 1, 3, 95, 94, 136, 1,
+       3, 19, 130, 129, 1, 3, 19, 129, 141, 1, 3, 130, 36, 135, 1, 3, 135, 129, 130, 1,
+       3, 27, 140, 129, 1, 3, 27, 129, 135, 1, 3, 40, 141, 129, 1, 3, 40, 129, 140, 1,
+ 3, 14, 114, 89, 1, 3, 14, 89, 90, 1, 3, 114, 33, 142, 1, 3, 142, 89, 114, 1,
+  3, 25, 143, 89, 1, 3, 25, 89, 142, 1, 3, 143, 26, 90, 1, 3, 90, 89, 143, 1,
+       3, 17, 131, 109, 1, 3, 17, 109, 110, 1, 3, 131, 37, 144, 1, 3, 144, 109, 131, 1,
+       3, 25, 142, 109, 1, 3, 25, 109, 144, 1, 3, 142, 33, 110, 1, 3, 110, 109, 142, 1,
+       3, 19, 141, 126, 1, 3, 19, 126, 127, 1, 3, 141, 40, 145, 1, 3, 145, 126, 141, 1,
+       3, 25, 144, 126, 1, 3, 25, 126, 145, 1, 3, 144, 37, 127, 1, 3, 127, 126, 144, 1,
+   3, 15, 97, 96, 1, 3, 15, 96, 139, 1, 3, 97, 26, 143, 1, 3, 143, 96, 97, 1,
+3, 25, 145, 96, 1, 3, 25, 96, 143, 1, 3, 145, 40, 139, 1, 3, 139, 96, 145, 1,
+3, 76, 12, 146, 1, 3, 146, 75, 76, 1, 3, 146, 41, 148, 1, 3, 148, 75, 146, 1,
+ 3, 148, 21, 149, 1, 3, 149, 75, 148, 1, 3, 22, 76, 75, 1, 3, 22, 75, 149, 1,
+       3, 155, 8, 151, 1, 3, 151, 147, 155, 1, 3, 43, 153, 147, 1, 3, 43, 147, 151, 1,
+       3, 153, 21, 148, 1, 3, 148, 147, 153, 1, 3, 41, 155, 147, 1, 3, 41, 147, 148, 1,
+       3, 160, 11, 157, 1, 3, 157, 152, 160, 1, 3, 44, 158, 152, 1, 3, 44, 152, 157, 1,
+       3, 158, 21, 153, 1, 3, 153, 152, 158, 1, 3, 43, 160, 152, 1, 3, 43, 152, 153, 1,
+   3, 161, 13, 88, 1, 3, 88, 87, 161, 1, 3, 22, 149, 87, 1, 3, 22, 87, 88, 1,
+       3, 149, 21, 158, 1, 3, 158, 87, 149, 1, 3, 158, 44, 161, 1, 3, 161, 87, 158, 1,
+       3, 18, 162, 132, 1, 3, 18, 132, 133, 1, 3, 162, 45, 164, 1, 3, 164, 132, 162, 1,
+       3, 38, 165, 132, 1, 3, 38, 132, 164, 1, 3, 165, 39, 133, 1, 3, 133, 132, 165, 1,
+       3, 170, 9, 167, 1, 3, 167, 163, 170, 1, 3, 47, 168, 163, 1, 3, 47, 163, 167, 1,
+       3, 168, 38, 164, 1, 3, 164, 163, 168, 1, 3, 45, 170, 163, 1, 3, 45, 163, 164, 1,
+3, 8, 155, 154, 1, 3, 8, 154, 173, 1, 3, 155, 41, 171, 1, 3, 171, 154, 155, 1,
+       3, 38, 168, 154, 1, 3, 38, 154, 171, 1, 3, 168, 47, 173, 1, 3, 173, 154, 168, 1,
+       3, 146, 12, 138, 1, 3, 138, 137, 146, 1, 3, 39, 165, 137, 1, 3, 39, 137, 138, 1,
+       3, 165, 38, 171, 1, 3, 171, 137, 165, 1, 3, 41, 146, 137, 1, 3, 41, 137, 171, 1,
+       3, 16, 108, 107, 1, 3, 16, 107, 177, 1, 3, 108, 30, 174, 1, 3, 174, 107, 108, 1,
+       3, 29, 176, 107, 1, 3, 29, 107, 174, 1, 3, 176, 50, 177, 1, 3, 177, 107, 176, 1,
+  3, 99, 13, 161, 1, 3, 161, 98, 99, 1, 3, 44, 178, 98, 1, 3, 44, 98, 161, 1,
+ 3, 178, 29, 174, 1, 3, 174, 98, 178, 1, 3, 30, 99, 98, 1, 3, 30, 98, 174, 1,
+       3, 11, 180, 156, 1, 3, 11, 156, 157, 1, 3, 180, 49, 181, 1, 3, 181, 156, 180, 1,
+       3, 29, 178, 156, 1, 3, 29, 156, 181, 1, 3, 178, 44, 157, 1, 3, 157, 156, 178, 1,
+       3, 185, 10, 183, 1, 3, 183, 175, 185, 1, 3, 50, 176, 175, 1, 3, 50, 175, 183, 1,
+       3, 176, 29, 181, 1, 3, 181, 175, 176, 1, 3, 49, 185, 175, 1, 3, 49, 175, 181, 1,
+       3, 162, 18, 125, 1, 3, 125, 124, 162, 1, 3, 35, 186, 124, 1, 3, 35, 124, 125, 1,
+       3, 186, 34, 187, 1, 3, 187, 124, 186, 1, 3, 45, 162, 124, 1, 3, 45, 124, 187, 1,
+       3, 116, 16, 177, 1, 3, 177, 115, 116, 1, 3, 50, 188, 115, 1, 3, 50, 115, 177, 1,
+       3, 188, 34, 186, 1, 3, 186, 115, 188, 1, 3, 35, 116, 115, 1, 3, 35, 115, 186, 1,
+       3, 10, 190, 182, 1, 3, 10, 182, 183, 1, 3, 190, 52, 191, 1, 3, 191, 182, 190, 1,
+       3, 191, 34, 188, 1, 3, 188, 182, 191, 1, 3, 50, 183, 182, 1, 3, 50, 182, 188, 1,
+3, 9, 170, 169, 1, 3, 9, 169, 193, 1, 3, 45, 187, 169, 1, 3, 45, 169, 170, 1,
+       3, 187, 34, 191, 1, 3, 191, 169, 187, 1, 3, 191, 52, 193, 1, 3, 193, 169, 191, 1,
+3, 1, 196, 194, 1, 3, 1, 194, 201, 1, 3, 196, 54, 198, 1, 3, 198, 194, 196, 1,
+       3, 46, 199, 194, 1, 3, 46, 194, 198, 1, 3, 56, 201, 194, 1, 3, 56, 194, 199, 1,
+       3, 206, 3, 203, 1, 3, 203, 197, 206, 1, 3, 55, 204, 197, 1, 3, 55, 197, 203, 1,
+       3, 204, 46, 198, 1, 3, 198, 197, 204, 1, 3, 54, 206, 197, 1, 3, 54, 197, 198, 1,
+       3, 208, 8, 173, 1, 3, 173, 172, 208, 1, 3, 47, 207, 172, 1, 3, 47, 172, 173, 1,
+       3, 46, 204, 172, 1, 3, 46, 172, 207, 1, 3, 204, 55, 208, 1, 3, 208, 172, 204, 1,
+3, 9, 209, 166, 1, 3, 9, 166, 167, 1, 3, 209, 56, 199, 1, 3, 199, 166, 209, 1,
+       3, 46, 207, 166, 1, 3, 46, 166, 199, 1, 3, 207, 47, 167, 1, 3, 167, 166, 207, 1,
+3, 1, 201, 200, 1, 3, 1, 200, 214, 1, 3, 201, 56, 210, 1, 3, 210, 200, 201, 1,
+       3, 51, 212, 200, 1, 3, 51, 200, 210, 1, 3, 212, 59, 214, 1, 3, 214, 200, 212, 1,
+       3, 209, 9, 193, 1, 3, 193, 192, 209, 1, 3, 52, 215, 192, 1, 3, 52, 192, 193, 1,
+       3, 215, 51, 210, 1, 3, 210, 192, 215, 1, 3, 192, 210, 56, 1, 3, 56, 209, 192, 1,
+       3, 190, 10, 216, 1, 3, 216, 189, 190, 1, 3, 189, 216, 57, 1, 3, 57, 217, 189, 1,
+       3, 217, 51, 215, 1, 3, 215, 189, 217, 1, 3, 52, 190, 189, 1, 3, 52, 189, 215, 1,
+3, 0, 219, 211, 1, 3, 0, 211, 221, 1, 3, 219, 59, 212, 1, 3, 212, 211, 219, 1,
+       3, 51, 217, 211, 1, 3, 51, 211, 212, 1, 3, 217, 57, 221, 1, 3, 221, 211, 217, 1,
+3, 0, 221, 220, 1, 3, 0, 220, 226, 1, 3, 57, 222, 220, 1, 3, 57, 220, 221, 1,
+       3, 48, 224, 220, 1, 3, 48, 220, 222, 1, 3, 224, 62, 226, 1, 3, 226, 220, 224, 1,
+       3, 10, 185, 184, 1, 3, 10, 184, 216, 1, 3, 185, 49, 227, 1, 3, 227, 184, 185, 1,
+       3, 48, 222, 184, 1, 3, 48, 184, 227, 1, 3, 222, 57, 216, 1, 3, 216, 184, 222, 1,
+       3, 180, 11, 228, 1, 3, 228, 179, 180, 1, 3, 228, 60, 229, 1, 3, 229, 179, 228, 1,
+       3, 48, 227, 179, 1, 3, 48, 179, 229, 1, 3, 49, 180, 179, 1, 3, 49, 179, 227, 1,
+       3, 233, 2, 231, 1, 3, 231, 223, 233, 1, 3, 62, 224, 223, 1, 3, 62, 223, 231, 1,
+       3, 224, 48, 229, 1, 3, 229, 223, 224, 1, 3, 60, 233, 223, 1, 3, 60, 223, 229, 1,
+       3, 237, 2, 233, 1, 3, 233, 232, 237, 1, 3, 60, 234, 232, 1, 3, 60, 232, 233, 1,
+       3, 234, 42, 235, 1, 3, 235, 232, 234, 1, 3, 64, 237, 232, 1, 3, 64, 232, 235, 1,
+       3, 11, 160, 159, 1, 3, 11, 159, 228, 1, 3, 160, 43, 238, 1, 3, 238, 159, 160, 1,
+       3, 42, 234, 159, 1, 3, 42, 159, 238, 1, 3, 234, 60, 228, 1, 3, 228, 159, 234, 1,
+3, 8, 208, 150, 1, 3, 8, 150, 151, 1, 3, 208, 55, 239, 1, 3, 239, 150, 208, 1,
+       3, 42, 238, 150, 1, 3, 42, 150, 239, 1, 3, 238, 43, 151, 1, 3, 151, 150, 238, 1,
+       3, 203, 3, 241, 1, 3, 241, 202, 203, 1, 3, 64, 235, 202, 1, 3, 64, 202, 241, 1,
+       3, 235, 42, 239, 1, 3, 239, 202, 235, 1, 3, 55, 203, 202, 1, 3, 55, 202, 239, 1,
+3, 2, 237, 236, 1, 3, 2, 236, 245, 1, 3, 237, 64, 242, 1, 3, 242, 236, 237, 1,
+       3, 63, 244, 236, 1, 3, 63, 236, 242, 1, 3, 244, 68, 245, 1, 3, 245, 236, 244, 1,
+3, 3, 246, 240, 1, 3, 3, 240, 241, 1, 3, 246, 65, 248, 1, 3, 248, 240, 246, 1,
+       3, 63, 242, 240, 1, 3, 63, 240, 248, 1, 3, 242, 64, 241, 1, 3, 241, 240, 242, 1,
+3, 4, 250, 247, 1, 3, 4, 247, 253, 1, 3, 67, 251, 247, 1, 3, 67, 247, 250, 1,
+       3, 63, 248, 247, 1, 3, 63, 247, 251, 1, 3, 248, 65, 253, 1, 3, 253, 247, 248, 1,
+3, 7, 255, 243, 1, 3, 7, 243, 257, 1, 3, 255, 68, 244, 1, 3, 244, 243, 255, 1,
+       3, 63, 251, 243, 1, 3, 63, 243, 244, 1, 3, 67, 257, 243, 1, 3, 67, 243, 251, 1,
+3, 3, 206, 205, 1, 3, 3, 205, 246, 1, 3, 206, 54, 258, 1, 3, 258, 205, 206, 1,
+       3, 53, 259, 205, 1, 3, 53, 205, 258, 1, 3, 259, 65, 246, 1, 3, 246, 205, 259, 1,
+3, 1, 260, 195, 1, 3, 1, 195, 196, 1, 3, 69, 262, 195, 1, 3, 69, 195, 260, 1,
+       3, 262, 53, 258, 1, 3, 258, 195, 262, 1, 3, 54, 196, 195, 1, 3, 54, 195, 258, 1,
+3, 5, 264, 261, 1, 3, 5, 261, 267, 1, 3, 70, 265, 261, 1, 3, 70, 261, 264, 1,
+       3, 53, 262, 261, 1, 3, 53, 261, 265, 1, 3, 262, 69, 267, 1, 3, 267, 261, 262, 1,
+       3, 268, 4, 253, 1, 3, 253, 252, 268, 1, 3, 253, 65, 259, 1, 3, 259, 252, 253, 1,
+       3, 53, 265, 252, 1, 3, 53, 252, 259, 1, 3, 70, 268, 252, 1, 3, 70, 252, 265, 1,
+       3, 260, 1, 214, 1, 3, 214, 213, 260, 1, 3, 214, 59, 269, 1, 3, 269, 213, 214, 1,
+       3, 269, 58, 270, 1, 3, 270, 213, 269, 1, 3, 69, 260, 213, 1, 3, 69, 213, 270, 1,
+       3, 219, 0, 271, 1, 3, 271, 218, 219, 1, 3, 71, 273, 218, 1, 3, 71, 218, 271, 1,
+       3, 273, 58, 269, 1, 3, 269, 218, 273, 1, 3, 269, 59, 219, 1, 3, 219, 218, 269, 1,
+3, 6, 275, 272, 1, 3, 6, 272, 278, 1, 3, 72, 276, 272, 1, 3, 72, 272, 275, 1,
+       3, 276, 58, 273, 1, 3, 273, 272, 276, 1, 3, 71, 278, 272, 1, 3, 71, 272, 273, 1,
+3, 5, 267, 266, 1, 3, 5, 266, 279, 1, 3, 69, 270, 266, 1, 3, 69, 266, 267, 1,
+       3, 270, 58, 276, 1, 3, 276, 266, 270, 1, 3, 72, 279, 266, 1, 3, 72, 266, 276, 1,
+3, 0, 226, 225, 1, 3, 0, 225, 271, 1, 3, 62, 280, 225, 1, 3, 62, 225, 226, 1,
+       3, 280, 61, 281, 1, 3, 281, 225, 280, 1, 3, 71, 271, 225, 1, 3, 71, 225, 281, 1,
+3, 2, 245, 230, 1, 3, 2, 230, 231, 1, 3, 245, 68, 282, 1, 3, 282, 230, 245, 1,
+       3, 61, 280, 230, 1, 3, 61, 230, 282, 1, 3, 280, 62, 231, 1, 3, 231, 230, 280, 1,
+       3, 255, 7, 283, 1, 3, 283, 254, 255, 1, 3, 73, 284, 254, 1, 3, 73, 254, 283, 1,
+       3, 61, 282, 254, 1, 3, 61, 254, 284, 1, 3, 282, 68, 255, 1, 3, 255, 254, 282, 1,
+3, 6, 278, 277, 1, 3, 6, 277, 285, 1, 3, 278, 71, 281, 1, 3, 281, 277, 278, 1,
+       3, 61, 284, 277, 1, 3, 61, 277, 281, 1, 3, 73, 285, 277, 1, 3, 73, 277, 284, 1,
+3, 4, 268, 249, 1, 3, 4, 249, 250, 1, 3, 268, 70, 286, 1, 3, 286, 249, 268, 1,
+       3, 66, 287, 249, 1, 3, 66, 249, 286, 1, 3, 287, 67, 250, 1, 3, 250, 249, 287, 1,
+3, 5, 279, 263, 1, 3, 5, 263, 264, 1, 3, 279, 72, 288, 1, 3, 288, 263, 279, 1,
+       3, 66, 286, 263, 1, 3, 66, 263, 288, 1, 3, 286, 70, 264, 1, 3, 264, 263, 286, 1,
+3, 6, 285, 274, 1, 3, 6, 274, 275, 1, 3, 285, 73, 289, 1, 3, 289, 274, 285, 1,
+       3, 66, 288, 274, 1, 3, 66, 274, 289, 1, 3, 288, 72, 275, 1, 3, 275, 274, 288, 1,
+3, 7, 257, 256, 1, 3, 7, 256, 283, 1, 3, 257, 67, 287, 1, 3, 287, 256, 257, 1,
+       3, 66, 289, 256, 1, 3, 66, 256, 287, 1, 3, 289, 73, 283, 1, 3, 283, 256, 289, 1,
+
+       0
+};
+
+struct lwo  LWO_s1_5 =
+{
+       290,                    /* number of points */
+       s1_5_PNTS, s1_5_normals, s1_5_POLS, 0L
+};
+
+#endif /* MODE_sproingies */
+
+/* End of s1_5.c */
diff --git a/xlockmore-4.14/modes/glx/s1_6.c b/xlockmore-4.14/modes/glx/s1_6.c
new file mode 100644 (file)
index 0000000..cdd589f
--- /dev/null
@@ -0,0 +1,1057 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)s1_6.c       4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points, polygons, and normal vectors to render "s1_6" in 3D.
+ *
+ * Generated by lw2ogl.  Link this with your program but do
+ * not edit by hand.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_sproingies
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat s1_6_PNTS[] =
+{
+       (GLfloat) 1.339151, (GLfloat) - 0.510672, (GLfloat) - 0.339151,
+       (GLfloat) 1.339151, (GLfloat) - 0.510672, (GLfloat) - 0.660849,
+       (GLfloat) 1.660849, (GLfloat) - 0.510672, (GLfloat) - 0.339151,
+       (GLfloat) 1.660849, (GLfloat) - 0.510672, (GLfloat) - 0.660849,
+       (GLfloat) 1.638667, (GLfloat) - 0.642463, (GLfloat) - 0.638667,
+       (GLfloat) 1.361333, (GLfloat) - 0.642463, (GLfloat) - 0.638667,
+       (GLfloat) 1.361333, (GLfloat) - 0.642463, (GLfloat) - 0.361333,
+       (GLfloat) 1.638667, (GLfloat) - 0.642463, (GLfloat) - 0.361333,
+       (GLfloat) 1.589301, (GLfloat) - 0.085107, (GLfloat) - 0.624049,
+       (GLfloat) 1.356947, (GLfloat) - 0.122198, (GLfloat) - 0.624049,
+       (GLfloat) 1.356947, (GLfloat) - 0.122198, (GLfloat) - 0.375951,
+       (GLfloat) 1.589301, (GLfloat) - 0.085107, (GLfloat) - 0.375951,
+       (GLfloat) 1.460394, (GLfloat) 0.412133, (GLfloat) - 0.660849,
+       (GLfloat) 1.460394, (GLfloat) 0.412133, (GLfloat) - 0.339151,
+       (GLfloat) 1.370035, (GLfloat) 0.524394, (GLfloat) - 0.361333,
+       (GLfloat) 1.370035, (GLfloat) 0.524394, (GLfloat) - 0.638667,
+       (GLfloat) 1.226863, (GLfloat) 0.204423, (GLfloat) - 0.339151,
+       (GLfloat) 1.177383, (GLfloat) 0.324897, (GLfloat) - 0.361333,
+       (GLfloat) 1.226863, (GLfloat) 0.204423, (GLfloat) - 0.660849,
+       (GLfloat) 1.177383, (GLfloat) 0.324897, (GLfloat) - 0.638667,
+       (GLfloat) 1.460683, (GLfloat) 0.568581, (GLfloat) - 0.500000,
+       (GLfloat) 1.564666, (GLfloat) 0.208184, (GLfloat) - 0.500000,
+       (GLfloat) 1.502855, (GLfloat) 0.449898, (GLfloat) - 0.500000,
+       (GLfloat) 1.294932, (GLfloat) 0.399266, (GLfloat) - 0.262379,
+       (GLfloat) 1.416649, (GLfloat) 0.522728, (GLfloat) - 0.326134,
+       (GLfloat) 1.260429, (GLfloat) 0.437469, (GLfloat) - 0.500000,
+       (GLfloat) 1.392236, (GLfloat) 0.557026, (GLfloat) - 0.500000,
+       (GLfloat) 1.294932, (GLfloat) 0.399266, (GLfloat) - 0.737621,
+       (GLfloat) 1.416649, (GLfloat) 0.522728, (GLfloat) - 0.673866,
+       (GLfloat) 1.412872, (GLfloat) 0.126752, (GLfloat) - 0.313640,
+       (GLfloat) 1.343629, (GLfloat) 0.308278, (GLfloat) - 0.280660,
+       (GLfloat) 1.129180, (GLfloat) 0.229952, (GLfloat) - 0.500000,
+       (GLfloat) 1.174088, (GLfloat) 0.274960, (GLfloat) - 0.326134,
+       (GLfloat) 1.268890, (GLfloat) 0.429299, (GLfloat) - 0.322437,
+       (GLfloat) 1.261078, (GLfloat) 0.045321, (GLfloat) - 0.500000,
+       (GLfloat) 1.184403, (GLfloat) 0.166658, (GLfloat) - 0.500000,
+       (GLfloat) 1.174088, (GLfloat) 0.274960, (GLfloat) - 0.673866,
+       (GLfloat) 1.145545, (GLfloat) 0.301571, (GLfloat) - 0.500000,
+       (GLfloat) 1.412872, (GLfloat) 0.126752, (GLfloat) - 0.686360,
+       (GLfloat) 1.343629, (GLfloat) 0.308278, (GLfloat) - 0.719340,
+       (GLfloat) 1.268890, (GLfloat) 0.429299, (GLfloat) - 0.677562,
+       (GLfloat) 1.524188, (GLfloat) 0.186469, (GLfloat) - 0.636664,
+       (GLfloat) 1.682599, (GLfloat) - 0.328303, (GLfloat) - 0.500000,
+       (GLfloat) 1.631547, (GLfloat) - 0.078363, (GLfloat) - 0.500000,
+       (GLfloat) 1.524188, (GLfloat) 0.186469, (GLfloat) - 0.363336,
+       (GLfloat) 1.301556, (GLfloat) 0.067036, (GLfloat) - 0.636664,
+       (GLfloat) 1.497312, (GLfloat) - 0.330832, (GLfloat) - 0.686360,
+       (GLfloat) 1.473124, (GLfloat) - 0.103652, (GLfloat) - 0.669158,
+       (GLfloat) 1.497312, (GLfloat) - 0.330832, (GLfloat) - 0.313640,
+       (GLfloat) 1.473124, (GLfloat) - 0.103652, (GLfloat) - 0.330842,
+       (GLfloat) 1.301556, (GLfloat) 0.067036, (GLfloat) - 0.363336,
+       (GLfloat) 1.312026, (GLfloat) - 0.333361, (GLfloat) - 0.500000,
+       (GLfloat) 1.314701, (GLfloat) - 0.128942, (GLfloat) - 0.500000,
+       (GLfloat) 1.500000, (GLfloat) - 0.609501, (GLfloat) - 0.737621,
+       (GLfloat) 1.500000, (GLfloat) - 0.510672, (GLfloat) - 0.719340,
+       (GLfloat) 1.633189, (GLfloat) - 0.328978, (GLfloat) - 0.636664,
+       (GLfloat) 1.361436, (GLfloat) - 0.332687, (GLfloat) - 0.636664,
+       (GLfloat) 1.361436, (GLfloat) - 0.332687, (GLfloat) - 0.363336,
+       (GLfloat) 1.262379, (GLfloat) - 0.609501, (GLfloat) - 0.500000,
+       (GLfloat) 1.280660, (GLfloat) - 0.510672, (GLfloat) - 0.500000,
+       (GLfloat) 1.633189, (GLfloat) - 0.328978, (GLfloat) - 0.363336,
+       (GLfloat) 1.500000, (GLfloat) - 0.609501, (GLfloat) - 0.262379,
+       (GLfloat) 1.500000, (GLfloat) - 0.510672, (GLfloat) - 0.280660,
+       (GLfloat) 1.737621, (GLfloat) - 0.609501, (GLfloat) - 0.500000,
+       (GLfloat) 1.719340, (GLfloat) - 0.510672, (GLfloat) - 0.500000,
+       (GLfloat) 1.673866, (GLfloat) - 0.608893, (GLfloat) - 0.673866,
+       (GLfloat) 1.500000, (GLfloat) - 0.660924, (GLfloat) - 0.500000,
+       (GLfloat) 1.677562, (GLfloat) - 0.649161, (GLfloat) - 0.500000,
+       (GLfloat) 1.673866, (GLfloat) - 0.608893, (GLfloat) - 0.326134,
+       (GLfloat) 1.326134, (GLfloat) - 0.608893, (GLfloat) - 0.673866,
+       (GLfloat) 1.500000, (GLfloat) - 0.649161, (GLfloat) - 0.677562,
+       (GLfloat) 1.326134, (GLfloat) - 0.608893, (GLfloat) - 0.326134,
+       (GLfloat) 1.322438, (GLfloat) - 0.649161, (GLfloat) - 0.500000,
+       (GLfloat) 1.500000, (GLfloat) - 0.649161, (GLfloat) - 0.322437,
+       (GLfloat) 1.470529, (GLfloat) 0.515074, (GLfloat) - 0.593594,
+       (GLfloat) 1.521298, (GLfloat) 0.332708, (GLfloat) - 0.580972,
+       (GLfloat) 1.492239, (GLfloat) 0.440457, (GLfloat) - 0.587736,
+       (GLfloat) 1.470529, (GLfloat) 0.515074, (GLfloat) - 0.406406,
+       (GLfloat) 1.481548, (GLfloat) 0.525864, (GLfloat) - 0.500000,
+       (GLfloat) 1.423386, (GLfloat) 0.566478, (GLfloat) - 0.587500,
+       (GLfloat) 1.449724, (GLfloat) 0.556950, (GLfloat) - 0.594774,
+       (GLfloat) 1.382377, (GLfloat) 0.428753, (GLfloat) - 0.718387,
+       (GLfloat) 1.437472, (GLfloat) 0.482703, (GLfloat) - 0.671590,
+       (GLfloat) 1.382377, (GLfloat) 0.428753, (GLfloat) - 0.281613,
+       (GLfloat) 1.437472, (GLfloat) 0.482703, (GLfloat) - 0.328410,
+       (GLfloat) 1.423386, (GLfloat) 0.566478, (GLfloat) - 0.412500,
+       (GLfloat) 1.449724, (GLfloat) 0.556950, (GLfloat) - 0.405226,
+       (GLfloat) 1.521298, (GLfloat) 0.332708, (GLfloat) - 0.419028,
+       (GLfloat) 1.492239, (GLfloat) 0.440457, (GLfloat) - 0.412264,
+       (GLfloat) 1.327417, (GLfloat) 0.498590, (GLfloat) - 0.409500,
+       (GLfloat) 1.384841, (GLfloat) 0.546182, (GLfloat) - 0.417500,
+       (GLfloat) 1.433279, (GLfloat) 0.578472, (GLfloat) - 0.500000,
+       (GLfloat) 1.341069, (GLfloat) 0.481236, (GLfloat) - 0.294000,
+       (GLfloat) 1.392914, (GLfloat) 0.533174, (GLfloat) - 0.339125,
+       (GLfloat) 1.341069, (GLfloat) 0.481236, (GLfloat) - 0.706000,
+       (GLfloat) 1.392914, (GLfloat) 0.533174, (GLfloat) - 0.660875,
+       (GLfloat) 1.327417, (GLfloat) 0.498590, (GLfloat) - 0.590500,
+       (GLfloat) 1.384841, (GLfloat) 0.546182, (GLfloat) - 0.582500,
+       (GLfloat) 1.438984, (GLfloat) 0.272283, (GLfloat) - 0.311066,
+       (GLfloat) 1.407319, (GLfloat) 0.364926, (GLfloat) - 0.295283,
+       (GLfloat) 1.250150, (GLfloat) 0.299272, (GLfloat) - 0.281613,
+       (GLfloat) 1.316263, (GLfloat) 0.364012, (GLfloat) - 0.266014,
+       (GLfloat) 1.361260, (GLfloat) 0.466583, (GLfloat) - 0.278403,
+       (GLfloat) 1.161998, (GLfloat) 0.212951, (GLfloat) - 0.406406,
+       (GLfloat) 1.195055, (GLfloat) 0.245321, (GLfloat) - 0.328410,
+       (GLfloat) 1.219504, (GLfloat) 0.355352, (GLfloat) - 0.294000,
+       (GLfloat) 1.229040, (GLfloat) 0.331527, (GLfloat) - 0.278403,
+       (GLfloat) 1.315513, (GLfloat) 0.181646, (GLfloat) - 0.311066,
+       (GLfloat) 1.279939, (GLfloat) 0.251630, (GLfloat) - 0.295283,
+       (GLfloat) 1.201684, (GLfloat) 0.368389, (GLfloat) - 0.409500,
+       (GLfloat) 1.213173, (GLfloat) 0.368416, (GLfloat) - 0.335375,
+       (GLfloat) 1.279412, (GLfloat) 0.419138, (GLfloat) - 0.278500,
+       (GLfloat) 1.137187, (GLfloat) 0.270110, (GLfloat) - 0.412500,
+       (GLfloat) 1.169407, (GLfloat) 0.301726, (GLfloat) - 0.339125,
+       (GLfloat) 1.327792, (GLfloat) 0.487107, (GLfloat) - 0.335375,
+       (GLfloat) 1.233200, (GLfloat) 0.121222, (GLfloat) - 0.419028,
+       (GLfloat) 1.195018, (GLfloat) 0.176099, (GLfloat) - 0.412264,
+       (GLfloat) 1.161998, (GLfloat) 0.212951, (GLfloat) - 0.593594,
+       (GLfloat) 1.150979, (GLfloat) 0.202161, (GLfloat) - 0.500000,
+       (GLfloat) 1.140576, (GLfloat) 0.241160, (GLfloat) - 0.405226,
+       (GLfloat) 1.250150, (GLfloat) 0.299272, (GLfloat) - 0.718387,
+       (GLfloat) 1.195055, (GLfloat) 0.245321, (GLfloat) - 0.671590,
+       (GLfloat) 1.137187, (GLfloat) 0.270110, (GLfloat) - 0.587500,
+       (GLfloat) 1.140576, (GLfloat) 0.241160, (GLfloat) - 0.594774,
+       (GLfloat) 1.233200, (GLfloat) 0.121222, (GLfloat) - 0.580972,
+       (GLfloat) 1.195018, (GLfloat) 0.176099, (GLfloat) - 0.587736,
+       (GLfloat) 1.201684, (GLfloat) 0.368389, (GLfloat) - 0.590500,
+       (GLfloat) 1.156124, (GLfloat) 0.309340, (GLfloat) - 0.582500,
+       (GLfloat) 1.125545, (GLfloat) 0.259804, (GLfloat) - 0.500000,
+       (GLfloat) 1.219504, (GLfloat) 0.355352, (GLfloat) - 0.706000,
+       (GLfloat) 1.169407, (GLfloat) 0.301726, (GLfloat) - 0.660875,
+       (GLfloat) 1.156124, (GLfloat) 0.309340, (GLfloat) - 0.417500,
+       (GLfloat) 1.315513, (GLfloat) 0.181646, (GLfloat) - 0.688934,
+       (GLfloat) 1.279939, (GLfloat) 0.251630, (GLfloat) - 0.704717,
+       (GLfloat) 1.316263, (GLfloat) 0.364012, (GLfloat) - 0.733986,
+       (GLfloat) 1.229040, (GLfloat) 0.331527, (GLfloat) - 0.721597,
+       (GLfloat) 1.361260, (GLfloat) 0.466583, (GLfloat) - 0.721597,
+       (GLfloat) 1.438984, (GLfloat) 0.272283, (GLfloat) - 0.688934,
+       (GLfloat) 1.407319, (GLfloat) 0.364926, (GLfloat) - 0.704717,
+       (GLfloat) 1.327792, (GLfloat) 0.487107, (GLfloat) - 0.664625,
+       (GLfloat) 1.279412, (GLfloat) 0.419138, (GLfloat) - 0.721500,
+       (GLfloat) 1.213173, (GLfloat) 0.368416, (GLfloat) - 0.664625,
+       (GLfloat) 1.262552, (GLfloat) 0.435419, (GLfloat) - 0.402250,
+       (GLfloat) 1.330455, (GLfloat) 0.505735, (GLfloat) - 0.500000,
+       (GLfloat) 1.194650, (GLfloat) 0.365104, (GLfloat) - 0.500000,
+       (GLfloat) 1.262552, (GLfloat) 0.435419, (GLfloat) - 0.597750,
+       (GLfloat) 1.490430, (GLfloat) 0.310049, (GLfloat) - 0.648448,
+       (GLfloat) 1.588828, (GLfloat) 0.061527, (GLfloat) - 0.569694,
+       (GLfloat) 1.554547, (GLfloat) 0.202755, (GLfloat) - 0.574544,
+       (GLfloat) 1.531587, (GLfloat) 0.340261, (GLfloat) - 0.500000,
+       (GLfloat) 1.647861, (GLfloat) - 0.211045, (GLfloat) - 0.569694,
+       (GLfloat) 1.620986, (GLfloat) - 0.080049, (GLfloat) - 0.567663,
+       (GLfloat) 1.588828, (GLfloat) 0.061527, (GLfloat) - 0.430306,
+       (GLfloat) 1.599013, (GLfloat) 0.064899, (GLfloat) - 0.500000,
+       (GLfloat) 1.507354, (GLfloat) 0.034552, (GLfloat) - 0.662619,
+       (GLfloat) 1.558275, (GLfloat) 0.051411, (GLfloat) - 0.627772,
+       (GLfloat) 1.507354, (GLfloat) 0.034552, (GLfloat) - 0.337381,
+       (GLfloat) 1.558275, (GLfloat) 0.051411, (GLfloat) - 0.372228,
+       (GLfloat) 1.554547, (GLfloat) 0.202755, (GLfloat) - 0.425456,
+       (GLfloat) 1.647861, (GLfloat) - 0.211045, (GLfloat) - 0.430306,
+       (GLfloat) 1.620986, (GLfloat) - 0.080049, (GLfloat) - 0.432337,
+       (GLfloat) 1.490430, (GLfloat) 0.310049, (GLfloat) - 0.351552,
+       (GLfloat) 1.264067, (GLfloat) 0.143881, (GLfloat) - 0.648448,
+       (GLfloat) 1.385142, (GLfloat) - 0.005911, (GLfloat) - 0.662619,
+       (GLfloat) 1.352154, (GLfloat) 0.094180, (GLfloat) - 0.673936,
+       (GLfloat) 1.377249, (GLfloat) 0.226965, (GLfloat) - 0.702430,
+       (GLfloat) 1.421273, (GLfloat) - 0.224532, (GLfloat) - 0.662619,
+       (GLfloat) 1.409755, (GLfloat) - 0.113768, (GLfloat) - 0.657881,
+       (GLfloat) 1.446248, (GLfloat) 0.014320, (GLfloat) - 0.674234,
+       (GLfloat) 1.303667, (GLfloat) - 0.032887, (GLfloat) - 0.569694,
+       (GLfloat) 1.334220, (GLfloat) - 0.022771, (GLfloat) - 0.627772,
+       (GLfloat) 1.473590, (GLfloat) 0.159325, (GLfloat) - 0.673936,
+       (GLfloat) 1.557226, (GLfloat) - 0.216440, (GLfloat) - 0.662619,
+       (GLfloat) 1.536493, (GLfloat) - 0.093537, (GLfloat) - 0.657881,
+       (GLfloat) 1.377249, (GLfloat) 0.226965, (GLfloat) - 0.297570,
+       (GLfloat) 1.385142, (GLfloat) - 0.005911, (GLfloat) - 0.337381,
+       (GLfloat) 1.352154, (GLfloat) 0.094180, (GLfloat) - 0.326064,
+       (GLfloat) 1.264067, (GLfloat) 0.143881, (GLfloat) - 0.351552,
+       (GLfloat) 1.473590, (GLfloat) 0.159325, (GLfloat) - 0.326064,
+       (GLfloat) 1.557226, (GLfloat) - 0.216440, (GLfloat) - 0.337381,
+       (GLfloat) 1.536493, (GLfloat) - 0.093537, (GLfloat) - 0.342119,
+       (GLfloat) 1.446248, (GLfloat) 0.014320, (GLfloat) - 0.325766,
+       (GLfloat) 1.303667, (GLfloat) - 0.032887, (GLfloat) - 0.430306,
+       (GLfloat) 1.334220, (GLfloat) - 0.022771, (GLfloat) - 0.372228,
+       (GLfloat) 1.421273, (GLfloat) - 0.224532, (GLfloat) - 0.337381,
+       (GLfloat) 1.409755, (GLfloat) - 0.113768, (GLfloat) - 0.342119,
+       (GLfloat) 1.222911, (GLfloat) 0.113669, (GLfloat) - 0.500000,
+       (GLfloat) 1.271198, (GLfloat) 0.050750, (GLfloat) - 0.574544,
+       (GLfloat) 1.271198, (GLfloat) 0.050750, (GLfloat) - 0.425456,
+       (GLfloat) 1.330638, (GLfloat) - 0.229927, (GLfloat) - 0.430306,
+       (GLfloat) 1.325262, (GLfloat) - 0.127256, (GLfloat) - 0.432337,
+       (GLfloat) 1.293483, (GLfloat) - 0.036258, (GLfloat) - 0.500000,
+       (GLfloat) 1.330638, (GLfloat) - 0.229927, (GLfloat) - 0.569694,
+       (GLfloat) 1.325262, (GLfloat) - 0.127256, (GLfloat) - 0.567663,
+       (GLfloat) 1.419028, (GLfloat) - 0.429344, (GLfloat) - 0.688934,
+       (GLfloat) 1.406406, (GLfloat) - 0.569469, (GLfloat) - 0.718387,
+       (GLfloat) 1.412264, (GLfloat) - 0.510672, (GLfloat) - 0.704717,
+       (GLfloat) 1.580972, (GLfloat) - 0.429344, (GLfloat) - 0.688934,
+       (GLfloat) 1.500000, (GLfloat) - 0.429344, (GLfloat) - 0.702430,
+       (GLfloat) 1.423198, (GLfloat) - 0.331844, (GLfloat) - 0.673936,
+       (GLfloat) 1.311066, (GLfloat) - 0.429344, (GLfloat) - 0.580972,
+       (GLfloat) 1.351552, (GLfloat) - 0.429344, (GLfloat) - 0.648448,
+       (GLfloat) 1.688934, (GLfloat) - 0.429344, (GLfloat) - 0.580972,
+       (GLfloat) 1.648448, (GLfloat) - 0.429344, (GLfloat) - 0.648448,
+       (GLfloat) 1.571427, (GLfloat) - 0.329821, (GLfloat) - 0.673936,
+       (GLfloat) 1.593594, (GLfloat) - 0.569469, (GLfloat) - 0.718387,
+       (GLfloat) 1.587736, (GLfloat) - 0.510672, (GLfloat) - 0.704717,
+       (GLfloat) 1.489249, (GLfloat) - 0.220486, (GLfloat) - 0.674234,
+       (GLfloat) 1.613873, (GLfloat) - 0.213068, (GLfloat) - 0.627772,
+       (GLfloat) 1.364627, (GLfloat) - 0.227904, (GLfloat) - 0.627772,
+       (GLfloat) 1.324378, (GLfloat) - 0.333193, (GLfloat) - 0.574544,
+       (GLfloat) 1.311066, (GLfloat) - 0.429344, (GLfloat) - 0.419028,
+       (GLfloat) 1.297570, (GLfloat) - 0.429344, (GLfloat) - 0.500000,
+       (GLfloat) 1.281613, (GLfloat) - 0.569469, (GLfloat) - 0.593594,
+       (GLfloat) 1.295283, (GLfloat) - 0.510672, (GLfloat) - 0.587736,
+       (GLfloat) 1.319309, (GLfloat) - 0.230602, (GLfloat) - 0.500000,
+       (GLfloat) 1.364627, (GLfloat) - 0.227904, (GLfloat) - 0.372228,
+       (GLfloat) 1.324378, (GLfloat) - 0.333193, (GLfloat) - 0.425456,
+       (GLfloat) 1.281613, (GLfloat) - 0.569469, (GLfloat) - 0.406406,
+       (GLfloat) 1.295283, (GLfloat) - 0.510672, (GLfloat) - 0.412264,
+       (GLfloat) 1.419028, (GLfloat) - 0.429344, (GLfloat) - 0.311066,
+       (GLfloat) 1.351552, (GLfloat) - 0.429344, (GLfloat) - 0.351552,
+       (GLfloat) 1.423198, (GLfloat) - 0.331844, (GLfloat) - 0.326064,
+       (GLfloat) 1.580972, (GLfloat) - 0.429344, (GLfloat) - 0.311066,
+       (GLfloat) 1.500000, (GLfloat) - 0.429344, (GLfloat) - 0.297570,
+       (GLfloat) 1.406406, (GLfloat) - 0.569469, (GLfloat) - 0.281613,
+       (GLfloat) 1.412264, (GLfloat) - 0.510672, (GLfloat) - 0.295283,
+       (GLfloat) 1.489249, (GLfloat) - 0.220486, (GLfloat) - 0.325766,
+       (GLfloat) 1.613873, (GLfloat) - 0.213068, (GLfloat) - 0.372228,
+       (GLfloat) 1.571427, (GLfloat) - 0.329821, (GLfloat) - 0.326064,
+       (GLfloat) 1.593594, (GLfloat) - 0.569469, (GLfloat) - 0.281613,
+       (GLfloat) 1.587736, (GLfloat) - 0.510672, (GLfloat) - 0.295283,
+       (GLfloat) 1.688934, (GLfloat) - 0.429344, (GLfloat) - 0.419028,
+       (GLfloat) 1.648448, (GLfloat) - 0.429344, (GLfloat) - 0.351552,
+       (GLfloat) 1.670246, (GLfloat) - 0.328472, (GLfloat) - 0.425456,
+       (GLfloat) 1.702430, (GLfloat) - 0.429344, (GLfloat) - 0.500000,
+       (GLfloat) 1.718387, (GLfloat) - 0.569469, (GLfloat) - 0.406406,
+       (GLfloat) 1.704717, (GLfloat) - 0.510672, (GLfloat) - 0.412264,
+       (GLfloat) 1.659190, (GLfloat) - 0.210370, (GLfloat) - 0.500000,
+       (GLfloat) 1.670246, (GLfloat) - 0.328472, (GLfloat) - 0.574544,
+       (GLfloat) 1.718387, (GLfloat) - 0.569469, (GLfloat) - 0.593594,
+       (GLfloat) 1.704717, (GLfloat) - 0.510672, (GLfloat) - 0.587736,
+       (GLfloat) 1.733986, (GLfloat) - 0.569469, (GLfloat) - 0.500000,
+       (GLfloat) 1.706000, (GLfloat) - 0.633319, (GLfloat) - 0.412500,
+       (GLfloat) 1.721597, (GLfloat) - 0.609197, (GLfloat) - 0.405226,
+       (GLfloat) 1.671590, (GLfloat) - 0.569469, (GLfloat) - 0.328410,
+       (GLfloat) 1.671590, (GLfloat) - 0.569469, (GLfloat) - 0.671590,
+       (GLfloat) 1.706000, (GLfloat) - 0.633319, (GLfloat) - 0.587500,
+       (GLfloat) 1.721597, (GLfloat) - 0.609197, (GLfloat) - 0.594774,
+       (GLfloat) 1.590500, (GLfloat) - 0.655194, (GLfloat) - 0.590500,
+       (GLfloat) 1.664625, (GLfloat) - 0.646948, (GLfloat) - 0.582500,
+       (GLfloat) 1.721500, (GLfloat) - 0.634535, (GLfloat) - 0.500000,
+       (GLfloat) 1.587500, (GLfloat) - 0.633319, (GLfloat) - 0.706000,
+       (GLfloat) 1.660875, (GLfloat) - 0.632104, (GLfloat) - 0.660875,
+       (GLfloat) 1.587500, (GLfloat) - 0.633319, (GLfloat) - 0.294000,
+       (GLfloat) 1.660875, (GLfloat) - 0.632104, (GLfloat) - 0.339125,
+       (GLfloat) 1.590500, (GLfloat) - 0.655194, (GLfloat) - 0.409500,
+       (GLfloat) 1.664625, (GLfloat) - 0.646948, (GLfloat) - 0.417500,
+       (GLfloat) 1.500000, (GLfloat) - 0.569469, (GLfloat) - 0.733986,
+       (GLfloat) 1.594774, (GLfloat) - 0.609197, (GLfloat) - 0.721597,
+       (GLfloat) 1.328410, (GLfloat) - 0.569469, (GLfloat) - 0.671590,
+       (GLfloat) 1.412500, (GLfloat) - 0.633319, (GLfloat) - 0.706000,
+       (GLfloat) 1.405226, (GLfloat) - 0.609197, (GLfloat) - 0.721597,
+       (GLfloat) 1.409500, (GLfloat) - 0.655194, (GLfloat) - 0.590500,
+       (GLfloat) 1.417500, (GLfloat) - 0.646948, (GLfloat) - 0.664625,
+       (GLfloat) 1.500000, (GLfloat) - 0.634535, (GLfloat) - 0.721500,
+       (GLfloat) 1.294000, (GLfloat) - 0.633319, (GLfloat) - 0.587500,
+       (GLfloat) 1.339125, (GLfloat) - 0.632104, (GLfloat) - 0.660875,
+       (GLfloat) 1.582500, (GLfloat) - 0.646948, (GLfloat) - 0.664625,
+       (GLfloat) 1.266014, (GLfloat) - 0.569469, (GLfloat) - 0.500000,
+       (GLfloat) 1.278403, (GLfloat) - 0.609197, (GLfloat) - 0.594774,
+       (GLfloat) 1.328410, (GLfloat) - 0.569469, (GLfloat) - 0.328410,
+       (GLfloat) 1.294000, (GLfloat) - 0.633319, (GLfloat) - 0.412500,
+       (GLfloat) 1.278403, (GLfloat) - 0.609197, (GLfloat) - 0.405226,
+       (GLfloat) 1.409500, (GLfloat) - 0.655194, (GLfloat) - 0.409500,
+       (GLfloat) 1.335375, (GLfloat) - 0.646948, (GLfloat) - 0.417500,
+       (GLfloat) 1.278500, (GLfloat) - 0.634535, (GLfloat) - 0.500000,
+       (GLfloat) 1.412500, (GLfloat) - 0.633319, (GLfloat) - 0.294000,
+       (GLfloat) 1.339125, (GLfloat) - 0.632104, (GLfloat) - 0.339125,
+       (GLfloat) 1.335375, (GLfloat) - 0.646948, (GLfloat) - 0.582500,
+       (GLfloat) 1.500000, (GLfloat) - 0.569469, (GLfloat) - 0.266014,
+       (GLfloat) 1.405226, (GLfloat) - 0.609197, (GLfloat) - 0.278403,
+       (GLfloat) 1.594774, (GLfloat) - 0.609197, (GLfloat) - 0.278403,
+       (GLfloat) 1.582500, (GLfloat) - 0.646948, (GLfloat) - 0.335375,
+       (GLfloat) 1.500000, (GLfloat) - 0.634535, (GLfloat) - 0.278500,
+       (GLfloat) 1.417500, (GLfloat) - 0.646948, (GLfloat) - 0.335375,
+       (GLfloat) 1.500000, (GLfloat) - 0.657972, (GLfloat) - 0.597750,
+       (GLfloat) 1.597750, (GLfloat) - 0.657972, (GLfloat) - 0.500000,
+       (GLfloat) 1.402250, (GLfloat) - 0.657972, (GLfloat) - 0.500000,
+       (GLfloat) 1.500000, (GLfloat) - 0.657972, (GLfloat) - 0.402250,
+};
+
+static GLfloat s1_6_normals[] =
+{
+       (GLfloat) 0.863661, (GLfloat) 0.210849, (GLfloat) - 0.457857,
+       (GLfloat) 0.863729, (GLfloat) 0.215548, (GLfloat) - 0.455534,
+       (GLfloat) 0.952947, (GLfloat) 0.267284, (GLfloat) - 0.143006,
+       (GLfloat) 0.953156, (GLfloat) 0.266032, (GLfloat) - 0.143950,
+       (GLfloat) 0.887569, (GLfloat) 0.433517, (GLfloat) - 0.155833,
+       (GLfloat) 0.886526, (GLfloat) 0.436070, (GLfloat) - 0.154645,
+       (GLfloat) 0.784332, (GLfloat) 0.380163, (GLfloat) - 0.490203,
+       (GLfloat) 0.785458, (GLfloat) 0.376379, (GLfloat) - 0.491319,
+       (GLfloat) 0.863661, (GLfloat) 0.210849, (GLfloat) 0.457857,
+       (GLfloat) 0.863729, (GLfloat) 0.215548, (GLfloat) 0.455534,
+       (GLfloat) 0.785458, (GLfloat) 0.376379, (GLfloat) 0.491319,
+       (GLfloat) 0.784333, (GLfloat) 0.380162, (GLfloat) 0.490203,
+       (GLfloat) 0.887569, (GLfloat) 0.433517, (GLfloat) 0.155833,
+       (GLfloat) 0.886526, (GLfloat) 0.436070, (GLfloat) 0.154645,
+       (GLfloat) 0.953156, (GLfloat) 0.266032, (GLfloat) 0.143950,
+       (GLfloat) 0.952947, (GLfloat) 0.267284, (GLfloat) 0.143006,
+       (GLfloat) - 0.476698, (GLfloat) 0.854621, (GLfloat) 0.205866,
+       (GLfloat) - 0.498450, (GLfloat) 0.848428, (GLfloat) 0.178092,
+       (GLfloat) - 0.462000, (GLfloat) 0.884194, (GLfloat) 0.068965,
+       (GLfloat) - 0.472068, (GLfloat) 0.878521, (GLfloat) 0.073162,
+       (GLfloat) 0.299348, (GLfloat) 0.942240, (GLfloat) 0.150245,
+       (GLfloat) 0.334834, (GLfloat) 0.927714, (GLfloat) 0.165022,
+       (GLfloat) 0.146237, (GLfloat) 0.884155, (GLfloat) 0.443716,
+       (GLfloat) 0.183286, (GLfloat) 0.864289, (GLfloat) 0.468413,
+       (GLfloat) - 0.498450, (GLfloat) 0.848429, (GLfloat) - 0.178092,
+       (GLfloat) - 0.476698, (GLfloat) 0.854621, (GLfloat) - 0.205865,
+       (GLfloat) 0.146237, (GLfloat) 0.884155, (GLfloat) - 0.443716,
+       (GLfloat) 0.183286, (GLfloat) 0.864289, (GLfloat) - 0.468413,
+       (GLfloat) 0.334834, (GLfloat) 0.927714, (GLfloat) - 0.165022,
+       (GLfloat) 0.299348, (GLfloat) 0.942240, (GLfloat) - 0.150245,
+       (GLfloat) - 0.472068, (GLfloat) 0.878521, (GLfloat) - 0.073162,
+       (GLfloat) - 0.462000, (GLfloat) 0.884194, (GLfloat) - 0.068965,
+       (GLfloat) 0.601151, (GLfloat) 0.064321, (GLfloat) 0.796542,
+       (GLfloat) 0.602133, (GLfloat) 0.074603, (GLfloat) 0.794903,
+       (GLfloat) 0.305416, (GLfloat) - 0.098916, (GLfloat) 0.947067,
+       (GLfloat) 0.305705, (GLfloat) - 0.083664, (GLfloat) 0.948443,
+       (GLfloat) 0.204663, (GLfloat) 0.031235, (GLfloat) 0.978334,
+       (GLfloat) 0.206924, (GLfloat) 0.024347, (GLfloat) 0.978054,
+       (GLfloat) 0.503723, (GLfloat) 0.214462, (GLfloat) 0.836821,
+       (GLfloat) 0.504738, (GLfloat) 0.210719, (GLfloat) 0.837160,
+       (GLfloat) - 0.295242, (GLfloat) - 0.450841, (GLfloat) 0.842363,
+       (GLfloat) - 0.299933, (GLfloat) - 0.431633, (GLfloat) 0.850725,
+       (GLfloat) - 0.391261, (GLfloat) - 0.341115, (GLfloat) 0.854725,
+       (GLfloat) - 0.390827, (GLfloat) - 0.342109, (GLfloat) 0.854527,
+       (GLfloat) - 0.083295, (GLfloat) - 0.151964, (GLfloat) 0.984870,
+       (GLfloat) - 0.083124, (GLfloat) - 0.152402, (GLfloat) 0.984817,
+       (GLfloat) 0.015860, (GLfloat) - 0.266588, (GLfloat) 0.963680,
+       (GLfloat) 0.013989, (GLfloat) - 0.247700, (GLfloat) 0.968736,
+       (GLfloat) - 0.816724, (GLfloat) 0.502516, (GLfloat) 0.283619,
+       (GLfloat) - 0.805591, (GLfloat) 0.530375, (GLfloat) 0.264055,
+       (GLfloat) - 0.732550, (GLfloat) 0.603459, (GLfloat) 0.314971,
+       (GLfloat) - 0.730076, (GLfloat) 0.611620, (GLfloat) 0.304811,
+       (GLfloat) - 0.516849, (GLfloat) 0.314381, (GLfloat) 0.796261,
+       (GLfloat) - 0.502724, (GLfloat) 0.272837, (GLfloat) 0.820261,
+       (GLfloat) - 0.744687, (GLfloat) 0.181500, (GLfloat) 0.642261,
+       (GLfloat) - 0.739362, (GLfloat) 0.135764, (GLfloat) 0.659478,
+       (GLfloat) - 0.549371, (GLfloat) 0.797029, (GLfloat) 0.250869,
+       (GLfloat) - 0.542332, (GLfloat) 0.789948, (GLfloat) 0.286109,
+       (GLfloat) - 0.086395, (GLfloat) 0.693389, (GLfloat) 0.715365,
+       (GLfloat) - 0.059539, (GLfloat) 0.687907, (GLfloat) 0.723353,
+       (GLfloat) - 0.265868, (GLfloat) 0.473566, (GLfloat) 0.839672,
+       (GLfloat) - 0.289224, (GLfloat) 0.481874, (GLfloat) 0.827131,
+       (GLfloat) - 0.628658, (GLfloat) 0.711043, (GLfloat) 0.314972,
+       (GLfloat) - 0.636726, (GLfloat) 0.708286, (GLfloat) 0.304813,
+       (GLfloat) - 0.602622, (GLfloat) - 0.619862, (GLfloat) 0.502612,
+       (GLfloat) - 0.608832, (GLfloat) - 0.607495, (GLfloat) 0.510170,
+       (GLfloat) - 0.718752, (GLfloat) - 0.676658, (GLfloat) 0.159776,
+       (GLfloat) - 0.721882, (GLfloat) - 0.672658, (GLfloat) 0.162535,
+       (GLfloat) - 0.782122, (GLfloat) - 0.600854, (GLfloat) 0.165107,
+       (GLfloat) - 0.776469, (GLfloat) - 0.609074, (GLfloat) 0.161631,
+       (GLfloat) - 0.682182, (GLfloat) - 0.521915, (GLfloat) 0.512086,
+       (GLfloat) - 0.675579, (GLfloat) - 0.534280, (GLfloat) 0.508073,
+       (GLfloat) - 0.608832, (GLfloat) - 0.607495, (GLfloat) - 0.510170,
+       (GLfloat) - 0.602622, (GLfloat) - 0.619862, (GLfloat) - 0.502612,
+       (GLfloat) - 0.682182, (GLfloat) - 0.521915, (GLfloat) - 0.512086,
+       (GLfloat) - 0.675579, (GLfloat) - 0.534280, (GLfloat) - 0.508073,
+       (GLfloat) - 0.776469, (GLfloat) - 0.609074, (GLfloat) - 0.161631,
+       (GLfloat) - 0.782122, (GLfloat) - 0.600854, (GLfloat) - 0.165107,
+       (GLfloat) - 0.718752, (GLfloat) - 0.676658, (GLfloat) - 0.159776,
+       (GLfloat) - 0.721882, (GLfloat) - 0.672658, (GLfloat) - 0.162535,
+       (GLfloat) - 0.870738, (GLfloat) 0.446582, (GLfloat) - 0.205866,
+       (GLfloat) - 0.865307, (GLfloat) 0.468537, (GLfloat) - 0.178091,
+       (GLfloat) - 0.899779, (GLfloat) 0.430861, (GLfloat) - 0.068965,
+       (GLfloat) - 0.894461, (GLfloat) 0.441120, (GLfloat) - 0.073162,
+       (GLfloat) - 0.988176, (GLfloat) - 0.083362, (GLfloat) - 0.128682,
+       (GLfloat) - 0.982213, (GLfloat) - 0.119589, (GLfloat) - 0.144763,
+       (GLfloat) - 0.919779, (GLfloat) 0.029098, (GLfloat) - 0.391357,
+       (GLfloat) - 0.919364, (GLfloat) - 0.008818, (GLfloat) - 0.393310,
+       (GLfloat) - 0.865307, (GLfloat) 0.468537, (GLfloat) 0.178091,
+       (GLfloat) - 0.870738, (GLfloat) 0.446582, (GLfloat) 0.205866,
+       (GLfloat) - 0.919364, (GLfloat) - 0.008818, (GLfloat) 0.393310,
+       (GLfloat) - 0.919779, (GLfloat) 0.029098, (GLfloat) 0.391357,
+       (GLfloat) - 0.982213, (GLfloat) - 0.119589, (GLfloat) 0.144763,
+       (GLfloat) - 0.988176, (GLfloat) - 0.083362, (GLfloat) 0.128682,
+       (GLfloat) - 0.894461, (GLfloat) 0.441120, (GLfloat) 0.073162,
+       (GLfloat) - 0.899779, (GLfloat) 0.430861, (GLfloat) 0.068965,
+       (GLfloat) - 0.295242, (GLfloat) - 0.450841, (GLfloat) - 0.842362,
+       (GLfloat) - 0.299933, (GLfloat) - 0.431632, (GLfloat) - 0.850725,
+       (GLfloat) 0.013989, (GLfloat) - 0.247700, (GLfloat) - 0.968736,
+       (GLfloat) 0.015860, (GLfloat) - 0.266588, (GLfloat) - 0.963680,
+       (GLfloat) - 0.083295, (GLfloat) - 0.151964, (GLfloat) - 0.984870,
+       (GLfloat) - 0.083124, (GLfloat) - 0.152402, (GLfloat) - 0.984817,
+       (GLfloat) - 0.390828, (GLfloat) - 0.342108, (GLfloat) - 0.854527,
+       (GLfloat) - 0.391261, (GLfloat) - 0.341115, (GLfloat) - 0.854725,
+       (GLfloat) 0.602133, (GLfloat) 0.074603, (GLfloat) - 0.794903,
+       (GLfloat) 0.601151, (GLfloat) 0.064322, (GLfloat) - 0.796542,
+       (GLfloat) 0.503722, (GLfloat) 0.214463, (GLfloat) - 0.836821,
+       (GLfloat) 0.504737, (GLfloat) 0.210719, (GLfloat) - 0.837161,
+       (GLfloat) 0.206924, (GLfloat) 0.024347, (GLfloat) - 0.978054,
+       (GLfloat) 0.204663, (GLfloat) 0.031235, (GLfloat) - 0.978334,
+       (GLfloat) 0.305416, (GLfloat) - 0.098916, (GLfloat) - 0.947067,
+       (GLfloat) 0.305705, (GLfloat) - 0.083664, (GLfloat) - 0.948443,
+       (GLfloat) - 0.549371, (GLfloat) 0.797029, (GLfloat) - 0.250870,
+       (GLfloat) - 0.542332, (GLfloat) 0.789948, (GLfloat) - 0.286110,
+       (GLfloat) - 0.628658, (GLfloat) 0.711043, (GLfloat) - 0.314972,
+       (GLfloat) - 0.636726, (GLfloat) 0.708286, (GLfloat) - 0.304813,
+       (GLfloat) - 0.289225, (GLfloat) 0.481875, (GLfloat) - 0.827131,
+       (GLfloat) - 0.265869, (GLfloat) 0.473567, (GLfloat) - 0.839672,
+       (GLfloat) - 0.086396, (GLfloat) 0.693390, (GLfloat) - 0.715365,
+       (GLfloat) - 0.059540, (GLfloat) 0.687907, (GLfloat) - 0.723352,
+       (GLfloat) - 0.805592, (GLfloat) 0.530374, (GLfloat) - 0.264056,
+       (GLfloat) - 0.816724, (GLfloat) 0.502516, (GLfloat) - 0.283619,
+       (GLfloat) - 0.744687, (GLfloat) 0.181500, (GLfloat) - 0.642260,
+       (GLfloat) - 0.739363, (GLfloat) 0.135764, (GLfloat) - 0.659478,
+       (GLfloat) - 0.502724, (GLfloat) 0.272838, (GLfloat) - 0.820261,
+       (GLfloat) - 0.516850, (GLfloat) 0.314382, (GLfloat) - 0.796260,
+       (GLfloat) - 0.732550, (GLfloat) 0.603460, (GLfloat) - 0.314971,
+       (GLfloat) - 0.730076, (GLfloat) 0.611620, (GLfloat) - 0.304812,
+       (GLfloat) - 0.612735, (GLfloat) 0.780498, (GLfloat) 0.124010,
+       (GLfloat) - 0.620926, (GLfloat) 0.772016, (GLfloat) 0.135801,
+       (GLfloat) - 0.683860, (GLfloat) 0.721331, (GLfloat) 0.109621,
+       (GLfloat) - 0.686475, (GLfloat) 0.718049, (GLfloat) 0.114708,
+       (GLfloat) - 0.697666, (GLfloat) 0.715659, (GLfloat) 0.033080,
+       (GLfloat) - 0.695640, (GLfloat) 0.717757, (GLfloat) 0.030164,
+       (GLfloat) - 0.638159, (GLfloat) 0.768656, (GLfloat) 0.043833,
+       (GLfloat) - 0.634338, (GLfloat) 0.772038, (GLfloat) 0.039657,
+       (GLfloat) - 0.793216, (GLfloat) 0.593605, (GLfloat) 0.135802,
+       (GLfloat) - 0.801406, (GLfloat) 0.585123, (GLfloat) 0.124011,
+       (GLfloat) - 0.790459, (GLfloat) 0.610945, (GLfloat) 0.043833,
+       (GLfloat) - 0.793705, (GLfloat) 0.607008, (GLfloat) 0.039656,
+       (GLfloat) - 0.741597, (GLfloat) 0.670167, (GLfloat) 0.030164,
+       (GLfloat) - 0.739572, (GLfloat) 0.672265, (GLfloat) 0.033079,
+       (GLfloat) - 0.744759, (GLfloat) 0.658269, (GLfloat) 0.109621,
+       (GLfloat) - 0.741569, (GLfloat) 0.660997, (GLfloat) 0.114710,
+       (GLfloat) - 0.801406, (GLfloat) 0.585123, (GLfloat) - 0.124011,
+       (GLfloat) - 0.793216, (GLfloat) 0.593605, (GLfloat) - 0.135802,
+       (GLfloat) - 0.744759, (GLfloat) 0.658269, (GLfloat) - 0.109621,
+       (GLfloat) - 0.741569, (GLfloat) 0.660997, (GLfloat) - 0.114710,
+       (GLfloat) - 0.739572, (GLfloat) 0.672265, (GLfloat) - 0.033079,
+       (GLfloat) - 0.741597, (GLfloat) 0.670167, (GLfloat) - 0.030164,
+       (GLfloat) - 0.790459, (GLfloat) 0.610945, (GLfloat) - 0.043833,
+       (GLfloat) - 0.793705, (GLfloat) 0.607008, (GLfloat) - 0.039656,
+       (GLfloat) - 0.620926, (GLfloat) 0.772016, (GLfloat) - 0.135801,
+       (GLfloat) - 0.612735, (GLfloat) 0.780498, (GLfloat) - 0.124010,
+       (GLfloat) - 0.638159, (GLfloat) 0.768656, (GLfloat) - 0.043833,
+       (GLfloat) - 0.634338, (GLfloat) 0.772038, (GLfloat) - 0.039657,
+       (GLfloat) - 0.695640, (GLfloat) 0.717757, (GLfloat) - 0.030164,
+       (GLfloat) - 0.697666, (GLfloat) 0.715659, (GLfloat) - 0.033080,
+       (GLfloat) - 0.683860, (GLfloat) 0.721331, (GLfloat) - 0.109621,
+       (GLfloat) - 0.686475, (GLfloat) 0.718049, (GLfloat) - 0.114708,
+       (GLfloat) 0.864441, (GLfloat) 0.198220, (GLfloat) - 0.462008,
+       (GLfloat) 0.865832, (GLfloat) 0.204848, (GLfloat) - 0.456478,
+       (GLfloat) 0.861398, (GLfloat) 0.190399, (GLfloat) - 0.470894,
+       (GLfloat) 0.864411, (GLfloat) 0.198309, (GLfloat) - 0.462024,
+       (GLfloat) 0.959873, (GLfloat) 0.240404, (GLfloat) - 0.144397,
+       (GLfloat) 0.959903, (GLfloat) 0.238290, (GLfloat) - 0.147664,
+       (GLfloat) 0.957414, (GLfloat) 0.250909, (GLfloat) - 0.142837,
+       (GLfloat) 0.957562, (GLfloat) 0.249145, (GLfloat) - 0.144919,
+       (GLfloat) 0.850599, (GLfloat) 0.179835, (GLfloat) - 0.494106,
+       (GLfloat) 0.855506, (GLfloat) 0.187394, (GLfloat) - 0.482693,
+       (GLfloat) 0.963921, (GLfloat) 0.218904, (GLfloat) - 0.151448,
+       (GLfloat) 0.963730, (GLfloat) 0.216664, (GLfloat) - 0.155826,
+       (GLfloat) 0.961835, (GLfloat) 0.230558, (GLfloat) - 0.147363,
+       (GLfloat) 0.961732, (GLfloat) 0.228244, (GLfloat) - 0.151580,
+       (GLfloat) 0.856249, (GLfloat) 0.184340, (GLfloat) - 0.482552,
+       (GLfloat) 0.860720, (GLfloat) 0.192749, (GLfloat) - 0.471178,
+       (GLfloat) 0.850599, (GLfloat) 0.179835, (GLfloat) 0.494106,
+       (GLfloat) 0.855506, (GLfloat) 0.187394, (GLfloat) 0.482693,
+       (GLfloat) 0.860720, (GLfloat) 0.192749, (GLfloat) 0.471179,
+       (GLfloat) 0.856249, (GLfloat) 0.184340, (GLfloat) 0.482552,
+       (GLfloat) 0.961835, (GLfloat) 0.230558, (GLfloat) 0.147363,
+       (GLfloat) 0.961732, (GLfloat) 0.228244, (GLfloat) 0.151580,
+       (GLfloat) 0.963730, (GLfloat) 0.216664, (GLfloat) 0.155826,
+       (GLfloat) 0.963921, (GLfloat) 0.218904, (GLfloat) 0.151448,
+       (GLfloat) 0.865832, (GLfloat) 0.204848, (GLfloat) 0.456478,
+       (GLfloat) 0.864441, (GLfloat) 0.198220, (GLfloat) 0.462008,
+       (GLfloat) 0.957414, (GLfloat) 0.250909, (GLfloat) 0.142837,
+       (GLfloat) 0.957562, (GLfloat) 0.249144, (GLfloat) 0.144919,
+       (GLfloat) 0.959903, (GLfloat) 0.238290, (GLfloat) 0.147664,
+       (GLfloat) 0.959873, (GLfloat) 0.240404, (GLfloat) 0.144397,
+       (GLfloat) 0.861398, (GLfloat) 0.190399, (GLfloat) 0.470894,
+       (GLfloat) 0.864411, (GLfloat) 0.198309, (GLfloat) 0.462024,
+       (GLfloat) - 0.368470, (GLfloat) - 0.398468, (GLfloat) - 0.839912,
+       (GLfloat) - 0.366469, (GLfloat) - 0.378022, (GLfloat) - 0.850177,
+       (GLfloat) - 0.433076, (GLfloat) - 0.339336, (GLfloat) - 0.835043,
+       (GLfloat) - 0.426924, (GLfloat) - 0.323639, (GLfloat) - 0.844390,
+       (GLfloat) - 0.078376, (GLfloat) - 0.184951, (GLfloat) - 0.979617,
+       (GLfloat) - 0.089636, (GLfloat) - 0.204692, (GLfloat) - 0.974714,
+       (GLfloat) - 0.031836, (GLfloat) - 0.216104, (GLfloat) - 0.975851,
+       (GLfloat) - 0.037496, (GLfloat) - 0.237942, (GLfloat) - 0.970555,
+       (GLfloat) - 0.516334, (GLfloat) - 0.149595, (GLfloat) - 0.843220,
+       (GLfloat) - 0.522141, (GLfloat) - 0.155987, (GLfloat) - 0.838473,
+       (GLfloat) - 0.160863, (GLfloat) - 0.078983, (GLfloat) - 0.983811,
+       (GLfloat) - 0.162216, (GLfloat) - 0.080222, (GLfloat) - 0.983489,
+       (GLfloat) - 0.124313, (GLfloat) - 0.142798, (GLfloat) - 0.981914,
+       (GLfloat) - 0.134702, (GLfloat) - 0.155051, (GLfloat) - 0.978680,
+       (GLfloat) - 0.485511, (GLfloat) - 0.259251, (GLfloat) - 0.834906,
+       (GLfloat) - 0.481803, (GLfloat) - 0.253626, (GLfloat) - 0.838773,
+       (GLfloat) 0.539229, (GLfloat) 0.099743, (GLfloat) - 0.836232,
+       (GLfloat) 0.527244, (GLfloat) 0.088685, (GLfloat) - 0.845073,
+       (GLfloat) 0.560111, (GLfloat) 0.087128, (GLfloat) - 0.823823,
+       (GLfloat) 0.546849, (GLfloat) 0.072324, (GLfloat) - 0.834101,
+       (GLfloat) 0.201167, (GLfloat) - 0.045810, (GLfloat) - 0.978485,
+       (GLfloat) 0.215853, (GLfloat) - 0.030110, (GLfloat) - 0.975962,
+       (GLfloat) 0.175573, (GLfloat) - 0.002365, (GLfloat) - 0.984464,
+       (GLfloat) 0.184916, (GLfloat) 0.005715, (GLfloat) - 0.982738,
+       (GLfloat) 0.593439, (GLfloat) 0.077285, (GLfloat) - 0.801160,
+       (GLfloat) 0.587937, (GLfloat) 0.063575, (GLfloat) - 0.806405,
+       (GLfloat) 0.272897, (GLfloat) - 0.086428, (GLfloat) - 0.958153,
+       (GLfloat) 0.279890, (GLfloat) - 0.067483, (GLfloat) - 0.957657,
+       (GLfloat) 0.236530, (GLfloat) - 0.071307, (GLfloat) - 0.969004,
+       (GLfloat) 0.249518, (GLfloat) - 0.051953, (GLfloat) - 0.966975,
+       (GLfloat) 0.579087, (GLfloat) 0.080825, (GLfloat) - 0.811250,
+       (GLfloat) 0.568834, (GLfloat) 0.065408, (GLfloat) - 0.819847,
+       (GLfloat) - 0.366469, (GLfloat) - 0.378021, (GLfloat) 0.850177,
+       (GLfloat) - 0.368470, (GLfloat) - 0.398468, (GLfloat) 0.839912,
+       (GLfloat) - 0.031836, (GLfloat) - 0.216104, (GLfloat) 0.975851,
+       (GLfloat) - 0.037496, (GLfloat) - 0.237942, (GLfloat) 0.970555,
+       (GLfloat) - 0.089636, (GLfloat) - 0.204692, (GLfloat) 0.974714,
+       (GLfloat) - 0.078376, (GLfloat) - 0.184951, (GLfloat) 0.979617,
+       (GLfloat) - 0.433076, (GLfloat) - 0.339336, (GLfloat) 0.835043,
+       (GLfloat) - 0.426924, (GLfloat) - 0.323639, (GLfloat) 0.844389,
+       (GLfloat) 0.593439, (GLfloat) 0.077284, (GLfloat) 0.801160,
+       (GLfloat) 0.587937, (GLfloat) 0.063575, (GLfloat) 0.806405,
+       (GLfloat) 0.568834, (GLfloat) 0.065408, (GLfloat) 0.819847,
+       (GLfloat) 0.579087, (GLfloat) 0.080825, (GLfloat) 0.811249,
+       (GLfloat) 0.236530, (GLfloat) - 0.071307, (GLfloat) 0.969004,
+       (GLfloat) 0.249518, (GLfloat) - 0.051953, (GLfloat) 0.966975,
+       (GLfloat) 0.279890, (GLfloat) - 0.067483, (GLfloat) 0.957657,
+       (GLfloat) 0.272897, (GLfloat) - 0.086428, (GLfloat) 0.958153,
+       (GLfloat) 0.527244, (GLfloat) 0.088685, (GLfloat) 0.845073,
+       (GLfloat) 0.539229, (GLfloat) 0.099743, (GLfloat) 0.836232,
+       (GLfloat) 0.175573, (GLfloat) - 0.002365, (GLfloat) 0.984464,
+       (GLfloat) 0.184916, (GLfloat) 0.005715, (GLfloat) 0.982738,
+       (GLfloat) 0.215853, (GLfloat) - 0.030110, (GLfloat) 0.975962,
+       (GLfloat) 0.201167, (GLfloat) - 0.045810, (GLfloat) 0.978485,
+       (GLfloat) 0.560111, (GLfloat) 0.087128, (GLfloat) 0.823823,
+       (GLfloat) 0.546849, (GLfloat) 0.072324, (GLfloat) 0.834101,
+       (GLfloat) - 0.516334, (GLfloat) - 0.149595, (GLfloat) 0.843220,
+       (GLfloat) - 0.522141, (GLfloat) - 0.155986, (GLfloat) 0.838473,
+       (GLfloat) - 0.481803, (GLfloat) - 0.253626, (GLfloat) 0.838773,
+       (GLfloat) - 0.485511, (GLfloat) - 0.259250, (GLfloat) 0.834906,
+       (GLfloat) - 0.124313, (GLfloat) - 0.142798, (GLfloat) 0.981914,
+       (GLfloat) - 0.134702, (GLfloat) - 0.155051, (GLfloat) 0.978680,
+       (GLfloat) - 0.162216, (GLfloat) - 0.080222, (GLfloat) 0.983489,
+       (GLfloat) - 0.160863, (GLfloat) - 0.078982, (GLfloat) 0.983811,
+       (GLfloat) - 0.686861, (GLfloat) - 0.525025, (GLfloat) - 0.502564,
+       (GLfloat) - 0.684324, (GLfloat) - 0.536936, (GLfloat) - 0.493357,
+       (GLfloat) - 0.799089, (GLfloat) - 0.580700, (GLfloat) - 0.155709,
+       (GLfloat) - 0.801122, (GLfloat) - 0.576989, (GLfloat) - 0.159016,
+       (GLfloat) - 0.862913, (GLfloat) - 0.481876, (GLfloat) - 0.152238,
+       (GLfloat) - 0.863678, (GLfloat) - 0.479780, (GLfloat) - 0.154502,
+       (GLfloat) - 0.750556, (GLfloat) - 0.441554, (GLfloat) - 0.491625,
+       (GLfloat) - 0.750719, (GLfloat) - 0.448983, (GLfloat) - 0.484598,
+       (GLfloat) - 0.686861, (GLfloat) - 0.525025, (GLfloat) 0.502564,
+       (GLfloat) - 0.684324, (GLfloat) - 0.536936, (GLfloat) 0.493357,
+       (GLfloat) - 0.750719, (GLfloat) - 0.448983, (GLfloat) 0.484598,
+       (GLfloat) - 0.750556, (GLfloat) - 0.441554, (GLfloat) 0.491625,
+       (GLfloat) - 0.862913, (GLfloat) - 0.481876, (GLfloat) 0.152238,
+       (GLfloat) - 0.863678, (GLfloat) - 0.479780, (GLfloat) 0.154503,
+       (GLfloat) - 0.801122, (GLfloat) - 0.576990, (GLfloat) 0.159016,
+       (GLfloat) - 0.799089, (GLfloat) - 0.580700, (GLfloat) 0.155709,
+       (GLfloat) - 0.845506, (GLfloat) - 0.204102, (GLfloat) 0.493419,
+       (GLfloat) - 0.849139, (GLfloat) - 0.212205, (GLfloat) 0.483666,
+       (GLfloat) - 0.962881, (GLfloat) - 0.220433, (GLfloat) 0.155789,
+       (GLfloat) - 0.962834, (GLfloat) - 0.223594, (GLfloat) 0.151516,
+       (GLfloat) - 0.918492, (GLfloat) - 0.365350, (GLfloat) 0.151297,
+       (GLfloat) - 0.918584, (GLfloat) - 0.364876, (GLfloat) 0.151885,
+       (GLfloat) - 0.806201, (GLfloat) - 0.341087, (GLfloat) 0.483425,
+       (GLfloat) - 0.806184, (GLfloat) - 0.341015, (GLfloat) 0.483504,
+       (GLfloat) - 0.849139, (GLfloat) - 0.212204, (GLfloat) - 0.483666,
+       (GLfloat) - 0.845506, (GLfloat) - 0.204102, (GLfloat) - 0.493419,
+       (GLfloat) - 0.806201, (GLfloat) - 0.341087, (GLfloat) - 0.483425,
+       (GLfloat) - 0.806184, (GLfloat) - 0.341015, (GLfloat) - 0.483504,
+       (GLfloat) - 0.918584, (GLfloat) - 0.364876, (GLfloat) - 0.151885,
+       (GLfloat) - 0.918492, (GLfloat) - 0.365350, (GLfloat) - 0.151297,
+       (GLfloat) - 0.962881, (GLfloat) - 0.220433, (GLfloat) - 0.155789,
+       (GLfloat) - 0.962834, (GLfloat) - 0.223594, (GLfloat) - 0.151516,
+       (GLfloat) - 0.503594, (GLfloat) 0.204765, (GLfloat) - 0.839324,
+       (GLfloat) - 0.503594, (GLfloat) 0.204765, (GLfloat) - 0.839324,
+       (GLfloat) - 0.161047, (GLfloat) 0.200914, (GLfloat) - 0.966280,
+       (GLfloat) - 0.161047, (GLfloat) 0.200914, (GLfloat) - 0.966280,
+       (GLfloat) - 0.165393, (GLfloat) 0.154386, (GLfloat) - 0.974069,
+       (GLfloat) - 0.162365, (GLfloat) 0.156806, (GLfloat) - 0.974192,
+       (GLfloat) - 0.508257, (GLfloat) 0.155255, (GLfloat) - 0.847095,
+       (GLfloat) - 0.512203, (GLfloat) 0.151943, (GLfloat) - 0.845318,
+       (GLfloat) 0.503594, (GLfloat) 0.204765, (GLfloat) - 0.839324,
+       (GLfloat) 0.503594, (GLfloat) 0.204765, (GLfloat) - 0.839324,
+       (GLfloat) 0.506875, (GLfloat) 0.175794, (GLfloat) - 0.843904,
+       (GLfloat) 0.506455, (GLfloat) 0.176110, (GLfloat) - 0.844091,
+       (GLfloat) 0.160943, (GLfloat) 0.163176, (GLfloat) - 0.973381,
+       (GLfloat) 0.162221, (GLfloat) 0.162243, (GLfloat) - 0.973325,
+       (GLfloat) 0.161047, (GLfloat) 0.200914, (GLfloat) - 0.966280,
+       (GLfloat) 0.161047, (GLfloat) 0.200914, (GLfloat) - 0.966280,
+       (GLfloat) 0.521791, (GLfloat) 0.120579, (GLfloat) - 0.844509,
+       (GLfloat) 0.514604, (GLfloat) 0.123502, (GLfloat) - 0.848487,
+       (GLfloat) 0.164688, (GLfloat) 0.065494, (GLfloat) - 0.984169,
+       (GLfloat) 0.164274, (GLfloat) 0.065656, (GLfloat) - 0.984227,
+       (GLfloat) 0.162599, (GLfloat) 0.118143, (GLfloat) - 0.979594,
+       (GLfloat) 0.160323, (GLfloat) 0.119382, (GLfloat) - 0.979819,
+       (GLfloat) 0.509344, (GLfloat) 0.149891, (GLfloat) - 0.847409,
+       (GLfloat) 0.511715, (GLfloat) 0.148557, (GLfloat) - 0.846214,
+       (GLfloat) - 0.523595, (GLfloat) - 0.008036, (GLfloat) - 0.851929,
+       (GLfloat) - 0.537099, (GLfloat) - 0.019782, (GLfloat) - 0.843287,
+       (GLfloat) - 0.515557, (GLfloat) 0.088028, (GLfloat) - 0.852322,
+       (GLfloat) - 0.525730, (GLfloat) 0.079884, (GLfloat) - 0.846892,
+       (GLfloat) - 0.173169, (GLfloat) 0.095066, (GLfloat) - 0.980293,
+       (GLfloat) - 0.165823, (GLfloat) 0.100484, (GLfloat) - 0.981023,
+       (GLfloat) - 0.177991, (GLfloat) 0.018184, (GLfloat) - 0.983864,
+       (GLfloat) - 0.169802, (GLfloat) 0.024484, (GLfloat) - 0.985174,
+       (GLfloat) - 0.839324, (GLfloat) 0.204765, (GLfloat) - 0.503594,
+       (GLfloat) - 0.839323, (GLfloat) 0.204765, (GLfloat) - 0.503595,
+       (GLfloat) - 0.849441, (GLfloat) 0.151406, (GLfloat) - 0.505496,
+       (GLfloat) - 0.847954, (GLfloat) 0.148744, (GLfloat) - 0.508773,
+       (GLfloat) - 0.975887, (GLfloat) 0.146977, (GLfloat) - 0.161379,
+       (GLfloat) - 0.975827, (GLfloat) 0.145984, (GLfloat) - 0.162638,
+       (GLfloat) - 0.966280, (GLfloat) 0.200913, (GLfloat) - 0.161047,
+       (GLfloat) - 0.966280, (GLfloat) 0.200913, (GLfloat) - 0.161047,
+       (GLfloat) - 0.869115, (GLfloat) - 0.045798, (GLfloat) - 0.492485,
+       (GLfloat) - 0.862005, (GLfloat) - 0.035136, (GLfloat) - 0.505681,
+       (GLfloat) - 0.985988, (GLfloat) - 0.044696, (GLfloat) - 0.160715,
+       (GLfloat) - 0.986683, (GLfloat) - 0.048596, (GLfloat) - 0.155223,
+       (GLfloat) - 0.984333, (GLfloat) 0.067324, (GLfloat) - 0.162959,
+       (GLfloat) - 0.984743, (GLfloat) 0.069793, (GLfloat) - 0.159404,
+       (GLfloat) - 0.856976, (GLfloat) 0.069431, (GLfloat) - 0.510658,
+       (GLfloat) - 0.861737, (GLfloat) 0.075800, (GLfloat) - 0.501660,
+       (GLfloat) - 0.869115, (GLfloat) - 0.045798, (GLfloat) 0.492485,
+       (GLfloat) - 0.862005, (GLfloat) - 0.035136, (GLfloat) 0.505681,
+       (GLfloat) - 0.856976, (GLfloat) 0.069431, (GLfloat) 0.510659,
+       (GLfloat) - 0.861738, (GLfloat) 0.075800, (GLfloat) 0.501660,
+       (GLfloat) - 0.984743, (GLfloat) 0.069793, (GLfloat) 0.159404,
+       (GLfloat) - 0.984333, (GLfloat) 0.067324, (GLfloat) 0.162959,
+       (GLfloat) - 0.986683, (GLfloat) - 0.048596, (GLfloat) 0.155223,
+       (GLfloat) - 0.985988, (GLfloat) - 0.044696, (GLfloat) 0.160715,
+       (GLfloat) - 0.839324, (GLfloat) 0.204766, (GLfloat) 0.503594,
+       (GLfloat) - 0.839323, (GLfloat) 0.204765, (GLfloat) 0.503595,
+       (GLfloat) - 0.966280, (GLfloat) 0.200913, (GLfloat) 0.161047,
+       (GLfloat) - 0.966280, (GLfloat) 0.200913, (GLfloat) 0.161047,
+       (GLfloat) - 0.975887, (GLfloat) 0.146977, (GLfloat) 0.161379,
+       (GLfloat) - 0.975827, (GLfloat) 0.145984, (GLfloat) 0.162638,
+       (GLfloat) - 0.847954, (GLfloat) 0.148744, (GLfloat) 0.508773,
+       (GLfloat) - 0.849441, (GLfloat) 0.151406, (GLfloat) 0.505496,
+       (GLfloat) - 0.503594, (GLfloat) 0.204766, (GLfloat) 0.839324,
+       (GLfloat) - 0.503595, (GLfloat) 0.204765, (GLfloat) 0.839323,
+       (GLfloat) - 0.512203, (GLfloat) 0.151943, (GLfloat) 0.845318,
+       (GLfloat) - 0.508258, (GLfloat) 0.155255, (GLfloat) 0.847095,
+       (GLfloat) - 0.165393, (GLfloat) 0.154386, (GLfloat) 0.974069,
+       (GLfloat) - 0.162365, (GLfloat) 0.156806, (GLfloat) 0.974192,
+       (GLfloat) - 0.161047, (GLfloat) 0.200914, (GLfloat) 0.966280,
+       (GLfloat) - 0.161047, (GLfloat) 0.200914, (GLfloat) 0.966280,
+       (GLfloat) - 0.537099, (GLfloat) - 0.019782, (GLfloat) 0.843287,
+       (GLfloat) - 0.523595, (GLfloat) - 0.008036, (GLfloat) 0.851930,
+       (GLfloat) - 0.177991, (GLfloat) 0.018183, (GLfloat) 0.983864,
+       (GLfloat) - 0.169802, (GLfloat) 0.024484, (GLfloat) 0.985174,
+       (GLfloat) - 0.165823, (GLfloat) 0.100484, (GLfloat) 0.981023,
+       (GLfloat) - 0.173169, (GLfloat) 0.095066, (GLfloat) 0.980293,
+       (GLfloat) - 0.515557, (GLfloat) 0.088028, (GLfloat) 0.852322,
+       (GLfloat) - 0.525730, (GLfloat) 0.079884, (GLfloat) 0.846892,
+       (GLfloat) 0.514604, (GLfloat) 0.123503, (GLfloat) 0.848487,
+       (GLfloat) 0.521791, (GLfloat) 0.120579, (GLfloat) 0.844509,
+       (GLfloat) 0.509344, (GLfloat) 0.149891, (GLfloat) 0.847409,
+       (GLfloat) 0.511715, (GLfloat) 0.148557, (GLfloat) 0.846214,
+       (GLfloat) 0.160323, (GLfloat) 0.119382, (GLfloat) 0.979819,
+       (GLfloat) 0.162599, (GLfloat) 0.118143, (GLfloat) 0.979594,
+       (GLfloat) 0.164688, (GLfloat) 0.065494, (GLfloat) 0.984169,
+       (GLfloat) 0.164275, (GLfloat) 0.065655, (GLfloat) 0.984227,
+       (GLfloat) 0.503594, (GLfloat) 0.204766, (GLfloat) 0.839324,
+       (GLfloat) 0.503595, (GLfloat) 0.204765, (GLfloat) 0.839323,
+       (GLfloat) 0.161047, (GLfloat) 0.200914, (GLfloat) 0.966280,
+       (GLfloat) 0.161047, (GLfloat) 0.200914, (GLfloat) 0.966280,
+       (GLfloat) 0.160943, (GLfloat) 0.163176, (GLfloat) 0.973381,
+       (GLfloat) 0.162221, (GLfloat) 0.162243, (GLfloat) 0.973325,
+       (GLfloat) 0.506455, (GLfloat) 0.176110, (GLfloat) 0.844090,
+       (GLfloat) 0.506875, (GLfloat) 0.175794, (GLfloat) 0.843904,
+       (GLfloat) 0.839324, (GLfloat) 0.204766, (GLfloat) 0.503594,
+       (GLfloat) 0.839323, (GLfloat) 0.204765, (GLfloat) 0.503595,
+       (GLfloat) 0.842767, (GLfloat) 0.188271, (GLfloat) 0.504280,
+       (GLfloat) 0.842301, (GLfloat) 0.187401, (GLfloat) 0.505381,
+       (GLfloat) 0.968491, (GLfloat) 0.190085, (GLfloat) 0.160914,
+       (GLfloat) 0.968481, (GLfloat) 0.189712, (GLfloat) 0.161414,
+       (GLfloat) 0.966280, (GLfloat) 0.200913, (GLfloat) 0.161047,
+       (GLfloat) 0.966280, (GLfloat) 0.200913, (GLfloat) 0.161047,
+       (GLfloat) 0.850151, (GLfloat) 0.182077, (GLfloat) 0.494055,
+       (GLfloat) 0.846712, (GLfloat) 0.177186, (GLfloat) 0.501681,
+       (GLfloat) 0.966795, (GLfloat) 0.202453, (GLfloat) 0.155950,
+       (GLfloat) 0.966634, (GLfloat) 0.200782, (GLfloat) 0.159079,
+       (GLfloat) 0.968271, (GLfloat) 0.191230, (GLfloat) 0.160881,
+       (GLfloat) 0.968343, (GLfloat) 0.192206, (GLfloat) 0.159274,
+       (GLfloat) 0.844217, (GLfloat) 0.179436, (GLfloat) 0.505074,
+       (GLfloat) 0.845886, (GLfloat) 0.181962, (GLfloat) 0.501364,
+       (GLfloat) 0.846712, (GLfloat) 0.177186, (GLfloat) - 0.501682,
+       (GLfloat) 0.850151, (GLfloat) 0.182077, (GLfloat) - 0.494055,
+       (GLfloat) 0.844217, (GLfloat) 0.179436, (GLfloat) - 0.505074,
+       (GLfloat) 0.845886, (GLfloat) 0.181962, (GLfloat) - 0.501365,
+       (GLfloat) 0.968343, (GLfloat) 0.192206, (GLfloat) - 0.159274,
+       (GLfloat) 0.968271, (GLfloat) 0.191230, (GLfloat) - 0.160881,
+       (GLfloat) 0.966795, (GLfloat) 0.202453, (GLfloat) - 0.155950,
+       (GLfloat) 0.966634, (GLfloat) 0.200782, (GLfloat) - 0.159079,
+       (GLfloat) 0.839324, (GLfloat) 0.204765, (GLfloat) - 0.503594,
+       (GLfloat) 0.839323, (GLfloat) 0.204765, (GLfloat) - 0.503595,
+       (GLfloat) 0.966280, (GLfloat) 0.200913, (GLfloat) - 0.161047,
+       (GLfloat) 0.966280, (GLfloat) 0.200913, (GLfloat) - 0.161047,
+       (GLfloat) 0.968491, (GLfloat) 0.190085, (GLfloat) - 0.160914,
+       (GLfloat) 0.968481, (GLfloat) 0.189713, (GLfloat) - 0.161414,
+       (GLfloat) 0.842301, (GLfloat) 0.187401, (GLfloat) - 0.505381,
+       (GLfloat) 0.842767, (GLfloat) 0.188271, (GLfloat) - 0.504280,
+       (GLfloat) 0.831768, (GLfloat) 0.243104, (GLfloat) 0.499061,
+       (GLfloat) 0.831768, (GLfloat) 0.243103, (GLfloat) 0.499062,
+       (GLfloat) 0.957902, (GLfloat) 0.238609, (GLfloat) 0.159651,
+       (GLfloat) 0.957902, (GLfloat) 0.238611, (GLfloat) 0.159650,
+       (GLfloat) 0.982539, (GLfloat) 0.084307, (GLfloat) 0.165861,
+       (GLfloat) 0.982460, (GLfloat) 0.089222, (GLfloat) 0.163743,
+       (GLfloat) 0.853634, (GLfloat) 0.079021, (GLfloat) 0.514845,
+       (GLfloat) 0.854444, (GLfloat) 0.084251, (GLfloat) 0.512667,
+       (GLfloat) 0.831768, (GLfloat) 0.243103, (GLfloat) - 0.499062,
+       (GLfloat) 0.831768, (GLfloat) 0.243104, (GLfloat) - 0.499061,
+       (GLfloat) 0.853634, (GLfloat) 0.079020, (GLfloat) - 0.514845,
+       (GLfloat) 0.854444, (GLfloat) 0.084251, (GLfloat) - 0.512667,
+       (GLfloat) 0.982460, (GLfloat) 0.089222, (GLfloat) - 0.163743,
+       (GLfloat) 0.982539, (GLfloat) 0.084307, (GLfloat) - 0.165861,
+       (GLfloat) 0.957902, (GLfloat) 0.238609, (GLfloat) - 0.159651,
+       (GLfloat) 0.957902, (GLfloat) 0.238611, (GLfloat) - 0.159650,
+       (GLfloat) 0.283620, (GLfloat) - 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) 0.264056, (GLfloat) - 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) 0.315105, (GLfloat) - 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) 0.304029, (GLfloat) - 0.949849, (GLfloat) - 0.073163,
+       (GLfloat) 0.811943, (GLfloat) - 0.566920, (GLfloat) - 0.139104,
+       (GLfloat) 0.830641, (GLfloat) - 0.534923, (GLfloat) - 0.154571,
+       (GLfloat) 0.677706, (GLfloat) - 0.609532, (GLfloat) - 0.411322,
+       (GLfloat) 0.690948, (GLfloat) - 0.577758, (GLfloat) - 0.434496,
+       (GLfloat) 0.264055, (GLfloat) - 0.947923, (GLfloat) 0.178092,
+       (GLfloat) 0.283620, (GLfloat) - 0.936578, (GLfloat) 0.205866,
+       (GLfloat) 0.677707, (GLfloat) - 0.609531, (GLfloat) 0.411322,
+       (GLfloat) 0.690948, (GLfloat) - 0.577758, (GLfloat) 0.434496,
+       (GLfloat) 0.830641, (GLfloat) - 0.534923, (GLfloat) 0.154571,
+       (GLfloat) 0.811943, (GLfloat) - 0.566920, (GLfloat) 0.139104,
+       (GLfloat) 0.304029, (GLfloat) - 0.949849, (GLfloat) 0.073163,
+       (GLfloat) 0.315105, (GLfloat) - 0.946548, (GLfloat) 0.068965,
+       (GLfloat) 0.499061, (GLfloat) 0.243103, (GLfloat) - 0.831768,
+       (GLfloat) 0.499061, (GLfloat) 0.243104, (GLfloat) - 0.831768,
+       (GLfloat) 0.159650, (GLfloat) 0.238610, (GLfloat) - 0.957902,
+       (GLfloat) 0.159651, (GLfloat) 0.238610, (GLfloat) - 0.957902,
+       (GLfloat) 0.165862, (GLfloat) 0.084307, (GLfloat) - 0.982539,
+       (GLfloat) 0.163744, (GLfloat) 0.089222, (GLfloat) - 0.982460,
+       (GLfloat) 0.514845, (GLfloat) 0.079019, (GLfloat) - 0.853634,
+       (GLfloat) 0.512666, (GLfloat) 0.084251, (GLfloat) - 0.854444,
+       (GLfloat) - 0.499061, (GLfloat) 0.243104, (GLfloat) - 0.831768,
+       (GLfloat) - 0.499061, (GLfloat) 0.243103, (GLfloat) - 0.831768,
+       (GLfloat) - 0.514845, (GLfloat) 0.079019, (GLfloat) - 0.853634,
+       (GLfloat) - 0.512666, (GLfloat) 0.084251, (GLfloat) - 0.854444,
+       (GLfloat) - 0.163744, (GLfloat) 0.089222, (GLfloat) - 0.982460,
+       (GLfloat) - 0.165862, (GLfloat) 0.084307, (GLfloat) - 0.982539,
+       (GLfloat) - 0.159650, (GLfloat) 0.238610, (GLfloat) - 0.957902,
+       (GLfloat) - 0.159651, (GLfloat) 0.238610, (GLfloat) - 0.957902,
+       (GLfloat) - 0.205866, (GLfloat) - 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) - 0.178092, (GLfloat) - 0.947923, (GLfloat) - 0.264056,
+       (GLfloat) - 0.068965, (GLfloat) - 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) - 0.073162, (GLfloat) - 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) - 0.139105, (GLfloat) - 0.566920, (GLfloat) - 0.811943,
+       (GLfloat) - 0.154572, (GLfloat) - 0.534923, (GLfloat) - 0.830641,
+       (GLfloat) - 0.411321, (GLfloat) - 0.609532, (GLfloat) - 0.677706,
+       (GLfloat) - 0.434496, (GLfloat) - 0.577758, (GLfloat) - 0.690948,
+       (GLfloat) 0.178092, (GLfloat) - 0.947923, (GLfloat) - 0.264056,
+       (GLfloat) 0.205866, (GLfloat) - 0.936578, (GLfloat) - 0.283621,
+       (GLfloat) 0.411321, (GLfloat) - 0.609532, (GLfloat) - 0.677706,
+       (GLfloat) 0.434496, (GLfloat) - 0.577758, (GLfloat) - 0.690948,
+       (GLfloat) 0.154572, (GLfloat) - 0.534923, (GLfloat) - 0.830641,
+       (GLfloat) 0.139105, (GLfloat) - 0.566920, (GLfloat) - 0.811943,
+       (GLfloat) 0.073162, (GLfloat) - 0.949849, (GLfloat) - 0.304029,
+       (GLfloat) 0.068965, (GLfloat) - 0.946548, (GLfloat) - 0.315105,
+       (GLfloat) - 0.831768, (GLfloat) 0.243104, (GLfloat) - 0.499061,
+       (GLfloat) - 0.831768, (GLfloat) 0.243103, (GLfloat) - 0.499062,
+       (GLfloat) - 0.957902, (GLfloat) 0.238609, (GLfloat) - 0.159651,
+       (GLfloat) - 0.957902, (GLfloat) 0.238611, (GLfloat) - 0.159650,
+       (GLfloat) - 0.982539, (GLfloat) 0.084307, (GLfloat) - 0.165861,
+       (GLfloat) - 0.982460, (GLfloat) 0.089222, (GLfloat) - 0.163743,
+       (GLfloat) - 0.853634, (GLfloat) 0.079020, (GLfloat) - 0.514845,
+       (GLfloat) - 0.854444, (GLfloat) 0.084251, (GLfloat) - 0.512667,
+       (GLfloat) - 0.831768, (GLfloat) 0.243103, (GLfloat) 0.499062,
+       (GLfloat) - 0.831768, (GLfloat) 0.243104, (GLfloat) 0.499061,
+       (GLfloat) - 0.853634, (GLfloat) 0.079021, (GLfloat) 0.514845,
+       (GLfloat) - 0.854444, (GLfloat) 0.084251, (GLfloat) 0.512667,
+       (GLfloat) - 0.982460, (GLfloat) 0.089222, (GLfloat) 0.163743,
+       (GLfloat) - 0.982539, (GLfloat) 0.084307, (GLfloat) 0.165861,
+       (GLfloat) - 0.957902, (GLfloat) 0.238609, (GLfloat) 0.159651,
+       (GLfloat) - 0.957902, (GLfloat) 0.238611, (GLfloat) 0.159650,
+       (GLfloat) - 0.283620, (GLfloat) - 0.936578, (GLfloat) 0.205866,
+       (GLfloat) - 0.264055, (GLfloat) - 0.947923, (GLfloat) 0.178092,
+       (GLfloat) - 0.315105, (GLfloat) - 0.946548, (GLfloat) 0.068965,
+       (GLfloat) - 0.304029, (GLfloat) - 0.949849, (GLfloat) 0.073163,
+       (GLfloat) - 0.811943, (GLfloat) - 0.566920, (GLfloat) 0.139104,
+       (GLfloat) - 0.830641, (GLfloat) - 0.534923, (GLfloat) 0.154571,
+       (GLfloat) - 0.677707, (GLfloat) - 0.609531, (GLfloat) 0.411322,
+       (GLfloat) - 0.690948, (GLfloat) - 0.577758, (GLfloat) 0.434496,
+       (GLfloat) - 0.264056, (GLfloat) - 0.947923, (GLfloat) - 0.178092,
+       (GLfloat) - 0.283620, (GLfloat) - 0.936578, (GLfloat) - 0.205866,
+       (GLfloat) - 0.677706, (GLfloat) - 0.609532, (GLfloat) - 0.411322,
+       (GLfloat) - 0.690948, (GLfloat) - 0.577758, (GLfloat) - 0.434496,
+       (GLfloat) - 0.830641, (GLfloat) - 0.534923, (GLfloat) - 0.154571,
+       (GLfloat) - 0.811943, (GLfloat) - 0.566920, (GLfloat) - 0.139104,
+       (GLfloat) - 0.304029, (GLfloat) - 0.949849, (GLfloat) - 0.073163,
+       (GLfloat) - 0.315105, (GLfloat) - 0.946548, (GLfloat) - 0.068965,
+       (GLfloat) - 0.499061, (GLfloat) 0.243104, (GLfloat) 0.831769,
+       (GLfloat) - 0.499061, (GLfloat) 0.243103, (GLfloat) 0.831768,
+       (GLfloat) - 0.159650, (GLfloat) 0.238610, (GLfloat) 0.957902,
+       (GLfloat) - 0.159651, (GLfloat) 0.238610, (GLfloat) 0.957902,
+       (GLfloat) - 0.165862, (GLfloat) 0.084307, (GLfloat) 0.982539,
+       (GLfloat) - 0.163744, (GLfloat) 0.089222, (GLfloat) 0.982460,
+       (GLfloat) - 0.514844, (GLfloat) 0.079021, (GLfloat) 0.853634,
+       (GLfloat) - 0.512667, (GLfloat) 0.084251, (GLfloat) 0.854444,
+       (GLfloat) 0.499061, (GLfloat) 0.243103, (GLfloat) 0.831768,
+       (GLfloat) 0.499061, (GLfloat) 0.243104, (GLfloat) 0.831769,
+       (GLfloat) 0.514844, (GLfloat) 0.079021, (GLfloat) 0.853634,
+       (GLfloat) 0.512667, (GLfloat) 0.084251, (GLfloat) 0.854444,
+       (GLfloat) 0.163744, (GLfloat) 0.089222, (GLfloat) 0.982460,
+       (GLfloat) 0.165862, (GLfloat) 0.084307, (GLfloat) 0.982539,
+       (GLfloat) 0.159650, (GLfloat) 0.238610, (GLfloat) 0.957902,
+       (GLfloat) 0.159651, (GLfloat) 0.238610, (GLfloat) 0.957902,
+       (GLfloat) 0.205866, (GLfloat) - 0.936578, (GLfloat) 0.283621,
+       (GLfloat) 0.178092, (GLfloat) - 0.947923, (GLfloat) 0.264055,
+       (GLfloat) 0.068965, (GLfloat) - 0.946548, (GLfloat) 0.315105,
+       (GLfloat) 0.073162, (GLfloat) - 0.949849, (GLfloat) 0.304029,
+       (GLfloat) 0.139105, (GLfloat) - 0.566920, (GLfloat) 0.811943,
+       (GLfloat) 0.154572, (GLfloat) - 0.534923, (GLfloat) 0.830641,
+       (GLfloat) 0.411321, (GLfloat) - 0.609531, (GLfloat) 0.677707,
+       (GLfloat) 0.434496, (GLfloat) - 0.577757, (GLfloat) 0.690948,
+       (GLfloat) - 0.178092, (GLfloat) - 0.947923, (GLfloat) 0.264055,
+       (GLfloat) - 0.205866, (GLfloat) - 0.936578, (GLfloat) 0.283621,
+       (GLfloat) - 0.411321, (GLfloat) - 0.609531, (GLfloat) 0.677707,
+       (GLfloat) - 0.434496, (GLfloat) - 0.577757, (GLfloat) 0.690948,
+       (GLfloat) - 0.154572, (GLfloat) - 0.534923, (GLfloat) 0.830641,
+       (GLfloat) - 0.139105, (GLfloat) - 0.566920, (GLfloat) 0.811943,
+       (GLfloat) - 0.073162, (GLfloat) - 0.949849, (GLfloat) 0.304029,
+       (GLfloat) - 0.068965, (GLfloat) - 0.946548, (GLfloat) 0.315105,
+       (GLfloat) 0.135802, (GLfloat) - 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) 0.124011, (GLfloat) - 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) 0.043834, (GLfloat) - 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) 0.039656, (GLfloat) - 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) 0.030163, (GLfloat) - 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) 0.033079, (GLfloat) - 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) 0.109621, (GLfloat) - 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) 0.114709, (GLfloat) - 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) - 0.124011, (GLfloat) - 0.982944, (GLfloat) - 0.135802,
+       (GLfloat) - 0.135802, (GLfloat) - 0.982944, (GLfloat) - 0.124011,
+       (GLfloat) - 0.109621, (GLfloat) - 0.993006, (GLfloat) - 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) - 0.992607, (GLfloat) - 0.039656,
+       (GLfloat) - 0.033079, (GLfloat) - 0.998998, (GLfloat) - 0.030163,
+       (GLfloat) - 0.030163, (GLfloat) - 0.998998, (GLfloat) - 0.033079,
+       (GLfloat) - 0.043834, (GLfloat) - 0.993006, (GLfloat) - 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) - 0.992607, (GLfloat) - 0.114709,
+       (GLfloat) - 0.135803, (GLfloat) - 0.982944, (GLfloat) 0.124011,
+       (GLfloat) - 0.124011, (GLfloat) - 0.982944, (GLfloat) 0.135802,
+       (GLfloat) - 0.043834, (GLfloat) - 0.993006, (GLfloat) 0.109621,
+       (GLfloat) - 0.039656, (GLfloat) - 0.992607, (GLfloat) 0.114709,
+       (GLfloat) - 0.030163, (GLfloat) - 0.998998, (GLfloat) 0.033079,
+       (GLfloat) - 0.033079, (GLfloat) - 0.998998, (GLfloat) 0.030163,
+       (GLfloat) - 0.109621, (GLfloat) - 0.993006, (GLfloat) 0.043834,
+       (GLfloat) - 0.114709, (GLfloat) - 0.992607, (GLfloat) 0.039656,
+       (GLfloat) 0.124011, (GLfloat) - 0.982944, (GLfloat) 0.135802,
+       (GLfloat) 0.135803, (GLfloat) - 0.982944, (GLfloat) 0.124011,
+       (GLfloat) 0.109621, (GLfloat) - 0.993006, (GLfloat) 0.043834,
+       (GLfloat) 0.114709, (GLfloat) - 0.992607, (GLfloat) 0.039656,
+       (GLfloat) 0.033079, (GLfloat) - 0.998998, (GLfloat) 0.030163,
+       (GLfloat) 0.030163, (GLfloat) - 0.998998, (GLfloat) 0.033079,
+       (GLfloat) 0.043834, (GLfloat) - 0.993006, (GLfloat) 0.109621,
+       (GLfloat) 0.039656, (GLfloat) - 0.992607, (GLfloat) 0.114709,
+};
+
+static unsigned short int s1_6_POLS[] =
+{
+      3, 82, 12, 76, 1, 3, 76, 74, 82, 1, 3, 22, 78, 74, 1, 3, 22, 74, 76, 1,
+      3, 78, 20, 80, 1, 3, 80, 74, 78, 1, 3, 28, 82, 74, 1, 3, 28, 74, 80, 1,
+      3, 88, 13, 84, 1, 3, 84, 77, 88, 1, 3, 24, 86, 77, 1, 3, 24, 77, 84, 1,
+      3, 86, 20, 78, 1, 3, 78, 77, 86, 1, 3, 22, 88, 77, 1, 3, 22, 77, 78, 1,
+      3, 14, 90, 85, 1, 3, 14, 85, 93, 1, 3, 26, 91, 85, 1, 3, 26, 85, 90, 1,
+      3, 20, 86, 85, 1, 3, 20, 85, 91, 1, 3, 86, 24, 93, 1, 3, 93, 85, 86, 1,
+      3, 15, 95, 79, 1, 3, 15, 79, 97, 1, 3, 95, 28, 80, 1, 3, 80, 79, 95, 1,
+      3, 20, 91, 79, 1, 3, 20, 79, 80, 1, 3, 26, 97, 79, 1, 3, 26, 79, 91, 1,
+    3, 13, 99, 83, 1, 3, 13, 83, 84, 1, 3, 99, 30, 101, 1, 3, 101, 83, 99, 1,
+  3, 23, 102, 83, 1, 3, 23, 83, 101, 1, 3, 102, 24, 84, 1, 3, 84, 83, 102, 1,
+       3, 108, 16, 104, 1, 3, 104, 100, 108, 1, 3, 32, 106, 100, 1, 3, 32, 100, 104, 1,
+       3, 106, 23, 101, 1, 3, 101, 100, 106, 1, 3, 30, 108, 100, 1, 3, 30, 100, 101, 1,
+       3, 17, 110, 105, 1, 3, 17, 105, 113, 1, 3, 110, 33, 111, 1, 3, 111, 105, 110, 1,
+       3, 23, 106, 105, 1, 3, 23, 105, 111, 1, 3, 106, 32, 113, 1, 3, 113, 105, 106, 1,
+  3, 114, 14, 93, 1, 3, 93, 92, 114, 1, 3, 93, 24, 102, 1, 3, 102, 92, 93, 1,
+3, 23, 111, 92, 1, 3, 23, 92, 102, 1, 3, 111, 33, 114, 1, 3, 114, 92, 111, 1,
+       3, 16, 116, 103, 1, 3, 16, 103, 104, 1, 3, 116, 35, 118, 1, 3, 118, 103, 116, 1,
+       3, 31, 119, 103, 1, 3, 31, 103, 118, 1, 3, 119, 32, 104, 1, 3, 104, 103, 119, 1,
+       3, 18, 121, 117, 1, 3, 18, 117, 125, 1, 3, 121, 36, 123, 1, 3, 123, 117, 121, 1,
+       3, 31, 118, 117, 1, 3, 31, 117, 123, 1, 3, 118, 35, 125, 1, 3, 125, 117, 118, 1,
+       3, 19, 127, 122, 1, 3, 19, 122, 130, 1, 3, 37, 128, 122, 1, 3, 37, 122, 127, 1,
+       3, 31, 123, 122, 1, 3, 31, 122, 128, 1, 3, 36, 130, 122, 1, 3, 36, 122, 123, 1,
+       3, 17, 113, 112, 1, 3, 17, 112, 131, 1, 3, 32, 119, 112, 1, 3, 32, 112, 113, 1,
+       3, 31, 128, 112, 1, 3, 31, 112, 119, 1, 3, 37, 131, 112, 1, 3, 37, 112, 128, 1,
+       3, 121, 18, 133, 1, 3, 133, 120, 121, 1, 3, 39, 134, 120, 1, 3, 39, 120, 133, 1,
+       3, 134, 27, 135, 1, 3, 135, 120, 134, 1, 3, 36, 121, 120, 1, 3, 36, 120, 135, 1,
+   3, 12, 82, 81, 1, 3, 12, 81, 138, 1, 3, 82, 28, 136, 1, 3, 136, 81, 82, 1,
+3, 27, 134, 81, 1, 3, 27, 81, 136, 1, 3, 134, 39, 138, 1, 3, 138, 81, 134, 1,
+3, 95, 15, 139, 1, 3, 139, 94, 95, 1, 3, 139, 40, 140, 1, 3, 140, 94, 139, 1,
+  3, 27, 136, 94, 1, 3, 27, 94, 140, 1, 3, 136, 28, 95, 1, 3, 95, 94, 136, 1,
+       3, 19, 130, 129, 1, 3, 19, 129, 141, 1, 3, 130, 36, 135, 1, 3, 135, 129, 130, 1,
+       3, 27, 140, 129, 1, 3, 27, 129, 135, 1, 3, 140, 40, 141, 1, 3, 141, 129, 140, 1,
+ 3, 14, 114, 89, 1, 3, 14, 89, 90, 1, 3, 114, 33, 142, 1, 3, 142, 89, 114, 1,
+  3, 25, 143, 89, 1, 3, 25, 89, 142, 1, 3, 143, 26, 90, 1, 3, 90, 89, 143, 1,
+       3, 17, 131, 109, 1, 3, 17, 109, 110, 1, 3, 131, 37, 144, 1, 3, 144, 109, 131, 1,
+       3, 25, 142, 109, 1, 3, 25, 109, 144, 1, 3, 142, 33, 110, 1, 3, 110, 109, 142, 1,
+       3, 19, 141, 126, 1, 3, 19, 126, 127, 1, 3, 141, 40, 145, 1, 3, 145, 126, 141, 1,
+       3, 25, 144, 126, 1, 3, 25, 126, 145, 1, 3, 144, 37, 127, 1, 3, 127, 126, 144, 1,
+   3, 15, 97, 96, 1, 3, 15, 96, 139, 1, 3, 97, 26, 143, 1, 3, 143, 96, 97, 1,
+3, 25, 145, 96, 1, 3, 25, 96, 143, 1, 3, 145, 40, 139, 1, 3, 139, 96, 145, 1,
+ 3, 12, 146, 75, 1, 3, 12, 75, 76, 1, 3, 146, 41, 148, 1, 3, 148, 75, 146, 1,
+  3, 21, 149, 75, 1, 3, 21, 75, 148, 1, 3, 149, 22, 76, 1, 3, 76, 75, 149, 1,
+       3, 155, 8, 151, 1, 3, 151, 147, 155, 1, 3, 43, 153, 147, 1, 3, 43, 147, 151, 1,
+       3, 153, 21, 148, 1, 3, 148, 147, 153, 1, 3, 41, 155, 147, 1, 3, 41, 147, 148, 1,
+       3, 160, 11, 157, 1, 3, 157, 152, 160, 1, 3, 44, 158, 152, 1, 3, 44, 152, 157, 1,
+       3, 158, 21, 153, 1, 3, 153, 152, 158, 1, 3, 43, 160, 152, 1, 3, 43, 152, 153, 1,
+   3, 13, 88, 87, 1, 3, 13, 87, 161, 1, 3, 88, 22, 149, 1, 3, 149, 87, 88, 1,
+3, 21, 158, 87, 1, 3, 21, 87, 149, 1, 3, 158, 44, 161, 1, 3, 161, 87, 158, 1,
+       3, 18, 162, 132, 1, 3, 18, 132, 133, 1, 3, 162, 45, 164, 1, 3, 164, 132, 162, 1,
+       3, 38, 165, 132, 1, 3, 38, 132, 164, 1, 3, 165, 39, 133, 1, 3, 133, 132, 165, 1,
+       3, 170, 9, 167, 1, 3, 167, 163, 170, 1, 3, 47, 168, 163, 1, 3, 47, 163, 167, 1,
+       3, 168, 38, 164, 1, 3, 164, 163, 168, 1, 3, 45, 170, 163, 1, 3, 45, 163, 164, 1,
+3, 8, 155, 154, 1, 3, 8, 154, 173, 1, 3, 155, 41, 171, 1, 3, 171, 154, 155, 1,
+       3, 38, 168, 154, 1, 3, 38, 154, 171, 1, 3, 168, 47, 173, 1, 3, 173, 154, 168, 1,
+       3, 146, 12, 138, 1, 3, 138, 137, 146, 1, 3, 39, 165, 137, 1, 3, 39, 137, 138, 1,
+       3, 165, 38, 171, 1, 3, 171, 137, 165, 1, 3, 41, 146, 137, 1, 3, 41, 137, 171, 1,
+       3, 16, 108, 107, 1, 3, 16, 107, 177, 1, 3, 108, 30, 174, 1, 3, 174, 107, 108, 1,
+       3, 29, 176, 107, 1, 3, 29, 107, 174, 1, 3, 176, 50, 177, 1, 3, 177, 107, 176, 1,
+  3, 99, 13, 161, 1, 3, 161, 98, 99, 1, 3, 44, 178, 98, 1, 3, 44, 98, 161, 1,
+ 3, 178, 29, 174, 1, 3, 174, 98, 178, 1, 3, 30, 99, 98, 1, 3, 30, 98, 174, 1,
+       3, 11, 180, 156, 1, 3, 11, 156, 157, 1, 3, 180, 49, 181, 1, 3, 181, 156, 180, 1,
+       3, 29, 178, 156, 1, 3, 29, 156, 181, 1, 3, 178, 44, 157, 1, 3, 157, 156, 178, 1,
+       3, 185, 10, 183, 1, 3, 183, 175, 185, 1, 3, 50, 176, 175, 1, 3, 50, 175, 183, 1,
+       3, 176, 29, 181, 1, 3, 181, 175, 176, 1, 3, 49, 185, 175, 1, 3, 49, 175, 181, 1,
+       3, 162, 18, 125, 1, 3, 125, 124, 162, 1, 3, 35, 186, 124, 1, 3, 35, 124, 125, 1,
+       3, 186, 34, 187, 1, 3, 187, 124, 186, 1, 3, 45, 162, 124, 1, 3, 45, 124, 187, 1,
+       3, 116, 16, 177, 1, 3, 177, 115, 116, 1, 3, 50, 188, 115, 1, 3, 50, 115, 177, 1,
+       3, 188, 34, 186, 1, 3, 186, 115, 188, 1, 3, 35, 116, 115, 1, 3, 35, 115, 186, 1,
+       3, 10, 190, 182, 1, 3, 10, 182, 183, 1, 3, 190, 52, 191, 1, 3, 191, 182, 190, 1,
+       3, 34, 188, 182, 1, 3, 34, 182, 191, 1, 3, 188, 50, 183, 1, 3, 183, 182, 188, 1,
+3, 9, 170, 169, 1, 3, 9, 169, 193, 1, 3, 170, 45, 187, 1, 3, 187, 169, 170, 1,
+       3, 34, 191, 169, 1, 3, 34, 169, 187, 1, 3, 191, 52, 193, 1, 3, 193, 169, 191, 1,
+       3, 201, 1, 196, 1, 3, 196, 194, 201, 1, 3, 54, 198, 194, 1, 3, 54, 194, 196, 1,
+       3, 198, 46, 199, 1, 3, 199, 194, 198, 1, 3, 56, 201, 194, 1, 3, 56, 194, 199, 1,
+       3, 206, 3, 203, 1, 3, 203, 197, 206, 1, 3, 55, 204, 197, 1, 3, 55, 197, 203, 1,
+       3, 204, 46, 198, 1, 3, 198, 197, 204, 1, 3, 54, 206, 197, 1, 3, 54, 197, 198, 1,
+3, 8, 173, 172, 1, 3, 8, 172, 208, 1, 3, 173, 47, 207, 1, 3, 207, 172, 173, 1,
+       3, 46, 204, 172, 1, 3, 46, 172, 207, 1, 3, 204, 55, 208, 1, 3, 208, 172, 204, 1,
+3, 9, 209, 166, 1, 3, 9, 166, 167, 1, 3, 209, 56, 199, 1, 3, 199, 166, 209, 1,
+       3, 46, 207, 166, 1, 3, 46, 166, 199, 1, 3, 207, 47, 167, 1, 3, 167, 166, 207, 1,
+       3, 214, 1, 201, 1, 3, 201, 200, 214, 1, 3, 56, 210, 200, 1, 3, 56, 200, 201, 1,
+       3, 210, 51, 212, 1, 3, 212, 200, 210, 1, 3, 59, 214, 200, 1, 3, 59, 200, 212, 1,
+       3, 209, 9, 193, 1, 3, 193, 192, 209, 1, 3, 52, 215, 192, 1, 3, 52, 192, 193, 1,
+       3, 51, 210, 192, 1, 3, 51, 192, 215, 1, 3, 210, 56, 209, 1, 3, 209, 192, 210, 1,
+       3, 190, 10, 216, 1, 3, 216, 189, 190, 1, 3, 216, 57, 217, 1, 3, 217, 189, 216, 1,
+       3, 51, 215, 189, 1, 3, 51, 189, 217, 1, 3, 52, 190, 189, 1, 3, 52, 189, 215, 1,
+       3, 221, 0, 219, 1, 3, 219, 211, 221, 1, 3, 59, 212, 211, 1, 3, 59, 211, 219, 1,
+       3, 212, 51, 217, 1, 3, 217, 211, 212, 1, 3, 57, 221, 211, 1, 3, 57, 211, 217, 1,
+       3, 226, 0, 221, 1, 3, 221, 220, 226, 1, 3, 57, 222, 220, 1, 3, 57, 220, 221, 1,
+       3, 222, 48, 224, 1, 3, 224, 220, 222, 1, 3, 62, 226, 220, 1, 3, 62, 220, 224, 1,
+       3, 10, 185, 184, 1, 3, 10, 184, 216, 1, 3, 185, 49, 227, 1, 3, 227, 184, 185, 1,
+       3, 48, 222, 184, 1, 3, 48, 184, 227, 1, 3, 222, 57, 216, 1, 3, 216, 184, 222, 1,
+       3, 11, 228, 179, 1, 3, 11, 179, 180, 1, 3, 228, 60, 229, 1, 3, 229, 179, 228, 1,
+       3, 48, 227, 179, 1, 3, 48, 179, 229, 1, 3, 227, 49, 180, 1, 3, 180, 179, 227, 1,
+       3, 233, 2, 231, 1, 3, 231, 223, 233, 1, 3, 62, 224, 223, 1, 3, 62, 223, 231, 1,
+       3, 224, 48, 229, 1, 3, 229, 223, 224, 1, 3, 60, 233, 223, 1, 3, 60, 223, 229, 1,
+       3, 237, 2, 233, 1, 3, 233, 232, 237, 1, 3, 60, 234, 232, 1, 3, 60, 232, 233, 1,
+       3, 234, 42, 235, 1, 3, 235, 232, 234, 1, 3, 64, 237, 232, 1, 3, 64, 232, 235, 1,
+       3, 11, 160, 159, 1, 3, 11, 159, 228, 1, 3, 160, 43, 238, 1, 3, 238, 159, 160, 1,
+       3, 42, 234, 159, 1, 3, 42, 159, 238, 1, 3, 234, 60, 228, 1, 3, 228, 159, 234, 1,
+3, 8, 208, 150, 1, 3, 8, 150, 151, 1, 3, 208, 55, 239, 1, 3, 239, 150, 208, 1,
+       3, 42, 238, 150, 1, 3, 42, 150, 239, 1, 3, 238, 43, 151, 1, 3, 151, 150, 238, 1,
+       3, 203, 3, 241, 1, 3, 241, 202, 203, 1, 3, 64, 235, 202, 1, 3, 64, 202, 241, 1,
+       3, 235, 42, 239, 1, 3, 239, 202, 235, 1, 3, 55, 203, 202, 1, 3, 55, 202, 239, 1,
+3, 2, 237, 236, 1, 3, 2, 236, 245, 1, 3, 237, 64, 242, 1, 3, 242, 236, 237, 1,
+       3, 63, 244, 236, 1, 3, 63, 236, 242, 1, 3, 244, 68, 245, 1, 3, 245, 236, 244, 1,
+3, 3, 246, 240, 1, 3, 3, 240, 241, 1, 3, 246, 65, 248, 1, 3, 248, 240, 246, 1,
+       3, 63, 242, 240, 1, 3, 63, 240, 248, 1, 3, 242, 64, 241, 1, 3, 241, 240, 242, 1,
+3, 4, 250, 247, 1, 3, 4, 247, 253, 1, 3, 67, 251, 247, 1, 3, 67, 247, 250, 1,
+       3, 63, 248, 247, 1, 3, 63, 247, 251, 1, 3, 248, 65, 253, 1, 3, 253, 247, 248, 1,
+3, 7, 255, 243, 1, 3, 7, 243, 257, 1, 3, 255, 68, 244, 1, 3, 244, 243, 255, 1,
+       3, 63, 251, 243, 1, 3, 63, 243, 244, 1, 3, 67, 257, 243, 1, 3, 67, 243, 251, 1,
+3, 3, 206, 205, 1, 3, 3, 205, 246, 1, 3, 206, 54, 258, 1, 3, 258, 205, 206, 1,
+       3, 53, 259, 205, 1, 3, 53, 205, 258, 1, 3, 259, 65, 246, 1, 3, 246, 205, 259, 1,
+3, 1, 260, 195, 1, 3, 1, 195, 196, 1, 3, 260, 69, 262, 1, 3, 262, 195, 260, 1,
+       3, 53, 258, 195, 1, 3, 53, 195, 262, 1, 3, 258, 54, 196, 1, 3, 196, 195, 258, 1,
+3, 5, 264, 261, 1, 3, 5, 261, 267, 1, 3, 70, 265, 261, 1, 3, 70, 261, 264, 1,
+       3, 53, 262, 261, 1, 3, 53, 261, 265, 1, 3, 262, 69, 267, 1, 3, 267, 261, 262, 1,
+3, 4, 253, 252, 1, 3, 4, 252, 268, 1, 3, 253, 65, 259, 1, 3, 259, 252, 253, 1,
+       3, 53, 265, 252, 1, 3, 53, 252, 259, 1, 3, 70, 268, 252, 1, 3, 70, 252, 265, 1,
+3, 1, 214, 213, 1, 3, 1, 213, 260, 1, 3, 214, 59, 269, 1, 3, 269, 213, 214, 1,
+       3, 58, 270, 213, 1, 3, 58, 213, 269, 1, 3, 270, 69, 260, 1, 3, 260, 213, 270, 1,
+3, 0, 271, 218, 1, 3, 0, 218, 219, 1, 3, 271, 71, 273, 1, 3, 273, 218, 271, 1,
+       3, 58, 269, 218, 1, 3, 58, 218, 273, 1, 3, 269, 59, 219, 1, 3, 219, 218, 269, 1,
+3, 6, 275, 272, 1, 3, 6, 272, 278, 1, 3, 72, 276, 272, 1, 3, 72, 272, 275, 1,
+       3, 58, 273, 272, 1, 3, 58, 272, 276, 1, 3, 273, 71, 278, 1, 3, 278, 272, 273, 1,
+3, 5, 267, 266, 1, 3, 5, 266, 279, 1, 3, 267, 69, 270, 1, 3, 270, 266, 267, 1,
+       3, 58, 276, 266, 1, 3, 58, 266, 270, 1, 3, 72, 279, 266, 1, 3, 72, 266, 276, 1,
+3, 0, 226, 225, 1, 3, 0, 225, 271, 1, 3, 226, 62, 280, 1, 3, 280, 225, 226, 1,
+       3, 61, 281, 225, 1, 3, 61, 225, 280, 1, 3, 281, 71, 271, 1, 3, 271, 225, 281, 1,
+3, 2, 245, 230, 1, 3, 2, 230, 231, 1, 3, 245, 68, 282, 1, 3, 282, 230, 245, 1,
+       3, 61, 280, 230, 1, 3, 61, 230, 282, 1, 3, 280, 62, 231, 1, 3, 231, 230, 280, 1,
+3, 7, 283, 254, 1, 3, 7, 254, 255, 1, 3, 73, 284, 254, 1, 3, 73, 254, 283, 1,
+       3, 61, 282, 254, 1, 3, 61, 254, 284, 1, 3, 282, 68, 255, 1, 3, 255, 254, 282, 1,
+3, 6, 278, 277, 1, 3, 6, 277, 285, 1, 3, 278, 71, 281, 1, 3, 281, 277, 278, 1,
+       3, 61, 284, 277, 1, 3, 61, 277, 281, 1, 3, 73, 285, 277, 1, 3, 73, 277, 284, 1,
+3, 4, 268, 249, 1, 3, 4, 249, 250, 1, 3, 268, 70, 286, 1, 3, 286, 249, 268, 1,
+       3, 66, 287, 249, 1, 3, 66, 249, 286, 1, 3, 287, 67, 250, 1, 3, 250, 249, 287, 1,
+3, 5, 279, 263, 1, 3, 5, 263, 264, 1, 3, 279, 72, 288, 1, 3, 288, 263, 279, 1,
+       3, 66, 286, 263, 1, 3, 66, 263, 288, 1, 3, 286, 70, 264, 1, 3, 264, 263, 286, 1,
+3, 6, 285, 274, 1, 3, 6, 274, 275, 1, 3, 285, 73, 289, 1, 3, 289, 274, 285, 1,
+       3, 66, 288, 274, 1, 3, 66, 274, 289, 1, 3, 288, 72, 275, 1, 3, 275, 274, 288, 1,
+3, 7, 257, 256, 1, 3, 7, 256, 283, 1, 3, 257, 67, 287, 1, 3, 287, 256, 257, 1,
+       3, 66, 289, 256, 1, 3, 66, 256, 287, 1, 3, 289, 73, 283, 1, 3, 283, 256, 289, 1,
+
+       0
+};
+
+struct lwo  LWO_s1_6 =
+{
+       290,                    /* number of points */
+       s1_6_PNTS, s1_6_normals, s1_6_POLS, 0L
+};
+
+#endif /* MODE_sproingies */
+
+/* End of s1_6.c */
diff --git a/xlockmore-4.14/modes/glx/s1_b.c b/xlockmore-4.14/modes/glx/s1_b.c
new file mode 100644 (file)
index 0000000..73a5fef
--- /dev/null
@@ -0,0 +1,537 @@
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)s1_b.c       4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ * Points to render "s1_b" in 3D.
+ *
+ * Generated by lw2ogl.  Link this with your program but do
+ * not edit by hand.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_sproingies
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+#include <GL/gl.h>
+#include "buildlwo.h"
+
+static GLfloat s1_b_PNTS[] =
+{
+       (GLfloat) - 0.137893, (GLfloat) 0.043508, (GLfloat) - 0.125711,
+       (GLfloat) - 0.095845, (GLfloat) - 0.165656, (GLfloat) 0.072892,
+       (GLfloat) - 0.093165, (GLfloat) 0.152051, (GLfloat) 0.327744,
+       (GLfloat) - 0.003795, (GLfloat) 0.001470, (GLfloat) - 0.102225,
+       (GLfloat) 0.152845, (GLfloat) - 0.430757, (GLfloat) - 0.031907,
+       (GLfloat) - 0.118828, (GLfloat) 0.399389, (GLfloat) 0.091047,
+       (GLfloat) - 0.169137, (GLfloat) - 0.181241, (GLfloat) - 0.288763,
+       (GLfloat) 0.048660, (GLfloat) 0.018262, (GLfloat) - 0.035049,
+       (GLfloat) 0.008859, (GLfloat) 0.208004, (GLfloat) - 0.059048,
+       (GLfloat) - 0.009212, (GLfloat) - 0.042229, (GLfloat) - 0.000692,
+       (GLfloat) - 0.040025, (GLfloat) 0.115695, (GLfloat) 0.178962,
+       (GLfloat) - 0.198525, (GLfloat) 0.018630, (GLfloat) 0.257202,
+       (GLfloat) 0.205081, (GLfloat) - 0.244569, (GLfloat) 0.136314,
+       (GLfloat) - 0.214336, (GLfloat) - 0.149946, (GLfloat) - 0.006872,
+       (GLfloat) 0.245675, (GLfloat) - 0.227316, (GLfloat) - 0.184201,
+       (GLfloat) - 0.001494, (GLfloat) 0.259139, (GLfloat) - 0.260652,
+       (GLfloat) 0.070243, (GLfloat) 0.038750, (GLfloat) 0.069425,
+       (GLfloat) - 0.033229, (GLfloat) - 0.259151, (GLfloat) 0.298856,
+       (GLfloat) 0.088773, (GLfloat) - 0.065324, (GLfloat) 0.260294,
+       (GLfloat) 0.009195, (GLfloat) 0.078651, (GLfloat) 0.055543,
+       (GLfloat) - 0.090795, (GLfloat) 0.025672, (GLfloat) 0.056988,
+       (GLfloat) - 0.163707, (GLfloat) - 0.011627, (GLfloat) - 0.096395,
+       (GLfloat) 0.068886, (GLfloat) 0.257031, (GLfloat) - 0.264175,
+       (GLfloat) - 0.018086, (GLfloat) - 0.285526, (GLfloat) 0.152989,
+       (GLfloat) - 0.017489, (GLfloat) 0.031671, (GLfloat) 0.000107,
+       (GLfloat) - 0.075583, (GLfloat) - 0.097617, (GLfloat) 0.030074,
+       (GLfloat) 0.129221, (GLfloat) - 0.087628, (GLfloat) 0.171748,
+       (GLfloat) - 0.007530, (GLfloat) - 0.084194, (GLfloat) 0.186045,
+       (GLfloat) 0.474638, (GLfloat) 0.004818, (GLfloat) 0.200460,
+       (GLfloat) 0.016796, (GLfloat) 0.096614, (GLfloat) - 0.221351,
+       (GLfloat) 0.187032, (GLfloat) 0.031017, (GLfloat) 0.039986,
+       (GLfloat) - 0.142119, (GLfloat) - 0.105297, (GLfloat) - 0.100849,
+       (GLfloat) 0.142768, (GLfloat) - 0.313960, (GLfloat) - 0.349716,
+       (GLfloat) - 0.146805, (GLfloat) 0.140482, (GLfloat) 0.035653,
+       (GLfloat) 0.039939, (GLfloat) - 0.051822, (GLfloat) - 0.017672,
+       (GLfloat) 0.057111, (GLfloat) - 0.075686, (GLfloat) - 0.103478,
+       (GLfloat) 0.049696, (GLfloat) - 0.135070, (GLfloat) 0.055097,
+       (GLfloat) 0.030271, (GLfloat) 0.075412, (GLfloat) - 0.103571,
+       (GLfloat) 0.100158, (GLfloat) - 0.022917, (GLfloat) 0.073895,
+       (GLfloat) 0.085544, (GLfloat) - 0.273613, (GLfloat) 0.092456,
+       (GLfloat) 0.077489, (GLfloat) - 0.309836, (GLfloat) - 0.003664,
+       (GLfloat) - 0.017590, (GLfloat) - 0.127869, (GLfloat) 0.153118,
+       (GLfloat) - 0.157014, (GLfloat) - 0.242184, (GLfloat) 0.070478,
+       (GLfloat) - 0.018167, (GLfloat) - 0.133639, (GLfloat) - 0.174937,
+       (GLfloat) - 0.106973, (GLfloat) - 0.189783, (GLfloat) 0.038622,
+       (GLfloat) - 0.000096, (GLfloat) 0.104429, (GLfloat) - 0.032589,
+       (GLfloat) - 0.032036, (GLfloat) - 0.021493, (GLfloat) 0.279829,
+       (GLfloat) - 0.093181, (GLfloat) - 0.058024, (GLfloat) 0.182239,
+       (GLfloat) 0.012941, (GLfloat) - 0.010409, (GLfloat) 0.088080,
+       (GLfloat) 0.256718, (GLfloat) - 0.118137, (GLfloat) - 0.078847,
+       (GLfloat) - 0.113382, (GLfloat) 0.135060, (GLfloat) 0.269946,
+       (GLfloat) 0.175810, (GLfloat) - 0.026321, (GLfloat) 0.013860,
+       (GLfloat) - 0.110606, (GLfloat) - 0.023553, (GLfloat) - 0.255525,
+       (GLfloat) 0.007163, (GLfloat) 0.068674, (GLfloat) 0.010214,
+       (GLfloat) 0.031631, (GLfloat) - 0.170381, (GLfloat) - 0.174604,
+       (GLfloat) 0.117242, (GLfloat) 0.014353, (GLfloat) - 0.021215,
+       (GLfloat) 0.090315, (GLfloat) 0.161755, (GLfloat) 0.074427,
+       (GLfloat) 0.285616, (GLfloat) 0.335824, (GLfloat) - 0.083891,
+       (GLfloat) - 0.145763, (GLfloat) 0.109292, (GLfloat) 0.121340,
+       (GLfloat) - 0.147459, (GLfloat) - 0.041936, (GLfloat) 0.010427,
+       (GLfloat) - 0.082626, (GLfloat) 0.151300, (GLfloat) - 0.030875,
+       (GLfloat) 0.217154, (GLfloat) - 0.288504, (GLfloat) - 0.202483,
+       (GLfloat) 0.026532, (GLfloat) - 0.106796, (GLfloat) 0.121041,
+       (GLfloat) 0.046695, (GLfloat) - 0.033673, (GLfloat) - 0.043721,
+       (GLfloat) 0.135596, (GLfloat) 0.217426, (GLfloat) - 0.219631,
+       (GLfloat) 0.137627, (GLfloat) 0.026335, (GLfloat) - 0.082390,
+       (GLfloat) - 0.031665, (GLfloat) - 0.115897, (GLfloat) 0.077834,
+       (GLfloat) - 0.214922, (GLfloat) - 0.162169, (GLfloat) 0.073035,
+       (GLfloat) - 0.076108, (GLfloat) 0.200481, (GLfloat) 0.036119,
+       (GLfloat) 0.012715, (GLfloat) - 0.161921, (GLfloat) 0.179804,
+       (GLfloat) 0.140409, (GLfloat) - 0.165899, (GLfloat) - 0.005149,
+       (GLfloat) - 0.054606, (GLfloat) 0.011149, (GLfloat) 0.045768,
+       (GLfloat) 0.116640, (GLfloat) - 0.180314, (GLfloat) 0.045320,
+       (GLfloat) 0.342166, (GLfloat) 0.295895, (GLfloat) - 0.049250,
+       (GLfloat) - 0.133242, (GLfloat) 0.129064, (GLfloat) 0.136969,
+       (GLfloat) 0.137520, (GLfloat) - 0.387145, (GLfloat) 0.132137,
+       (GLfloat) 0.023302, (GLfloat) 0.194298, (GLfloat) - 0.066187,
+       (GLfloat) 0.089302, (GLfloat) 0.128683, (GLfloat) - 0.072530,
+       (GLfloat) - 0.141374, (GLfloat) 0.035924, (GLfloat) - 0.079354,
+       (GLfloat) - 0.209233, (GLfloat) 0.018987, (GLfloat) - 0.004193,
+       (GLfloat) 0.156295, (GLfloat) - 0.034087, (GLfloat) 0.344315,
+       (GLfloat) - 0.005946, (GLfloat) 0.039791, (GLfloat) 0.071862,
+       (GLfloat) 0.076043, (GLfloat) - 0.094430, (GLfloat) 0.090122,
+       (GLfloat) 0.127394, (GLfloat) 0.031466, (GLfloat) - 0.028015,
+       (GLfloat) - 0.061000, (GLfloat) 0.169741, (GLfloat) - 0.127635,
+       (GLfloat) - 0.015117, (GLfloat) - 0.160883, (GLfloat) - 0.095443,
+       (GLfloat) - 0.185998, (GLfloat) - 0.182942, (GLfloat) 0.056857,
+       (GLfloat) 0.016499, (GLfloat) - 0.308118, (GLfloat) - 0.075513,
+       (GLfloat) 0.024971, (GLfloat) - 0.301226, (GLfloat) - 0.027251,
+       (GLfloat) - 0.035944, (GLfloat) 0.061566, (GLfloat) 0.013883,
+       (GLfloat) 0.007215, (GLfloat) 0.046198, (GLfloat) - 0.227891,
+       (GLfloat) 0.189165, (GLfloat) 0.079471, (GLfloat) - 0.067849,
+       (GLfloat) 0.026963, (GLfloat) 0.027982, (GLfloat) - 0.050419,
+       (GLfloat) - 0.050896, (GLfloat) 0.069604, (GLfloat) - 0.196938,
+       (GLfloat) 0.064274, (GLfloat) - 0.205263, (GLfloat) 0.297868,
+       (GLfloat) - 0.047543, (GLfloat) 0.147822, (GLfloat) 0.166593,
+       (GLfloat) 0.010318, (GLfloat) - 0.002148, (GLfloat) 0.029434,
+       (GLfloat) 0.036107, (GLfloat) - 0.523568, (GLfloat) - 0.118442,
+       (GLfloat) - 0.199410, (GLfloat) 0.233526, (GLfloat) - 0.161289,
+       (GLfloat) - 0.047441, (GLfloat) - 0.013973, (GLfloat) 0.112998,
+       (GLfloat) - 0.043494, (GLfloat) - 0.181796, (GLfloat) 0.065864,
+       (GLfloat) - 0.074984, (GLfloat) 0.177758, (GLfloat) - 0.156470,
+       (GLfloat) 0.225216, (GLfloat) 0.081058, (GLfloat) - 0.169876,
+       (GLfloat) - 0.041510, (GLfloat) 0.025763, (GLfloat) - 0.231350,
+       (GLfloat) 0.259015, (GLfloat) 0.274641, (GLfloat) 0.018290,
+       (GLfloat) 0.039196, (GLfloat) 0.010028, (GLfloat) 0.072771,
+       (GLfloat) 0.031646, (GLfloat) 0.075290, (GLfloat) 0.039258,
+       (GLfloat) 0.052930, (GLfloat) - 0.034809, (GLfloat) 0.165429,
+       (GLfloat) - 0.072511, (GLfloat) 0.095786, (GLfloat) - 0.222144,
+       (GLfloat) 0.038706, (GLfloat) 0.032296, (GLfloat) - 0.002495,
+       (GLfloat) 0.011675, (GLfloat) - 0.061944, (GLfloat) 0.082555,
+       (GLfloat) - 0.168400, (GLfloat) 0.074113, (GLfloat) 0.049321,
+       (GLfloat) 0.001263, (GLfloat) - 0.207436, (GLfloat) 0.013949,
+       (GLfloat) - 0.027045, (GLfloat) 0.015697, (GLfloat) - 0.047831,
+       (GLfloat) 0.121989, (GLfloat) - 0.043014, (GLfloat) - 0.004426,
+       (GLfloat) 0.238374, (GLfloat) - 0.320060, (GLfloat) - 0.111754,
+       (GLfloat) 0.095077, (GLfloat) 0.014640, (GLfloat) 0.070665,
+       (GLfloat) - 0.084367, (GLfloat) 0.016444, (GLfloat) 0.000788,
+       (GLfloat) - 0.117804, (GLfloat) 0.113550, (GLfloat) 0.087029,
+       (GLfloat) - 0.109080, (GLfloat) - 0.155795, (GLfloat) 0.040085,
+       (GLfloat) - 0.020370, (GLfloat) 0.118787, (GLfloat) 0.101787,
+       (GLfloat) 0.140877, (GLfloat) - 0.144829, (GLfloat) 0.107720,
+       (GLfloat) - 0.247002, (GLfloat) - 0.454632, (GLfloat) 0.070535,
+       (GLfloat) - 0.016278, (GLfloat) - 0.111440, (GLfloat) 0.270110,
+       (GLfloat) - 0.017624, (GLfloat) - 0.146232, (GLfloat) 0.154626,
+       (GLfloat) 0.214030, (GLfloat) 0.041025, (GLfloat) - 0.170250,
+       (GLfloat) 0.010009, (GLfloat) - 0.159290, (GLfloat) - 0.076895,
+       (GLfloat) 0.116168, (GLfloat) 0.156775, (GLfloat) - 0.077935,
+       (GLfloat) 0.199355, (GLfloat) 0.081120, (GLfloat) 0.003352,
+       (GLfloat) 0.054178, (GLfloat) - 0.036863, (GLfloat) - 0.004573,
+       (GLfloat) - 0.015149, (GLfloat) 0.057005, (GLfloat) - 0.008878,
+       (GLfloat) 0.374758, (GLfloat) - 0.007823, (GLfloat) - 0.078051,
+       (GLfloat) - 0.034977, (GLfloat) 0.026837, (GLfloat) 0.035441,
+       (GLfloat) 0.101867, (GLfloat) 0.121954, (GLfloat) 0.040450,
+       (GLfloat) - 0.136911, (GLfloat) 0.010061, (GLfloat) 0.082698,
+       (GLfloat) 0.121665, (GLfloat) - 0.589852, (GLfloat) 0.106401,
+       (GLfloat) - 0.064574, (GLfloat) 0.098679, (GLfloat) 0.059336,
+       (GLfloat) 0.103037, (GLfloat) - 0.075263, (GLfloat) 0.172586,
+       (GLfloat) - 0.217492, (GLfloat) - 0.170584, (GLfloat) - 0.025846,
+       (GLfloat) 0.260366, (GLfloat) 0.002117, (GLfloat) 0.041535,
+       (GLfloat) - 0.024112, (GLfloat) - 0.023437, (GLfloat) - 0.088146,
+       (GLfloat) - 0.007767, (GLfloat) 0.061738, (GLfloat) 0.116208,
+       (GLfloat) 0.253471, (GLfloat) 0.113278, (GLfloat) 0.231012,
+       (GLfloat) - 0.011399, (GLfloat) 0.116962, (GLfloat) - 0.037465,
+       (GLfloat) 0.233898, (GLfloat) 0.226108, (GLfloat) 0.077176,
+       (GLfloat) - 0.004640, (GLfloat) 0.209191, (GLfloat) - 0.091738,
+       (GLfloat) 0.093995, (GLfloat) 0.328937, (GLfloat) 0.245098,
+       (GLfloat) 0.155739, (GLfloat) - 0.327971, (GLfloat) - 0.115265,
+       (GLfloat) 0.125306, (GLfloat) 0.174931, (GLfloat) 0.130030,
+       (GLfloat) 0.005005, (GLfloat) - 0.022310, (GLfloat) 0.120651,
+       (GLfloat) 0.046982, (GLfloat) - 0.058839, (GLfloat) - 0.097958,
+       (GLfloat) - 0.059618, (GLfloat) - 0.068114, (GLfloat) 0.070137,
+       (GLfloat) 0.053184, (GLfloat) - 0.081163, (GLfloat) 0.000020,
+       (GLfloat) 0.188066, (GLfloat) - 0.082942, (GLfloat) - 0.013689,
+       (GLfloat) - 0.161390, (GLfloat) - 0.335891, (GLfloat) - 0.060737,
+       (GLfloat) 0.131189, (GLfloat) 0.036733, (GLfloat) - 0.093511,
+       (GLfloat) - 0.002496, (GLfloat) - 0.059035, (GLfloat) - 0.084055,
+       (GLfloat) 0.109820, (GLfloat) - 0.235531, (GLfloat) 0.130865,
+       (GLfloat) 0.018909, (GLfloat) 0.062351, (GLfloat) 0.111532,
+       (GLfloat) 0.123548, (GLfloat) 0.094008, (GLfloat) 0.056761,
+       (GLfloat) 0.106710, (GLfloat) - 0.049834, (GLfloat) - 0.147748,
+       (GLfloat) 0.102940, (GLfloat) - 0.113169, (GLfloat) 0.191710,
+       (GLfloat) - 0.028647, (GLfloat) 0.128038, (GLfloat) - 0.104189,
+       (GLfloat) 0.107226, (GLfloat) - 0.220633, (GLfloat) - 0.147310,
+       (GLfloat) - 0.205747, (GLfloat) 0.063433, (GLfloat) - 0.026135,
+       (GLfloat) - 0.064614, (GLfloat) 0.096963, (GLfloat) - 0.080108,
+       (GLfloat) - 0.083255, (GLfloat) 0.113008, (GLfloat) - 0.089852,
+       (GLfloat) 0.180961, (GLfloat) - 0.269100, (GLfloat) 0.115523,
+       (GLfloat) 0.044722, (GLfloat) - 0.023285, (GLfloat) 0.024813,
+       (GLfloat) 0.078986, (GLfloat) 0.037242, (GLfloat) 0.005124,
+       (GLfloat) 0.115141, (GLfloat) 0.124478, (GLfloat) - 0.034603,
+       (GLfloat) 0.022454, (GLfloat) 0.155937, (GLfloat) - 0.096183,
+       (GLfloat) 0.175318, (GLfloat) 0.007233, (GLfloat) - 0.138507,
+       (GLfloat) 0.019182, (GLfloat) - 0.037869, (GLfloat) 0.074242,
+       (GLfloat) 0.058218, (GLfloat) 0.212269, (GLfloat) - 0.003886,
+       (GLfloat) - 0.188525, (GLfloat) - 0.075703, (GLfloat) 0.075643,
+       (GLfloat) - 0.029085, (GLfloat) - 0.076746, (GLfloat) - 0.273473,
+       (GLfloat) - 0.105590, (GLfloat) - 0.238524, (GLfloat) - 0.087465,
+       (GLfloat) 0.086122, (GLfloat) - 0.340807, (GLfloat) - 0.192851,
+       (GLfloat) - 0.247936, (GLfloat) - 0.003160, (GLfloat) 0.082106,
+       (GLfloat) 0.137988, (GLfloat) - 0.041876, (GLfloat) - 0.012086,
+       (GLfloat) - 0.140714, (GLfloat) - 0.138827, (GLfloat) - 0.064179,
+       (GLfloat) - 0.059380, (GLfloat) 0.015642, (GLfloat) 0.113841,
+       (GLfloat) - 0.031501, (GLfloat) 0.007130, (GLfloat) - 0.125767,
+       (GLfloat) 0.021294, (GLfloat) - 0.021957, (GLfloat) - 0.069365,
+       (GLfloat) - 0.012419, (GLfloat) 0.019780, (GLfloat) - 0.077459,
+       (GLfloat) 0.085524, (GLfloat) 0.087513, (GLfloat) - 0.107484,
+       (GLfloat) - 0.303263, (GLfloat) 0.263672, (GLfloat) - 0.220649,
+       (GLfloat) - 0.090267, (GLfloat) - 0.376337, (GLfloat) - 0.127634,
+       (GLfloat) 0.087681, (GLfloat) 0.015985, (GLfloat) - 0.029860,
+       (GLfloat) 0.119257, (GLfloat) 0.140347, (GLfloat) 0.194003,
+       (GLfloat) 0.066270, (GLfloat) 0.127178, (GLfloat) - 0.003765,
+       (GLfloat) 0.037563, (GLfloat) - 0.110829, (GLfloat) 0.000382,
+       (GLfloat) 0.034295, (GLfloat) - 0.045737, (GLfloat) 0.045204,
+       (GLfloat) 0.017365, (GLfloat) - 0.072708, (GLfloat) 0.056698,
+       (GLfloat) 0.045238, (GLfloat) 0.187956, (GLfloat) - 0.055878,
+       (GLfloat) - 0.132755, (GLfloat) 0.017969, (GLfloat) - 0.041205,
+       (GLfloat) 0.189702, (GLfloat) - 0.020780, (GLfloat) - 0.077422,
+       (GLfloat) 0.210419, (GLfloat) 0.178041, (GLfloat) - 0.005855,
+       (GLfloat) 0.104527, (GLfloat) - 0.304323, (GLfloat) 0.002581,
+       (GLfloat) 0.043359, (GLfloat) - 0.060695, (GLfloat) - 0.011878,
+       (GLfloat) - 0.000267, (GLfloat) 0.020510, (GLfloat) - 0.046383,
+       (GLfloat) 0.252891, (GLfloat) 0.074246, (GLfloat) - 0.047689,
+       (GLfloat) - 0.069874, (GLfloat) 0.118962, (GLfloat) - 0.052781,
+       (GLfloat) 0.086188, (GLfloat) 0.068354, (GLfloat) - 0.213621,
+       (GLfloat) 0.086637, (GLfloat) - 0.171519, (GLfloat) 0.006447,
+       (GLfloat) 0.196785, (GLfloat) - 0.086044, (GLfloat) - 0.068059,
+       (GLfloat) 0.100401, (GLfloat) 0.243886, (GLfloat) - 0.142258,
+       (GLfloat) 0.173010, (GLfloat) 0.303375, (GLfloat) - 0.060085,
+       (GLfloat) - 0.041181, (GLfloat) - 0.097467, (GLfloat) 0.073776,
+       (GLfloat) - 0.013471, (GLfloat) - 0.133299, (GLfloat) - 0.143570,
+       (GLfloat) - 0.302092, (GLfloat) - 0.158342, (GLfloat) 0.230719,
+       (GLfloat) 0.074434, (GLfloat) - 0.143530, (GLfloat) 0.294895,
+       (GLfloat) - 0.165626, (GLfloat) 0.200869, (GLfloat) - 0.130737,
+       (GLfloat) 0.102444, (GLfloat) 0.277067, (GLfloat) 0.078210,
+       (GLfloat) - 0.183696, (GLfloat) - 0.010502, (GLfloat) - 0.150481,
+       (GLfloat) - 0.070029, (GLfloat) - 0.019635, (GLfloat) - 0.059141,
+       (GLfloat) - 0.005930, (GLfloat) 0.069199, (GLfloat) - 0.013126,
+       (GLfloat) - 0.119333, (GLfloat) - 0.007972, (GLfloat) 0.119489,
+       (GLfloat) 0.033072, (GLfloat) 0.081756, (GLfloat) - 0.034481,
+       (GLfloat) - 0.108282, (GLfloat) - 0.065310, (GLfloat) 0.146009,
+       (GLfloat) 0.080950, (GLfloat) 0.111320, (GLfloat) 0.004291,
+       (GLfloat) 0.071208, (GLfloat) - 0.112941, (GLfloat) 0.028135,
+       (GLfloat) - 0.024632, (GLfloat) 0.190525, (GLfloat) - 0.285626,
+       (GLfloat) - 0.105040, (GLfloat) 0.044008, (GLfloat) 0.020236,
+       (GLfloat) - 0.017815, (GLfloat) - 0.076684, (GLfloat) - 0.065840,
+       (GLfloat) 0.083563, (GLfloat) 0.100873, (GLfloat) - 0.141154,
+       (GLfloat) - 0.062066, (GLfloat) - 0.010894, (GLfloat) 0.066110,
+       (GLfloat) - 0.056763, (GLfloat) 0.024777, (GLfloat) - 0.176209,
+       (GLfloat) - 0.014442, (GLfloat) 0.052861, (GLfloat) 0.013010,
+       (GLfloat) - 0.157546, (GLfloat) - 0.118279, (GLfloat) - 0.237648,
+       (GLfloat) - 0.234497, (GLfloat) - 0.158049, (GLfloat) 0.102635,
+       (GLfloat) 0.061685, (GLfloat) - 0.052695, (GLfloat) - 0.042243,
+       (GLfloat) 0.093961, (GLfloat) - 0.025060, (GLfloat) 0.046602,
+       (GLfloat) 0.004395, (GLfloat) 0.150912, (GLfloat) 0.191784,
+       (GLfloat) 0.067299, (GLfloat) - 0.059575, (GLfloat) 0.161018,
+       (GLfloat) - 0.233155, (GLfloat) - 0.109721, (GLfloat) 0.194653,
+       (GLfloat) 0.217444, (GLfloat) 0.221231, (GLfloat) - 0.201241,
+       (GLfloat) - 0.033689, (GLfloat) - 0.341937, (GLfloat) - 0.099231,
+       (GLfloat) 0.042771, (GLfloat) - 0.028862, (GLfloat) 0.067736,
+       (GLfloat) 0.110240, (GLfloat) 0.274029, (GLfloat) - 0.157689,
+       (GLfloat) - 0.055994, (GLfloat) 0.144729, (GLfloat) 0.090901,
+       (GLfloat) 0.211192, (GLfloat) 0.058165, (GLfloat) - 0.149872,
+       (GLfloat) 0.102735, (GLfloat) - 0.044061, (GLfloat) - 0.044795,
+       (GLfloat) - 0.042153, (GLfloat) - 0.010955, (GLfloat) 0.014341,
+       (GLfloat) - 0.011649, (GLfloat) 0.099072, (GLfloat) - 0.086419,
+       (GLfloat) - 0.018920, (GLfloat) 0.000640, (GLfloat) - 0.031729,
+       (GLfloat) - 0.216886, (GLfloat) - 0.057512, (GLfloat) 0.071195,
+       (GLfloat) - 0.188150, (GLfloat) 0.049292, (GLfloat) 0.258489,
+       (GLfloat) - 0.023494, (GLfloat) 0.021489, (GLfloat) 0.199785,
+       (GLfloat) - 0.045818, (GLfloat) 0.066753, (GLfloat) - 0.035593,
+       (GLfloat) 0.010986, (GLfloat) 0.166767, (GLfloat) 0.275085,
+       (GLfloat) - 0.177039, (GLfloat) 0.010372, (GLfloat) 0.167936,
+       (GLfloat) - 0.423239, (GLfloat) 0.027466, (GLfloat) - 0.126114,
+       (GLfloat) - 0.102035, (GLfloat) 0.282640, (GLfloat) 0.022622,
+       (GLfloat) - 0.023997, (GLfloat) 0.176943, (GLfloat) 0.093272,
+       (GLfloat) - 0.090009, (GLfloat) 0.015338, (GLfloat) 0.250857,
+       (GLfloat) 0.011095, (GLfloat) 0.006703, (GLfloat) 0.057076,
+       (GLfloat) 0.133423, (GLfloat) 0.234639, (GLfloat) - 0.070260,
+       (GLfloat) - 0.295994, (GLfloat) 0.185615, (GLfloat) 0.117148,
+       (GLfloat) 0.235480, (GLfloat) 0.066195, (GLfloat) 0.078641,
+       (GLfloat) - 0.026545, (GLfloat) 0.093931, (GLfloat) 0.008019,
+       (GLfloat) 0.181656, (GLfloat) - 0.088719, (GLfloat) 0.045959,
+       (GLfloat) - 0.076308, (GLfloat) - 0.164584, (GLfloat) 0.018271,
+       (GLfloat) 0.092026, (GLfloat) 0.201866, (GLfloat) - 0.106051,
+       (GLfloat) 0.019876, (GLfloat) 0.050967, (GLfloat) 0.176081,
+       (GLfloat) - 0.018546, (GLfloat) 0.138749, (GLfloat) - 0.008255,
+       (GLfloat) - 0.026049, (GLfloat) - 0.068465, (GLfloat) - 0.055467,
+       (GLfloat) - 0.260245, (GLfloat) 0.221833, (GLfloat) - 0.048541,
+       (GLfloat) - 0.169783, (GLfloat) 0.354992, (GLfloat) - 0.017943,
+       (GLfloat) - 0.306063, (GLfloat) 0.074787, (GLfloat) 0.101971,
+       (GLfloat) 0.215973, (GLfloat) 0.107558, (GLfloat) - 0.008808,
+       (GLfloat) 0.390235, (GLfloat) - 0.275652, (GLfloat) - 0.117085,
+       (GLfloat) 0.033898, (GLfloat) 0.046047, (GLfloat) - 0.108977,
+       (GLfloat) - 0.263507, (GLfloat) - 0.091765, (GLfloat) - 0.250234,
+       (GLfloat) - 0.044613, (GLfloat) 0.149563, (GLfloat) 0.027937,
+       (GLfloat) - 0.015397, (GLfloat) - 0.040254, (GLfloat) 0.065692,
+       (GLfloat) - 0.017531, (GLfloat) - 0.013504, (GLfloat) 0.004021,
+       (GLfloat) 0.054665, (GLfloat) - 0.018996, (GLfloat) - 0.006954,
+       (GLfloat) 0.033068, (GLfloat) 0.219349, (GLfloat) - 0.194079,
+       (GLfloat) - 0.057780, (GLfloat) 0.011881, (GLfloat) 0.084904,
+       (GLfloat) 0.139243, (GLfloat) - 0.109890, (GLfloat) 0.039145,
+       (GLfloat) 0.223272, (GLfloat) 0.208110, (GLfloat) 0.165882,
+       (GLfloat) - 0.008046, (GLfloat) 0.103847, (GLfloat) 0.278718,
+       (GLfloat) - 0.035499, (GLfloat) 0.112662, (GLfloat) - 0.088418,
+       (GLfloat) - 0.053118, (GLfloat) 0.053871, (GLfloat) - 0.054706,
+       (GLfloat) 0.118632, (GLfloat) 0.086431, (GLfloat) - 0.022494,
+       (GLfloat) 0.014943, (GLfloat) 0.039622, (GLfloat) 0.047307,
+       (GLfloat) 0.006570, (GLfloat) 0.093461, (GLfloat) 0.058982,
+       (GLfloat) 0.031448, (GLfloat) 0.325716, (GLfloat) - 0.047305,
+       (GLfloat) - 0.193710, (GLfloat) 0.087226, (GLfloat) 0.051790,
+       (GLfloat) 0.116154, (GLfloat) - 0.080023, (GLfloat) - 0.106643,
+       (GLfloat) 0.156514, (GLfloat) - 0.222710, (GLfloat) 0.275425,
+       (GLfloat) - 0.084294, (GLfloat) - 0.101851, (GLfloat) 0.425222,
+       (GLfloat) 0.030344, (GLfloat) - 0.141370, (GLfloat) - 0.282460,
+       (GLfloat) 0.003022, (GLfloat) 0.108996, (GLfloat) - 0.229152,
+       (GLfloat) - 0.133040, (GLfloat) 0.061025, (GLfloat) - 0.128942,
+       (GLfloat) - 0.077348, (GLfloat) 0.013363, (GLfloat) - 0.072511,
+       (GLfloat) - 0.050317, (GLfloat) 0.452190, (GLfloat) 0.094114,
+       (GLfloat) 0.053309, (GLfloat) - 0.143722, (GLfloat) 0.249884,
+       (GLfloat) - 0.257016, (GLfloat) 0.100544, (GLfloat) 0.012236,
+       (GLfloat) - 0.022056, (GLfloat) - 0.212133, (GLfloat) 0.023533,
+       (GLfloat) 0.153299, (GLfloat) 0.031763, (GLfloat) 0.034577,
+       (GLfloat) 0.161729, (GLfloat) 0.084914, (GLfloat) 0.050770,
+       (GLfloat) 0.320438, (GLfloat) 0.112175, (GLfloat) 0.135015,
+       (GLfloat) - 0.040717, (GLfloat) 0.073400, (GLfloat) 0.080543,
+       (GLfloat) - 0.226004, (GLfloat) 0.143154, (GLfloat) 0.170139,
+       (GLfloat) 0.009756, (GLfloat) 0.068337, (GLfloat) 0.132111,
+       (GLfloat) 0.380191, (GLfloat) 0.233715, (GLfloat) 0.026664,
+       (GLfloat) - 0.018016, (GLfloat) 0.265426, (GLfloat) - 0.110691,
+       (GLfloat) 0.041281, (GLfloat) 0.056674, (GLfloat) - 0.119834,
+       (GLfloat) 0.170794, (GLfloat) - 0.112611, (GLfloat) 0.094839,
+       (GLfloat) 0.216318, (GLfloat) 0.002081, (GLfloat) 0.154653,
+       (GLfloat) - 0.036815, (GLfloat) 0.024332, (GLfloat) 0.172587,
+       (GLfloat) - 0.064554, (GLfloat) 0.160699, (GLfloat) 0.101229,
+       (GLfloat) 0.114451, (GLfloat) 0.016039, (GLfloat) 0.293489,
+       (GLfloat) 0.023010, (GLfloat) - 0.028932, (GLfloat) 0.014800,
+       (GLfloat) - 0.290527, (GLfloat) 0.172553, (GLfloat) 0.129526,
+       (GLfloat) - 0.048159, (GLfloat) - 0.181222, (GLfloat) 0.305871,
+       (GLfloat) 0.065351, (GLfloat) - 0.399962, (GLfloat) - 0.030479,
+       (GLfloat) 0.334123, (GLfloat) - 0.120149, (GLfloat) 0.241310,
+       (GLfloat) - 0.203728, (GLfloat) - 0.155627, (GLfloat) 0.140805,
+       (GLfloat) 0.061022, (GLfloat) - 0.016097, (GLfloat) 0.131688,
+       (GLfloat) 0.045050, (GLfloat) - 0.313782, (GLfloat) - 0.279077,
+       (GLfloat) 0.034252, (GLfloat) - 0.135512, (GLfloat) - 0.087765,
+       (GLfloat) 0.276236, (GLfloat) 0.036449, (GLfloat) 0.418332,
+       (GLfloat) - 0.122146, (GLfloat) 0.050998, (GLfloat) 0.131453,
+       (GLfloat) - 0.087629, (GLfloat) 0.330142, (GLfloat) 0.061353,
+       (GLfloat) 0.228676, (GLfloat) 0.093309, (GLfloat) - 0.009307,
+       (GLfloat) 0.435264, (GLfloat) 0.186185, (GLfloat) - 0.127484,
+       (GLfloat) 0.156565, (GLfloat) 0.013842, (GLfloat) - 0.103874,
+       (GLfloat) - 0.274053, (GLfloat) - 0.084119, (GLfloat) 0.096687,
+       (GLfloat) - 0.027947, (GLfloat) - 0.051152, (GLfloat) - 0.078997,
+       (GLfloat) 0.013399, (GLfloat) 0.194440, (GLfloat) 0.072030,
+       (GLfloat) 0.000082, (GLfloat) 0.130666, (GLfloat) 0.052218,
+       (GLfloat) 0.064984, (GLfloat) - 0.136859, (GLfloat) 0.092204,
+       (GLfloat) 0.109060, (GLfloat) 0.424779, (GLfloat) - 0.111867,
+       (GLfloat) 0.061748, (GLfloat) 0.160827, (GLfloat) - 0.068538,
+       (GLfloat) 0.062960, (GLfloat) 0.059638, (GLfloat) - 0.181514,
+       (GLfloat) 0.018961, (GLfloat) 0.072298, (GLfloat) 0.003517,
+       (GLfloat) - 0.099508, (GLfloat) - 0.225455, (GLfloat) - 0.021791,
+       (GLfloat) 0.001955, (GLfloat) - 0.320555, (GLfloat) 0.159506,
+       (GLfloat) - 0.057735, (GLfloat) - 0.054327, (GLfloat) - 0.095525,
+       (GLfloat) 0.319748, (GLfloat) - 0.146158, (GLfloat) - 0.198384,
+       (GLfloat) - 0.158741, (GLfloat) - 0.265443, (GLfloat) 0.036635,
+       (GLfloat) - 0.093089, (GLfloat) - 0.358379, (GLfloat) - 0.110549,
+       (GLfloat) - 0.049805, (GLfloat) 0.022246, (GLfloat) - 0.036724,
+       (GLfloat) 0.223000, (GLfloat) 0.247522, (GLfloat) - 0.232652,
+       (GLfloat) - 0.249441, (GLfloat) - 0.248325, (GLfloat) - 0.071169,
+       (GLfloat) 0.000369, (GLfloat) 0.094598, (GLfloat) - 0.162153,
+       (GLfloat) - 0.133873, (GLfloat) - 0.188473, (GLfloat) 0.272734,
+       (GLfloat) 0.046594, (GLfloat) 0.069766, (GLfloat) 0.015561,
+       (GLfloat) 0.111582, (GLfloat) - 0.239786, (GLfloat) 0.034658,
+       (GLfloat) 0.093232, (GLfloat) 0.183507, (GLfloat) - 0.011298,
+       (GLfloat) - 0.226805, (GLfloat) 0.514871, (GLfloat) - 0.064144,
+       (GLfloat) 0.085949, (GLfloat) 0.031412, (GLfloat) 0.042790,
+       (GLfloat) - 0.043755, (GLfloat) - 0.290797, (GLfloat) - 0.159142,
+       (GLfloat) 0.056671, (GLfloat) 0.167837, (GLfloat) 0.016536,
+       (GLfloat) - 0.034538, (GLfloat) 0.072185, (GLfloat) 0.066973,
+       (GLfloat) - 0.021211, (GLfloat) 0.064120, (GLfloat) - 0.174756,
+       (GLfloat) 0.090627, (GLfloat) - 0.055253, (GLfloat) 0.109457,
+       (GLfloat) 0.019686, (GLfloat) 0.004469, (GLfloat) - 0.096316,
+       (GLfloat) - 0.038864, (GLfloat) - 0.135083, (GLfloat) 0.244529,
+       (GLfloat) 0.034613, (GLfloat) - 0.069587, (GLfloat) 0.144533,
+       (GLfloat) - 0.100009, (GLfloat) - 0.057516, (GLfloat) - 0.079338,
+       (GLfloat) - 0.178026, (GLfloat) 0.085994, (GLfloat) 0.061804,
+       (GLfloat) - 0.189256, (GLfloat) 0.342739, (GLfloat) 0.043372,
+       (GLfloat) - 0.046206, (GLfloat) 0.168946, (GLfloat) - 0.133904,
+       (GLfloat) 0.015314, (GLfloat) - 0.090127, (GLfloat) - 0.058530,
+       (GLfloat) 0.169657, (GLfloat) - 0.097086, (GLfloat) 0.013746,
+       (GLfloat) 0.185131, (GLfloat) - 0.089445, (GLfloat) 0.347806,
+       (GLfloat) - 0.264432, (GLfloat) - 0.170170, (GLfloat) - 0.335858,
+       (GLfloat) - 0.086511, (GLfloat) 0.248252, (GLfloat) - 0.169698,
+       (GLfloat) 0.002287, (GLfloat) - 0.028338, (GLfloat) - 0.266432,
+       (GLfloat) - 0.085060, (GLfloat) 0.001974, (GLfloat) - 0.032789,
+       (GLfloat) 0.192750, (GLfloat) - 0.007081, (GLfloat) 0.098197,
+       (GLfloat) 0.012577, (GLfloat) 0.034983, (GLfloat) - 0.003058,
+       (GLfloat) - 0.039249, (GLfloat) 0.038498, (GLfloat) 0.067306,
+       (GLfloat) 0.021988, (GLfloat) 0.379705, (GLfloat) - 0.054619,
+       (GLfloat) - 0.151707, (GLfloat) 0.051034, (GLfloat) - 0.016003,
+       (GLfloat) - 0.057048, (GLfloat) 0.075729, (GLfloat) - 0.213397,
+       (GLfloat) - 0.137847, (GLfloat) 0.130600, (GLfloat) 0.046198,
+       (GLfloat) 0.024786, (GLfloat) 0.049556, (GLfloat) - 0.045772,
+       (GLfloat) - 0.082533, (GLfloat) 0.155397, (GLfloat) - 0.096145,
+       (GLfloat) 0.049152, (GLfloat) 0.270979, (GLfloat) - 0.147022,
+       (GLfloat) 0.061153, (GLfloat) - 0.104531, (GLfloat) - 0.103623,
+       (GLfloat) - 0.142997, (GLfloat) - 0.232885, (GLfloat) 0.040538,
+       (GLfloat) 0.048806, (GLfloat) - 0.013095, (GLfloat) - 0.003505,
+       (GLfloat) - 0.095063, (GLfloat) 0.241414, (GLfloat) - 0.202255,
+       (GLfloat) 0.108558, (GLfloat) - 0.147584, (GLfloat) 0.162682,
+       (GLfloat) 0.217105, (GLfloat) 0.252340, (GLfloat) - 0.114830,
+       (GLfloat) - 0.188028, (GLfloat) 0.417252, (GLfloat) - 0.077456,
+       (GLfloat) - 0.112855, (GLfloat) 0.105192, (GLfloat) 0.073968,
+       (GLfloat) - 0.186972, (GLfloat) 0.164022, (GLfloat) - 0.073415,
+       (GLfloat) - 0.074349, (GLfloat) - 0.324874, (GLfloat) - 0.056645,
+       (GLfloat) 0.327855, (GLfloat) - 0.271424, (GLfloat) - 0.141142,
+       (GLfloat) 0.151049, (GLfloat) 0.155239, (GLfloat) - 0.083116,
+       (GLfloat) 0.035395, (GLfloat) - 0.133176, (GLfloat) - 0.095112,
+       (GLfloat) 0.127283, (GLfloat) - 0.011837, (GLfloat) 0.199750,
+       (GLfloat) - 0.120775, (GLfloat) 0.103698, (GLfloat) 0.063302,
+       (GLfloat) 0.014222, (GLfloat) 0.198468, (GLfloat) 0.137537,
+       (GLfloat) - 0.269656, (GLfloat) 0.120644, (GLfloat) - 0.153958,
+       (GLfloat) - 0.136743, (GLfloat) - 0.119817, (GLfloat) - 0.073747,
+       (GLfloat) - 0.068156, (GLfloat) - 0.138484, (GLfloat) 0.033507,
+       (GLfloat) - 0.106835, (GLfloat) 0.114964, (GLfloat) 0.023924,
+       (GLfloat) - 0.222525, (GLfloat) 0.330321, (GLfloat) - 0.007431,
+       (GLfloat) - 0.011739, (GLfloat) 0.095156, (GLfloat) 0.139086,
+       (GLfloat) 0.146766, (GLfloat) 0.037685, (GLfloat) 0.136122,
+       (GLfloat) - 0.086532, (GLfloat) - 0.081295, (GLfloat) 0.009434,
+       (GLfloat) 0.189439, (GLfloat) 0.290592, (GLfloat) - 0.048317,
+       (GLfloat) 0.139152, (GLfloat) 0.224931, (GLfloat) 0.355509,
+       (GLfloat) 0.017162, (GLfloat) - 0.016825, (GLfloat) 0.094198,
+       (GLfloat) - 0.237595, (GLfloat) 0.205475, (GLfloat) - 0.041412,
+       (GLfloat) 0.050511, (GLfloat) 0.094900, (GLfloat) 0.252891,
+       (GLfloat) - 0.012538, (GLfloat) - 0.014082, (GLfloat) 0.064629,
+       (GLfloat) - 0.059810, (GLfloat) 0.020665, (GLfloat) - 0.260979,
+       (GLfloat) 0.073490, (GLfloat) - 0.242270, (GLfloat) 0.085847,
+       (GLfloat) 0.049499, (GLfloat) - 0.045617, (GLfloat) - 0.015894,
+       (GLfloat) - 0.121040, (GLfloat) 0.004350, (GLfloat) 0.381603,
+       (GLfloat) - 0.062798, (GLfloat) 0.055006, (GLfloat) 0.077472,
+       (GLfloat) - 0.156846, (GLfloat) - 0.033342, (GLfloat) 0.035284,
+       (GLfloat) 0.105383, (GLfloat) 0.002776, (GLfloat) - 0.046394,
+       (GLfloat) 0.247612, (GLfloat) 0.310528, (GLfloat) 0.046188,
+       (GLfloat) - 0.144567, (GLfloat) - 0.197996, (GLfloat) 0.083309,
+       (GLfloat) - 0.317845, (GLfloat) - 0.014793, (GLfloat) - 0.041608,
+       (GLfloat) - 0.169858, (GLfloat) 0.102631, (GLfloat) 0.283962,
+       (GLfloat) - 0.168757, (GLfloat) 0.093105, (GLfloat) 0.050325,
+       (GLfloat) - 0.013639, (GLfloat) 0.285100, (GLfloat) 0.047089,
+       (GLfloat) 0.216644, (GLfloat) 0.102018, (GLfloat) 0.031983,
+       (GLfloat) 0.046988, (GLfloat) 0.081482, (GLfloat) 0.021865,
+       (GLfloat) 0.124995, (GLfloat) - 0.193086, (GLfloat) 0.127870,
+       (GLfloat) 0.009153, (GLfloat) 0.178713, (GLfloat) - 0.077949,
+       (GLfloat) - 0.235371, (GLfloat) - 0.046817, (GLfloat) - 0.125764,
+       (GLfloat) - 0.089381, (GLfloat) 0.289172, (GLfloat) - 0.129356,
+       (GLfloat) 0.312993, (GLfloat) 0.120426, (GLfloat) 0.296957,
+       (GLfloat) - 0.106431, (GLfloat) 0.117096, (GLfloat) 0.156971,
+       (GLfloat) 0.030001, (GLfloat) 0.244577, (GLfloat) 0.085119,
+       (GLfloat) 0.002958, (GLfloat) - 0.035469, (GLfloat) - 0.084615,
+       (GLfloat) - 0.052248, (GLfloat) - 0.004298, (GLfloat) - 0.129170,
+       (GLfloat) - 0.158458, (GLfloat) 0.059061, (GLfloat) - 0.041780,
+       (GLfloat) - 0.007117, (GLfloat) - 0.174211, (GLfloat) 0.098819,
+       (GLfloat) - 0.158387, (GLfloat) 0.060840, (GLfloat) - 0.064818,
+       (GLfloat) 0.117241, (GLfloat) - 0.050754, (GLfloat) - 0.027945,
+       (GLfloat) - 0.014301, (GLfloat) 0.146402, (GLfloat) - 0.118414,
+       (GLfloat) 0.186611, (GLfloat) - 0.162182, (GLfloat) - 0.150909,
+       (GLfloat) - 0.106992, (GLfloat) 0.286109, (GLfloat) - 0.055512,
+       (GLfloat) 0.109689, (GLfloat) - 0.346409, (GLfloat) 0.072611,
+       (GLfloat) - 0.009694, (GLfloat) - 0.038102, (GLfloat) 0.098565,
+       (GLfloat) - 0.034598, (GLfloat) 0.323300, (GLfloat) 0.020962,
+       (GLfloat) - 0.149219, (GLfloat) 0.040596, (GLfloat) - 0.114206,
+       (GLfloat) 0.164744, (GLfloat) 0.048081, (GLfloat) 0.105464,
+       (GLfloat) 0.036214, (GLfloat) 0.099523, (GLfloat) 0.038595,
+       (GLfloat) 0.056537, (GLfloat) 0.036271, (GLfloat) 0.003042,
+       (GLfloat) - 0.157110, (GLfloat) 0.001614, (GLfloat) - 0.133994,
+       (GLfloat) - 0.104357, (GLfloat) - 0.032004, (GLfloat) 0.262334,
+       (GLfloat) 0.041215, (GLfloat) - 0.010418, (GLfloat) - 0.037968,
+       (GLfloat) 0.223491, (GLfloat) - 0.387946, (GLfloat) 0.117291,
+       (GLfloat) - 0.344434, (GLfloat) 0.110318, (GLfloat) - 0.031448,
+       (GLfloat) 0.123562, (GLfloat) - 0.315729, (GLfloat) 0.164533,
+       (GLfloat) 0.008207, (GLfloat) 0.042004, (GLfloat) 0.050014,
+       (GLfloat) - 0.191339, (GLfloat) - 0.069291, (GLfloat) - 0.220065,
+       (GLfloat) 0.023845, (GLfloat) 0.009474, (GLfloat) 0.035598,
+       (GLfloat) - 0.173295, (GLfloat) - 0.036604, (GLfloat) - 0.193323,
+       (GLfloat) - 0.040347, (GLfloat) - 0.106063, (GLfloat) - 0.055559,
+       (GLfloat) - 0.071543, (GLfloat) 0.136487, (GLfloat) 0.105697,
+       (GLfloat) - 0.179027, (GLfloat) - 0.071852, (GLfloat) 0.117512,
+       (GLfloat) 0.064769, (GLfloat) - 0.345895, (GLfloat) 0.012833,
+       (GLfloat) 0.044800, (GLfloat) - 0.032357, (GLfloat) - 0.042161,
+       (GLfloat) 0.243586, (GLfloat) 0.392499, (GLfloat) - 0.180641,
+       (GLfloat) - 0.148924, (GLfloat) - 0.181446, (GLfloat) 0.146644,
+       (GLfloat) - 0.042773, (GLfloat) 0.045843, (GLfloat) - 0.176893,
+       (GLfloat) 0.025938, (GLfloat) 0.058109, (GLfloat) 0.242063,
+       (GLfloat) - 0.028489, (GLfloat) - 0.024828, (GLfloat) 0.161289,
+       (GLfloat) 0.073899, (GLfloat) - 0.081205, (GLfloat) - 0.023751,
+       (GLfloat) 0.026149, (GLfloat) 0.051399, (GLfloat) - 0.072348,
+       (GLfloat) 0.024308, (GLfloat) - 0.041819, (GLfloat) - 0.030578,
+       (GLfloat) - 0.077778, (GLfloat) 0.010272, (GLfloat) 0.066967,
+       (GLfloat) - 0.139184, (GLfloat) - 0.018983, (GLfloat) 0.035150,
+       (GLfloat) - 0.061359, (GLfloat) - 0.152358, (GLfloat) - 0.072849,
+       (GLfloat) 0.043101, (GLfloat) 0.028278, (GLfloat) 0.077387,
+       (GLfloat) 0.065599, (GLfloat) - 0.049676, (GLfloat) 0.043708,
+       (GLfloat) - 0.255767, (GLfloat) 0.023510, (GLfloat) - 0.076982,
+       (GLfloat) 0.020468, (GLfloat) - 0.040630, (GLfloat) 0.208424,
+       (GLfloat) 0.044922, (GLfloat) 0.025184, (GLfloat) 0.004764,
+       (GLfloat) 0.107432, (GLfloat) - 0.009356, (GLfloat) 0.239863,
+       (GLfloat) - 0.005475, (GLfloat) 0.158400, (GLfloat) 0.089743,
+       (GLfloat) 0.018352, (GLfloat) 0.134559, (GLfloat) 0.221650,
+       (GLfloat) 0.094423, (GLfloat) 0.129390, (GLfloat) - 0.031274,
+       (GLfloat) 0.048541, (GLfloat) 0.100595, (GLfloat) - 0.155938,
+       (GLfloat) - 0.016298, (GLfloat) - 0.036518, (GLfloat) - 0.149178,
+       (GLfloat) - 0.329953, (GLfloat) - 0.327602, (GLfloat) - 0.150086,
+       (GLfloat) 0.148403, (GLfloat) - 0.363334, (GLfloat) 0.028237,
+       (GLfloat) - 0.305790, (GLfloat) - 0.009844, (GLfloat) - 0.075571,
+       (GLfloat) - 0.045131, (GLfloat) 0.152595, (GLfloat) 0.228720,
+       (GLfloat) 0.039725, (GLfloat) - 0.127469, (GLfloat) 0.066522,
+       (GLfloat) - 0.078576, (GLfloat) - 0.349749, (GLfloat) - 0.146881,
+       (GLfloat) 0.013160, (GLfloat) - 0.040312, (GLfloat) 0.129980,
+       (GLfloat) 0.221142, (GLfloat) - 0.106068, (GLfloat) 0.254967,
+       (GLfloat) 0.180912, (GLfloat) - 0.207357, (GLfloat) - 0.196999,
+       (GLfloat) 0.098219, (GLfloat) 0.085231, (GLfloat) 0.121963,
+};
+
+struct lwo  LWO_s1_b =
+{
+       500,                    /* number of points */
+       s1_b_PNTS, 0L, 0L, 0L
+};
+
+#endif /* MODE_sproingies */
+
+/* End of s1_b.c */
diff --git a/xlockmore-4.14/modes/glx/shark.c b/xlockmore-4.14/modes/glx/shark.c
new file mode 100644 (file)
index 0000000..f51aa89
--- /dev/null
@@ -0,0 +1,1403 @@
+/* atlantis --- Shows moving 3D sea animals */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)shark.c      1.2 98/06/16 xlockmore";
+
+#endif
+
+/* Copyright (c) E. Lassauge, 1998. */
+
+/*
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The original code for this mode was written by Mark J. Kilgard
+ * as a demo for openGL programming.
+ * 
+ * Porting it to xlock  was possible by comparing the original Mesa's morph3d 
+ * demo with it's ported version to xlock, so thanks for Marcelo F. Vianna 
+ * (look at morph3d.c) for his indirect help.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * My e-mail address is lassauge@sagem.fr
+ *
+ * Eric Lassauge  (May-13-1998)
+ *
+ */
+
+/**
+ * (c) Copyright 1993, 1994, Silicon Graphics, Inc.
+ * ALL RIGHTS RESERVED
+ * Permission to use, copy, modify, and distribute this software for
+ * any purpose and without fee is hereby granted, provided that the above
+ * copyright notice appear in all copies and that both the copyright notice
+ * and this permission notice appear in supporting documentation, and that
+ * the name of Silicon Graphics, Inc. not be used in advertising
+ * or publicity pertaining to distribution of the software without specific,
+ * written prior permission.
+ *
+ * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
+ * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
+ * FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
+ * GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
+ * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
+ * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
+ * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
+ * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
+ * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
+ * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * US Government Users Restricted Rights
+ * Use, duplication, or disclosure by the Government is subject to
+ * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
+ * (c)(1)(ii) of the Rights in Technical Data and Computer Software
+ * clause at DFARS 252.227-7013 and/or in similar or successor
+ * clauses in the FAR or the DOD or NASA FAR Supplement.
+ * Unpublished-- rights reserved under the copyright laws of the
+ * United States.  Contractor/manufacturer is Silicon Graphics,
+ * Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
+ *
+ * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
+ */
+
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_atlantis
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+
+#include "atlantis.h"
+/* *INDENT-OFF* */
+#if 0
+static float N001[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N002[3] = {0.000077 ,-0.020611 ,0.999788};
+static float N003[3] = {0.961425 ,0.258729 ,-0.093390};
+static float N004[3] = {0.510811 ,-0.769633 ,-0.383063};
+static float N005[3] = {0.400123 ,0.855734 ,-0.328055};
+static float N006[3] = {-0.770715 ,0.610204 ,-0.183440};
+static float N007[3] = {-0.915597 ,-0.373345 ,-0.149316};
+static float N008[3] = {-0.972788 ,0.208921 ,-0.100179};
+static float N009[3] = {-0.939713 ,-0.312268 ,-0.139383};
+static float N010[3] = {-0.624138 ,-0.741047 ,-0.247589};
+static float N011[3] = {0.591434 ,-0.768401 ,-0.244471};
+static float N012[3] = {0.935152 ,-0.328495 ,-0.132598};
+static float N013[3] = {0.997102 ,0.074243 ,-0.016593};
+static float N014[3] = {0.969995 ,0.241712 ,-0.026186};
+static float N015[3] = {0.844539 ,0.502628 ,-0.184714};
+static float N016[3] = {-0.906608 ,0.386308 ,-0.169787};
+static float N017[3] = {-0.970016 ,0.241698 ,-0.025516};
+static float N018[3] = {-0.998652 ,0.050493 ,-0.012045};
+static float N019[3] = {-0.942685 ,-0.333051 ,-0.020556};
+static float N020[3] = {-0.660944 ,-0.750276 ,0.015480};
+static float N021[3] = {0.503549 ,-0.862908 ,-0.042749};
+static float N022[3] = {0.953202 ,-0.302092 ,-0.012089};
+static float N023[3] = {0.998738 ,0.023574 ,0.044344};
+static float N024[3] = {0.979297 ,0.193272 ,0.060202};
+static float N025[3] = {0.798300 ,0.464885 ,0.382883};
+static float N026[3] = {-0.756590 ,0.452403 ,0.472126};
+static float N027[3] = {-0.953855 ,0.293003 ,0.065651};
+static float N028[3] = {-0.998033 ,0.040292 ,0.048028};
+static float N029[3] = {-0.977079 ,-0.204288 ,0.059858};
+static float N030[3] = {-0.729117 ,-0.675304 ,0.111140};
+static float N031[3] = {0.598361 ,-0.792753 ,0.116221};
+static float N032[3] = {0.965192 ,-0.252991 ,0.066332};
+static float N033[3] = {0.998201 ,-0.002790 ,0.059892};
+static float N034[3] = {0.978657 ,0.193135 ,0.070207};
+static float N035[3] = {0.718815 ,0.680392 ,0.142733};
+static float N036[3] = {-0.383096 ,0.906212 ,0.178936};
+static float N037[3] = {-0.952831 ,0.292590 ,0.080647};
+static float N038[3] = {-0.997680 ,0.032417 ,0.059861};
+static float N039[3] = {-0.982629 ,-0.169881 ,0.074700};
+static float N040[3] = {-0.695424 ,-0.703466 ,0.146700};
+static float N041[3] = {0.359323 ,-0.915531 ,0.180805};
+static float N042[3] = {0.943356 ,-0.319387 ,0.089842};
+static float N043[3] = {0.998272 ,-0.032435 ,0.048993};
+static float N044[3] = {0.978997 ,0.193205 ,0.065084};
+static float N045[3] = {0.872144 ,0.470094 ,-0.135565};
+static float N046[3] = {-0.664282 ,0.737945 ,-0.119027};
+static float N047[3] = {-0.954508 ,0.288570 ,0.075107};
+static float N048[3] = {-0.998273 ,0.032406 ,0.048993};
+static float N049[3] = {-0.979908 ,-0.193579 ,0.048038};
+static float N050[3] = {-0.858736 ,-0.507202 ,-0.072938};
+static float N051[3] = {0.643545 ,-0.763887 ,-0.048237};
+static float N052[3] = {0.955580 ,-0.288954 ,0.058068};
+#if 0
+static float N053[3] = {0.000000 ,1.000000 ,0.000000};
+static float N054[3] = {0.000000 ,1.000000 ,0.000000};
+static float N055[3] = {0.000000 ,1.000000 ,0.000000};
+static float N056[3] = {0.000000 ,1.000000 ,0.000000};
+static float N057[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N058[3] = {0.000050 ,0.793007 ,-0.609213};
+static float N059[3] = {0.913510 ,0.235418 ,-0.331779};
+static float N060[3] = {-0.807970 ,0.495000 ,-0.319625};
+static float N061[3] = {0.000000 ,0.784687 ,-0.619892};
+static float N062[3] = {0.000000 ,-1.000000 ,0.000000};
+static float N063[3] = {0.000000 ,1.000000 ,0.000000};
+static float N064[3] = {0.000000 ,1.000000 ,0.000000};
+static float N065[3] = {0.000000 ,1.000000 ,0.000000};
+static float N066[3] = {-0.055784 ,0.257059 ,0.964784};
+#if 0
+static float N067[3] = {0.000000 ,1.000000 ,0.000000};
+static float N068[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N069[3] = {-0.000505 ,-0.929775 ,-0.368127};
+static float N070[3] = {0.000000 ,1.000000 ,0.000000};
+#if 0
+static float N071[3] = {-0.987102 ,0.131723 ,-0.090984};
+static float N072[3] = {-0.987102 ,0.131723 ,-0.090984};
+static float N073[3] = {-0.987102 ,0.131723 ,-0.090984};
+static float N074[3] = {0.000000 ,1.000000 ,0.000000};
+static float N075[3] = {0.000000 ,1.000000 ,0.000000};
+static float N076[3] = {0.000000 ,1.000000 ,0.000000};
+static float N077[3] = {0.995210 ,0.071962 ,-0.066168};
+static float N078[3] = {0.995210 ,0.071962 ,-0.066168};
+static float N079[3] = {0.995210 ,0.071962 ,-0.066168};
+static float N080[3] = {0.000000 ,1.000000 ,0.000000};
+static float N081[3] = {0.000000 ,1.000000 ,0.000000};
+static float N082[3] = {0.000000 ,1.000000 ,0.000000};
+static float P001[3] = {0.00, 0.00, 0.00};
+#endif
+static float P002[3] = {0.00, -36.59, 5687.72};
+static float P003[3] = {90.00, 114.73, 724.38};
+static float P004[3] = {58.24, -146.84, 262.35};
+static float P005[3] = {27.81, 231.52, 510.43};
+static float P006[3] = {-27.81, 230.43, 509.76};
+static float P007[3] = {-46.09, -146.83, 265.84};
+static float P008[3] = {-90.00, 103.84, 718.53};
+static float P009[3] = {-131.10, -165.92, 834.85};
+static float P010[3] = {-27.81, -285.31, 500.00};
+static float P011[3] = {27.81, -285.32, 500.00};
+static float P012[3] = {147.96, -170.89, 845.50};
+static float P013[3] = {180.00, 0.00, 2000.00};
+static float P014[3] = {145.62, 352.67, 2000.00};
+static float P015[3] = {55.62, 570.63, 2000.00};
+static float P016[3] = {-55.62, 570.64, 2000.00};
+static float P017[3] = {-145.62, 352.68, 2000.00};
+static float P018[3] = {-180.00, 0.01, 2000.00};
+static float P019[3] = {-178.20, -352.66, 2001.61};
+static float P020[3] = {-55.63, -570.63, 2000.00};
+static float P021[3] = {55.62, -570.64, 2000.00};
+static float P022[3] = {179.91, -352.69, 1998.39};
+static float P023[3] = {150.00, 0.00, 3000.00};
+static float P024[3] = {121.35, 293.89, 3000.00};
+static float P025[3] = {46.35, 502.93, 2883.09};
+static float P026[3] = {-46.35, 497.45, 2877.24};
+static float P027[3] = {-121.35, 293.90, 3000.00};
+static float P028[3] = {-150.00, 0.00, 3000.00};
+static float P029[3] = {-152.21, -304.84, 2858.68};
+static float P030[3] = {-46.36, -475.52, 3000.00};
+static float P031[3] = {46.35, -475.53, 3000.00};
+static float P032[3] = {155.64, -304.87, 2863.50};
+static float P033[3] = {90.00, 0.00, 4000.00};
+static float P034[3] = {72.81, 176.33, 4000.00};
+static float P035[3] = {27.81, 285.32, 4000.00};
+static float P036[3] = {-27.81, 285.32, 4000.00};
+static float P037[3] = {-72.81, 176.34, 4000.00};
+static float P038[3] = {-90.00, 0.00, 4000.00};
+static float P039[3] = {-72.81, -176.33, 4000.00};
+static float P040[3] = {-27.81, -285.31, 4000.00};
+static float P041[3] = {27.81, -285.32, 4000.00};
+static float P042[3] = {72.81, -176.34, 4000.00};
+static float P043[3] = {30.00, 0.00, 5000.00};
+static float P044[3] = {24.27, 58.78, 5000.00};
+static float P045[3] = {9.27, 95.11, 5000.00};
+static float P046[3] = {-9.27, 95.11, 5000.00};
+static float P047[3] = {-24.27, 58.78, 5000.00};
+static float P048[3] = {-30.00, 0.00, 5000.00};
+static float P049[3] = {-24.27, -58.78, 5000.00};
+static float P050[3] = {-9.27, -95.10, 5000.00};
+static float P051[3] = {9.27, -95.11, 5000.00};
+static float P052[3] = {24.27, -58.78, 5000.00};
+#if 0
+static float P053[3] = {0.00, 0.00, 0.00};
+static float P054[3] = {0.00, 0.00, 0.00};
+static float P055[3] = {0.00, 0.00, 0.00};
+static float P056[3] = {0.00, 0.00, 0.00};
+static float P057[3] = {0.00, 0.00, 0.00};
+#endif
+static float P058[3] = {0.00, 1212.72, 2703.08};
+static float P059[3] = {50.36, 0.00, 108.14};
+static float P060[3] = {-22.18, 0.00, 108.14};
+static float P061[3] = {0.00, 1181.61, 6344.65};
+static float P062[3] = {516.45, -887.08, 2535.45};
+static float P063[3] = {-545.69, -879.31, 2555.63};
+static float P064[3] = {618.89, -1005.64, 2988.32};
+static float P065[3] = {-635.37, -1014.79, 2938.68};
+static float P066[3] = {0.00, 1374.43, 3064.18};
+#if 0
+static float P067[3] = {158.49, -11.89, 1401.56};
+static float P068[3] = {-132.08, -17.90, 1394.31};
+#endif
+static float P069[3] = {0.00, -418.25, 5765.04};
+static float P070[3] = {0.00, 1266.91, 6629.60};
+static float P071[3] = {-139.12, -124.96, 997.98};
+static float P072[3] = {-139.24, -110.18, 1020.68};
+static float P073[3] = {-137.33, -94.52, 1022.63};
+static float P074[3] = {-137.03, -79.91, 996.89};
+static float P075[3] = {-135.21, -91.48, 969.14};
+static float P076[3] = {-135.39, -110.87, 968.76};
+static float P077[3] = {150.23, -78.44, 995.53};
+static float P078[3] = {152.79, -92.76, 1018.46};
+static float P079[3] = {154.19, -110.20, 1020.55};
+static float P080[3] = {151.33, -124.15, 993.77};
+static float P081[3] = {150.49, -111.19, 969.86};
+static float P082[3] = {150.79, -92.41, 969.70};
+static float iP002[3] = {0.00, -36.59, 5687.72};
+static float iP004[3] = {58.24, -146.84, 262.35};
+static float iP007[3] = {-46.09, -146.83, 265.84};
+static float iP010[3] = {-27.81, -285.31, 500.00};
+static float iP011[3] = {27.81, -285.32, 500.00};
+static float iP023[3] = {150.00, 0.00, 3000.00};
+static float iP024[3] = {121.35, 293.89, 3000.00};
+static float iP025[3] = {46.35, 502.93, 2883.09};
+static float iP026[3] = {-46.35, 497.45, 2877.24};
+static float iP027[3] = {-121.35, 293.90, 3000.00};
+static float iP028[3] = {-150.00, 0.00, 3000.00};
+static float iP029[3] = {-121.35, -304.84, 2853.86};
+static float iP030[3] = {-46.36, -475.52, 3000.00};
+static float iP031[3] = {46.35, -475.53, 3000.00};
+static float iP032[3] = {121.35, -304.87, 2853.86};
+static float iP033[3] = {90.00, 0.00, 4000.00};
+static float iP034[3] = {72.81, 176.33, 4000.00};
+static float iP035[3] = {27.81, 285.32, 4000.00};
+static float iP036[3] = {-27.81, 285.32, 4000.00};
+static float iP037[3] = {-72.81, 176.34, 4000.00};
+static float iP038[3] = {-90.00, 0.00, 4000.00};
+static float iP039[3] = {-72.81, -176.33, 4000.00};
+static float iP040[3] = {-27.81, -285.31, 4000.00};
+static float iP041[3] = {27.81, -285.32, 4000.00};
+static float iP042[3] = {72.81, -176.34, 4000.00};
+static float iP043[3] = {30.00, 0.00, 5000.00};
+static float iP044[3] = {24.27, 58.78, 5000.00};
+static float iP045[3] = {9.27, 95.11, 5000.00};
+static float iP046[3] = {-9.27, 95.11, 5000.00};
+static float iP047[3] = {-24.27, 58.78, 5000.00};
+static float iP048[3] = {-30.00, 0.00, 5000.00};
+static float iP049[3] = {-24.27, -58.78, 5000.00};
+static float iP050[3] = {-9.27, -95.10, 5000.00};
+static float iP051[3] = {9.27, -95.11, 5000.00};
+static float iP052[3] = {24.27, -58.78, 5000.00};
+#if 0
+static float iP053[3] = {0.00, 0.00, 0.00};
+#endif
+static float iP061[3] = {0.00, 1181.61, 6344.65};
+static float iP069[3] = {0.00, -418.25, 5765.04};
+static float iP070[3] = {0.00, 1266.91, 6629.60};
+/* *INDENT-ON* */
+
+
+
+static void
+Fish001(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N007);
+       glVertex3fv(P007);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N004);
+       glVertex3fv(P004);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glNormal3fv(N007);
+       glVertex3fv(P007);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N004);
+       glVertex3fv(P004);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P071);
+       glVertex3fv(P072);
+       glVertex3fv(P073);
+       glVertex3fv(P074);
+       glVertex3fv(P075);
+       glVertex3fv(P076);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P077);
+       glVertex3fv(P078);
+       glVertex3fv(P079);
+       glVertex3fv(P080);
+       glVertex3fv(P081);
+       glVertex3fv(P082);
+       glEnd();
+}
+
+static void
+Fish002(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+}
+
+static void
+Fish003(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glEnd();
+}
+
+static void
+Fish004(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glNormal3fv(N061);
+       glVertex3fv(P061);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N061);
+       glVertex3fv(P061);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N061);
+       glVertex3fv(P061);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N061);
+       glVertex3fv(P061);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glNormal3fv(N061);
+       glVertex3fv(P061);
+       glEnd();
+}
+
+static void
+Fish005(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+}
+
+static void
+Fish006(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glEnd();
+}
+
+static void
+Fish007(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N064);
+       glVertex3fv(P064);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+}
+
+static void
+Fish008(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+}
+
+static void
+Fish009(GLenum cap)
+{
+       glBegin(cap);
+       glVertex3fv(P059);
+       glVertex3fv(P012);
+       glVertex3fv(P009);
+       glVertex3fv(P060);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P012);
+       glVertex3fv(P004);
+       glVertex3fv(P007);
+       glVertex3fv(P009);
+       glEnd();
+}
+
+static void
+Fish_1(GLenum cap)
+{
+       Fish004(cap);
+       Fish005(cap);
+       Fish003(cap);
+       Fish007(cap);
+       Fish006(cap);
+       Fish002(cap);
+       Fish008(cap);
+       Fish009(cap);
+       Fish001(cap);
+}
+
+static void
+Fish_2(GLenum cap)
+{
+       Fish005(cap);
+       Fish004(cap);
+       Fish003(cap);
+       Fish008(cap);
+       Fish006(cap);
+       Fish002(cap);
+       Fish007(cap);
+       Fish009(cap);
+       Fish001(cap);
+}
+
+static void
+Fish_3(GLenum cap)
+{
+       Fish005(cap);
+       Fish004(cap);
+       Fish007(cap);
+       Fish003(cap);
+       Fish002(cap);
+       Fish008(cap);
+       Fish009(cap);
+       Fish001(cap);
+       Fish006(cap);
+}
+
+static void
+Fish_4(GLenum cap)
+{
+       Fish005(cap);
+       Fish004(cap);
+       Fish008(cap);
+       Fish003(cap);
+       Fish002(cap);
+       Fish007(cap);
+       Fish009(cap);
+       Fish001(cap);
+       Fish006(cap);
+}
+
+static void
+Fish_5(GLenum cap)
+{
+       Fish009(cap);
+       Fish006(cap);
+       Fish007(cap);
+       Fish001(cap);
+       Fish002(cap);
+       Fish003(cap);
+       Fish008(cap);
+       Fish004(cap);
+       Fish005(cap);
+}
+
+static void
+Fish_6(GLenum cap)
+{
+       Fish009(cap);
+       Fish006(cap);
+       Fish008(cap);
+       Fish001(cap);
+       Fish002(cap);
+       Fish007(cap);
+       Fish003(cap);
+       Fish004(cap);
+       Fish005(cap);
+}
+
+static void
+Fish_7(GLenum cap)
+{
+       Fish009(cap);
+       Fish001(cap);
+       Fish007(cap);
+       Fish005(cap);
+       Fish002(cap);
+       Fish008(cap);
+       Fish003(cap);
+       Fish004(cap);
+       Fish006(cap);
+}
+
+static void
+Fish_8(GLenum cap)
+{
+       Fish009(cap);
+       Fish008(cap);
+       Fish001(cap);
+       Fish002(cap);
+       Fish007(cap);
+       Fish003(cap);
+       Fish005(cap);
+       Fish004(cap);
+       Fish006(cap);
+}
+
+void
+DrawShark(fishRec * fish, int wire)
+{
+       float       mat[4][4];
+       int         n;
+       float       seg1, seg2, seg3, seg4, segup;
+       float       thrash, chomp;
+       GLenum      cap;
+
+       fish->htail = (int) (fish->htail - (int) (5.0 * fish->v)) % 360;
+
+       thrash = 50.0 * fish->v;
+
+       seg1 = 0.6 * thrash * sin(fish->htail * RRAD);
+       seg2 = 1.8 * thrash * sin((fish->htail + 45.0) * RRAD);
+       seg3 = 3.0 * thrash * sin((fish->htail + 90.0) * RRAD);
+       seg4 = 4.0 * thrash * sin((fish->htail + 110.0) * RRAD);
+
+       chomp = 0.0;
+       if (fish->v > 2.0) {
+               chomp = -(fish->v - 2.0) * 200.0;
+       }
+       P004[1] = iP004[1] + chomp;
+       P007[1] = iP007[1] + chomp;
+       P010[1] = iP010[1] + chomp;
+       P011[1] = iP011[1] + chomp;
+
+       P023[0] = iP023[0] + seg1;
+       P024[0] = iP024[0] + seg1;
+       P025[0] = iP025[0] + seg1;
+       P026[0] = iP026[0] + seg1;
+       P027[0] = iP027[0] + seg1;
+       P028[0] = iP028[0] + seg1;
+       P029[0] = iP029[0] + seg1;
+       P030[0] = iP030[0] + seg1;
+       P031[0] = iP031[0] + seg1;
+       P032[0] = iP032[0] + seg1;
+       P033[0] = iP033[0] + seg2;
+       P034[0] = iP034[0] + seg2;
+       P035[0] = iP035[0] + seg2;
+       P036[0] = iP036[0] + seg2;
+       P037[0] = iP037[0] + seg2;
+       P038[0] = iP038[0] + seg2;
+       P039[0] = iP039[0] + seg2;
+       P040[0] = iP040[0] + seg2;
+       P041[0] = iP041[0] + seg2;
+       P042[0] = iP042[0] + seg2;
+       P043[0] = iP043[0] + seg3;
+       P044[0] = iP044[0] + seg3;
+       P045[0] = iP045[0] + seg3;
+       P046[0] = iP046[0] + seg3;
+       P047[0] = iP047[0] + seg3;
+       P048[0] = iP048[0] + seg3;
+       P049[0] = iP049[0] + seg3;
+       P050[0] = iP050[0] + seg3;
+       P051[0] = iP051[0] + seg3;
+       P052[0] = iP052[0] + seg3;
+       P002[0] = iP002[0] + seg4;
+       P061[0] = iP061[0] + seg4;
+       P069[0] = iP069[0] + seg4;
+       P070[0] = iP070[0] + seg4;
+
+       fish->vtail += ((fish->dtheta - fish->vtail) * 0.1);
+
+       if (fish->vtail > 0.5) {
+               fish->vtail = 0.5;
+       } else if (fish->vtail < -0.5) {
+               fish->vtail = -0.5;
+       }
+       segup = thrash * fish->vtail;
+
+       P023[1] = iP023[1] + segup;
+       P024[1] = iP024[1] + segup;
+       P025[1] = iP025[1] + segup;
+       P026[1] = iP026[1] + segup;
+       P027[1] = iP027[1] + segup;
+       P028[1] = iP028[1] + segup;
+       P029[1] = iP029[1] + segup;
+       P030[1] = iP030[1] + segup;
+       P031[1] = iP031[1] + segup;
+       P032[1] = iP032[1] + segup;
+       P033[1] = iP033[1] + segup * 5.0;
+       P034[1] = iP034[1] + segup * 5.0;
+       P035[1] = iP035[1] + segup * 5.0;
+       P036[1] = iP036[1] + segup * 5.0;
+       P037[1] = iP037[1] + segup * 5.0;
+       P038[1] = iP038[1] + segup * 5.0;
+       P039[1] = iP039[1] + segup * 5.0;
+       P040[1] = iP040[1] + segup * 5.0;
+       P041[1] = iP041[1] + segup * 5.0;
+       P042[1] = iP042[1] + segup * 5.0;
+       P043[1] = iP043[1] + segup * 12.0;
+       P044[1] = iP044[1] + segup * 12.0;
+       P045[1] = iP045[1] + segup * 12.0;
+       P046[1] = iP046[1] + segup * 12.0;
+       P047[1] = iP047[1] + segup * 12.0;
+       P048[1] = iP048[1] + segup * 12.0;
+       P049[1] = iP049[1] + segup * 12.0;
+       P050[1] = iP050[1] + segup * 12.0;
+       P051[1] = iP051[1] + segup * 12.0;
+       P052[1] = iP052[1] + segup * 12.0;
+       P002[1] = iP002[1] + segup * 17.0;
+       P061[1] = iP061[1] + segup * 17.0;
+       P069[1] = iP069[1] + segup * 17.0;
+       P070[1] = iP070[1] + segup * 17.0;
+
+       glPushMatrix();
+
+       glTranslatef(0.0, 0.0, -3000.0);
+
+       glGetFloatv(GL_MODELVIEW_MATRIX, &mat[0][0]);
+       n = 0;
+       if (mat[0][2] >= 0.0) {
+               n += 1;
+       }
+       if (mat[1][2] >= 0.0) {
+               n += 2;
+       }
+       if (mat[2][2] >= 0.0) {
+               n += 4;
+       }
+       glScalef(2.0, 1.0, 1.0);
+
+       glEnable(GL_CULL_FACE);
+       cap = wire ? GL_LINE_LOOP : GL_POLYGON;
+       switch (n) {
+               case 0:
+                       Fish_1(cap);
+                       break;
+               case 1:
+                       Fish_2(cap);
+                       break;
+               case 2:
+                       Fish_3(cap);
+                       break;
+               case 3:
+                       Fish_4(cap);
+                       break;
+               case 4:
+                       Fish_5(cap);
+                       break;
+               case 5:
+                       Fish_6(cap);
+                       break;
+               case 6:
+                       Fish_7(cap);
+                       break;
+               case 7:
+                       Fish_8(cap);
+                       break;
+       }
+       glDisable(GL_CULL_FACE);
+
+       glPopMatrix();
+}
+#endif
diff --git a/xlockmore-4.14/modes/glx/sproingies.c b/xlockmore-4.14/modes/glx/sproingies.c
new file mode 100644 (file)
index 0000000..8c328a5
--- /dev/null
@@ -0,0 +1,827 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* sproingies.c - 3D sproingies */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)sproingies.c 4.04 97/07/28 xlockmore";
+
+#endif
+
+/*-
+ *  sproingies.c - Copyright 1996 by Ed Mackey, freely distributable.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 07-Dec-96: Written.
+ */
+
+#ifdef STANDALONE
+#include "xlockmoreI.h"                /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_sproingies
+
+#include <GL/gl.h>
+#include <GL/glu.h>
+#include "buildlwo.h"
+
+#define MAXSPROING 100
+#define T_COUNT 40
+#define BOOM_FRAME 50
+
+struct sPosColor {
+       int         x, y, z, frame, life;
+       GLfloat     r, g, b;
+};
+
+typedef struct {
+       int         rotx, roty, dist, wireframe, flatshade, groundlevel,
+                   maxsproingies, mono;
+       int         sframe, target_rx, target_ry, target_dist, target_count;
+       GLuint      sproingies[6], TopsSides, SproingieBoom;
+       struct sPosColor *positions;
+} sp_instance;
+
+static sp_instance *si_list = NULL;
+static int  active_screens = 0;
+
+void        SproingieSwap(void);
+
+extern struct lwo LWO_s1_1, LWO_s1_2, LWO_s1_3, LWO_s1_4;
+extern struct lwo LWO_s1_5, LWO_s1_6, LWO_s1_b;
+
+static int
+myrand(int range)
+{
+       return ((int) (((float) range) * LRAND() / (MAXRAND)));
+}
+
+static      GLuint
+build_TopsSides(int wireframe)
+{
+       GLuint      dl_num;
+       GLfloat     mat_color[4] =
+       {0.0, 0.0, 0.0, 1.0};
+
+       dl_num = glGenLists(2);
+       if (!dl_num)
+               return (0);     /* 0 means out of display lists. */
+
+       /* Surface: Tops */
+       glNewList(dl_num, GL_COMPILE);
+       mat_color[0] = 0.392157;
+       mat_color[1] = 0.784314;
+       mat_color[2] = 0.941176;
+       if (wireframe)
+               glColor3fv(mat_color);
+       else {
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, mat_color);
+       }
+       glEndList();
+
+       /* Surface: Sides */
+       glNewList(dl_num + 1, GL_COMPILE);
+       mat_color[0] = 0.156863;
+       mat_color[1] = 0.156863;
+       mat_color[2] = 0.392157;
+       if (wireframe)
+               glColor3fv(mat_color);
+       else {
+               glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, mat_color);
+       }
+       glEndList();
+       return (dl_num);
+}
+
+static void
+LayGround(int sx, int sy, int sz, int width, int height, sp_instance * si)
+{
+       int         x, y, z, w, h;
+       GLenum      begin_polygon;
+
+       if (si->wireframe)
+               begin_polygon = GL_LINE_LOOP;
+       else
+               begin_polygon = GL_POLYGON;
+
+       if (!si->wireframe) {
+               if (!si->mono)
+                       glCallList(si->TopsSides);      /* Render the tops */
+               glNormal3f(0.0, 1.0, 0.0);
+
+               for (h = 0; h < height; ++h) {
+                       x = sx + h;
+                       y = sy - (h << 1);
+                       z = sz + h;
+                       for (w = 0; w < width; ++w) {
+                               glBegin(begin_polygon);
+                               glVertex3i(x, y, z);
+                               glVertex3i(x, y, z - 1);
+                               glVertex3i(x + 1, y, z - 1);
+                               glVertex3i(x + 1, y, z);
+                               glEnd();
+                               glBegin(begin_polygon);
+                               glVertex3i(x + 1, y - 1, z);
+                               glVertex3i(x + 1, y - 1, z - 1);
+                               glVertex3i(x + 2, y - 1, z - 1);
+                               glVertex3i(x + 2, y - 1, z);
+                               glEnd();
+                               ++x;
+                               --z;
+                       }
+               }
+       }
+       if (!si->mono)
+               glCallList(si->TopsSides + 1);  /* Render the sides */
+       if (!si->wireframe)
+               glNormal3f(0.0, 0.0, 1.0);
+
+       for (h = 0; h < height; ++h) {
+               x = sx + h;
+               y = sy - (h << 1);
+               z = sz + h;
+               for (w = 0; w < width; ++w) {
+                       glBegin(begin_polygon);
+                       glVertex3i(x, y, z);
+                       glVertex3i(x + 1, y, z);
+                       glVertex3i(x + 1, y - 1, z);
+                       glVertex3i(x, y - 1, z);
+                       glEnd();
+                       glBegin(begin_polygon);
+                       glVertex3i(x + 1, y - 1, z);
+                       glVertex3i(x + 2, y - 1, z);
+                       glVertex3i(x + 2, y - 2, z);
+                       glVertex3i(x + 1, y - 2, z);
+/*-
+ * PURIFY 4.0.1 reports an unitialized memory read on the next line when using
+ * MesaGL 2.2 and -mono.  This has been fixed in MesaGL 2.3 and later. */
+                       glEnd();
+                       ++x;
+                       --z;
+               }
+       }
+
+       /* Render the other sides */
+       if (!si->wireframe)
+               glNormal3f(1.0, 0.0, 0.0);
+
+       for (h = 0; h < height; ++h) {
+               x = sx + h;
+               y = sy - (h << 1);
+               z = sz + h;
+               for (w = 0; w < width; ++w) {
+                       glBegin(begin_polygon);
+                       glVertex3i(x + 1, y, z);
+                       glVertex3i(x + 1, y, z - 1);
+                       glVertex3i(x + 1, y - 1, z - 1);
+                       glVertex3i(x + 1, y - 1, z);
+                       glEnd();
+                       glBegin(begin_polygon);
+                       glVertex3i(x + 2, y - 1, z);
+                       glVertex3i(x + 2, y - 1, z - 1);
+                       glVertex3i(x + 2, y - 2, z - 1);
+                       glVertex3i(x + 2, y - 2, z);
+                       glEnd();
+                       ++x;
+                       --z;
+               }
+       }
+
+       if (si->wireframe) {
+               if (!si->mono)
+                       glCallList(si->TopsSides);      /* Render the tops */
+
+               for (h = 0; h < height; ++h) {
+                       x = sx + h;
+                       y = sy - (h << 1);
+                       z = sz + h;
+                       for (w = 0; w < width; ++w) {
+                               glBegin(begin_polygon);
+                               glVertex3i(x, y, z);
+                               glVertex3i(x, y, z - 1);
+                               glVertex3i(x + 1, y, z - 1);
+                               glVertex3i(x + 1, y, z);
+                               glEnd();
+                               glBegin(begin_polygon);
+                               glVertex3i(x + 1, y - 1, z);
+                               glVertex3i(x + 1, y - 1, z - 1);
+                               glVertex3i(x + 2, y - 1, z - 1);
+                               glVertex3i(x + 2, y - 1, z);
+                               glEnd();
+                               ++x;
+                               --z;
+                       }
+               }
+       }
+}
+
+#define RESET_SPROINGIE (-30 + myrand(28))
+
+static void
+AdvanceSproingie(int t, sp_instance * si)
+{
+       int         g_higher, g_back, t2;
+       struct sPosColor *thisSproingie = &(si->positions[t]);
+       struct sPosColor *S2 = &(si->positions[0]);
+
+       if (thisSproingie->life > 0) {
+               if ((++(thisSproingie->frame)) > 11) {
+                       if (thisSproingie->frame >= BOOM_FRAME) {
+                               if ((thisSproingie->r -= 0.08) < 0.0)
+                                       thisSproingie->r = 0.0;
+                               if ((thisSproingie->g -= 0.08) < 0.0)
+                                       thisSproingie->g = 0.0;
+                               if ((thisSproingie->b -= 0.08) < 0.0)
+                                       thisSproingie->b = 0.0;
+                               if ((--(thisSproingie->life)) < 1) {
+                                       thisSproingie->life = RESET_SPROINGIE;
+                               }
+                               return;
+                       }
+                       thisSproingie->x += 1;
+                       thisSproingie->y -= 2;
+                       thisSproingie->z += 1;
+                       thisSproingie->frame = 0;
+
+                       for (t2 = 0; t2 < si->maxsproingies; ++t2) {
+                               if ((t2 != t) && (thisSproingie->x == S2->x) &&
+                                   (thisSproingie->y == S2->y) && (thisSproingie->z == S2->z) &&
+                                   (S2->life > 10) && (S2->frame < 6)) {
+#if 0
+                                       if (thisSproingie->life > S2->life) {
+                                               S2->life = 10;
+                                       } else {
+#endif
+                                               if (thisSproingie->life > 10) {
+                                                       thisSproingie->life = 10;
+                                                       thisSproingie->frame = BOOM_FRAME;
+                                                       if ((thisSproingie->r += 0.5) > 1.0)
+                                                               thisSproingie->r = 1.0;
+                                                       if ((thisSproingie->g += 0.5) > 1.0)
+                                                               thisSproingie->g = 1.0;
+                                                       if ((thisSproingie->b += 0.5) > 1.0)
+                                                               thisSproingie->b = 1.0;
+                                               }
+#if 0
+                                       }
+#endif
+                               }
+                               ++S2;
+                       }
+               }
+               if (!((thisSproingie->life == 10) &&
+                     (thisSproingie->frame > 0) &&
+                     (thisSproingie->frame < BOOM_FRAME))) {
+                       if ((--(thisSproingie->life)) < 1) {
+                               thisSproingie->life = RESET_SPROINGIE;
+                       } else if (thisSproingie->life < 9) {
+                               thisSproingie->frame -= 2;
+                       }
+               }               /* else wait here for frame 0 to come about. */
+       } else if (++(thisSproingie->life) >= 0) {
+               if (t > 1) {
+                       g_higher = -3 + myrand(5);
+                       g_back = -2 + myrand(5);
+               } else if (t == 1) {
+                       g_higher = -2 + myrand(3);
+                       g_back = -1 + myrand(3);
+               } else {
+                       g_higher = -1;
+                       g_back = 0;
+               }
+
+               thisSproingie->x = (-g_higher - g_back);
+               thisSproingie->y = (g_higher << 1);
+               thisSproingie->z = (g_back - g_higher);
+               thisSproingie->life = 40 + myrand(200);
+               thisSproingie->frame = -10;
+               thisSproingie->r = (GLfloat) (40 + myrand(200)) / 255.0;
+               thisSproingie->g = (GLfloat) (40 + myrand(200)) / 255.0;
+               thisSproingie->b = (GLfloat) (40 + myrand(200)) / 255.0;
+
+               for (t2 = 0; t2 < si->maxsproingies; ++t2) {
+                       if ((t2 != t) && (thisSproingie->x == S2->x) &&
+                           (thisSproingie->y == S2->y) && (thisSproingie->z == S2->z) &&
+                           (S2->life > 10) && (S2->frame < 0)) {
+                               /* If one is already being born, just wait. */
+                               thisSproingie->life = -1;
+                       }
+                       ++S2;
+               }
+       }
+}
+
+static void
+NextSproingie(int screen)
+{
+       sp_instance *si = &si_list[screen];
+       int         ddx, t;
+       struct sPosColor *thisSproingie = &(si->positions[0]);
+
+       if (++si->sframe > 11) {
+               si->sframe = 0;
+               for (t = 0; t < si->maxsproingies; ++t) {
+                       thisSproingie->x -= 1;
+                       thisSproingie->y += 2;
+                       thisSproingie->z -= 1;
+                       ++thisSproingie;
+               }
+       }
+       for (t = 0; t < si->maxsproingies; ++t) {
+               AdvanceSproingie(t, si);
+       }
+
+       if (si->target_count < 0) {     /* track to current target */
+               if (si->target_rx < si->rotx)
+                       --si->rotx;
+               else if (si->target_rx > si->rotx)
+                       ++si->rotx;
+
+               if (si->target_ry < si->roty)
+                       --si->roty;
+               else if (si->target_ry > si->roty)
+                       ++si->roty;
+
+               ddx = (si->target_dist - si->dist) / 8;
+               if (ddx)
+                       si->dist += ddx;
+               else if (si->target_dist < si->dist)
+                       --si->dist;
+               else if (si->target_dist > si->dist)
+                       ++si->dist;
+
+               if ((si->target_rx == si->rotx) && (si->target_ry == si->roty) &&
+                   (si->target_dist == si->dist)) {
+                       si->target_count = T_COUNT;
+                       if (si->target_dist <= 32)
+                               si->target_count >>= 2;
+               }
+       } else if (--si->target_count < 0) {    /* make up new target */
+               si->target_rx = myrand(100) - 35;
+               si->target_ry = -myrand(90);
+               si->target_dist = 32 << myrand(2);      /* could be 32, 64, or 128, (previously or 256) */
+
+               if (si->target_dist >= si->dist)        /* no duplicate distances */
+                       si->target_dist <<= 1;
+       }
+       /* Otherwise just hang loose for a while here */
+}
+
+#ifdef __AUXFUNCS__
+void
+PrintEm(void)
+{
+       int         t, count = 0;
+
+       for (t = 0; t < maxsproingies; ++t) {
+               if (positions[t].life > 0)
+                       ++count;
+       }
+       (void) printf("RotX: %d, RotY: %d, Dist: %d.  Targets: X %d, Y %d, D %d.  Visible: %d\n",
+                rotx, roty, dist, target_rx, target_ry, target_dist, count);
+}
+
+void
+ResetEm(void)
+{
+       int         t;
+
+       for (t = 0; t < maxsproingies; ++t) {
+               positions[t].x = 0;
+               positions[t].y = 0;
+               positions[t].z = 0;
+               positions[t].life = -2;
+               positions[t].frame = 0;
+       }
+}
+
+void
+distAdd(void)
+{
+       if (dist < (1 << 16 << 4))
+               dist <<= 1;
+}
+
+void
+distSubtract(void)
+{
+       if (dist > 1)
+               dist >>= 1;
+}
+
+void
+rotxAdd(void)
+{
+       rotx = (rotx + 5) % 360;
+}
+
+void
+rotxSubtract(void)
+{
+       rotx = (rotx - 5) % 360;
+}
+
+void
+rotyAdd(void)
+{
+       roty = (roty + 5) % 360;
+}
+
+void
+rotySubtract(void)
+{
+       roty = (roty - 5) % 360;
+}
+
+void
+rotxBAdd(void)
+{
+       rotx = (rotx + 45) % 360;
+}
+
+void
+rotxBSubtract(void)
+{
+       rotx = (rotx - 45) % 360;
+}
+
+void
+rotyBAdd(void)
+{
+       roty = (roty + 45) % 360;
+}
+
+void
+rotyBSubtract(void)
+{
+       roty = (roty - 45) % 360;
+}
+
+#endif
+
+static void
+RenderSproingie(int t, sp_instance * si)
+{
+       GLfloat     scale, pointsize, mat_color[4] =
+       {0.0, 0.0, 0.0, 1.0};
+       GLdouble    clipplane[4] =
+       {0.0, 1.0, 0.0, 0.0};
+       struct sPosColor *thisSproingie = &(si->positions[t]);
+
+       if (thisSproingie->life < 1)
+               return;
+
+       glPushMatrix();
+
+       if (!si->mono) {
+               mat_color[0] = thisSproingie->r;
+               mat_color[1] = thisSproingie->g;
+               mat_color[2] = thisSproingie->b;
+               if (si->wireframe)
+                       glColor3fv(mat_color);
+               else {
+                       glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, mat_color);
+               }
+       }
+       if (thisSproingie->frame < 0) {
+               glEnable(GL_CLIP_PLANE0);
+               glTranslatef((GLfloat) (thisSproingie->x),
+                            (GLfloat) (thisSproingie->y) +
+                            ((GLfloat) (thisSproingie->frame) / 9.0),
+                            (GLfloat) (thisSproingie->z));
+               clipplane[3] = ((GLdouble) (thisSproingie->frame) / 9.0) +
+                       (si->wireframe ? 0.0 : 0.1);
+               glClipPlane(GL_CLIP_PLANE0, clipplane);
+               glCallList(si->sproingies[0]);
+               glDisable(GL_CLIP_PLANE0);
+       } else if (thisSproingie->frame >= BOOM_FRAME) {
+               glTranslatef((GLfloat) (thisSproingie->x) + 0.5,
+                            (GLfloat) (thisSproingie->y) + 0.5,
+                            (GLfloat) (thisSproingie->z) - 0.5);
+               scale = (GLfloat) (1 << (thisSproingie->frame - BOOM_FRAME));
+               glScalef(scale, scale, scale);
+               if (!si->wireframe) {
+                       if (!si->mono)
+                               glColor3fv(mat_color);
+                       glDisable(GL_LIGHTING);
+               }
+               pointsize = (GLfloat) ((BOOM_FRAME + 8) - thisSproingie->frame) -
+                       (si->dist / 64.0);
+               glPointSize((pointsize < 1.0) ? 1.0 : pointsize);
+/*-
+ * PURIFY 4.0.1 reports an unitialized memory read on the next line when using
+ * MesaGL 2.2.  This has been tracked to MesaGL 2.2 src/points.c line 313. */
+               glCallList(si->SproingieBoom);
+               glPointSize(1.0);
+               if (!si->wireframe) {
+                       glEnable(GL_LIGHTING);
+               }
+       } else if (thisSproingie->frame > 5) {
+               glTranslatef((GLfloat) (thisSproingie->x + 1),
+                            (GLfloat) (thisSproingie->y - 1), (GLfloat) (thisSproingie->z - 1));
+               glRotatef((GLfloat) - 90.0, 0.0, 1.0, 0.0);
+               glCallList(si->sproingies[thisSproingie->frame - 6]);
+       } else {
+               glTranslatef((GLfloat) (thisSproingie->x), (GLfloat) (thisSproingie->y),
+                            (GLfloat) (thisSproingie->z));
+               glCallList(si->sproingies[thisSproingie->frame]);
+       }
+
+       glPopMatrix();
+
+}
+
+static void
+ComputeGround(sp_instance * si)
+{
+       int         g_higher, g_back, g_width, g_height;
+
+       /* higher: x-1, y+2, z-1 */
+       /* back: x-1, y, z+1 */
+
+       if (si->groundlevel == 0) {
+               g_back = 2;
+               g_width = 5;
+       } else if (si->groundlevel == 1) {
+               g_back = 4;
+               g_width = 8;
+       } else {
+               g_back = 8;
+               g_width = 16;
+       }
+
+       if ((g_higher = si->dist >> 3) < 4)
+               g_higher = 4;
+       if (g_higher > 16)
+               g_higher = 16;
+       g_height = g_higher << 1;
+
+       if (si->rotx < -10)
+               g_higher += (g_higher >> 2);
+       else if (si->rotx > 10)
+               g_higher -= (g_higher >> 2);
+
+#if 0
+       if (si->dist > 128) {
+               ++g_higher;
+               ++g_back;
+               g_back <<= 1;
+       } else if (si->dist > 64) {
+               ++g_higher;
+               ++g_back;
+       } else if (si->dist > 32) {
+               /* nothing special */
+       } else {
+               if (g_higher > 2) {
+                       g_higher = g_back = 4;
+               }
+       }
+#endif
+
+       /* startx, starty, startz, width, height */
+       LayGround((-g_higher - g_back), (g_higher << 1), (g_back - g_higher),
+                 (g_width), (g_height), si);
+}
+
+void
+DisplaySproingies(int screen)
+{
+       sp_instance *si = &si_list[screen];
+       int         t;
+       GLfloat     position[] =
+       {8.0, 5.0, -2.0, 0.1};
+
+       if (si->wireframe)
+               glClear(GL_COLOR_BUFFER_BIT);
+       else
+               glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       glPushMatrix();
+       glTranslatef(0.0, 0.0, -(GLfloat) (si->dist) / 16.0);   /* viewing transform  */
+       glRotatef((GLfloat) si->rotx, 1.0, 0.0, 0.0);
+       glRotatef((GLfloat) si->roty, 0.0, 1.0, 0.0);
+
+       if (!si->wireframe)
+               glLightfv(GL_LIGHT0, GL_POSITION, position);
+
+#if 0                          /* Show light pos */
+       glPushMatrix();
+       glTranslatef(position[0], position[1], position[2]);
+       glColor3f(1.0, 1.0, 1.0);
+       if (!si->wireframe) {
+               glDisable(GL_LIGHTING);
+       }
+       glCallList(si->SproingieBoom);
+       if (!si->wireframe) {
+               glEnable(GL_LIGHTING);
+       }
+       glPopMatrix();
+#endif
+
+       glTranslatef((GLfloat) si->sframe * (-1.0 / 12.0) - 0.75,
+                    (GLfloat) si->sframe * (2.0 / 12.0) - 0.5,
+                    (GLfloat) si->sframe * (-1.0 / 12.0) + 0.75);
+
+       if (si->wireframe)
+               ComputeGround(si);
+
+       for (t = 0; t < si->maxsproingies; ++t) {
+               RenderSproingie(t, si);
+       }
+
+       if (!si->wireframe)
+               ComputeGround(si);
+
+       glPopMatrix();
+       glFlush();
+
+       SproingieSwap();
+}
+
+void
+NextSproingieDisplay(int screen)
+{
+       NextSproingie(screen);
+       DisplaySproingies(screen);
+}
+
+#if 0
+void
+ReshapeSproingies(int w, int h)
+{
+       glViewport(0, 0, w, h);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       gluPerspective(65.0, (GLfloat) w / (GLfloat) h, 0.1, 2000.0);   /* was 200000.0 */
+       glMatrixMode(GL_MODELVIEW);
+       glLoadIdentity();
+}
+
+#endif
+
+void
+CleanupSproingies(int screen)
+{
+       sp_instance *si = &si_list[screen];
+       int         t;
+
+       if (si->SproingieBoom) {
+               for (t = 0; t < 6; ++t)
+                       glDeleteLists(si->sproingies[t], 1);
+
+               glDeleteLists(si->TopsSides, 2);
+               glDeleteLists(si->SproingieBoom, 1);
+
+               --active_screens;
+               si->SproingieBoom = 0;
+       }
+       if (si->positions) {
+               (void) free((void *) (si->positions));
+               si->positions = NULL;
+       }
+       if ((active_screens == 0) && si_list) {
+               (void) free((void *) (si_list));
+               si_list = NULL;
+       }
+}
+
+void
+InitSproingies(int wfmode, int grnd, int mspr, int screen, int numscreens,
+              int mono)
+{
+       GLfloat     ambient[] =
+       {0.2, 0.2, 0.2, 1.0};
+       GLfloat     position[] =
+       {10.0, 1.0, 1.0, 10.0};
+       GLfloat     mat_diffuse[] =
+       {0.6, 0.6, 0.6, 1.0};
+       GLfloat     mat_specular[] =
+       {0.8, 0.8, 0.8, 1.0};
+       GLfloat     mat_shininess[] =
+       {50.0};
+
+       sp_instance *si;
+       int         t;
+
+       if (si_list == NULL) {
+               if ((si_list = (sp_instance *) calloc(numscreens,
+                                             sizeof (sp_instance))) == NULL)
+                       return;
+       }
+       si = &si_list[screen];
+
+       active_screens++;
+       CleanupSproingies(screen);
+
+       if (mspr < 0)
+               mspr = 0;
+       if (mspr >= MAXSPROING)
+               mspr = MAXSPROING - 1;
+
+       si->rotx = 0;
+       si->roty = -45;
+       si->dist = (16 << 2);
+       si->sframe = 0;
+       si->target_count = 0;
+       si->mono = mono;
+
+       si->wireframe = si->flatshade = 0;
+
+       if (wfmode == 2)
+               si->flatshade = 1;
+       else if (wfmode)
+               si->wireframe = 1;
+
+       si->groundlevel = grnd;
+       si->maxsproingies = mspr;
+
+       if (si->maxsproingies) {
+               si->positions = (struct sPosColor *) calloc(si->maxsproingies,
+                                                 sizeof (struct sPosColor));
+
+               if (!(si->positions))
+                       si->maxsproingies = 0;
+       }
+       for (t = 0; t < si->maxsproingies; ++t) {
+               si->positions[t].x = 0;
+               si->positions[t].y = 0;
+               si->positions[t].z = 0;
+               si->positions[t].life = (-t * ((si->maxsproingies > 19) ? 1 : 4)) - 2;
+               si->positions[t].frame = 0;
+       }
+
+#if 0                          /* Test boom */
+       si->positions[0].x = 0;
+       si->positions[0].y = 0;
+       si->positions[0].z = 0;
+       si->positions[0].life = 10;
+       si->positions[0].frame = BOOM_FRAME;
+       si->positions[0].r = 0.656863;
+       si->positions[0].g = 1.0;
+       si->positions[0].b = 0.656863;
+#endif
+
+       if (!(si->TopsSides = build_TopsSides(si->wireframe)))
+               (void) fprintf(stderr, "build_TopsSides\n");
+
+       if (!(si->sproingies[0] = BuildLWO(si->wireframe, &LWO_s1_1)))
+               (void) fprintf(stderr, "BuildLWO - 1\n");
+       if (!(si->sproingies[1] = BuildLWO(si->wireframe, &LWO_s1_2)))
+               (void) fprintf(stderr, "BuildLWO - 2\n");
+       if (!(si->sproingies[2] = BuildLWO(si->wireframe, &LWO_s1_3)))
+               (void) fprintf(stderr, "BuildLWO - 3\n");
+       if (!(si->sproingies[3] = BuildLWO(si->wireframe, &LWO_s1_4)))
+               (void) fprintf(stderr, "BuildLWO - 4\n");
+       if (!(si->sproingies[4] = BuildLWO(si->wireframe, &LWO_s1_5)))
+               (void) fprintf(stderr, "BuildLWO - 5\n");
+       if (!(si->sproingies[5] = BuildLWO(si->wireframe, &LWO_s1_6)))
+               (void) fprintf(stderr, "BuildLWO - 6\n");
+
+       if (!(si->SproingieBoom = BuildLWO(si->wireframe, &LWO_s1_b)))
+               (void) fprintf(stderr, "BuildLWO - b\n");
+
+       if (si->wireframe) {
+               glShadeModel(GL_FLAT);
+               glDisable(GL_LIGHTING);
+       } else {
+               if (si->flatshade) {
+                       glShadeModel(GL_FLAT);
+                       position[0] = 1.0;
+                       position[3] = 0.0;
+               }
+               glEnable(GL_LIGHTING);
+               glEnable(GL_LIGHT0);
+               glDepthFunc(GL_LEQUAL);
+               glEnable(GL_DEPTH_TEST);
+
+               glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+               glLightfv(GL_LIGHT0, GL_POSITION, position);
+
+               glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, mat_diffuse);
+               glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, mat_specular);
+               glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, mat_shininess);
+
+               /* glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_FALSE); */
+               glCullFace(GL_BACK);
+               glEnable(GL_CULL_FACE);
+
+               glFrontFace(GL_CW);
+               /* glEnable(GL_NORMALIZE); */
+       }
+}
+
+#endif
+
+/* End of sproingies.c */
diff --git a/xlockmore-4.14/modes/glx/sproingiewrap.c b/xlockmore-4.14/modes/glx/sproingiewrap.c
new file mode 100644 (file)
index 0000000..2eed4e0
--- /dev/null
@@ -0,0 +1,247 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* sproingiewrap.c - sproingies wrapper */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)sproingiewrap.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * sproingiewrap.c - Copyright 1996 Sproingie Technologies Incorporated.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ *    Programming:  Ed Mackey, http://www.netaxs.com/~emackey/
+ *    Sproingie 3D objects modeled by:  Al Mackey, al@iam.com
+ *       (using MetaNURBS in NewTek's Lightwave 3D v5).
+ *
+ * Revision History:
+ * 26-Apr-97: Added glPointSize() calls around explosions, plus other fixes.
+ * 28-Mar-97: Added size support.
+ * 22-Mar-97: Updated to use glX interface instead of xmesa one.
+ *              Also, support for multiscreens added.
+ * 20-Mar-97: Updated for xlockmore v4.02alpha7 and higher, using
+ *              xlockmore's built-in Mesa/OpenGL support instead of
+ *              my own.  Submitted for inclusion in xlockmore.
+ * 09-Dec-96: Written.
+ */
+
+/*-
+ * The sproingies have six "real" frames, (s1_1 to s1_6) that show a
+ * sproingie jumping off a block, headed down and to the right.  But
+ * the program thinks of sproingies as having twelve "virtual" frames,
+ * with the latter six being copies of the first, only lowered and
+ * rotated by 90 degrees (jumping to the left).  So after going
+ * through 12 frames, a sproingie has gone down two rows but not
+ * moved horizontally. 
+ *
+ * To have the sproingies randomly choose left/right jumps at each
+ * block, the program should go back to thinking of only 6 frames,
+ * and jumping down only one row when it is done.  Then it can pick a
+ * direction for the next row.
+ *
+ * (Falling off the end might not be so bad either.  :) )  
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Sproingies"
+#define HACK_INIT init_sproingies
+#define HACK_DRAW draw_sproingies
+#define sproingies_opts xlockmore_opts
+#define DEFAULTS "*delay: 100 \n" \
+ "*count: 5 \n" \
+ "*cycles: 0 \n" \
+ "*size: 0 \n" \
+ "*wireframe: False \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_sproingies
+
+ModeSpecOpt sproingies_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   sproingies_description =
+{"sproingies", "init_sproingies", "draw_sproingies", "release_sproingies",
+ "refresh_sproingies", "init_sproingies", NULL, &sproingies_opts,
+ 1000, 5, 0, 400, 4, 1.0, "",
+ "Shows Sproingies!  Nontoxic.  Safe for pets and small children", 0, NULL};
+
+#endif
+
+#define MINSIZE 32
+
+#include <GL/glu.h>
+#include <time.h>
+
+void        NextSproingie(int screen);
+void        NextSproingieDisplay(int screen);
+void        DisplaySproingies(int screen);
+
+#if 0
+void        ReshapeSproingies(int w, int h);
+
+#endif
+void        CleanupSproingies(int screen);
+void        InitSproingies(int wfmode, int grnd, int mspr, int screen, int numscreens, int mono);
+
+typedef struct {
+       GLfloat     view_rotx, view_roty, view_rotz;
+       GLint       gear1, gear2, gear3;
+       GLfloat     angle;
+       GLuint      limit;
+       GLuint      count;
+       GLXContext *glx_context;
+       int         mono;
+       Window      window;
+} sproingiesstruct;
+
+static sproingiesstruct *sproingies = NULL;
+
+static Display *swap_display;
+static Window swap_window;
+
+void
+SproingieSwap(void)
+{
+       glFinish();
+       glXSwapBuffers(swap_display, swap_window);
+}
+
+
+void
+init_sproingies(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         screen = MI_SCREEN(mi);
+
+       int         cycles = MI_CYCLES(mi);
+       int         count = MI_COUNT(mi);
+       int         size = MI_SIZE(mi);
+
+       sproingiesstruct *sp;
+       int         wfmode = 0, grnd, mspr, w, h;
+
+       if (sproingies == NULL) {
+               if ((sproingies = (sproingiesstruct *) calloc(MI_NUM_SCREENS(mi),
+                                        sizeof (sproingiesstruct))) == NULL)
+                       return;
+       }
+       sp = &sproingies[screen];
+
+       sp->mono = (MI_IS_MONO(mi) ? 1 : 0);
+       sp->window = window;
+       if ((sp->glx_context = init_GL(mi)) != NULL) {
+
+               if ((cycles & 1) || MI_IS_WIREFRAME(mi))
+                       wfmode = 1;
+               grnd = (cycles >> 1);
+               if (grnd > 2)
+                       grnd = 2;
+
+               mspr = count;
+               if (mspr > 100)
+                       mspr = 100;
+
+               /* wireframe, ground, maxsproingies */
+               InitSproingies(wfmode, grnd, mspr, MI_SCREEN(mi), MI_NUM_SCREENS(mi), sp->mono);
+
+               /* Viewport is specified size if size >= MINSIZE && size < screensize */
+               if (size == 0) {
+                       w = MI_WIDTH(mi);
+                       h = MI_HEIGHT(mi);
+               } else if (size < MINSIZE) {
+                       w = MINSIZE;
+                       h = MINSIZE;
+               } else {
+                       w = (size > MI_WIDTH(mi)) ? MI_WIDTH(mi) : size;
+                       h = (size > MI_HEIGHT(mi)) ? MI_HEIGHT(mi) : size;
+               }
+
+               glViewport((MI_WIDTH(mi) - w) / 2, (MI_HEIGHT(mi) - h) / 2, w, h);
+               glMatrixMode(GL_PROJECTION);
+               glLoadIdentity();
+               gluPerspective(65.0, (GLfloat) w / (GLfloat) h, 0.1, 2000.0);   /* was 200000.0 */
+               glMatrixMode(GL_MODELVIEW);
+               glLoadIdentity();
+
+               swap_display = display;
+               swap_window = window;
+               DisplaySproingies(MI_SCREEN(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+/* ARGSUSED */
+void
+draw_sproingies(ModeInfo * mi)
+{
+       sproingiesstruct *sp = &sproingies[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!sp->glx_context)
+               return;
+
+       glDrawBuffer(GL_BACK);
+       glXMakeCurrent(display, window, *(sp->glx_context));
+
+       swap_display = display;
+       swap_window = window;
+
+       NextSproingieDisplay(MI_SCREEN(mi));    /* It will swap. */
+}
+
+void
+refresh_sproingies(ModeInfo * mi)
+{
+       /* No need to do anything here... The whole screen is updated
+        * every frame anyway.  Otherwise this would be just like
+        * draw_sproingies, above, but replace NextSproingieDisplay(...)
+        * with DisplaySproingies(...).
+        */
+}
+
+void
+release_sproingies(ModeInfo * mi)
+{
+       if (sproingies != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       sproingiesstruct *sp = &sproingies[screen];
+
+                       if (sp->glx_context) {
+
+                               glXMakeCurrent(MI_DISPLAY(mi), sp->window, *(sp->glx_context));
+                               CleanupSproingies(MI_SCREEN(mi));
+                       }
+               }
+
+               (void) free((void *) sproingies);
+               sproingies = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+#endif
+
+/* End of sproingiewrap.c */
diff --git a/xlockmore-4.14/modes/glx/stairs.c b/xlockmore-4.14/modes/glx/stairs.c
new file mode 100644 (file)
index 0000000..e96b91f
--- /dev/null
@@ -0,0 +1,487 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* stairs --- Infinite Stairs, and Escher-like scene. */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)stairs.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+#undef DEBUG_LISTS
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * This mode shows some interesting scenes that are impossible OR very
+ * weird to build in the real universe. Much of the scenes are inspirated
+ * on Mauritz Cornelis stairs's works which derivated the mode's name.
+ * M.C. Escher (1898-1972) was a dutch artist and many people prefer to
+ * say he was a mathematician.
+ *
+ * Thanks goes to Brian Paul for making it possible and inexpensive to use 
+ * OpenGL at home.
+ *
+ * Since I'm not a native English speaker, my apologies for any grammatical
+ * mistake.
+ *
+ * My e-mail address is
+ * m-vianna@usa.net
+ *
+ * Marcelo F. Vianna (Jun-01-1997)
+ *
+ * Revision History:
+ * 07-Jan-98: This would be a scene for the escher mode, but now escher mode
+ *            was splitted in different modes for each scene. This is the
+ *            initial release and is not working yet.
+ *            Marcelo F. Vianna.
+ *
+ */
+
+/*-
+ * Texture mapping is only available on RGBA contexts, Mono and color index
+ * visuals DO NOT support texture mapping in OpenGL.
+ *
+ * BUT Mesa do implements RGBA contexts in pseudo color visuals, so texture
+ * mapping shuld work on PseudoColor, DirectColor, TrueColor using Mesa. Mono
+ * is not officially supported for both OpenGL and Mesa, but seems to not crash
+ * Mesa.
+ *
+ * In real OpenGL, PseudoColor DO NOT support texture map (as far as I know).
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "stairs"
+#define HACK_INIT init_stairs
+#define HACK_DRAW draw_stairs
+#define stairs_opts xlockmore_opts
+#define DEFAULTS "*delay: 200000 \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_stairs
+
+#include <GL/glu.h>
+#include "e_textures.h"
+
+ModeSpecOpt stairs_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   stairs_description =
+{"stairs", "init_stairs", "draw_stairs", "release_stairs",
+ "draw_stairs", "change_stairs", NULL, &stairs_opts,
+ 1000, 1, 1, 1, 4, 1.0, "",
+ "Shows Infinite Stairs, an Escher-like scene", 0, NULL};
+
+#endif
+
+#define Scale4Window               0.3
+#define Scale4Iconic               0.4
+
+#define sqr(A)                     ((A)*(A))
+
+#ifndef Pi
+#define Pi                         M_PI
+#endif
+
+/*************************************************************************/
+
+typedef struct {
+       GLint       WindH, WindW;
+       GLfloat     step;
+       Bool        direction;
+       int         AreObjectsDefined[1];
+       int         sphere_position;
+       GLXContext *glx_context;
+} stairsstruct;
+
+static float front_shininess[] =
+{60.0};
+static float front_specular[] =
+{0.7, 0.7, 0.7, 1.0};
+static float ambient[] =
+{0.0, 0.0, 0.0, 1.0};
+static float diffuse[] =
+{1.0, 1.0, 1.0, 1.0};
+static float position0[] =
+{1.0, 1.0, 1.0, 0.0};
+static float position1[] =
+{-1.0, -1.0, 1.0, 0.0};
+static float lmodel_ambient[] =
+{0.5, 0.5, 0.5, 1.0};
+static float lmodel_twoside[] =
+{GL_TRUE};
+
+#if 0
+static float MaterialRed[] =
+{0.7, 0.0, 0.0, 1.0};
+static float MaterialGreen[] =
+{0.1, 0.5, 0.2, 1.0};
+static float MaterialBlue[] =
+{0.0, 0.0, 0.7, 1.0};
+static float MaterialCyan[] =
+{0.2, 0.5, 0.7, 1.0};
+static float MaterialMagenta[] =
+{0.6, 0.2, 0.5, 1.0};
+static float MaterialGray[] =
+{0.2, 0.2, 0.2, 1.0};
+static float MaterialGray5[] =
+{0.5, 0.5, 0.5, 1.0};
+static float MaterialGray6[] =
+{0.6, 0.6, 0.6, 1.0};
+static float MaterialGray8[] =
+{0.8, 0.8, 0.8, 1.0};
+
+#endif
+static float MaterialYellow[] =
+{0.7, 0.7, 0.0, 1.0};
+static float MaterialWhite[] =
+{0.7, 0.7, 0.7, 1.0};
+
+static float positions[] =
+{
+       -2.5, 4.0, 0.0,         /* First one is FUDGED :) */
+       -3.0, 3.25, 1.0,
+       -3.0, 4.4, 1.5,
+       -3.0, 3.05, 2.0,
+       -3.0, 4.2, 2.5,
+
+       -3.0, 2.85, 3.0,
+       -2.5, 4.0, 3.0,
+       -2.0, 2.75, 3.0,
+       -1.5, 3.9, 3.0,
+       -1.0, 2.65, 3.0,
+       -0.5, 3.8, 3.0,
+       0.0, 2.55, 3.0,
+       0.5, 3.7, 3.0,
+       1.0, 2.45, 3.0,
+       1.5, 3.6, 3.0,
+       2.0, 2.35, 3.0,
+
+       2.0, 3.5, 2.5,
+       2.0, 2.25, 2.0,
+       2.0, 3.4, 1.5,
+       2.0, 2.15, 1.0,
+       2.0, 3.3, 0.5,
+       2.0, 2.05, 0.0,
+       2.0, 3.2, -0.5,
+       2.0, 1.95, -1.0,
+       2.0, 3.1, -1.5,
+       2.0, 1.85, -2.0,
+
+       1.5, 2.9, -2.0,
+       1.0, 1.65, -2.0,
+       0.5, 2.7, -2.0,
+       0.0, 1.55, -2.0,
+       -0.5, 2.5, -2.0,
+       -1.0, 1.45, -2.0,
+};
+
+#define NPOSITIONS ((sizeof positions) / (sizeof positions[0]))
+
+static stairsstruct *stairs = NULL;
+static GLuint objects;
+
+#define ObjSphere    0
+
+#define PlankWidth      3.0
+#define PlankHeight     0.35
+#define PlankThickness  0.15
+
+static void
+mySphere(float radius)
+{
+       GLUquadricObj *quadObj;
+
+       quadObj = gluNewQuadric();
+       gluQuadricDrawStyle(quadObj, (GLenum) GLU_FILL);
+       gluSphere(quadObj, radius, 16, 16);
+       gluDeleteQuadric(quadObj);
+}
+
+static void
+draw_block(GLfloat width, GLfloat height, GLfloat thickness)
+{
+       glBegin(GL_QUADS);
+       glNormal3f(0, 0, 1);
+       glTexCoord2f(0, 0);
+       glVertex3f(-width, -height, thickness);
+       glTexCoord2f(1, 0);
+       glVertex3f(width, -height, thickness);
+       glTexCoord2f(1, 1);
+       glVertex3f(width, height, thickness);
+       glTexCoord2f(0, 1);
+       glVertex3f(-width, height, thickness);
+       glNormal3f(0, 0, -1);
+       glTexCoord2f(0, 0);
+       glVertex3f(-width, height, -thickness);
+       glTexCoord2f(1, 0);
+       glVertex3f(width, height, -thickness);
+       glTexCoord2f(1, 1);
+       glVertex3f(width, -height, -thickness);
+       glTexCoord2f(0, 1);
+       glVertex3f(-width, -height, -thickness);
+       glNormal3f(0, 1, 0);
+       glTexCoord2f(0, 0);
+       glVertex3f(-width, height, thickness);
+       glTexCoord2f(1, 0);
+       glVertex3f(width, height, thickness);
+       glTexCoord2f(1, 1);
+       glVertex3f(width, height, -thickness);
+       glTexCoord2f(0, 1);
+       glVertex3f(-width, height, -thickness);
+       glNormal3f(0, -1, 0);
+       glTexCoord2f(0, 0);
+       glVertex3f(-width, -height, -thickness);
+       glTexCoord2f(1, 0);
+       glVertex3f(width, -height, -thickness);
+       glTexCoord2f(1, 1);
+       glVertex3f(width, -height, thickness);
+       glTexCoord2f(0, 1);
+       glVertex3f(-width, -height, thickness);
+       glNormal3f(1, 0, 0);
+       glTexCoord2f(0, 0);
+       glVertex3f(width, -height, thickness);
+       glTexCoord2f(1, 0);
+       glVertex3f(width, -height, -thickness);
+       glTexCoord2f(1, 1);
+       glVertex3f(width, height, -thickness);
+       glTexCoord2f(0, 1);
+       glVertex3f(width, height, thickness);
+       glNormal3f(-1, 0, 0);
+       glTexCoord2f(0, 0);
+       glVertex3f(-width, height, thickness);
+       glTexCoord2f(1, 0);
+       glVertex3f(-width, height, -thickness);
+       glTexCoord2f(1, 1);
+       glVertex3f(-width, -height, -thickness);
+       glTexCoord2f(0, 1);
+       glVertex3f(-width, -height, thickness);
+       glEnd();
+}
+
+static void
+draw_stairs_internal(ModeInfo * mi)
+{
+       stairsstruct *sp = &stairs[MI_SCREEN(mi)];
+       GLfloat     X;
+
+       glPushMatrix();
+       glPushMatrix();
+       glTranslatef(-3.0, 0.1, 2.0);
+       for (X = 0; X < 2; X++) {
+               draw_block(0.5, 2.7 + 0.1 * X, 0.5);
+               glTranslatef(0.0, 0.1, -1.0);
+       }
+       glPopMatrix();
+       glTranslatef(-3.0, 0.0, 3.0);
+       glPushMatrix();
+
+       for (X = 0; X < 6; X++) {
+               draw_block(0.5, 2.6 - 0.1 * X, 0.5);
+               glTranslatef(1.0, -0.1, 0.0);
+       }
+       glTranslatef(-1.0, -0.9, -1.0);
+       for (X = 0; X < 5; X++) {
+               draw_block(0.5, 3.0 - 0.1 * X, 0.5);
+               glTranslatef(0.0, 0.0, -1.0);
+       }
+       glTranslatef(-1.0, -1.1, 1.0);
+       for (X = 0; X < 3; X++) {
+               draw_block(0.5, 3.5 - 0.1 * X, 0.5);
+               glTranslatef(-1.0, -0.1, 0.0);
+       }
+       glPopMatrix();
+       glPopMatrix();
+
+       glPushMatrix();
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialYellow);
+
+       glTranslatef((GLfloat) positions[sp->sphere_position],
+                    (GLfloat) positions[sp->sphere_position + 1],
+                    (GLfloat) positions[sp->sphere_position + 2]);
+       if (sp->sphere_position == 0)   /* FUDGE soo its not so obvious */
+               mySphere(0.48);
+       else
+               mySphere(0.5);
+       glPopMatrix();
+       sp->sphere_position += 3;
+       if (sp->sphere_position >= (int) NPOSITIONS)
+               sp->sphere_position = 0;
+}
+
+static void
+reshape(ModeInfo * mi, int width, int height)
+{
+       stairsstruct *sp = &stairs[MI_SCREEN(mi)];
+
+       glViewport(0, 0, sp->WindW = (GLint) width, sp->WindH = (GLint) height);
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 15.0);
+       glMatrixMode(GL_MODELVIEW);
+       if (width >= 1024) {
+               glLineWidth(3);
+               glPointSize(3);
+       } else if (width >= 512) {
+               glLineWidth(2);
+               glPointSize(2);
+       } else {
+               glLineWidth(1);
+               glPointSize(1);
+       }
+}
+
+static void
+pinit(void)
+{
+       glClearDepth(1.0);
+       glClearColor(0.0, 0.0, 0.0, 1.0);
+
+       glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT0, GL_POSITION, position0);
+       glLightfv(GL_LIGHT1, GL_AMBIENT, ambient);
+       glLightfv(GL_LIGHT1, GL_DIFFUSE, diffuse);
+       glLightfv(GL_LIGHT1, GL_POSITION, position1);
+       glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lmodel_ambient);
+       glLightModelfv(GL_LIGHT_MODEL_TWO_SIDE, lmodel_twoside);
+       glEnable(GL_LIGHTING);
+       glEnable(GL_LIGHT0);
+       glEnable(GL_LIGHT1);
+       glEnable(GL_NORMALIZE);
+       glFrontFace(GL_CCW);
+       glCullFace(GL_BACK);
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, MaterialWhite);
+       glShadeModel(GL_FLAT);
+       glEnable(GL_DEPTH_TEST);
+       glEnable(GL_TEXTURE_2D);
+       glEnable(GL_CULL_FACE);
+
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+       gluBuild2DMipmaps(GL_TEXTURE_2D, 3, WoodTextureWidth, WoodTextureHeight,
+                         GL_RGB, GL_UNSIGNED_BYTE, WoodTextureData);
+       glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+       glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, front_shininess);
+       glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, front_specular);
+}
+
+void
+init_stairs(ModeInfo * mi)
+{
+       int         screen = MI_SCREEN(mi);
+       stairsstruct *sp;
+
+       if (stairs == NULL) {
+               if ((stairs = (stairsstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (stairsstruct))) == NULL)
+                       return;
+       }
+       sp = &stairs[screen];
+       sp->step = 0.0;
+       sp->direction = LRAND() & 1;
+       sp->sphere_position = NRAND(NPOSITIONS / 3) * 3;
+
+       if ((sp->glx_context = init_GL(mi)) != NULL) {
+
+               reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+               glDrawBuffer(GL_BACK);
+               if (!glIsList(objects))
+                       objects = glGenLists(1);
+               pinit();
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_stairs(ModeInfo * mi)
+{
+       stairsstruct *sp = &stairs[MI_SCREEN(mi)];
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!sp->glx_context)
+               return;
+
+       glXMakeCurrent(display, window, *(sp->glx_context));
+
+       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       glPushMatrix();
+
+       glTranslatef(0.0, 0.0, -10.0);
+
+       if (!MI_IS_ICONIC(mi)) {
+               glScalef(Scale4Window * sp->WindH / sp->WindW, Scale4Window, Scale4Window);
+       } else {
+               glScalef(Scale4Iconic * sp->WindH / sp->WindW, Scale4Iconic, Scale4Iconic);
+       }
+
+       glRotatef(44.5, 1, 0, 0);
+       glRotatef(50 + ((sp->direction) ? 1 : -1) *
+              ((sp->step * 100 > 120) ? sp->step * 100 - 120 : 0), 0, 1, 0);
+       if (sp->step * 100 >= 360 + 120) {      /* stop showing secrets */
+               sp->step = 0;
+               sp->direction = LRAND() & 1;
+       }
+       draw_stairs_internal(mi);
+
+       glPopMatrix();
+
+       glFlush();
+
+       glXSwapBuffers(display, window);
+
+       sp->step += 0.025;
+}
+
+void
+change_stairs(ModeInfo * mi)
+{
+       stairsstruct *sp = &stairs[MI_SCREEN(mi)];
+
+       if (!sp->glx_context)
+               return;
+
+       glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(sp->glx_context));
+       pinit();
+}
+
+void
+release_stairs(ModeInfo * mi)
+{
+       if (stairs != NULL) {
+               (void) free((void *) stairs);
+               stairs = NULL;
+       }
+       if (glIsList(objects)) {
+               glDeleteLists(objects, 1);
+       }
+       FreeAllGL(mi);
+}
+
+#endif
diff --git a/xlockmore-4.14/modes/glx/superquadrics.c b/xlockmore-4.14/modes/glx/superquadrics.c
new file mode 100644 (file)
index 0000000..3612bd1
--- /dev/null
@@ -0,0 +1,781 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* superquadrics --- 3D mathematical shapes */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)superquadrics.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Superquadrics were invented by Dr. Alan Barr of Caltech University.
+ * They were first published in "Computer Graphics and Applications",
+ * volume 1, number 1, 1981, in the article "Superquadrics and Angle-
+ * Preserving Transformations."  Dr. Barr based the Superquadrics on
+ * Piet Hein's "super ellipses."  Super ellipses are like 2D ellipses,
+ * except that the formula includes an exponent, raising its X and Y
+ * values to a (fractional) power, and allowing them to gradually
+ * change from round to square edges.  Superquadrics extend this
+ * idea into 3 dimensions, using two exponents to modify a
+ * quadric surface in a similar fashion.
+ *
+ * Revision History:
+ * 30-Mar-97: Turned into a module for xlockmore 4.02 alpha.  The code
+ *    is almost unrecognizable now from the first revision, except for
+ *    a few remaining two-letter variable names.  I still don't have
+ *    the normal vectors working right (I wrote the buggy normal vector
+ *    code myself, can you tell?)
+ * 07-Jan-97: A legend reborn; Superquadrics make an appearance as a
+ *    real OpenGL program written in C.  I can even render them with
+ *    proper lighting and specular highlights.  Gee, they look almost
+ *    as good now as the original color plates of them that my uncle
+ *    showed me as a child in 1981.  I don't know what computer hardware
+ *    he was using at the time, but it's taken a couple decades for the
+ *    PC clone hardware to catch up to it.
+ * 05-Jan-97: After almost a decade, Superquadrics had almost faded away
+ *    into the myths and folklore of all the things my brother and I played
+ *    with on computers when we were kids with too much time on our hands.
+ *    I had since gotten involved in Unix, OpenGL, and other things.
+ *    A sudden flash of inspiration caused me to dig out the old Pascal
+ *    source code, run it through p2c, and start ripping away the old
+ *    wireframe rendering code, to be replaced by OpenGL.
+ * Late 1989 or early 1990:  Around this time I did the Turbo Pascal
+ *    port of the Superquadrics.  Unfortunately, many of the original variable
+ *    names remained the same from the C= 64 original.  This was unfortunate
+ *    because BASIC on the c64 only allowed 2-letter, global variable names.
+ *    But the speed improvement over BASIC was very impressive at the time.
+ * Thanksgiving, 1987: Written.  My uncle Al, who invented Superquadrics some
+ *    years earlier, came to visit us.  I was a high school kid at the time,
+ *    with nothing more than a Commodore 64.  Somehow we wrote this program,
+ *    (he did the math obviously, I just coded it into BASIC for the c64).
+ *    Yeah, 320x200 resolution, colorless white wireframe, and half an hour
+ *    rendering time per superquadric.  PLOT x,y.  THOSE were the days.
+ *    In the following years I would port Superquadrics to AppleBASIC,
+ *    AmigaBASIC, and then Turbo Pascal for IBM clones.  5 minutes on a 286!
+ *    Talk about fast rendering!  But these days, when my Pentium 166 runs
+ *    the same program, the superquadric will already be waiting on the
+ *    screen before my monitor can change frequency from text to graphics
+ *    mode.  Can't time the number of minutes that way!  Darn ;)
+ *
+ * Ed Mackey
+ */
+
+/*-
+ * due to a Bug/feature in VMS X11/Intrinsic.h has to be placed before xlock.
+ * otherwise caddr_t is not defined correctly
+ */
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Superquadrics"
+#define HACK_INIT init_superquadrics
+#define HACK_DRAW draw_superquadrics
+#define superquadrics_opts xlockmore_opts
+#define DEFAULTS "*delay: 100 \n" \
+ "*count: 25 \n" \
+ "*cycles: 40 \n" \
+ "*wireframe: False \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_superquadrics
+
+/*-
+ * Note for low-CPU-speed machines:  If your frame rate is so low that
+ * attempts at animation appear futile, try using "-cycles 1", which puts
+ * Superquadrics into kind of a slide-show mode.  It will still use up
+ * all of your CPU power, but it may look nicer.
+ */
+
+#define DEF_SPINSPEED  "5.0"
+
+static float spinspeed;
+
+static XrmOptionDescRec opts[] =
+{
+  {"-spinspeed", ".superquadrics.spinspeed", XrmoptionSepArg, (caddr_t) NULL}
+};
+static argtype vars[] =
+{
+  {(caddr_t *) & spinspeed, "spinspeed", "Spinspeed", DEF_SPINSPEED, t_Float}
+};
+static OptionStruct desc[] =
+{
+       {"-spinspeed num", "speed of rotation, in degrees per frame"}
+};
+
+ModeSpecOpt superquadrics_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   superquadrics_description =
+{"superquadrics", "init_superquadrics", "draw_superquadrics", "release_superquadrics",
+ "refresh_superquadrics", "init_superquadrics", NULL, &superquadrics_opts,
+ 1000, 25, 40, 1, 4, 1.0, "",
+ "Shows 3D mathematical shapes", 0, NULL};
+
+#endif
+
+#include <GL/glu.h>
+
+#define MaxRes          50
+#define MinRes          5
+
+typedef double dimi[MaxRes + 1];
+
+typedef struct {
+       double      xExponent, yExponent;
+       GLfloat     r[4], g[4], b[4];
+       long        Mode;
+       int         rotx, rotz;
+} state;
+
+typedef struct {
+       GLXContext *glx_context;
+       int         dist, wireframe, flatshade, shownorms, maxcount, maxwait;
+       int         counter, viewcount, viewwait, mono;
+       GLfloat     curmat[4][4], rotx, roty, rotz, spinspeed;
+       /* In dimi: the first letter stands for cosine/sine, the second
+        *          stands for North, South, East, or West.  I think.
+        */
+       dimi        cs, se, sw, sn, ss, ce, cw, cn, Prevxx, Prevyy, Prevzz,
+                   Prevxn, Prevyn, Prevzn;
+       double      xExponent, yExponent, Mode;
+       int         resolution;
+       state       now, later;
+} superquadricsstruct;
+
+static superquadricsstruct *superquadrics = NULL;
+
+#define CLIP_NORMALS 10000.0
+
+static void ReshapeSuperquadrics(int w, int h);
+
+static int
+myrand(int range)
+{
+       return ((int) (((float) range) * LRAND() / (MAXRAND)));
+}
+
+static float
+myrandreal(void)
+{
+       return (LRAND() / (MAXRAND));
+}
+
+/* Some old, old, OLD code follows.  Ahh this takes me back..... */
+
+/* Output from p2c, the Pascal-to-C translator */
+/* From input file "squad.pas" */
+
+static double
+XtoY(double x, double y)
+{
+       double      z, a;
+
+       /* This is NOT your typical raise-X-to-the-Y-power function.  Do not attempt
+        * to replace this with a standard exponent function.  If you must, just
+        * replace the "a = exp(y * log(z));" line with something faster.
+        */
+
+       z = fabs(x);
+       if (z < 1e-20) {
+               a = 0.0;
+               return a;
+       }
+       a = exp(y * log(z));
+       if (a > CLIP_NORMALS)
+               a = CLIP_NORMALS;
+       if (x < 0)
+               a = -a;
+       return a;
+}
+
+
+static double
+Sine(double x, double e)
+{
+       /* This is just the sine wave raised to the exponent.  BUT, you can't
+        * raise negative numbers to fractional exponents.  So we have a special
+        * XtoY routune which handles it in a way useful to superquadrics.
+        */
+
+       return (XtoY(sin(x), e));
+}
+
+
+static double
+Cosine(double x, double e)
+{
+       return (XtoY(cos(x), e));
+}
+
+
+static void
+MakeUpStuff(int allstuff, superquadricsstruct * sp)
+{
+       static int  pats[4][4] =
+       {
+               {0, 0, 0, 0},
+               {0, 1, 0, 1},
+               {0, 0, 1, 1},
+               {0, 1, 1, 0}
+       };
+
+       int         dostuff;
+       int         t, pat;
+       GLfloat     r, g, b, r2, g2, b2;
+
+       /* randomize it. */
+
+       if (sp->maxcount < 2)
+               allstuff = 1;
+       dostuff = allstuff * 15;
+       if (!dostuff) {
+               dostuff = myrand(3) + 1;
+               if (myrand(2) || (dostuff & 1))
+                       dostuff |= 4;
+               if (myrand(2))
+                       dostuff |= 8;
+       }
+       if (dostuff & 1) {
+               sp->later.xExponent = (((long) floor(myrandreal() * 250 + 0.5)) / 100.0) + 0.1;
+               sp->later.yExponent = (((long) floor(myrandreal() * 250 + 0.5)) / 100.0) + 0.1;
+
+               /* Increase the 2.0 .. 2.5 range to 2.0 .. 3.0 */
+               if (sp->later.xExponent > 2.0)
+                       sp->later.xExponent = (sp->later.xExponent * 2.0) - 2.0;
+               if (sp->later.yExponent > 2.0)
+                       sp->later.yExponent = (sp->later.yExponent * 2.0) - 2.0;
+       }
+       if (dostuff & 2) {
+               do {
+                       sp->later.Mode = myrand(3L) + 1;
+               } while (!allstuff && (sp->later.Mode == sp->now.Mode));
+               /* On init: make sure it can stay in mode 1 if it feels like it. */
+       }
+       if (dostuff & 4) {
+               if (sp->mono) {
+                       if (sp->wireframe) {
+                               b = g = r = 1.0;
+                               b2 = g2 = r2 = 1.0;
+                       } else {
+                               b = g = r = (GLfloat) (140 + myrand(100)) / 255.0;
+                               b2 = g2 = r2 = ((r > 0.69) ? (1.0 - r) : r);
+                       }
+               } else {
+                       r = (GLfloat) (40 + myrand(200)) / 255.0;
+                       g = (GLfloat) (40 + myrand(200)) / 255.0;
+                       b = (GLfloat) (40 + myrand(200)) / 255.0;
+
+                       r2 = ((myrand(4) && ((r < 0.31) || (r > 0.69))) ? (1.0 - r) : r);
+                       g2 = ((myrand(4) && ((g < 0.31) || (g > 0.69))) ? (1.0 - g) : g);
+                       b2 = ((myrand(4) && ((b < 0.31) || (b > 0.69))) ? (1.0 - b) : b);
+               }
+
+               pat = myrand(4);
+               for (t = 0; t < 4; ++t) {
+                       sp->later.r[t] = pats[pat][t] ? r : r2;
+                       sp->later.g[t] = pats[pat][t] ? g : g2;
+                       sp->later.b[t] = pats[pat][t] ? b : b2;
+               }
+       }
+       if (dostuff & 8) {
+               sp->later.rotx = myrand(360) - 180;
+               sp->later.rotz = myrand(160) - 80;
+       }
+}
+
+static void
+inputs(superquadricsstruct * sp)
+{
+       int         iv;
+       double      u, v, mode3, cn3, inverter2, flatu, flatv;
+
+       if (sp->Mode < 1.000001) {
+               mode3 = 1.0;
+               cn3 = 0.0;
+               inverter2 = 1.0;
+       } else if (sp->Mode < 2.000001) {
+               mode3 = 1.0;
+               cn3 = (sp->Mode - 1.0) * 1.5;
+               inverter2 = (sp->Mode - 1.0) * -2.0 + 1.0;
+       } else {
+               mode3 = (sp->Mode - 1.0);
+               cn3 = (sp->Mode - 2.0) / 2.0 + 1.5;
+               inverter2 = -1.0;
+       }
+
+       if (sp->flatshade) {
+               flatu = M_PI / (sp->resolution - 1);
+               flatv = mode3 * M_PI / ((sp->resolution - 1) * 2);
+       } else {
+               flatu = flatv = 0.0;
+       }
+
+       /* (void) printf("Calculating....\n"); */
+       for (iv = 1; iv <= sp->resolution; iv++) {
+
+               /* u ranges from PI down to -PI */
+               u = (1 - iv) * 2 * M_PI / (sp->resolution - 1) + M_PI;
+
+               /* v ranges from PI/2 down to -PI/2 */
+               v = (1 - iv) * mode3 * M_PI / (sp->resolution - 1) + M_PI * (mode3 / 2.0);
+
+               /* Use of xExponent */
+               sp->se[iv] = Sine(u, sp->xExponent);
+               sp->ce[iv] = Cosine(u, sp->xExponent);
+               sp->sn[iv] = Sine(v, sp->yExponent);
+               sp->cn[iv] = Cosine(v, sp->yExponent) * inverter2 + cn3;
+
+               /* Normal vector computations only */
+               sp->sw[iv] = Sine(u + flatu, 2 - sp->xExponent);
+               sp->cw[iv] = Cosine(u + flatu, 2 - sp->xExponent);
+               sp->ss[iv] = Sine(v + flatv, 2 - sp->yExponent) * inverter2;
+               sp->cs[iv] = Cosine(v + flatv, 2 - sp->yExponent);
+       }                       /* next */
+
+       /* Now fix up the endpoints */
+       sp->se[sp->resolution] = sp->se[1];
+       sp->ce[sp->resolution] = sp->ce[1];
+
+       if (sp->Mode > 2.999999) {
+               sp->sn[sp->resolution] = sp->sn[1];
+               sp->cn[sp->resolution] = sp->cn[1];
+       }
+}
+
+
+static void
+DoneScale(superquadricsstruct * sp)
+{
+       double      xx, yy, zz, xp = 0, yp = 0, zp = 0, xn, yn, zn, xnp = 0,
+                   ynp = 0, znp = 0;
+       int         ih, iv;
+
+       /* Hey don't knock my 2-letter variable names.  Simon's BASIC rules, man! ;-> */
+       /* Just kidding..... */
+       int         toggle = 0;
+
+       for (ih = 1; ih <= sp->resolution; ih++) {
+               toggle ^= 2;
+               for (iv = 1; iv <= sp->resolution; iv++) {
+                       toggle ^= 1;
+                       if (sp->wireframe)
+                               glColor3f(sp->curmat[toggle][0], sp->curmat[toggle][1], sp->curmat[toggle][2]);
+                       else
+                               glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, sp->curmat[toggle]);
+
+                       xx = sp->cn[iv] * sp->ce[ih];
+                       zz = sp->cn[iv] * sp->se[ih];
+                       yy = sp->sn[iv];
+
+                       if (sp->wireframe) {
+                               if ((ih > 1) || (iv > 1)) {
+                                       glBegin(GL_LINES);
+                                       if (ih > 1) {
+                                               glVertex3f(xx, yy, zz);
+                                               glVertex3f(sp->Prevxx[iv], sp->Prevyy[iv], sp->Prevzz[iv]);
+                                       }
+                                       if (iv > 1) {
+                                               glVertex3f(xx, yy, zz);
+                                               glVertex3f(sp->Prevxx[iv - 1], sp->Prevyy[iv - 1], sp->Prevzz[iv - 1]);
+                                       }
+/* PURIFY 4.0.1 reports an unitialized memory read on the next line when using
+   * MesaGL 2.2 and -mono.  This has been fixed in MesaGL 2.3 and later. */
+                                       glEnd();
+                               }
+                       } else {
+                               if ((sp->cs[iv] > 1e+10) || (sp->cs[iv] < -1e+10)) {
+                                       xn = sp->cs[iv];
+                                       zn = sp->cs[iv];
+                                       yn = sp->ss[iv];
+                               } else {
+                                       xn = sp->cs[iv] * sp->cw[ih];
+                                       zn = sp->cs[iv] * sp->sw[ih];
+                                       yn = sp->ss[iv];
+                               }
+                               if ((ih > 1) && (iv > 1)) {
+                                       glNormal3f(xn, yn, zn);
+                                       glBegin(GL_POLYGON);
+                                       glVertex3f(xx, yy, zz);
+                                       if (!sp->flatshade)
+                                               glNormal3f(sp->Prevxn[iv], sp->Prevyn[iv], sp->Prevzn[iv]);
+                                       glVertex3f(sp->Prevxx[iv], sp->Prevyy[iv], sp->Prevzz[iv]);
+                                       if (!sp->flatshade)
+                                               glNormal3f(xnp, ynp, znp);
+                                       glVertex3f(xp, yp, zp);
+                                       if (!sp->flatshade)
+                                               glNormal3f(sp->Prevxn[iv - 1], sp->Prevyn[iv - 1], sp->Prevzn[iv - 1]);
+                                       glVertex3f(sp->Prevxx[iv - 1], sp->Prevyy[iv - 1], sp->Prevzz[iv - 1]);
+                                       glEnd();
+                               }
+                               if (sp->shownorms) {
+                                       if (!sp->flatshade)
+                                               glShadeModel(GL_FLAT);
+                                       glDisable(GL_LIGHTING);
+                                       glBegin(GL_LINES);
+                                       glVertex3f(xx, yy, zz);
+                                       glVertex3f(xx + xn, yy + yn, zz + zn);
+                                       glEnd();
+                                       if (!sp->flatshade)
+                                               glShadeModel(GL_SMOOTH);
+                                       glEnable(GL_LIGHTING);
+                               }
+                               xnp = sp->Prevxn[iv];
+                               ynp = sp->Prevyn[iv];
+                               znp = sp->Prevzn[iv];
+                               sp->Prevxn[iv] = xn;
+                               sp->Prevyn[iv] = yn;
+                               sp->Prevzn[iv] = zn;
+                       }
+
+                       xp = sp->Prevxx[iv];
+                       yp = sp->Prevyy[iv];
+                       zp = sp->Prevzz[iv];
+                       sp->Prevxx[iv] = xx;
+                       sp->Prevyy[iv] = yy;
+                       sp->Prevzz[iv] = zz;
+
+               }               /* next */
+       }                       /* next */
+}
+
+/**** End of really old code ****/
+
+static void
+SetCull(int init, superquadricsstruct * sp)
+{
+       static int  cullmode;
+
+       if (init) {
+               cullmode = 0;
+               return;
+       }
+       if (sp->Mode < 1.0001) {
+               if (cullmode != 1) {
+                       glEnable(GL_CULL_FACE);
+                       glCullFace(GL_BACK);
+                       cullmode = 1;
+               }
+       } else if (sp->Mode > 2.9999) {
+               if (cullmode != 2) {
+                       glEnable(GL_CULL_FACE);
+                       glCullFace(GL_FRONT);
+                       cullmode = 2;
+               }
+       } else {
+               if (cullmode) {
+                       glDisable(GL_CULL_FACE);
+                       cullmode = 0;
+               }
+       }
+}
+
+static void
+SetCurrentShape(superquadricsstruct * sp)
+{
+       int         t;
+
+       sp->xExponent = sp->now.xExponent = sp->later.xExponent;
+       sp->yExponent = sp->now.yExponent = sp->later.yExponent;
+
+       for (t = 0; t < 4; ++t) {
+               sp->curmat[t][0] = sp->now.r[t] = sp->later.r[t];
+               sp->curmat[t][1] = sp->now.g[t] = sp->later.g[t];
+               sp->curmat[t][2] = sp->now.b[t] = sp->later.b[t];
+       }
+
+       sp->Mode = (double) (sp->now.Mode = sp->later.Mode);
+       sp->rotx = sp->now.rotx = sp->later.rotx;
+       sp->rotz = sp->now.rotz = sp->later.rotz;
+
+       sp->counter = -sp->maxwait;
+
+       inputs(sp);
+}
+
+static void
+NextSuperquadric(superquadricsstruct * sp)
+{
+       double      fnow, flater;
+       int         t;
+
+       sp->roty -= sp->spinspeed;
+       while (sp->roty >= 360.0)
+               sp->roty -= 360.0;
+       while (sp->roty < 0.0)
+               sp->roty += 360.0;
+
+       --sp->viewcount;
+
+       if (sp->counter > 0) {
+               if (--sp->counter == 0) {
+                       SetCurrentShape(sp);
+                       if (sp->counter == 0) {         /* Happens if sp->maxwait == 0 */
+                               MakeUpStuff(0, sp);
+                               sp->counter = sp->maxcount;
+                       }
+               } else {
+                       fnow = (double) sp->counter / (double) sp->maxcount;
+                       flater = (double) (sp->maxcount - sp->counter) / (double) sp->maxcount;
+                       sp->xExponent = sp->now.xExponent * fnow + sp->later.xExponent * flater;
+                       sp->yExponent = sp->now.yExponent * fnow + sp->later.yExponent * flater;
+
+                       for (t = 0; t < 4; ++t) {
+                               sp->curmat[t][0] = sp->now.r[t] * fnow + sp->later.r[t] * flater;
+                               sp->curmat[t][1] = sp->now.g[t] * fnow + sp->later.g[t] * flater;
+                               sp->curmat[t][2] = sp->now.b[t] * fnow + sp->later.b[t] * flater;
+                       }
+
+                       sp->Mode = (double) sp->now.Mode * fnow + (double) sp->later.Mode * flater;
+                       sp->rotx = (double) sp->now.rotx * fnow + (double) sp->later.rotx * flater;
+                       sp->rotz = (double) sp->now.rotz * fnow + (double) sp->later.rotz * flater;
+
+                       inputs(sp);
+               }
+       } else {
+               if (++sp->counter >= 0) {
+                       MakeUpStuff(0, sp);
+                       sp->counter = sp->maxcount;
+               }
+       }
+}
+
+static void
+DisplaySuperquadrics(superquadricsstruct * sp)
+{
+       glDrawBuffer(GL_BACK);
+       if (sp->wireframe)
+               glClear(GL_COLOR_BUFFER_BIT);
+       else
+               glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+       if (sp->viewcount < 1) {
+               sp->viewcount = sp->viewwait;
+               ReshapeSuperquadrics(-1, -1);
+       }
+       glPushMatrix();
+       glTranslatef(0.0, 0.0, -((GLfloat) (sp->dist) / 16.0) - (sp->Mode * 3.0 - 1.0));        /* viewing transform  */
+       glRotatef(sp->rotx, 1.0, 0.0, 0.0);     /* pitch */
+       glRotatef(sp->rotz, 0.0, 0.0, 1.0);     /* bank */
+       glRotatef(sp->roty, 0.0, 1.0, 0.0);     /* "spin", like heading but comes after P & B */
+
+       SetCull(0, sp);
+
+       DoneScale(sp);
+
+       glPopMatrix();
+
+       /* Remember to flush & swap the buffers after calling this function! */
+}
+
+static void
+NextSuperquadricDisplay(superquadricsstruct * sp)
+{
+       NextSuperquadric(sp);
+       DisplaySuperquadrics(sp);
+}
+
+#define MINSIZE 200
+static void
+ReshapeSuperquadrics(int w, int h)
+{
+       static int  last_w = 0, last_h = 0;
+       int         maxsize, cursize;
+
+       if (w < 0) {
+               w = last_w;
+               h = last_h;
+       } else {
+               last_w = w;
+               last_h = h;
+       }
+       maxsize = (w < h) ? w : h;
+       if (maxsize <= MINSIZE) {
+               cursize = maxsize;
+       } else {
+               cursize = myrand(maxsize - MINSIZE) + MINSIZE;
+       }
+       if ((w > cursize) && (h > cursize)) {
+               glViewport(myrand(w - cursize), myrand(h - cursize), cursize, cursize);
+               w = h = cursize;
+       } else {
+               glViewport(0, 0, w, h);
+       }
+       glMatrixMode(GL_PROJECTION);
+       glLoadIdentity();
+       gluPerspective(30.0, (GLfloat) w / (GLfloat) h, 0.1, 200.0);
+       glMatrixMode(GL_MODELVIEW);
+       glLoadIdentity();
+}
+
+static void
+InitSuperquadrics(int wfmode, int snorm, int res, int count, float speed, superquadricsstruct * sp)
+{
+       GLfloat     ambient[] =
+       {0.4, 0.4, 0.4, 1.0};
+       GLfloat     position[] =
+       {10.0, 1.0, 1.0, 10.0};
+       GLfloat     mat_diffuse[] =
+       {1.0, 0.5, 0.5, 1.0};
+       GLfloat     mat_specular[] =
+       {0.8, 0.8, 0.8, 1.0};
+       GLfloat     mat_shininess[] =
+       {50.0};
+
+       int         t;
+
+       for (t = 0; t < 4; ++t)
+               sp->curmat[t][3] = 1.0;
+
+       sp->rotx = 35.0;
+       sp->roty = 0.0;
+       sp->rotz = 0.0;
+       sp->dist = (16 << 3);
+       sp->wireframe = sp->flatshade = sp->shownorms = 0;
+       sp->maxcount = count;
+       if (sp->maxcount < 1)
+               sp->maxcount = 1;
+       sp->maxwait = sp->maxcount >> 1;
+       SetCull(1, sp);
+
+       sp->spinspeed = speed;
+       sp->viewcount = sp->viewwait = (sp->maxcount < 2) ? 1 : (sp->maxcount << 3);
+
+       if (res < MinRes)
+               res = MinRes;
+       if (res > MaxRes)
+               res = MaxRes;
+       sp->resolution = res;
+
+       if (wfmode == 2)
+               sp->flatshade = 1;
+       else if (wfmode)
+               sp->wireframe = 1;
+
+       if (snorm)
+               sp->shownorms = 1;
+
+       if (sp->wireframe) {
+               glShadeModel(GL_FLAT);
+               glDisable(GL_LIGHTING);
+               glColor3f(mat_diffuse[0], mat_diffuse[1], mat_diffuse[2]);
+       } else {
+               if (sp->flatshade) {
+                       glShadeModel(GL_FLAT);
+                       position[0] = 1.0;
+                       position[3] = 0.0;
+               }
+               glEnable(GL_LIGHTING);
+               glEnable(GL_LIGHT0);
+               glDepthFunc(GL_LEQUAL);
+               glEnable(GL_DEPTH_TEST);
+
+               glLightfv(GL_LIGHT0, GL_AMBIENT, ambient);
+               glLightfv(GL_LIGHT0, GL_POSITION, position);
+
+               /*glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, mat_diffuse); */
+               glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, mat_specular);
+               glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, mat_shininess);
+
+               glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_TRUE);
+
+               glFrontFace(GL_CW);
+               glEnable(GL_NORMALIZE);
+       }
+
+       MakeUpStuff(1, sp);
+       SetCurrentShape(sp);
+       MakeUpStuff(1, sp);     /* Initialize it */
+       sp->counter = sp->maxcount;
+}
+
+/* End of superquadrics main functions */
+
+void
+init_superquadrics(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         screen = MI_SCREEN(mi);
+
+       superquadricsstruct *sp;
+
+       if (superquadrics == NULL) {
+               if ((superquadrics = (superquadricsstruct *) calloc(MI_NUM_SCREENS(mi),
+                                     sizeof (superquadricsstruct))) == NULL)
+                       return;
+       }
+       sp = &superquadrics[screen];
+       sp->mono = (MI_IS_MONO(mi) ? 1 : 0);
+
+       if ((sp->glx_context = init_GL(mi)) != NULL) {
+
+               InitSuperquadrics(MI_IS_WIREFRAME(mi), 0,
+                                 MI_COUNT(mi), MI_CYCLES(mi), spinspeed, sp);
+               ReshapeSuperquadrics(MI_WIDTH(mi), MI_HEIGHT(mi));
+
+               DisplaySuperquadrics(sp);
+               glFinish();
+               glXSwapBuffers(display, window);
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_superquadrics(ModeInfo * mi)
+{
+       superquadricsstruct *sp = &superquadrics[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!sp->glx_context)
+               return;
+
+       glXMakeCurrent(display, window, *(sp->glx_context));
+
+       NextSuperquadricDisplay(sp);
+
+       glFinish();
+       glXSwapBuffers(display, window);
+}
+
+void
+refresh_superquadrics(ModeInfo * mi)
+{
+       /* Nothing happens here */
+}
+
+void
+release_superquadrics(ModeInfo * mi)
+{
+       if (superquadrics != NULL) {
+               (void) free((void *) superquadrics);
+               superquadrics = NULL;
+       }
+       FreeAllGL(mi);
+}
+
+
+#endif
+
+/* End of superquadrics.c */
diff --git a/xlockmore-4.14/modes/glx/swim.c b/xlockmore-4.14/modes/glx/swim.c
new file mode 100644 (file)
index 0000000..b726965
--- /dev/null
@@ -0,0 +1,233 @@
+/* atlantis --- Shows moving 3D sea animals */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)swim.c       1.3 98/06/18 xlockmore";
+
+#endif
+
+/* Copyright (c) E. Lassauge, 1998. */
+
+/*
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The original code for this mode was written by Mark J. Kilgard
+ * as a demo for openGL programming.
+ * 
+ * Porting it to xlock  was possible by comparing the original Mesa's morph3d 
+ * demo with it's ported version to xlock, so thanks for Marcelo F. Vianna 
+ * (look at morph3d.c) for his indirect help.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * My e-mail address is lassauge@sagem.fr
+ *
+ * Eric Lassauge  (May-13-1998)
+ *
+ */
+
+/**
+ * (c) Copyright 1993, 1994, Silicon Graphics, Inc.
+ * ALL RIGHTS RESERVED
+ * Permission to use, copy, modify, and distribute this software for
+ * any purpose and without fee is hereby granted, provided that the above
+ * copyright notice appear in all copies and that both the copyright notice
+ * and this permission notice appear in supporting documentation, and that
+ * the name of Silicon Graphics, Inc. not be used in advertising
+ * or publicity pertaining to distribution of the software without specific,
+ * written prior permission.
+ *
+ * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
+ * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
+ * FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
+ * GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
+ * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
+ * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
+ * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
+ * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
+ * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
+ * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * US Government Users Restricted Rights
+ * Use, duplication, or disclosure by the Government is subject to
+ * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
+ * (c)(1)(ii) of the Rights in Technical Data and Computer Software
+ * clause at DFARS 252.227-7013 and/or in similar or successor
+ * clauses in the FAR or the DOD or NASA FAR Supplement.
+ * Unpublished-- rights reserved under the copyright laws of the
+ * United States.  Contractor/manufacturer is Silicon Graphics,
+ * Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
+ *
+ * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
+ */
+
+#ifdef STANDALONE
+#include "xlockmoreI.h"                /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_atlantis
+
+#include "atlantis.h"
+
+void
+FishTransform(fishRec * fish)
+{
+
+       glTranslatef(fish->y, fish->z, -fish->x);
+       glRotatef(-fish->psi, 0.0, 1.0, 0.0);
+       glRotatef(fish->theta, 1.0, 0.0, 0.0);
+       glRotatef(-fish->phi, 0.0, 0.0, 1.0);
+}
+
+void
+WhalePilot(fishRec * fish, float whalespeed, Bool whaledir)
+{
+
+       fish->phi = -20.0;
+       fish->theta = 0.0;
+       fish->psi += ((whaledir) ? -0.5 : 0.5);
+
+       fish->x += whalespeed * fish->v * cos(fish->psi / RAD) * cos(fish->theta / RAD);
+       fish->y += whalespeed * fish->v * sin(fish->psi / RAD) * cos(fish->theta / RAD);
+       fish->z += whalespeed * fish->v * sin(fish->theta / RAD);
+}
+
+void
+SharkPilot(fishRec * fish, float sharkspeed)
+{
+       static int  sign = 1;
+       float       X, Y, Z, tpsi, ttheta, thetal;
+
+       fish->xt = 60000.0;
+       fish->yt = 0.0;
+       fish->zt = 0.0;
+
+       X = fish->xt - fish->x;
+       Y = fish->yt - fish->y;
+       Z = fish->zt - fish->z;
+
+       thetal = fish->theta;
+
+       ttheta = RAD * atan(Z / (sqrt(X * X + Y * Y)));
+
+       if (ttheta > fish->theta + 0.25) {
+               fish->theta += 0.5;
+       } else if (ttheta < fish->theta - 0.25) {
+               fish->theta -= 0.5;
+       }
+       if (fish->theta > 90.0) {
+               fish->theta = 90.0;
+       }
+       if (fish->theta < -90.0) {
+               fish->theta = -90.0;
+       }
+       fish->dtheta = fish->theta - thetal;
+
+       tpsi = RAD * atan2(Y, X);
+
+       fish->attack = 0;
+
+       if (fabs(tpsi - fish->psi) < 10.0) {
+               fish->attack = 1;
+       } else if (fabs(tpsi - fish->psi) < 45.0) {
+               if (fish->psi > tpsi) {
+                       fish->psi -= 0.5;
+                       if (fish->psi < -180.0) {
+                               fish->psi += 360.0;
+                       }
+               } else if (fish->psi < tpsi) {
+                       fish->psi += 0.5;
+                       if (fish->psi > 180.0) {
+                               fish->psi -= 360.0;
+                       }
+               }
+       } else {
+               if (NRAND(100) > 98) {
+                       sign = 1 - sign;
+               }
+               fish->psi += sign;
+               if (fish->psi > 180.0) {
+                       fish->psi -= 360.0;
+               }
+               if (fish->psi < -180.0) {
+                       fish->psi += 360.0;
+               }
+       }
+
+       if (fish->attack) {
+               if (fish->v < 1.1) {
+                       fish->spurt = 1;
+               }
+               if (fish->spurt) {
+                       fish->v += 0.2;
+               }
+               if (fish->v > 5.0) {
+                       fish->spurt = 0;
+               }
+               if ((fish->v > 1.0) && (!fish->spurt)) {
+                       fish->v -= 0.2;
+               }
+       } else {
+               if (!(NRAND(400)) && (!fish->spurt)) {
+                       fish->spurt = 1;
+               }
+               if (fish->spurt) {
+                       fish->v += 0.05;
+               }
+               if (fish->v > 3.0) {
+                       fish->spurt = 0;
+               }
+               if ((fish->v > 1.0) && (!fish->spurt)) {
+                       fish->v -= 0.05;
+               }
+       }
+
+       fish->x += sharkspeed * fish->v * cos(fish->psi / RAD) * cos(fish->theta / RAD);
+       fish->y += sharkspeed * fish->v * sin(fish->psi / RAD) * cos(fish->theta / RAD);
+       fish->z += sharkspeed * fish->v * sin(fish->theta / RAD);
+}
+
+void
+SharkMiss(atlantisstruct * ap, int i)
+{
+       int         j;
+       float       avoid, thetal;
+       float       X, Y, Z, R;
+
+       for (j = 0; j < ap->num_sharks; j++) {
+               if (j != i) {
+                       X = ap->sharks[j].x - ap->sharks[i].x;
+                       Y = ap->sharks[j].y - ap->sharks[i].y;
+                       Z = ap->sharks[j].z - ap->sharks[i].z;
+
+                       R = sqrt(X * X + Y * Y + Z * Z);
+
+                       avoid = 1.0;
+                       thetal = ap->sharks[i].theta;
+
+                       if (R < ap->sharksize) {
+                               if (Z > 0.0) {
+                                       ap->sharks[i].theta -= avoid;
+                               } else {
+                                       ap->sharks[i].theta += avoid;
+                               }
+                       }
+                       ap->sharks[i].dtheta += (ap->sharks[i].theta - thetal);
+               }
+       }
+}
+#endif
diff --git a/xlockmore-4.14/modes/glx/text3d.cc b/xlockmore-4.14/modes/glx/text3d.cc
new file mode 100644 (file)
index 0000000..0070179
--- /dev/null
@@ -0,0 +1,1123 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* text3d --- Shows moving 3D texts */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)text3d.cc    2.0 99/06/02 xlockmore";
+
+#endif
+
+/* Copyright (c) E. Lassauge, 1998. */
+
+/*
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * This module is based on a demo of the gltt graphics library
+ * Copyright (C) 1998 Stephane Rehel.
+ *
+ * See the gltt Official Site at http://home.worldnet.fr/~rehel/gltt/gltt.html
+ *
+ * My e-mail address is lassauge@sagem.fr
+ * My personnal e-mail address is eric_lassauge@mail.dotcom.fr (less used)
+ *
+ * Eric Lassauge  (August-18-1998)
+ *
+ * REVISION HISTORY:
+ *       99/06/02: patches for initialization errors of GLTT library.
+ *                 Thanks to Jouk Jansen and Scott <mcmillan@cambridge.com>.
+ *                 text3d updates for fortunes thanks to Jouk Jansen 
+ *                 <joukj@hrem.stm.tudelft.nl>
+ *                 Option no_split added.
+ *                 
+ *       98/08/23: add better handling of "faulty" fontfile and randomize 
+ *                 fontfile if '-ttfont' value is a directory.
+ *                 Minor changes for AIX from Jouk Jansen (joukj@hrem.stm.tudelft.nl).
+ * 
+ * TODO : 
+ *       I've still not really decided how to "move" the 3Dtext. 
+ *       Function Animate needs still a lot of work! Help welcome !!
+ *       Light problem with some letters (don't know why they "reflect" more).
+ *       
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Text3d"
+#define HACK_INIT init_text3d
+#define HACK_DRAW draw_text3d
+#define text3d_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*ncolors: 64 \n" \
+ "*font: \n" \
+ "*text: \n" \
+ "*filename: \n" \
+ "*fortunefile: \n" \
+ "*program: \n"
+
+extern "C"
+{
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+}
+#else                          /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+
+#endif                         /* !STANDALONE */
+
+#ifdef MODE_text3d
+
+#if 1
+#include <gltt/FTEngine.h>
+#include <gltt/FTFace.h>
+#include <gltt/FTInstance.h>
+#include <gltt/FTGlyph.h>
+#include <gltt/FTFont.h>
+#include <gltt/GLTTOutlineFont.h>
+#include <gltt/GLTTFont.h>
+#include <gltt/GLTTGlyphPolygonizer.h>
+#include <gltt/GLTTGlyphTriangulator.h>
+#else
+#include "FTEngine.h"
+#include "FTFace.h"
+#include "FTInstance.h"
+#include "FTGlyph.h"
+#include "FTFont.h"
+#include "GLTTOutlineFont.h"
+#include "GLTTFont.h"
+#include "GLTTGlyphPolygonizer.h"
+#include "GLTTGlyphTriangulator.h"
+#endif
+
+#include "text3d.h"
+#include <GL/glu.h>
+
+/* #define USE_BLANK *//* This is really bad when debugging. */
+#ifdef USE_BLANK       /* if the module cannot create the font struct
+                        * then use blank mode instead 
+                        */
+extern "C" { void init_blank(ModeInfo * mi); }
+extern "C" { void draw_blank(ModeInfo * mi); }
+extern "C" { void release_blank(ModeInfo * mi); }
+extern "C" { void refresh_blank(ModeInfo * mi); }
+#endif
+
+/* Yes, it's an ugly mix of 'C' and 'C++' functions */
+extern "C" { void init_text3d(ModeInfo * mi); }
+extern "C" { void draw_text3d(ModeInfo * mi); }
+extern "C" { void change_text3d(ModeInfo * mi); }
+extern "C" { void release_text3d(ModeInfo * mi); }
+extern "C" { void refresh_text3d(ModeInfo * mi); }
+
+/* Manage Option vars */
+/* I found this font on NT in c:\WINDOWS\SYSTEM\ARIAL.TTF can also be found
+   on Windows95 in c:\windows\fonts\arial.ttf */
+#define DEF_FONT "arial.ttf"
+#define DEF_EXTRUSION  "25.0"
+#define DEF_ROTAMPL  "1.0"
+#define DEF_ROTFREQ  "0.001"
+#define DEF_FONTSIZE  220
+#define DEF_NOSPLIT    0
+static float extrusion;
+static float rampl;
+static float rfreq;
+static char *mode_font;
+static int nosplit;
+
+static XrmOptionDescRec opts[] =
+{
+    {"-ttfont", ".text3d.ttfont", XrmoptionSepArg, (caddr_t) NULL},
+    {"-extrusion", ".text3d.extrusion", XrmoptionSepArg, (caddr_t) NULL},
+    {"-rot_amplitude", ".text3d.rot_amplitude", XrmoptionSepArg, (caddr_t) NULL},
+    {"-rot_frequency", ".text3d.rot_frequency", XrmoptionSepArg, (caddr_t) NULL},
+    {"-no_split", ".text3d.no_split", XrmoptionNoArg, (caddr_t) "on"},
+    {"+no_split", ".text3d.no_split", XrmoptionNoArg, (caddr_t) "off"},
+};
+
+static argtype vars[] =
+{
+    {(caddr_t *) & mode_font, "ttfont", "TTFont", DEF_FONT, t_String},
+    {(caddr_t *) & extrusion, "extrusion", "Extrusion", DEF_EXTRUSION, t_Float},
+    {(caddr_t *) & rampl, "rot_amplitude", "RotationAmplitude", DEF_ROTAMPL, t_Float},
+    {(caddr_t *) & rfreq, "rot_frequency", "RotationFrequency", DEF_ROTFREQ, t_Float},
+    {(caddr_t *) & nosplit, "no_split", "NoSplit", DEF_NOSPLIT, t_Bool},
+};
+
+static OptionStruct desc[] =
+{
+    {"-ttfont filename", "Text3d TrueType font file name"},
+    {"-extrusion float", "Text3d extrusion length"},
+    {"-rot_amplitude float", "Text3d rotation amplitude"},
+    {"-rot_frequency float", "Text3d rotation frequency"},
+    {"-/+no_split", "Text3d words splitting off/on"},
+};
+
+ModeSpecOpt text3d_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct text3d_description =
+{"text3d", "init_text3d", "draw_text3d", "release_text3d",
+ "refresh_text3d", "change_text3d", NULL, &text3d_opts,
+ 100000, 1, 1, 1, 64, 1.0, "",
+ "Shows 3D texts", 0, NULL};
+#endif
+
+static double camera_dist = 0.0;     /* could it be a per screen variable ? */
+static double ref_camera_dist = 0.0; /* could it be a per screen variable ? */
+static text3dstruct *text3d = (text3dstruct *) NULL;
+
+/* Hacks to use $TOP/xlock/util.c and iostuff.c functions */
+extern "C" { int index_dir(char *str1, char *substr); }
+extern "C" { char *getWords(int screen, int screens); }
+extern "C" { FILE *my_fopen(char *filename, char *type); }
+
+#if HAVE_DIRENT_H
+#define sel_font       sel_image       /* "rename" the sel_image function */
+extern "C" { void get_dir(char *fullpath, char *dir, char *filename); }
+extern "C" { int sel_font(struct dirent *name); }
+extern "C" { int scan_dir(const char *directoryname,
+                struct dirent ***namelist,
+                int (*select) (struct dirent *),
+                int (*compare) (const void *, const void *));
+}
+#endif                         /* HAVE_DIRENT_H */
+
+/*
+ *-----------------------------------------------------------------------------
+ *-----------------------------------------------------------------------------
+ *    Mode funcs.
+ *-----------------------------------------------------------------------------
+ *-----------------------------------------------------------------------------
+ */
+
+/*
+ *-----------------------------------------------------------------------------
+ *    Utils.
+ *-----------------------------------------------------------------------------
+ */
+
+static char *
+ text3d_newstr(char *s1)
+{
+    char *s;
+
+    s = (char *) malloc(strlen(s1));
+    strcpy(s, s1);
+    return s;
+}
+
+static int 
+ readable(char *filename)
+{
+    FILE *fp;
+
+    if ((fp = my_fopen(filename, "r")) == NULL)
+       return False;
+    (void) fclose(fp);
+    return True;
+}
+
+#ifdef AIXV3
+/* should probabely be in xlock.h */
+extern "C" long int lrand48(void);     /*Seems to missing in xlC for AIX3.2.5 */
+#endif
+
+/*-------------------------------------------------------------*/
+#if HAVE_DIRENT_H
+
+static void
+ randomFileFromList(char *directory,
+                   struct dirent **filelist, int numfiles, char *file_local)
+{
+    int num;
+
+    num = NRAND(numfiles);
+    if (strlen(directory) + strlen(filelist[num]->d_name) + 1 < 256)
+    {
+       (void) sprintf(file_local, "%s%s",
+                      directory, filelist[num]->d_name);
+    }
+}
+
+/*-------------------------------------------------------------*/
+static void
+ getRandomFontFile(char *randomfile, char *randomfile_local)
+{
+    /* mimic getRandomImageFile from $TOP/xlock/iostuff.c */
+    char directory_r[DIRBUF];
+    struct dirent ***fonts_list;
+    struct dirent **font_list = (dirent **) NULL;
+    int num_list;
+
+    /* extern char 'stolen' from $TOP/xlock/resource.c */
+    extern char filename_r[MAXNAMLEN];
+
+    get_dir(randomfile, directory_r, filename_r);
+
+    fonts_list = (struct dirent ***) malloc(sizeof(struct dirent **));
+
+    num_list = scan_dir(directory_r, fonts_list, sel_font, (int (*)(const
+                                                void *, const void *)) NULL);
+    font_list = *fonts_list;
+    (void) free((void *) fonts_list);
+    if (num_list > 0)
+    {
+       randomFileFromList(directory_r, font_list, num_list, randomfile_local);
+    }
+}
+#endif                         /* HAVE_DIRENT_H */
+
+/*-------------------------------------------------------------*/
+
+#ifdef DIFFUSE_COLOR
+static void
+ hsv_to_rgb(double h, double s, double v,
+           double *r, double *g, double *b)
+{
+    double xh = fmod(h * 360., 360) / 60.0,
+          i = floor(xh),
+          f = xh - i,
+          p1 = v * (1 - s),
+          p2 = v * (1 - (s * f)),
+          p3 = v * (1 - (s * (1 - f)));
+
+    switch ((int) i)
+    {
+    case 0:
+       *r = v;
+       *g = p3;
+       *b = p1;
+       break;
+    case 1:
+       *r = p2;
+       *g = v;
+       *b = p1;
+       break;
+    case 2:
+       *r = p1;
+       *g = v;
+       *b = p3;
+       break;
+    case 3:
+       *r = p1;
+       *g = p2;
+       *b = v;
+       break;
+    case 4:
+       *r = p3;
+       *g = p1;
+       *b = v;
+       break;
+    case 5:
+       *r = v;
+       *g = p1;
+       *b = p2;
+       break;
+    }
+}
+#endif                         /* DIFFUSE_COLOR */
+
+/*-------------------------------------------------------------*/
+static void spheric_camera(text3dstruct * tp,
+                          float center_x, float center_y, float center_z,
+                          float phi, float theta, float radius)
+{
+    float x = center_x + cos(phi) * cos(theta) * radius;
+    float y = center_y + sin(phi) * cos(theta) * radius;
+    float z = center_z + sin(theta) * radius;
+
+    float vx = -cos(phi) * sin(theta) * radius;
+    float vy = -sin(phi) * sin(theta) * radius;
+    float vz = cos(theta) * radius;
+
+    glViewport(0, 0, tp->WinW, tp->WinH);
+    glMatrixMode(GL_PROJECTION);
+    glLoadIdentity();
+    gluPerspective(60, GLfloat(tp->WinW) / GLfloat(tp->WinH), 10, 10000);
+
+    glMatrixMode(GL_MODELVIEW);
+    glLoadIdentity();
+    gluLookAt(x, y, z, center_x, center_y, center_z, vx, vy, vz);
+}
+
+/*-------------------------------------------------------------*/
+class GLTTGlyphTriangles:public GLTTGlyphTriangulator
+{
+public:
+    struct Triangle
+    {
+       FTGlyphVectorizer::POINT * p1;
+       FTGlyphVectorizer::POINT * p2;
+       FTGlyphVectorizer::POINT * p3;
+    };
+
+    Triangle *triangles;
+    int nTriangles;
+
+    GLTTboolean count_them;
+
+    GLTTGlyphTriangles(FTGlyphVectorizer * vectorizer):
+       GLTTGlyphTriangulator(vectorizer)
+       {
+           triangles  = 0;
+           nTriangles = 0;
+           count_them = GLTT_TRUE;
+       }
+    virtual ~GLTTGlyphTriangles()
+    {
+       delete[]triangles;
+       triangles = 0;
+    }
+    void alloc()
+    {
+       delete triangles;
+       triangles = new Triangle[nTriangles + 1];
+    }
+    virtual void triangle(FTGlyphVectorizer::POINT * p1,
+                         FTGlyphVectorizer::POINT * p2,
+                         FTGlyphVectorizer::POINT * p3)
+    {
+       if (count_them)
+       {
+           ++nTriangles;
+           return;
+       }
+       triangles[nTriangles].p1 = p1;
+
+       triangles[nTriangles].p2 = p2;
+       triangles[nTriangles].p3 = p3;
+       ++nTriangles;
+    }
+};
+
+/*
+ *-----------------------------------------------------------------------------
+ *    "Main" local funcs.
+ *-----------------------------------------------------------------------------
+ */
+
+static void
+ Reshape(ModeInfo * mi, int width, int height)
+{
+    text3dstruct *tp = &text3d[MI_SCREEN(mi)];
+
+    glViewport(0, 0, tp->WinW = (GLint) width, tp->WinH = (GLint) height);
+
+    glMatrixMode(GL_PROJECTION);
+    glLoadIdentity();
+    gluPerspective(60.0, (GLdouble) width / (GLdouble) height, 10, 10000);
+    glMatrixMode(GL_MODELVIEW);
+}
+
+/*-------------------------------------------------------------*/
+static void
+ Animate(text3dstruct * tp)
+{
+#ifdef FUNNY_ANIMATE
+    const double angle_speed = 2.5 / 180.0 * M_PI;
+    int key = NRAND(32);
+
+    switch (key)
+    {
+    case 0:
+    case 1:
+    case 2:
+    case 3:
+       tp->theta += angle_speed;
+       break;
+    case 4:
+    case 5:
+    case 6:
+    case 7:
+       tp->theta -= angle_speed;
+       break;
+    case 8:
+    case 9:
+    case 10:
+    case 11:
+       tp->phi -= angle_speed;
+       break;
+    case 12:
+    case 13:
+    case 14:
+    case 15:
+       tp->phi += angle_speed;
+
+    case 16:
+    case 17:
+       if (camera_dist / 1.05 > ref_camera_dist)
+           camera_dist /= 1.05;
+       break;
+    case 18:
+    case 19:
+       if (camera_dist * 1.05 < (ref_camera_dist * 2.0))
+           camera_dist *= 1.05;
+       break;
+    case 20:
+       if ((tp->extrusion - 5.0) > 25)
+           tp->extrusion -= 5.0;
+       break;
+    case 21:
+       if ((tp->extrusion + 5.0) < 75)
+           tp->extrusion += 5.0;
+       break;
+    case 22:
+    case 23:
+       tp->rampl /= 1.15;
+       break;
+    case 24:
+    case 25:
+       tp->rampl *= 1.15;
+       break;
+    case 26:
+    case 27:
+       tp->rfreq *= 1.15;
+       break;
+    case 28:
+    case 29:
+       tp->rfreq /= 1.15;
+       break;
+    }
+#else                          /* !FUNNY_ANIMATE */
+    const double angle_speed = 2.5 / 180.0 * M_PI;
+
+    tp->phi -= angle_speed;
+    tp->theta -= angle_speed;
+#endif
+}
+
+/*-------------------------------------------------------------*/
+static void
+ Draw(text3dstruct * tp,
+      Display * display,
+      Window window)
+{
+    int text_length;
+    char *c_text;
+
+    if (!nosplit)
+    {
+       text_length = index_dir(tp->words, " ");
+       if (text_length == 0)
+           text_length = strlen(tp->words);
+       c_text = (char *) malloc(text_length);
+       strncpy(c_text, tp->words, text_length);
+    }
+    else
+    {
+       c_text = tp->words_start;
+       text_length = strlen(tp->words_start);
+    }
+    GLTTFont font(tp->face);
+
+    if (!font.create(DEF_FONTSIZE))
+       return;
+
+    FTGlyphVectorizer *vec = new FTGlyphVectorizer[text_length];
+    GLTTGlyphTriangles **tri = new GLTTGlyphTriangles *[text_length];
+
+    int i;
+
+    for (i = 0; i < text_length; ++i)
+       tri[i] = new GLTTGlyphTriangles(vec + i);
+
+    if (camera_dist == 0.0)
+       /* PURIFY reports an Array Bounds Read on the next line */
+       ref_camera_dist = camera_dist = font.getWidth(c_text) * 0.55;
+    double min_y = 1e20;
+    double max_y = -1e20;
+    double size_x = 0.0;
+
+    for (i = 0; i < text_length; ++i)
+    {
+       int ch = (unsigned char) c_text[i];
+
+#if ((MESA_MAJOR_VERSION > 3 ) || (( MESA_MAJOR_VERSION == 3 ) && (MESA_MINOR_VERSION > 0 )))
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+       glPixelStorei(GL_UNPACK_SWAP_BYTES, GL_FALSE);
+       glPixelStorei(GL_UNPACK_LSB_FIRST, GL_FALSE);
+       glPixelStorei(GL_UNPACK_SKIP_ROWS, 0);
+       glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0);
+       glPixelStorei(GL_UNPACK_ROW_LENGTH, 0);
+#endif
+
+       FTGlyph *g = font.getFont()->getGlyph(ch);
+
+       if (g == 0)
+           continue;
+       FTGlyphVectorizer & v = vec[i];
+       v.setPrecision(10.0);
+       if (!v.init(g))
+           continue;
+
+       size_x += v.getAdvance();
+
+       if (!v.vectorize())
+           continue;
+
+       for (int c = 0; c < v.getNContours(); ++c)
+       {
+           FTGlyphVectorizer::Contour * contour = v.getContour(c);
+           if (contour == 0)
+               continue;
+           for (int j = 0; j < contour->nPoints; ++j)
+           {
+               FTGlyphVectorizer::POINT * point = contour->points + j;
+               if (point->y < min_y)
+                   min_y = point->y;
+               if (point->y > max_y)
+                   max_y = point->y;
+               point->data = (void *) new double[6];
+           }
+       }
+       GLTTGlyphTriangles *t = tri[i];
+
+       if (!t->init(g))
+           continue;
+
+       t->count_them = GLTT_TRUE;
+       t->nTriangles = 0;
+       t->triangulate();
+
+       t->count_them = GLTT_FALSE;
+       t->alloc();
+       t->nTriangles = 0;
+       t->triangulate();
+    }
+
+    if (!nosplit)
+       free(c_text);
+    if (size_x == 0.0)
+    {
+       fprintf(stderr, "Please give something to draw !\n");
+       return;
+    }
+
+    double y_delta = (min_y + max_y) / 2. + min_y + 50;
+
+    for (i = 0; i < text_length; ++i)
+    {
+
+#if ((MESA_MAJOR_VERSION > 3 ) || (( MESA_MAJOR_VERSION == 3 ) && (MESA_MINOR_VERSION > 0 )))
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+       glPixelStorei(GL_UNPACK_SWAP_BYTES, GL_FALSE);
+       glPixelStorei(GL_UNPACK_LSB_FIRST, GL_FALSE);
+       glPixelStorei(GL_UNPACK_SKIP_ROWS, 0);
+       glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0);
+       glPixelStorei(GL_UNPACK_ROW_LENGTH, 0);
+#endif
+
+       FTGlyphVectorizer & v = vec[i];
+
+       for (int c = 0; c < v.getNContours(); ++c)
+       {
+           FTGlyphVectorizer::Contour * contour = v.getContour(c);
+           if (contour == 0)
+               continue;
+           for (int j = 0; j < contour->nPoints; ++j)
+           {
+               FTGlyphVectorizer::POINT * point = contour->points + j;
+               point->y -= y_delta;
+           }
+       }
+    }
+
+#define TWO_LIGHTS
+#define ALL_STUFF
+
+#ifdef ALL_STUFF
+    float front_emission[4] = {0.1, 0.1, 0.1, 0};
+    float front_ambient[4]  = {0.2, 0.2, 0.2, 0};
+    float front_diffuse[4]  = {0.95, 0.95, 0.8, 0};
+    float back_diffuse[4]   = {0.75, 0.75, 0.95, 0};
+    float front_specular[4] = {0.6, 0.6, 0.6, 0};
+
+    glMaterialfv(GL_FRONT, GL_EMISSION, front_emission);
+    glMaterialfv(GL_FRONT, GL_AMBIENT, front_ambient);
+    glMaterialfv(GL_FRONT, GL_DIFFUSE, front_diffuse);
+    glMaterialfv(GL_FRONT, GL_SPECULAR, front_specular);
+    glMaterialf(GL_FRONT, GL_SHININESS, 32.0);
+#ifdef TWO_LIGHTS
+    float light1_ambient[4]  = {0.3, 0.3, 0.3, 1};
+    float light1_diffuse[4]  = {0.9, 0.9, 0.9, 1};     /* A "white" light */
+    float light1_specular[4] = {0.7, 0.7, 0.7, 1};
+    float light1_position[4] = {-1, 1, 1, 0};
+
+    glLightfv(GL_LIGHT1, GL_AMBIENT, light1_ambient);
+    glLightfv(GL_LIGHT1, GL_DIFFUSE, light1_diffuse);
+    glLightfv(GL_LIGHT1, GL_SPECULAR, light1_specular);
+    glLightfv(GL_LIGHT1, GL_POSITION, light1_position);
+    glEnable(GL_LIGHT1);
+
+    float light2_ambient[4]  = {0.1, 0.1, 0.1, 1};
+    float light2_diffuse[4]  = {0.85, 0.3, 0.3, 1};    /* A "red" light */
+    float light2_specular[4] = {0.6, 0.6, 0.6, 1};
+    float light2_position[4] = {1, -1, -1, 0};
+
+    glLightfv(GL_LIGHT2, GL_AMBIENT, light2_ambient);
+    glLightfv(GL_LIGHT2, GL_DIFFUSE, light2_diffuse);
+    glLightfv(GL_LIGHT2, GL_SPECULAR, light2_specular);
+    glLightfv(GL_LIGHT2, GL_POSITION, light2_position);
+    glEnable(GL_LIGHT2);
+#else
+    GLfloat pos[4] = {-1.0, 1.0, 1.0, 0.0};
+
+    glLightfv(GL_LIGHT0, GL_POSITION, pos);
+    glEnable(GL_LIGHT0);
+#endif                         /* TWO_LIGHTS */
+
+    float back_color[4] = {0.2, 0.2, 0.6, 0};
+
+    glMaterialfv(GL_BACK, GL_DIFFUSE, back_color);
+    glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_FALSE);
+    glCullFace(GL_BACK);
+    glFrontFace(GL_CCW);
+    glEnable(GL_CULL_FACE);
+
+    glColorMaterial(GL_FRONT, GL_DIFFUSE);
+    glEnable(GL_COLOR_MATERIAL);
+#endif                         /* ALL_STUFF */
+
+    spheric_camera(tp, tp->center_x,
+                  tp->center_y + size_x / 2.,
+                  0,
+                  tp->phi, tp->theta + M_PI / 2, camera_dist);
+    glClearColor(0, 0, 0, 0);
+    glEnable(GL_DEPTH_TEST);
+    glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+    glMatrixMode(GL_MODELVIEW);
+    glPushMatrix();
+
+#ifdef ALL_STUFF
+    glEnable(GL_LIGHTING);
+    glShadeModel(GL_SMOOTH);
+    glEnable(GL_NORMALIZE);
+#endif
+
+    double base_x = 0.0;
+
+    for (i = 0; i < text_length; ++i)
+    {
+
+#if ((MESA_MAJOR_VERSION > 3 ) || (( MESA_MAJOR_VERSION == 3 ) && (MESA_MINOR_VERSION > 0 )))
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+       glPixelStorei(GL_UNPACK_SWAP_BYTES, GL_FALSE);
+       glPixelStorei(GL_UNPACK_LSB_FIRST, GL_FALSE);
+       glPixelStorei(GL_UNPACK_SKIP_ROWS, 0);
+       glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0);
+       glPixelStorei(GL_UNPACK_ROW_LENGTH, 0);
+#endif
+
+       FTGlyphVectorizer & v = vec[i];
+
+       int c;
+
+       for (c = 0; c < v.getNContours(); ++c)
+       {
+           FTGlyphVectorizer::Contour * contour = v.getContour(c);
+           if (contour == 0)
+               continue;
+
+           for (int j = 0; j < contour->nPoints; ++j)
+           {
+               FTGlyphVectorizer::POINT * point = contour->points + j;
+               double cx = -point->y;
+               double cy = base_x + point->x;
+               double phi = sin(cy * tp->rfreq) * tp->rampl * M_PI / 2.;
+               double rcx = cx * cos(phi);
+               double rcz = cx * sin(phi);
+
+               double *p = (double *) point->data;
+               double *n = p + 3;
+
+               p[0] = rcx;
+               p[1] = cy;
+               p[2] = rcz;
+
+               n[0] = -sin(phi);
+               n[1] = 0.;
+               n[2] = cos(phi);
+           }
+       }
+
+       GLTTGlyphTriangles::Triangle * triangles = tri[i]->triangles;
+       int nTriangles = tri[i]->nTriangles;
+
+       glBegin(GL_TRIANGLES);
+
+       for (int j = 0; j < nTriangles; ++j)
+       {
+           GLTTGlyphTriangles::Triangle & t = triangles[j];
+
+           double *p1 = ((double *) t.p1->data);
+           double *p2 = ((double *) t.p2->data);
+           double *p3 = ((double *) t.p3->data);
+           double *n1 = p1 + 3;
+           double *n2 = p2 + 3;
+           double *n3 = p3 + 3;
+
+#ifdef ALL_STUFF
+           glColor4fv(front_diffuse);
+#endif
+
+           glNormal3dv(n1);
+           glVertex3dv(p1);
+           glNormal3dv(n2);
+           glVertex3dv(p2);
+           glNormal3dv(n3);
+           glVertex3dv(p3);
+
+#ifdef ALL_STUFF
+           glColor4fv(back_diffuse);
+#endif
+
+           glNormal3d(-n3[0], 0., -n3[2]);
+           glVertex3d(p3[0] - n3[0] * tp->extrusion,
+                      p3[1],
+                      p3[2] - n3[2] * tp->extrusion);
+           glNormal3d(-n2[0], 0., -n2[2]);
+           glVertex3d(p2[0] - n2[0] * tp->extrusion,
+                      p2[1],
+                      p2[2] - n2[2] * tp->extrusion);
+           glNormal3d(-n1[0], 0., -n1[2]);
+           glVertex3d(p1[0] - n1[0] * tp->extrusion,
+                      p1[1],
+                      p1[2] - n1[2] * tp->extrusion);
+       }
+       glEnd();
+
+       for (c = 0; c < v.getNContours(); ++c)
+       {
+           FTGlyphVectorizer::Contour * contour = v.getContour(c);
+           if (contour == 0)
+               continue;
+           glBegin(GL_QUAD_STRIP);
+           for (int j = 0; j <= contour->nPoints; ++j)
+           {
+               int j1 = (j < contour->nPoints) ? j : 0;
+               int j0 = (j1 == 0) ? (contour->nPoints - 1) : (j1 - 1);
+
+               FTGlyphVectorizer::POINT * point0 = contour->points + j0;
+               FTGlyphVectorizer::POINT * point1 = contour->points + j1;
+               double *p0 = (double *) point0->data;
+               double *p1 = (double *) point1->data;
+               double *e = p0 + 3;
+               double vx = p1[0] - p0[0];
+               double vy = p1[1] - p0[1];
+               double vz = p1[2] - p0[2];
+               double nx = -vy * e[2];
+               double ny = e[2] * vx - vz * e[0];
+               double nz = e[0] * vy;
+#ifdef DIFFUSE_COLOR
+               double u = double ((j * 2) % contour->nPoints) / double (contour->nPoints);
+               double r, g, b;
+
+               hsv_to_rgb(u, 0.7, 0.7, &r, &g, &b);
+               glColor4f(r, g, b, 1);  // diffuse color of material
+#else
+               GLfloat blue[4] = {0.35, 0.35, 1.0, 1.0};
+               glColor4fv(blue);
+#endif
+
+               glNormal3f(nx, ny, nz);
+               glVertex3f(p0[0] - e[0] * tp->extrusion,
+                          p0[1],
+                          p0[2] - e[2] * tp->extrusion);
+               glNormal3f(nx, ny, nz);
+               glVertex3f(p0[0], p0[1], p0[2]);
+           }
+           glEnd();
+       }
+
+       base_x += v.getAdvance();
+    }
+
+#ifdef ALL_STUFF
+    glDisable(GL_NORMALIZE);
+    glDisable(GL_LIGHTING);
+    glShadeModel(GL_FLAT);
+#endif
+    glPopMatrix();
+
+    glXSwapBuffers(display, window);
+
+    for (i = 0; i < text_length; ++i)
+    {
+
+#if ((MESA_MAJOR_VERSION > 3 ) || (( MESA_MAJOR_VERSION == 3 ) && (MESA_MINOR_VERSION > 0 )))
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+       glPixelStorei(GL_UNPACK_SWAP_BYTES, GL_FALSE);
+       glPixelStorei(GL_UNPACK_LSB_FIRST, GL_FALSE);
+       glPixelStorei(GL_UNPACK_SKIP_ROWS, 0);
+       glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0);
+       glPixelStorei(GL_UNPACK_ROW_LENGTH, 0);
+#endif
+
+       delete tri[i];
+
+       FTGlyphVectorizer & v = vec[i];
+       for (int c = 0; c < v.getNContours(); ++c)
+       {
+           FTGlyphVectorizer::Contour * contour = v.getContour(c);
+           if (contour == 0)
+               continue;
+           for (int j = 0; j < contour->nPoints; ++j)
+           {
+               FTGlyphVectorizer::POINT * point = contour->points + j;
+               delete[]point->data;
+               point->data = 0;
+           }
+       }
+    }
+
+    delete[]tri;
+    delete[]vec;
+}
+
+/*
+ *-----------------------------------------------------------------------------
+ *-----------------------------------------------------------------------------
+ *    Xlock hooks.
+ *-----------------------------------------------------------------------------
+ *-----------------------------------------------------------------------------
+ */
+
+/*
+ *-----------------------------------------------------------------------------
+ *    Initialize text3d.  Called each time the window changes.
+ *-----------------------------------------------------------------------------
+ */
+
+void
+ init_text3d(ModeInfo * mi)
+{
+    int screen = MI_SCREEN(mi);
+    text3dstruct *tp;
+    Display *display = MI_DISPLAY(mi);
+    Window window = MI_WINDOW(mi);
+    char *fontfile = (char *) NULL;
+
+    if (text3d == NULL)
+    {
+       if ((text3d = (text3dstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof(text3dstruct))) == NULL)
+           return;
+    }
+    tp = &text3d[screen];
+    tp->wire = MI_IS_WIREFRAME(mi);
+    tp->extrusion = extrusion;
+    tp->rampl = rampl;
+    tp->rfreq = rfreq;
+
+    /* Get fontfile from mode_font (it can be a dir name) */
+    if (mode_font && strlen(mode_font))
+    {
+       fontfile = (char *) malloc(256);
+       (void) strncpy(fontfile, mode_font, 256);
+#if HAVE_DIRENT_H
+       getRandomFontFile(mode_font, fontfile);
+#endif
+    }
+
+    /* Check if fontfile exists */
+    if (!fontfile || !strlen(fontfile) || (fontfile && !readable(fontfile)))
+    {
+       (void) fprintf(stderr,
+                      "%s: could not read file \"%s\" !\n",
+                      MI_NAME(mi), fontfile);
+       (void) free((void *) text3d);
+       text3d = (text3dstruct *) NULL;
+#ifdef USE_BLANK
+       (void) fprintf(stderr,
+                      "%s: jumping to 'blank' mode.\n", MI_NAME(mi));
+       init_blank(mi);
+#endif
+       return;
+    }
+
+    tp->face = new FTFace;
+    if (!tp->face->open(fontfile))
+    {
+       fprintf(stderr, "%s: unable to open True Type font %s !\n", MI_NAME(mi), fontfile);
+       delete tp->face;
+
+       (void) free((void *) text3d);
+       text3d = (text3dstruct *) NULL;
+#ifdef USE_BLANK
+       (void) fprintf(stderr,
+                      "%s: jumping to 'blank' mode.\n", MI_NAME(mi));
+       init_blank(mi);
+#endif
+       return;
+    }
+    if (MI_IS_DEBUG(mi))
+    {
+       (void) fprintf(stderr,
+                      "%s:\n\tfontfile=%s .\n", MI_NAME(mi), fontfile);
+    }
+    free(fontfile);
+
+    tp->words_start = tp->words =
+       text3d_newstr(getWords(MI_SCREEN(mi), MI_NUM_SCREENS(mi)));
+    tp->counter = 0;
+
+    if ((tp->glx_context = init_GL(mi)) != NULL)
+    {
+
+       Reshape(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+       /*glDrawBuffer(GL_BACK); */
+       if (MI_IS_DEBUG(mi))
+       {
+           (void) fprintf(stderr,
+                          "%s:\n\tcamera_dist=%.1f\n\ttheta=%.1f\n\tphi=%.1f\n\textrusion=%.1f\n\trampl=%.1f.\n",
+                          MI_NAME(mi), camera_dist, tp->theta, tp->phi,
+                          tp->extrusion, tp->rampl);
+       }
+/*
+       glXSwapBuffers(display, window);
+*/
+
+    }
+    else
+    {
+       MI_CLEARWINDOW(mi);
+    }
+}
+
+/*
+ *-----------------------------------------------------------------------------
+ *    Called by the mainline code periodically to update the display.
+ *-----------------------------------------------------------------------------
+ */
+void
+ draw_text3d(ModeInfo * mi)
+{
+    text3dstruct *tp = (text3dstruct *) NULL;
+
+    Display *display = MI_DISPLAY(mi);
+    Window window = MI_WINDOW(mi);
+
+    MI_IS_DRAWN(mi) = True;
+
+    if (text3d)
+       tp = &text3d[MI_SCREEN(mi)];
+#ifdef USE_BLANK
+    if (!tp)
+    {
+       draw_blank(mi);
+       return;
+    }
+#else
+    if (!tp || !tp->glx_context)
+       return;
+#endif
+    tp->counter = tp->counter + 1;
+    if (tp->counter > MI_CYCLES(mi) & !nosplit)
+    {
+       int text_length = index_dir(tp->words, " ");
+
+       /* Every now and then, get a new word */
+       if (text_length == 0)
+           text_length = strlen(tp->words);
+       tp->counter = 0;
+       tp->words += text_length;
+       text_length = strlen(tp->words);
+       if (text_length == 0)
+       {
+           (void) free((void *) tp->words_start);
+           tp->words_start = tp->words =
+               text3d_newstr(getWords(MI_SCREEN(mi),
+                                      MI_NUM_SCREENS(mi)));
+       }
+    }
+    glXMakeCurrent(display, window, *(tp->glx_context));
+
+    glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+    glPushMatrix();
+
+    Draw(tp, display, window);
+    Animate(tp);
+    if (MI_IS_DEBUG(mi))
+    {
+       (void) fprintf(stderr,
+                      "%s:\n\tcamera_dist=%.1f\n\ttheta=%.1f\n\tphi=%.1f\n\textrusion=%.1f\n\trampl=%.1f\n",
+                      MI_NAME(mi), camera_dist, tp->theta, tp->phi,
+                      tp->extrusion, tp->rampl);
+    }
+
+/*
+    glXSwapBuffers(display, window);
+*/
+}
+
+/*
+ *-----------------------------------------------------------------------------
+ *    The display is being taken away from us.  Free up malloc'ed 
+ *      memory and X resources that we've alloc'ed.  Only called
+ *      once, we must zap everything for every screen.
+ *-----------------------------------------------------------------------------
+ */
+
+void
+ release_text3d(ModeInfo * mi)
+{
+    int screen;
+
+    if (text3d != NULL)
+    {
+       for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++)
+       {
+           text3dstruct *tp = &text3d[screen];
+
+           if (tp->face)
+               delete tp->face;
+       }
+       (void) free((void *) text3d);
+       text3d = (text3dstruct *) NULL;
+    }
+#ifdef USE_BLANK
+    else
+       release_blank(mi);
+#endif
+    FreeAllGL(mi);
+}
+
+void
+ refresh_text3d(ModeInfo * mi)
+{
+    /* Do nothing, it will refresh by itself :) */
+}
+
+void
+ change_text3d(ModeInfo * mi)
+{
+    text3dstruct *tp = (text3dstruct *) NULL;
+
+    if (text3d)
+       tp = &text3d[MI_SCREEN(mi)];
+
+#ifdef USE_BLANK
+    if (!tp)
+    {
+       refresh_blank(mi);
+       return;
+    }
+#else
+    if (!tp || !tp->glx_context)
+       return;
+#endif
+
+    glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(tp->glx_context));
+}
+
+#endif                         /* MODE_text3d */
diff --git a/xlockmore-4.14/modes/glx/text3d.h b/xlockmore-4.14/modes/glx/text3d.h
new file mode 100644 (file)
index 0000000..8baaa0c
--- /dev/null
@@ -0,0 +1,41 @@
+/* text3d --- Shows moving 3D texts */
+
+/* Copyright (c) E. Lassauge, 1998. */
+
+/*
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * My e-mail address is lassauge@sagem.fr
+ *
+ * Eric Lassauge  (August-18-1998)
+ *
+ */
+
+extern      "C" {
+#include <GL/gl.h>
+#include <GL/glx.h>
+} typedef struct {
+
+       /* global Parameters */
+       int         wire, counter;
+       float       extrusion;
+       float       rampl;
+       float       rfreq;
+       char       *words, *words_start;
+       /* per Screen variables */
+       GLint       WinH, WinW;
+       GLXContext *glx_context;
+       FTFace     *face;
+       float       center_x, center_y, center_z;
+       float       phi, theta, radius;
+} text3dstruct;
diff --git a/xlockmore-4.14/modes/glx/whale.c b/xlockmore-4.14/modes/glx/whale.c
new file mode 100644 (file)
index 0000000..31bbf46
--- /dev/null
@@ -0,0 +1,1894 @@
+/* atlantis --- Shows moving 3D sea animals */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)whale.c      1.3 98/06/18 xlockmore";
+
+#endif
+
+/* Copyright (c) E. Lassauge, 1998. */
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The original code for this mode was written by Mark J. Kilgard
+ * as a demo for openGL programming.
+ * 
+ * Porting it to xlock  was possible by comparing the original Mesa's morph3d 
+ * demo with it's ported version to xlock, so thanks for Marcelo F. Vianna 
+ * (look at morph3d.c) for his indirect help.
+ *
+ * Thanks goes also to Brian Paul for making it possible and inexpensive
+ * to use OpenGL at home.
+ *
+ * My e-mail address is lassauge@sagem.fr
+ *
+ * Eric Lassauge  (May-13-1998)
+ *
+ */
+
+/*-
+ * (c) Copyright 1993, 1994, Silicon Graphics, Inc.
+ * ALL RIGHTS RESERVED
+ * Permission to use, copy, modify, and distribute this software for
+ * any purpose and without fee is hereby granted, provided that the above
+ * copyright notice appear in all copies and that both the copyright notice
+ * and this permission notice appear in supporting documentation, and that
+ * the name of Silicon Graphics, Inc. not be used in advertising
+ * or publicity pertaining to distribution of the software without specific,
+ * written prior permission.
+ *
+ * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
+ * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
+ * FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
+ * GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
+ * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
+ * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
+ * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
+ * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
+ * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
+ * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * US Government Users Restricted Rights
+ * Use, duplication, or disclosure by the Government is subject to
+ * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
+ * (c)(1)(ii) of the Rights in Technical Data and Computer Software
+ * clause at DFARS 252.227-7013 and/or in similar or successor
+ * clauses in the FAR or the DOD or NASA FAR Supplement.
+ * Unpublished-- rights reserved under the copyright laws of the
+ * United States.  Contractor/manufacturer is Silicon Graphics,
+ * Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
+ *
+ * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
+ */
+#ifndef STANDALONE
+#include "xlock.h"
+#endif
+
+#ifdef MODE_atlantis
+
+#ifdef STANDALONE
+#include <GL/glx.h>
+#endif
+
+#include "atlantis.h"
+/* *INDENT-OFF* */
+static float N001[3] = {0.019249 ,0.011340 ,-0.999750};
+static float N002[3] = {-0.132579 ,0.954547 ,0.266952};
+static float N003[3] = {-0.196061 ,0.980392 ,-0.019778};
+static float N004[3] = {0.695461 ,0.604704 ,0.388158};
+static float N005[3] = {0.870600 ,0.425754 ,0.246557};
+static float N006[3] = {-0.881191 ,0.392012 ,0.264251};
+#if 0
+static float N007[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N008[3] = {-0.341437 ,0.887477 ,0.309523};
+static float N009[3] = {0.124035 ,-0.992278 ,0.000000};
+static float N010[3] = {0.242536 ,0.000000 ,-0.970143};
+static float N011[3] = {0.588172 ,0.000000 ,0.808736};
+static float N012[3] = {0.929824 ,-0.340623 ,-0.139298};
+static float N013[3] = {0.954183 ,0.267108 ,-0.134865};
+static float N014[3] = {0.495127 ,0.855436 ,-0.151914};
+static float N015[3] = {-0.390199 ,0.906569 ,-0.160867};
+static float N016[3] = {-0.923605 ,0.354581 ,-0.145692};
+static float N017[3] = {-0.955796 ,-0.260667 ,-0.136036};
+static float N018[3] = {-0.501283 ,-0.853462 ,-0.142540};
+static float N019[3] = {0.405300 ,-0.901974 ,-0.148913};
+static float N020[3] = {0.909913 ,-0.392746 ,-0.133451};
+static float N021[3] = {0.936494 ,0.331147 ,-0.115414};
+static float N022[3] = {0.600131 ,0.793724 ,-0.099222};
+static float N023[3] = {-0.231556 ,0.968361 ,-0.093053};
+static float N024[3] = {-0.844369 ,0.525330 ,-0.105211};
+static float N025[3] = {-0.982725 ,-0.136329 ,-0.125164};
+static float N026[3] = {-0.560844 ,-0.822654 ,-0.093241};
+static float N027[3] = {0.263884 ,-0.959981 ,-0.093817};
+static float N028[3] = {0.842057 ,-0.525192 ,-0.122938};
+static float N029[3] = {0.921620 ,0.367565 ,-0.124546};
+static float N030[3] = {0.613927 ,0.784109 ,-0.090918};
+static float N031[3] = {-0.448754 ,0.888261 ,-0.098037};
+static float N032[3] = {-0.891865 ,0.434376 ,-0.126077};
+static float N033[3] = {-0.881447 ,-0.448017 ,-0.149437};
+static float N034[3] = {-0.345647 ,-0.922057 ,-0.174183};
+static float N035[3] = {0.307998 ,-0.941371 ,-0.137688};
+static float N036[3] = {0.806316 ,-0.574647 ,-0.140124};
+static float N037[3] = {0.961346 ,0.233646 ,-0.145681};
+static float N038[3] = {0.488451 ,0.865586 ,-0.110351};
+static float N039[3] = {-0.374290 ,0.921953 ,-0.099553};
+static float N040[3] = {-0.928504 ,0.344533 ,-0.138485};
+static float N041[3] = {-0.918419 ,-0.371792 ,-0.135189};
+static float N042[3] = {-0.520666 ,-0.833704 ,-0.183968};
+static float N043[3] = {0.339204 ,-0.920273 ,-0.195036};
+static float N044[3] = {0.921475 ,-0.387382 ,-0.028636};
+static float N045[3] = {0.842465 ,0.533335 ,-0.076204};
+static float N046[3] = {0.380110 ,0.924939 ,0.002073};
+static float N047[3] = {-0.276128 ,0.961073 ,-0.009579};
+static float N048[3] = {-0.879684 ,0.473001 ,-0.049250};
+static float N049[3] = {-0.947184 ,-0.317614 ,-0.044321};
+static float N050[3] = {-0.642059 ,-0.764933 ,-0.051363};
+static float N051[3] = {0.466794 ,-0.880921 ,-0.077990};
+static float N052[3] = {0.898509 ,-0.432277 ,0.076279};
+static float N053[3] = {0.938985 ,0.328141 ,0.103109};
+static float N054[3] = {0.442420 ,0.895745 ,0.043647};
+static float N055[3] = {-0.255163 ,0.966723 ,0.018407};
+static float N056[3] = {-0.833769 ,0.540650 ,0.111924};
+static float N057[3] = {-0.953653 ,-0.289939 ,0.080507};
+static float N058[3] = {-0.672357 ,-0.730524 ,0.119461};
+static float N059[3] = {0.522249 ,-0.846652 ,0.102157};
+static float N060[3] = {0.885868 ,-0.427631 ,0.179914};
+#if 0
+static float N061[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N062[3] = {0.648942 ,0.743116 ,0.163255};
+static float N063[3] = {-0.578967 ,0.807730 ,0.111219};
+#if 0
+static float N064[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float N065[3] = {-0.909864 ,-0.352202 ,0.219321};
+static float N066[3] = {-0.502541 ,-0.818090 ,0.279610};
+static float N067[3] = {0.322919 ,-0.915358 ,0.240504};
+static float N068[3] = {0.242536 ,0.000000 ,-0.970143};
+static float N069[3] = {0.000000 ,1.000000 ,0.000000};
+static float N070[3] = {0.000000 ,1.000000 ,0.000000};
+static float N071[3] = {0.000000 ,1.000000 ,0.000000};
+static float N072[3] = {0.000000 ,1.000000 ,0.000000};
+static float N073[3] = {0.000000 ,1.000000 ,0.000000};
+static float N074[3] = {0.000000 ,1.000000 ,0.000000};
+static float N075[3] = {0.031220 ,0.999025 ,-0.031220};
+static float N076[3] = {0.000000 ,1.000000 ,0.000000};
+static float N077[3] = {0.446821 ,0.893642 ,0.041889};
+static float N078[3] = {0.863035 ,-0.100980 ,0.494949};
+static float N079[3] = {0.585597 ,-0.808215 ,0.062174};
+static float N080[3] = {0.000000 ,1.000000 ,0.000000};
+static float N081[3] = {1.000000 ,0.000000 ,0.000000};
+static float N082[3] = {0.000000 ,1.000000 ,0.000000};
+static float N083[3] = {-1.000000 ,0.000000 ,0.000000};
+static float N084[3] = {-0.478893 ,0.837129 ,-0.264343};
+static float N085[3] = {0.000000 ,1.000000 ,0.000000};
+static float N086[3] = {0.763909 ,0.539455 ,-0.354163};
+static float N087[3] = {0.446821 ,0.893642 ,0.041889};
+static float N088[3] = {0.385134 ,-0.908288 ,0.163352};
+static float N089[3] = {-0.605952 ,0.779253 ,-0.159961};
+static float N090[3] = {0.000000 ,1.000000 ,0.000000};
+static float N091[3] = {0.000000 ,1.000000 ,0.000000};
+static float N092[3] = {0.000000 ,1.000000 ,0.000000};
+static float N093[3] = {0.000000 ,1.000000 ,0.000000};
+static float N094[3] = {1.000000 ,0.000000 ,0.000000};
+static float N095[3] = {-1.000000 ,0.000000 ,0.000000};
+static float N096[3] = {0.644444 ,-0.621516 ,0.445433};
+static float N097[3] = {-0.760896 ,-0.474416 ,0.442681};
+static float N098[3] = {0.636888 ,-0.464314 ,0.615456};
+static float N099[3] = {-0.710295 ,0.647038 ,0.277168};
+static float N100[3] = {0.009604 ,0.993655 ,0.112063};
+#if 0
+static float N101[3] = {0.000000 ,1.000000 ,0.000000};
+static float N102[3] = {0.000000 ,1.000000 ,0.000000};
+static float N103[3] = {0.000000 ,1.000000 ,0.000000};
+static float N104[3] = {0.031837 ,0.999285 ,0.020415};
+static float N105[3] = {0.031837 ,0.999285 ,0.020415};
+static float N106[3] = {0.031837 ,0.999285 ,0.020415};
+static float N107[3] = {0.014647 ,0.999648 ,0.022115};
+static float N108[3] = {0.014647 ,0.999648 ,0.022115};
+static float N109[3] = {0.014647 ,0.999648 ,0.022115};
+static float N110[3] = {-0.985141 ,0.039475 ,0.167149};
+static float N111[3] = {-0.985141 ,0.039475 ,0.167149};
+static float N112[3] = {-0.985141 ,0.039475 ,0.167149};
+static float N113[3] = {0.000000 ,1.000000 ,0.000000};
+static float N114[3] = {0.000000 ,1.000000 ,0.000000};
+static float N115[3] = {0.000000 ,1.000000 ,0.000000};
+static float N116[3] = {0.000000 ,1.000000 ,0.000000};
+static float N117[3] = {0.000000 ,1.000000 ,0.000000};
+static float N118[3] = {0.000000 ,1.000000 ,0.000000};
+static float N119[3] = {0.000000 ,1.000000 ,0.000000};
+static float N120[3] = {0.000000 ,1.000000 ,0.000000};
+static float N121[3] = {0.000000 ,1.000000 ,0.000000};
+#endif
+static float iP001[3] = {18.74, 13.19, 3.76};
+static float P001[3] = {18.74, 13.19, 3.76};
+static float P002[3] = {0.00, 390.42, 10292.57};
+static float P003[3] = {55.80, 622.31, 8254.35};
+static float P004[3] = {20.80, 247.66, 10652.13};
+static float P005[3] = {487.51, 198.05, 9350.78};
+static float P006[3] = {-457.61, 199.04, 9353.01};
+#if 0
+static float P007[3] = {0.00, 259.00, 10276.27};
+#endif
+static float P008[3] = {-34.67, 247.64, 10663.71};
+static float iP009[3] = {97.46, 67.63, 593.82};
+static float iP010[3] = {-84.33, 67.63, 588.18};
+static float iP011[3] = {118.69, 8.98, -66.91};
+static float P009[3] = {97.46, 67.63, 593.82};
+static float P010[3] = {-84.33, 67.63, 588.18};
+static float P011[3] = {118.69, 8.98, -66.91};
+static float iP012[3] = {156.48, -31.95, 924.54};
+static float iP013[3] = {162.00, 110.22, 924.54};
+static float iP014[3] = {88.16, 221.65, 924.54};
+static float iP015[3] = {-65.21, 231.16, 924.54};
+static float iP016[3] = {-156.48, 121.97, 924.54};
+static float iP017[3] = {-162.00, -23.93, 924.54};
+static float iP018[3] = {-88.16, -139.10, 924.54};
+static float iP019[3] = {65.21, -148.61, 924.54};
+static float iP020[3] = {246.87, -98.73, 1783.04};
+static float iP021[3] = {253.17, 127.76, 1783.04};
+static float iP022[3] = {132.34, 270.77, 1783.04};
+static float iP023[3] = {-97.88, 285.04, 1783.04};
+static float iP024[3] = {-222.97, 139.80, 1783.04};
+static float iP025[3] = {-225.29, -86.68, 1783.04};
+static float iP026[3] = {-108.44, -224.15, 1783.04};
+static float iP027[3] = {97.88, -221.56, 1783.04};
+static float iP028[3] = {410.55, -200.66, 3213.87};
+static float iP029[3] = {432.19, 148.42, 3213.87};
+static float iP030[3] = {200.66, 410.55, 3213.87};
+static float iP031[3] = {-148.42, 432.19, 3213.87};
+static float iP032[3] = {-407.48, 171.88, 3213.87};
+static float iP033[3] = {-432.19, -148.42, 3213.87};
+static float iP034[3] = {-148.88, -309.74, 3213.87};
+static float iP035[3] = {156.38, -320.17, 3213.87};
+static float iP036[3] = {523.39, -303.81, 4424.57};
+static float iP037[3] = {574.66, 276.84, 4424.57};
+static float iP038[3] = {243.05, 492.50, 4424.57};
+static float iP039[3] = {-191.23, 520.13, 4424.57};
+static float iP040[3] = {-523.39, 304.01, 4424.57};
+static float iP041[3] = {-574.66, -231.83, 4424.57};
+static float iP042[3] = {-266.95, -578.17, 4424.57};
+static float iP043[3] = {211.14, -579.67, 4424.57};
+static float iP044[3] = {680.57, -370.27, 5943.46};
+static float iP045[3] = {834.01, 363.09, 5943.46};
+static float iP046[3] = {371.29, 614.13, 5943.46};
+static float iP047[3] = {-291.43, 621.86, 5943.46};
+static float iP048[3] = {-784.13, 362.60, 5943.46};
+static float iP049[3] = {-743.29, -325.82, 5943.46};
+static float iP050[3] = {-383.24, -804.77, 5943.46};
+static float iP051[3] = {283.47, -846.09, 5943.46};
+static float P012[3] = {156.48, -31.95, 924.54};
+static float P013[3] = {162.00, 110.22, 924.54};
+static float P014[3] = {88.16, 221.65, 924.54};
+static float P015[3] = {-65.21, 231.16, 924.54};
+static float P016[3] = {-156.48, 121.97, 924.54};
+static float P017[3] = {-162.00, -23.93, 924.54};
+static float P018[3] = {-88.16, -139.10, 924.54};
+static float P019[3] = {65.21, -148.61, 924.54};
+static float P020[3] = {246.87, -98.73, 1783.04};
+static float P021[3] = {253.17, 127.76, 1783.04};
+static float P022[3] = {132.34, 270.77, 1783.04};
+static float P023[3] = {-97.88, 285.04, 1783.04};
+static float P024[3] = {-222.97, 139.80, 1783.04};
+static float P025[3] = {-225.29, -86.68, 1783.04};
+static float P026[3] = {-108.44, -224.15, 1783.04};
+static float P027[3] = {97.88, -221.56, 1783.04};
+static float P028[3] = {410.55, -200.66, 3213.87};
+static float P029[3] = {432.19, 148.42, 3213.87};
+static float P030[3] = {200.66, 410.55, 3213.87};
+static float P031[3] = {-148.42, 432.19, 3213.87};
+static float P032[3] = {-407.48, 171.88, 3213.87};
+static float P033[3] = {-432.19, -148.42, 3213.87};
+static float P034[3] = {-148.88, -309.74, 3213.87};
+static float P035[3] = {156.38, -320.17, 3213.87};
+static float P036[3] = {523.39, -303.81, 4424.57};
+static float P037[3] = {574.66, 276.84, 4424.57};
+static float P038[3] = {243.05, 492.50, 4424.57};
+static float P039[3] = {-191.23, 520.13, 4424.57};
+static float P040[3] = {-523.39, 304.01, 4424.57};
+static float P041[3] = {-574.66, -231.83, 4424.57};
+static float P042[3] = {-266.95, -578.17, 4424.57};
+static float P043[3] = {211.14, -579.67, 4424.57};
+static float P044[3] = {680.57, -370.27, 5943.46};
+static float P045[3] = {834.01, 363.09, 5943.46};
+static float P046[3] = {371.29, 614.13, 5943.46};
+static float P047[3] = {-291.43, 621.86, 5943.46};
+static float P048[3] = {-784.13, 362.60, 5943.46};
+static float P049[3] = {-743.29, -325.82, 5943.46};
+static float P050[3] = {-383.24, -804.77, 5943.46};
+static float P051[3] = {283.47, -846.09, 5943.46};
+static float P052[3] = {599.09, -332.24, 7902.59};
+static float P053[3] = {735.48, 306.26, 7911.92};
+static float P054[3] = {321.55, 558.53, 7902.59};
+static float P055[3] = {-260.54, 559.84, 7902.59};
+static float P056[3] = {-698.66, 320.83, 7902.59};
+static float P057[3] = {-643.29, -299.16, 7902.59};
+static float P058[3] = {-341.47, -719.30, 7902.59};
+static float P059[3] = {252.57, -756.12, 7902.59};
+static float P060[3] = {458.39, -265.31, 9355.44};
+static float iP061[3] = {353.63, 138.70, 10214.20};
+static float P061[3] = {353.63, 138.70, 10214.20};
+static float P062[3] = {224.04, 438.98, 9364.77};
+static float P063[3] = {-165.71, 441.27, 9355.44};
+static float iP064[3] = {-326.40, 162.04, 10209.54};
+static float P064[3] = {-326.40, 162.04, 10209.54};
+static float P065[3] = {-473.99, -219.71, 9355.44};
+static float P066[3] = {-211.97, -479.87, 9355.44};
+static float P067[3] = {192.86, -504.03, 9355.44};
+static float iP068[3] = {-112.44, 9.25, -64.42};
+static float iP069[3] = {1155.63, 0.00, -182.46};
+static float iP070[3] = {-1143.13, 0.00, -181.54};
+static float iP071[3] = {1424.23, 0.00, -322.09};
+static float iP072[3] = {-1368.01, 0.00, -310.38};
+static float iP073[3] = {1255.57, 2.31, 114.05};
+static float iP074[3] = {-1149.38, 0.00, 117.12};
+static float iP075[3] = {718.36, 0.00, 433.36};
+static float iP076[3] = {-655.90, 0.00, 433.36};
+static float P068[3] = {-112.44, 9.25, -64.42};
+static float P069[3] = {1155.63, 0.00, -182.46};
+static float P070[3] = {-1143.13, 0.00, -181.54};
+static float P071[3] = {1424.23, 0.00, -322.09};
+static float P072[3] = {-1368.01, 0.00, -310.38};
+static float P073[3] = {1255.57, 2.31, 114.05};
+static float P074[3] = {-1149.38, 0.00, 117.12};
+static float P075[3] = {718.36, 0.00, 433.36};
+static float P076[3] = {-655.90, 0.00, 433.36};
+static float P077[3] = {1058.00, -2.66, 7923.51};
+static float P078[3] = {-1016.51, -15.47, 7902.87};
+static float P079[3] = {-1363.99, -484.50, 7593.38};
+static float P080[3] = {1478.09, -861.47, 7098.12};
+static float P081[3] = {1338.06, -284.68, 7024.15};
+static float P082[3] = {-1545.51, -860.64, 7106.60};
+static float P083[3] = {1063.19, -70.46, 7466.60};
+static float P084[3] = {-1369.18, -288.11, 7015.34};
+static float P085[3] = {1348.44, -482.50, 7591.41};
+static float P086[3] = {-1015.45, -96.80, 7474.86};
+static float P087[3] = {731.04, 148.38, 7682.58};
+static float P088[3] = {-697.03, 151.82, 7668.81};
+static float P089[3] = {-686.82, 157.09, 7922.29};
+static float P090[3] = {724.73, 147.75, 7931.39};
+static float iP091[3] = {0.00, 327.10, 2346.55};
+static float iP092[3] = {0.00, 552.28, 2311.31};
+static float iP093[3] = {0.00, 721.16, 2166.41};
+static float iP094[3] = {0.00, 693.42, 2388.80};
+static float iP095[3] = {0.00, 389.44, 2859.97};
+static float P091[3] = {0.00, 327.10, 2346.55};
+static float P092[3] = {0.00, 552.28, 2311.31};
+static float P093[3] = {0.00, 721.16, 2166.41};
+static float P094[3] = {0.00, 693.42, 2388.80};
+static float P095[3] = {0.00, 389.44, 2859.97};
+static float iP096[3] = {222.02, -183.67, 10266.89};
+static float iP097[3] = {-128.90, -182.70, 10266.89};
+static float iP098[3] = {41.04, 88.31, 10659.36};
+static float iP099[3] = {-48.73, 88.30, 10659.36};
+static float P096[3] = {222.02, -183.67, 10266.89};
+static float P097[3] = {-128.90, -182.70, 10266.89};
+static float P098[3] = {41.04, 88.31, 10659.36};
+static float P099[3] = {-48.73, 88.30, 10659.36};
+static float P100[3] = {0.00, 603.42, 9340.68};
+#if 0
+static float P101[3] = {5.70, 567.00, 7862.98};
+static float P102[3] = {521.61, 156.61, 9162.34};
+static float P103[3] = {83.68, 566.67, 7861.26};
+#endif
+static float P104[3] = {-9.86, 567.62, 7858.65};
+static float P105[3] = {31.96, 565.27, 7908.46};
+static float P106[3] = {22.75, 568.13, 7782.83};
+static float P107[3] = {58.93, 568.42, 7775.94};
+static float P108[3] = {55.91, 565.59, 7905.86};
+static float P109[3] = {99.21, 566.00, 7858.65};
+static float P110[3] = {-498.83, 148.14, 9135.10};
+static float P111[3] = {-495.46, 133.24, 9158.48};
+static float P112[3] = {-490.82, 146.23, 9182.76};
+static float P113[3] = {-489.55, 174.11, 9183.66};
+static float P114[3] = {-492.92, 189.00, 9160.28};
+static float P115[3] = {-497.56, 176.02, 9136.00};
+static float P116[3] = {526.54, 169.68, 9137.70};
+static float P117[3] = {523.49, 184.85, 9161.42};
+static float P118[3] = {518.56, 171.78, 9186.06};
+static float P119[3] = {516.68, 143.53, 9186.98};
+static float P120[3] = {519.73, 128.36, 9163.26};
+static float P121[3] = {524.66, 141.43, 9138.62};
+/* *INDENT-ON* */
+
+
+
+static void
+Whale001(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N068);
+       glVertex3fv(P068);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N068);
+       glVertex3fv(P068);
+       glNormal3fv(N076);
+       glVertex3fv(P076);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N068);
+       glVertex3fv(P068);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glNormal3fv(N076);
+       glVertex3fv(P076);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N076);
+       glVertex3fv(P076);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glNormal3fv(N074);
+       glVertex3fv(P074);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glNormal3fv(N072);
+       glVertex3fv(P072);
+       glNormal3fv(N074);
+       glVertex3fv(P074);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N072);
+       glVertex3fv(P072);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glNormal3fv(N074);
+       glVertex3fv(P074);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N074);
+       glVertex3fv(P074);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glNormal3fv(N076);
+       glVertex3fv(P076);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N070);
+       glVertex3fv(P070);
+       glNormal3fv(N068);
+       glVertex3fv(P068);
+       glNormal3fv(N076);
+       glVertex3fv(P076);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N076);
+       glVertex3fv(P076);
+       glNormal3fv(N068);
+       glVertex3fv(P068);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N068);
+       glVertex3fv(P068);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N010);
+       glVertex3fv(P010);
+       glEnd();
+}
+
+static void
+Whale002(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N075);
+       glVertex3fv(P075);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N075);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glNormal3fv(N075);
+       glVertex3fv(P075);
+       glNormal3fv(N073);
+       glVertex3fv(P073);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N071);
+       glVertex3fv(P071);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glNormal3fv(N073);
+       glVertex3fv(P073);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N009);
+       glVertex3fv(P009);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N075);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N011);
+       glVertex3fv(P011);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glNormal3fv(N075);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glNormal3fv(N073);
+       glVertex3fv(P073);
+       glNormal3fv(N075);
+       glVertex3fv(P075);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N069);
+       glVertex3fv(P069);
+       glNormal3fv(N071);
+       glVertex3fv(P071);
+       glNormal3fv(N073);
+       glVertex3fv(P073);
+       glEnd();
+}
+
+static void
+Whale003(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N001);
+       glVertex3fv(P001);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glEnd();
+}
+
+static void
+Whale004(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N015);
+       glVertex3fv(P015);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N016);
+       glVertex3fv(P016);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N017);
+       glVertex3fv(P017);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N014);
+       glVertex3fv(P014);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N013);
+       glVertex3fv(P013);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N018);
+       glVertex3fv(P018);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N019);
+       glVertex3fv(P019);
+       glNormal3fv(N012);
+       glVertex3fv(P012);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glEnd();
+}
+
+static void
+Whale005(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N022);
+       glVertex3fv(P022);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N023);
+       glVertex3fv(P023);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N024);
+       glVertex3fv(P024);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N021);
+       glVertex3fv(P021);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N020);
+       glVertex3fv(P020);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N025);
+       glVertex3fv(P025);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N026);
+       glVertex3fv(P026);
+       glNormal3fv(N027);
+       glVertex3fv(P027);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glEnd();
+}
+
+static void
+Whale006(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N093);
+       glVertex3fv(P093);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N093);
+       glVertex3fv(P093);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N091);
+       glVertex3fv(P091);
+       glNormal3fv(N095);
+       glVertex3fv(P095);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N091);
+       glVertex3fv(P091);
+       glNormal3fv(N092);
+       glVertex3fv(P092);
+       glNormal3fv(N094);
+       glVertex3fv(P094);
+       glNormal3fv(N095);
+       glVertex3fv(P095);
+       glEnd();
+}
+
+static void
+Whale007(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N030);
+       glVertex3fv(P030);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N029);
+       glVertex3fv(P029);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N028);
+       glVertex3fv(P028);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glNormal3fv(N035);
+       glVertex3fv(P035);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N034);
+       glVertex3fv(P034);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N031);
+       glVertex3fv(P031);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N032);
+       glVertex3fv(P032);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N033);
+       glVertex3fv(P033);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glEnd();
+}
+
+static void
+Whale008(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N043);
+       glVertex3fv(P043);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N042);
+       glVertex3fv(P042);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N036);
+       glVertex3fv(P036);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N041);
+       glVertex3fv(P041);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N040);
+       glVertex3fv(P040);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N037);
+       glVertex3fv(P037);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N038);
+       glVertex3fv(P038);
+       glNormal3fv(N039);
+       glVertex3fv(P039);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glEnd();
+}
+
+static void
+Whale009(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N051);
+       glVertex3fv(P051);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N044);
+       glVertex3fv(P044);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N050);
+       glVertex3fv(P050);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N049);
+       glVertex3fv(P049);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N048);
+       glVertex3fv(P048);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N045);
+       glVertex3fv(P045);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N046);
+       glVertex3fv(P046);
+       glNormal3fv(N047);
+       glVertex3fv(P047);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glEnd();
+}
+
+static void
+Whale010(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N080);
+       glVertex3fv(P080);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N090);
+       glVertex3fv(P090);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N080);
+       glVertex3fv(P080);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N081);
+       glVertex3fv(P081);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N085);
+       glVertex3fv(P085);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N083);
+       glVertex3fv(P083);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N087);
+       glVertex3fv(P087);
+       glNormal3fv(N077);
+       glVertex3fv(P077);
+       glNormal3fv(N090);
+       glVertex3fv(P090);
+       glEnd();
+}
+
+static void
+Whale011(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N082);
+       glVertex3fv(P082);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N088);
+       glVertex3fv(P088);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glNormal3fv(N088);
+       glVertex3fv(P088);
+       glNormal3fv(N089);
+       glVertex3fv(P089);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N088);
+       glVertex3fv(P088);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N089);
+       glVertex3fv(P089);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N089);
+       glVertex3fv(P089);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N086);
+       glVertex3fv(P086);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N078);
+       glVertex3fv(P078);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N084);
+       glVertex3fv(P084);
+       glNormal3fv(N082);
+       glVertex3fv(P082);
+       glNormal3fv(N079);
+       glVertex3fv(P079);
+       glEnd();
+}
+
+static void
+Whale012(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N059);
+       glVertex3fv(P059);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N058);
+       glVertex3fv(P058);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N057);
+       glVertex3fv(P057);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N056);
+       glVertex3fv(P056);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N053);
+       glVertex3fv(P053);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N052);
+       glVertex3fv(P052);
+       glEnd();
+}
+
+static void
+Whale013(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glNormal3fv(N096);
+       glVertex3fv(P096);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glNormal3fv(N096);
+       glVertex3fv(P096);
+       glNormal3fv(N098);
+       glVertex3fv(P098);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N066);
+       glVertex3fv(P066);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N067);
+       glVertex3fv(P067);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N096);
+       glVertex3fv(P096);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N060);
+       glVertex3fv(P060);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N096);
+       glVertex3fv(P096);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N096);
+       glVertex3fv(P096);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glNormal3fv(N098);
+       glVertex3fv(P098);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N065);
+       glVertex3fv(P065);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N097);
+       glVertex3fv(P097);
+       glNormal3fv(N099);
+       glVertex3fv(P099);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P005);
+       glVertex3fv(P006);
+       glVertex3fv(P099);
+       glVertex3fv(P098);
+       glEnd();
+}
+
+static void
+Whale014(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N004);
+       glVertex3fv(P004);
+       glNormal3fv(N005);
+       glVertex3fv(P005);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P006);
+       glVertex3fv(P005);
+       glVertex3fv(P004);
+       glVertex3fv(P008);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N006);
+       glVertex3fv(P006);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N008);
+       glVertex3fv(P008);
+       glNormal3fv(N004);
+       glVertex3fv(P004);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N004);
+       glVertex3fv(P004);
+       glEnd();
+}
+
+static void
+Whale015(GLenum cap)
+{
+       glBegin(cap);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N055);
+       glVertex3fv(P055);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N003);
+       glVertex3fv(P003);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N054);
+       glVertex3fv(P054);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N063);
+       glVertex3fv(P063);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glEnd();
+       glBegin(cap);
+       glNormal3fv(N100);
+       glVertex3fv(P100);
+       glNormal3fv(N002);
+       glVertex3fv(P002);
+       glNormal3fv(N062);
+       glVertex3fv(P062);
+       glEnd();
+}
+
+static void
+Whale016(GLenum cap)
+{
+       glBegin(cap);
+       glVertex3fv(P104);
+       glVertex3fv(P105);
+       glVertex3fv(P106);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P107);
+       glVertex3fv(P108);
+       glVertex3fv(P109);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P110);
+       glVertex3fv(P111);
+       glVertex3fv(P112);
+       glVertex3fv(P113);
+       glVertex3fv(P114);
+       glVertex3fv(P115);
+       glEnd();
+       glBegin(cap);
+       glVertex3fv(P116);
+       glVertex3fv(P117);
+       glVertex3fv(P118);
+       glVertex3fv(P119);
+       glVertex3fv(P120);
+       glVertex3fv(P121);
+       glEnd();
+}
+
+void
+DrawWhale(fishRec * fish, int wire)
+{
+       float       seg0, seg1, seg2, seg3, seg4, seg5, seg6, seg7;
+       float       pitch, thrash, chomp;
+       GLenum      cap;
+
+       fish->htail = (int) (fish->htail - (int) (5.0 * fish->v)) % 360;
+
+       thrash = 70.0 * fish->v;
+
+       seg0 = 1.5 * thrash * sin((fish->htail) * RRAD);
+       seg1 = 2.5 * thrash * sin((fish->htail + 10.0) * RRAD);
+       seg2 = 3.7 * thrash * sin((fish->htail + 15.0) * RRAD);
+       seg3 = 4.8 * thrash * sin((fish->htail + 23.0) * RRAD);
+       seg4 = 6.0 * thrash * sin((fish->htail + 28.0) * RRAD);
+       seg5 = 6.5 * thrash * sin((fish->htail + 35.0) * RRAD);
+       seg6 = 6.5 * thrash * sin((fish->htail + 40.0) * RRAD);
+       seg7 = 6.5 * thrash * sin((fish->htail + 55.0) * RRAD);
+
+       pitch = fish->v * sin((fish->htail - 160.0) * RRAD);
+
+       chomp = 0.0;
+       if (fish->v > 2.0) {
+               chomp = -(fish->v - 2.0) * 200.0;
+       }
+       P012[1] = iP012[1] + seg5;
+       P013[1] = iP013[1] + seg5;
+       P014[1] = iP014[1] + seg5;
+       P015[1] = iP015[1] + seg5;
+       P016[1] = iP016[1] + seg5;
+       P017[1] = iP017[1] + seg5;
+       P018[1] = iP018[1] + seg5;
+       P019[1] = iP019[1] + seg5;
+
+       P020[1] = iP020[1] + seg4;
+       P021[1] = iP021[1] + seg4;
+       P022[1] = iP022[1] + seg4;
+       P023[1] = iP023[1] + seg4;
+       P024[1] = iP024[1] + seg4;
+       P025[1] = iP025[1] + seg4;
+       P026[1] = iP026[1] + seg4;
+       P027[1] = iP027[1] + seg4;
+
+       P028[1] = iP028[1] + seg2;
+       P029[1] = iP029[1] + seg2;
+       P030[1] = iP030[1] + seg2;
+       P031[1] = iP031[1] + seg2;
+       P032[1] = iP032[1] + seg2;
+       P033[1] = iP033[1] + seg2;
+       P034[1] = iP034[1] + seg2;
+       P035[1] = iP035[1] + seg2;
+
+       P036[1] = iP036[1] + seg1;
+       P037[1] = iP037[1] + seg1;
+       P038[1] = iP038[1] + seg1;
+       P039[1] = iP039[1] + seg1;
+       P040[1] = iP040[1] + seg1;
+       P041[1] = iP041[1] + seg1;
+       P042[1] = iP042[1] + seg1;
+       P043[1] = iP043[1] + seg1;
+
+       P044[1] = iP044[1] + seg0;
+       P045[1] = iP045[1] + seg0;
+       P046[1] = iP046[1] + seg0;
+       P047[1] = iP047[1] + seg0;
+       P048[1] = iP048[1] + seg0;
+       P049[1] = iP049[1] + seg0;
+       P050[1] = iP050[1] + seg0;
+       P051[1] = iP051[1] + seg0;
+
+       P009[1] = iP009[1] + seg6;
+       P010[1] = iP010[1] + seg6;
+       P075[1] = iP075[1] + seg6;
+       P076[1] = iP076[1] + seg6;
+
+       P001[1] = iP001[1] + seg7;
+       P011[1] = iP011[1] + seg7;
+       P068[1] = iP068[1] + seg7;
+       P069[1] = iP069[1] + seg7;
+       P070[1] = iP070[1] + seg7;
+       P071[1] = iP071[1] + seg7;
+       P072[1] = iP072[1] + seg7;
+       P073[1] = iP073[1] + seg7;
+       P074[1] = iP074[1] + seg7;
+
+       P091[1] = iP091[1] + seg3 * 1.1;
+       P092[1] = iP092[1] + seg3;
+       P093[1] = iP093[1] + seg3;
+       P094[1] = iP094[1] + seg3;
+       P095[1] = iP095[1] + seg3 * 0.9;
+
+       P099[1] = iP099[1] + chomp;
+       P098[1] = iP098[1] + chomp;
+       P064[1] = iP064[1] + chomp;
+       P061[1] = iP061[1] + chomp;
+       P097[1] = iP097[1] + chomp;
+       P096[1] = iP096[1] + chomp;
+
+       glPushMatrix();
+
+       glRotatef(pitch, 1.0, 0.0, 0.0);
+
+       glTranslatef(0.0, 0.0, 8000.0);
+
+       glRotatef(180.0, 0.0, 1.0, 0.0);
+
+       glScalef(3.0, 3.0, 3.0);
+
+       glEnable(GL_CULL_FACE);
+
+       cap = wire ? GL_LINE_LOOP : GL_POLYGON;
+       Whale001(cap);
+       Whale002(cap);
+       Whale003(cap);
+       Whale004(cap);
+       Whale005(cap);
+       Whale006(cap);
+       Whale007(cap);
+       Whale008(cap);
+       Whale009(cap);
+       Whale010(cap);
+       Whale011(cap);
+       Whale012(cap);
+       Whale013(cap);
+       Whale014(cap);
+       Whale015(cap);
+       Whale016(cap);
+
+       glDisable(GL_CULL_FACE);
+
+       glPopMatrix();
+}
+#endif
diff --git a/xlockmore-4.14/modes/goop.c b/xlockmore-4.14/modes/goop.c
new file mode 100644 (file)
index 0000000..040dd77
--- /dev/null
@@ -0,0 +1,591 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* goop --- goop from a lava lamp */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)goop.c  4.10 98/03/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by Jamie Zawinski
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 24-Mar-98: xlock version David Bagley <bagleyd@tux.org>
+ * 1997:      xscreensaver version Jamie Zawinski <jwz@jwz.org>
+ */
+
+/*-
+ * original copyright
+ * xscreensaver, Copyright (c) 1997 Jamie Zawinski <jwz@jwz.org>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ */
+
+/*-
+ * This is pretty compute-intensive, probably due to the large number of
+ * polygon fills.  I tried introducing a scaling factor to make the spline
+ * code emit fewer line segments, but that made the edges very rough.
+ * However, tuning *maxVelocity, *elasticity and *delay can result in much
+ * smoother looking animation.  I tuned these for a 1280x1024 Indy display,
+ * but I don't know whether these values will be reasonable for a slower
+ * machine...
+ *
+ * The more planes the better -- SGIs have a 12-bit pseudocolor display
+ * (4096 colormap cells) which is mostly useless, except for this program,
+ * where it means you can have 11 or 12 mutually-transparent objects instead
+ * of only 7 or 8.  But, if you are using the 12-bit visual, you should crank
+ * down the velocity and elasticity, or server slowness will cause the
+ * animation to look jerky (yes, it's sad but true, SGI's X server is
+ * perceptibly slower when using plane masks on a 12-bit visual than on an
+ * 8-bit visual.)  Using -max-velocity 0.5 -elasticity 0.9 seems to work ok
+ * on my Indy R5k with visual 0x27 and the bottom-of-the-line 24-bit graphics
+ * board.
+ *
+ * It might look better if each blob had an outline, which was a *slightly*
+ * darker color than the center, to give them a bit more definition -- but
+ * that would mean using two planes per blob.  (Or maybe allocating the
+ * outline colors outside of the plane-space?  Then the outlines wouldn't be
+ * transparent, but maybe that wouldn't be so noticeable?)
+ *
+ * Oh, for an alpha channel... maybe I should rewrite this in GL.  Then the
+ * blobs could have thickness, and curved edges with specular reflections...
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Goop"
+#define HACK_INIT init_goop
+#define HACK_DRAW draw_goop
+#define goop_opts xlockmore_opts
+#define DEFAULTS "*delay: 40000 \n" \
+ "*count: 100 \n"
+/*-  Come back to this.
+  "*delay:             12000",
+"*transparent: true",
+"*additive:            true",
+"*xor:         false",
+"*count:               0",
+"*planes:              0",
+"*thickness:           5",
+"*torque:              0.0075",
+"*elasticity:          1.8",
+"*maxVelocity: 1.2",
+ */
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+#include <spline.h>
+
+#ifdef MODE_goop
+
+ModeSpecOpt goop_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   goop_description =
+{"goop", "init_goop", "draw_goop", "release_goop",
+ "refresh_goop", "init_goop", NULL, &goop_opts,
+ 10000, -5, 1, 1, 64, 1.0, "",
+ "Shows goop from a lava lamp", 0, NULL};
+
+#endif
+
+
+#define SCALE       10000      /* fixed-point math, for sub-pixel motion */
+#define DEF_COUNT   12         /* When planes and count are 0, how many blobs. */
+
+
+#define RANDSIGN() ((LRAND() & 1) ? 1 : -1)
+
+typedef struct {
+       long        x, y;       /* position of midpoint */
+       long        dx, dy;     /* velocity and direction */
+       double      torque;     /* rotational speed */
+       double      th;         /* angle of rotation */
+       long        elasticity; /* how fast they deform */
+       long        max_velocity;       /* speed limit */
+       long        min_r, max_r;       /* radius range */
+       int         npoints;    /* control points */
+       long       *r;          /* radii */
+       spline     *splines;
+} blob;
+
+typedef struct {
+       int         nblobs;     /* number of blops per plane */
+       blob       *blobs;
+       Pixmap      pixmap;
+       unsigned long pixel;
+       GC          gc;
+} layer;
+
+enum goop_mode {
+       transparent,
+       opaque,
+       xor,
+       outline
+};
+
+typedef struct {
+       enum goop_mode mode;
+       int         width, height;
+       int         nlayers;
+       layer      *layers;
+       unsigned long background;
+       Pixmap      pixmap;
+       GC          pixmap_gc;
+} goopstruct;
+
+static goopstruct *goops = NULL;
+
+static void
+make_blob(blob * b, int maxx, int maxy, int size)
+{
+       int         i;
+       long        mid;
+
+       maxx *= SCALE;
+       maxy *= SCALE;
+       size *= SCALE;
+
+       b->max_r = size / 2;
+       b->min_r = size / 10;
+
+       if (b->min_r < (5 * SCALE))
+               b->min_r = (5 * SCALE);
+       mid = ((b->min_r + b->max_r) / 2);
+
+       b->torque = 0.0075;     /* torque init */
+       b->elasticity = (long) (SCALE * 1.8);   /* elasticity init */
+       b->max_velocity = (long) (SCALE * 1.2);         /* max_velocity init */
+
+       b->x = NRAND(maxx);
+       b->y = NRAND(maxy);
+
+       b->dx = NRAND(b->max_velocity) * RANDSIGN();
+       b->dy = NRAND(b->max_velocity) * RANDSIGN();
+       b->th = (2.0 * M_PI) * LRAND() / MAXRAND * RANDSIGN();
+       b->npoints = (int) (LRAND() % 5) + 5;
+
+       b->splines = make_spline(b->npoints);
+       b->r = (long *) malloc(sizeof (*b->r) * b->npoints);
+       for (i = 0; i < b->npoints; i++)
+               b->r[i] = ((LRAND() % mid) + (mid / 2)) * RANDSIGN();
+}
+
+static void
+throb_blob(blob * b)
+{
+       int         i;
+       double      frac = ((M_PI + M_PI) / b->npoints);
+
+       for (i = 0; i < b->npoints; i++) {
+               long        r = b->r[i];
+               long        ra = (r > 0 ? r : -r);
+               double      th = (b->th > 0 ? b->th : -b->th);
+               long        x, y;
+
+               /* place control points evenly around perimiter, shifted by theta */
+               x = b->x + (long) (ra * cos(i * frac + th));
+               y = b->y + (long) (ra * sin(i * frac + th));
+
+               b->splines->control_x[i] = x / SCALE;
+               b->splines->control_y[i] = y / SCALE;
+
+               /* alter the radius by a random amount, in the direction in which
+                  it had been going (the sign of the radius indicates direction.) */
+               ra += (NRAND(b->elasticity) * (r > 0 ? 1 : -1));
+               r = ra * (r >= 0 ? 1 : -1);
+
+               /* If we've reached the end (too long or too short) reverse direction. */
+               if ((ra > b->max_r && r >= 0) ||
+                   (ra < b->min_r && r < 0))
+                       r = -r;
+               /* And reverse direction in mid-course once every 50 times. */
+               else if (!(LRAND() % 50))
+                       r = -r;
+
+               b->r[i] = r;
+       }
+}
+
+static void
+move_blob(blob * b, int maxx, int maxy)
+{
+       maxx *= SCALE;
+       maxy *= SCALE;
+
+       b->x += b->dx;
+       b->y += b->dy;
+
+       /* If we've reached the edge of the box, reverse direction. */
+       if ((b->x > maxx && b->dx >= 0) ||
+           (b->x < 0 && b->dx < 0)) {
+               b->dx = -b->dx;
+       }
+       if ((b->y > maxy && b->dy >= 0) ||
+           (b->y < 0 && b->dy < 0)) {
+               b->dy = -b->dy;
+       }
+       /* Alter velocity randomly. */
+       if (!(LRAND() % 10)) {
+               b->dx += (NRAND(b->max_velocity / 2) * RANDSIGN());
+               b->dy += (NRAND(b->max_velocity / 2) * RANDSIGN());
+
+               /* Throttle velocity */
+               if (b->dx > b->max_velocity || b->dx < -b->max_velocity)
+                       b->dx /= 2;
+               if (b->dy > b->max_velocity || b->dy < -b->max_velocity)
+                       b->dy /= 2;
+       } {
+               double      th = b->th;
+               double      d = (b->torque == 0 ? 0 : (b->torque) * LRAND() / MAXRAND);
+
+               if (th < 0)
+                       th = -(th + d);
+               else
+                       th += d;
+
+               if (th > (M_PI + M_PI))
+                       th -= (M_PI + M_PI);
+               else if (th < 0)
+                       th += (M_PI + M_PI);
+
+               b->th = (b->th > 0 ? th : -th);
+       }
+
+       /* Alter direction of rotation randomly. */
+       if (!(LRAND() % 100))
+               b->th *= -1;
+}
+
+
+static void
+draw_blob(Display * display, Drawable drawable, GC gc, blob * b,
+         Bool fill_p)
+{
+       compute_closed_spline(b->splines);
+#ifdef DEBUG
+       {
+               int         i;
+
+               for (i = 0; i < b->npoints; i++)
+                       XDrawLine(display, drawable, gc, b->x / SCALE, b->y / SCALE,
+                        b->splines->control_x[i], b->splines->control_y[i]);
+       }
+#else
+       if (fill_p)
+               XFillPolygon(display, drawable, gc, b->splines->points, b->splines->n_points,
+                            Nonconvex, CoordModeOrigin);
+       else
+#endif
+               XDrawLines(display, drawable, gc, b->splines->points, b->splines->n_points,
+                          CoordModeOrigin);
+}
+
+static void
+make_layer(ModeInfo * mi, layer * l, int nblobs)
+{
+       int         i;
+       int         blob_min, blob_max;
+       XGCValues   gcv;
+       int         width = MI_WIDTH(mi), height = MI_HEIGHT(mi);
+
+       l->nblobs = nblobs;
+
+       l->blobs = (blob *) calloc(l->nblobs, sizeof (blob));
+
+       blob_max = (width < height ? width : height) / 2;
+       blob_min = (blob_max * 2) / 3;
+       for (i = 0; i < l->nblobs; i++)
+               make_blob(&(l->blobs[i]), width, height,
+                         (int) (LRAND() % (blob_max - blob_min)) + blob_min);
+
+       l->pixmap = XCreatePixmap(MI_DISPLAY(mi), MI_WINDOW(mi), width, height, 1);
+       l->gc = XCreateGC(MI_DISPLAY(mi), l->pixmap, 0, &gcv);
+}
+
+static void
+draw_layer_plane(Display * display, layer * layer_plane, int width, int height)
+{
+       int         i;
+
+       XSetForeground(display, layer_plane->gc, 1L);
+       XFillRectangle(display, layer_plane->pixmap, layer_plane->gc,
+     0, 0, width, height);
+       XSetForeground(display, layer_plane->gc, 0L);
+       for (i = 0; i < layer_plane->nblobs; i++) {
+               throb_blob(&(layer_plane->blobs[i]));
+               move_blob(&(layer_plane->blobs[i]), width, height);
+               draw_blob(display, layer_plane->pixmap, layer_plane->gc,
+       &(layer_plane->blobs[i]), True);
+       }
+}
+
+
+static void
+draw_layer_blobs(Display * display, Drawable drawable, GC gc,
+                layer * layer_plane, int width, int height,
+                Bool fill_p)
+{
+       int         i;
+
+       for (i = 0; i < layer_plane->nblobs; i++) {
+               throb_blob(&(layer_plane->blobs[i]));
+               move_blob(&(layer_plane->blobs[i]), width, height);
+               draw_blob(display, drawable, gc, &(layer_plane->blobs[i]), fill_p);
+       }
+}
+
+static void
+free_goop(Display * display, goopstruct * gp)
+{
+       int         l;
+
+       if (gp->layers) {
+               for (l = 0; l < gp->nlayers; l++) {
+                       if (gp->layers[l].blobs) {
+                               int         b;
+
+                               for (b = 0; b < gp->layers[l].nblobs; b++) {
+                                       if (gp->layers[l].blobs[b].r)
+                                               (void) free((void *) gp->layers[l].blobs[b].r);
+                                       free_spline(gp->layers[l].blobs[b].splines);
+                               }
+                               (void) free((void *) gp->layers[l].blobs);
+                       }
+                       if (gp->layers[l].gc != None)
+                               XFreeGC(display, gp->layers[l].gc);
+                       if (gp->layers[l].pixmap != None)
+                               XFreePixmap(display, gp->layers[l].pixmap);
+               }
+               if (gp->pixmap_gc != None) {
+                       XFreeGC(display, gp->pixmap_gc);
+                       gp->pixmap_gc = None;
+               }
+               if (gp->pixmap != None) {
+                       XFreePixmap(display, gp->pixmap);
+                       gp->pixmap = None;
+               }
+               (void) free((void *) gp->layers);
+               gp->layers = NULL;
+       }
+}
+
+void
+init_goop(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       goopstruct *gp;
+       int         i;
+       XGCValues   gcv;
+       int         nblobs;
+
+       unsigned long *plane_masks = 0;
+       unsigned long base_pixel = 0;
+
+       if (goops == NULL) {
+               if ((goops = (goopstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (goopstruct))) == NULL)
+                       return;
+       }
+       gp = &goops[MI_SCREEN(mi)];
+
+
+       gp->mode = (False /* xor init */ ? xor
+                   : (True /* transparent init */ ? transparent : opaque));
+
+       gp->width = MI_WIDTH(mi);
+       gp->height = MI_HEIGHT(mi);
+
+       free_goop(display, gp);
+
+       gp->nlayers = 0;        /* planes init */
+       if (gp->nlayers <= 0)
+               gp->nlayers = (int) (LRAND() % (MI_DEPTH(mi) - 2)) + 2;
+       gp->layers = (layer *) calloc(gp->nlayers, sizeof (layer));
+
+
+       if ((MI_NPIXELS(mi) < 2) && gp->mode == transparent)
+               gp->mode = opaque;
+
+       /* Try to allocate some color planes before committing to nlayers.
+        */
+#if 0
+       if (gp->mode == transparent) {
+               Bool        additive_p = True;  /* additive init */
+               int         nplanes = gp->nlayers;
+
+               /* allocate_alpha_colors (display, MI_COLORMAP(mi), &nplanes, additive_p, &plane_masks,
+                  &base_pixel); *//* COME BACK */
+               if (nplanes > 1)
+                       gp->nlayers = nplanes;
+               else {
+                       (void) fprintf(stderr,
+                                      "could not allocate any color planes; turning transparency off.\n");
+                       gp->mode = opaque;
+               }
+       }
+#else
+       if (gp->mode == transparent)
+               gp->mode = opaque;
+#endif
+
+       nblobs = MI_COUNT(mi);
+       if (nblobs < 0) {
+               nblobs = NRAND(-nblobs) + 1;    /* Add 1 so its not too boring */
+       } {
+               int         lblobs[32];
+               int         total = DEF_COUNT;
+
+               /* What does this do? DAB */
+               if (nblobs <= 0)
+                       while (total)
+                               for (i = 0; total && i < gp->nlayers; i++)
+                                       lblobs[i]++, total--;
+               for (i = 0; i < gp->nlayers; i++)
+                       make_layer(mi, &(gp->layers[i]),
+                                  (nblobs > 0 ? nblobs : lblobs[i]));
+       }
+
+       if (gp->mode == transparent && plane_masks) {
+               for (i = 0; i < gp->nlayers; i++)
+                       gp->layers[i].pixel = base_pixel | plane_masks[i];
+               gp->background = base_pixel;
+       }
+       if (plane_masks)
+               (void) free((void *) plane_masks);
+
+       if (gp->mode != transparent) {
+               XColor      color;
+
+               color.flags = DoRed | DoGreen | DoBlue;
+
+               gp->background = 0;     /* init */
+
+               for (i = 0; i < gp->nlayers; i++) {
+                       if (MI_NPIXELS(mi) > 2)
+                               gp->layers[i].pixel = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       else
+                               gp->layers[i].pixel = MI_WHITE_PIXEL(mi);
+               }
+       }
+       gp->pixmap = XCreatePixmap(display, window, MI_WIDTH(mi), MI_HEIGHT(mi),
+                                  (gp->mode == xor ? 1 : MI_DEPTH(mi)));
+
+       gcv.background = gp->background;
+       gcv.foreground = 255;   /* init */
+       gcv.line_width = 5;     /* thickness init */
+       gp->pixmap_gc = XCreateGC(display, gp->pixmap, GCLineWidth, &gcv);
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_goop(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       goopstruct *gp = &goops[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       switch (gp->mode) {
+               case transparent:
+
+                       for (i = 0; i < gp->nlayers; i++)
+                               draw_layer_plane(display, &(gp->layers[i]), gp->width, gp->height);
+
+                       XSetForeground(display, gp->pixmap_gc, gp->background);
+                       XSetPlaneMask(display, gp->pixmap_gc, AllPlanes);
+                       XFillRectangle(display, gp->pixmap, gp->pixmap_gc, 0, 0,
+                                      gp->width, gp->height);
+                       XSetForeground(display, gp->pixmap_gc, ~0L);
+                       for (i = 0; i < gp->nlayers; i++) {
+                               XSetPlaneMask(display, gp->pixmap_gc, gp->layers[i].pixel);
+/*
+   XSetForeground (display, gp->pixmap_gc, ~0L);
+   XFillRectangle (display, gp->pixmap, gp->pixmap_gc, 0, 0,
+   gp->width, gp->height);
+   XSetForeground (display, gp->pixmap_gc, 0L);
+ */
+                               draw_layer_blobs(display, gp->pixmap, gp->pixmap_gc,
+                                    &(gp->layers[i]), gp->width, gp->height,
+                                                True);
+                       }
+                       XCopyArea(display, gp->pixmap, window, MI_GC(mi), 0, 0,
+                                 gp->width, gp->height, 0, 0);
+                       break;
+
+               case xor:
+                       XSetFunction(display, gp->pixmap_gc, GXcopy);
+                       XSetForeground(display, gp->pixmap_gc, 0);
+                       XFillRectangle(display, gp->pixmap, gp->pixmap_gc, 0, 0,
+                                      gp->width, gp->height);
+                       XSetFunction(display, gp->pixmap_gc, GXxor);
+                       XSetForeground(display, gp->pixmap_gc, 1);
+                       for (i = 0; i < gp->nlayers; i++)
+                               draw_layer_blobs(display, gp->pixmap, gp->pixmap_gc,
+                                    &(gp->layers[i]), gp->width, gp->height,
+                                                (gp->mode != outline));
+                       XCopyPlane(display, gp->pixmap, window, MI_GC(mi), 0, 0,
+                                  gp->width, gp->height, 0, 0, 1L);
+                       break;
+
+               case opaque:
+               case outline:
+                       XSetForeground(display, gp->pixmap_gc, MI_BLACK_PIXEL(mi));
+                       XFillRectangle(display, gp->pixmap, gp->pixmap_gc, 0, 0,
+                                      gp->width, gp->height);
+                       for (i = 0; i < gp->nlayers; i++) {
+                               XSetForeground(display, gp->pixmap_gc, gp->layers[i].pixel);
+                               draw_layer_blobs(display, gp->pixmap, gp->pixmap_gc,
+                                    &(gp->layers[i]), gp->width, gp->height,
+                                                (gp->mode != outline));
+                       }
+                       XCopyArea(display, gp->pixmap, window, MI_GC(mi), 0, 0,
+                                 gp->width, gp->height, 0, 0);
+                       break;
+
+               default:
+                       abort();
+                       break;
+       }
+}
+
+void
+release_goop(ModeInfo * mi)
+{
+       if (goops != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       goopstruct *gp = &goops[screen];
+
+                       free_goop(MI_DISPLAY(mi), gp);
+               }
+               (void) free((void *) goops);
+               goops = NULL;
+       }
+}
+
+#endif /* MODE_goop */
diff --git a/xlockmore-4.14/modes/grav.c b/xlockmore-4.14/modes/grav.c
new file mode 100644 (file)
index 0000000..4f65ad3
--- /dev/null
@@ -0,0 +1,341 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* grav --- planets spinning around a pulsar */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)grav.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1993 by Greg Boewring <greg@smug.student.adelaide.edu.au>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 11-Jul-94: color version
+ * 06-Oct-93: Written by Greg Bowering <greg@smug.student.adelaide.edu.au>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Grav"
+#define HACK_INIT init_grav
+#define HACK_DRAW draw_grav
+#define grav_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: -12 \n" \
+ "*ncolors: 64 \n"
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_grav
+
+#define DEF_DECAY "False"      /* Damping for decaying orbits */
+#define DEF_TRAIL "False"      /* For trails (works good in mono only) */
+
+static Bool decay;
+static Bool trail;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-decay", ".grav.decay", XrmoptionNoArg, (caddr_t) "on"},
+       {"+decay", ".grav.decay", XrmoptionNoArg, (caddr_t) "off"},
+       {"-trail", ".grav.trail", XrmoptionNoArg, (caddr_t) "on"},
+       {"+trail", ".grav.trail", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & decay, "decay", "Decay", DEF_DECAY, t_Bool},
+       {(caddr_t *) & trail, "trail", "Trail", DEF_TRAIL, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+decay", "turn on/off decaying orbits"},
+       {"-/+trail", "turn on/off trail dots"}
+};
+
+ModeSpecOpt grav_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   grav_description =
+{"grav", "init_grav", "draw_grav", "release_grav",
+ "refresh_grav", "init_grav", NULL, &grav_opts,
+ 10000, -12, 1, 1, 64, 1.0, "",
+ "Shows orbiting planets", 0, NULL};
+
+#endif
+
+#define GRAV                   -0.02   /* Gravitational constant */
+#define DIST                   16.0
+#define COLLIDE                        0.0001
+#define ALMOST                 15.99
+#define HALF                   0.5
+/* #define INTRINSIC_RADIUS     200.0 */
+#define INTRINSIC_RADIUS       ((float) (gp->height/5))
+#define STARRADIUS             (unsigned int)(gp->height/(2*DIST))
+#define AVG_RADIUS             (INTRINSIC_RADIUS/DIST)
+#define RADIUS                 (unsigned int)(INTRINSIC_RADIUS/(POS(Z)+DIST))
+
+#define XR                     HALF*ALMOST
+#define YR                     HALF*ALMOST
+#define ZR                     HALF*ALMOST
+
+#define VR                     0.04
+
+#define DIMENSIONS             3
+#define X                      0
+#define Y                      1
+#define Z                      2
+
+#define DAMP                   0.999999
+#define MaxA                   0.1     /* Maximum acceleration (w/ damping) */
+
+#define POS(c) planet->P[c]
+#define VEL(c) planet->V[c]
+#define ACC(c) planet->A[c]
+
+#define Planet(x,y)\
+  if ((x) >= 0 && (y) >= 0 && (x) <= gp->width && (y) <= gp->height) {\
+    if (planet->ri < 2)\
+     XDrawPoint(display, window, gc, (x), (y));\
+    else\
+     XFillArc(display, window, gc,\
+      (x) - planet->ri / 2, (y) - planet->ri / 2, planet->ri, planet->ri,\
+      0, 23040);\
+   }
+
+#define FLOATRAND(min,max)     ((min)+(LRAND()/MAXRAND)*((max)-(min)))
+
+typedef struct {
+       double      P[DIMENSIONS], V[DIMENSIONS], A[DIMENSIONS];
+       int         xi, yi, ri;
+       unsigned long colors;
+} planetstruct;
+
+typedef struct {
+       int         width, height;
+       int         x, y, sr, nplanets;
+       unsigned long starcolor;
+       planetstruct *planets;
+} gravstruct;
+
+static gravstruct *gravs = NULL;
+
+static void
+init_planet(ModeInfo * mi, planetstruct * planet)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       gravstruct *gp = &gravs[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) > 2)
+               planet->colors = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       else
+               planet->colors = MI_WHITE_PIXEL(mi);
+       /* Initialize positions */
+       POS(X) = FLOATRAND(-XR, XR);
+       POS(Y) = FLOATRAND(-YR, YR);
+       POS(Z) = FLOATRAND(-ZR, ZR);
+
+       if (POS(Z) > -ALMOST) {
+               planet->xi = (int)
+                       ((double) gp->width * (HALF + POS(X) / (POS(Z) + DIST)));
+               planet->yi = (int)
+                       ((double) gp->height * (HALF + POS(Y) / (POS(Z) + DIST)));
+       } else
+               planet->xi = planet->yi = -1;
+       planet->ri = RADIUS;
+
+       /* Initialize velocities */
+       VEL(X) = FLOATRAND(-VR, VR);
+       VEL(Y) = FLOATRAND(-VR, VR);
+       VEL(Z) = FLOATRAND(-VR, VR);
+
+       /* Draw planets */
+       Planet(planet->xi, planet->yi);
+}
+
+static void
+draw_planet(ModeInfo * mi, planetstruct * planet)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       gravstruct *gp = &gravs[MI_SCREEN(mi)];
+       double      D;          /* A distance variable to work with */
+       register unsigned char cmpt;
+
+       D = POS(X) * POS(X) + POS(Y) * POS(Y) + POS(Z) * POS(Z);
+       if (D < COLLIDE)
+               D = COLLIDE;
+       D = sqrt(D);
+       D = D * D * D;
+       for (cmpt = X; cmpt < DIMENSIONS; cmpt++) {
+               ACC(cmpt) = POS(cmpt) * GRAV / D;
+               if (decay) {
+                       if (ACC(cmpt) > MaxA)
+                               ACC(cmpt) = MaxA;
+                       else if (ACC(cmpt) < -MaxA)
+                               ACC(cmpt) = -MaxA;
+                       VEL(cmpt) = VEL(cmpt) + ACC(cmpt);
+                       VEL(cmpt) *= DAMP;
+               } else {
+                       /* update velocity */
+                       VEL(cmpt) = VEL(cmpt) + ACC(cmpt);
+               }
+               /* update position */
+               POS(cmpt) = POS(cmpt) + VEL(cmpt);
+       }
+
+       gp->x = planet->xi;
+       gp->y = planet->yi;
+
+       if (POS(Z) > -ALMOST) {
+               planet->xi = (int)
+                       ((double) gp->width * (HALF + POS(X) / (POS(Z) + DIST)));
+               planet->yi = (int)
+                       ((double) gp->height * (HALF + POS(Y) / (POS(Z) + DIST)));
+       } else
+               planet->xi = planet->yi = -1;
+
+       /* Mask */
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       Planet(gp->x, gp->y);
+       if (trail) {
+               XSetForeground(display, gc, planet->colors);
+               XDrawPoint(display, MI_WINDOW(mi), gc, gp->x, gp->y);
+       }
+       /* Move */
+       gp->x = planet->xi;
+       gp->y = planet->yi;
+       planet->ri = RADIUS;
+
+       /* Redraw */
+       XSetForeground(display, gc, planet->colors);
+       Planet(gp->x, gp->y);
+}
+
+void
+init_grav(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       gravstruct *gp;
+       unsigned char ball;
+
+       if (gravs == NULL) {
+               if ((gravs = (gravstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (gravstruct))) == NULL)
+                       return;
+       }
+       gp = &gravs[MI_SCREEN(mi)];
+
+       gp->width = MI_WIDTH(mi);
+       gp->height = MI_HEIGHT(mi);
+
+       gp->sr = STARRADIUS;
+
+       gp->nplanets = MI_COUNT(mi);
+       if (gp->nplanets < 0) {
+               if (gp->planets) {
+                       (void) free((void *) gp->planets);
+                       gp->planets = NULL;
+               }
+               gp->nplanets = NRAND(-gp->nplanets) + 1;        /* Add 1 so its not too boring */
+       }
+       if (!gp->planets)
+               gp->planets = (planetstruct *) calloc(gp->nplanets, sizeof (planetstruct));
+
+       MI_CLEARWINDOW(mi);
+
+       if (MI_NPIXELS(mi) > 2)
+               gp->starcolor = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       else
+               gp->starcolor = MI_WHITE_PIXEL(mi);
+       for (ball = 0; ball < (unsigned char) gp->nplanets; ball++)
+               init_planet(mi, &gp->planets[ball]);
+
+       /* Draw centrepoint */
+       XDrawArc(display, MI_WINDOW(mi), gc,
+                gp->width / 2 - gp->sr / 2, gp->height / 2 - gp->sr / 2, gp->sr, gp->sr,
+                0, 23040);
+}
+
+void
+draw_grav(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       gravstruct *gp = &gravs[MI_SCREEN(mi)];
+       register unsigned char ball;
+
+       MI_IS_DRAWN(mi) = True;
+
+       /* Mask centrepoint */
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       XDrawArc(display, window, gc,
+                gp->width / 2 - gp->sr / 2, gp->height / 2 - gp->sr / 2, gp->sr, gp->sr,
+                0, 23040);
+
+       /* Resize centrepoint */
+       switch (NRAND(4)) {
+               case 0:
+                       if (gp->sr < (int) STARRADIUS)
+                               gp->sr++;
+                       break;
+               case 1:
+                       if (gp->sr > 2)
+                               gp->sr--;
+       }
+
+       /* Draw centrepoint */
+       XSetForeground(display, gc, gp->starcolor);
+       XDrawArc(display, window, gc,
+                gp->width / 2 - gp->sr / 2, gp->height / 2 - gp->sr / 2, gp->sr, gp->sr,
+                0, 23040);
+
+       for (ball = 0; ball < (unsigned char) gp->nplanets; ball++)
+               draw_planet(mi, &gp->planets[ball]);
+}
+
+void
+release_grav(ModeInfo * mi)
+{
+       if (gravs != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       gravstruct *gp = &gravs[screen];
+
+                       if (gp->planets)
+                               (void) free((void *) gp->planets);
+               }
+               (void) free((void *) gravs);
+               gravs = NULL;
+       }
+}
+
+void
+refresh_grav(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_grav */
diff --git a/xlockmore-4.14/modes/helix.c b/xlockmore-4.14/modes/helix.c
new file mode 100644 (file)
index 0000000..694650c
--- /dev/null
@@ -0,0 +1,373 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* helix --- string art */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)helix.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1992 by Jamie Zawinski
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 06-Apr-97: new ellipse code from Dan Stromberg <strombrg@nis.acs.uci.edu>
+ * 11-Aug-95: found some typos, looks more interesting now
+ * 08-Aug-95: speed up thanks to Heath A. Kehoe <hakehoe@icaen.uiowa.edu>
+ * 17-Jun-95: removed sleep statements
+ * 2-Sep-93: xlock version David Bagley <bagleyd@tux.org>
+ * 1992:     xscreensaver version Jamie Zawinski <jwz@jwz.org>
+ */
+
+/*-
+ * original copyright
+ * Copyright (c) 1992 by Jamie Zawinski
+ * Permission to use, copy, modify, distribute, and sell this software and
+ * its documentation for any purpose is hereby granted without fee, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or
+ * implied warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Helix"
+#define HACK_INIT init_helix
+#define HACK_DRAW draw_helix
+#define helix_opts xlockmore_opts
+#define DEFAULTS "*delay: 25000 \n" \
+ "*cycles: 100 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n"
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_helix
+
+#define DEF_ELLIPSE "False"
+
+static Bool ellipse;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-ellipse", ".helix.ellipse", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ellipse", ".helix.ellipse", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & ellipse, "ellipse", "Ellipse", DEF_ELLIPSE, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+ellipse", "turn on/off ellipse format"}
+};
+
+ModeSpecOpt helix_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   helix_description =
+{"helix", "init_helix", "draw_helix", "release_helix",
+ "refresh_helix", "init_helix", NULL, &helix_opts,
+ 25000, 1, 100, 1, 64, 1.0, "",
+ "Shows string art", 0, NULL};
+
+#endif
+
+#define ANGLES 360
+
+static double cos_array[ANGLES], sin_array[ANGLES];
+
+typedef struct {
+       Bool        painted;
+       int         width, height;
+       int         xmid, ymid;
+       int         color;
+       int         time;
+       int         radius1, radius2, d_angle, factor1, factor2, factor3,
+                   factor4;
+       int         redraw;
+
+       Bool        ellipse;
+       int         d_angle_offset, dir;
+       int         offset;
+       int         density;
+       int         count;
+} helixstruct;
+
+static helixstruct *helixes = NULL;
+
+static int
+gcd(int a, int b)
+{
+       while (b > 0) {
+               int         tmp;
+
+               tmp = a % b;
+               a = b;
+               b = tmp;
+       }
+       return (a < 0 ? -a : a);
+}
+
+static void
+helix(ModeInfo * mi, int radius1, int radius2, int d_angle,
+      int factor1, int factor2, int factor3, int factor4)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       helixstruct *hp = &helixes[MI_SCREEN(mi)];
+       int         x_1, y_1, x_2, y_2, angle, limit;
+       int         i;
+
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, hp->color));
+               if (++hp->color >= MI_NPIXELS(mi))
+                       hp->color = 0;
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       x_1 = hp->xmid;
+       y_1 = hp->ymid + radius2;
+       x_2 = hp->xmid;
+       y_2 = hp->ymid + radius1;
+       angle = 0;
+       limit = 1 + (ANGLES / gcd(ANGLES, d_angle));
+
+       for (i = 0; i < limit; i++) {
+               int         tmp;
+
+#define pmod(x,y) (tmp=((x)%(y)),(tmp>=0?tmp:tmp+y))
+               x_1 = hp->xmid + (int) (((double) radius1) *
+                                sin_array[pmod((angle * factor1), ANGLES)]);
+               y_1 = hp->ymid + (int) (((double) radius2) *
+                                cos_array[pmod((angle * factor2), ANGLES)]);
+               if (MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, gc, MI_PIXEL(mi, hp->color));
+                       if (++hp->color >= MI_NPIXELS(mi))
+                               hp->color = 0;
+               }
+               XDrawLine(display, window, gc, x_1, y_1, x_2, y_2);
+               x_2 = hp->xmid + (int) (((double) radius2) *
+                                sin_array[pmod((angle * factor3), ANGLES)]);
+               y_2 = hp->ymid + (int) (((double) radius1) *
+                                cos_array[pmod((angle * factor4), ANGLES)]);
+               if (MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, gc, MI_PIXEL(mi, hp->color));
+                       if (++hp->color >= MI_NPIXELS(mi))
+                               hp->color = 0;
+               }
+               XDrawLine(display, window, gc, x_1, y_1, x_2, y_2);
+               angle += d_angle;
+       }
+}
+
+static void
+trig(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       helixstruct *hp = &helixes[MI_SCREEN(mi)];
+       int         x1, y1, x2, y2;
+       int         tmp, angle;
+
+
+#define pmod(x,y) (tmp=((x)%(y)),(tmp>=0?tmp:tmp+y))
+
+       while (ABS(hp->d_angle) <= ANGLES) {
+               angle = hp->d_angle + hp->d_angle_offset;
+               x1 = (int) (sin_array[pmod(angle * hp->factor1, ANGLES)] * hp->xmid) +
+                       hp->xmid;
+               y1 = (int) (cos_array[pmod(angle * hp->factor1, ANGLES)] * hp->ymid) +
+                       hp->ymid;
+               x2 = (int) (sin_array[pmod(angle * hp->factor2 + hp->offset, ANGLES)] *
+                           hp->xmid) + hp->xmid;
+               y2 = (int) (cos_array[pmod(angle * hp->factor2 + hp->offset, ANGLES)] *
+                           hp->ymid) + hp->ymid;
+               XDrawLine(display, MI_WINDOW(mi), gc, x1, y1, x2, y2);
+               if (MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, gc, MI_PIXEL(mi, hp->color));
+                       if (++hp->color >= MI_NPIXELS(mi))
+                               hp->color = 0;
+               }
+               tmp = (int) ANGLES / (2 * hp->density * hp->factor1 * hp->factor2);
+               if (tmp == 0)   /* Do not want it getting stuck... */
+                       tmp = 1;        /* Would not need if floating point */
+               hp->d_angle += hp->dir * tmp;
+       }
+}
+
+static void
+random_helix(ModeInfo * mi)
+{
+       helixstruct *hp = &helixes[MI_SCREEN(mi)];
+       int         radius;
+       double      divisor;
+
+       radius = MIN(hp->xmid, hp->ymid);
+
+       hp->d_angle = 0;
+       hp->factor1 = 2;
+       hp->factor2 = 2;
+       hp->factor3 = 2;
+       hp->factor4 = 2;
+
+       divisor = ((LRAND() / MAXRAND * 3.0 + 1) * (((LRAND() & 1) * 2) - 1));
+
+       if ((LRAND() & 1) == 0) {
+               hp->radius1 = radius;
+               hp->radius2 = (int) ((double) radius / divisor);
+       } else {
+               hp->radius2 = radius;
+               hp->radius1 = (int) ((double) radius / divisor);
+       }
+
+       while (gcd(ANGLES, hp->d_angle) >= 2)
+               hp->d_angle = NRAND(ANGLES);
+
+#define random_factor()                                \
+  (int) (((NRAND(7)) ? ((LRAND() & 1) + 1) : 3)        * (((LRAND() & 1) * 2) - 1))
+
+       while (gcd(gcd(gcd(hp->factor1, hp->factor2), hp->factor3), hp->factor4)
+              != 1) {
+               hp->factor1 = random_factor();
+               hp->factor2 = random_factor();
+               hp->factor3 = random_factor();
+               hp->factor4 = random_factor();
+       }
+
+       helix(mi, hp->radius1, hp->radius2, hp->d_angle,
+             hp->factor1, hp->factor2, hp->factor3, hp->factor4);
+}
+
+static void
+random_trig(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       helixstruct *hp = &helixes[MI_SCREEN(mi)];
+
+       hp->d_angle = 0;
+       hp->factor1 = NRAND(8) + 1;
+       do
+               hp->factor2 = NRAND(8) + 1;
+       while (hp->factor1 == hp->factor2);
+       hp->dir = (LRAND() & 1) ? 1 : -1;
+       hp->d_angle_offset = NRAND(ANGLES);
+       hp->offset = (NRAND(ANGLES / 4 - 1) + 1) / 4;
+       hp->density = 1 << (NRAND(4) + 4);      /* Higher density, higher ANGLES */
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, hp->color));
+               if (++hp->color >= MI_NPIXELS(mi))
+                       hp->color = 0;
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       trig(mi);
+}
+
+void
+init_helix(ModeInfo * mi)
+{
+       helixstruct *hp;
+       int         i;
+       static int  first = 1;
+
+       if (helixes == NULL) {
+               if ((helixes = (helixstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (helixstruct))) == NULL)
+                       return;
+       }
+       hp = &helixes[MI_SCREEN(mi)];
+
+       if (first) {
+               first = 0;
+               for (i = 0; i < ANGLES; i++) {
+                       cos_array[i] = cos((((double) i) / (double) (ANGLES / 2)) * M_PI);
+                       sin_array[i] = sin((((double) i) / (double) (ANGLES / 2)) * M_PI);;
+               }
+       }
+       hp->ellipse = ellipse;
+       if (MI_IS_FULLRANDOM(mi))
+               hp->ellipse = (Bool) (!NRAND(5));       /* 1:5 chance of running ellipse stuff */
+
+       hp->width = MI_WIDTH(mi);
+       hp->height = MI_HEIGHT(mi);
+       hp->xmid = hp->width / 2;
+       hp->ymid = hp->height / 2;
+       hp->redraw = 0;
+
+       MI_CLEARWINDOW(mi);
+       hp->painted = False;
+
+       if (MI_NPIXELS(mi) > 2)
+               hp->color = NRAND(MI_NPIXELS(mi));
+       hp->time = 0;
+
+       if (hp->ellipse) {
+               random_trig(mi);
+       } else
+               random_helix(mi);
+}
+
+void
+draw_helix(ModeInfo * mi)
+{
+       helixstruct *hp = &helixes[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (++hp->time > MI_CYCLES(mi))
+               init_helix(mi);
+       else
+               hp->painted = True;
+       if (hp->redraw) {
+               if (hp->ellipse) {
+                       trig(mi);
+               } else {
+                       helix(mi, hp->radius1, hp->radius2, hp->d_angle,
+                        hp->factor1, hp->factor2, hp->factor3, hp->factor4);
+               }
+               hp->redraw = 0;
+       }
+}
+
+void
+release_helix(ModeInfo * mi)
+{
+       if (helixes != NULL) {
+               (void) free((void *) helixes);
+               helixes = NULL;
+       }
+}
+
+void
+refresh_helix(ModeInfo * mi)
+{
+       helixstruct *hp = &helixes[MI_SCREEN(mi)];
+
+       if (hp->painted) {
+               MI_CLEARWINDOW(mi);
+               helix(mi, hp->radius1, hp->radius2, hp->d_angle,
+                     hp->factor1, hp->factor2, hp->factor3, hp->factor4);
+               hp->painted = False;
+       }
+}
+
+#endif /* MODE_helix */
diff --git a/xlockmore-4.14/modes/hop.c b/xlockmore-4.14/modes/hop.c
new file mode 100644 (file)
index 0000000..53a97a1
--- /dev/null
@@ -0,0 +1,552 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* hop --- real plane fractals */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)hop.c        4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * Changes in xlockmore distribution
+ * 24-Jun-97: EJK and RR functions stolen from xmartin2.2
+ *            Ed Kubaitis <ejk@ux2.cso.uiuc.edu> ejk functions and xmartin 
+ *            Renaldo Recuerdo rr function, generalized exponent version
+ *              of the Barry Martin's square root function
+ * 10-May-97: Compatible with xscreensaver
+ * 27-Jul-95: added Peter de Jong's hop from Scientific American
+ *            July 87 p. 111.  Sometimes they are amazing but there are a
+ *            few duds (I did not see a pattern in the parameters).
+ * 29-Mar-95: changed name from hopalong to hop
+ * 09-Dec-94: added Barry Martin's sine hop
+ * Changes in original xlock
+ * 29-Oct-90: fix bad (int) cast.
+ * 29-Jul-90: support for multiple screens.
+ * 08-Jul-90: new timing and colors and new algorithm for fractals.
+ * 15-Dec-89: Fix for proper skipping of {White,Black}Pixel() in colors.
+ * 08-Oct-89: Fixed long standing typo bug in RandomInitHop();
+ *           Fixed bug in memory allocation in init_hop();
+ *           Moved seconds() to an extern.
+ *           Got rid of the % mod since .mod is slow on a sparc.
+ * 20-Sep-89: Lint.
+ * 31-Aug-88: Forked from xlock.c for modularity.
+ * 23-Mar-88: Coded HOPALONG routines from Scientific American Sept. 86 p. 14.
+ *            Hopalong was attributed to Barry Martin of Aston University
+ *            (Birmingham, England)
+ */
+
+
+#ifdef STANDALONE
+#define PROGCLASS "Hop"
+#define HACK_INIT init_hop
+#define HACK_DRAW draw_hop
+#define hop_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 1000 \n" \
+ "*cycles: 2500 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n" \
+ "*verbose: False \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_hop
+
+#define DEF_MARTIN "False"
+#define DEF_POPCORN "False"
+#define DEF_EJK1 "False"
+#define DEF_EJK2 "False"
+#define DEF_EJK3 "False"
+#define DEF_EJK4 "False"
+#define DEF_EJK5 "False"
+#define DEF_EJK6 "False"
+#define DEF_RR "False"
+#define DEF_JONG "False"
+#define DEF_SINE "False"
+
+static Bool martin;
+static Bool popcorn;
+static Bool ejk1;
+static Bool ejk2;
+static Bool ejk3;
+static Bool ejk4;
+static Bool ejk5;
+static Bool ejk6;
+static Bool rr;
+static Bool jong;
+static Bool sine;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-martin", ".hop.martin", XrmoptionNoArg, (caddr_t) "on"},
+       {"+martin", ".hop.martin", XrmoptionNoArg, (caddr_t) "off"},
+       {"-popcorn", ".hop.popcorn", XrmoptionNoArg, (caddr_t) "on"},
+       {"+popcorn", ".hop.popcorn", XrmoptionNoArg, (caddr_t) "off"},
+       {"-ejk1", ".hop.ejk1", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ejk1", ".hop.ejk1", XrmoptionNoArg, (caddr_t) "off"},
+       {"-ejk2", ".hop.ejk2", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ejk2", ".hop.ejk2", XrmoptionNoArg, (caddr_t) "off"},
+       {"-ejk3", ".hop.ejk3", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ejk3", ".hop.ejk3", XrmoptionNoArg, (caddr_t) "off"},
+       {"-ejk4", ".hop.ejk4", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ejk4", ".hop.ejk4", XrmoptionNoArg, (caddr_t) "off"},
+       {"-ejk5", ".hop.ejk5", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ejk5", ".hop.ejk5", XrmoptionNoArg, (caddr_t) "off"},
+       {"-ejk6", ".hop.ejk6", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ejk6", ".hop.ejk6", XrmoptionNoArg, (caddr_t) "off"},
+       {"-rr", ".hop.rr", XrmoptionNoArg, (caddr_t) "on"},
+       {"+rr", ".hop.rr", XrmoptionNoArg, (caddr_t) "off"},
+       {"-jong", ".hop.jong", XrmoptionNoArg, (caddr_t) "on"},
+       {"+jong", ".hop.jong", XrmoptionNoArg, (caddr_t) "off"},
+       {"-sine", ".hop.sine", XrmoptionNoArg, (caddr_t) "on"},
+       {"+sine", ".hop.sine", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & martin, "martin", "Martin", DEF_MARTIN, t_Bool},
+       {(caddr_t *) & popcorn, "popcorn", "Popcorn", DEF_POPCORN, t_Bool},
+       {(caddr_t *) & ejk1, "ejk1", "EJK1", DEF_EJK1, t_Bool},
+       {(caddr_t *) & ejk2, "ejk2", "EJK2", DEF_EJK2, t_Bool},
+       {(caddr_t *) & ejk3, "ejk3", "EJK3", DEF_EJK3, t_Bool},
+       {(caddr_t *) & ejk4, "ejk4", "EJK4", DEF_EJK4, t_Bool},
+       {(caddr_t *) & ejk5, "ejk5", "EJK5", DEF_EJK5, t_Bool},
+       {(caddr_t *) & ejk6, "ejk6", "EJK6", DEF_EJK6, t_Bool},
+       {(caddr_t *) & rr, "rr", "RR", DEF_RR, t_Bool},
+       {(caddr_t *) & jong, "jong", "Jong", DEF_JONG, t_Bool},
+       {(caddr_t *) & sine, "sine", "Sine", DEF_SINE, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+martin", "turn on/off sqrt format"},
+       {"-/+popcorn", "turn on/off Clifford A. Pickover's popcorn format"},
+       {"-/+ejk1", "turn on/off ejk1 format"},
+       {"-/+ejk2", "turn on/off ejk2 format"},
+       {"-/+ejk3", "turn on/off ejk3 format"},
+       {"-/+ejk4", "turn on/off ejk4 format"},
+       {"-/+ejk5", "turn on/off ejk5 format"},
+       {"-/+ejk6", "turn on/off ejk6 format"},
+       {"-/+rr", "turn on/off rr format"},
+       {"-/+jong", "turn on/off jong format"},
+       {"-/+sine", "turn on/off sine format"}
+};
+
+ModeSpecOpt hop_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   hop_description =
+{"hop", "init_hop", "draw_hop", "release_hop",
+ "refresh_hop", "init_hop", NULL, &hop_opts,
+ 10000, 1000, 2500, 1, 64, 1.0, "",
+ "Shows real plane iterated fractals", 0, NULL};
+
+#endif
+
+#define MARTIN 0
+#define POPCORN 7
+#define SINE 8
+#define EJK1 1
+#define EJK2 2
+#define EJK3 9
+#define EJK4 3
+#define EJK5 4
+#define EJK6 10
+#define RR 5
+#define JONG 6
+#ifdef OFFENDING
+#define OPS 8                  /* 8, 9, 10 might be too close to a swastika for some... */
+#else
+#define OPS 11
+#endif
+
+typedef struct {
+       int         centerx, centery;   /* center of the screen */
+       double      a, b, c, d;
+       double      i, j;       /* hopalong parameters */
+       int         inc;
+       int         pix;
+       int         op;
+       int         count;
+       int         bufsize;
+       XPoint     *pointBuffer;        /* pointer for XDrawPoints */
+} hopstruct;
+
+static hopstruct *hops = NULL;
+
+void
+init_hop(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       hopstruct  *hp;
+       double      range;
+
+       if (hops == NULL) {
+               if ((hops = (hopstruct *) calloc(MI_NUM_SCREENS(mi),
+                                                sizeof (hopstruct))) == NULL)
+                       return;
+       }
+       hp = &hops[MI_SCREEN(mi)];
+
+       hp->centerx = MI_WIDTH(mi) / 2;
+       hp->centery = MI_HEIGHT(mi) / 2;
+       /* Make the other operations less common since they are less interesting */
+       if (MI_IS_FULLRANDOM(mi)) {
+               hp->op = NRAND(OPS);
+       } else {
+               if (martin)
+                       hp->op = MARTIN;
+               else if (popcorn)
+                       hp->op = POPCORN;
+               else if (ejk1)
+                       hp->op = EJK1;
+               else if (ejk2)
+                       hp->op = EJK2;
+               else if (ejk3)
+                       hp->op = EJK3;
+               else if (ejk4)
+                       hp->op = EJK4;
+               else if (ejk5)
+                       hp->op = EJK5;
+               else if (ejk6)
+                       hp->op = EJK6;
+               else if (rr)
+                       hp->op = RR;
+               else if (jong)
+                       hp->op = JONG;
+               else if (sine)
+                       hp->op = SINE;
+               else
+                       hp->op = NRAND(OPS);
+       }
+
+       range = sqrt((double) hp->centerx * hp->centerx +
+            (double) hp->centery * hp->centery) / (1.0 + LRAND() / MAXRAND);
+       hp->i = hp->j = 0.0;
+       hp->inc = (int) ((LRAND() / MAXRAND) * 200) - 100;
+#undef XMARTIN
+       switch (hp->op) {
+               case MARTIN:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 1500.0 + 40.0;
+                       hp->b = (LRAND() / MAXRAND) * 17.0 + 3.0;
+                       hp->c = (LRAND() / MAXRAND) * 3000.0 + 100.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 20.0;
+                       hp->b = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 20.0;
+                       if (LRAND() & 1)
+                               hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 20.0;
+                       else
+                               hp->c = 0.0;
+#endif
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "sqrt a=%g, b=%g, c=%g\n", hp->a, hp->b, hp->c);
+                       break;
+               case EJK1:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 500.0;
+                       hp->c = (LRAND() / MAXRAND) * 100.0 + 10.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 30.0;
+                       hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 40.0;
+#endif
+                       hp->b = (LRAND() / MAXRAND) * 0.4;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "ejk1 a=%g, b=%g, c=%g\n", hp->a, hp->b, hp->c);
+                       break;
+               case EJK2:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 500.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 30.0;
+#endif
+                       hp->b = pow(10.0, 6.0 + (LRAND() / MAXRAND) * 24.0);
+                       if (LRAND() & 1)
+                               hp->b = -hp->b;
+                       hp->c = pow(10.0, (LRAND() / MAXRAND) * 9.0);
+                       if (LRAND() & 1)
+                               hp->c = -hp->c;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "ejk2 a=%g, b=%g, c=%g\n", hp->a, hp->b, hp->c);
+                       break;
+               case EJK3:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 500.0;
+                       hp->c = (LRAND() / MAXRAND) * 80.0 + 30.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 30.0;
+                       hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 70.0;
+#endif
+                       hp->b = (LRAND() / MAXRAND) * 0.35 + 0.5;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "ejk3 a=%g, b=%g, c=%g\n", hp->a, hp->b, hp->c);
+                       break;
+               case EJK4:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 1000.0;
+                       hp->c = (LRAND() / MAXRAND) * 40.0 + 30.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 2.0;
+                       hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 200.0;
+#endif
+                       hp->b = (LRAND() / MAXRAND) * 9.0 + 1.0;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "ejk4 a=%g, b=%g, c=%g\n", hp->a, hp->b, hp->c);
+                       break;
+               case EJK5:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 600.0;
+                       hp->c = (LRAND() / MAXRAND) * 90.0 + 20.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 2.0;
+                       hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 200.0;
+#endif
+                       hp->b = (LRAND() / MAXRAND) * 0.3 + 0.1;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "ejk5 a=%g, b=%g, c=%g\n", hp->a, hp->b, hp->c);
+                       break;
+               case EJK6:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 100.0 + 550.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 30.0;
+#endif
+                       hp->b = (LRAND() / MAXRAND) + 0.5;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "ejk6 a=%g, b=%g\n", hp->a, hp->b);
+                       break;
+               case RR:
+#ifdef XMARTIN
+                       hp->a = (LRAND() / MAXRAND) * 100.0;
+                       hp->b = (LRAND() / MAXRAND) * 20.0;
+                       hp->c = (LRAND() / MAXRAND) * 200.0;
+#else
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 40.0;
+                       hp->b = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 200.0;
+                       hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * range / 20.0;
+#endif
+                       hp->d = (LRAND() / MAXRAND) * 0.9;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "rr a=%g, b=%g, c=%g, d=%g\n",
+                                              hp->a, hp->b, hp->c, hp->d);
+                       break;
+               case POPCORN:
+                       hp->a = 0.0;
+                       hp->b = 0.0;
+                       hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.24 + 0.25;
+                       hp->inc = 100;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "popcorn a=%g, b=%g, c=%g, d=%g\n",
+                                              hp->a, hp->b, hp->c, hp->d);
+                       break;
+               case JONG:
+                       hp->a = ((LRAND() / MAXRAND) * 2.0 - 1.0) * M_PI;
+                       hp->b = ((LRAND() / MAXRAND) * 2.0 - 1.0) * M_PI;
+                       hp->c = ((LRAND() / MAXRAND) * 2.0 - 1.0) * M_PI;
+                       hp->d = ((LRAND() / MAXRAND) * 2.0 - 1.0) * M_PI;
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "jong a=%g, b=%g, c=%g, d=%g\n",
+                                              hp->a, hp->b, hp->c, hp->d);
+                       break;
+               case SINE:      /* MARTIN2 */
+#ifdef XMARTIN
+                       hp->a = M_PI + ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.07;
+#else
+                       hp->a = M_PI + ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.7;
+#endif
+                       if (MI_IS_VERBOSE(mi))
+                               (void) fprintf(stdout, "sine a=%g\n", hp->a);
+                       break;
+       }
+       if (MI_NPIXELS(mi) > 2)
+               hp->pix = NRAND(MI_NPIXELS(mi));
+       hp->bufsize = MI_COUNT(mi);
+
+       if (!hp->pointBuffer)
+               hp->pointBuffer = (XPoint *) malloc(hp->bufsize * sizeof (XPoint));
+
+       MI_CLEARWINDOW(mi);
+
+       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       hp->count = 0;
+}
+
+
+void
+draw_hop(ModeInfo * mi)
+{
+       hopstruct  *hp = &hops[MI_SCREEN(mi)];
+       double      oldj, oldi;
+       XPoint     *xp = hp->pointBuffer;
+       int         k = hp->bufsize;
+
+       MI_IS_DRAWN(mi) = True;
+
+       hp->inc++;
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_PIXEL(mi, hp->pix));
+               if (++hp->pix >= MI_NPIXELS(mi))
+                       hp->pix = 0;
+       }
+       while (k--) {
+               oldj = hp->j;
+               switch (hp->op) {
+                       case MARTIN:    /* SQRT, MARTIN1 */
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj + ((hp->i < 0)
+                                          ? sqrt(fabs(hp->b * oldi - hp->c))
+                                       : -sqrt(fabs(hp->b * oldi - hp->c)));
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case EJK1:
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - ((hp->i > 0) ? (hp->b * oldi - hp->c) :
+                                               -(hp->b * oldi - hp->c));
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case EJK2:
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - ((hp->i < 0) ? log(fabs(hp->b * oldi - hp->c)) :
+                                          -log(fabs(hp->b * oldi - hp->c)));
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case EJK3:
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - ((hp->i > 0) ? sin(hp->b * oldi) - hp->c :
+                                               -sin(hp->b * oldi) - hp->c);
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case EJK4:
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - ((hp->i > 0) ? sin(hp->b * oldi) - hp->c :
+                                         -sqrt(fabs(hp->b * oldi - hp->c)));
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case EJK5:
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - ((hp->i > 0) ? sin(hp->b * oldi) - hp->c :
+                                               -(hp->b * oldi - hp->c));
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case EJK6:
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - asin((hp->b * oldi) - (long) (hp->b * oldi));
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case RR:        /* RR1 */
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - ((hp->i < 0) ? -pow(fabs(hp->b * oldi - hp->c), hp->d) :
+                                    pow(fabs(hp->b * oldi - hp->c), hp->d));
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+                       case POPCORN:
+#define HVAL 0.05
+#define INCVAL 50
+                               {
+                                       double      tempi, tempj;
+
+                                       if (hp->inc >= 100)
+                                               hp->inc = 0;
+                                       if (hp->inc == 0) {
+                                               if (hp->a++ >= INCVAL) {
+                                                       hp->a = 0;
+                                                       if (hp->b++ >= INCVAL)
+                                                               hp->b = 0;
+                                               }
+                                               hp->i = (-hp->c * INCVAL / 2 + hp->c * hp->a) * M_PI / 180.0;
+                                               hp->j = (-hp->c * INCVAL / 2 + hp->c * hp->b) * M_PI / 180.0;
+                                       }
+                                       tempi = hp->i - HVAL * sin(hp->j + tan(3.0 * hp->j));
+                                       tempj = hp->j - HVAL * sin(hp->i + tan(3.0 * hp->i));
+                                       xp->x = hp->centerx + (int) (MI_WIDTH(mi) / 40 * tempi);
+                                       xp->y = hp->centery + (int) (MI_HEIGHT(mi) / 40 * tempj);
+                                       hp->i = tempi;
+                                       hp->j = tempj;
+                               }
+                               break;
+                       case JONG:
+                               if (hp->centerx > 0)
+                                       oldi = hp->i + 4 * hp->inc / hp->centerx;
+                               else
+                                       oldi = hp->i;
+                               hp->j = sin(hp->c * hp->i) - cos(hp->d * hp->j);
+                               hp->i = sin(hp->a * oldj) - cos(hp->b * oldi);
+                               xp->x = hp->centerx + (int) (hp->centerx * (hp->i + hp->j) / 4.0);
+                               xp->y = hp->centery - (int) (hp->centery * (hp->i - hp->j) / 4.0);
+                               break;
+                       case SINE:      /* MARTIN2 */
+                               oldi = hp->i + hp->inc;
+                               hp->j = hp->a - hp->i;
+                               hp->i = oldj - sin(oldi);
+                               xp->x = hp->centerx + (int) (hp->i + hp->j);
+                               xp->y = hp->centery - (int) (hp->i - hp->j);
+                               break;
+               }
+               xp++;
+       }
+       XDrawPoints(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                   hp->pointBuffer, hp->bufsize, CoordModeOrigin);
+       if (++hp->count > MI_CYCLES(mi)) {
+               init_hop(mi);
+       }
+}
+
+void
+release_hop(ModeInfo * mi)
+{
+       if (hops != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       hopstruct  *hp = &hops[screen];
+
+                       if (hp->pointBuffer)
+                               (void) free((void *) hp->pointBuffer);
+               }
+
+               (void) free((void *) hops);
+               hops = NULL;
+       }
+}
+
+void
+refresh_hop(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_hop */
diff --git a/xlockmore-4.14/modes/hyper.c b/xlockmore-4.14/modes/hyper.c
new file mode 100644 (file)
index 0000000..4a35871
--- /dev/null
@@ -0,0 +1,1192 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* hyper --- spinning hypercubes, not just for tesseracts any more */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)hyper.c 4.12 98/08/04 xlockmore";
+
+#endif
+
+/*-
+ * hyper.c (nee multidico)
+ * Copyright (C) 1992,1998 John Heidemann <johnh@isi.edu>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ *
+ ***
+ *
+ * hyper (then called multidico) was originally written for
+ * xscreensaver in 1992.  Unfortunately it didn't make it into that
+ * code because Jamie Zawinski was implementing his own tesseract and
+ * preferred his version (optimized for speed) to my version
+ * (with support for more than 4 dimesnions).
+ *
+ * In 1998 I finally got around to porting it to xlockmore and sending
+ * it off.
+ *
+ * (The implementation is independent of jwz's---I started with ico.)
+ *
+ * Editor's Note... (DAB)
+ * Removed all original Color stuff.  Replaced it so it could do xoring
+ * effectively....  Took move_line from jwz's version.... to make it legal...
+ *
+ * Copyright (c) 1992 by Jamie Zawinski
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ * 
+ * Check out A.K. Dewdney's "Computer Recreations", Scientific American
+ * Magazine" Apr 1986 pp 14-25 for more info.
+ * Idea on 3d taken from there but does not work yet.  Also a small number of
+ * random chosen planes drawn may be nice.
+ *
+ * Revision History:
+ * 04-Aug-98: Added "3d" support from Scientific American
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Hyper"
+#define HACK_INIT init_hyper
+#define HACK_DRAW draw_hyper
+#define HACK_CHANGE change_hyper
+#define hyper_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: -6 \n" \
+ "*cycles: 300 \n" \
+ "*ncolors: 200 \n" \
+ "*use3d: False \n" \
+ "*delta3d: 1.5 \n" \
+ "*right3d: red \n" \
+ "*left3d: blue \n" \
+ "*both3d: magenta \n" \
+ "*none3d: black \n" \
+ "*spinDelay:  2 \n" \
+ "*showAxes:   false \n" \
+ "*randomStart:        false \n" \
+ "*debug:      false \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_hyper
+
+static Bool random_start;
+static Bool show_axes;
+static Bool show_planes;
+static int  spin_delay;
+
+extern XFontStruct *getFont(Display * display);
+
+static XrmOptionDescRec opts[] =
+{
+       {"-randomstart", ".hyper.randomStart", XrmoptionNoArg, "on"},
+       {"+randomstart", ".hyper.randomStart", XrmoptionNoArg, "off"},
+       {"-showaxes", ".hyper.showAxes", XrmoptionNoArg, "on"},
+       {"+showaxes", ".hyper.showAxes", XrmoptionNoArg, "off"},
+       {"-showplanes", ".hyper.showPlanes", XrmoptionNoArg, "on"},
+       {"+showplanes", ".hyper.showPlanes", XrmoptionNoArg, "off"},
+       {"-spindelay", ".hyper.spinDelay", XrmoptionSepArg, 0},
+};
+static argtype vars[] =
+{
+  {(caddr_t *) & random_start, "randomStart", "RandomStart", "True", t_Bool},
+       {(caddr_t *) & show_axes, "showAxes", "ShowAxes", "True", t_Bool},
+       {(caddr_t *) & show_planes, "showPlanes", "ShowPlanes", "False", t_Bool},
+       {(caddr_t *) & spin_delay, "spinDelay", "SpinDelay", "2", t_Int},
+};
+static OptionStruct desc[] =
+{
+       {"-/+randomstart", "turn on/off begining with random rotations"},
+       {"-/+showaxes", "turn on/off showing the axes"},
+       {"-/+showplanes", "turn on/off showing the planes"},
+       {"-spindelay num", "delay in seconds before chaning spin speed"},
+};
+
+ModeSpecOpt hyper_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   hyper_description =
+{"hyper", "init_hyper", "draw_hyper", "release_hyper",
+ "refresh_hyper", "change_hyper", NULL, &hyper_opts,
+ 100000, -6, 300, 1, 64, 1.0, "",
+ "Shows spinning n-dimensional hypercubes", 0, NULL};
+
+#endif
+
+#if DEBUG
+#include <assert.h>
+#endif
+
+typedef struct {
+       double      x, y;
+} dpoint;
+
+typedef double vector;         /* Was an array of size (MAX_D + 1) */
+typedef double matrix;         /* Was a double array of size (MAX_D + 1) ^ 2 */
+
+#define MIN_D 2
+#define MAX_D 10               /* Memory use goes up exponentially */
+
+/* Normally DELTA3D is not in degrees, but it works here, so why fight it? */
+#define DELDEG (MI_DELTA3D(mi)*M_PI/180.0)
+
+typedef struct {
+       int         from, to;
+       long        color;
+} line_segment;
+
+typedef struct {
+       int         a, b, c, d;
+       long        color;
+} plane_section;
+
+
+typedef struct hyper {
+       GC          gc;
+       Bool        redrawing;
+       Bool        painted;
+       XFontStruct *font;
+
+       int         show_axes;
+       int         show_planes;
+
+       int         maxx, maxy;
+       int         delay;
+       int         spinDelay;
+       Bool        normxor;
+
+       /*
+        * Data storage.
+        */
+       int         num_d;      /* number of dimensions */
+       int         num_mat;
+       int         num_matmat;
+
+       /* there are C(num_d,2) planes */
+       int         num_planes; /* #define max_planes 40 */
+       XPoint     *rotation_planes;
+
+       /* Formerly max_planes arrays */
+       double     *rotations;  /* where we are in each dimension */
+       double     *d_rotations;        /* change in rotation */
+       double     *dd_rotations;       /* change in change in rotation */
+       int        *cdd_rotations;      /* how many turns to apply dd_rotations */
+       matrix     *Trotations;
+       matrix     *Trotationsleft;
+
+       matrix     *Tall;
+       matrix     *Tallleft;
+
+       int         num_points;
+       vector     *points;
+       vector     *pointsleft;
+       int         num_lines;
+       line_segment *lines;
+       plane_section *planes;
+
+       int         point_set;  /* which bank of points are we using */
+       XPoint     *xpoints[2];
+       XPoint     *xpointsleft[2];
+
+       int         num_axis_points;
+
+       /* Formerly an array of (MAX_D + 1) */
+       int        *axis_points;
+
+       /*
+        * Inter-step state:
+        */
+       int         this_set;
+       Bool        stationary;
+} hyperstruct;
+
+
+static hyperstruct *hypers = NULL;
+
+#define allocarray(ELTYPE,N) ((ELTYPE*)malloc((N)*sizeof(ELTYPE)))
+#define callocarray(ELTYPE,N) ((ELTYPE*)calloc(N,sizeof(ELTYPE)))
+
+/*
+ * Matrix handling & 3d transformation routines
+ */
+
+static void
+MatMult(matrix * a, matrix * b, matrix * c, int n)
+       /* c = a * b  for n x n matricies */
+{
+       register int i, j, k;
+       double      temp;
+
+       /* Strassen' method... what's that? */
+       for (i = 0; i < n; i++) /* go through a's rows */
+               for (j = 0; j < n; j++) {       /* go through b's columns */
+                       temp = 0.0;
+                       for (k = 0; k < n; k++)
+                               temp += a[i * n + k] * b[k * n + j];
+                       c[i * n + j] = temp;
+               }
+}
+
+static void
+MatVecMult(matrix * a, vector * b, vector * c, int n)
+       /* c = a * b  for a n x n, b&c 1 x n */
+{
+       register int i, k;
+       double      temp;
+
+       for (i = 0; i < n; i++) {       /* go through a's rows */
+               temp = 0.0;
+               for (k = 0; k < n; k++)
+                       temp += a[i * n + k] * b[k];
+               c[i] = temp;
+       }
+}
+
+static void
+MatCopy(matrix * a, matrix * b, int n)
+       /* b <- a */
+{
+       register int i, j;
+
+       for (i = 0; i < n; i++)
+               for (j = 0; j < n; j++)
+                       b[i * n + j] = a[i * n + j];
+}
+
+static void
+MatZero(matrix * a, int n)
+       /* a = 0 */
+{
+       register int i, j;
+
+       for (i = 0; i < n; i++)
+               for (j = 0; j < n; j++)
+                       a[i * n + j] = 0.0;
+}
+
+static void
+MatIdent(matrix * a, int n)
+       /* a = I */
+{
+       register int i;
+
+       MatZero(a, n);
+       for (i = 0; i < n; i++)
+               a[i * n + i] = 1.0;
+}
+
+static void
+ZeroMultiCounter(int *c, int n)
+{
+       int         i;
+
+       for (i = 0; i < n; i++)
+               c[i] = 0;
+}
+
+
+static int
+RealIncMultiCounter(int *c, int n, int place)
+{
+#define BASE 2
+       if (place >= n)
+               return 0;
+       else if (++c[place] >= BASE) {
+               c[place] = 0;
+               return RealIncMultiCounter(c, n, place + 1);
+       } else
+               return 1;
+}
+
+
+static int
+IncMultiCounter(int *c, int n)
+{
+       return RealIncMultiCounter(c, n, 0);
+}
+
+
+static int
+figure_num_points(int d)
+{
+       return 1 << d;          /* (int)pow(2.0, (double)d); */
+}
+
+static int
+figure_num_lines(int d)
+{
+       return d * figure_num_points(d - 1);
+}
+
+static int
+figure_num_planes(int d)
+{
+       return ((d - 1) * d) / 2;
+}
+
+static void
+figure_points(ModeInfo * mi)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+       int         i, j, k, n, d, pix = 0;
+       int        *c;
+
+       /*
+        * First, figure out the points.
+        */
+       hp->num_points = figure_num_points(hp->num_d);
+#if DEBUG
+       assert(hp->num_points <= hp->max_points);
+#endif
+       hp->points = allocarray(vector, hp->num_points * hp->num_mat);
+       hp->xpoints[0] = allocarray(XPoint, hp->num_points);
+       hp->xpoints[1] = allocarray(XPoint, hp->num_points);
+       if (MI_IS_USE3D(mi)) {
+               hp->pointsleft = allocarray(vector, hp->num_points * hp->num_mat);
+               hp->xpointsleft[0] = allocarray(XPoint, hp->num_points);
+               hp->xpointsleft[1] = allocarray(XPoint, hp->num_points);
+       }
+       c = allocarray(int, hp->num_points);    /* will be lost, sigh */
+
+       ZeroMultiCounter(c, hp->num_d);
+       n = 0;
+       do {
+               for (i = 0; i < hp->num_d; i++) {
+                       hp->points[n * hp->num_mat + i] = c[i];
+                       if (MI_IS_USE3D(mi))
+                               hp->pointsleft[n * hp->num_mat + i] = c[i];
+               }
+               n++;
+       } while (IncMultiCounter(c, hp->num_d));
+       (void) free((void *) c);
+#if DEBUG
+       assert(hp->num_points == n);
+#endif
+       /*
+        * Next connect them.
+        * We could do this more intelligently, but why bother?
+        *
+        * Connect points that differ by only one coordinate.
+        */
+       if (MI_NPIXELS(mi) > 2)
+               pix = NRAND(MI_NPIXELS(mi));
+
+       hp->num_lines = figure_num_lines(hp->num_d);
+#if DEBUG
+       assert(hp->num_lines <= hp->max_lines);
+#endif
+       hp->lines = (line_segment *) malloc(hp->num_lines * sizeof (line_segment));
+       for (n = i = 0; i < hp->num_points; i++) {
+               for (j = i + 1; j < hp->num_points; j++) {
+                       for (d = k = 0; k < hp->num_d; k++) {
+                               if (hp->points[i * hp->num_mat + k] != hp->points[j * hp->num_mat + k])
+                                       d++;
+                       }
+                       if (d == 1) {
+                               hp->lines[n].from = i;
+                               hp->lines[n].to = j;
+                               /* (void) printf ("from %x to %x ", i, j); */
+                               if (MI_NPIXELS(mi) > 2) {
+                                       hp->lines[n].color = MI_PIXEL(mi, pix);
+                                       if (++pix >= MI_NPIXELS(mi))
+                                               pix = 0;
+                               } else
+                                       hp->lines[n].color = MI_WHITE_PIXEL(mi);
+                               n++;
+                       }
+               }
+       }
+#if DEBUG
+       assert(hp->num_lines == n);
+#endif
+
+       /*
+        * Now determine the planes of rotation.
+        */
+       hp->num_planes = figure_num_planes(hp->num_d);
+#if DEBUG
+       assert(hp->num_planes <= max_planes);
+#endif
+       hp->show_planes = show_planes;
+
+       if (hp->show_planes) {
+               hp->planes = (plane_section *)
+                               malloc(hp->num_planes * sizeof (plane_section));
+
+               /* Keeping it simple and just drawing planes that touch the
+                * axes.  Still not the simple, have to figure out which pt c is
+                * furthest away and draw it first... yuck.
+                */
+
+               for (n = i = 0; i < hp->num_d; i++) {
+                       for (j = i + 1; j < hp->num_d; j++) {
+                               hp->planes[n].a = 0;    
+                               hp->planes[n].b = 1 << i;       
+                               hp->planes[n].d = 1 << j;       
+                               hp->planes[n].c = hp->planes[n].b + hp->planes[n].d;    
+                               /*(void) printf ("a %d, b %d, c %d, d %d\n",
+                                       0, 1 << i, (1 << i) + (1 << j), 1 << j);*/
+                               if (MI_NPIXELS(mi) > 2) {
+                                       hp->planes[n].color = MI_PIXEL(mi, pix);
+                                       if (++pix >= MI_NPIXELS(mi))
+                                               pix = 0;
+                               } else
+                                       hp->planes[n].color = MI_WHITE_PIXEL(mi);
+                               n++;
+                       }
+               }
+       }
+
+       hp->axis_points = allocarray(int, hp->num_d + 1);
+
+       hp->rotations = allocarray(double, hp->num_planes);
+       hp->d_rotations = callocarray(double, hp->num_planes);
+       hp->dd_rotations = callocarray(double, hp->num_planes);
+       hp->cdd_rotations = callocarray(int, hp->num_planes);
+
+       hp->Trotations = allocarray(matrix, hp->num_planes * hp->num_matmat);
+       hp->Tall = allocarray(matrix, hp->num_matmat);
+
+       if (MI_IS_USE3D(mi)) {
+               hp->Trotationsleft = allocarray(matrix, hp->num_planes * hp->num_matmat);
+               hp->Tallleft = allocarray(matrix, hp->num_matmat);
+       }
+       hp->rotation_planes = allocarray(XPoint, hp->num_planes);
+
+       for (n = i = 0; i < hp->num_d; i++)
+               for (j = i + 1; j < hp->num_d; j++) {
+                       hp->rotation_planes[n].x = i;
+                       hp->rotation_planes[n].y = j;
+                       n++;
+               }
+#if DEBUG
+       assert(hp->num_planes == n);
+#endif
+       /*
+        * Potential random initial rotations.
+        */
+#define FRAC (1024*16)
+       if (random_start) {
+               for (i = 0; i < hp->num_planes; i++)
+                       hp->rotations[i] = 2.0 * NRAND(FRAC) * M_PI / FRAC;
+       }
+}
+
+static void
+figure_axis_points(hyperstruct * hp)
+{
+       int         i, j, num_set;
+
+       hp->show_axes = show_axes;
+       for (hp->num_axis_points = i = 0; i < hp->num_points; i++) {
+               for (num_set = j = 0; j < hp->num_d; j++)
+                       if (hp->points[i * hp->num_mat + j] != 0.0)
+                               num_set++;
+               if (num_set <= 1)
+                       hp->axis_points[hp->num_axis_points++] = i;
+       }
+}
+
+static void
+free_hyper(hyperstruct * hp)
+{
+       if (hp->axis_points) {
+               (void) free((void *) hp->axis_points);
+               hp->axis_points = NULL;
+       }
+       if (hp->points) {
+               (void) free((void *) hp->points);
+               hp->points = NULL;
+       }
+       if (hp->pointsleft) {
+               (void) free((void *) hp->pointsleft);
+               hp->pointsleft = NULL;
+       }
+       if (hp->lines) {
+               XFree(hp->lines);
+               hp->lines = NULL;
+       }
+       if (hp->planes) {
+               XFree(hp->planes);
+               hp->planes = NULL;
+       }
+       if (hp->rotation_planes) {
+               XFree(hp->rotation_planes);
+               hp->rotation_planes = NULL;
+       }
+       if (hp->rotations) {
+               (void) free((void *) hp->rotations);
+               hp->rotations = NULL;
+       }
+       if (hp->d_rotations) {
+               (void) free((void *) hp->d_rotations);
+               hp->d_rotations = NULL;
+       }
+       if (hp->dd_rotations) {
+               (void) free((void *) hp->dd_rotations);
+               hp->dd_rotations = NULL;
+       }
+       if (hp->cdd_rotations) {
+               (void) free((void *) hp->cdd_rotations);
+               hp->cdd_rotations = NULL;
+       }
+       if (hp->Trotations) {
+               (void) free((void *) hp->Trotations);
+               hp->Trotations = NULL;
+       }
+       if (hp->Trotationsleft) {
+               (void) free((void *) hp->Trotationsleft);
+               hp->Trotationsleft = NULL;
+       }
+       if (hp->Tall) {
+               (void) free((void *) hp->Tall);
+               hp->Tall = NULL;
+       }
+       if (hp->Tallleft) {
+               (void) free((void *) hp->Tallleft);
+               hp->Tallleft = NULL;
+       }
+       if (hp->xpoints[0]) {
+               XFree(hp->xpoints[0]);
+               hp->xpoints[0] = NULL;
+       }
+       if (hp->xpoints[1]) {
+               XFree(hp->xpoints[1]);
+               hp->xpoints[1] = NULL;
+       }
+       if (hp->xpointsleft[0]) {
+               XFree(hp->xpointsleft[0]);
+               hp->xpointsleft[0] = NULL;
+       }
+       if (hp->xpointsleft[1]) {
+               XFree(hp->xpointsleft[1]);
+               hp->xpointsleft[1] = NULL;
+       }
+}
+
+static void
+init_x_stuff(ModeInfo * mi)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+       XGCValues   gcv;
+
+       hp->maxx = MI_WIDTH(mi);
+       hp->maxy = MI_HEIGHT(mi);
+
+
+       hp->spinDelay = 10 * spin_delay;
+       if (hp->spinDelay < 0)
+               hp->spinDelay = 0;
+
+       free_hyper(hp);
+       hp->num_d = MI_COUNT(mi);
+       if (hp->num_d < -MAX_D)
+               hp->num_d = -MAX_D;
+       if (hp->num_d > MAX_D)
+               hp->num_d = MAX_D;
+       else if (hp->num_d < -MIN_D) {
+               hp->num_d = NRAND(-hp->num_d - MIN_D + 1) + MIN_D;
+       } else if (hp->num_d < MIN_D)
+               hp->num_d = MIN_D;
+
+       hp->num_mat = hp->num_d + 1;
+       hp->num_matmat = hp->num_mat * hp->num_mat;
+
+       if (!hp->font)
+               hp->font = getFont(MI_DISPLAY(mi));
+
+       if (MI_NPIXELS(mi) <= 2 || MI_IS_USE3D(mi))
+               hp->normxor = False;
+       if (!hp->gc && (MI_NPIXELS(mi) <= 2 || !MI_IS_USE3D(mi))) {
+               long        options;
+
+               if (hp->normxor) {
+                       options = GCForeground | GCFont | GCFunction;
+                       gcv.foreground = MI_WHITE_PIXEL(mi) ^ MI_BLACK_PIXEL(mi);
+                       gcv.function = GXxor;
+               } else {
+                       options = GCForeground | GCBackground | GCFont;
+                       gcv.foreground = MI_WHITE_PIXEL(mi);
+                       gcv.background = MI_BLACK_PIXEL(mi);
+               }
+               gcv.font = hp->font->fid;
+               hp->gc = XCreateGC(MI_DISPLAY(mi), MI_WINDOW(mi), options, &gcv);
+       }
+}
+
+static void
+move_line(ModeInfo * mi, int from, int to, int set, long color)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) <= 2 || !MI_IS_USE3D(mi))
+               gc = hp->gc;
+       if (hp->normxor) {
+               XSetForeground(display, gc, color);
+               if (!hp->redrawing)
+                       XDrawLine(display, window, gc,
+                       hp->xpoints[!set][from].x, hp->xpoints[!set][from].y,
+                          hp->xpoints[!set][to].x, hp->xpoints[!set][to].y);
+               XDrawLine(display, window, gc,
+                         hp->xpoints[set][from].x, hp->xpoints[set][from].y,
+                         hp->xpoints[set][to].x, hp->xpoints[set][to].y);
+       } else {
+               if (!hp->redrawing) {
+                       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi))
+                               XSetForeground(display, gc, MI_NONE_COLOR(mi));
+                       else
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                       XDrawLine(display, window, gc,
+                         hp->xpoints[set][from].x, hp->xpoints[set][from].y,
+                            hp->xpoints[set][to].x, hp->xpoints[set][to].y);
+                       if (MI_IS_USE3D(mi))
+                               XDrawLine(display, window, gc,
+                                         hp->xpointsleft[set][from].x, hp->xpointsleft[set][from].y,
+                                         hp->xpointsleft[set][to].x, hp->xpointsleft[set][to].y);
+               }
+               if (MI_IS_USE3D(mi)) {
+                       if (MI_IS_INSTALL(mi)) {
+                               XSetFunction(display, gc, GXor);
+                       }
+                       XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               } else if (MI_NPIXELS(mi) <= 2)
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               else
+                       XSetForeground(display, gc, color);
+               XDrawLine(display, window, gc,
+                       hp->xpoints[!set][from].x, hp->xpoints[!set][from].y,
+                         hp->xpoints[!set][to].x, hp->xpoints[!set][to].y);
+               if (MI_IS_USE3D(mi)) {
+                       XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+                       XDrawLine(display, window, gc,
+                                 hp->xpointsleft[!set][from].x, hp->xpointsleft[!set][from].y,
+                                 hp->xpointsleft[!set][to].x, hp->xpointsleft[!set][to].y);
+                       if (MI_IS_INSTALL(mi)) {
+                               XSetFunction(display, gc, GXcopy);
+                       }
+               }
+       }
+}
+
+static void
+move_plane(ModeInfo * mi, int a, int b, int c, int d, int set, long color)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+  XPoint rect[4];
+
+       if (MI_NPIXELS(mi) <= 2 || !MI_IS_USE3D(mi))
+               gc = hp->gc;
+       if (hp->normxor) {
+               XSetForeground(display, gc, color);
+               if (!hp->redrawing) {
+                       rect[0].x = hp->xpoints[!set][a].x;
+                       rect[0].y = hp->xpoints[!set][a].y;
+                       rect[1].x = hp->xpoints[!set][b].x;
+                       rect[1].y = hp->xpoints[!set][b].y;
+                       rect[2].x = hp->xpoints[!set][c].x;
+                       rect[2].y = hp->xpoints[!set][c].y;
+                       rect[3].x = hp->xpoints[!set][d].x;
+                       rect[3].y = hp->xpoints[!set][d].y;
+                       XFillPolygon(display, window, gc, rect, 4, Convex, CoordModeOrigin);
+               }
+               rect[0].x = hp->xpoints[set][a].x;
+               rect[0].y = hp->xpoints[set][a].y;
+               rect[1].x = hp->xpoints[set][b].x;
+               rect[1].y = hp->xpoints[set][b].y;
+               rect[2].x = hp->xpoints[set][c].x;
+               rect[2].y = hp->xpoints[set][c].y;
+               rect[3].x = hp->xpoints[set][d].x;
+               rect[3].y = hp->xpoints[set][d].y;
+               XFillPolygon(display, window, gc, rect, 4, Convex, CoordModeOrigin);
+       } else {
+               if (!hp->redrawing) {
+                       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi))
+                               XSetForeground(display, gc, MI_NONE_COLOR(mi));
+                       else
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                       rect[0].x = hp->xpoints[set][a].x;
+                       rect[0].y = hp->xpoints[set][a].y;
+                       rect[1].x = hp->xpoints[set][b].x;
+                       rect[1].y = hp->xpoints[set][b].y;
+                       rect[2].x = hp->xpoints[set][c].x;
+                       rect[2].y = hp->xpoints[set][c].y;
+                       rect[3].x = hp->xpoints[set][d].x;
+                       rect[3].y = hp->xpoints[set][d].y;
+                       XFillPolygon(display, window, gc, rect, 4, Convex, CoordModeOrigin);
+                       if (MI_IS_USE3D(mi)) {
+                               rect[0].x = hp->xpointsleft[set][a].x;
+                               rect[0].y = hp->xpointsleft[set][a].y;
+                               rect[1].x = hp->xpointsleft[set][b].x;
+                               rect[1].y = hp->xpointsleft[set][b].y;
+                               rect[2].x = hp->xpointsleft[set][c].x;
+                               rect[2].y = hp->xpointsleft[set][c].y;
+                               rect[3].x = hp->xpointsleft[set][d].x;
+                               rect[3].y = hp->xpointsleft[set][d].y;
+                               XFillPolygon(display, window, gc, rect, 4, Convex, CoordModeOrigin);
+                       }
+               }
+               if (MI_IS_USE3D(mi)) {
+                       if (MI_IS_INSTALL(mi)) {
+                               XSetFunction(display, gc, GXor);
+                       }
+                       XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               } else if (MI_NPIXELS(mi) <= 2)
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               else
+                       XSetForeground(display, gc, color);
+               rect[0].x = hp->xpoints[!set][a].x;
+               rect[0].y = hp->xpoints[!set][a].y;
+               rect[1].x = hp->xpoints[!set][b].x;
+               rect[1].y = hp->xpoints[!set][b].y;
+               rect[2].x = hp->xpoints[!set][c].x;
+               rect[2].y = hp->xpoints[!set][c].y;
+               rect[3].x = hp->xpoints[!set][d].x;
+               rect[3].y = hp->xpoints[!set][d].y;
+               XFillPolygon(display, window, gc, rect, 4, Convex, CoordModeOrigin);
+               if (MI_IS_USE3D(mi)) {
+                       XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+                       rect[0].x = hp->xpointsleft[!set][a].x;
+                       rect[0].y = hp->xpointsleft[!set][a].y;
+                       rect[1].x = hp->xpointsleft[!set][b].x;
+                       rect[1].y = hp->xpointsleft[!set][b].y;
+                       rect[2].x = hp->xpointsleft[!set][c].x;
+                       rect[2].y = hp->xpointsleft[!set][c].y;
+                       rect[3].x = hp->xpointsleft[!set][d].x;
+                       rect[3].y = hp->xpointsleft[!set][d].y;
+                       XFillPolygon(display, window, gc, rect, 4, Convex, CoordModeOrigin);
+                       if (MI_IS_INSTALL(mi)) {
+                               XSetFunction(display, gc, GXcopy);
+                       }
+               }
+       }
+}
+
+static void
+move_number(ModeInfo * mi, int axis, char *string, int set, long color)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) <= 2 || !MI_IS_USE3D(mi))
+               gc = hp->gc;
+       if (hp->normxor) {
+               XSetForeground(display, gc, color);
+               if (!hp->redrawing)
+                       XDrawString(display, window, gc,
+                       hp->xpoints[!set][axis].x, hp->xpoints[!set][axis].y,
+                                   string, strlen(string));
+               XDrawString(display, window, gc,
+                         hp->xpoints[set][axis].x, hp->xpoints[set][axis].y,
+                           string, strlen(string));
+       } else {
+               if (!hp->redrawing) {
+                       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi))
+                               XSetForeground(display, gc, MI_NONE_COLOR(mi));
+                       else
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                       XDrawString(display, window, gc,
+                         hp->xpoints[set][axis].x, hp->xpoints[set][axis].y,
+                                   string, strlen(string));
+                       if (MI_IS_USE3D(mi))
+                               XDrawString(display, window, gc,
+                                           hp->xpointsleft[set][axis].x, hp->xpointsleft[set][axis].y,
+                                           string, strlen(string));
+               }
+               if (MI_IS_USE3D(mi)) {
+                       if (MI_IS_INSTALL(mi)) {
+                               XSetFunction(display, gc, GXor);
+                       }
+                       XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               } else if (MI_NPIXELS(mi) <= 2)
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               else
+                       XSetForeground(display, gc, color);
+               XDrawString(display, window, gc,
+                       hp->xpoints[!set][axis].x, hp->xpoints[!set][axis].y,
+                           string, strlen(string));
+               if (MI_IS_USE3D(mi)) {
+                       XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+                       XDrawString(display, window, gc,
+                                   hp->xpointsleft[!set][axis].x, hp->xpointsleft[!set][axis].y,
+                                   string, strlen(string));
+                       if (MI_IS_INSTALL(mi)) {
+                               XSetFunction(display, gc, GXcopy);
+                       }
+               }
+       }
+}
+
+static void
+draw_hyper_step(ModeInfo * mi, int set)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+       int         i;
+       char        tmps[3];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!hp->stationary || hp->redrawing) {
+               for (i = 0; i < hp->num_lines; i++) {
+                       move_line(mi, hp->lines[i].from, hp->lines[i].to,
+                               set, hp->lines[i].color);
+               }
+               if (hp->show_planes) {
+                       for (i = 0; i < hp->num_planes; i++) {
+                               move_plane(mi, hp->planes[i].a, hp->planes[i].b, hp->planes[i].c,
+                                       hp->planes[i].d, set, hp->planes[i].color);
+                       }
+               }
+               if (hp->show_axes) {
+                       for (i = 0; i < hp->num_axis_points; i++) {
+                               (void) sprintf(tmps, "%d", i);
+                               move_number(mi, hp->axis_points[i], tmps, set, MI_WHITE_PIXEL(mi));
+                       }
+               }
+       }
+}
+
+static void
+move_hyper(ModeInfo * mi)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+       int         i;
+
+/* NEEDSWORK: These should be resources */
+#define default_cdd_rotation 10
+#define default_dd_rotation (M_PI/1024.0)
+       int         axis, max_axis;
+       int         faster;
+
+       hp->stationary = False;
+       if (hp->spinDelay-- <= 0) {
+
+               hp->spinDelay = 10 * spin_delay;
+               /*
+                * Change rotation?
+                *
+                * 66% chance if stationary, 33% if not.
+                */
+               hp->stationary = True;
+               for (i = 0; i < hp->num_planes; i++)
+                       if (hp->d_rotations[i] != 0.0 || hp->cdd_rotations[i]) {
+                               hp->stationary = False;
+                               break;
+                       }
+               if (NRAND(3) < 1 + hp->stationary) {
+                       /* Change!  But what? */
+                       max_axis = hp->num_planes;
+
+                       if (max_axis > hp->num_planes || max_axis < 0)
+                               max_axis = hp->num_planes;
+                       axis = NRAND(max_axis);
+
+                       /*
+                        * And how much?  33% chance faster, 66% slower.
+                        * If stopped, slower doesn't start it moving
+                        * unless we're stationary.
+                        */
+                       hp->cdd_rotations[axis] = default_cdd_rotation +
+                               NRAND(7) - 3;
+                       faster = (NRAND(3) < 1);
+                       if (faster || hp->dd_rotations[axis] != 0.0 || hp->stationary)
+                               hp->dd_rotations[axis] = default_dd_rotation *
+                                       (hp->dd_rotations[axis] >= 0.0 ? 1 : -1) *
+                                       (faster ? 1 : -1);
+                       if (MI_IS_DEBUG(mi))
+                               (void) fprintf(stderr,
+                                              "axis %d made %s\n", axis, faster ? "faster" : "slower");
+               }
+       }
+       /*
+        * Rotate.
+        */
+       for (i = 0; i < hp->num_planes; i++) {
+               if (hp->cdd_rotations[i]) {
+                       hp->cdd_rotations[i]--;
+                       hp->d_rotations[i] += hp->dd_rotations[i];
+               }
+               hp->rotations[i] += hp->d_rotations[i];
+       }
+}
+
+static void
+calc_transformation(ModeInfo * mi)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+       double      cosa, sina;
+       double      cosb = 0.0, sinb = 0.0;
+       int         p1, p2;
+       matrix     *Ttmp;
+       matrix     *Tpre, *Tuser, *Tuserleft = NULL;
+       matrix     *Tpretranspose, *Tscale, *Tposttranspose;
+       int         i;
+       dpoint      scale, range, offset;
+       double      scale_used;
+
+       Ttmp = allocarray(matrix, hp->num_matmat);
+       Tpre = allocarray(matrix, hp->num_matmat);
+       Tuser = allocarray(matrix, hp->num_matmat);
+       if (MI_IS_USE3D(mi)) {
+               Tuserleft = allocarray(matrix, hp->num_matmat);
+       }
+       Tpretranspose = allocarray(matrix, hp->num_matmat);
+       Tscale = allocarray(matrix, hp->num_matmat);
+       Tposttranspose = allocarray(matrix, hp->num_matmat);
+
+       /*
+        * Adjust the data.
+        * Since the data goes from 0->1 on each axis,
+        * we shift it by -0.5 here to center the figure.
+        */
+       MatIdent(Tpre, hp->num_mat);
+       for (i = 0; i < hp->num_d; i++) {
+               Tpre[i * hp->num_mat + hp->num_d] = -0.5;
+       }
+
+
+       /*
+        * Figure the rotation.
+        */
+       MatIdent(Tuser, hp->num_mat);
+       if (MI_IS_USE3D(mi)) {
+               MatIdent(Tuserleft, hp->num_mat);
+       }
+       for (i = 0; i < hp->num_planes; i++) {
+               p1 = hp->rotation_planes[i].x;
+               p2 = hp->rotation_planes[i].y;
+               if (MI_IS_USE3D(mi)) {
+                       sinb = sin(hp->rotations[i] - DELDEG);
+                       cosb = cos(hp->rotations[i] - DELDEG);
+                       sina = sin(hp->rotations[i] + DELDEG);
+                       cosa = cos(hp->rotations[i] + DELDEG);
+               } else {
+                       sina = sin(hp->rotations[i]);
+                       cosa = cos(hp->rotations[i]);
+               }
+
+               MatIdent(&hp->Trotations[i * hp->num_matmat], hp->num_mat);
+               hp->Trotations[i * hp->num_matmat + p1 * hp->num_mat + p1] =
+                       hp->Trotations[i * hp->num_matmat + p2 * hp->num_mat + p2] = cosa;
+               hp->Trotations[i * hp->num_matmat + p1 * hp->num_mat + p2] = sina;
+               hp->Trotations[i * hp->num_matmat + p2 * hp->num_mat + p1] = -sina;
+               MatMult(&hp->Trotations[i * hp->num_matmat], Tuser, Ttmp, hp->num_mat);
+               MatCopy(Ttmp, Tuser, hp->num_mat);
+
+               if (MI_IS_USE3D(mi)) {
+                       MatIdent(&hp->Trotationsleft[i * hp->num_matmat], hp->num_mat);
+                       hp->Trotationsleft[i * hp->num_matmat + p1 * hp->num_mat + p1] =
+                               hp->Trotationsleft[i * hp->num_matmat + p2 * hp->num_mat + p2] = cosb;
+                       hp->Trotationsleft[i * hp->num_matmat + p1 * hp->num_mat + p2] = sinb;
+                       hp->Trotationsleft[i * hp->num_matmat + p2 * hp->num_mat + p1] = -sinb;
+                       MatMult(&hp->Trotationsleft[i * hp->num_matmat], Tuserleft, Ttmp, hp->num_mat);
+                       MatCopy(Ttmp, Tuserleft, hp->num_mat);
+               }
+       }
+
+/* Now calculate the scaling matrix */
+#if 1
+       /*
+        * Calculate the best scale of the two axes.
+        * Multiply by 0.9 to use 90% of the display.
+        * Divide by the sqrt(2.0) because it's bigest when
+        * rotated by 45 degrees.
+        *
+        * This principle generalizes to sqrt(hp->num_d).
+        */
+#define border_width (0.05)
+       range.x = sqrt((double) hp->num_d);
+       range.y = range.x;
+       scale.x = (1.0 - 2 * border_width) * hp->maxx / range.x;
+       scale.y = (1.0 - 2 * border_width) * hp->maxy / range.y;
+       scale_used = ((scale.x < scale.y) ? scale.x : scale.y);
+       offset.x = hp->maxx / 2.0;
+       offset.y = hp->maxy / 2.0;
+
+       /*
+        * Setup & compute the matricies
+        */
+       MatIdent(Tpretranspose, hp->num_mat);
+       Tpretranspose[0 * hp->num_mat + hp->num_d] = 0;
+       Tpretranspose[1 * hp->num_mat + hp->num_d] = 0;
+
+       MatIdent(Tscale, hp->num_mat);
+       Tscale[0 * hp->num_mat + 0] = scale_used;
+       Tscale[1 * hp->num_mat + 1] = -scale_used;
+
+       MatIdent(Tposttranspose, hp->num_mat);
+       Tposttranspose[0 * hp->num_mat + hp->num_d] = offset.x;
+       Tposttranspose[1 * hp->num_mat + hp->num_d] = offset.y;
+
+       MatMult(Tscale, Tpretranspose, Ttmp, hp->num_mat);
+       MatMult(Tposttranspose, Ttmp, Tscale, hp->num_mat);
+#else
+       MatIdent(Tscale, hp->num_mat);
+#endif
+       (void) free((void *) Tpretranspose);
+       (void) free((void *) Tposttranspose);
+
+       /*
+        * Put it all together.
+        */
+       MatMult(Tuser, Tpre, Ttmp, hp->num_mat);
+       MatMult(Tscale, Ttmp, hp->Tall, hp->num_mat);
+       (void) free((void *) Tuser);
+       if (MI_IS_USE3D(mi)) {
+               MatMult(Tuserleft, Tpre, Ttmp, hp->num_mat);
+               MatMult(Tscale, Ttmp, hp->Tallleft, hp->num_mat);
+               (void) free((void *) Tuserleft);
+       }
+       (void) free((void *) Tpre);
+       (void) free((void *) Ttmp);
+       (void) free((void *) Tscale);
+}
+
+
+static void
+translate_point(hyperstruct * hp, matrix * Tall, vector * real, XPoint * screen_image)
+{
+       vector     *image;
+
+       image = allocarray(vector, hp->num_mat);
+
+       MatVecMult(Tall, real, image, hp->num_mat);
+       screen_image->x = (short) image[0];
+       screen_image->y = (short) image[1];
+
+       (void) free((void *) image);
+}
+
+static void
+translate_points(ModeInfo * mi, int set)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+       int         i;
+
+       calc_transformation(mi);
+       for (i = 0; i < hp->num_points; i++) {
+               translate_point(hp, hp->Tall, &hp->points[i * hp->num_mat], &hp->xpoints[set][i]);
+               if (MI_IS_USE3D(mi))
+                       translate_point(hp, hp->Tallleft, &hp->pointsleft[i * hp->num_mat], &hp->xpointsleft[set][i]);
+       }
+}
+
+void
+refresh_hyper(ModeInfo * mi)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+
+       if (!hp->painted) {
+               MI_CLEARWINDOW(mi);
+               hp->redrawing = True;
+               draw_hyper_step(mi, hp->this_set);
+               hp->redrawing = False;
+               hp->painted = True;
+       }
+}
+
+void
+init_hyper(ModeInfo * mi)
+{
+       hyperstruct *hp;
+       int         i;
+
+       if (hypers == NULL) {
+               if ((hypers = (hyperstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (hyperstruct))) == NULL)
+                       return;
+       }
+       hp = &hypers[MI_SCREEN(mi)];
+
+       init_x_stuff(mi);
+
+       figure_points(mi);
+
+       /*
+        * Fix the d+1 coord of all points.
+        */
+       for (i = 0; i < hp->num_points; i++) {
+               hp->points[i * hp->num_mat + hp->num_d] = 1;
+               if (MI_IS_USE3D(mi))
+                       hp->pointsleft[i * hp->num_mat + hp->num_d] = 1;
+       }
+
+       figure_axis_points(hp);
+
+       hp->this_set = 0;
+       translate_points(mi, !hp->this_set);
+       translate_points(mi, hp->this_set);
+       refresh_hyper(mi);
+       hp->painted = True;
+       hp->stationary = True;
+}
+
+
+void
+draw_hyper(ModeInfo * mi)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+
+       hp->painted = False;
+       draw_hyper_step(mi, hp->this_set);
+
+       /* Set up next place */
+       move_hyper(mi);
+       translate_points(mi, hp->this_set);
+       if (!hp->stationary)
+               hp->this_set = !hp->this_set;
+}
+
+void
+change_hyper(ModeInfo * mi)
+{
+       hyperstruct *hp = &hypers[MI_SCREEN(mi)];
+
+       /* make it change */
+       hp->spinDelay = 0;
+}
+
+void
+release_hyper(ModeInfo * mi)
+{
+       if (hypers != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       hyperstruct *hp = &hypers[screen];
+
+                       if (hp->gc != NULL)
+                               XFreeGC(MI_DISPLAY(mi), hp->gc);
+                       if (hp->font)
+                               XFreeFont(MI_DISPLAY(mi), hp->font);
+                       free_hyper(hp);
+               }
+               (void) free((void *) hypers);
+               hypers = NULL;
+       }
+}
+
+#endif /* MODE_hyper */
diff --git a/xlockmore-4.14/modes/ico.c b/xlockmore-4.14/modes/ico.c
new file mode 100644 (file)
index 0000000..5ad4eaf
--- /dev/null
@@ -0,0 +1,928 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* ico --- bouncing polyhedra */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)ico.c        4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1987  X Consortium
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 25-Mar-97:  David Bagley <bagleyd@tux.org>
+ *             Took ico from the X11R6 distribution.  Stripped out
+ *             anything complicated... to be added back in later.
+ *             added dodecahedron, tetrahedron, and star octahedron.
+ * $XConsortium: ico.c,v 1.47 94/04/17 20:45:15 gildea Exp $
+ */
+
+/*-
+original copyright
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
+X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
+AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+Except as contained in this notice, the name of the X Consortium shall not be
+used in advertising or otherwise to promote the sale, use or other dealings
+in this Software without prior written authorization from the X Consortium.
+
+
+Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
+
+                        All Rights Reserved
+
+Permission to use, copy, modify, and distribute this software and its 
+documentation for any purpose and without fee is hereby granted, 
+provided that the above copyright notice appear in all copies and that
+both that copyright notice and this permission notice appear in 
+supporting documentation, and that the name of Digital not be
+used in advertising or publicity pertaining to distribution of the
+software without specific, written prior permission.  
+
+DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
+ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
+ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+SOFTWARE.
+
+******************************************************************/
+/******************************************************************************
+ * Description
+ *     Display a wire-frame rotating icosahedron, with hidden lines removed
+ *****************************************************************************/
+/*-
+ * Additions by jimmc@sci:
+ *  faces and colors
+ *  double buffering on the display
+ *  additional polyhedra
+ *
+ * multi-thread version by Stephen Gildea, January 1992
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Ico"
+#define HACK_INIT init_ico
+#define HACK_DRAW draw_ico
+#define ico_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: 0 \n" \
+ "*cycles: 300 \n" \
+ "*ncolors: 200 \n"
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_ico
+
+#define DEF_FACES "False"
+#define DEF_EDGES "True"       /* Wire frame edges, set true if faces false. */
+
+static Bool faces;
+static Bool edges;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-faces", ".ico.faces", XrmoptionNoArg, (caddr_t) "on"},
+       {"+faces", ".ico.faces", XrmoptionNoArg, (caddr_t) "off"},
+       {"-edges", ".ico.trail", XrmoptionNoArg, (caddr_t) "on"},
+       {"+edges", ".ico.trail", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & faces, "faces", "Faces", DEF_FACES, t_Bool},
+       {(caddr_t *) & edges, "edges", "Edges", DEF_EDGES, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+faces", "turn on/off drawing of faces"},
+       {"-/+edges", "turn on/off drawing of wireframe"}
+};
+
+ModeSpecOpt ico_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   ico_description =
+{"ico", "init_ico", "draw_ico", "release_ico",
+ "refresh_ico", "change_ico", NULL, &ico_opts,
+ 100000, 0, 400, 0, 64, 1.0, "",
+ "Shows a bouncing polyhedron", 0, NULL};
+
+#endif
+
+#define MINSIZE 5
+#define DEFAULT_DELTAX 13
+#define DEFAULT_DELTAY 9
+
+/*-
+ * This is the description of one polyhedron file
+ */
+
+#define MAXVERTS 120
+       /* great rhombicosidodecahedron has 120 vertices */
+#define MAXNV MAXVERTS
+#define MAXFACES 30
+       /* (hexakis icosahedron has 120 faces) */
+#define MAXEDGES 180
+       /* great rhombicosidodecahedron has 180 edges */
+#define MAXEDGESPERPOLY 20
+
+typedef struct {
+       double      x, y, z;
+} Point3D;
+
+/* structure of the include files which define the polyhedra */
+typedef struct {
+#ifdef DEFUNCT
+       char       *longname;   /* long name of object */
+       char       *shortname;  /* short name of object */
+       char       *dual;       /* long name of dual */
+#endif
+       int         numverts;   /* number of vertices */
+       int         numedges;   /* number of edges */
+       int         numfaces;   /* number of faces */
+       Point3D     v[MAXVERTS];        /* the vertices */
+       int         f[MAXEDGES * 2 + MAXFACES];         /* the faces */
+} Polyinfo;
+
+/*-
+ *                              faces/edges/vert Vertex Config   Wythoff Symbol
+ * tetrahedron                  4/6/4            {3,3,3}         3|2 3
+ * cube                         6/12/8           {4,4,4}         3|2 4
+ * octahedron                   8/12/6           {3,3,3,3}       4|2 3
+ * dodecahedron                 12/30/12         {5,5,5}         3|2 5
+ * icosahedron                  20/30/12         {3,3,3,3,3}     5|2 3
+ *Nice additions would be the Kepler-Poinsot Solids:
+ * small stellated dodecahedron 12/30/12      {5/2,5/2,5/2,5/2,5/2}   5|2 5/2
+ * great stellated dodecahedron 12/30/20         {5/2,5/2,5/2}   3|2 5/2
+ * great dodecahedron           12/30/12         {5,5,5,5,5}/2   5/2|2 5
+ * great icosahedron            20/30/12         {3,3,3,3,3}/2   5/2|2 3
+ */
+
+static Polyinfo polygons[] =
+{
+
+/* objtetra - structure values for tetrahedron */
+       {
+#ifdef DEFUNCT
+               "tetrahedron", "tetra",         /* long and short names */
+               "tetrahedron",  /* long name of dual */
+#endif
+               4, 6, 4,        /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+#define T 0.57735
+                       {T, T, T},
+                       {T, -T, -T},
+                       {-T, T, -T},
+                       {-T, -T, T},
+#undef T
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       3, 2, 1, 0,
+                       3, 1, 3, 0,
+                       3, 3, 2, 0,
+                       3, 2, 3, 1,
+               }
+       },
+
+/* objcube - structure values for cube */
+
+       {
+#ifdef DEFUNCT
+               "hexahedron", "cube",   /* long and short names */
+               "octahedron",   /* long name of dual */
+#endif
+               8, 12, 6,       /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+#define T 0.57735
+                       {T, T, T},
+                       {T, T, -T},
+                       {T, -T, -T},
+                       {T, -T, T},
+                       {-T, T, T},
+                       {-T, T, -T},
+                       {-T, -T, -T},
+                       {-T, -T, T},
+#undef T
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       4, 0, 1, 2, 3,
+                       4, 7, 6, 5, 4,
+                       4, 1, 0, 4, 5,
+                       4, 3, 2, 6, 7,
+                       4, 2, 1, 5, 6,
+                       4, 0, 3, 7, 4,
+               }
+       },
+
+/* objocta - structure values for octahedron */
+
+       {
+#ifdef DEFUNCT
+               "octahedron", "octa",   /* long and short names */
+               "hexahedron",   /* long name of dual */
+#endif
+               6, 12, 8,       /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+#define T 1.0
+                       {T, 0, 0},
+                       {-T, 0, 0},
+                       {0, T, 0},
+                       {0, -T, 0},
+                       {0, 0, T},
+                       {0, 0, -T},
+#undef T
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       3, 0, 4, 2,
+                       3, 0, 2, 5,
+                       3, 0, 5, 3,
+                       3, 0, 3, 4,
+                       3, 1, 2, 4,
+                       3, 1, 5, 2,
+                       3, 1, 3, 5,
+                       3, 1, 4, 3,
+               }
+       },
+
+/* objdodec - structure values for dodecahedron */
+
+       {
+#ifdef DEFUNCT
+               "dodecahedron", "dodeca",       /* long and short names */
+               "icosahedron",  /* long name of dual */
+#endif
+               20, 30, 12,     /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+                       {0.000000, 0.309017, 0.809015},
+                       {0.000000, -0.309017, 0.809015},
+                       {0.000000, -0.309017, -0.809015},
+                       {0.000000, 0.309017, -0.809015},
+                       {0.809015, 0.000000, 0.309017},
+                       {-0.809015, 0.000000, 0.309017},
+                       {-0.809015, 0.000000, -0.309017},
+                       {0.809015, 0.000000, -0.309017},
+                       {0.309017, 0.809015, 0.000000},
+                       {-0.309017, 0.809015, 0.000000},
+                       {-0.309017, -0.809015, 0.000000},
+                       {0.309017, -0.809015, 0.000000},
+                       {0.500000, 0.500000, 0.500000},
+                       {-0.500000, 0.500000, 0.500000},
+                       {-0.500000, -0.500000, 0.500000},
+                       {0.500000, -0.500000, 0.500000},
+                       {0.500000, -0.500000, -0.500000},
+                       {0.500000, 0.500000, -0.500000},
+                       {-0.500000, 0.500000, -0.500000},
+                       {-0.500000, -0.500000, -0.500000},
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       5, 12, 8, 17, 7, 4,
+                       5, 5, 6, 18, 9, 13,
+                       5, 14, 10, 19, 6, 5,
+                       5, 12, 4, 15, 1, 0,
+                       5, 13, 9, 8, 12, 0,
+                       5, 1, 14, 5, 13, 0,
+                       5, 16, 7, 17, 3, 2,
+                       5, 19, 10, 11, 16, 2,
+                       5, 3, 18, 6, 19, 2,
+                       5, 15, 11, 10, 14, 1,
+                       5, 3, 17, 8, 9, 18,
+                       5, 4, 7, 16, 11, 15,
+               }
+       },
+
+/* objicosa - structure values for icosahedron */
+
+       {
+#ifdef DEFUNCT
+               "icosahedron", "icosa",         /* long and short names */
+               "dodecahedron", /* long name of dual */
+#endif
+               12, 30, 20,     /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+                       {0.00000000, 0.00000000, -0.95105650},
+                       {0.00000000, 0.85065080, -0.42532537},
+                       {0.80901698, 0.26286556, -0.42532537},
+                       {0.50000000, -0.68819095, -0.42532537},
+                       {-0.50000000, -0.68819095, -0.42532537},
+                       {-0.80901698, 0.26286556, -0.42532537},
+                       {0.50000000, 0.68819095, 0.42532537},
+                       {0.80901698, -0.26286556, 0.42532537},
+                       {0.00000000, -0.85065080, 0.42532537},
+                       {-0.80901698, -0.26286556, 0.42532537},
+                       {-0.50000000, 0.68819095, 0.42532537},
+                       {0.00000000, 0.00000000, 0.95105650}
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       3, 0, 2, 1,
+                       3, 0, 3, 2,
+                       3, 0, 4, 3,
+                       3, 0, 5, 4,
+                       3, 0, 1, 5,
+                       3, 1, 6, 10,
+                       3, 1, 2, 6,
+                       3, 2, 7, 6,
+                       3, 2, 3, 7,
+                       3, 3, 8, 7,
+                       3, 3, 4, 8,
+                       3, 4, 9, 8,
+                       3, 4, 5, 9,
+                       3, 5, 10, 9,
+                       3, 5, 1, 10,
+                       3, 10, 6, 11,
+                       3, 6, 7, 11,
+                       3, 7, 8, 11,
+                       3, 8, 9, 11,
+                       3, 9, 10, 11
+               }
+       },
+
+/* objplane - structure values for plane */
+
+       {
+#ifdef DEFUNCT
+               "plane", "plane",       /* long and short names */
+               "plane",        /* long name of dual?? */
+#endif
+               4, 4, 1,        /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+#define T 1.0
+                       {T, 0, 0},
+                       {-T, 0, 0},
+                       {0, T, 0},
+                       {0, -T, 0},
+#undef T
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       4, 0, 2, 1, 3,
+               }
+       },
+
+/* objpyr - structure values for pyramid */
+
+       {
+#ifdef DEFUNCT
+               "pyramid", "pyramid",   /* long and short names */
+               "pyramid",      /* long name of dual */
+#endif
+               5, 8, 5,        /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+#define T 1.0
+                       {T, 0, 0},
+                       {-T, 0, 0},
+                       {0, T, 0},
+                       {0, -T, 0},
+                       {0, 0, T},
+               /* {  0,  0, -T }, */
+#undef T
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       3, 0, 4, 2,
+               /* 3,   0, 2, 5, */
+               /* 3,   0, 5, 3, */
+                       3, 0, 3, 4,
+                       3, 1, 2, 4,
+               /* 3,   1, 5, 2, */
+               /* 3,   1, 3, 5, */
+                       3, 1, 4, 3,
+                       4, 0, 2, 1, 3,
+               }
+       },
+
+#if 0
+  /* ico does not draw non-convex polyhedra well. */
+/* objstar - structure values for octahedron star (stellated octahedron?) */
+       {
+#ifdef DEFUNCT
+               "star", "star", /* long and short names */
+               "star",         /* long name of dual */
+#endif
+               8, 12, 8,       /* number of vertices, edges, and faces */
+               {               /* vertices (x,y,z) */
+                       /* all points must be within radius 1 of the origin */
+#define T 0.577
+                       {T, T, T},
+                       {T, -T, -T},
+                       {-T, T, -T},
+                       {-T, -T, T},
+                       {-T, -T, -T},
+                       {-T, T, T},
+                       {T, -T, T},
+                       {T, T, -T},
+#undef T
+               },
+               {               /* faces (numfaces + indexes into vertices) */
+               /*  faces must be specified clockwise from the outside */
+                       3, 2, 1, 0,
+                       3, 1, 3, 0,
+                       3, 3, 2, 0,
+                       3, 2, 3, 1,
+                       3, 6, 5, 4,
+                       3, 5, 7, 4,
+                       3, 7, 6, 4,
+                       3, 6, 7, 5,
+               }
+       },
+  /* Needed 4 other 3-D stars */
+#endif
+
+};
+
+static int  polysize = sizeof (polygons) / sizeof (polygons[0]);
+
+
+typedef double Transform3D[4][4];
+
+/* variables that need to be per-thread */
+
+typedef struct {
+       int         loopcount;
+       int         object;
+       int         width, height;
+       int         color;
+       Polyinfo   *poly;
+       int         polyW, polyH;
+       int         currX, currY;
+       int         prevX, prevY;
+       int         polyDeltaX, polyDeltaY;
+       int         polydeltax2, polydeltay2;
+       Bool        faces, edges;
+       char        drawn[MAXNV][MAXNV];
+       int         xv_buffer;
+       Transform3D xform;
+       Point3D     xv[2][MAXNV];
+       double      wo2, ho2;
+} icostruct;
+
+static icostruct *icos = NULL;
+
+/*-
+ * variables that are not set except maybe in initialization before
+ * any additional threads are created
+ */
+
+
+static void
+icoClearArea(ModeInfo * mi, int x, int y, int w, int h)
+{
+       Display    *display = MI_DISPLAY(mi);
+
+#if 1
+       /* my monochrome likes this better */
+       XSetForeground(display, MI_GC(mi), MI_BLACK_PIXEL(mi));
+       XFillRectangle(display, MI_WINDOW(mi), MI_GC(mi), x, y, w, h);
+#else
+       XClearArea(display, MI_WINDOW(mi), x, y, w, h, 0);
+#endif
+}
+
+/******************************************************************************
+ * Description
+ *     Format a 4x4 identity matrix.
+ *
+ * Output
+ *     *m              Formatted identity matrix
+ *****************************************************************************/
+static void
+IdentMat(register Transform3D m)
+{
+       register int i;
+       register int j;
+
+       for (i = 3; i >= 0; --i) {
+               for (j = 3; j >= 0; --j)
+                       m[i][j] = 0.0;
+               m[i][i] = 1.0;
+       }
+}
+
+
+
+/******************************************************************************
+ * Description
+ *     Format a matrix that will perform a rotation transformation
+ *     about the specified axis.  The rotation angle is measured
+ *     counterclockwise about the specified axis when looking
+ *     at the origin from the positive axis.
+ *
+ * Input
+ *     axis            Axis ('x', 'y', 'z') about which to perform rotation
+ *     angle           Angle (in radians) of rotation
+ *     A               Pointer to rotation matrix
+ *
+ * Output
+ *     *m              Formatted rotation matrix
+ *****************************************************************************/
+
+static void
+FormatRotateMat(char axis, double angle, register Transform3D m)
+{
+       double      s, c;
+
+       IdentMat(m);
+
+       s = sin(angle);
+       c = cos(angle);
+
+       switch (axis) {
+               case 'x':
+                       m[1][1] = m[2][2] = c;
+                       m[1][2] = s;
+                       m[2][1] = -s;
+                       break;
+               case 'y':
+                       m[0][0] = m[2][2] = c;
+                       m[2][0] = s;
+                       m[0][2] = -s;
+                       break;
+               case 'z':
+                       m[0][0] = m[1][1] = c;
+                       m[0][1] = s;
+                       m[1][0] = -s;
+                       break;
+       }
+}
+
+
+/******************************************************************************
+ * Description
+ *     Concatenate two 4-by-4 transformation matrices.
+ *
+ * Input
+ *     l               multiplicand (left operand)
+ *     r               multiplier (right operand)
+ *
+ * Output
+ *     *m              Result matrix
+ *****************************************************************************/
+
+static void
+ConcatMat(register Transform3D l, register Transform3D r,
+         register Transform3D m)
+{
+       register int i;
+       register int j;
+
+       for (i = 0; i < 4; ++i)
+               for (j = 0; j < 4; ++j)
+                       m[i][j] = l[i][0] * r[0][j]
+                               + l[i][1] * r[1][j]
+                               + l[i][2] * r[2][j]
+                               + l[i][3] * r[3][j];
+}
+
+/* Set up points, transforms, etc.  */
+
+static void
+initPoly(ModeInfo * mi, Polyinfo * poly, int icoW, int icoH)
+{
+       icostruct  *ip = &icos[MI_SCREEN(mi)];
+       Point3D    *vertices = poly->v;
+       int         NV = poly->numverts;
+       Transform3D r1;
+       Transform3D r2;
+
+       FormatRotateMat('x', 5 * M_PI / 180.0, r1);
+       FormatRotateMat('y', 5 * M_PI / 180.0, r2);
+       ConcatMat(r1, r2, ip->xform);
+
+       (void) memcpy((char *) ip->xv[0], (char *) vertices, NV * sizeof (Point3D));
+       ip->xv_buffer = 0;
+       ip->wo2 = icoW / 2.0;
+       ip->ho2 = icoH / 2.0;
+}
+
+/******************************************************************************
+ * Description
+ *     Perform a partial transform on non-homogeneous points.
+ *     Given an array of non-homogeneous (3-coordinate) input points,
+ *     this routine multiplies them by the 3-by-3 upper left submatrix
+ *     of a standard 4-by-4 transform matrix.  The resulting non-homogeneous
+ *     points are returned.
+ *
+ * Input
+ *     n               number of points to transform
+ *     m               4-by-4 transform matrix
+ *     in              array of non-homogeneous input points
+ *
+ * Output
+ *     *out            array of transformed non-homogeneous output points
+ *****************************************************************************/
+
+static void
+PartialNonHomTransform(int n, register Transform3D m,
+                      register Point3D * in, register Point3D * out)
+{
+       for (; n > 0; --n, ++in, ++out) {
+               out->x = in->x * m[0][0] + in->y * m[1][0] + in->z * m[2][0];
+               out->y = in->x * m[0][1] + in->y * m[1][1] + in->z * m[2][1];
+               out->z = in->x * m[0][2] + in->y * m[1][2] + in->z * m[2][2];
+       }
+}
+
+
+/******************************************************************************
+ * Description
+ *     Undraw previous polyhedron (by erasing its bounding box).
+ *     Rotate and draw the new polyhedron.
+ *
+ * Input
+ *     poly            the polyhedron to draw
+ *     gc              X11 graphics context to be used for drawing
+ *     icoX, icoY      position of upper left of bounding-box
+ *     icoW, icoH      size of bounding-box
+ *     prevX, prevY    position of previous bounding-box
+ *****************************************************************************/
+
+static void
+drawPoly(ModeInfo * mi, Polyinfo * poly, GC gc,
+        int icoX, int icoY, int icoW, int icoH, int prevX, int prevY)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       icostruct  *ip = &icos[MI_SCREEN(mi)];
+       int        *f = poly->f;
+       int         NV = poly->numverts;
+       int         NF = poly->numfaces;
+
+       register int p0;
+       register int p1;
+       register XPoint *pv2;
+       XSegment   *pe;
+       register Point3D *pxv;
+       XPoint      v2[MAXNV];
+       XSegment    edge_segs[MAXEDGES];
+       register int i;
+       int         j, k;
+       register int *pf;
+       int         facecolor;
+
+       int         pcount;
+       double      pxvz;
+       XPoint      ppts[MAXEDGESPERPOLY];
+
+       /* Switch double-buffer and rotate vertices */
+
+       ip->xv_buffer = !ip->xv_buffer;
+       PartialNonHomTransform(NV, ip->xform,
+                              ip->xv[!ip->xv_buffer], ip->xv[ip->xv_buffer]);
+
+
+       /* Convert 3D coordinates to 2D window coordinates: */
+
+       pxv = ip->xv[ip->xv_buffer];
+       pv2 = v2;
+       for (i = NV - 1; i >= 0; --i) {
+               pv2->x = (int) ((pxv->x + 1.0) * ip->wo2) + icoX;
+               pv2->y = (int) ((pxv->y + 1.0) * ip->ho2) + icoY;
+               ++pxv;
+               ++pv2;
+       }
+
+
+       /* Accumulate edges to be drawn, eliminating duplicates for speed: */
+
+       pxv = ip->xv[ip->xv_buffer];
+       pv2 = v2;
+       pf = f;
+       pe = edge_segs;
+       (void) memset(ip->drawn, 0, sizeof (ip->drawn));
+
+       /* for faces, need to clear before FillPoly */
+       if (ip->faces) {        /* multibuf uses update background */
+               icoClearArea(mi, prevX, prevY, icoW + 1, icoH + 1);
+       }
+       for (i = NF - 1; i >= 0; --i, pf += pcount) {
+
+               pcount = *pf++; /* number of edges for this face */
+               pxvz = 0.0;
+               for (j = 0; j < pcount; j++) {
+                       p0 = pf[j];
+                       pxvz += pxv[p0].z;
+               }
+
+               /* If facet faces away from viewer, don't consider it: */
+               if (pxvz < 0.0)
+                       continue;
+
+               if (ip->faces) {
+                       if (MI_NPIXELS(mi) > 2)
+                               facecolor = i % (MI_NPIXELS(mi)) + 1;
+                       else
+                               facecolor = 1;
+
+                       for (j = 0; j < pcount; j++) {
+                               p0 = pf[j];
+                               ppts[j].x = pv2[p0].x;
+                               ppts[j].y = pv2[p0].y;
+                       }
+                       if (MI_NPIXELS(mi) <= 2)
+                               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                       else
+                               XSetForeground(display, gc, MI_PIXEL(mi, facecolor));
+                       XFillPolygon(display, window, gc, ppts, pcount,
+                                    Convex, CoordModeOrigin);
+               }
+               if (ip->edges) {
+                       for (j = 0; j < pcount; j++) {
+                               if (j < pcount - 1)
+                                       k = j + 1;
+                               else
+                                       k = 0;
+                               p0 = pf[j];
+                               p1 = pf[k];
+                               if (!ip->drawn[p0][p1]) {
+                                       ip->drawn[p0][p1] = 1;
+                                       ip->drawn[p1][p0] = 1;
+                                       pe->x1 = pv2[p0].x;
+                                       pe->y1 = pv2[p0].y;
+                                       pe->x2 = pv2[p1].x;
+                                       pe->y2 = pv2[p1].y;
+                                       ++pe;
+                               }
+                       }
+               }
+       }
+
+       /* Erase previous, draw current icosahedrons; sync for smoothness. */
+
+       if (ip->edges) {
+               icoClearArea(mi, prevX, prevY, icoW + 1, icoH + 1);
+               if (MI_NPIXELS(mi) <= 2)
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               else {
+                       ip->color = (ip->color + 1) % MI_NPIXELS(mi);
+                       XSetForeground(display, gc, MI_PIXEL(mi, ip->color));
+               }
+               XDrawSegments(display, window, gc, edge_segs, pe - edge_segs);
+       }
+}
+
+void
+init_ico(ModeInfo * mi)
+{
+       icostruct  *ip;
+       int         size = MI_SIZE(mi);
+
+       if (icos == NULL) {
+               if ((icos = (icostruct *) calloc(MI_NUM_SCREENS(mi),
+                                                sizeof (icostruct))) == NULL)
+                       return;
+       }
+       ip = &icos[MI_SCREEN(mi)];
+
+       ip->width = MI_WIDTH(mi);
+       ip->height = MI_HEIGHT(mi);
+
+       ip->edges = edges;
+#ifdef DEBUG
+       ip->faces = faces;
+#else
+       ip->faces = faces = 0;
+#endif
+       /*ip->linewidth
+          if (!ip->faces && !ip->edges) icoFatal("nothing to draw"); */
+
+       if (size < -MINSIZE)
+               ip->polyW = NRAND(MIN(-size, MAX(MINSIZE,
+                  MIN(ip->width, ip->height) / 4)) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE) {
+               if (!size)
+                       ip->polyW = MAX(MINSIZE, MIN(ip->width, ip->height) / 4);
+               else
+                       ip->polyW = MINSIZE;
+       } else
+               ip->polyW = MIN(size, MAX(MINSIZE,
+                                         MIN(ip->width, ip->height) / 4));
+
+       ip->polyH = ip->polyW;
+       ip->polyDeltaX = ip->polyW / DEFAULT_DELTAY + 1;
+       ip->polyDeltaY = ip->polyH / DEFAULT_DELTAX + 1;
+       ip->currX = NRAND(ip->width - ip->polyW);
+       ip->currY = NRAND(ip->height - ip->polyH);
+
+       /* Bounce the box in the window */
+
+       ip->polydeltax2 = ip->polyDeltaX * 2;
+       ip->polydeltay2 = ip->polyDeltaY * 2;
+
+       ip->loopcount = 0;
+
+       ip->object = MI_COUNT(mi) - 1;
+       if (ip->object < 0 || ip->object >= polysize)
+               ip->object = NRAND(polysize);
+       ip->poly = polygons + ip->object;
+       if (MI_NPIXELS(mi) > 2)
+               ip->color = NRAND(MI_NPIXELS(mi));
+
+       MI_CLEARWINDOW(mi);
+
+       initPoly(mi, ip->poly, ip->polyW, ip->polyH);
+}
+
+void
+draw_ico(ModeInfo * mi)
+{
+       icostruct  *ip = &icos[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (++ip->loopcount > MI_CYCLES(mi))
+               init_ico(mi);
+
+       ip->prevX = ip->currX;
+       ip->prevY = ip->currY;
+
+       ip->currX += ip->polyDeltaX;
+       if (ip->currX < 0 || ip->currX + ip->polyW > ip->width) {
+
+               ip->currX -= ip->polydeltax2;
+               ip->polyDeltaX = -ip->polyDeltaX;
+               ip->polydeltax2 = ip->polyDeltaX * 2;
+       }
+       ip->currY += ip->polyDeltaY;
+       if (ip->currY < 0 || ip->currY + ip->polyH > ip->height) {
+               ip->currY -= ip->polydeltay2;
+               ip->polyDeltaY = -ip->polyDeltaY;
+               ip->polydeltay2 = ip->polyDeltaY * 2;
+       }
+       drawPoly(mi, ip->poly, MI_GC(mi),
+          ip->currX, ip->currY, ip->polyW, ip->polyH, ip->prevX, ip->prevY);
+}
+void
+refresh_ico(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+void
+release_ico(ModeInfo * mi)
+{
+       if (icos != NULL) {
+               (void) free((void *) icos);
+               icos = NULL;
+       }
+}
+
+void
+change_ico(ModeInfo * mi)
+{
+       icostruct  *ip = &icos[MI_SCREEN(mi)];
+
+       ip->object = (ip->object + 1) % polysize;
+       ip->poly = polygons + ip->object;
+       ip->loopcount = 0;
+
+       MI_CLEARWINDOW(mi);
+
+       initPoly(mi, ip->poly, ip->polyW, ip->polyH);
+}
+
+#endif /* MODE_ico */
diff --git a/xlockmore-4.14/modes/ifs.c b/xlockmore-4.14/modes/ifs.c
new file mode 100644 (file)
index 0000000..b531918
--- /dev/null
@@ -0,0 +1,485 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* ifs --- modified iterated functions system */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)ifs.c        4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by Massimino Pascal <Pascal.Massimon@ens.fr>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * If this mode is weird and you have an old MetroX server, it is buggy.
+ * There is a free SuSE-enhanced MetroX X server that is fine.
+ *
+ * When shown ifs, Diana Rose (4 years old) said, "It looks like dancing."
+ *
+ * Revision History:
+ * 10-May-97: jwz@jwz.org: turned into a standalone program.
+ *            Made it render into an offscreen bitmap and then copy
+ *            that onto the screen, to reduce flicker.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "IFS"
+#define HACK_INIT init_ifs
+#define HACK_DRAW draw_ifs
+#define ifs_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*ncolors: 100 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_ifs
+
+ModeSpecOpt ifs_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   ifs_description =
+{"ifs", "init_ifs", "draw_ifs", "release_ifs",
+ "init_ifs", "init_ifs", NULL, &ifs_opts,
+ 1000, 1, 1, 1, 64, 1.0, "",
+ "Shows a modified iterated function system", 0, NULL};
+
+#endif
+
+/*****************************************************/
+
+typedef float DBL;
+typedef int F_PT;
+
+/* typedef float               F_PT; */
+
+/*****************************************************/
+
+#define FIX 12
+#define UNIT   ( 1<<FIX )
+#define MAX_SIMI  6
+
+   /* settings for a PC 120Mhz... */
+#define MAX_DEPTH_2  10
+#define MAX_DEPTH_3  6
+#define MAX_DEPTH_4  4
+#define MAX_DEPTH_5  3
+
+#define DBL_To_F_PT(x)  (F_PT)( (DBL)(UNIT)*(x) )
+
+typedef struct Similitude_Struct SIMI;
+typedef struct Fractal_Struct FRACTAL;
+
+struct Similitude_Struct {
+
+       DBL         c_x, c_y;
+       DBL         r, r2, A, A2;
+       F_PT        Ct, St, Ct2, St2;
+       F_PT        Cx, Cy;
+       F_PT        R, R2;
+};
+
+struct Fractal_Struct {
+
+       int         Nb_Simi;
+       SIMI        Components[5 * MAX_SIMI];
+       int         Depth, Col;
+       int         Count, Speed;
+       int         Width, Height, Lx, Ly;
+       DBL         r_mean, dr_mean, dr2_mean;
+       int         Cur_Pt, Max_Pt;
+       XPoint     *Buffer1, *Buffer2;
+       Pixmap      dbuf;
+       GC          dbuf_gc;
+};
+
+static FRACTAL *Root = NULL, *Cur_F;
+static XPoint *Buf;
+static int  Cur_Pt;
+
+
+/*****************************************************/
+
+static      DBL
+Gauss_Rand(DBL c, DBL A, DBL S)
+{
+       DBL         y;
+
+       y = (DBL) LRAND() / MAXRAND;
+       y = A * (1.0 - exp(-y * y * S)) / (1.0 - exp(-S));
+       if (NRAND(2))
+               return (c + y);
+       return (c - y);
+}
+
+static      DBL
+Half_Gauss_Rand(DBL c, DBL A, DBL S)
+{
+       DBL         y;
+
+       y = (DBL) LRAND() / MAXRAND;
+       y = A * (1.0 - exp(-y * y * S)) / (1.0 - exp(-S));
+       return (c + y);
+}
+
+static void
+Random_Simis(FRACTAL * F, SIMI * Cur, int i)
+{
+       while (i--) {
+               Cur->c_x = Gauss_Rand(0.0, .8, 4.0);
+               Cur->c_y = Gauss_Rand(0.0, .8, 4.0);
+               Cur->r = Gauss_Rand(F->r_mean, F->dr_mean, 3.0);
+               Cur->r2 = Half_Gauss_Rand(0.0, F->dr2_mean, 2.0);
+               Cur->A = Gauss_Rand(0.0, 360.0, 4.0) * (M_PI / 180.0);
+               Cur->A2 = Gauss_Rand(0.0, 360.0, 4.0) * (M_PI / 180.0);
+               Cur++;
+       }
+}
+
+/***************************************************************/
+
+void
+init_ifs(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       int         i;
+       FRACTAL    *Fractal;
+
+       if (Root == NULL) {
+               Root = (FRACTAL *) calloc(
+                                      MI_NUM_SCREENS(mi), sizeof (FRACTAL));
+               if (Root == NULL)
+                       return;
+       }
+       Fractal = &Root[MI_SCREEN(mi)];
+
+       if (Fractal->Buffer1 != NULL) {
+               (void) free((void *) Fractal->Buffer1);
+               Fractal->Buffer1 = NULL;
+       }
+       if (Fractal->Buffer2 != NULL) {
+               (void) free((void *) Fractal->Buffer2);
+               Fractal->Buffer2 = NULL;
+       }
+       i = (NRAND(4)) + 2;     /* Number of centers */
+       switch (i) {
+               case 3:
+                       Fractal->Depth = MAX_DEPTH_3;
+                       Fractal->r_mean = .6;
+                       Fractal->dr_mean = .4;
+                       Fractal->dr2_mean = .3;
+                       break;
+
+               case 4:
+                       Fractal->Depth = MAX_DEPTH_4;
+                       Fractal->r_mean = .5;
+                       Fractal->dr_mean = .4;
+                       Fractal->dr2_mean = .3;
+                       break;
+
+               case 5:
+                       Fractal->Depth = MAX_DEPTH_5;
+                       Fractal->r_mean = .5;
+                       Fractal->dr_mean = .4;
+                       Fractal->dr2_mean = .3;
+                       break;
+
+               default:
+               case 2:
+                       Fractal->Depth = MAX_DEPTH_2;
+                       Fractal->r_mean = .7;
+                       Fractal->dr_mean = .3;
+                       Fractal->dr2_mean = .4;
+                       break;
+       }
+       /* (void) fprintf( stderr, "N=%d\n", i ); */
+       Fractal->Nb_Simi = i;
+       Fractal->Max_Pt = Fractal->Nb_Simi - 1;
+       for (i = 0; i <= Fractal->Depth + 2; ++i)
+               Fractal->Max_Pt *= Fractal->Nb_Simi;
+
+       Fractal->Buffer1 = (XPoint *) calloc(Fractal->Max_Pt, sizeof (XPoint));
+       Fractal->Buffer2 = (XPoint *) calloc(Fractal->Max_Pt, sizeof (XPoint));
+       if (Fractal->Buffer1 == NULL || Fractal->Buffer2 == NULL) {
+               if (Fractal->Buffer1 != NULL) {
+                       (void) free((void *) Fractal->Buffer1);
+                       Fractal->Buffer1 = NULL;
+               }
+               if (Fractal->Buffer2 != NULL) {
+                       (void) free((void *) Fractal->Buffer2);
+                       Fractal->Buffer2 = NULL;
+               }
+               Fractal->Max_Pt = 0;
+               return;
+       }
+       Fractal->Speed = 6;
+       Fractal->Width = MI_WIDTH(mi);
+       Fractal->Height = MI_HEIGHT(mi);
+       Fractal->Cur_Pt = 0;
+       Fractal->Count = 0;
+       Fractal->Lx = (Fractal->Width - 1) / 2;
+       Fractal->Ly = (Fractal->Height - 1) / 2;
+       Fractal->Col = NRAND(MI_NPIXELS(mi) - 1) + 1;
+
+       Random_Simis(Fractal, Fractal->Components, 5 * MAX_SIMI);
+
+       if (Fractal->dbuf)
+               XFreePixmap(display, Fractal->dbuf);
+       Fractal->dbuf = XCreatePixmap(display, window,
+                                     Fractal->Width, Fractal->Height, 1);
+       if (Fractal->dbuf) {
+               XGCValues   gcv;
+
+               gcv.foreground = 0;
+               gcv.background = 0;
+               gcv.graphics_exposures = False;
+               gcv.function = GXcopy;
+
+               if (Fractal->dbuf_gc)
+                       XFreeGC(display, Fractal->dbuf_gc);
+               Fractal->dbuf_gc = XCreateGC(display, Fractal->dbuf,
+                                            GCForeground | GCBackground | GCGraphicsExposures | GCFunction,
+                                            &gcv);
+               XFillRectangle(display, Fractal->dbuf,
+                   Fractal->dbuf_gc, 0, 0, Fractal->Width, Fractal->Height);
+               XSetBackground(display, gc, MI_BLACK_PIXEL(mi));
+               XSetFunction(display, gc, GXcopy);
+       }
+       MI_CLEARWINDOW(mi);
+
+       /* don't want any exposure events from XCopyPlane */
+       XSetGraphicsExposures(display, gc, False);
+
+}
+
+
+/***************************************************************/
+
+/* Should be taken care of already... but just in case */
+#if !defined( __GNUC__ ) && !defined(__cplusplus) && !defined(c_plusplus)
+#undef inline
+#define inline                 /* */
+#endif
+static inline void
+Transform(SIMI * Simi, F_PT xo, F_PT yo, F_PT * x, F_PT * y)
+{
+       F_PT        xx, yy;
+
+       xo = xo - Simi->Cx;
+       xo = (xo * Simi->R) / UNIT;
+       yo = yo - Simi->Cy;
+       yo = (yo * Simi->R) / UNIT;
+
+       xx = xo - Simi->Cx;
+       xx = (xx * Simi->R2) / UNIT;
+       yy = -yo - Simi->Cy;
+       yy = (yy * Simi->R2) / UNIT;
+
+       *x = ((xo * Simi->Ct - yo * Simi->St + xx * Simi->Ct2 - yy * Simi->St2) / UNIT) + Simi->Cx;
+       *y = ((xo * Simi->St + yo * Simi->Ct + xx * Simi->St2 + yy * Simi->Ct2) / UNIT) + Simi->Cy;
+}
+
+/***************************************************************/
+
+static void
+Trace(FRACTAL * F, F_PT xo, F_PT yo)
+{
+       F_PT        x, y, i;
+       SIMI       *Cur;
+
+       Cur = Cur_F->Components;
+       for (i = Cur_F->Nb_Simi; i; --i, Cur++) {
+               Transform(Cur, xo, yo, &x, &y);
+               Buf->x = F->Lx + (x * F->Lx / (UNIT * 2));
+               Buf->y = F->Ly - (y * F->Ly / (UNIT * 2));
+               Buf++;
+               Cur_Pt++;
+
+               if (F->Depth && ((x - xo) >> 4) && ((y - yo) >> 4)) {
+                       F->Depth--;
+                       Trace(F, x, y);
+                       F->Depth++;
+               }
+       }
+}
+
+static void
+Draw_Fractal(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       FRACTAL    *F = &Root[MI_SCREEN(mi)];
+       int         i, j;
+       F_PT        x, y, xo, yo;
+       SIMI       *Cur, *Simi;
+
+       for (Cur = F->Components, i = F->Nb_Simi; i; --i, Cur++) {
+               Cur->Cx = DBL_To_F_PT(Cur->c_x);
+               Cur->Cy = DBL_To_F_PT(Cur->c_y);
+
+               Cur->Ct = DBL_To_F_PT(cos(Cur->A));
+               Cur->St = DBL_To_F_PT(sin(Cur->A));
+               Cur->Ct2 = DBL_To_F_PT(cos(Cur->A2));
+               Cur->St2 = DBL_To_F_PT(sin(Cur->A2));
+
+               Cur->R = DBL_To_F_PT(Cur->r);
+               Cur->R2 = DBL_To_F_PT(Cur->r2);
+       }
+
+
+       Cur_Pt = 0;
+       Cur_F = F;
+       Buf = F->Buffer2;
+       for (Cur = F->Components, i = F->Nb_Simi; i; --i, Cur++) {
+               xo = Cur->Cx;
+               yo = Cur->Cy;
+               for (Simi = F->Components, j = F->Nb_Simi; j; --j, Simi++) {
+                       if (Simi == Cur)
+                               continue;
+                       Transform(Simi, xo, yo, &x, &y);
+                       Trace(F, x, y);
+               }
+       }
+
+       /* Erase previous */
+
+       if (F->Cur_Pt) {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               if (F->dbuf) {
+                       XSetForeground(display, F->dbuf_gc, 0);
+/* XDrawPoints(display, F->dbuf, F->dbuf_gc, F->Buffer1, F->Cur_Pt,
+   CoordModeOrigin); */
+                       XFillRectangle(display, F->dbuf, F->dbuf_gc, 0, 0,
+                                      F->Width, F->Height);
+               } else
+                       XDrawPoints(display, window, gc, F->Buffer1, F->Cur_Pt, CoordModeOrigin);
+       }
+       if (MI_NPIXELS(mi) < 2)
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       else
+               XSetForeground(display, gc, MI_PIXEL(mi, F->Col % MI_NPIXELS(mi)));
+       if (Cur_Pt) {
+               if (F->dbuf) {
+                       XSetForeground(display, F->dbuf_gc, 1);
+                       XDrawPoints(display, F->dbuf, F->dbuf_gc, F->Buffer2, Cur_Pt,
+                                   CoordModeOrigin);
+               } else
+                       XDrawPoints(display, window, gc, F->Buffer2, Cur_Pt, CoordModeOrigin);
+       }
+       if (F->dbuf)
+               XCopyPlane(display, F->dbuf, window, gc, 0, 0, F->Width, F->Height, 0, 0, 1);
+
+       F->Cur_Pt = Cur_Pt;
+       Buf = F->Buffer1;
+       F->Buffer1 = F->Buffer2;
+       F->Buffer2 = Buf;
+}
+
+
+void
+draw_ifs(ModeInfo * mi)
+{
+       int         i;
+       FRACTAL    *F = &Root[MI_SCREEN(mi)];
+       DBL         u, uu, v, vv, u0, u1, u2, u3;
+       SIMI       *S, *S1, *S2, *S3, *S4;
+
+       u = (DBL) (F->Count) * (DBL) (F->Speed) / 1000.0;
+       uu = u * u;
+       v = 1.0 - u;
+       vv = v * v;
+       u0 = vv * v;
+       u1 = 3.0 * vv * u;
+       u2 = 3.0 * v * uu;
+       u3 = u * uu;
+
+       S = F->Components;
+       S1 = S + F->Nb_Simi;
+       S2 = S1 + F->Nb_Simi;
+       S3 = S2 + F->Nb_Simi;
+       S4 = S3 + F->Nb_Simi;
+
+       for (i = F->Nb_Simi; i; --i, S++, S1++, S2++, S3++, S4++) {
+               S->c_x = u0 * S1->c_x + u1 * S2->c_x + u2 * S3->c_x + u3 * S4->c_x;
+               S->c_y = u0 * S1->c_y + u1 * S2->c_y + u2 * S3->c_y + u3 * S4->c_y;
+               S->r = u0 * S1->r + u1 * S2->r + u2 * S3->r + u3 * S4->r;
+               S->r2 = u0 * S1->r2 + u1 * S2->r2 + u2 * S3->r2 + u3 * S4->r2;
+               S->A = u0 * S1->A + u1 * S2->A + u2 * S3->A + u3 * S4->A;
+               S->A2 = u0 * S1->A2 + u1 * S2->A2 + u2 * S3->A2 + u3 * S4->A2;
+       }
+
+       MI_IS_DRAWN(mi) = True;
+
+       Draw_Fractal(mi);
+
+       if (F->Count >= 1000 / F->Speed) {
+               S = F->Components;
+               S1 = S + F->Nb_Simi;
+               S2 = S1 + F->Nb_Simi;
+               S3 = S2 + F->Nb_Simi;
+               S4 = S3 + F->Nb_Simi;
+
+               for (i = F->Nb_Simi; i; --i, S++, S1++, S2++, S3++, S4++) {
+                       S2->c_x = 2.0 * S4->c_x - S3->c_x;
+                       S2->c_y = 2.0 * S4->c_y - S3->c_y;
+                       S2->r = 2.0 * S4->r - S3->r;
+                       S2->r2 = 2.0 * S4->r2 - S3->r2;
+                       S2->A = 2.0 * S4->A - S3->A;
+                       S2->A2 = 2.0 * S4->A2 - S3->A2;
+
+                       *S1 = *S4;
+               }
+               Random_Simis(F, F->Components + 3 * F->Nb_Simi, F->Nb_Simi);
+
+               Random_Simis(F, F->Components + 4 * F->Nb_Simi, F->Nb_Simi);
+
+               F->Count = 0;
+       } else
+               F->Count++;
+
+       F->Col++;
+}
+
+
+/***************************************************************/
+
+void
+release_ifs(ModeInfo * mi)
+{
+       int         screen;
+
+       if (Root != NULL) {
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       FRACTAL    *Fractal = &Root[screen];
+
+                       if (Fractal->Buffer1 != NULL)
+                               (void) free((void *) Fractal->Buffer1);
+                       if (Fractal->Buffer2 != NULL)
+                               (void) free((void *) Fractal->Buffer2);
+                       if (Fractal->dbuf)
+                               XFreePixmap(MI_DISPLAY(mi), Fractal->dbuf);
+                       if (Fractal->dbuf_gc)
+                               XFreeGC(MI_DISPLAY(mi), Fractal->dbuf_gc);
+               }
+               (void) free((void *) Root);
+               Root = NULL;
+       }
+}
+
+#endif /* MODE_ifs */
diff --git a/xlockmore-4.14/modes/image.c b/xlockmore-4.14/modes/image.c
new file mode 100644 (file)
index 0000000..e935075
--- /dev/null
@@ -0,0 +1,257 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* image --- image bouncer */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)image.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 03-Nov-95: Patched to add an arbitrary xpm file. 
+ * 21-Sep-95: Patch if xpm fails to load <Markus.Zellner@anu.edu.au>.
+ * 17-Jun-95: Pixmap stuff of Skip_Burrell@sterling.com added.
+ * 07-Dec-94: Icons are now better centered if do not exactly fill an area.
+ * 29-Jul-90: Written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Image"
+#define HACK_INIT init_image
+#define HACK_DRAW draw_image
+#define image_opts xlockmore_opts
+#define DEFAULTS "*delay: 2000000 \n" \
+ "*count: -10 \n" \
+ "*ncolors: 200 \n" \
+ "*bitmap: \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_image
+
+ModeSpecOpt image_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   image_description =
+{"image", "init_image", "draw_image", "release_image",
+ "refresh_image", "init_image", NULL, &image_opts,
+ 2000000, -10, 1, 1, 64, 1.0, "",
+ "Shows randomly appearing logos", 0, NULL};
+
+#endif
+
+/* aliases for vars defined in the bitmap file */
+#define IMAGE_WIDTH    image_width
+#define IMAGE_HEIGHT   image_height
+#define IMAGE_BITS     image_bits
+
+#include "image.xbm"
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+#define IMAGE_NAME     image_name
+#include "image.xpm"
+#define DEFAULT_XPM 1
+#endif
+
+#define MINICONS 1
+
+typedef struct {
+       int         x, y;
+       int         color;
+} imagetype;
+
+typedef struct {
+       int         width, height;
+       int         nrows, ncols;
+       XPoint      image_offset;
+       int         iconcount;
+       imagetype  *icons;
+       int         graphics_format;
+       GC          backGC;
+       XImage     *logo;
+       Colormap    cmap;
+       unsigned long black;
+} imagestruct;
+
+static imagestruct *ims = NULL;
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       imagestruct *ip = &ims[MI_SCREEN(mi)];
+
+       if (!ip->logo)
+               getImage(mi, &ip->logo, IMAGE_WIDTH, IMAGE_HEIGHT, IMAGE_BITS,
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                        DEFAULT_XPM, IMAGE_NAME,
+#endif
+                        &ip->graphics_format, &ip->cmap, &ip->black);
+#ifndef STANDALONE
+       if (ip->cmap != None) {
+               setColormap(display, window, ip->cmap, MI_IS_INWINDOW(mi));
+               if (ip->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = ip->black;
+                       ip->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else
+#endif /* STANDALONE */
+       {
+               ip->black = MI_BLACK_PIXEL(mi);
+               ip->backGC = MI_GC(mi);
+       }
+}
+
+static void
+free_stuff(Display * display, imagestruct * ip)
+{
+       if (ip->cmap != None) {
+               XFreeColormap(display, ip->cmap);
+               if (ip->backGC != None) {
+                       XFreeGC(display, ip->backGC);
+                       ip->backGC = None;
+               }
+               ip->cmap = None;
+       } else
+               ip->backGC = None;
+       destroyImage(&ip->logo, &ip->graphics_format);
+}
+
+void
+refresh_image(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       imagestruct *ip = &ims[MI_SCREEN(mi)];
+       int         i;
+
+       MI_CLEARWINDOWCOLORMAP(mi, ip->backGC, ip->black);
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       /* This is needed when another program changes the colormap. */
+       free_stuff(MI_DISPLAY(mi), ip);
+       init_stuff(mi);
+#endif
+       if (MI_NPIXELS(mi) <= 2)
+               XSetForeground(display, ip->backGC, MI_WHITE_PIXEL(mi));
+       for (i = 0; i < ip->iconcount; i++) {
+               if (ip->logo != NULL && ip->icons[i].x >= 0) {
+                       if (MI_NPIXELS(mi) > 2 && ip->graphics_format < IS_XPM)
+                               XSetForeground(display, ip->backGC, MI_PIXEL(mi, ip->icons[i].color));
+                       (void) XPutImage(display, window, ip->backGC, ip->logo, 0, 0,
+                       ip->logo->width * ip->icons[i].x + ip->image_offset.x,
+                                        ip->logo->height * ip->icons[i].y + ip->image_offset.y,
+                                        ip->logo->width, ip->logo->height);
+               }
+       }
+}
+
+void
+init_image(ModeInfo * mi)
+{
+       imagestruct *ip;
+       int         i;
+
+       if (ims == NULL) {
+               if ((ims = (imagestruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (imagestruct))) == NULL)
+                       return;
+       }
+       ip = &ims[MI_SCREEN(mi)];
+
+       init_stuff(mi);
+
+       ip->width = MI_WIDTH(mi);
+       ip->height = MI_HEIGHT(mi);
+       if (ip->width > ip->logo->width)
+               ip->ncols = ip->width / ip->logo->width;
+       else
+               ip->ncols = 1;
+       if (ip->height > ip->logo->height)
+               ip->nrows = ip->height / ip->logo->height;
+       else
+               ip->nrows = 1;
+       ip->image_offset.x = (ip->width - ip->ncols * ip->logo->width) / 2;
+       ip->image_offset.y = (ip->height - ip->nrows * ip->logo->height) / 2;
+       ip->iconcount = MI_COUNT(mi);
+       if (ip->iconcount < -MINICONS)
+               ip->iconcount = NRAND(-ip->iconcount - MINICONS + 1) + MINICONS;
+       else if (ip->iconcount < MINICONS)
+               ip->iconcount = MINICONS;
+       if (ip->iconcount > ip->ncols * ip->nrows)
+               ip->iconcount = ip->ncols * ip->nrows;
+       if (ip->icons != NULL)
+               (void) free((void *) ip->icons);
+       ip->icons = (imagetype *) malloc(ip->iconcount * sizeof (imagetype));
+       for (i = 0; i < ip->iconcount; i++)
+               ip->icons[i].x = -1;
+
+       MI_CLEARWINDOWCOLORMAP(mi, ip->backGC, ip->black);
+}
+
+void
+draw_image(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       imagestruct *ip = &ims[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       XSetForeground(display, ip->backGC, ip->black);
+       for (i = 0; i < ip->iconcount; i++) {
+               if ((ip->ncols * ip->nrows > ip->iconcount) && ip->icons[i].x >= 0)
+                       XFillRectangle(display, window, ip->backGC,
+                       ip->logo->width * ip->icons[i].x + ip->image_offset.x,
+                                      ip->logo->height * ip->icons[i].y + ip->image_offset.y,
+                                      ip->logo->width, ip->logo->height);
+               ip->icons[i].x = NRAND(ip->ncols);
+               ip->icons[i].y = NRAND(ip->nrows);
+               ip->icons[i].color = NRAND(MI_NPIXELS(mi));
+       }
+       refresh_image(mi);
+}
+
+void
+release_image(ModeInfo * mi)
+{
+       if (ims != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       imagestruct *ip = &ims[screen];
+                       Display    *display = MI_DISPLAY(mi);
+
+                       if (ip->icons != NULL)
+                               (void) free((void *) ip->icons);
+                       free_stuff(display, ip);
+               }
+               (void) free((void *) ims);
+               ims = NULL;
+       }
+}
+
+#endif /* MODE_image */
diff --git a/xlockmore-4.14/modes/julia.c b/xlockmore-4.14/modes/julia.c
new file mode 100644 (file)
index 0000000..18dbd68
--- /dev/null
@@ -0,0 +1,416 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* julia --- continuously varying Julia set */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)julia.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*- 
+ * Copyright (c) 1995 Sean McCullough <bankshot@mailhost.nmt.edu>.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Check out  A.K. Dewdney's "Computer Recreations", Scientific
+ * American Magazine" Nov 1987.
+ *
+ * Revision History:
+ * 28-May-97: jwz@jwz.org: added interactive frobbing with the mouse.
+ * 10-May-97: jwz@jwz.org: turned into a standalone program.
+ * 02-Dec-95: snagged boilerplate from hop.c
+ *           used ifs {w0 = sqrt(x-c), w1 = -sqrt(x-c)} with random iteration 
+ *           to plot the julia set, and sinusoidially varied parameter for set 
+ *           and plotted parameter with a circle.
+ */
+
+/*-
+ * One thing to note is that batchcount is the *depth* of the search tree,
+ * so the number of points computed is 2^batchcount - 1.  I use 8 or 9
+ * on a dx266 and it looks okay.  The sinusoidal variation of the parameter
+ * might not be as interesting as it could, but it still gives an idea of
+ * the effect of the parameter.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Julia"
+#define HACK_INIT init_julia
+#define HACK_DRAW draw_julia
+#define julia_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 1000 \n" \
+ "*cycles: 20 \n" \
+ "*ncolors: 200 \n" \
+ "*mouse: False \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_julia
+
+#define DEF_TRACKMOUSE  "False"
+
+static Bool trackmouse;
+
+static XrmOptionDescRec opts[] =
+{
+        {"-trackmouse", ".julia.trackmouse", XrmoptionNoArg, (caddr_t) "on"},
+        {"+trackmouse", ".julia.trackmouse", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+        {(caddr_t *) & trackmouse, "trackmouse", "TrackMouse", DEF_TRACKMOUSE, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+        {"-/+trackmouse", "turn on/off the tracking of the mouse"}
+};
+
+ModeSpecOpt julia_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+
+#ifdef USE_MODULES
+ModStruct   julia_description =
+{"julia", "init_julia", "draw_julia", "release_julia",
+ "refresh_julia", "init_julia", NULL, &julia_opts,
+ 10000, 1000, 20, 1, 64, 1.0, "",
+ "Shows the Julia set", 0, NULL};
+
+#endif
+
+#define numpoints ((0x2<<jp->depth)-1)
+
+typedef struct {
+       int         centerx;
+       int         centery;    /* center of the screen */
+       double      cr;
+       double      ci;         /* julia params */
+       int         depth;
+       int         inc;
+       int         circsize;
+       int         erase;
+       int         pix;
+       long        itree;
+       int         buffer;
+       int         nbuffers;
+       int         redrawing, redrawpos;
+       Pixmap      pixmap;
+       GC          stippledGC;
+       XPoint    **pointBuffer;        /* pointer for XDrawPoints */
+       Cursor      cursor;
+} juliastruct;
+
+static juliastruct *julias = NULL;
+
+/* How many segments to draw per cycle when redrawing */
+#define REDRAWSTEP 3
+
+static void
+apply(juliastruct * jp, register double xr, register double xi, int d)
+{
+       double      theta, r;
+
+       jp->pointBuffer[jp->buffer][jp->itree].x =
+               (int) (0.5 * xr * jp->centerx + jp->centerx);
+       jp->pointBuffer[jp->buffer][jp->itree].y =
+               (int) (0.5 * xi * jp->centery + jp->centery);
+       jp->itree++;
+
+       if (d > 0) {
+               xi -= jp->ci;
+               xr -= jp->cr;
+
+               /* Avoid atan2: DOMAIN error message */
+               theta = (xi == 0.0 && xr == 0.0) ? 0.0 : atan2(xi, xr) / 2.0;
+
+               /*r = pow(xi * xi + xr * xr, 0.25); */
+               r = sqrt(sqrt(xi * xi + xr * xr));      /* 3 times faster */
+
+               xr = r * cos(theta);
+               xi = r * sin(theta);
+
+               d--;
+               apply(jp, xr, xi, d);
+               apply(jp, -xr, -xi, d);
+       }
+}
+
+static void
+incr(ModeInfo * mi, juliastruct * jp)
+{
+       Bool        track_p = trackmouse;
+       int         cx, cy;
+
+       if (track_p) {
+               Window      r, c;
+               int         rx, ry;
+               unsigned int m;
+
+               (void) XQueryPointer(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                    &r, &c, &rx, &ry, &cx, &cy, &m);
+               if (cx <= 0 || cy <= 0 ||
+                   cx >= MI_WIDTH(mi) - jp->circsize - 1 ||
+                   cy >= MI_HEIGHT(mi) - jp->circsize - 1)
+                       track_p = False;
+       }
+       if (track_p) {
+               jp->cr = ((double) (cx + 2 - jp->centerx)) * 2 / jp->centerx;
+               jp->ci = ((double) (cy + 2 - jp->centery)) * 2 / jp->centery;
+       } else {
+               jp->cr = 1.5 * (sin(M_PI * (jp->inc / 300.0)) *
+                               sin(jp->inc * M_PI / 200.0));
+               jp->ci = 1.5 * (cos(M_PI * (jp->inc / 300.0)) *
+                               cos(jp->inc * M_PI / 200.0));
+
+               jp->cr += 0.5 * cos(M_PI * jp->inc / 400.0);
+               jp->ci += 0.5 * sin(M_PI * jp->inc / 400.0);
+       }
+}
+
+void
+init_julia(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       juliastruct *jp;
+       XGCValues   gcv;
+       int         i, j;
+
+       if (julias == NULL) {
+               if ((julias = (juliastruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (juliastruct))) == NULL)
+                       return;
+       }
+       jp = &julias[MI_SCREEN(mi)];
+
+       jp->centerx = MI_WIDTH(mi) / 2;
+       jp->centery = MI_HEIGHT(mi) / 2;
+
+       jp->depth = MI_COUNT(mi);
+       if (jp->depth > 10)
+               jp->depth = 10;
+
+       if (trackmouse && !jp->cursor) {        /* Create an invisible cursor */
+               Pixmap      bit;
+               XColor      black;
+
+               black.red = 0;
+               black.green = 0;
+               black.blue = 0;
+               black.flags = DoRed | DoGreen | DoBlue;
+               bit = XCreatePixmapFromBitmapData(display, window, "\000", 1, 1,
+                                                 MI_BLACK_PIXEL(mi),
+                                                 MI_BLACK_PIXEL(mi), 1);
+               jp->cursor = XCreatePixmapCursor(display, bit, bit, &black, &black,
+                                                0, 0);
+               XFreePixmap(display, bit);
+       }
+       XDefineCursor(display, window, jp->cursor);
+       if (jp->pixmap != None &&
+           jp->circsize != (MIN(jp->centerx, jp->centery) / 60) * 2 + 1) {
+               XFreePixmap(display, jp->pixmap);
+               jp->pixmap = None;
+       }
+       if (jp->pixmap == None) {
+               GC          fg_gc = None, bg_gc = None;
+
+               jp->circsize = (MIN(jp->centerx, jp->centery) / 96) * 2 + 1;
+               jp->pixmap = XCreatePixmap(display, window, jp->circsize, jp->circsize, 1);
+               gcv.foreground = 1;
+               fg_gc = XCreateGC(display, jp->pixmap, GCForeground, &gcv);
+               gcv.foreground = 0;
+               bg_gc = XCreateGC(display, jp->pixmap, GCForeground, &gcv);
+               XFillRectangle(display, jp->pixmap, bg_gc,
+                              0, 0, jp->circsize, jp->circsize);
+               if (jp->circsize < 2)
+                       XDrawPoint(display, jp->pixmap, fg_gc, 0, 0);
+               else
+                       XFillArc(display, jp->pixmap, fg_gc,
+                                0, 0, jp->circsize, jp->circsize, 0, 23040);
+               if (fg_gc != None)
+                       XFreeGC(display, fg_gc);
+               if (bg_gc != None)
+                       XFreeGC(display, bg_gc);
+       }
+       if (!jp->stippledGC) {
+               gcv.foreground = MI_BLACK_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               if ((jp->stippledGC = XCreateGC(display, window,
+                                GCForeground | GCBackground, &gcv)) == None)
+                       return;
+       }
+       if (MI_NPIXELS(mi) > 2)
+               jp->pix = NRAND(MI_NPIXELS(mi));
+       jp->inc = NRAND(400) - 200;
+       jp->nbuffers = MI_CYCLES(mi) + 1;
+       if (!jp->pointBuffer)
+               jp->pointBuffer = (XPoint **) calloc(jp->nbuffers, sizeof (XPoint *));
+       for (i = 0; i < jp->nbuffers; ++i) {
+               if (!jp->pointBuffer[i])
+                       jp->pointBuffer[i] = (XPoint *) malloc(numpoints * sizeof (XPoint));
+               for (j = 0; j < numpoints; j++)
+                       jp->pointBuffer[i][j].x = jp->pointBuffer[i][j].y = -1;         /* move initial point off screen */
+       }
+       jp->buffer = 0;
+       jp->redrawing = 0;
+       jp->erase = 0;
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_julia(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       juliastruct *jp = &julias[MI_SCREEN(mi)];
+       double      r, theta;
+       register double xr = 0.0, xi = 0.0;
+       int         k = 64, rnd = 0, i, j;
+       XPoint     *xp = jp->pointBuffer[jp->buffer], old_circle, new_circle;
+
+       MI_IS_DRAWN(mi) = True;
+
+       old_circle.x = (int) (jp->centerx * jp->cr / 2) + jp->centerx - 2;
+       old_circle.y = (int) (jp->centery * jp->ci / 2) + jp->centery - 2;
+       incr(mi, jp);
+       new_circle.x = (int) (jp->centerx * jp->cr / 2) + jp->centerx - 2;
+       new_circle.y = (int) (jp->centery * jp->ci / 2) + jp->centery - 2;
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       ERASE_IMAGE(display, window, gc, new_circle.x, new_circle.y,
+                   old_circle.x, old_circle.y, jp->circsize, jp->circsize);
+       /* draw a circle at the c-parameter so you can see it's effect on the
+          structure of the julia set */
+       XSetTSOrigin(display, jp->stippledGC, new_circle.x, new_circle.y);
+       XSetForeground(display, jp->stippledGC, MI_WHITE_PIXEL(mi));
+       XSetStipple(display, jp->stippledGC, jp->pixmap);
+       XSetFillStyle(display, jp->stippledGC, FillOpaqueStippled);
+       XFillRectangle(display, window, jp->stippledGC, new_circle.x, new_circle.y,
+                      jp->circsize, jp->circsize);
+       XFlush(display);
+       if (jp->erase == 1) {
+               XDrawPoints(display, window, gc,
+                   jp->pointBuffer[jp->buffer], numpoints, CoordModeOrigin);
+       }
+       jp->inc++;
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, jp->pix));
+               if (++jp->pix >= MI_NPIXELS(mi))
+                       jp->pix = 0;
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       while (k--) {
+
+               /* save calls to LRAND by using bit shifts over and over on the same
+                  int for 32 iterations, then get a new random int */
+               if (!(k % 32))
+                       rnd = (int) LRAND();
+
+               /* complex sqrt: x^0.5 = radius^0.5*(cos(theta/2) + i*sin(theta/2)) */
+
+               xi -= jp->ci;
+               xr -= jp->cr;
+
+               /* Avoid atan2: DOMAIN error message */
+               if (xi == 0.0 && xr == 0.0)
+                       theta = 0.0;
+               else
+                       theta = atan2(xi, xr) / 2.0;
+
+               /*r = pow(xi * xi + xr * xr, 0.25); */
+               r = sqrt(sqrt(xi * xi + xr * xr));      /* 3 times faster */
+
+               xr = r * cos(theta);
+               xi = r * sin(theta);
+
+               if ((rnd >> (k % 32)) & 0x1) {
+                       xi = -xi;
+                       xr = -xr;
+               }
+               xp->x = jp->centerx + (int) ((jp->centerx >> 1) * xr);
+               xp->y = jp->centery + (int) ((jp->centery >> 1) * xi);
+               xp++;
+       }
+
+       jp->itree = 0;
+       apply(jp, xr, xi, jp->depth);
+
+       XDrawPoints(display, window, gc,
+                   jp->pointBuffer[jp->buffer], numpoints, CoordModeOrigin);
+
+       jp->buffer++;
+       if (jp->buffer > jp->nbuffers - 1) {
+               jp->buffer -= jp->nbuffers;
+               jp->erase = 1;
+       }
+       if (jp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       j = (jp->buffer - jp->redrawpos + jp->nbuffers) % jp->nbuffers;
+                       XDrawPoints(display, window, gc,
+                            jp->pointBuffer[j], numpoints, CoordModeOrigin);
+
+                       if (++(jp->redrawpos) >= jp->nbuffers) {
+                               jp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+void
+release_julia(ModeInfo * mi)
+{
+       if (julias != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       Display    *display = MI_DISPLAY(mi);
+                       juliastruct *jp = &julias[screen];
+                       int         buffer;
+
+                       if (jp->pointBuffer) {
+                               for (buffer = 0; buffer < jp->nbuffers; buffer++)
+                                       if (jp->pointBuffer[buffer])
+                                               (void) free((void *) jp->pointBuffer[buffer]);
+                               (void) free((void *) jp->pointBuffer);
+                       }
+                       if (jp->stippledGC != None)
+                               XFreeGC(display, jp->stippledGC);
+                       if (jp->pixmap != None)
+                               XFreePixmap(display, jp->pixmap);
+                       if (jp->cursor)
+                               XFreeCursor(display, jp->cursor);
+               }
+               (void) free((void *) julias);
+               julias = NULL;
+       }
+}
+
+void
+refresh_julia(ModeInfo * mi)
+{
+       juliastruct *jp = &julias[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+       jp->redrawing = 1;
+       jp->redrawpos = 0;
+}
+
+#endif /* MODE_julia */
diff --git a/xlockmore-4.14/modes/kaleid.c b/xlockmore-4.14/modes/kaleid.c
new file mode 100644 (file)
index 0000000..d5f82f4
--- /dev/null
@@ -0,0 +1,1278 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* kaleid --- Brewster's Kaleidoscope */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)kaleid.c  4.11 98/06/01 xlockmore";
+
+#endif
+
+/*-
+ * 
+ *  kaleid.c - Brewster's Kaleidoscope  (Sir David Brewster invented the
+ *     kaleidoscope in 1816 and patented it in 1817.)
+ *
+ *  Copyright (c) 1998 by Robert Adam, II  <raii@comm.net>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ *  -batchcount n     number of pens [default 4]
+ *
+ *  -cycle n          percentage of black in the pattern (0%-95%)
+ *
+ *  -size n          symmetry mode [default -9]
+ *                         <0     = random from 0 to -number
+ *                         >0     = mirrored                  (-alternate)
+ *                                  rotated                   (+alternate)
+ *
+ *
+ *  -/+disconnected   turn on/off disconnected pen movement
+ *
+ *  -/+serial         turn on/off sequential allocation of colors
+ *
+ *  -/+alternate      turn on/off alternate display mode
+ *
+ *  -/+quad           turn on/off quad mirrored/rotated mode similar
+ *                       to size 4, works with alternate
+ *
+ *  -/+oct            turn on/off oct mirrored/rotated moded similar 
+ *                       to size 8, works with alternate
+ *
+ *  -/+linear         select Cartesian/Polar coordinate mode. Cartesian
+ *                       uses straight lines similar to -oct and -quad 
+ *                       mode instead of the curved lines of Polar mode.
+ *                       [default off]
+ *
+ */
+
+#include <math.h>
+
+#ifdef STANDALONE
+#define PROGCLASS "Kaleid"
+#define HACK_INIT init_kaleid
+#define HACK_DRAW draw_kaleid
+#define kaleid_opts xlockmore_opts
+#define DEFAULTS "*delay: 80000 \n" \
+ "*count: 4 \n" \
+ "*cycles: 40 \n" \
+ "*size: -9 \n" \
+ "*ncolors: 200 \n" \
+ "*disconnected: True \n" \
+ "*serial: False \n" \
+ "*alternate: False \n" \
+ "*linear: False \n" \
+ "*quad: False \n" \
+ "*oct: False \n"
+"*fullrandom: False \n"
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_kaleid
+
+#define DEF_DISCONNECTED  "True"
+#define DEF_SERIAL        "False"
+#define DEF_ALTERNATE     "False"
+#define DEF_QUAD          "False"
+#define DEF_OCT           "False"
+#define DEF_LINEAR        "False"
+
+static Bool Disconnected;
+static Bool Serial;
+static Bool Alternate;
+static Bool Quad;
+static Bool Oct;
+static Bool Linear;
+
+static XrmOptionDescRec opts[] =
+{
+   {"-disconnected", ".kaleid.disconnected", XrmoptionNoArg, (caddr_t) "on"},
+  {"+disconnected", ".kaleid.disconnected", XrmoptionNoArg, (caddr_t) "off"},
+       {"-serial", ".kaleid.serial", XrmoptionNoArg, (caddr_t) "on"},
+       {"+serial", ".kaleid.serial", XrmoptionNoArg, (caddr_t) "off"},
+       {"-alternate", ".kaleid.alternate", XrmoptionNoArg, (caddr_t) "on"},
+       {"+alternate", ".kaleid.alternate", XrmoptionNoArg, (caddr_t) "off"},
+       {"-quad", ".kaleid.quad", XrmoptionNoArg, (caddr_t) "on"},
+       {"+quad", ".kaleid.quad", XrmoptionNoArg, (caddr_t) "off"},
+       {"-oct", ".kaleid.oct", XrmoptionNoArg, (caddr_t) "on"},
+       {"+oct", ".kaleid.oct", XrmoptionNoArg, (caddr_t) "off"},
+       {"-linear", ".kaleid.linear", XrmoptionNoArg, (caddr_t) "on"},
+       {"+linear", ".kaleid.linear", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & Disconnected, "disconnected", "Disconnected", DEF_DISCONNECTED, t_Bool},
+       {(caddr_t *) & Serial, "serial", "Serial", DEF_SERIAL, t_Bool},
+  {(caddr_t *) & Alternate, "alternate", "Alternate", DEF_ALTERNATE, t_Bool},
+       {(caddr_t *) & Quad, "quad", "Quad", DEF_QUAD, t_Bool},
+       {(caddr_t *) & Oct, "oct", "Oct", DEF_OCT, t_Bool},
+       {(caddr_t *) & Linear, "linear", "Linear", DEF_LINEAR, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-/+disconnected", "turn on/off disconnected pen movement"},
+       {"-/+serial", "turn on/off sequential color selection"},
+       {"-/+alternate", "turn on/off alternate display mode"},
+       {"-/+quad", "turn on/off quad mirrored display mode"},
+       {"-/+oct", "turn on/off oct mirrored display mode"},
+       {"-/+linear", "select Cartesian/Polar coordinate display mode"}
+};
+
+ModeSpecOpt kaleid_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   kaleid_description =
+{
+       "kaleid", "init_kaleid", "draw_kaleid", "release_kaleid",
+       "refresh_kaleid", "init_kaleid", NULL, &kaleid_opts,
+       80000, 4, 40, -9, 64, 0.6, "",
+       "Shows Brewster's Kaleidoscope", 0, NULL
+};
+
+#endif
+
+#define INTRAND(min,max) (NRAND(((max+1)-(min)))+(min))
+
+#define MINPENS 1
+#define MINSIZE 1
+#define QUAD (-4)
+#define OCT (-8)
+
+#define MinVelocity         6
+#define MaxVelocity         4
+
+#define MinRadialVelocity   6
+#define MaxRadialVelocity   30
+
+#define MinAngularVelocity  5
+#define MaxAngularVelocity  3
+
+#define WidthPercent  25
+#define ChangeChance  2
+
+#define ToRadians 0.017453293
+#define ToDegrees 57.29577951
+#define PolarToCartX(r, t) ((r) * cos((t) * ToRadians))
+#define PolarToCartY(r, t) ((r) * sin((t) * ToRadians))
+#define CartToRadius(x, y) (sqrt(((x)*(x)) + ((y)*(y))))
+#define CartToAngle(x,y)   ((((x) == 0.0) && ((y) == 0.0)) ? 0.0 : (atan2((y),(x)) * ToDegrees))
+
+typedef struct {
+       double      cx;
+       double      cy;
+       double      ox;
+       double      oy;
+       double      xv;
+       double      yv;
+       int         curlwidth;
+       int         pix;
+       int         White;
+       Bool        RadiusOut;
+       Bool        AngleOut;
+       Bool        DeferredChange;
+} penstruct;
+
+typedef struct {
+       penstruct  *pen;
+
+
+       int         PercentBlack;
+       int         PenCount;
+       int         maxlwidth;
+       double      width, widthby2;
+       double      height, heightby2;
+       double      radius;
+       double      slice;
+       int         bouncetype;
+       int         modetype;
+       Bool        alternate, disconnected, serial, linear;
+} kaleidstruct;
+
+static kaleidstruct *kaleids = NULL;
+
+/*-
+ *
+ */
+static void
+QuadMirrored(
+                   kaleidstruct * kp,
+                   int pn,
+                   XSegment segs[4]
+)
+{
+       kp->pen[pn].cx = kp->pen[pn].cx + kp->pen[pn].xv;
+       if (kp->pen[pn].cx < 0.0) {
+               kp->pen[pn].cx = -kp->pen[pn].cx;
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       } else if (kp->pen[pn].cx >= kp->widthby2) {
+               kp->pen[pn].cx = (kp->widthby2 - 1.0)
+                       - (kp->pen[pn].cx - kp->widthby2);
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       }
+       kp->pen[pn].cy = kp->pen[pn].cy + kp->pen[pn].yv;
+       if (kp->pen[pn].cy < 0.0) {
+               kp->pen[pn].cy = -kp->pen[pn].cy;
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       } else if (kp->pen[pn].cy >= kp->heightby2) {
+               kp->pen[pn].cy = (kp->heightby2 - 1.0)
+                       - (kp->pen[pn].cy - kp->heightby2);
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       }
+       segs[0].x1 = (int) kp->pen[pn].ox;
+       segs[0].y1 = (int) kp->pen[pn].oy;
+       segs[0].x2 = (int) kp->pen[pn].cx;
+       segs[0].y2 = (int) kp->pen[pn].cy;
+
+       segs[1].x1 = (int) (kp->width - kp->pen[pn].ox);
+       segs[1].y1 = (int) kp->pen[pn].oy;
+       segs[1].x2 = (int) (kp->width - kp->pen[pn].cx);
+       segs[1].y2 = (int) kp->pen[pn].cy;
+
+       segs[2].x1 = (int) (kp->width - kp->pen[pn].ox);
+       segs[2].y1 = (int) (kp->height - kp->pen[pn].oy);
+       segs[2].x2 = (int) (kp->width - kp->pen[pn].cx);
+       segs[2].y2 = (int) (kp->height - kp->pen[pn].cy);
+
+       segs[3].x1 = (int) kp->pen[pn].ox;
+       segs[3].y1 = (int) (kp->height - kp->pen[pn].oy);
+       segs[3].x2 = (int) kp->pen[pn].cx;
+       segs[3].y2 = (int) (kp->height - kp->pen[pn].cy);
+
+}
+
+/*-
+ *
+ */
+static void
+QuadRotated(
+                  kaleidstruct * kp,
+                  int pn,
+                  XSegment segs[4]
+)
+{
+       double      oxscaled2y;
+       double      oyscaled2x;
+       double      cxscaled2y;
+       double      cyscaled2x;
+
+       kp->pen[pn].cx = kp->pen[pn].cx + kp->pen[pn].xv;
+       if (kp->pen[pn].cx < 0.0) {
+               kp->pen[pn].cx = -kp->pen[pn].cx;
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       } else if (kp->pen[pn].cx >= kp->widthby2) {
+               kp->pen[pn].cx = (kp->widthby2 - 1.0)
+                       - (kp->pen[pn].cx - kp->widthby2);
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       }
+       kp->pen[pn].cy = kp->pen[pn].cy + kp->pen[pn].yv;
+       if (kp->pen[pn].cy < 0.0) {
+               kp->pen[pn].cy = -kp->pen[pn].cy;
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       } else if (kp->pen[pn].cy >= kp->heightby2) {
+               kp->pen[pn].cy = (kp->heightby2 - 1.0)
+                       - (kp->pen[pn].cy - kp->heightby2);
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       }
+       segs[0].x1 = (int) kp->pen[pn].ox;
+       segs[0].y1 = (int) kp->pen[pn].oy;
+       segs[0].x2 = (int) kp->pen[pn].cx;
+       segs[0].y2 = (int) kp->pen[pn].cy;
+
+       oxscaled2y = ((kp->pen[pn].ox * kp->heightby2) / kp->widthby2);
+       oyscaled2x = ((kp->pen[pn].oy * kp->widthby2) / kp->heightby2);
+       cxscaled2y = ((kp->pen[pn].cx * kp->heightby2) / kp->widthby2);
+       cyscaled2x = ((kp->pen[pn].cy * kp->widthby2) / kp->heightby2);
+
+       segs[1].x1 = (int) (kp->width - oyscaled2x);
+       segs[1].y1 = (int) oxscaled2y;
+       segs[1].x2 = (int) (kp->width - cyscaled2x);
+       segs[1].y2 = (int) cxscaled2y;
+
+       segs[2].x1 = (int) (kp->width - kp->pen[pn].ox);
+       segs[2].y1 = (int) (kp->height - kp->pen[pn].oy);
+       segs[2].x2 = (int) (kp->width - kp->pen[pn].cx);
+       segs[2].y2 = (int) (kp->height - kp->pen[pn].cy);
+
+       segs[3].x1 = (int) oyscaled2x;
+       segs[3].y1 = (int) (kp->height - oxscaled2y);
+       segs[3].x2 = (int) cyscaled2x;
+       segs[3].y2 = (int) (kp->height - cxscaled2y);
+
+}
+
+/*-
+ *
+ */
+static void
+GeneralPolarMoveAndBounce(
+                                kaleidstruct * kp,
+                                int pn
+)
+{
+       kp->pen[pn].cx = kp->pen[pn].cx + kp->pen[pn].xv;
+       if (kp->pen[pn].cx < 0.0) {
+               kp->pen[pn].cx = -kp->pen[pn].cx;
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       } else if (kp->pen[pn].cx >= kp->radius) {
+               kp->pen[pn].cx = (kp->radius - 1.0)
+                       - (kp->pen[pn].cx - kp->radius);
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       }
+       switch (kp->bouncetype) {
+               case 0:
+                       {
+                               kp->pen[pn].cy = kp->pen[pn].cy + kp->pen[pn].yv;
+                               break;
+                       }
+               case 1:
+                       {
+                               kp->pen[pn].cy = kp->pen[pn].cy
+                                       + ((kp->pen[pn].yv * kp->pen[pn].cx) / kp->radius);
+                               break;
+                       }
+               case 2:
+                       {
+                               kp->pen[pn].cy = kp->pen[pn].cy
+                                       + ((kp->pen[pn].yv * (kp->radius - kp->pen[pn].cx)) / kp->radius);
+                               break;
+                       }
+               default:
+                       {
+                               kp->pen[pn].cy = kp->slice / 2.0;
+                               kp->pen[pn].cx = kp->radius / 2.0;
+                               break;
+                       }
+       }
+
+       if (kp->pen[pn].cy < 0) {
+               kp->pen[pn].RadiusOut = True;
+               if (kp->pen[pn].oy >= 0) {
+                       kp->pen[pn].yv = -kp->pen[pn].yv;
+               }
+       } else if (kp->pen[pn].cy >= kp->slice) {
+               kp->pen[pn].RadiusOut = True;
+               if (kp->pen[pn].oy < kp->slice) {
+                       kp->pen[pn].yv = -kp->pen[pn].yv;
+               }
+       } else {
+               kp->pen[pn].RadiusOut = False;
+       }
+
+}
+
+
+/*-
+ *
+ */
+static void
+GeneralRotated(
+                     kaleidstruct * kp,
+                     int pn,
+                     XSegment * segs
+)
+{
+       double      Angle;
+       int         segnum;
+
+
+       GeneralPolarMoveAndBounce(kp, pn);
+
+       Angle = 0.0;
+       for (segnum = 0; segnum < kp->modetype; segnum += 1) {
+               segs[segnum].x1 = (int) (PolarToCartX(kp->pen[pn].ox,
+                                                     kp->pen[pn].oy + Angle
+                                        ) + kp->widthby2
+                       );
+               segs[segnum].y1 = (int) (PolarToCartY(kp->pen[pn].ox,
+                                                     kp->pen[pn].oy + Angle
+                                        ) + kp->heightby2
+                       );
+               segs[segnum].x2 = (int) (PolarToCartX(kp->pen[pn].cx,
+                                                     kp->pen[pn].cy + Angle
+                                        ) + kp->widthby2
+                       );
+               segs[segnum].y2 = (int) (PolarToCartY(kp->pen[pn].cx,
+                                                     kp->pen[pn].cy + Angle
+                                        ) + kp->heightby2
+                       );
+
+               Angle += kp->slice;
+       }
+}
+
+/*-
+ *
+ */
+static void
+GeneralMirrored(
+                      kaleidstruct * kp,
+                      int pn,
+                      XSegment * segs
+)
+{
+       double      Angle;
+       int         segnum;
+
+       GeneralPolarMoveAndBounce(kp, pn);
+
+       Angle = 0.0;
+       for (segnum = 0; segnum < kp->modetype; segnum += 2) {
+               segs[segnum].x1 = (int) (PolarToCartX(kp->pen[pn].ox,
+                                                     kp->pen[pn].oy + Angle
+                                        ) + kp->widthby2
+                       );
+
+               segs[segnum].y1 = (int) (PolarToCartY(kp->pen[pn].ox,
+                                                     kp->pen[pn].oy + Angle
+                                        ) + kp->heightby2
+                       );
+
+               segs[segnum].x2 = (int) (PolarToCartX(kp->pen[pn].cx,
+                                                     kp->pen[pn].cy + Angle
+                                        ) + kp->widthby2
+                       );
+
+               segs[segnum].y2 = (int) (PolarToCartY(kp->pen[pn].cx,
+                                                     kp->pen[pn].cy + Angle
+                                        ) + kp->heightby2
+                       );
+
+               Angle += (2.0 * kp->slice);
+       }
+
+       Angle = 360.0 - kp->slice;
+       for (segnum = 1; segnum < kp->modetype; segnum += 2) {
+               segs[segnum].x1 =
+                       (int) (PolarToCartX(kp->pen[pn].ox,
+                                        (kp->slice - kp->pen[pn].oy) + Angle
+                              ) + kp->widthby2
+                       );
+
+               segs[segnum].y1 =
+                       (int) (PolarToCartY(kp->pen[pn].ox,
+                                        (kp->slice - kp->pen[pn].oy) + Angle
+                              ) + kp->heightby2
+                       );
+
+               segs[segnum].x2 =
+                       (int) (PolarToCartX(kp->pen[pn].cx,
+                                        (kp->slice - kp->pen[pn].cy) + Angle
+                              ) + kp->widthby2
+                       );
+
+               segs[segnum].y2 =
+                       (int) (PolarToCartY(kp->pen[pn].cx,
+                                        (kp->slice - kp->pen[pn].cy) + Angle
+                              ) + kp->heightby2
+                       );
+
+               Angle -= (2.0 * kp->slice);
+       }
+}
+
+/*-
+ *
+ */
+static void
+OctMirrored(
+                  kaleidstruct * kp,
+                  int pn,
+                  XSegment * segs
+)
+{
+       double      xdiag;
+       double      ydiag;
+       double      oxscaled2y, cxscaled2y;
+       double      oyscaled2x, cyscaled2x;
+
+       /*
+        *  I know that the "bounce" is not really accurate, but I like the way
+        * it looks.
+        */
+
+       xdiag = (kp->widthby2 * kp->pen[pn].oy) / kp->heightby2;
+
+       kp->pen[pn].cx = kp->pen[pn].cx + kp->pen[pn].xv;
+       if (kp->pen[pn].cx < xdiag) {
+               kp->pen[pn].cx = xdiag + (xdiag - kp->pen[pn].cx);
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       } else if (kp->pen[pn].cx >= kp->widthby2) {
+               kp->pen[pn].cx = (kp->widthby2 - 1.0)
+                       - (kp->pen[pn].cx - kp->widthby2);
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       }
+       ydiag = (kp->heightby2 * kp->pen[pn].cx) / kp->widthby2;
+
+       kp->pen[pn].cy = kp->pen[pn].cy + kp->pen[pn].yv;
+       if (kp->pen[pn].cy < 0.0) {
+               kp->pen[pn].cy = -kp->pen[pn].cy;
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       } else if (kp->pen[pn].cy > ydiag) {
+               kp->pen[pn].cy = ydiag - (kp->pen[pn].cy - ydiag);
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       }
+       segs[0].x1 = (int) kp->pen[pn].ox;
+       segs[0].y1 = (int) kp->pen[pn].oy;
+       segs[0].x2 = (int) kp->pen[pn].cx;
+       segs[0].y2 = (int) kp->pen[pn].cy;
+
+       segs[1].x1 = (int) (kp->width - kp->pen[pn].ox);
+       segs[1].y1 = (int) kp->pen[pn].oy;
+       segs[1].x2 = (int) (kp->width - kp->pen[pn].cx);
+       segs[1].y2 = (int) kp->pen[pn].cy;
+
+       segs[4].x1 = segs[1].x1;
+       segs[4].y1 = (int) kp->height - segs[0].y1;
+       segs[4].x2 = segs[1].x2;
+       segs[4].y2 = (int) kp->height - segs[0].y2;
+
+       segs[5].x1 = segs[0].x1;
+       segs[5].y1 = (int) kp->height - segs[0].y1;
+       segs[5].x2 = segs[0].x2;
+       segs[5].y2 = (int) kp->height - segs[0].y2;
+
+
+       oxscaled2y = ((kp->pen[pn].ox * kp->heightby2) / kp->widthby2);
+       oyscaled2x = ((kp->pen[pn].oy * kp->widthby2) / kp->heightby2);
+       cxscaled2y = ((kp->pen[pn].cx * kp->heightby2) / kp->widthby2);
+       cyscaled2x = ((kp->pen[pn].cy * kp->widthby2) / kp->heightby2);
+
+
+       segs[7].x1 = (int) oyscaled2x;
+       segs[7].y1 = (int) oxscaled2y;
+       segs[7].x2 = (int) cyscaled2x;
+       segs[7].y2 = (int) cxscaled2y;
+
+
+       segs[2].x1 = (int) kp->width - segs[7].x1;
+       segs[2].y1 = segs[7].y1;
+       segs[2].x2 = (int) kp->width - segs[7].x2;
+       segs[2].y2 = segs[7].y2;
+
+       segs[6].x1 = segs[7].x1;
+       segs[6].y1 = (int) kp->height - segs[7].y1;
+       segs[6].x2 = segs[7].x2;
+       segs[6].y2 = (int) kp->height - segs[7].y2;
+
+       segs[3].x1 = (int) kp->width - segs[7].x1;
+       segs[3].y1 = segs[6].y1;
+       segs[3].x2 = (int) kp->width - segs[7].x2;
+       segs[3].y2 = segs[6].y2;
+
+}
+
+
+
+/*-
+ *
+ */
+#if 0
+static void
+OldOctRotated(
+                    kaleidstruct * kp,
+                    int pn,
+                    XSegment * segs
+)
+{
+       double      angle, radius;
+       double      oangle, oradius;
+       double      rv, av;
+       double      perp, para;
+       int         i;
+
+       /*
+        *  I know that the "bounce" is not really accurate, but I like the way
+        * it looks.
+        */
+
+       kp->pen[pn].cx = kp->pen[pn].cx + kp->pen[pn].xv;
+       kp->pen[pn].cy = kp->pen[pn].cy + kp->pen[pn].yv;
+       angle = CartToAngle(kp->pen[pn].cx, kp->pen[pn].cy);
+       radius = CartToRadius(kp->pen[pn].cx, kp->pen[pn].cy);
+
+       oangle = CartToAngle(kp->pen[pn].ox, kp->pen[pn].oy);
+       oradius = CartToRadius(kp->pen[pn].ox, kp->pen[pn].oy);
+
+       if (radius < 0.0) {
+               if (kp->pen[pn].xv < 0.0) {
+                       kp->pen[pn].xv = -kp->pen[pn].xv;
+               }
+       } else if (radius > kp->radius) {
+               if (kp->pen[pn].xv > 0.0) {
+                       kp->pen[pn].xv = -kp->pen[pn].xv;
+               }
+       }
+       if (angle < 0.0) {
+               if (oangle > 0.0) {
+                       kp->pen[pn].yv = -kp->pen[pn].yv;
+               }
+       } else if (angle > 45.0) {
+               if (oangle < 45.0) {
+                       rv = CartToRadius(kp->pen[pn].xv, kp->pen[pn].yv);
+                       av = CartToAngle(kp->pen[pn].xv, kp->pen[pn].yv);
+
+                       para = PolarToCartX(rv, av - 45.0);
+                       perp = PolarToCartY(rv, av - 45.0);
+
+                       rv = CartToRadius(para, -perp);
+                       av = CartToAngle(para, -perp);
+
+                       kp->pen[pn].xv = PolarToCartX(rv, av + 45.0);
+                       kp->pen[pn].yv = PolarToCartY(rv, av + 45.0);
+               }
+       }
+       for (i = 0; i < 8; i += 1) {
+               segs[i].x1 = (int) (kp->widthby2 + PolarToCartX(oradius, oangle));
+               segs[i].y1 = (int) (kp->heightby2 - PolarToCartY(oradius, oangle));
+               segs[i].x2 = (int) (kp->widthby2 + PolarToCartX(radius, angle));
+               segs[i].y2 = (int) (kp->heightby2 - PolarToCartY(radius, angle));
+
+               oangle += 45.0;
+               angle += 45.0;
+       }
+}
+
+#endif
+
+/*-
+ *
+ */
+static void
+OctRotated(
+                 kaleidstruct * kp,
+                 int pn,
+                 XSegment * segs
+)
+{
+       double      xdiag;
+       double      ydiag;
+       double      radius, angle;
+       double      oradius, oangle;
+       double      ox, oy, cx, cy;
+       double      offset;
+       int         i;
+
+       /*
+        *  I know that the "bounce" is not really accurate, but I like the way
+        * it looks.
+        */
+
+       xdiag = (kp->widthby2 * kp->pen[pn].oy) / kp->heightby2;
+
+       kp->pen[pn].cx = kp->pen[pn].cx + kp->pen[pn].xv;
+       if (kp->pen[pn].cx < xdiag) {
+               kp->pen[pn].cx = xdiag + (xdiag - kp->pen[pn].cx);
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       } else if (kp->pen[pn].cx >= kp->widthby2) {
+               kp->pen[pn].cx = (kp->widthby2 - 1.0)
+                       - (kp->pen[pn].cx - kp->widthby2);
+               kp->pen[pn].xv = -kp->pen[pn].xv;
+       }
+       ydiag = (kp->heightby2 * kp->pen[pn].cx) / kp->widthby2;
+
+       kp->pen[pn].cy = kp->pen[pn].cy + kp->pen[pn].yv;
+       if (kp->pen[pn].cy < 0.0) {
+               kp->pen[pn].cy = -kp->pen[pn].cy;
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       } else if (kp->pen[pn].cy > ydiag) {
+               kp->pen[pn].cy = ydiag - (kp->pen[pn].cy - ydiag);
+               kp->pen[pn].yv = -kp->pen[pn].yv;
+       }
+       offset = CartToRadius(kp->heightby2, kp->widthby2);
+       ox = (kp->pen[pn].ox * offset) / kp->widthby2;
+       oy = (kp->pen[pn].oy * offset) / kp->heightby2;
+       cx = (kp->pen[pn].cx * offset) / kp->widthby2;
+       cy = (kp->pen[pn].cy * offset) / kp->heightby2;
+
+       angle = CartToAngle(cx - offset,
+                           offset - cy
+               ) - 90.0;
+       radius = CartToRadius(cx - offset,
+                             offset - cy
+               );
+
+       oangle = CartToAngle(ox - offset,
+                            offset - oy
+               ) - 90.0;
+       oradius = CartToRadius(ox - offset,
+                              offset - oy
+               );
+
+
+       for (i = 0; i < 8; i += 1) {
+               segs[i].x1 = (int) (kp->widthby2 + PolarToCartX(oradius, oangle));
+               segs[i].y1 = (int) (kp->heightby2 - PolarToCartY(oradius, oangle));
+               segs[i].x2 = (int) (kp->widthby2 + PolarToCartX(radius, angle));
+               segs[i].y2 = (int) (kp->heightby2 - PolarToCartY(radius, angle));
+
+               oangle += 45.0;
+               angle += 45.0;
+       }
+
+}
+
+/*-
+ *
+ */
+static void
+GeneralLinearMoveAndBounce(
+                                 kaleidstruct * kp,
+                                 int pn,
+                                 double *angle,
+                                 double *radius,
+                                 double *oangle,
+                                 double *oradius
+)
+{
+       double      rv, av;
+       double      perp, para;
+
+       kp->pen[pn].cx = kp->pen[pn].cx + kp->pen[pn].xv;
+       kp->pen[pn].cy = kp->pen[pn].cy + kp->pen[pn].yv;
+
+       *angle = CartToAngle(kp->pen[pn].cx, kp->pen[pn].cy);
+       *radius = CartToRadius(kp->pen[pn].cx, kp->pen[pn].cy);
+
+       *oangle = CartToAngle(kp->pen[pn].ox, kp->pen[pn].oy);
+       *oradius = CartToRadius(kp->pen[pn].ox, kp->pen[pn].oy);
+
+       if (*radius < 0.0) {
+               kp->pen[pn].RadiusOut = True;
+               if (*oradius > 0.0) {
+                       rv = CartToRadius(kp->pen[pn].xv, kp->pen[pn].yv);
+                       av = CartToAngle(kp->pen[pn].xv, kp->pen[pn].yv);
+
+                       para = PolarToCartX(rv, av - (*angle + 90.0));
+                       perp = PolarToCartY(rv, av - (*angle + 90.0));
+
+                       rv = CartToRadius(para, -perp);
+                       av = CartToAngle(para, -perp);
+
+                       kp->pen[pn].xv = PolarToCartX(rv, av + (*angle + 90.0));
+                       kp->pen[pn].yv = PolarToCartY(rv, av + (*angle + 90.0));
+               }
+       } else if (*radius > kp->radius) {
+               kp->pen[pn].RadiusOut = True;
+               if (*oradius < kp->radius) {
+                       rv = CartToRadius(kp->pen[pn].xv, kp->pen[pn].yv);
+                       av = CartToAngle(kp->pen[pn].xv, kp->pen[pn].yv);
+
+                       para = PolarToCartX(rv, av - (*angle + 90.0));
+                       perp = PolarToCartY(rv, av - (*angle + 90.0));
+
+                       rv = CartToRadius(para, -perp);
+                       av = CartToAngle(para, -perp);
+
+                       kp->pen[pn].xv = PolarToCartX(rv, av + (*angle + 90.0));
+                       kp->pen[pn].yv = PolarToCartY(rv, av + (*angle + 90.0));
+               }
+       } else {
+               kp->pen[pn].RadiusOut = False;
+       }
+
+
+       if (*angle < 0.0) {
+               kp->pen[pn].AngleOut = True;
+               if (*oangle > 0.0) {
+                       rv = CartToRadius(kp->pen[pn].xv, kp->pen[pn].yv);
+                       av = CartToAngle(kp->pen[pn].xv, kp->pen[pn].yv);
+
+                       para = PolarToCartX(rv, av);
+                       perp = PolarToCartY(rv, av);
+
+                       rv = CartToRadius(para, -perp);
+                       av = CartToAngle(para, -perp);
+
+                       kp->pen[pn].xv = PolarToCartX(rv, av);
+                       kp->pen[pn].yv = PolarToCartY(rv, av);
+               }
+       } else if (*angle > kp->slice) {
+               kp->pen[pn].AngleOut = True;
+               if (*oangle < kp->slice) {
+                       rv = CartToRadius(kp->pen[pn].xv, kp->pen[pn].yv);
+                       av = CartToAngle(kp->pen[pn].xv, kp->pen[pn].yv);
+
+                       para = PolarToCartX(rv, av - kp->slice);
+                       perp = PolarToCartY(rv, av - kp->slice);
+
+                       rv = CartToRadius(para, -perp);
+                       av = CartToAngle(para, -perp);
+
+                       kp->pen[pn].xv = PolarToCartX(rv, av + kp->slice);
+                       kp->pen[pn].yv = PolarToCartY(rv, av + kp->slice);
+               }
+       } else {
+               kp->pen[pn].AngleOut = False;
+       }
+}
+
+/*-
+ *
+ */
+static void
+GeneralLinearRotated(
+                           kaleidstruct * kp,
+                           int pn,
+                           XSegment * segs
+)
+{
+       double      angle, radius;
+       double      oangle, oradius;
+       int         i;
+
+       GeneralLinearMoveAndBounce(kp, pn, &angle, &radius, &oangle, &oradius);
+
+       for (i = 0; i < kp->modetype; i += 1) {
+               segs[i].x1 = (int) (kp->widthby2 + PolarToCartX(oradius, oangle));
+               segs[i].y1 = (int) (kp->heightby2 - PolarToCartY(oradius, oangle));
+               segs[i].x2 = (int) (kp->widthby2 + PolarToCartX(radius, angle));
+               segs[i].y2 = (int) (kp->heightby2 - PolarToCartY(radius, angle));
+
+               oangle += kp->slice;
+               angle += kp->slice;
+       }
+}
+
+
+
+/*-
+ *
+ */
+static void
+GeneralLinearMirrored(
+                            kaleidstruct * kp,
+                            int pn,
+                            XSegment * segs
+)
+{
+       double      hangle, angle, radius;
+       double      hoangle, oangle, oradius;
+       int         i;
+
+
+       GeneralLinearMoveAndBounce(kp, pn, &angle, &radius, &oangle, &oradius);
+
+       hoangle = oangle;
+       hangle = angle;
+
+       for (i = 0; i < kp->modetype; i += 2) {
+               segs[i].x1 = (int) (kp->widthby2 + PolarToCartX(oradius, oangle));
+               segs[i].y1 = (int) (kp->heightby2 - PolarToCartY(oradius, oangle));
+               segs[i].x2 = (int) (kp->widthby2 + PolarToCartX(radius, angle));
+               segs[i].y2 = (int) (kp->heightby2 - PolarToCartY(radius, angle));
+
+               oangle += 2.0 * kp->slice;
+               angle += 2.0 * kp->slice;
+       }
+
+       oangle = kp->slice * 2.0;
+       angle = kp->slice * 2.0;
+       for (i = 1; i < kp->modetype; i += 2) {
+               segs[i].x1 = (int) (kp->widthby2 + PolarToCartX(oradius, oangle - hoangle));
+               segs[i].y1 = (int) (kp->heightby2 - PolarToCartY(oradius, oangle - hoangle));
+               segs[i].x2 = (int) (kp->widthby2 + PolarToCartX(radius, angle - hangle));
+               segs[i].y2 = (int) (kp->heightby2 - PolarToCartY(radius, angle - hangle));
+
+               oangle += 2.0 * kp->slice;
+               angle += 2.0 * kp->slice;
+       }
+}
+
+/*-
+ *
+ */
+static void
+random_velocity(kaleidstruct * kp, int i)
+{
+       if (kp->modetype > 0) {
+               kp->pen[i].xv = INTRAND(-MaxRadialVelocity, MaxRadialVelocity);
+               if (kp->pen[i].xv > 0.0) {
+                       kp->pen[i].xv += MinRadialVelocity;
+               } else if (kp->pen[i].xv < 0.0) {
+                       kp->pen[i].xv -= MinRadialVelocity;
+               }
+               kp->pen[i].yv = INTRAND(-MaxAngularVelocity, MaxAngularVelocity);
+               if (kp->pen[i].yv > 0.0) {
+                       kp->pen[i].yv += MinAngularVelocity;
+               } else if (kp->pen[i].yv < 0.0) {
+                       kp->pen[i].yv -= MinAngularVelocity;
+               }
+       } else {
+               kp->pen[i].xv = INTRAND(-MaxVelocity, MaxVelocity);
+               if (kp->pen[i].xv > 0.0) {
+                       kp->pen[i].xv += MinVelocity;
+               } else if (kp->pen[i].xv < 0.0) {
+                       kp->pen[i].xv -= MinVelocity;
+               }
+               kp->pen[i].yv = INTRAND(-MaxVelocity, MaxVelocity);
+               if (kp->pen[i].yv > 0.0) {
+                       kp->pen[i].yv += MinVelocity;
+               } else if (kp->pen[i].yv < 0.0) {
+                       kp->pen[i].yv -= MinVelocity;
+               }
+       }
+}
+
+
+static void
+random_position(kaleidstruct * kp, int i)
+{
+
+       if (kp->modetype >= 0) {
+               if (kp->linear) {
+                       double      radius, angle;
+
+                       radius = (double) INTRAND(0, (int) (kp->radius - 1.0));
+                       angle = (double) INTRAND(0, (int) (kp->slice - 1.0));
+
+                       kp->pen[i].cx = PolarToCartX(radius, angle);
+                       kp->pen[i].cy = PolarToCartY(radius, angle);
+               } else {
+                       kp->pen[i].cx = (double) INTRAND(0, (int) (kp->radius - 1.0));
+                       kp->pen[i].cy = (double) INTRAND(0, (int) (kp->slice - 1.0));
+               }
+       } else if (kp->modetype == OCT) {
+               double      radius, angle;
+
+               radius = (double) INTRAND(0, (int) (kp->radius - 1.0));
+               angle = (double) INTRAND(0, 44);
+
+               kp->pen[i].cx = PolarToCartX(radius, angle);
+               kp->pen[i].cy = PolarToCartY(radius, angle);
+       } else {
+               kp->pen[i].cx = (double) INTRAND(0, (int) (kp->widthby2 - 1.0));
+               kp->pen[i].cy = (double) INTRAND(0,
+                    (int) ((kp->heightby2 * kp->pen[i].cx) / kp->widthby2));
+       }
+}
+
+
+/*-
+ *
+ */
+void
+init_kaleid(ModeInfo * mi)
+{
+       kaleidstruct *kp = &kaleids[MI_SCREEN(mi)];
+       int         i;
+
+
+       if (kaleids == NULL) {
+               if ((kaleids = (kaleidstruct *) calloc(
+                                                         MI_NUM_SCREENS(mi),
+                                                      sizeof (kaleidstruct))
+                   ) == NULL
+                       )
+                       return;
+       }
+       kp = &kaleids[MI_SCREEN(mi)];
+
+       kp->PenCount = MI_COUNT(mi);
+
+       if (MI_IS_FULLRANDOM(mi)) {
+               kp->alternate = (Bool) (LRAND() & 1);
+               kp->disconnected = (Bool) (LRAND() & 1);
+               kp->serial = (Bool) (LRAND() & 1);
+               kp->linear = (Bool) (LRAND() & 1);
+       } else {
+               kp->alternate = Alternate;
+               kp->disconnected = Disconnected;
+               kp->serial = Serial;
+               kp->linear = Linear;
+       }
+
+       if (kp->PenCount < -MINPENS) {
+               /* if kp->PenCount is random ... the size can change */
+               if (kp->pen != NULL) {
+                       (void) free((void *) kp->pen);
+                       kp->pen = NULL;
+               }
+               kp->PenCount = NRAND(-kp->PenCount - MINPENS + 1) + MINPENS;
+       } else if (kp->PenCount < MINPENS)
+               kp->PenCount = MINPENS;
+
+       if (kp->pen == NULL)
+               kp->pen = (penstruct *) malloc(kp->PenCount * sizeof (penstruct));
+
+       if ((MI_SIZE(mi)) > MINSIZE) {
+               kp->modetype = (!kp->alternate + 1) * MI_SIZE(mi);
+       } else if ((MI_SIZE(mi)) < -MINSIZE) {
+               kp->modetype = (!kp->alternate + 1) * (NRAND(-MI_SIZE(mi) + 1) + MINSIZE);
+       } else {
+               kp->modetype = (!kp->alternate + 1) * MINSIZE;
+       }
+       if (MI_IS_FULLRANDOM(mi)) {
+               int         tmp;
+
+               tmp = NRAND(ABS(MI_SIZE(mi)) + 2);
+               if (tmp == 0)
+                       kp->modetype = OCT;
+               else if (tmp == 1)
+                       kp->modetype = QUAD;
+       } else {
+               if (Oct)
+                       kp->modetype = OCT;
+               else if (Quad)
+                       kp->modetype = QUAD;
+       }
+
+       kp->PercentBlack = (int) MAX(0, MIN(MI_CYCLES(mi), 95));
+
+
+       /* set various size parameters */
+
+       kp->width = (double) MI_WIDTH(mi);
+       kp->height = (double) MI_HEIGHT(mi);
+
+       if (kp->width < 2.0)
+               kp->width = 2.0;
+       if (kp->height < 2.0)
+               kp->height = 2.0;
+
+       kp->radius = sqrt(((kp->width * kp->width) +
+                          (kp->height * kp->height)
+                         ) / 4.0
+               );
+
+
+       if (kp->modetype >= 0) {
+               kp->bouncetype = INTRAND(0, 2);
+
+               kp->slice = 360.0 / (double) kp->modetype;
+
+               kp->widthby2 = kp->width / 2.0;
+               kp->heightby2 = kp->height / 2.0;
+       } else {
+               kp->widthby2 = kp->width / 2.0;
+               kp->heightby2 = kp->height / 2.0;
+       }
+
+       /* set the maximum pen width */
+       if (kp->modetype >= 0) {
+               if ((kp->slice == 360.0) || (kp->slice == 180.0)) {
+                       kp->maxlwidth = (int) ((((double) MIN(kp->widthby2, kp->heightby2)) *
+                                            (double) WidthPercent) / 100.0);
+               } else {
+                       kp->maxlwidth = (int) (((sin(kp->slice * ToRadians) *
+                                         MIN(kp->widthby2, kp->heightby2)) *
+                                            (double) WidthPercent) / 100.0);
+               }
+       } else {
+               kp->maxlwidth = (int) ((MIN(kp->widthby2,
+                                           kp->heightby2
+                                       ) * (double) WidthPercent
+                                      ) / 100.0
+                       );
+       }
+
+       if (kp->maxlwidth <= 0) {
+               kp->maxlwidth = 1;
+       }
+       for (i = 0; i < kp->PenCount; i += 1) {
+               if (MI_NPIXELS(mi) > 2) {
+                       kp->pen[i].pix = NRAND(MI_NPIXELS(mi));
+                       kp->pen[i].White = 1;
+               } else {
+                       kp->pen[i].White = 1;
+               }
+
+               kp->pen[i].curlwidth = INTRAND(1, kp->maxlwidth);
+
+               kp->pen[i].RadiusOut = False;
+               kp->pen[i].AngleOut = False;
+
+               random_position(kp, i);
+
+               kp->pen[i].ox = kp->pen[i].cx;
+               kp->pen[i].oy = kp->pen[i].cy;
+               kp->pen[i].DeferredChange = False;
+
+               random_velocity(kp, i);
+       }
+       MI_CLEARWINDOW(mi);
+
+}
+
+/*-
+ *
+ */
+static void
+set_pen_attributes(ModeInfo * mi, kaleidstruct * kp, int i)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+
+       if (kp->pen[i].White) {
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, gc, MI_PIXEL(mi, kp->pen[i].pix));
+               else
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       } else {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       }
+       XSetLineAttributes(display, gc,
+                      kp->pen[i].curlwidth, LineSolid, CapRound, JoinRound);
+}
+
+/*-
+ *
+ */
+static void
+change_pen(ModeInfo * mi, kaleidstruct * kp, int i)
+{
+       if (INTRAND(0, 100) < kp->PercentBlack) {
+               kp->pen[i].White = 0;
+       } else {
+               kp->pen[i].White = 1;
+               if (kp->serial) {
+                       if (MI_NPIXELS(mi) > 2) {
+                               if (++kp->pen[i].pix >= MI_NPIXELS(mi))
+                                       kp->pen[i].pix = 0;
+                       }
+               } else {
+                       if (MI_NPIXELS(mi) > 2) {
+                               kp->pen[i].pix = NRAND(MI_NPIXELS(mi));
+                       }
+               }
+       }
+
+       random_velocity(kp, i);
+
+       kp->pen[i].curlwidth = INTRAND(1, kp->maxlwidth);
+
+       if (kp->modetype >= 0) {
+               kp->bouncetype = INTRAND(0, 2);
+       }
+       if (kp->disconnected) {
+               random_position(kp, i);
+               kp->pen[i].ox = kp->pen[i].cx;
+               kp->pen[i].oy = kp->pen[i].cy;
+       }
+}
+
+/*-
+ *
+ */
+void
+draw_kaleid(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       kaleidstruct *kp = &kaleids[MI_SCREEN(mi)];
+       XSegment   *segs;
+       int         NumberOfSegments = 0;
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (kp->modetype == QUAD) {
+               NumberOfSegments = 4;
+               segs = (XSegment *) malloc(NumberOfSegments * sizeof (XSegment));
+       } else if (kp->modetype == OCT) {
+               NumberOfSegments = 8;
+               segs = (XSegment *) malloc(NumberOfSegments * sizeof (XSegment));
+       } else {                /* if (kp->modetype > 0) */
+               NumberOfSegments = kp->modetype;
+               segs = (XSegment *) malloc(NumberOfSegments * sizeof (XSegment));
+       }
+       for (i = 0; i < kp->PenCount; i++) {
+               set_pen_attributes(mi, kp, i);
+
+               if (kp->modetype == QUAD) {
+                       if (kp->alternate) {
+                               QuadRotated(kp, i, segs);
+                       } else {
+                               QuadMirrored(kp, i, segs);
+                       }
+               } else if (kp->modetype == OCT) {
+                       if (kp->alternate) {
+                               OctRotated(kp, i, segs);
+                       } else {
+                               OctMirrored(kp, i, segs);
+                       }
+               } else {
+                       if (kp->alternate) {
+                               if (kp->linear) {
+                                       GeneralLinearRotated(kp, i, segs);
+                               } else {
+                                       GeneralRotated(kp, i, segs);
+                               }
+                       } else {
+                               if (kp->linear) {
+                                       GeneralLinearMirrored(kp, i, segs);
+                               } else {
+                                       GeneralMirrored(kp, i, segs);
+                               }
+                       }
+               }
+               XDrawSegments(
+                                    display,
+                                    MI_WINDOW(mi),
+                                    gc,
+                                    segs,
+                                    NumberOfSegments
+                       );
+
+               kp->pen[i].ox = kp->pen[i].cx;
+               kp->pen[i].oy = kp->pen[i].cy;
+
+
+               if ((INTRAND(0, 100) < ChangeChance) || kp->pen[i].DeferredChange) {
+                       if (!kp->pen[i].AngleOut && !kp->pen[i].RadiusOut) {
+                               kp->pen[i].DeferredChange = False;
+                               change_pen(mi, kp, i);
+                       } else {
+                               kp->pen[i].DeferredChange = True;
+                       }
+               }
+       }
+
+       XSetLineAttributes(display, gc, 1, LineSolid, CapRound, JoinRound);
+       (void) free((void *) segs);
+}
+
+/*-
+ *
+ */
+void
+release_kaleid(ModeInfo * mi)
+{
+       if (kaleids != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       kaleidstruct *kp = &kaleids[MI_SCREEN(mi)];
+
+                       if (kp->pen != NULL)
+                               (void) free((void *) kp->pen);
+               }
+               (void) free((void *) kaleids);
+               kaleids = NULL;
+       }
+}
+
+/*-
+ *
+ */
+void
+refresh_kaleid(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_kaleid */
diff --git a/xlockmore-4.14/modes/kumppa.c b/xlockmore-4.14/modes/kumppa.c
new file mode 100644 (file)
index 0000000..e2e388b
--- /dev/null
@@ -0,0 +1,743 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* kumppa ---  */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)kumppa.c     4.11 98/06/11 xlockmore";
+
+#endif
+
+/*-
+   Copyright (C) Teemu Suutari (temisu@utu.fi) Feb 1998
+
+   Permission is hereby granted, free of charge, to any person obtaining
+   a copy of this software and associated documentation files (the
+   "Software"), to deal in the Software without restriction, including
+   without limitation the rights to use, copy, modify, merge, publish,
+   distribute, sublicense, and/or sell copies of the Software, and to
+   permit persons to whom the Software is furnished to do so, subject to
+   the following conditions:
+
+   The above copyright notice and this permission notice shall be included
+   in all copies or substantial portions of the Software.
+
+   THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+   OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+   MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+   IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR
+   OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+   ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+   OTHER DEALINGS IN THE SOFTWARE.
+
+   Except as contained in this notice, the name of the X Consortium shall
+   not be used in advertising or otherwise to promote the sale, use or
+   other dealings in this Software without prior written authorization
+   from the X Consortium.
+
+   * Revision History:
+   * 16-Jul-98:  xlockmore version by Jouk Jansen <joukj@hrem.stm.tudelft.nl>
+   * Feb 1998 :  original xscreensaver version by Teemu Suutari <temisu@utu.fi>
+ */
+
+/*-
+   *** This is contest-version. Don't look any further, code is *very* ugly.
+ */
+
+
+#include <math.h>
+
+
+#if 0
+/* commented out since xlockmore does not support (yet) double buffering */
+#ifdef HAVE_XDBE_EXTENSION
+#include <X11/extensions/Xdbe.h>
+#endif /* HAVE_XDBE_EXTENSION */
+#endif
+
+#ifdef STANDALONE
+#define PROGCLASS "kumppa"
+#define HACK_INIT init_kumppa
+#define HACK_DRAW draw_kumppa
+#define kumppa_opts xlockmore_opts
+#define DEFAULTS "*delay: 0 \n" \
+ "*cycles: 1000 \n" \
+ ".background: black\n",\
+ "*speed: 0.1",\
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_kumppa
+
+#define DEF_COSILINES "True"
+#define DEF_SPEED "0.1"
+
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+#define DEF_USEDOUBLE "False"
+
+static Bool usedouble;
+
+#endif /* HAVE_XDBE_EXTENSION */
+#endif
+
+static Bool cosilines;
+static Bool mono_p;
+static float speed;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-speed", ".kumppa.speed", XrmoptionSepArg, (caddr_t) NULL},
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+       {"-dbuf", ".kumppa.dbuf", XrmoptionNoArg, (caddr_t) "on"},
+       {"+dbuf", ".kumppa.dbuf", XrmoptionNoArg, (caddr_t) "off"},
+#endif                         /* HAVE_XDBE_EXTENSION */
+#endif
+       {"-rrandom", ".kumppa.rrandom", XrmoptionNoArg, (caddr_t) "on"},
+       {"+rrandom", ".kumppa.rrandom", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & speed, "speed", "speed", DEF_SPEED, t_Float},
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+       {(caddr_t *) & usedouble, "dbuf", "dbuf", DEF_USEDOUBLE, t_Bool},
+#endif                         /* HAVE_XDBE_EXTENSION */
+#endif
+       {(caddr_t *) & cosilines, "rrandom", "rrandom", DEF_COSILINES, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-speed num", "Speed"},
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+       {"-/+dbuf", "turn on/off double buffering"},
+#endif                         /* HAVE_XDBE_EXTENSION */
+#endif
+       {"-/+rrandom", "turn on/off random"}
+};
+
+ModeSpecOpt kumppa_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   kumppa_description =
+{"kumppa", "init_kumppa", "draw_kumppa", "release_kumppa",
+ "refresh_kumppa", "init_kumppa", NULL, &kumppa_opts,
+ 10000, 1, 1000, 1, 64, 1.0, "",
+ "Shows Kumppa", 0, NULL};
+
+#endif
+
+static const unsigned char colors[96] =
+{0, 0, 255, 0, 51, 255, 0, 102, 255, 0, 153, 255, 0, 204, 255,
+ 0, 255, 255, 0, 255, 204, 0, 255, 153, 0, 255, 102, 0, 255, 51,
+ 0, 255, 0, 51, 255, 0, 102, 255, 0, 153, 255, 0, 204, 255, 0,
+ 255, 255, 0, 255, 204, 0, 255, 153, 0, 255, 102, 0, 255, 51, 0,
+ 255, 0, 0, 255, 0, 51, 255, 0, 102, 255, 0, 153, 255, 0, 204,
+ 255, 0, 255, 219, 0, 255, 182, 0, 255, 146, 0, 255, 109, 0, 255,
+ 73, 0, 255, 37, 0, 255};
+
+static const float cosinus[8][6] =
+{
+       {-0.07, 0.12, -0.06, 32, 25, 37},
+       {0.08, -0.03, 0.05, 51, 46, 32},
+       {0.12, 0.07, -0.13, 27, 45, 36},
+       {0.05, -0.04, -0.07, 36, 27, 39},
+       {-0.02, -0.07, 0.1, 21, 43, 42},
+       {-0.11, 0.06, 0.02, 51, 25, 34},
+       {0.04, -0.15, 0.02, 42, 32, 25},
+       {-0.02, -0.04, -0.13, 34, 20, 15}};
+
+static const float acosinus[24] =
+{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
+
+static const int   ocoords[8] =
+{0, 0, 0, 0, 0, 0, 0, 0};
+
+typedef struct {
+       Colormap    cmap;
+       float      *acosinus;
+       unsigned long blackpixel, whitepixel, fg, bg;
+       int         coords[8];
+       int         ocoords[8];
+
+       GC          fgc[33];
+       GC          cgc;
+       int         sizx, sizy;
+       int         midx, midy;
+
+       int        *Xrotations;
+       int        *Yrotations;
+       int        *Xrottable;
+       int        *Yrottable;
+
+       int        *rotateX;
+       int        *rotateY;
+
+       int         rotsizeX, rotsizeY;
+       int         stateX, stateY;
+       int         dir, time;
+       int         rx, ry;
+       int         c;
+       long        c1;
+       Bool        cosilines;
+} kumppastruct;
+
+static kumppastruct *kumppas = NULL;
+
+
+
+static int
+Satnum(int maxi)
+{
+       return (int) (maxi * ((double) NRAND(2500) / 2500.0));
+}
+
+
+static void
+palaRotate(ModeInfo * mi, int x, int y)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         ax, ay, bx, by, cx, cy;
+       kumppastruct *s = &kumppas[MI_SCREEN(mi)];
+
+       ax = s->rotateX[x];
+       ay = s->rotateY[y];
+       bx = s->rotateX[x + 1] + 2;
+       by = s->rotateY[y + 1] + 2;
+       cx = s->rotateX[x] + (x - s->rx) - s->dir * (y - s->ry);
+       cy = s->rotateY[y] + s->dir * (x - s->rx) + (y - s->ry);
+       if (cx < 0) {
+               ax -= cx;
+               cx = 0;
+       }
+       if (cy < 0) {
+               ay -= cy;
+               cy = 0;
+       }
+       if (cx + bx - ax > s->sizx)
+               bx = ax - cx + s->sizx;
+       if (cy + by - ay > s->sizy)
+               by = ay - cy + s->sizy;
+       if (ax < bx && ay < by) {
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       XCopyArea(display, window, window, s->cgc, ax, ay, bx - ax, by - ay, cx, cy);
+               } else {
+                       XCopyArea(display, window, window, MI_GC(mi), ax, ay, bx - ax, by - ay, cx, cy);
+               }
+       }
+}
+
+
+static void
+rotate(ModeInfo * mi)
+{
+       int         x, y;
+       int         dx, dy;
+       kumppastruct *s = &kumppas[MI_SCREEN(mi)];
+
+       s->rx = s->Xrottable[s->stateX + 1] - s->Xrottable[s->stateX];
+       s->ry = s->Yrottable[s->stateX + 1] - s->Yrottable[s->stateY];
+
+
+       for (x = 0; x <= s->rx; x++)
+               s->rotateX[x] = (x) ? s->midx - 1 - s->Xrotations[s->Xrottable[s->stateX + 1] - x] : 0;
+       for (x = 0; x <= s->rx; x++)
+               s->rotateX[x + s->rx + 1] = (x == s->rx) ? s->sizx - 1 : s->midx + s->Xrotations[s->Xrottable[s->stateX] + x];
+       for (y = 0; y <= s->ry; y++)
+               s->rotateY[y] = (y) ? s->midy - 1 - s->Yrotations[s->Yrottable[s->stateY + 1] - y] : 0;
+       for (y = 0; y <= s->ry; y++)
+               s->rotateY[y + s->ry + 1] = (y == s->ry) ? s->sizy - 1 : s->midy + s->Yrotations[s->Yrottable[s->stateY] + y];
+
+       x = (s->rx > s->ry) ? s->rx : s->ry;
+       for (dy = 0; dy < (x + 1) << 1; dy++)
+               for (dx = 0; dx < (x + 1) << 1; dx++) {
+                       y = (s->rx > s->ry) ? s->ry - s->rx : 0;
+                       if (dy + y >= 0 && dy < (s->ry + 1) << 1 && dx < (s->rx + 1) << 1)
+                               if (dy + y + dx <= s->ry + s->rx && dy + y - dx <= s->ry - s->rx) {
+                                       palaRotate(mi, (s->rx << 1) + 1 - dx, dy + y);
+                                       palaRotate(mi, dx, (s->ry << 1) + 1 - dy - y);
+                               }
+                       y = (s->ry > s->rx) ? s->rx - s->ry : 0;
+                       if (dy + y >= 0 && dx < (s->ry + 1) << 1 && dy < (s->rx + 1) << 1)
+                               if (dy + y + dx <= s->ry + s->rx && dx - dy - y >= s->ry - s->rx) {
+                                       palaRotate(mi, dy + y, dx);
+                                       palaRotate(mi, (s->rx << 1) + 1 - dy - y, (s->ry << 1) + 1 - dx);
+                               }
+               }
+       s->stateX++;
+       if (s->stateX == s->rotsizeX)
+               s->stateX = 0;
+       s->stateY++;
+       if (s->stateY == s->rotsizeY)
+               s->stateY = 0;
+}
+
+
+
+static void
+make_rots(ModeInfo * mi, double xspeed, double yspeed)
+{
+       int         a, b, c, f, g, j, k = 0, l;
+       double      m, om, ok;
+       double      d, ix, iy;
+       int         maxi;
+       kumppastruct *s = &kumppas[MI_SCREEN(mi)];
+
+       Bool       *chks;
+
+       s->rotsizeX = (int) (2 / xspeed + 1);
+       ix = (double) (s->midx + 1) / (double) (s->rotsizeX);
+       s->rotsizeY = (int) (2 / yspeed + 1);
+       iy = (double) (s->midy + 1) / (double) (s->rotsizeY);
+
+       if (s->Xrotations)
+               (void) free((void *) s->Xrotations);
+       if (s->Yrotations)
+               (void) free((void *) s->Yrotations);
+
+       s->Xrotations = (int *) calloc((s->midx + 2), sizeof (int));
+       s->Yrotations = (int *) calloc((s->midy + 2), sizeof (int));
+
+       if (s->Xrottable)
+               (void) free((void *) s->Xrottable);
+       if (s->Yrottable)
+               (void) free((void *) s->Yrottable);
+       s->Xrottable = (int *) malloc((s->rotsizeX + 1) * sizeof (int));
+       s->Yrottable = (int *) malloc((s->rotsizeY + 1) * sizeof (int));
+
+       chks = (Bool *) malloc(((s->midx > s->midy) ? s->midx : s->midy) * sizeof (Bool));
+
+
+       maxi = 0;
+       c = 0;
+       d = 0;
+       g = 0;
+       for (a = 0; a < s->midx; a++)
+               chks[a] = True;
+       for (a = 0; a < s->rotsizeX; a++) {
+               s->Xrottable[a] = c;
+               f = (int) (d + ix) - g;         /*viivojen lkm. */
+               g += f;
+               if (g > s->midx) {
+                       f -= g - s->midx;
+                       g = s->midx;
+               }
+               for (b = 0; b < f; b++) {
+                       m = 0;
+                       for (j = 0; j < s->midx; j++) {         /*testi */
+                               if (chks[j]) {
+                                       om = 0;
+                                       ok = 1;
+                                       l = 0;
+                                       while (j + l < s->midx && om + 12 * ok > m) {
+                                               if (j - l >= 0) {
+                                                       if (chks[j - l])
+                                                               om += ok;
+                                               } else if (chks[l - j])
+                                                       om += ok;
+                                               if (chks[j + l])
+                                                       om += ok;
+                                               ok /= 1.5;
+                                               l++;
+                                       }
+                                       if (om >= m) {
+                                               k = j;
+                                               m = om;
+                                       }
+                               }
+                       }
+                       chks[k] = False;
+                       l = c;
+                       while (l >= s->Xrottable[a]) {
+                               if (l != s->Xrottable[a])
+                                       s->Xrotations[l] = s->Xrotations[l - 1];
+                               if (k > s->Xrotations[l] || l == s->Xrottable[a]) {
+                                       s->Xrotations[l] = k;
+                                       c++;
+                                       l = s->Xrottable[a];
+                               }
+                               l--;
+                       }
+               }
+               d += ix;
+               if (maxi < c - s->Xrottable[a])
+                       maxi = c - s->Xrottable[a];
+       }
+       s->Xrottable[a] = c;
+       if (s->rotateX)
+               (void) free((void *) s->rotateX);
+       s->rotateX = (int *) calloc((maxi + 2) << 1, sizeof (int));
+
+       maxi = 0;
+       c = 0;
+       d = 0;
+       g = 0;
+       for (a = 0; a < s->midy; a++)
+               chks[a] = True;
+       for (a = 0; a < s->rotsizeY; a++) {
+               s->Yrottable[a] = c;
+               f = (int) (d + iy) - g;         /*viivojen lkm. */
+               g += f;
+               if (g > s->midy) {
+                       f -= g - s->midy;
+                       g = s->midy;
+               }
+               for (b = 0; b < f; b++) {
+                       m = 0;
+                       for (j = 0; j < s->midy; j++) {         /*testi */
+                               if (chks[j]) {
+                                       om = 0;
+                                       ok = 1;
+                                       l = 0;
+                                       while (j + l < s->midy && om + 12 * ok > m) {
+                                               if (j - l >= 0) {
+                                                       if (chks[j - l])
+                                                               om += ok;
+                                               } else if (chks[l - j])
+                                                       om += ok;
+                                               if (chks[j + l])
+                                                       om += ok;
+                                               ok /= 1.5;
+                                               l++;
+                                       }
+                                       if (om >= m) {
+                                               k = j;
+                                               m = om;
+                                       }
+                               }
+                       }
+                       chks[k] = False;
+                       l = c;
+                       while (l >= s->Yrottable[a]) {
+                               if (l != s->Yrottable[a])
+                                       s->Yrotations[l] = s->Yrotations[l - 1];
+                               if (k > s->Yrotations[l] || l == s->Yrottable[a]) {
+                                       s->Yrotations[l] = k;
+                                       c++;
+                                       l = s->Yrottable[a];
+                               }
+                               l--;
+                       }
+
+               }
+               d += iy;
+               if (maxi < c - s->Yrottable[a])
+                       maxi = c - s->Yrottable[a];
+       }
+       s->Yrottable[a] = c;
+       if (s->rotateY)
+               (void) free((void *) s->rotateY);
+       s->rotateY = (int *) calloc((maxi + 2) << 1, sizeof (int));
+
+       (void) free((void *) chks);
+}
+
+
+void
+init_kumppa(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       XGCValues   xgcv;
+       int         n, i;
+       double      rspeed;
+       kumppastruct *s;
+
+       if (kumppas == NULL) {
+               if ((kumppas = (kumppastruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (kumppastruct))) == NULL)
+                       return;
+       }
+       s = &kumppas[MI_SCREEN(mi)];
+
+       if (!s->acosinus) {
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       XColor      color;
+
+#ifndef STANDALONE
+                       extern char *background;
+                       extern char *foreground;
+
+                       s->fg = MI_FG_PIXEL(mi);
+                       s->bg = MI_BG_PIXEL(mi);
+#endif
+                       s->blackpixel = MI_BLACK_PIXEL(mi);
+                       s->whitepixel = MI_WHITE_PIXEL(mi);
+                       s->cmap = XCreateColormap(display, window, MI_VISUAL(mi), AllocNone);
+
+                       XSetWindowColormap(display, window, s->cmap);
+                       (void) XParseColor(display, s->cmap, "black", &color);
+                       (void) XAllocColor(display, s->cmap, &color);
+                       MI_BLACK_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, s->cmap, "white", &color);
+                       (void) XAllocColor(display, s->cmap, &color);
+                       MI_WHITE_PIXEL(mi) = color.pixel;
+#ifndef STANDALONE
+                       (void) XParseColor(display, s->cmap, background, &color);
+                       (void) XAllocColor(display, s->cmap, &color);
+                       MI_BG_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, s->cmap, foreground, &color);
+                       (void) XAllocColor(display, s->cmap, &color);
+                       MI_FG_PIXEL(mi) = color.pixel;
+#endif
+
+                       xgcv.function = GXcopy;
+                       xgcv.foreground = MI_BLACK_PIXEL(mi);
+                       s->fgc[32] = XCreateGC(display, window, GCForeground | GCFunction, &xgcv);
+
+                       n = 0;
+                       if (mono_p) {
+                               s->fgc[0] = s->fgc[32];
+                               xgcv.foreground = MI_BLACK_PIXEL(mi);
+                               s->fgc[1] = XCreateGC(display, window, GCForeground | GCFunction, &xgcv);
+                               for (i = 0; i < 32; i += 2)
+                                       s->fgc[i] = s->fgc[0];
+                               for (i = 1; i < 32; i += 2)
+                                       s->fgc[i] = s->fgc[1];
+                       } else
+                               for (i = 0; i < 32; i++) {
+                                       color.red = colors[n++] * 256;
+                                       color.green = colors[n++] * 256;
+                                       color.blue = colors[n++] * 256;
+                                       color.flags = DoRed | DoGreen | DoBlue;
+                                       (void) XAllocColor(display, s->cmap, &color);
+                                       xgcv.foreground = color.pixel;
+                                       s->fgc[i] = XCreateGC(display, window, GCForeground | GCFunction, &xgcv);
+                               }
+                       xgcv.foreground = MI_BLACK_PIXEL(mi);
+                       xgcv.function = GXcopy;
+                       s->cgc = XCreateGC(display, window, GCForeground | GCFunction, &xgcv);
+               }
+               s->acosinus = (float *) malloc(24 * sizeof (float));
+               (void) memcpy(s->acosinus, acosinus, 24 * sizeof (float));
+               (void) memcpy(s->ocoords, ocoords, 8 * sizeof (int));
+       }
+       if (MI_NCOLORS(mi) <= 2)
+               mono_p = True;
+       else
+               mono_p = False;
+
+       if (MI_IS_FULLRANDOM(mi)) {
+               if (NRAND(2) == 1)
+                       s->cosilines = False;
+               else
+                       s->cosilines = True;
+       } else {
+               s->cosilines = cosilines;
+       }
+       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+               XInstallColormap(display, s->cmap);
+               XSetGraphicsExposures(display, s->cgc, False);
+       } else {
+               XSetGraphicsExposures(display, MI_GC(mi), False);
+               s->c1 = NRAND(MI_NPIXELS(mi));
+       }
+       s->time = MI_CYCLES(mi) + NRAND(MI_CYCLES(mi));
+
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+       if (get_string_resource("dbuf", "String") != NULL && get_string_resource("dbuf", "String")[0] != 0)
+               usedouble = True;
+       if (usedouble) {
+               XdbeQueryExtension(display, &n, &i);
+               if (n == 0 && i == 0) {
+                       (void) fprintf(stderr, "Double buffer extension not supported!\n");
+                       usedouble = False;
+               }
+       }
+       if (usedouble)
+               win[1] = XdbeAllocateBackBufferName(display, win[0], XdbeUndefined);
+#endif /* HAVE_XDBE_EXTENSION */
+#endif
+
+       rspeed = (double) speed;
+       if (rspeed < 0.0001 || rspeed > 0.2) {
+               (void) fprintf(stderr,
+                  "Speed not in valid range! (0.0001 - 0.2), using 0.1 \n");
+               rspeed = 0.1;
+       }
+       s->sizx = MI_WIDTH(mi);
+       s->sizy = MI_HEIGHT(mi);
+       s->midx = s->sizx >> 1;
+       s->midy = s->sizy >> 1;
+       s->stateX = 0;
+       s->stateY = 0;
+       s->c = 0;
+       s->dir = (LRAND() & 1) ? -1 : 1;
+       MI_CLEARWINDOW(mi);
+
+       make_rots(mi, rspeed, rspeed);
+}
+
+
+void
+draw_kumppa(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc;
+       kumppastruct *s = &kumppas[MI_SCREEN(mi)];
+
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+       XdbeSwapInfo xdswp;
+
+#endif /* HAVE_XDBE_EXTENSION */
+#endif
+       int         a, b, e;
+       float       f;
+
+       MI_IS_DRAWN(mi) = True;
+
+
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+       if (usedouble) {
+               xdswp.swap_action = XdbeUndefined;
+               xdswp.swap_window = win[0];
+       } else
+#endif /* HAVE_XDBE_EXTENSION */
+               win[1] = win[0];
+#endif
+
+       if (s->cosilines) {
+               s->c++;
+               for (a = 0; a < 8; a++) {
+                       f = 0;
+                       for (b = 0; b < 3; b++) {
+                               s->acosinus[a * 3 + b] += cosinus[a][b];
+                               f += cosinus[a][b + 3] *
+                                       sin((double) s->acosinus[a * 3 + b]);
+                       }
+                       s->coords[a] = (int) f;
+               }
+               for (a = 0; a < 4; a++) {
+                       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                               gc = (mono_p) ? s->fgc[1] : s->fgc[((a << 2) + s->c) & 31];
+                       } else {
+                               gc = MI_GC(mi);
+                               if (MI_NPIXELS(mi) <= 2)
+                                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                               else
+                                       XSetForeground(display, gc, MI_PIXEL(mi, ((((a << 2) + s->c) & 31) * MI_NPIXELS(mi) / 32) % MI_NPIXELS(mi)));
+                       }
+                       XDrawLine(display, window, gc,
+                                 s->midx + s->ocoords[a << 1], s->midy + s->ocoords[(a << 1) + 1],
+                                 s->midx + s->coords[a << 1], s->midy + s->coords[(a << 1) + 1]);
+                       s->ocoords[a << 1] = s->coords[a << 1];
+                       s->ocoords[(a << 1) + 1] = s->coords[(a << 1) + 1];
+               }
+
+       } else {
+               for (e = 0; e < 8; e++) {
+                       a = Satnum(50);
+                       if (a >= 32)
+                               a = 32;
+                       b = Satnum(32) - 16 + s->midx;
+                       s->c = Satnum(32) - 16 + s->midy;
+                       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                               gc = s->fgc[a];
+                       } else {
+                               gc = MI_GC(mi);
+                               if (MI_NPIXELS(mi) > 2)
+                                       XSetForeground(display, gc, MI_PIXEL(mi, (a * MI_NPIXELS(mi) / 32) % MI_NPIXELS(mi)));
+                               else
+                                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                       }
+                       XFillRectangle(display, window, gc, b, s->c, 2, 2);
+               }
+       }
+       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+               gc = s->fgc[32];
+       } else {
+               gc = MI_GC(mi);
+               if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, s->c1));
+               else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       }
+       XFillRectangle(display, window, gc, s->midx - 2, s->midy - 2, 4, 4);
+       rotate(mi);
+#if 0
+#ifdef HAVE_XDBE_EXTENSION
+       if (usedouble)
+               XdbeSwapBuffers(display, &xdswp, 1);
+#endif /* HAVE_XDBE_EXTENSION */
+#endif
+       if (--s->time <= 0) {
+               s->time = MI_CYCLES(mi) + NRAND(MI_CYCLES(mi));
+               s->dir = s->dir * (-1);
+       }
+}
+
+
+void
+refresh_kumppa(ModeInfo * mi)
+{
+       init_kumppa(mi);
+}
+
+void
+release_kumppa(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+
+       if (kumppas != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       kumppastruct *s = &kumppas[screen];
+
+                       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                               MI_WHITE_PIXEL(mi) = s->whitepixel;
+                               MI_BLACK_PIXEL(mi) = s->blackpixel;
+#ifndef STANDALONE
+                               MI_FG_PIXEL(mi) = s->fg;
+                               MI_BG_PIXEL(mi) = s->bg;
+#endif
+                               if (s->fgc[32])
+                                       XFreeGC(display, s->fgc[32]);
+                               if (mono_p) {
+                                       if (s->fgc[1])
+                                               XFreeGC(display, s->fgc[1]);
+                               } else {
+                                       int         i;
+
+                                       for (i = 0; i < 32; i++) {
+                                               if (s->fgc[i])
+                                                       XFreeGC(display, s->fgc[i]);
+                                       }
+                               }
+                               if (s->cgc)
+                                       XFreeGC(display, s->cgc);
+                               if (s->cmap) {
+                                       XFreeColormap(display, s->cmap);
+                               }
+                       }
+                       if (s->acosinus)
+                               (void) free((void *) s->acosinus);
+                       if (s->Xrotations)
+                               (void) free((void *) s->Xrotations);
+                       if (s->Yrotations)
+                               (void) free((void *) s->Yrotations);
+                       if (s->Xrottable)
+                               (void) free((void *) s->Xrottable);
+                       if (s->Yrottable)
+                               (void) free((void *) s->Yrottable);
+                       if (s->rotateX)
+                               (void) free((void *) s->rotateX);
+                       if (s->rotateY)
+                               (void) free((void *) s->rotateY);
+               }
+               (void) free((void *) kumppas);
+               kumppas = NULL;
+       }
+}
+
+#endif /* MODE_kumppa */
diff --git a/xlockmore-4.14/modes/laser.c b/xlockmore-4.14/modes/laser.c
new file mode 100644 (file)
index 0000000..12d7a88
--- /dev/null
@@ -0,0 +1,340 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* laser --- spinning lasers */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)laser.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 Pascal Pensa <pensa@aurora.unice.fr>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Laser"
+#define HACK_INIT init_laser
+#define HACK_DRAW draw_laser
+#define laser_opts xlockmore_opts
+#define DEFAULTS "*delay: 20000 \n" \
+ "*count: -10 \n" \
+ "*cycles: 200 \n" \
+ "*ncolors: 200 \n"
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_laser
+
+ModeSpecOpt laser_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   laser_description =
+{"laser", "init_laser", "draw_laser", "release_laser",
+ "refresh_laser", "init_laser", NULL, &laser_opts,
+ 20000, -10, 200, 1, 64, 1.0, "",
+ "Shows spinning lasers", 0, NULL};
+
+#endif
+
+#define MINREDRAW 3            /* Number of redrawn on each frame */
+#define MAXREDRAW 8
+
+#define MINLASER  1            /* Laser number */
+
+#define MINWIDTH  2            /* Laser ray width range */
+#define MAXWIDTH 40
+
+#define MINSPEED  2            /* Speed range */
+#define MAXSPEED 17
+
+#define MINDIST  10            /* Minimal distance from edges */
+
+#define COLORSTEP 2            /* Laser color step */
+
+#define RANGE_RAND(min,max) (int) ((min) + LRAND() % ((max) - (min)))
+
+typedef enum {
+       TOP, RIGHT, BOTTOM, LEFT
+} border;
+
+typedef struct {
+       int         bx;         /* border x */
+       int         by;         /* border y */
+       border      bn;         /* active border */
+       int         dir;        /* direction */
+       int         speed;      /* laser velocity from MINSPEED to MAXSPEED */
+       int         sx[MAXWIDTH];       /* x stack */
+       int         sy[MAXWIDTH];       /* x stack */
+       XGCValues   gcv;        /* for color */
+} laserstruct;
+
+typedef struct {
+       int         width;
+       int         height;
+       int         cx;         /* center x */
+       int         cy;         /* center y */
+       int         lw;         /* laser width */
+       int         ln;         /* laser number */
+       int         lr;         /* laser redraw */
+       int         sw;         /* stack width */
+       int         so;         /* stack offset */
+       int         time;       /* up time */
+       GC          stippledGC;
+       XGCValues   gcv_black;  /* for black color */
+       laserstruct *laser;
+} lasersstruct;
+
+static lasersstruct *lasers = NULL;
+
+
+void
+init_laser(ModeInfo * mi)
+{
+       int         i, c = 0;
+       lasersstruct *lp;
+
+       if (lasers == NULL) {
+               if ((lasers = (lasersstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (lasersstruct))) == NULL)
+                       return;
+       }
+       lp = &lasers[MI_SCREEN(mi)];
+
+       lp->width = MI_WIDTH(mi);
+       lp->height = MI_HEIGHT(mi);
+       lp->time = 0;
+
+       lp->ln = MI_COUNT(mi);
+       if (lp->ln < -MINLASER) {
+               /* if lp->ln is random ... the size can change */
+               if (lp->laser != NULL) {
+                       (void) free((void *) lp->laser);
+                       lp->laser = NULL;
+               }
+               lp->ln = NRAND(-lp->ln - MINLASER + 1) + MINLASER;
+       } else if (lp->ln < MINLASER)
+               lp->ln = MINLASER;
+
+       if (!lp->laser) {
+               lp->laser = (laserstruct *) malloc(lp->ln * sizeof (laserstruct));
+       }
+       if (lp->stippledGC == NULL) {
+               XGCValues   gcv;
+
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               lp->gcv_black.foreground = MI_BLACK_PIXEL(mi);
+               lp->stippledGC = XCreateGC(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                          GCForeground | GCBackground, &gcv);
+       }
+       MI_CLEARWINDOW(mi);
+
+       if (MINDIST < lp->width - MINDIST)
+               lp->cx = RANGE_RAND(MINDIST, lp->width - MINDIST);
+       else
+               lp->cx = RANGE_RAND(0, lp->width);
+       if (MINDIST < lp->height - MINDIST)
+               lp->cy = RANGE_RAND(MINDIST, lp->height - MINDIST);
+       else
+               lp->cy = RANGE_RAND(0, lp->height);
+       lp->lw = RANGE_RAND(MINWIDTH, MAXWIDTH);
+       lp->lr = RANGE_RAND(MINREDRAW, MAXREDRAW);
+       lp->sw = 0;
+       lp->so = 0;
+
+       if (MI_NPIXELS(mi) > 2)
+               c = NRAND(MI_NPIXELS(mi));
+
+       for (i = 0; i < lp->ln; i++) {
+               laserstruct *l = &lp->laser[i];
+
+               l->bn = (border) NRAND(4);
+
+               switch (l->bn) {
+                       case TOP:
+                               l->bx = NRAND(lp->width);
+                               l->by = 0;
+                               break;
+                       case RIGHT:
+                               l->bx = lp->width;
+                               l->by = NRAND(lp->height);
+                               break;
+                       case BOTTOM:
+                               l->bx = NRAND(lp->width);
+                               l->by = lp->height;
+                               break;
+                       case LEFT:
+                               l->bx = 0;
+                               l->by = NRAND(lp->height);
+               }
+
+               l->dir = (int) (LRAND() & 1);
+               l->speed = ((RANGE_RAND(MINSPEED, MAXSPEED) * lp->width) / 1000) + 1;
+               if (MI_NPIXELS(mi) > 2) {
+                       l->gcv.foreground = MI_PIXEL(mi, c);
+                       c = (c + COLORSTEP) % MI_NPIXELS(mi);
+               } else
+                       l->gcv.foreground = MI_WHITE_PIXEL(mi);
+       }
+}
+
+static void
+draw_laser_once(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       lasersstruct *lp = &lasers[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < lp->ln; i++) {
+               laserstruct *l = &lp->laser[i];
+
+               if (lp->sw >= lp->lw) {
+                       XChangeGC(display, lp->stippledGC, GCForeground, &(lp->gcv_black));
+                       XDrawLine(display, MI_WINDOW(mi), lp->stippledGC,
+                                 lp->cx, lp->cy,
+                                 l->sx[lp->so], l->sy[lp->so]);
+               }
+               if (l->dir) {
+                       switch (l->bn) {
+                               case TOP:
+                                       l->bx -= l->speed;
+                                       if (l->bx < 0) {
+                                               l->by = -l->bx;
+                                               l->bx = 0;
+                                               l->bn = LEFT;
+                                       }
+                                       break;
+                               case RIGHT:
+                                       l->by -= l->speed;
+                                       if (l->by < 0) {
+                                               l->bx = lp->width + l->by;
+                                               l->by = 0;
+                                               l->bn = TOP;
+                                       }
+                                       break;
+                               case BOTTOM:
+                                       l->bx += l->speed;
+                                       if (l->bx >= lp->width) {
+                                               l->by = lp->height - l->bx % lp->width;
+                                               l->bx = lp->width;
+                                               l->bn = RIGHT;
+                                       }
+                                       break;
+                               case LEFT:
+                                       l->by += l->speed;
+                                       if (l->by >= lp->height) {
+                                               l->bx = l->by % lp->height;
+                                               l->by = lp->height;
+                                               l->bn = BOTTOM;
+                                       }
+                       }
+               } else {
+                       switch (l->bn) {
+                               case TOP:
+                                       l->bx += l->speed;
+                                       if (l->bx >= lp->width) {
+                                               l->by = l->bx % lp->width;
+                                               l->bx = lp->width;
+                                               l->bn = RIGHT;
+                                       }
+                                       break;
+                               case RIGHT:
+                                       l->by += l->speed;
+                                       if (l->by >= lp->height) {
+                                               l->bx = lp->width - l->by % lp->height;
+                                               l->by = lp->height;
+                                               l->bn = BOTTOM;
+                                       }
+                                       break;
+                               case BOTTOM:
+                                       l->bx -= l->speed;
+                                       if (l->bx < 0) {
+                                               l->by = lp->height + l->bx;
+                                               l->bx = 0;
+                                               l->bn = LEFT;
+                                       }
+                                       break;
+                               case LEFT:
+                                       l->by -= l->speed;
+                                       if (l->by < 0) {
+                                               l->bx = -l->bx;
+                                               l->by = 0;
+                                               l->bn = TOP;
+                                       }
+                       }
+               }
+
+               XChangeGC(display, lp->stippledGC, GCForeground, &l->gcv);
+               XDrawLine(display, MI_WINDOW(mi), lp->stippledGC,
+                         lp->cx, lp->cy, l->bx, l->by);
+
+               l->sx[lp->so] = l->bx;
+               l->sy[lp->so] = l->by;
+
+       }
+
+       if (lp->sw < lp->lw)
+               ++lp->sw;
+
+       lp->so = (lp->so + 1) % lp->lw;
+}
+
+void
+draw_laser(ModeInfo * mi)
+{
+       lasersstruct *lp = &lasers[MI_SCREEN(mi)];
+       int         i;
+
+       for (i = 0; i < lp->lr; i++)
+               draw_laser_once(mi);
+
+       if (++lp->time > MI_CYCLES(mi))
+               init_laser(mi);
+}
+
+void
+release_laser(ModeInfo * mi)
+{
+       if (lasers != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       lasersstruct *lp = &lasers[screen];
+
+                       if (lp->laser != NULL)
+                               (void) free((void *) lp->laser);
+                       if (lp->stippledGC != NULL)
+                               XFreeGC(MI_DISPLAY(mi), lp->stippledGC);
+               }
+               (void) free((void *) lasers);
+               lasers = NULL;
+       }
+}
+
+void
+refresh_laser(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_laser */
diff --git a/xlockmore-4.14/modes/life.c b/xlockmore-4.14/modes/life.c
new file mode 100644 (file)
index 0000000..7e401a0
--- /dev/null
@@ -0,0 +1,2914 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* life --- Conway's game of Life */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)life.c       4.07 98/01/18 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ * Copyright (c) 1997 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 08-Dec-97: Paul Callahan's B2a/S2b34 rule added.  Described on the news
+ *            site for cellular-automata.  <ppc997@aber.ac.uk>
+ *            http://www.cs.jhu.edu/~callahan/lifepage.html
+ *            http://www.cs.jhu.edu/~callahan/hexrule.txt
+ *            B2a/S2b34: Birth of x if 2a,
+ *                       Survival of x if 2b, 3, or 4 neighbors
+ *                       Assume symmetry.
+ *                       (2a, 2b, 2c: 2o, 2m, 2p original notation)
+ *                  O O            O .            O .
+ *            2a:  . x .     2b:  . x O     2c:  . x .
+ *                  . .            . .            . O
+ *            Also Bob Andreen's rule (my own notation for consistency)
+ *            B2a3a4b/S2a2b4a (original notation: 234'B/22'4S)
+ *            <andreen@msmc.edu>
+ *                  O O            O O            O . 
+ *            3a:  . x O     3b:  . x .     3c:  . x O
+ *                  . .            . O            O .
+ * 
+ *                  O O            O O            O O 
+ *            4a:  . x O     4b:  . x O     4c:  . x .
+ *                  . O            O .            O O
+ *            Some other rules
+ *            B2a3b3c5/S12b2c3a4b4c6
+ *            B23a3c4b4c6/S12b2c3c4a56
+ *            B2a2c6/S13b
+ * 27-Oct-97: xpm and ras capability added.
+ * 04-Jun-97: Removed old algorithm, now use wator's.  I could not
+ *            understand it and had trouble adding more features.
+ *            New algorithm is more efficient iff there lots of blank areas
+ * 10-May-97: Compatible with xscreensaver
+ * 07-May-97: life neighbor option.  Still have to fix -neighbor 3
+ * 07-Jan-95: life now has a random soup pattern.
+ * 07-Dec-94: life now has new organisms.  They are now better centered.
+ *            Some of the nonperiodic forms were removed. New life forms
+ *            were taken from xlife (an AMAZING collection of life forms).
+ *            life's gliders now come from the edge of the screen except
+ *            when generated by a life form.
+ * 23-Nov-94: Bug fix for different iconified window sizes
+ * 21-Jul-94: Took out bzero & bcopy since memset & memcpy is more portable
+ * 10-Jun-94: Changed name of function 'kill', which is a libc function on
+ *            many systems from Victor Langeveld <vic@mbfys.kun.nl>
+ * Changes in original xlock
+ * 24-May-91: Added wraparound code from johnson@bugs.comm.mot.com.
+ *        Made old cells stay blue.
+ *        Made batchcount control the number of generations until restart.
+ * 29-Jul-90: support for multiple screens.
+ * 07-Feb-90: remove bogus semi-colon after #include line.
+ * 15-Dec-89: Fix for proper skipping of {White,Black}Pixel() in colors.
+ * 08-Oct-89: Moved seconds() to an extern.
+ * 20-Sep-89: Written, life algorithm courtesy of Jim Graham <flar@sun.com>
+ */
+
+/*-
+  Grid     Number of Neigbors
+  ----     ------------------
+  Square   4 or 8
+  Hexagon  6
+  Triangle 3, 9, or 12
+
+  Conway's Life: -neighbors 8 -rule S23/B3
+  Other things to try:
+    -neighbors 4 -rule S234/B2
+    -neighbors 6 -rule S23/B3
+    -neighbors 3 -rule S12/B23
+    -neighbors 6 -rule S2b34/B2a     <CALLAHAN>
+    -neighbors 6 -rule S2a2b4a/B2b3a4b  <ANDREEN>
+*/
+
+#ifdef STANDALONE
+#define PROGCLASS "Life"
+#define HACK_INIT init_life
+#define HACK_DRAW draw_life
+#define life_opts xlockmore_opts
+#define DEFAULTS "*delay: 750000 \n" \
+ "*count: 40 \n" \
+ "*cycles: 140 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 200 \n" \
+ "*bitmap: \n" \
+ "*neighbors: 0 \n" \
+ "*verbose: False \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+#include "iostuff.h"
+#include "automata.h"
+
+#ifdef MODE_life
+
+/*-
+ * neighbors of 0 does not randomize.  All inappropriate
+ * modes will be set at 8.  3, 6, 9, & 12 also available.
+ */
+#define DEF_NEIGHBORS  "0"      /* choose best value (8) */
+
+#if 1
+#define DEF_RULE  "G"          /* All rules with known gliders */
+#else
+#define DEF_RULE  "P"          /* All rules with known patterns */
+#define DEF_RULE  "S23/B3"     /* "B3/S23" */
+#define DEF_RULE  "S2b34/B2a"  /* CALLAHAN */
+#define DEF_RULE  "S2a2b4a/B2b3a4b"    /* ANDREEN */
+#endif
+
+#define DEF_CALLAHAN  "FALSE"
+#define DEF_ANDREEN  "FALSE"
+
+static int  neighbors;
+static char *rule;
+static char *lifefile;
+static Bool callahan;
+static Bool andreen;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".life.neighbors", XrmoptionSepArg, (caddr_t) NULL},
+       {"-rule", ".life.rule", XrmoptionSepArg, (caddr_t) NULL},
+       {"-lifefile", ".life.lifefile", XrmoptionSepArg, (caddr_t) NULL},
+       {"-callahan", ".life.callahan", XrmoptionNoArg, (caddr_t) "on"},
+       {"+callahan", ".life.callahan", XrmoptionNoArg, (caddr_t) "off"},
+       {"-andreen", ".life.andreen", XrmoptionNoArg, (caddr_t) "on"},
+       {"+andreen", ".life.andreen", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int},
+       {(caddr_t *) & rule, "rule", "Rule", DEF_RULE, t_String},
+       {(caddr_t *) & lifefile, "lifefile", "LifeFile", "", t_String},
+      {(caddr_t *) & callahan, "callahan", "Callahan", DEF_CALLAHAN, t_Bool},
+       {(caddr_t *) & andreen, "andreen", "Andreen", DEF_ANDREEN, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-neighbors num", "squares 4 or 8, hexagons 6, triangles 3, 9 or 12"},
+       {"-rule string", "S<survival_neighborhood>/B<birth_neighborhood> parameters                                                                                "},
+       {"-lifefile file", "life file"},
+       {"-/+callahan", "turn on/off Callahan's hex rule B2a/S2b34"},
+       {"-/+andreen", "turn on/off Andreen's hex rule B2a3a4b/S2a2m4a"}
+};
+
+ModeSpecOpt life_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   life_description =
+{"life", "init_life", "draw_life", "release_life",
+ "refresh_life", "change_life", NULL, &life_opts,
+ 750000, 40, 140, 0, 64, 1.0, "",
+ "Shows Conway's game of Life", 0, NULL};
+
+#endif
+
+/* aliases for vars defined in the bitmap file */
+#define CELL_WIDTH   image_width
+#define CELL_HEIGHT    image_height
+#define CELL_BITS    image_bits
+
+#include "life.xbm"
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+static char *image_name[] =
+{""};
+
+#define CELL_NAME image_name
+#define DEFAULT_XPM 0
+#endif
+
+static int  local_neighbors = 0;
+static int  neighbor_kind = 0;
+
+#define REDRAWSTEP 2000                /* How many cells to draw per cycle */
+#define MINGRIDSIZE 20
+#define MINSIZE 4
+#define MAXNEIGHBORS 12
+#define MAXGROUPS 3            /* Eventually this may be MAXNEIGHBORS - 3 */
+#define FIRSTGROUP 2           /* Need at least 2 to make a group */
+#define MAXCOUNTNEIGHBORS 9    /* This restriction is because of base 10 */
+#define NEIGHBORKINDS 6
+#define DEAD 0
+#define LIVE 1
+#define STATES 2
+
+typedef struct {
+       long        position;
+       unsigned short age;
+       unsigned char state;
+       unsigned char toggle;
+} cellstruct;
+
+/* Singly linked list */
+typedef struct _CellList {
+       cellstruct  info;
+       struct _CellList *previous, *next;
+} CellList;
+
+typedef struct {
+       int         survival, birth;
+       int         survival_group[MAXGROUPS];
+       int         birth_group[MAXGROUPS];
+} paramstruct;
+
+typedef struct {
+       Bool        painted;
+       paramstruct param;
+       int         pattern, patterned_rule;
+       int         pixelmode;
+       int         generation;
+       int         xs, ys, xb, yb;     /* cell size, grid border */
+       int         nrows, ncols, npositions;
+       int         width, height;
+       int         state;
+       int         redrawing, redrawpos;
+       int         ncells[STATES];
+       CellList   *last[STATES], *first[STATES];
+       CellList  **arr;
+       union {
+               XPoint      hexagon[6];
+               XPoint      triangle[2][3];
+       } shape;
+       XImage     *logo;
+       Colormap    cmap;
+       unsigned long black;
+       int         graphics_format;
+       GC          backGC;
+} lifestruct;
+
+static lifestruct *lifes = NULL;
+
+static paramstruct input_param;
+static Bool allPatterns = False, allGliders = False;
+static char *filePattern = NULL;
+
+static char plots[NEIGHBORKINDS] =
+{
+       3, 4, 6, 8, 9, 12       /* Neighborhoods */
+};
+
+static char maxgroups[NEIGHBORKINDS] =
+{0, 0, 3, 0, 0, 0};
+static char groupnumber[NEIGHBORKINDS][MAXGROUPS] =
+{
+       {0, 0, 0},              /* Triangular */
+       {0, 0, 0},              /* Future improvement */
+       {3, 3, 3},              /* Hexagonal */
+       {0, 0, 0},              /* Maxgroup will expand... */
+       {0, 0, 0},              /* Future improvement */
+       {0, 0, 0}               /* Future improvement */
+};
+
+static char style6[64] =
+{0, 0, 0, 0, 0, 1, 0, 0, 0, 2, 1, 1, 0, 1, 0, 0,
+ 0, 1, 2, 1, 1, 2, 1, 1, 0, 1, 1, 2, 0, 1, 0, 0,
+ 0, 0, 1, 0, 2, 1, 1, 0, 1, 1, 2, 1, 1, 2, 1, 0,
+ 0, 0, 1, 0, 1, 1, 2, 0, 0, 0, 1, 0, 0, 0, 0, 0};
+
+
+#define NUMPTS  64
+#define NUMFILEPTS  (2*NUMPTS)
+
+/*-
+ * Patterns have < NUMPTS pts (and should have a size of <= 32x32,
+ * the Glider Gun is an exception)
+ */
+static char patterns_8S23B3[][2 * NUMPTS + 1] =
+{
+       {                       /* GLIDER GUN */
+               6, -4,
+               5, -3, 6, -3,
+               -6, -2, -5, -2, 8, -2, 9, -2, 16, -2,
+               -7, -1, 8, -1, 9, -1, 10, -1, 16, -1, 17, -1,
+               -18, 0, -17, 0, -8, 0, 8, 0, 9, 1,
+               -17, 1, -8, 1, 5, 1, 6, 1,
+               -8, 2, 6, 2,
+               -7, 3,
+               -6, 4, -5, 4,
+               127
+       },
+       {                       /* SHOWER TUB (PART OF OSCILATORS) */
+               -3, -6, -2, -6, 2, -6, 3, -6,
+               -4, -5, -2, -5, 2, -5, 4, -5,
+               -4, -4, 4, -4,
+               -7, -3, -6, -3, -4, -3, -3, -3, 3, -3, 4, -3, 6, -3, 7, -3,
+               -7, -2, -6, -2, -4, -2, 0, -2, 4, -2, 6, -2, 7, -2,
+               -4, -1, -2, -1, 2, -1, 4, -1,
+               -4, 0, -2, 0, 2, 0, 4, 0,
+               -5, 1, -4, 1, -2, 1, 2, 1, 4, 1, 5, 1,
+               -4, 2, -1, 2, 0, 2, 1, 2, 4, 2,
+               -4, 3, 4, 3, 6, 3,
+               -3, 4, -2, 4, -1, 4, 5, 4, 6, 4,
+               -1, 5,
+               127
+       },
+       {                       /* P4 LARGE TOASTER */
+               -5, -3, -4, -3, -2, -3, 2, -3, 4, -3, 5, -3,
+               -5, -2, 5, -2,
+               -4, -1, -3, -1, 3, -1, 4, -1,
+       -7, 0, -6, 0, -5, 0, -2, 0, -1, 0, 0, 0, 1, 0, 2, 0, 5, 0, 6, 0, 7, 0,
+               -7, 1, -4, 1, 4, 1, 7, 1,
+               -6, 2, -5, 2, 5, 2, 6, 2,
+               127
+       },
+       {                       /* STARGATE REPEATER P3 */
+               0, -6,
+               -1, -5, 1, -5,
+               -2, -4, 0, -4, 2, -4,
+               -2, -3, 2, -3,
+               -4, -2, -3, -2, 0, -2, 3, -2, 4, -2,
+               -5, -1, 0, -1, 5, -1,
+               -6, 0, -4, 0, -2, 0, -1, 0, 1, 0, 2, 0, 4, 0, 6, 0,
+               -5, 1, 0, 1, 5, 1,
+               -4, 2, -3, 2, 0, 2, 3, 2, 4, 2,
+               -2, 3, 2, 3,
+               -2, 4, 0, 4, 2, 4,
+               -1, 5, 1, 5,
+               0, 6,
+               127
+       },
+       {                       /* OSCILLATOR 7 (P8) */
+               -4, -2, -3, -2, -2, -2, -1, -2, 4, -2, 5, -2, 6, -2, 7, -2,
+               -9, -1, -8, -1, 0, -1, 8, -1,
+               -9, 0, -8, 0, -5, 0, -4, 0, 0, 0, 3, 0, 4, 0, 8, 0,
+               -5, 1, -4, 1, -1, 1, 3, 1, 4, 1, 7, 1,
+               127
+       },
+       {                       /* P144 */
+               -14, -9, -13, -9, 12, -9, 13, -9,
+               -14, -8, -13, -8, 12, -8, 13, -8,
+               4, -7, 5, -7,
+               3, -6, 6, -6,
+               4, -5, 5, -5,
+               -1, -3, 0, -3, 1, -3,
+               -1, -2, 1, -2,
+               -1, -1, 0, -1, 1, -1,
+               -1, 0, 0, 0,
+               -2, 1, -1, 1, 0, 1,
+               -2, 2, 0, 2,
+               -2, 3, -1, 3, 0, 3,
+               -6, 5, -5, 5,
+               -7, 6, -4, 6,
+               -6, 7, -5, 7,
+               -14, 8, -13, 8, 12, 8, 13, 8,
+               -14, 9, -13, 9, 12, 9, 13, 9,
+               127
+       },
+       {                       /* FIGURE EIGHT */
+               -3, -3, -2, -3, -1, -3,
+               -3, -2, -2, -2, -1, -2,
+               -3, -1, -2, -1, -1, -1,
+               0, 0, 1, 0, 2, 0,
+               0, 1, 1, 1, 2, 1,
+               0, 2, 1, 2, 2, 2,
+               127
+       },
+       {                       /* PULSAR 18-22-20 */
+               0, -4, 1, -4, 2, -4,
+               -1, -2, 4, -2,
+               -2, -1, 0, -1, 4, -1,
+               -4, 0, -3, 0, -2, 0, 1, 0, 4, 0,
+               2, 1,
+               0, 2, 1, 2,
+               0, 3,
+               0, 4,
+               127
+       },
+       {                       /* PULSAR 48-56-72 */
+               -2, -1, -1, -1, 0, -1, 1, -1, 2, -1,
+               -2, 0, 2, 0,
+               127
+       },
+       {                       /* BARBER POLE P2 */
+               -6, -6, -5, -6,
+               -6, -5, -4, -5,
+               -4, -3, -2, -3,
+               -2, -1, 0, -1,
+               0, 1, 2, 1,
+               2, 3, 4, 3,
+               5, 4,
+               4, 5, 5, 5,
+               127
+       },
+       {                       /* ACHIM P5 */
+               -6, -6, -5, -6,
+               -6, -5,
+               -4, -4,
+               -4, -3, -2, -3,
+               -2, -1, 0, -1,
+               0, 1, 2, 1,
+               2, 3, 3, 3,
+               5, 4,
+               4, 5, 5, 5,
+               127
+       },
+       {                       /* HERTZ P4 */
+               -2, -5, -1, -5,
+               -2, -4, -1, -4,
+               -7, -2, -6, -2, -2, -2, -1, -2, 0, -2, 1, -2, 5, -2, 6, -2,
+               -7, -1, -5, -1, -3, -1, 2, -1, 4, -1, 6, -1,
+               -5, 0, -3, 0, -2, 0, 2, 0, 4, 0,
+               -6, 1, -5, 1, -3, 1, 2, 1, 4, 1, 5, 1,
+               -2, 2, -1, 2, 0, 2, 1, 2,
+               -2, 4, -1, 4,
+               -2, 5, -1, 5,
+               127
+       },
+       {                       /* PUMP (TUMBLER, P14) */
+               -2, -3, -1, -3, 1, -3, 2, -3,
+               -2, -2, -1, -2, 1, -2, 2, -2,
+               -1, -1, 1, -1,
+               -3, 0, -1, 0, 1, 0, 3, 0,
+               -3, 1, -1, 1, 1, 1, 3, 1,
+               -3, 2, -2, 2, 2, 2, 3, 2,
+               127
+       },
+       {                       /* SMILEY (P8) */
+               -3, -3, -2, -3, -1, -3, 1, -3, 2, -3, 3, -3,
+               -2, -2, 0, -2, 2, -2,
+               -2, 0, 2, 0,
+               -3, 2, -1, 2, 1, 2, 3, 2,
+               -1, 3, 1, 3,
+               127
+       },
+       {                       /* PULSE1 P4 */
+               0, -3, 1, -3,
+               -2, -2, 0, -2,
+               -3, -1, 3, -1,
+               -2, 0, 2, 0, 3, 0,
+               0, 2, 2, 2,
+               1, 3,
+               127
+       },
+       {                       /* SHINING FLOWER P5 */
+               -1, -4, 0, -4,
+               -2, -3, 1, -3,
+               -3, -2, 2, -2,
+               -4, -1, 3, -1,
+               -4, 0, 3, 0,
+               -3, 1, 2, 1,
+               -2, 2, 1, 2,
+               -1, 3, 0, 3,
+               127
+       },
+       {                       /* PULSE2 P6 */
+               0, -4, 1, -4,
+               -4, -3, -3, -3, -1, -3,
+               -4, -2, -3, -2, 0, -2, 3, -2,
+               1, -1, 3, -1,
+               2, 0,
+               1, 2, 2, 2,
+               1, 3, 2, 3,
+               127
+       },
+       {                       /* PINWHEEL P4 */
+               -2, -6, -1, -6,
+               -2, -5, -1, -5,
+               -2, -3, -1, -3, 0, -3, 1, -3,
+               -3, -2, -1, -2, 2, -2, 4, -2, 5, -2,
+               -3, -1, 1, -1, 2, -1, 4, -1, 5, -1,
+               -6, 0, -5, 0, -3, 0, 0, 0, 2, 0,
+               -6, 1, -5, 1, -3, 1, 2, 1,
+               -2, 2, -1, 2, 0, 2, 1, 2,
+               0, 4, 1, 4,
+               0, 5, 1, 5,
+               127
+       },
+       {                       /* CLOCK P4 */
+               -2, -6, -1, -6,
+               -2, -5, -1, -5,
+               -2, -3, -1, -3, 0, -3, 1, -3,
+               -6, -2, -5, -2, -3, -2, 0, -2, 2, -2,
+               -6, -1, -5, -1, -3, -1, -1, -1, 2, -1,
+               -3, 0, -1, 0, 2, 0, 4, 0, 5, 0,
+               -3, 1, 2, 1, 4, 1, 5, 1,
+               -2, 2, -1, 2, 0, 2, 1, 2,
+               0, 4, 1, 4,
+               0, 5, 1, 5,
+               127
+       },
+       {                       /* CROSS P3 */
+               -2, -4, -1, -4, 0, -4, 1, -4,
+               -2, -3, 1, -3,
+               -4, -2, -3, -2, -2, -2, 1, -2, 2, -2, 3, -2,
+               -4, -1, 3, -1,
+               -4, 0, 3, 0,
+               -4, 1, -3, 1, -2, 1, 1, 1, 2, 1, 3, 1,
+               -2, 2, 1, 2,
+               -2, 3, -1, 3, 0, 3, 1, 3,
+               127
+       },
+       {                       /* BIG CROSS P3 */
+               0, -5,
+               -1, -4, 0, -4, 1, -4,
+               -3, -3, -2, -3, -1, -3, 1, -3, 2, -3, 3, -3,
+               -3, -2, 3, -2,
+               -4, -1, -3, -1, 3, -1, 4, -1,
+               -5, 0, -4, 0, 4, 0, 5, 0,
+               -4, 1, -3, 1, 3, 1, 4, 1,
+               -3, 2, 3, 2,
+               -3, 3, -2, 3, -1, 3, 1, 3, 2, 3, 3, 3,
+               -1, 4, 0, 4, 1, 4,
+               0, 5,
+               127
+       },
+       {                       /* P4 DIAG SYM */
+               -2, -4, 0, -4,
+               -2, -3, 0, -3, 2, -3, 3, -3,
+               -4, -2, -3, -2, 2, -2,
+               0, -1, 1, -1, 2, -1,
+               -4, 0, -3, 0, -1, 0, 2, 0,
+               -1, 1, 2, 1,
+               -3, 2, -2, 2, -1, 2, 0, 2, 1, 2,
+               -3, 3,
+               127
+       },
+       {                       /* P4 ASYM */
+               -4, -4, -2, -4,
+               -4, -3, -1, -3,
+               -1, -2,
+               -2, -1, -1, -1, 0, -1, 3, -1, 4, -1, 5, -1,
+               -5, 0, -4, 0, -3, 0, 0, 0, 1, 0, 2, 0,
+               1, 1,
+               1, 2, 4, 2,
+               2, 3, 4, 3,
+               127
+       },
+       {                       /* P4 ASYM 2 */
+               -3, -3, -1, -3, 2, -3, 4, -3, 5, -3, 6, -3,
+               -4, -2, -1, -2, 1, -2, 3, -2, 5, -2,
+               -4, -1,
+               3, 0,
+               -6, 1, -4, 1, -2, 1, 0, 1, 3, 1,
+               -7, 2, -6, 2, -5, 2, -3, 2, 0, 2, 2, 2,
+               127
+       },
+       {                       /* P8 ASYM */
+               -3, -4, -2, -4,
+               -4, -3,
+               -3, -2, 1, -2,
+               -3, -1, 1, -1, 2, -1,
+               -1, 0, 1, 0,
+               -2, 1, -1, 1, 3, 1,
+               -1, 2, 3, 2,
+               4, 3,
+               2, 4, 3, 4,
+               127
+       },
+       {                       /* P4 SYM */
+               -6, -2, -5, -2, 4, -2, 5, -2,
+               -6, -1, -5, -1, -3, -1, -2, -1, 1, -1, 2, -1, 4, -1, 5, -1,
+               -5, 0, -2, 0, 1, 0, 4, 0,
+               -5, 1, -4, 1, -2, 1, -1, 1, 0, 1, 1, 1, 3, 1, 4, 1,
+               127
+       },
+       {                       /* QUESTION P3 NOSYM */
+               -2, -4, -1, -4, 0, -4,
+               2, -3,
+               -3, -2, 2, -2,
+               1, -1,
+               -2, 0, -1, 0,
+               -2, 1,
+               -2, 2,
+               -2, 3,
+               127
+       },
+       {                       /* WHIRLY THING P12 */
+               -5, -6,
+               -5, -5, -4, -5, -3, -5, 5, -5, 6, -5,
+               -2, -4, 5, -4,
+               -3, -3, -2, -3, 3, -3, 5, -3,
+               3, -2, 4, -2,
+               0, -1, 1, -1,
+               0, 0, 1, 0,
+               0, 1, 1, 1,
+               -4, 2, -3, 2,
+               -5, 3, -3, 3, 2, 3, 3, 3,
+               -5, 4, 2, 4,
+               -6, 5, -5, 5, 3, 5, 4, 5, 5, 5,
+               5, 6,
+               127
+       },
+       {                       /* PENTADECATHOLON P15 */
+            -5, 0, -4, 0, -3, 0, -2, 0, -1, 0, 0, 0, 1, 0, 2, 0, 3, 0, 4, 0,
+               127
+       },
+       {                       /* BALLOON P5 */
+               -1, -3, 0, -3,
+               -3, -2, 2, -2,
+               -3, -1, 2, -1,
+               -3, 0, 2, 0,
+               -2, 1, 1, 1,
+               -4, 2, -2, 2, 1, 2, 3, 2,
+               -4, 3, -3, 3, 2, 3, 3, 3,
+               127
+       },
+       {                       /* FENCEPOST P12 */
+               -11, -3, -9, -3, -7, -3,
+        -11, -2, -9, -2, -7, -2, 5, -2, 6, -2, 7, -2, 9, -2, 10, -2, 11, -2,
+               -11, -1, -7, -1, -3, -1, 1, -1, 8, -1,
+         -10, 0, -8, 0, -3, 0, -2, 0, -1, 0, 1, 0, 5, 0, 6, 0, 10, 0, 11, 0,
+               -11, 1, -7, 1, -3, 1, 1, 1, 8, 1,
+               -11, 2, -9, 2, -7, 2, 5, 2, 6, 2, 7, 2, 9, 2, 10, 2, 11, 2,
+               -11, 3, -9, 3, -7, 3,
+               127
+       },
+       {                       /* PISTON (SHUTTLE) P30 */
+               1, -3, 2, -3,
+               0, -2,
+               -10, -1, -1, -1,
+               -11, 0, -10, 0, -1, 0, 9, 0, 10, 0,
+               -1, 1, 9, 1,
+               0, 2,
+               1, 3, 2, 3,
+               127
+       },
+       {                       /* P30 */
+               -8, -5, 7, -5,
+               -9, -4, -7, -4, 1, -4, 2, -4, 6, -4, 8, -4,
+               -8, -3, 0, -3, 1, -3, 2, -3, 7, -3,
+               1, -2, 2, -2,
+               1, 2, 2, 2,
+               -8, 3, 0, 3, 1, 3, 2, 3, 7, 3,
+               -9, 4, -7, 4, 1, 4, 2, 4, 6, 4, 8, 4,
+               -8, 5, 7, 5,
+               127
+       },
+       {                       /* PISTON2 P46 */
+               -3, -5,
+               -14, -4, -13, -4, -4, -4, -3, -4, 13, -4, 14, -4,
+               -14, -3, -13, -3, -5, -3, -4, -3, 13, -3, 14, -3,
+               -4, -2, -3, -2, 0, -2, 1, -2,
+               -4, 2, -3, 2, 0, 2, 1, 2,
+               -14, 3, -13, 3, -5, 3, -4, 3, 13, 3, 14, 3,
+               -14, 4, -13, 4, -4, 4, -3, 4, 13, 4, 14, 4,
+               -3, 5,
+               127
+       },
+       {                       /* GEARS (gear, flywheel, blinker) P2 */
+               -1, -4,
+               -1, -3, 1, -3,
+               -3, -2,
+               2, -1, 3, -1,
+               -4, 0, -3, 0,
+               2, 1,
+               -2, 2, 0, 2,
+               0, 3,
+
+               5, 3,
+               3, 4, 4, 4,
+               5, 5, 6, 5,
+               4, 6,
+
+               8, 0,
+               8, 1,
+               8, 2,
+               127
+       },
+       {                       /* TURBINE8, KOK'S GALAXY */
+               -4, -4, -3, -4, -2, -4, -1, -4, 0, -4, 1, -4, 3, -4, 4, -4,
+               -4, -3, -3, -3, -2, -3, -1, -3, 0, -3, 1, -3, 3, -3, 4, -3,
+               3, -2, 4, -2,
+               -4, -1, -3, -1, 3, -1, 4, -1,
+               -4, 0, -3, 0, 3, 0, 4, 0,
+               -4, 1, -3, 1, 3, 1, 4, 1,
+               -4, 2, -3, 2,
+               -4, 3, -3, 3, -1, 3, 0, 3, 1, 3, 2, 3, 3, 3, 4, 3,
+               -4, 4, -3, 4, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4, 4, 4,
+               127
+       },
+       {                       /* P16 */
+               -3, -6, 1, -6, 2, -6,
+               -3, -5, 0, -5, 3, -5,
+               3, -4,
+               -5, -3, -4, -3, 1, -3, 2, -3, 5, -3, 6, -3,
+               -6, -2, -3, -2,
+               -6, -1, -3, -1,
+               -5, 0, 5, 0,
+               3, 1, 6, 1,
+               3, 2, 6, 2,
+               -6, 3, -5, 3, -2, 3, -1, 3, 4, 3, 5, 3,
+               -3, 4,
+               -3, 5, 0, 5, 3, 5,
+               -2, 6, -1, 6, 3, 6,
+               127
+       },
+       {                       /* P28 (FLUTTER) */
+               -9, -7, -7, -7, 7, -7, 9, -7,
+               -6, -6, 6, -6,
+               -10, -5, -7, -5, 7, -5, 10, -5,
+               -11, -4, -9, -4, -7, -4, 7, -4, 9, -4, 11, -4,
+               -11, -3, -8, -3, 8, -3, 11, -3,
+               -10, -2, -9, -2, -4, -2, -3, -2, -2, -2,
+               2, -2, 3, -2, 4, -2, 9, -2, 10, -2,
+               -3, -1, 3, -1,
+               -10, 1, -9, 1, 9, 1, 10, 1,
+               -11, 2, -8, 2, 8, 2, 11, 2,
+               -11, 3, -9, 3, -6, 3, 6, 3, 9, 3, 11, 3,
+               -10, 4, 10, 4,
+               -9, 5, -8, 5, -6, 5, 6, 5, 8, 5, 9, 5,
+               -7, 6, 7, 6,
+               127
+       },
+       {                       /* P54 (PISTON3) */
+               -14, -8, -13, -8, 13, -8, 14, -8,
+               -13, -7, 13, -7,
+               -13, -6, -11, -6, 11, -6, 13, -6,
+               -12, -5, -11, -5, -1, -5, 11, -5, 12, -5,
+               0, -4,
+               -6, -3, -5, -3, 1, -3,
+               -6, -2, -5, -2, -2, -2, 0, -2,
+               -1, -1,
+               -1, 1,
+               -6, 2, -5, 2, -2, 2, 0, 2,
+               -6, 3, -5, 3, 1, 3,
+               0, 4,
+               -12, 5, -11, 5, -1, 5, 11, 5, 12, 5,
+               -13, 6, -11, 6, 11, 6, 13, 6,
+               -13, 7, 13, 7,
+               -14, 8, -13, 8, 13, 8, 14, 8,
+               127
+       },
+       {                       /* P88 PI OSCILLATOR (OSC88) */
+               6, -12,
+               4, -11, 5, -11, 6, -11,
+               3, -10,
+               3, -9, 4, -9,
+               -13, -8, -12, -8, 8, -8, 9, -8,
+               -12, -7, 8, -7,
+               -12, -6, -10, -6, 6, -6, 8, -6,
+               -11, -5, -10, -5, 6, -5, 7, -5,
+               0, -3, 1, -3, 2, -3,
+               0, -2, 2, -2,
+               0, -1, 2, -1,
+               -7, 5, -6, 5, 10, 5, 11, 5,
+               -8, 6, -6, 6, 10, 6, 12, 6,
+               -8, 7, 12, 7,
+               -9, 8, -8, 8, 12, 8, 13, 8,
+               -4, 9, -3, 9,
+               -3, 10,
+               -6, 11, -5, 11, -4, 11,
+               -6, 12,
+               127
+       },
+       {                       /* SWITCH ENGINE */
+               -12, -3, -10, -3,
+               -13, -2,
+               -12, -1, -9, -1,
+               -10, 0, -9, 0, -8, 0,
+               13, 2, 14, 2,
+               13, 3,
+               127
+       },
+       {                       /* PUFFER TRAIN */
+               1, -9,
+               2, -8,
+               -2, -7, 2, -7,
+               -1, -6, 0, -6, 1, -6, 2, -6,
+               -2, -2,
+               -1, -1, 0, -1,
+               0, 0,
+               0, 1,
+               -1, 2,
+               1, 5,
+               2, 6,
+               -2, 7, 2, 7,
+               -1, 8, 0, 8, 1, 8, 2, 8,
+               127
+       },
+       {                       /* SCHOOL OF FISH (ESCORT) */
+               3, -8,
+               4, -7,
+               -2, -6, 4, -6,
+               -1, -5, 0, -5, 1, -5, 2, -5, 3, -5, 4, -5,
+               -5, -1, -4, -1, -3, -1, -2, -1, -1, -1, 0, -1,
+               1, -1, 2, -1, 3, -1, 4, -1, 5, -1, 6, -1,
+               -6, 0, 6, 0,
+               6, 1,
+               5, 2,
+               3, 4,
+               4, 5,
+               -2, 6, 4, 6,
+               -1, 7, 0, 7, 1, 7, 2, 7, 3, 7, 4, 7,
+
+               127
+       },
+       {                       /* DART SPEED 1/3 */
+               3, -7,
+               2, -6, 4, -6,
+               1, -5, 2, -5,
+               4, -4,
+               0, -3, 4, -3,
+               -3, -2, 0, -2,
+               -4, -1, -2, -1, 1, -1, 2, -1, 3, -1, 4, -1,
+               -5, 0, -2, 0,
+               -4, 1, -2, 1, 1, 1, 2, 1, 3, 1, 4, 1,
+               -3, 2, 0, 2,
+               0, 3, 4, 3,
+               4, 4,
+               1, 5, 2, 5,
+               2, 6, 4, 6,
+               3, 7,
+               127
+       },
+       {                       /* PERIOD 4 SPEED 1/2 */
+               -3, -5,
+               -4, -4, -3, -4, -2, -4, -1, -4, 0, -4,
+               -5, -3, -4, -3, 0, -3, 1, -3, 3, -3,
+               -4, -2, 4, -2,
+               -3, -1, -2, -1, 1, -1, 3, -1,
+               -3, 1, -2, 1, 1, 1, 3, 1,
+               -4, 2, 4, 2,
+               -5, 3, -4, 3, 0, 3, 1, 3, 3, 3,
+               -4, 4, -3, 4, -2, 4, -1, 4, 0, 4,
+               -3, 5,
+               127
+       },
+       {                       /* ANOTHER PERIOD 4 SPEED 1/2 */
+               -4, -7, -3, -7, -1, -7, 0, -7, 1, -7, 2, -7, 3, -7, 4, -7,
+               -5, -6, -4, -6, -3, -6, -2, -6, 5, -6,
+               -6, -5, -5, -5,
+               -5, -4, 5, -4,
+               -4, -3, -3, -3, -2, -3, 0, -3,
+               -2, -2,
+               -2, -1,
+               -1, 0,
+               -2, 1,
+               -2, 2,
+               -4, 3, -3, 3, -2, 3, 0, 3,
+               -5, 4, 5, 4,
+               -6, 5, -5, 5,
+               -5, 6, -4, 6, -3, 6, -2, 6, 5, 6,
+               -4, 7, -3, 7, -1, 7, 0, 7, 1, 7, 2, 7, 3, 7, 4, 7,
+               127
+       },
+       {                       /* SMALLEST KNOWN PERIOD 3 SPACESHIP SPEED 1/3 */
+               0, -8,
+               -1, -7, 1, -7,
+               -1, -6, 1, -6,
+               -1, -5,
+               -2, -3, -1, -3,
+               -1, -2, 1, -2,
+               -2, -1, 0, -1,
+               -2, 0, -1, 0, 0, 0,
+               -1, 2, 1, 2,
+               -1, 3, 0, 3,
+               0, 4,
+               0, 5, 2, 5,
+               0, 6, 2, 6,
+               1, 7,
+               127
+       },
+       {                       /* TURTLE SPEED 1/3 */
+               -4, -5, -3, -5, -2, -5, 6, -5,
+               -4, -4, -3, -4, 0, -4, 2, -4, 3, -4, 5, -4, 6, -4,
+               -2, -3, -1, -3, 0, -3, 5, -3,
+               -4, -2, -1, -2, 1, -2, 5, -2,
+               -5, -1, 0, -1, 5, -1,
+               -5, 0, 0, 0, 5, 0,
+               -4, 1, -1, 1, 1, 1, 5, 1,
+               -2, 2, -1, 2, 0, 2, 5, 2,
+               -4, 3, -3, 3, 0, 3, 2, 3, 3, 3, 5, 3, 6, 3,
+               -4, 4, -3, 4, -2, 4, 6, 4,
+               127
+       },
+       {                       /* SMALLEST KNOWN PERIOD 5 SPEED 2/5 */
+               1, -7, 3, -7,
+               -2, -6, 3, -6,
+               -3, -5, -2, -5, -1, -5, 4, -5,
+               -4, -4, -2, -4,
+               -5, -3, -4, -3, -1, -3, 0, -3, 5, -3,
+               -4, -2, -3, -2, 0, -2, 1, -2, 2, -2, 3, -2, 4, -2,
+               -4, 2, -3, 2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 2,
+               -5, 3, -4, 3, -1, 3, 0, 3, 5, 3,
+               -4, 4, -2, 4,
+               -3, 5, -2, 5, -1, 5, 4, 5,
+               -2, 6, 3, 6,
+               1, 7, 3, 7,
+               127
+       },
+       {                       /* SYM PUFFER */
+               1, -4, 2, -4, 3, -4, 4, -4,
+               0, -3, 4, -3,
+               4, -2,
+               -4, -1, -3, -1, 0, -1, 3, -1,
+               -4, 0, -3, 0, -2, 0,
+               -4, 1, -3, 1, 0, 1, 3, 1,
+               4, 2,
+               0, 3, 4, 3,
+               1, 4, 2, 4, 3, 4, 4, 4,
+               127
+       },
+       {                       /* RAKE P20 BACKWARDS */
+               0, -10, 1, -10, 10, -10,
+               -1, -9, 0, -9, 1, -9, 2, -9, 11, -9,
+               -1, -8, 0, -8, 2, -8, 3, -8, 7, -8, 11, -8,
+               1, -7, 2, -7, 8, -7, 9, -7, 10, -7, 11, -7,
+               6, -3, 7, -3,
+               5, -2, 6, -2, 8, -2, 9, -2,
+               6, -1, 9, -1,
+               6, 0, 9, 0,
+               7, 1, 8, 1,
+               10, 4,
+               11, 5,
+               -8, 6, 7, 6, 11, 6,
+               -7, 7, 8, 7, 9, 7, 10, 7, 11, 7,
+               -11, 8, -7, 8,
+               -10, 9, -9, 9, -8, 9, -7, 9,
+               127
+       },
+       {                       /* RAKE P20 FORWARDS */
+               0, -10, 1, -10, 10, -10,
+               -1, -9, 0, -9, 1, -9, 2, -9, 11, -9,
+               -1, -8, 0, -8, 2, -8, 3, -8, 7, -8, 11, -8,
+               1, -7, 2, -7, 8, -7, 9, -7, 10, -7, 11, -7,
+               6, -3, 7, -3,
+               5, -2, 6, -2, 8, -2, 9, -2,
+               6, -1, 9, -1,
+               6, 0, 9, 0,
+               7, 1, 8, 1,
+               10, 4,
+               11, 5,
+               7, 6, 11, 6,
+               -9, 7, -8, 7, -7, 7, -6, 7, 8, 7, 9, 7, 10, 7, 11, 7,
+               -10, 8, -6, 8,
+               -6, 9,
+               -7, 10,
+               127
+       },
+       {                       /* RAKE P24 BACKWARDS */
+               -5, -10,
+               -4, -9,
+               -10, -8, -4, -8,
+               -9, -7, -8, -7, -7, -7, -6, -7, -5, -7, -4, -7,
+               6, -6, 7, -6,
+               5, -5, 6, -5, 7, -5, 8, -5,
+               5, -4, 6, -4, 8, -4, 9, -4,
+               7, -3, 8, -3,
+               0, -2, 2, -2,
+               -1, -1, 2, -1, 3, -1,
+               0, 0, 2, 0,
+               7, 1, 8, 1,
+               5, 2, 6, 2, 8, 2, 9, 2,
+               5, 3, 6, 3, 7, 3, 8, 3,
+               6, 4, 7, 4,
+               -5, 6, -4, 6,
+               -9, 7, -8, 7, -7, 7, -6, 7, -4, 7, -3, 7,
+               -9, 8, -8, 8, -7, 8, -6, 8, -5, 8, -4, 8,
+               -8, 9, -7, 9, -6, 9, -5, 9,
+               127
+       },
+       {                       /* BIG GLIDER 1 */
+               -4, -7, -3, -7,
+               -4, -6, -2, -6,
+               -4, -5,
+               -7, -4, -6, -4, -4, -4,
+               -7, -3, -2, -3,
+               -7, -2, -5, -2, -4, -2, 3, -2, 4, -2, 5, -2,
+               -2, -1, -1, -1, 0, -1, 5, -1, 6, -1,
+               -1, 0, 0, 0, 1, 0, 3, 0, 5, 0,
+               6, 1,
+               -1, 2, 1, 2,
+               -2, 3, -1, 3, 1, 3,
+               -1, 4,
+               -3, 5, -2, 5, 0, 5,
+               0, 6,
+               -2, 7, -1, 7,
+               127
+       },
+       {                       /* BIG GLIDER 2 */
+               0, -9, 1, -9,
+               0, -8, 2, -8,
+               0, -7,
+               1, -6, 2, -6, 3, -6,
+               1, -5, 3, -5, 4, -5, 5, -5,
+               1, -4, 4, -4, 5, -4,
+               3, -3, 5, -3, 7, -3, 8, -3,
+               2, -2, 3, -2, 5, -2, 7, -2,
+               1, -1, 2, -1, 7, -1,
+               -9, 0, -8, 0, -7, 0,
+               -9, 1, -6, 1, -5, 1, -4, 1, -1, 1, 3, 1, 4, 1,
+               -8, 2, -6, 2, -2, 2, -1, 2,
+               -6, 3, -5, 3, -3, 3, -2, 3, 1, 3,
+               -5, 4, -4, 4, 1, 4,
+               -5, 5, -4, 5, -3, 5, -2, 5,
+               -3, 7, -2, 7, -1, 7,
+               -3, 8,
+               127
+       },
+       {                       /* BIG GLIDER 3 */
+               -1, -8,
+               -2, -7, -1, -7,
+               -2, -6, 0, -6,
+               0, -4, 2, -4,
+               -2, -3, 0, -3, 2, -3,
+               -7, -2, -3, -2, -2, -2, 0, -2, 2, -2, 3, -2,
+               -8, -1, -7, -1, -6, -1, -5, -1, -2, -1, 4, -1,
+               -8, 0, -5, 0, -4, 0, -2, 0, -1, 0, 3, 0, 4, 0,
+               -6, 1, -5, 1, 0, 1,
+               -4, 2, -3, 2, 1, 2,
+               -3, 3, -2, 3, -1, 3, 2, 3, 4, 3, 5, 3, 6, 3, 7, 3,
+               -3, 4, 0, 4, 3, 4, 4, 4, 5, 4,
+               -1, 5, 0, 5, 1, 5,
+               1, 6, 2, 6, 3, 6,
+               2, 7, 3, 7,
+               127
+       },
+       {                       /* Small c/4 diagonal sparker */
+               1, -11,
+               0, -10, 1, -10,
+               -2, -8, -1, -8, 0, -8,
+               -2, -7, -1, -7, 0, -7,
+               -3, -4, -2, -4, -1, -4,
+               -3, -3, -2, -3,
+               -4, -2, -1, -2, 0, -2, 1, -2, 3, -2,
+               -4, -1, -3, -1, -1, -1, 3, -1,
+               -4, 0, -3, 0, -1, 0, 0, 0, 2, 0, 3, 0,
+               -4, 1, -3, 1, -2, 1,
+               -4, 2, -3, 2,
+               -4, 3,
+               -4, 4, -3, 4,
+               -3, 5, -1, 5,
+               1, 6,
+               -1, 7, 2, 7,
+               0, 8, 3, 8,
+               0, 9,
+               3, 10,
+               1, 11, 2, 11, 3, 11,
+               127
+       },
+       {                       /* PI HEPTOMINO (], NEAR SHIP) */
+               -2, -1, -1, -1, 0, -1,
+               1, 0,
+               -2, 1, -1, 1, 0, 1,
+               127
+       },
+       {                       /* R PENTOMINO */
+               0, -1, 1, -1,
+               -1, 0, 0, 0,
+               0, 1,
+               127
+       },
+       {                       /* BUNNIES */
+               -4, -2, 2, -2,
+               -2, -1, 2, -1,
+               -2, 0, 1, 0, 3, 0,
+               -3, 1, -1, 1,
+               127
+       }
+};
+
+
+/*-
+ * This uses Callahan's "/" notation
+ *    ABC                   A B C
+ *    DEF          ->      D E F
+ *    GHI                 G H I
+ */
+static char patterns_6S2b34B2a[][2 * NUMPTS + 1] =
+{
+#if 0
+       {                       /* GLIDER (P4) */
+               0, -2,
+               1, -1,
+               -2, 0, 1, 0,
+               1, 1,
+               1, 2,
+               127
+       },
+#endif
+       {                       /* 3 OSCILLATOR GLIDER GUN (P42) */
+               5, -6, 6, -6,
+               6, -5, 7, -5, 9, -5,
+               6, -4, 8, -4, 9, -4,
+               7, -3, 8, -3, 10, -3, 11, -3,
+               8, -2, 10, -2,
+               8, -1, 10, -1, 11, -1,
+               8, 0, 9, 0, 10, 0, 12, 0,
+               10, 1,
+
+               -10, -5,
+               -11, -4, -10, -4, -8, -4,
+               -12, -3, -11, -3, -9, -3, -8, -3, -7, -3,
+               -10, -2, -8, -2, -6, -2,
+               -10, -1, -9, -1, -7, -1, -6, -1, -5, -1, -4, -1,
+               -10, 0, -8, 0, -7, 0, -5, 0,
+
+               0, -1, 1, -1,
+               1, 0, 2, 0, 3, 0,
+               1, 1, 3, 1,
+               0, 2, 1, 2, 2, 2, 3, 2,
+               0, 3, 4, 3,
+               1, 4, 2, 4, 3, 4, 4, 4, 5, 4,
+               3, 5,
+               3, 6,
+               127
+       },
+       {                       /* ANOTHER GUN (P20) */
+               -2, -7, -1, -7,
+               -2, -6,
+
+               -8, -2,
+               -9, -1, -8, -1, -7, -1, -6, -1, -5, -1,
+               -8, 0, -6, 0, -5, 0,
+               -7, 1, -6, 1,
+               -8, 2, -7, 2,
+               -10, 3, -9, 3, -8, 3,
+               -8, 4,
+               -9, 5, -8, 5, -7, 5,
+               -6, 6,
+
+               4, 0,
+               3, 1, 4, 1, 5, 1, 10, 1,
+               3, 2, 4, 2, 6, 2, 7, 2, 10, 2,
+               5, 3, 6, 3, 8, 3, 9, 3, 10, 3, 11, 3,
+               7, 4, 10, 4, 12, 4,
+               11, 5,
+               127
+       },
+       {                       /* SHIP (P48) */
+               -3, -2, -1, -2,
+               -2, -1, -1, -1,
+               -2, 0, -1, 0, 0, 0, 2, 0,
+               -1, 1, 0, 1, 3, 1,
+               0, 2,
+               127
+       },
+       {                       /* SHIP (P15) */
+               -3, -5, -1, -5,
+               -2, -4, -1, -4, 0, -4,
+               -4, -3, -3, -3, -2, -3, 0, -3,
+               -2, -2, 0, -2,
+               -1, -1, 0, -1,
+               0, 1, 1, 1,
+               0, 2, 2, 2,
+               -1, 3, 0, 3, 1, 3, 3, 3,
+               2, 4, 3, 4, 4, 4,
+               2, 5, 4, 5,
+               127
+       },
+       {                       /* SHIP BY A COLLISION OF 3 GLIDERS (P15) */
+               7, -4,
+               8, -3,
+               8, -2, 10, -2,
+               -11, -1, -10, -1, 1, -1, 2, -1, 3, -1, 4, -1, 9, -1, 11, -1,
+               -9, 0, 1, 0, 10, 0,
+               -8, 1,
+               -7, 2, 5, 2,
+               -9, 3,
+               127
+       },
+       {                       /* STALK (P8) */
+               -2, -4,
+               -3, -3, -2, -3,
+               -3, -2, -1, -2, 0, -2,
+               -3, -1, -2, -1, -1, -1, 1, -1,
+               0, 0, 1, 0,
+               0, 1, 2, 1,
+               0, 2, 1, 2, 2, 2,
+               2, 3, 3, 3, 4, 3,
+               127
+       },
+       {                       /* STALK BY A COLLISION OF 3 GLIDERS */
+               -8, -9,
+               -5, -8,
+               -5, -7,
+               -5, -6,
+               -6, -5, -5, -5,
+               -3, 1,
+               -4, 2, -2, 2,
+               -3, 3, -1, 3,
+               -1, 4,
+               0, 5, 5, 5,
+               5, 6,
+               5, 7, 8, 7,
+               5, 8,
+               6, 9,
+               127
+       },
+       {                       /* STALK BY A COLLISION OF 2 GLIDERS AND EATER */
+               3, -6,
+               3, -5,
+               -5, -4, 4, -4, 7, -4,
+               -4, -3, -3, -3, 5, -3,
+               6, -2,
+               -7, 1, -6, 1,
+               -5, 2,
+               -4, 3,
+               -3, 4,
+               -5, 5,
+               127
+       },
+       {                       /* OSCILLATOR (P42) */
+               -2, -3, -1, -3,
+               -2, -2, 0, -2,
+               -3, -1, -2, -1, -1, -1, 0, -1,
+               -3, 0, 1, 0,
+               -2, 1, -1, 1, 0, 1, 1, 1, 2, 1,
+               0, 2,
+               0, 3,
+               127
+       },
+       {                       /* TENTACLE (P66) */
+               -3, -3, -2, -3,
+               -5, -2, -4, -2, -3, -2, -1, -2,
+               -5, -1, -3, -1, -1, -1,
+               -4, 0, -3, 0, -1, 0, 0, 0,
+               -4, 1, -2, 1, -1, 1, 1, 1, 3, 1,
+               0, 2, 1, 2, 3, 2, 4, 2, 5, 2,
+               2, 3, 3, 3,
+               127
+       },
+       {                       /* ROTATING OSCILLATOR (P42) */
+               0, -2, 1, -2,
+               -1, -1, 0, -1, 1, -1,
+               1, 0,
+               -2, 1, -1, 1, 0, 1, 1, 1,
+               -2, 2, -1, 2,
+               127
+       },
+       {                       /* INTERNAL OSCILLATOR (P7) */
+               -3, -6,
+               -4, -5, -3, -5,
+               -5, -4, -4, -4, -2, -4, -1, -4, 1, -4,
+               -3, -3, -1, -3, 0, -3, 1, -3,
+               -6, -2, -4, -2, -3, -2, -1, -2, 2, -2, 3, -2,
+               -5, -1, -4, -1, -2, -1, 2, -1,
+               -6, 0, -5, 0, -3, 0, -2, 0, -1, 0, 0, 0, 3, 0,
+               -4, 1, -3, 1, 1, 1, 3, 1,
+               -4, 2, -2, 2, 0, 2, 1, 2, 4, 2,
+               -4, 3, -3, 3, -2, 3, 0, 3, 1, 3, 3, 3, 4, 3, 5, 3,
+               -1, 4, 0, 4, 2, 4, 3, 4,
+               1, 5, 2, 5,
+               127
+       },
+       {                       /* OSCILLATOR (P7) */
+               -6, -7,
+               -6, -6,
+               -5, -5, -4, -5,
+               -4, -4, -3, -4, -2, -4,
+               -5, -3, -4, -3, -1, -3, 0, -3, 2, -3,
+               -5, -2, 0, -2, 1, -2, 2, -2,
+               -4, -1, 2, -1,
+               3, 0,
+               2, 1, 3, 1,
+               2, 2,
+               3, 3, 5, 3,
+               2, 4, 3, 4, 4, 4, 5, 4,
+               5, 5,
+               6, 6,
+               127
+       },
+       {                       /* OSCILLATOR (P9) */
+               -2, -6, -1, -6,
+               -4, -5, -3, -5, -2, -5, 0, -5,
+               -3, -4, -1, -4, 0, -4,
+               -3, -3, -2, -3, -1, -3, 1, -3,
+               0, -2, 1, -2,
+               0, -1,
+               -1, 0, 0, 0, 1, 0,
+               -1, 1, 2, 1,
+               -2, 2, -1, 2, 0, 2, 2, 2,
+               -2, 3, 0, 3, 3, 3,
+               -1, 4, 0, 4, 2, 4, 3, 4,
+               1, 5, 2, 5,
+               2, 6,
+               127
+       },
+       {                       /* OSCILLATOR1 (P11) */
+               -4, -5,
+               -5, -4, -4, -4,
+               -4, -3, -3, -3, -1, -3,
+               -6, -2, -5, -2, -4, -2, -2, -2, 0, -2,
+               -4, -1, -2, -1, 1, -1, 2, -1,
+               -4, 0, -3, 0, -2, 0, -1, 0, 0, 0, 1, 0, 3, 0, 4, 0, 5, 0,
+               -4, 1, 0, 1, 1, 1, 4, 1,
+               2, 2, 3, 2, 4, 2,
+               4, 3,
+               5, 4,
+               127
+       },
+       {                       /* OSCILLATOR2 (P11) */
+               -3, -3, -2, -3, 0, -3,
+               -3, -2, 0, -2, 1, -2,
+               -1, -1, 0, -1, 2, -1,
+               -3, 0, -2, 0, -1, 0, 1, 0, 2, 0,
+               -2, 1, 0, 1, 1, 1, 3, 1,
+               -1, 2, 0, 2, 2, 2, 3, 2,
+               1, 3, 2, 3,
+               127
+       },
+       {                       /* OSCILLATOR (P14) */
+               -2, -3, -1, -3, 0, -3,
+               -3, -2, -2, -2, 0, -2,
+               -3, -1, 1, -1, 2, -1,
+               -3, 0, -2, 0, 0, 0, 1, 0,
+               -1, 1, 0, 1, 2, 1, 3, 1,
+               -1, 2, 1, 2, 2, 2,
+               1, 3,
+               127
+       },
+       {                       /* OSCILLATOR (P17) */
+               -3, -6,
+               -3, -5,
+               -5, -4, -4, -4, -3, -4, -2, -4, -1, -4, 0, -4,
+               -3, -3, -1, -3, 0, -3,
+               -2, -2, -1, -2,
+               -2, 0, -1, 0, 2, 0,
+               -3, 1, -2, 1, 0, 1, 1, 1,
+               -3, 2, 0, 2, 2, 2,
+               -2, 3, -1, 3, 1, 3, 2, 3,
+               0, 4, 1, 4, 3, 4, 4, 4,
+               2, 5, 3, 5,
+               2, 6,
+               127
+       },
+       {                       /* OSCILLATOR (P18) */
+               -5, -4, -3, -4,
+               -4, -3, -3, -3, -2, -3,
+               -5, -2, -4, -2, -2, -2,
+               -6, -1, -5, -1, -3, -1, -2, -1, 0, -1, 1, -1, 2, -1, 4, -1,
+               -6, 0, -4, 0, -3, 0, -1, 0, 1, 0, 3, 0, 4, 0, 5, 0, 6, 0,
+               -5, 1, -4, 1, -2, 1, -1, 1, 0, 1, 1, 1, 2, 1, 4, 1, 5, 1,
+               -3, 2, -2, 2, 0, 2, 2, 2, 3, 2, 4, 2, 6, 2,
+               -3, 3, -1, 3, 4, 3,
+               127
+       },
+       {                       /* OSCILLATOR (P19) */
+               -6, -4, -2, -4,
+               -7, -3, -6, -3, -3, -3, -2, -3, -1, -3, 1, -3,
+               -7, -2, -5, -2, -4, -2, -2, -2, 0, -2, 1, -2, 2, -2,
+               -6, -1, -5, -1, -3, -1, -2, -1, -1, -1, 0, -1, 1, -1, 3, -1,
+               -6, 0, -4, 0, -3, 0, 0, 0, 2, 0, 3, 0,
+               -4, 1, -2, 1, 0, 1, 1, 1, 2, 1, 4, 1, 5, 1,
+               0, 2, 1, 2, 3, 2, 4, 2, 5, 2,
+               1, 3, 2, 3, 3, 3, 6, 3,
+               3, 4,
+               127
+       },
+       {                       /* OSCILLATOR (P22) */
+               -5, -5,
+               -4, -4,
+               -6, -3, -5, -3, -4, -3, -3, -3, -2, -3,
+               -4, -2, -2, -2,
+               -4, -1, -3, -1, -2, -1, -1, -1, 0, -1,
+               -3, 0, -1, 0, 1, 0, 2, 0,
+               0, 1, 1, 1, 2, 1, 3, 1,
+               0, 2, 1, 2,
+               4, 4,
+               5, 5, 6, 5,
+               127
+       },
+       {                       /* OSCILLATOR (P26) */
+               -5, -7,
+               -5, -6, -3, -6,
+               -6, -5, -5, -5, -4, -5, -3, -5, -2, -5,
+               -5, -4, -3, -4, -1, -4, 0, -4,
+               -5, -3, -2, -3, -1, -3, 1, -3,
+               -3, -2, -2, -2, 1, -2,
+               -1, -1, 0, -1, 1, -1, 2, -1, 3, -1,
+               1, 0, 3, 0,
+               -1, 1, 0, 1, 1, 1, 2, 1, 3, 1, 4, 1,
+               -4, 2, -3, 2, -1, 2, 1, 2, 3, 2, 5, 2,
+               -2, 3, 0, 3, 1, 3, 3, 3,
+               2, 4, 3, 4, 4, 4,
+               2, 5, 5, 5,
+               5, 6,
+               127
+       },
+       {                       /* OSCILLATOR (P29) */
+               -2, -6,
+               -2, -5, -1, -5,
+               -3, -4, -2, -4, 0, -4, 1, -4,
+               -5, -3, -4, -3, -3, -3, 2, -3, 3, -3, 4, -3,
+               -4, -2, -2, -2, 2, -2, 4, -2,
+               -3, -1, -2, -1, -1, -1, 0, -1, 3, -1, 4, -1, 5, -1,
+               -5, 0, -4, 0, -3, 0, -2, 0, 1, 0, 2, 0, 3, 0,
+               -5, 1, -4, 1, -1, 1, 0, 1, 1, 1, 2, 1,
+               -4, 2, -3, 2, -2, 2, 0, 2, 2, 2,
+               -3, 3, 0, 3,
+               1, 5,
+               127
+       },
+       {                       /* OSCILLATOR (P46) */
+               -2, -4,
+               -2, -3, -1, -3, 0, -3,
+               -4, -2, -3, -2, -2, -2, 0, -2,
+               -5, -1, -3, -1, -1, -1, 0, -1, 1, -1, 2, -1, 3, -1,
+               -4, 0, -3, 0, -2, 0, -1, 0, 0, 0, 3, 0,
+               -3, 1, -1, 1, 1, 1, 4, 1,
+               -4, 2, -3, 2, -2, 2, -1, 2, 0, 2, 1, 2,
+               -1, 3,
+               -1, 4,
+               127
+       },
+};
+
+static char patterns_6S2a2b4aB2a3a4b[][2 * NUMPTS + 1] =
+{
+       {                       /* GLIDERS */
+               -5, -9,
+               -5, -8,
+               -4, -7, -3, -7,
+               -4, -6,
+               -3, -5,
+               -1, -2,
+               -1, -1, 1, -1,
+               -1, 0, 1, 0,
+               0, 1,
+               0, 2,
+               2, 5,
+               2, 6,
+               2, 7,
+               3, 8, 5, 8,
+               3, 9,
+               127
+       },
+       {                       /* SYMMETRIC 4 GLIDER GUN */
+               -2, -3, -1, -3, 0, -3,
+               -3, -2, -2, -2, 3, -2,
+               -2, -1, 0, -1, 1, -1,
+               -2, 0, 0, 0, 2, 0, 3, 0,
+               -1, 1,
+               -1, 2,
+               127
+       },
+       {                       /* PUFFER (P18) */
+               -2, -4,
+               -3, -3, -2, -3, -1, -3, 0, -3,
+               -2, -2, 0, -2,
+               -2, -1, 1, -1,
+               -2, 0, 2, 0,
+               -2, 2, 4, 2,
+               -1, 3, 0, 3, 1, 3, 2, 3, 3, 3, 4, 3,
+               0, 4, 1, 4, 3, 4, 4, 4,
+               1, 5, 4, 5,
+               127
+       },
+       {                       /* QUASAR (P10) */
+               -2, -1, -1, -1, 0, -1,
+               -1, 0, 0, 0,
+               0, 1,
+               127
+       },
+};
+
+static int  patterns_6rules[] =
+{
+       (sizeof patterns_6S2b34B2a / sizeof patterns_6S2b34B2a[0]),
+       (sizeof patterns_6S2a2b4aB2a3a4b / sizeof patterns_6S2a2b4aB2a3a4b[0])
+};
+
+static int  patterns_8rules[] =
+{
+       (sizeof patterns_8S23B3 / sizeof patterns_8S23B3[0])
+};
+
+static paramstruct param_6rules[] =
+{
+       {
+               0x18, 0x0,
+               {0x2, 0x0, 0x0},
+               {0x1, 0x0, 0x0}
+       },
+       {
+               0x0, 0x0,
+               {0x3, 0x0, 0x1},
+               {0x1, 0x1, 0x2}
+       }
+};
+
+static paramstruct param_8rules[] =
+{
+       {
+               0xC, 0x8,
+               {0x0, 0x0, 0x0},
+               {0x0, 0x0, 0x0}
+       }
+};
+
+#define LIFE_6S2b34B2a 0
+#define LIFE_6GLIDERS 1                /* GLIDER rules are first in param_6rules */
+#define LIFE_6S2a2b4aB2a3a4b 1
+#define LIFE_6RULES (sizeof param_6rules / sizeof param_6rules[0])
+#define LIFE_8S23B3 0
+#define LIFE_8GLIDERS 1                /* GLIDER rules are first in param_8rules */
+#define LIFE_8RULES (sizeof param_8rules / sizeof param_8rules[0])
+
+static int
+codeToPatternedRule(paramstruct param)
+{
+       unsigned int i;
+       int         g;
+
+       switch (local_neighbors) {
+               case 6:
+                       for (i = 0; i < LIFE_6RULES; i++)
+                               if (param_6rules[i].survival == param.survival &&
+                                   param_6rules[i].birth == param.birth) {
+                                       for (g = 0; g < maxgroups[neighbor_kind]; g++) {
+                                               if (param_6rules[i].survival_group[g] !=
+                                                   param.survival_group[g] ||
+                                                   param_6rules[i].birth_group[g] !=
+                                                   param.birth_group[g]) {
+                                                       break;
+                                               }
+                                       }
+                                       if (g == maxgroups[neighbor_kind])
+                                               return i;
+                               }
+                       return LIFE_6RULES;
+               case 8:
+                       for (i = 0; i < LIFE_8RULES; i++)
+                               if (param_8rules[i].survival == param.survival &&
+                                   param_8rules[i].birth == param.birth) {
+                                       for (g = 0; g < maxgroups[neighbor_kind]; g++) {
+                                               if (param_8rules[i].survival_group[g] !=
+                                                   param.survival_group[g] ||
+                                                   param_8rules[i].birth_group[g] !=
+                                                   param.birth_group[g]) {
+                                                       break;
+                                               }
+                                       }
+                                       if (g == maxgroups[neighbor_kind])
+                                               return i;
+                               }
+                       return LIFE_8RULES;
+       }
+       return 0;
+}
+
+static void
+copyFromPatternedRule(paramstruct * param, int patterned_rule)
+{
+       int         i;
+
+       switch (local_neighbors) {
+               case 6:
+                       param->survival = param_6rules[patterned_rule].survival;
+                       param->birth = param_6rules[patterned_rule].birth;
+                       for (i = 0; i < maxgroups[neighbor_kind]; i++) {
+                               param->survival_group[i] =
+                                       param_6rules[patterned_rule].survival_group[i];
+                               param->birth_group[i] =
+                                       param_6rules[patterned_rule].birth_group[i];
+                       }
+                       break;
+               case 8:
+                       param->survival = param_8rules[patterned_rule].survival;
+                       param->birth = param_8rules[patterned_rule].birth;
+                       for (i = 0; i < maxgroups[neighbor_kind]; i++) {
+                               param->survival_group[i] =
+                                       param_8rules[patterned_rule].survival_group[i];
+                               param->birth_group[i] =
+                                       param_8rules[patterned_rule].birth_group[i];
+                       }
+                       break;
+       }
+}
+
+static void
+printRule(paramstruct param)
+{
+       int         l, g;
+       Bool        found;
+
+       (void) fprintf(stdout, "rule (Survival/Birth neighborhood): S");
+       for (l = 0; l <= local_neighbors; l++) {
+               if (param.survival & (1 << l))
+                       (void) fprintf(stdout, "%d", l);
+               else if (l >= FIRSTGROUP && l < FIRSTGROUP + maxgroups[neighbor_kind])
+                       for (g = 0; g < groupnumber[neighbor_kind][l - FIRSTGROUP]; g++) {
+                               if (param.survival_group[l - FIRSTGROUP] & (1 << g))
+                                       (void) fprintf(stdout, "%d%c", l, 'a' + g);
+                       }
+       } (void) fprintf(stdout, "/B");
+       for (l = 0; l <= local_neighbors; l++) {
+               if (param.birth & (1 << l))
+                       (void) fprintf(stdout, "%d", l);
+               else if (l >= FIRSTGROUP && l < FIRSTGROUP + maxgroups[neighbor_kind])
+                       for (g = 0; g < groupnumber[neighbor_kind][l - FIRSTGROUP]; g++) {
+                               if (param.birth_group[l - FIRSTGROUP] & (1 << g))
+                                       (void) fprintf(stdout, "%d%c", l, 'a' + g);
+                       }
+       }
+       (void) fprintf(stdout, "\nbinary rule: Survival 0x%X, Birth 0x%X\n",
+                      param.survival, param.birth);
+       found = False;
+       for (l = 0; l <= maxgroups[neighbor_kind]; l++) {
+               if (param.survival_group[l] || param.birth_group[l]) {
+                       found = True;
+                       break;
+               }
+       }
+       if (found)
+               for (l = 0; l < maxgroups[neighbor_kind]; l++) {
+                       (void) fprintf(stdout,
+                                      "groups in neighborhood %d: Survival 0x%X, Birth 0x%X\n",
+                                      l + FIRSTGROUP, param.survival_group[l], param.birth_group[l]);
+               }
+}
+
+static int
+position_of_neighbor(lifestruct * lp, int n, int col, int row)
+{
+       int         dir = n * 360 / local_neighbors;
+
+       if (local_neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                               break;
+                       case 60:
+                               if (!(row & 1))
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                               row = (!row) ? lp->nrows - 1 : row - 1;
+                               break;
+                       case 120:
+                               if (row & 1)
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                               row = (!row) ? lp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? lp->ncols - 1 : col - 1;
+                               break;
+                       case 240:
+                               if (row & 1)
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                               row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                               break;
+                       case 300:
+                               if (!(row & 1))
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else if (local_neighbors == 4 || local_neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                               break;
+                       case 45:
+                               col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                               row = (!row) ? lp->nrows - 1 : row - 1;
+                               break;
+                       case 90:
+                               row = (!row) ? lp->nrows - 1 : row - 1;
+                               break;
+                       case 135:
+                               col = (!col) ? lp->ncols - 1 : col - 1;
+                               row = (!row) ? lp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? lp->ncols - 1 : col - 1;
+                               break;
+                       case 225:
+                               col = (!col) ? lp->ncols - 1 : col - 1;
+                               row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                               break;
+                       case 270:
+                               row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                               break;
+                       case 315:
+                               col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {                /* TRI */
+               if ((col + row) % 2) {  /* right */
+                       switch (dir) {
+                               case 0:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 60:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       if (row + 1 == lp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == lp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (row + 1 == lp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == lp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 120:
+                                       row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 180:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? lp->nrows - 1 : row - 1;
+                                       break;
+                               case 240:
+                                       row = (!row) ? lp->nrows - 1 : row - 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (!row)
+                                               row = lp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = lp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 300:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       if (!row)
+                                               row = lp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = lp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       row = (!row) ? lp->nrows - 1 : row - 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               } else {        /* left */
+                       switch (dir) {
+                               case 0:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? lp->nrows - 1 : row - 1;
+                                       break;
+                               case 60:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       if (!row)
+                                               row = lp->nrows - 2;
+                                       else if (row == 1)
+                                               row = lp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (!row)
+                                               row = lp->nrows - 2;
+                                       else if (row == 1)
+                                               row = lp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 120:
+                                       row = (!row) ? lp->nrows - 1 : row - 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       row = (!row) ? lp->nrows - 1 : row - 1;
+                                       break;
+                               case 180:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (!col) ? lp->ncols - 1 : col - 1;
+                                       row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 240:
+                                       row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (row + 1 == lp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == lp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 300:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       if (row + 1 == lp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == lp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (col + 1 == lp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == lp->nrows) ? 0 : row + 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               }
+       }
+
+       return (row * lp->ncols + col);
+}
+
+static void
+parseRule(ModeInfo * mi)
+{
+       int         n, g, l;
+       char        serving = 0;
+       static Bool found = False;
+
+       if (found)
+               return;
+       input_param.survival = input_param.birth = 0;
+       for (n = 0; n < MAXGROUPS; n++) {
+               input_param.survival_group[n] = input_param.birth_group[n] = 0;
+       }
+       if (callahan) {
+               local_neighbors = 6;
+               neighbor_kind = 2;
+               found = True;
+               input_param.survival = param_6rules[0].survival;
+               input_param.birth = param_6rules[0].birth;
+               for (n = 0; n < maxgroups[neighbor_kind]; n++) {
+                       input_param.survival_group[n] = param_6rules[0].survival_group[n];
+                       input_param.birth_group[n] = param_6rules[0].birth_group[n];
+               }
+               return;
+       } else if (andreen) {
+               local_neighbors = 6;
+               neighbor_kind = 2;
+               found = True;
+               input_param.survival = param_6rules[1].survival;
+               input_param.birth = param_6rules[1].birth;
+               for (n = 0; n < maxgroups[neighbor_kind]; n++) {
+                       input_param.survival_group[n] = param_6rules[1].survival_group[n];
+                       input_param.birth_group[n] = param_6rules[1].birth_group[n];
+               }
+               return;
+       }
+       if (rule) {
+               n = 0;
+               while (rule[n]) {
+                       if (rule[n] == 'P') {
+                               allPatterns = True;
+                               found = True;
+                               if (MI_IS_VERBOSE(mi))
+                                       (void) fprintf(stdout, "rule: All rules with known patterns\n");
+                               return;
+                       } else if (rule[n] == 'G') {
+                               allGliders = True;
+                               found = True;
+                               if (MI_IS_VERBOSE(mi))
+                                       (void) fprintf(stdout, "rule: All rules with known gliders\n");
+                               return;
+                       } else if (rule[n] == 'S' || rule[n] == 'E' || rule[n] == 'L') {
+                               serving = 'S';
+                       } else if (rule[n] == 'B') {
+                               serving = 'B';
+                       } else {
+                               l = rule[n] - '0';
+                               if (l >= 0 && l <= 9 && l <= local_neighbors) {         /* no 10, 11, 12 */
+                                       g = rule[n + 1] - 'a';
+                                       if (l >= FIRSTGROUP && l < FIRSTGROUP + maxgroups[neighbor_kind] &&
+                                           g >= 0 && g < groupnumber[neighbor_kind][l]) {      /* Groupings */
+                                               if (serving == 'S') {
+                                                       found = True;
+                                                       input_param.survival_group[l - FIRSTGROUP] |= (1 << g);
+                                               } else if (serving == 'B') {
+                                                       found = True;
+                                                       input_param.birth_group[l - FIRSTGROUP] |= (1 << g);
+                                               }
+                                       } else {
+                                               if (serving == 'S') {
+                                                       found = True;
+                                                       input_param.survival |= (1 << l);
+                                               } else if (serving == 'B') {
+                                                       found = True;
+                                                       input_param.birth |= (1 << l);
+                                               }
+                                       }
+                               }
+                       }
+                       n++;
+               }
+       }
+       if (!found) {           /* Default to Conway's rule if very stupid */
+               allGliders = True;
+               found = True;
+               if (MI_IS_VERBOSE(mi))
+                       (void) fprintf(stdout,
+                       "rule: Defaulting to all rules with known gliders\n");
+               return;
+       }
+       if (MI_IS_VERBOSE(mi))
+               printRule(input_param);
+}
+
+static void
+parseFile(void)
+{
+       FILE       *file;
+       static Bool done = False;
+       int         firstx = 0, x = 0, y = 0, i = 0;
+       int         c = 0;
+       char        line[256];
+
+       if (done)
+               return;
+       done = True;
+       if (!lifefile || !*lifefile || ((file = my_fopen(lifefile, "r")) == NULL)) {
+               /*(void) fprintf(stderr, "could not read file \"%s\"\n", lifefile); */
+               return;
+       }
+       for (;;) {
+               if (!fgets(line, 256, file)) {
+                       (void) fprintf(stderr, "could not read header of file \"%s\"\n",
+                                      lifefile);
+                       (void) fclose(file);
+                       return;
+               }
+               if (strncmp(line, "#P", (size_t) 2) == 0 &&
+                   sscanf(line, "#P %d %d", &x, &y) == 2)
+                       break;
+       }
+       c = getc(file);
+       while (c != EOF && !(c == '0' || c == 'O' || c == '*' || c == '.')) {
+               c = getc(file);
+       }
+       if (c == EOF || x <= -127 || y <= -127 || x >= 127 || y >= 127) {
+               (void) fprintf(stderr, "corrupt file \"%s\" or file to large\n",
+                              lifefile);
+               (void) fclose(file);
+               return;
+       }
+       firstx = x;
+       filePattern = (char *) malloc((2 * NUMFILEPTS + 1) * sizeof (char));
+
+       while (c != EOF && x < 127 && y < 127 && i < 2 * NUMFILEPTS) {
+               if (c == '0' || c == 'O' || c == '*') {
+                       filePattern[i++] = x++;
+                       filePattern[i++] = y;
+               } else if (c == '.') {
+                       x++;
+               } else if (c == '\n') {
+                       x = firstx;
+                       y++;
+               }
+               c = getc(file);
+       }
+       (void) fclose(file);
+       filePattern[i] = 127;
+}
+
+static void
+init_list(lifestruct * lp, int state)
+{
+       /* Waste some space at the beginning and end of list
+          so we do not have to complicated checks against falling off the ends. */
+       lp->last[state] = (CellList *) malloc(sizeof (CellList));
+       lp->first[state] = (CellList *) malloc(sizeof (CellList));
+       lp->first[state]->previous = lp->last[state]->next = NULL;
+       lp->first[state]->next = lp->last[state]->previous = NULL;
+       lp->first[state]->next = lp->last[state];
+       lp->last[state]->previous = lp->first[state];
+}
+
+static void
+addto_list(lifestruct * lp, int state, cellstruct info)
+{
+       CellList   *curr;
+
+       curr = (CellList *) malloc(sizeof (CellList));
+       lp->last[state]->previous->next = curr;
+       curr->previous = lp->last[state]->previous;
+       curr->next = lp->last[state];
+       lp->last[state]->previous = curr;
+       curr->info = info;
+       if (info.position >= 0) {
+               lp->arr[info.position] = curr;
+               lp->ncells[state]++;
+       }
+}
+static void
+removefrom_list(lifestruct * lp, int state, CellList * curr)
+{
+       curr->previous->next = curr->next;
+       curr->next->previous = curr->previous;
+       if (curr->info.position >= 0) {
+               lp->arr[curr->info.position] = NULL;
+               lp->ncells[state]--;
+       }
+       (void) free((void *) curr);
+}
+
+#ifdef DEBUG
+static void
+print_state(ModeInfo * mi, int state)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       CellList   *curr;
+       int         i = 0;
+
+       curr = lp->first[state]->next;
+       (void) printf("state %d\n", state);
+       while (curr != lp->last[state]) {
+               (void) printf("%d: position %ld,        age %d, state %d, toggle %d\n",
+                             i, curr->info.position, curr->info.age,
+                             curr->info.state, curr->info.toggle);
+               curr = curr->next;
+               i++;
+       }
+}
+
+#endif
+
+static void
+flush_list(lifestruct * lp, int state)
+{
+       while (lp->last[state]->previous != lp->first[state]) {
+               CellList   *curr = lp->last[state]->previous;
+
+               curr->previous->next = lp->last[state];
+               lp->last[state]->previous = curr->previous;
+               (void) free((void *) curr);
+       }
+       lp->ncells[state] = 0;
+}
+
+
+static void
+draw_cell(ModeInfo * mi, cellstruct info)
+{
+       Display    *display = MI_DISPLAY(mi);
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       GC          gc = lp->backGC;
+       int         col, row;
+
+       col = (int) (info.position % lp->ncols);
+       row = (int) (info.position / lp->ncols);
+       if (info.state == LIVE) {
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, gc, MI_PIXEL(mi, info.age));
+               else
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       } else
+               XSetForeground(display, gc, lp->black);
+
+       if (local_neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               lp->shape.hexagon[0].x = lp->xb + ccol * lp->xs;
+               lp->shape.hexagon[0].y = lp->yb + crow * lp->ys;
+               if (lp->xs == 1 && lp->ys == 1)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                      lp->backGC, lp->shape.hexagon[0].x, lp->shape.hexagon[0].y);
+               else
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), lp->backGC,
+                           lp->shape.hexagon, 6, Convex, CoordModePrevious);
+       } else if (local_neighbors == 4 || local_neighbors == 8) {
+               if (lp->pixelmode || info.state == DEAD)
+                       XFillRectangle(display, MI_WINDOW(mi), gc,
+                                      lp->xb + lp->xs * col, lp->yb + lp->ys * row,
+                                lp->xs - (lp->xs > 3 && lp->pixelmode),
+                                lp->ys - (lp->ys > 3 && lp->pixelmode));
+               else
+/*-
+ * PURIFY 4.0.1 on SunOS4 and on Solaris 2 reports a 132 byte memory leak on
+ * the next line */
+                       (void) XPutImage(display, MI_WINDOW(mi), gc, lp->logo,
+                         0, 0, lp->xb + lp->xs * col, lp->yb + lp->ys * row,
+                                        lp->logo->width, lp->logo->height);
+       } else {                /* TRI */
+               int         orient = (col + row) % 2;   /* O left 1 right */
+
+               lp->shape.triangle[orient][0].x = lp->xb + col * lp->xs;
+               lp->shape.triangle[orient][0].y = lp->yb + row * lp->ys;
+               if (lp->xs <= 3 || lp->ys <= 3)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), lp->backGC,
+                       ((orient) ? -1 : 1) + lp->shape.triangle[orient][0].x,
+                                      lp->shape.triangle[orient][0].y);
+               else {
+                       if (orient)
+                               lp->shape.triangle[orient][0].x += (lp->xs / 2 - 1);
+                       else
+                               lp->shape.triangle[orient][0].x -= (lp->xs / 2 - 1);
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), lp->backGC,
+                                    lp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+
+               }
+       }
+}
+
+static void
+setcelltoggles(ModeInfo * mi, int col, int row)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       int         position;
+       CellList   *curr;
+
+       position = row * lp->ncols + col;
+       curr = lp->arr[position];
+       if (!curr) {
+               (void) fprintf(stderr, "state toggling but not on list\n");
+               return;
+       }
+       curr->info.toggle = True;
+}
+
+static void
+setcellfromtoggle(ModeInfo * mi, int col, int row)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       int         neighbor, n, position;
+       cellstruct  info;
+       CellList   *curr, *currn;
+
+       position = row * lp->ncols + col;
+       curr = lp->arr[position];
+       if ((curr && curr->info.state == DEAD && curr->info.toggle) ||
+           (curr && curr->info.state == LIVE && !curr->info.toggle)) {
+               for (n = 0; n < local_neighbors; n++) {
+                       neighbor = position_of_neighbor(lp, n, col, row);
+                       currn = lp->arr[neighbor];
+                       if (!currn) {
+                               info.position = neighbor;
+                               info.age = 0;
+                               info.state = DEAD;
+                               info.toggle = False;
+                               addto_list(lp, DEAD, info);
+                       }
+               }
+       }
+       if (curr && curr->info.state == DEAD && curr->info.toggle) {
+               removefrom_list(lp, DEAD, curr);
+               info.age = 0;
+               info.position = position;
+               info.toggle = False;
+               info.state = LIVE;
+               addto_list(lp, LIVE, info);
+               draw_cell(mi, info);
+       } else if (curr && curr->info.state == LIVE && !curr->info.toggle) {
+               info = curr->info;
+               /* if we aren't up to blue yet, then keep aging the cell. */
+               if ((MI_NPIXELS(mi) > 2) &&
+                   (info.age < (unsigned short) (MI_NPIXELS(mi) * 0.7))) {
+                       ++(info.age);
+                       curr->info.age = info.age;
+                       draw_cell(mi, info);
+               }
+       }
+}
+
+static void
+setcell(ModeInfo * mi, int col, int row, int state)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       int         neighbor, n, position;
+       cellstruct  info;
+       CellList   *curr, *currn;
+
+       position = row * lp->ncols + col;
+       curr = lp->arr[position];
+       if (state == LIVE) {
+               if (curr && curr->info.state == DEAD) {
+                       removefrom_list(lp, DEAD, curr);
+                       curr = NULL;
+               }
+               if (!curr) {
+                       for (n = 0; n < local_neighbors; n++) {
+                               neighbor = position_of_neighbor(lp, n, col, row);
+                               currn = lp->arr[neighbor];
+                               if (!currn) {
+                                       info.age = 0;
+                                       info.position = neighbor;
+                                       info.state = DEAD;
+                                       info.toggle = False;
+                                       addto_list(lp, DEAD, info);
+                               }
+                       }
+                       info.age = 0;
+                       info.position = position;
+                       info.state = LIVE;
+                       info.toggle = False;
+                       addto_list(lp, LIVE, info);
+                       draw_cell(mi, info);
+               } else {
+                       info = curr->info;
+                       info.age = 0;
+                       draw_cell(mi, info);
+               }
+       } else if (curr && curr->info.state == LIVE) {
+               info.age = 0;
+               info.position = position;
+               info.state = DEAD;
+               info.toggle = False;
+               removefrom_list(lp, LIVE, curr);
+               addto_list(lp, DEAD, info);     /* Just in case... */
+               draw_cell(mi, info);
+       }
+}
+
+static void
+alloc_cells(lifestruct * lp)
+{
+       lp->arr = (CellList **) calloc(lp->npositions, sizeof (CellList *));
+}
+
+static void
+free_cells(lifestruct * lp)
+{
+       if (lp->arr != NULL)
+               (void) free((void *) lp->arr);
+       lp->arr = NULL;
+}
+
+#if 0
+static int
+n_neighbors(lifestruct * lp, CellList * curr)
+{
+       int         col, row, n, p, count = 0;
+
+       col = curr->info.position % lp->ncols;
+       row = curr->info.position / lp->ncols;
+       for (n = 0; n < local_neighbors; n++) {
+               p = position_of_neighbor(lp, n, col, row);
+               if (lp->arr[p] && lp->arr[p]->info.state == LIVE) {
+                       count++;
+               }
+       }
+       return count;
+}
+#endif
+
+static int
+ng_neighbors(lifestruct * lp, CellList * curr, int *group)
+{
+       int         col, row, n, p, count = 0, gcount = 0;
+
+       col = (int) (curr->info.position % lp->ncols);
+       row = (int) (curr->info.position / lp->ncols);
+       for (n = 0; n < local_neighbors; n++) {
+               p = position_of_neighbor(lp, n, col, row);
+               gcount <<= 1;
+               if (lp->arr[p] && lp->arr[p]->info.state == LIVE) {
+                       count++;
+                       gcount++;
+               }
+       }
+       *group = gcount;
+       return count;
+}
+
+static void
+RandomSoup(ModeInfo * mi, int n, int v)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       int         row, col;
+
+       v /= 2;
+       if (v < 1)
+               v = 1;
+       for (row = lp->nrows / 2 - v; row < lp->nrows / 2 + v; ++row)
+               for (col = lp->ncols / 2 - v; col < lp->ncols / 2 + v; ++col)
+                       if (NRAND(100) < n && col > 1 && row > 1 &&
+                           col < lp->ncols && row < lp->nrows)
+                               setcell(mi, col, row, LIVE);
+       if (MI_IS_VERBOSE(mi))
+               (void) fprintf(stdout, "random pattern\n");
+}
+
+static void
+GetPattern(ModeInfo * mi, int pattern_rule, int pattern)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       int         row, col;
+       char       *patptr = NULL;
+
+       if (filePattern) {
+               patptr = &filePattern[0];
+       } else {
+               switch (local_neighbors) {
+                       case 6:
+                               switch (pattern_rule) {
+                                       case LIFE_6S2b34B2a:
+                                               patptr = &patterns_6S2b34B2a[pattern][0];
+                                               break;
+                                       case LIFE_6S2a2b4aB2a3a4b:
+                                               patptr = &patterns_6S2a2b4aB2a3a4b[pattern][0];
+                                               break;
+                               }
+                               break;
+                       case 8:
+                               switch (pattern_rule) {
+                                       case LIFE_8S23B3:
+                                               patptr = &patterns_8S23B3[pattern][0];
+                                               break;
+                               }
+                               break;
+               }
+       }
+       while ((col = *patptr++) != 127) {
+               row = *patptr++;
+               col += lp->ncols / 2;
+               if (local_neighbors == 6) {
+                       if (row < 0)
+                               col += (lp->nrows / 2 % 2) ? -row / 2 : -(row - 1) / 2;
+                       else
+                               col += (lp->nrows / 2 % 2) ? -(row + 1) / 2 : -row / 2;
+               }
+               row += lp->nrows / 2;
+
+               if (col >= 0 && row >= 0 && col < lp->ncols && row < lp->nrows)
+                       setcell(mi, col, row, LIVE);
+       }
+       if (MI_IS_VERBOSE(mi) && !filePattern)
+               (void) fprintf(stdout, "table number %d\n", pattern);
+}
+
+static void
+shooter(ModeInfo * mi)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       int         hsp, vsp, hoff = 1, voff = 1, temp;
+
+       /* Generate the glider at the edge of the screen */
+       if (local_neighbors == 6 && lp->patterned_rule == LIFE_6S2b34B2a) {
+               /*-
+     * Generate gliders on left and right.... more could be done from top and
+     * bottom... also phase with voff
+     */
+               hsp = (LRAND() & 1) ? 0 : lp->ncols - 1;
+               hsp = lp->ncols - 1;
+               temp = MIN(lp->nrows, 12);
+               vsp = lp->nrows / 2 + NRAND(temp) - temp / 2;
+               if (hsp > lp->ncols / 2) {
+                       hoff = -1;
+                       temp = (vsp % 2) ? 0 : hoff;
+               } else
+                       temp = (vsp % 2) ? hoff : 0;
+
+               setcell(mi, hsp + temp + 2 * hoff, vsp + 4 * voff, LIVE);
+               setcell(mi, hsp + 3 * hoff, vsp + 3 * voff, LIVE);
+               setcell(mi, hsp + temp + 3 * hoff, vsp + 2 * voff, LIVE);
+               setcell(mi, hsp + temp + 0 * hoff, vsp + 2 * voff, LIVE);
+               setcell(mi, hsp + 4 * hoff, vsp + 1 * voff, LIVE);
+               setcell(mi, hsp + temp + 3 * hoff, vsp + 0 * voff, LIVE);
+       } else if (local_neighbors == 8 && lp->patterned_rule == LIFE_8S23B3) {
+               if (LRAND() & 1) {
+                       hsp = (LRAND() & 1) ? 0 : lp->ncols - 1;
+                       vsp = NRAND(lp->nrows);
+               } else {
+                       vsp = (LRAND() & 1) ? 0 : lp->nrows - 1;
+                       hsp = NRAND(lp->ncols);
+               }
+               if (vsp > lp->nrows / 2)
+                       voff = -1;
+               if (hsp > lp->ncols / 2)
+                       hoff = -1;
+               setcell(mi, hsp + 2 * hoff, vsp + 0 * voff, LIVE);
+               setcell(mi, hsp + 2 * hoff, vsp + 1 * voff, LIVE);
+               setcell(mi, hsp + 2 * hoff, vsp + 2 * voff, LIVE);
+               setcell(mi, hsp + 1 * hoff, vsp + 2 * voff, LIVE);
+               setcell(mi, hsp + 0 * hoff, vsp + 1 * voff, LIVE);
+       }
+}
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+
+       if (!lp->logo)
+               getImage(mi, &lp->logo, CELL_WIDTH, CELL_HEIGHT, CELL_BITS,
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                        DEFAULT_XPM, CELL_NAME,
+#endif
+                        &lp->graphics_format, &lp->cmap, &lp->black);
+#ifndef STANDALONE
+       if (lp->cmap != None) {
+               setColormap(display, window, lp->cmap, MI_IS_INWINDOW(mi));
+               if (lp->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = lp->black;
+                       lp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else
+#endif /* STANDALONE */
+       {
+               lp->black = MI_BLACK_PIXEL(mi);
+               lp->backGC = MI_GC(mi);
+       }
+}
+
+static void
+free_stuff(Display * display, lifestruct * lp)
+{
+       if (lp->cmap != None) {
+               XFreeColormap(display, lp->cmap);
+               if (lp->backGC != None) {
+                       XFreeGC(display, lp->backGC);
+                       lp->backGC = None;
+               }
+               lp->cmap = None;
+       } else
+               lp->backGC = None;
+       if (lp->logo)
+               destroyImage(&lp->logo, &lp->graphics_format);
+}
+
+void
+init_life(ModeInfo * mi)
+{
+       lifestruct *lp;
+       int         size = MI_SIZE(mi), npats, i;
+
+       if (lifes == NULL) {
+               if ((lifes = (lifestruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (lifestruct))) == NULL)
+                       return;
+       }
+       lp = &lifes[MI_SCREEN(mi)];
+
+       lp->generation = 0;
+       lp->redrawing = 0;
+
+       if (!local_neighbors) {
+               for (i = 0; i < NEIGHBORKINDS; i++) {
+                       if (neighbors == plots[i]) {
+                               local_neighbors = neighbors;
+                               neighbor_kind = i;
+                               break;
+                       }
+                       if (i == NEIGHBORKINDS - 1) {
+#if 0
+                               local_neighbors = plots[NRAND(NEIGHBORKINDS)];
+                               local_neighbors = (LRAND() & 1) ? 4 : 8;
+                               neighbor_kind = (local_neighbors == 4) ? 1 : 3;
+#else
+                               local_neighbors = 8;
+                               neighbor_kind = 3;
+#endif
+                               break;
+                       }
+               }
+       }
+       parseRule(mi);
+       parseFile();
+       if (allPatterns) {
+               switch (local_neighbors) {
+                       case 6:
+                               lp->patterned_rule = NRAND(LIFE_6RULES);
+                               break;
+                       case 8:
+                               lp->patterned_rule = NRAND(LIFE_8RULES);
+                               break;
+               }
+               copyFromPatternedRule(&lp->param, lp->patterned_rule);
+               if (MI_IS_VERBOSE(mi))
+                       printRule(lp->param);
+       } else if (allGliders) {
+               switch (local_neighbors) {
+                       case 6:
+                               lp->patterned_rule = NRAND(LIFE_6GLIDERS);
+                               break;
+                       case 8:
+                               lp->patterned_rule = NRAND(LIFE_8GLIDERS);
+                               break;
+               }
+               copyFromPatternedRule(&lp->param, lp->patterned_rule);
+               if (MI_IS_VERBOSE(mi))
+                       printRule(lp->param);
+       } else {
+               lp->param.survival = input_param.survival;
+               lp->param.birth = input_param.birth;
+               for (i = 0; i < maxgroups[neighbor_kind]; i++) {
+                       lp->param.survival_group[i] = input_param.survival_group[i];
+                       lp->param.birth_group[i] = input_param.birth_group[i];
+               }
+               lp->patterned_rule = codeToPatternedRule(lp->param);
+       }
+       lp->width = MI_WIDTH(mi);
+       lp->height = MI_HEIGHT(mi);
+
+       if (lp->first[0])
+               for (i = 0; i < STATES; i++)
+                       flush_list(lp, i);
+       else
+               for (i = 0; i < STATES; i++)
+                       init_list(lp, i);
+       free_cells(lp);
+
+       if (local_neighbors == 6) {
+               int         nccols, ncrows, sides;
+
+               if (lp->width < 2)
+                       lp->width = 2;
+               if (lp->height < 4)
+                       lp->height = 4;
+               if (size < -MINSIZE)
+                       lp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               lp->ys = MAX(MINSIZE, MIN(lp->width, lp->height) / (4 * MINGRIDSIZE));
+                       else
+                               lp->ys = MINSIZE;
+               } else
+                       lp->ys = MIN(size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                              MINGRIDSIZE));
+               lp->xs = lp->ys;
+               nccols = MAX(lp->width / lp->xs - 2, 2);
+               ncrows = MAX(lp->height / lp->ys - 1, 2);
+               lp->ncols = nccols / 2;
+               lp->nrows = 2 * (ncrows / 4);
+               lp->xb = (lp->width - lp->xs * nccols) / 2 + lp->xs / 2;
+               lp->yb = (lp->height - lp->ys * (ncrows / 2) * 2) / 2 + lp->ys;
+               for (sides = 0; sides < 6; sides++) {
+                       lp->shape.hexagon[sides].x = (lp->xs - 1) * hexagonUnit[sides].x;
+                       lp->shape.hexagon[sides].y =
+                               ((lp->ys - 1) * hexagonUnit[sides].y / 2) * 4 / 3;
+               }
+               lp->black = MI_BLACK_PIXEL(mi);
+               lp->backGC = MI_GC(mi);
+       } else if (local_neighbors == 4 || local_neighbors == 8) {
+               init_stuff(mi);
+               if (lp->width < 2)
+                       lp->width = 2;
+               if (lp->height < 2)
+                       lp->height = 2;
+#if 0
+               if (size == 0 && !MI_IS_ICONIC(mi)) {
+                       lp->pixelmode = False;
+                       lp->xs = lp->logo->width;
+                       lp->ys = lp->logo->height;
+               }
+#else
+               if (size == 0 ||
+                   MINGRIDSIZE * size > lp->width || MINGRIDSIZE * size > lp->height) {
+                       if (lp->width > MINGRIDSIZE * lp->logo->width &&
+                           lp->height > MINGRIDSIZE * lp->logo->height) {
+                               lp->pixelmode = False;
+                               lp->xs = lp->logo->width;
+                               lp->ys = lp->logo->height;
+                       } else {
+                               lp->pixelmode = True;
+                               lp->xs = lp->ys = MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                                     MINGRIDSIZE);
+                       }
+               }
+#endif
+               else {
+                       lp->pixelmode = True;
+                       if (size < -MINSIZE)
+                               lp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+                       else if (size < MINSIZE)
+                               lp->ys = MINSIZE;
+                       else
+                               lp->ys = MIN(size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                                      MINGRIDSIZE));
+                       lp->xs = lp->ys;
+               }
+               lp->ncols = MAX(lp->width / lp->xs, 4);
+               lp->nrows = MAX(lp->height / lp->ys, 4);
+               lp->xb = (lp->width - lp->xs * lp->ncols) / 2;
+               lp->yb = (lp->height - lp->ys * lp->nrows) / 2;
+       } else {                /* TRI */
+               int         orient, sides;
+
+               lp->black = MI_BLACK_PIXEL(mi);
+               lp->backGC = MI_GC(mi);
+               if (lp->width < 2)
+                       lp->width = 2;
+               if (lp->height < 2)
+                       lp->height = 2;
+               if (size < -MINSIZE)
+                       lp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               lp->ys = MAX(MINSIZE, MIN(lp->width, lp->height) / (4 * MINGRIDSIZE));
+                       else
+                               lp->ys = MINSIZE;
+               } else
+                       lp->ys = MIN(size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                              MINGRIDSIZE));
+               lp->xs = (int) (1.52 * lp->ys);
+               lp->ncols = (MAX(lp->width / lp->xs - 1, 2) / 2) * 2;
+               lp->nrows = (MAX(lp->height / lp->ys - 1, 2) / 2) * 2;
+               lp->xb = (lp->width - lp->xs * lp->ncols) / 2 + lp->xs / 2;
+               lp->yb = (lp->height - lp->ys * lp->nrows) / 2 + lp->ys / 2;
+               for (orient = 0; orient < 2; orient++) {
+                       for (sides = 0; sides < 3; sides++) {
+                               lp->shape.triangle[orient][sides].x =
+                                       (lp->xs - 2) * triangleUnit[orient][sides].x;
+                               lp->shape.triangle[orient][sides].y =
+                                       (lp->ys - 2) * triangleUnit[orient][sides].y;
+                       }
+               }
+       }
+       lp->npositions = lp->nrows * lp->ncols;
+
+       MI_CLEARWINDOWCOLORMAP(mi, lp->backGC, lp->black);
+       lp->painted = False;
+       alloc_cells(lp);
+
+       lp->patterned_rule = codeToPatternedRule(lp->param);
+       npats = 0;
+       switch (local_neighbors) {
+               case 6:
+                       if ((unsigned) lp->patterned_rule < LIFE_6RULES)
+                               npats = patterns_6rules[lp->patterned_rule];
+                       break;
+               case 8:
+                       if ((unsigned) lp->patterned_rule < LIFE_8RULES)
+                               npats = patterns_8rules[lp->patterned_rule];
+                       break;
+       }
+       lp->pattern = NRAND(npats + 2);
+       if (lp->pattern >= npats && !filePattern)
+               RandomSoup(mi, 30, MAX(2 * MIN(lp->nrows, lp->ncols) / 3, 15));
+       else
+               GetPattern(mi, lp->patterned_rule, lp->pattern);
+}
+
+void
+draw_life(ModeInfo * mi)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       CellList   *middle[STATES];     /* To distinguish between old and new stuff */
+       CellList   *curr;
+       cellstruct  info;
+       int         i, count, gcount;
+
+/*-
+ * LIVE list are the on cells
+ * DEAD list are the cells that may go on in the next iteration.
+ * Init plan:
+     Create live list and dead list which border all live cells
+       (no good for rules like 0000 :) )
+ * Big loop plan:
+     Setup toggles, toggle state next iteration?
+     Remove all from dead list except toggled and remove all from live list
+       that are dead (but in this case draw background square)
+     Toggle toggled states, age existing ones, create a new dead list, draw
+ */
+
+       /* Go through dead list to see if anything spawns (generate new lists),
+          then delete the used dead list */
+
+       MI_IS_DRAWN(mi) = True;
+
+       /* Setup toggles */
+       curr = lp->first[DEAD]->next;
+       while (curr != lp->last[DEAD]) {
+               count = ng_neighbors(lp, curr, &gcount);
+               if ((lp->param.birth & (1 << count)) || (count >= FIRSTGROUP &&
+                            count < FIRSTGROUP + maxgroups[neighbor_kind] &&
+                                (lp->param.birth_group[count - FIRSTGROUP] &
+                                 (1 << style6[gcount])))) {
+                       setcelltoggles(mi, (int) (curr->info.position % lp->ncols),
+                                   (int) (curr->info.position / lp->ncols));
+               }
+               curr = curr->next;
+       }
+       curr = lp->first[LIVE]->next;
+       while (curr != lp->last[LIVE]) {
+               count = ng_neighbors(lp, curr, &gcount);
+               if (!((lp->param.survival & (1 << count)) || (count >= FIRSTGROUP &&
+                            count < FIRSTGROUP + maxgroups[neighbor_kind] &&
+                             (lp->param.survival_group[count - FIRSTGROUP] &
+                              (1 << style6[gcount]))))) {
+                       setcelltoggles(mi, (int) (curr->info.position % lp->ncols),
+                                   (int) (curr->info.position / lp->ncols));
+               }
+               curr = curr->next;
+       }
+
+       /* Bring out your dead! */
+       curr = lp->first[DEAD]->next;
+       while (curr != lp->last[DEAD]) {
+               curr = curr->next;
+               if (!curr->previous->info.toggle)
+                       removefrom_list(lp, DEAD, curr->previous);
+       }
+       curr = lp->first[LIVE]->next;
+       while (curr != lp->last[LIVE]) {
+               if (curr->info.toggle) {
+                       curr->info.state = DEAD;
+                       draw_cell(mi, curr->info);
+                       curr = curr->next;
+                       removefrom_list(lp, LIVE, curr->previous);
+               } else
+                       curr = curr->next;
+       }
+
+       /* Fence off the babies */
+       info.position = -1;     /* dummy value */
+       info.age = 0;           /* dummy value */
+       addto_list(lp, DEAD, info);
+       addto_list(lp, LIVE, info);
+       middle[DEAD] = lp->last[DEAD]->previous;
+       middle[LIVE] = lp->last[LIVE]->previous;
+
+       /* Toggle toggled states, age existing ones, create a new dead list */
+       while (lp->first[DEAD]->next != middle[DEAD]) {
+               curr = lp->first[DEAD]->next;
+               setcellfromtoggle(mi, (int) (curr->info.position % lp->ncols),
+                                 (int) (curr->info.position / lp->ncols));
+       }
+       curr = lp->first[LIVE]->next;
+       while (curr != middle[LIVE]) {
+               setcellfromtoggle(mi, (int) (curr->info.position % lp->ncols),
+                                 (int) (curr->info.position / lp->ncols));
+               curr = curr->next;
+       }
+       removefrom_list(lp, DEAD, middle[DEAD]);
+       removefrom_list(lp, LIVE, middle[LIVE]);
+
+       if (lp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       CellList   *redraw_curr = lp->arr[lp->redrawpos];
+
+                       /* TODO: More efficient to use list rather than array. */
+                       if (redraw_curr && redraw_curr->info.state == LIVE) {
+                               draw_cell(mi, redraw_curr->info);
+                       }
+                       if (++(lp->redrawpos) >= lp->npositions) {
+                               lp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+       if (++lp->generation > MI_CYCLES(mi))
+               init_life(mi);
+       else
+               lp->painted = True;
+
+       /*
+        * generate a randomized shooter aimed roughly toward the center of the
+        * screen after batchcount.
+        */
+
+       if (lp->generation && lp->generation %
+           ((MI_COUNT(mi) < 0) ? 1 : MI_COUNT(mi)) == 0)
+               shooter(mi);
+
+}
+
+void
+release_life(ModeInfo * mi)
+{
+       if (lifes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       lifestruct *lp = &lifes[screen];
+                       int         state;
+
+                       for (state = 0; state < STATES; state++) {
+                               if (lp->first[0])
+                                       flush_list(lp, state);
+                               if (lp->last[state])
+                                       (void) free((void *) lp->last[state]);
+                               if (lp->first[state])
+                                       (void) free((void *) lp->first[state]);
+                       }
+                       free_cells(lp);
+                       free_stuff(MI_DISPLAY(mi), lp);
+               }
+               (void) free((void *) lifes);
+               lifes = NULL;
+       }
+}
+
+void
+refresh_life(ModeInfo * mi)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+
+       if (lp->painted) {
+               MI_CLEARWINDOWCOLORMAP(mi, lp->backGC, lp->black);
+               lp->redrawing = 1;
+               lp->redrawpos = 0;
+               lp->painted = False;
+       }
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+        /* This is needed when another program changes the colormap. */
+       free_stuff(MI_DISPLAY(mi), lp);
+       init_stuff(mi);
+#endif
+}
+
+void
+change_life(ModeInfo * mi)
+{
+       lifestruct *lp = &lifes[MI_SCREEN(mi)];
+       int         npats, i;
+
+       lp->generation = 0;
+       if (lp->first[0])
+               for (i = 0; i < STATES; i++)
+                       flush_list(lp, i);
+       else
+               for (i = 0; i < STATES; i++)
+                       init_list(lp, i);
+       free_cells(lp);
+       alloc_cells(lp);
+
+       MI_CLEARWINDOWCOLORMAP(mi, lp->backGC, lp->black);
+
+       lp->pattern++;
+       lp->patterned_rule = codeToPatternedRule(lp->param);
+       npats = 0;
+       switch (local_neighbors) {
+               case 6:
+                       if ((unsigned) lp->patterned_rule < LIFE_6RULES)
+                               npats = patterns_6rules[lp->patterned_rule];
+                       break;
+               case 8:
+                       if ((unsigned) lp->patterned_rule < LIFE_8RULES)
+                               npats = patterns_8rules[lp->patterned_rule];
+                       break;
+       }
+       if (lp->pattern >= npats + 2) {
+               lp->pattern = 0;
+               if (allPatterns) {
+                       lp->patterned_rule++;
+                       switch (local_neighbors) {
+                               case 6:
+                                       if ((unsigned) lp->patterned_rule >= LIFE_6RULES)
+                                               lp->patterned_rule = 0;
+                                       break;
+                               case 8:
+                                       if ((unsigned) lp->patterned_rule >= LIFE_8RULES)
+                                               lp->patterned_rule = 0;
+                                       break;
+                       }
+                       copyFromPatternedRule(&lp->param, lp->patterned_rule);
+                       if (MI_IS_VERBOSE(mi))
+                               printRule(lp->param);
+               } else if (allGliders) {
+                       lp->patterned_rule++;
+                       switch (local_neighbors) {
+                               case 6:
+                                       if ((unsigned) lp->patterned_rule >= LIFE_6GLIDERS)
+                                               lp->patterned_rule = 0;
+                                       break;
+                               case 8:
+                                       if ((unsigned) lp->patterned_rule >= LIFE_8GLIDERS)
+                                               lp->patterned_rule = 0;
+                                       break;
+                       }
+                       copyFromPatternedRule(&lp->param, lp->patterned_rule);
+                       if (MI_IS_VERBOSE(mi))
+                               printRule(lp->param);
+               }
+       }
+       if (lp->pattern >= npats)
+               RandomSoup(mi, 30, MAX(2 * MIN(lp->nrows, lp->ncols) / 3, 15));
+       else
+               GetPattern(mi, lp->patterned_rule, lp->pattern);
+}
+
+#endif /* MODE_life */
diff --git a/xlockmore-4.14/modes/life1d.c b/xlockmore-4.14/modes/life1d.c
new file mode 100644 (file)
index 0000000..1d4e419
--- /dev/null
@@ -0,0 +1,856 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* life1d --- Stephen Wolfram's 1d game of Life */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)life1d.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 27-Oct-97: xpm and ras capability added... it does not make too much
+ *              sense here but ...
+ * 10-May-97: Compatible with xscreensaver
+ * 27-Jul-95: written, used life.c as a basis, using totalistic rules
+ *            (default).  Special thanks to Harold V. McIntosh
+ *            <mcintosh@servidor.unam.mx> for providing me with the
+ *            LCAU collection and references.
+ *
+ * References:
+ * Dewdney, A.K., "The Armchair Universe, Computer Recreations from the
+ *   Pages of Scientific American Magazine", W.H. Freedman and Company,
+ *   New York, 1988 (May 1985).
+ * Perry, Kenneth E., "Abstract Mathematical Art", BYTE, December, 1986
+ *   pp. 181-192
+ * Hayes, Brian, "Computer Recreations", Scientific American, March 1984,
+ *   p. 12
+ * Wolfram, Stephen, "Cellular automata as models of complexity", Nature,
+ *   4 October 1984, pp. 419-424
+ * Wolfram, Stephen, "Computer Software in Science and Mathematics",
+ *   Scientific American, September 1984, pp. 188-203
+ *
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Life1D"
+#define HACK_INIT init_life1d
+#define HACK_DRAW draw_life1d
+#define life1d_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*cycles: 10 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 200 \n" \
+ "*bitmap: \n" \
+ "*verbose: \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+#include "automata.h"
+#include "iostuff.h"
+
+#ifdef MODE_life1d
+
+#define DEF_TOTALISTIC  "True" /* FALSE is LCAU */
+
+static Bool totalistic;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-totalistic", ".life1d.totalistic", XrmoptionNoArg, (caddr_t) "on"},
+       {"+totalistic", ".life1d.totalistic", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+{(caddr_t *) & totalistic, "totalistic", "Totalistic", DEF_TOTALISTIC, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+totalistic", "turn on/off totalistic rules (else LCAU rules)"}
+};
+
+ModeSpecOpt life1d_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   life1d_description =
+{"life1d", "init_life1d", "draw_life1d", "release_life1d",
+ "refresh_life1d", "init_life1d", NULL, &life1d_opts,
+ 10000, 1, 10, 0, 64, 1.0, "",
+ "Shows Wolfram's game of 1D Life", 0, NULL};
+
+#endif
+
+#define LIFE1DBITS(n,w,h)\
+  lp->pixmaps[lp->init_bits++]=\
+  XCreatePixmapFromBitmapData(display,window,(char *)n,w,h,1,0,1)
+
+/* aliases for vars defined in the bitmap file */
+#define CELL_WIDTH   image_width
+#define CELL_HEIGHT    image_height
+#define CELL_BITS    image_bits
+
+#include "life1d.xbm"
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+static char *image_name[] =
+{""};
+
+#define CELL_NAME image_name
+#define DEFAULT_XPM 0
+#endif
+
+static int  maxstates;
+static int  maxradius;
+static int  maxsum_size;
+
+#define MINGRIDSIZE 10
+#define MINSIZE 2              /* 3 may be better here */
+#define REPEAT 24
+#define MAXSTATES 5
+
+typedef struct {
+       int         init_bits;
+       int         pixelmode;
+       int         xs, ys, xb, yb;     /* cell size, grid border */
+       int         screen_generation, row;
+       int         nrows, ncols, border;
+       int         width, height;
+       int         k, r;
+       long        code;
+       int         repeating;
+       char       *nextstate;
+       int         colors[MAXSTATES];
+       Pixmap      pixmaps[MAXSTATES];
+       GC          stippledGC;
+       unsigned char *newcells;
+       unsigned char *oldcells;
+       unsigned char *buffer;
+       XImage     *logo;
+       Colormap    cmap;
+       unsigned long black;
+       int         graphics_format;
+       GC          backGC;
+       int         busyLoop;
+} life1dstruct;
+
+static life1dstruct *life1ds = NULL;
+
+static int  totalistic_rules[][3] =
+{
+
+  /* Well behaved rules */
+  /* Scientific American (Dewdney) */
+       {2, 2, 20},
+       {2, 2, 52},             /* A bit too prolific but I like it anyway */
+       {2, 3, 88},             /* James K. Park's 1D Gun (1111111111011) */
+       {2, 4, 368},
+
+  /* Nature */
+       {3, 1, 792},
+
+  /* BYTE (Translated to Wolfram's notation) */
+       {4, 1, 39744},
+       {4, 1, 81036},
+       {4, 1, 126092},
+       {4, 1, 147824},
+       {4, 1, 156272},
+       {4, 1, 189468},
+       {4, 1, 176412},
+       {4, 1, 214840},
+       {4, 1, 245028},
+       {4, 1, 267320},
+       {4, 1, 257808},
+       {4, 1, 258596},
+       {4, 1, 260224},
+       {4, 1, 267408},
+       {4, 1, 290960},
+       {4, 1, 330056},
+       {4, 1, 330436},
+       {4, 1, 400192},
+       {4, 1, 433296},
+       {4, 1, 434492},
+       {4, 1, 447368},
+       {4, 1, 453768},
+       {4, 1, 454416},
+       {4, 1, 485488},
+       {4, 1, 505904},
+       {4, 1, 618960},
+       {4, 1, 642948},
+       {4, 1, 680528},
+       {4, 1, 708484},
+       {4, 1, 741004},
+       {4, 1, 749708},
+       {4, 1, 756420},
+       {4, 1, 761356},
+       {4, 1, 769088},
+       {4, 1, 778568},
+       {4, 1, 779792},
+       {4, 1, 797456},
+       {4, 1, 803728},
+       {4, 1, 844092},
+       {4, 1, 874524},
+       {4, 1, 881440},
+       {4, 1, 921476},
+       {4, 1, 936832},
+       {4, 1, 937792},
+       {4, 1, 1004600},
+
+  /* Nature */
+       {5, 1, 580020},
+       {5, 1, 5694390},
+       {5, 1, 59123000},
+
+#if 0                          /* OK but annoying */
+
+  /* BYTE */
+       {4, 1, 10552},
+       {4, 1, 14708},
+       {4, 1, 25284},
+       {4, 1, 42848},
+       {4, 1, 44328},
+       {4, 1, 51788},
+       {4, 1, 107364},
+       {4, 1, 111448},
+       {4, 1, 155848},
+       {4, 1, 173024},
+       {4, 1, 224148},
+       {4, 1, 238372},
+       {4, 1, 241656},
+       {4, 1, 243764},
+       {4, 1, 255856},
+       {4, 1, 259222},
+       {4, 1, 310148},
+       {4, 1, 324148},
+       {4, 1, 346696},
+       {4, 1, 364424},
+       {4, 1, 403652},
+       {4, 1, 436072},
+       {4, 1, 456708},
+       {4, 1, 461912},
+       {4, 1, 534812},
+       {4, 1, 546700},
+       {4, 1, 552708},
+       {4, 1, 569092},
+       {4, 1, 616736},
+       {4, 1, 658564},
+       {4, 1, 717956},
+       {4, 1, 748432},
+       {4, 1, 800964},
+       {4, 1, 800972},
+       {4, 1, 801144},
+       {4, 1, 821116},
+       {4, 1, 840172},
+       {4, 1, 858312},
+       {4, 1, 865394},
+       {4, 1, 914952},
+       {4, 1, 919244},
+       {4, 1, 984296},
+       {4, 1, 997964},
+       {4, 1, 1018488},
+       {4, 1, 1018808},
+       {4, 1, 1023864},
+       {4, 1, 1024472},
+       {4, 1, 1033776},
+       {4, 1, 1033784},
+       {4, 1, 1034552},
+
+  /* Nature */
+       {5, 1, 583330},
+       {5, 1, 672900},
+#endif
+
+#if 0                          /* rejects */
+  /* Nature */
+       {2, 1, 4},
+       {2, 3, 18},
+       {2, 3, 22},
+       {2, 3, 90},
+       {2, 3, 94},
+       {2, 3, 126},
+       {2, 3, 128},
+
+  /* Scientific American (Dewdney) */
+       {2, 3, 54},
+       {3, 2, 66},             /* RIPPLE, Dewdney's personal 1d rule */
+       {3, 1, 257},
+
+  /* BYTE */
+       {4, 1, 16},
+       {4, 1, 56},
+       {4, 1, 4408},
+       {4, 1, 101988},
+       {4, 1, 113688},
+       {4, 1, 227892},
+       {4, 1, 254636},
+       {4, 1, 258598},
+       {4, 1, 294146},
+       {4, 1, 377576},
+       {4, 1, 472095},
+       {4, 1, 538992},
+       {4, 1, 615028},
+       {4, 1, 901544},
+       {4, 1, 911876},
+
+  /* Nature */
+       {5, 1, 10175},
+       {5, 1, 566780},
+       {5, 1, 570090},
+#endif
+};
+
+#define TOTALISTICRULES (sizeof totalistic_rules / sizeof totalistic_rules[0])
+
+#if 0
+static char lcau21_rules[][9] =
+{
+       "00010010",             /* 18 Hollow enlarging triangles */
+       "00110110",             /* 54 Hollow triangles */
+       "01101110",             /* 110 Hollow right triangles */
+       "01111100",             /* 124 Hollow left triangles */
+       "10010011",             /* 147 Solid triangles */
+       "10001001",             /* 137 Solid right triangles */
+       "11000001",             /* 193 Solid left triangles */
+};
+
+#define LCAU2RULES (sizeof lcau21_rules / sizeof lcau21_rules[0])
+#endif
+
+static char lcau31_rules[][28] =
+{
+       "000222111000111222222111000",  /* equal thirds */
+       "002220210110110211110002200",  /* threads on triangles */
+       "001121102222110110111002100",  /* interfaces of 2 vel */
+       "020201010201010102010102020",  /* class iv, sparse */
+       "020201011201011112011112120",  /* blue bground class iv */
+       "021211110211110101110101020",  /* diagonal black gaps */
+       "022221211221211012222111120",  /* macrocell w/ 012 membrane */
+       "100002021002021210021210100",  /* totalistic rule 792 (iv) */
+       "100002200112201200020121200",  /* binary counter */
+       "101021220111100222112102020",  /* two patterns compete #1 */
+       "110001000112221222112221000",  /* reversible rule */
+       "111012101002110122121102120",  /* small blue triangles */
+       "111021210012110202120212122",  /* 2 glider on 1 background */
+       "111111101010202020202010101",  /* motes and triangles */
+       "111220012222012120001221020",  /* black triangles */
+       "112110201012001210101200010",  /* dendrites */
+       "112122000000122112112122000",  /* reversible rule's reverse */
+       "200211020111110002001101210",  /* crocodile skin */
+       "202000200112001200120211100",  /* two slow gliders collide */
+       "202211000201021001100200200",  /* Red Queen's binary counter */
+       "210101012101012120012120200",  /* blue on red background */
+       "212021022100200221201101020",  /* two patterns compete #2 */
+       "220222010220211111000211010",  /* Fisch's cyclic eater */
+       "222022001222211202022120012",  /* macrocell w/ 0122 membrane */
+};
+
+#define LCAU3RULES (sizeof lcau31_rules / sizeof lcau31_rules[0])
+
+static char lcau41_rules[][65] =
+{
+       "0000000313131323232312121213232323231313131101010202020202010101",     /* skewed triangle */
+       "0000020202000000020232220203300000000101020030000100322121003020",     /* slow glider - copies bar */
+       "0000213323132331123303003213323113233123002033211332313233120001",     /* slightly chaotic symmetri */
+       "0000332030033323010020122303001002120210000000100110020220000010",     /* shuttle squeeze */
+       "0100030000030323200323120202001003000203000220001310220100200010",     /* coo gldrs */
+       "0121200113213320110223311213201013131010111011101120012132103210",     /* mixture of types */
+       "0212301103023320313223121332310023203323333231301020023120303020",     /* slo gl w/ many f gl */
+       "0320032100113332112321213211003321233210121032320000321000010200",     /* crosshatching */
+       "0323323323313310323323313310310223313310310210213310310210210210",     /* Perry's 245028 */
+       "0323330023210000121122232322122113310131032101002110122321102120",     /*  */
+       "0332200131100112230221012111210202022013210332120210222311212100",     /* cycles on dgl bgrnd */
+       "0332200131100112230221012111210202022013210332120210222311212300",     /* cycles on dgl bgrnd */
+       "1230320301231030321132211021112010202330101010112312220310311000",     /* very complex glider */
+       "1230320301321030321132211021112010212121232212112312220310311000",     /* nice cross hatching */
+       "2031122112031101123123233000321210301112010303203232213000311000",     /* gliders among stills */
+       "2202003300010200010011010011020003033000032302002203110033010200",     /* bin ctr */
+       "2313032202112320111221023212120203132000233322021310311101010030",     /* diagonal growth on mesh */
+       "2332102112210200233210120311023110322213112123233132331213211212",     /* gliderettes & latice */
+       "3000213323132331123302003213323113233123001033211332313233120000",     /* symmetric rule */
+       "3003003203213211003203213211211303213211211311323211211311321320",     /* Perry's blue background */
+       "3010213223113300321221011010123112301033010221203333211323110100",     /* v. bars w/entanglement */
+       "3111213323132331123313113213323113233123220133211332313233121110",     /* not purely symmetric */
+       "3112001202313030102330122003321023102122030102001210223122203020",     /* slow & fast gliders */
+       "3130123232333201012202313210121032302200211020313130002001103210",     /* crocodile skin */
+       "3230120202031130033311232111223012311113322032103210123012303210",     /* y/o on b/g */
+       "3330333312110010333032222222001033303222121111110000322212110010",     /* Fisch's rule */
+       "3332032303133100221122122213220022000212021022100200221203103020",     /* slow glider */
+       "3333101022220101323201012323101033331010222201013232010123231010",     /* reverse of rvble #22 */
+       "3333111122000022333311112200002233111133002222003311113300222200",     /* reversible Rule 22 */
+};
+
+#define LCAU4RULES (sizeof lcau41_rules / sizeof lcau41_rules[0])
+
+#ifdef LCAU2RULES
+#define LCAURULES (LCAU2RULES + LCAU3RULES + LCAU4RULES)
+#else
+#define LCAURULES (LCAU3RULES + LCAU4RULES)
+#endif
+
+static void
+drawcell(ModeInfo * mi, int col, int row, unsigned int state)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       life1dstruct *lp = &life1ds[MI_SCREEN(mi)];
+       GC          gc = lp->backGC;
+
+       if (!state) {
+               XSetForeground(display, gc, lp->black);
+               XFillRectangle(display, window, gc,
+               lp->xb + lp->xs * col, lp->yb + lp->ys * row, lp->xs, lp->ys);
+               return;
+       }
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, lp->colors[state - 1]));
+       if (lp->pixelmode || (MI_NPIXELS(mi) <= 2)) {
+               if (MI_NPIXELS(mi) <= 2) {
+                       XGCValues   gcv;
+
+                       gcv.stipple = lp->pixmaps[state - 1];
+                       gcv.foreground = MI_WHITE_PIXEL(mi);
+                       gcv.background = lp->black;
+                       gcv.fill_style = FillOpaqueStippled;
+                       XChangeGC(display, lp->stippledGC,
+                                 GCStipple | GCFillStyle | GCForeground | GCBackground, &gcv);
+                       XFillRectangle(display, window, lp->stippledGC,
+                                      lp->xb + lp->xs * col, lp->yb + lp->ys * row, lp->xs, lp->ys);
+               } else
+                       XFillRectangle(display, window, gc,
+                                      lp->xb + lp->xs * col, lp->yb + lp->ys * row, lp->xs, lp->ys);
+       } else {
+               (void) XPutImage(display, window, gc,
+               lp->logo, 0, 0, lp->xb + lp->xs * col, lp->yb + lp->ys * row,
+                                lp->logo->width, lp->logo->height);
+       }
+}
+
+static void
+RandomSoup(life1dstruct * lp, int n, int v)
+{
+       int         col;
+
+       v /= 2;
+       if (v < 1)
+               v = 1;
+       for (col = lp->ncols / 2 - v; col < lp->ncols / 2 + v; ++col)
+               if (NRAND(100) < n && col >= 0 && col < lp->ncols)
+                       lp->newcells[col + lp->border] = (unsigned char) NRAND(lp->k - 1) + 1;
+}
+
+static long
+power(int x, int n)
+{                              /* raise x to the nth power n >= 0 */
+       int         i;
+       long        p = 1;
+
+       for (i = 1; i <= n; ++i)
+               p = p * x;
+       return p;
+}
+
+static void
+GetRule(life1dstruct * lp, int i)
+{
+       long        sum_size, j;
+
+       if (totalistic) {
+               long        code, pow_size;
+
+               lp->k = totalistic_rules[i][0];
+               lp->r = totalistic_rules[i][1];
+               sum_size = (lp->k - 1) * (lp->r * 2 + 1) + 1;
+               code = lp->code = totalistic_rules[i][2];
+
+               pow_size = power(lp->k, (int) (sum_size - 1));  /* Should be < max long */
+               for (j = 0; j < sum_size; j++) {
+                       lp->nextstate[sum_size - 1 - j] = (char) (code / pow_size);
+                       code -= ((long) lp->nextstate[sum_size - 1 - j]) * pow_size;
+                       pow_size /= (long) lp->k;
+               }
+       } else {
+               lp->r = 1;
+#ifdef LCAU2RULES
+               if (i < (int) LCAU2RULES) {
+                       lp->k = 2;
+                       sum_size = power(lp->k, 2 * lp->r + 1);
+                       for (j = 0; j < sum_size; j++)
+                               lp->nextstate[sum_size - 1 - j] = lcau21_rules[i][j] - '0';
+               } else if (i < LCAU2RULES + LCAU3RULES)
+#else
+               if (i < (int) LCAU3RULES)
+#endif
+               {
+                       lp->k = 3;
+                       sum_size = power(lp->k, 2 * lp->r + 1);
+#ifdef LCAU2RULES
+                       i -= LCAU2RULES;
+#endif
+                       for (j = 0; j < sum_size; j++)
+                               lp->nextstate[sum_size - 1 - j] = lcau31_rules[i][j] - '0';
+               } else {
+                       lp->k = 4;
+                       sum_size = power(lp->k, 2 * lp->r + 1);
+#ifdef LCAU2RULES
+                       i -= (LCAU2RULES + LCAU3RULES);
+#else
+                       i -= LCAU3RULES;
+#endif
+                       for (j = 0; j < sum_size; j++)
+                               lp->nextstate[sum_size - 1 - j] = lcau41_rules[i][j] - '0';
+               }
+       }
+}
+
+/* The following sometimes does not detect when there are multiple periodic
+   life forms side by side. */
+static int
+compare(ModeInfo * mi)
+{
+       life1dstruct *lp = &life1ds[MI_SCREEN(mi)];
+       int         row, col, tryagain = False;
+       unsigned char *initl, *cmpr;
+
+       initl = lp->buffer + lp->row * lp->ncols;
+       for (row = lp->row - 1; row >= 0; row--) {
+               cmpr = lp->buffer + row * lp->ncols;
+               for (col = 0; col < lp->ncols; col++) {
+                       tryagain = False;
+                       if (*(initl + col) != *cmpr) {
+                               tryagain = True;
+                               break;
+                       }
+                       cmpr++;
+               }
+               if (!tryagain)
+                       return True;
+       }
+       return False;
+}
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       life1dstruct *lp = &life1ds[MI_SCREEN(mi)];
+
+       if (!lp->logo)
+               getImage(mi, &lp->logo, CELL_WIDTH, CELL_HEIGHT, CELL_BITS,
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                        DEFAULT_XPM, CELL_NAME,
+#endif
+                        &lp->graphics_format, &lp->cmap, &lp->black);
+#ifndef STANDALONE
+       if (lp->cmap != None) {
+               setColormap(display, window, lp->cmap, MI_IS_INWINDOW(mi));
+               if (lp->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = lp->black;
+                       lp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else
+#endif /* STANDALONE */
+       {
+               lp->black = MI_BLACK_PIXEL(mi);
+               lp->backGC = MI_GC(mi);
+       }
+}
+
+static void
+free_stuff(Display * display, life1dstruct * lp)
+{
+       if (lp->cmap != None) {
+               XFreeColormap(display, lp->cmap);
+               if (lp->backGC != None) {
+                       XFreeGC(display, lp->backGC);
+                       lp->backGC = None;
+               }
+               lp->cmap = None;
+       } else
+               lp->backGC = None;
+       destroyImage(&lp->logo, &lp->graphics_format);
+}
+
+void
+init_life1d(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         size = MI_SIZE(mi);
+       life1dstruct *lp;
+       int         i;
+
+       if (life1ds == NULL) {
+               if ((life1ds = (life1dstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (life1dstruct))) == NULL)
+                       return;
+       }
+       lp = &life1ds[MI_SCREEN(mi)];
+
+       init_stuff(mi);
+
+       lp->screen_generation = 0;
+       lp->row = 0;
+
+       if (totalistic) {
+               maxstates = MAXSTATES;
+               maxradius = 4;
+               maxsum_size = (maxstates - 1) * (maxradius * 2 + 1) + 1;
+       } else {
+               maxstates = MAXSTATES - 1;
+               maxradius = 1;
+               maxsum_size = (int) power(maxstates, (2 * maxradius + 1));
+       }
+       if (lp->nextstate == NULL)
+               lp->nextstate = (char *) malloc(maxsum_size * sizeof (char));
+
+       if (lp->init_bits == 0) {
+               XGCValues   gcv;
+
+               gcv.fill_style = FillOpaqueStippled;
+               lp->stippledGC = XCreateGC(display, window, GCFillStyle, &gcv);
+               for (i = 0; i < MAXSTATES - 1; i++)
+                       LIFE1DBITS(stipples[i + NUMSTIPPLES - MAXSTATES + 1],
+                                  STIPPLESIZE, STIPPLESIZE);
+               LIFE1DBITS(stipples[NUMSTIPPLES / 2],
+                          STIPPLESIZE, STIPPLESIZE);   /* grey */
+       }
+       if (lp->newcells != NULL)
+               (void) free((void *) lp->newcells);
+       if (lp->oldcells != NULL)
+               (void) free((void *) lp->oldcells);
+       if (lp->buffer != NULL)
+               (void) free((void *) lp->buffer);
+       lp->width = MI_WIDTH(mi);
+       lp->height = MI_HEIGHT(mi);
+       if (lp->width < 2)
+               lp->width = 2;
+       if (lp->height < 2)
+               lp->height = 2;
+       if (size == 0 ||
+        MINGRIDSIZE * size > lp->width || MINGRIDSIZE * size > lp->height) {
+               if (lp->width > MINGRIDSIZE * lp->logo->width &&
+                   lp->height > MINGRIDSIZE * lp->logo->height) {
+                       lp->pixelmode = False;
+                       lp->xs = lp->logo->width;
+                       lp->ys = lp->logo->height;
+               } else {
+                       lp->pixelmode = True;
+                       lp->xs = lp->ys = MAX(MINSIZE, MIN(lp->width, lp->height) / MINGRIDSIZE);
+               }
+       } else {
+               lp->pixelmode = True;
+               if (size < -MINSIZE)
+                       lp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE)
+                       lp->ys = MINSIZE;
+               else
+                       lp->ys = MIN(size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                              MINGRIDSIZE));
+               lp->xs = lp->ys;
+       }
+       lp->ncols = MAX(lp->width / lp->xs, 2);
+       lp->nrows = MAX(lp->height / lp->ys, 2);
+       lp->border = (lp->nrows / 2 + 1) * MI_CYCLES(mi);
+       lp->newcells = (unsigned char *) calloc(lp->ncols + 2 * lp->border,
+                                               sizeof (unsigned char));
+
+       lp->oldcells = (unsigned char *) calloc(lp->ncols +
+                      2 * (maxradius + lp->border), sizeof (unsigned char));
+
+       lp->buffer = (unsigned char *) calloc(lp->ncols * lp->nrows,
+                                             sizeof (unsigned char));
+
+       lp->xb = (lp->width - lp->xs * lp->ncols) / 2;
+       lp->yb = (lp->height - lp->ys * lp->nrows) / 2;
+
+       GetRule(lp, (int) NRAND((totalistic) ? TOTALISTICRULES : LCAURULES));
+       if (MI_IS_VERBOSE(mi)) {
+               (void) fprintf(stdout, "colors %d, radius %d, code %ld, ",
+                              lp->k, lp->r, lp->code);
+               if (totalistic) {
+                       (void) fprintf(stdout, "totalistic rule ");
+                       for (i = (lp->k - 1) * (lp->r * 2 + 1); i >= 0; i--)
+                               (void) fprintf(stdout, "%d", (int) lp->nextstate[i]);
+               } else {
+                       (void) fprintf(stdout, "LCAU rule ");
+                       for (i = (int) power(lp->k, (lp->r * 2 + 1)); i >= 0; i--)
+                               (void) fprintf(stdout, "%d", (int) lp->nextstate[i]);
+               }
+               (void) fprintf(stdout, "\n");
+       }
+       if (MI_NPIXELS(mi) > 2)
+               for (i = 0; i < lp->k - 1; i++)
+                       lp->colors[i] = (NRAND(MI_NPIXELS(mi)) + i * MI_NPIXELS(mi)) /
+                               (lp->k - 1);
+       RandomSoup(lp, 40, 25);
+       (void) memcpy((char *) (lp->oldcells + maxradius + lp->border),
+                     (char *) (lp->newcells + lp->border), lp->ncols);
+       lp->busyLoop = 0;
+
+       MI_CLEARWINDOWCOLORMAP(mi, lp->backGC, lp->black);
+}
+
+void
+draw_life1d(ModeInfo * mi)
+{
+       life1dstruct *lp = &life1ds[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       int         col;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (lp->busyLoop) {
+               if (lp->busyLoop >= 250)
+                       lp->busyLoop = 0;
+               else
+                       lp->busyLoop++;
+               return;
+       }
+       if (lp->row == 0) {
+               lp->repeating = 0;
+               if (lp->screen_generation > MI_CYCLES(mi))
+                       init_life1d(mi);
+
+               for (col = 0; col < lp->ncols; col++)
+                       if (lp->buffer[col] != lp->newcells[col + lp->border])
+                               drawcell(mi, col, 0, lp->newcells[col + lp->border]);
+               (void) memcpy((char *) lp->buffer, (char *) (lp->newcells + lp->border),
+                             lp->ncols);
+       } else {
+               for (col = 0; col < lp->ncols + 2 * lp->border; col++) {
+                       int         sum = 0, m;
+
+                       if (totalistic) {
+                               for (m = col - lp->r; m <= col + lp->r; m++)
+                                       sum += lp->oldcells[m + maxradius];
+                       } else {
+                               int         pow_size = 1;
+
+                               for (m = col + lp->r; m >= col - lp->r; m--) {
+                                       sum += lp->oldcells[m + maxradius] * pow_size;
+                                       pow_size *= lp->k;
+                               }
+                       }
+                       lp->newcells[col] = (unsigned char) lp->nextstate[sum];
+               }
+               (void) memcpy((char *) (lp->oldcells + maxradius),
+                         (char *) lp->newcells, lp->ncols + 2 * lp->border);
+
+               for (col = 0; col < lp->ncols; col++) {
+                       if (lp->buffer[col + lp->row * lp->ncols] !=
+                           lp->newcells[col + lp->border])
+                               drawcell(mi, col, lp->row, lp->newcells[col + lp->border]);
+               }
+               (void) memcpy((char *) (lp->buffer + lp->row * lp->ncols),
+                           (char *) (lp->newcells + lp->border), lp->ncols);
+               {
+                       int         temp = compare(mi);
+
+                       if (temp)
+                               lp->repeating += temp;
+                       else
+                               lp->repeating = 0;
+               }
+               lp->repeating += (lp->row == lp->nrows - 1) ? REPEAT * compare(mi) : 0;
+       }
+       if (lp->repeating >= 1) {
+               XGCValues   gcv;
+
+               gcv.stipple = lp->pixmaps[MAXSTATES - 1];
+               gcv.fill_style = FillStippled;
+               gcv.foreground = lp->black;
+               XChangeGC(MI_DISPLAY(mi), lp->stippledGC,
+                         GCStipple | GCFillStyle | GCForeground, &gcv);
+               XFillRectangle(display, MI_WINDOW(mi), lp->stippledGC,
+                              0, lp->yb + lp->ys * lp->row,
+                              lp->width, lp->ys);
+       }
+       lp->row++;
+       if (lp->repeating >= REPEAT) {
+               if (lp->row < lp->nrows) {
+                       XSetForeground(display, lp->backGC, lp->black);
+                       XFillRectangle(display, MI_WINDOW(mi), lp->backGC,
+                                      0, lp->yb + lp->ys * lp->row,
+                         lp->width, lp->height - lp->ys * lp->row - lp->yb);
+               }
+               lp->screen_generation = MI_CYCLES(mi);
+               lp->row = lp->nrows;
+       }
+       if (lp->row >= lp->nrows) {
+               lp->screen_generation++;
+               lp->busyLoop = 1;
+               lp->row = 0;
+       }
+}
+
+void
+release_life1d(ModeInfo * mi)
+{
+       if (life1ds != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       life1dstruct *lp = &life1ds[screen];
+                       int         shade;
+
+                       if (lp->stippledGC != NULL) {
+                               XFreeGC(MI_DISPLAY(mi), lp->stippledGC);
+                       }
+                       if (lp->init_bits != 0) {
+                               for (shade = 0; shade < MAXSTATES; shade++)
+                                       XFreePixmap(MI_DISPLAY(mi), lp->pixmaps[shade]);
+                       }
+                       if (lp->newcells != NULL)
+                               (void) free((void *) lp->newcells);
+                       if (lp->oldcells != NULL)
+                               (void) free((void *) lp->oldcells);
+                       if (lp->buffer != NULL)
+                               (void) free((void *) lp->buffer);
+                       if (lp->nextstate != NULL)
+                               (void) free((void *) lp->nextstate);
+                       free_stuff(MI_DISPLAY(mi), lp);
+               }
+               (void) free((void *) life1ds);
+               life1ds = NULL;
+       }
+}
+
+void
+refresh_life1d(ModeInfo * mi)
+{
+       life1dstruct *lp = &life1ds[MI_SCREEN(mi)];
+       int         row, col, nrow;
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       /* This is needed when another program changes the colormap. */
+       free_stuff(MI_DISPLAY(mi), lp);
+       init_stuff(mi);
+#endif
+
+       for (row = 0; row < lp->nrows; row++) {
+               nrow = row * lp->ncols;
+               for (col = 0; col < lp->ncols; col++)
+                       drawcell(mi, col, row, lp->buffer[col + nrow]);
+       }
+}
+
+#endif /* MODE_life1d */
diff --git a/xlockmore-4.14/modes/life3d.c b/xlockmore-4.14/modes/life3d.c
new file mode 100644 (file)
index 0000000..8218d10
--- /dev/null
@@ -0,0 +1,2320 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* life3d --- Extension to Conway's game of Life, Carter Bays' S45/B5 3d life */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)life3d.c     4.07 98/01/18 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1994 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 18-Apr-97: Memory leak fixed by Tom Schmidt <tschmidt@micron.com>
+ * 12-Mar-95: added LIFE_S567B6 compile-time option
+ * 12-Feb-95: shooting gliders added
+ * 07-Dec-94: used life.c and a DOS version of 3dlife
+ * Copyright 1993 Anthony Wesley awesley@canb.auug.org.au found at
+ * life.anu.edu.au /pub/complex_systems/alife/3DLIFE.ZIP
+ * There is some flashing that was not in the original.  This is because 
+ * the direct video memory access garbage collection was not portable.
+ *
+ *
+ * References:
+ * Dewdney, A.K., "The Armchair Universe, Computer Recreations from the
+ *   Pages of Scientific American Magazine", W.H. Freedman and Company,
+ *   New York, 1988 (February 1987 p 16)
+ * Bays, Carter, "The Game of Three Dimensional Life", 86/11/20
+ *   with (latest?) update from 87/2/1
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Life3D"
+#define HACK_INIT init_life3d
+#define HACK_DRAW draw_life3d
+#define life3d_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000000 \n" \
+ "*count: 35 \n" \
+ "*cycles: 85 \n" \
+ "*ncolors: 200 \n" \
+ "*wireframe: False \n" \
+ "*fullrandom: False \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_life3d
+
+#if 1
+#define DEF_RULE  "G"          /* All rules with gliders */
+#else
+#define DEF_RULE  "P"          /* All rules with known patterns */
+#define DEF_RULE  "S45/B5"     /* "B5/S45" */
+#define DEF_RULE  "S567/B6"    /* "B6/S567" */
+/* There are no known gliders for S56/B5 or S67/B67 */
+#endif
+
+static char *rule;
+static char *lifefile;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-rule", ".life3d.rule", XrmoptionSepArg, (caddr_t) NULL},
+       {"-lifefile", ".life3d.lifefile", XrmoptionSepArg, (caddr_t) NULL}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & rule, "rule", "Rule", DEF_RULE, t_String},
+       {(caddr_t *) & lifefile, "lifefile", "LifeFile", "", t_String}
+};
+static OptionStruct desc[] =
+{
+       {"-rule string", "S<survial_neighborhood>/B<birth_neighborhood> parameters"},
+       {"-lifefile file", "life file"},
+};
+
+ModeSpecOpt life3d_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   life3d_description =
+{"life3d", "init_life3d", "draw_life3d", "release_life3d",
+ "refresh_life3d", "change_life3d", NULL, &life3d_opts,
+ 1000000, 35, 85, 1, 64, 1.0, "",
+ "Shows Bays' game of 3D Life", 0, NULL};
+
+#endif
+
+#define ON 0x40
+#define OFF 0
+
+/* Don't change these numbers without changing the offset() macro below! */
+#define MAXSTACKS 64
+#define        MAXROWS 128
+#define MAXCOLUMNS 128
+#define BASESIZE ((MAXCOLUMNS*MAXROWS*MAXSTACKS)>>6)
+
+#define RT_ANGLE 90
+#define HALFRT_ANGLE 45
+#define MAXNEIGHBORS 27
+
+/* Store state of cell in top bit. Reserve low bits for count of living nbrs */
+#define Set3D(x,y,z) SetMem(lp,(unsigned int)x,(unsigned int)y,(unsigned int)z,ON)
+#define Reset3D(x,y,z) SetMem(lp,(unsigned int)x,(unsigned int)y,(unsigned int)z,OFF)
+
+#define SetList3D(x,y,z) SetMem(lp,(unsigned int)x,(unsigned int)y,(unsigned int)z,ON), AddToList(lp,(unsigned int)x,(unsigned int)y,(unsigned int)z)
+
+#define CellState3D(c) ((c)&ON)
+#define CellNbrs3D(c) ((c)&0x1f)       /* 26 <= 31 */
+
+#define EyeToScreen 72.0       /* distance from eye to screen */
+#define HalfScreenD 14.0       /* 1/2 the diameter of screen */
+#define BUCKETSIZE 10
+#define NBUCKETS ((MAXCOLUMNS+MAXROWS+MAXSTACKS)*BUCKETSIZE)
+#define Distance(x1,y1,z1,x2,y2,z2) sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2)+(z1-z2)*(z1-z2))
+
+#define IP 0.0174533
+
+#define COLORBASE 3
+#define COLORS (COLORBASE + 2)
+#define COLORSTEP (MI_NPIXELS(mi)/COLORBASE)   /* 21 different colors per side */
+
+#define BLACK 0
+#define RED 1
+#define GREEN 2
+#define BLUE 3
+#define WHITE 4
+#define NUMPTS 42
+#define NUMFILEPTS (2*NUMPTS)
+
+typedef struct _CellList {
+       unsigned char x, y, z;  /* Location in world coordinates */
+       char        visible;    /* 1 if the cube is to be displayed */
+       short       dist;       /* dist from cell to eye */
+       struct _CellList *next; /* pointer to next entry on linked list */
+       struct _CellList *prev;
+       struct _CellList *priority;
+} CellList;
+
+typedef struct {
+       int         survival, birth;
+} paramstruct;
+
+typedef struct {
+       Bool        painted;
+       paramstruct param;
+       int         pattern, patterned_rule;
+       int         ox, oy, oz; /* origin */
+       double      vx, vy, vz; /* viewpoint */
+       int         generation;
+       int         nstacks, nrows, ncolumns;
+       int         memstart;
+       char        visible;
+       unsigned char *base[BASESIZE];
+       double      A, B, C, F;
+       int         width, height;
+       unsigned long color[COLORS];
+       int         alt, azm;
+       double      dist;
+       CellList   *ptrhead, *ptrend, eraserhead, eraserend;
+       CellList   *buckethead[NBUCKETS], *bucketend[NBUCKETS];         /* comfortable upper b */
+       Bool        wireframe;
+} life3dstruct;
+
+static life3dstruct *life3ds = NULL;
+
+static paramstruct input_param;
+static Bool allPatterns = False, allGliders = False;
+static char *filePattern = NULL;
+
+/*-
+ * S45/B5 life is probably the best
+ * S567/B6 life has gliders like Conway's 2d S23/B3 life
+ * There are no known gliders for S56/B5 or S67/B67,
+ * so the others may be better
+ */
+
+static char patterns_S45B5[][3 * NUMPTS + 1] =
+{
+#if 0
+/* Still life */
+       {                       /* V */
+               -1, -1, -1, 0, -1, -1,
+               -1, 0, -1, 0, 0, -1,
+
+               -1, -1, 0, 0, -1, 0,
+               127
+       },
+       {                       /* CROSS */
+               0, 0, -1,
+
+               0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               0, 0, 1,
+               127
+       },
+       {                       /* PILLAR */
+               0, -1, -1,
+               -1, 0, -1, 1, 0, -1,
+               0, 1, -1,
+
+               0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+               127
+       },
+#endif
+       {                       /* BLINKER P2 */
+               0, 0, -1,
+
+               0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               -1, 0, 1, 1, 0, 1,
+               127
+       },
+       {                       /* DOUBLE BLINKER P2 */
+               0, -1, -1,
+               0, 1, -1,
+
+               0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               -1, 0, 1, 1, 0, 1,
+               127
+       },
+       {                       /* TRIPLE BLINKER 1 P2 */
+               -1, -1, -2,
+               -1, 0, -2,
+
+               -2, -1, -1,
+               1, 0, -1,
+               -1, 1, -1, 0, 1, -1,
+
+               -1, -2, 0, 0, -2, 0,
+               -2, -1, 0, 1, 0, 0,
+
+               0, -1, 1,
+               0, 0, 1,
+               127
+       },
+       {                       /* TRIPLE BLINKER 2 P2 */
+               -1, -1, -2, 0, -1, -2,
+
+               0, -2, -1,
+               1, -1, -1,
+               1, 0, -1,
+               -1, 1, -1,
+
+               0, -2, 0,
+               -2, -1, 0,
+               -2, 0, 0,
+               -1, 1, 0,
+
+               -1, 0, 1, 0, 0, 1,
+               127
+       },
+       {                       /* THREE HALFS BLINKER  P2 */
+               0, -1, -1,
+               -1, 0, -1, 1, 0, -1,
+
+               -1, -1, 0,
+               1, 0, 0,
+               -1, 1, 0, 0, 1, 0,
+
+               0, -1, 1,
+               0, 0, 1,
+               127
+       },
+       {                       /* PUFFER P4 */
+               0, -1, -1,
+               0, 0, -1,
+
+               0, -2, 0,
+               -1, -1, 0, 1, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+               127
+       },
+       {                       /* PINWHEEL P4 */
+               -1, 1, -1, 0, 1, -1,
+
+               -1, -1, 0, 0, -1, 0,
+               -2, 0, 0, 1, 0, 0,
+
+               -1, 0, 1, 0, 0, 1,
+               -1, 1, 1, 0, 1, 1,
+               127
+       },
+       {                       /* HEART P4 */
+               -1, -1, -1,
+               -1, 0, -1, 0, 0, -1,
+
+               0, -1, 0,
+               -2, 0, 0, 1, 0, 0,
+
+               -1, -1, 1,
+               -1, 1, 1, 0, 1, 1,
+               127
+       },
+       {                       /* ARROW P4 */
+               0, -1, -1,
+               0, 0, -1,
+
+               0, -2, 0,
+               1, -1, 0,
+               1, 0, 0,
+               0, 1, 0,
+
+               -1, -1, 1,
+               -1, 0, 1,
+               127
+       },
+       {                       /* ROTOR P2 */
+               0, -1, -1,
+               0, 0, -1,
+
+               0, -2, 0,
+               -1, -1, 0, 1, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               0, -1, 1,
+               0, 0, 1,
+               127
+       },
+       {                       /* BRONCO P4 */
+               0, -1, -1,
+               0, 0, -1,
+
+               0, -2, 0,
+               -1, -1, 0, 1, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               -1, -1, 1,
+               -1, 0, 1,
+               127
+       },
+       {                       /* TRIPUMP P2 */
+               0, -2, -2,
+               -2, -1, -2, -1, -1, -2, 0, -1, -2,
+
+               0, -2, -1,
+               -2, 0, -1,
+               -2, 1, -1, -1, 1, -1,
+
+               1, -2, 0,
+               1, -1, 0,
+               1, 0, 0,
+               -1, 1, 0,
+
+               0, 0, 1, 1, 0, 1,
+               -1, 1, 1,
+               127
+       },
+       {                       /* WINDSHIELDWIPER (HELICOPTER) P2 */
+               -2, -1, -2, -1, -1, -2,
+               0, 0, -2,
+
+               -1, -2, -1,
+               -2, -1, -1,
+               1, 0, -1,
+               -1, 1, -1, 0, 1, -1, 1, 1, -1,
+
+               0, -2, 0,
+               -2, -1, 0, 1, -1, 0,
+
+               0, -2, 1,
+               0, -1, 1,
+               0, 0, 1,
+               127
+       },
+       {                       /* WALTZER P6 */
+               -2, -1, -1, -1, -1, -1, 0, -1, -1,
+               -2, 0, -1,
+               -1, 1, -1, 0, 1, -1,
+
+               -2, -1, 0,
+               -2, 0, 0, 1, 0, 0,
+               1, 1, 0,
+
+               -1, 0, 1, 0, 0, 1,
+               0, 1, 1,
+               127
+       },
+       {                       /* BIG WALTZER P6 */
+               0, -1, -1, 1, -1, -1,
+               -1, 0, -1, 0, 0, -1,
+               -1, 1, -1,
+
+               0, -2, 0, 1, -2, 0,
+               -2, 0, 0,
+               -2, 1, 0,
+
+               0, -1, 1, 1, -1, 1,
+               -1, 0, 1, 0, 0, 1,
+               -1, 1, 1,
+               127
+       },
+       {                       /* SEESAW P2 */
+               0, 0, -2,
+
+               -2, -1, -1, -1, -1, -1,
+               -2, 0, -1,
+               0, 1, -1,
+
+               -1, -1, 0,
+               1, 0, 0,
+               0, 1, 0, 1, 1, 0,
+
+               -1, 0, 1,
+               127
+       },
+       {                       /* COLLISION -> REDIRECTION */
+               -3, 5, -7, 0, 5, -7,
+               -3, 4, -7, 0, 4, -7,
+               -2, 3, -7, -1, 3, -7,
+
+               -2, 5, -6, -1, 5, -6,
+               -2, 4, -6, -1, 4, -6,
+
+               1, -2, 1,
+
+               1, -3, 2,
+               0, -2, 2, 2, -2, 2,
+               1, -1, 2,
+
+               0, -2, 3, 2, -2, 3,
+               127
+       },
+       {                       /* COLLISION -> SEESAW P2 */
+               -4, -6, -7, -1, -6, -7,
+               -4, -5, -7, -1, -5, -7,
+               -3, -4, -7, -2, -4, -7,
+
+               -3, -6, -6, -2, -6, -6,
+               -3, -5, -6, -2, -5, -6,
+
+               1, 4, 6, 2, 4, 6,
+               0, 5, 6, 3, 5, 6,
+               0, 6, 6, 3, 6, 6,
+
+               1, 5, 5, 2, 5, 5,
+               1, 6, 5, 2, 6, 5,
+               127
+       }
+};
+
+static char patterns_S567B6[][3 * NUMPTS + 1] =
+{
+       {                       /* KNIFE-SWITCH BLINKER */
+               0, -1, -1,
+               -1, 0, -1, 0, 0, -1, 1, 0, -1,
+
+               0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 0, 1,
+               127,
+       },
+       {                       /* CLOCK */
+               0, -1, -2,
+               0, 0, -2,
+
+               -2, -1, -1, 0, -1, -1,
+               -2, 0, -1, 0, 0, -1,
+
+               -1, -1, 0, 1, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+
+               -1, -1, 1,
+               -1, 0, 1,
+               127,
+       },
+       {                       /* HALF BLINKERS */
+               0, -1, -2,
+               0, 0, -2,
+
+               -1, -1, -1, 1, -1, -1,
+               -1, 0, -1, 1, 0, -1,
+               0, 1, -1,
+
+               -1, -2, 0, 0, -2, 0, 1, -2, 0,
+               -2, -1, 0, 2, -1, 0,
+               -2, 0, 0, 2, 0, 0,
+               0, 1, 0,
+
+               -1, -1, 1, 1, -1, 1,
+               -1, 0, 1, 1, 0, 1,
+               0, 1, 1,
+
+               0, -1, 2,
+               0, 0, 2,
+               127,
+       },
+       {                       /* MUTANT HALF BLINKERS */
+               0, -1, -2,
+               0, 0, -2,
+
+               0, -2, -1,
+               -1, -1, -1, 1, -1, -1,
+               -1, 0, -1, 1, 0, -1,
+               0, 1, -1,
+
+               -1, -2, 0, 1, -2, 0,
+               -2, -1, 0, 2, -1, 0,
+               -2, 0, 0, 2, 0, 0,
+               0, 1, 0,
+
+               0, -2, 1, 1, -2, 1,
+               -1, -1, 1, 2, -1, 1,
+               -1, 0, 1, 2, 0, 1,
+               0, 1, 1,
+
+               0, -1, 2, 1, -1, 2,
+               0, 0, 2,
+               127,
+       },
+       {                       /* FUSE */
+               0, 0, 4,
+
+               0, 0, 3,
+
+               0, -2, 2,
+               -1, -1, 2, 1, -1, 2,
+               -2, 0, 2, 2, 0, 2,
+               -1, 1, 2, 1, 1, 2,
+               0, 2, 2,
+
+               0, -2, 1,
+               -1, -1, 1, 1, -1, 1,
+               -2, 0, 1, 2, 0, 1,
+               -1, 1, 1, 1, 1, 1,
+               0, 2, 1,
+
+               0, 0, 0,
+
+               0, 0, -1,
+
+               0, -2, -2,
+               -1, -1, -2, 1, -1, -2,
+               -2, 0, -2, 2, 0, -2,
+               -1, 1, -2, 1, 1, -2,
+               0, 2, -2,
+
+               0, -2, -3,
+               -1, -1, -3, 1, -1, -3,
+               -2, 0, -3, 2, 0, -3,
+               -1, 1, -3, 1, 1, -3,
+               0, 2, -3,
+
+               -1, 0, -4, 0, 0, -4, 1, 0, -4,
+               127,
+       },
+       {                       /* 2 PTS OF STAR OF DAVID */
+               1, 0, -3, 2, 0, -3,
+
+               1, -1, -2, 2, -1, -2,
+               0, 0, -2,
+               1, 1, -2, 2, 1, -2,
+
+               1, 0, -1, 2, 0, -1,
+
+               -2, 0, 0, 0, 0, 0,
+
+               -2, -1, 1,
+               -3, 0, 1, -1, 0, 1,
+               -2, 1, 1,
+
+               -2, -1, 2,
+               -3, 0, 2, -1, 0, 2,
+               -2, 1, 2,
+               127,
+       },
+       {                       /* TRIPLE BLINKER 1 */
+               0, -1, -2,
+               0, 0, -2,
+
+               -1, -1, -1, 1, -1, -1,
+               -2, 0, -1,
+               -1, 1, -1, 0, 1, -1,
+
+               -1, -2, 0, 0, -2, 0,
+               1, -1, 0,
+               -2, 0, 0, 0, 0, 0,
+
+               -1, -1, 1,
+               -1, 0, 1,
+               127,
+       },
+       {                       /* TRIPLE BLINKER 2 */
+               -1, -1, -2, 0, -1, -2,
+
+               -1, -2, -1,
+               -2, -1, -1, -1, -1, -1,
+               -2, 0, -1,
+               0, 1, -1,
+
+               -1, -2, 0,
+               1, -1, 0,
+               0, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               -1, 0, 1, 0, 0, 1,
+               127,
+       },
+       {                       /* TRIKNOT */
+               0, 0, -1, 1, 0, -1,
+
+               -1, -1, 0, 0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               0, 0, 1,
+               0, 1, 1,
+               127,
+       },
+       {                       /* SEARCHLIGHT */
+               -1, -1, -2, 0, -1, -2,
+               -1, 0, -2, 0, 0, -2,
+
+               -1, -2, -1, 0, -2, -1,
+               -2, -1, -1, 1, -1, -1,
+               -2, 0, -1, 1, 0, -1,
+               0, 1, -1,
+
+               -1, -2, 0, 0, -2, 0,
+               1, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               -1, -1, 1, 0, -1, 1,
+               127,
+       },
+       {                       /* POLE DRIVER */
+               -1, -1, -1, 0, -1, -1,
+               -1, 0, -1, 1, 0, -1,
+               0, 1, -1, 1, 1, -1,
+
+               0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0,
+
+               0, 0, 1,
+               127,
+       },
+       {                       /* LITTLE STAR */
+               0, -1, -1,
+               -1, 0, -1, 1, 0, -1,
+               -1, 1, -1, 0, 1, -1, 1, 1, -1,
+
+               -1, -1, 0, 1, -1, 0,
+               -1, 1, 0, 1, 1, 0,
+
+               -1, -1, 1, 0, -1, 1, 1, -1, 1,
+               -1, 0, 1, 1, 0, 1,
+               0, 1, 1,
+               127,
+       },
+       {                       /* JAWS */
+               0, -1, -2,
+               -1, 0, -2, 1, 0, -2,
+               0, 1, -2,
+
+               0, -2, -1,
+               -1, -1, -1, 1, -1, -1,
+               -1, 0, -1, 2, 0, -1,
+               0, 1, -1, 1, 1, -1,
+
+               -1, -2, 0, 1, -2, 0,
+               -1, -1, 0, 2, -1, 0,
+               1, 1, 0, 2, 1, 0,
+
+               0, -2, 1,
+               0, -1, 1, 1, -1, 1,
+               1, 0, 1, 2, 0, 1,
+
+               -2, 1, 1,
+               -2, 2, 1, -1, 2, 1,
+
+               -2, 1, 2, -1, 1, 2,
+               -2, 2, 2, -1, 2, 2,
+               127,
+       },
+       {                       /* NEAR SHIP */
+               -2, -1, -2, -1, -1, -2,
+               -2, 0, -2, -1, 0, -2,
+
+               -2, -1, -1, -1, -1, -1,
+               -2, 0, -1, -1, 0, -1,
+
+               0, -1, 0,
+               0, 0, 0,
+
+               -2, -1, 1, -1, -1, 1,
+               -2, 0, 1, -1, 0, 1,
+
+               -2, -1, 2, -1, -1, 2,
+               -2, 0, 2, -1, 0, 2,
+               127
+       }
+};
+
+/*-
+ * Many names of S56/B5 & S67/B67 are made up by David Bagley.
+ * They are listed in * order given by Carter Bays all p2 except "H"
+ */
+static char patterns_S56B5[][3 * NUMPTS + 1] =
+{
+       {                       /* SEESAW */
+               0, -1, -1,
+               -1, 0, -1, 0, 0, -1,
+
+               0, 0, 0, 1, 0, 0,
+               0, 1, 0,
+               127
+       },
+       {                       /* PROP */
+               -1, 0, -1, 0, 0, -1, 1, 0, -1,
+
+               0, -1, 0,
+               0, 0, 0,
+               0, 1, 0,
+               127
+       },
+       {                       /*  */
+               -1, 0, -1, 0, 0, -1,
+
+               0, -1, 0,
+               0, 0, 0, 1, 0, 0,
+               0, 1, 0,
+               127
+       },
+       {                       /* COLUMN */
+               0, 0, -6,
+
+               0, 0, -5,
+
+               0, -1, -4,
+               -1, 0, -4, 0, 0, -4, 1, 0, -4,
+               0, 1, -4,
+
+               0, -1, -1,
+               -1, 0, -1, 0, 0, -1, 1, 0, -1,
+               0, 1, -1,
+
+               0, 0, 0,
+
+               0, 0, 1,
+
+               0, 0, 2,
+
+               0, 0, 3,
+
+               0, -1, 4,
+               -1, 0, 4, 0, 0, 4, 1, 0, 4,
+               0, 1, 4,
+               127
+       },
+       {                       /* FLIPPING C */
+               -1, 0, -1, 1, 0, -1,
+
+               -1, 0, 0, 0, 0, 0, 1, 0, 0,
+               127
+       },
+       {                       /* SLIDING BLOCKS  */
+               -1, 0, -1, 0, 0, -1,
+               -1, 1, -1, 0, 1, -1,
+
+               -1, -1, 0, 0, -1, 0,
+               0, 0, 0,
+               127
+       },
+       {                       /*  */
+               -1, -1, -1,
+               -1, 1, -1,
+
+               -1, 0, 0, 0, 0, 0, 1, 0, 0,
+
+               -1, -1, 1,
+               -1, 1, 1,
+               127
+       },
+       {                       /* Y */
+               1, -1, -1,
+               -1, 0, -1,
+               0, 1, -1,
+
+               1, -1, 0,
+               -1, 0, 0, 0, 0, 0,
+               0, 1, 0,
+               127
+       },
+       {                       /* PUMP */
+               0, -1, -1,
+               -1, 0, -1, 1, 0, -1,
+               0, 1, -1,
+
+               -1, -1, 0, 0, -1, 0,
+               -1, 0, 0, 1, 0, 0,
+               0, 1, 0, 1, 1, 0,
+               127
+       },
+       {                       /* WALKER */
+               -1, -1, -1, 0, -1, -1,
+               1, 0, -1,
+
+               0, -1, 0, 1, -1, 0,
+               -1, 0, 0, 0, 0, 0,
+               127
+       },
+       {                       /* SWITCH */
+               2, -1, -2,
+               1, 0, -2, 2, 0, -2,
+
+               1, -1, -1, 2, -1, -1,
+               1, 0, -1,
+
+               1, 0, 0,
+
+               -1, -1, 1,
+               -2, 0, 1, -1, 0, 1, 0, 0, 1,
+
+               -2, -1, 2, -1, -1, 2,
+               -2, 0, 2,
+               127
+       },
+       {                       /* HOPPER */
+               -1, -1, -1, 0, -1, -1, 1, -1, -1,
+
+               0, -1, 0,
+               -1, 0, 0, 0, 0, 0, 1, 0, 0,
+               127
+       },
+       {                       /* PUSHUPS */
+               -1, -2, -2,
+
+               -1, -2, -1, 0, -2, -1,
+               -1, -1, -1, 0, -1, -1,
+
+               -1, 0, 0, 0, 0, 0,
+
+               -1, 0, 1, 0, 0, 1,
+               -1, 1, 1,
+               127
+       },
+       {                       /* PUSHER */
+               0, -2, -2,
+               0, -1, -2,
+
+               -1, -2, -1,
+               -1, -1, -1, 0, -1, -1,
+
+               -1, 0, 0, 0, 0, 0,
+               0, 1, 0,
+
+               -1, 0, 1,
+               0, 1, 1,
+               127
+       },
+       {                       /* CAPACITOR */
+               0, -1, -2,
+               -1, 0, -2, 0, 0, -2,
+
+               0, 0, -1, 1, 0, -1,
+               0, 1, -1, 1, 1, -1,
+
+               0, 0, 1, 1, 0, 1,
+               0, 1, 1, 1, 1, 1,
+
+               0, -1, 2,
+               -1, 0, 2, 0, 0, 2,
+               127
+       },
+       {                       /* CORNER 1 */
+               -1, -3, -3,
+               -1, -2, -3, 0, -2, -3,
+               1, -1, -3,
+               1, 0, -3, 2, 0, -3,
+
+               -1, -3, -2,
+               0, -2, -2,
+               1, -1, -2,
+               2, 0, -2,
+
+               -3, -3, -1, -2, -3, -1,
+               -3, -2, -1,
+               2, 1, -1,
+               1, 2, -1, 2, 2, -1,
+
+               -3, -2, 0, -2, -2, 0,
+               1, 1, 0,
+               1, 2, 0,
+
+               -3, -1, 1, -2, -1, 1,
+               -3, 0, 1,
+               0, 1, 1,
+               -1, 2, 1, 0, 2, 1,
+
+               -3, 0, 2, -2, 0, 2,
+               -1, 1, 2,
+               -1, 2, 2,
+               127
+       },
+       {                       /* CORNER 2 */
+               -2, -2, -3, -1, -2, -3,
+               -2, -1, -3,
+               2, 1, -3,
+               1, 2, -3, 2, 2, -3,
+
+               -3, -2, -2, -1, -2, -2,
+               -3, -1, -2, 0, -1, -2,
+               1, 0, -2,
+               2, 1, -2,
+               1, 3, -2, 2, 3, -2,
+
+               -3, -2, -1, -2, -2, -1,
+               0, -1, -1,
+               1, 0, -1,
+               2, 2, -1,
+               2, 3, -1,
+
+               -2, -1, 0, -1, -1, 0,
+               1, 1, 0,
+               1, 2, 0,
+
+               -2, 0, 1, -1, 0, 1,
+               0, 1, 1,
+               -3, 2, 1, 0, 2, 1,
+               -2, 3, 1,
+
+               -3, 1, 2, -2, 1, 2,
+               -3, 2, 2, -1, 2, 2,
+               -2, 3, 2, -1, 3, 2,
+               127
+       },
+       {                       /* RUNNER */
+               -1, -2, -1, 0, -2, -1,
+               0, -1, -1,
+
+               -1, -1, 0, 0, -1, 0,
+
+               -1, 0, 1, 0, 0, 1,
+               0, 1, 1,
+
+               -1, 1, 2, 0, 1, 2,
+               127
+       },
+       {                       /* BACKWARDS RUNNER */
+               -1, -2, -1, 0, -2, -1,
+               0, -1, -1,
+
+               -1, -1, 0, 0, -1, 0,
+
+               -1, 0, 1, 0, 0, 1,
+               -1, 1, 1,
+
+               -1, 0, 2, 0, 0, 2,
+               127
+       },
+       {                       /* FLIPPING H */
+               -1, 0, -1, 1, 0, -1,
+
+               -1, 0, 0, 0, 0, 0, 1, 0, 0,
+
+               -1, 0, 1, 1, 0, 1,
+               127
+       },
+       {                       /* EAGLE */
+               0, -2, -1, 1, -2, -1,
+               0, -1, -1, 1, -1, -1,
+               0, 1, -1, 1, 1, -1,
+               0, 2, -1, 1, 2, -1,
+
+               0, -1, 0,
+               -1, 0, 0,
+               0, 1, 0,
+               127
+       },
+       {                       /* VARIANT 1 */
+               1, -1, -2,
+               0, 0, -2,
+
+               0, -1, -1,
+               0, 0, -1, 1, 0, -1,
+
+               -1, -1, 0,
+
+               0, -1, 1,
+               0, 0, 1, 1, 0, 1,
+
+               1, -1, 2,
+               0, 0, 2,
+               127
+       },
+       {                       /* VARIANT 2 */
+               0, -1, -2,
+               1, 0, -2,
+
+               0, -1, -1, 1, -1, -1,
+               0, 0, -1,
+
+               -1, 0, 0,
+
+               0, -1, 1,
+               0, 0, 1, 1, 0, 1,
+
+               1, -1, 2,
+               0, 0, 2,
+               127
+       },
+       {                       /* VARIANT 3 */
+               1, -1, -2,
+               0, 0, -2,
+
+               0, -1, -1, 1, -1, -1,
+               0, 0, -1,
+
+               -1, -1, 0,
+
+               0, -1, 1,
+               0, 0, 1, 1, 0, 1,
+
+               1, -1, 2,
+               0, 0, 2,
+               127
+       },
+       {                       /* VARIANT 4 */
+               1, -1, -2,
+               0, 0, -2,
+
+               0, -1, -1, 1, -1, -1,
+               0, 0, -1,
+
+               -1, 0, 0,
+
+               0, -1, 1,
+               0, 0, 1, 1, 0, 1,
+
+               1, -1, 2,
+               0, 0, 2,
+               127
+       },
+       {                       /* SQUID */
+               -2, -1, -2, -1, -1, -2,
+               1, 1, -2,
+               1, 2, -2,
+
+               -2, -1, -1, -1, -1, -1, 0, -1, -1,
+               1, 0, -1,
+               1, 1, -1,
+               1, 2, -1,
+
+               -1, -1, 0,
+               1, 1, 0,
+
+               -1, 0, 1,
+               -2, 1, 1, -1, 1, 1, 0, 1, 1,
+               -2, 2, 1, -1, 2, 1,
+               127
+       },
+       {                       /* ROWER */
+               0, 1, -2,
+
+               -1, -1, -1, 1, -1, -1,
+               -2, 0, -1, -1, 0, -1, 1, 0, -1, 2, 0, -1,
+
+               -1, 0, 0, 1, 0, 0,
+               -1, 1, 0, 1, 1, 0,
+
+               0, -1, 1,
+               127
+       },
+       {                       /* FLIP */
+               -1, -2, -2,
+               0, -1, -2,
+               0, 0, -2,
+
+               -1, -2, -1,
+               -2, -1, -1, 1, -1, -1,
+               1, 0, -1,
+               1, 1, -1,
+
+               -1, -2, 0,
+               -2, -1, 0,
+               -1, 1, 0, 0, 1, 0,
+
+               -2, 0, 1, -1, 0, 1, 0, 0, 1,
+               127
+       }
+};
+static char patterns_S67B67[][3 * NUMPTS + 1] =
+{
+       {                       /* WALKING BOX */
+               -1, -1, -2,
+               0, 0, -2,
+
+               -1, -2, -1, 0, -2, -1,
+               -2, -1, -1, 1, -1, -1,
+               -2, 0, -1, 1, 0, -1,
+               -1, 1, -1, 0, 1, -1,
+
+               -1, -2, 0, 0, -2, 0,
+               -2, -1, 0, 1, -1, 0,
+               -2, 0, 0, 1, 0, 0,
+               -1, 1, 0, 0, 1, 0,
+
+               -1, -1, 1,
+               0, 0, 1,
+               127
+       },
+       {                       /* WALKER */
+               0, -1, -1,
+               -1, 0, -1,
+
+               -1, -1, 0, 0, -1, 0,
+               -1, 0, 0, 0, 0, 0,
+
+               0, -1, 1,
+               -1, 0, 1,
+               127
+       },
+       {                       /* S */
+               -1, -1, -1, 0, -1, -1,
+               -1, 0, -1, 0, 0, -1,
+
+               -1, 0, 0, 0, 0, 0,
+               -1, 1, 0, 0, 1, 0,
+               127
+       },
+       {                       /* BACKWARDS ARROW */
+               -1, 0, -1, 0, 0, -1,
+
+               -1, 0, 0, 0, 0, 0,
+               -1, 1, 0, 0, 1, 0,
+
+               -1, -1, 1, 0, -1, 1,
+               127
+       },
+       {                       /* SPINING BOX */
+               -1, -1, -2, 0, -1, -2,
+               -1, 0, -2, 0, 0, -2,
+
+               0, -2, -1,
+               -2, -1, -1, 1, -1, -1,
+               -2, 0, -1,
+               -1, 1, -1, 0, 1, -1,
+
+               -1, -2, 0, 0, -2, 0,
+               -2, -1, 0, 1, -1, 0,
+               -2, 0, 0, 1, 0, 0,
+               -1, 1, 0, 0, 1, 0,
+
+               -1, -1, 1, 0, -1, 1,
+               0, 0, 1,
+               127
+       },
+       {                       /* FLIPPING T */
+               0, 0, -1,
+
+               0, 0, 0,
+
+               0, -1, 1,
+               -1, 0, 1, 0, 0, 1, 1, 0, 1,
+               -1, 1, 1, 0, 1, 1,
+               127
+       }
+};
+
+static int  patterns_rules[] =
+{
+       (sizeof patterns_S45B5 / sizeof patterns_S45B5[0]),
+       (sizeof patterns_S567B6 / sizeof patterns_S567B6[0]),
+       (sizeof patterns_S56B5 / sizeof patterns_S56B5[0]),
+       (sizeof patterns_S67B67 / sizeof patterns_S67B67[0])
+};
+
+static paramstruct param_rules[] =
+{
+       {0x30, 0x20},
+       {0xE0, 0x40},
+       {0x60, 0x20},
+       {0xC0, 0xC0}
+};
+
+#define LIFE_S45B5 0
+#define LIFE_S567B6 1
+#define LIFE_GLIDERS 2         /* GLIDER rules are first in param_rules */
+#define LIFE_S56B5 2
+#define LIFE_S67B67 3
+#define LIFE_RULES (sizeof patterns_rules / sizeof patterns_rules[0])
+
+static int
+codeToPatternedRule(paramstruct param)
+{
+       unsigned int i;
+
+       for (i = 0; i < LIFE_RULES; i++)
+               if (param_rules[i].survival == param.survival &&
+                   param_rules[i].birth == param.birth)
+                       return i;
+       return LIFE_RULES;
+}
+
+static void
+copyFromPatternedRule(paramstruct * param, int patterned_rule)
+{
+       param->survival = param_rules[patterned_rule].survival;
+       param->birth = param_rules[patterned_rule].birth;
+}
+
+static void
+printRule(paramstruct param)
+{
+       int         l;
+
+       (void) fprintf(stdout, "rule (Survival/Birth neighborhood): S");
+       for (l = 0; l <= MAXNEIGHBORS; l++) {
+               if (param.survival & (1 << l))
+                       (void) fprintf(stdout, "%d", l);
+       }
+       (void) fprintf(stdout, "/B");
+       for (l = 0; l <= MAXNEIGHBORS; l++) {
+               if (param.birth & (1 << l))
+                       (void) fprintf(stdout, "%d", l);
+       }
+       (void) fprintf(stdout, "\nbinary rule: Survival 0x%X, Birth 0x%X\n",
+                      param.survival, param.birth);
+}
+
+/*-
+ * This stuff is not good for rules above 9 cubes but it is unlikely that
+ * these modes would be much good anyway....  death assumed.
+ */
+static void
+parseRule(ModeInfo * mi)
+{
+       int         n, l;
+       char        serving = 0;
+       static Bool found = False;
+
+       if (found)
+               return;
+
+       input_param.survival = input_param.birth = 0;
+       if (rule) {
+               n = 0;
+               while (rule[n]) {
+                       if (rule[n] == 'P') {
+                               allPatterns = True;
+                               found = True;
+                               if (MI_IS_VERBOSE(mi))
+                                       (void) fprintf(stdout, "rule: All rules with known patterns\n");
+                               return;
+                       } else if (rule[n] == 'G') {
+                               allGliders = True;
+                               found = True;
+                               if (MI_IS_VERBOSE(mi))
+                                       (void) fprintf(stdout, "rule: All rules with known gliders\n");
+                               return;
+                       } else if (rule[n] == 'S' || rule[n] == 'E' || rule[n] == 'L') {
+                               serving = 'S';
+                       } else if (rule[n] == 'B') {
+                               serving = 'B';
+                       } else {
+                               l = rule[n] - '0';
+                               if (l >= 0 && l <= 9 /*&& l <= MAXNEIGHBORS */ ) {      /* no 10..27 */
+                                       if (serving == 'S') {
+                                               found = True;
+                                               input_param.survival |= (1 << l);
+                                       } else if (serving == 'B') {
+                                               found = True;
+                                               input_param.birth |= (1 << l);
+                                       }
+                               }
+                       }
+                       n++;
+               }
+       }
+       if (!found) {           /* Default to Bays' rules if very stupid */
+               allGliders = True;
+               found = True;
+               if (MI_IS_VERBOSE(mi))
+                       (void) fprintf(stdout,
+                                      "rule: Defaulting to all rules with known gliders\n");
+               return;
+       }
+       if (MI_IS_VERBOSE(mi))
+               printRule(input_param);
+}
+
+static void
+parseFile(void)
+{
+       FILE       *file;
+       static Bool done = False;
+       int         firstx = 0, firsty = 0, x = 0, y = 0, z = 0, i = 0;
+       int         c = 0, cprev = ' ';
+       char        line[256];
+
+       if (done)
+               return;
+       done = True;
+       if (!lifefile || !*lifefile ||
+           ((file = my_fopen(lifefile, "r")) == NULL)) {
+               /*(void) fprintf(stderr, "could not read file \"%s\"\n", lifefile); */
+               return;
+       }
+       for (;;) {
+               if (!fgets(line, 256, file)) {
+                       (void) fprintf(stderr, "could not read header of file \"%s\"\n",
+                                      lifefile);
+                       (void) fclose(file);
+                       return;
+               }
+               if (strncmp(line, "#P", (size_t) 2) == 0 &&
+                   sscanf(line, "#P %d %d %d", &x, &y, &z) == 3)
+                       break;
+       }
+       c = getc(file);
+       while (c != EOF && !(c == '0' || c == 'O' || c == '*' || c == '.')) {
+               c = getc(file);
+       }
+       if (c == EOF || x <= -127 || y <= -127 || z <= -127 ||
+           x >= 127 || y >= 127 || z >= 127) {
+               (void) fprintf(stderr, "corrupt file \"%s\" or file to large\n",
+                              lifefile);
+               (void) fclose(file);
+               return;
+       }
+       firstx = x;
+       firsty = y;
+       filePattern = (char *) malloc((3 * NUMFILEPTS + 1) * sizeof (char));
+
+       while (c != EOF && x < 127 && y < 127 && i < 3 * NUMFILEPTS) {
+               if (c == '0' || c == 'O' || c == '*') {
+                       filePattern[i++] = x++;
+                       filePattern[i++] = y;
+                       filePattern[i++] = z;
+               } else if (c == '.') {
+                       x++;
+               } else if (c == '\n') {
+                       if (cprev == '\n') {
+                               z++;
+                               y = firsty;
+                       } else {
+                               x = firstx;
+                               y++;
+                       }
+               }
+               cprev = c;
+               c = getc(file);
+       }
+       (void) fclose(file);
+       filePattern[i] = 127;
+}
+
+/*--- list ---*/
+/* initialise the state of all cells to OFF */
+static void
+Init3D(life3dstruct * lp)
+{
+       lp->ptrhead = lp->ptrend = NULL;
+       lp->eraserhead.next = &lp->eraserend;
+       lp->eraserend.prev = &lp->eraserhead;
+}
+
+static CellList *
+NewCell(void)
+{
+       return ((CellList *) malloc(sizeof (CellList)));
+}
+
+/*-
+ * Function that adds the cell (assumed live) at (x,y,z) onto the search
+ * list so that it is scanned in future generations
+ */
+static void
+AddToList(life3dstruct * lp, unsigned int x, unsigned int y, unsigned int z)
+{
+       CellList   *tmp;
+
+       tmp = NewCell();
+       tmp->x = x;
+       tmp->y = y;
+       tmp->z = z;
+       if (lp->ptrhead == NULL) {
+               lp->ptrhead = lp->ptrend = tmp;
+               tmp->prev = NULL;
+       } else {
+               lp->ptrend->next = tmp;
+               tmp->prev = lp->ptrend;
+               lp->ptrend = tmp;
+       }
+       lp->ptrend->next = NULL;
+}
+
+static void
+AddToEraseList(life3dstruct * lp, CellList * cell)
+{
+       cell->next = &lp->eraserend;
+       cell->prev = lp->eraserend.prev;
+       lp->eraserend.prev->next = cell;
+       lp->eraserend.prev = cell;
+}
+
+static void
+DelFromList(life3dstruct * lp, CellList * cell)
+{
+       if (cell != lp->ptrhead)
+               cell->prev->next = cell->next;
+       else {
+               lp->ptrhead = cell->next;
+               if (lp->ptrhead != NULL)
+                       lp->ptrhead->prev = NULL;
+       }
+
+       if (cell != lp->ptrend)
+               cell->next->prev = cell->prev;
+       else {
+               lp->ptrend = cell->prev;
+               if (lp->ptrend != NULL)
+                       lp->ptrend->next = NULL;
+       }
+
+       AddToEraseList(lp, cell);
+}
+
+static void
+DelFromEraseList(CellList * cell)
+{
+       cell->next->prev = cell->prev;
+       cell->prev->next = cell->next;
+       (void) free((void *) cell);
+}
+
+/*--- memory ---*/
+/*-
+ * Simulate a large array by dynamically allocating 4x4x4 size cells when
+ * needed.
+ */
+static void
+MemInit(life3dstruct * lp)
+{
+       int         i;
+
+       for (i = 0; i < BASESIZE; ++i) {
+               if (lp->base[i] != NULL) {
+                       (void) free((void *) lp->base[i]);
+                       lp->base[i] = NULL;
+               }
+       }
+       lp->memstart = 0;
+}
+
+static void
+BaseOffset(life3dstruct * lp,
+          unsigned int x, unsigned int y, unsigned int z, int *b, int *o)
+{
+       *b = ((x & 0x7c) << 7) + ((y & 0x7c) << 2) + ((z & 0x7c) >> 2);
+       *o = (x & 3) + ((y & 3) << 2) + ((z & 3) << 4);
+
+       if (!lp->base[*b])
+               lp->base[*b] = (unsigned char *) calloc(64, sizeof (unsigned char));
+}
+
+static int
+GetMem(life3dstruct * lp, unsigned int x, unsigned int y, unsigned int z)
+{
+       int         b, o;
+
+       if (lp->memstart)
+               MemInit(lp);
+       BaseOffset(lp, x, y, z, &b, &o);
+       return lp->base[b][o];
+}
+
+static void
+SetMem(life3dstruct * lp,
+       unsigned int x, unsigned int y, unsigned int z, unsigned int val)
+{
+       int         b, o;
+
+       if (lp->memstart)
+               MemInit(lp);
+
+       BaseOffset(lp, x, y, z, &b, &o);
+       lp->base[b][o] = val;
+}
+
+static void
+ChangeMem(life3dstruct * lp,
+         unsigned int x, unsigned int y, unsigned int z, unsigned int val)
+{
+       int         b, o;
+
+       if (lp->memstart)
+               MemInit(lp);
+       BaseOffset(lp, x, y, z, &b, &o);
+       lp->base[b][o] += val;
+}
+
+static void
+ClearMem(life3dstruct * lp)
+{
+       int         i, j, count;
+
+       for (i = 0; i < BASESIZE; ++i)
+               if (lp->base[i] != NULL) {
+                       for (count = j = 0; j < 64 && count == 0; ++j)
+                               if (CellState3D(lp->base[i][j]))
+                                       ++count;
+                       if (!count) {
+                               (void) free((void *) lp->base[i]);
+                               lp->base[i] = NULL;
+                       }
+               }
+}
+
+
+/*-
+ * This routine increments the values stored in the 27 cells centred on
+ * (x,y,z) Note that the offset() macro implements wrapping - the world is a 
+ * torus.
+ */
+static void
+IncrementNbrs3D(life3dstruct * lp, CellList * cell)
+{
+       int         xc, yc, zc, x, y, z;
+
+       xc = cell->x;
+       yc = cell->y;
+       zc = cell->z;
+       for (z = zc - 1; z != zc + 2; ++z)
+               for (y = yc - 1; y != yc + 2; ++y)
+                       for (x = xc - 1; x != xc + 2; ++x)
+                               if (x != xc || y != yc || z != zc)
+                                       ChangeMem(lp,
+                                                 (unsigned int) x, (unsigned int) y, (unsigned int) z, 1);
+}
+
+static void
+End3D(life3dstruct * lp)
+{
+       CellList   *ptr;
+
+       while (lp->ptrhead != NULL) {
+               SetMem(lp, lp->ptrhead->x, lp->ptrhead->y, lp->ptrhead->z, OFF);
+               DelFromList(lp, lp->ptrhead);
+       }
+       ptr = lp->eraserhead.next;
+       while (ptr != &lp->eraserend) {
+               DelFromEraseList(ptr);
+               ptr = lp->eraserhead.next;
+       }
+       MemInit(lp);
+}
+
+static void
+RunLife3D(life3dstruct * lp)
+{
+       unsigned int x, y, z, xc, yc, zc;
+       int         c;
+       CellList   *ptr, *ptrnextcell;
+
+       /* Step 1 - Add 1 to all neighbours of living cells. */
+       ptr = lp->ptrhead;
+       while (ptr != NULL) {
+               IncrementNbrs3D(lp, ptr);
+               ptr = ptr->next;
+       }
+
+       /* Step 2 - Scan world and implement Survival rules. We have a list of live
+        * cells, so do the following:
+        * Start at the END of the list and work backwards (so we don't have to worry
+        * about scanning newly created cells since they are appended to the end) and
+        * for every entry, scan its neighbours for new live cells. If found, add them
+        * to the end of the list. If the centre cell is dead, unlink it.
+        * Make sure we do not append multiple copies of cells.
+        */
+       ptr = lp->ptrend;
+       while (ptr != NULL) {
+               ptrnextcell = ptr->prev;
+               xc = ptr->x;
+               yc = ptr->y;
+               zc = ptr->z;
+               for (z = zc - 1; z != zc + 2; ++z)
+                       for (y = yc - 1; y != yc + 2; ++y)
+                               for (x = xc - 1; x != xc + 2; ++x)
+                                       if (x != xc || y != yc || z != zc)
+                                               if ((c = GetMem(lp, x, y, z))) {
+                                                       if (CellState3D(c) == OFF) {
+                                                               if (lp->param.birth & (1 << CellNbrs3D(c)))
+                                                                       SetList3D(x, y, z);
+                                                               else
+                                                                       Reset3D(x, y, z);
+                                                       }
+                                               }
+               c = GetMem(lp, xc, yc, zc);
+               if (lp->param.survival & (1 << CellNbrs3D(c)))
+                       Set3D(xc, yc, zc);
+               else {
+                       SetMem(lp, ptr->x, ptr->y, ptr->z, OFF);
+                       DelFromList(lp, ptr);
+               }
+               ptr = ptrnextcell;
+       }
+       ClearMem(lp);
+}
+
+#if 0
+static int
+CountCells3D(life3dstruct * lp)
+{
+       CellList   *ptr;
+       int         count = 0;
+
+       ptr = lp->ptrhead;
+       while (ptr != NULL) {
+               ++count;
+               ptr = ptr->next;
+       }
+       return count;
+}
+
+void
+DisplayList(life3dstruct * lp)
+{
+       CellList   *ptr;
+       int         count = 0;
+
+       ptr = lp->ptrhead;
+       while (ptr != NULL) {
+               (void) printf("(%x)=[%d,%d,%d] ", (int) ptr, ptr->x, ptr->y, ptr->z);
+               ptr = ptr->next;
+               ++count;
+       }
+       (void) printf("Living cells = %d\n", count);
+}
+
+#endif
+
+static void
+RandomSoup(ModeInfo * mi, int n, int v)
+{
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+       int         x, y, z;
+
+       v /= 2;
+       if (v < 1)
+               v = 1;
+       for (z = lp->nstacks / 2 - v; z < lp->nstacks / 2 + v; ++z)
+               for (y = lp->nrows / 2 - v; y < lp->nrows / 2 + v; ++y)
+                       for (x = lp->ncolumns / 2 - v; x < lp->ncolumns / 2 + v; ++x)
+                               if (NRAND(100) < n)
+                                       SetList3D(x, y, z);
+       if (MI_IS_VERBOSE(mi)) {
+               (void) fprintf(stdout, "random pattern\n");
+       }
+}
+
+static void
+GetPattern(ModeInfo * mi, int pattern_rule, int pattern)
+{
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+       int         x, y, z;
+       char       *patptr = NULL;
+
+       if (filePattern) {
+               patptr = &filePattern[0];
+       } else {
+               switch (pattern_rule) {
+                       case LIFE_S45B5:
+                               patptr = &patterns_S45B5[pattern][0];
+                               break;
+                       case LIFE_S567B6:
+                               patptr = &patterns_S567B6[pattern][0];
+                               break;
+                       case LIFE_S56B5:
+                               patptr = &patterns_S56B5[pattern][0];
+                               break;
+                       case LIFE_S67B67:
+                               patptr = &patterns_S67B67[pattern][0];
+                               break;
+               }
+       }
+       while ((x = *patptr++) != 127) {
+               y = *patptr++;
+               z = *patptr++;
+               x += lp->ncolumns / 2;
+               y += lp->nrows / 2;
+               z += lp->nstacks / 2;
+               if (x >= 0 && y >= 0 && z >= 0 &&
+                   x < lp->ncolumns && y < lp->nrows && z < lp->nstacks)
+                       SetList3D(x, y, z);
+       }
+       if (MI_IS_VERBOSE(mi) && !filePattern) {
+               (void) fprintf(stdout, "table number %d\n", pattern);
+       }
+}
+
+static void
+NewViewpoint(life3dstruct * lp, double x, double y, double z)
+{
+       double      k, l, d1, d2;
+
+       k = x * x + y * y;
+       l = sqrt(k + z * z);
+       k = sqrt(k);
+       d1 = (EyeToScreen / HalfScreenD);
+       d2 = EyeToScreen / (HalfScreenD * lp->height / lp->width);
+       lp->A = d1 * l * (lp->width / 2) / k;
+       lp->B = l * l;
+       lp->C = d2 * (lp->height / 2) / k;
+       lp->F = k * k;
+}
+
+static void
+NewPoint(life3dstruct * lp, double x, double y, double z,
+        register XPoint * cubepts)
+{
+       double      p1, E;
+
+       p1 = x * lp->vx + y * lp->vy;
+       E = lp->B - p1 - z * lp->vz;
+       cubepts->x = (int) (lp->width / 2 - lp->A * (lp->vx * y - lp->vy * x) / E);
+       cubepts->y = (int) (lp->height / 2 - lp->C * (z * lp->F - lp->vz * p1) / E);
+}
+
+
+/* Chain together all cells that are at the same distance. These * cannot
+   mutually overlap. */
+static void
+SortList(life3dstruct * lp)
+{
+       short       dist;
+       double      d, x, y, z, rsize;
+       int         i, r;
+       XPoint      point;
+       CellList   *ptr;
+
+       for (i = 0; i < NBUCKETS; ++i)
+               lp->buckethead[i] = lp->bucketend[i] = NULL;
+
+       /* Calculate distances and re-arrange pointers to chain off buckets */
+       ptr = lp->ptrhead;
+       while (ptr != NULL) {
+
+               x = (double) ptr->x - lp->ox;
+               y = (double) ptr->y - lp->oy;
+               z = (double) ptr->z - lp->oz;
+               d = Distance(lp->vx, lp->vy, lp->vz, x, y, z);
+               if (lp->vx * (lp->vx - x) + lp->vy * (lp->vy - y) +
+                   lp->vz * (lp->vz - z) > 0 && d > 1.5)
+                       ptr->visible = 1;
+               else
+                       ptr->visible = 0;
+
+               ptr->dist = (short) d;
+               dist = (short) (d * BUCKETSIZE);
+               if (dist > NBUCKETS - 1)
+                       dist = NBUCKETS - 1;
+
+               if (lp->buckethead[dist] == NULL) {
+                       lp->buckethead[dist] = lp->bucketend[dist] = ptr;
+                       ptr->priority = NULL;
+               } else {
+                       lp->bucketend[dist]->priority = ptr;
+                       lp->bucketend[dist] = ptr;
+                       lp->bucketend[dist]->priority = NULL;
+               }
+               ptr = ptr->next;
+       }
+
+       /* Check for invisibility */
+       rsize = 0.47 * lp->width / ((double) HalfScreenD * 2);
+       i = lp->azm;
+       if (i < 0)
+               i = -i;
+       i = i % RT_ANGLE;
+       if (i > HALFRT_ANGLE)
+               i = RT_ANGLE - i;
+       rsize /= cos(i * IP);
+
+       lp->visible = 0;
+       for (i = 0; i < NBUCKETS; ++i)
+               lp->buckethead[i] = lp->bucketend[i] = NULL;
+
+       /* Calculate distances and re-arrange pointers to chain off buckets */
+       ptr = lp->ptrhead;
+       while (ptr != NULL) {
+
+               x = (double) ptr->x - lp->ox;
+               y = (double) ptr->y - lp->oy;
+               z = (double) ptr->z - lp->oz;
+               d = Distance(lp->vx, lp->vy, lp->vz, x, y, z);
+               if (lp->vx * (lp->vx - x) + lp->vy * (lp->vy - y) +
+                   lp->vz * (lp->vz - z) > 0 && d > 1.5)
+                       ptr->visible = 1;
+               else
+                       ptr->visible = 0;
+
+               ptr->dist = (short) d;
+               dist = (short) (d * BUCKETSIZE);
+               if (dist > NBUCKETS - 1)
+                       dist = NBUCKETS - 1;
+
+               if (lp->buckethead[dist] == NULL) {
+                       lp->buckethead[dist] = lp->bucketend[dist] = ptr;
+                       ptr->priority = NULL;
+               } else {
+                       lp->bucketend[dist]->priority = ptr;
+                       lp->bucketend[dist] = ptr;
+                       lp->bucketend[dist]->priority = NULL;
+               }
+               ptr = ptr->next;
+       }
+
+       /* Check for invisibility */
+       rsize = 0.47 * lp->width / ((double) HalfScreenD * 2);
+       i = lp->azm;
+       if (i < 0)
+               i = -i;
+       i = i % RT_ANGLE;
+       if (i > HALFRT_ANGLE)
+               i = RT_ANGLE - i;
+       rsize /= cos(i * IP);
+
+       lp->visible = 0;
+       for (i = 0; i < NBUCKETS; ++i)
+               if (lp->buckethead[i] != NULL) {
+                       ptr = lp->buckethead[i];
+                       while (ptr != NULL) {
+                               if (ptr->visible) {
+                                       x = (double) ptr->x - lp->ox;
+                                       y = (double) ptr->y - lp->oy;
+                                       z = (double) ptr->z - lp->oz;
+                                       NewPoint(lp, x, y, z, &point);
+
+                                       r = (int) (rsize * (double) EyeToScreen / (double) ptr->dist);
+                                       if (point.x + r >= 0 && point.y + r >= 0 &&
+                                           point.x - r < lp->width && point.y - r < lp->height)
+                                               lp->visible = 1;
+                               }
+                               ptr = ptr->priority;
+                       }
+               }
+}
+
+static void
+DrawFace(ModeInfo * mi, int color, XPoint * cubepts,
+        int p1, int p2, int p3, int p4)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+       XPoint      facepts[5];
+
+       facepts[0] = cubepts[p1];
+       facepts[1] = cubepts[p2];
+       facepts[2] = cubepts[p3];
+       facepts[3] = cubepts[p4];
+       facepts[4] = cubepts[p1];
+
+       if (!lp->wireframe) {
+               XSetForeground(display, gc, lp->color[color]);
+               XFillPolygon(display, MI_WINDOW(mi), gc, facepts, 4,
+                            Convex, CoordModeOrigin);
+       }
+       if (lp->wireframe) {
+               XSetForeground(display, gc, lp->color[color]);
+       } else if (color == BLACK)
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       XDrawLines(display, MI_WINDOW(mi), gc, facepts, 5, CoordModeOrigin);
+}
+
+#define LEN 0.45
+#define LEN2 0.9
+
+static int
+DrawCube(ModeInfo * mi, CellList * cell)
+{
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+       XPoint      cubepts[8]; /* screen coords for point */
+       int         i = 0, out;
+       unsigned int mask;
+       double      x, y, z;
+       double      dx, dy, dz;
+
+       x = (double) cell->x - lp->ox;
+       y = (double) cell->y - lp->oy;
+       z = (double) cell->z - lp->oz;
+       out = 0;
+       for (dz = z - LEN; dz <= z + LEN2; dz += LEN2)
+               for (dy = y - LEN; dy <= y + LEN2; dy += LEN2)
+                       for (dx = x - LEN; dx <= x + LEN2; dx += LEN2) {
+                               NewPoint(lp, dx, dy, dz, &cubepts[i]);
+                               if (cubepts[i].x < 0 || cubepts[i].x >= lp->width ||
+                                   cubepts[i].y < 0 || cubepts[i].y >= lp->height)
+                                       ++out;
+                               ++i;
+                       }
+       if (out == 8)
+               return (0);
+
+       if (cell->visible)
+               mask = 0xFFFF;
+       else
+               mask = 0x0;
+
+       /* Only draw those faces that are visible */
+       dx = lp->vx - x;
+       dy = lp->vy - y;
+       dz = lp->vz - z;
+       if (lp->wireframe) {
+               if (dz <= LEN)
+                       DrawFace(mi, (int) (BLUE & mask), cubepts, 4, 5, 7, 6);
+               else if (dz >= -LEN)
+                       DrawFace(mi, (int) (BLUE & mask), cubepts, 0, 1, 3, 2);
+               if (dx <= LEN)
+                       DrawFace(mi, (int) (GREEN & mask), cubepts, 1, 3, 7, 5);
+               else if (dx >= -LEN)
+                       DrawFace(mi, (int) (GREEN & mask), cubepts, 0, 2, 6, 4);
+               if (dy <= LEN)
+                       DrawFace(mi, (int) (RED & mask), cubepts, 2, 3, 7, 6);
+               else if (dy >= -LEN)
+                       DrawFace(mi, (int) (RED & mask), cubepts, 0, 1, 5, 4);
+       }
+       if (dz > LEN)
+               DrawFace(mi, (int) (BLUE & mask), cubepts, 4, 5, 7, 6);
+       else if (dz < -LEN)
+               DrawFace(mi, (int) (BLUE & mask), cubepts, 0, 1, 3, 2);
+       if (dx > LEN)
+               DrawFace(mi, (int) (GREEN & mask), cubepts, 1, 3, 7, 5);
+       else if (dx < -LEN)
+               DrawFace(mi, (int) (GREEN & mask), cubepts, 0, 2, 6, 4);
+       if (dy > LEN)
+               DrawFace(mi, (int) (RED & mask), cubepts, 2, 3, 7, 6);
+       else if (dy < -LEN)
+               DrawFace(mi, (int) (RED & mask), cubepts, 0, 1, 5, 4);
+       return (1);
+}
+
+static void
+DrawScreen(ModeInfo * mi)
+{
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+       CellList   *ptr;
+       CellList   *eraserptr;
+       int         i;
+
+       SortList(lp);
+
+       /* Erase dead cubes */
+       eraserptr = lp->eraserhead.next;
+       while (eraserptr != &lp->eraserend) {
+               eraserptr->visible = 0;
+               (void) DrawCube(mi, eraserptr);
+               DelFromEraseList(eraserptr);
+               eraserptr = lp->eraserhead.next;
+       }
+
+       /* draw furthest cubes first */
+       for (i = NBUCKETS - 1; i >= 0; --i) {
+               ptr = lp->buckethead[i];
+               while (ptr != NULL) {
+                       /*if (ptr->visible) */
+                       /* v += */ (void) DrawCube(mi, ptr);
+                       ptr = ptr->priority;
+                       /* ++count; */
+               }
+       }
+#if 0
+       {
+               int         count = 0, v = 0;
+
+
+               (void) printf("Pop=%-4d  Viewpoint (%3d,%3d,%3d)  Origin (%3d,%3d,%3d)  Mode %dx%d\
+(%d,%d) %d\n",
+                    count, (int) (lp->vx + lp->ox), (int) (lp->vy + lp->oy),
+                             (int) (lp->vz + lp->oz), (int) lp->ox, (int) lp->oy, (int) lp->oz,
+                             lp->width, lp->height, lp->alt, lp->azm, v);
+       }
+#endif
+}
+
+static void
+shooter(life3dstruct * lp)
+{
+       int         hsp, vsp, asp, hoff = 1, voff = 1, aoff = 1, r, c2,
+                   r2, s2;
+
+       /* Generate the glider at the edge of the screen */
+#define V 10
+#define V2 (V/2)
+       c2 = lp->ncolumns / 2;
+       r2 = lp->nrows / 2;
+       s2 = lp->nstacks / 2;
+       r = NRAND(3);
+       if (!r) {
+               hsp = NRAND(V2) + c2 - V2 / 2;
+               vsp = (LRAND() & 1) ? r2 - V : r2 + V;
+               asp = (LRAND() & 1) ? s2 - V : s2 + V;
+               if (asp > s2)
+                       aoff = -1;
+               if (vsp > r2)
+                       voff = -1;
+               if (hsp > c2)
+                       hoff = -1;
+               if (lp->patterned_rule == LIFE_S45B5) {
+                       SetList3D(hsp + 0 * hoff, vsp + 0 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 1 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 2 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 2 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 3 * hoff, vsp + 0 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 3 * hoff, vsp + 1 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 0 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 0 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+               } else if (lp->patterned_rule == LIFE_S567B6) {
+                       SetList3D(hsp + 0 * hoff, vsp + 1 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 2 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 2 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 0 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 0 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 1 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 2 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 2 * voff, asp + 2 * aoff);
+               }
+       } else if (r == 1) {
+               hsp = (LRAND() & 1) ? c2 - V : c2 + V;
+               vsp = (LRAND() & 1) ? r2 - V : r2 + V;
+               asp = NRAND(V2) + s2 - V2 / 2;
+               if (asp > s2)
+                       aoff = -1;
+               if (vsp > r2)
+                       voff = -1;
+               if (hsp > c2)
+                       hoff = -1;
+               if (lp->patterned_rule == LIFE_S45B5) {
+                       SetList3D(hsp + 0 * hoff, vsp + 0 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 0 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 0 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 0 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 0 * voff, asp + 3 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 0 * voff, asp + 3 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 1 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 2 * aoff);
+               } else if (lp->patterned_rule == LIFE_S567B6) {
+                       SetList3D(hsp + 1 * hoff, vsp + 0 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 0 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 1 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 2 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 2 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 2 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 2 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 2 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 2 * voff, asp + 1 * aoff);
+               }
+       } else {
+               hsp = (LRAND() & 1) ? c2 - V : c2 + V;
+               vsp = NRAND(V2) + r2 - V2 / 2;
+               asp = (LRAND() & 1) ? s2 - V : s2 + V;
+               if (asp > s2)
+                       aoff = -1;
+               if (vsp > r2)
+                       voff = -1;
+               if (hsp > c2)
+                       hoff = -1;
+               if (lp->patterned_rule == LIFE_S45B5) {
+                       SetList3D(hsp + 0 * hoff, vsp + 0 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 0 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 1 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 2 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 3 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 3 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 2 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 2 * voff, asp + 1 * aoff);
+               } else if (lp->patterned_rule == LIFE_S567B6) {
+                       SetList3D(hsp + 0 * hoff, vsp + 0 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 0 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 0 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 1 * hoff, vsp + 1 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 0 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 1 * voff, asp + 0 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 0 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 1 * voff, asp + 1 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 0 * voff, asp + 2 * aoff);
+                       SetList3D(hsp + 2 * hoff, vsp + 1 * voff, asp + 2 * aoff);
+               }
+       }
+}
+
+void
+init_life3d(ModeInfo * mi)
+{
+       life3dstruct *lp;
+       int         i, npats;
+
+       if (life3ds == NULL) {
+               if ((life3ds = (life3dstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (life3dstruct))) == NULL)
+                       return;
+       }
+       lp = &life3ds[MI_SCREEN(mi)];
+
+       lp->generation = 0;
+
+       parseRule(mi);
+       parseFile();
+       if (allPatterns) {
+               lp->patterned_rule = NRAND(LIFE_RULES);
+               copyFromPatternedRule(&lp->param, lp->patterned_rule);
+               if (MI_IS_VERBOSE(mi))
+                       printRule(lp->param);
+       } else if (allGliders) {
+               lp->patterned_rule = NRAND(LIFE_GLIDERS);
+               copyFromPatternedRule(&lp->param, lp->patterned_rule);
+               if (MI_IS_VERBOSE(mi))
+                       printRule(lp->param);
+       } else {
+               lp->param.survival = input_param.survival;
+               lp->param.birth = input_param.birth;
+       }
+       if (!lp->eraserhead.next) {
+               lp->dist = 50.0 /*30.0 */ ;
+               lp->alt = 20 /*30 */ ;
+               lp->azm = 10 /*30 */ ;
+               lp->ncolumns = MAXCOLUMNS;
+               lp->nrows = MAXROWS;
+               lp->nstacks = MAXSTACKS;
+               lp->ox = lp->ncolumns / 2;
+               lp->oy = lp->nrows / 2;
+               lp->oz = lp->nstacks / 2;
+
+               Init3D(lp);
+       } else
+               End3D(lp);
+       lp->color[0] = MI_BLACK_PIXEL(mi);
+       if (MI_NPIXELS(mi) > 2) {
+               i = NRAND(3);
+
+               lp->color[i + 1] = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi) / COLORBASE));
+               lp->color[(i + 1) % 3 + 1] = MI_PIXEL(mi,
+                                         NRAND(MI_NPIXELS(mi) / COLORBASE) +
+                                                MI_NPIXELS(mi) / COLORBASE);
+               lp->color[(i + 2) % 3 + 1] = MI_PIXEL(mi,
+                                         NRAND(MI_NPIXELS(mi) / COLORBASE) +
+                                            2 * MI_NPIXELS(mi) / COLORBASE);
+       } else
+               lp->color[1] = lp->color[2] = lp->color[3] = MI_WHITE_PIXEL(mi);
+       lp->color[4] = MI_WHITE_PIXEL(mi);
+       lp->width = MI_WIDTH(mi);
+       lp->height = MI_HEIGHT(mi);
+       lp->memstart = 1;
+       /*lp->tablesMade = 0; */
+
+       if (MI_IS_FULLRANDOM(mi)) {
+               lp->wireframe = (Bool) (LRAND() & 1);
+       } else {
+               lp->wireframe = MI_IS_WIREFRAME(mi);
+       }
+
+       MI_CLEARWINDOW(mi);
+       lp->painted = False;
+
+       if (lp->alt > 89)
+               lp->alt = 89;
+       else if (lp->alt < -89)
+               lp->alt = -89;
+       /* Calculate viewpoint */
+       lp->vx = (sin(lp->azm * IP) * cos(lp->alt * IP) * lp->dist);
+       lp->vy = (cos(lp->azm * IP) * cos(lp->alt * IP) * lp->dist);
+       lp->vz = (sin(lp->alt * IP) * lp->dist);
+       NewViewpoint(lp, lp->vx, lp->vy, lp->vz);
+
+       lp->patterned_rule = codeToPatternedRule(lp->param);
+       if ((unsigned) lp->patterned_rule < LIFE_RULES)
+               npats = patterns_rules[lp->patterned_rule];
+       else
+               npats = 0;
+       lp->pattern = NRAND(npats + 2);
+       if (lp->pattern >= npats && !filePattern)
+               RandomSoup(mi, 30, 10);
+       else
+               GetPattern(mi, lp->patterned_rule, lp->pattern);
+
+       DrawScreen(mi);
+}
+
+void
+draw_life3d(ModeInfo * mi)
+{
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+
+       RunLife3D(lp);
+       DrawScreen(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (++lp->generation > MI_CYCLES(mi) || !lp->visible) {
+               /*CountCells3D(lp) == 0) */
+               init_life3d(mi);
+       } else
+               lp->painted = True;
+
+       /*
+        * generate a randomized shooter aimed roughly toward the center of the
+        * screen after batchcount.
+        */
+
+       if (lp->generation && lp->generation %
+           ((MI_COUNT(mi) < 0) ? 1 : MI_COUNT(mi)) == 0)
+               shooter(lp);
+}
+
+void
+release_life3d(ModeInfo * mi)
+{
+       if (life3ds != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       life3dstruct *lp = &life3ds[screen];
+
+                       if (lp->eraserhead.next)
+                               End3D(lp);
+               }
+               (void) free((void *) life3ds);
+               life3ds = NULL;
+       }
+}
+
+void
+refresh_life3d(ModeInfo * mi)
+{
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+
+       if (lp->painted) {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+change_life3d(ModeInfo * mi)
+{
+       life3dstruct *lp = &life3ds[MI_SCREEN(mi)];
+       int         npats;
+
+       lp->generation = 0;
+
+       if (lp->eraserhead.next)
+               End3D(lp);
+       /*lp->tablesMade = 0; */
+
+       MI_CLEARWINDOW(mi);
+
+       lp->pattern++;
+       lp->patterned_rule = codeToPatternedRule(lp->param);
+       if ((unsigned) lp->patterned_rule < LIFE_RULES)
+               npats = patterns_rules[lp->patterned_rule];
+       else
+               npats = 0;
+       if (lp->pattern >= npats + 2) {
+               lp->pattern = 0;
+               if (allPatterns) {
+                       lp->patterned_rule++;
+                       if ((unsigned) lp->patterned_rule >= LIFE_RULES)
+                               lp->patterned_rule = 0;
+                       copyFromPatternedRule(&lp->param, lp->patterned_rule);
+                       if (MI_IS_VERBOSE(mi))
+                               printRule(lp->param);
+               } else if (allGliders) {
+                       lp->patterned_rule++;
+                       if (lp->patterned_rule >= LIFE_GLIDERS)
+                               lp->patterned_rule = 0;
+                       copyFromPatternedRule(&lp->param, lp->patterned_rule);
+                       if (MI_IS_VERBOSE(mi))
+                               printRule(lp->param);
+               }
+       }
+       if (lp->pattern >= npats)
+               RandomSoup(mi, 30, 10);
+       else
+               GetPattern(mi, lp->patterned_rule, lp->pattern);
+
+       DrawScreen(mi);
+}
+
+#endif /* MODE_life3d */
diff --git a/xlockmore-4.14/modes/lightning.c b/xlockmore-4.14/modes/lightning.c
new file mode 100644 (file)
index 0000000..d6fb3c5
--- /dev/null
@@ -0,0 +1,608 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* lightning --- fractal lightning bolds */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)lightning.c  4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by Keith Romberg <kromberg@saxe.com>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 14-Jul-96: Cleaned up code.
+ * 27-Jun-96: Written and submitted by Keith Romberg <kromberg@saxe.com>.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Lightning"
+#define HACK_INIT init_lightning
+#define HACK_DRAW draw_lightning
+#define lightning_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n"
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_lightning
+
+ModeSpecOpt lightning_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   lightning_description =
+{"lightning", "init_lightning", "draw_lightning", "release_lightning",
+ "refresh_lightning", "init_lightning", NULL, &lightning_opts,
+ 10000, 1, 1, 1, 64, 0.6, "",
+ "Shows Keith's fractal lightning bolts", 0, NULL};
+
+#endif
+
+#define BOLT_NUMBER 4
+#define BOLT_ITERATION 4
+#define LONG_FORK_ITERATION 3
+#define MEDIUM_FORK_ITERATION 2
+#define SMALL_FORK_ITERATION 1
+
+#define WIDTH_VARIATION 30
+#define HEIGHT_VARIATION 15
+
+#define DELAY_TIME_AMOUNT 15
+#define MULTI_DELAY_TIME_BASE 5
+
+#define MAX_WIGGLES 16
+#define WIGGLE_BASE 8
+#define WIGGLE_AMOUNT 14
+
+#define RANDOM_FORK_PROBILITY   4
+
+#define FIRST_LEVEL_STRIKE 0
+#define LEVEL_ONE_STRIKE 1
+#define LEVEL_TWO_STRIKE 2
+
+#define BOLT_VERTICIES ((1<<BOLT_ITERATION)-1)
+  /* BOLT_ITERATION = 4. 2^(BOLT_ITERATION) - 1 = 15 */
+
+#define NUMBER_FORK_VERTICIES 9
+
+#define FLASH_PROBILITY 20
+#define MAX_FLASH_AMOUNT 2     /*  half the total duration of the bolt  */
+
+typedef struct {
+       XPoint      ForkVerticies[NUMBER_FORK_VERTICIES];
+       int         num_used;
+} Fork;
+
+typedef struct {
+       XPoint      end1, end2;
+       XPoint      middle[BOLT_VERTICIES];
+       int         fork_number;
+       int         forks_start[2];
+       Fork        branch[2];
+       int         wiggle_number;
+       int         wiggle_amount;
+       int         delay_time;
+       int         flash;
+       int         flash_begin, flash_stop;
+       int         visible;
+       int         strike_level;
+} Lightning;
+
+typedef struct {
+       Lightning   bolts[BOLT_NUMBER];
+       int         scr_width, scr_height;
+       int         multi_strike;
+       int         give_it_hell;
+       int         draw_time;
+       int         stage;
+       int         busyLoop;
+       unsigned long color;
+} Storm;
+
+static Storm *Helga = NULL;
+
+/*-------------------   function prototypes  ----------------------------*/
+
+static int  distance(XPoint a, XPoint b);
+
+static int  setup_multi_strike(void);
+static int  flashing_strike(void);
+static void flash_duration(int *start, int *end, int total_duration);
+static void random_storm(Storm * st);
+static void generate(XPoint A, XPoint B, int iter, XPoint * verts, int *vert_index);
+static void create_fork(Fork * f, XPoint start, XPoint end, int level);
+
+static void first_strike(Lightning bolt, ModeInfo * mi);
+static void draw_bolt(Lightning * bolt, ModeInfo * mi);
+static void draw_line(ModeInfo * mi, XPoint * p, int number, GC use, int x_offset);
+static void level1_strike(Lightning bolt, ModeInfo * mi);
+static void level2_strike(Lightning bolt, ModeInfo * mi);
+
+static int  storm_active(Storm * st);
+static void update_bolt(Lightning * bolt, int time_now);
+static void wiggle_bolt(Lightning * bolt);
+static void wiggle_line(XPoint * p, int number, int wiggle_amount);
+
+/*-------------------------  functions  ---------------------------------*/
+
+static int
+setup_multi_strike(void)
+{
+       int         result, multi_prob;
+
+       multi_prob = NRAND(100);
+
+       if (multi_prob < 50)
+               result = 1;
+       else if ((multi_prob >= 51) && (multi_prob < 75))
+               result = 2;
+       else if ((multi_prob >= 76) && (multi_prob < 92))
+               result = 3;
+       else
+               result = BOLT_NUMBER;   /* 4 */
+
+       return (result);
+}
+
+/*-------------------------------------------------------------------------*/
+
+static int
+flashing_strike(void)
+{
+       int         tmp = NRAND(FLASH_PROBILITY);
+
+       if (tmp <= FLASH_PROBILITY)
+               return (1);
+       return (0);
+}
+
+/*-------------------------------------------------------------------------*/
+
+static void
+flash_duration(int *start, int *end, int total_duration)
+{
+       int         mid, d;
+
+       mid = total_duration / MAX_FLASH_AMOUNT;
+       d = NRAND(total_duration / MAX_FLASH_AMOUNT) / 2;
+       *start = mid - d;
+       *end = mid + d;
+}
+
+/*-------------------------------------------------------------------------*/
+
+static void
+random_storm(Storm * st)
+{
+       int         i, j, tmp;
+       XPoint      p;
+
+       for (i = 0; i < st->multi_strike; i++) {
+               st->bolts[i].end1.x = NRAND(st->scr_width);
+               st->bolts[i].end1.y = 0;
+               st->bolts[i].end2.x = NRAND(st->scr_width);
+               st->bolts[i].end2.y = st->scr_height;
+               st->bolts[i].wiggle_number = WIGGLE_BASE + NRAND(MAX_WIGGLES);
+               if ((st->bolts[i].flash = flashing_strike()))
+                       flash_duration(&(st->bolts[i].flash_begin), &(st->bolts[i].flash_stop),
+                                      st->bolts[i].wiggle_number);
+               else
+                       st->bolts[i].flash_begin = st->bolts[i].flash_stop = 0;
+               st->bolts[i].wiggle_amount = WIGGLE_AMOUNT;
+               if (i == 0)
+                       st->bolts[i].delay_time = NRAND(DELAY_TIME_AMOUNT);
+               else
+                       st->bolts[i].delay_time = NRAND(DELAY_TIME_AMOUNT) +
+                               (MULTI_DELAY_TIME_BASE * i);
+               st->bolts[i].strike_level = FIRST_LEVEL_STRIKE;
+               tmp = 0;
+               generate(st->bolts[i].end1, st->bolts[i].end2, BOLT_ITERATION,
+                        st->bolts[i].middle, &tmp);
+               st->bolts[i].fork_number = 0;
+               st->bolts[i].visible = 0;
+               for (j = 0; j < BOLT_VERTICIES; j++) {
+                       if (st->bolts[i].fork_number >= 2)
+                               break;
+                       if (NRAND(100) < RANDOM_FORK_PROBILITY) {
+                               p.x = NRAND(st->scr_width);
+                               p.y = st->scr_height;
+                               st->bolts[i].forks_start[st->bolts[i].fork_number] = j;
+                               create_fork(&(st->bolts[i].branch[st->bolts[i].fork_number]),
+                                           st->bolts[i].middle[j], p, j);
+                               st->bolts[i].fork_number++;
+                       }
+               }
+       }
+}
+
+static void
+generate(XPoint A, XPoint B, int iter, XPoint * verts, int *vert_index)
+{
+       XPoint      mid;
+
+       mid.x = (A.x + B.x) / 2 + NRAND(WIDTH_VARIATION) - WIDTH_VARIATION / 2;
+       mid.y = (A.y + B.y) / 2 + NRAND(HEIGHT_VARIATION) - HEIGHT_VARIATION / 2;
+
+       if (!iter) {
+               verts[*vert_index].x = mid.x;
+               verts[*vert_index].y = mid.y;
+               (*vert_index)++;
+               return;
+       }
+       generate(A, mid, iter - 1, verts, vert_index);
+       generate(mid, B, iter - 1, verts, vert_index);
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+create_fork(Fork * f, XPoint start, XPoint end, int level)
+{
+       int         tmp = 1;
+
+       f->ForkVerticies[0].x = start.x;
+       f->ForkVerticies[0].y = start.y;
+
+       if (level <= 6) {
+               generate(start, end, LONG_FORK_ITERATION, f->ForkVerticies, &tmp);
+               f->num_used = 9;
+       } else if ((level > 6) && (level <= 11)) {
+               generate(start, end, MEDIUM_FORK_ITERATION, f->ForkVerticies, &tmp);
+               f->num_used = 5;
+       } else {
+               if (distance(start, end) > 100) {
+                       generate(start, end, MEDIUM_FORK_ITERATION, f->ForkVerticies, &tmp);
+                       f->num_used = 5;
+               } else {
+                       generate(start, end, SMALL_FORK_ITERATION, f->ForkVerticies, &tmp);
+                       f->num_used = 3;
+               }
+       }
+
+       f->ForkVerticies[f->num_used - 1].x = end.x;
+       f->ForkVerticies[f->num_used - 1].y = end.y;
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+update_bolt(Lightning * bolt, int time_now)
+{
+       wiggle_bolt(bolt);
+       if ((bolt->wiggle_amount == 0) && (bolt->wiggle_number > 2))
+               bolt->wiggle_number = 0;
+       if (((time_now % 3) == 0))
+               bolt->wiggle_amount++;
+
+       if (((time_now >= bolt->delay_time) && (time_now < bolt->flash_begin)) ||
+           (time_now > bolt->flash_stop))
+               bolt->visible = 1;
+       else
+               bolt->visible = 0;
+
+       if (time_now == bolt->delay_time)
+               bolt->strike_level = FIRST_LEVEL_STRIKE;
+       else if (time_now == (bolt->delay_time + 1))
+               bolt->strike_level = LEVEL_ONE_STRIKE;
+       else if ((time_now > (bolt->delay_time + 1)) &&
+                (time_now <= (bolt->delay_time + bolt->flash_begin - 2)))
+               bolt->strike_level = LEVEL_TWO_STRIKE;
+       else if (time_now == (bolt->delay_time + bolt->flash_begin - 1))
+               bolt->strike_level = LEVEL_ONE_STRIKE;
+       else if (time_now == (bolt->delay_time + bolt->flash_stop + 1))
+               bolt->strike_level = LEVEL_ONE_STRIKE;
+       else
+               bolt->strike_level = LEVEL_TWO_STRIKE;
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+draw_bolt(Lightning * bolt, ModeInfo * mi)
+{
+       if (bolt->visible) {
+               if (bolt->strike_level == FIRST_LEVEL_STRIKE)
+                       first_strike(*bolt, mi);
+               else if (bolt->strike_level == LEVEL_ONE_STRIKE)
+                       level1_strike(*bolt, mi);
+               else
+                       level2_strike(*bolt, mi);
+       }
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+first_strike(Lightning bolt, ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       int         i;
+
+       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       XDrawLine(display, window, gc,
+              bolt.end1.x, bolt.end1.y, bolt.middle[0].x, bolt.middle[0].y);
+       draw_line(mi, bolt.middle, BOLT_VERTICIES, gc, 0);
+       XDrawLine(display, window, gc,
+       bolt.middle[BOLT_VERTICIES - 1].x, bolt.middle[BOLT_VERTICIES - 1].y,
+                 bolt.end2.x, bolt.end2.y);
+
+       for (i = 0; i < bolt.fork_number; i++)
+               draw_line(mi, bolt.branch[i].ForkVerticies, bolt.branch[i].num_used,
+                         gc, 0);
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+draw_line(ModeInfo * mi, XPoint * points, int number, GC to_use, int offset)
+{
+       int         i;
+
+       for (i = 0; i < number - 1; i++) {
+               if (points[i].y <= points[i + 1].y)
+                       XDrawLine(MI_DISPLAY(mi), MI_WINDOW(mi), to_use, points[i].x + offset,
+                                 points[i].y, points[i + 1].x + offset, points[i + 1].y);
+               else {
+                       if (points[i].x < points[i + 1].x)
+                               XDrawLine(MI_DISPLAY(mi), MI_WINDOW(mi), to_use, points[i].x +
+                                         offset, points[i].y + offset, points[i + 1].x + offset,
+                                         points[i + 1].y + offset);
+                       else
+                               XDrawLine(MI_DISPLAY(mi), MI_WINDOW(mi), to_use, points[i].x -
+                                         offset, points[i].y + offset, points[i + 1].x - offset,
+                                         points[i + 1].y + offset);
+               }
+       }
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+level1_strike(Lightning bolt, ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       Storm      *st = &Helga[MI_SCREEN(mi)];
+       GC          gc = MI_GC(mi);
+       int         i;
+
+       if (MI_NPIXELS(mi) > 2) /* color */
+               XSetForeground(display, gc, MI_PIXEL(mi, st->color));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       XDrawLine(display, window, gc,
+       bolt.end1.x - 1, bolt.end1.y, bolt.middle[0].x - 1, bolt.middle[0].y);
+       draw_line(mi, bolt.middle, BOLT_VERTICIES, gc, -1);
+       XDrawLine(display, window, gc,
+                 bolt.middle[BOLT_VERTICIES - 1].x - 1,
+           bolt.middle[BOLT_VERTICIES - 1].y, bolt.end2.x - 1, bolt.end2.y);
+       XDrawLine(display, window, gc,
+       bolt.end1.x + 1, bolt.end1.y, bolt.middle[0].x + 1, bolt.middle[0].y);
+       draw_line(mi, bolt.middle, BOLT_VERTICIES, gc, 1);
+       XDrawLine(display, window, gc,
+                 bolt.middle[BOLT_VERTICIES - 1].x + 1,
+           bolt.middle[BOLT_VERTICIES - 1].y, bolt.end2.x + 1, bolt.end2.y);
+
+       for (i = 0; i < bolt.fork_number; i++) {
+               draw_line(mi, bolt.branch[i].ForkVerticies, bolt.branch[i].num_used,
+                         gc, -1);
+               draw_line(mi, bolt.branch[i].ForkVerticies, bolt.branch[i].num_used,
+                         gc, 1);
+       }
+       first_strike(bolt, mi);
+}
+
+/*------------------------------------------------------------------------*/
+
+static int
+distance(XPoint a, XPoint b)
+{
+       return ((int) sqrt((a.x - b.x) * (a.x - b.x) + (a.y - b.y) * (a.y - b.y)));
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+level2_strike(Lightning bolt, ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       Storm      *st = &Helga[MI_SCREEN(mi)];
+       GC          gc = MI_GC(mi);
+       int         i;
+
+       /* This was originally designed to be a little darker then the
+          level1 strike.  This was changed to get it to work on
+          multiscreens and to add more color variety.   I tried
+          stippling but it did not look good. */
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, st->color));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       XDrawLine(display, window, gc,
+       bolt.end1.x - 2, bolt.end1.y, bolt.middle[0].x - 2, bolt.middle[0].y);
+       draw_line(mi, bolt.middle, BOLT_VERTICIES, gc, -2);
+       XDrawLine(display, window, gc,
+                 bolt.middle[BOLT_VERTICIES - 1].x - 2,
+           bolt.middle[BOLT_VERTICIES - 1].y, bolt.end2.x - 2, bolt.end2.y);
+
+       XDrawLine(display, window, gc,
+       bolt.end1.x + 2, bolt.end1.y, bolt.middle[0].x + 2, bolt.middle[0].y);
+       draw_line(mi, bolt.middle, BOLT_VERTICIES, gc, 2);
+       XDrawLine(display, window, gc,
+                 bolt.middle[BOLT_VERTICIES - 1].x + 2,
+           bolt.middle[BOLT_VERTICIES - 1].y, bolt.end2.x + 2, bolt.end2.y);
+
+       for (i = 0; i < bolt.fork_number; i++) {
+               draw_line(mi, bolt.branch[i].ForkVerticies, bolt.branch[i].num_used,
+                         gc, -2);
+               draw_line(mi, bolt.branch[i].ForkVerticies, bolt.branch[i].num_used,
+                         gc, 2);
+       }
+       level1_strike(bolt, mi);
+}
+
+/*------------------------------------------------------------------------*/
+
+static int
+storm_active(Storm * st)
+{
+       int         i, atleast_1 = 0;
+
+       for (i = 0; i < st->multi_strike; i++)
+               if (st->bolts[i].wiggle_number > 0)
+                       atleast_1++;
+
+       return (atleast_1);
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+wiggle_bolt(Lightning * bolt)
+{
+       int         i;
+
+       wiggle_line(bolt->middle, BOLT_VERTICIES, bolt->wiggle_amount);
+       bolt->end2.x += NRAND(bolt->wiggle_amount) - bolt->wiggle_amount / 2;
+       bolt->end2.y += NRAND(bolt->wiggle_amount) - bolt->wiggle_amount / 2;
+
+       for (i = 0; i < bolt->fork_number; i++) {
+               wiggle_line(bolt->branch[i].ForkVerticies, bolt->branch[i].num_used,
+                           bolt->wiggle_amount);
+               bolt->branch[i].ForkVerticies[0].x = bolt->middle[bolt->forks_start[i]].x;
+               bolt->branch[i].ForkVerticies[0].y = bolt->middle[bolt->forks_start[i]].y;
+       }
+
+       if (bolt->wiggle_amount > 1)
+               bolt->wiggle_amount -= 1;
+       else
+               bolt->wiggle_amount = 0;
+}
+
+/*------------------------------------------------------------------------*/
+
+static void
+wiggle_line(XPoint * p, int number, int amount)
+{
+       int         i;
+
+       for (i = 0; i < number; i++) {
+               p[i].x += NRAND(amount) - amount / 2;
+               p[i].y += NRAND(amount) - amount / 2;
+       }
+}
+
+/*------------------------------------------------------------------------*/
+
+void
+init_lightning(ModeInfo * mi)
+{
+       Storm      *st;
+
+       if (Helga == NULL) {
+               if ((Helga = (Storm *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (Storm))) == NULL)
+                       return;
+       }
+       st = &Helga[MI_SCREEN(mi)];
+
+       st->scr_width = MI_WIDTH(mi);
+       st->scr_height = MI_HEIGHT(mi);
+
+       st->multi_strike = setup_multi_strike();
+       random_storm(st);
+       st->stage = 0;
+}
+
+/*------------------------------------------------------------------------*/
+
+void
+draw_lightning(ModeInfo * mi)
+{
+       Storm      *st = &Helga[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       switch (st->stage) {
+               case 0:
+                       MI_IS_DRAWN(mi) = False;
+                       MI_CLEARWINDOW(mi);
+                       MI_IS_DRAWN(mi) = True;
+
+                       st->color = NRAND(MI_NPIXELS(mi));
+                       st->draw_time = 0;
+                       if (storm_active(st))
+                               st->stage++;
+                       else
+                               st->stage = 4;
+                       break;
+               case 1:
+                       for (i = 0; i < st->multi_strike; i++) {
+                               if (st->bolts[i].visible)
+                                       draw_bolt(&(st->bolts[i]), mi);
+                               update_bolt(&(st->bolts[i]), st->draw_time);
+                       }
+                       st->draw_time++;
+                       st->stage++;
+                       st->busyLoop = 0;
+                       break;
+               case 2:
+                       if (++st->busyLoop > 6) {
+                               st->stage++;
+                               st->busyLoop = 0;
+                       }
+                       break;
+               case 3:
+                       MI_IS_DRAWN(mi) = False;
+                       MI_CLEARWINDOW(mi);
+                       MI_IS_DRAWN(mi) = True;
+
+                       if (storm_active(st))
+                               st->stage = 1;
+                       else
+                               st->stage++;
+                       break;
+               case 4:
+                       if (++st->busyLoop > 100) {
+                               st->busyLoop = 0;
+                       }
+                       init_lightning(mi);
+                       break;
+       }
+}
+
+void
+release_lightning(ModeInfo * mi)
+{
+       if (Helga != NULL) {
+               (void) free((void *) Helga);
+               Helga = NULL;
+       }
+}
+
+void
+refresh_lightning(ModeInfo * mi)
+{
+       /* Do nothing, it will refresh by itself */
+}
+
+#endif /* MODE_lightning */
diff --git a/xlockmore-4.14/modes/lisa.c b/xlockmore-4.14/modes/lisa.c
new file mode 100644 (file)
index 0000000..a4ad686
--- /dev/null
@@ -0,0 +1,517 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* lisa --- animated full-loop lisajous figures */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)lisa.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by Caleb Cullen.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ *
+ * The inspiration for this program, Lasp, was written by Adam B. Roach 
+ * in 1990, assisted by me, Caleb Cullen.  It was written first in C, then
+ * in assembly, and used pre-calculated data tables to graph lisajous
+ * figures on 386 machines and lower.  This version bears only superficial
+ * resemblances to the original Lasp.
+ *
+ * The `lissie' module's source code was studied as an example of how
+ * to incorporate a new module into xlock.  Resemblances to it are
+ * expected, but not intended to be plaigiaristic.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Lisa"
+#define HACK_INIT init_lisa
+#define HACK_DRAW draw_lisa
+#define lisa_opts xlockmore_opts
+#define DEFAULTS "*delay: 25000 \n" \
+ "*count: 1 \n" \
+ "*cycles: 256 \n" \
+ "*size: -1 \n" \
+ "*ncolors: 200 \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_lisa
+
+#define  DEF_ADDITIVE     "True"
+
+static Bool additive;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-additive", ".lisa.additive", XrmoptionNoArg, (caddr_t) "True"},
+       {"+additive", ".lisa.additive", XrmoptionNoArg, (caddr_t) "False"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & additive, "additive", "Additive", DEF_ADDITIVE, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-/+additive", "turn on/off additive functions mode"}
+};
+
+ModeSpecOpt lisa_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   lisa_description =
+{"lisa", "init_lisa", "draw_lisa", "release_lisa",
+ "refresh_lisa", "change_lisa", NULL, &lisa_opts,
+ 25000, 1, 256, -1, 64, 1.0, "",
+ "Shows animated lisajous loops", 0, NULL};
+
+#endif
+
+#define  DRAWLINES    1
+#define  TWOLOOPS     1
+#define  XVMAX        10       /* Maximum velocities */
+#define  YVMAX        10
+#define  LISAMAXFUNCS 2
+#define  NUMSTDFUNCS  10
+#define  MAXCYCLES    3
+#define  MINLISAS     1
+#define  lisasetcolor() \
+if (MI_NPIXELS(mi) > 2) { \
+  XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_PIXEL(mi, loop->color)); \
+  if (++(loop->color) >= (unsigned) MI_NPIXELS(mi)) { loop->color=0; } \
+  } else { XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WHITE_PIXEL(mi)); }
+#define getRadius(context) \
+  ((context->width > context->height)?context->height:context->width) * 3 / 8
+#define checkRadius(loop, context) \
+  if ((context->height / 2 > MI_SIZE(mi)) && (context->width / 2 > MI_SIZE(mi))) \
+      loop->radius = MI_SIZE(mi); \
+  if ((loop->radius < 0) || \
+      (loop->radius > loop->center.x) || \
+      (loop->radius > loop->center.y)) loop->radius = getRadius(context)
+
+
+typedef struct lisafunc_struct {
+       double      xcoeff[2], ycoeff[2];
+       int         nx, ny;
+       int         index;
+} lisafuncs;
+
+typedef struct lisa_struct {
+       unsigned long color;
+       int         radius, dx, dy, nsteps, nfuncs, melting;
+       double      pistep, phi, theta;
+       XPoint      center, *lastpoint;
+       lisafuncs  *function[LISAMAXFUNCS];
+       int         linewidth;
+} lisas;
+
+typedef struct lisacontext_struct {
+       lisas      *lisajous;
+       int         width, height, nlisajous, loopcount;
+       int         maxcycles;
+       Bool        painted;
+} lisacons;
+
+static lisacons *Lisa = NULL;
+
+static lisafuncs Function[NUMSTDFUNCS] =
+{
+       {
+               {1.0, 2.0},
+               {1.0, 2.0}, 2, 2, 0},
+       {
+               {1.0, 2.0},
+               {1.0, 1.0}, 2, 2, 1},
+       {
+               {1.0, 3.0},
+               {1.0, 2.0}, 2, 2, 2},
+       {
+               {1.0, 3.0},
+               {1.0, 3.0}, 2, 2, 3},
+       {
+               {2.0, 4.0},
+               {1.0, 2.0}, 2, 2, 4},
+       {
+               {1.0, 4.0},
+               {1.0, 3.0}, 2, 2, 5},
+       {
+               {1.0, 4.0},
+               {1.0, 4.0}, 2, 2, 6},
+       {
+               {1.0, 5.0},
+               {1.0, 5.0}, 2, 2, 7},
+       {
+               {2.0, 5.0},
+               {2.0, 5.0}, 2, 2, 8},
+       {
+               {1.0, 0.0},
+               {1.0, 0.0}, 1, 1, 9}
+};
+
+static void
+drawlisa(ModeInfo * mi, lisas * loop)
+{
+       XPoint     *np;
+       XPoint     *lp = loop->lastpoint;
+       lisacons   *lc = &Lisa[MI_SCREEN(mi)];
+       lisafuncs **lf = loop->function;
+       int         phase = lc->loopcount % loop->nsteps;
+       int         pctr, fctr, xctr, yctr;
+       double      xprod, yprod, xsum, ysum;
+
+       /* Allocate the np array */
+       np = (XPoint *) calloc(loop->nsteps, sizeof (XPoint));
+
+       /* Update the center */
+       loop->center.x += loop->dx;
+       loop->center.y += loop->dy;
+       checkRadius(loop, lc);
+       if ((loop->center.x - loop->radius) <= 0) {
+               loop->center.x = loop->radius;
+               loop->dx = NRAND(XVMAX);
+       } else if ((loop->center.x + loop->radius) >= lc->width) {
+               loop->center.x = lc->width - loop->radius;
+               loop->dx = -NRAND(XVMAX);
+       };
+       if ((loop->center.y - loop->radius) <= 0) {
+               loop->center.y = loop->radius;
+               loop->dy = NRAND(YVMAX);
+       } else if ((loop->center.y + loop->radius) >= lc->height) {
+               loop->center.y = lc->height - loop->radius;
+               loop->dy = -NRAND(YVMAX);
+       };
+
+       /* Now draw the points, and erase the ones from the last cycle */
+
+       for (pctr = 0; pctr < loop->nsteps; pctr++) {
+               fctr = loop->nfuncs;
+               loop->phi = (double) (pctr - phase) * loop->pistep;
+               loop->theta = (double) (pctr + phase) * loop->pistep;
+               xsum = ysum = 0;
+               while (fctr--) {
+                       xctr = lf[fctr]->nx;
+                       yctr = lf[fctr]->ny;
+                       if (additive) {
+                               xprod = yprod = 0.0;
+                               while (xctr--)
+                                       xprod += sin(lf[fctr]->xcoeff[xctr] * loop->theta);
+                               while (yctr--)
+                                       yprod += sin(lf[fctr]->ycoeff[yctr] * loop->phi);
+                               if (loop->melting) {
+                                       if (fctr) {
+                                               xsum += xprod * (double) (loop->nsteps - loop->melting) /
+                                                       (double) loop->nsteps;
+                                               ysum += yprod * (double) (loop->nsteps - loop->melting) /
+                                                       (double) loop->nsteps;
+                                       } else {
+                                               xsum += xprod * (double) loop->melting / (double) loop->nsteps;
+                                               ysum += yprod * (double) loop->melting / (double) loop->nsteps;
+                                       }
+                               } else {
+                                       xsum = xprod;
+                                       ysum = yprod;
+                               }
+                               if (!fctr) {
+                                       xsum = xsum * (double) loop->radius / (double) lf[fctr]->nx;
+                                       ysum = ysum * (double) loop->radius / (double) lf[fctr]->ny;
+                               }
+                       } else {
+                               if (loop->melting) {
+                                       if (fctr) {
+                                               yprod = xprod = (double) loop->radius *
+                                                       (double) (loop->nsteps - loop->melting) /
+                                                       (double) (loop->nsteps);
+                                       } else {
+                                               yprod = xprod = (double) loop->radius *
+                                                       (double) (loop->melting) / (double) (loop->nsteps);
+                                       }
+                               } else {
+                                       xprod = yprod = (double) loop->radius;
+                               }
+                               while (xctr--)
+                                       xprod *= sin(lf[fctr]->xcoeff[xctr] * loop->theta);
+                               while (yctr--)
+                                       yprod *= sin(lf[fctr]->ycoeff[yctr] * loop->phi);
+                               xsum += xprod;
+                               ysum += yprod;
+                       }
+               }
+               if ((loop->nfuncs > 1) && (!loop->melting)) {
+                       xsum /= (double) loop->nfuncs;
+                       ysum /= (double) loop->nfuncs;
+               }
+               xsum += (double) loop->center.x;
+               ysum += (double) loop->center.y;
+
+               np[pctr].x = (int) ceil(xsum);
+               np[pctr].y = (int) ceil(ysum);
+       }
+       if (loop->melting) {
+               if (!--loop->melting) {
+                       loop->nfuncs = 1;
+                       loop->function[0] = loop->function[1];
+               }
+       }
+       for (pctr = 0; pctr < loop->nsteps; pctr++) {
+
+#if defined DRAWLINES
+               XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), loop->linewidth,
+                                  LineSolid, CapProjecting, JoinMiter);
+               /* erase the last cycle's point */
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+               XDrawLine(MI_DISPLAY(mi), MI_WINDOW(mi),
+                         MI_GC(mi), lp[pctr].x, lp[pctr].y,
+                         lp[(pctr + 1) % loop->nsteps].x,
+                         lp[(pctr + 1) % loop->nsteps].y);
+
+               /* Set the new color */
+               lisasetcolor();
+
+               /* plot this cycle's point */
+               XDrawLine(MI_DISPLAY(mi), MI_WINDOW(mi),
+                         MI_GC(mi), np[pctr].x, np[pctr].y,
+                         np[(pctr + 1) % loop->nsteps].x,
+                         np[(pctr + 1) % loop->nsteps].y);
+               XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), 1,
+                                  LineSolid, CapProjecting, JoinMiter);
+#else
+               /* erase the last cycle's point */
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_BLACK_PIXEL(mi));
+               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi),
+                          MI_GC(mi), lp[pctr].x, lp[pctr].y);
+
+               /* Set the new color */
+               lisasetcolor();
+
+               /* plot this cycle's point */
+               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi),
+                          MI_GC(mi), np[pctr].x, np[pctr].y);
+#endif
+       }
+       (void) free((void *) lp);
+       loop->lastpoint = np;
+}
+
+static void
+initlisa(ModeInfo * mi, lisas * loop)
+{
+       lisacons   *lc = &Lisa[MI_SCREEN(mi)];
+       lisafuncs **lf = loop->function;
+       XPoint     *lp;
+       int         phase, pctr, fctr, xctr, yctr;
+       double      xprod, yprod, xsum, ysum;
+
+       if (MI_NPIXELS(mi) > 2) {
+               loop->color = 0;
+       } else
+               loop->color = MI_WHITE_PIXEL(mi);
+       loop->nsteps = MI_CYCLES(mi);
+       if (loop->nsteps == 0)
+               loop->nsteps = 1;
+       lc->maxcycles = (MAXCYCLES * loop->nsteps) - 1;
+       loop->melting = 0;
+       loop->nfuncs = 1;
+       loop->pistep = 2.0 * M_PI / (double) loop->nsteps;
+       loop->center.x = lc->width / 2;
+       loop->center.y = lc->height / 2;
+       loop->radius = (int) MI_SIZE(mi);
+       checkRadius(loop, lc);
+       loop->dx = NRAND(XVMAX);
+       loop->dy = NRAND(YVMAX);
+       loop->dx++;
+       loop->dy++;
+       lf[0] = &Function[lc->loopcount % NUMSTDFUNCS];
+       if ((lp = loop->lastpoint = (XPoint *)
+            calloc(loop->nsteps, sizeof (XPoint))) == NULL)
+               return;
+       phase = lc->loopcount % loop->nsteps;
+
+       for (pctr = 0; pctr < loop->nsteps; pctr++) {
+               loop->phi = (double) (pctr - phase) * loop->pistep;
+               loop->theta = (double) (pctr + phase) * loop->pistep;
+               fctr = loop->nfuncs;
+               xsum = ysum = 0.0;
+               while (fctr--) {
+                       xprod = yprod = (double) loop->radius;
+                       xctr = lf[fctr]->nx;
+                       yctr = lf[fctr]->ny;
+                       while (xctr--)
+                               xprod *= sin(lf[fctr]->xcoeff[xctr] * loop->theta);
+                       while (yctr--)
+                               yprod *= sin(lf[fctr]->ycoeff[yctr] * loop->phi);
+                       xsum += xprod;
+                       ysum += yprod;
+               }
+               if (loop->nfuncs > 1) {
+                       xsum /= 2.0;
+                       ysum /= 2.0;
+               }
+               xsum += (double) loop->center.x;
+               ysum += (double) loop->center.y;
+
+               lp[pctr].x = (int) ceil(xsum);
+               lp[pctr].y = (int) ceil(ysum);
+       }
+#if defined DRAWLINES
+       {
+               loop->linewidth = -8;   /* #### make this a resource */
+
+               if (loop->linewidth == 0)
+                       loop->linewidth = 1;
+               if (loop->linewidth < 0)
+                       loop->linewidth = NRAND(-loop->linewidth) + 1;
+               XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), loop->linewidth,
+                                  LineSolid, CapProjecting, JoinMiter);
+       }
+#endif
+       for (pctr = 0; pctr < loop->nsteps; pctr++) {
+               /* Set the color */
+               lisasetcolor();
+#if defined DRAWLINES
+               XDrawLine(MI_DISPLAY(mi), MI_WINDOW(mi),
+                         MI_GC(mi), lp[pctr].x, lp[pctr].y,
+                         lp[(pctr + 1) % loop->nsteps].x,
+                         lp[(pctr + 1) % loop->nsteps].y);
+#else
+               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                          lp[pctr].x, lp[pctr].y);
+#endif
+       }
+#if defined DRAWLINES
+       XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), 1,
+                          LineSolid, CapProjecting, JoinMiter);
+#endif
+
+}
+
+static void
+refreshlisa(ModeInfo * mi)
+{
+       lisacons   *lc = &Lisa[MI_SCREEN(mi)];
+       int         lctr;
+
+       for (lctr = 0; lctr < lc->nlisajous; lctr++) {
+               drawlisa(mi, &lc->lisajous[lctr]);
+       }
+}
+
+void
+refresh_lisa(ModeInfo * mi)
+{
+       lisacons   *lc = &Lisa[MI_SCREEN(mi)];
+
+       if (lc->painted) {
+               lc->painted = False;
+               MI_CLEARWINDOW(mi);
+               refreshlisa(mi);
+       }
+}
+
+void
+change_lisa(ModeInfo * mi)
+{
+       lisacons   *lc = &Lisa[MI_SCREEN(mi)];
+       lisas      *loop;
+       int         lctr;
+
+       lc->loopcount = 0;
+       for (lctr = 0; lctr < lc->nlisajous; lctr++) {
+               loop = &lc->lisajous[lctr];
+               loop->function[1] = &Function[(loop->function[0]->index + 1) %
+                                             NUMSTDFUNCS];
+               loop->melting = loop->nsteps - 1;
+               loop->nfuncs = 2;
+       }
+}
+
+void
+init_lisa(ModeInfo * mi)
+{
+       lisacons   *lc;
+       int         lctr;
+
+       if (Lisa == NULL) {
+               if ((Lisa = (lisacons *) calloc(MI_NUM_SCREENS(mi), sizeof (lisacons)))
+                   == NULL)
+                       return;
+       }
+       lc = &Lisa[MI_SCREEN(mi)];
+       lc->width = MI_WIDTH(mi);
+       lc->height = MI_HEIGHT(mi);
+       lc->loopcount = 0;
+       lc->nlisajous = MI_COUNT(mi);
+       if (lc->nlisajous <= 0)
+               lc->nlisajous = 1;
+       MI_CLEARWINDOW(mi);
+       lc->painted = False;
+
+       if (lc->lisajous == NULL) {
+               if ((lc->lisajous = (lisas *) calloc(lc->nlisajous, sizeof (lisas)))
+                   == NULL)
+                       return;
+               for (lctr = 0; lctr < lc->nlisajous; lctr++) {
+                       initlisa(mi, &lc->lisajous[lctr]);
+                       lc->loopcount++;
+               }
+       } else {
+               refreshlisa(mi);
+       }
+}
+
+void
+draw_lisa(ModeInfo * mi)
+{
+       lisacons   *lc = &Lisa[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       lc->painted = True;
+       if (++lc->loopcount > lc->maxcycles) {
+               change_lisa(mi);
+       }
+       refreshlisa(mi);
+}
+
+void
+release_lisa(ModeInfo * mi)
+{
+       lisacons   *lc;
+       int         lctr, sctr;
+
+       if (Lisa) {
+               for (sctr = 0; sctr < MI_NUM_SCREENS(mi); sctr++) {
+                       lc = &Lisa[sctr];
+                       while (lc->lisajous) {
+                               for (lctr = 0; lctr < lc->nlisajous; lctr++) {
+                                       (void) free(lc->lisajous[lctr].lastpoint);
+                               }
+                               (void) free(lc->lisajous);
+                               lc->lisajous = NULL;
+                       }
+               }
+               (void) free(Lisa);
+               Lisa = NULL;
+       }
+}
+
+#endif /* MODE_lisa */
diff --git a/xlockmore-4.14/modes/lissie.c b/xlockmore-4.14/modes/lissie.c
new file mode 100644 (file)
index 0000000..23ad4da
--- /dev/null
@@ -0,0 +1,309 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* lissie --- the Lissajous worm */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)lissie.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * lissie.c - The Lissajous worm for xlock, the X Window System
+ *               lockscreen.
+ *
+ * Copyright (c) 1996 by Alexander Jolk <ub9x@rz.uni-karlsruhe.de>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 18-Aug-96: added refresh-hook.
+ * 01-May-96: written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Lissie"
+#define HACK_INIT init_lissie
+#define HACK_DRAW draw_lissie
+#define lissie_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 1 \n" \
+ "*cycles: 20000 \n" \
+ "*size: -200 \n" \
+ "*ncolors: 200 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_lissie
+
+ModeSpecOpt lissie_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   lissie_description =
+{"lissie", "init_lissie", "draw_lissie", "release_lissie",
+ "refresh_lissie", "init_lissie", NULL, &lissie_opts,
+ 10000, 1, 2000, -200, 64, 0.6, "",
+ "Shows lissajous worms", 0, NULL};
+
+#endif
+
+#define MINSIZE 1
+
+#define Lissie(n)\
+       if (lissie->loc[(n)].x > 0 && lissie->loc[(n)].y > 0 &&\
+               lissie->loc[(n)].x <= lp->width && lissie->loc[(n)].y <= lp->height) {\
+               if (lissie->ri < 2)\
+                       XDrawPoint(display, MI_WINDOW(mi),\
+                               gc, lissie->loc[(n)].x, lissie->loc[(n)].y);\
+               else\
+                       XDrawArc(display, MI_WINDOW(mi), gc,\
+                               lissie->loc[(n)].x - lissie->ri / 2,\
+                               lissie->loc[(n)].y - lissie->ri / 2,\
+                               lissie->ri, lissie->ri, 0, 23040);\
+       }
+
+#define FLOATRAND(min,max)     ((min)+(LRAND()/MAXRAND)*((max)-(min)))
+#define INTRAND(min,max)     ((min)+NRAND((max)-(min)+1))
+
+#define MINDT  0.01
+#define MAXDT  0.15
+
+#define MAXLISSIELEN  100
+#define MINLISSIELEN  10
+#define MINLISSIES 1
+
+/* How many segments to draw per cycle when redrawing */
+#define REDRAWSTEP 3
+
+typedef struct {
+       double      tx, ty, dtx, dty;
+       int         xi, yi, ri, rx, ry, len, pos;
+       int         redrawing, redrawpos;
+       XPoint      loc[MAXLISSIELEN];
+       unsigned long color;
+} lissiestruct;
+
+typedef struct {
+       Bool        painted;
+       int         width, height;
+       int         nlissies;
+       lissiestruct *lissie;
+       int         loopcount;
+} lissstruct;
+
+static lissstruct *lisses = NULL;
+
+
+static void
+drawlissie(ModeInfo * mi, lissiestruct * lissie)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       lissstruct *lp = &lisses[MI_SCREEN(mi)];
+       int         p = (++lissie->pos) % MAXLISSIELEN;
+       int         oldp = (lissie->pos - lissie->len + MAXLISSIELEN) % MAXLISSIELEN;
+
+       /* Let time go by ... */
+       lissie->tx += lissie->dtx;
+       lissie->ty += lissie->dty;
+       if (lissie->tx > 2 * M_PI)
+               lissie->tx -= 2 * M_PI;
+       if (lissie->ty > 2 * M_PI)
+               lissie->ty -= 2 * M_PI;
+
+       /* vary both (x/y) speeds by max. 1% */
+       lissie->dtx *= FLOATRAND(0.99, 1.01);
+       lissie->dty *= FLOATRAND(0.99, 1.01);
+       if (lissie->dtx < MINDT)
+               lissie->dtx = MINDT;
+       else if (lissie->dtx > MAXDT)
+               lissie->dtx = MAXDT;
+       if (lissie->dty < MINDT)
+               lissie->dty = MINDT;
+       else if (lissie->dty > MAXDT)
+               lissie->dty = MAXDT;
+
+       lissie->loc[p].x = lissie->xi + (int) (sin(lissie->tx) * lissie->rx);
+       lissie->loc[p].y = lissie->yi + (int) (sin(lissie->ty) * lissie->ry);
+
+       /* Mask */
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       Lissie(oldp);
+
+       /* Redraw */
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, lissie->color));
+               if (++lissie->color >= (unsigned) MI_NPIXELS(mi))
+                       lissie->color = 0;
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       Lissie(p);
+       if (lissie->redrawing) {
+               int         i;
+
+               lissie->redrawpos++;
+               /* This compensates for the changed p
+                  since the last callback. */
+
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       Lissie((p - lissie->redrawpos + MAXLISSIELEN) % MAXLISSIELEN);
+                       if (++(lissie->redrawpos) >= lissie->len) {
+                               lissie->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+static void
+initlissie(ModeInfo * mi, lissiestruct * lissie)
+{
+       lissstruct *lp = &lisses[MI_SCREEN(mi)];
+       int         size = MI_SIZE(mi);
+       int         i;
+
+       if (MI_NPIXELS(mi) > 2)
+               lissie->color = NRAND(MI_NPIXELS(mi));
+       else
+               lissie->color = MI_WHITE_PIXEL(mi);
+       /* Initialize parameters */
+       if (size < -MINSIZE)
+               lissie->ri = NRAND(MIN(-size, MAX(MINSIZE,
+                  MIN(lp->width, lp->height) / 4)) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE) {
+               if (!size)
+                       lissie->ri = MAX(MINSIZE, MIN(lp->width, lp->height) / 4);
+               else
+                       lissie->ri = MINSIZE;
+       } else
+               lissie->ri = MIN(size, MAX(MINSIZE, MIN(lp->width, lp->height) / 4));
+       lissie->xi = INTRAND(lp->width / 4 + lissie->ri,
+                            lp->width * 3 / 4 - lissie->ri);
+       lissie->yi = INTRAND(lp->height / 4 + lissie->ri,
+                            lp->height * 3 / 4 - lissie->ri);
+       lissie->rx = INTRAND(lp->width / 4,
+                  MIN(lp->width - lissie->xi, lissie->xi)) - 2 * lissie->ri;
+       lissie->ry = INTRAND(lp->height / 4,
+                 MIN(lp->height - lissie->yi, lissie->yi)) - 2 * lissie->ri;
+       lissie->len = INTRAND(MINLISSIELEN, MAXLISSIELEN - 1);
+       lissie->pos = 0;
+
+       lissie->redrawing = 0;
+
+       lissie->tx = FLOATRAND(0, 2 * M_PI);
+       lissie->ty = FLOATRAND(0, 2 * M_PI);
+       lissie->dtx = FLOATRAND(MINDT, MAXDT);
+       lissie->dty = FLOATRAND(MINDT, MAXDT);
+
+       for (i = 0; i < MAXLISSIELEN; i++)
+               lissie->loc[i].x = lissie->loc[i].y = 0;
+       /* Draw lissie */
+       drawlissie(mi, lissie);
+}
+
+void
+init_lissie(ModeInfo * mi)
+{
+       lissstruct *lp;
+       unsigned char ball;
+
+       if (lisses == NULL) {
+               if ((lisses = (lissstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (lissstruct))) == NULL)
+                       return;
+       }
+       lp = &lisses[MI_SCREEN(mi)];
+
+       lp->width = MI_WIDTH(mi);
+       lp->height = MI_HEIGHT(mi);
+
+       lp->nlissies = MI_COUNT(mi);
+       if (lp->nlissies < -MINLISSIES) {
+               if (lp->lissie) {
+                       (void) free((void *) lp->lissie);
+                       lp->lissie = NULL;
+               }
+               lp->nlissies = NRAND(-lp->nlissies - MINLISSIES + 1) + MINLISSIES;
+       } else if (lp->nlissies < MINLISSIES)
+               lp->nlissies = MINLISSIES;
+
+       lp->loopcount = 0;
+
+       if (!lp->lissie)
+               lp->lissie = (lissiestruct *) calloc(lp->nlissies, sizeof (lissiestruct));
+
+       MI_CLEARWINDOW(mi);
+       lp->painted = False;
+
+       for (ball = 0; ball < (unsigned char) lp->nlissies; ball++)
+               initlissie(mi, &lp->lissie[ball]);
+
+}
+
+void
+draw_lissie(ModeInfo * mi)
+{
+       lissstruct *lp = &lisses[MI_SCREEN(mi)];
+       register unsigned char ball;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (++lp->loopcount > MI_CYCLES(mi)) {
+               init_lissie(mi);
+       } else {
+               lp->painted = True;
+               for (ball = 0; ball < (unsigned char) lp->nlissies; ball++)
+                       drawlissie(mi, &lp->lissie[ball]);
+       }
+}
+
+void
+release_lissie(ModeInfo * mi)
+{
+       if (lisses != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       lissstruct *lp = &lisses[screen];
+
+                       if (lp->lissie) {
+                               (void) free((void *) lp->lissie);
+                               lp->lissie = NULL;
+                       }
+               }
+               (void) free((void *) lisses);
+               lisses = NULL;
+       }
+}
+
+void
+refresh_lissie(ModeInfo * mi)
+{
+       if (lisses != NULL) {
+               lissstruct *lp = &lisses[MI_SCREEN(mi)];
+               int         i;
+
+               if (lp->painted) {
+                       MI_CLEARWINDOW(mi);
+                       for (i = 0; i < lp->nlissies; i++) {
+                               lp->lissie[i].redrawing = 1;
+                               lp->lissie[i].redrawpos = 0;
+                       }
+               }
+       }
+}
+
+#endif /* MODE_lissie */
diff --git a/xlockmore-4.14/modes/loop.c b/xlockmore-4.14/modes/loop.c
new file mode 100644 (file)
index 0000000..66b8f8f
--- /dev/null
@@ -0,0 +1,1449 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* loop --- Chris Langton's self-producing loops */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)loop.c       4.13 98/10/18 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 18-Oct-98: Started creating a hexagon version, probably will not work
+ *            for a while since some work has to go into getting not
+ *            only the program to handle the hexagonal data but the loop
+ *            has to be "programmed" as well.  I suspect it should be easier
+ *            than the original since the loop will have six sides to
+ *            store its genes (data).
+ * 10-May-97: Compatible with xscreensaver
+ * 15-Nov-95: Coded from Chris Langton's Self-Reproduction in Cellular
+ *            Automata Physica 10D 135-144 1984
+ *            also used wire.c as a guide.
+ */
+
+/*-
+  Grid     Number of Neigbors
+  ----     ------------------
+  Square   4
+  Hexagon  6  (currently in development)
+*/
+
+/*-
+ * From Steven Levy's Artificial Life
+ * Chris Langton's cellular automata "loops" reproduce in the spirit of life.
+ * Beginning from a single organism, the loops from a colony.  As the loops
+ * on the outer fringes reproduce, the inner loops -- blocked by their
+ * daughters -- can no longer produce offspring.  These dead progenitors
+ * provide a base for future generations' expansion, much like the formation
+ * of a coral reef.  This self-organizing behavior emerges spontaneously,
+ * from the bottom up -- a key characteristic of artificial life.
+ */
+
+/*-
+   Don't Panic  --  When the artificial life tries to leave its petri
+   dish (ie. the screen) it will (usually) die...
+   The loops are short of "real" life because a general purpose Turing
+   machine is not contained in the loop.  This is a simplification of
+   von Neumann and Codd's self-producing Turing machine.
+   The data spinning around could be viewed as both its DNA and its internal
+   clock.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "loop"
+#define HACK_INIT init_loop
+#define HACK_DRAW draw_loop
+#define loop_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*cycles: 1600 \n" \
+ "*size: -12 \n" \
+ "*ncolors: 15 \n" \
+ "*neighbors: 0 \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_loop
+
+/*-
+ * neighbors of 0 randomizes between 4 and 6.
+ */
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+
+static int  neighbors;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".loop.neighbors", XrmoptionSepArg, (caddr_t) NULL}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int}
+};
+
+static OptionStruct desc[] =
+{
+       {"-neighbors num", "squares 4 or hexagons 6"}
+};
+
+ModeSpecOpt loop_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+
+#ifdef USE_MODULES
+ModStruct   loop_description =
+{"loop", "init_loop", "draw_loop", "release_loop",
+ "refresh_loop", "init_loop", NULL, &loop_opts,
+ 100000, 1, 1600, -12, 64, 1.0, "",
+ "Shows Langton's self-producing loops", 0, NULL};
+
+#endif
+
+#define LOOPBITS(n,w,h)\
+  lp->pixmaps[lp->init_bits++]=\
+  XCreatePixmapFromBitmapData(display,window,(char *)n,w,h,1,0,1)
+
+static int  local_neighbors = 0;
+static int  neighbor_kind = 0;
+
+#define COLORS 8
+#define REALCOLORS (COLORS-2)
+#define MINLOOPS 1
+#define REDRAWSTEP 2000                /* How many cells to draw per cycle */
+#define ADAM_SIZE 8 /* MIN 5 */
+#if 1
+#define ADAM_LOOPX  (ADAM_SIZE+2)
+#define ADAM_LOOPY  (ADAM_SIZE+2)
+#else
+#define ADAM_LOOPX 16
+#define ADAM_LOOPY 10
+#endif
+#define MINGRIDSIZE (3*ADAM_LOOPX)
+/* TRIA stuff was an attempt to make a triangular lifeform on a
+   hex grid but I got bored.  You probably need an additional 7th
+   state for a coherent step by step process of separation and
+   initial stem development.
+ */
+/* #define TRIA 1 */
+#ifdef TRIA
+#define HEX_ADAM_SIZE 3 /* MIN 3 */
+#else
+#define HEX_ADAM_SIZE 5 /* MIN 3 */
+#endif
+#if 1
+#define HEX_ADAM_LOOPX (2*HEX_ADAM_SIZE+1)
+#define HEX_ADAM_LOOPY (2*HEX_ADAM_SIZE+1)
+#else
+#define HEX_ADAM_LOOPX 3 
+#define HEX_ADAM_LOOPY 7
+#endif
+#define HEX_MINGRIDSIZE (6*HEX_ADAM_LOOPX)
+#define MINSIZE 1
+#define NEIGHBORKINDS 2
+#define ANGLES 360
+#define MAXNEIGHBORS 6
+
+/* Singly linked list */
+typedef struct _CellList {
+       XPoint      pt;
+       struct _CellList *next;
+} CellList;
+
+typedef struct {
+       int         init_bits;
+       int         generation;
+       int         xs, ys;
+       int         xb, yb;
+       int         nrows, ncols;
+       int         bx, by, bnrows, bncols;
+       int         mincol, minrow, maxcol, maxrow;
+       int         width, height;
+       int         redrawing, redrawpos;
+       Bool        dead;
+       unsigned char *newcells, *oldcells;
+       int         ncells[COLORS];
+       CellList   *cellList[COLORS];
+       unsigned long colors[COLORS];
+       GC          stippledGC;
+       Pixmap      pixmaps[COLORS];
+       union {
+               XPoint      hexagon[6];
+       } shape;
+} loopstruct;
+
+static loopstruct *loops = NULL;
+
+#define TRANSITION(TT,V) V=TT&7;TT>>=3
+#define TABLE(R,T,L,B) (table[((B)<<9)|((L)<<6)|((T)<<3)|(R)])
+#define HEX_TABLE(R,T,t,l,b,B) (table[((B)<<15)|((b)<<12)|((l)<<9)|((t)<<6)|((T)<<3)|(R)])
+#ifdef RAND_RULES              /* Hack, see below */
+#define TABLE_IN(C,R,T,L,B,I) (TABLE(R,T,L,B)&=~(7<<((C)*3)));\
+(TABLE(R,T,L,B)|=((I)<<((C)*3)))
+#define HEX_TABLE_IN(C,R,T,t,l,b,B,I) (HEX_TABLE(R,T,t,l,b,B)&=~(7<<((C)*3)));\
+(HEX_TABLE(R,T,t,l,b,B)|=((I)<<((C)*3)))
+#else
+#define TABLE_IN(C,R,T,L,B,I) (TABLE(R,T,L,B)|=((I)<<((C)*3)))
+#define HEX_TABLE_IN(C,R,T,t,l,b,B,I) (HEX_TABLE(R,T,t,l,b,B)|=((I)<<((C)*3)))
+#endif
+#define TABLE_OUT(C,R,T,L,B) ((TABLE(R,T,L,B)>>((C)*3))&7)
+#define HEX_TABLE_OUT(C,R,T,t,l,b,B) ((HEX_TABLE(R,T,t,l,b,B)>>((C)*3))&7)
+
+static unsigned int *table = NULL;     /* 8*8*8*8 = 2^12 = 2^3^4 = 4K */
+  /* 8*8*8*8*8*8 = too big? */
+
+static char plots[NEIGHBORKINDS] =
+{
+  4, 6 /* Neighborhoods */
+};
+
+static unsigned int transition_table[] =
+{                              /* Octal  CBLTR->I */
+  /* CBLTRI   CBLTRI   CBLTRI   CBLTRI   CBLTRI */
+    0000000, 0025271, 0113221, 0202422, 0301021,
+    0000012, 0100011, 0122244, 0202452, 0301220,
+    0000020, 0100061, 0122277, 0202520, 0302511,
+    0000030, 0100077, 0122434, 0202552, 0401120,
+    0000050, 0100111, 0122547, 0202622, 0401220,
+    0000063, 0100121, 0123244, 0202722, 0401250,
+    0000071, 0100211, 0123277, 0203122, 0402120,
+    0000112, 0100244, 0124255, 0203216, 0402221,
+    0000122, 0100277, 0124267, 0203226, 0402326,
+    0000132, 0100511, 0125275, 0203422, 0402520,
+    0000212, 0101011, 0200012, 0204222, 0403221,
+    0000220, 0101111, 0200022, 0205122, 0500022,
+    0000230, 0101244, 0200042, 0205212, 0500215,
+    0000262, 0101277, 0200071, 0205222, 0500225,
+    0000272, 0102026, 0200122, 0205521, 0500232,
+    0000320, 0102121, 0200152, 0205725, 0500272,
+    0000525, 0102211, 0200212, 0206222, 0500520,
+    0000622, 0102244, 0200222, 0206722, 0502022,
+    0000722, 0102263, 0200232, 0207122, 0502122,
+    0001022, 0102277, 0200242, 0207222, 0502152,
+    0001120, 0102327, 0200250, 0207422, 0502220,
+    0002020, 0102424, 0200262, 0207722, 0502244,
+    0002030, 0102626, 0200272, 0211222, 0502722,
+    0002050, 0102644, 0200326, 0211261, 0512122,
+    0002125, 0102677, 0200423, 0212222, 0512220,
+    0002220, 0102710, 0200517, 0212242, 0512422,
+    0002322, 0102727, 0200522, 0212262, 0512722,
+    0005222, 0105427, 0200575, 0212272, 0600011,
+    0012321, 0111121, 0200722, 0214222, 0600021,
+    0012421, 0111221, 0201022, 0215222, 0602120,
+    0012525, 0111244, 0201122, 0216222, 0612125,
+    0012621, 0111251, 0201222, 0217222, 0612131,
+    0012721, 0111261, 0201422, 0222272, 0612225,
+    0012751, 0111277, 0201722, 0222442, 0700077,
+    0014221, 0111522, 0202022, 0222462, 0701120,
+    0014321, 0112121, 0202032, 0222762, 0701220,
+    0014421, 0112221, 0202052, 0222772, 0701250,
+    0014721, 0112244, 0202073, 0300013, 0702120,
+    0016251, 0112251, 0202122, 0300022, 0702221,
+    0017221, 0112277, 0202152, 0300041, 0702251,
+    0017255, 0112321, 0202212, 0300076, 0702321,
+    0017521, 0112424, 0202222, 0300123, 0702525,
+    0017621, 0112621, 0202272, 0300421, 0702720,
+    0017721, 0112727, 0202321, 0300622
+};
+
+static unsigned int hex_transition_table[] =
+{                              /* Octal CBbltTR->I */
+  /* CBbltTRI   CBbltTRI   CBbltTRI   CBbltTRI   CBbltTRI */
+
+#ifdef TRIA
+    000000000, 000000020, 000000220, 000002220, 000022220,
+    011122121, 011121221, 011122221, 011221221,
+    011222221, 011112121, 011112221,
+    020021122, 020002122, 020211222, 021111222,
+    020221122, 020027122, 020020722, 020021022,
+    001127221,
+    011122727, 011227227, 010122121, 010222211,
+    021117222, 020112272,
+    070221220,
+    001227221,
+    010221121, 011721221, 011222277,
+    020111222, 020221172,
+    070211220,
+    001217221,
+    010212277, 010221221,
+    020122112,
+    070122220,
+    001722221,
+    010221271,
+    020002022, 021122172,
+    070121220,
+    011122277, 011172121,
+    010212177, 011212277,
+    070112220,
+    001772221,
+    021221772,
+    070121270, 070721220,
+    000112721, 000272211,
+    010022211, 012222277,
+    020072272, 020227122, 020217222,
+    010211121,
+    020002727,
+    070222220,
+    001727721,
+    020021072, 020070722,
+    070002072, 070007022,
+    001772721,
+    070002022,
+    000000070, 000000770, 000072220, 000000270,
+    020110222, 020220272, 020220722,
+    070007071, 070002072, 070007022,
+    000000012, 000000122, 000000212, 001277721,
+    020122072, 020202212,
+    010002121,
+    020001122, 020002112,
+    020021722,
+    020122022, 020027022, 020070122, 020020122,
+    010227027,
+    020101222,
+    010227227, 010227277,
+    021722172,
+    001727221,
+    010222277,
+    020702272,
+    070122020,
+    000172721,
+    010022277, 010202177, 010227127,
+
+    001214221,
+    010202244,
+    020024122, 020020422,
+    040122220,
+    001422221,
+    010221241, 010224224,
+    021122142,
+    040121220,
+    001124221,
+    010224274,
+    020112242, 021422172,
+    040221220,
+    001224221, 001427221,
+    010222244,
+    020227042,
+    040122020,
+    000142721,
+    010022244, 010202144, 010224124,
+    040112220,
+    001442221,
+    021221442,
+    040121240, 040421220,
+    000242211, 000112421,
+    020042242, 020214222, 020021422, 020220242, 020024022,
+    011224224,
+    020224122,
+    020220422,
+    012222244,
+    020002424,
+    040222220,
+    001244421, 000000420, 000000440, 000000240, 000000040,
+    020040121, 020021042,
+    040004022, 040004042, 040002042,
+    010021121,
+    020011122, 020002112,
+    001424421,
+    020040422,
+    001442421,
+    040002022,
+    001724221,
+    010227247,
+    020224072, 021417222,
+    000172421,
+    010021721,
+    020017022,
+    020120212,
+    020271727,
+    070207072, 070701220,
+    000001222,
+    020110122,
+    001277221,
+    001777721,
+    020021222, 020202272, 020120222, 020221722,
+    020027227,
+    070070222,
+    000007220,
+    020101272, 020272172, 020721422, 020721722,
+    020011222, 020202242,
+#if 0
+              {2,2,0,0,2,7,0},
+             {2,0,2,0,2,0,2},
+            {2,4,1,2,2,1,2},
+           {2,1,2,1,2,1,2},
+          {2,0,2,2,1,1,2},
+         {2,7,1,1,1,1,2},
+        {0,2,2,2,2,2,2},
+              {2,2,0,0,7,7,0},
+             {2,1,2,0,2,0,7},
+            {2,0,1,2,2,1,2},
+           {2,4,2,1,2,1,2},
+          {2,1,2,2,1,1,2},
+         {2,0,7,1,1,1,2},
+        {0,2,2,2,2,2,2},
+#endif
+#else
+    000000000, 000000020, 000000220, 000002220,
+    011212121, 011212221, 011221221, 011222221,
+    020002122, 020021122, 020211122,
+
+    010221221, 010222121,
+    020002022, 020021022, 020020122, 020112022,
+
+    010202121,
+    020102022, 020202112,
+
+    000000012, 000000122, 000000212,
+    010002121, 
+    020001122, 020002112, 020011122,
+
+
+    001227221, 001272221, 001272721,
+    012212277, 011222727, 011212727,
+    020021722, 020027122, 020020722, 020027022,
+    020211722, 020202172, 020120272,
+    020271122, 020202172, 020207122, 020217122,
+    020120272, 020210722, 020270722,
+    070212220, 070221220, 070212120,
+
+
+    012222277,
+    020002727,
+    070222220,
+
+    001277721, 000000070, 000000270, 000000720, 000000770,
+    020070122, 020021072,
+    070002072, 070007022, 070007071,
+
+    020070722,
+    070002022,
+
+    010227227, 010222727, 010202727,
+    020172022, 020202712,
+
+    001224221, 001242221, 001242421,
+    012212244, 011222424, 011212424,
+    020021422, 020024122, 020020422, 020024022,
+    020211422, 020202142, 020120242,
+    020241122, 020202142, 020204122, 020214122,
+    020120242, 020210422, 020240422,
+    040212220, 040221220, 040212120,
+
+
+    012222244,
+    020002424,
+    040222220,
+
+    001244421, 000000040, 000000240, 000000420, 000000440,
+    020040122, 020021042,
+    040002042,
+    040004021, 040004042,
+
+    020040422,
+    040002022,
+    
+    010224224, 010222424, 010202424,
+    020142022, 020202412,
+    020011722, 020112072, 020172072, 020142072,
+
+
+
+    000210225, 000022015, 000022522,
+    011225521, 
+    020120525, 020020152, 020005122, 020214255, 020021152,
+    020255242,
+    050215222, 050225121,
+
+    000225220, 001254222,
+    010221250, 011221251, 011225221,
+    020025122, 020152152, 020211252, 020214522, 020511125,
+    050212241, 05221120,
+    040521225,
+
+    000000250, 000000520, 000150220, 000220520, 000222210,
+    001224251,
+    010022152, 010251221, 010522121, 011212151, 011221251,
+    011215221,
+    020000220, 020002152, 020020220, 020021020, 020022152,
+    020021422, 020022152, 020022522, 020025425, 020050422,
+    020051022, 020051122, 020211122, 020211222, 020215222,
+    020245122,
+    050021125, 050021025, 050011125, 051242221,
+    041225220,
+
+    000220250, 000220520, 001227521, 001275221,
+    011257227, 011522727,
+    020002052, 020002752, 020021052, 020057125,
+    050020722, 050027125,
+    070215220,
+
+    070212255,
+    071225220,
+    020275122,
+    051272521,
+    020055725,
+    020021552,
+    012252277,
+    050002521,
+    020005725,     
+
+    050011022,
+    000000155,
+    020050722,
+    001227250,
+    010512727,
+    010002151,
+    020027112,
+    001227251,
+    012227257,
+    050002125,
+    020517122,
+    050002025,
+    020050102,
+    050002725,
+    020570722,
+    001252721,
+    020007051,
+    020102052,
+    020271072,
+    050001122,
+    010002151,
+    011227257,
+    020051722,
+    020057022,
+    020050122,
+
+
+    020051422,
+    011224254,
+    012224254,
+
+    020054022,
+    050002425,
+    040252220,
+    020002454,
+
+
+    000000540,
+    001254425,
+    050004024,
+    040004051,
+
+    000000142,
+    040001522,
+    010002547,
+    020045122,
+    051221240,
+    020002512,
+    020021522,
+
+
+    020020022,
+    021125522,
+    020521122,
+    020025022,
+    020025522,
+    020020522, 
+
+    020202222,
+    020212222,
+    021212222,
+    021222722,
+    021222422,
+    020002222,
+    020021222,
+    020022122,
+    020212122,
+    020027222,
+    020024222,
+    020020222,
+    020212722,
+    020212422,
+    020202122,
+    001222221,
+    020002522,
+
+    020017125,
+    010022722,
+    020212052,
+
+    020205052,
+#endif
+};
+
+
+/*-
+Neighborhoods are read as follows (rotations are not listed):
+    T
+  L C R  ==>  I
+    B
+
+   t T
+  l C R  ==>  I
+   b B
+ */
+
+static unsigned char self_reproducing_loop[ADAM_LOOPY][ADAM_LOOPX] =
+{
+/* 10x10 */
+       {0, 2, 2, 2, 2, 2, 2, 2, 2, 0},
+       {2, 4, 0, 1, 4, 0, 1, 1, 1, 2},
+       {2, 1, 2, 2, 2, 2, 2, 2, 1, 2},
+       {2, 0, 2, 0, 0, 0, 0, 2, 1, 2},
+       {2, 7, 2, 0, 0, 0, 0, 2, 7, 2},
+       {2, 1, 2, 0, 0, 0, 0, 2, 0, 2},
+       {2, 0, 2, 0, 0, 0, 0, 2, 1, 2},
+       {2, 7, 2, 2, 2, 2, 2, 2, 7, 2},
+       {2, 1, 0, 6, 1, 0, 7, 1, 0, 2},
+       {0, 2, 2, 2, 2, 2, 2, 2, 2, 0}
+};
+
+static unsigned char hex_self_reproducing_loop[HEX_ADAM_LOOPY][HEX_ADAM_LOOPX] =
+{
+#if 0
+/* Experimental TRIA5:7x7 */
+             {2,2,0,0,0,0,0},
+            {2,1,2,0,2,2,0},
+           {2,0,4,2,2,0,2},
+          {2,7,2,0,2,0,2},
+         {2,1,2,2,1,1,2},
+        {2,0,7,1,0,7,2},
+       {0,2,2,2,2,2,2},
+  /* Stem cells, only "5" will fully reproduce itself */
+/* 3:12x7 */
+             {2,2,2,2,0,0,0,0,0,0,0,0},
+            {2,1,1,1,2,0,0,0,0,0,0,0},
+           {2,1,2,2,1,2,2,2,2,2,2,0},
+          {2,1,2,0,2,7,1,1,1,1,1,2},
+         {0,2,1,2,2,0,2,2,2,2,2,2},
+        {0,0,2,0,4,1,2,0,0,0,0,0},
+       {0,0,0,2,2,2,2,0,0,0,0,0}
+/* 4:14x9 */
+               {2,2,2,2,2,0,0,0,0,0,0,0,0,0},
+              {2,1,1,1,1,2,0,0,0,0,0,0,0,0},
+             {2,1,2,2,2,1,2,0,0,0,0,0,0,0},
+            {2,1,2,0,0,2,1,2,2,2,2,2,2,0},
+           {2,1,2,0,0,0,2,7,1,1,1,1,1,2},
+          {0,2,1,2,0,0,2,0,2,2,2,2,2,2},
+         {0,0,2,0,2,2,2,1,2,0,0,0,0,0},
+        {0,0,0,2,4,1,0,7,2,0,0,0,0,0},
+       {0,0,0,0,2,2,2,2,2,0,0,0,0,0}
+/* 5:16x11 */
+                 {2,2,2,2,2,2,0,0,0,0,0,0,0,0,0,0},
+                {2,1,1,1,1,1,2,0,0,0,0,0,0,0,0,0},
+               {2,1,2,2,2,2,1,2,0,0,0,0,0,0,0,0},
+              {2,1,2,0,0,0,2,1,2,0,0,0,0,0,0,0},
+             {2,1,2,0,0,0,0,2,1,2,2,2,2,2,2,0},
+            {2,1,2,0,0,0,0,0,2,7,1,1,1,1,1,2},
+           {0,2,1,2,0,0,0,0,2,0,2,2,2,2,2,2},
+          {0,0,2,0,2,0,0,0,2,1,2,0,0,0,0,0},
+         {0,0,0,2,4,2,2,2,2,7,2,0,0,0,0,0},
+        {0,0,0,0,2,1,0,7,1,0,2,0,0,0,0,0},
+       {0,0,0,0,0,2,2,2,2,2,2,0,0,0,0,0}
+/* test:3x7  (0,4) is blank  ... very strange.
+          init_adam seems ok something after that I guess */
+                    {2,2,0},
+                   {2,0,2},
+                  {0,2,2},
+                 {0,0,0},
+                {2,2,0},
+               {2,1,2},
+              {0,2,2},
+#else /* this might be better for hexagons, spacewise efficient... */
+#ifdef TRIA
+/* Experimental TRIA5:7x7 */
+             {2,2,0,0,2,2,0},
+            {2,4,2,0,2,7,2},
+           {2,1,0,2,2,0,2},
+          {2,0,2,1,2,1,2},
+         {2,7,2,2,7,7,2},
+        {2,1,0,7,1,0,2},
+       {0,2,2,2,2,2,2},
+#else
+/* 5:11x11 */
+                 {2,2,2,2,2,2,0,0,0,0,0},
+                {2,1,1,7,0,1,2,0,0,0,0},
+               {2,1,2,2,2,2,7,2,0,0,0},
+              {2,1,2,0,0,0,2,0,2,0,0},
+             {2,1,2,0,0,0,0,2,1,2,0},
+            {2,1,2,0,0,0,0,0,2,7,2},
+           {0,2,1,2,0,0,0,0,2,0,2},
+          {0,0,2,1,2,0,0,0,2,1,2},
+         {0,0,0,2,1,2,2,2,2,4,2},
+        {0,0,0,0,2,1,1,1,1,5,2},
+       {0,0,0,0,0,2,2,2,2,2,2}
+#endif
+#endif
+};
+
+static void
+position_of_neighbor(int dir, int *pcol, int *prow)
+{
+       int         col = *pcol, row = *prow;
+
+       /* NO WRAPING */
+
+       if (local_neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = col + 1;
+                               break;
+                       case 60:
+                               if (row & 1)
+                                       col = col + 1;
+                               row = row - 1;
+                               break;
+                       case 120:
+                               if (!(row & 1))
+                                       col = col - 1;
+                               row = row - 1;
+                               break;
+                       case 180:
+                               col = col - 1;
+                               break;
+                       case 240:
+                               if (!(row & 1))
+                                       col = col - 1;
+                               row = row + 1;
+                               break;
+                       case 300:
+                               if (row & 1)
+                                       col = col + 1;
+                               row = row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {
+               switch (dir) {
+                       case 0:
+                               col = col + 1;
+                               break;
+                       case 90:
+                               row = row - 1;
+                               break;
+                       case 180:
+                               col = col - 1;
+                               break;
+                       case 270:
+                               row = row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       }
+       *pcol = col;
+       *prow = row;
+}
+
+static      Bool
+withinBounds(loopstruct * lp, int col, int row)
+{
+       return (row >= 1 && row < lp->bnrows - 1 &&
+               col >= 1 && col < lp->bncols - 1 - (local_neighbors == 6 && (row % 2)));
+}
+
+static void
+fillcell(ModeInfo * mi, GC gc, int col, int row)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+
+       if (local_neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               lp->shape.hexagon[0].x = lp->xb + ccol * lp->xs;
+               lp->shape.hexagon[0].y = lp->yb + crow * lp->ys;
+               if (lp->xs == 1 && lp->ys == 1)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                               lp->shape.hexagon[0].x, lp->shape.hexagon[0].y);
+               else
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                               lp->shape.hexagon, 6, Convex, CoordModePrevious);
+       } else {
+               XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                       lp->xb + lp->xs * col, lp->yb + lp->ys * row,
+                       lp->xs - (lp->xs > 3), lp->ys - (lp->ys > 3));
+       }
+}
+
+static void
+drawcell(ModeInfo * mi, int col, int row, int state)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+       XGCValues   gcv;
+       GC          gc;
+
+       if (MI_NPIXELS(mi) >= COLORS) {
+               gc = MI_GC(mi);
+               XSetForeground(MI_DISPLAY(mi), gc, lp->colors[state]);
+       } else {
+               gcv.stipple = lp->pixmaps[state];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), lp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = lp->stippledGC;
+       }
+       fillcell(mi, gc, col, row);
+}
+
+static void
+addtolist(ModeInfo * mi, int col, int row, unsigned char state)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+       CellList   *current = lp->cellList[state];
+
+       lp->cellList[state] = NULL;
+       if ((lp->cellList[state] = (CellList *) malloc(sizeof (CellList))) == NULL) {
+               lp->cellList[state] = current;
+               return;
+       }
+       lp->cellList[state]->pt.x = col;
+       lp->cellList[state]->pt.y = row;
+       lp->cellList[state]->next = current;
+       lp->ncells[state]++;
+}
+
+#ifdef DEBUG
+static void
+print_state(ModeInfo * mi, int state)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+       CellList   *locallist = lp->cellList[state];
+       int         i = 0;
+
+       (void) printf("state %d\n", state);
+       while (locallist) {
+               (void) printf("%d x %d, y %d\n", i,
+                             locallist->pt.x, locallist->pt.y);
+               locallist = locallist->next;
+               i++;
+       }
+}
+
+#endif
+
+static void
+free_state(loopstruct * lp, int state)
+{
+       CellList   *current;
+
+       while (lp->cellList[state]) {
+               current = lp->cellList[state];
+               lp->cellList[state] = lp->cellList[state]->next;
+               (void) free((void *) current);
+       }
+       lp->ncells[state] = 0;
+}
+
+static void
+draw_state(ModeInfo * mi, int state)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+       GC          gc;
+       XGCValues   gcv;
+       CellList   *current = lp->cellList[state];
+
+       if (MI_NPIXELS(mi) >= COLORS) {
+               gc = MI_GC(mi);
+               XSetForeground(MI_DISPLAY(mi), gc, lp->colors[state]);
+       } else {
+               gcv.stipple = lp->pixmaps[state];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), lp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = lp->stippledGC;
+       }
+
+       if (local_neighbors == 6) {       /* Draw right away, slow */
+               while (current) {
+                       int      col, row, ccol, crow;
+
+                       col = current->pt.x;
+                       row = current->pt.y;
+                       ccol = 2 * col + !(row & 1), crow = 2 * row;
+                       lp->shape.hexagon[0].x = lp->xb + ccol * lp->xs;
+                       lp->shape.hexagon[0].y = lp->yb + crow * lp->ys;
+                       if (lp->xs == 1 && lp->ys == 1)
+                               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                       lp->shape.hexagon[0].x, lp->shape.hexagon[0].y);
+                       else
+                               XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                       lp->shape.hexagon, 6, Convex, CoordModePrevious);
+                       current = current->next;
+               }
+       } else {
+               /* Take advantage of XFillRectangles */
+               XRectangle *rects = NULL;
+               int         nrects = 0;
+
+               /* Create Rectangle list from part of the cellList */
+               if ((rects = (XRectangle *) malloc(lp->ncells[state] * sizeof (XRectangle))) == NULL) {
+                       return;
+               }
+
+               while (current) {
+                       rects[nrects].x = lp->xb + current->pt.x * lp->xs;
+                       rects[nrects].y = lp->yb + current->pt.y * lp->ys;
+                       rects[nrects].width = lp->xs - (lp->xs > 3);
+                       rects[nrects].height = lp->ys - (lp->ys > 3);
+                       current = current->next;
+                       nrects++;
+               }
+               /* Finally get to draw */
+               XFillRectangles(MI_DISPLAY(mi), MI_WINDOW(mi), gc, rects, nrects);
+               /* Free up rects list and the appropriate part of the cellList */
+               (void) free((void *) rects);
+       }
+       free_state(lp, state);
+       XFlush(MI_DISPLAY(mi));
+}
+
+static int
+init_table(void)
+{
+       if (table == NULL) {
+               int mult = 1;
+               unsigned int tt, c, n[MAXNEIGHBORS], i;
+               int         j, k;
+               int  size_transition_table = sizeof (transition_table) /
+                       sizeof (unsigned int);
+               int  size_hex_transition_table = sizeof (hex_transition_table) /
+                       sizeof (unsigned int);
+
+               for (j = 0; j < local_neighbors; j++)
+                       mult *= 8;
+
+               if ((table = (unsigned int *) calloc(mult, sizeof (unsigned int))) == NULL) {
+                       return 1;
+               }
+
+#ifdef RAND_RULES
+               /* Here I was interested to see what happens when it hits a wall....
+                  Rules not normally used take over... takes too much time though */
+               {
+                       for (j = 0; j < mult; j++) {
+                               for (k = 0; k < 8; k++)
+                                       table[j] |= (unsigned int) ((unsigned int) (NRAND(8)) << (k * 3));
+                       }
+               }
+#endif
+               if (local_neighbors == 6) {
+                       for (j = 0; j < size_hex_transition_table; j++) {
+                               tt = hex_transition_table[j];
+                               TRANSITION(tt, i);
+                               for (k = 0; k < local_neighbors; k++) {
+                                       TRANSITION(tt, n[k]);
+                               }
+                               TRANSITION(tt, c);
+                               HEX_TABLE_IN(c, n[0], n[1], n[2], n[3], n[4], n[5], i);
+                               HEX_TABLE_IN(c, n[1], n[2], n[3], n[4], n[5], n[0], i);
+                               HEX_TABLE_IN(c, n[2], n[3], n[4], n[5], n[0], n[1], i);
+                               HEX_TABLE_IN(c, n[3], n[4], n[5], n[0], n[1], n[2], i);
+                               HEX_TABLE_IN(c, n[4], n[5], n[0], n[1], n[2], n[3], i);
+                               HEX_TABLE_IN(c, n[5], n[0], n[1], n[2], n[3], n[4], i);
+                       }
+               } else {
+                       for (j = 0; j < size_transition_table; j++) {
+                               tt = transition_table[j];
+                               TRANSITION(tt, i);
+                               for (k = 0; k < local_neighbors; k++) {
+                                       TRANSITION(tt, n[k]);
+                               }
+                               TRANSITION(tt, c);
+                               TABLE_IN(c, n[0], n[1], n[2], n[3], i);
+                               TABLE_IN(c, n[1], n[2], n[3], n[0], i);
+                               TABLE_IN(c, n[2], n[3], n[0], n[1], i);
+                               TABLE_IN(c, n[3], n[0], n[1], n[2], i);
+                       }
+               }
+       }
+       return 0;
+}
+
+static void
+init_adam(ModeInfo * mi)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+       XPoint      start, dirx, diry;
+       int         i, j;
+
+  if (local_neighbors == 6) {
+               int k;
+
+               /* switch (0) */
+               switch (NRAND(6)) {
+                       case 0:
+                               start.x = (lp->bncols - HEX_ADAM_LOOPX / 2) / 2;
+                               start.y = (lp->bnrows - HEX_ADAM_LOOPY) / 2;
+                               lp->mincol = start.x - 2;
+                               lp->minrow = start.y - 1;
+                               lp->maxcol = start.x + HEX_ADAM_LOOPX + 1;
+                               lp->maxrow = start.y + HEX_ADAM_LOOPY + 1;
+                               for (j = 0; j < HEX_ADAM_LOOPY; j++) {
+                                       for (i = 0; i < HEX_ADAM_LOOPX; i++) {
+                                               k = (((lp->bnrows / 2 + HEX_ADAM_LOOPY / 2) % 2) ? -j / 2 : -(j + 1) / 2);
+                                               lp->newcells[(start.y + j) * lp->bncols + start.x + i + k] =
+                                                       hex_self_reproducing_loop[j][i];
+                                       }
+                               }
+                               break;
+                       case 1:
+                               start.x = (lp->bncols - (HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2) / 2;
+                               start.y = (lp->bnrows - HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2;
+                               lp->mincol = start.x - 1;
+                               lp->minrow = start.y - HEX_ADAM_LOOPX;
+                               lp->maxcol = start.x + (HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2 + 1;
+                               lp->maxrow = start.y + HEX_ADAM_LOOPY + 1;
+                               for (j = 0; j < HEX_ADAM_LOOPY; j++) {
+                                       for (i = 0; i < HEX_ADAM_LOOPX; i++) {
+                                               k = (((lp->bnrows / 2 + (HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2) % 2)
+              ? -(i + j + 1) / 2 : -(i + j) / 2);
+                                               lp->newcells[(start.y + j - i) * lp->bncols + start.x + i + j + k] =
+                                                       hex_self_reproducing_loop[j][i];
+                                       }
+                               }
+                               break;
+                       case 2:
+                               start.x = (lp->bncols - HEX_ADAM_LOOPY / 2) / 2;
+                               start.y = (lp->bnrows - HEX_ADAM_LOOPX) / 2;
+                               lp->mincol = start.x - 2;
+                               lp->minrow = start.y - 1;
+                               lp->maxcol = start.x + HEX_ADAM_LOOPY + 1;
+                               lp->maxrow = start.y + HEX_ADAM_LOOPX + 1;
+                               for (j = 0; j < HEX_ADAM_LOOPX; j++) {
+                                       for (i = 0; i < HEX_ADAM_LOOPY; i++) {
+                                               k = (((lp->bnrows / 2 + HEX_ADAM_LOOPX / 2) % 2) ? -(HEX_ADAM_LOOPX - j - 1) / 2 : -(HEX_ADAM_LOOPX - j) / 2);
+                                               lp->newcells[(start.y + j) * lp->bncols + start.x + i + k] =
+                                                       hex_self_reproducing_loop[i][HEX_ADAM_LOOPX - j - 1];
+                                       }
+                               }
+                               break;
+                       case 3:
+                               start.x = (lp->bncols - HEX_ADAM_LOOPX / 2) / 2;
+                               start.y = (lp->bnrows - HEX_ADAM_LOOPY) / 2;
+                               lp->mincol = start.x - 1, lp->minrow = start.y - 1;
+                               lp->maxcol = start.x + HEX_ADAM_LOOPX + 1, lp->maxrow = start.y + HEX_ADAM_LOOPY + 1;
+                               for (j = 0; j < HEX_ADAM_LOOPY; j++) {
+                                       for (i = 0; i < HEX_ADAM_LOOPX; i++) {
+                                               k = (((lp->bnrows / 2 + HEX_ADAM_LOOPY / 2) % 2) ? -j / 2 : -(j + 1) / 2);
+                                               lp->newcells[(start.y + j) * lp->bncols + start.x + i + k] =
+                                                       hex_self_reproducing_loop[HEX_ADAM_LOOPY - j - 1][HEX_ADAM_LOOPX - i - 1];
+                                       }
+                               }
+                               break;
+                       case 4:
+                               start.x = (lp->bncols - (HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2) / 2;
+                               start.y = (lp->bnrows - HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2;
+                               lp->mincol = start.x - 1;
+                               lp->minrow = start.y - HEX_ADAM_LOOPX;
+                               lp->maxcol = start.x + (HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2 + 1;
+                               lp->maxrow = start.y + HEX_ADAM_LOOPY + 1;
+                               for (j = 0; j < HEX_ADAM_LOOPY; j++) {
+                                       for (i = 0; i < HEX_ADAM_LOOPX; i++) {
+                                               k = (((lp->bnrows / 2 + (HEX_ADAM_LOOPX + HEX_ADAM_LOOPY) / 2) % 2)
+              ? -(i + j + 1) / 2 : -(i + j) / 2);
+                                               lp->newcells[(start.y + j - i) * lp->bncols + start.x + i + j + k] =
+                                                       hex_self_reproducing_loop[HEX_ADAM_LOOPY - j - 1][HEX_ADAM_LOOPX - i - 1];
+                                       }
+                               }
+                               break;
+                       case 5:
+                               start.x = (lp->bncols - HEX_ADAM_LOOPY / 2) / 2;
+                               start.y = (lp->bnrows - HEX_ADAM_LOOPX) / 2;
+                               lp->mincol = start.x - 2;
+                               lp->minrow = start.y - 1;
+                               lp->maxcol = start.x + HEX_ADAM_LOOPY + 1;
+                               lp->maxrow = start.y + HEX_ADAM_LOOPX + 1;
+                               for (j = 0; j < HEX_ADAM_LOOPX; j++) {
+                                       for (i = 0; i < HEX_ADAM_LOOPY; i++) {
+                                               k = (((lp->bnrows / 2 + HEX_ADAM_LOOPX / 2) % 2) ? -(HEX_ADAM_LOOPX - j - 1) / 2 : -(HEX_ADAM_LOOPX - j) / 2);
+                                               lp->newcells[(start.y + j) * lp->bncols + start.x + i + k] =
+                                                       hex_self_reproducing_loop[HEX_ADAM_LOOPX - i - 1][j];
+                                       }
+                               }
+                               break;
+               }
+#if DEBUGTEST
+                               /* printf ("s %d  s %d \n", start.x, start.y); */
+               printf ("%d %d %d %d %d\t",
+     start.x + i + ((lp->bnrows / 2 % 2) ? -j / 2 : -(j + 1) / 2) - lp->bx,
+                start.y + j - lp->by, i, j, hex_self_reproducing_loop[j][i]);
+               /* Draw right away */
+               drawcell(mi, start.x + i + ((lp->bnrows / 2 % 2) ? -j / 2 : -(j + 1) / 2) - lp->bx,
+                start.y + j - lp->by,
+                hex_self_reproducing_loop[j][i]);
+#endif
+#if DEBUGTEST
+                        printf ("\n");
+#endif
+#if DEBUGTEST
+                        printf ("\n");
+#endif
+  } else {
+               switch (NRAND(4)) {
+                       case 0:
+                               start.x = (lp->bncols - ADAM_LOOPX) / 2;
+                               start.y = (lp->bnrows - ADAM_LOOPY) / 2;
+                               dirx.x = 1, dirx.y = 0;
+                               diry.x = 0, diry.y = 1;
+                               lp->mincol = start.x, lp->minrow = start.y;
+                               lp->maxcol = start.x + ADAM_LOOPX, lp->maxrow = start.y + ADAM_LOOPY;
+                               break;
+                       case 1:
+                               start.x = (lp->bncols + ADAM_LOOPY) / 2;
+                               start.y = (lp->bnrows - ADAM_LOOPX) / 2;
+                               dirx.x = 0, dirx.y = 1;
+                               diry.x = -1, diry.y = 0;
+                               lp->mincol = start.x - ADAM_LOOPY, lp->minrow = start.y;
+                               lp->maxcol = start.x, lp->maxrow = start.y + ADAM_LOOPX;
+                               break;
+                       case 2:
+                               start.x = (lp->bncols + ADAM_LOOPX) / 2;
+                               start.y = (lp->bnrows + ADAM_LOOPY) / 2;
+                               dirx.x = -1, dirx.y = 0;
+                               diry.x = 0, diry.y = -1;
+                               lp->mincol = start.x - ADAM_LOOPX, lp->minrow = start.y - ADAM_LOOPY;
+                               lp->maxcol = start.x, lp->maxrow = start.y;
+                               break;
+                       case 3:
+                               start.x = (lp->bncols - ADAM_LOOPY) / 2;
+                               start.y = (lp->bnrows + ADAM_LOOPX) / 2;
+                               dirx.x = 0, dirx.y = -1;
+                               diry.x = 1, diry.y = 0;
+                               lp->mincol = start.x, lp->minrow = start.y - ADAM_LOOPX;
+                               lp->maxcol = start.x + ADAM_LOOPY, lp->maxrow = start.y;
+                               break;
+               }
+               for (j = 0; j < ADAM_LOOPY; j++)
+                       for (i = 0; i < ADAM_LOOPX; i++)
+                               lp->newcells[(start.y + dirx.y * i + diry.y * j) * lp->bncols +
+                                            start.x + dirx.x * i + diry.x * j] =
+                                       self_reproducing_loop[j][i];
+#if DEBUG
+               /* Draw right away */
+               drawcell(mi, start.x + dirx.x * i + diry.x * j - lp->bx,
+                start.y + dirx.y * i + diry.y * j - lp->by,
+                self_reproducing_loop[j][i]);
+#endif
+       }
+}
+
+
+static void
+do_gen(loopstruct * lp)
+{
+       int         i, j, k;
+       unsigned char *z;
+       unsigned int n[MAXNEIGHBORS];
+       unsigned int c;
+
+#define LOC(X, Y) (*(lp->oldcells + (X) + ((Y) * lp->bncols)))
+
+       for (j = lp->minrow; j <= lp->maxrow; j++) {
+               for (i = lp->mincol; i <= lp->maxcol; i++) {
+                       z = lp->newcells + i + j * lp->bncols;
+                       c = LOC(i, j);
+                       for (k = 0; k < local_neighbors; k++) {
+                               int         newi = i, newj = j;
+
+                               position_of_neighbor(k * ANGLES / local_neighbors, &newi, &newj);
+                               n[k] = 0;
+                   if (withinBounds(lp, newi, newj)) {
+                                       n[k] = LOC(newi, newj);
+                               }
+                       }
+                       if (local_neighbors == 6) {
+                               *z = HEX_TABLE_OUT(c, n[0], n[1], n[2], n[3], n[4], n[5]);
+                       } else {
+                               *z = TABLE_OUT(c, n[0], n[1], n[2], n[3]);
+                       }
+               }
+       }
+}
+
+static void
+free_list(loopstruct * lp)
+{
+       int         state;
+
+       for (state = 0; state < COLORS; state++)
+               free_state(lp, state);
+}
+
+void
+release_loop(ModeInfo * mi)
+{
+       if (loops != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       loopstruct *lp = &loops[screen];
+                       int         shade;
+
+                       for (shade = 0; shade < lp->init_bits; shade++)
+                               if (lp->pixmaps[shade] != None)
+                                       XFreePixmap(MI_DISPLAY(mi), lp->pixmaps[shade]);
+                       if (lp->stippledGC != None)
+                               XFreeGC(MI_DISPLAY(mi), lp->stippledGC);
+                       if (lp->oldcells != NULL)
+                               (void) free((void *) lp->oldcells);
+                       if (lp->newcells != NULL)
+                               (void) free((void *) lp->newcells);
+                       free_list(lp);
+               }
+               (void) free((void *) loops);
+               loops = NULL;
+       }
+       if (table != NULL) {
+               (void) free((void *) table);
+               table = NULL;
+       }
+}
+
+void
+init_loop(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         i, size = MI_SIZE(mi);
+       loopstruct *lp;
+       XGCValues   gcv;
+
+       if (loops == NULL) {
+               if ((loops = (loopstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (loopstruct))) == NULL)
+                       return;
+       }
+       lp = &loops[MI_SCREEN(mi)];
+
+       lp->redrawing = 0;
+
+       if ((MI_NPIXELS(mi) < COLORS) && (lp->init_bits == 0)) {
+               if (lp->stippledGC == None) {
+                       gcv.fill_style = FillOpaqueStippled;
+                       lp->stippledGC = XCreateGC(display, window, GCFillStyle, &gcv);
+                       if (lp->stippledGC == None) {
+                               release_loop(mi);
+                               return;
+                       }
+               }
+               LOOPBITS(stipples[0], STIPPLESIZE, STIPPLESIZE);
+               LOOPBITS(stipples[2], STIPPLESIZE, STIPPLESIZE);
+               LOOPBITS(stipples[3], STIPPLESIZE, STIPPLESIZE);
+               LOOPBITS(stipples[4], STIPPLESIZE, STIPPLESIZE);
+               LOOPBITS(stipples[6], STIPPLESIZE, STIPPLESIZE);
+               LOOPBITS(stipples[7], STIPPLESIZE, STIPPLESIZE);
+               LOOPBITS(stipples[8], STIPPLESIZE, STIPPLESIZE);
+               LOOPBITS(stipples[10], STIPPLESIZE, STIPPLESIZE);
+       if (lp->pixmaps[COLORS - 1] == None) {
+                       release_loop(mi);
+                       return;
+               }
+       }
+       if (MI_NPIXELS(mi) >= COLORS) {
+               /* Maybe these colors should be randomized */
+               lp->colors[0] = MI_BLACK_PIXEL(mi);
+               lp->colors[1] = MI_PIXEL(mi, 0);        /* RED */
+               lp->colors[5] = MI_PIXEL(mi, MI_NPIXELS(mi) / REALCOLORS);      /* YELLOW */
+               lp->colors[4] = MI_PIXEL(mi, 2 * MI_NPIXELS(mi) / REALCOLORS);  /* GREEN */
+               lp->colors[6] = MI_PIXEL(mi, 3 * MI_NPIXELS(mi) / REALCOLORS);  /* CYAN */
+               lp->colors[2] = MI_PIXEL(mi, 4 * MI_NPIXELS(mi) / REALCOLORS);  /* BLUE */
+               lp->colors[3] = MI_PIXEL(mi, 5 * MI_NPIXELS(mi) / REALCOLORS);  /* MAGENTA */
+               lp->colors[7] = MI_WHITE_PIXEL(mi);
+       }
+       free_list(lp);
+       lp->generation = 0;
+       lp->width = MI_WIDTH(mi);
+       lp->height = MI_HEIGHT(mi);
+
+  if (!local_neighbors) {
+    for (i = 0; i < NEIGHBORKINDS; i++) {
+      if (neighbors == plots[i]) {
+        local_neighbors = neighbors;
+        neighbor_kind = i;
+        break;
+      }
+                       if (i == NEIGHBORKINDS - 1) {
+#if 1
+                               local_neighbors = plots[NRAND(NEIGHBORKINDS)];
+                               neighbor_kind = (local_neighbors == 4) ? 0 : 1;
+#else
+                               local_neighbors = 4;
+                               neighbor_kind = 0;
+#endif
+                               break;
+                       }
+               }
+       }
+
+
+  if (local_neighbors == 6) {
+    int         nccols, ncrows;
+
+    if (lp->width < 4)
+      lp->width = 4;
+    if (lp->height < 4)
+      lp->height = 4;
+    if (size < -MINSIZE) {
+      lp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+              HEX_MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+    } else if (size < MINSIZE) {
+      if (!size)
+        lp->ys = MAX(MINSIZE, MIN(lp->width, lp->height) / HEX_MINGRIDSIZE);
+      else
+        lp->ys = MINSIZE;
+    } else
+      lp->ys = MIN(size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                 HEX_MINGRIDSIZE));
+    lp->xs = lp->ys;
+               nccols = MAX(lp->width / lp->xs - 2, HEX_ADAM_LOOPX + 1);
+               ncrows = MAX(lp->height / lp->ys - 1, HEX_ADAM_LOOPY + 1);
+    lp->ncols = nccols / 2;
+    lp->nrows = ncrows / 2;
+               lp->nrows -= !(lp->nrows & 1);  /* Must be odd */
+    lp->xb = (lp->width - lp->xs * nccols) / 2 + lp->xs;
+    lp->yb = (lp->height - lp->ys * ncrows) / 2 + lp->ys;
+    for (i = 0; i < 6; i++) {
+      lp->shape.hexagon[i].x = (lp->xs - 1) * hexagonUnit[i].x;
+      lp->shape.hexagon[i].y = ((lp->ys - 1) * hexagonUnit[i].y / 2) * 4 / 3;
+    }
+  } else {
+               if (size < -MINSIZE)
+                       lp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                             MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               lp->ys = MAX(MINSIZE, MIN(lp->width, lp->height) / MINGRIDSIZE);
+                       else
+                               lp->ys = MINSIZE;
+               } else
+                       lp->ys = MIN(size, MAX(MINSIZE, MIN(lp->width, lp->height) /
+                                              MINGRIDSIZE));
+               lp->xs = lp->ys;
+               lp->ncols = MAX(lp->width / lp->xs, ADAM_LOOPX + 1);
+               lp->nrows = MAX(lp->height / lp->ys, ADAM_LOOPX + 1);
+               lp->xb = (lp->width - lp->xs * lp->ncols) / 2;
+               lp->yb = (lp->height - lp->ys * lp->nrows) / 2;
+       }
+       lp->bx = 1;
+       lp->by = 1;
+       lp->bncols = lp->ncols + 2 * lp->bx;
+       lp->bnrows = lp->nrows + 2 * lp->by;
+
+       MI_CLEARWINDOW(mi);
+
+       if (lp->oldcells != NULL) {
+               (void) free((void *) lp->oldcells);
+               lp->oldcells = NULL;
+       }       
+       if ((lp->oldcells = (unsigned char *) calloc(lp->bncols * lp->bnrows, sizeof (unsigned char))) == NULL) {
+               release_loop(mi);
+               return;
+       }
+       if (lp->newcells != NULL) {
+               (void) free((void *) lp->newcells);
+               lp->newcells = NULL;
+       }
+       if ((lp->newcells = (unsigned char *) calloc(lp->bncols * lp->bnrows, sizeof (unsigned char))) == NULL) {
+               release_loop(mi);
+               return;
+       }
+  if (init_table()) {
+               release_loop(mi);
+               return;
+       }
+       init_adam(mi);
+}
+
+void
+draw_loop(ModeInfo * mi)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+       int         offset, i, j, life = 0;
+       unsigned char *z, *znew;
+
+       if (loops == NULL) {
+               init_loop(mi);
+               return;
+       }
+       MI_IS_DRAWN(mi) = True;
+       lp->dead = True;
+
+       for (j = lp->minrow; j <= lp->maxrow; j++) {
+               for (i = lp->mincol; i <= lp->maxcol; i++) {
+                       offset = j * lp->bncols + i;
+                       z = lp->oldcells + offset;
+                       znew = lp->newcells + offset;
+                       if (*z != *znew) {
+                               lp->dead = False;
+                               *z = *znew;
+                               addtolist(mi, i - lp->bx, j - lp->by, *znew);
+                               life = 1;
+                               if (i == lp->mincol && i > lp->bx)
+                                       lp->mincol--;
+                               if (j == lp->minrow && j > lp->by)
+                                       lp->minrow--;
+                               if (i == lp->maxcol && i < lp->bncols - 2 * lp->bx)
+                                       lp->maxcol++;
+                               if (j == lp->maxrow && j < lp->bnrows - 2 * lp->by)
+                                       lp->maxrow++;
+                       }
+               }
+       }
+       for (i = 0; i < COLORS; i++)
+               draw_state(mi, i);
+       if (++lp->generation > MI_CYCLES(mi) || lp->dead) {
+               init_loop(mi);
+               return;
+       } else
+               do_gen(lp);
+
+       if (lp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       if ((*(lp->oldcells + lp->redrawpos))) {
+                               drawcell(mi, lp->redrawpos % lp->bncols - lp->bx,
+                                        lp->redrawpos / lp->bncols - lp->by,
+                                        *(lp->oldcells + lp->redrawpos));
+                       }
+                       if (++(lp->redrawpos) >= lp->bncols * (lp->bnrows - lp->bx)) {
+                               lp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+void
+refresh_loop(ModeInfo * mi)
+{
+       loopstruct *lp = &loops[MI_SCREEN(mi)];
+
+       if (loops == NULL) {
+               init_loop(mi);
+               return;
+       }
+       MI_CLEARWINDOW(mi);
+       lp->redrawing = 1;
+       lp->redrawpos = lp->by * lp->ncols + lp->bx;
+}
+
+#endif /* MODE_loop */
diff --git a/xlockmore-4.14/modes/lyapunov.c b/xlockmore-4.14/modes/lyapunov.c
new file mode 100644 (file)
index 0000000..9628c35
--- /dev/null
@@ -0,0 +1,402 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* lyapunov --- animated lyapunov space */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)lyapunov.c 4.13 98/12/21 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Pictures discovered by Mario Markus and Benno Hess while trying to
+ * simulate how enzymes break down carbohydrates.  By adjusting a pair of
+ * parameter's they found they could make the simulated enzymes behave in
+ * either a orderly or chaotic manner.  Images are based on a formula
+ * named after the Russian mathematician Aleksandr M. Lyapunov.
+ * See  A.K. Dewdney's "Computer Recreations", Scientific American 
+ * Magazine" Sep 1991 for more info.
+ *
+ * Revision History:
+ * 17-Dec-98: Used as basis mandelbrot.c
+ */
+
+
+#ifdef STANDALONE
+#define PROGCLASS "Lyapunov"
+#define HACK_INIT init_lyapunov
+#define HACK_DRAW draw_lyapunov
+#define lyapunov_opts xlockmore_opts
+#define DEFAULTS "*delay: 25000 \n" \
+ "*count: 600 \n" \
+ "*cycles: 20000 \n" \
+ "*ncolors: 200 \n"
+#define SMOOTH_COLORS
+#define WRITABLE_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#include <X11/Xutil.h>
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#include "color.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_lyapunov
+
+#define MINPOWER 2
+#define DEF_INCREMENT  "1.00"
+/* 4.0 is best for seeing if a point is inside the set, 13 is better if
+** you want to get a pretty corona
+*/
+
+#define FLOATRAND(min,max) ((min)+((double) LRAND()/((double) MAXRAND))*((max)-(min)))
+
+ModeSpecOpt lyapunov_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   lyapunov_description =
+{"lyapunov", "init_lyapunov", "draw_lyapunov", "release_lyapunov",
+ NULL, "init_lyapunov", NULL, &lyapunov_opts,
+ 25000, 600, 20000, 1, 64, 1.0, "",
+ "Shows lyapunov space", 0, NULL};
+
+#endif
+
+#define ROUND_FLOAT(x,a) ((float) ((int) ((x) / (a) + 0.5)) * (a))
+#define MAXPOWER 14 /* (32 - 2) for 32 bit unsigned long */
+
+#ifdef DEBUG
+static int debug;
+#endif
+
+typedef struct {
+       int         column;
+       XColor      fgcol, bgcol;       /* foreground and background colour specs */
+       Bool        fixed_colormap;
+       int         ncolors;
+       XColor      top;
+       XColor      bottom;
+       XColor     *colors;
+       Colormap    cmap;
+       int         usable_colors;
+       unsigned int cur_color;
+       int         screen_width;
+       int                     screen_height;
+       float                   reptop;
+  unsigned long periodic_forcing;
+  int firstone;
+} lyapstruct;
+
+static lyapstruct *lyaps = NULL;
+#define OFFSET 3.0  /* Slight changes here may have unexpected results! */
+
+static double
+reps(unsigned long periodic_forcing, int firstone, int iter, double a, double b)
+{
+       int         forcing_index = firstone, n;
+  double      x = 0.5, total = 0.0, gamma;
+
+  a += OFFSET, b += OFFSET;
+       for (n = 1; n <= iter; n++) {
+               gamma = (periodic_forcing & (1 << forcing_index)) ? b : a;
+               if (forcing_index == 0)
+                       forcing_index = firstone;
+               else
+                       forcing_index--;
+               x = gamma * x * (1.0 - x);
+               /* Sci. Am. article says this should be a table */
+               total += (log(ABS(gamma * (1.0 - 2.0 * x))) / M_LN2);
+#ifdef DEBUG
+               if (debug)
+    /*if (!(n % 1000)) */
+    (void) printf("gamma %g, a %g,  b %g, result %g, n %d, total %g, x %g, index %d\n",
+                        gamma, a, b, total / n, n, total, x, forcing_index);
+#endif
+       }
+       return (total / ((double) iter));
+}
+
+void
+init_lyapunov(ModeInfo * mi)
+{
+       lyapstruct *lp;
+       int         preserve;
+       Bool        truecolor;
+       unsigned long redmask, greenmask, bluemask;
+       Window      window = MI_WINDOW(mi);
+       Display    *display = MI_DISPLAY(mi);
+       int i = NRAND(MAXPOWER);
+  unsigned long power2;
+
+       if (lyaps == NULL) {
+               if ((lyaps = (lyapstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (lyapstruct))) == NULL)
+                       return;
+       }
+       lp = &lyaps[MI_SCREEN(mi)];
+
+#ifdef DEBUG
+       debug = MI_IS_DEBUG(mi);
+#endif
+       lp->column = 0;
+
+       MI_CLEARWINDOW(mi);
+
+       lp->screen_width = MI_WIDTH(mi);
+       lp->screen_height = MI_HEIGHT(mi);
+
+       lp->reptop = 0.6;
+
+       /* To force a number, say <i = 2;> has  i + 2 (or 4) binary digits */
+  power2 = 1 << (i + 1);
+  /* Do not want numbers which in binary are all 1's. */
+  lp->periodic_forcing = NRAND(power2 - 1) + power2;
+       lp->firstone = 1;
+       for (i = 32 - 2; i >= 1; i--)
+               if (lp->periodic_forcing & (1 << i)) {
+                       lp->firstone = i;
+                       break;
+               }
+
+  if (MI_IS_VERBOSE(mi)) {
+               (void) printf("0x%x forcing number", lp->periodic_forcing);
+               switch (lp->periodic_forcing) {
+                       case 0x2:
+                               (void) printf(", swallow\n");
+                               break;
+      case 0x34:
+                               (void) printf(", jellyfish\n");
+                               break;
+                       case 0xFC0: /* Yeah, I think it should be "city" too, but its not. */
+                               (void) printf(", zircon zity\n");
+                               break;
+                       default:
+                               (void) printf("\n");
+                               break;
+               }
+       }
+
+#ifndef STANDALONE
+       lp->fixed_colormap = !setupColormap(mi,
+               &(lp->ncolors), &truecolor, &redmask, &greenmask, &bluemask);
+       if (!lp->fixed_colormap) {
+               preserve = preserveColors(MI_BLACK_PIXEL(mi), MI_WHITE_PIXEL(mi),
+                                         MI_BG_PIXEL(mi), MI_FG_PIXEL(mi));
+               lp->bgcol.pixel = MI_BG_PIXEL(mi);
+               lp->fgcol.pixel = MI_FG_PIXEL(mi);
+               XQueryColor(display, MI_COLORMAP(mi), &(lp->bgcol));
+               XQueryColor(display, MI_COLORMAP(mi), &(lp->fgcol));
+
+#define RANGE 65536
+#define DENOM 4
+               /* color in the bottom part */
+               lp->bottom.red = NRAND(RANGE / DENOM);
+               lp->bottom.blue = NRAND(RANGE / DENOM);
+               lp->bottom.green = NRAND(RANGE / DENOM);
+               /* color in the top part */
+               lp->top.red = RANGE - NRAND(((DENOM-1)*RANGE) / DENOM);
+               lp->top.blue = RANGE - NRAND(((DENOM-1)*RANGE) / DENOM);
+               lp->top.green = RANGE - NRAND(((DENOM-1)*RANGE) / DENOM);
+
+               /* allocate colormap, if needed */
+               if (lp->colors == NULL)
+                       lp->colors = (XColor *) malloc(sizeof (XColor) * lp->ncolors);
+               if (lp->cmap == None)
+                       lp->cmap = XCreateColormap(display, window,
+                                                  MI_VISUAL(mi), AllocAll);
+               lp->usable_colors = lp->ncolors - preserve;
+       }
+
+#endif /* !STANDALONE */
+}
+
+#if !defined(OLD_COLOR)
+static unsigned short
+pick_rgb(unsigned short bottom,unsigned short top,
+       int color_ind,int ncolors)
+{
+       /* por == part of range */
+       double por;
+       if (color_ind<ncolors/2) {
+               /* going up */
+               por = ((float)color_ind*2) / ncolors;
+       } else {
+               /* going down */
+               por = ((float)(color_ind-ncolors/2)*2) / ncolors;
+       }
+       return bottom + (top - bottom)*por;
+}
+#endif
+
+void
+draw_lyapunov(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       lyapstruct *lp = &lyaps[MI_SCREEN(mi)];
+       int         h;
+
+       unsigned int i;
+       int         j, k;
+
+       MI_IS_DRAWN(mi) = True;
+
+#ifndef STANDALONE
+       if (lp->column % 15 == 0) {
+               /* advance "drawing" color */
+               lp->cur_color = (lp->cur_color + 1) % lp->ncolors;
+               if (!lp->fixed_colormap && lp->usable_colors > 2) {
+                       while (lp->cur_color == MI_WHITE_PIXEL(mi) ||
+                              lp->cur_color == MI_BLACK_PIXEL(mi) ||
+                              lp->cur_color == MI_BG_PIXEL(mi) ||
+                              lp->cur_color == MI_FG_PIXEL(mi)) {
+                               lp->cur_color = (lp->cur_color + 1) % lp->ncolors;
+                       }
+               }
+               /* advance colormap */
+               if (!lp->fixed_colormap && lp->usable_colors > 2) {
+                       for (i = 0, j = lp->cur_color, k = 0;
+                            i < (unsigned int) lp->ncolors; i++) {
+                               if (i == MI_WHITE_PIXEL(mi)) {
+                                       lp->colors[i].pixel = i;
+                                       lp->colors[i].red = 65535;
+                                       lp->colors[i].blue = 65535;
+                                       lp->colors[i].green = 65535;
+                                       lp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                               } else if (i == MI_BLACK_PIXEL(mi)) {
+                                       lp->colors[i].pixel = i;
+                                       lp->colors[i].red = 0;
+                                       lp->colors[i].blue = 0;
+                                       lp->colors[i].green = 0;
+                                       lp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                               } else if (i == MI_BG_PIXEL(mi)) {
+                                       lp->colors[i] = lp->bgcol;
+                               } else if (i == MI_FG_PIXEL(mi)) {
+                                       lp->colors[i] = lp->fgcol;
+                               } else {
+#if defined(OLD_COLOR)
+                                       /* this is known to work well enough. I just wanted
+                                       ** to explore some other possibilities
+                                       */
+                                       double      range;
+                                       lp->colors[i].pixel = i;
+                                       range = ((double) (lp->top.red - lp->bottom.red)) /
+                                               lp->ncolors;
+                                       lp->colors[i].red = (short unsigned int) (range * j +
+                                                            lp->bottom.red);
+                                       range = ((double) (lp->top.green - lp->bottom.green)) /
+                                               lp->ncolors;
+                                       lp->colors[i].green = (short unsigned int) (range * j +
+                                                          lp->bottom.green);
+                                       range = ((double) (lp->top.blue - lp->bottom.blue)) /
+                                               lp->ncolors;
+                                       lp->colors[i].blue = (short unsigned int) (range * j +
+                                                           lp->bottom.blue);
+                                       lp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                                       j = (j + 1) % lp->ncolors;
+                                       k++;
+#else
+                                       lp->colors[i].pixel = i;
+                                       lp->colors[i].red = pick_rgb(lp->bottom.red,lp->top.red,
+                                               j,lp->ncolors);
+                                       lp->colors[i].green = pick_rgb(lp->bottom.green,lp->top.green,
+                                               j,lp->ncolors);
+                                       lp->colors[i].blue = pick_rgb(lp->bottom.blue,lp->top.blue,
+                                               j,lp->ncolors);
+                                       lp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                                       j = (j + 1) % lp->ncolors;
+                                       k++;
+#endif
+                               }
+                       }
+                       /* make the entire lyapunov move forward */
+                       XStoreColors(display, lp->cmap, lp->colors, lp->ncolors);
+                       setColormap(display, window, lp->cmap, MI_IS_INWINDOW(mi));
+               }
+       }
+#endif /* !STANDALONE */
+       /* so we iterate columns beyond the width of the physical screen, so that
+       ** we just wait around and show what we've done
+       */
+       if (lp->column >= 4 * lp->screen_width) {
+               /* reset to left edge of screen */
+               init_lyapunov(mi);
+               return;
+               /* select a new region! */
+       } else if (lp->column >= lp->screen_width) {
+               /* delay a while */
+               lp->column++;
+               return;
+       }
+       for (h = 0; h < lp->screen_height; h++) {
+               unsigned int color;
+               double  result;
+
+#define MULT 1.0
+               result = reps(lp->periodic_forcing, lp->firstone, MI_COUNT(mi),
+                       ((double) lp->column) / (MULT * lp->screen_width),
+                       ((double) h) / (MULT * lp->screen_height));
+#ifdef DEBUG
+               if (debug)
+               (void) printf("a %g, b %g, result %g\n",
+                        ((double) lp->column) / lp->screen_width,
+                        ((double) h) / lp->screen_height, result); 
+#endif
+               if (result > 0.0)
+                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               else {
+                       color=(unsigned int) ((MI_NPIXELS(mi) * (float)-result) / lp->reptop);
+                       color = color % MI_NPIXELS(mi);
+#ifndef STANDALONE
+                       if (!lp->fixed_colormap && lp->usable_colors > 2) {
+                               while (color == MI_WHITE_PIXEL(mi) ||
+                                      color == MI_BLACK_PIXEL(mi) ||
+                                      color == MI_BG_PIXEL(mi) ||
+                                      color == MI_FG_PIXEL(mi)) {
+                                       color = (color + 1) % lp->ncolors;
+                               }
+                               XSetForeground(display, gc, color);
+                       } else
+                               XSetForeground(display, gc, MI_PIXEL(mi, color));
+#endif /* !STANDALONE */
+               }
+               /* we no longer have vertical symmetry - so we colpute all points
+               ** and don't draw with redundancy
+               */
+               XDrawPoint(display, window, gc, lp->column, h);
+       }
+       lp->column++;
+}
+
+void
+release_lyapunov(ModeInfo * mi)
+{
+       if (lyaps != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       lyapstruct *lp = &lyaps[screen];
+
+                       if (lp->cmap != None)
+                               XFreeColormap(MI_DISPLAY(mi), lp->cmap);
+                       if (lp->colors != NULL)
+                               XFree((caddr_t) lp->colors);
+               }
+               (void) free((void *) lyaps);
+               lyaps = NULL;
+       }
+}
+
+#endif /* MODE_lyapunov */
diff --git a/xlockmore-4.14/modes/mandelbrot.c b/xlockmore-4.14/modes/mandelbrot.c
new file mode 100644 (file)
index 0000000..b957ec1
--- /dev/null
@@ -0,0 +1,642 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* mandelbrot --- animated mandelbrot sets */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)mandelbrot.c 4.13 98/12/21 xlockmore";
+
+#endif
+
+#define USE_LOG
+
+/*-
+ * Copyright (c) 1997 Dan Stromberg <strombrg@nis.acs.uci.edu>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * See  A.K. Dewdney's "Computer Recreations", Scientific American 
+ * Magazine" Aug 1985 for more info.  Also A.K. Dewdney's "Computer
+ * Recreations", Scientific American Magazine" Jul 1989, has some neat
+ * extensions besides z^n + c (n small but >= 2) some of these are:
+ *   z^z + z^n + c
+ *   sin(z) + e^z + c 
+ *   sin(z) + z^n + c
+ * These were first explored by a colleague of Mandelbrot, Clifford A.
+ * Pickover.  These would make nice additions to add.
+ *
+ * Revision History:
+ * 24-Mar-99: DEM and Binary decomp options added by Tim.Auckland@Sun.COM
+ *            Ideas from Peitgen & Saupe's "The Science of Fractal Images"
+ * 20-Oct-97: Written by Dan Stromberg <strombrg@nis.acs.uci.edu>
+ * 17-Nov-98: Many Changes by Stromberg, including selection of
+ *            interesting subregions, more extreme color ranges,
+ *            reduction of possible powers to smaller/more interesting
+ *            range, elimination of some unused code, slower color cycling,
+ *            longer period of color cycling after the drawing is complete.
+ *            Hopefully the longer color cycling period will make the mode
+ *            reasonable even after CPUs are so fast that the drawing
+ *            interval goes by quickly
+ */
+
+
+#ifdef STANDALONE
+#define PROGCLASS "Mandelbrot"
+#define HACK_INIT init_mandelbrot
+#define HACK_DRAW draw_mandelbrot
+#define mandelbrot_opts xlockmore_opts
+#define DEFAULTS "*delay: 25000 \n" \
+ "*count: -8 \n" \
+ "*cycles: 20000 \n" \
+ "*ncolors: 200 \n"
+#define SMOOTH_COLORS
+#define WRITABLE_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#include <X11/Xutil.h>
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#include "color.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_mandelbrot
+
+#define MINPOWER 2
+#define DEF_INCREMENT  "1.00"
+#define DEF_BINARY     "False"
+#define DEF_DEM        "False"
+/* 4.0 is best for seeing if a point is inside the set, 13 is better if
+** you want to get a pretty corona
+*/
+#define ESCAPE 13.0
+#define FLOATRAND(min,max) ((min)+((double) LRAND()/((double) MAXRAND))*((max)-(min)))
+
+       /* incr also would be nice as a parameter.  It controls how fast
+          the order is advanced.  Non-integral values are not true orders,
+          but it's a somewhat interesting function anyway
+        */
+static float increment;
+static Bool  binary;
+static Bool  dem;
+
+static XrmOptionDescRec opts[] =
+{
+     {"-increment", ".mandelbrot.increment", XrmoptionSepArg, (caddr_t) NULL},
+     {"-binary", ".mandelbrot.binary", XrmoptionNoArg, (caddr_t) "on"},
+     {"+binary", ".mandelbrot.binary", XrmoptionNoArg, (caddr_t) "off"},
+     {"-dem", ".mandelbrot.dem", XrmoptionNoArg, (caddr_t) "on"},
+     {"+dem", ".mandelbrot.dem", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+ {(caddr_t *) & increment, "increment", "Increment", DEF_INCREMENT, t_Float},
+ {(caddr_t *) & binary, "binary", "Binary", DEF_BINARY, t_Bool},
+ {(caddr_t *) & dem, "dem", "Dem", DEF_DEM, t_Bool},
+};
+static OptionStruct desc[] =
+{
+       {"-increment value", "increasing orders"},
+       {"-/+binary", "turn on/off Binary Decomposition colour modulation"},
+       {"-/+dem", "turn on/off Distance Estimator Method (instead of escape time)"}
+};
+
+ModeSpecOpt mandelbrot_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   mandelbrot_description =
+{"mandelbrot", "init_mandelbrot", "draw_mandelbrot", "release_mandelbrot",
+ NULL, "init_mandelbrot", NULL, &mandelbrot_opts,
+ 25000, -8, 20000, 1, 64, 1.0, "",
+ "Shows mandelbrot sets", 0, NULL};
+
+#endif
+
+#define ROUND_FLOAT(x,a) ((float) ((int) ((x) / (a) + 0.5)) * (a))
+
+typedef struct {
+       double      real, imag;
+} complex;
+
+static void
+add(complex * a, complex b)
+{
+       a->real = a->real + b.real;
+       a->imag = a->imag + b.imag;
+}
+
+static void
+mult(complex * a, complex b)
+{
+       double      tr, ti;
+
+       /* a.real*b.real + i*a.real*b.imag + i*a.imag*b.real + i^2*a.imag*b.imag */
+       tr = a->real * b.real - a->imag * b.imag;
+       ti = a->real * b.imag + a->imag * b.real;
+       a->real = tr;
+       a->imag = ti;
+}
+
+/* Plans for future additions?  a, z complex; x, y real
+   sin(z) = (e^(i * z) - e^(-i * z)) / (2 * i)
+   cos(z) = (e^(i * z) - e^(-i * z)) / 2
+   a^z = e^(z * ln(a))
+   e^z = e^x * (cos(y) + i * sin(y))
+   ln(z) = ln ((x^2 + y^2)^(1/2)) + i * invtan(y/x)
+ */
+
+/* this is a true power function. */
+static void
+ipow(complex * a, int n)
+{
+
+
+       switch (n) {
+               case 1:
+                       return;
+               case 2:
+                       mult(a, *a);
+                       return;
+               default:
+                       {
+                               complex     a2;
+                               int         t2;
+
+                               a2 = *a;        /* Not very efficient to use:  mult(a, ipow(&a2, n-1)); */
+                               t2 = n / 2;
+                               ipow(&a2, t2);
+                               mult(&a2, a2);
+                               if (t2 * 2 != n)        /* if n is odd */
+                                       mult(&a2, *a);
+                               *a = a2;
+                       }
+       }
+}
+
+typedef struct {
+       int         counter;
+       double      power;
+       int         column;
+       XColor      fgcol, bgcol;       /* foreground and background colour specs */
+       Bool        fixed_colormap;
+       int         ncolors;
+       XColor      top;
+       XColor      bottom;
+       XColor     *colors;
+       Colormap    cmap;
+       int         usable_colors;
+       unsigned int cur_color;
+       complex         extreme_ul;
+       complex         extreme_lr;
+       complex         ul;
+       complex         lr;
+       int         screen_width;
+       int                     screen_height;
+       int                     reptop;
+       Bool            dem;
+       Bool            binary;
+} mandelstruct;
+
+static mandelstruct *mandels = NULL;
+
+/* do the iterations
+ * if binary is true, check halfplane of last iteration.
+ * if demrange is non zero, estimate lower bound of dist(c, M)
+ * Loosely based on  Peitgen & Saupe's "The Science of Fractal Images" 
+ */
+static int
+reps(complex c, double p, int r, Bool binary, double demrange)
+{
+       int         rep;
+       int         escaped = 0;
+       complex     t;
+       int escape = (demrange == 0) ? ESCAPE :
+               ESCAPE*ESCAPE*ESCAPE*ESCAPE; /* 2 more iterations */
+       complex     t1;
+       complex     dt;
+
+       t = c;
+       dt.real = 1; dt.imag = 0;
+       for (rep = 0; rep < r; rep++) {
+           t1 = t;
+               ipow(&t, p);
+               add(&t, c);
+               if (t.real * t.real + t.imag * t.imag >= escape) {
+                       escaped = 1;
+                       break;
+               }
+               if (demrange){
+                       /* compute dt/dc 
+                        *               p-1
+                        * dt    =  p * t  * dt + 1
+                        *   k+1         k     k
+                        */
+                       dt.real *= p; dt.imag *= p;
+                       if(p > 2) ipow(&t1, p - 1);
+                       mult(&dt, t1);
+                       dt.real += 1;
+                       if (dt.real * dt.real + dt.imag * dt.imag >= 1e300) {
+                               escaped = 2;
+                               break;
+                       }
+               }
+       }
+       if (escaped) {
+               if(demrange) {
+                       double mt = sqrt(t1.real * t1.real + t1.imag * t1.imag);
+                        /* distance estimate */
+                       double dist = 0.5 * mt * log(mt) /
+                               sqrt(dt.real * dt.real + dt.imag * dt.imag);
+                       rep = (int) 1 + 10*r*dist/demrange; /* scale for viewing */
+                       if(rep > r-1) rep = r-1; /* chop into color range */
+               } else {
+                       if(binary && t.imag > 0)
+                               rep = (r + rep / 2) % r; /* binary decomp */
+               }
+               return rep;
+       } else
+               return r;
+}
+
+static void
+Select(
+       /* input variables first */
+       complex *extreme_ul,complex *extreme_lr,
+       int width,int height,
+       int power,int top,
+       /* output variables follow */
+       complex *selected_ul,complex *selected_lr)
+       {
+       double precision;
+       double s2;
+       int inside;
+       int uninteresting;
+       int found;
+       int tries;
+       found = 0;
+       while (!found)
+               {
+               /* select a precision - be careful with this */
+               precision = pow(2.0,FLOATRAND(-9.0,-18.0));
+               /* printf("precision is %f\n",precision); */
+               for (tries=0;tries<10000&&!found;tries++)
+                       {
+                       /* it eventually turned out that this inner loop doesn't always
+                       ** terminate - so we just try 10000 times, and if we don't get
+                       ** anything interesting, we pick a new precision
+                       */
+                       complex temp;
+                       int sample_step = 4;
+                       int row,column;
+                       inside = 0;
+                       uninteresting = 0;
+                       /* pick a random point in the allowable range */
+                       temp.real = FLOATRAND(extreme_ul->real,extreme_lr->real);
+                       temp.imag = FLOATRAND(extreme_ul->imag,extreme_lr->imag);
+                       /* find upper left and lower right points */
+                       selected_ul->real = temp.real - precision * width / 2;
+                       selected_lr->real = temp.real + precision * width / 2;
+                       selected_ul->imag = temp.imag - precision * height / 2;
+                       selected_lr->imag = temp.imag + precision * height / 2;
+                       /* sample the results we'd get from this choice, accept or reject
+                       ** accordingly
+                       */
+                       for (row=0; row<sample_step; row++)
+                               {
+                               for (column=0; column<sample_step; column++)
+                                       {
+                                       int r;
+                                       temp.imag = selected_ul->imag +
+                                               (selected_ul->imag - selected_lr->imag) * 
+                                               (((double)row)/sample_step);
+                                       temp.real = selected_ul->real + 
+                                               (selected_ul->real - selected_lr->real) * 
+                                               (((double)column)/sample_step);
+                                       r = reps(temp,power,top,0,0);
+                                       /* Here, we just want to see if the point is in the set,
+                                       ** not if we can make something pretty
+                                       */
+                                       if (r == top)
+                                               {
+                                               inside++;
+                                               }
+                                       if (r < 2)
+                                               {
+                                               uninteresting++;
+                                               }
+                                       }
+                               }
+                       s2 = sample_step*sample_step;
+                       /* more than 10 percent, but less than 60 percent inside the set */
+                       if (inside >= ceil(s2/10.0) && inside <= s2*6.0/10.0 &&
+                               uninteresting <= s2/10.0)
+                               {
+                               /* this one looks interesting */
+                               found = 1;
+                               }
+                       else
+                               {
+                               /* this doesn't look like a real good combination, so back up
+                               ** to the top of the loop to try another possibility
+                               */
+                               }
+                       }
+               }
+       }
+
+void
+init_mandelbrot(ModeInfo * mi)
+{
+       mandelstruct *mp;
+       int         preserve;
+       Bool        truecolor;
+       unsigned long redmask, greenmask, bluemask;
+       Window      window = MI_WINDOW(mi);
+       Display    *display = MI_DISPLAY(mi);
+
+       if (mandels == NULL) {
+               if ((mandels = (mandelstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (mandelstruct))) == NULL)
+                       return;
+       }
+       mp = &mandels[MI_SCREEN(mi)];
+
+
+       mp->power = NRAND(3) + MINPOWER;
+
+       mp->column = 0;
+       mp->counter = 0;
+
+       MI_CLEARWINDOW(mi);
+
+       mp->screen_width = MI_WIDTH(mi);
+       mp->screen_height = MI_HEIGHT(mi);
+
+       if (MI_IS_FULLRANDOM(mi)) {
+         switch(NRAND(3)){
+         case 0: mp->binary = 1; mp->dem = 0; break;
+         case 1: mp->binary = 0; mp->dem = 1; break;
+         default:mp->binary = 0; mp->dem = 0; break;
+         }
+       } else {
+         mp->binary = binary;
+         mp->dem = dem;
+       }
+
+       mp->reptop = 300;
+
+       /* these could be tuned a little closer, but the selection
+       ** process throws out the chaf anyway, it just takes slightly
+       ** longer
+       */
+       mp->extreme_ul.real = -3.0;
+       mp->extreme_ul.imag = -3.0;
+       mp->extreme_lr.real = 3.0;
+       mp->extreme_lr.imag = 3.0;
+
+#ifndef STANDALONE
+       mp->fixed_colormap = !setupColormap(mi,
+               &(mp->ncolors), &truecolor, &redmask, &greenmask, &bluemask);
+       if (!mp->fixed_colormap) {
+               preserve = preserveColors(MI_BLACK_PIXEL(mi), MI_WHITE_PIXEL(mi),
+                                         MI_BG_PIXEL(mi), MI_FG_PIXEL(mi));
+               mp->bgcol.pixel = MI_BG_PIXEL(mi);
+               mp->fgcol.pixel = MI_FG_PIXEL(mi);
+               XQueryColor(display, MI_COLORMAP(mi), &(mp->bgcol));
+               XQueryColor(display, MI_COLORMAP(mi), &(mp->fgcol));
+
+#define RANGE 65536
+#define DENOM 4
+               /* color in the bottom part */
+               mp->bottom.red = NRAND(RANGE / DENOM);
+               mp->bottom.blue = NRAND(RANGE / DENOM);
+               mp->bottom.green = NRAND(RANGE / DENOM);
+               /* color in the top part */
+               mp->top.red = RANGE - NRAND(((DENOM-1)*RANGE) / DENOM);
+               mp->top.blue = RANGE - NRAND(((DENOM-1)*RANGE) / DENOM);
+               mp->top.green = RANGE - NRAND(((DENOM-1)*RANGE) / DENOM);
+
+               /* allocate colormap, if needed */
+               if (mp->colors == NULL)
+                       mp->colors = (XColor *) malloc(sizeof (XColor) * mp->ncolors);
+               if (mp->cmap == None)
+                       mp->cmap = XCreateColormap(display, window,
+                                                  MI_VISUAL(mi), AllocAll);
+               mp->usable_colors = mp->ncolors - preserve;
+       }
+       Select(&mp->extreme_ul,&mp->extreme_lr,
+               mp->screen_width,mp->screen_height,
+               mp->power,mp->reptop,
+               &mp->ul,&mp->lr);
+
+#endif /* !STANDALONE */
+}
+
+#if !defined(OLD_COLOR)
+static unsigned short
+pick_rgb(unsigned short bottom,unsigned short top,
+       int color_ind,int ncolors)
+{
+       /* por == part of range */
+       double por;
+       if (color_ind<ncolors/2) {
+               /* going up */
+               por = ((float)color_ind*2) / ncolors;
+       } else {
+               /* going down */
+               por = ((float)(color_ind-ncolors/2)*2) / ncolors;
+       }
+       return bottom + (top - bottom)*por;
+}
+#endif
+
+void
+draw_mandelbrot(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       mandelstruct *mp = &mandels[MI_SCREEN(mi)];
+       int         h;
+       complex     c;
+#if defined(USE_LOG)
+       double      log_top;
+#endif
+
+       double      demrange;
+       unsigned int i;
+       int         j, k;
+
+#if defined(USE_LOG)
+       log_top = log((float) mp->reptop);
+#endif
+
+       MI_IS_DRAWN(mi) = True;
+
+#ifndef STANDALONE
+       if (mp->counter % 15 == 0) {
+               /* advance "drawing" color */
+               mp->cur_color = (mp->cur_color + 1) % mp->ncolors;
+               if (!mp->fixed_colormap && mp->usable_colors > 2) {
+                       while (mp->cur_color == MI_WHITE_PIXEL(mi) ||
+                              mp->cur_color == MI_BLACK_PIXEL(mi) ||
+                              mp->cur_color == MI_BG_PIXEL(mi) ||
+                              mp->cur_color == MI_FG_PIXEL(mi)) {
+                               mp->cur_color = (mp->cur_color + 1) % mp->ncolors;
+                       }
+               }
+               /* advance colormap */
+               if (!mp->fixed_colormap && mp->usable_colors > 2) {
+                       for (i = 0, j = mp->cur_color, k = 0;
+                            i < (unsigned int) mp->ncolors; i++) {
+                               if (i == MI_WHITE_PIXEL(mi)) {
+                                       mp->colors[i].pixel = i;
+                                       mp->colors[i].red = 65535;
+                                       mp->colors[i].blue = 65535;
+                                       mp->colors[i].green = 65535;
+                                       mp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                               } else if (i == MI_BLACK_PIXEL(mi)) {
+                                       mp->colors[i].pixel = i;
+                                       mp->colors[i].red = 0;
+                                       mp->colors[i].blue = 0;
+                                       mp->colors[i].green = 0;
+                                       mp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                               } else if (i == MI_BG_PIXEL(mi)) {
+                                       mp->colors[i] = mp->bgcol;
+                               } else if (i == MI_FG_PIXEL(mi)) {
+                                       mp->colors[i] = mp->fgcol;
+                               } else {
+#if defined(OLD_COLOR)
+                                       /* this is known to work well enough. I just wanted
+                                       ** to explore some other possibilities
+                                       */
+                                       double      range;
+                                       mp->colors[i].pixel = i;
+                                       range = ((double) (mp->top.red - mp->bottom.red)) /
+                                               mp->ncolors;
+                                       mp->colors[i].red = (short unsigned int) (range * j +
+                                                            mp->bottom.red);
+                                       range = ((double) (mp->top.green - mp->bottom.green)) /
+                                               mp->ncolors;
+                                       mp->colors[i].green = (short unsigned int) (range * j +
+                                                          mp->bottom.green);
+                                       range = ((double) (mp->top.blue - mp->bottom.blue)) /
+                                               mp->ncolors;
+                                       mp->colors[i].blue = (short unsigned int) (range * j +
+                                                           mp->bottom.blue);
+                                       mp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                                       j = (j + 1) % mp->ncolors;
+                                       k++;
+#else
+                                       mp->colors[i].pixel = i;
+                                       mp->colors[i].red = pick_rgb(mp->bottom.red,mp->top.red,
+                                               j,mp->ncolors);
+                                       mp->colors[i].green = pick_rgb(mp->bottom.green,mp->top.green,
+                                               j,mp->ncolors);
+                                       mp->colors[i].blue = pick_rgb(mp->bottom.blue,mp->top.blue,
+                                               j,mp->ncolors);
+                                       mp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                                       j = (j + 1) % mp->ncolors;
+                                       k++;
+#endif
+                               }
+                       }
+                       /* make the entire mandelbrot move forward */
+                       XStoreColors(display, mp->cmap, mp->colors, mp->ncolors);
+                       setColormap(display, window, mp->cmap, MI_IS_INWINDOW(mi));
+               }
+       }
+#endif /* !STANDALONE */
+       /* so we iterate columns beyond the width of the physical screen, so that
+       ** we just wait around and show what we've done
+       */
+       if (mp->column >= 3 * mp->screen_width) {
+               /* reset to left edge of screen, bump power */
+               mp->column = 0;
+               mp->power = NRAND(3) + MINPOWER;
+               /* select a new region! */
+               Select(&mp->extreme_ul,&mp->extreme_lr,
+                       mp->screen_width,mp->screen_height,
+                       mp->power,mp->reptop,
+                       &mp->ul,&mp->lr);
+       } else if (mp->column >= mp->screen_width) {
+               /* delay a while */
+               mp->column++;
+               mp->counter++;
+               return;
+       }
+       /* demrange is used to give some idea of scale */
+       demrange = mp->dem ? fabs(mp->ul.real - mp->lr.real) / 2 : 0;
+       for (h = 0; h < mp->screen_height; h++) {
+               unsigned int color;
+               int         result;
+
+               /* c.real = 1.3 - (double) mp->column / mp->screen_width * 3.4; */
+               /* c.imag = -1.6 + (double) h / mp->screen_height * 3.2; */
+               c.real = mp->ul.real + 
+                       (mp->ul.real-mp->lr.real)*(((double)(mp->column))/mp->screen_width);
+               c.imag = mp->ul.imag + 
+                       (mp->ul.imag - mp->lr.imag)*(((double) h) / mp->screen_height);
+               result = reps(c, mp->power, mp->reptop, mp->binary, demrange);
+               if (result == 0 || result == mp->reptop)
+                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               else {
+#if defined(USE_LOG)
+                       color=(unsigned int) (MI_NPIXELS(mi) * log((float) result) / log_top);
+#else
+                       color=(unsigned int) ((MI_NPIXELS(mi) * (float)result) / mp->reptop);
+#endif
+#ifndef STANDALONE
+                       if (!mp->fixed_colormap && mp->usable_colors > 2) {
+                               while (color == MI_WHITE_PIXEL(mi) ||
+                                      color == MI_BLACK_PIXEL(mi) ||
+                                      color == MI_BG_PIXEL(mi) ||
+                                      color == MI_FG_PIXEL(mi)) {
+                                       color = (color + 1) % mp->ncolors;
+                               }
+                               XSetForeground(display, gc, color);
+                       } else
+                               XSetForeground(display, gc, MI_PIXEL(mi, color));
+#endif /* !STANDALONE */
+               }
+               /* we no longer have vertical symmetry - so we compute all points
+               ** and don't draw with redundancy
+               */
+               XDrawPoint(display, window, gc, mp->column, h);
+       }
+       mp->column++;
+       mp->counter++;
+       if (mp->counter > MI_CYCLES(mi)) {
+               init_mandelbrot(mi);
+       }
+}
+
+void
+release_mandelbrot(ModeInfo * mi)
+{
+       if (mandels != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       mandelstruct *mp = &mandels[screen];
+
+                       if (mp->cmap != None)
+                               XFreeColormap(MI_DISPLAY(mi), mp->cmap);
+                       if (mp->colors != NULL)
+                               XFree((caddr_t) mp->colors);
+               }
+               (void) free((void *) mandels);
+               mandels = NULL;
+       }
+}
+
+#endif /* MODE_mandelbrot */
diff --git a/xlockmore-4.14/modes/marquee.c b/xlockmore-4.14/modes/marquee.c
new file mode 100644 (file)
index 0000000..f24a7b4
--- /dev/null
@@ -0,0 +1,516 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* marquee --- types a text-file or a text ribbon */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)marquee.c    4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by Tobias Gloth and David Bagley
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 03-Nov-95 Many changes (hopefully good ones) by David Bagley
+ * 01-Oct-95 Written by Tobias Gloth
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Marquee"
+#define HACK_INIT init_marquee
+#define HACK_DRAW draw_marquee
+#define marquee_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*ncolors: 64 \n" \
+ "*font: \n" \
+ "*text: \n" \
+ "*filename: \n" \
+ "*fortunefile: \n" \
+ "*program: \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_marquee
+
+ModeSpecOpt marquee_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   marquee_description =
+{"marquee", "init_marquee", "draw_marquee", "release_marquee",
+ "refresh_marquee", "init_marquee", NULL, &marquee_opts,
+ 100000, 1, 1, 1, 64, 1.0, "",
+ "Shows messages", 0, NULL};
+
+#endif
+
+#define font_height(f) ((f==None)?8:f->ascent + f->descent)
+
+extern XFontStruct *getFont(Display * display);
+extern char *getWords(int screen, int screens);
+extern int  isRibbon(void);
+
+typedef struct {
+       int         ascent;
+       int         height;
+       int         win_height;
+       int         win_width;
+       int         x;
+       int         y;
+       int         t;
+       int         startx;
+       int         nonblanks;
+       int         color;
+       int         time;
+       GC          gc;
+       char       *words;
+       char        modwords[256];
+} marqueestruct;
+
+static marqueestruct *marquees = NULL;
+
+static XFontStruct *mode_font = None;
+static int  char_width[256];
+
+static int
+font_width(XFontStruct * font, char ch)
+{
+       int         dummy;
+       XCharStruct xcs;
+
+       (void) XTextExtents(font, &ch, 1, &dummy, &dummy, &dummy, &xcs);
+       return xcs.width;
+}
+
+/* returns 1 if c is a printable char, the test should work for most 8 * bit
+   charsets (e.g. latin1), if we would use isprint, we would * depend of
+   locale settings that are probably incorrect. */
+
+static int
+is_valid_char(char c)
+{
+       return (unsigned char) c >= ' ';
+}
+
+static int
+is_char_back_char(char *s)
+{
+       return is_valid_char(*s) && *(s + 1) == '\b' &&
+               *(s + 2) && is_valid_char(*(s + 2));
+}
+
+static int
+char_back_char_width(char *s)
+{
+       int         w1 = char_width[(int) (unsigned char) *s];
+       int         w2 = char_width[(int) (unsigned char) *(s + 2)];
+
+       return w2 < w1 ? w1 : w2;
+}
+
+
+/*-
+ * fix strings of the form abc^H^H^H123 to a^H1b^H2c^H3, since we only
+ * handle backspace for char, back, char correctly. We do this without
+ * duplicating the string, but I'm not sure if there are conditions
+ * when the string is actually const. (when it is def_message, no ^Hs
+ * are present, I'm not sure about resource strings)
+ */
+
+static char *
+fixup_back(char *s)
+{
+       char       *p, *p1, *p2;
+       char        tmp[1000];
+       char       *t;
+       char       *w;
+
+       /* first of all, check if we have to do anything */
+
+       if (!*s)
+               return s;
+
+       for (p = s + 1; *p; p++)
+               if (*p == '\b' && *(p + 1) == '\b')
+                       break;
+       if (!*p)
+               return s;
+
+       /* now search for runs of the form char*n, back*n, char. */
+
+       for (p = s; *p; p++) {
+               for (p1 = p; *p1 && is_valid_char(*p1); p1++);
+               if (*p1 == '\b') {
+                       for (p2 = p1; *p2 && *p2 == '\b'; p2++);
+
+                       /* do we have `enough' chars for the backspaces? */
+
+                       if (p2 - p1 > 1 && p1 - p >= p2 - p1) {
+                               if (p1 - p > p2 - p1) {
+                                       p = p1 - (p2 - p1);
+                               }
+                               /* the situation is as follows:
+                                  p points to the first char,
+                                  p1 to the first backspace (end first char run),
+                                  p2 to the first char in the 2nd run
+
+                                  Question: how to do that without tmp storage?
+                                */
+                               (void) strncpy(tmp, p, p1 - p);
+                               t = tmp;
+                               w = p;
+                               while (t - tmp < p1 - p && *p2) {
+                                       *w++ = *t++;
+                                       *w++ = '\b';
+                                       *w++ = *p2++;
+                               }
+                               p = p2;
+                       } else {
+                               p = p2;
+                       }
+               } else {
+                       /* we hit some other control char, just continue at this
+                          position */
+                       p = p1;
+               }
+       }
+       return s;
+}
+
+static int
+text_font_width(char *string)
+{
+       int         n = 0, x = 0, t = 0;
+
+       /* The following does not handle a tab or other weird junk */
+       while (*string != '\0') {
+               if (x > n)
+                       n = x;
+               switch (*string) {
+                       case '\v':
+                       case '\f':
+                       case '\n':
+                               x = 0;
+                               t = 0;
+                               break;
+                       case '\b':
+                               /* we handle only char, ^H, char smartly, if
+                                * we have something different, we use the
+                                * (probably wrong) assumption that we have
+                                * a monospaced font. */
+                               if (t) {
+                                       t--;
+                                       x -= char_width[' '];
+                               }
+                               break;
+                       case '\t':
+                               x += char_width[' '] * (8 - (t % 8));
+                               t = ((t + 8) / 8) * 8;
+                               break;
+                       case '\r':
+                               break;
+                       default:
+                               t++;
+                               /* handle char, ^H, char */
+                               if (is_char_back_char(string)) {
+                                       x += char_back_char_width(string);
+                                       string += 2;
+                               } else {
+                                       x += char_width[(int) (unsigned char) *string];
+                               }
+               }
+               string++;
+       }
+       return n;
+}
+
+static int
+text_height(char *string)
+{
+       int         n = 0;
+
+       while (*string != '\0') {
+               if ((*string == '\n') || (*string == '\f') || (*string == '\v'))
+                       n++;
+               string++;
+       }
+       return n;
+}
+
+static int
+add_blanks(marqueestruct * mp)
+{
+       if (mp->t < 251) {
+               mp->modwords[mp->t] = ' ';
+               mp->t++;
+               mp->modwords[mp->t] = ' ';
+               mp->t++;
+               mp->modwords[mp->t] = '\0';
+               (void) strcat(mp->modwords, "  ");
+       }
+       mp->x -= 2 * char_width[' '];
+       if (mp->x <= -char_width[(int) (unsigned char) mp->modwords[0]]) {
+               mp->x += char_width[(int) (unsigned char) mp->modwords[0]];
+               (void) memcpy(mp->modwords, &(mp->modwords[1]), mp->nonblanks);
+               mp->nonblanks--;
+       }
+       return (mp->nonblanks < 0);
+}
+
+static void
+add_letter(marqueestruct * mp, char letter)
+{
+       if (mp->t < 252) {
+               mp->modwords[mp->t] = letter;
+               mp->t++;
+               mp->modwords[mp->t] = '\0';
+               (void) strcat(mp->modwords, "  ");
+       }
+       mp->x -= char_width[(int) letter];
+       if (mp->x <= -char_width[(int) (unsigned char) mp->modwords[0]]) {
+               mp->x += char_width[(int) (unsigned char) mp->modwords[0]];
+               (void) memcpy(mp->modwords, &(mp->modwords[1]), mp->t);
+               mp->modwords[mp->t] = ' ';
+               mp->t--;
+       } else
+               mp->nonblanks = mp->t;
+}
+
+void
+init_marquee(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       marqueestruct *mp;
+       XGCValues   gcv;
+       int         i;
+
+       if (marquees == NULL) {
+               if ((marquees = (marqueestruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (marqueestruct))) == NULL)
+                       return;
+       }
+       mp = &marquees[MI_SCREEN(mi)];
+
+       mp->win_width = MI_WIDTH(mi);
+       mp->win_height = MI_HEIGHT(mi);
+       if (MI_NPIXELS(mi) > 2)
+               mp->color = NRAND(MI_NPIXELS(mi));
+       mp->time = 0;
+       mp->t = 0;
+       mp->nonblanks = 0;
+       mp->x = 0;
+
+       MI_CLEARWINDOW(mi);
+
+       if (mode_font == None)
+               mode_font = getFont(display);
+       if (mp->gc == NULL && mode_font != None) {
+               gcv.font = mode_font->fid;
+               XSetFont(display, MI_GC(mi), mode_font->fid);
+               gcv.graphics_exposures = False;
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               mp->gc = XCreateGC(display, MI_WINDOW(mi),
+                                  GCForeground | GCBackground | GCGraphicsExposures | GCFont, &gcv);
+               mp->ascent = mode_font->ascent;
+               mp->height = font_height(mode_font);
+               for (i = 0; i < 256; i++)
+                       if ((i >= (int) mode_font->min_char_or_byte2) &&
+                           (i <= (int) mode_font->max_char_or_byte2))
+                               char_width[i] = font_width(mode_font, (char) i);
+                       else
+                               char_width[i] = font_width(mode_font, (char) mode_font->default_char);
+       } else if (mode_font == None) {
+               for (i = 0; i < 256; i++)
+                       char_width[i] = 8;
+       }
+       mp->words = fixup_back(getWords(MI_SCREEN(mi), MI_NUM_SCREENS(mi)));
+       mp->y = 0;
+
+       if (isRibbon()) {
+               mp->x = mp->win_width;
+               if (mp->win_height > font_height(mode_font))
+                       mp->y += NRAND(mp->win_height - font_height(mode_font));
+               else if (mp->win_height < font_height(mode_font))
+                       mp->y -= NRAND(font_height(mode_font) - mp->win_height);
+       } else {
+               int         text_ht = text_height(mp->words);
+               int         text_font_wid = text_font_width(mp->words);
+
+               if (mp->win_height > text_ht * font_height(mode_font))
+                       mp->y = NRAND(mp->win_height - text_ht * font_height(mode_font));
+               if (mp->y < 0)
+                       mp->y = 0;
+               mp->x = 0;
+               if (mp->win_width > text_font_wid)
+                       mp->x += NRAND(mp->win_width - text_font_wid);
+               /* else if (mp->win_width < text_font_wid)
+                  mp->x -= NRAND(text_font_wid - mp->win_width); */
+               mp->startx = mp->x;
+       }
+}
+
+void
+draw_marquee(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       marqueestruct *mp = &marquees[MI_SCREEN(mi)];
+       char       *space = "        ";
+       char       *ch;
+
+       MI_IS_DRAWN(mi) = True;
+
+       ch = mp->words;
+       if (isRibbon()) {
+               ch = mp->words;
+               switch (*ch) {
+                       case '\0':
+                               if (add_blanks(mp)) {
+                                       init_marquee(mi);
+                                       return;
+                               }
+                               break;
+                       case '\b':
+                       case '\r':
+                       case '\n':
+                       case '\t':
+                       case '\v':
+                       case '\f':
+                               add_letter(mp, ' ');
+                               mp->words++;
+                               break;
+                       default:
+                               add_letter(mp, *ch);
+                               mp->words++;
+               }
+               if (MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, mp->gc, MI_PIXEL(mi, mp->color));
+                       if (++mp->color == MI_NPIXELS(mi))
+                               mp->color = 0;
+               } else
+                       XSetForeground(display, mp->gc, MI_WHITE_PIXEL(mi));
+               (void) XDrawImageString(display, MI_WINDOW(mi), mp->gc,
+                        mp->x, mp->y + mp->ascent, mp->modwords, mp->t + 2);
+       } else {
+               switch (*ch) {
+                       case '\0':
+                               if (++mp->time > 16)
+                                       init_marquee(mi);
+                               return;
+                       case '\b':
+                               if (mp->t) {
+                                       /* see note in text_font_width */
+                                       mp->t--;
+                                       mp->x -= char_width[' '];
+                               }
+                               break;
+                       case '\v':
+                       case '\f':
+                       case '\n':
+                               mp->x = mp->startx;
+                               mp->t = 0;
+                               mp->y += mp->height;
+                               if (mp->y + mp->height > mp->win_height) {
+                                       XCopyArea(display, window, window, mp->gc,
+                                                 0, mp->height, mp->win_width, mp->y - mp->height, 0, 0);
+                                       XSetForeground(display, mp->gc, MI_BLACK_PIXEL(mi));
+                                       mp->y -= mp->height;
+                                       XFillRectangle(display, window, mp->gc,
+                                       0, mp->y, mp->win_width, mp->height);
+                               }
+                               break;
+                       case '\t':
+                               (void) XDrawString(display, window, mp->gc, mp->x, mp->y + mp->ascent,
+                                                  space, 8 - (mp->t % 8));
+                               mp->x += char_width[' '] * (8 - (mp->t % 8));
+                               mp->t = ((mp->t + 8) / 8) * 8;
+                               break;
+                       case '\r':
+                               break;
+                       default:
+                               if (MI_NPIXELS(mi) > 2) {
+                                       XSetForeground(display, mp->gc, MI_PIXEL(mi, mp->color));
+                                       if (++mp->color == MI_NPIXELS(mi))
+                                               mp->color = 0;
+                               } else
+                                       XSetForeground(display, mp->gc, MI_WHITE_PIXEL(mi));
+                               if (is_char_back_char(ch)) {
+                                       int         xmid = mp->x + (char_back_char_width(ch) + 1) / 2;
+
+                                       (void) XDrawString(display, window, mp->gc,
+                                                          xmid - char_width[(int) (unsigned char) *ch] / 2,
+                                                 mp->y + mp->ascent, ch, 1);
+                                       (void) XDrawString(display, window, mp->gc,
+                                                          xmid - char_width[(int) (unsigned char) *(ch + 2)] / 2,
+                                             mp->y + mp->ascent, ch + 2, 1);
+                                       mp->x += char_back_char_width(ch);
+                                       mp->words += 2;
+                               } else {
+#ifdef USE_MB
+                                       int         mb = (*ch & 0x80) ? 2 : 1;
+
+                                       (void) XDrawString(display, window, mp->gc,
+                                         mp->x, mp->y + mp->ascent, ch, mb);
+                                       if (mb == 1)
+                                               mp->x += char_width[(int) (unsigned char) *ch];
+                                       else {
+                                               XRectangle  rect;
+
+                                               XmbTextExtents(fontset, ch, 2, NULL, &rect);
+                                               mp->x += rect.width;
+                                       }
+#else
+                                       (void) XDrawString(display, window, mp->gc,
+                                          mp->x, mp->y + mp->ascent, ch, 1);
+                                       mp->x += char_width[(int) (unsigned char) *ch];
+#endif
+                               }
+                               mp->t++;
+               }
+#ifdef USE_MB
+               mp->words += (*mp->words & 0x80) ? 2 : 1;
+#else
+               mp->words++;
+#endif
+       }
+}
+
+void
+release_marquee(ModeInfo * mi)
+{
+       if (marquees != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       marqueestruct *mp = &marquees[screen];
+
+                       if (mp->gc != NULL)
+                               XFreeGC(MI_DISPLAY(mi), mp->gc);
+               }
+               (void) free((void *) marquees);
+               marquees = NULL;
+       }
+       if (mode_font != None) {
+               XFreeFont(MI_DISPLAY(mi), mode_font);
+               mode_font = None;
+       }
+}
+
+#endif /* MODE_marquee */
diff --git a/xlockmore-4.14/modes/matrix.c b/xlockmore-4.14/modes/matrix.c
new file mode 100644 (file)
index 0000000..135cef9
--- /dev/null
@@ -0,0 +1,493 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* matrix --- screensaver inspired by the 1999 sci-fi flick "The Matrix" */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)matrix.c     1.0 99/04/20 xlockmore";
+#endif
+
+/* Matrix-style screensaver
+ *
+ * Author: Erik O'Shaughnessy (eriko@xenolab.com)  20 Apr 1999
+ * 
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ *
+ * 22-Apr-1999: Initial version
+ *
+ * 09-Jun-1999: Tweaks by Joan Touzet to look more like the original film's
+ *              effects
+ */
+
+#include <X11/Intrinsic.h>
+
+#define BRIGHTGREEN (27 * MI_NPIXELS(mi) / 64)
+#define GREEN (23 * MI_NPIXELS(mi) / 64)
+
+/* these characters stolen from a font named "7x14rk" */
+#define katakana_cell_width  7
+#define katakana_cell_height 10
+#define katakana_width       384
+#define katakana_height      10
+
+static unsigned char katakana_bits[] = {
+ 0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x1f,0xf8,0xdd,0xff,0xdf,0xfb,
+ 0xfd,0xbe,0xff,0x6f,0xf7,0xff,0x7d,0xef,0xfe,0xb9,0x0d,0xf7,0xef,0xff,0xff,
+ 0xfd,0xfd,0xef,0xff,0xf7,0xfb,0x7f,0x7e,0xff,0x0e,0xf7,0xff,0xff,0x70,0xf7,
+ 0xde,0xff,0xff,0xdf,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xfb,0xde,
+ 0x83,0xdf,0xfb,0xfd,0xb0,0x0f,0x6e,0xef,0xc1,0xfd,0xee,0x30,0x6e,0xfd,0xf7,
+ 0xef,0x61,0xf0,0xfd,0xbd,0xef,0x03,0xf7,0x7b,0xe0,0x79,0xff,0xde,0xf7,0xe1,
+ 0xe0,0x7f,0xb7,0xde,0x07,0x03,0xdf,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,
+ 0xff,0x3a,0x07,0xee,0xdf,0xfb,0xe1,0xb6,0xff,0x6e,0xef,0xdf,0xfd,0xee,0xf6,
+ 0x5e,0xfd,0xf7,0xef,0xff,0x37,0xf0,0x7d,0xef,0x7e,0xeb,0xc0,0xef,0x77,0xdf,
+ 0xde,0x07,0xef,0xef,0x7f,0xb7,0xde,0x77,0x7b,0x40,0xe0,0x77,0xff,0x7f,0xf7,
+ 0xff,0xff,0xed,0xff,0x4c,0xf7,0xee,0x81,0x40,0x7a,0x37,0xf8,0x06,0x7a,0xdf,
+ 0xc1,0xee,0xf6,0xde,0x05,0xe6,0x81,0xff,0xf7,0xfb,0xfd,0x6e,0x7f,0xeb,0xfb,
+ 0x6f,0x7e,0xbf,0xde,0x73,0xef,0x6f,0x60,0xb7,0xde,0x77,0x7b,0xdf,0xef,0x1b,
+ 0x08,0x06,0x06,0xe3,0x60,0x2b,0xf0,0x7e,0xf7,0xee,0xcf,0xdb,0xbb,0xb7,0xfe,
+ 0x6e,0x77,0xdf,0xdc,0x6f,0x15,0xf8,0xbd,0xd7,0xef,0xff,0xf6,0xfd,0xdd,0x8e,
+ 0x7f,0xdd,0xe9,0xf6,0x79,0x7f,0x06,0xae,0xef,0xef,0x6f,0xb7,0xde,0x75,0x7b,
+ 0xef,0xf3,0xdc,0xbb,0x3f,0xb3,0xef,0xef,0xea,0xff,0x7e,0x7f,0xef,0xcf,0xdb,
+ 0xe3,0xdb,0xfe,0x6e,0xb7,0xef,0xed,0xb7,0xfb,0xfe,0xbd,0xb7,0xef,0xff,0xf9,
+ 0xf8,0xde,0xed,0xbf,0xdf,0xd9,0xf5,0x7f,0xfe,0xde,0xcf,0xef,0xe0,0x6f,0xb7,
+ 0xda,0x75,0xbf,0xef,0x3b,0xdd,0xbb,0x5f,0xcf,0xef,0xe1,0xf6,0xff,0x7e,0x7f,
+ 0xef,0xd7,0x5b,0xf8,0xfb,0xfe,0x6e,0xbf,0xef,0xf5,0xf7,0xfb,0xfe,0xbe,0xb7,
+ 0xef,0xff,0x3b,0xf5,0xde,0xed,0xbf,0xdf,0xda,0xfb,0xbf,0x7d,0xdd,0xef,0xef,
+ 0xef,0xf7,0xbb,0xda,0x76,0xbf,0xf7,0xfb,0xfd,0xbd,0x6f,0xef,0xef,0xef,0xf7,
+ 0x7f,0x7f,0xbf,0xef,0xdb,0xdd,0xf7,0xfd,0xfe,0xbe,0xdf,0xd7,0xfd,0xfb,0xfd,
+ 0xfe,0xbe,0xf7,0xef,0xff,0xf5,0x7d,0xdf,0xed,0xdf,0xbf,0xda,0x3b,0xbe,0xbd,
+ 0xdd,0xdf,0xef,0xef,0xf7,0xbb,0xdc,0x76,0xdf,0xfb,0xfd,0xfd,0xbe,0x77,0xef,
+ 0xef,0xef,0xfb,0x7f,0x7f,0xdf,0xef,0xdd,0xdd,0xf7,0x7e,0x0f,0xbe,0xef,0xbb,
+ 0xfd,0xfd,0x7e,0x7f,0xdf,0xf7,0xf7,0xc0,0xee,0xbd,0xdf,0xed,0xef,0xbf,0xfb,
+ 0xf7,0x19,0xda,0xdf,0xdf,0xef,0xef,0xfb,0xdd,0x5c,0x07,0xef,0xfd,0xfe,0x3d,
+ 0x0f,0x3c,0xef,0x81,0xe0,0xfd,0xbf,0x7f,0xef,0x03,0xcf,0xe6,0x77,0xbf,0xff,
+ 0xdf,0xf3,0xbd,0xc3,0x7e,0xbf,0xbf,0xef,0xf7,0xfb,0x7f,0xef,0xdd,0xef,0x1d,
+ 0xf6,0xbf,0xfb,0xf7,0xf7,0xeb,0x3f,0xde,0x81,0xe0,0xfd,0xde,0x9e,0xff,0xf7
+ };
+
+#ifdef STANDALONE
+#define PROGCLASS "Matrix"
+#define HACK_INIT init_matrix
+#define HACK_DRAW draw_matrix
+#define matrix_opts xlockmore_opts
+#define DEFAULTS "*delay: 100\n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+ModeSpecOpt matrix_opts = {0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   matrix_description =
+{"matrix", "init_matrix","draw_matrix","release_matrix",
+ "refresh_matrix","change_matrix", NULL,&matrix_opts, 
+ 100, 1, 1, 1, 64, 1.0, "", 
+ "Shows the matrix", 0, NULL};
+#endif
+
+typedef struct {
+  int speed;                                   /* pixels downward per update */
+  int yoffset[2];                              /* current offset relative to root origin */
+  int width,height;
+  Pixmap pix[2];
+} column_t;
+
+typedef struct {
+  Pixel fg;                                            /* foreground */
+  Pixel bg;                                            /* background */
+  Pixel bold;                                  /* standout foreground color */
+  Pixmap kana[2];                              /* pixmap containing katakana 
+                                                                * [0] is fg on bg
+                                                                * [1] is bold on bg
+                                                                */
+  int width;                                   /* width of screen */
+  int height;                                  /* height of screen */
+  int num_cols;                                        /* number of columns of "matrix" data */
+  int col_width;
+  int col_height;                              
+  column_t *columns;
+} matrix_t;
+
+Pixel get_color(ModeInfo *mi,char *colorname);
+void create_columns(ModeInfo *mi,matrix_t *mp);
+void new_column(ModeInfo *mi,matrix_t *mp,Pixmap pix);
+
+#define PICK_MATRIX(mi) &matrix[MI_SCREEN((mi))]
+#define MATRIX_RANDOM(min,max) ((LRAND()% ((max)-(min)))+(min))
+
+matrix_t *matrix;
+
+/* defining RANDOM_MATRIX causes each column pixmap to be regenerated
+ * after scrolling off the screen rather than just repeating
+ * infinitely.  this is a better effect, but uses more CPU and will
+ * cause update hesitations (especially on multi-headed machines or
+ * slower hardware).   Undefining RANDOM_MATRIX will cause the pixmaps
+ * to be generated only once and should save alot of horsepower for
+ * whatever else your machine might be doing.
+ */
+
+#define RANDOM_MATRIX
+
+
+/* NAME: init_matrix
+ *
+ * FUNCTION: allocate space for global matrix array, 
+ *           initialize colors,
+ *           initialize dimensions
+ *           allocate a pair of pixmaps containing character set 
+ *               (0 is green on black, 1 is bold on black)
+ *           create columns of "matrix" data
+ *
+ * RETURNS: void
+ */
+
+void init_matrix(ModeInfo * mi){
+       matrix_t *mp;
+
+       if( ! matrix ){
+               if((matrix = (matrix_t *) calloc(MI_NUM_SCREENS(mi),
+                       sizeof(matrix_t)))==(matrix_t *)NULL){
+                       perror("calloc");
+                       return;
+               }
+       }
+
+       MI_CLEARWINDOW(mi);    
+
+       mp = PICK_MATRIX(mi);
+
+       if (mp->columns == NULL)  {
+               if (MI_NPIXELS(mi) > 2) {
+                       mp->fg = MI_PIXEL(mi, GREEN);
+                       mp->bold =  MI_PIXEL(mi, BRIGHTGREEN);
+               } else {
+                       mp->fg = mp->bold = MI_WHITE_PIXEL(mi);
+               }
+               mp->bg = MI_BLACK_PIXEL(mi);
+               mp->width = MI_WIDTH(mi);
+               mp->height = MI_HEIGHT(mi);
+
+               mp->kana[0] = XCreatePixmapFromBitmapData(MI_DISPLAY(mi),
+                       MI_WINDOW(mi), (char *) katakana_bits,
+                       katakana_width, katakana_height,
+                       mp->bg, mp->fg, MI_DEPTH(mi));
+
+               mp->kana[1] = XCreatePixmapFromBitmapData(MI_DISPLAY(mi),
+                       MI_WINDOW(mi), (char *) katakana_bits,
+                       katakana_width, katakana_height,
+                       mp->bg, mp->bold, MI_DEPTH(mi));
+
+               /* don't want any exposure events from XCopyArea */
+               XSetGraphicsExposures(MI_DISPLAY(mi), MI_GC(mi), False);
+
+               create_columns(mi,mp);
+       }
+}
+
+
+/* NAME: draw_matrix
+ *
+ * FUNCTION: copy column pixmaps to the root window
+ *
+ * RETURNS: void
+ */
+
+void draw_matrix(ModeInfo *mi){
+  matrix_t *mp = PICK_MATRIX(mi);
+  int i,xoffset;
+
+  xoffset = (mp->width / mp->num_cols);
+  MI_IS_DRAWN(mi) = True;
+
+  /* for each column in the current matrix
+   *   move each pixmap down by increment it's offset by the column's speed
+   *   copy each pixmap to the root window
+   *   if a pixmap has scrolled off the bottom of the root window,
+   *      reset it's yoffset so that it's bottom edge is at the top edge of
+   *       the root window.
+   *      generate a new speed to spice things up
+   *   fi
+   * rof
+   */
+
+  for(i=0;i<mp->num_cols;i++){
+
+    mp->columns[i].yoffset[0] += mp->columns[i].speed;
+    mp->columns[i].yoffset[1] += mp->columns[i].speed;
+
+    XCopyArea(MI_DISPLAY(mi), mp->columns[i].pix[0],
+             MI_WINDOW(mi), MI_GC(mi),
+             0,0,
+             mp->col_width,mp->col_height,
+             (i+1)*xoffset,mp->columns[i].yoffset[0]);
+
+    XCopyArea(MI_DISPLAY(mi), mp->columns[i].pix[1],
+              MI_WINDOW(mi), MI_GC(mi),
+             0,0,
+             mp->col_width,mp->col_height,
+             (i+1)*xoffset,mp->columns[i].yoffset[1]);
+
+    if( mp->columns[i].yoffset[0] > mp->height ){
+      mp->columns[i].yoffset[0] = -(mp->height);
+      mp->columns[i].speed = MATRIX_RANDOM(5,20); 
+#ifdef RANDOM_DISPLAY
+         new_column(mi,mp,mp->columns[i].pix[0]);
+#endif
+    }
+
+    if( mp->columns[i].yoffset[1] > mp->height ){
+      mp->columns[i].yoffset[1] = -(mp->height);
+      mp->columns[i].speed = MATRIX_RANDOM(5,20); 
+#ifdef RANDOM_DISPLAY
+         new_column(mi,mp,mp->columns[i].pix[1]);
+#endif
+    }
+
+  }
+}
+
+/* NAME: release_matrix
+ *
+ * FUNCTION: frees all allocated resources
+ *
+ * RETURNS: void
+ */
+
+void release_matrix(ModeInfo * mi){
+  int i,j;
+
+  /* free allocated resources:
+   * 
+   * foreach submatrix in matrix
+   *   foreach column in submatrix
+   *      free pixmaps
+   *   free column
+   * free matrix
+   */
+
+  /*  check matrix for NULL in the event that it's called twice
+   */
+
+  if (matrix != (matrix_t *) NULL) {
+       for (i = 0; i< (sizeof(matrix) / sizeof(matrix_t)); i++) {
+         for (j = 0; j < matrix[i].num_cols; j++){
+               XFreePixmap(MI_DISPLAY(mi),matrix[i].columns[j].pix[0]);
+               XFreePixmap(MI_DISPLAY(mi),matrix[i].columns[j].pix[1]);
+         }
+         (void) free((void *) matrix[i].columns);
+         XFreePixmap(MI_DISPLAY(mi),matrix[i].kana[0]);
+         XFreePixmap(MI_DISPLAY(mi),matrix[i].kana[1]);
+       }
+         (void) free((void *) matrix->columns);
+       (void) free((void *) matrix);
+       matrix = (matrix_t *)NULL;
+  }
+}
+
+/* NAME: refresh_matrix
+ *
+ * FUNCTION: same as draw_matrix, clears screen to repair damage 
+ *
+ * RETURNS: void
+ */
+
+void refresh_matrix(ModeInfo * mi){
+
+  MI_CLEARWINDOW(mi);                  /* nuke anything that might have been drawn */
+  
+  draw_matrix(mi);
+}
+
+/* NAME: change_matrix
+ *
+ * FUNCTION: resets column offsets and generates new column pixmaps
+ *
+ * RETURNS: void
+ */
+
+void change_matrix(ModeInfo *mi){
+  matrix_t *mp = PICK_MATRIX(mi);
+  int i;
+
+  /* 
+   * 1. reset column pixmap offsets to inital conditions
+   * 2. generate new column speed
+   * 3. generate new pixmap contents
+   */
+
+  MI_CLEARWINDOW(mi);    
+  for(i=0;i<mp->num_cols;i++){
+       mp->columns[i].yoffset[0] = -(mp->height);
+       mp->columns[i].yoffset[1] = -(mp->height * 2);
+       mp->columns[i].speed = MATRIX_RANDOM(5,20); 
+       new_column(mi,mp,mp->columns[i].pix[0]);
+       new_column(mi,mp,mp->columns[i].pix[1]);
+  }
+}
+
+/* NAME: get_color
+ *
+ * FUNCTION: wrapper function for XAllocNamedColor
+ *
+ * RETURNS: pixel value for requested named color
+ */
+
+Pixel get_color(ModeInfo *mi,char *colorname){
+  XColor ret,exact;
+
+  if( ! colorname || ! mi )
+    return (Pixel )0;
+    
+  (void) XAllocNamedColor(MI_DISPLAY(mi),MI_COLORMAP(mi),colorname,&ret,&exact);
+
+  return ret.pixel;
+}
+
+/* NAME: create_columns
+ *
+ * FUNCTION: based on the width and height of the display
+ *           allocates and initializes column data structures
+ *
+ * RETURNS: void
+ */
+
+void create_columns(ModeInfo *mi,matrix_t *mp){
+  int i;
+
+  /* 
+   * using the width of the selected font, determine how many
+   * columns can fit across the current screen.  initalize the
+   * column width and height for later use too.
+   */
+  mp->num_cols = mp->width / (katakana_cell_width * 1.3);
+  mp->col_width = katakana_cell_width;
+  mp->col_height = mp->height;
+
+  /* 
+   * allocate columns
+   */
+  mp->columns = (column_t *) calloc(mp->num_cols,sizeof(column_t));
+
+  if( mp->columns == (column_t *)NULL ){
+    perror("create_columns:calloc");
+    return ;
+  }
+
+  /* 
+   * initialize column data structures. 
+   *
+   *  1. pick a random speed
+   *  2. set the yoffset's for each of the two pixmaps in a column
+   *     the yoffset is relative to the origin of the root window
+   *     and is gradually increased causing the pixmap to scroll
+   *     downward from the top of the root window.
+   *  3. create a pair of pixmaps.  a pair is used so that when the top
+   *     edge of the first scrolls past the top of the root window, the
+   *     second can begin scrolling down creating the effect of seamless
+   *     scrolling.
+   *  4. initalize the column pixmaps with a series of random strings and
+   *     inter-string gaps.
+   */
+
+  for(i=0;i<mp->num_cols;i++){
+    mp->columns[i].speed = MATRIX_RANDOM(5,20);
+
+    mp->columns[i].yoffset[0] = -(mp->col_height);
+    mp->columns[i].yoffset[1] = -(mp->col_height * 2);
+
+    mp->columns[i].pix[0] = XCreatePixmap(MI_DISPLAY(mi), MI_WINDOW(mi),
+         mp->col_width, mp->col_height, MI_DEPTH(mi));
+    mp->columns[i].pix[1] = XCreatePixmap(MI_DISPLAY(mi), MI_WINDOW(mi),
+         mp->col_width, mp->col_height, MI_DEPTH(mi));
+    new_column(mi,mp,mp->columns[i].pix[0]);
+    new_column(mi,mp,mp->columns[i].pix[1]);
+  }
+}
+
+
+/* NAME: new_column
+ *
+ * FUNCTION: clears and generates a pixmap of "matrix" data
+ *
+ * RETURNS: void
+ */
+
+void new_column(ModeInfo *mi,matrix_t *mp,Pixmap pix){
+  int yoffset,koffset,max;
+  int i,first,gap_len,str_len;
+  Pixmap src;
+
+  /* 
+   * clear the pixmap to get rid of previous data or initialize
+   */
+
+  XSetForeground(MI_DISPLAY(mi),MI_GC(mi),mp->bg);
+  XFillRectangle(MI_DISPLAY(mi), pix, MI_GC(mi),
+                                0,0, mp->col_width, mp->col_height);
+
+  /* yoffset is the max. height of a cell in the katakana data + fudge */
+  yoffset = katakana_cell_height + 2;
+
+  /* max is the number of characters that fit in a column */
+  max = mp->col_height / yoffset;
+
+  /* the first character in a string (read up to down) is drawn in a
+   * differnt color, the first flag helps choose the color.
+   */
+  first = 1;                                   
+
+  /* 
+   * each column is composed of a series of "strings" and inter-string
+   * gaps. 
+   */
+  str_len = MATRIX_RANDOM(6,40); /* initial string length */
+  gap_len = 0;
+
+  /* 
+   * write characters into the column pixmap, starting at the
+   * bottom and moving upwards. 
+   */
+
+  for(i = max;i>=0;i--){
+
+       src = (first)?mp->kana[1]:mp->kana[0];
+
+       if( gap_len ){                  /* either starting or in a gap */
+         gap_len--;
+         continue;
+       } else{                         /* either starting or in a string */
+         koffset = MATRIX_RANDOM(0,55);
+         str_len--;
+         first = 0;
+       }
+
+       XCopyArea(MI_DISPLAY(mi),src,pix,MI_GC(mi),
+                         koffset*katakana_cell_width,0,
+                         katakana_cell_width, katakana_cell_height,
+                         0,i*yoffset);
+
+       /* 
+        * if we have reached the end of the current string, so we generate
+        * a gap of random length.  the next string's length is also generated
+        * here, and the first flag set to indicate the beginning of a new
+        * string.
+        */
+
+       if( str_len == 0 ){
+         gap_len = MATRIX_RANDOM(1,10);
+         str_len = MATRIX_RANDOM(6,40);
+         first = 1;
+       }
+  }
+}
diff --git a/xlockmore-4.14/modes/maze.c b/xlockmore-4.14/modes/maze.c
new file mode 100644 (file)
index 0000000..118a81f
--- /dev/null
@@ -0,0 +1,895 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* maze --- a varying maze */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)maze.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1988 by Sun Microsystems
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 27-Oct-97: xpm and ras capability added.
+ * 10-May-97: Compatible with xscreensaver
+ * 27-Feb-96: Add ModeInfo args to init and callback hooks, use new
+ *             ModeInfo handle to specify long pauses (eliminate onepause).
+ *             Ron Hitchens <ron@idiom.com>
+ * 20-Jul-95: minimum size fix Peter Schmitzberger <schmitz@coma.sbg.ac.at>
+ * 17-Jun-95: removed sleep statements
+ * 22-Mar-95: multidisplay fix Caleb Epstein <epstein_caleb@jpmorgan.com>
+ * 9-Mar-95: changed how batchcount is used 
+ * 27-Feb-95: patch for VMS
+ * 4-Feb-95: patch to slow down maze Heath Kehoe <hakehoe@icaen.uiowa.edu>
+ * 17-Jun-94: HP ANSI C compiler needs a type cast for gray_bits
+ *            Richard Lloyd <R.K.Lloyd@csc.liv.ac.uk> 
+ * 2-Sep-93: xlock version David Bagley <bagleyd@tux.org>
+ * 7-Mar-93: Good ideas from xscreensaver Jamie Zawinski <jwz@jwz.org>
+ * 6-Jun-85: Martin Weiss Sun Microsystems 
+ */
+
+/*-
+ * original copyright
+ * **************************************************************************
+ * Copyright 1988 by Sun Microsystems, Inc. Mountain View, CA.
+ *
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the names of Sun or MIT not be used in advertising
+ * or publicity pertaining to distribution of the software without specific
+ * prior written permission. Sun and M.I.T. make no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
+ * without any express or implied warranty.
+ *
+ * SUN DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ * IN NO EVENT SHALL SUN BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
+ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
+ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
+ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+ * SOFTWARE.
+ * ***************************************************************************
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Maze"
+#define HACK_INIT init_maze
+#define HACK_DRAW draw_maze
+#define maze_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*cycles: 3000 \n" \
+ "*size: -40 \n" \
+ "*ncolors: 64 \n" \
+ "*bitmap: \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_maze
+
+ModeSpecOpt maze_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   maze_description =
+{"maze", "init_maze", "draw_maze", "release_maze",
+ "refresh_maze", "init_maze", NULL, &maze_opts,
+ 1000, 1, 3000, -40, 64, 1.0, "",
+ "Shows a random maze and a depth first search solution", 0, NULL};
+
+#endif
+
+#include "bitmaps/gray1.xbm"
+
+/* aliases for vars defined in the bitmap file */
+#define ICON_WIDTH   image_width
+#define ICON_HEIGHT    image_height
+#define ICON_BITS    image_bits
+
+#include "maze.xbm"
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+#define ICON_NAME  image_name
+#include "maze.xpm"
+#define DEFAULT_XPM 1
+#endif
+
+#define MINGRIDSIZE    3
+#define MINSIZE        8
+
+#define WALL_TOP       0x8000
+#define WALL_RIGHT     0x4000
+#define WALL_BOTTOM    0x2000
+#define WALL_LEFT      0x1000
+
+#define DOOR_IN_TOP    0x800
+#define DOOR_IN_RIGHT  0x400
+#define DOOR_IN_BOTTOM 0x200
+#define DOOR_IN_LEFT   0x100
+#define DOOR_IN_ANY    0xF00
+
+#define DOOR_OUT_TOP   0x80
+#define DOOR_OUT_RIGHT 0x40
+#define DOOR_OUT_BOTTOM        0x20
+#define DOOR_OUT_LEFT  0x10
+
+#define START_SQUARE   0x2
+#define END_SQUARE     0x1
+
+typedef struct {
+       unsigned char x;
+       unsigned char y;
+       char        dir;
+} paths;
+
+typedef struct {
+       int         ncols, nrows, maze_size, xb, yb;
+       int         sqnum, cur_sq_x, cur_sq_y, path_length;
+       int         start_x, start_y, start_dir, end_x, end_y, end_dir;
+       int         logo_x, logo_y;
+       int         width, height;
+       int         xs, ys, logo_size_x, logo_size_y;
+       int         solving, current_path, stage;
+       int         cycles;
+       unsigned short *maze;
+       paths      *move_list;
+       paths      *save_path, *path;
+       GC          grayGC;
+       Pixmap      graypix;
+       XImage     *logo;
+       Colormap    cmap;
+       unsigned long black, color;
+       int         graphics_format;
+       GC          backGC;
+       int         time;
+} mazestruct;
+
+static mazestruct *mazes = NULL;
+
+static void
+draw_wall(ModeInfo * mi, int i, int j, int dir)
+{                              /* draw a single wall */
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+       GC          gc = mp->backGC;
+
+       switch (dir) {
+               case 0:
+                       XDrawLine(display, window, gc,
+                                 mp->xb + mp->xs * i,
+                                 mp->yb + mp->ys * j,
+                                 mp->xb + mp->xs * (i + 1),
+                                 mp->yb + mp->ys * j);
+                       break;
+               case 1:
+                       XDrawLine(display, window, gc,
+                                 mp->xb + mp->xs * (i + 1),
+                                 mp->yb + mp->ys * j,
+                                 mp->xb + mp->xs * (i + 1),
+                                 mp->yb + mp->ys * (j + 1));
+                       break;
+               case 2:
+                       XDrawLine(display, window, gc,
+                                 mp->xb + mp->xs * i,
+                                 mp->yb + mp->ys * (j + 1),
+                                 mp->xb + mp->xs * (i + 1),
+                                 mp->yb + mp->ys * (j + 1));
+                       break;
+               case 3:
+                       XDrawLine(display, window, gc,
+                                 mp->xb + mp->xs * i,
+                                 mp->yb + mp->ys * j,
+                                 mp->xb + mp->xs * i,
+                                 mp->yb + mp->ys * (j + 1));
+                       break;
+       }
+}                              /* end of draw_wall */
+
+static void
+draw_solid_square(ModeInfo * mi, GC gc,
+                 register int i, register int j, register int dir)
+{                              /* draw a solid square in a square */
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+
+       switch (dir) {
+               case 0:
+                       XFillRectangle(display, window, gc,
+                                      mp->xb + 3 + mp->xs * i,
+                                      mp->yb - 3 + mp->ys * j,
+                                      mp->xs - 6, mp->ys);
+                       break;
+               case 1:
+                       XFillRectangle(display, window, gc,
+                                      mp->xb + 3 + mp->xs * i,
+                                      mp->yb + 3 + mp->ys * j,
+                                      mp->xs, mp->ys - 6);
+                       break;
+               case 2:
+                       XFillRectangle(display, window, gc,
+                                      mp->xb + 3 + mp->xs * i,
+                                      mp->yb + 3 + mp->ys * j,
+                                      mp->xs - 6, mp->ys);
+                       break;
+               case 3:
+                       XFillRectangle(display, window, gc,
+                                      mp->xb - 3 + mp->xs * i,
+                                      mp->yb + 3 + mp->ys * j,
+                                      mp->xs, mp->ys - 6);
+                       break;
+       }
+
+}                              /* end of draw_solid_square() */
+
+static void
+enter_square(ModeInfo * mi, int n)
+{                              /* move into a neighboring square */
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+
+       draw_solid_square(mi, mp->backGC, (int) mp->path[n].x, (int) mp->path[n].y,
+                         (int) mp->path[n].dir);
+
+       mp->path[n + 1].dir = -1;
+       switch (mp->path[n].dir) {
+               case 0:
+                       mp->path[n + 1].x = mp->path[n].x;
+                       mp->path[n + 1].y = mp->path[n].y - 1;
+                       break;
+               case 1:
+                       mp->path[n + 1].x = mp->path[n].x + 1;
+                       mp->path[n + 1].y = mp->path[n].y;
+                       break;
+               case 2:
+                       mp->path[n + 1].x = mp->path[n].x;
+                       mp->path[n + 1].y = mp->path[n].y + 1;
+                       break;
+               case 3:
+                       mp->path[n + 1].x = mp->path[n].x - 1;
+                       mp->path[n + 1].y = mp->path[n].y;
+                       break;
+       }
+
+}                              /* end of enter_square() */
+
+static void
+free_maze(mazestruct * mp)
+{
+       if (mp->maze) {
+               (void) free((void *) mp->maze);
+               mp->maze = NULL;
+       }
+       if (mp->move_list) {
+               (void) free((void *) mp->move_list);
+               mp->move_list = NULL;
+       }
+       if (mp->save_path) {
+               (void) free((void *) mp->save_path);
+               mp->save_path = NULL;
+       }
+       if (mp->path) {
+               (void) free((void *) mp->path);
+               mp->path = NULL;
+       }
+}
+
+static void
+set_maze_sizes(ModeInfo * mi)
+{
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+       int         size = MI_SIZE(mi);
+
+       if (size < -MINSIZE) {
+               free_maze(mp);
+               mp->ys = NRAND(MIN(-size, MAX(MINSIZE, (MIN(mp->width, mp->height) - 1) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+       } else if (size < MINSIZE) {
+               if (!size)
+                       mp->ys = MAX(MINSIZE, (MIN(mp->width, mp->height) - 1) / MINGRIDSIZE);
+               else
+                       mp->ys = MINSIZE;
+       } else
+               mp->ys = MIN(size, MAX(MINSIZE, (MIN(mp->width, mp->height) - 1) /
+                                      MINGRIDSIZE));
+       mp->xs = mp->ys;
+       mp->logo_size_x = mp->logo->width / mp->xs + 1;
+       mp->logo_size_y = mp->logo->height / mp->ys + 1;
+
+       mp->ncols = MAX((mp->width - 1) / mp->xs, MINGRIDSIZE);
+       mp->nrows = MAX((mp->height - 1) / mp->ys, MINGRIDSIZE);
+
+       mp->xb = (mp->width - mp->ncols * mp->xs) / 2;
+       mp->yb = (mp->height - mp->nrows * mp->ys) / 2;
+       mp->maze_size = mp->ncols * mp->nrows;
+       if (!mp->maze)
+               mp->maze = (unsigned short *)
+                       calloc(mp->maze_size, sizeof (unsigned short));
+
+       if (!mp->move_list)
+               mp->move_list = (paths *) calloc(mp->maze_size, sizeof (paths));
+       if (!mp->save_path)
+               mp->save_path = (paths *) calloc(mp->maze_size, sizeof (paths));
+       if (!mp->path)
+               mp->path = (paths *) calloc(mp->maze_size, sizeof (paths));
+}                              /* end of set_maze_sizes */
+
+
+static void
+initialize_maze(ModeInfo * mi)
+{                              /* draw the surrounding wall and start/end squares */
+       Display    *display = MI_DISPLAY(mi);
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+       register int i, j, wall;
+
+       if (MI_NPIXELS(mi) <= 2) {
+               mp->color = MI_WHITE_PIXEL(mi);
+       } else {
+               i = NRAND(MI_NPIXELS(mi));
+               mp->color = MI_PIXEL(mi, i);
+       }
+       XSetForeground(display, mp->backGC, mp->color);
+       XSetForeground(display, mp->grayGC, mp->color);
+       /* initialize all squares */
+       for (i = 0; i < mp->ncols; i++) {
+               for (j = 0; j < mp->nrows; j++) {
+                       mp->maze[i * mp->nrows + j] = 0;
+               }
+       }
+
+       /* top wall */
+       for (i = 0; i < mp->ncols; i++) {
+               mp->maze[i * mp->nrows] |= WALL_TOP;
+       }
+
+       /* right wall */
+       for (j = 0; j < mp->nrows; j++) {
+               mp->maze[(mp->ncols - 1) * mp->nrows + j] |= WALL_RIGHT;
+       }
+
+       /* bottom wall */
+       for (i = 0; i < mp->ncols; i++) {
+               mp->maze[i * mp->nrows + mp->nrows - 1] |= WALL_BOTTOM;
+       }
+
+       /* left wall */
+       for (j = 0; j < mp->nrows; j++) {
+               mp->maze[j] |= WALL_LEFT;
+       }
+
+       /* set start square */
+       wall = NRAND(4);
+       switch (wall) {
+               case 0:
+                       i = NRAND(mp->ncols);
+                       j = 0;
+                       break;
+               case 1:
+                       i = mp->ncols - 1;
+                       j = NRAND(mp->nrows);
+                       break;
+               case 2:
+                       i = NRAND(mp->ncols);
+                       j = mp->nrows - 1;
+                       break;
+               case 3:
+                       i = 0;
+                       j = NRAND(mp->nrows);
+                       break;
+       }
+       mp->maze[i * mp->nrows + j] |= START_SQUARE;
+       mp->maze[i * mp->nrows + j] |= (DOOR_IN_TOP >> wall);
+       mp->maze[i * mp->nrows + j] &= ~(WALL_TOP >> wall);
+       mp->cur_sq_x = i;
+       mp->cur_sq_y = j;
+       mp->start_x = i;
+       mp->start_y = j;
+       mp->start_dir = wall;
+       mp->sqnum = 0;
+
+       /* set end square */
+       wall = (wall + 2) % 4;
+       switch (wall) {
+               case 0:
+                       i = NRAND(mp->ncols);
+                       j = 0;
+                       break;
+               case 1:
+                       i = mp->ncols - 1;
+                       j = NRAND(mp->nrows);
+                       break;
+               case 2:
+                       i = NRAND(mp->ncols);
+                       j = mp->nrows - 1;
+                       break;
+               case 3:
+                       i = 0;
+                       j = NRAND(mp->nrows);
+                       break;
+       }
+       mp->maze[i * mp->nrows + j] |= END_SQUARE;
+       mp->maze[i * mp->nrows + j] |= (DOOR_OUT_TOP >> wall);
+       mp->maze[i * mp->nrows + j] &= ~(WALL_TOP >> wall);
+       mp->end_x = i;
+       mp->end_y = j;
+       mp->end_dir = wall;
+
+       /* set logo */
+       if ((mp->ncols > mp->logo_size_x + 6) &&
+           (mp->nrows > mp->logo_size_y + 6)) {
+               mp->logo_x = NRAND(mp->ncols - mp->logo_size_x - 6) + 3;
+               mp->logo_y = NRAND(mp->nrows - mp->logo_size_y - 6) + 3;
+
+               for (i = 0; i < mp->logo_size_x; i++)
+                       for (j = 0; j < mp->logo_size_y; j++)
+                               mp->maze[(mp->logo_x + i) * mp->nrows + mp->logo_y + j] |=
+                                       DOOR_IN_TOP;
+       } else
+               mp->logo_y = mp->logo_x = -1;
+}
+
+static int
+choose_door(ModeInfo * mi)
+{                              /* pick a new path */
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+       int         candidates[3];
+       register int num_candidates;
+
+       num_candidates = 0;
+
+       /* top wall */
+       if ((!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_IN_TOP)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_OUT_TOP)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              WALL_TOP))) {
+               if (mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y - 1] &
+                   DOOR_IN_ANY) {
+                       mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] |= WALL_TOP;
+                       mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y - 1] |=
+                               WALL_BOTTOM;
+               } else
+                       candidates[num_candidates++] = 0;
+       }
+       /* right wall */
+       if ((!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_IN_RIGHT)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_OUT_RIGHT)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              WALL_RIGHT))) {
+               if (mp->maze[(mp->cur_sq_x + 1) * mp->nrows + mp->cur_sq_y] &
+                   DOOR_IN_ANY) {
+                       mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] |= WALL_RIGHT;
+                       mp->maze[(mp->cur_sq_x + 1) * mp->nrows + mp->cur_sq_y] |=
+                               WALL_LEFT;
+               } else
+                       candidates[num_candidates++] = 1;
+       }
+       /* bottom wall */
+       if ((!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_IN_BOTTOM)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_OUT_BOTTOM)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              WALL_BOTTOM))) {
+               if (mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y + 1] &
+                   DOOR_IN_ANY) {
+                       mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] |= WALL_BOTTOM;
+                       mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y + 1] |= WALL_TOP;
+               } else
+                       candidates[num_candidates++] = 2;
+       }
+       /* left wall */
+       if ((!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_IN_LEFT)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              DOOR_OUT_LEFT)) &&
+           (!(mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] &
+              WALL_LEFT))) {
+               if (mp->maze[(mp->cur_sq_x - 1) * mp->nrows + mp->cur_sq_y] &
+                   DOOR_IN_ANY) {
+                       mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] |= WALL_LEFT;
+                       mp->maze[(mp->cur_sq_x - 1) * mp->nrows + mp->cur_sq_y] |=
+                               WALL_RIGHT;
+               } else
+                       candidates[num_candidates++] = 3;
+       }
+       /* done wall */
+       if (num_candidates == 0)
+               return (-1);
+       if (num_candidates == 1)
+               return (candidates[0]);
+       return (candidates[NRAND(num_candidates)]);
+
+}                              /* end of choose_door() */
+
+static void
+draw_maze_walls(ModeInfo * mi)
+{                              /* pick a new path */
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+       int         i, j, isize;
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < mp->ncols; i++) {
+               isize = i * mp->nrows;
+               for (j = 0; j < mp->nrows; j++) {
+                       /* Only need to draw half the walls... since they are shared */
+                       /* top wall */
+                       if (    /*(!(mp->maze[isize + j] & DOOR_IN_TOP)) &&
+                                  (!(mp->maze[isize + j] & DOOR_OUT_TOP)) && */
+                                  (mp->maze[isize + j] & WALL_TOP))
+                               draw_wall(mi, i, j, 0);
+                       /* left wall */
+                       if (    /*(!(mp->maze[isize + j] & DOOR_IN_RIGHT)) &&
+                                  (!(mp->maze[isize + j] & DOOR_OUT_RIGHT)) && */
+                                  (mp->maze[isize + j] & WALL_RIGHT))
+                               draw_wall(mi, i, j, 1);
+               }
+       }
+}                              /* end of draw_maze_walls() */
+
+static int
+backup(mazestruct * mp)
+{                              /* back up a move */
+       mp->sqnum--;
+       if (mp->sqnum >= 0) {
+               mp->cur_sq_x = mp->move_list[mp->sqnum].x;
+               mp->cur_sq_y = mp->move_list[mp->sqnum].y;
+       }
+       return (mp->sqnum);
+}                              /* end of backup() */
+
+static void
+create_maze_walls(ModeInfo * mi)
+{                              /* create a maze layout given the intiialized maze */
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+       register int i, newdoor;
+
+       for (;;) {
+               mp->move_list[mp->sqnum].x = mp->cur_sq_x;
+               mp->move_list[mp->sqnum].y = mp->cur_sq_y;
+               mp->move_list[mp->sqnum].dir = -1;
+               while ((newdoor = choose_door(mi)) == -1)       /* pick a door */
+                       if (backup(mp) == -1)   /* no more doors ... backup */
+                               return;         /* done ... return */
+
+               /* mark the out door */
+               mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] |=
+                       (DOOR_OUT_TOP >> newdoor);
+
+               switch (newdoor) {
+                       case 0:
+                               mp->cur_sq_y--;
+                               break;
+                       case 1:
+                               mp->cur_sq_x++;
+                               break;
+                       case 2:
+                               mp->cur_sq_y++;
+                               break;
+                       case 3:
+                               mp->cur_sq_x--;
+                               break;
+               }
+               mp->sqnum++;
+
+               /* mark the in door */
+               mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] |=
+                       (DOOR_IN_TOP >> ((newdoor + 2) % 4));
+
+               /* if end square set path length and save path */
+               if (mp->maze[mp->cur_sq_x * mp->nrows + mp->cur_sq_y] & END_SQUARE) {
+                       mp->path_length = mp->sqnum;
+                       for (i = 0; i < mp->path_length; i++) {
+                               mp->save_path[i].x = mp->move_list[i].x;
+                               mp->save_path[i].y = mp->move_list[i].y;
+                               mp->save_path[i].dir = mp->move_list[i].dir;
+                       }
+               }
+       }
+
+}                              /* end of create_maze_walls() */
+
+static void
+draw_maze_border(ModeInfo * mi)
+{                              /* draw the maze outline */
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+       GC          gc = mp->backGC;
+       register int i, j;
+
+       if (mp->logo_x != -1) {
+               (void) XPutImage(display, window, gc, mp->logo,
+                                0, 0,
+                                mp->xb + mp->xs * mp->logo_x +
+                       (mp->xs * mp->logo_size_x - mp->logo->width + 1) / 2,
+                                mp->yb + mp->ys * mp->logo_y +
+                      (mp->ys * mp->logo_size_y - mp->logo->height + 1) / 2,
+                                mp->logo->width, mp->logo->height);
+       }
+       for (i = 0; i < mp->ncols; i++) {
+               if (mp->maze[i * mp->nrows] & WALL_TOP) {
+                       XDrawLine(display, window, gc,
+                                 mp->xb + mp->xs * i, mp->yb,
+                                 mp->xb + mp->xs * (i + 1), mp->yb);
+               }
+               if ((mp->maze[i * mp->nrows + mp->nrows - 1] & WALL_BOTTOM)) {
+                       XDrawLine(display, window, gc,
+                                 mp->xb + mp->xs * i,
+                                 mp->yb + mp->ys * (mp->nrows),
+                                 mp->xb + mp->xs * (i + 1),
+                                 mp->yb + mp->ys * (mp->nrows));
+               }
+       }
+       for (j = 0; j < mp->nrows; j++) {
+               if (mp->maze[(mp->ncols - 1) * mp->nrows + j] & WALL_RIGHT) {
+                       XDrawLine(display, window, gc,
+                                 mp->xb + mp->xs * mp->ncols,
+                                 mp->yb + mp->ys * j,
+                                 mp->xb + mp->xs * mp->ncols,
+                                 mp->yb + mp->ys * (j + 1));
+               }
+               if (mp->maze[j] & WALL_LEFT) {
+                       XDrawLine(display, window, gc,
+                                 mp->xb, mp->yb + mp->ys * j,
+                                 mp->xb, mp->yb + mp->ys * (j + 1));
+               }
+       }
+
+       draw_solid_square(mi, gc, mp->start_x, mp->start_y, mp->start_dir);
+       draw_solid_square(mi, gc, mp->end_x, mp->end_y, mp->end_dir);
+}                              /* end of draw_maze() */
+
+static void
+solve_maze(ModeInfo * mi)
+{                              /* solve it with graphical feedback */
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+
+       if (!mp->solving) {
+               /* plug up the surrounding wall */
+               mp->maze[mp->start_x * mp->nrows + mp->start_y] |=
+                       (WALL_TOP >> mp->start_dir);
+               mp->maze[mp->end_x * mp->nrows + mp->end_y] |=
+                       (WALL_TOP >> mp->end_dir);
+
+               /* initialize search path */
+               mp->current_path = 0;
+               mp->path[mp->current_path].x = mp->end_x;
+               mp->path[mp->current_path].y = mp->end_y;
+               mp->path[mp->current_path].dir = -1;
+
+               mp->solving = 1;
+       }
+       if (++mp->path[mp->current_path].dir >= 4) {
+               /* This draw is to fill in the dead ends,
+                  it ends up drawing more gray boxes then it needs to. */
+               draw_solid_square(mi, mp->grayGC,
+                                 (int) (mp->path[mp->current_path].x),
+                                 (int) (mp->path[mp->current_path].y),
+                        (int) (mp->path[mp->current_path - 1].dir + 2) % 4);
+
+               mp->current_path--;
+               draw_solid_square(mi, mp->grayGC,
+                                 (int) (mp->path[mp->current_path].x),
+                                 (int) (mp->path[mp->current_path].y),
+                                 (int) (mp->path[mp->current_path].dir));
+       } else if (!(mp->maze[mp->path[mp->current_path].x * mp->nrows +
+                             mp->path[mp->current_path].y] &
+                    (WALL_TOP >> mp->path[mp->current_path].dir)) &&
+                  ((mp->current_path == 0) ||
+                   ((mp->path[mp->current_path].dir !=
+                     (unsigned char) (mp->path[mp->current_path - 1].dir +
+                                      2) % 4)))) {
+               enter_square(mi, mp->current_path);
+               mp->current_path++;
+               if (mp->maze[mp->path[mp->current_path].x * mp->nrows +
+                            mp->path[mp->current_path].y] & START_SQUARE) {
+                       mp->solving = 0;
+                       return;
+               }
+       }
+}                              /* end of solve_maze() */
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+
+       if (!mp->logo)
+               getImage(mi, &mp->logo, ICON_WIDTH, ICON_HEIGHT, ICON_BITS,
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                        DEFAULT_XPM, ICON_NAME,
+#endif
+                        &mp->graphics_format, &mp->cmap, &mp->black);
+#ifndef STANDALONE
+       if (mp->cmap != None) {
+               setColormap(display, window, mp->cmap, MI_IS_INWINDOW(mi));
+               if (mp->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = mp->black;
+                       mp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else
+#endif /* STANDALONE */
+       {
+               mp->black = MI_BLACK_PIXEL(mi);
+               mp->backGC = MI_GC(mi);
+       }
+}
+
+static void
+free_stuff(Display * display, mazestruct * mp)
+{
+       if (mp->cmap != None) {
+               XFreeColormap(display, mp->cmap);
+               if (mp->backGC != None) {
+                       XFreeGC(display, mp->backGC);
+                       mp->backGC = None;
+               }
+               mp->cmap = None;
+       } else
+               mp->backGC = None;
+       destroyImage(&mp->logo, &mp->graphics_format);
+}
+
+void
+init_maze(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       mazestruct *mp;
+
+       if (mazes == NULL) {
+               if ((mazes = (mazestruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (mazestruct))) == NULL)
+                       return;
+       }
+       mp = &mazes[MI_SCREEN(mi)];
+
+       init_stuff(mi);
+
+       mp->width = MI_WIDTH(mi);
+       mp->height = MI_HEIGHT(mi);
+       mp->width = (mp->width >= 32) ? mp->width : 32;
+       mp->height = (mp->height >= 32) ? mp->height : 32;
+
+       if (!mp->graypix) {
+               mp->graypix = XCreateBitmapFromData(display, MI_WINDOW(mi),
+                            (char *) gray1_bits, gray1_width, gray1_height);
+       }
+       if (!mp->grayGC) {
+               mp->grayGC = XCreateGC(display, MI_WINDOW(mi), 0L, (XGCValues *) 0);
+               XSetBackground(display, mp->grayGC, mp->black);
+               XSetFillStyle(display, mp->grayGC, FillOpaqueStippled);
+               XSetStipple(display, mp->grayGC, mp->graypix);
+       }
+       mp->solving = 0;
+       mp->stage = 0;
+       mp->time = 0;
+       mp->cycles = MI_CYCLES(mi);
+       if (mp->cycles < 4)
+               mp->cycles = 4;
+}
+
+void
+draw_maze(ModeInfo * mi)
+{
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+
+       if (mp->solving) {
+               solve_maze(mi);
+               return;
+       }
+       switch (mp->stage) {
+               case 0:
+                       MI_CLEARWINDOWCOLORMAP(mi, mp->backGC, mp->black);
+
+                       set_maze_sizes(mi);
+                       initialize_maze(mi);
+                       create_maze_walls(mi);
+                       mp->stage++;
+                       break;
+               case 1:
+                       draw_maze_border(mi);
+                       mp->stage++;
+                       break;
+               case 2:
+                       draw_maze_walls(mi);
+                       mp->stage++;
+                       break;
+               case 3:
+                       if (++mp->time > mp->cycles / 4)
+                               mp->stage++;
+                       break;
+               case 4:
+                       solve_maze(mi);
+                       mp->stage++;
+                       break;
+               case 5:
+                       if (++mp->time > 3 * mp->cycles / 4)
+                               init_maze(mi);
+                       break;
+       }
+}                              /*  end of draw_maze() */
+
+void
+release_maze(ModeInfo * mi)
+{
+       if (mazes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       mazestruct *mp = &mazes[screen];
+                       Display    *display = MI_DISPLAY(mi);
+
+                       free_maze(mp);
+                       if (mp->grayGC != NULL)
+                               XFreeGC(display, mp->grayGC);
+                       if (mp->graypix != None)
+                               XFreePixmap(display, mp->graypix);
+                       free_stuff(display, mp);
+               }
+               (void) free((void *) mazes);
+               mazes = NULL;
+       }
+}
+
+void
+refresh_maze(ModeInfo * mi)
+{
+       mazestruct *mp = &mazes[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOWCOLORMAP(mi, mp->backGC, mp->black);
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+       /* This is needed when another program changes the colormap. */
+       free_stuff(MI_DISPLAY(mi), mp);
+       init_stuff(mi);
+#endif
+       XSetForeground(MI_DISPLAY(mi), mp->backGC, mp->color);
+       if (mp->stage >= 1) {
+               mp->stage = 3;
+               mp->sqnum = 0;
+               mp->cur_sq_x = mp->start_x;
+               mp->cur_sq_y = mp->start_y;
+               mp->maze[mp->start_x * mp->nrows + mp->start_y] |= START_SQUARE;
+               mp->maze[mp->start_x * mp->nrows + mp->start_y] |=
+                       (DOOR_IN_TOP >> mp->start_dir);
+               mp->maze[mp->start_x * mp->nrows + mp->start_y] &=
+                       ~(WALL_TOP >> mp->start_dir);
+               mp->maze[mp->end_x * mp->nrows + mp->end_y] |= END_SQUARE;
+               mp->maze[mp->end_x * mp->nrows + mp->end_y] |=
+                       (DOOR_OUT_TOP >> mp->end_dir);
+               mp->maze[mp->end_x * mp->nrows + mp->end_y] &=
+                       ~(WALL_TOP >> mp->end_dir);
+               draw_maze_border(mi);
+               draw_maze_walls(mi);
+       }
+       mp->solving = 0;
+}
+
+#endif /* MODE_maze */
diff --git a/xlockmore-4.14/modes/mountain.c b/xlockmore-4.14/modes/mountain.c
new file mode 100644 (file)
index 0000000..42a66b2
--- /dev/null
@@ -0,0 +1,280 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* mountain -- square grid mountains */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)mountain.c   4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 Pascal Pensa <pensa@aurora.unice.fr>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Mountain"
+#define HACK_INIT init_mountain
+#define HACK_DRAW draw_mountain
+#define mountain_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: 30 \n" \
+ "*cycles: 4000 \n" \
+ "*ncolors: 64 \n" \
+ "*wireframe: False \n" \
+ "*fullrandom: False \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_mountain
+
+ModeSpecOpt mountain_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   mountain_description =
+{"mountain", "init_mountain", "draw_mountain", "release_mountain",
+ "refresh_mountain", "init_mountain", NULL, &mountain_opts,
+ 1000, 30, 4000, 1, 64, 1.0, "",
+ "Shows Papo's mountain range", 0, NULL};
+
+#endif
+
+/* ~ 5000 Max mountain height (1000 - 10000) */
+#define MAXHEIGHT  (3 * (mp->width + mp->height))
+
+#define WORLDWIDTH 50          /* World size x * y */
+
+#define RANGE_RAND(min,max) ((min) + NRAND((max) - (min)))
+
+typedef struct {
+       int         pixelmode;
+       int         width;
+       int         height;
+       int         x, y;
+       int         offset;
+       int         stage;
+       int         h[WORLDWIDTH][WORLDWIDTH];
+       long        time;       /* up time */
+       int         first;
+       Bool        wireframe;
+       Bool        joke;
+       GC          stippled_GC;
+} mountainstruct;
+
+static mountainstruct *mountains = NULL;
+
+static void
+spread(int  (*m)[50], int x, int y)
+{
+       int         x2, y2;
+       int         h = m[x][y];
+
+       for (y2 = y - 1; y2 <= y + 1; y2++)
+               for (x2 = x - 1; x2 <= x + 1; x2++)
+                       if (x2 >= 0 && y2 >= 0 && x2 < WORLDWIDTH && y2 < WORLDWIDTH)
+                               m[x2][y2] = (m[x2][y2] + h) / 2;
+}
+
+static void
+drawamountain(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       mountainstruct *mp = &mountains[MI_SCREEN(mi)];
+       int         x2, y2, x3, y3, y4, y5, c = 0;
+       XPoint      p[5];
+
+       if (MI_NPIXELS(mi) > 2) {
+               c = (mp->h[mp->x][mp->y] + mp->h[mp->x + 1][mp->y] +
+                 mp->h[mp->x][mp->y + 1] + mp->h[mp->x + 1][mp->y + 1]) / 4;
+               c = (c / 10 + mp->offset) % MI_NPIXELS(mi);
+       }
+       x2 = mp->x * (2 * mp->width) / (3 * WORLDWIDTH);
+       y2 = mp->y * (2 * mp->height) / (3 * WORLDWIDTH);
+       p[0].x = (x2 - y2 / 2) + (mp->width / 4);
+       p[0].y = (y2 - mp->h[mp->x][mp->y]) + mp->height / 4;
+
+       x3 = (mp->x + 1) * (2 * mp->width) / (3 * WORLDWIDTH);
+       y3 = mp->y * (2 * mp->height) / (3 * WORLDWIDTH);
+       p[1].x = (x3 - y3 / 2) + (mp->width / 4);
+       p[1].y = (y3 - mp->h[mp->x + 1][mp->y]) + mp->height / 4;
+
+       y4 = (mp->y + 1) * (2 * mp->height) / (3 * WORLDWIDTH);
+       p[2].x = (x3 - y4 / 2) + (mp->width / 4);
+       p[2].y = (y4 - mp->h[mp->x + 1][mp->y + 1]) + mp->height / 4;
+
+       y5 = (mp->y + 1) * (2 * mp->height) / (3 * WORLDWIDTH);
+       p[3].x = (x2 - y5 / 2) + (mp->width / 4);
+       p[3].y = (y5 - mp->h[mp->x][mp->y + 1]) + mp->height / 4;
+
+       p[4].x = p[0].x;
+       p[4].y = p[0].y;
+
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, c));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       if (mp->joke) {
+               if ((Bool) (LRAND() & 1))
+                       XDrawLines(display, window, gc, p, 5, CoordModeOrigin);
+               else {
+                       XFillPolygon(display, window, gc, p, 4, Complex, CoordModeOrigin);
+                       if (!mp->pixelmode) {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XDrawLines(display, window, gc, p, 5, CoordModeOrigin);
+                       }
+               }
+       } else {
+               if (mp->wireframe) {
+                       XDrawLines(display, window, gc, p, 5, CoordModeOrigin);
+               } else {
+                       XFillPolygon(display, window, gc, p, 4, Complex, CoordModeOrigin);
+
+                       if (!mp->pixelmode) {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XDrawLines(display, window, gc, p, 5, CoordModeOrigin);
+                       }
+               }
+       }
+       mp->x++;
+       if (mp->x == WORLDWIDTH - 1) {
+               mp->y++;
+               mp->x = 0;
+       }
+       if (mp->y == WORLDWIDTH - 1)
+               mp->stage++;
+}
+
+void
+init_mountain(ModeInfo * mi)
+{
+       mountainstruct *mp;
+       int         i, j, x, y;
+       XGCValues   gcv;
+
+       if (mountains == NULL) {
+               if ((mountains = (mountainstruct *) calloc(MI_NUM_SCREENS(mi),
+                                          sizeof (mountainstruct))) == NULL)
+                       return;
+       }
+       mp = &mountains[MI_SCREEN(mi)];
+       mp->width = MI_WIDTH(mi);
+       mp->height = MI_HEIGHT(mi);
+       mp->pixelmode = (mp->width + mp->height < 200);
+       mp->stage = 0;
+       mp->time = 0;
+       mp->x = mp->y = 0;
+       if (MI_IS_FULLRANDOM(mi)) {
+               mp->joke = (Bool) (NRAND(10) == 0);
+               mp->wireframe = (Bool) (LRAND() & 1);
+       } else {
+               mp->joke = False;
+               mp->wireframe = MI_IS_WIREFRAME(mi);
+       }
+
+       if (!mp->first) {
+               mp->first = 1;
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+
+               mp->stippled_GC = XCreateGC(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                         GCForeground | GCBackground, &gcv);
+       }
+       MI_CLEARWINDOW(mi);
+
+       for (y = 0; y < (int) WORLDWIDTH; y++)
+               for (x = 0; x < (int) WORLDWIDTH; x++)
+                       mp->h[x][y] = 0;
+
+       j = MI_COUNT(mi);
+       if (j < 0)
+               j = NRAND(-j) + 1;
+       for (i = 0; i < j; i++)
+               mp->h[RANGE_RAND(1, WORLDWIDTH - 1)][RANGE_RAND(1, WORLDWIDTH - 1)] =
+                       NRAND(MAXHEIGHT);
+
+       for (y = 0; y < WORLDWIDTH; y++)
+               for (x = 0; x < WORLDWIDTH; x++)
+                       spread(mp->h, x, y);
+
+       for (y = 0; y < WORLDWIDTH; y++)
+               for (x = 0; x < WORLDWIDTH; x++) {
+                       mp->h[x][y] = mp->h[x][y] + NRAND(10) - 5;
+                       if (mp->h[x][y] < 10)
+                               mp->h[x][y] = 0;
+               }
+
+       if (MI_NPIXELS(mi) > 2)
+               mp->offset = NRAND(MI_NPIXELS(mi));
+       else
+               mp->offset = 0;
+}
+
+void
+draw_mountain(ModeInfo * mi)
+{
+       mountainstruct *mp = &mountains[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       switch (mp->stage) {
+               case 0:
+                       drawamountain(mi);
+                       break;
+               case 1:
+                       if (++mp->time > MI_CYCLES(mi))
+                               mp->stage++;
+                       break;
+               case 2:
+                       init_mountain(mi);
+                       break;
+       }
+}
+
+void
+release_mountain(ModeInfo * mi)
+{
+       if (mountains != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       mountainstruct *mp = &mountains[screen];
+
+                       if (mp->stippled_GC)
+                               XFreeGC(MI_DISPLAY(mi), mp->stippled_GC);
+               }
+               (void) free((void *) mountains);
+               mountains = NULL;
+       }
+}
+
+void
+refresh_mountain(ModeInfo * mi)
+{
+       mountainstruct *mp = &mountains[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+       mp->x = 0;
+       mp->y = 0;
+}
+
+#endif /* MODE_mountain */
diff --git a/xlockmore-4.14/modes/munch.c b/xlockmore-4.14/modes/munch.c
new file mode 100644 (file)
index 0000000..8434917
--- /dev/null
@@ -0,0 +1,264 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* munch --- munching squares */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)munch.c 4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Tim Showalter <tjs@andrew.cmu.edu>
+ * 
+ * Copyright 1997, Tim Showalter
+ * Permission is granted to copy, modify, and use this as long
+ * as this notice remains intact.  No warranties are expressed or implied.
+ * CMU Sucks.
+ * 
+ * Some code stolen from / This is meant to work with
+ * xscreensaver, Copyright (c) 1992, 1995, 1996
+ * Jamie Zawinski <jwz@jwz.org>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ */
+
+/*-
+ * Munching Squares is this simplistic, silly screen hack (according to
+ * HAKMEM, discovered by Jackson Wright in 1962) where you take Y = X XOR T
+ * and graph it over and over.  According to HAKMEM, it  takes 5 instructions
+ * of PDP-1 assembly.  This is a little more complicated than that, mostly X's 
+ *  fault, but it does some other random things.
+ * http://www.inwap.com/pdp10/hbaker/hakmem/hacks.html#item146
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Munch"
+#define HACK_INIT init_munch
+#define HACK_DRAW draw_munch
+#define munch_opts xlockmore_opts
+#define DEFAULTS "*delay: 5000 \n" \
+ "*cycles: 7 \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_munch
+
+ModeSpecOpt munch_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   munch_description =
+{"munch", "init_munch", "draw_munch", "release_munch",
+ "init_munch", "init_munch", NULL, &munch_opts,
+ 5000, 1, 7, 1, 64, 1.0, "",
+ "Shows munching squares", 0, NULL};
+
+#endif
+
+#if DEBUG
+#include <assert.h>
+#endif
+
+/* flags for random things.  Must be < log2(random's maximum), incidentially. */
+#define SHIFT_KX (0x01)
+#define SHIFT_KT (0x02)
+#define SHIFT_KY (0x04)
+#define GRAV     (0x08)
+
+typedef struct {
+       int         width, height;
+       int         logminwidth;
+       int         logmaxwidth;
+       GC          gc;
+       int         thiswidth;
+       int         t;
+       int         atX, atY;
+       int         kX, kT, kY;
+       int         grav;
+} munchstruct;
+
+static munchstruct *munches = NULL;
+
+static void
+munchBit(ModeInfo * mi, int width,     /* pixels */
+        int atX, int atY,      /* pixels */
+        int kX, int kT, int kY,        /* pixels */
+        int grav /* 0 or not */ )
+{
+       munchstruct *mp = &munches[MI_SCREEN(mi)];
+
+       int         x, y;
+       int         drawX, drawY;
+
+#if 0
+       (void) fprintf(stderr, "Doing width %d at %d %d shift %d %d %d grav %d\n",
+                      width, atX, atY, kX, kT, kY, grav);
+#endif
+
+       for (x = 0; x < width; x++) {
+               /* figure out the next point */
+               y = ((x ^ ((mp->t + kT) % width)) + kY) % width;
+
+               drawX = ((x + kX) % width) + atX;
+               drawY = (grav ? y + atY : atY + width - 1 - y);
+
+               /* used to be bugs where it would draw partially offscreen.
+                  while that might be a pretty feature, I didn't want it to do
+                  that yet.  if these trigger, please let me know.
+                */
+#if DEBUG
+               assert(drawX >= 0 && drawX < MI_WIDTH(mi));
+               assert(drawY >= 0 && drawY < MI_HEIGHT(mi));
+#endif
+
+               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), mp->gc, drawX, drawY);
+               /* XXX may want to change this to XDrawPoints,
+                  but it's fast enough without it for the moment. */
+
+       }
+}
+
+/* 
+ * dumb way to get # of digits in number.  Probably faster than actually
+ * doing a log and a division, maybe.
+ */
+static int
+dumb_log_2(int k)
+{
+       int         r = -1;
+
+       while (k > 0) {
+               k >>= 1;
+               r++;
+       }
+       return r;
+}
+
+void
+init_munch(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       munchstruct *mp;
+
+       if (munches == NULL) {
+               if ((munches = (munchstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (munchstruct))) == NULL)
+                       return;
+       }
+       mp = &munches[MI_SCREEN(mi)];
+
+       if (!mp->gc) {
+               if ((mp->gc = XCreateGC(display, MI_WINDOW(mi),
+                            (unsigned long) 0, (XGCValues *) NULL)) == None)
+                       return;
+       }
+       mp->width = MI_WIDTH(mi);
+       mp->height = MI_HEIGHT(mi);
+
+       /* We need a square; limit on screen size? */
+       /* we want a power of 2 for the width or the munch doesn't fill up. */
+       mp->logmaxwidth = (int)
+               dumb_log_2((mp->height < mp->width) ? mp->height : mp->width);
+
+       XSetFunction(display, mp->gc, GXxor);
+
+       mp->logminwidth = MI_CYCLES(mi);
+       if (mp->logminwidth < 2 || MI_IS_ICONIC(mi))
+               mp->logminwidth = 2;
+
+       if (mp->logmaxwidth < mp->logminwidth)
+               mp->logmaxwidth = mp->logminwidth;
+
+       mp->t = 0;
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_munch(ModeInfo * mi)
+{
+       munchstruct *mp = &munches[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!mp->t) {           /* New one */
+               int         randflags = (int) LRAND();
+
+               /* choose size -- power of two */
+               mp->thiswidth = (int) (1 << (mp->logminwidth +
+                      (LRAND() % (1 + mp->logmaxwidth - mp->logminwidth))));
+
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(MI_DISPLAY(mi), mp->gc,
+                                      MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))));
+               else            /* Xor'red so WHITE may not be appropriate */
+                       XSetForeground(MI_DISPLAY(mi), mp->gc, 1);
+
+               mp->atX = (int) (LRAND() %
+                                ((mp->width <= mp->thiswidth) ? 1 : mp->width - mp->thiswidth));
+               mp->atY = (int) (LRAND() %
+                                ((mp->height <= mp->thiswidth) ? 1 : mp->height - mp->thiswidth));
+
+               /* wrap-around by these values; no need to %
+                  as we end up doing that later anyway */
+               mp->kX = (int) ((randflags & SHIFT_KX) ? LRAND() % mp->thiswidth : 0);
+               mp->kT = (int) ((randflags & SHIFT_KT) ? LRAND() % mp->thiswidth : 0);
+               mp->kY = (int) ((randflags & SHIFT_KY) ? LRAND() % mp->thiswidth : 0);
+
+               /* set the gravity of the munch, or rather,
+                  which direction we draw stuff in. */
+               mp->grav = randflags & GRAV;
+       }
+       /* Finally draw this munching square. */
+       munchBit(mi,
+                mp->thiswidth, /* Width, in pixels */
+       /* draw at this location */
+                mp->atX, mp->atY, mp->kX, mp->kT, mp->kY, mp->grav);
+
+       mp->t++;
+       if (mp->t == mp->thiswidth)
+               mp->t = 0;
+}
+
+void
+release_munch(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+
+       MI_CLEARWINDOW(mi);
+
+       if (munches != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       munchstruct *mp = &munches[screen];
+
+                       if (mp->gc != NULL)
+                               XFreeGC(display, mp->gc);
+               }
+
+               (void) free((void *) munches);
+               munches = NULL;
+       }
+}
+
+#endif /* MODE_munch */
diff --git a/xlockmore-4.14/modes/nose.c b/xlockmore-4.14/modes/nose.c
new file mode 100644 (file)
index 0000000..cd4241a
--- /dev/null
@@ -0,0 +1,782 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/*-
+ * nose --- a little guy with a big nose and a hat wanders around
+ *          spewing out messages
+ */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)nose.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 06-Jun-97: Compatible with xscreensaver and now colorized (idea from
+ *            xscreensaver but colors are random).
+ * 27-Feb-96: Added new ModeInfo arg to init and callback hooks.  Removed
+ *             references to onepause, now uses MI_PAUSE(mi) interface.
+ *             Ron Hitchens <ron@idiom.com>
+ * 10-Oct-95: A better way of handling fortunes from a file, thanks to
+ *            Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+ * 21-Sep-95: font option added, debugged for multiscreens
+ * 12-Aug-95: xlock version
+ * 1992: xscreensaver version, noseguy (Jamie Zawinski <jwz@jwz.org>)
+ * 1990: X11 version, xnlock (Dan Heller <argv@sun.com>)
+ */
+
+/*-
+ * xscreensaver, Copyright (c) 1992 Jamie Zawinski <jwz@mcom.com>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or
+ * implied warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Nose"
+#define HACK_INIT init_nose
+#define HACK_DRAW draw_nose
+#define nose_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*ncolors: 64 \n" \
+ "*font: \n" \
+ "*text: \n" \
+ "*filename: \n" \
+ "*fortunefile: \n" \
+ "*program: \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_nose
+
+ModeSpecOpt nose_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   nose_description =
+{"nose", "init_nose", "draw_nose", "release_nose",
+ "refresh_nose", "init_nose", NULL, &nose_opts,
+ 100000, 1, 1, 1, 64, 1.0, "",
+ "Shows a man with a big nose runs around spewing out messages", 0, NULL};
+
+#endif
+
+#include "bitmaps/nose-hat.xbm"
+#include "bitmaps/nose-hatd.xbm"
+#include "bitmaps/nose-facef.xbm"
+#include "bitmaps/nose-faced.xbm"
+#include "bitmaps/nose-facel.xbm"
+#include "bitmaps/nose-facer.xbm"
+#include "bitmaps/nose-shoef.xbm"
+#include "bitmaps/nose-shoel.xbm"
+#include "bitmaps/nose-shoer.xbm"
+#include "bitmaps/nose-stepl.xbm"
+#include "bitmaps/nose-stepr.xbm"
+
+#define font_height(f) ((f == None) ? 8 : f->ascent + f->descent)
+
+#define L 0
+#define R 1
+#define LSTEP 2
+#define RSTEP 3
+#define LF 4
+#define RF 5
+#define F 6
+#define D 7
+#define PIXMAPS 8
+#define PIXMAP_SIZE 64
+#define MOVE 0
+#define TALK 1
+#define FREEZE 2
+
+extern XFontStruct *getFont(Display * display);
+extern char *getWords(int screen, int screens);
+extern int  isRibbon(void);
+
+typedef struct {
+       int         x, y, width, height;
+} window_rect;
+
+typedef struct {
+       int         xs, ys;
+       int         width, height;
+       GC          text_fg_gc, text_bg_gc, noseGC[PIXMAPS];
+       char       *words;
+       int         x, y;
+       int         tinymode;   /* walking or getting passwd */
+       int         length, dir, lastdir;
+       int         up;
+       int         busyLoop;
+       int         frames;
+       int         state;
+       Bool        talking;
+       window_rect s;
+       Pixmap      position[PIXMAPS];
+} nosestruct;
+
+static nosestruct *noses = NULL;
+
+static XFontStruct *mode_font = None;
+
+#define LEFT 001
+#define RIGHT 002
+#define DOWN 004
+#define UP 010
+#define FRONT 020
+#define X_INCR 3
+#define Y_INCR 2
+#define YELLOW (MI_NPIXELS(mi) / 6)
+
+#define COPY(d,g,c,p,np,x,y,w,h) XSetForeground(d,g,c);\
+XSetStipple(d,g,p); XSetTSOrigin(d,g,x,y);\
+XFillRectangle(d,np,g,x,y,w,h)
+
+static void
+pickClothes(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       nosestruct *np = &noses[MI_SCREEN(mi)];
+       XGCValues   gcv;
+       Pixmap      face_pix, hat_pix, shoe_pix, shoel_pix, shoer_pix;
+       unsigned long hat_color = (MI_NPIXELS(mi) <= 2) ?
+       MI_WHITE_PIXEL(mi) : MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       unsigned long face_color = (MI_NPIXELS(mi) <= 2) ?
+       MI_WHITE_PIXEL(mi) : MI_PIXEL(mi, (YELLOW));    /* Racism? */
+       unsigned long shoe_color = (MI_NPIXELS(mi) <= 2) ?
+       MI_WHITE_PIXEL(mi) : MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       int         i;
+
+       gcv.graphics_exposures = False;
+       gcv.foreground = MI_BLACK_PIXEL(mi);
+       gcv.background = MI_BLACK_PIXEL(mi);
+       for (i = 0; i < PIXMAPS; i++) {
+               np->position[i] = XCreatePixmap(display, window, PIXMAP_SIZE, PIXMAP_SIZE,
+                                               MI_DEPTH(mi));
+               np->noseGC[i] = XCreateGC(display, np->position[i],
+                   GCForeground | GCBackground | GCGraphicsExposures, &gcv);
+               XFillRectangle(display, np->position[i], np->noseGC[i],
+                              0, 0, PIXMAP_SIZE, PIXMAP_SIZE);
+       }
+       XSetBackground(display, gc, MI_BLACK_PIXEL(mi));
+       XSetFillStyle(display, gc, FillStippled);
+       /* DOWN NOSE GUY */
+       hat_pix = XCreateBitmapFromData(display, window,
+                                       (char *) nose_hat_down_bits,
+                                 nose_hat_down_width, nose_hat_down_height);
+       face_pix = XCreateBitmapFromData(display, window,
+                                        (char *) nose_face_down_bits,
+                               nose_face_down_width, nose_face_down_height);
+       shoe_pix = XCreateBitmapFromData(display, window,
+                                        (char *) nose_shoe_front_bits,
+                             nose_shoe_front_width, nose_shoe_front_height);
+       COPY(display, gc, shoe_color, shoe_pix, np->position[D],
+            (PIXMAP_SIZE - nose_shoe_front_width) / 2,
+            nose_hat_height + nose_face_front_height + 3,
+            nose_shoe_front_width, nose_shoe_front_height);
+       COPY(display, gc, face_color, face_pix, np->position[D],
+         (PIXMAP_SIZE - nose_face_down_width) / 2, nose_hat_down_height + 7,
+            nose_face_down_width, nose_face_down_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[D],
+            (PIXMAP_SIZE - nose_hat_down_width) / 2, 7,
+            nose_hat_down_width, nose_hat_down_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[D], gc,
+                              0, nose_hat_down_height + 6, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       XFreePixmap(display, face_pix);
+       XFreePixmap(display, hat_pix);
+       /* FRONT NOSE GUY */
+       hat_pix = XCreateBitmapFromData(display, window,
+                                       (char *) nose_hat_bits,
+                                       nose_hat_width, nose_hat_height);
+       face_pix = XCreateBitmapFromData(display, window,
+                                        (char *) nose_face_front_bits,
+                             nose_face_front_width, nose_face_front_height);
+       COPY(display, gc, shoe_color, shoe_pix, np->position[F],
+            (PIXMAP_SIZE - nose_shoe_front_width) / 2,
+            nose_hat_height + nose_face_front_height + 3,
+            nose_shoe_front_width, nose_shoe_front_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[F],
+            (PIXMAP_SIZE - nose_hat_width) / 2, 4,
+            nose_hat_width, nose_hat_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[F], gc,
+                              0, nose_hat_height + 3, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       COPY(display, gc, face_color, face_pix, np->position[F],
+            (PIXMAP_SIZE - nose_face_front_width) / 2, nose_hat_height + 1,
+            nose_face_front_width, nose_face_front_height);
+       XFreePixmap(display, shoe_pix);
+       /* FRONT LEFT NOSE GUY */
+       shoel_pix = XCreateBitmapFromData(display, window,
+                                         (char *) nose_shoe_left_bits,
+                               nose_shoe_left_width, nose_shoe_left_height);
+       COPY(display, gc, shoe_color, shoel_pix, np->position[LF],
+            (PIXMAP_SIZE - nose_shoe_left_width) / 2 - 4,
+            nose_hat_height + nose_face_front_height + 3,
+            nose_shoe_left_width, nose_shoe_left_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[LF],
+            (PIXMAP_SIZE - nose_hat_width) / 2, 4,
+            nose_hat_width, nose_hat_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[LF], gc,
+                              0, nose_hat_height + 3, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       COPY(display, gc, face_color, face_pix, np->position[LF],
+            (PIXMAP_SIZE - nose_face_front_width) / 2, nose_hat_height + 1,
+            nose_face_front_width, nose_face_front_height);
+       /* FRONT RIGHT NOSE GUY */
+       shoer_pix = XCreateBitmapFromData(display, window,
+                                         (char *) nose_shoe_right_bits,
+                             nose_shoe_right_width, nose_shoe_right_height);
+       COPY(display, gc, shoe_color, shoer_pix, np->position[RF],
+            (PIXMAP_SIZE - nose_shoe_right_width) / 2 + 4,
+            nose_hat_height + nose_face_front_height + 3,
+            nose_shoe_right_width, nose_shoe_right_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[RF],
+            (PIXMAP_SIZE - nose_hat_width) / 2, 4,
+            nose_hat_width, nose_hat_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[RF], gc,
+                              0, nose_hat_height + 3, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       COPY(display, gc, face_color, face_pix, np->position[RF],
+            (PIXMAP_SIZE - nose_face_front_width) / 2, nose_hat_height + 1,
+            nose_face_front_width, nose_face_front_height);
+       XFreePixmap(display, face_pix);
+       /* LEFT NOSE GUY */
+       face_pix = XCreateBitmapFromData(display, window,
+                                        (char *) nose_face_left_bits,
+                               nose_face_left_width, nose_face_left_height);
+       COPY(display, gc, shoe_color, shoel_pix, np->position[L],
+            (PIXMAP_SIZE - nose_shoe_left_width) / 2 - 4,
+            nose_hat_height + nose_face_front_height + 3,
+            nose_shoe_left_width, nose_shoe_left_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[L],
+            (PIXMAP_SIZE - nose_hat_width) / 2, 4,
+            nose_hat_width, nose_hat_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[L], gc,
+                              0, nose_hat_height + 3, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       COPY(display, gc, face_color, face_pix, np->position[L],
+          (PIXMAP_SIZE - nose_face_left_width) / 2 - 4, nose_hat_height + 4,
+            nose_face_left_width, nose_face_left_height);
+       XFreePixmap(display, shoel_pix);
+       /* LEFT NOSE GUY STEPPING */
+       shoel_pix = XCreateBitmapFromData(display, window,
+                                         (char *) nose_step_left_bits,
+                               nose_step_left_width, nose_step_left_height);
+       COPY(display, gc, shoe_color, shoel_pix, np->position[LSTEP],
+            (PIXMAP_SIZE - nose_step_left_width) / 2,
+            nose_hat_height + nose_face_front_height - 1,
+            nose_step_left_width, nose_step_left_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[LSTEP],
+            (PIXMAP_SIZE - nose_hat_width) / 2, 4,
+            nose_hat_width, nose_hat_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[LSTEP], gc,
+                              0, nose_hat_height + 3, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       COPY(display, gc, face_color, face_pix, np->position[LSTEP],
+          (PIXMAP_SIZE - nose_face_left_width) / 2 - 4, nose_hat_height + 4,
+            nose_face_left_width, nose_face_left_height);
+       XFreePixmap(display, face_pix);
+       XFreePixmap(display, shoel_pix);
+       /* RIGHT NOSE GUY */
+       face_pix = XCreateBitmapFromData(display, window,
+                                        (char *) nose_face_right_bits,
+                             nose_face_right_width, nose_face_right_height);
+       COPY(display, gc, shoe_color, shoer_pix, np->position[R],
+            (PIXMAP_SIZE - nose_shoe_right_width) / 2 + 4,
+            nose_hat_height + nose_face_front_height + 3,
+            nose_shoe_right_width, nose_shoe_right_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[R],
+            (PIXMAP_SIZE - nose_hat_width) / 2, 4,
+            nose_hat_width, nose_hat_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[R], gc,
+                              0, nose_hat_height + 3, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       COPY(display, gc, face_color, face_pix, np->position[R],
+         (PIXMAP_SIZE - nose_face_right_width) / 2 + 4, nose_hat_height + 4,
+            nose_face_right_width, nose_face_right_height);
+       XFreePixmap(display, shoer_pix);
+       /* RIGHT NOSE GUY STEPPING */
+       shoer_pix = XCreateBitmapFromData(display, window,
+                                         (char *) nose_step_right_bits,
+                             nose_step_right_width, nose_step_right_height);
+       COPY(display, gc, shoe_color, shoer_pix, np->position[RSTEP],
+            (PIXMAP_SIZE - nose_step_right_width) / 2,
+            nose_hat_height + nose_face_front_height - 1,
+            nose_step_right_width, nose_step_right_height);
+       COPY(display, gc, hat_color, hat_pix, np->position[RSTEP],
+            (PIXMAP_SIZE - nose_hat_width) / 2, 4,
+            nose_hat_width, nose_hat_height);
+       if (MI_NPIXELS(mi) <= 2) {
+               XSetFillStyle(display, gc, FillSolid);
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, np->position[RSTEP], gc,
+                              0, nose_hat_height + 3, PIXMAP_SIZE, 1);
+               XSetFillStyle(display, gc, FillStippled);
+       }
+       COPY(display, gc, face_color, face_pix, np->position[RSTEP],
+         (PIXMAP_SIZE - nose_face_right_width) / 2 + 4, nose_hat_height + 4,
+            nose_face_right_width, nose_face_right_height);
+       XFreePixmap(display, face_pix);
+       XFreePixmap(display, shoer_pix);
+       XFreePixmap(display, hat_pix);
+       XSetFillStyle(display, gc, FillSolid);
+}
+
+static void
+walk(ModeInfo * mi, register int dir)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       nosestruct *np = &noses[MI_SCREEN(mi)];
+       register int incr = 0;
+
+       if (dir & (LEFT | RIGHT)) {     /* left/right movement (mabye up/down too) */
+               np->up = -np->up;       /* bouncing effect (even if hit a wall) */
+               if (dir & LEFT) {
+                       incr = X_INCR;
+                       np->frames = (np->up < 0) ? L : LSTEP;
+               } else {
+                       incr = -X_INCR;
+                       np->frames = (np->up < 0) ? R : RSTEP;
+               }
+               /* note that maybe neither UP nor DOWN is set! */
+               if (dir & UP && np->y > Y_INCR)
+                       np->y -= Y_INCR;
+               else if (dir & DOWN && np->y < np->height - np->ys)
+                       np->y += Y_INCR;
+       } else if (dir == UP) { /* Explicit up/down movement only (no left/right) */
+               np->y -= Y_INCR;
+               XCopyArea(display, np->position[F], window, np->noseGC[F],
+                         0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y);
+       } else if (dir == DOWN) {
+               np->y += Y_INCR;
+               XCopyArea(display, np->position[D], window, np->noseGC[D],
+                         0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y);
+       } else if (dir == FRONT && np->frames != F) {
+               if (np->up > 0)
+                       np->up = -np->up;
+               if (np->lastdir & LEFT)
+                       np->frames = LF;
+               else if (np->lastdir & RIGHT)
+                       np->frames = RF;
+               else
+                       np->frames = F;
+               XCopyArea(display, np->position[np->frames], window, np->noseGC[np->frames],
+                         0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y);
+       }
+       if (dir & LEFT)
+               while (--incr >= 0) {
+                       --np->x;
+                       XCopyArea(display, np->position[np->frames], window, np->noseGC[np->frames],
+                                 0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y + np->up);
+                       XFlush(display);
+       } else if (dir & RIGHT)
+               while (++incr <= 0) {
+                       ++np->x;
+                       XCopyArea(display, np->position[np->frames], window, np->noseGC[np->frames],
+                                 0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y + np->up);
+                       XFlush(display);
+               }
+       np->lastdir = dir;
+}
+
+static int
+think(ModeInfo * mi)
+{
+       nosestruct *np = &noses[MI_SCREEN(mi)];
+
+       if (LRAND() & 1)
+               walk(mi, FRONT);
+       if (LRAND() & 1) {
+               np->words = getWords(MI_SCREEN(mi), MI_NUM_SCREENS(mi));
+               return 1;
+       }
+       return 0;
+}
+
+#define MAXLINES 40
+#if 0
+#define MAXWIDTH BUFSIZ
+#else
+#define MAXWIDTH 170
+#endif
+
+/*-
+Strange but true:
+On an HP Pa-RISC with gcc MAXLINES * MAXWIDTH should be <=
+around 6800 (40 * 170) or
+
+as: /usr/tmp/cca####.s line#3364 [err#13]
+  (warning) Use of GR3 when frame>=8192 may cause conflict
+
+*/
+
+static void
+talk(ModeInfo * mi, Bool force_erase)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       nosestruct *np = &noses[MI_SCREEN(mi)];
+       int         width = 0, height, Y, Z, total = 0;
+       register char *p, *p2;
+       char        buf[BUFSIZ], args[MAXLINES][MAXWIDTH];
+
+       /* clear what we've written */
+       if (np->talking || force_erase) {
+               if (!np->talking)
+                       return;
+               XFillRectangle(display, window, np->text_bg_gc, np->s.x - 5, np->s.y - 5,
+                              np->s.width + 10, np->s.height + 10);
+               np->talking = False;
+               if (!force_erase)
+                       np->state = MOVE;
+               return;
+       }
+       np->talking = True;
+       walk(mi, FRONT);
+       p = strncpy(buf, np->words, BUFSIZ);
+       if (!(p2 = (char *) strchr(p, '\n')) || !p2[1]) {
+               (void) strncpy(args[0], np->words, MAXWIDTH - 1);
+               total = strlen(args[0]);
+               args[0][MAXWIDTH - 1] = '\0';
+               if (mode_font == None)
+                       width = 8;
+               else
+                       width = XTextWidth(mode_font, np->words, total);
+               height = 0;
+       } else
+               /* p2 now points to the first '\n' */
+               for (height = 0; p && height < MAXLINES; height++) {
+                       int         w;
+
+                       *p2 = 0;
+                       if (mode_font != None && (w = XTextWidth(mode_font, p, p2 - p)) > width)
+                               width = w;
+                       total += p2 - p;        /* total chars; count to determine reading time */
+                       (void) strncpy(args[height], p, MAXWIDTH - 1);
+                       args[height][MAXWIDTH - 1] = '\0';
+                       p = p2 + 1;
+                       if (!(p2 = (char *) strchr(p, '\n')))
+                               break;
+               }
+
+       height++;
+       /*
+        * Figure out the height and width in imagepixels (height, width) extend the
+        * new box by 15 pixels on the sides (30 total) top and bottom.
+        */
+       np->s.width = width + 30;
+       np->s.height = height * font_height(mode_font) + 30;
+       if (np->x - np->s.width - 10 < 5)
+               np->s.x = 5;
+       else if ((np->s.x = np->x + 32 - (np->s.width + 15) / 2)
+                + np->s.width + 15 > np->width - 5)
+               np->s.x = np->width - 15 - np->s.width;
+       if (np->y - np->s.height - 10 < 5)
+               np->s.y = np->y + np->ys + 5;
+       else
+               np->s.y = np->y - 5 - np->s.height;
+
+       XFillRectangle(display, window, np->text_bg_gc,
+                      np->s.x, np->s.y, np->s.width, np->s.height);
+
+       /* make a box that's 5 pixels thick. Then add a thin box inside it */
+       XSetLineAttributes(display, np->text_fg_gc, 5, 0, 0, 0);
+       XDrawRectangle(display, window, np->text_fg_gc,
+                      np->s.x, np->s.y, np->s.width - 1, np->s.height - 1);
+       XSetLineAttributes(display, np->text_fg_gc, 0, 0, 0, 0);
+       XDrawRectangle(display, window, np->text_fg_gc,
+             np->s.x + 7, np->s.y + 7, np->s.width - 15, np->s.height - 15);
+
+       Y = 15 + font_height(mode_font);
+
+       /* now print each string in reverse order (start at bottom of box) */
+       for (Z = 0; Z < height; Z++) {
+               (void) XDrawString(display, window, np->text_fg_gc,
+                       np->s.x + 15, np->s.y + Y, args[Z], strlen(args[Z]));
+               Y += font_height(mode_font);
+       }
+       np->busyLoop = (total / 15) * 10;
+       if (np->busyLoop < 30)
+               np->busyLoop = 30;
+       np->state = TALK;
+}
+
+static int
+look(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+
+       /*GC          gc = MI_GC(mi); */
+       nosestruct *np = &noses[MI_SCREEN(mi)];
+       int         i;
+
+       if (NRAND(3)) {
+               i = (LRAND() & 1) ? D : F;
+               XCopyArea(display, np->position[i], window, np->noseGC[i],
+                         0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y);
+               return 3;
+       }
+       if (!NRAND(5))
+               return 0;
+       if (NRAND(3)) {
+               i = (LRAND() & 1) ? LF : RF;
+               XCopyArea(display, np->position[i], window, np->noseGC[i],
+                         0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y);
+               return 3;
+       }
+       if (!NRAND(5))
+               return 0;
+       i = (LRAND() & 1) ? L : R;
+       XCopyArea(display, np->position[i], window, np->noseGC[i],
+                 0, 0, PIXMAP_SIZE, PIXMAP_SIZE, np->x, np->y);
+       return 3;
+}
+
+static void
+move(ModeInfo * mi)
+{
+       nosestruct *np = &noses[MI_SCREEN(mi)];
+
+       if (!np->length) {
+               register int tries = 0;
+
+               np->dir = 0;
+               if ((LRAND() & 1) && think(mi)) {
+                       talk(mi, False);        /* sets timeout to itself */
+                       return;
+               }
+               if (!NRAND(3) && (np->busyLoop = look(mi))) {
+                       np->state = MOVE;
+                       return;
+               }
+               np->busyLoop = 3 + NRAND(3);
+               do {
+                       if (!tries)
+                               np->length = np->width / 100 + NRAND(90), tries = 8;
+                       else
+                               tries--;
+                       switch (NRAND(8)) {
+                               case 0:
+                                       if (np->x - X_INCR * np->length >= 5)
+                                               np->dir = LEFT;
+                                       break;
+                               case 1:
+                                       if (np->x + X_INCR * np->length <= np->width - np->xs - 6)
+                                               np->dir = RIGHT;
+                                       break;
+                               case 2:
+                                       if (np->y - (Y_INCR * np->length) >= 5)
+                                               np->dir = UP;
+                                       break;
+                               case 3:
+                                       if (np->y + Y_INCR * np->length <= np->height - np->ys - 6)
+                                               np->dir = DOWN;
+                                       break;
+                               case 4:
+                                       if (np->x - X_INCR * np->length >= 5 &&
+                                         np->y - (Y_INCR * np->length) >= 5)
+                                               np->dir = (LEFT | UP);
+                                       break;
+                               case 5:
+                                       if (np->x + X_INCR * np->length <= np->width - np->xs - 6 &&
+                                           np->y - Y_INCR * np->length >= 5)
+                                               np->dir = (RIGHT | UP);
+                                       break;
+                               case 6:
+                                       if (np->x - X_INCR * np->length >= 5 &&
+                                           np->y + Y_INCR * np->length <= np->height - np->ys - 6)
+                                               np->dir = (LEFT | DOWN);
+                                       break;
+                               case 7:
+                                       if (np->x + X_INCR * np->length <= np->width - np->xs - 6 &&
+                                           np->y + Y_INCR * np->length <= np->height - np->ys - 6)
+                                               np->dir = (RIGHT | DOWN);
+                                       break;
+                               default:
+                                       /* No Defaults */
+                                       break;
+                       }
+               } while (!np->dir);
+       }
+       walk(mi, np->dir);
+       --np->length;
+       np->state = MOVE;
+}
+
+void
+init_nose(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       nosestruct *np;
+       XGCValues   gcv;
+       int         i = 0;
+
+       if (noses == NULL) {
+               if ((noses = (nosestruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (nosestruct))) == NULL)
+                       return;
+       }
+       np = &noses[MI_SCREEN(mi)];
+
+       np->width = MI_WIDTH(mi) + 2;
+       np->height = MI_HEIGHT(mi) + 2;
+       np->tinymode = (np->width + np->height < 4 * PIXMAP_SIZE);
+       np->xs = PIXMAP_SIZE;
+       np->ys = PIXMAP_SIZE;
+
+       MI_CLEARWINDOW(mi);
+
+       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       /* don't want any exposure events from XCopyPlane */
+       XSetGraphicsExposures(display, gc, False);
+
+       if (mode_font == None)
+               mode_font = getFont(display);
+       if (np->noseGC[0] == NULL)
+               pickClothes(mi);
+       np->words = getWords(MI_SCREEN(mi), MI_NUM_SCREENS(mi));
+       if (np->text_fg_gc == NULL && mode_font != None) {
+               gcv.font = mode_font->fid;
+               XSetFont(display, gc, mode_font->fid);
+               gcv.graphics_exposures = False;
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               np->text_fg_gc = XCreateGC(display, window,
+                                          GCForeground | GCBackground | GCGraphicsExposures | GCFont, &gcv);
+               gcv.foreground = MI_BLACK_PIXEL(mi);
+               gcv.background = MI_WHITE_PIXEL(mi);
+               np->text_bg_gc = XCreateGC(display, window,
+                                          GCForeground | GCBackground | GCGraphicsExposures | GCFont, &gcv);
+       }
+       np->up = 1;
+       if (np->tinymode) {
+               np->x = 0;
+               np->y = 0;
+               i = (NRAND(PIXMAPS));
+               XCopyArea(display, np->position[i], window, np->noseGC[i],
+                         0, 0, PIXMAP_SIZE, PIXMAP_SIZE,
+                         (np->width - PIXMAP_SIZE) / 2,
+                         (np->height - PIXMAP_SIZE) / 2);
+               np->state = FREEZE;
+       } else {
+               np->x = np->width / 2;
+               np->y = np->height / 2;
+               np->state = MOVE;
+       }
+       XFlush(display);
+}
+
+void
+draw_nose(ModeInfo * mi)
+{
+       nosestruct *np = &noses[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (np->busyLoop > 0) {
+               np->busyLoop--;
+               return;
+       }
+       switch (np->state) {
+               case MOVE:
+                       move(mi);
+                       break;
+               case TALK:
+                       talk(mi, 0);
+                       break;
+       }
+}
+
+void
+release_nose(ModeInfo * mi)
+{
+       if (noses != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       Display    *display = MI_DISPLAY(mi);
+                       nosestruct *np = &noses[screen];
+                       int         i;
+
+                       if (np->text_fg_gc != NULL)
+                               XFreeGC(display, np->text_fg_gc);
+                       if (np->text_bg_gc != NULL)
+                               XFreeGC(display, np->text_bg_gc);
+                       for (i = 0; i < PIXMAPS; i++) {
+                               if (np->position[i])
+                                       XFreePixmap(display, np->position[i]);
+                               if (np->noseGC[i] != NULL)
+                                       XFreeGC(display, np->noseGC[i]);
+                       }
+               }
+               (void) free((void *) noses);
+               noses = NULL;
+       }
+       if (mode_font != None) {
+               XFreeFont(MI_DISPLAY(mi), mode_font);
+               mode_font = None;
+       }
+}
+
+void
+refresh_nose(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_nose */
diff --git a/xlockmore-4.14/modes/pacman.c b/xlockmore-4.14/modes/pacman.c
new file mode 100644 (file)
index 0000000..c8d5d69
--- /dev/null
@@ -0,0 +1,749 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* pacman --- Mr. Pacman and his ghost friends */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)pacman.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by Heath Rice <rice@asl.dl.nec.com>.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 04-Jun-97: Compatible with xscreensaver
+ *
+ */
+
+/*-
+ * [Pacman eats screen.  Ghosts put screen back.]
+ * Pacman eats ghosts when he encounters them.
+ * After all ghosts are eaten, pacman continues
+ * eating the screen until all of it is gone. Then
+ * it starts over.
+ * Food dots should be added.  Restart when done eating.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Pacman"
+#define HACK_INIT init_pacman
+#define HACK_DRAW draw_pacman
+#define pacman_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: 10 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 6 \n" \
+ "*bitmap: \n"
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_pacman
+
+ModeSpecOpt pacman_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   pacman_description =
+{"pacman", "init_pacman", "draw_pacman", "release_pacman",
+ "refresh_pacman", "init_pacman", NULL, &pacman_opts,
+ 100000, 10, 1, 0, 64, 1.0, "",
+ "Shows Pacman(tm)", 0, NULL};
+
+#endif
+
+/* aliases for vars defined in the bitmap file */
+#define CELL_WIDTH   image_width
+#define CELL_HEIGHT    image_height
+#define CELL_BITS    image_bits
+
+#include "ghost.xbm"
+
+#define MINGHOSTS 1
+#define MAXMOUTH 11
+#define MINGRIDSIZE 4
+#define MINSIZE 1
+#define NOWHERE 255
+
+#define NONE 0x0000
+#define LT   0x1000
+#define RT   0x0001
+#define RB   0x0010
+#define LB   0x0100
+#define ALL  0x1111
+
+#define YELLOW (MI_NPIXELS(mi) / 6)
+#define GREEN (23 * MI_NPIXELS(mi) / 64)
+#define BLUE (45 * MI_NPIXELS(mi) / 64)
+
+typedef struct {
+       int         col, row;
+       int         nextbox, lastbox, nextcol, nextrow;
+       int         dead;
+       int         mouthstage, mouthdirection;
+       /*int         color; */
+} beingstruct;
+
+typedef struct {
+       int         pixelmode;
+       int         width, height;
+       int         nrows, ncols;
+       int         xs, ys, xb, yb;
+       int         incx, incy;
+       GC          stippledGC;
+       Pixmap      ghostPixmap;
+       int         ghostWidth, ghostHeight;
+       int         graphics_format;
+       beingstruct pacman;
+       beingstruct *ghosts;
+       int         nghosts;
+#ifdef DEFUNCT
+       unsigned int *eaten;
+#endif
+       Pixmap      pacmanPixmap[4][MAXMOUTH];
+} pacmangamestruct;
+
+static pacmangamestruct *pacmangames = NULL;
+
+#if DEFUNCT
+static void
+clearcorners(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       Window      window = MI_WINDOW(mi);
+       pacmangamestruct *pp = &pacmangames[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, GREEN));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       if ((pp->pacman.nextrow == 0) && (pp->pacman.nextcol == 0)) {
+               XFillRectangle(display, window, gc, 0, 0,
+               ((pp->width / pp->ncols) / 2), ((pp->width / pp->ncols) / 2));
+               pp->eaten[(pp->pacman.nextcol * pp->nrows) + pp->pacman.nextrow] |=
+                       RT | LT | RB | LB;
+       } else if ((pp->pacman.nextrow == pp->nrows - 1) &&
+                  (pp->pacman.nextcol == 0)) {
+               XFillRectangle(display, window, gc,
+                    0, (pp->nrows * pp->ys) - ((pp->width / pp->ncols) / 2),
+               ((pp->width / pp->ncols) / 2), ((pp->width / pp->ncols) / 2));
+               pp->eaten[(pp->pacman.nextcol * pp->nrows) + pp->pacman.nextrow] |=
+                       RT | LT | RB | LB;
+       } else if ((pp->pacman.nextrow == 0) &&
+                  (pp->pacman.nextcol == pp->ncols - 1)) {
+               XFillRectangle(display, window, gc,
+                    (pp->ncols * pp->xs) - ((pp->width / pp->ncols) / 2), 0,
+               ((pp->width / pp->ncols) / 2), ((pp->width / pp->ncols) / 2));
+               pp->eaten[(pp->pacman.nextcol * pp->nrows) + pp->pacman.nextrow] |=
+                       RT | LT | RB | LB;
+       } else if ((pp->pacman.nextrow == pp->nrows - 1) &&
+                  (pp->pacman.nextcol == pp->ncols - 1)) {
+               XFillRectangle(display, window, gc,
+                       (pp->ncols * pp->xs) - ((pp->width / pp->ncols) / 2),
+                       (pp->nrows * pp->ys) - ((pp->width / pp->ncols) / 2),
+               ((pp->width / pp->ncols) / 2), ((pp->width / pp->ncols) / 2));
+               pp->eaten[(pp->pacman.nextcol * pp->nrows) + pp->pacman.nextrow] |=
+                       RT | LT | RB | LB;
+       }
+}
+#endif
+static void
+repopulate(ModeInfo * mi)
+{
+       pacmangamestruct *pp = &pacmangames[MI_SCREEN(mi)];
+       int         ghost;
+
+#if DEFUNCT
+       if (pp->eaten)
+               (void) free((void *) pp->eaten);
+       pp->eaten = (unsigned int *) calloc((pp->nrows * pp->ncols),
+                                           sizeof (unsigned int));
+
+#endif
+
+       MI_CLEARWINDOW(mi);
+
+       for (ghost = 0; ghost < pp->nghosts; ghost++) {
+               do {
+                       pp->ghosts[ghost].col = NRAND(pp->ncols);
+                       pp->ghosts[ghost].row = NRAND(pp->nrows);
+                       if ((pp->ghosts[ghost].row + pp->ghosts[ghost].col) % 2 !=
+                           (pp->pacman.row + pp->pacman.col) % 2) {
+                               if (pp->ghosts[ghost].col != 0)
+                                       pp->ghosts[ghost].col--;
+                               else
+                                       pp->ghosts[ghost].col++;
+                       }
+               }
+               while ((pp->ghosts[ghost].col == pp->pacman.col) &&
+                      (pp->ghosts[ghost].row == pp->pacman.row));
+               pp->ghosts[ghost].dead = 0;
+               pp->ghosts[ghost].lastbox = -1;
+
+       }
+}
+
+static void
+movepac(ModeInfo * mi)
+{
+       typedef struct {
+               int         cfactor, rfactor;
+               int         cf, rf;
+               int         oldcf, oldrf;
+       } being;
+       being      *g, p;
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       pacmangamestruct *pp = &pacmangames[MI_SCREEN(mi)];
+       int         ghost, alldead, dir;
+       XPoint      delta;
+
+       if (pp->pacman.nextcol > pp->pacman.col) {
+               p.cfactor = 1;
+#if DEFUNCT
+               if (pp->eaten) {
+                       pp->eaten[(pp->pacman.col * pp->nrows) + pp->pacman.row] |=
+                               RT | RB;
+                       pp->eaten[((pp->pacman.col + 1) * pp->nrows) + pp->pacman.row] |=
+                               LT | LB;
+               }
+#endif
+       } else if (pp->pacman.col > pp->pacman.nextcol) {
+               p.cfactor = -1;
+#if DEFUNCT
+               if (pp->eaten) {
+                       pp->eaten[(pp->pacman.col * pp->nrows) + pp->pacman.row] |=
+                               LT | LB;
+                       pp->eaten[((pp->pacman.col - 1) * pp->nrows) + pp->pacman.row] |=
+                               RT | RB;
+               }
+#endif
+       } else {
+               p.cfactor = 0;
+       }
+
+       if (pp->pacman.nextrow > pp->pacman.row) {
+               p.rfactor = 1;
+#if DEFUNCT
+               if (pp->eaten) {
+                       pp->eaten[(pp->pacman.col * pp->nrows) + pp->pacman.row] |=
+                               RB | LB;
+                       pp->eaten[(pp->pacman.col * pp->nrows) + (pp->pacman.row + 1)] |=
+                               RT | LT;
+               }
+#endif
+       } else if (pp->pacman.row > pp->pacman.nextrow) {
+               p.rfactor = -1;
+#if DEFUNCT
+               if (pp->eaten) {
+                       pp->eaten[(pp->pacman.col * pp->nrows) + pp->pacman.row] |=
+                               RT | LT;
+                       pp->eaten[(pp->pacman.col * pp->nrows) + (pp->pacman.row - 1)] |=
+                               RB | LB;
+               }
+#endif
+       } else {
+               p.rfactor = 0;
+       }
+
+       p.oldcf = pp->pacman.col * pp->xs + pp->xb;
+       p.oldrf = pp->pacman.row * pp->ys + pp->yb;
+       g = (being *) malloc(pp->nghosts * sizeof (being));
+
+       for (ghost = 0; ghost < pp->nghosts; ghost++) {
+               if (pp->ghosts[ghost].dead == 0) {
+#if DEFUNCT
+                       pp->eaten[(pp->ghosts[ghost].col * pp->nrows) +
+                                 pp->ghosts[ghost].row] = NONE;
+#endif
+                       if (pp->ghosts[ghost].nextcol > pp->ghosts[ghost].col) {
+                               g[ghost].cfactor = 1;
+                       } else if (pp->ghosts[ghost].col > pp->ghosts[ghost].nextcol) {
+                               g[ghost].cfactor = -1;
+                       } else {
+                               g[ghost].cfactor = 0;
+                       }
+                       if (pp->ghosts[ghost].nextrow > pp->ghosts[ghost].row) {
+                               g[ghost].rfactor = 1;
+                       } else if (pp->ghosts[ghost].row > pp->ghosts[ghost].nextrow) {
+                               g[ghost].rfactor = -1;
+                       } else {
+                               g[ghost].rfactor = 0;
+                       }
+
+                       g[ghost].oldcf = pp->ghosts[ghost].col * pp->xs +
+                               pp->xb;
+                       g[ghost].oldrf = pp->ghosts[ghost].row * pp->ys +
+                               pp->yb;
+               }
+       }
+       for (delta.x = pp->incx, delta.y = pp->incy;
+            (delta.x < pp->xs + pp->incx) || (delta.y < pp->ys + pp->incy);
+            delta.x += pp->incx, delta.y += pp->incy) {
+               if (delta.x > pp->xs)
+                       delta.x = pp->xs;
+               if (delta.y > pp->ys)
+                       delta.y = pp->ys;
+               p.cf = pp->pacman.col * pp->xs + delta.x * p.cfactor + pp->xb;
+               p.rf = pp->pacman.row * pp->ys + delta.y * p.rfactor + pp->yb;
+
+               dir = (ABS(p.cfactor) * (2 - p.cfactor) +
+                      ABS(p.rfactor) * (1 + p.rfactor)) % 4;
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+#ifdef FLASH
+               XFillRectangle(display, window, gc,
+                              p.oldcf, p.oldrf,
+                              pp->xs, pp->ys);
+#else
+               ERASE_IMAGE(display, window, gc, p.cf, p.rf,
+                           p.oldcf, p.oldrf, pp->xs, pp->ys);
+#endif
+               XSetTSOrigin(display, pp->stippledGC, p.cf, p.rf);
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, pp->stippledGC, MI_PIXEL(mi, YELLOW));
+               else
+                       XSetForeground(display, pp->stippledGC, MI_WHITE_PIXEL(mi));
+
+               XSetStipple(display, pp->stippledGC,
+                           pp->pacmanPixmap[dir][pp->pacman.mouthstage]);
+#ifdef FLASH
+               XSetFillStyle(display, pp->stippledGC, FillStippled);
+#else
+               XSetFillStyle(display, pp->stippledGC, FillOpaqueStippled);
+#endif
+               XFillRectangle(display, window, pp->stippledGC,
+                              p.cf, p.rf, pp->xs, pp->ys);
+               pp->pacman.mouthstage += pp->pacman.mouthdirection;
+               if ((pp->pacman.mouthstage >= MAXMOUTH) ||
+                   (pp->pacman.mouthstage < 0)) {
+                       pp->pacman.mouthdirection *= -1;
+                       pp->pacman.mouthstage += pp->pacman.mouthdirection * 2;
+               }
+               p.oldcf = p.cf;
+               p.oldrf = p.rf;
+
+               for (ghost = 0; ghost < pp->nghosts; ghost++) {
+                       if (!pp->ghosts[ghost].dead) {
+                               g[ghost].cf = pp->ghosts[ghost].col * pp->xs +
+                                       delta.x * g[ghost].cfactor + pp->xb;
+                               g[ghost].rf = pp->ghosts[ghost].row * pp->ys +
+                                       delta.y * g[ghost].rfactor + pp->yb;
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               if (pp->pixelmode) {
+                                       XFillRectangle(display, window, gc,
+                                             g[ghost].oldcf, g[ghost].oldrf,
+                                                      pp->xs, pp->ys);
+                                       if (MI_NPIXELS(mi) > 2)
+                                               XSetForeground(display, gc, MI_PIXEL(mi, BLUE));
+                                       else
+                                               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                                       XFillRectangle(display, window, gc,
+                                                      g[ghost].cf, g[ghost].rf, pp->xs, pp->ys);
+                                       XFlush(display);
+                               } else {
+#ifdef FLASH
+                                       XFillRectangle(display, window, gc,
+                                             g[ghost].oldcf, g[ghost].oldrf,
+                                                      pp->xs, pp->ys);
+#else
+                                       ERASE_IMAGE(display, window, gc, g[ghost].cf, g[ghost].rf,
+                                                   g[ghost].oldcf, g[ghost].oldrf, pp->xs, pp->ys);
+#endif
+                                       XSetTSOrigin(display, pp->stippledGC, g[ghost].cf, g[ghost].rf);
+                                       if (MI_NPIXELS(mi) > 2)
+                                               XSetForeground(display, pp->stippledGC, MI_PIXEL(mi, BLUE));
+                                       else
+                                               XSetForeground(display, pp->stippledGC, MI_WHITE_PIXEL(mi));
+                                       XSetStipple(display, pp->stippledGC, pp->ghostPixmap);
+#ifdef FLASH
+                                       XSetFillStyle(display, pp->stippledGC, FillStippled);
+#else
+                                       XSetFillStyle(display, pp->stippledGC, FillOpaqueStippled);
+#endif
+                                       XFillRectangle(display, window, pp->stippledGC,
+                                                      g[ghost].cf, g[ghost].rf, pp->xs, pp->ys);
+                                       XFlush(display);
+                               }
+                               g[ghost].oldcf = g[ghost].cf;
+                               g[ghost].oldrf = g[ghost].rf;
+                       }
+               }
+               XFlush(display);
+       }
+
+#if 0
+       clearcorners(mi);
+#endif
+       (void) free((void *) g);
+
+       alldead = 1;
+       for (ghost = 0; ghost < pp->nghosts; ghost++) {
+               if (pp->ghosts[ghost].dead == 0) {
+#if 0
+                       if ((pp->ghosts[ghost].nextrow >= pp->pacman.nextrow - 1) &&
+                           (pp->ghosts[ghost].nextrow <= pp->pacman.nextrow + 1) &&
+                           (pp->ghosts[ghost].nextcol >= pp->pacman.nextcol - 1) &&
+                           (pp->ghosts[ghost].nextcol <= pp->pacman.nextcol + 1)) {
+                               (void) printf("%d %d\n", pp->ghosts[ghost].nextrow,
+                                             pp->ghosts[ghost].nextcol);
+                       }
+#endif
+                       if (((pp->ghosts[ghost].nextrow == pp->pacman.nextrow) &&
+                       (pp->ghosts[ghost].nextcol == pp->pacman.nextcol)) ||
+                           ((pp->ghosts[ghost].nextrow == pp->pacman.row) &&
+                            (pp->ghosts[ghost].nextcol == pp->pacman.col) &&
+                            (pp->ghosts[ghost].row == pp->pacman.nextrow) &&
+                            (pp->ghosts[ghost].col == pp->pacman.nextcol))) {
+                               pp->ghosts[ghost].dead = 1;
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               /*XFillRectangle(display, window, gc,
+                                  pp->ghosts[ghost].col * pp->xs + pp->xb,
+                                  pp->ghosts[ghost].row * pp->ys + pp->yb,
+                                  pp->xs, pp->ys); */
+                               XFillRectangle(display, window, gc,
+                                pp->ghosts[ghost].nextcol * pp->xs + pp->xb,
+                                pp->ghosts[ghost].nextrow * pp->ys + pp->yb,
+                                              pp->xs, pp->ys);
+                       } else {
+                               pp->ghosts[ghost].row = pp->ghosts[ghost].nextrow;
+                               pp->ghosts[ghost].col = pp->ghosts[ghost].nextcol;
+                               alldead = 0;
+                       }
+               }
+       }
+       pp->pacman.row = pp->pacman.nextrow;
+       pp->pacman.col = pp->pacman.nextcol;
+
+#if DEFUNCT
+       if (alldead && pp->eaten) {
+               for (ghost = 0; ghost < (pp->nrows * pp->ncols); ghost++)
+                       if (pp->eaten[ghost] != ALL)
+                               break;
+               if (ghost == pp->nrows * pp->ncols)
+                       repopulate(mi);
+       }
+#else
+       if (alldead) {
+               repopulate(mi);
+       }
+#endif
+}
+
+void
+init_pacman(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         size = MI_SIZE(mi);
+       pacmangamestruct *pp;
+       XGCValues   gcv;
+       int         ghost, dir, mouth;
+       GC          fg_gc, bg_gc;
+
+       if (pacmangames == NULL) {
+               if ((pacmangames = (pacmangamestruct *) calloc(MI_NUM_SCREENS(mi),
+                                        sizeof (pacmangamestruct))) == NULL)
+                       return;
+       }
+       pp = &pacmangames[MI_SCREEN(mi)];
+       pp->width = MI_WIDTH(mi);
+       pp->height = MI_HEIGHT(mi);
+       if (pp->stippledGC == None) {
+               gcv.foreground = MI_BLACK_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               if ((pp->stippledGC = XCreateGC(display, window,
+                                GCForeground | GCBackground, &gcv)) == None)
+                       return;
+               pp->ghostWidth = CELL_WIDTH;
+               pp->ghostHeight = CELL_HEIGHT;
+               if (size == 0) {
+                       if (pp->ghostPixmap == None) {
+                               getPixmap(mi, window, CELL_WIDTH, CELL_HEIGHT, CELL_BITS,
+                                         &(pp->ghostWidth), &(pp->ghostHeight), &(pp->ghostPixmap),
+                                         &(pp->graphics_format));
+                               pp->xs = pp->ghostWidth;
+                               pp->ys = pp->ghostHeight;
+                       }
+               }
+       }
+       if (size == 0) {
+               if (MINGRIDSIZE * pp->ghostWidth > pp->width ||
+                   MINGRIDSIZE * pp->ghostHeight > pp->height) {
+                       pp->pixelmode = 1;
+                       pp->xs = pp->ys = MAX(MINSIZE, MIN(pp->width, pp->height) / MINGRIDSIZE);
+               } else {
+                       pp->pixelmode = 0;
+                       pp->xs = pp->ghostWidth;
+                       pp->ys = pp->ghostHeight;
+               }
+       } else {
+               pp->pixelmode = 1;
+               if (size < -MINSIZE)
+                       pp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(pp->width, pp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE)
+                       pp->ys = MINSIZE;
+               else
+                       pp->ys = MIN(size, MAX(MINSIZE, MIN(pp->width, pp->height) /
+                                              MINGRIDSIZE));
+               pp->xs = pp->ys;
+       }
+       pp->incx = pp->xs / 10 + 1;
+       pp->incy = pp->ys / 10 + 1;
+       pp->ncols = MAX(pp->width / pp->xs, 2);
+       pp->nrows = MAX(pp->height / pp->ys, 2);
+       pp->xb = pp->width - pp->ncols * pp->xs;
+       pp->yb = pp->height - pp->nrows * pp->ys;
+
+       if (pp->pacmanPixmap[0][0] != None)
+               for (dir = 0; dir < 4; dir++)
+                       for (mouth = 0; mouth < MAXMOUTH; mouth++)
+                               XFreePixmap(display, pp->pacmanPixmap[dir][mouth]);
+
+
+       for (dir = 0; dir < 4; dir++)
+               for (mouth = 0; mouth < MAXMOUTH; mouth++) {
+                       pp->pacmanPixmap[dir][mouth] = XCreatePixmap(display, MI_WINDOW(mi),
+                                                         pp->xs, pp->ys, 1);
+                       gcv.foreground = 1;
+                       fg_gc = XCreateGC(display, pp->pacmanPixmap[dir][mouth],
+                                         GCForeground, &gcv);
+                       gcv.foreground = 0;
+                       bg_gc = XCreateGC(display, pp->pacmanPixmap[dir][mouth],
+                                         GCForeground, &gcv);
+                       XFillRectangle(display, pp->pacmanPixmap[dir][mouth], bg_gc,
+                                      0, 0, pp->xs, pp->ys);
+                       if (pp->xs == 1 && pp->ys == 1)
+                               XFillRectangle(display, pp->pacmanPixmap[dir][mouth], fg_gc,
+                                              0, 0, pp->xs, pp->ys);
+                       else
+                               XFillArc(display, pp->pacmanPixmap[dir][mouth], fg_gc,
+                                        0, 0, pp->xs, pp->ys,
+                                        ((90 - dir * 90) + mouth * 5) * 64,
+                                        (360 + (-2 * mouth * 5)) * 64);
+                       XFreeGC(display, fg_gc);
+                       XFreeGC(display, bg_gc);
+               }
+       pp->pacman.lastbox = -1;
+       pp->pacman.mouthdirection = 1;
+
+       pp->nghosts = MI_COUNT(mi);
+       if (pp->nghosts < -MINGHOSTS) {
+               /* if pp->nghosts is random ... the size can change */
+               if (pp->ghosts != NULL) {
+                       (void) free((void *) pp->ghosts);
+                       pp->ghosts = NULL;
+               }
+               pp->nghosts = NRAND(-pp->nghosts - MINGHOSTS + 1) + MINGHOSTS;
+       } else if (pp->nghosts < MINGHOSTS)
+               pp->nghosts = MINGHOSTS;
+
+       if (!pp->ghosts)
+               pp->ghosts = (beingstruct *) calloc(pp->nghosts, sizeof (beingstruct));
+       for (ghost = 0; ghost < pp->nghosts; ghost++)
+               pp->ghosts[ghost].nextbox = NOWHERE;
+
+       pp->pacman.row = NRAND(pp->nrows);
+       pp->pacman.col = NRAND(pp->ncols);
+
+       MI_CLEARWINDOW(mi);
+
+       pp->pacman.mouthstage = MAXMOUTH - 1;
+       for (ghost = 0; ghost < pp->nghosts; ghost++) {
+               do {
+                       pp->ghosts[ghost].col = NRAND(pp->ncols);
+                       pp->ghosts[ghost].row = NRAND(pp->nrows);
+               }
+               while ((pp->ghosts[ghost].col == pp->pacman.col) &&
+                      (pp->ghosts[ghost].row == pp->pacman.row));
+               pp->ghosts[ghost].dead = 0;
+               pp->ghosts[ghost].lastbox = -1;
+
+       }
+#if DEFUNCT
+       if (pp->eaten)
+               (void) free((void *) pp->eaten);
+       pp->eaten = (unsigned int *) malloc((pp->nrows * pp->ncols) *
+                                           sizeof (unsigned int));
+
+       if (pp->eaten)
+               for (ghost = 0; ghost < (pp->nrows * pp->ncols); ghost++)
+                       pp->eaten[ghost] = NONE;
+#endif
+}
+
+void
+draw_pacman(ModeInfo * mi)
+{
+       pacmangamestruct *pp = &pacmangames[MI_SCREEN(mi)];
+       int         g;
+
+       MI_IS_DRAWN(mi) = True;
+
+       do {
+               if (NRAND(3) == 2)
+                       pp->pacman.nextbox = NRAND(5);
+
+               switch (pp->pacman.nextbox) {
+                       case 0:
+                               if ((pp->pacman.row == 0) || (pp->pacman.lastbox == 2))
+                                       pp->pacman.nextbox = NOWHERE;
+                               else {
+                                       pp->pacman.nextrow = pp->pacman.row - 1;
+                                       pp->pacman.nextcol = pp->pacman.col;
+                               }
+                               break;
+
+                       case 1:
+                               if ((pp->pacman.col == pp->ncols - 1) ||
+                                   (pp->pacman.lastbox == 3))
+                                       pp->pacman.nextbox = NOWHERE;
+                               else {
+                                       pp->pacman.nextrow = pp->pacman.row;
+                                       pp->pacman.nextcol = pp->pacman.col + 1;
+                               }
+                               break;
+
+                       case 2:
+                               if ((pp->pacman.row == pp->nrows - 1) ||
+                                   (pp->pacman.lastbox == 0))
+                                       pp->pacman.nextbox = NOWHERE;
+                               else {
+                                       pp->pacman.nextrow = pp->pacman.row + 1;
+                                       pp->pacman.nextcol = pp->pacman.col;
+                               }
+                               break;
+
+                       case 3:
+                               if ((pp->pacman.col == 0) || (pp->pacman.lastbox == 1))
+                                       pp->pacman.nextbox = NOWHERE;
+                               else {
+                                       pp->pacman.nextrow = pp->pacman.row;
+                                       pp->pacman.nextcol = pp->pacman.col - 1;
+                               }
+                               break;
+
+                       default:
+                               pp->pacman.nextbox = NOWHERE;
+                               break;
+               }
+       }
+       while (pp->pacman.nextbox == NOWHERE);
+
+
+       for (g = 0; g < pp->nghosts; g++) {
+               if (pp->ghosts[g].dead == 0) {
+                       do {
+                               if (NRAND(3) == 2)
+                                       pp->ghosts[g].nextbox = NRAND(5);
+
+                               switch (pp->ghosts[g].nextbox) {
+                                       case 0:
+                                               if ((pp->ghosts[g].row == 0) || (pp->ghosts[g].lastbox == 2))
+                                                       pp->ghosts[g].nextbox = NOWHERE;
+                                               else {
+                                                       pp->ghosts[g].nextrow = pp->ghosts[g].row - 1;
+                                                       pp->ghosts[g].nextcol = pp->ghosts[g].col;
+                                               }
+                                               break;
+
+                                       case 1:
+                                               if ((pp->ghosts[g].col == pp->ncols - 1) ||
+                                               (pp->ghosts[g].lastbox == 3))
+                                                       pp->ghosts[g].nextbox = NOWHERE;
+                                               else {
+                                                       pp->ghosts[g].nextrow = pp->ghosts[g].row;
+                                                       pp->ghosts[g].nextcol = pp->ghosts[g].col + 1;
+                                               }
+                                               break;
+
+                                       case 2:
+                                               if ((pp->ghosts[g].row == pp->nrows - 1) ||
+                                               (pp->ghosts[g].lastbox == 0))
+                                                       pp->ghosts[g].nextbox = NOWHERE;
+                                               else {
+                                                       pp->ghosts[g].nextrow = pp->ghosts[g].row + 1;
+                                                       pp->ghosts[g].nextcol = pp->ghosts[g].col;
+                                               }
+                                               break;
+
+                                       case 3:
+                                               if ((pp->ghosts[g].col == 0) || (pp->ghosts[g].lastbox == 1))
+                                                       pp->ghosts[g].nextbox = NOWHERE;
+                                               else {
+                                                       pp->ghosts[g].nextrow = pp->ghosts[g].row;
+                                                       pp->ghosts[g].nextcol = pp->ghosts[g].col - 1;
+                                               }
+                                               break;
+
+                                       default:
+                                               pp->ghosts[g].nextbox = NOWHERE;
+                                               break;
+                               }
+                       }
+                       while (pp->ghosts[g].nextbox == NOWHERE);
+                       pp->ghosts[g].lastbox = pp->ghosts[g].nextbox;
+               }
+       }
+       if (pp->pacman.lastbox != pp->pacman.nextbox)
+               pp->pacman.mouthstage = 0;
+       pp->pacman.lastbox = pp->pacman.nextbox;
+       movepac(mi);
+
+}
+
+void
+release_pacman(ModeInfo * mi)
+{
+       if (pacmangames != NULL) {
+               int         screen, dir, mouth;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       pacmangamestruct *pp = &pacmangames[screen];
+                       Display    *display = MI_DISPLAY(mi);
+
+                       if (pp->ghosts != NULL)
+                               (void) free((void *) pp->ghosts);
+#ifdef DEFUNCT
+                       if (pp->eaten != NULL)
+                               (void) free((void *) pp->eaten);
+#endif
+                       if (pp->stippledGC != None)
+                               XFreeGC(display, pp->stippledGC);
+                       if (pp->ghostPixmap != None)
+                               XFreePixmap(display, pp->ghostPixmap);
+                       if (pp->pacmanPixmap[0][0] != None)
+                               for (dir = 0; dir < 4; dir++)
+                                       for (mouth = 0; mouth < MAXMOUTH; mouth++)
+                                               XFreePixmap(display, pp->pacmanPixmap[dir][mouth]);
+               }
+               (void) free((void *) pacmangames);
+               pacmangames = NULL;
+       }
+}
+
+void
+refresh_pacman(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_pacman */
diff --git a/xlockmore-4.14/modes/penrose.c b/xlockmore-4.14/modes/penrose.c
new file mode 100644 (file)
index 0000000..4dfad29
--- /dev/null
@@ -0,0 +1,1302 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* penrose --- quasiperiodic tilings */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)penrose.c    4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by Timo Korvola <tkorvola@dopey.hut.fi>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Jamie Zawinski <jwz@jwz.org> compatible with xscreensaver
+ * 09-Sep-96: Written.
+ */
+
+/*-
+Be careful, this probably still has a few bugs (many of which may only
+appear with a very low probability).  These are seen with -verbose .
+If one of these are hit penrose will reinitialize.
+*/
+
+/*-
+ * See Onoda, Steinhardt, DiVincenzo and Socolar in
+ * Phys. Rev. Lett. 60, #25, 1988 or
+ * Strandburg in Computers in Physics, Sep/Oct 1991.
+ *
+ * This implementation uses the simpler version of the growth
+ * algorithm, i.e., if there are no forced vertices, a randomly chosen
+ * tile is added to a randomly chosen vertex (no preference for those
+ * 108 degree angles).
+ *
+ * There are two essential differences to the algorithm presented in
+ * the literature: First, we do not allow the tiling to enclose an
+ * untiled area.  Whenever this is in danger of happening, we just
+ * do not add the tile, hoping for a better random choice the next
+ * time.  Second, when choosing a vertex randomly, we will take
+ * one that lies withing the viewport if available.  If this seems to
+ * cause enclosures in the forced rule case, we will allow invisible
+ * vertices to be chosen.
+ *
+ * Tiling is restarted whenever one of the following happens: there
+ * are no incomplete vertices within the viewport or the tiling has
+ * extended a window's length beyond the edge of the window
+ * horizontally or vertically or forced rule choice has failed 100
+ * times due to areas about to become enclosed.
+ *
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Penrose"
+#define HACK_INIT init_penrose
+#define HACK_DRAW draw_penrose
+#define penrose_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*size: 40 \n" \
+ "*ncolors: 64 \n" \
+ "*fullrandom: True \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_penrose
+
+#define DEF_AMMANN  "False"
+
+static Bool ammann;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-ammann", ".penrose.ammann", XrmoptionNoArg, (caddr_t) "on"},
+       {"+ammann", ".penrose.ammann", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & ammann, "ammann", "Ammann", DEF_AMMANN, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+ammann", "turn on/off Ammann lines"}
+};
+
+ModeSpecOpt penrose_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   penrose_description =
+{"penrose", "init_penrose", "draw_penrose", "release_penrose",
+ "init_penrose", "init_penrose", NULL, &penrose_opts,
+ 10000, 1, 1, -40, 64, 1.0, "",
+ "Shows Penrose's quasiperiodic tilings", 0, NULL};
+
+#endif
+
+/*-
+ * Annoyingly the ANSI C library people have reserved all identifiers
+ * ending with _t for future use.  Hence we use _c as a suffix for
+ * typedefs (c for class, although this is not C++).
+ */
+
+#define MINSIZE 5
+
+/*-
+ * In theory one could fit 10 tiles to a single vertex.  However, the
+ * vertex rules only allow at most seven tiles to meet at a vertex.
+ */
+
+#define CELEBRATE 31415                /* This causes a pause, an error occurred. */
+#define COMPLETION 3141                /* This causes a pause, tiles filled up screen. */
+
+#define MAX_TILES_PER_VERTEX 7
+#define N_VERTEX_RULES 8
+#define ALLOC_NODE( type) ((type *)malloc( sizeof( type)))
+
+/*-
+ * These are used to specify directions.  They can also be used in bit
+ * masks to specify a combination of directions.
+ */
+#define S_LEFT 1
+#define S_RIGHT 2
+
+
+/*-
+ * We do not actually maintain objects corresponding to the tiles since
+ * we do not really need them and they would only consume memory and
+ * cause additional bookkeeping.  Instead we only have vertices, and
+ * each vertex lists the type of each adjacent tile as well as the
+ * position of the vertex on the tile (hereafter refered to as
+ * "corner").  These positions are numbered in counterclockwise order
+ * so that 0 is where two double arrows meet (see one of the
+ * articles).  The tile type and vertex number are stored in a single
+ * integer (we use char, and even most of it remains unused).
+ *
+ * The primary use of tile objects would be draw traversal, but we do
+ * not currently do redraws at all (we just start over).
+ */
+#define VT_CORNER_MASK 0x3
+#define VT_TYPE_MASK 0x4
+#define VT_THIN 0
+#define VT_THICK 0x4
+#define VT_BITS 3
+#define VT_TOTAL_MASK 0x7
+
+typedef unsigned char vertex_type_c;
+
+/*-
+ * These allow one to compute the types of the other corners of the tile.  If
+ * you are standing at a vertex of type vt looking towards the middle of the
+ * tile, VT_LEFT( vt) is the vertex on your left etc.
+ */
+#define VT_LEFT( vt) ((((vt) - 1) & VT_CORNER_MASK) | (((vt) & VT_TYPE_MASK)))
+#define VT_RIGHT( vt) ((((vt) + 1) & VT_CORNER_MASK) | (((vt) & VT_TYPE_MASK)))
+#define VT_FAR( vt) ((vt) ^ 2)
+
+
+/*-
+ * Since we do not do redraws, we only store the vertices we need.  These are
+ * the ones with still some empty space around them for the growth algorithm
+ * to fill.
+ *
+ * Here we use a doubly chained ring-like structure as vertices often need
+ * to be removed or inserted (they are kept in geometrical order 
+ * circling the tiled area counterclockwise).  The ring is refered to by
+ * a pointer to one more or less random node.  When deleting nodes one
+ * must make sure that this pointer continues to refer to a valid
+ * node.  A vertex count is maintained to make it easier to pick
+ * vertices randomly.
+ */
+typedef struct forced_node forced_node_c;
+
+typedef struct fringe_node {
+       struct fringe_node *prev;
+       struct fringe_node *next;
+       /* These are numbered counterclockwise.  The gap, if any, lies
+          between the last and first tiles.  */
+       vertex_type_c tiles[MAX_TILES_PER_VERTEX];
+       int         n_tiles;
+       /* A bit mask used to indicate vertex rules that are still applicable for
+          completing this vertex.  Initialize this to (1 << N_VERTEX_RULES) - 1,
+          i.e., all ones, and the rule matching functions will automatically mask
+          out rules that no longer match. */
+       unsigned char rule_mask;
+       /* If the vertex is on the forced vertex list, this points to the
+          pointer to the appropriate node in the list.  To remove the
+          vertex from the list just set *list_ptr to the next node,
+          deallocate and decrement node count. */
+       struct forced_node **list_ptr;
+       /* Screen coordinates. */
+       XPoint      loc;
+       /* We also keep track of 5D coordinates to avoid rounding errors.
+          These are in units of edge length. */
+       int         fived[5];
+       /* This is used to quickly check if a vertex is visible. */
+       unsigned char off_screen;
+} fringe_node_c;
+
+typedef struct {
+       fringe_node_c *nodes;
+       /* This does not count off-screen nodes. */
+       int         n_nodes;
+} fringe_c;
+
+
+/*-
+ * The forced vertex pool contains vertices where at least one
+ * side of the tiled region can only be extended in one way.  Note
+ * that this does not necessarily mean that there would only be one
+ * applicable rule.  forced_sides are specified using S_LEFT and
+ * S_RIGHT as if looking at the untiled region from the vertex.
+ */
+struct forced_node {
+       fringe_node_c *vertex;
+       unsigned    forced_sides;
+       struct forced_node *next;
+};
+
+typedef struct {
+       forced_node_c *first;
+       int         n_nodes, n_visible;
+} forced_pool_c;
+
+
+/* This is the data related to the tiling of one screen. */
+typedef struct {
+       int         width, height;
+       XPoint      origin;
+       int         edge_length;
+       fringe_c    fringe;
+       forced_pool_c forced;
+       int         done, failures;
+       unsigned long thick_color, thin_color;
+       int         busyLoop;
+       Bool        ammann;
+} tiling_c;
+
+static tiling_c *tilings;      /* = {0} */
+
+
+/* The tiles are listed in counterclockwise order. */
+typedef struct {
+       vertex_type_c tiles[MAX_TILES_PER_VERTEX];
+       int         n_tiles;
+} vertex_rule_c;
+
+static vertex_rule_c vertex_rules[N_VERTEX_RULES] =
+{
+       {
+  {VT_THICK | 2, VT_THICK | 2, VT_THICK | 2, VT_THICK | 2, VT_THICK | 2}, 5},
+       {
+  {VT_THICK | 0, VT_THICK | 0, VT_THICK | 0, VT_THICK | 0, VT_THICK | 0}, 5},
+       {
+               {VT_THICK | 0, VT_THICK | 0, VT_THICK | 0, VT_THIN | 0}, 4},
+       {
+        {VT_THICK | 2, VT_THICK | 2, VT_THIN | 1, VT_THIN | 3, VT_THICK | 2,
+         VT_THIN | 1, VT_THIN | 3}, 7},
+       {
+               {VT_THICK | 2, VT_THICK | 2, VT_THICK | 2, VT_THICK | 2,
+                VT_THIN | 1, VT_THIN | 3}, 6},
+       {
+               {VT_THICK | 1, VT_THICK | 3, VT_THIN | 2}, 3},
+       {
+               {VT_THICK | 0, VT_THIN | 0, VT_THIN | 0}, 3},
+       {
+     {VT_THICK | 2, VT_THIN | 1, VT_THICK | 3, VT_THICK | 1, VT_THIN | 3}, 5}
+};
+
+
+/* Match information returned by match_rules. */
+typedef struct {
+       int         rule;
+       int         pos;
+} rule_match_c;
+
+
+/* Occasionally floating point coordinates are needed. */
+typedef struct {
+       float       x, y;
+} fcoord_c;
+
+
+/* All angles are measured in multiples of 36 degrees. */
+typedef int angle_c;
+
+static angle_c vtype_angles[] =
+{4, 1, 4, 1, 2, 3, 2, 3};
+
+#define vtype_angle( v) (vtype_angles[ v])
+
+
+/* Direction angle of an edge. */
+static      angle_c
+vertex_dir(ModeInfo * mi, fringe_node_c * vertex, unsigned side)
+{
+       tiling_c   *tp = &tilings[MI_SCREEN(mi)];
+       fringe_node_c *v2 =
+       (side == S_LEFT ? vertex->next : vertex->prev);
+       register int i;
+
+       for (i = 0; i < 5; i++)
+               switch (v2->fived[i] - vertex->fived[i]) {
+                       case 1:
+                               return 2 * i;
+                       case -1:
+                               return (2 * i + 5) % 10;
+               }
+       tp->done = True;
+       if (MI_IS_VERBOSE(mi)) {
+               (void) fprintf(stderr,
+                      "Weirdness in vertex_dir (this has been reported)\n");
+               for (i = 0; i < 5; i++)
+                       (void) fprintf(stderr, "v2->fived[%d]=%d, vertex->fived[%d]=%d\n",
+                                      i, v2->fived[i], i, vertex->fived[i]);
+       }
+       tp->busyLoop = CELEBRATE;
+       return 0;
+}
+
+
+/* Move one step to a given direction. */
+static void
+add_unit_vec(angle_c dir, int *fived)
+{
+       static int  dir2i[] =
+       {0, 3, 1, 4, 2};
+
+       while (dir < 0)
+               dir += 10;
+       fived[dir2i[dir % 5]] += (dir % 2 ? -1 : 1);
+}
+
+
+/* For comparing coordinates. */
+#define fived_equal( f1, f2) (!memcmp( (f1), (f2), 5 * sizeof( int)))
+
+
+/*-
+ * This computes screen coordinates from 5D representation.  Note that X
+ * uses left-handed coordinates (y increases downwards).
+ */
+static void
+fived_to_loc(int fived[], tiling_c * tp, XPoint *pt)
+{
+       static fcoord_c fived_table[5] =
+       {
+               {.0, .0}};
+       float       fifth = 8 * atan(1.) / 5;
+       register int i;
+       register float r;
+       register fcoord_c offset;
+
+       *pt = tp->origin;
+       offset.x = 0.0;
+       offset.y = 0.0;
+       if (fived_table[0].x == .0)
+               for (i = 0; i < 5; i++) {
+                       fived_table[i].x = cos(fifth * i);
+                       fived_table[i].y = sin(fifth * i);
+               }
+       for (i = 0; i < 5; i++) {
+               r = fived[i] * tp->edge_length;
+               offset.x += r * fived_table[i].x;
+               offset.y -= r * fived_table[i].y;
+       }
+       (*pt).x += (int) (offset.x + .5);
+       (*pt).y += (int) (offset.y + .5);
+}
+
+
+/* Mop up dynamic data for one screen. */
+static void
+release_screen(tiling_c * tp)
+{
+       register fringe_node_c *fp1, *fp2;
+       register forced_node_c *lp1, *lp2;
+
+       if (tp->fringe.nodes == 0)
+               return;
+       fp1 = tp->fringe.nodes;
+       do {
+               fp2 = fp1;
+               fp1 = fp1->next;
+               (void) free((void *) fp2);
+       } while (fp1 != tp->fringe.nodes);
+       tp->fringe.nodes = 0;
+       for (lp1 = tp->forced.first; lp1 != 0;) {
+               lp2 = lp1;
+               lp1 = lp1->next;
+               (void) free((void *) lp2);
+       }
+       tp->forced.first = 0;
+}
+
+
+/* Called to init the mode. */
+void
+init_penrose(ModeInfo * mi)
+{
+       tiling_c   *tp;
+       fringe_node_c *fp;
+       int         i, size;
+
+       if (tilings == NULL) {
+               if ((tilings = (tiling_c *) calloc(MI_NUM_SCREENS(mi),
+                                                sizeof (tiling_c))) == NULL)
+                       return;
+       }
+       tp = &tilings[MI_SCREEN(mi)];
+
+       if (MI_IS_FULLRANDOM(mi))
+               tp->ammann = (Bool) (LRAND() & 1);
+       else
+               tp->ammann = ammann;
+       tp->done = False;
+       tp->busyLoop = 0;
+       tp->failures = 0;
+       tp->width = MI_WIDTH(mi);
+       tp->height = MI_HEIGHT(mi);
+       if (MI_NPIXELS(mi) > 2) {
+               tp->thick_color = NRAND(MI_NPIXELS(mi));
+               /* Insure good contrast */
+               tp->thin_color = (NRAND(2 * MI_NPIXELS(mi) / 3) + tp->thick_color +
+                                 MI_NPIXELS(mi) / 6) % MI_NPIXELS(mi);
+       }
+       size = MI_SIZE(mi);
+       if (size < -MINSIZE)
+               tp->edge_length = NRAND(MIN(-size, MAX(MINSIZE,
+                  MIN(tp->width, tp->height) / 2)) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE) {
+               if (!size)
+                       tp->edge_length = MAX(MINSIZE, MIN(tp->width, tp->height) / 2);
+               else
+                       tp->edge_length = MINSIZE;
+       } else
+               tp->edge_length = MIN(size, MAX(MINSIZE,
+                                           MIN(tp->width, tp->height) / 2));
+       tp->origin.x = (tp->width / 2 + NRAND(tp->width)) / 2;
+       tp->origin.y = (tp->height / 2 + NRAND(tp->height)) / 2;
+       tp->fringe.n_nodes = 2;
+       if (tp->fringe.nodes != 0)
+               release_screen(tp);
+       if (tp->fringe.nodes != 0 || tp->forced.first != 0) {
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in init_penrose()\n");
+                       (void) fprintf(stderr, "tp->fringe.nodes = 0 && tp->forced.first = 0\n");
+               }
+               release_screen(tp);     /* Try again */
+               tp->done = True;
+       }
+       tp->forced.n_nodes = tp->forced.n_visible = 0;
+       fp = tp->fringe.nodes = ALLOC_NODE(fringe_node_c);
+       if (fp == 0) {
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in init_penrose()\n");
+                       (void) fprintf(stderr, "fp = 0\n");
+               }
+               fp = tp->fringe.nodes = ALLOC_NODE(fringe_node_c);
+               tp->done = True;
+       }
+       /* First vertex. */
+       fp->rule_mask = (1 << N_VERTEX_RULES) - 1;
+       fp->list_ptr = 0;
+       fp->prev = fp->next = ALLOC_NODE(fringe_node_c);
+       if (fp->next == 0) {
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in init_penrose()\n");
+                       (void) fprintf(stderr, "fp->next = 0\n");
+               }
+               fp->prev = fp->next = ALLOC_NODE(fringe_node_c);
+               tp->done = True;
+       }
+       fp->n_tiles = 0;
+       fp->loc = tp->origin;
+       fp->off_screen = False;
+       for (i = 0; i < 5; i++)
+               fp->fived[i] = 0;
+
+       /* Second vertex. */
+       *(fp->next) = *fp;
+       fp->next->prev = fp->next->next = fp;
+       fp = fp->next;
+       i = NRAND(5);
+       fp->fived[i] = 2 * NRAND(2) - 1;
+       fived_to_loc(fp->fived, tp, &(fp->loc));
+       /* That's it!  We have created our first edge. */
+}
+
+/*-
+ * This attempts to match the configuration of vertex with the vertex
+ * rules.   The return value is a total match count.  If matches is
+ * non-null, it will be used to store information about the matches
+ * and must be large enough to contain it.  To play it absolutely
+ * safe, allocate room for MAX_TILES_PER_VERTEX * N_VERTEX_RULES
+ * entries when searching all matches.   The rule mask of vertex will
+ * be applied and rules masked out will not be searched.  Only strict
+ * subsequences match.  If first_only is true, the search stops when
+ * the first match is found.  Otherwise all matches will be found and
+ * the rule_mask of vertex will be updated, which also happens in
+ * single-match mode if no match is found.
+ */
+static int
+match_rules(fringe_node_c * vertex, rule_match_c * matches, int first_only)
+{
+       /* I will assume that I can fit all the relevant bits in vertex->tiles
+          into one unsigned long.  With 3 bits per element and at most 7
+          elements this means 21 bits, which should leave plenty of room.
+          After packing the bits the rest is just integer comparisons and
+          some bit shuffling.  This is essentially Rabin-Karp without
+          congruence arithmetic. */
+       register int i, j;
+       int         hits = 0, good_rules[N_VERTEX_RULES], n_good = 0;
+       unsigned long
+                   vertex_hash = 0, lower_bits_mask = ~(VT_TOTAL_MASK << VT_BITS * (vertex->n_tiles - 1));
+       unsigned    new_rule_mask = 0;
+
+       for (i = 0; i < N_VERTEX_RULES; i++)
+               if (vertex->n_tiles >= vertex_rules[i].n_tiles)
+                       vertex->rule_mask &= ~(1 << i);
+               else if (vertex->rule_mask & 1 << i)
+                       good_rules[n_good++] = i;
+       for (i = 0; i < vertex->n_tiles; i++)
+               vertex_hash |= (unsigned long) vertex->tiles[i] << (VT_BITS * i);
+
+       for (j = 0; j < n_good; j++) {
+               unsigned long rule_hash = 0;
+               vertex_rule_c *vr = vertex_rules + good_rules[j];
+
+               for (i = 0; i < vertex->n_tiles; i++)
+                       rule_hash |= (unsigned long) vr->tiles[i] << (VT_BITS * i);
+               if (rule_hash == vertex_hash) {
+                       if (matches != 0) {
+                               matches[hits].rule = good_rules[j];
+                               matches[hits].pos = 0;
+                       }
+                       hits++;
+                       if (first_only)
+                               return hits;
+                       else
+                               new_rule_mask |= 1 << good_rules[j];
+               }
+               for (i = vr->n_tiles - 1; i > 0; i--) {
+                       rule_hash = vr->tiles[i] | (rule_hash & lower_bits_mask) << VT_BITS;
+                       if (vertex_hash == rule_hash) {
+                               if (matches != 0) {
+                                       matches[hits].rule = good_rules[j];
+                                       matches[hits].pos = i;
+                               }
+                               hits++;
+                               if (first_only)
+                                       return hits;
+                               else
+                                       new_rule_mask |= 1 << good_rules[j];
+                       }
+               }
+       }
+       vertex->rule_mask = new_rule_mask;
+       return hits;
+}
+
+
+/*-
+ * find_completions finds the possible ways to add a tile to a vertex.
+ * The return values is the number of such possibilities.  You must
+ * first call match_rules to produce matches and n_matches.  sides
+ * specifies which side of the vertex to extend and can be S_LEFT or
+ * S_RIGHT.  If results is non-null, it should point to an array large
+ * enough to contain the results, which will be stored there.
+ * MAX_COMPL elements will always suffice.  If first_only is true we
+ * stop as soon as we find one possibility (NOT USED).
+ */
+#define MAX_COMPL 2
+
+static int
+find_completions(fringe_node_c * vertex, rule_match_c * matches, int n_matches,
+              unsigned side, vertex_type_c * results /*, int first_only */ )
+{
+       int         n_res = 0, cont;
+       register int i, j;
+       vertex_type_c buf[MAX_COMPL];
+
+       if (results == 0)
+               results = buf;
+       if (n_matches <= 0)
+               return 0;
+       for (i = 0; i < n_matches; i++) {
+               vertex_rule_c *rule = vertex_rules + matches[i].rule;
+               int         pos = (matches[i].pos
+                  + (side == S_RIGHT ? vertex->n_tiles : rule->n_tiles - 1))
+               % rule->n_tiles;
+               vertex_type_c vtype = rule->tiles[pos];
+
+               cont = 1;
+               for (j = 0; j < n_res; j++)
+                       if (vtype == results[j]) {
+                               cont = 0;
+                               break;
+                       }
+               if (cont)
+                       results[n_res++] = vtype;
+       }
+       return n_res;
+}
+
+
+/*-
+ * Draw a tile on the display.  Vertices must be given in a
+ * counterclockwise order.  vtype is the vertex type of v1 (and thus
+ * also gives the tile type).
+ */
+static void
+draw_tile(fringe_node_c * v1, fringe_node_c * v2,
+         fringe_node_c * v3, fringe_node_c * v4,
+         vertex_type_c vtype, ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       tiling_c   *tp = &tilings[MI_SCREEN(mi)];
+       XPoint      pts[5];
+       vertex_type_c corner = vtype & VT_CORNER_MASK;
+
+       if (v1->off_screen && v2->off_screen && v3->off_screen && v4->off_screen)
+               return;
+       pts[corner] = v1->loc;
+       pts[VT_RIGHT(corner)] = v2->loc;
+       pts[VT_FAR(corner)] = v3->loc;
+       pts[VT_LEFT(corner)] = v4->loc;
+       pts[4] = pts[0];
+       if (MI_NPIXELS(mi) > 2) {
+               if ((vtype & VT_TYPE_MASK) == VT_THICK)
+                       XSetForeground(display, gc, MI_PIXEL(mi, tp->thick_color));
+               else
+                       XSetForeground(display, gc, MI_PIXEL(mi, tp->thin_color));
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       XFillPolygon(display, window, gc, pts, 4, Convex, CoordModeOrigin);
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       XDrawLines(display, window, gc, pts, 5, CoordModeOrigin);
+
+       if (tp->ammann) {
+               /* Draw some Ammann lines for debugging purposes.  This will probably
+                  fail miserably on a b&w display. */
+
+               if ((vtype & VT_TYPE_MASK) == VT_THICK) {
+                       static float r = .0;
+
+                       if (r == .0) {
+                               float       pi10 = 2 * atan(1.) / 5;
+
+                               r = 1 - sin(pi10) / (2 * sin(3 * pi10));
+                       }
+                       if (MI_NPIXELS(mi) > 2)
+                               XSetForeground(display, gc, MI_PIXEL(mi, tp->thin_color));
+                       else {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XSetLineAttributes(display, gc, 1, LineOnOffDash, CapNotLast, JoinMiter);
+                       }
+                       XDrawLine(display, window, gc,
+                             (int) (r * pts[3].x + (1 - r) * pts[0].x + .5),
+                             (int) (r * pts[3].y + (1 - r) * pts[0].y + .5),
+                             (int) (r * pts[1].x + (1 - r) * pts[0].x + .5),
+                            (int) (r * pts[1].y + (1 - r) * pts[0].y + .5));
+                       if (MI_NPIXELS(mi) <= 2)
+                               XSetLineAttributes(display, gc, 1, LineSolid, CapNotLast, JoinMiter);
+               } else {
+                       if (MI_NPIXELS(mi) > 2)
+                               XSetForeground(display, gc, MI_PIXEL(mi, tp->thick_color));
+                       else {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XSetLineAttributes(display, gc, 1, LineOnOffDash, CapNotLast, JoinMiter);
+                       }
+                       XDrawLine(display, window, gc,
+                                 (int) ((pts[3].x + pts[2].x) / 2 + .5),
+                                 (int) ((pts[3].y + pts[2].y) / 2 + .5),
+                                 (int) ((pts[1].x + pts[2].x) / 2 + .5),
+                                 (int) ((pts[1].y + pts[2].y) / 2 + .5));
+                       if (MI_NPIXELS(mi) <= 2)
+                               XSetLineAttributes(display, gc, 1, LineSolid, CapNotLast, JoinMiter);
+               }
+       }
+}
+
+/*-
+ * Update the status of this vertex on the forced vertex queue.  If
+ * the vertex has become untileable set tp->done.  This is supposed
+ * to detect dislocations -- never call this routine with a completely
+ * tiled vertex.
+ *
+ * Check for untileable vertices in check_vertex and stop tiling as
+ * soon as one finds one.  I don't know if it is possible to run out
+ * of forced vertices while untileable vertices exist (or will
+ * cavities inevitably appear).  If this can happen, add_random_tile
+ * might get called with an untileable vertex, causing ( n <= 1).
+ * (This is what the tp->done checks for).
+ *
+ * A delayLoop celebrates the dislocation.
+ */
+static void
+check_vertex(ModeInfo * mi, fringe_node_c * vertex, tiling_c * tp)
+{
+       rule_match_c hits[MAX_TILES_PER_VERTEX * N_VERTEX_RULES];
+       int         n_hits = match_rules(vertex, hits, False);
+       unsigned    forced_sides = 0;
+
+       if (vertex->rule_mask == 0) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Dislocation occurred!\n");
+               }
+               tp->busyLoop = CELEBRATE;       /* Should be able to recover */
+       }
+       if (1 == find_completions(vertex, hits, n_hits, S_LEFT, 0 /*, False */ ))
+               forced_sides |= S_LEFT;
+       if (1 == find_completions(vertex, hits, n_hits, S_RIGHT, 0 /*, False */ ))
+               forced_sides |= S_RIGHT;
+       if (forced_sides == 0) {
+               if (vertex->list_ptr != 0) {
+                       forced_node_c *node = *vertex->list_ptr;
+
+                       *vertex->list_ptr = node->next;
+                       if (node->next != 0)
+                               node->next->vertex->list_ptr = vertex->list_ptr;
+                       (void) free((void *) node);
+                       tp->forced.n_nodes--;
+                       if (!vertex->off_screen)
+                               tp->forced.n_visible--;
+                       vertex->list_ptr = 0;
+               }
+       } else {
+               forced_node_c *node;
+
+               if (vertex->list_ptr == 0) {
+                       node = ALLOC_NODE(forced_node_c);
+                       node->vertex = vertex;
+                       node->next = tp->forced.first;
+                       if (tp->forced.first != 0)
+                               tp->forced.first->vertex->list_ptr = &(node->next);
+                       tp->forced.first = node;
+                       vertex->list_ptr = &(tp->forced.first);
+                       tp->forced.n_nodes++;
+                       if (!vertex->off_screen)
+                               tp->forced.n_visible++;
+               } else
+                       node = *vertex->list_ptr;
+               node->forced_sides = forced_sides;
+       }
+}
+
+
+/*-
+ * Delete this vertex.  If the vertex is a member of the forced vertex queue,
+ * also remove that entry.  We assume that the vertex is no longer
+ * connected to the fringe.  Note that tp->fringe.nodes must not point to
+ * the vertex being deleted.
+ */
+static void
+delete_vertex(ModeInfo * mi, fringe_node_c * vertex, tiling_c * tp)
+{
+       if (tp->fringe.nodes == vertex) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in delete_penrose()\n");
+                       (void) fprintf(stderr, "tp->fringe.nodes == vertex\n");
+               }
+               tp->busyLoop = CELEBRATE;
+       }
+       if (vertex->list_ptr != 0) {
+               forced_node_c *node = *vertex->list_ptr;
+
+               *vertex->list_ptr = node->next;
+               if (node->next != 0)
+                       node->next->vertex->list_ptr = vertex->list_ptr;
+               (void) free((void *) node);
+               tp->forced.n_nodes--;
+               if (!vertex->off_screen)
+                       tp->forced.n_visible--;
+       }
+       if (!vertex->off_screen)
+               tp->fringe.n_nodes--;
+       (void) free((void *) vertex);
+}
+
+
+/*-
+ * Check whether the addition of a tile of type vtype would completely fill
+ * the space available at vertex.
+ */
+static int
+fills_vertex(ModeInfo * mi, vertex_type_c vtype, fringe_node_c * vertex)
+{
+       return
+               (vertex_dir(mi, vertex, S_LEFT) - vertex_dir(mi, vertex, S_RIGHT)
+                - vtype_angle(vtype)) % 10 == 0;
+}
+
+
+/*-
+ * If you were to add a tile of type vtype to a specified side of
+ * vertex, fringe_changes tells you which other vertices it would
+ * attach to.  The addresses of these vertices will be stored in the
+ * last three arguments.  Null is stored if the corresponding vertex
+ * would need to be allocated.
+ *
+ * The function also analyzes which vertices would be swallowed by the tiling
+ * and thus cut off from the fringe.  The result is returned as a bit pattern.
+ */
+#define FC_BAG 1               /* Total enclosure.  Should never occur. */
+#define FC_NEW_RIGHT 2
+#define FC_NEW_FAR 4
+#define FC_NEW_LEFT 8
+#define FC_NEW_MASK 0xe
+#define FC_CUT_THIS 0x10
+#define FC_CUT_RIGHT 0x20
+#define FC_CUT_FAR 0x40
+#define FC_CUT_LEFT 0x80
+#define FC_CUT_MASK 0xf0
+#define FC_TOTAL_MASK 0xff
+
+static unsigned
+fringe_changes(ModeInfo * mi, fringe_node_c * vertex,
+              unsigned side, vertex_type_c vtype,
+              fringe_node_c ** right, fringe_node_c ** far,
+              fringe_node_c ** left)
+{
+       fringe_node_c *v, *f = NULL;
+       unsigned    result = FC_NEW_FAR;        /* We clear this later if necessary. */
+
+       if (far)
+               *far = 0;
+       if (fills_vertex(mi, vtype, vertex)) {
+               result |= FC_CUT_THIS;
+       } else if (side == S_LEFT) {
+               result |= FC_NEW_RIGHT;
+               if (right)
+                       *right = 0;
+       } else {
+               result |= FC_NEW_LEFT;
+               if (left)
+                       *left = 0;
+       }
+
+       if (!(result & FC_NEW_LEFT)) {
+               v = vertex->next;
+               if (left)
+                       *left = v;
+               if (fills_vertex(mi, VT_LEFT(vtype), v)) {
+                       result = (result & ~FC_NEW_FAR) | FC_CUT_LEFT;
+                       f = v->next;
+                       if (far)
+                               *far = f;
+               }
+       }
+       if (!(result & FC_NEW_RIGHT)) {
+               v = vertex->prev;
+               if (right)
+                       *right = v;
+               if (fills_vertex(mi, VT_RIGHT(vtype), v)) {
+                       result = (result & ~FC_NEW_FAR) | FC_CUT_RIGHT;
+                       f = v->prev;
+                       if (far)
+                               *far = f;
+               }
+       }
+       if (!(result & FC_NEW_FAR)
+           && fills_vertex(mi, VT_FAR(vtype), f)) {
+               result |= FC_CUT_FAR;
+               result &= (~FC_NEW_LEFT & ~FC_NEW_RIGHT);
+               if (right && (result & FC_CUT_LEFT))
+                       *right = f->next;
+               if (left && (result & FC_CUT_RIGHT))
+                       *left = f->prev;
+       }
+       if (((result & FC_CUT_LEFT) && (result & FC_CUT_RIGHT))
+           || ((result & FC_CUT_THIS) && (result & FC_CUT_FAR)))
+               result |= FC_BAG;
+       return result;
+}
+
+
+/* A couple of lesser helper functions for add_tile. */
+static void
+add_vtype(fringe_node_c * vertex, unsigned side, vertex_type_c vtype)
+{
+       if (side == S_RIGHT)
+               vertex->tiles[vertex->n_tiles++] = vtype;
+       else {
+               register int i;
+
+               for (i = vertex->n_tiles; i > 0; i--)
+                       vertex->tiles[i] = vertex->tiles[i - 1];
+               vertex->tiles[0] = vtype;
+               vertex->n_tiles++;
+       }
+}
+
+static fringe_node_c *
+alloc_vertex(ModeInfo * mi, angle_c dir, fringe_node_c * from, tiling_c * tp)
+{
+       fringe_node_c *v = ALLOC_NODE(fringe_node_c);
+
+       if (v == 0) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in alloc_vertex()\n");
+                       (void) fprintf(stderr, "v = 0\n");
+               }
+               tp->busyLoop = CELEBRATE;
+       }
+       *v = *from;
+       add_unit_vec(dir, v->fived);
+       fived_to_loc(v->fived, tp, &(v->loc));
+       if (v->loc.x < 0 || v->loc.y < 0
+           || v->loc.x >= tp->width || v->loc.y >= tp->height) {
+               v->off_screen = True;
+               if (v->loc.x < -tp->width || v->loc.y < -tp->height
+                 || v->loc.x >= 2 * tp->width || v->loc.y >= 2 * tp->height)
+                       tp->done = True;
+       } else {
+               v->off_screen = False;
+               tp->fringe.n_nodes++;
+       }
+       v->n_tiles = 0;
+       v->rule_mask = (1 << N_VERTEX_RULES) - 1;
+       v->list_ptr = 0;
+       return v;
+}
+
+/*-
+ * Add a tile described by vtype to the side of vertex.  This must be
+ * allowed by the rules -- we do not check it here.  New vertices are
+ * allocated as necessary.  The fringe and the forced vertex pool are updated.
+ * The new tile is drawn on the display.
+ *
+ * One thing we do check here is whether the new tile causes an untiled
+ * area to become enclosed by the tiling.  If this would happen, the tile
+ * is not added.  The return value is true iff a tile was added.
+ */
+static int
+add_tile(ModeInfo * mi,
+        fringe_node_c * vertex, unsigned side, vertex_type_c vtype)
+{
+       tiling_c   *tp = &tilings[MI_SCREEN(mi)];
+
+       fringe_node_c
+               * left = 0,
+               *right = 0,
+               *far = 0,
+               *node;
+       unsigned    fc = fringe_changes(mi, vertex, side, vtype, &right, &far, &left);
+
+       vertex_type_c
+               ltype = VT_LEFT(vtype),
+               rtype = VT_RIGHT(vtype),
+               ftype = VT_FAR(vtype);
+
+       /* By our conventions vertex->next lies to the left of vertex and
+          vertex->prev to the right. */
+
+       /* This should never occur. */
+       if (fc & FC_BAG) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in add_tile()\n");
+                       (void) fprintf(stderr, "fc = %d, FC_BAG = %d\n", fc, FC_BAG);
+               }
+       }
+       if (side == S_LEFT) {
+               if (right == 0)
+                       right = alloc_vertex(mi,
+                                            vertex_dir(mi, vertex, S_LEFT) - vtype_angle(vtype), vertex, tp);
+               if (far == 0)
+                       far = alloc_vertex(mi,
+                                          vertex_dir(mi, left, S_RIGHT) + vtype_angle(ltype), left, tp);
+       } else {
+               if (left == 0)
+                       left = alloc_vertex(mi,
+                                           vertex_dir(mi, vertex, S_RIGHT) + vtype_angle(vtype), vertex, tp);
+               if (far == 0)
+                       far = alloc_vertex(mi,
+                                          vertex_dir(mi, right, S_LEFT) - vtype_angle(rtype), right, tp);
+       }
+
+       /* Having allocated the new vertices, but before joining them with
+          the rest of the fringe, check if vertices with same coordinates
+          already exist.  If any such are found, give up. */
+       node = tp->fringe.nodes;
+       do {
+               if (((fc & FC_NEW_LEFT) && fived_equal(node->fived, left->fived))
+                   || ((fc & FC_NEW_RIGHT) && fived_equal(node->fived, right->fived))
+                   || ((fc & FC_NEW_FAR) && fived_equal(node->fived, far->fived))) {
+                       /* Better luck next time. */
+                       if (fc & FC_NEW_LEFT)
+                               delete_vertex(mi, left, tp);
+                       if (fc & FC_NEW_RIGHT)
+                               delete_vertex(mi, right, tp);
+                       if (fc & FC_NEW_FAR)
+                               delete_vertex(mi, far, tp);
+                       return False;
+               }
+               node = node->next;
+       } while (node != tp->fringe.nodes);
+
+       /* Rechain. */
+       if (!(fc & FC_CUT_THIS)) {
+               if (side == S_LEFT) {
+                       vertex->next = right;
+                       right->prev = vertex;
+               } else {
+                       vertex->prev = left;
+                       left->next = vertex;
+               }
+       }
+       if (!(fc & FC_CUT_FAR)) {
+               if (!(fc & FC_CUT_LEFT)) {
+                       far->next = left;
+                       left->prev = far;
+               }
+               if (!(fc & FC_CUT_RIGHT)) {
+                       far->prev = right;
+                       right->next = far;
+               }
+       }
+       draw_tile(vertex, right, far, left, vtype, mi);
+
+       /* Delete vertices that are no longer on the fringe.  Check the others. */
+       if (fc & FC_CUT_THIS) {
+               tp->fringe.nodes = far;
+               delete_vertex(mi, vertex, tp);
+       } else {
+               add_vtype(vertex, side, vtype);
+               check_vertex(mi, vertex, tp);
+               tp->fringe.nodes = vertex;
+       }
+       if (fc & FC_CUT_FAR)
+               delete_vertex(mi, far, tp);
+       else {
+               add_vtype(far, fc & FC_CUT_RIGHT ? S_LEFT : S_RIGHT, ftype);
+               check_vertex(mi, far, tp);
+       }
+       if (fc & FC_CUT_LEFT)
+               delete_vertex(mi, left, tp);
+       else {
+               add_vtype(left, fc & FC_CUT_FAR ? S_LEFT : S_RIGHT, ltype);
+               check_vertex(mi, left, tp);
+       }
+       if (fc & FC_CUT_RIGHT)
+               delete_vertex(mi, right, tp);
+       else {
+               add_vtype(right, fc & FC_CUT_FAR ? S_RIGHT : S_LEFT, rtype);
+               check_vertex(mi, right, tp);
+       }
+       return True;
+}
+
+
+/*-
+ * Add a forced tile to a given forced vertex.  Basically an easy job,
+ * since we know what to add.  But it might fail if adding the tile
+ * would cause some untiled area to become enclosed.  There is also another
+ * more exotic culprit: we might have a dislocation.  Fortunately, they
+ * are very rare (the PRL article reported that perfect tilings of over
+ * 2^50 tiles had been generated).  There is a version of the algorithm
+ * that doesn't produce dislocations, but it's a lot hairier than the
+ * simpler version I used.
+ */
+static int
+add_forced_tile(ModeInfo * mi, forced_node_c * node)
+{
+       tiling_c   *tp = &tilings[MI_SCREEN(mi)];
+       unsigned    side;
+       vertex_type_c vtype;
+       rule_match_c hits[MAX_TILES_PER_VERTEX * N_VERTEX_RULES];
+       int         n;
+
+       if (node->forced_sides == (S_LEFT | S_RIGHT))
+               side = NRAND(2) ? S_LEFT : S_RIGHT;
+       else
+               side = node->forced_sides;
+       n = match_rules(node->vertex, hits, True);
+       n = find_completions(node->vertex, hits, n, side, &vtype /*, True */ );
+       if (n <= 0) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in add_forced_tile()\n");
+                       (void) fprintf(stderr, "n = %d\n", n);
+               }
+       }
+       return add_tile(mi, node->vertex, side, vtype);
+}
+
+
+/*-
+ * Whether the addition of a tile of vtype on the given side of vertex
+ * would conform to the rules.  The efficient way to do this would be
+ * to add the new tile and then use the same type of search as in
+ * match_rules.  However, this function is not a performance
+ * bottleneck (only needed for random tile additions, which are
+ * relatively infrequent), so I will settle for a simpler implementation.
+ */
+static int
+legal_move(fringe_node_c * vertex, unsigned side, vertex_type_c vtype)
+{
+       rule_match_c hits[MAX_TILES_PER_VERTEX * N_VERTEX_RULES];
+       vertex_type_c legal_vt[MAX_COMPL];
+       int         n_hits, n_legal, i;
+
+       n_hits = match_rules(vertex, hits, False);
+       n_legal = find_completions(vertex, hits, n_hits, side, legal_vt /*, False */ );
+       for (i = 0; i < n_legal; i++)
+               if (legal_vt[i] == vtype)
+                       return True;
+       return False;
+}
+
+
+/*-
+ * Add a randomly chosen tile to a given vertex.  This requires more checking
+ * as we must make sure the new tile conforms to the vertex rules at every
+ * vertex it touches. */
+static void
+add_random_tile(fringe_node_c * vertex, ModeInfo * mi)
+{
+       fringe_node_c *right, *left, *far;
+       int         i, j, n, n_hits, n_good;
+       unsigned    side, fc, no_good, s;
+       vertex_type_c vtypes[MAX_COMPL];
+       rule_match_c hits[MAX_TILES_PER_VERTEX * N_VERTEX_RULES];
+       tiling_c   *tp = &tilings[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) > 2) {
+               tp->thick_color = NRAND(MI_NPIXELS(mi));
+               /* Insure good contrast */
+               tp->thin_color = (NRAND(2 * MI_NPIXELS(mi) / 3) + tp->thick_color +
+                                 MI_NPIXELS(mi) / 6) % MI_NPIXELS(mi);
+       } else
+               tp->thick_color = tp->thin_color = MI_WHITE_PIXEL(mi);
+       n_hits = match_rules(vertex, hits, False);
+       side = NRAND(2) ? S_LEFT : S_RIGHT;
+       n = find_completions(vertex, hits, n_hits, side, vtypes /*, False */ );
+       /* One answer would mean a forced tile. */
+       if (n <= 0) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in add_random_tile()\n");
+                       (void) fprintf(stderr, "n = %d\n", n);
+               }
+       }
+       no_good = 0;
+       n_good = n;
+       for (i = 0; i < n; i++) {
+               fc = fringe_changes(mi, vertex, side, vtypes[i], &right, &far, &left);
+               if (fc & FC_BAG) {
+                       tp->done = True;
+                       if (MI_IS_VERBOSE(mi)) {
+                               (void) fprintf(stderr, "Weirdness in add_random_tile()\n");
+                               (void) fprintf(stderr, "fc = %d, FC_BAG = %d\n", fc, FC_BAG);
+                       }
+               }
+               if (right) {
+                       s = (((fc & FC_CUT_FAR) && (fc & FC_CUT_LEFT)) ? S_RIGHT : S_LEFT);
+                       if (!legal_move(right, s, VT_RIGHT(vtypes[i]))) {
+                               no_good |= (1 << i);
+                               n_good--;
+                               continue;
+                       }
+               }
+               if (left) {
+                       s = (((fc & FC_CUT_FAR) && (fc & FC_CUT_RIGHT)) ? S_LEFT : S_RIGHT);
+                       if (!legal_move(left, s, VT_LEFT(vtypes[i]))) {
+                               no_good |= (1 << i);
+                               n_good--;
+                               continue;
+                       }
+               }
+               if (far) {
+                       s = ((fc & FC_CUT_LEFT) ? S_RIGHT : S_LEFT);
+                       if (!legal_move(far, s, VT_FAR(vtypes[i]))) {
+                               no_good |= (1 << i);
+                               n_good--;
+                       }
+               }
+       }
+       if (n_good <= 0) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in add_random_tile()\n");
+                       (void) fprintf(stderr, "n_good = %d\n", n_good);
+               }
+       }
+       n = NRAND(n_good);
+       for (i = j = 0; i <= n; i++, j++)
+               while (no_good & (1 << j))
+                       j++;
+
+       i = add_tile(mi, vertex, side, vtypes[j - 1]);
+       if (!i) {
+               tp->done = True;
+               if (MI_IS_VERBOSE(mi)) {
+                       (void) fprintf(stderr, "Weirdness in add_random_tile()\n");
+                       (void) fprintf(stderr, "i = %d\n", i);
+               }
+       }
+}
+
+/* One step of the growth algorithm. */
+void
+draw_penrose(ModeInfo * mi)
+{
+       tiling_c   *tp = &tilings[MI_SCREEN(mi)];
+       int         i = 0, n;
+       forced_node_c *p = tp->forced.first;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (tp->busyLoop > 0) {
+               tp->busyLoop--;
+               return;
+       }
+       if (tp->done || tp->failures >= 100) {
+               init_penrose(mi);
+               return;
+       }
+       /* Check for the initial "2-gon". */
+       if (tp->fringe.nodes->prev == tp->fringe.nodes->next) {
+               vertex_type_c vtype = (unsigned char) (VT_TOTAL_MASK & LRAND());
+
+               MI_CLEARWINDOW(mi);
+
+               (void) add_tile(mi, tp->fringe.nodes, S_LEFT, vtype);
+               return;
+       }
+       /* No visible nodes left. */
+       if (tp->fringe.n_nodes == 0) {
+               tp->done = True;
+               tp->busyLoop = COMPLETION;      /* Just finished drawing */
+               return;
+       }
+       if (tp->forced.n_visible > 0 && tp->failures < 10) {
+               n = NRAND(tp->forced.n_visible);
+               for (;;) {
+                       while (p->vertex->off_screen)
+                               p = p->next;
+                       if (i++ < n)
+                               p = p->next;
+                       else
+                               break;
+               }
+       } else if (tp->forced.n_nodes > 0) {
+               n = NRAND(tp->forced.n_nodes);
+               while (i++ < n)
+                       p = p->next;
+       } else {
+               fringe_node_c *fringe_p = tp->fringe.nodes;
+
+               n = NRAND(tp->fringe.n_nodes);
+               i = 0;
+               for (; i <= n; i++)
+                       do {
+                               fringe_p = fringe_p->next;
+                       } while (fringe_p->off_screen);
+               add_random_tile(fringe_p, mi);
+               tp->failures = 0;
+               return;
+       }
+       if (add_forced_tile(mi, p))
+               tp->failures = 0;
+       else
+               tp->failures++;
+}
+
+
+/* Total clean-up. */
+void
+release_penrose(ModeInfo * mi)
+{
+       if (tilings != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       tiling_c   *tp = &tilings[screen];
+
+                       release_screen(tp);
+               }
+               (void) free((void *) tilings);
+               tilings = NULL;
+       }
+}
+
+#endif /* MODE_penrose */
diff --git a/xlockmore-4.14/modes/petal.c b/xlockmore-4.14/modes/petal.c
new file mode 100644 (file)
index 0000000..edf42a1
--- /dev/null
@@ -0,0 +1,358 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* petal --- mathematical flowers */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)petal.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 12-Aug-95: xlock version
+ * Jan-95: xscreensaver version (Jamie Zawinski <jwz@jwz.org>)
+ * 24-Jun-94: X11 version (Dale Moore  <Dale.Moore@cs.cmu.edu>)  
+ *            Based on a program for some old PDP-11 Graphics
+ *            Display Processors at CMU.
+ */
+
+/*-
+ * original copyright
+ * Copyright \(co 1994, by Carnegie Mellon University.  Permission to use,
+ * copy, modify, distribute, and sell this software and its documentation
+ * for any purpose is hereby granted without fee, provided fnord that the
+ * above copyright notice appear in all copies and that both that copyright
+ * notice and this permission notice appear in supporting documentation.
+ * No representations are made about the  suitability of fnord this software
+ * for any purpose.  It is provided "as is" without express or implied
+ * warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Petal"
+#define HACK_INIT init_petal
+#define HACK_DRAW draw_petal
+#define petal_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: -500 \n" \
+ "*cycles: 400 \n" \
+ "*ncolors: 64 \n" \
+ "*wireframe: False \n" \
+ "*fullrandom: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_petal
+
+ModeSpecOpt petal_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   petal_description =
+{"petal", "init_petal", "draw_petal", "release_petal",
+ "refresh_petal", "init_petal", NULL, &petal_opts,
+ 10000, -500, 400, 1, 64, 1.0, "",
+ "Shows various GCD Flowers", 0, NULL};
+
+#endif
+
+#define TWOPI (2.0*M_PI)
+
+/*-
+ * If MAXLINES is too big, we might not be able to get it
+ * to the X server in the 2byte length field.
+ * Must be less * than 16k
+ */
+#define MAXLINES (16*1024)
+
+/*-
+ * If the petal has only this many lines, it must be ugly and we do not
+ * want to see it.
+ */
+#define MINLINES 5
+
+typedef struct {
+       Bool        painted;
+       int         width, height;
+       int         lines;
+       int         time;
+       int         npoints;
+       long        color;
+       XPoint     *points;
+       Bool        wireframe;
+} petalstruct;
+
+static petalstruct *petals = NULL;
+
+/*-
+ * Macro:
+ *   sine
+ *   cosine
+ * Description:
+ *   Assume that degrees is .. oh 360... meaning that
+ *   there are 360 degress in a circle.  Then this function
+ *   would return the sin of the angle in degrees.  But lets
+ *   say that they are really big degrees, with 4 big degrees
+ *   the same as one regular degree.  Then this routine
+ *   would be called mysin(t, 90) and would return sin(t degrees * 4)
+ */
+#define sine(t, degrees) sin(t * TWOPI / (degrees))
+#define cosine(t, degrees) cos(t * TWOPI / (degrees))
+
+/*-
+ * Macro:
+ *   rand_range
+ * Description:
+ *   Return a random number between a inclusive  and b exclusive.
+ *    rand (3, 6) returns 3 or 4 or 5, but not 6.
+ */
+#define rand_range(a, b) (a + NRAND(b - a))
+
+static int
+gcd(int m, int n)
+/*-
+ * Greatest Common Divisor (also Greatest common factor).
+ */
+{
+       int         r;
+
+       for (;;) {
+               r = m % n;
+               if (r == 0)
+                       return (n);
+               m = n;
+               n = r;
+       }
+}
+
+static int
+numlines(int a, int b, int d)
+/*-
+ * Description:
+ *
+ *      Given parameters a and b, how many lines will we have to draw?
+ *
+ * Algorithm:
+ *
+ *      This algorithm assumes that r = sin (theta * a), where we
+ *      evaluate theta on multiples of b.
+ *
+ *      LCM (i, j) = i * j / GCD (i, j);
+ *
+ *      So, at LCM (b, 360) we start over again.  But since we
+ *      got to LCM (b, 360) by steps of b, the number of lines is
+ *      LCM (b, 360) / b.
+ *
+ *      If a is odd, then at 180 we cross over and start the
+ *      negative.  Someone should write up an elegant way of proving
+ *      this.  Why?  Because I'm not convinced of it myself.
+ *
+ */
+{
+#define odd(x) (x & 1)
+#define even(x) (!odd(x))
+       if (odd(a) && odd(b) && even(d))
+               d /= 2;
+       return (d / gcd(d, b));
+#undef odd
+}
+
+static int
+compute_petal(XPoint * points, int lines, int sizex, int sizey)
+/*-
+ * Description:
+ *
+ *    Basically, it's combination spirograph and string art.
+ *    Instead of doing lines, we just use a complex polygon,
+ *    and use an even/odd rule for filling in between.
+ *
+ *    The spirograph, in mathematical terms is a polar
+ *    plot of the form r = sin (theta * c);
+ *    The string art of this is that we evaluate that
+ *    function only on certain multiples of theta.  That is
+ *    we let theta advance in some random increment.  And then
+ *    we draw a straight line between those two adjacent points.
+ *
+ *    Eventually, the lines will start repeating themselves
+ *    if we've evaluated theta on some rational portion of the
+ *    whole.
+ *
+ *    The number of lines generated is limited to the
+ *    ratio of the increment we put on theta to the whole.
+ *    If we say that there are 360 degrees in a circle, then we
+ *    will never have more than 360 lines.
+ *
+ * Return:
+ *
+ *    The number of points.
+ *
+ */
+{
+       int         a, b, d;    /* These describe a unique petal */
+
+       double      r;
+       int         theta = 0;
+       XPoint     *p = points;
+       int         count;
+       int         npoints;
+
+       for (;;) {
+               d = lines;
+
+               a = rand_range(1, d);
+               b = rand_range(1, d);
+               npoints = numlines(a, b, d);
+               if (npoints >= MINLINES)
+                       break;
+       }
+
+       /* it might be nice to try to move as much sin and cos computing
+        * (or at least the argument computing) out of the loop.
+        */
+       for (count = npoints; count--;) {
+               r = sine(theta * a, d);
+
+               /* Convert from polar to cartesian coordinates */
+               /* We could round the results, but coercing seems just fine */
+               p->x = (int) (sine(theta, d) * r * sizex + sizex);
+               p->y = (int) (cosine(theta, d) * r * sizey + sizey);
+
+               /* Advance index into array */
+               p++;
+
+               /* Advance theta */
+               theta += b;
+               theta %= d;
+       }
+       *p = points[0];         /* Tack on another for XDrawLines */
+
+       return (npoints);
+}
+
+static void
+petal(ModeInfo * mi)
+{
+       petalstruct *pp = &petals[MI_SCREEN(mi)];
+
+       XSetForeground(MI_DISPLAY(mi), MI_GC(mi), pp->color);
+       if (pp->wireframe) {
+               XDrawLines(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                          pp->points, pp->npoints + 1, CoordModeOrigin);
+       } else {
+               XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                         pp->points, pp->npoints, Complex, CoordModeOrigin);
+       }
+}
+
+static void
+random_petal(ModeInfo * mi)
+{
+       petalstruct *pp = &petals[MI_SCREEN(mi)];
+
+       pp->npoints = compute_petal(pp->points, pp->lines,
+                                   pp->width / 2, pp->height / 2);
+
+       if (MI_NPIXELS(mi) <= 2)
+               pp->color = MI_WHITE_PIXEL(mi);
+       else
+               pp->color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       petal(mi);
+}
+
+void
+init_petal(ModeInfo * mi)
+{
+       petalstruct *pp;
+
+       if (petals == NULL) {
+               if ((petals = (petalstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (petalstruct))) == NULL)
+                       return;
+       }
+       pp = &petals[MI_SCREEN(mi)];
+
+       pp->lines = MI_COUNT(mi);
+       if (pp->lines > MAXLINES)
+               pp->lines = MAXLINES;
+       else if (pp->lines < -MINLINES) {
+               if (pp->points) {
+                       (void) free((void *) pp->points);
+                       pp->points = NULL;
+               }
+               pp->lines = NRAND(-pp->lines - MINLINES + 1) + MINLINES;
+       } else if (pp->lines < MINLINES)
+               pp->lines = MINLINES;
+       if (!pp->points)
+               pp->points = (XPoint *) malloc((pp->lines + 1) * sizeof (XPoint));
+       pp->width = MI_WIDTH(mi);
+       pp->height = MI_HEIGHT(mi);
+
+       pp->time = 0;
+       if (MI_IS_FULLRANDOM(mi))
+               pp->wireframe = (Bool) (LRAND() & 1);
+       else
+               pp->wireframe = MI_IS_WIREFRAME(mi);
+
+       MI_CLEARWINDOW(mi);
+       pp->painted = False;
+
+       random_petal(mi);
+}
+
+void
+draw_petal(ModeInfo * mi)
+{
+       petalstruct *pp = &petals[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (++pp->time > MI_CYCLES(mi))
+               init_petal(mi);
+       else
+               pp->painted = True;
+}
+
+void
+release_petal(ModeInfo * mi)
+{
+       if (petals != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       petalstruct *pp = &petals[screen];
+
+                       if (pp->points)
+                               (void) free((void *) pp->points);
+               }
+               (void) free((void *) petals);
+               petals = NULL;
+       }
+}
+
+void
+refresh_petal(ModeInfo * mi)
+{
+       petalstruct *pp = &petals[MI_SCREEN(mi)];
+
+       if (pp->painted) {
+               MI_CLEARWINDOW(mi);
+               petal(mi);
+               pp->painted = False;
+       }
+}
+
+#endif /* MODE_petal */
diff --git a/xlockmore-4.14/modes/puzzle.c b/xlockmore-4.14/modes/puzzle.c
new file mode 100644 (file)
index 0000000..8833767
--- /dev/null
@@ -0,0 +1,627 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* puzzle --- the familiar Sam Loyd puzzle */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)puzzle.c     4.09 98/03/20 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by Heath Rice <rice@asl.dl.nec.com>.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 20-Mar-98: Ideas from slip.c and eyes.c, problems with XGetImage when
+ *            image moved off screen (-inwindow or -debug).
+ * 10-May-97: Compatible with xscreensaver
+ * 15-Mar-96: cleaned up, NUMBERED compile-time switch is now broken.
+ * Feb-96: combined with rastering.  Jouk Jansen <joukj@hrem.stm.tudelft.nl>.
+ * Feb-95: written.  Heath Rice <hrice@netcom.com>
+ */
+
+/*-
+ * Chops up the screen into squares and randomly slides them around
+ * like that game where you try to rearrange the little tiles in their
+ * original order.  After it scrambles the tiles for awhile, it reverses
+ * itself and puts them back like they started.  This mode looks the coolest
+ * if you have a picture on your background.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Puzzle"
+#define HACK_INIT init_puzzle
+#define HACK_DRAW draw_puzzle
+#define puzzle_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 250 \n" \
+ "*ncolors: 64 \n" \
+ "*bitmap: \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+#include "iostuff.h"
+
+#ifdef MODE_puzzle
+
+ModeSpecOpt puzzle_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   puzzle_description =
+{"puzzle", "init_puzzle", "draw_puzzle", "release_puzzle",
+ "init_puzzle", "init_puzzle", NULL, &puzzle_opts,
+ 10000, 250, 1, 1, 64, 1.0, "",
+ "Shows a puzzle being scrambled and then solved", 0, NULL};
+
+#endif
+
+#define PUZZLE_WIDTH   image_width
+#define PUZZLE_HEIGHT    image_height
+#define PUZZLE_BITS    image_bits
+#include "puzzle.xbm"
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+#define PUZZLE_NAME    image_name
+#include "puzzle.xpm"
+#define DEFAULT_XPM 1
+#endif
+
+#define NOWAY 255
+
+  /*int storedmoves, *moves, *position, space;  To keep track of puzzle */
+typedef struct {
+       Bool        painted;    /* For debouncing */
+       int         excount;
+       int        *fixbuff;
+       XPoint      count, boxsize, windowsize;
+       XPoint      usablewindow, offsetwindow;
+       XPoint      randompos, randpos;
+       unsigned long black;
+       int         row, col, nextrow, nextcol, nextbox;
+       int         incrementOfMove;
+       int         lastbox;
+       int         forward;
+       int         prev;
+       int         moves;
+
+       /* Delta move stuff */
+       int         movingBox;
+       Pixmap      bufferBox;
+       int         cfactor, rfactor;
+       int         Lp;
+       int         cbs, cbw, rbs, rbw;
+       int         lengthOfMove;
+
+#ifdef NUMBERED
+       XImage     *image;
+       GC          gc;
+       /* Font stuff */
+       int         done;
+       int         ascent, fontWidth, fontHeight;
+#else
+       XImage     *logo;
+       GC          backGC;
+       Colormap    cmap;
+       int         graphics_format;
+#endif
+} puzzlestruct;
+
+static puzzlestruct *puzzs = NULL;
+
+#ifdef NUMBERED
+extern XFontStruct *getFont(Display * display);
+
+#define font_height(f) (f->ascent + f->descent)
+static XFontStruct *mode_font = None;
+
+static int
+font_width(XFontStruct * font, char ch)
+{
+       int         dummy;
+       XCharStruct xcs;
+
+       (void) XTextExtents(font, &ch, 1, &dummy, &dummy, &dummy, &xcs);
+       return xcs.width;
+}
+
+void
+NumberScreen(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+
+       if (mode_font == None)
+               mode_font = getFont(display);
+       if (!pp->done) {
+               XGCValues   gcv;
+
+               pp->done = 1;
+               gcv.font = mode_font->fid;
+               XSetFont(display, MI_GC(mi), mode_font->fid);
+               gcv.graphics_exposures = False;
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               pp->gc = XCreateGC(display, window,
+                                  GCForeground | GCBackground | GCGraphicsExposures | GCFont, &gcv);
+               pp->ascent = mode_font->ascent;
+               pp->fontHeight = font_height(mode_font);
+               pp->fontWidth = font_width(mode_font, '5');
+       }
+       XSetForeground(display, pp->gc, MI_WHITE_PIXEL(mi));
+
+       {
+               XPoint      pos, letter;
+               int         count = 1, digitOffset = 1, temp, letterOffset;
+               int         i, j, mult = pp->count.x * pp->count.y;
+               char        buf[16];
+
+               letter.x = pp->boxsize.x / 2 - 3;
+               letter.y = pp->boxsize.y / 2 + pp->ascent / 2 - 1;
+               letterOffset = pp->fontWidth / 2;
+               pos.y = 0;
+               for (j = 0; j < pp->count.y; j++) {
+                       pos.x = 0;
+                       for (i = 0; i < pp->count.x; i++) {
+                               if (count < mult) {
+                                       if (pp->boxsize.x > 2 * pp->fontWidth &&
+                                           pp->boxsize.y > pp->fontHeight) {
+                                               (void) sprintf(buf, "%d", count);
+                                               (void) XDrawString(display, window, pp->gc,
+                                                                  pos.x + letter.x - letterOffset * digitOffset +
+                                                            pp->randompos.x,
+                                                                  pos.y + letter.y + pp->randompos.y, buf, digitOffset);
+                                       }
+                                       XDrawRectangle(display, window, pp->gc,
+                                                      pos.x + 1 + pp->randompos.x, pos.y + 1 + pp->randompos.y,
+                                       pp->boxsize.x - 3, pp->boxsize.y - 3);
+                                       count++;
+                                       digitOffset = 0;
+                                       temp = count;
+                                       while (temp >= 1) {
+                                               temp /= 10;
+                                               digitOffset++;
+                                       }
+                               }
+                               pos.x += pp->boxsize.x;
+                       }
+                       pos.y += pp->boxsize.y;
+               }
+       }
+}
+#endif
+
+static int
+setupmove(ModeInfo * mi)
+{
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+
+       if ((pp->prev == pp->excount) && (pp->excount > 0) && (pp->forward == 1)) {
+               pp->lastbox = -1;
+               pp->forward = 0;
+               pp->prev--;
+       } else if ((pp->prev == -1) && (pp->excount > 0) && (pp->forward == 0)) {
+               pp->lastbox = -1;
+               pp->forward = 1;
+               pp->prev++;
+       }
+       if (pp->forward)
+               pp->nextbox = NRAND(5);
+       else
+               pp->nextbox = pp->fixbuff[pp->prev];
+
+       switch (pp->nextbox) {
+               case 0:
+                       if ((pp->row == 0) || (pp->lastbox == 2))
+                               pp->nextbox = NOWAY;
+                       else {
+                               pp->nextrow = pp->row - 1;
+                               pp->nextcol = pp->col;
+                       }
+                       break;
+               case 1:
+                       if ((pp->col == pp->count.x - 1) || (pp->lastbox == 3))
+                               pp->nextbox = NOWAY;
+                       else {
+                               pp->nextrow = pp->row;
+                               pp->nextcol = pp->col + 1;
+                       }
+                       break;
+               case 2:
+                       if ((pp->row == pp->count.y - 1) || (pp->lastbox == 0))
+                               pp->nextbox = NOWAY;
+                       else {
+                               pp->nextrow = pp->row + 1;
+                               pp->nextcol = pp->col;
+                       }
+                       break;
+               case 3:
+                       if ((pp->col == 0) || (pp->lastbox == 1))
+                               pp->nextbox = NOWAY;
+                       else {
+                               pp->nextrow = pp->row;
+                               pp->nextcol = pp->col - 1;
+                       }
+                       break;
+               default:
+                       pp->nextbox = NOWAY;
+                       break;
+       }
+
+       if (pp->nextbox != NOWAY) {
+               pp->lastbox = pp->nextbox;
+               return True;
+       } else
+               return False;
+}
+
+static void
+setupmovedelta(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+
+       if (pp->bufferBox != None) {
+               XFreePixmap(display, pp->bufferBox);
+               pp->bufferBox = None;
+       }
+       pp->bufferBox = XCreatePixmap(display, MI_WINDOW(mi),
+                                pp->boxsize.x, pp->boxsize.y, MI_DEPTH(mi));
+       if (pp->bufferBox == None) {
+               return;
+       }
+       XCopyArea(MI_DISPLAY(mi), MI_WINDOW(mi), pp->bufferBox, pp->backGC,
+                 pp->nextcol * pp->boxsize.x + pp->randompos.x + 1,
+                 pp->nextrow * pp->boxsize.y + pp->randompos.y + 1,
+                 pp->boxsize.x - 2, pp->boxsize.y - 2, 0, 0);
+       XFlush(MI_DISPLAY(mi));
+
+       if (pp->nextcol > pp->col) {
+               pp->cfactor = -1;
+               pp->cbs = pp->boxsize.x;
+               pp->cbw = pp->incrementOfMove;
+       } else if (pp->col > pp->nextcol) {
+               pp->cfactor = 1;
+               pp->cbs = -pp->incrementOfMove;
+               pp->cbw = pp->incrementOfMove;
+       } else {
+               pp->cfactor = 0;
+               pp->cbs = 0;
+               pp->cbw = pp->boxsize.x;
+       }
+       if (pp->nextrow > pp->row) {
+               pp->rfactor = -1;
+               pp->rbs = pp->boxsize.y;
+               pp->rbw = pp->incrementOfMove;
+       } else if (pp->row > pp->nextrow) {
+               pp->rfactor = 1;
+               pp->rbs = -pp->incrementOfMove;
+               pp->rbw = pp->incrementOfMove;
+       } else {
+               pp->rfactor = 0;
+               pp->rbs = 0;
+               pp->rbw = pp->boxsize.y;
+       }
+
+       if (pp->cfactor == 0)
+               pp->lengthOfMove = pp->boxsize.y;
+       else if (pp->rfactor == 0)
+               pp->lengthOfMove = pp->boxsize.x;
+       else
+               pp->lengthOfMove = MIN(pp->boxsize.x, pp->boxsize.y);
+       pp->Lp = pp->incrementOfMove;
+}
+
+static void
+wrapupmove(ModeInfo * mi)
+{
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+
+       if (pp->excount) {
+               if (pp->forward) {
+                       pp->fixbuff[pp->prev] = (pp->nextbox + 2) % 4;
+                       pp->prev++;
+               } else
+                       pp->prev--;
+       }
+}
+
+static void
+wrapupmovedelta(ModeInfo * mi)
+{
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+
+       if (pp->bufferBox) {
+
+               XCopyArea(MI_DISPLAY(mi), pp->bufferBox, MI_WINDOW(mi), pp->backGC,
+                         0, 0, pp->boxsize.x - 2, pp->boxsize.y - 2,
+                         pp->col * pp->boxsize.x + pp->randompos.x + 1,
+                         pp->row * pp->boxsize.y + pp->randompos.y + 1);
+
+               XFlush(MI_DISPLAY(mi));
+
+               pp->row = pp->nextrow;
+               pp->col = pp->nextcol;
+
+               XFreePixmap(MI_DISPLAY(mi), pp->bufferBox);
+               pp->bufferBox = None;
+       }
+}
+
+static int
+moveboxdelta(ModeInfo * mi)
+{
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+       int         cf = pp->nextcol * pp->boxsize.x +
+       pp->Lp * pp->cfactor + pp->randompos.x;
+       int         rf = pp->nextrow * pp->boxsize.y +
+       pp->Lp * pp->rfactor + pp->randompos.y;
+
+       if (pp->Lp <= pp->lengthOfMove) {
+               if (pp->bufferBox) {
+                       XCopyArea(MI_DISPLAY(mi), pp->bufferBox, MI_WINDOW(mi),
+                                 pp->backGC, 0, 0, pp->boxsize.x - 2, pp->boxsize.y - 2,
+                                 cf + 1, rf + 1);
+                       XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), pp->backGC,
+                                      cf + pp->cbs - 1, rf + pp->rbs - 1, pp->cbw + 2, pp->rbw + 2);
+               }
+               if ((pp->Lp + pp->incrementOfMove > pp->lengthOfMove) &&
+                   (pp->Lp != pp->lengthOfMove))
+                       pp->Lp = pp->lengthOfMove - pp->incrementOfMove;
+               pp->Lp += pp->incrementOfMove;
+               return False;
+       } else
+               return True;
+}
+
+static void
+init_stuff(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+
+       if (!pp->logo)
+               getImage(mi, &pp->logo, PUZZLE_WIDTH, PUZZLE_HEIGHT, PUZZLE_BITS,
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+                        DEFAULT_XPM, PUZZLE_NAME,
+#endif
+                        &pp->graphics_format, &pp->cmap, &pp->black);
+#ifndef STANDALONE
+       if (pp->cmap != None) {
+               setColormap(display, window, pp->cmap, MI_IS_INWINDOW(mi));
+               if (pp->backGC == None) {
+                       XGCValues   xgcv;
+
+                       xgcv.background = pp->black;
+                       pp->backGC = XCreateGC(display, window, GCBackground, &xgcv);
+               }
+       } else
+#endif /* STANDALONE */
+       {
+               pp->black = MI_BLACK_PIXEL(mi);
+               pp->backGC = MI_GC(mi);
+       }
+}
+
+static void
+free_stuff(Display * display, puzzlestruct * pp)
+{
+       if (pp->cmap != None) {
+               XFreeColormap(display, pp->cmap);
+               if (pp->backGC != None) {
+                       XFreeGC(display, pp->backGC);
+                       pp->backGC = None;
+               }
+               pp->cmap = None;
+       } else
+               pp->backGC = None;
+       destroyImage(&pp->logo, &pp->graphics_format);
+}
+
+void
+init_puzzle(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       puzzlestruct *pp;
+       int         x, y;
+       XPoint      size;
+
+       if (puzzs == NULL) {
+               if ((puzzs = (puzzlestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (puzzlestruct))) == NULL)
+                       return;
+       }
+       pp = &puzzs[MI_SCREEN(mi)];
+
+#if defined( USE_XPM ) || defined( USE_XPMINC )
+        /* This is needed when another program changes the colormap. */
+        free_stuff(MI_DISPLAY(mi), pp);
+#endif
+       init_stuff(mi);
+       if (pp->painted && pp->windowsize.x == MI_WIDTH(mi) &&
+           pp->windowsize.y == MI_HEIGHT(mi))
+               return;         /* Debounce since refresh_puzzle is init_puzzle */
+
+       pp->excount = MI_COUNT(mi);
+       if (pp->excount < 0) {
+               if (pp->fixbuff != NULL)
+                       (void) free((void *) pp->fixbuff);
+               pp->fixbuff = NULL;
+               pp->excount = NRAND(-pp->excount) + 1;
+       }
+       pp->lastbox = -1;
+       pp->moves = 0;
+       pp->movingBox = False;
+
+       pp->windowsize.x = MI_WIDTH(mi);
+       pp->windowsize.y = MI_HEIGHT(mi);
+       if (pp->windowsize.x < 7)
+               pp->windowsize.x = 7;
+       if (pp->windowsize.y < 7)
+               pp->windowsize.y = 7;
+       pp->forward = 1;
+       pp->prev = 0;
+       /* don't want any exposure events from XCopyArea */
+       XSetGraphicsExposures(display, pp->backGC, False);
+
+       MI_CLEARWINDOWCOLORMAP(mi, pp->backGC, pp->black);
+
+       if (pp->logo) {
+               size.x = (pp->logo->width < pp->windowsize.x) ?
+                       pp->logo->width : pp->windowsize.x;
+               size.y = (pp->logo->height < pp->windowsize.y) ?
+                       pp->logo->height : pp->windowsize.y;
+       } else {
+               size.x = pp->windowsize.x;
+               size.y = pp->windowsize.y;
+       }
+       pp->boxsize.y = NRAND(1 + size.y / 4) + 6;
+       pp->boxsize.x = NRAND(1 + size.x / 4) + 6;
+       if ((pp->boxsize.x > 4 * pp->boxsize.y) ||
+           pp->boxsize.y > 4 * pp->boxsize.x)
+               pp->boxsize.x = pp->boxsize.y = 2 * MIN(pp->boxsize.x, pp->boxsize.y);
+       pp->count.x = size.x / pp->boxsize.x;
+       pp->count.y = size.y / pp->boxsize.y;
+
+       if (pp->bufferBox != None) {
+               XFreePixmap(display, pp->bufferBox);
+               pp->bufferBox = None;
+       }
+       pp->usablewindow.x = pp->count.x * pp->boxsize.x;
+       pp->usablewindow.y = pp->count.y * pp->boxsize.y;
+       pp->offsetwindow.x = (pp->windowsize.x - pp->usablewindow.x) / 2;
+       pp->offsetwindow.y = (pp->windowsize.y - pp->usablewindow.y) / 2;
+
+       pp->incrementOfMove = MIN(pp->usablewindow.x, pp->usablewindow.y) / 20;
+       pp->incrementOfMove = MAX(pp->incrementOfMove, 1);
+
+       if (pp->logo) {
+               pp->randompos.x = NRAND(MAX((pp->windowsize.x - pp->logo->width),
+                                           2 * pp->offsetwindow.x + 1));
+               pp->randompos.y = NRAND(MAX((pp->windowsize.y - pp->logo->height),
+                                           2 * pp->offsetwindow.y + 1));
+               if (MI_NPIXELS(mi) <= 2)
+                       XSetForeground(display, pp->backGC, MI_WHITE_PIXEL(mi));
+               else
+                       XSetForeground(display, pp->backGC, MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))));
+               (void) XPutImage(display, window, pp->backGC, pp->logo,
+               (int) (NRAND(MAX(1, (pp->logo->width - pp->usablewindow.x)))),
+                                (int) (NRAND(MAX(1, (pp->logo->height - pp->usablewindow.y)))),
+                                pp->randompos.x, pp->randompos.y,
+                                pp->usablewindow.x, pp->usablewindow.y);
+               XSetForeground(display, pp->backGC, pp->black);
+               for (x = 0; x <= pp->count.x; x++) {
+                       int         tempx = x * pp->boxsize.x;
+
+                       XDrawLine(display, window, pp->backGC,
+                                 tempx + pp->randompos.x, pp->randompos.y,
+                                 tempx + pp->randompos.x, pp->usablewindow.y + pp->randompos.y);
+                       XDrawLine(display, window, pp->backGC,
+                               tempx + pp->randompos.x - 1, pp->randompos.y,
+                                 tempx + pp->randompos.x - 1, pp->usablewindow.y + pp->randompos.y);
+               }
+               for (y = 0; y <= pp->count.y; y++) {
+                       int         tempy = y * pp->boxsize.y;
+
+                       XDrawLine(display, window, pp->backGC,
+                                 pp->randompos.x, tempy + pp->randompos.y,
+                                 pp->usablewindow.x + pp->randompos.x, tempy + pp->randompos.y);
+                       XDrawLine(display, window, pp->backGC,
+                               pp->randompos.x, tempy + pp->randompos.y - 1,
+                                 pp->usablewindow.x + pp->randompos.x, tempy + pp->randompos.y - 1);
+               }
+       }
+#ifdef NUMBERED
+       else {
+               if (pp->image)
+                       (void) XDestroyImage(pp->image);
+               pp->randompos.x = pp->offsetwindow.x;
+               pp->randompos.y = pp->offsetwindow.y;
+               NumberScreen(mi);
+               pp->image = XGetImage(display, window,
+                                     pp->offsetwindow.x, pp->offsetwindow.y,
+                                     pp->usablewindow.x, pp->usablewindow.y,
+                                     AllPlanes,
+                                (MI_NPIXELS(mi) <= 2) ? XYPixmap : ZPixmap);
+       }
+
+       pp->row = pp->count.y - 1;
+       pp->col = pp->count.x - 1;
+#else
+       pp->row = NRAND(pp->count.y);
+       pp->col = NRAND(pp->count.x);
+#endif
+
+       if ((pp->excount) && (pp->fixbuff == NULL))
+               if ((pp->fixbuff = (int *) calloc(pp->excount, sizeof (int))) == NULL)
+                                   (void) fprintf(stderr, "Could not allocate memory for puzzle buffer\n");
+
+       pp->painted = True;
+}
+
+void
+draw_puzzle(ModeInfo * mi)
+{
+       puzzlestruct *pp = &puzzs[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       pp->painted = False;
+       if (pp->movingBox) {
+               if (moveboxdelta(mi)) {
+                       wrapupmovedelta(mi);
+                       wrapupmove(mi);
+                       pp->movingBox = False;
+                       if (pp->moves++ > 2 * MI_COUNT(mi))
+                               init_puzzle(mi);
+               }
+       } else {
+               if (setupmove(mi)) {
+                       setupmovedelta(mi);
+                       pp->movingBox = True;
+               }
+       }
+}
+
+void
+release_puzzle(ModeInfo * mi)
+{
+       if (puzzs != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       puzzlestruct *pp = &puzzs[screen];
+
+                       if (pp->fixbuff != NULL)
+                               (void) free((void *) pp->fixbuff);
+                       if (pp->bufferBox != None)
+                               XFreePixmap(MI_DISPLAY(mi), pp->bufferBox);
+                       free_stuff(MI_DISPLAY(mi), pp);
+               }
+               (void) free((void *) puzzs);
+               puzzs = NULL;
+       }
+#ifdef NUMBERED
+       if (mode_font != None) {
+               XFreeFont(MI_DISPLAY(mi), mode_font);
+               mode_font = None;
+       }
+#endif
+}
+
+#endif /* MODE_puzzle */
diff --git a/xlockmore-4.14/modes/pyro.c b/xlockmore-4.14/modes/pyro.c
new file mode 100644 (file)
index 0000000..4cf04b3
--- /dev/null
@@ -0,0 +1,607 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* pyro --- fireworks */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)pyro.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 15-May-97: jwz@jwz.org: turned into a standalone program.
+ * 05-Sep-96: Added 3d support Henrik Theiling <theiling@coli.uni-sb.de>
+ * 16-Mar-91: Written, received from David Brooks <brooks@osf.org>
+ */
+
+/*-
+ * The physics of the rockets is a little bogus, but it looks OK.  Each is
+ * given an initial velocity impetus.  They decelerate slightly (gravity
+ * overcomes the rocket's impulse) and explode as the rocket's main fuse
+ * gives out (we could add a ballistic stage, maybe).  The individual
+ * stars fan out from the rocket, and they decelerate less quickly.
+ * That's called bouyancy, but really it's again a visual preference.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Pyro"
+#define HACK_INIT init_pyro
+#define HACK_DRAW draw_pyro
+#define pyro_opts xlockmore_opts
+#define DEFAULTS "*delay: 15000 \n" \
+ "*count: 100 \n" \
+ "*size: -3 \n" \
+ "*ncolors: 200 \n" \
+ "*use3d: False \n" \
+ "*delta3d: 1.5 \n" \
+ "*right3d: red \n" \
+ "*left3d: blue \n" \
+ "*both3d: magenta \n" \
+ "*none3d: black \n"
+#define UNIFORM_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_pyro
+
+ModeSpecOpt pyro_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   pyro_description =
+{"pyro", "init_pyro", "draw_pyro", "release_pyro",
+ "refresh_pyro", "init_pyro", NULL, &pyro_opts,
+ 15000, 100, 1, -3, 64, 1.0, "",
+ "Shows fireworks", 0, NULL};
+
+#endif
+
+#define ORANGE (MI_NPIXELS(mi) / 16)
+
+#define MINROCKETS 1
+#define MINSIZE 1
+
+#define SILENT 0
+#define REDGLARE 1
+#define BURSTINGINAIR 2
+
+#define CLOUD 0
+#define DOUBLECLOUD 1
+#define COLORCLOUD 2
+/* Clearly other types and other fascinating visual effects could be added... */
+
+/* P_xxx parameters represent the reciprocal of the probability... */
+#define P_IGNITE 5000          /* ...of ignition per cycle */
+#define P_DOUBLECLOUD 10       /* ...of an ignition being double */
+#define P_COLORCLOUD 5         /* ...of an ignition being full color */
+#define P_MULTI 75             /* ...of an ignition being several @ once */
+#define P_FUSILLADE 250                /* ...of an ignition starting a fusillade */
+
+#define ROCKETW 2              /* Dimensions of rocket */
+#define ROCKETH 4
+#define XVELFACTOR 0.0025      /* Max horizontal velocity / screen width */
+#define ZVELFACTOR 0.0025
+#define MINZVAL      250       /* absolute minimum of z values */
+#define MINZVALSTART 300       /* range where they start */
+#define MAXZVALSTART 1000
+#define SCREENZ      400
+/* the z-component still gets too small sometimes */
+#define GETZDIFFAUX(z) (MI_DELTA3D(mi)*20.0*(1.0-(SCREENZ)/(z)))
+#define GETZDIFF(z)    ((z)<MINZVAL?GETZDIFFAUX(MINZVAL):GETZDIFFAUX(z))
+#define MINYVELFACTOR 0.016    /* Min vertical velocity / screen height */
+#define MAXYVELFACTOR 0.018
+#define GRAVFACTOR 0.0002      /* delta v / screen height */
+#define MINFUSE 50             /* range of fuse lengths for rocket */
+#define MAXFUSE 100
+
+#define FUSILFACTOR 10         /* Generate fusillade by reducing P_IGNITE */
+#define FUSILLEN 100           /* Length of fusillade, in ignitions */
+
+#define SVELFACTOR 0.1         /* Max star velocity / yvel */
+#define BOUYANCY 0.2           /* Reduction in grav deceleration for stars */
+#define MAXSTARS 150           /* Number of stars issued from a shell */
+#define MINSTARS 50
+#define MINSFUSE 50            /* Range of fuse lengths for stars */
+#define MAXSFUSE 100
+
+#define INTRAND(min,max) (NRAND((max+1)-(min))+(min))
+#define FLOATRAND(min,max) ((min)+((double) LRAND()/((double) MAXRAND))*((max)-(min)))
+#define INCZ(val,add) if((val)+(add)>MINZVAL) val+=(add)
+#define ADDZ(val,add) (((val)+(add)>MINZVAL)?(val)+(add):(val))
+#define TWOPI (2.0*M_PI)
+
+typedef struct {
+       unsigned long color;
+       float       sx, sy, sz; /* Distance from notional center  */
+       float       sxvel, syvel, szvel;        /* Relative to notional center */
+} star;
+
+typedef struct {
+       int         state;
+       int         shelltype;
+       int         fuse;
+       float       xvel, yvel, zvel;
+       float       x, y, z;
+       unsigned long color[2];
+       int         nstars;
+       XRectangle  Xpoints[2][MAXSTARS];
+       XRectangle  Xpointsleft[2][MAXSTARS];
+       star        stars[MAXSTARS];
+} rocket;
+
+typedef struct {
+       int         p_ignite;
+       unsigned long rockpixel;
+       int         nflying, nrockets;
+       int         fusilcount;
+       int         width, height;
+       int         lmargin, rmargin;
+       int         star_size;
+       float       minvelx, maxvelx;
+       float       minvely, maxvely;
+       float       minvelz, maxvelz;
+       float       maxsvel;
+       float       rockdecel, stardecel;
+       rocket     *rockq;
+} pyrostruct;
+
+static void shootup(ModeInfo * mi, pyrostruct * pp, rocket * rp);
+static void burst(ModeInfo * mi, pyrostruct * pp, rocket * rp);
+
+static pyrostruct *pyros = NULL;
+static int  orig_p_ignite;
+static int  just_started = True;       /* Greet the user right away */
+
+static void
+ignite(ModeInfo * mi, pyrostruct * pp)
+{
+       rocket     *rp;
+       int         multi, shelltype, nstars, fuse, pix;
+       unsigned long color[2];
+       float       xvel, yvel, x, zvel = 0.0, z = 0.0;
+
+       x = NRAND(pp->width);
+       xvel = FLOATRAND(-pp->maxvelx, pp->maxvelx);
+/* All this to stop too many rockets going offscreen: */
+       if ((x < pp->lmargin && xvel < 0.0) || (x > pp->rmargin && xvel > 0.0))
+               xvel = -xvel;
+       yvel = FLOATRAND(pp->minvely, pp->maxvely);
+       if (MI_IS_USE3D(mi)) {
+               z = FLOATRAND(MINZVALSTART, MAXZVALSTART);
+               zvel = FLOATRAND(pp->minvelz, pp->maxvelz);
+       }
+       fuse = INTRAND(MINFUSE, MAXFUSE);
+       nstars = INTRAND(MINSTARS, MAXSTARS);
+       if (MI_NPIXELS(mi) > 2) {
+               pix = NRAND(MI_NPIXELS(mi));
+               color[0] = MI_PIXEL(mi, pix);
+               color[1] = MI_PIXEL(mi,
+                           ((pix + (MI_NPIXELS(mi) / 2)) % MI_NPIXELS(mi)));
+       } else {
+               color[0] = color[1] = MI_WHITE_PIXEL(mi);
+       }
+
+       multi = 1;
+       if (NRAND(P_DOUBLECLOUD) == 0)
+               shelltype = DOUBLECLOUD;
+       else {
+               shelltype = CLOUD;
+               if (NRAND(P_MULTI) == 0)
+                       multi = INTRAND(5, 15);
+       }
+       if (NRAND(P_COLORCLOUD) == 0)
+               shelltype |= COLORCLOUD;
+
+       rp = pp->rockq;
+       while (multi--) {
+               if (pp->nflying >= pp->nrockets)
+                       return;
+               while (rp->state != SILENT)
+                       rp++;
+               pp->nflying++;
+               rp->shelltype = shelltype;
+               rp->state = REDGLARE;
+               rp->color[0] = color[0];
+               rp->color[1] = color[1];
+               rp->xvel = xvel;
+               rp->yvel = FLOATRAND(yvel * 0.97, yvel * 1.03);
+               rp->fuse = INTRAND((fuse * 90) / 100, (fuse * 110) / 100);
+               rp->x = x + FLOATRAND(multi * 7.6, multi * 8.4);
+               rp->y = pp->height - 1;
+               if (MI_IS_USE3D(mi)) {
+                       rp->zvel = FLOATRAND(zvel * 0.97, zvel * 1.03);
+                       rp->z = z;
+               }
+               rp->nstars = nstars;
+       }
+}
+
+static void
+animate(ModeInfo * mi, pyrostruct * pp, rocket * rp)
+{
+       int         starn, diff;
+       float       r, theta;
+
+       if (rp->state == REDGLARE) {
+               shootup(mi, pp, rp);
+
+/* Handle setup for explosion */
+               if (rp->state == BURSTINGINAIR) {
+                       for (starn = 0; starn < rp->nstars; starn++) {
+                               rp->stars[starn].sx = rp->stars[starn].sy = 0.0;
+                               if (MI_IS_USE3D(mi)) {
+                                       rp->stars[starn].sz = 0.0;
+                                       diff = (int) GETZDIFF(rp->z);
+                                       rp->Xpoints[0][starn].x = (int) rp->x + diff;
+                                       rp->Xpointsleft[0][starn].x = (int) rp->x - diff;
+                                       rp->Xpoints[0][starn].y =
+                                               rp->Xpointsleft[0][starn].y = (int) rp->y;
+                                       if (rp->shelltype & DOUBLECLOUD) {
+                                               rp->Xpoints[1][starn].x = (int) rp->x + diff;
+                                               rp->Xpointsleft[1][starn].x = (int) rp->x - diff;
+                                               rp->Xpoints[1][starn].y =
+                                                       rp->Xpointsleft[1][starn].y = (int) rp->y;
+                                       }
+                                       /* this isn't really a 3d direction. it's */
+                                       /* very much the same as in worm. */
+                                       r = FLOATRAND(0.0, pp->maxsvel);
+                                       theta = FLOATRAND(0.0, TWOPI);
+                                       rp->stars[starn].sxvel = r * COSF(theta);
+                                       rp->stars[starn].syvel = r * SINF(theta);
+                                       theta = FLOATRAND(0.0, TWOPI);
+                                       rp->stars[starn].szvel = FLOATRAND(0.0, pp->maxsvel) * SINF(theta);
+                               } else {
+                                       rp->Xpoints[0][starn].x = (int) rp->x;
+                                       rp->Xpoints[0][starn].y = (int) rp->y;
+                                       if ((rp->shelltype & COLORCLOUD) && (MI_NPIXELS(mi) > 2)) {
+                                               if (NRAND(6) < 1)
+                                                       rp->stars[starn].color = MI_WHITE_PIXEL(mi);
+                                               else
+                                                       rp->stars[starn].color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                                       }
+                                       if (rp->shelltype & DOUBLECLOUD) {
+                                               rp->Xpoints[1][starn].x = (int) rp->x;
+                                               rp->Xpoints[1][starn].y = (int) rp->y;
+                                       }
+                                       r = FLOATRAND(0.0, pp->maxsvel);
+                                       theta = FLOATRAND(0.0, TWOPI);
+                                       rp->stars[starn].sxvel = r * COSF(theta);
+                                       rp->stars[starn].syvel = r * SINF(theta);
+                               }
+/* This isn't accurate solid geometry, but it looks OK. */
+                       }
+                       rp->fuse = INTRAND(MINSFUSE, MAXSFUSE);
+               }
+       }
+       if (rp->state == BURSTINGINAIR) {
+               burst(mi, pp, rp);
+       }
+}
+
+static void
+shootup(ModeInfo * mi, pyrostruct * pp, rocket * rp)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       int         diff, h;
+
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi))
+               XSetForeground(display, gc, MI_NONE_COLOR(mi));
+       else
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       if (MI_IS_USE3D(mi)) {
+               diff = (int) GETZDIFF(rp->z);
+               XFillRectangle(display, window, gc, (int) (rp->x) + diff, (int) (rp->y),
+                              ROCKETW, ROCKETH + 3);
+               XFillRectangle(display, window, gc, (int) (rp->x) - diff, (int) (rp->y),
+                              ROCKETW, ROCKETH + 3);
+       } else
+               XFillRectangle(display, window, gc, (int) (rp->x), (int) (rp->y),
+                              ROCKETW, ROCKETH + 3);
+
+       if (rp->fuse-- <= 0) {
+               rp->state = BURSTINGINAIR;
+               return;
+       }
+       rp->x += rp->xvel;
+       rp->y += rp->yvel;
+       rp->yvel += pp->rockdecel;
+       if (MI_IS_USE3D(mi)) {
+               INCZ(rp->z, rp->zvel);
+               diff = (int) GETZDIFF(rp->z);
+               h = (int) (ROCKETH + NRAND(4));
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXor);
+               XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+               XFillRectangle(display, window, gc, (int) (rp->x) + diff, (int) (rp->y),
+                              ROCKETW, h);
+               XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               XFillRectangle(display, window, gc, (int) (rp->x) - diff, (int) (rp->y),
+                              ROCKETW, h);
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXcopy);
+       } else {
+               XSetForeground(display, gc, pp->rockpixel);
+               XFillRectangle(display, window, gc, (int) (rp->x), (int) (rp->y),
+                              ROCKETW, (int) (ROCKETH + NRAND(4)));
+       }
+}
+
+static void
+burst(ModeInfo * mi, pyrostruct * pp, rocket * rp)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       register int starn;
+       register int nstars, stype;
+       register float rx, ry, rz = 0.0, sd;    /* Help compiler optimize :-) */
+       register float sx, sy, sz;
+       int         diff;
+
+       nstars = rp->nstars;
+       stype = rp->shelltype;
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi))
+               XSetForeground(display, gc, MI_NONE_COLOR(mi));
+       else
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+
+       XFillRectangles(display, window, gc, rp->Xpoints[0], nstars);
+       if (stype & DOUBLECLOUD)
+               XFillRectangles(display, window, gc, rp->Xpoints[1], nstars);
+       if (MI_IS_USE3D(mi)) {
+               XFillRectangles(display, window, gc, rp->Xpointsleft[0], nstars);
+               if (stype & DOUBLECLOUD)
+                       XFillRectangles(display, window, gc, rp->Xpointsleft[1], nstars);
+       }
+       if (rp->fuse-- <= 0) {
+               rp->state = SILENT;
+               pp->nflying--;
+               return;
+       }
+/* Stagger the stars' decay */
+       if (rp->fuse <= 7) {
+               if ((rp->nstars = nstars = nstars * 90 / 100) == 0)
+                       return;
+       }
+       rx = rp->x;
+       ry = rp->y;
+       if (MI_IS_USE3D(mi)) {
+               rz = rp->z;
+       }
+       sd = pp->stardecel;
+       for (starn = 0; starn < nstars; starn++) {
+               sx = rp->stars[starn].sx += rp->stars[starn].sxvel;
+               sy = rp->stars[starn].sy += rp->stars[starn].syvel;
+               rp->stars[starn].syvel += sd;
+               if (MI_IS_USE3D(mi)) {
+                       if (rz + rp->stars[starn].sz + rp->stars[starn].szvel > MINZVAL)
+                               rp->stars[starn].sz += rp->stars[starn].szvel;
+                       sz = rp->stars[starn].sz;
+                       diff = (int) GETZDIFF(rz + sz);
+                       rp->Xpoints[0][starn].x = (int) (rx + sx + diff);
+                       rp->Xpointsleft[0][starn].x = (int) (rx + sx - diff);
+                       rp->Xpoints[0][starn].y =
+                               rp->Xpointsleft[0][starn].y = (int) (ry + sy);
+                       if (stype & DOUBLECLOUD) {
+                               rp->Xpoints[1][starn].x = (int) (rx + 1.7 * sx) + diff;
+                               rp->Xpointsleft[1][starn].x = (int) (rx + 1.7 * sx) - diff;
+                               rp->Xpoints[1][starn].y =
+                                       rp->Xpointsleft[1][starn].y = (int) (ry + 1.7 * sy);
+                       }
+               } else {
+
+                       rp->Xpoints[0][starn].x = (int) (rx + sx);
+                       rp->Xpoints[0][starn].y = (int) (ry + sy);
+                       if (stype & DOUBLECLOUD) {
+                               rp->Xpoints[1][starn].x = (int) (rx + 1.7 * sx);
+                               rp->Xpoints[1][starn].y = (int) (ry + 1.7 * sy);
+                       }
+               }
+       }
+       rp->x = rx + rp->xvel;
+       rp->y = ry + rp->yvel;
+       if (MI_IS_USE3D(mi)) {
+               rp->z = ADDZ(rz, rp->zvel);
+       }
+       rp->yvel += sd;
+
+       if (MI_IS_USE3D(mi)) {
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXor);
+               XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+               XFillRectangles(display, window, gc, rp->Xpoints[0], nstars);
+               if (stype & DOUBLECLOUD) {
+                       XFillRectangles(display, window, gc, rp->Xpoints[1], nstars);
+               }
+               XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               XFillRectangles(display, window, gc, rp->Xpointsleft[0], nstars);
+               if (stype & DOUBLECLOUD) {
+                       XFillRectangles(display, window, gc, rp->Xpointsleft[1], nstars);
+               }
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXcopy);
+       } else {
+
+               if ((stype & COLORCLOUD) && (MI_NPIXELS(mi) > 2)) {
+                       for (starn = 0; starn < nstars; starn++) {
+                               XSetForeground(display, gc, rp->stars[starn].color);
+                               XFillRectangle(display, window, gc,
+                                              rp->Xpoints[0][starn].x, rp->Xpoints[0][starn].y,
+                                              rp->Xpoints[0][starn].width, rp->Xpoints[0][starn].height);
+                       }
+               } else {
+                       XSetForeground(display, gc, rp->color[0]);
+                       XFillRectangles(display, window, gc, rp->Xpoints[0], nstars);
+               }
+               if (stype & DOUBLECLOUD) {
+                       XSetForeground(display, gc, rp->color[1]);
+                       XFillRectangles(display, window, gc, rp->Xpoints[1], nstars);
+               }
+       }
+}
+
+void
+init_pyro(ModeInfo * mi)
+{
+       pyrostruct *pp;
+       rocket     *rp;
+       int         rockn, starn;
+       int         size = MI_SIZE(mi);
+
+       if (pyros == NULL) {
+               if ((pyros = (pyrostruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (pyrostruct))) == NULL)
+                       return;
+       }
+       pp = &pyros[MI_SCREEN(mi)];
+
+       pp->width = MI_WIDTH(mi);
+       pp->height = MI_HEIGHT(mi);
+       pp->lmargin = pp->width / 16;
+       pp->rmargin = pp->width - pp->lmargin;
+
+       pp->nrockets = MI_COUNT(mi);
+       if (pp->nrockets < -MINROCKETS) {
+               if (pp->rockq) {
+                       (void) free((void *) pp->rockq);
+                       pp->rockq = NULL;
+               }
+               pp->nrockets = NRAND(-pp->nrockets - MINROCKETS + 1) + MINROCKETS;
+       } else if (pp->nrockets < MINROCKETS)
+               pp->nrockets = MINROCKETS;
+       if (size < -MINSIZE)
+               pp->star_size = NRAND(MIN(-size, MAX(MINSIZE,
+                 MIN(pp->width, pp->height) / 64)) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE) {
+               if (!size)
+                       pp->star_size = MAX(MINSIZE, MIN(pp->width, pp->height) / 64);
+               else
+                       pp->star_size = MINSIZE;
+       } else
+               pp->star_size = MIN(size, MAX(MINSIZE, MIN(pp->width, pp->height) / 64));
+       orig_p_ignite = P_IGNITE / pp->nrockets;
+       if (orig_p_ignite <= 0)
+               orig_p_ignite = 1;
+       pp->p_ignite = orig_p_ignite;
+
+       if (!pp->rockq) {
+               pp->rockq = (rocket *) malloc(pp->nrockets * sizeof (rocket));
+       }
+       pp->nflying = pp->fusilcount = 0;
+
+       for (rockn = 0, rp = pp->rockq; rockn < pp->nrockets; rockn++, rp++) {
+               rp->state = SILENT;
+               for (starn = 0; starn < MAXSTARS; starn++) {
+                       rp->Xpoints[0][starn].width = rp->Xpoints[0][starn].height =
+                               rp->Xpoints[1][starn].width = rp->Xpoints[1][starn].height =
+                               pp->star_size;
+                       if (MI_IS_USE3D(mi)) {
+                               rp->Xpointsleft[0][starn].width = rp->Xpointsleft[0][starn].height =
+                                       rp->Xpointsleft[1][starn].width = rp->Xpointsleft[1][starn].height =
+                                       pp->star_size;
+                       }
+               }
+       }
+
+       if (MI_NPIXELS(mi) > 3)
+               pp->rockpixel = MI_PIXEL(mi, ORANGE);
+       else
+               pp->rockpixel = MI_WHITE_PIXEL(mi);
+
+/* Geometry-dependent physical data: */
+       pp->maxvelx = (float) (pp->width) * XVELFACTOR;
+       pp->minvelx = -pp->maxvelx;
+       pp->minvely = -(float) (pp->height) * MINYVELFACTOR;
+       pp->maxvely = -(float) (pp->height) * MAXYVELFACTOR;
+       if (MI_IS_USE3D(mi)) {
+               pp->maxvelz = (float) (MAXZVALSTART - MINZVALSTART) * ZVELFACTOR;
+               pp->minvelz = -pp->maxvelz;
+       }
+       pp->maxsvel = pp->minvely * SVELFACTOR;
+       pp->rockdecel = (float) (pp->height) * GRAVFACTOR;
+       pp->stardecel = pp->rockdecel * BOUYANCY;
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+/* ARGSUSED */
+void
+draw_pyro(ModeInfo * mi)
+{
+       pyrostruct *pp = &pyros[MI_SCREEN(mi)];
+       rocket     *rp;
+       int         rockn;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (just_started || (NRAND(pp->p_ignite) == 0)) {
+               just_started = False;
+               if (NRAND(P_FUSILLADE) == 0) {
+                       pp->p_ignite = orig_p_ignite / FUSILFACTOR;
+                       if (pp->p_ignite <= 0)
+                               pp->p_ignite = 1;
+                       pp->fusilcount = INTRAND(FUSILLEN * 9 / 10, FUSILLEN * 11 / 10);
+               }
+               ignite(mi, pp);
+               if (pp->fusilcount > 0) {
+                       if (--pp->fusilcount == 0)
+                               pp->p_ignite = orig_p_ignite;
+               }
+       }
+       for (rockn = pp->nflying, rp = pp->rockq; rockn > 0; rp++) {
+               if (rp->state != SILENT) {
+                       animate(mi, pp, rp);
+                       rockn--;
+               }
+       }
+}
+
+void
+release_pyro(ModeInfo * mi)
+{
+       if (pyros != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       pyrostruct *pp = &pyros[screen];
+
+                       if (pp->rockq != NULL) {
+                               (void) free((void *) pp->rockq);
+                       }
+               }
+               (void) free((void *) pyros);
+               pyros = NULL;
+       }
+}
+
+void
+refresh_pyro(ModeInfo * mi)
+{
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+#endif /* MODE_pyro */
diff --git a/xlockmore-4.14/modes/qix.c b/xlockmore-4.14/modes/qix.c
new file mode 100644 (file)
index 0000000..1801931
--- /dev/null
@@ -0,0 +1,397 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* qix --- vector swirl */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)qix.c        4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 03-Mar-98: Combined with Darrick Brown's "geometry".
+ * 10-May-97: Compatible with xscreensaver
+ * 29-Jul-90: support for multiple screens.
+ *           made check_bounds_?() a macro.
+ *           fixed initial parameter setup.
+ * 15-Dec-89: Fix for proper skipping of {White,Black}Pixel() in colors.
+ * 08-Oct-89: Fixed bug in memory allocation in init_qix().
+ *           Moved seconds() to an extern.
+ * 23-Sep-89: Switch to random() and fixed bug w/ less than 4 lines.
+ * 20-Sep-89: Lint.
+ * 24-Mar-89: Written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Qix"
+#define HACK_INIT init_qix
+#define HACK_DRAW draw_qix
+#define qix_opts xlockmore_opts
+#define DEFAULTS "*delay: 30000 \n" \
+ "*count: -5 \n" \
+ "*cycles: 32 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_qix
+
+#define DEF_COMPLETE  "False"
+#define DEF_KALEID  "False"
+
+static Bool complete;
+static Bool kaleid;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-complete", ".qix.complete", XrmoptionNoArg, (caddr_t) "on"},
+       {"+complete", ".qix.complete", XrmoptionNoArg, (caddr_t) "off"},
+       {"-kaleid", ".qix.kaleid", XrmoptionNoArg, (caddr_t) "on"},
+       {"+kaleid", ".qix.kaleid", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+      {(caddr_t *) & complete, "complete", "Complete", DEF_COMPLETE, t_Bool},
+       {(caddr_t *) & kaleid, "kaleid", "Kaleid", DEF_KALEID, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+complete", "turn on/off complete morphing graph"},
+       {"-/+kaleid", "turn on/off complete kaleidoscope"}
+};
+
+ModeSpecOpt qix_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   qix_description =
+{"qix", "init_qix", "draw_qix", "release_qix",
+ "refresh_qix", "init_qix", NULL, &qix_opts,
+ 30000, -5, 32, 1, 64, 1.0, "",
+ "Shows spinning lines a la Qix(tm)", 0, NULL};
+
+#endif
+
+/* How many segments to draw per cycle when redrawing */
+#define REDRAWSTEP 3
+#define MINPOINTS 2
+/*-
+ * remember when complete: the number of lines to be drawn is 1+2+3+...+N or
+ * N(N+1)/2
+ */
+
+/* I forget now, did Newton discover this as a boy? */
+#define NEWT(n) (n*(n+1)/2)
+
+typedef struct {
+       int         pix;
+       int         first, last;
+       XPoint     *delta, *position;
+       int         npoints;
+       int         offset;
+       int         max_delta;
+       int         width, height, mid, midx, midy;
+       int         nlines, linecount;
+       int         redrawing, redrawpos;
+       XPoint     *lineq;
+       Bool        complete;
+       Bool        kaleid;
+} qixstruct;
+
+static qixstruct *qixs = NULL;
+
+#define check_bounds(qp, val, del, min, max)                           \
+{                                                              \
+    if ((val) < (min)) {                                               \
+       *(del) = NRAND((qp)->max_delta) + (qp)->offset; \
+    } else if ((val) >= (max)) {                                       \
+       *(del) = -(NRAND((qp)->max_delta)) - (qp)->offset;      \
+    }                                                          \
+}
+
+void
+init_qix(ModeInfo * mi)
+{
+       qixstruct  *qp;
+       int         i;
+
+       if (qixs == NULL) {
+               if ((qixs = (qixstruct *) calloc(MI_NUM_SCREENS(mi),
+                                                sizeof (qixstruct))) == NULL)
+                       return;
+       }
+       qp = &qixs[MI_SCREEN(mi)];
+
+       qp->width = MI_WIDTH(mi);
+       qp->height = MI_HEIGHT(mi);
+       qp->mid = MAX(qp->width, qp->height) / 2;
+       qp->midx = qp->width / 2;
+       qp->midy = qp->height / 2;
+       qp->max_delta = 16;
+       qp->redrawing = 0;
+       qp->linecount = 0;
+
+       if (qp->width < 100) {  /* icon window */
+               qp->max_delta /= 4;
+       }
+       qp->offset = qp->max_delta / 3;
+       qp->last = 0;
+       if (MI_NPIXELS(mi) > 2)
+               qp->pix = NRAND(MI_NPIXELS(mi));
+
+       qp->npoints = MI_COUNT(mi);
+       if (qp->npoints < -MINPOINTS)
+               qp->npoints = NRAND(qp->npoints - MINPOINTS + 1) + MINPOINTS;
+       /* Absolute minimum */
+       if (qp->npoints < MINPOINTS)
+               qp->npoints = MINPOINTS;
+
+       if (MI_IS_FULLRANDOM(mi))
+               qp->complete = (Bool) (LRAND() & 1);
+       else
+               qp->complete = complete;
+
+       if (qp->complete) {
+               qp->kaleid = False;
+       } else {
+               if (MI_IS_FULLRANDOM(mi))
+                       qp->kaleid = (Bool) (LRAND() & 1);
+               else
+                       qp->kaleid = kaleid;
+       }
+       if (qp->delta)
+               (void) free((void *) qp->delta);
+       if (qp->position)
+               (void) free((void *) qp->position);
+
+       qp->delta = (XPoint *) malloc(qp->npoints * sizeof (XPoint));
+       qp->position = (XPoint *) malloc(qp->npoints * sizeof (XPoint));
+       for (i = 0; i < qp->npoints; i++) {
+               qp->delta[i].x = NRAND(qp->max_delta) + qp->offset;
+               qp->delta[i].y = NRAND(qp->max_delta) + qp->offset;
+               qp->position[i].x = NRAND(qp->width);
+               qp->position[i].y = NRAND(qp->height);
+       }
+
+       qp->nlines = (qp->npoints == 2) ? (MI_CYCLES(mi) + 1) * 2 :
+               ((MI_CYCLES(mi) + qp->npoints) / qp->npoints) * qp->npoints;
+       if (qp->complete) {
+               qp->max_delta /= 4;
+               qp->nlines = qp->npoints;
+       }
+       if (qp->kaleid) {
+               qp->nlines = MI_CYCLES(mi) * 16;        /* Fudge it so its compatible */
+       }
+       if (qp->lineq) {
+               (void) free((void *) qp->lineq);
+               qp->lineq = NULL;
+       }
+       if (!qp->kaleid) {
+               qp->lineq = (XPoint *) malloc(qp->nlines * sizeof (XPoint));
+               for (i = 0; i < qp->nlines; i++)
+                       qp->lineq[i].x = qp->lineq[i].y = -1;   /* move initial point off screen */
+       }
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_qix(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       qixstruct  *qp = &qixs[MI_SCREEN(mi)];
+       int         i, j, k, l;
+
+       qp->first = (qp->last + qp->npoints) % qp->nlines;
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < qp->npoints; i++) {
+               qp->position[i].x += qp->delta[i].x;
+               qp->position[i].y += qp->delta[i].y;
+               if (NRAND(20) < 1) {
+                       check_bounds(qp, qp->position[i].x, &qp->delta[i].x,
+                                    qp->width / 3, 2 * qp->width / 3);
+               } else {
+                       check_bounds(qp, qp->position[i].x, &qp->delta[i].x, 0, qp->width);
+               }
+               if (NRAND(20) < 1) {
+                       check_bounds(qp, qp->position[i].y, &qp->delta[i].y,
+                                    qp->height / 3, 2 * qp->height / 3);
+               } else {
+                       check_bounds(qp, qp->position[i].y, &qp->delta[i].y, 0, qp->height);
+               }
+       }
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       if (qp->complete && qp->npoints > 3) {
+               for (i = 0; i < qp->npoints - 1; i++)
+                       for (j = i + 1; j < qp->npoints; j++)
+                               XDrawLine(display, MI_WINDOW(mi), gc,
+                                         qp->lineq[qp->first + i].x, qp->lineq[qp->first + i].y,
+                                         qp->lineq[qp->first + j].x, qp->lineq[qp->first + j].y);
+       } else if (!qp->kaleid) {
+               for (i = 1; i < qp->npoints + ((qp->npoints == 2) ? -1 : 0); i++)
+                       XDrawLine(display, MI_WINDOW(mi), gc,
+                                 qp->lineq[qp->first + i - 1].x, qp->lineq[qp->first + i - 1].y,
+                                 qp->lineq[qp->first + i].x, qp->lineq[qp->first + i].y);
+               XDrawLine(display, MI_WINDOW(mi), gc,
+                         qp->lineq[qp->first].x, qp->lineq[qp->first].y,
+                         qp->lineq[qp->first + qp->npoints - 1].x,
+                         qp->lineq[qp->first + qp->npoints - 1].y);
+       }
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, qp->pix));
+               if (++qp->pix >= MI_NPIXELS(mi))
+                       qp->pix = 0;
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       if (qp->complete && qp->npoints > 3) {
+               for (i = 0; i < qp->npoints - 1; i++)
+                       for (j = i + 1; j < qp->npoints; j++)
+                               XDrawLine(display, MI_WINDOW(mi), gc,
+                                       qp->position[i].x, qp->position[i].y,
+                                      qp->position[j].x, qp->position[j].y);
+       } else if (qp->kaleid) {
+               for (i = 0; i < qp->npoints; i++) {
+                       XSegment    segs[8];
+                       XPoint      small[2];
+
+                       j = (i + 1) % qp->npoints;
+                       small[0].x = ABS(qp->position[i].x - qp->mid);
+                       small[0].y = ABS(qp->position[i].y - qp->mid);
+                       small[1].x = ABS(qp->position[j].x - qp->mid);
+                       small[1].y = ABS(qp->position[j].y - qp->mid);
+                       segs[0].x1 = qp->midx + small[0].x;
+                       segs[0].y1 = qp->midy + small[0].y;
+                       segs[0].x2 = qp->midx + small[1].x;
+                       segs[0].y2 = qp->midy + small[1].y;
+                       segs[1].x1 = qp->midx - small[0].x;
+                       segs[1].y1 = qp->midy + small[0].y;
+                       segs[1].x2 = qp->midx - small[1].x;
+                       segs[1].y2 = qp->midy + small[1].y;
+                       segs[2].x1 = qp->midx - small[0].x;
+                       segs[2].y1 = qp->midy - small[0].y;
+                       segs[2].x2 = qp->midx - small[1].x;
+                       segs[2].y2 = qp->midy - small[1].y;
+                       segs[3].x1 = qp->midx + small[0].x;
+                       segs[3].y1 = qp->midy - small[0].y;
+                       segs[3].x2 = qp->midx + small[1].x;
+                       segs[3].y2 = qp->midy - small[1].y;
+                       segs[4].x1 = qp->midx + small[0].y;
+                       segs[4].y1 = qp->midy + small[0].x;
+                       segs[4].x2 = qp->midx + small[1].y;
+                       segs[4].y2 = qp->midy + small[1].x;
+                       segs[5].x1 = qp->midx + small[0].y;
+                       segs[5].y1 = qp->midy - small[0].x;
+                       segs[5].x2 = qp->midx + small[1].y;
+                       segs[5].y2 = qp->midy - small[1].x;
+                       segs[6].x1 = qp->midx - small[0].y;
+                       segs[6].y1 = qp->midy - small[0].x;
+                       segs[6].x2 = qp->midx - small[1].y;
+                       segs[6].y2 = qp->midy - small[1].x;
+                       segs[7].x1 = qp->midx - small[0].y;
+                       segs[7].y1 = qp->midy + small[0].x;
+                       segs[7].x2 = qp->midx - small[1].y;
+                       segs[7].y2 = qp->midy + small[1].x;
+                       XDrawSegments(display, MI_WINDOW(mi), gc, segs, 8);
+                       if (qp->npoints == 2)   /* do not repeat drawing the same line */
+                               break;
+               }
+               if (++qp->linecount >= qp->nlines) {
+                       qp->linecount = 0;
+                       MI_CLEARWINDOW(mi);
+               }
+       } else {
+               for (i = 1; i < qp->npoints + ((qp->npoints == 2) ? -1 : 0); i++)
+                       XDrawLine(display, MI_WINDOW(mi), gc,
+                               qp->position[i - 1].x, qp->position[i - 1].y,
+                                 qp->position[i].x, qp->position[i].y);
+               XDrawLine(display, MI_WINDOW(mi), gc, qp->position[0].x, qp->position[0].y,
+                         qp->position[qp->npoints - 1].x, qp->position[qp->npoints - 1].y);
+       }
+
+       if (!qp->kaleid)
+               for (i = 0; i < qp->npoints; i++) {
+                       qp->lineq[qp->last].x = qp->position[i].x;
+                       qp->lineq[qp->last].y = qp->position[i].y;
+                       qp->last++;
+                       if (qp->last >= qp->nlines)
+                               qp->last = 0;
+               }
+       if (qp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       j = (qp->first - qp->redrawpos + qp->nlines - qp->npoints) % qp->nlines;
+                       if (qp->complete && qp->npoints > 3) {
+                               for (k = 0; k < qp->npoints - 1; k++)
+                                       for (l = k + 1; l < qp->npoints; l++)
+                                               XDrawLine(display, MI_WINDOW(mi), gc,
+                                                         qp->lineq[j + k].x, qp->lineq[j + k].y,
+                                                         qp->lineq[j + l].x, qp->lineq[j + l].y);
+                       } else if (!qp->kaleid) {
+                               for (k = 1; k < qp->npoints + ((qp->npoints == 2) ? -1 : 0); k++)
+                                       XDrawLine(display, MI_WINDOW(mi), gc,
+                                                 qp->lineq[j + k - 1].x, qp->lineq[j + k - 1].y,
+                                                 qp->lineq[j + k].x, qp->lineq[j + k].y);
+                               XDrawLine(display, MI_WINDOW(mi), gc,
+                                         qp->lineq[j].x, qp->lineq[j].y,
+                                         qp->lineq[j + qp->npoints - 1].x, qp->lineq[j + qp->npoints - 1].y);
+                       }
+                       qp->redrawpos += qp->npoints;
+                       if (qp->redrawpos >= qp->nlines - qp->npoints) {
+                               qp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+void
+release_qix(ModeInfo * mi)
+{
+       if (qixs != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       qixstruct  *qp = &qixs[screen];
+
+                       if (qp->lineq)
+                               (void) free((void *) qp->lineq);
+                       if (qp->delta)
+                               (void) free((void *) qp->delta);
+                       if (qp->position)
+                               (void) free((void *) qp->position);
+               }
+               (void) free((void *) qixs);
+               qixs = NULL;
+       }
+}
+
+void
+refresh_qix(ModeInfo * mi)
+{
+       qixstruct  *qp = &qixs[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+       qp->redrawing = 1;
+       qp->redrawpos = 0;
+}
+
+#endif /* MODE_qix */
diff --git a/xlockmore-4.14/modes/random.c b/xlockmore-4.14/modes/random.c
new file mode 100644 (file)
index 0000000..f52fd0b
--- /dev/null
@@ -0,0 +1,933 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* random --- run random modes for a certain duration */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)random.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Made more compatible with xscreensaver :)
+ * 18-Mar-96: Ron Hitchens <ron@idiom.com>
+ *             Re-coded for the ModeInfo calling scheme.  Added the
+ *             change hook.  Get ready for 3.8 release.
+ * 23-Dec-95: Ron Hitchens <ron@idiom.com>
+ *             Re-coded pickMode() to keep track of the modes, so
+ *             that all modes are tried before there are any repeats.
+ *             Also prevent a mode from being picked twice in a row
+ *             (could happen as first pick after refreshing the list).
+ * 04-Sep-95: Written by Heath A. Kehoe <hakehoe@icaen.uiowa.edu>.
+ *
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Random"
+#define HACK_INIT init_random
+#define HACK_DRAW draw_random
+#define random_opts xlockmore_opts
+#define DEFAULTS "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#include "util.h"
+#endif /* STANDALONE */
+
+#define DEF_DURATION   "60"    /* 0 == infinite duration */
+#define DEF_MODELIST   ""
+#define DEF_SEQUENTIAL "False"
+#define DEF_FULLRANDOM "True"
+
+static int  duration;
+static char *modelist;
+static Bool sequential;
+extern Bool fullrandom;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-duration", ".random.duration", XrmoptionSepArg, (caddr_t) NULL},
+       {"-modelist", ".random.modelist", XrmoptionSepArg, (caddr_t) NULL},
+       {"-sequential", ".random.sequential", XrmoptionNoArg, (caddr_t) "on"},
+      {"+sequential", ".random.sequential", XrmoptionNoArg, (caddr_t) "off"},
+       {"-sequential", ".random.sequential", XrmoptionNoArg, (caddr_t) "on"},
+      {"+sequential", ".random.sequential", XrmoptionNoArg, (caddr_t) "off"},
+       {"-fullrandom", ".random.fullrandom", XrmoptionNoArg, (caddr_t) "on"},
+       {"+fullrandom", ".random.fullrandom", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & duration, "duration", "Duration", DEF_DURATION, t_Int},
+    {(caddr_t *) & modelist, "modelist", "Modelist", DEF_MODELIST, t_String},
+       {(caddr_t *) & sequential, "sequential", "Sequential", DEF_SEQUENTIAL, t_Bool},
+{(caddr_t *) & fullrandom, "fullrandom", "FullRandom", DEF_FULLRANDOM, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-duration num", "how long a mode runs before changing to another"},
+       {"-modelist string", "list of modes to randomly choose from"},
+       {"-/+sequential", "turn on/off picking of modes sequentially"},
+       {"-/+fullrandom", "turn on/off full random choice of mode-options"}
+};
+
+ModeSpecOpt random_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   random_description =
+{"random", "init_random", "draw_random", "release_random",
+ "refresh_random", "change_random", NULL, &random_opts,
+ 1, 1, 1, 1, 64, 1.0, "",
+#ifdef USE_BOMB
+ "Shows a random mode from above except blank and bomb", 0, NULL};
+
+#else
+ "Shows a random mode from above except blank", 0, NULL};
+
+#endif
+
+#endif
+
+#ifdef USE_BOMB
+#define NUMSPECIAL     3       /* bomb, blank, random */
+#else
+#define NUMSPECIAL     2       /* blank, random */
+#endif
+
+#define GC_SAVE_VALUES (GCFunction|GCLineWidth|GCLineStyle|GCCapStyle|GCJoinStyle|GCGraphicsExposures|GCFont|GCSubwindowMode)
+
+extern int  startscreen;
+extern int  delay;
+extern int  count;
+extern int  cycles;
+extern int  size;
+extern int  ncolors;
+extern float saturation;
+extern char *bitmap;
+
+#define MAXMODECHARS 14
+
+#ifdef USE_GL
+static char gl_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_atlantis
+       "atlantis",
+#endif
+#ifdef MODE_bubble3d
+       "bubble3d",
+#endif
+#ifdef MODE_cage
+  "cage",
+#endif
+#ifdef MODE_gears
+  "gears",
+#endif
+#ifdef MODE_invert
+       "invert", 
+#endif
+#ifdef MODE_lament
+       "lament", 
+#endif
+#ifdef MODE_moebius
+       "moebius", 
+#endif
+#ifdef MODE_morph3d
+       "morph3d", 
+#endif
+#ifdef MODE_pipes
+       "pipes", 
+#endif
+#ifdef MODE_rubik
+       "rubik", 
+#endif
+#ifdef MODE_sproingies
+       "sproingies", 
+#endif
+#ifdef MODE_stairs
+       "stairs", 
+#endif
+#ifdef MODE_superquadrics
+       "superquadrics", 
+#endif
+#ifdef MODE_text3d
+       "text3d"
+#endif
+};
+
+#define NUMGL (int) (sizeof (gl_modes) / sizeof (gl_modes[0]))
+#else
+static char gl_modes[][MAXMODECHARS] =
+{""};
+
+#define NUMGL 0
+#endif
+
+static char xpm_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_bat
+       "bat",
+#endif
+#ifdef MODE_cartoon
+       "cartoon",
+#endif
+#ifdef MODE_image
+       "image",
+#endif
+#ifdef MODE_flag
+       "flag",
+#endif
+#ifdef MODE_life
+       "life",
+#endif
+#ifdef MODE_life1d
+       "life1d",
+#endif
+#ifdef MODE_maze
+       "maze",
+#endif
+#ifdef MODE_puzzle
+       "puzzle"
+#endif
+};
+
+#define NUMXPM (int) (sizeof (xpm_modes) / sizeof (xpm_modes[0]))
+
+static char write_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_crystal
+       "crystal",
+#endif
+#ifdef MODE_mandelbrot
+       "mandelbrot",
+#endif
+#ifdef MODE_starfish
+       "starfish",
+#endif
+#ifdef MODE_swirl
+       "swirl",
+#endif
+#ifdef MODE_tetris
+       "tetris",
+#endif
+#ifdef MODE_tube
+       "tube"
+#endif
+       /* XPM modes are usually writable too ... */
+};
+
+#define NUMWRITE (int) (sizeof (write_modes) / sizeof (write_modes[0]))
+
+static char nice_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_blot
+       "blot",
+#endif
+#ifdef MODE_bouboule
+       "bouboule",
+#endif
+#ifdef MODE_bug
+       "bug",
+#endif
+#ifdef MODE_clock
+       "clock",
+#endif
+#ifdef MODE_crystal
+       "crystal",
+#endif
+#ifdef MODE_daisy
+       "daisy",
+#endif
+#ifdef MODE_dclock
+       "dclock",
+#endif
+#ifdef MODE_demon
+       "demon",
+#endif
+#ifdef MODE_deco
+       "deco",
+#endif
+#ifdef MODE_eyes
+       "eyes",
+#endif
+#ifdef MODE_fadeplot
+       "fadeplot",
+#endif
+#ifdef MODE_flag
+       "flag",
+#endif
+#ifdef MODE_flame
+       "flame",
+#endif
+#ifdef MODE_grav
+       "grav",
+#endif
+#ifdef MODE_helix
+       "helix",
+#endif
+#ifdef MODE_hyper
+       "hyper",
+#endif
+#ifdef MODE_ico
+       "ico",
+#endif
+#ifdef MODE_image
+       "image",
+#endif
+#ifdef MODE_kaleid
+       "kaleid",
+#endif
+#ifdef MODE_laser
+  "laser",
+#endif
+#ifdef MODE_life
+  "life",
+#endif
+#ifdef MODE_life1d
+  "life1d",
+#endif
+#ifdef MODE_life3d
+  "life3d",
+#endif
+#ifdef MODE_lightning
+  "lightning",
+#endif
+#ifdef MODE_lisa
+  "lisa",
+#endif
+#ifdef MODE_lissie
+  "lissie",
+#endif
+#ifdef MODE_loop
+  "loop",
+#endif
+#ifdef MODE_marquee
+       "marquee",
+#endif
+#ifdef MODE_nose
+       "nose",
+#endif
+#ifdef MODE_penrose
+       "penrose",
+#endif
+#ifdef MODE_petal
+       "petal",
+#endif
+#ifdef MODE_puzzle
+       "puzzle",
+#endif
+#ifdef MODE_pyro
+       "pyro",
+#endif
+#ifdef MODE_qix
+       "qix",
+#endif
+#ifdef MODE_roll
+       "roll",
+#endif
+#ifdef MODE_rotor
+       "rotor",
+#endif
+#ifdef MODE_shape
+       "shape",
+#endif
+#ifdef MODE_sierpinski
+       "sierpinski",
+#endif
+#ifdef MODE_spline
+       "spline",
+#endif
+#ifdef MODE_star
+       "star",
+#endif
+#ifdef MODE_swarm
+       "swarm",
+#endif
+#ifdef MODE_triangle
+       "triangle",
+#endif
+#ifdef MODE_tube
+       "tube",
+#endif
+#ifdef MODE_turtle
+       "turtle",
+#endif
+#ifdef MODE_vines
+       "vines",
+#endif
+#ifdef MODE_voters
+       "voters",
+#endif
+#ifdef MODE_wire
+       "wire",
+#endif
+#ifdef MODE_world
+       "world",
+#endif
+#ifdef MODE_worm
+       "worm", 
+#endif
+#ifdef MODE_xjack
+       "xjack"
+#endif
+};
+
+#define NUMNICE (int) (sizeof (nice_modes) / sizeof (nice_modes[0]))
+
+static char use3d_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_bouboule
+       "bouboule",
+#endif
+#ifdef MODE_hyper
+       "hyper",
+#endif
+#ifdef MODE_pyro
+       "pyro",
+#endif
+#ifdef MODE_star
+       "star",
+#endif
+#ifdef MODE_worm
+       "worm"
+#endif
+};
+
+#define NUMUSE3D (int) (sizeof (use3d_modes) / sizeof (use3d_modes[0]))
+
+static char mouse_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_eyes
+       "eyes",
+#endif
+#ifdef MODE_julia
+       "julia",
+#endif
+#ifdef MODE_swarm
+       "swarm"
+#endif
+};
+
+#define NUMMOUSE (int) (sizeof (mouse_modes) / sizeof (mouse_modes[0]))
+
+static char automata_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_ant
+       "ant",
+#endif
+#ifdef MODE_bug
+       "bug",
+#endif
+#ifdef MODE_demon
+       "demon",
+#endif
+#ifdef MODE_dilemma
+       "dilemma",
+#endif
+#ifdef MODE_life
+       "life",
+#endif
+#ifdef MODE_life1d
+       "life1d",
+#endif
+#ifdef MODE_life3d
+       "life3d",
+#endif
+#ifdef MODE_loop
+       "loop",
+#endif
+#ifdef MODE_voters
+       "voters",
+#endif
+#ifdef MODE_wator
+       "wator",
+#endif
+#ifdef MODE_wire
+       "wire"
+#endif
+};
+
+#define NUMAUTOMATA (int) (sizeof (automata_modes) / sizeof (automata_modes[0]))
+
+static char fractal_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_coral
+       "coral",
+#endif
+#ifdef MODE_discrete
+       "discrete",
+#endif
+#ifdef MODE_drift
+       "drift",
+#endif
+#ifdef MODE_flame
+       "flame",
+#endif
+#ifdef MODE_flow
+       "flow",
+#endif
+#ifdef MODE_forest
+       "forest",
+#endif
+#ifdef MODE_julia
+       "julia",
+#endif
+#ifdef MODE_hop
+       "hop",
+#endif
+#ifdef MODE_ifs
+       "ifs",
+#endif
+#ifdef MODE_lightning
+       "lightning",
+#endif
+#ifdef MODE_mandelbrot
+       "mandelbrot",
+#endif
+#ifdef MODE_mountain
+       "mountain",
+#endif
+#ifdef MODE_sierpinski
+       "sierpinski",
+#endif
+#ifdef MODE_strange
+       "strange",
+#endif
+#ifdef MODE_thornbird
+       "thornbird",
+#endif
+#ifdef MODE_triangle
+       "triangle",
+#endif
+#ifdef MODE_turtle
+       "turtle",
+#endif
+#ifdef MODE_vines
+       "vines"
+#endif
+};
+
+#define NUMFRACTAL (int) (sizeof (fractal_modes) / sizeof (fractal_modes[0]))
+
+
+static char geometry_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_braid
+       "braid",
+#endif
+#ifdef MODE_fadeplot
+       "fadeplot",
+#endif
+#ifdef MODE_helix
+       "helix",
+#endif
+#ifdef MODE_hyper
+       "hyper",
+#endif
+#ifdef MODE_ico
+       "ico",
+#endif
+#ifdef MODE_kaleid
+       "kaleid",
+#endif
+#ifdef MODE_laser
+       "laser",
+#endif
+#ifdef MODE_lisa
+       "lisa",
+#endif
+#ifdef MODE_lissie
+       "lissie",
+#endif
+#ifdef MODE_penrose
+       "penrose",
+#endif
+#ifdef MODE_petal
+       "petal",
+#endif
+#ifdef MODE_qix
+       "qix",
+#endif
+#ifdef MODE_shape
+       "shape",
+#endif
+#ifdef MODE_sphere
+       "sphere",
+#endif
+#ifdef MODE_spiral
+       "spiral",
+#endif
+#ifdef MODE_spline
+       "spline"
+#endif
+};
+
+#define NUMGEOMETRY (int) (sizeof (geometry_modes) / sizeof (geometry_modes[0]))
+
+static char space_modes[][MAXMODECHARS] =
+{
+#ifdef MODE_bouboule
+       "bouboule",
+#endif
+#ifdef MODE_galaxy
+       "galaxy",
+#endif
+#ifdef MODE_grav
+       "grav",
+#endif
+#ifdef MODE_star
+       "star",
+#endif
+#ifdef MODE_world
+       "world"
+#endif
+};
+
+#define NUMSPACE (int) (sizeof (space_modes) / sizeof (space_modes[0]))
+
+typedef struct {
+       XGCValues   gcvs;
+       int         fix;
+} randomstruct;
+
+static int  currentmode = -1;
+static int  previousmode = -1;
+static unsigned long starttime;
+static int *modes;
+static int  nmodes;
+static Bool change_now = False;
+
+static randomstruct *randoms;
+
+static int
+pickMode(void)
+{
+       static int *mode_indexes = NULL;
+       static int  mode_count = 0;
+       static int  last_mode = -1, last_index = -1;
+       int         mode, i;
+
+       if (mode_indexes == NULL) {
+               if ((mode_indexes = (int *) calloc(nmodes, sizeof (int))) ==
+                   NULL) {
+                       if (sequential)
+                               return modes[0];
+                       else
+                               return modes[NRAND(nmodes)];
+               }
+       }
+       if (mode_count == 0) {
+               for (i = 0; i < nmodes; i++) {
+                       mode_indexes[i] = modes[i];
+               }
+               mode_count = nmodes;
+       }
+       if (mode_count == 1) {
+               /* only one left, let's use that one */
+               last_index = -1;
+               return (last_mode = mode_indexes[--mode_count]);
+       } else {
+               /* pick a random slot in the list, check for last */
+               if (sequential) {
+                       last_index = i = (last_index + 1) % nmodes;
+               } else
+                       while (mode_indexes[i = NRAND(mode_count)] == last_mode);
+       }
+
+       mode = mode_indexes[i]; /* copy out chosen mode */
+       /* move mode at end of list to slot vacated by chosen mode, dec count */
+       mode_indexes[i] = mode_indexes[--mode_count];
+       return (last_mode = mode);      /* remember last mode picked */
+}
+
+static
+char       *
+strpmtok(int *sign, char *str)
+{
+       static int  nextsign = 0;
+       static char *loc;
+       char       *p, *r;
+
+       if (str)
+               loc = str;
+       if (nextsign) {
+               *sign = nextsign;
+               nextsign = 0;
+       }
+       p = loc - 1;
+       for (;;) {
+               switch (*++p) {
+                       case '+':
+                               *sign = 1;
+                               continue;
+                       case '-':
+                               *sign = -1;
+                               continue;
+                       case ' ':
+                       case ',':
+                       case '\t':
+                       case '\n':
+                               continue;
+                       case 0:
+                               loc = p;
+                               return NULL;
+               }
+               break;
+       }
+       r = p;
+
+       for (;;) {
+               switch (*++p) {
+                       case '+':
+                               nextsign = 1;
+                               break;
+                       case '-':
+                               nextsign = -1;
+                               break;
+                       case ' ':
+                       case ',':
+                       case '\t':
+                       case '\n':
+                       case 0:
+                               break;
+                       default:
+                               continue;
+               }
+               break;
+       }
+       if (*p) {
+               *p = 0;
+               loc = p + 1;
+       } else
+               loc = p;
+
+       return r;
+}
+
+static void
+parsemodelist(ModeInfo * mi)
+{
+       int         i, sign = 1, j;
+       char       *p;
+
+       modes = (int *) calloc(numprocs - 1, sizeof (int));
+
+       p = strpmtok(&sign, (modelist) ? modelist : "");
+
+       while (p) {
+               if (!strcmp(p, "all")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allgl")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMGL; j++)
+                                       if (!strcmp(gl_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allxpm")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMXPM; j++)
+                                       if (!strcmp(xpm_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allwrite")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMWRITE; j++)
+                                       if (!strcmp(write_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allnice")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMNICE; j++)
+                                       if (!strcmp(nice_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "all3d")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMUSE3D; j++)
+                                       if (!strcmp(use3d_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allmouse")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMMOUSE; j++)
+                                       if (!strcmp(mouse_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allautomata")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMAUTOMATA; j++)
+                                       if (!strcmp(automata_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allfractal")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMFRACTAL; j++)
+                                       if (!strcmp(fractal_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allgeometry")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMGEOMETRY; j++)
+                                       if (!strcmp(geometry_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else if (!strcmp(p, "allspace")) {
+                       for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                               for (j = 0; j < NUMSPACE; j++)
+                                       if (!strcmp(space_modes[j], LockProcs[i].cmdline_arg))
+                                               modes[i] = (sign > 0);
+               } else {
+                       for (i = 0; i < numprocs - 1; i++)
+                               if (!strcmp(p, LockProcs[i].cmdline_arg))
+                                       break;
+                       if (i < numprocs - 1)
+                               modes[i] = (sign > 0);
+                       else
+                               (void) fprintf(stderr, "unrecognized mode \"%s\"\n", p);
+               }
+               p = strpmtok(&sign, (char *) NULL);
+       }
+
+       nmodes = 0;
+       for (i = 0; i < numprocs - 1; i++)
+               if (modes[i])
+                       modes[nmodes++] = i;
+       if (!nmodes) {          /* empty list */
+               for (i = 0; i < numprocs - NUMSPECIAL; i++)
+                       modes[i] = i;
+               nmodes = i;
+       }
+       if (MI_IS_DEBUG(mi)) {
+               (void) fprintf(stderr, "%d mode%s: ", nmodes, ((nmodes == 1) ? "" : "s"));
+               for (i = 0; i < nmodes; i++)
+                       (void) fprintf(stderr, "%d ", modes[i]);
+               (void) fprintf(stderr, "\n");
+       }
+}
+
+static
+void
+setMode(ModeInfo * mi, int newmode)
+{
+       randomstruct *rp = &randoms[MI_SCREEN(mi)];
+       int         i;
+
+       previousmode = currentmode;
+       currentmode = newmode;
+
+/* FIX THIS GLOBAL ACCESS */
+       delay = MI_DELAY(mi) = LockProcs[currentmode].def_delay;
+       count = MI_COUNT(mi) = LockProcs[currentmode].def_count;
+       cycles = MI_CYCLES(mi) = LockProcs[currentmode].def_cycles;
+       size = MI_SIZE(mi) = LockProcs[currentmode].def_size;
+       ncolors = MI_NCOLORS(mi) = LockProcs[currentmode].def_ncolors;
+       saturation = MI_SATURATION(mi) = LockProcs[currentmode].def_saturation;
+       bitmap = MI_BITMAP(mi) = LockProcs[currentmode].def_bitmap;
+
+       for (i = startscreen; i < MI_NUM_SCREENS(mi); i++) {
+
+               XChangeGC(MI_DISPLAY(mi), MI_GC(mi), GC_SAVE_VALUES,
+                         &(rp->gcvs));         /* Not sure if this is right for multiscreens */
+               randoms[i].fix = True;
+       }
+       if (MI_IS_VERBOSE(mi))
+               (void) fprintf(stderr, "mode: %s\n", LockProcs[currentmode].cmdline_arg);
+}
+
+void
+init_random(ModeInfo * mi)
+{
+       randomstruct *rp;
+       int         i;
+
+       if (randoms == NULL) {
+               if ((randoms = (randomstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (randomstruct))) == NULL)
+                       return;
+       }
+       rp = &randoms[MI_SCREEN(mi)];
+
+       MI_SET_FLAG_STATE(mi, WI_FLAG_FULLRANDOM, fullrandom);
+       if (currentmode < 0) {
+               parsemodelist(mi);
+
+               for (i = startscreen; i < MI_NUM_SCREENS(mi); i++) {
+                       (void) XGetGCValues(MI_DISPLAY(mi), MI_GC(mi),
+                                           GC_SAVE_VALUES, &(rp->gcvs));
+               }
+               setMode(mi, pickMode());
+               starttime = seconds();
+               if (duration < 0)
+                       duration = 0;
+       }
+       if (rp->fix) {
+               fixColormap(MI_DISPLAY(mi), MI_WINDOW(mi), MI_SCREEN(mi), MI_NCOLORS(mi),
+                       MI_SATURATION(mi), MI_IS_MONO(mi), MI_IS_INSTALL(mi),
+                   MI_IS_INROOT(mi), MI_IS_INWINDOW(mi), MI_IS_VERBOSE(mi));
+               rp->fix = False;
+       }
+       call_init_hook(&LockProcs[currentmode], mi);
+}
+
+void
+draw_random(ModeInfo * mi)
+{
+       int         scrn = MI_SCREEN(mi);
+       randomstruct *rp = &randoms[scrn];
+       int         newmode;
+       unsigned long now = seconds();
+       int         has_run = (duration == 0) ? 0 : (int) (now - starttime);
+       static int  do_init = 0;
+
+       if ((scrn == startscreen) && do_init) {
+               do_init = 0;
+       }
+       if ((scrn == startscreen) && (change_now || (has_run > duration))) {
+               newmode = pickMode();
+
+               MI_CLEARWINDOW(mi);
+
+               setMode(mi, newmode);
+               starttime = now;
+               do_init = 1;
+               change_now = False;
+       }
+       if (rp->fix) {
+               fixColormap(MI_DISPLAY(mi), MI_WINDOW(mi), MI_SCREEN(mi), MI_NCOLORS(mi),
+                       MI_SATURATION(mi), MI_IS_MONO(mi), MI_IS_INSTALL(mi),
+                   MI_IS_INROOT(mi), MI_IS_INWINDOW(mi), MI_IS_VERBOSE(mi));
+               rp->fix = False;
+       }
+       if (do_init) {
+               call_init_hook(&LockProcs[currentmode], mi);
+       }
+       call_callback_hook(&LockProcs[currentmode], mi);
+}
+
+void
+refresh_random(ModeInfo * mi)
+{
+       call_refresh_hook(&LockProcs[currentmode], mi);
+}
+
+void
+change_random(ModeInfo * mi)
+{
+       if (MI_SCREEN(mi) == startscreen)
+               change_now = True;      /* force a change on next draw callback */
+
+       draw_random(mi);
+}
+
+void
+release_random(ModeInfo * mi)
+{
+       if (previousmode >= 0 && previousmode != currentmode)
+               call_release_hook(&LockProcs[previousmode], mi);
+       previousmode = currentmode;
+}
diff --git a/xlockmore-4.14/modes/roll.c b/xlockmore-4.14/modes/roll.c
new file mode 100644 (file)
index 0000000..23f2403
--- /dev/null
@@ -0,0 +1,312 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* roll --- rolling ball of points */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)roll.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by Charles Vidal <vidalc@club-internet.fr>
+ *         http://www.chez.com/vidalc
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97:  Compatible with xscreensaver
+ * 1995: Written.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Roll"
+#define HACK_INIT init_roll
+#define HACK_DRAW draw_roll
+#define roll_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: 25 \n" \
+ "*size: -64 \n" \
+ "*ncolors: 200 \n"
+#define BRIGHT_COLORS
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_roll
+
+ModeSpecOpt roll_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   roll_description =
+{"roll", "init_roll", "draw_roll", "release_roll",
+ "refresh_roll", "init_roll", NULL, &roll_opts,
+ 100000, 25, 1, -64, 64, 0.6, "",
+ "Shows a rolling ball", 0, NULL};
+
+#endif
+
+#define MINPTS 1
+#define MINSIZE 8
+#define FACTOR 8.0
+#define SPEED 25.0
+
+typedef struct {
+       float       t, u, v;
+       float       t1, u1, v1;
+} ptsstruct;
+typedef struct {
+       ptsstruct  *pts;
+       XPoint     *p;
+       int         maxpts, npts;
+       float       alpha, theta, phi, r;
+       XPoint      sphere, direction;
+       int         color;
+       int         width, height;
+} rollstruct;
+
+static rollstruct *rolls = NULL;
+
+static void
+createsphere(rollstruct * rp, int n1, int n2)
+{
+       double      i, j;
+       int         n = 0;
+
+       for (i = 0.0; i < FACTOR * M_PI; i += (FACTOR * M_PI) / n1)
+               for (j = 0.0; j < FACTOR * M_PI; j += (FACTOR * M_PI) / n2) {
+                       rp->pts[n].t1 = rp->r * COSF(i) * COSF(j);
+                       rp->pts[n].u1 = rp->r * COSF(i) * SINF(j);
+                       rp->pts[n].v1 = rp->r * SINF(i);
+                       n++;
+               }
+}
+
+static void
+rotation3d(rollstruct * rp)
+{
+       float       c1, c2, c3, c4, c5, c6, c7, c8, c9, x, y, z;
+       float       sintheta, costheta;
+       float       sinphi, cosphi;
+       float       sinalpha, cosalpha;
+       int         i;
+
+       sintheta = SINF(rp->theta);
+       costheta = COSF(rp->theta);
+       sinphi = SINF(rp->phi);
+       cosphi = COSF(rp->phi);
+       sinalpha = SINF(rp->alpha);
+       cosalpha = COSF(rp->alpha);
+
+       c1 = cosphi * costheta;
+       c2 = sinphi * costheta;
+       c3 = -sintheta;
+
+       c4 = cosphi * sintheta * sinalpha - sinphi * cosalpha;
+       c5 = sinphi * sintheta * sinalpha + cosphi * cosalpha;
+       c6 = costheta * sinalpha;
+
+       c7 = cosphi * sintheta * cosalpha + sinphi * sinalpha;
+       c8 = sinphi * sintheta * cosalpha - cosphi * sinalpha;
+       c9 = costheta * cosalpha;
+       for (i = 0; i < rp->maxpts; i++) {
+               x = rp->pts[i].t;
+               y = rp->pts[i].u;
+               z = rp->pts[i].v;
+               rp->pts[i].t = c1 * x + c2 * y + c3 * z;
+               rp->pts[i].u = c4 * x + c5 * y + c6 * z;
+               rp->pts[i].v = c7 * x + c8 * y + c9 * z;
+       }
+}
+
+static void
+project(rollstruct * rp)
+{
+       int         i;
+
+       for (i = 0; i < rp->maxpts; i++) {
+               rp->p[i].x = (short) (2 * rp->pts[i].t);
+               rp->p[i].y = (short) (2 * rp->pts[i].u);
+       }
+}
+
+void
+init_roll(ModeInfo * mi)
+{
+       rollstruct *rp;
+       int         i;
+       int         size = MI_SIZE(mi);
+       double      ang;
+
+       if (rolls == NULL) {
+               if ((rolls = (rollstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (rollstruct))) == NULL)
+                       return;
+       }
+       rp = &rolls[MI_SCREEN(mi)];
+
+       ang = (double) NRAND(75) + 7.5;
+       rp->direction.x = (short) ((2 * (LRAND() & 1)) - 1) * (int)
+               (SPEED * SINF(ang * M_PI / 180.0));
+       rp->direction.y = (short) ((2 * (LRAND() & 1)) - 1) * (int)
+               (SPEED * COSF(ang * M_PI / 180.0));
+       rp->width = MI_WIDTH(mi);
+       rp->height = MI_HEIGHT(mi);
+       if (size < -MINSIZE)
+               rp->r = NRAND(MIN(-size, MAX(MINSIZE,
+                  MIN(rp->width, rp->height) / 4)) - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE) {
+               if (!size)
+                       rp->r = MAX(MINSIZE, MIN(rp->width, rp->height) / 4);
+               else
+                       rp->r = MINSIZE;
+       } else
+               rp->r = MIN(size, MAX(MINSIZE,
+                                     MIN(rp->width, rp->height) / 4));
+       rp->sphere.x = NRAND(MAX(1, rp->width - 4 * (int) rp->r)) +
+               2 * (int) rp->r;
+       rp->sphere.y = NRAND(MAX(1, rp->height - 4 * (int) rp->r)) +
+               2 * (int) rp->r;
+       rp->alpha = 0;
+       rp->theta = 0;
+       rp->phi = 0;
+       rp->maxpts = MI_COUNT(mi);
+       if (rp->maxpts < -MINPTS) {
+               /* if rp->maxpts is random ... the size can change */
+               if (rp->pts != NULL) {
+                       (void) free((void *) rp->pts);
+                       rp->pts = NULL;
+               }
+               rp->maxpts = NRAND(-rp->maxpts - MINPTS + 1) + MINPTS;
+       } else if (rp->maxpts < MINPTS)
+               rp->maxpts = MINPTS;
+       i = rp->maxpts;
+       rp->maxpts *= rp->maxpts;
+       rp->npts = 0;
+       if (rp->pts == NULL)
+               rp->pts = (ptsstruct *) malloc(rp->maxpts * sizeof (ptsstruct));
+       if (rp->p != NULL) {
+               (void) free((void *) rp->p);
+               rp->p = NULL;
+       }
+       if (MI_NPIXELS(mi) > 2)
+               rp->color = NRAND(MI_NPIXELS(mi));
+       createsphere(rp, i, i);
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_roll(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       rollstruct *rp = &rolls[MI_SCREEN(mi)];
+       int         i;
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < rp->maxpts; i++) {
+               rp->pts[i].t = rp->pts[i].t1;
+               rp->pts[i].u = rp->pts[i].u1;
+               rp->pts[i].v = rp->pts[i].v1;
+       }
+       rp->alpha += ((FACTOR * M_PI) / 200.0);
+       rp->theta += ((FACTOR * M_PI) / 200.0);
+       rp->phi += ((FACTOR * M_PI) / 200.0);
+       if (rp->alpha > (FACTOR * M_PI))
+               rp->alpha -= (FACTOR * M_PI);
+       if (rp->theta > (FACTOR * M_PI))
+               rp->theta -= (FACTOR * M_PI);
+       if (rp->phi > (FACTOR * M_PI))
+               rp->phi -= (FACTOR * M_PI);
+
+       if (rp->npts) {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XDrawPoints(display, window, gc, rp->p, rp->npts, CoordModeOrigin);
+       } else {
+               if (rp->p)
+                       (void) free((void *) rp->p);
+               rp->p = (XPoint *) malloc(rp->maxpts * sizeof (XPoint));
+       }
+       rotation3d(rp);
+       project(rp);
+       rp->npts = 0;
+       for (i = 0; i < rp->maxpts; i++) {
+               if (rp->pts[i].v > 0.0) {
+                       rp->p[rp->npts].x += rp->sphere.x;
+                       rp->p[rp->npts].y += rp->sphere.y;
+                       rp->npts++;
+               }
+       }
+       if (MI_NPIXELS(mi) <= 2)
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       else {
+               rp->color = (rp->color + 1) % MI_NPIXELS(mi);
+               XSetForeground(display, gc, MI_PIXEL(mi, rp->color));
+       }
+       XDrawPoints(display, window, gc, rp->p, rp->npts, CoordModeOrigin);
+       if (rp->sphere.x >= rp->width - (int) rp->r && rp->direction.x > 0)
+               rp->direction.x = -rp->direction.x;
+       else if (rp->sphere.x <= (int) rp->r && rp->direction.x < 0)
+               rp->direction.x = -rp->direction.x;
+       else if (rp->sphere.x < rp->width - 2 * (int) rp->r ||
+                rp->sphere.x > 2 * (int) rp->r) {
+               if (rp->sphere.x >= rp->width - 2 * (int) rp->r && rp->direction.x > 0)
+                       rp->direction.x = -rp->direction.x;
+               else if (rp->sphere.x <= 2 * (int) rp->r && rp->direction.x < 0)
+                       rp->direction.x = -rp->direction.x;
+       }
+       if (rp->sphere.y >= rp->height - (int) rp->r && rp->direction.y > 0)
+               rp->direction.y = -rp->direction.y;
+       else if (rp->sphere.y <= (int) rp->r && rp->direction.y < 0)
+               rp->direction.y = -rp->direction.y;
+       else if (rp->sphere.y < rp->height - 2 * (int) rp->r ||
+                rp->sphere.y > 2 * (int) rp->r) {
+               if (rp->sphere.y >= rp->height - 2 * (int) rp->r && rp->direction.y > 0)
+                       rp->direction.y = -rp->direction.y;
+               else if (rp->sphere.y <= 2 * (int) rp->r && rp->direction.y < 0)
+                       rp->direction.y = -rp->direction.y;
+       }
+       rp->sphere.x += rp->direction.x;
+       rp->sphere.y += rp->direction.y;
+}
+
+void
+release_roll(ModeInfo * mi)
+{
+       if (rolls != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       rollstruct *rp = &rolls[screen];
+
+                       if (rp->pts != NULL)
+                               (void) free((void *) rp->pts);
+                       if (rp->p != NULL)
+                               (void) free((void *) rp->p);
+               }
+               (void) free((void *) rolls);
+               rolls = NULL;
+       }
+}
+
+void
+refresh_roll(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_roll */
diff --git a/xlockmore-4.14/modes/rotor.c b/xlockmore-4.14/modes/rotor.c
new file mode 100644 (file)
index 0000000..abfaf04
--- /dev/null
@@ -0,0 +1,369 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* rotor --- a swirly rotor */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)rotor.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97:  Compatible with xscreensaver
+ * 08-Mar-95: CAT stuff for ## was tripping up some C compilers.  Removed.
+ * 01-Dec-93: added patch for AIXV3 from Tom McConnell
+ *            <tmcconne@sedona.intel.com>
+ * 11-Nov-90: put into xlock by Steve Zellers <zellers@sun.com>
+ * 16-Oct-90: Received from Tom Lawrence (tcl@cs.brown.edu: 'flight' simulator)
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Rotor"
+#define HACK_INIT init_rotor
+#define HACK_DRAW draw_rotor
+#define rotor_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 4 \n" \
+ "*cycles: 20 \n" \
+ "*size: -6 \n" \
+ "*ncolors: 200 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_rotor
+
+ModeSpecOpt rotor_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   rotor_description =
+{"rotor", "init_rotor", "draw_rotor", "release_rotor",
+ "refresh_rotor", "init_rotor", NULL, &rotor_opts,
+ 10000, 4, 20, -6, 64, 0.3, "",
+ "Shows Tom's Roto-Rooter", 0, NULL};
+
+#endif
+
+/*-
+ * A 'batchcount' of 3 or 4 works best!
+ */
+
+#define MAXANGLE       3000.0  /* irrectangular  (was 10000.0) */
+
+/* How many segments to draw per cycle when redrawing */
+#define REDRAWSTEP 3
+
+typedef struct {
+       float       angle;
+       float       radius;
+       float       start_radius;
+       float       end_radius;
+       float       radius_drift_max;
+       float       radius_drift_now;
+
+       float       ratio;
+       float       start_ratio;
+       float       end_ratio;
+       float       ratio_drift_max;
+       float       ratio_drift_now;
+} elem;
+
+typedef struct {
+       int         pix;
+       int         lastx, lasty;
+       int         num, rotor, prev;
+       int         nsave;
+       float       angle;
+       int         centerx, centery;
+       int         prevcenterx, prevcentery;
+       unsigned char firsttime;
+       unsigned char iconifiedscreen;  /* for iconified view */
+       unsigned char forward;
+       unsigned char unused;
+       elem       *elements;
+       XPoint     *save;
+       int         redrawing, redrawpos;
+       int         linewidth;
+} rotorstruct;
+
+static rotorstruct *rotors = NULL;
+
+void
+init_rotor(ModeInfo * mi)
+{
+       rotorstruct *rp;
+       int         x;
+       elem       *pelem;
+       unsigned char wasiconified;
+
+       if (rotors == NULL) {
+               if ((rotors = (rotorstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (rotorstruct))) == NULL)
+                       return;
+       }
+       rp = &rotors[MI_SCREEN(mi)];
+
+       rp->prevcenterx = rp->centerx;
+       rp->prevcentery = rp->centery;
+
+       rp->centerx = MI_WIDTH(mi) / 2;
+       rp->centery = MI_HEIGHT(mi) / 2;
+
+       rp->redrawing = 0;
+       /*
+        * sometimes, you go into iconified view, only to see a really whizzy pattern
+        * that you would like to look more closely at. Normally, clicking in the
+        * icon reinitializes everything - but I don't, cuz I'm that kind of guy.
+        * HENCE, the wasiconified stuff you see here.
+        */
+
+       wasiconified = rp->iconifiedscreen;
+       rp->iconifiedscreen = MI_IS_ICONIC(mi);
+
+       if (wasiconified && !rp->iconifiedscreen)
+               rp->firsttime = True;
+       else {
+
+               /* This is a fudge is needed since prevcenter may not be set when it comes
+                  from the the random mode and return is pressed (and its not the first
+                  mode that was running). This assumes that the size of the lock screen
+                  window / size of the icon window = 12 */
+               if (!rp->prevcenterx)
+                       rp->prevcenterx = rp->centerx * 12;
+               if (!rp->prevcentery)
+                       rp->prevcentery = rp->centery * 12;
+
+               rp->num = MI_COUNT(mi);
+               if (rp->num < 0) {
+                       rp->num = NRAND(-rp->num) + 1;
+                       if (rp->elements != NULL) {
+                               (void) free((void *) rp->elements);
+                               rp->elements = NULL;
+                       }
+               }
+               if (rp->elements == NULL)
+                       rp->elements = (elem *) calloc(rp->num, sizeof (elem));
+               rp->nsave = MI_CYCLES(mi);
+               if (rp->nsave <= 1)
+                       rp->nsave = 2;
+               if (rp->save == NULL)
+                       rp->save = (XPoint *) malloc(rp->nsave * sizeof (XPoint));
+               for (x = 0; x < rp->nsave; x++) {
+                       rp->save[x].x = rp->centerx;
+                       rp->save[x].y = rp->centery;
+               }
+
+               pelem = rp->elements;
+
+               for (x = rp->num; --x >= 0; pelem++) {
+                       pelem->radius_drift_max = 1.0;
+                       pelem->radius_drift_now = 1.0;
+
+                       pelem->end_radius = 100.0;
+
+                       pelem->ratio_drift_max = 1.0;
+                       pelem->ratio_drift_now = 1.0;
+                       pelem->end_ratio = 10.0;
+               }
+               if (MI_NPIXELS(mi) > 2)
+                       rp->pix = NRAND(MI_NPIXELS(mi));
+
+               rp->rotor = 0;
+               rp->prev = 1;
+               rp->lastx = rp->centerx;
+               rp->lasty = rp->centery;
+               rp->angle = (float) NRAND((long) MAXANGLE) / 3.0;
+               rp->forward = rp->firsttime = True;
+       }
+       rp->linewidth = MI_SIZE(mi);
+
+       if (rp->linewidth == 0)
+               rp->linewidth = 1;
+       if (rp->linewidth < 0)
+               rp->linewidth = NRAND(-rp->linewidth) + 1;
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_rotor(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       register rotorstruct *rp = &rotors[MI_SCREEN(mi)];
+       register elem *pelem;
+       int         thisx, thisy;
+       int         i;
+       int         x_1, y_1, x_2, y_2;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (!rp->iconifiedscreen) {
+               thisx = rp->centerx;
+               thisy = rp->centery;
+       } else {
+               thisx = rp->prevcenterx;
+               thisy = rp->prevcentery;
+       }
+       XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), rp->linewidth,
+                          LineSolid, CapButt, JoinMiter);
+       for (i = rp->num, pelem = rp->elements; --i >= 0; pelem++) {
+               if (pelem->radius_drift_max <= pelem->radius_drift_now) {
+                       pelem->start_radius = pelem->end_radius;
+                       pelem->end_radius = (float) NRAND(40000) / 100.0 - 200.0;
+                       pelem->radius_drift_max = (float) NRAND(100000) + 10000.0;
+                       pelem->radius_drift_now = 0.0;
+               }
+               if (pelem->ratio_drift_max <= pelem->ratio_drift_now) {
+                       pelem->start_ratio = pelem->end_ratio;
+                       pelem->end_ratio = (float) NRAND(2000) / 100.0 - 10.0;
+                       pelem->ratio_drift_max = (float) NRAND(100000) + 10000.0;
+                       pelem->ratio_drift_now = 0.0;
+               }
+               pelem->ratio = pelem->start_ratio +
+                       (pelem->end_ratio - pelem->start_ratio) /
+                       pelem->ratio_drift_max * pelem->ratio_drift_now;
+               pelem->angle = rp->angle * pelem->ratio;
+               pelem->radius = pelem->start_radius +
+                       (pelem->end_radius - pelem->start_radius) /
+                       pelem->radius_drift_max * pelem->radius_drift_now;
+
+               thisx += (int) (COSF(pelem->angle) * pelem->radius);
+               thisy += (int) (SINF(pelem->angle) * pelem->radius);
+
+               pelem->ratio_drift_now += 1.0;
+               pelem->radius_drift_now += 1.0;
+       }
+       if (rp->firsttime)
+               rp->firsttime = False;
+       else {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+
+               x_1 = (int) rp->save[rp->rotor].x;
+               y_1 = (int) rp->save[rp->rotor].y;
+               x_2 = (int) rp->save[rp->prev].x;
+               y_2 = (int) rp->save[rp->prev].y;
+
+               if (rp->iconifiedscreen) {
+                       x_1 = x_1 * rp->centerx / rp->prevcenterx;
+                       x_2 = x_2 * rp->centerx / rp->prevcenterx;
+                       y_1 = y_1 * rp->centery / rp->prevcentery;
+                       y_2 = y_2 * rp->centery / rp->prevcentery;
+               }
+               XDrawLine(display, MI_WINDOW(mi), gc, x_1, y_1, x_2, y_2);
+
+               if (MI_NPIXELS(mi) > 2) {
+                       XSetForeground(display, gc, MI_PIXEL(mi, rp->pix));
+                       if (++rp->pix >= MI_NPIXELS(mi))
+                               rp->pix = 0;
+               } else
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+               x_1 = rp->lastx;
+               y_1 = rp->lasty;
+               x_2 = thisx;
+               y_2 = thisy;
+
+               if (rp->iconifiedscreen) {
+                       x_1 = x_1 * rp->centerx / rp->prevcenterx;
+                       x_2 = x_2 * rp->centerx / rp->prevcenterx;
+                       y_1 = y_1 * rp->centery / rp->prevcentery;
+                       y_2 = y_2 * rp->centery / rp->prevcentery;
+               }
+               XDrawLine(display, MI_WINDOW(mi), gc, x_1, y_1, x_2, y_2);
+       }
+       rp->save[rp->rotor].x = rp->lastx = thisx;
+       rp->save[rp->rotor].y = rp->lasty = thisy;
+
+       ++rp->rotor;
+       rp->rotor %= rp->nsave;
+       ++rp->prev;
+       rp->prev %= rp->nsave;
+       if (rp->forward) {
+               rp->angle += 0.01;
+               if (rp->angle >= MAXANGLE) {
+                       rp->angle = MAXANGLE;
+                       rp->forward = False;
+               }
+       } else {
+               rp->angle -= 0.1;
+               if (rp->angle <= 0) {
+                       rp->angle = 0.0;
+                       rp->forward = True;
+               }
+       }
+       if (rp->redrawing) {
+               int         j;
+
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       j = (rp->rotor - rp->redrawpos + rp->nsave) % rp->nsave;
+
+                       x_1 = (int) rp->save[j].x;
+                       y_1 = (int) rp->save[j].y;
+                       x_2 = (int) rp->save[(j - 1 + rp->nsave) % rp->nsave].x;
+                       y_2 = (int) rp->save[(j - 1 + rp->nsave) % rp->nsave].y;
+
+                       if (rp->iconifiedscreen) {
+                               x_1 = x_1 * rp->centerx / rp->prevcenterx;
+                               x_2 = x_2 * rp->centerx / rp->prevcenterx;
+                               y_1 = y_1 * rp->centery / rp->prevcentery;
+                               y_2 = y_2 * rp->centery / rp->prevcentery;
+                       }
+                       XDrawLine(display, MI_WINDOW(mi), gc, x_1, y_1, x_2, y_2);
+
+                       if (++(rp->redrawpos) >= rp->nsave) {
+                               rp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+       XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), 1,
+                          LineSolid, CapButt, JoinMiter);
+}
+
+void
+release_rotor(ModeInfo * mi)
+{
+       if (rotors != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       rotorstruct *rp = &rotors[screen];
+
+                       if (rp->elements != NULL)
+                               (void) free((void *) rp->elements);
+                       if (rp->save != NULL)
+                               (void) free((void *) rp->save);
+               }
+               (void) free((void *) rotors);
+               rotors = NULL;
+       }
+}
+
+void
+refresh_rotor(ModeInfo * mi)
+{
+       rotorstruct *rp = &rotors[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+       rp->redrawing = 1;
+       rp->redrawpos = 1;
+}
+
+#endif /* MODE_rotor */
diff --git a/xlockmore-4.14/modes/shape.c b/xlockmore-4.14/modes/shape.c
new file mode 100644 (file)
index 0000000..6ee75ce
--- /dev/null
@@ -0,0 +1,416 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* shape --- basic in your face shapes */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)shape.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1992 by Jamie Zawinski
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 12-Mar-98: Got the idea for shadow from looking at xscreensaver web page.
+ * 10-May-97: Compatible with xscreensaver
+ * 03-Nov-95: formerly rect.c
+ * 11-Aug-95: slight change to initialization of pixmaps
+ * 27-Jun-95: added ellipses
+ * 27-Feb-95: patch for VMS
+ * 29-Sep-94: multidisplay bug fix <epstein_caleb@jpmorgan.com>
+ * 15-Jul-94: xlock version David Bagley <bagleyd@tux.org>
+ * 1992:      xscreensaver version Jamie Zawinski <jwz@jwz.org>
+ */
+
+/*-
+ * original copyright
+ * Copyright (c) 1992 by Jamie Zawinski
+ * Permission to use, copy, modify, distribute, and sell this software and
+ * its documentation for any purpose is hereby granted without fee, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or
+ * implied warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Shape"
+#define HACK_INIT init_shape
+#define HACK_DRAW draw_shape
+#define shape_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 100 \n" \
+ "*cycles: 256 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_shape
+
+#ifndef STIPPLING
+/*-
+ * For Linux (others, Intel based?) this could be deadly for the client.
+ *   If you have 15/16 bit displays it may want a hard reboot after
+ *   1 minute.  Not true on all systems... may be a XFree86 based problem.
+ *   Also what is it with those corruption lines in some of the shapes?
+ * 3 degrees for STIPPLING ...
+ *     0: absolutely not
+ *     1: if user insists (default for Linux)
+ *     2: permit (also no warning message) (default for other OS's)
+ */
+#ifdef __linux__
+#if 0
+#define STIPPLING 0
+#else
+#define STIPPLING 1
+#endif
+#else
+#define STIPPLING 2
+#endif
+#endif
+
+/*-
+ * "shade" is used over "shadow" because of possible confusion with
+ * password shadowing
+ */
+
+#define DEF_SHADE  "True"
+#define DEF_BORDER  "False"
+#if (STIPPLING > 1)
+#define DEF_STIPPLE  "True"
+#else
+#define DEF_STIPPLE  "False"
+#endif
+
+static Bool shade;
+static Bool border;
+static Bool stipple;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-shade", ".shape.shade", XrmoptionNoArg, (caddr_t) "on"},
+       {"+shade", ".shape.shade", XrmoptionNoArg, (caddr_t) "off"},
+       {"-border", ".shape.border", XrmoptionNoArg, (caddr_t) "on"},
+       {"+border", ".shape.border", XrmoptionNoArg, (caddr_t) "off"},
+       {"-stipple", ".shape.stipple", XrmoptionNoArg, (caddr_t) "on"},
+       {"+stipple", ".shape.stipple", XrmoptionNoArg, (caddr_t) "off"}
+};
+static argtype vars[] =
+{
+       {(caddr_t *) & shade, "shade", "Shade", DEF_SHADE, t_Bool},
+       {(caddr_t *) & border, "border", "Border", DEF_BORDER, t_Bool},
+       {(caddr_t *) & stipple, "stipple", "Stipple", DEF_STIPPLE, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+shade", "turn on/off shape's shadows"},
+       {"-/+border", "turn on/off shape's borders"},
+       {"-/+stipple", "turn on/off shape's stippling"}
+};
+
+ModeSpecOpt shape_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   shape_description =
+{"shape", "init_shape", "draw_shape", "release_shape",
+ "refresh_shape", "init_shape", NULL, &shape_opts,
+ 10000, 100, 256, 1, 64, 1.0, "",
+ "Shows overlaying rectangles, ellipses, and triangles", 0, NULL};
+
+#endif
+
+#define MAX_SHADE_OFFSET 32
+#define MIN_SHADE_OFFSET 2
+
+#define NBITS 12
+
+#include "bitmaps/gray1.xbm"
+#include "bitmaps/gray3.xbm"
+#include "bitmaps/stipple.xbm"
+#include "bitmaps/cross_weave.xbm"
+#include "bitmaps/dimple1.xbm"
+#include "bitmaps/dimple3.xbm"
+#include "bitmaps/flipped_gray.xbm"
+#include "bitmaps/hlines2.xbm"
+#include "bitmaps/light_gray.xbm"
+#include "bitmaps/root_weave.xbm"
+#include "bitmaps/vlines2.xbm"
+#include "bitmaps/vlines3.xbm"
+#define SHAPEBITS(n,w,h)\
+  sp->pixmaps[sp->init_bits++]=\
+               XCreateBitmapFromData(display,window,(char *)n,w,h)
+
+typedef struct {
+       int         width;
+       int         height;
+       int         borderx;
+       int         bordery;
+       int         time;
+       int         x, y, w, h;
+       Bool        shade;
+       Bool        border;
+       Bool        stipple;
+       XPoint      shade_offset;
+       int         init_bits;
+       Pixmap      pixmaps[NBITS];
+} shapestruct;
+
+static shapestruct *shapes = NULL;
+
+void
+init_shape(ModeInfo * mi)
+{
+       shapestruct *sp;
+
+       if (shapes == NULL) {
+               if ((shapes = (shapestruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (shapestruct))) == NULL)
+                       return;
+       }
+       sp = &shapes[MI_SCREEN(mi)];
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+       sp->borderx = sp->width / 20;
+       sp->bordery = sp->height / 20;
+       sp->time = 0;
+
+       if (MI_IS_FULLRANDOM(mi))
+               sp->shade = (Bool) (LRAND() & 1);
+       else
+               sp->shade = shade;
+
+       if (shade) {
+               sp->shade_offset.x = (NRAND(MAX_SHADE_OFFSET - MIN_SHADE_OFFSET) +
+                               MIN_SHADE_OFFSET) * ((LRAND() & 1) ? 1 : -1);
+               sp->shade_offset.y = (NRAND(MAX_SHADE_OFFSET - MIN_SHADE_OFFSET) +
+                               MIN_SHADE_OFFSET) * ((LRAND() & 1) ? 1 : -1);
+       }
+       if (MI_IS_FULLRANDOM(mi))
+               sp->border = (Bool) (LRAND() & 1);
+       else
+               sp->border = border;
+
+#if (STIPPLING > 1)
+       if (MI_IS_FULLRANDOM(mi))
+               sp->stipple = (Bool) (LRAND() & 1);
+       else
+               sp->stipple = stipple;
+#else
+#if (STIPPLING < 1)
+       sp->stipple = False;
+#else
+       sp->stipple = stipple;  /* OK if you insist... could be dangerous */
+#endif
+#endif
+       if (sp->stipple && !sp->init_bits) {
+               Display    *display = MI_DISPLAY(mi);
+               Window      window = MI_WINDOW(mi);
+
+#if defined( __linux__ ) && ( STIPPLING < 2 )
+               if ((MI_IS_VERBOSE(mi) || MI_IS_DEBUG(mi)) &&
+                   (MI_DEPTH(mi) == 15 || MI_DEPTH(mi) == 16))
+                       (void) fprintf(stderr, "This may cause a LOCKUP in seconds!!!\n");
+#endif
+               SHAPEBITS(gray1_bits, gray1_width, gray1_height);
+               SHAPEBITS(gray3_bits, gray3_width, gray3_height);
+               SHAPEBITS(cross_weave_bits, cross_weave_width, cross_weave_height);
+               SHAPEBITS(dimple1_bits, dimple1_width, dimple1_height);
+               SHAPEBITS(dimple3_bits, dimple3_width, dimple3_height);
+               SHAPEBITS(flipped_gray_bits, flipped_gray_width, flipped_gray_height);
+               SHAPEBITS(vlines3_bits, vlines3_width, vlines3_height);
+               SHAPEBITS(stipple_bits, stipple_width, stipple_height);
+               SHAPEBITS(hlines2_bits, hlines2_width, hlines2_height);
+               SHAPEBITS(light_gray_bits, light_gray_width, light_gray_height);
+               SHAPEBITS(root_weave_bits, root_weave_width, root_weave_height);
+               SHAPEBITS(vlines2_bits, vlines2_width, vlines2_height);
+       }
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_shape(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       shapestruct *sp = &shapes[MI_SCREEN(mi)];
+       int         shape, i;
+       XPoint      shade_offset;
+
+       MI_IS_DRAWN(mi) = True;
+
+       shade_offset.x = 0;
+       shade_offset.y = 0;
+       if (sp->stipple)
+               if (!sp->init_bits)
+                       return;
+
+       if (sp->stipple) {
+               XSetBackground(display, gc, (MI_NPIXELS(mi) > 2) ?
+                  MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))) : MI_BLACK_PIXEL(mi));
+       }
+       if (sp->border) {
+               XSetLineAttributes(display, gc, 2, LineSolid, CapNotLast, JoinRound);
+       }
+       shape = NRAND(3);
+       if (sp->shade) {
+               i = MAX(ABS(sp->shade_offset.x), ABS(sp->shade_offset.y));
+               shade_offset.x = (short int) (((float) NRAND(i) + 2.0) /
+                                             (1.0 + i) * sp->shade_offset.x);
+               shade_offset.y = (short int) (((float) NRAND(i) + 2.0) /
+                                             (1.0 + i) * sp->shade_offset.y);
+               /* This is over-simplistic... it casts the same length shadow over
+                * different depth objects.
+                */
+       }
+       if (shape == 2) {
+               XPoint      triangleList[4];
+               XPoint      triangleShade[3];
+
+               triangleList[0].x = sp->borderx + NRAND(sp->width - 2 * sp->borderx);
+               triangleList[0].y = sp->bordery + NRAND(sp->height - 2 * sp->bordery);
+               triangleList[1].x = sp->borderx + NRAND(sp->width - 2 * sp->borderx);
+               triangleList[1].y = sp->bordery + NRAND(sp->height - 2 * sp->bordery);
+               triangleList[2].x = sp->borderx + NRAND(sp->width - 2 * sp->borderx);
+               triangleList[2].y = sp->bordery + NRAND(sp->height - 2 * sp->bordery);
+               triangleList[3].x = triangleList[0].x;
+               triangleList[3].y = triangleList[0].y;
+               if (sp->shade) {
+                       for (i = 0; i < 3; i++) {
+                               triangleShade[i].x = triangleList[i].x + shade_offset.x;
+                               triangleShade[i].y = triangleList[i].y + shade_offset.y;
+                       }
+                       if (sp->stipple) {
+                               XSetStipple(display, gc, sp->pixmaps[0]);
+                               XSetFillStyle(display, gc, FillStippled);
+                       }
+                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                       XFillPolygon(display, window, gc, triangleShade, 3,
+                                    Convex, CoordModeOrigin);
+               }
+               if (sp->stipple) {
+                       XSetStipple(display, gc, sp->pixmaps[NRAND(sp->init_bits)]);
+                       XSetFillStyle(display, gc, FillOpaqueStippled);
+               }
+               XSetForeground(display, gc, (MI_NPIXELS(mi) > 2) ?
+                  MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))) : MI_WHITE_PIXEL(mi));
+               XFillPolygon(display, window, gc, triangleList, 3,
+                            Convex, CoordModeOrigin);
+               if (sp->border) {
+                       XSetForeground(display, gc, (MI_NPIXELS(mi) > 2) ?
+                                      MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))) : MI_BLACK_PIXEL(mi));
+                       XDrawLines(display, window, gc, triangleList, 4, CoordModeOrigin);
+               }
+       } else {
+               sp->w = sp->borderx + NRAND(sp->width - 2 * sp->borderx) *
+                       NRAND(sp->width) / sp->width;
+               sp->h = sp->bordery + NRAND(sp->height - 2 * sp->bordery) *
+                       NRAND(sp->height) / sp->height;
+               sp->x = NRAND(sp->width - sp->w);
+               sp->y = NRAND(sp->height - sp->h);
+               if (shape) {
+                       if (sp->shade) {
+                               if (sp->stipple) {
+                                       XSetStipple(display, gc, sp->pixmaps[0]);
+                                       XSetFillStyle(display, gc, FillStippled);
+                               }
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XFillArc(display, window, gc,
+                                        sp->x + shade_offset.x, sp->y + shade_offset.y,
+                                        sp->w, sp->h, 0, 23040);
+                       }
+                       if (sp->stipple) {
+                               XSetStipple(display, gc, sp->pixmaps[NRAND(sp->init_bits)]);
+                               XSetFillStyle(display, gc, FillOpaqueStippled);
+                       }
+                       XSetForeground(display, gc, (MI_NPIXELS(mi) > 2) ?
+                                      MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))) : MI_WHITE_PIXEL(mi));
+                       XFillArc(display, window, gc,
+                                sp->x, sp->y, sp->w, sp->h, 0, 23040);
+                       if (sp->border) {
+                               XSetForeground(display, gc, (MI_NPIXELS(mi) > 2) ?
+                                              MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))) : MI_BLACK_PIXEL(mi));
+                               XDrawArc(display, window, gc,
+                                      sp->x, sp->y, sp->w, sp->h, 0, 23040);
+                       }
+               } else {
+                       if (sp->shade) {
+                               if (sp->stipple) {
+                                       XSetStipple(display, gc, sp->pixmaps[0]);
+                                       XSetFillStyle(display, gc, FillStippled);
+                               }
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XFillRectangle(display, window, gc,
+                                              sp->x + shade_offset.x, sp->y + shade_offset.y, sp->w, sp->h);
+                       }
+                       if (sp->stipple) {
+                               XSetStipple(display, gc, sp->pixmaps[NRAND(sp->init_bits)]);
+                               XSetFillStyle(display, gc, FillOpaqueStippled);
+                       }
+                       XSetForeground(display, gc, (MI_NPIXELS(mi) > 2) ?
+                                      MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))) : MI_WHITE_PIXEL(mi));
+                       XFillRectangle(display, window, gc,
+                                      sp->x, sp->y, sp->w, sp->h);
+                       if (sp->border) {
+                               XSetForeground(display, gc, (MI_NPIXELS(mi) > 2) ?
+                                              MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))) : MI_BLACK_PIXEL(mi));
+                               XDrawRectangle(display, window, gc,
+                                              sp->x, sp->y, sp->w, sp->h);
+                       }
+               }
+       }
+       if (sp->border)
+               XSetLineAttributes(display, gc, 1, LineSolid, CapNotLast, JoinRound);
+       if (sp->stipple)
+               XSetFillStyle(display, gc, FillSolid);
+       if (sp->stipple && MI_NPIXELS(mi) > 2) {
+               XSetBackground(display, gc, MI_BLACK_PIXEL(mi));
+       }
+       XFlush(display);
+       if (++sp->time > MI_CYCLES(mi))
+               init_shape(mi);
+}
+
+void
+release_shape(ModeInfo * mi)
+{
+       if (shapes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       shapestruct *sp = &shapes[screen];
+                       int         bits;
+
+                       for (bits = 0; bits < sp->init_bits; bits++)
+                               XFreePixmap(MI_DISPLAY(mi), sp->pixmaps[bits]);
+               }
+               (void) free((void *) shapes);
+               shapes = NULL;
+       }
+}
+
+void
+refresh_shape(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_shape */
diff --git a/xlockmore-4.14/modes/sierpinski.c b/xlockmore-4.14/modes/sierpinski.c
new file mode 100644 (file)
index 0000000..e3c7130
--- /dev/null
@@ -0,0 +1,205 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* sierpinski --- Sierpinski's triangle fractal */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)sierpinski.c 4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by Desmond Daignault
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Dots initially appear where they "should not".  Later they get
+ * "focused".  This is correct behavior.
+ *
+ * Revision History:
+ * 18-Sep-97: 3D version Antti Kuntsi <kuntsi@iki.fi>.
+ * 20-May-97: Changed the name tri to sierpinski for more compatiblity
+ * 10-May-97: Jamie Zawinski <jwz@jwz.org> compatible with xscreensaver
+ * 05-Sep-96: Desmond Daignault Datatimes Incorporated
+ *            <tekdd@dtol.datatimes.com> .
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Sierpinski"
+#define HACK_INIT init_sierpinski
+#define HACK_DRAW draw_sierpinski
+#define sierpinski_opts xlockmore_opts
+#define DEFAULTS "*delay: 400000 \n" \
+ "*count: 2000 \n" \
+ "*cycles: 100 \n" \
+ "*ncolors: 64 \n"
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_sierpinski
+
+ModeSpecOpt sierpinski_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   sierpinski_description =
+{"sierpinski", "init_sierpinski", "draw_sierpinski", "release_sierpinski",
+ "refresh_sierpinski", "init_sierpinski", NULL, &sierpinski_opts,
+ 400000, 2000, 100, 1, 64, 1.0, "",
+ "Shows Sierpinski's triangle", 0, NULL};
+
+#endif
+
+#define MAXCORNERS 4
+
+typedef struct {
+       int         width, height;
+       int         time;
+       int         px, py;
+       int         total_npoints;
+       int         corners;
+       int         npoints[MAXCORNERS];
+       unsigned long colors[MAXCORNERS];
+       XPoint     *pointBuffer[MAXCORNERS];
+       XPoint      vertex[MAXCORNERS];
+} sierpinskistruct;
+
+static sierpinskistruct *tris = NULL;
+
+static void
+startover(ModeInfo * mi)
+{
+       int         j;
+       sierpinskistruct *sp = &tris[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) > 2) {
+               if (sp->corners == 3) {
+                       sp->colors[0] = (NRAND(MI_NPIXELS(mi)));
+                       sp->colors[1] = (sp->colors[0] + MI_NPIXELS(mi) / 7 +
+                        NRAND(2 * MI_NPIXELS(mi) / 7 + 1)) % MI_NPIXELS(mi);
+                       sp->colors[2] = (sp->colors[0] + 4 * MI_NPIXELS(mi) / 7 +
+                        NRAND(2 * MI_NPIXELS(mi) / 7 + 1)) % MI_NPIXELS(mi);
+               } else if (sp->corners == 4) {
+                       sp->colors[0] = (NRAND(MI_NPIXELS(mi)));
+                       sp->colors[1] = (sp->colors[0] + MI_NPIXELS(mi) / 7 +
+                            NRAND(MI_NPIXELS(mi) / 7 + 1)) % MI_NPIXELS(mi);
+                       sp->colors[2] = (sp->colors[0] + 3 * MI_NPIXELS(mi) / 7 +
+                            NRAND(MI_NPIXELS(mi) / 7 + 1)) % MI_NPIXELS(mi);
+                       sp->colors[3] = (sp->colors[0] + 5 * MI_NPIXELS(mi) / 7 +
+                            NRAND(MI_NPIXELS(mi) / 7 + 1)) % MI_NPIXELS(mi);
+               } else {
+                       (void) fprintf(stderr, "colors not set for %d corners\n", sp->corners);
+               }
+       }
+       for (j = 0; j < sp->corners; j++) {
+               sp->vertex[j].x = NRAND(sp->width);
+               sp->vertex[j].y = NRAND(sp->height);
+       }
+       sp->px = NRAND(sp->width);
+       sp->py = NRAND(sp->height);
+       sp->time = 0;
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+init_sierpinski(ModeInfo * mi)
+{
+       sierpinskistruct *sp;
+       int         i;
+
+       if (tris == NULL) {
+               if ((tris = (sierpinskistruct *) calloc(MI_NUM_SCREENS(mi),
+                                        sizeof (sierpinskistruct))) == NULL)
+                       return;
+       }
+       sp = &tris[MI_SCREEN(mi)];
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+
+       sp->total_npoints = MI_COUNT(mi);
+       if (sp->total_npoints < 1)
+               sp->total_npoints = 1;
+       sp->corners = MI_SIZE(mi);
+       if (sp->corners < 3 || sp->corners > 4) {
+               sp->corners = (int) (LRAND() & 1) + 3;
+       }
+       for (i = 0; i < sp->corners; i++) {
+               if (!sp->pointBuffer[i])
+                       sp->pointBuffer[i] = (XPoint *) malloc(sp->total_npoints *
+                                                           sizeof (XPoint));
+       }
+       startover(mi);
+}
+
+void
+draw_sierpinski(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       sierpinskistruct *sp = &tris[MI_SCREEN(mi)];
+       XPoint     *xp[MAXCORNERS];
+       int         i = 0, v;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (MI_NPIXELS(mi) <= 2)
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       for (i = 0; i < sp->corners; i++)
+               xp[i] = sp->pointBuffer[i];
+       for (i = 0; i < sp->total_npoints; i++) {
+               v = NRAND(sp->corners);
+               sp->px = (sp->px + sp->vertex[v].x) / 2;
+               sp->py = (sp->py + sp->vertex[v].y) / 2;
+               xp[v]->x = sp->px;
+               xp[v]->y = sp->py;
+               xp[v]++;
+               sp->npoints[v]++;
+       }
+       for (i = 0; i < sp->corners; i++) {
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, gc, MI_PIXEL(mi, sp->colors[i]));
+               XDrawPoints(display, MI_WINDOW(mi), gc, sp->pointBuffer[i], sp->npoints[i],
+                           CoordModeOrigin);
+               sp->npoints[i] = 0;
+       }
+       if (++sp->time >= MI_CYCLES(mi))
+               startover(mi);
+}
+
+void
+release_sierpinski(ModeInfo * mi)
+{
+       if (tris != NULL) {
+               int         screen, i;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       for (i = 0; i < MAXCORNERS; i++)
+                               if (tris[screen].pointBuffer[i] != NULL) {
+                                       (void) free((void *) tris[screen].pointBuffer[i]);
+                               }
+               }
+               (void) free((void *) tris);
+               tris = NULL;
+       }
+}
+
+void
+refresh_sierpinski(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_sierpinski */
diff --git a/xlockmore-4.14/modes/slip.c b/xlockmore-4.14/modes/slip.c
new file mode 100644 (file)
index 0000000..898f844
--- /dev/null
@@ -0,0 +1,327 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* slip --- lots of slipping blits */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)slip.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1992 by Scott Draves <spot@cs.cmu.edu>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * 10-May-97: Jamie Zawinski <jwz@jwz.org> compatible with xscreensaver
+ * 01-Dec-95: Patched for VMS <joukj@hrem.stm.tudelft.nl>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Slip"
+#define HACK_INIT init_slip
+#define HACK_DRAW draw_slip
+#define slip_opts xlockmore_opts
+#define DEFAULTS "*delay: 50000 \n" \
+ "*count: 35 \n" \
+ "*cycles: 50 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_slip
+
+ModeSpecOpt slip_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   slip_description =
+{"slip", "init_slip", "draw_slip", "release_slip",
+ "init_slip", "init_slip", NULL, &slip_opts,
+ 50000, 35, 50, 1, 64, 1.0, "",
+ "Shows slipping blits", 0, NULL};
+
+#endif
+
+typedef struct {
+       int         width, height;
+       int         nblits_remaining;
+       int         blit_width, blit_height;
+       int         mode;
+       int         first_time;
+       int         backwards;
+} slipstruct;
+static slipstruct *slips = NULL;
+
+static short
+halfrandom(int mv)
+{
+       static short lasthalf = 0;
+       unsigned long r;
+
+       if (lasthalf) {
+               r = lasthalf;
+               lasthalf = 0;
+       } else {
+               r = LRAND();
+               lasthalf = (short) (r >> 16);
+       }
+       return r % mv;
+}
+
+static int
+erandom(int mv)
+{
+       static int  stage = 0;
+       static unsigned long r;
+       int         res;
+
+       if (0 == stage) {
+               r = LRAND();
+               stage = 7;
+       }
+       res = (int) (r & 0xf);
+       r = r >> 4;
+       stage--;
+       if (res & 8)
+               return res & mv;
+       else
+               return -(res & mv);
+}
+
+static void
+prepare_screen(ModeInfo * mi, slipstruct * s)
+{
+
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       int         i, n, w = s->width / 20;
+       int         not_solid = halfrandom(10);
+
+#ifdef STANDALONE              /* jwz -- sometimes hack the desktop image! */
+       if (halfrandom(2) == 0) {
+#if 0
+               Pixmap      p =
+#endif
+               grab_screen_image(DefaultScreenOfDisplay(display),
+                                 MI_WINDOW(mi));
+
+#if 0
+               if (p)
+                       XFreePixmap(display, p);
+               return;
+#endif
+       }
+#endif
+
+       s->backwards = (int) (LRAND() & 1);     /* jwz: go the other way sometimes */
+
+       if (s->first_time || !halfrandom(10)) {
+               MI_CLEARWINDOW(mi);
+               n = 300;
+       } else {
+               if (halfrandom(5))
+                       return;
+               if (halfrandom(5))
+                       n = 100;
+               else
+                       n = 2000;
+       }
+
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, halfrandom(MI_NPIXELS(mi))));
+       else if (halfrandom(2))
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       else
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+
+       for (i = 0; i < n; i++) {
+               int         ww = ((w / 2) + halfrandom(w));
+
+               if (not_solid) {
+                       if (MI_NPIXELS(mi) > 2)
+                               XSetForeground(display, gc, MI_PIXEL(mi, halfrandom(MI_NPIXELS(mi))));
+                       else if (halfrandom(2))
+                               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+                       else
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               }
+               XFillRectangle(display, MI_WINDOW(mi), gc,
+                              halfrandom(s->width - ww),
+                              halfrandom(s->height - ww),
+                              ww, ww);
+       }
+       s->first_time = 0;
+}
+
+static int
+quantize(double d)
+{
+       int         i = (int) floor(d);
+       double      f = d - i;
+
+       if ((LRAND() & 0xff) < f * 0xff)
+               i++;
+       return i;
+}
+
+void
+init_slip(ModeInfo * mi)
+{
+       slipstruct *sp;
+
+       if (slips == NULL) {
+               if ((slips = (slipstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (slipstruct))) == NULL)
+                       return;
+       }
+       sp = &slips[MI_SCREEN(mi)];
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+
+       sp->blit_width = sp->width / 25;
+       sp->blit_height = sp->height / 25;
+       sp->nblits_remaining = 0;
+       sp->mode = 0;
+       sp->first_time = 1;
+
+       /* no "NoExpose" events from XCopyArea wanted */
+       XSetGraphicsExposures(MI_DISPLAY(mi), MI_GC(mi), False);
+}
+
+void
+draw_slip(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       slipstruct *s = &slips[MI_SCREEN(mi)];
+       int         timer;
+
+       timer = MI_COUNT(mi) * MI_CYCLES(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       while (timer--) {
+               int         xi = halfrandom(s->width - s->blit_width);
+               int         yi = halfrandom(s->height - s->blit_height);
+               double      x, y, dx = 0, dy = 0, t, s1, s2;
+
+               if (0 == s->nblits_remaining--) {
+                       static int  lut[] =
+                       {0, 0, 0, 1, 1, 1, 2};
+
+                       prepare_screen(mi, s);
+                       s->nblits_remaining = MI_COUNT(mi) *
+                               (2000 + halfrandom(1000) + halfrandom(1000));
+                       if (s->mode == 2)
+                               s->mode = halfrandom(2);
+                       else
+                               s->mode = lut[halfrandom(7)];
+               }
+               x = (2 * xi + s->blit_width) / (double) s->width - 1;
+               y = (2 * yi + s->blit_height) / (double) s->height - 1;
+
+               /* (x,y) is in biunit square */
+               switch (s->mode) {
+                       case 0: /* rotor */
+                               dx = x;
+                               dy = y;
+
+                               if (dy < 0) {
+                                       dy += 0.04;
+                                       if (dy > 0)
+                                               dy = 0.00;
+                               }
+                               if (dy > 0) {
+                                       dy -= 0.04;
+                                       if (dy < 0)
+                                               dy = 0.00;
+                               }
+                               t = dx * dx + dy * dy + 1e-10;
+                               s1 = 2 * dx * dx / t - 1;
+                               s2 = 2 * dx * dy / t;
+                               dx = s1 * 5;
+                               dy = s2 * 5;
+
+                               if (s->backwards) {     /* jwz: go the other way sometimes */
+                                       dx = -dx;
+                                       dy = -dy;
+                               }
+                               break;
+                       case 1: /* shuffle */
+                               dx = erandom(3);
+                               dy = erandom(3);
+                               break;
+                       case 2: /* explode */
+                               dx = x * 3;
+                               dy = y * 3;
+                               break;
+               }
+               {
+                       int         qx = xi + quantize(dx), qy = yi + quantize(dy);
+                       int         wrap;
+
+                       if (qx < 0 || qy < 0 ||
+                           qx >= s->width - s->blit_width ||
+                           qy >= s->height - s->blit_height)
+                               continue;
+
+                       XCopyArea(display, window, window, gc, xi, yi,
+                                 s->blit_width, s->blit_height,
+                                 qx, qy);
+
+                       switch (s->mode) {
+                               case 0:
+                                       /* wrap */
+                                       wrap = s->width - (2 * s->blit_width);
+                                       if (qx > wrap)
+                                               XCopyArea(display, window, window, gc, qx, qy,
+                                               s->blit_width, s->blit_height,
+                                                         qx - wrap, qy);
+
+                                       if (qx < 2 * s->blit_width)
+                                               XCopyArea(display, window, window, gc, qx, qy,
+                                               s->blit_width, s->blit_height,
+                                                         qx + wrap, qy);
+
+                                       wrap = s->height - (2 * s->blit_height);
+                                       if (qy > wrap)
+                                               XCopyArea(display, window, window, gc, qx, qy,
+                                               s->blit_width, s->blit_height,
+                                                         qx, qy - wrap);
+
+                                       if (qy < 2 * s->blit_height)
+                                               XCopyArea(display, window, window, gc, qx, qy,
+                                               s->blit_width, s->blit_height,
+                                                         qx, qy + wrap);
+                                       break;
+                               case 1:
+                               case 2:
+                                       break;
+                       }
+               }
+       }
+}
+
+void
+release_slip(ModeInfo * mi)
+{
+       if (slips != NULL) {
+               (void) free((void *) slips);
+               slips = NULL;
+       }
+}
+
+#endif /* MODE_slip */
diff --git a/xlockmore-4.14/modes/space.c b/xlockmore-4.14/modes/space.c
new file mode 100644 (file)
index 0000000..9172526
--- /dev/null
@@ -0,0 +1,424 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* space --- A journey into deep space */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)space.c  4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1998 by Vincent Caron [Vincent.Caron@ecl1999.ec-lyon.fr]
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Space"
+#define HACK_INIT init_space
+#define HACK_DRAW draw_space
+#define space_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*count: 100 \n" \
+ "*size: 15 \n" \
+ "*ncolors: 64 \n" \
+ "*use3d: False \n" \
+ "*delta3d: 1.5 \n" \
+ "*right3d: red \n" \
+ "*left3d: blue \n" \
+ "*both3d: magenta \n" \
+ "*none3d: black \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_space
+
+ModeSpecOpt space_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   space_description =
+{"space", "init_space", "draw_space", "release_space",
+ "refresh_space", "init_space", NULL, &space_opts,
+ 10000, 100, 1, 15, 64, 1.0, "",
+ "a journey into deep space", 0, NULL};
+
+#endif
+
+#define X_LIMIT 400            /* space coords clipping */
+#define Y_LIMIT 300
+#define Z_MAX   450
+#define Z_MIN   (-330)
+#define Z_L2    200            /* far-distance level */
+#define Z_L3    (-150)         /* close-distance level */
+#define DIST    400            /* observer-starfield distance */
+#define TRANS_X_MAX 3          /* cinetic parameters auto-change : */
+#define TRANS_Y_MAX 3          /*   defines limits for cinetic parameters randomizer */
+#define TRANS_Z_MAX 7          /*   idem  */
+#define ROT_X_MAX 60           /*   idem */
+#define ROT_Y_MAX 80           /*   idem */
+#define ROT_Z_MAX 50           /*   idem */
+#define TIME_MIN 500           /*   idem */
+#define TIME_AMP 800           /*   idem */
+#define DEGREE 0.01/100                /* custom angle unit :) */
+
+typedef struct {
+       int         ok;         /* starfield is properly set */
+       int         nb;         /* stars number */
+       int         originX, originY;   /* screen width/2,height/2 */
+       double      zoom;       /* adapt to screen dimensions */
+       double     *starX;      /* star buffer */
+       double     *starY;      /*   holds X,Y,Z coords */
+       double     *starZ;
+       int         ddxn, ddyn, ddzn, daxn, dayn, dazn;         /* counters */
+       double      dx, ddx, dy, ddy, dz, ddz, ax, dax, ay, day, az, daz;       /* cinetic params */
+       int         pixel_nb;   /* number of XPoints in last used pixel buffer */
+       XPoint     *stars1;     /* pixel buffer 1 */
+       XPoint     *stars1copy; /*   left eye or 2D mode */
+       XPoint     *stars1a;    /*   two buffers in stars1a,stars1b */
+       XPoint     *stars1b;
+       XPoint     *stars2;     /* pixel buffer 2 */
+       XPoint     *stars2copy; /*   right eye (3D mode only) */
+       XPoint     *stars2a;    /*   two buffers in stars2a,stars2b */
+       XPoint     *stars2b;
+} SpaceStruct;
+
+static SpaceStruct *spaces = NULL;
+
+void
+init_space(ModeInfo * mi)
+{
+       SpaceStruct *sp;
+       int         i;
+       double      originX, originY, zoom;
+
+       /* allocate a SpaceStruct for every screen */
+       if (spaces == NULL) {
+               if ((spaces = (SpaceStruct *) calloc(MI_NUM_SCREENS(mi), sizeof (SpaceStruct))) == NULL)
+                       return;
+       }
+       sp = &spaces[MI_SCREEN(mi)];
+       /* star density is linked to screen surface */
+       sp->nb = MI_COUNT(mi);
+       originX = sp->originX = MI_WIDTH(mi) / 2;
+       originY = sp->originY = MI_HEIGHT(mi) / 2;
+       zoom = sp->zoom = (double) MI_WIDTH(mi) * 0.54 + 40;
+       sp->ok = 0;
+
+       /* allocate stars buffers for current screen */
+       if ((sp->starX = (double *) calloc(sp->nb, sizeof (double))) == NULL)
+                           return;
+       if ((sp->starY = (double *) calloc(sp->nb, sizeof (double))) == NULL)
+                           return;
+       if ((sp->starZ = (double *) calloc(sp->nb, sizeof (double))) == NULL)
+                           return;
+
+       /* allocate pixels buffers for current screen */
+       if ((sp->stars1a = (XPoint *) calloc(9 * sp->nb, sizeof (XPoint))) == NULL)
+               return;
+       if ((sp->stars1b = (XPoint *) calloc(9 * sp->nb, sizeof (XPoint))) == NULL)
+               return;
+       if (MI_IS_USE3D(mi)) {
+               if ((sp->stars2a = (XPoint *) calloc(9 * sp->nb, sizeof (XPoint))) == NULL)
+                       return;
+               if ((sp->stars2b = (XPoint *) calloc(9 * sp->nb, sizeof (XPoint))) == NULL)
+                       return;
+       }
+       sp->ok = 1;             /* mem allocations succeeded */
+       sp->pixel_nb = 0;
+       sp->stars1 = sp->stars1a;
+       sp->stars1copy = sp->stars1b;
+       sp->stars2 = sp->stars2a;
+       sp->stars2copy = sp->stars2b;
+
+       /* place stars randomly */
+       for (i = 0; i < sp->nb; i++) {
+               sp->starX[i] = ((double) NRAND(10000) / 5000 - 1) * X_LIMIT;
+               sp->starY[i] = ((double) NRAND(10000) / 5000 - 1) * Y_LIMIT;
+               sp->starZ[i] = (double) NRAND(10000) / 10000 * (Z_MAX - Z_MIN) + Z_MIN;
+       }
+       sp->dx = 0;
+       sp->ddxn = 0;
+       sp->dy = 0;
+       sp->ddyn = 0;
+       sp->dz = 3;
+       sp->ddzn = 0;
+       sp->ax = 0;
+       sp->daxn = 0;
+       sp->ay = 0;
+       sp->dayn = 0;
+       sp->az = 0;
+       sp->dazn = 0;
+
+       /* clear screen */
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_space(ModeInfo * mi)
+{
+       int         i, n, originX, originY, x, x2 = 0, y, IS_SMALL;
+       double      _x, _y, _z, cosX, sinX, cosY, sinY, cosZ, sinZ, k, z,
+                   zoom;
+
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       int         is3D = MI_IS_USE3D(mi);
+       double      delta = MI_DELTA3D(mi) * 8;
+       SpaceStruct *sp;
+
+       if (spaces == NULL)
+               return;
+       sp = &spaces[MI_SCREEN(mi)];
+       if (!sp->ok)
+               return;
+       originX = sp->originX;
+       originY = sp->originY;
+       zoom = sp->zoom;
+       IS_SMALL = ((originX * originY) < (160 * 100));
+
+       /* get cos & sin of rotations */
+       cosX = COSF(sp->ax);
+       sinX = SINF(sp->ax);
+       cosY = COSF(sp->ay);
+       sinY = SINF(sp->ay);
+       cosZ = COSF(sp->az);
+       sinZ = SINF(sp->az);
+
+       /* move stars ! */
+       for (i = 0; i < sp->nb; i++) {
+               _x = sp->starX[i];
+               _y = sp->starY[i];
+               _z = sp->starZ[i];
+
+               /* X,Y & Z axis rotations */
+               k = _y * cosX + _z * sinX;
+               _z = _z * cosX - _y * sinX;
+               _y = k;
+               k = _x * cosY + _z * sinY;
+               _z = _z * cosY - _x * sinY;
+               _x = k;
+               k = _x * cosZ + _y * sinZ;
+               _y = _y * cosZ - _x * sinZ;
+               _x = k;
+
+               /* translations + space boundary overflow */
+               _x += sp->dx;
+               if (_x < (-X_LIMIT))
+                       _x = X_LIMIT;
+               else if (_x > X_LIMIT)
+                       _x = -X_LIMIT;
+               _y += sp->dy;
+               if (_y < (-Y_LIMIT))
+                       _y = Y_LIMIT;
+               else if (_y > Y_LIMIT)
+                       _y = -Y_LIMIT;
+               _z -= sp->dz;
+               if (_z < Z_MIN)
+                       _z = Z_MAX;
+               else if (_z > Z_MAX)
+                       _z = Z_MIN;
+
+               sp->starX[i] = _x;
+               sp->starY[i] = _y;
+               sp->starZ[i] = _z;
+       }
+
+       /* update translation parameters */
+       if (sp->ddxn == 0) {
+               k = (double) NRAND(TRANS_X_MAX * 2) - TRANS_X_MAX;
+               sp->ddxn = (int) NRAND(TIME_AMP) + TIME_MIN;
+               sp->ddx = (k - sp->dx) / sp->ddxn;
+       } else {
+               sp->dx += sp->ddx;
+               sp->ddxn--;
+       }
+       if (sp->ddyn == 0) {
+               k = (double) NRAND(TRANS_Y_MAX * 2) - TRANS_Y_MAX;
+               sp->ddyn = (int) NRAND(TIME_AMP) + TIME_MIN;
+               sp->ddy = (k - sp->dy) / sp->ddyn;
+       } else {
+               sp->dy += sp->ddy;
+               sp->ddyn--;
+       }
+       if (sp->ddzn == 0) {
+               k = (double) NRAND(TRANS_Z_MAX * 2) - TRANS_Z_MAX;
+               sp->ddzn = (int) NRAND(TIME_AMP) + TIME_MIN;
+               sp->ddz = (k - sp->dz) / sp->ddzn;
+       } else {
+               sp->dz += sp->ddz;
+               sp->ddzn--;
+       }
+
+       /* update rotation parameters */
+       if (sp->daxn == 0) {
+               k = (double) (NRAND(ROT_X_MAX * 2) - ROT_X_MAX) * DEGREE;
+               sp->daxn = (int) NRAND(TIME_AMP) + TIME_MIN;
+               sp->dax = (k - sp->ax) / sp->daxn;
+       } else {
+               sp->ax += sp->dax;
+               sp->daxn--;
+       }
+       if (sp->dayn == 0) {
+               k = (double) (NRAND(ROT_Y_MAX * 2) - ROT_Y_MAX) * DEGREE;
+               sp->dayn = (int) NRAND(TIME_AMP) + TIME_MIN;
+               sp->day = (k - sp->ay) / sp->dayn;
+       } else {
+               sp->ay += sp->day;
+               sp->dayn--;
+       }
+       if (sp->dazn == 0) {
+               k = (double) (NRAND(ROT_Z_MAX * 2) - ROT_Z_MAX) * DEGREE;
+               sp->dazn = (int) NRAND(TIME_AMP) + TIME_MIN;
+               sp->daz = (k - sp->az) / sp->dazn;
+       } else {
+               sp->az += sp->daz;
+               sp->dazn--;
+       }
+
+       /* project stars and create corresponding pixels */
+       n = 0;
+       for (i = 0; i < sp->nb; i++) {
+               z = sp->starZ[i];
+               k = zoom / (z + DIST);
+               y = sp->stars1[n].y = originY - (int) (k * sp->starY[i]);
+               if (is3D) {
+                       x = sp->stars1[n].x = originX + (int) (k * (sp->starX[i] - delta));
+                       x2 = sp->stars2[n].x = originX + (int) (k * (sp->starX[i] + delta));
+                       sp->stars2[n].y = y;
+               } else
+                       x = sp->stars1[n].x = originX + (int) (k * sp->starX[i]);
+               n++;
+               if (z < Z_L2) {
+                       /* not to close but closer : use 4 more pixels for this star */
+                       sp->stars1[n].x = x + 1;
+                       sp->stars1[n].y = y;
+                       sp->stars1[n + 1].x = x - 1;
+                       sp->stars1[n + 1].y = y;
+                       sp->stars1[n + 2].x = x;
+                       sp->stars1[n + 2].y = y + 1;
+                       sp->stars1[n + 3].x = x;
+                       sp->stars1[n + 3].y = y - 1;
+                       if (is3D) {
+                               sp->stars2[n].x = x2 + 1;
+                               sp->stars2[n].y = y;
+                               sp->stars2[n + 1].x = x2 - 1;
+                               sp->stars2[n + 1].y = y;
+                               sp->stars2[n + 2].x = x2;
+                               sp->stars2[n + 2].y = y + 1;
+                               sp->stars2[n + 3].x = x2;
+                               sp->stars2[n + 3].y = y - 1;
+                       }
+                       n += 4;
+               }
+               if ((z < Z_L3) && (!IS_SMALL)) {
+                       /* very close : use again 4 more pixels (makes 9 for this star) */
+                       sp->stars1[n].x = x - 1;
+                       sp->stars1[n].y = y + 1;
+                       sp->stars1[n + 1].x = x - 1;
+                       sp->stars1[n + 1].y = y - 1;
+                       sp->stars1[n + 2].x = x + 1;
+                       sp->stars1[n + 2].y = y + 1;
+                       sp->stars1[n + 3].x = x + 1;
+                       sp->stars1[n + 3].y = y - 1;
+                       if (is3D) {
+                               sp->stars2[n].x = x2 - 1;
+                               sp->stars2[n].y = y + 1;
+                               sp->stars2[n + 1].x = x2 - 1;
+                               sp->stars2[n + 1].y = y - 1;
+                               sp->stars2[n + 2].x = x2 + 1;
+                               sp->stars2[n + 2].y = y + 1;
+                               sp->stars2[n + 3].x = x2 + 1;
+                               sp->stars2[n + 3].y = y - 1;
+                       }
+                       n += 4;
+               }
+       }
+
+       /* erase pixels with previous pixel buffer */
+       if (MI_IS_INSTALL(mi) && is3D)
+               XSetForeground(display, gc, MI_NONE_COLOR(mi));
+       else
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       XDrawPoints(display, window, gc, sp->stars1copy, sp->pixel_nb, CoordModeOrigin);
+       if (is3D)
+               XDrawPoints(display, window, gc, sp->stars2copy, sp->pixel_nb, CoordModeOrigin);
+
+       /* draw pixels */
+       sp->pixel_nb = n;
+       if (is3D) {
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXor);
+               XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               XDrawPoints(display, window, gc, sp->stars1, sp->pixel_nb, CoordModeOrigin);
+               XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+               XDrawPoints(display, window, gc, sp->stars2, sp->pixel_nb, CoordModeOrigin);
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXcopy);
+       } else {
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               XDrawPoints(display, window, gc, sp->stars1, sp->pixel_nb, CoordModeOrigin);
+       }
+       XFlush(display);
+
+       /* swap pixel buffers a & b */
+       if (sp->stars1 == sp->stars1a) {
+               sp->stars1 = sp->stars1b;
+               sp->stars1copy = sp->stars1a;
+       } else {
+               sp->stars1 = sp->stars1a;
+               sp->stars1copy = sp->stars1b;
+       }
+       if (sp->stars2 == sp->stars2a) {
+               sp->stars2 = sp->stars2b;
+               sp->stars2copy = sp->stars2a;
+       } else {
+               sp->stars2 = sp->stars2a;
+               sp->stars2copy = sp->stars2b;
+       }
+}
+
+void
+refresh_space(ModeInfo * mi)
+{
+       /* Do nothing, it will refresh by itself */
+}
+
+void
+release_space(ModeInfo * mi)
+{
+       int         i;
+       SpaceStruct *sp;
+
+       if (spaces != NULL) {
+               for (i = 0; i < MI_NUM_SCREENS(mi); i++) {
+                       sp = &spaces[i];
+                       (void) free((void *) sp->starX);
+                       (void) free((void *) sp->starY);
+                       (void) free((void *) sp->starZ);
+                       (void) free((void *) sp->stars1a);
+                       (void) free((void *) sp->stars1b);
+                       if (MI_IS_USE3D(mi)) {
+                               (void) free((void *) sp->stars2a);
+                               (void) free((void *) sp->stars2b);
+                       }
+               }
+               (void) free((void *) spaces);
+               spaces = NULL;
+       }
+}
+
+#endif /* MODE_space */
diff --git a/xlockmore-4.14/modes/sphere.c b/xlockmore-4.14/modes/sphere.c
new file mode 100644 (file)
index 0000000..2c6d0b7
--- /dev/null
@@ -0,0 +1,293 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* sphere --- a bunch of shaded spheres */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)sphere.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1988 by Sun Microsystems
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 30-May-97: <jwz@jwz.org> made it go vertically as well as horizontally.
+ * 27-May-97: <jwz@jwz.org> turned into a standalone program.
+ * 02-Sep-93: xlock version David Bagley <bagleyd@tux.org>
+ * 1988: Revised to use SunView canvas instead of gfxsw Sun Microsystems
+ * 1982: Orignal Algorithm Tom Duff Lucasfilm Ltd.
+ */
+
+/*-
+ * original copyright
+ * **************************************************************************
+ * Copyright 1988 by Sun Microsystems, Inc. Mountain View, CA.
+ *
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the names of Sun or MIT not be used in advertising
+ * or publicity pertaining to distribution of the software without specific
+ * prior written permission. Sun and M.I.T. make no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
+ * without any express or implied warranty.
+ *
+ * SUN DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ * IN NO EVENT SHALL SUN BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
+ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
+ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
+ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+ * SOFTWARE.
+ * ***************************************************************************
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Sphere"
+#define HACK_INIT init_sphere
+#define HACK_DRAW draw_sphere
+#define sphere_opts xlockmore_opts
+#define DEFAULTS "*delay: 5000 \n" \
+ "*cycles: 20 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 64 \n"
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_sphere
+
+ModeSpecOpt sphere_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   sphere_description =
+{"sphere", "init_sphere", "draw_sphere", "release_sphere",
+ "refresh_sphere", "init_sphere", NULL, &sphere_opts,
+ 5000, 1, 20, 0, 64, 1.0, "",
+ "Shows a bunch of shaded spheres", 0, NULL};
+
+#endif
+
+/*-
+ * (NX, NY, NZ) is the light source vector -- length should be 100
+ */
+#define NX 48
+#define NY (-36)
+#define NZ 80
+#define NR 100
+#define SQRT(a) ((int)sqrt((double)(a)))
+
+typedef struct {
+       int         width, height;
+       int         radius;
+       int         x0;         /* x center */
+       int         y0;         /* y center */
+       int         color;
+       int         x, y;
+       int         dirx, diry;
+       int         shadowx, shadowy;
+       int         maxx, maxy;
+       XPoint     *points;
+} spherestruct;
+
+static spherestruct *spheres = NULL;
+
+void
+init_sphere(ModeInfo * mi)
+{
+       spherestruct *sp;
+
+       if (spheres == NULL) {
+               if ((spheres = (spherestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (spherestruct))) == NULL)
+                       return;
+       }
+       sp = &spheres[MI_SCREEN(mi)];
+
+       if (sp->points) {
+               (void) free((void *) sp->points);
+               sp->points = NULL;
+       }
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+       sp->points = (XPoint *) malloc(sp->height * sizeof (XPoint));
+
+       MI_CLEARWINDOW(mi);
+
+       sp->dirx = 1;
+       sp->x = sp->radius;
+       sp->shadowx = (LRAND() & 1) ? 1 : -1;
+       sp->shadowy = (LRAND() & 1) ? 1 : -1;
+}
+
+void
+draw_sphere(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       spherestruct *sp = &spheres[MI_SCREEN(mi)];
+       int         sqrd, nd;
+       register int minx = 0, maxx = 0, miny = 0, maxy = 0, npts = 0;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if ((sp->dirx && ABS(sp->x) >= sp->radius) ||
+           (sp->diry && ABS(sp->y) >= sp->radius)) {
+               sp->radius = NRAND(MIN(sp->width / 2, sp->height / 2) - 1) + 1;
+
+               if (LRAND() & 1) {
+                       sp->dirx = (int) (LRAND() & 1) * 2 - 1;
+                       sp->diry = 0;
+               } else {
+                       sp->dirx = 0;
+                       sp->diry = (int) (LRAND() & 1) * 2 - 1;
+               }
+               sp->x0 = NRAND(sp->width);
+               sp->y0 = NRAND(sp->height);
+
+               sp->x = -sp->radius * sp->dirx;
+               sp->y = -sp->radius * sp->diry;
+
+               if (MI_NPIXELS(mi) > 2)
+                       sp->color = NRAND(MI_NPIXELS(mi));
+       }
+       if (sp->dirx == 1) {
+               if (sp->x0 + sp->x < 0)
+                       sp->x = -sp->x0;
+       } else if (sp->dirx == -1) {
+               if (sp->x0 + sp->x >= sp->width)
+                       sp->x = sp->width - sp->x0 - 1;
+       }
+       if (sp->diry == 1) {
+               if (sp->y0 + sp->y < 0)
+                       sp->y = -sp->y0;
+       } else if (sp->diry == -1) {
+               if (sp->y0 + sp->y >= sp->height)
+                       sp->y = sp->height - sp->y0 - 1;
+       }
+       if (sp->dirx) {
+               sp->maxy = SQRT(sp->radius * sp->radius - sp->x * sp->x);
+               miny = -sp->maxy;
+               if (sp->y0 - sp->maxy < 0)
+                       miny = -sp->y0;
+               maxy = sp->maxy;
+       }
+       if (sp->diry) {
+               sp->maxx = SQRT(sp->radius * sp->radius - sp->y * sp->y);
+               minx = -sp->maxx;
+               if (sp->x0 - sp->maxx < 0)
+                       minx = -sp->x0;
+               maxx = sp->maxx;
+       }
+       if (sp->dirx) {
+               if (sp->y0 + sp->maxy >= sp->height)
+                       maxy = sp->height - sp->y0;
+       }
+       if (sp->diry) {
+               if (sp->x0 + sp->maxx >= sp->width)
+                       maxx = sp->width - sp->x0;
+       }
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+
+       if (sp->dirx)
+               XDrawLine(display, MI_WINDOW(mi), gc,
+               sp->x0 + sp->x, sp->y0 + miny, sp->x0 + sp->x, sp->y0 + maxy);
+       if (sp->diry)
+               XDrawLine(display, MI_WINDOW(mi), gc,
+               sp->x0 + minx, sp->y0 + sp->y, sp->x0 + maxx, sp->y0 + sp->y);
+
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, sp->color));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       if (sp->dirx) {
+               sqrd = sp->radius * sp->radius - sp->x * sp->x;
+               nd = NX * sp->shadowx * sp->x;
+               for (sp->y = miny; sp->y <= maxy; sp->y++)
+                       if ((NRAND(sp->radius * NR)) <= nd + NY * sp->shadowy * sp->y +
+                           NZ * SQRT(sqrd - sp->y * sp->y)) {
+                               sp->points[npts].x = sp->x + sp->x0;
+                               sp->points[npts].y = sp->y + sp->y0;
+                               npts++;
+                       }
+       }
+       if (sp->diry) {
+               sqrd = sp->radius * sp->radius - sp->y * sp->y;
+               nd = NY * sp->shadowy * sp->y;
+               for (sp->x = minx; sp->x <= maxx; sp->x++)
+                       if ((NRAND(sp->radius * NR)) <= NX * sp->shadowx * sp->x + nd +
+                           NZ * SQRT(sqrd - sp->x * sp->x)) {
+                               sp->points[npts].x = sp->x + sp->x0;
+                               sp->points[npts].y = sp->y + sp->y0;
+                               npts++;
+                       }
+       }
+       XDrawPoints(display, MI_WINDOW(mi), gc, sp->points, npts, CoordModeOrigin);
+       if (sp->dirx == 1) {
+               sp->x++;
+               if (sp->x0 + sp->x >= sp->width)
+                       sp->x = sp->radius;
+       } else if (sp->dirx == -1) {
+               sp->x--;
+               if (sp->x0 + sp->x < 0)
+                       sp->x = -sp->radius;
+       }
+       if (sp->diry == 1) {
+               sp->y++;
+               if (sp->y0 + sp->y >= sp->height)
+                       sp->y = sp->radius;
+       } else if (sp->diry == -1) {
+               sp->y--;
+               if (sp->y0 + sp->y < 0)
+                       sp->y = -sp->radius;
+       }
+}
+
+void
+release_sphere(ModeInfo * mi)
+{
+       if (spheres != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       spherestruct *sp = &spheres[screen];
+
+                       if (sp->points) {
+                               (void) free((void *) sp->points);
+                               sp->points = NULL;
+                       }
+               }
+               (void) free((void *) spheres);
+               spheres = NULL;
+       }
+}
+
+void
+refresh_sphere(ModeInfo * mi)
+{
+       spherestruct *sp = &spheres[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+
+       sp->x = -sp->radius;
+}
+
+#endif /* MODE_sphere */
diff --git a/xlockmore-4.14/modes/spiral.c b/xlockmore-4.14/modes/spiral.c
new file mode 100644 (file)
index 0000000..717cd63
--- /dev/null
@@ -0,0 +1,316 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* spiral --- spiraling dots */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)spiral.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1994 by Darrick Brown.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: jwz@jwz.org: turned into a standalone program.
+ * 24-Jul-95: Fix to allow cycles not to have an arbitrary value by
+ *            Peter Schmitzberger (schmitz@coma.sbg.ac.at).
+ * 06-Mar-95: Finished cleaning up and final testing.
+ * 03-Mar-95: Cleaned up code.
+ * 12-Jul-94: Written.
+ *
+ * Low CPU usage mode.
+ * Idea based on a graphics demo I saw a *LONG* time ago.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Spiral"
+#define HACK_INIT init_spiral
+#define HACK_DRAW draw_spiral
+#define spiral_opts xlockmore_opts
+#define DEFAULTS "*delay: 5000 \n" \
+ "*count: -40 \n" \
+ "*cycles: 350 \n" \
+ "*ncolors: 64 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_spiral
+
+ModeSpecOpt spiral_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   spiral_description =
+{"spiral", "init_spiral", "draw_spiral", "release_spiral",
+ "refresh_spiral", "init_spiral", NULL, &spiral_opts,
+ 5000, -40, 350, 1, 64, 1.0, "",
+ "Shows a helical locus of points", 0, NULL};
+
+#endif
+
+#define MAXTRAIL 512           /* The length of the trail */
+#define MAXDOTS 40
+#define MINDOTS 1
+#define TWOPI (2.0*M_PI)       /* for convienence */
+#define JAGGINESS 4            /* This sets the "Craziness" of the spiral (I like 4) */
+#define SPEED 2.0
+
+/* How many segments to draw per cycle when redrawing */
+#define REDRAWSTEP 3
+
+
+typedef struct {
+       float       hx, hy, ha, hr;
+} Traildots;
+
+typedef struct {
+       Traildots  *traildots;
+       float       cx, cy;
+       float       angle;
+       float       radius;
+       float       dr, da;
+       float       dx, dy;
+       int         erase;
+       int         inc;
+       float       colors;
+       int         width, height;
+       float       top, bottom, left, right;
+       int         dots, nlength;
+       int         redrawing, redrawpos;
+} spiralstruct;
+
+static spiralstruct *spirals = NULL;
+
+static void draw_dots(ModeInfo * mi, int in);
+
+#define TFX(sp,x) ((int)((x/sp->right)*(float)sp->width))
+#define TFY(sp,y) ((int)((y/sp->top)*(float)sp->height))
+
+static void
+draw_dots(ModeInfo * mi, int in)
+{
+
+       float       i, inc;
+       float       x, y;
+
+       spiralstruct *sp = &spirals[MI_SCREEN(mi)];
+
+       inc = TWOPI / (float) sp->dots;
+       for (i = 0.0; i < TWOPI; i += inc) {
+               x = sp->traildots[in].hx + COSF(i + sp->traildots[in].ha) *
+                       sp->traildots[in].hr;
+               y = sp->traildots[in].hy + SINF(i + sp->traildots[in].ha) *
+                       sp->traildots[in].hr;
+               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+                          TFX(sp, x), TFY(sp, y));
+       }
+}
+
+void
+init_spiral(ModeInfo * mi)
+{
+       spiralstruct *sp;
+       int         i;
+
+       if (spirals == NULL) {
+               if ((spirals = (spiralstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (spiralstruct))) == NULL)
+                       return;
+       }
+       sp = &spirals[MI_SCREEN(mi)];
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+
+       MI_CLEARWINDOW(mi);
+
+       /* Init */
+       sp->nlength = MI_CYCLES(mi);
+
+       if (!sp->traildots)
+               sp->traildots = (Traildots *) malloc(sp->nlength * sizeof (Traildots));
+
+       /* initialize the allocated array */
+       for (i = 0; i < sp->nlength; i++) {
+               sp->traildots[i].hx = 0.0;
+               sp->traildots[i].hy = 0.0;
+               sp->traildots[i].ha = 0.0;
+               sp->traildots[i].hr = 0.0;
+       }
+       sp->redrawing = 0;
+
+       /* keep the window parameters proportional */
+       sp->top = 10000.0;
+       sp->bottom = 0;
+       sp->right = (float) (sp->width) / (float) (sp->height) * (10000.0);
+       sp->left = 0;
+
+       /* assign the initial values */
+       sp->cx = (float) (5000.0 - NRAND(2000)) / 10000.0 * sp->right;
+       sp->cy = (float) (5000.0 - NRAND(2000));
+       sp->radius = (float) (NRAND(200) + 200);
+       sp->angle = 0.0;
+       sp->dx = (float) (10 - NRAND(20)) * SPEED;
+       sp->dy = (float) (10 - NRAND(20)) * SPEED;
+       sp->dr = (float) ((NRAND(10) + 4) * (1 - (LRAND() & 1) * 2));
+       sp->da = (float) NRAND(360) / 7200.0 + 0.01;
+       if (MI_NPIXELS(mi) > 2)
+               sp->colors = (float) NRAND(MI_NPIXELS(mi));
+       sp->erase = 0;
+       sp->inc = 0;
+       sp->traildots[sp->inc].hx = sp->cx;
+       sp->traildots[sp->inc].hy = sp->cy;
+       sp->traildots[sp->inc].ha = sp->angle;
+       sp->traildots[sp->inc].hr = sp->radius;
+       sp->inc++;
+
+       sp->dots = MI_COUNT(mi);
+       if (sp->dots < -MINDOTS)
+               sp->dots = NRAND(sp->dots - MINDOTS + 1) + MINDOTS;
+       /* Absolute minimum */
+       if (sp->dots < MINDOTS)
+               sp->dots = MINDOTS;
+}
+
+void
+draw_spiral(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       spiralstruct *sp = &spirals[MI_SCREEN(mi)];
+       int         i, j;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (sp->erase == 1) {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               draw_dots(mi, sp->inc);
+       }
+       sp->cx += sp->dx;
+       sp->traildots[sp->inc].hx = sp->cx;
+
+       if ((sp->cx > 9000.0) || (sp->cx < 1000.0))
+               sp->dx *= -1.0;
+
+       sp->cy += sp->dy;
+       sp->traildots[sp->inc].hy = sp->cy;
+
+       if ((sp->cy > 9000.0) || (sp->cy < 1000.0))
+               sp->dy *= -1.0;
+
+       sp->radius += sp->dr;
+       sp->traildots[sp->inc].hr = sp->radius;
+
+       if ((sp->radius > 2500.0) && (sp->dr > 0.0))
+               sp->dr *= -1.0;
+       else if ((sp->radius < 50.0) && (sp->radius < 0.0))
+               sp->dr *= -1.0;
+
+       /* Randomly give some variations to:  */
+
+       /* spiral direction (if it is within the boundaries) */
+       if ((NRAND(3000) < 1 * JAGGINESS) &&
+           (((sp->cx > 2000.0) && (sp->cx < 8000.0)) &&
+            ((sp->cy > 2000.0) && (sp->cy < 8000.0)))) {
+               sp->dx = (float) (10 - NRAND(20)) * SPEED;
+               sp->dy = (float) (10 - NRAND(20)) * SPEED;
+       }
+       /* The speed of the change in size of the spiral */
+       if (NRAND(3000) < 1 * JAGGINESS) {
+               if (LRAND() & 1)
+                       sp->dr += (float) (NRAND(3) + 1);
+               else
+                       sp->dr -= (float) (NRAND(3) + 1);
+
+               /* don't let it get too wild */
+               if (sp->dr > 18.0)
+                       sp->dr = 18.0;
+               else if (sp->dr < 4.0)
+                       sp->dr = 4.0;
+       }
+       /* The speed of rotation */
+       if (NRAND(3000) < 1 * JAGGINESS)
+               sp->da = (float) NRAND(360) / 7200.0 + 0.01;
+
+       /* Reverse rotation */
+       if (NRAND(3000) < 1 * JAGGINESS)
+               sp->da *= -1.0;
+
+       sp->angle += sp->da;
+       sp->traildots[sp->inc].ha = sp->angle;
+
+       if (sp->angle > TWOPI)
+               sp->angle -= TWOPI;
+       else if (sp->angle < 0.0)
+               sp->angle += TWOPI;
+
+       sp->colors += (float) MI_NPIXELS(mi) / ((float) (2 * sp->nlength));
+       if (sp->colors >= (float) MI_NPIXELS(mi))
+               sp->colors = 0.0;
+
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(display, gc, MI_PIXEL(mi, (int) sp->colors));
+       else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       draw_dots(mi, sp->inc);
+       sp->inc++;
+
+       if (sp->inc > sp->nlength - 1) {
+               sp->inc -= sp->nlength;
+               sp->erase = 1;
+       }
+       if (sp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       j = (sp->inc - sp->redrawpos + sp->nlength) % sp->nlength;
+                       draw_dots(mi, j);
+
+                       if (++(sp->redrawpos) >= sp->nlength) {
+                               sp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+void
+release_spiral(ModeInfo * mi)
+{
+       if (spirals != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       spiralstruct *sp = &spirals[screen];
+
+                       if (sp->traildots)
+                               (void) free((void *) sp->traildots);
+               }
+               (void) free((void *) spirals);
+               spirals = NULL;
+       }
+}
+
+void
+refresh_spiral(ModeInfo * mi)
+{
+       spiralstruct *sp = &spirals[MI_SCREEN(mi)];
+
+       MI_CLEARWINDOW(mi);
+       sp->redrawing = 1;
+       sp->redrawpos = 0;
+}
+
+#endif /* MODE_spiral */
diff --git a/xlockmore-4.14/modes/spline.c b/xlockmore-4.14/modes/spline.c
new file mode 100644 (file)
index 0000000..03c805d
--- /dev/null
@@ -0,0 +1,429 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* spline --- spline fun */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)spline.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1992 by Jef Poskanzer
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 13-Sep-96: changed FOLLOW to a runtime option "-erase"
+ * 17-Jan-96: added compile time option, FOLLOW to erase old splines like Qix
+ *           thanks to Richard Duran <rduran@cs.utep.edu>
+ * 9-Mar-95: changed how batchcount is used
+ * 2-Sep-93: xlock version: David Bagley <bagleyd@tux.org>
+ *           reminds me of a great "Twilight Zone" episode.
+ * 1992:     X11 version Jef Poskanzer <jef@netcom.com>, <jef@well.sf.ca.us>
+ *
+ * spline fun #3 
+ */
+
+/*-
+ * original copyright
+ * xsplinefun.c - X11 version of spline fun #3
+ * Displays colorful moving splines in the X11 root window.
+ * Copyright (C) 1992 by Jef Poskanzer
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  This software is provided "as is" without express or
+ * implied warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Spline"
+#define HACK_INIT init_spline
+#define HACK_DRAW draw_spline
+#define spline_opts xlockmore_opts
+#define DEFAULTS "*delay: 30000 \n" \
+ "*count: -6 \n" \
+ "*cycles: 2048 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n"
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_spline
+
+#define DEF_ERASE  "False"
+
+static Bool erase;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-erase", ".spline.erase", XrmoptionNoArg, (caddr_t) "on"},
+       {"+erase", ".spline.erase", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & erase, "erase", "Erase", DEF_ERASE, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-/+erase", "turn on/off the following erase of splines"}
+};
+
+ModeSpecOpt spline_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   spline_description =
+{"spline", "init_spline", "draw_spline", "release_spline",
+ "refresh_spline", "init_spline", NULL, &spline_opts,
+ 30000, -6, 2048, 1, 64, 0.3, "",
+ "Shows colorful moving splines", 0, NULL};
+
+#endif
+
+#define MINPOINTS 3
+
+/* How many segments to draw per cycle when redrawing */
+#define REDRAWSTEP 3
+
+#define SPLINE_THRESH 5
+
+typedef struct {
+       XPoint      pos, delta;
+} splinepointstruct;
+
+typedef struct {
+       /* ERASE stuff */
+       int         first;
+       int         last;
+       int         max_delta;
+       XPoint    **splineq;
+       int         redrawing, redrawpos;
+       Bool        erase;
+
+       int         width;
+       int         height;
+       int         color;
+       int         points;
+       int         nsplines;
+       splinepointstruct *pt;
+} splinestruct;
+
+static splinestruct *splines = NULL;
+
+static void XDrawSpline(Display * display, Drawable d, GC gc,
+                       int x0, int y0, int x1, int y1, int x2, int y2);
+
+void
+init_spline(ModeInfo * mi)
+{
+       splinestruct *sp;
+       int         i;
+
+       if (splines == NULL) {
+               if ((splines = (splinestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (splinestruct))) == NULL)
+                       return;
+       }
+       sp = &splines[MI_SCREEN(mi)];
+
+       if (MI_IS_FULLRANDOM(mi))
+               sp->erase = (Bool) (LRAND() & 1);
+       else
+               sp->erase = erase;
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+       /* batchcount is the upper bound on the number of points */
+       sp->points = MI_COUNT(mi);
+       if (sp->points < -MINPOINTS) {
+               if (sp->pt) {
+                       (void) free((void *) sp->pt);
+                       sp->pt = NULL;
+               }
+               if (sp->erase) {
+                       if (sp->splineq)
+                               for (i = 0; i < sp->nsplines; ++i)
+                                       if (sp->splineq[i]) {
+                                               (void) free((void *) sp->splineq[i]);
+                                               sp->splineq[i] = NULL;
+                                       }
+               }
+               sp->points = NRAND(-sp->points - MINPOINTS + 1) + MINPOINTS;
+       } else if (sp->points < MINPOINTS)
+               sp->points = MINPOINTS;
+       if (!sp->pt)
+               sp->pt = (splinepointstruct *) malloc(sp->points *
+                                                sizeof (splinepointstruct));
+
+       if (sp->erase) {
+               sp->max_delta = 16;
+               sp->redrawing = 0;
+               sp->last = 0;
+               sp->nsplines = MI_CYCLES(mi) / 64 + 1;  /* So as to be compatible */
+               if (!sp->splineq)
+                       sp->splineq = (XPoint **) calloc(sp->nsplines, sizeof (XPoint *));
+               for (i = 0; i < sp->nsplines; ++i)
+                       if (!sp->splineq[i])
+                               sp->splineq[i] = (XPoint *) calloc(sp->points, sizeof (XPoint));
+       } else {
+               sp->max_delta = 3;
+               sp->nsplines = 0;
+       }
+
+       MI_CLEARWINDOW(mi);
+
+       /* Initialize points. */
+       for (i = 0; i < sp->points; ++i) {
+               sp->pt[i].pos.x = NRAND(sp->width);
+               sp->pt[i].pos.y = NRAND(sp->height);
+               sp->pt[i].delta.x = NRAND(sp->max_delta * 2) - sp->max_delta;
+               if (sp->pt[i].delta.x <= 0 && sp->width > 1)
+                       --sp->pt[i].delta.x;
+               sp->pt[i].delta.y = NRAND(sp->max_delta * 2) - sp->max_delta;
+               if (sp->pt[i].delta.y <= 0 && sp->height > 1)
+                       --sp->pt[i].delta.y;
+       }
+       if (MI_NPIXELS(mi) > 2)
+               sp->color = NRAND(MI_NPIXELS(mi));
+}
+
+void
+draw_spline(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       splinestruct *sp = &splines[MI_SCREEN(mi)];
+       int         i, t, px, py, zx, zy, nx, ny;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (sp->erase)
+               sp->first = (sp->last + 2) % sp->nsplines;
+
+       /* Move the points. */
+       for (i = 0; i < sp->points; i++) {
+               for (;;) {
+                       t = sp->pt[i].pos.x + sp->pt[i].delta.x;
+                       if (t >= 0 && t < sp->width)
+                               break;
+                       sp->pt[i].delta.x = NRAND(sp->max_delta * 2) - sp->max_delta;
+                       if (sp->pt[i].delta.x <= 0 && sp->width > 1)
+                               --sp->pt[i].delta.x;
+               }
+               sp->pt[i].pos.x = t;
+               for (;;) {
+                       t = sp->pt[i].pos.y + sp->pt[i].delta.y;
+                       if (t >= 0 && t < sp->height)
+                               break;
+                       sp->pt[i].delta.y = NRAND(sp->max_delta * 2) - sp->max_delta;
+                       if (sp->pt[i].delta.y <= 0 && sp->height > 1)
+                               --sp->pt[i].delta.y;
+               }
+               sp->pt[i].pos.y = t;
+       }
+
+       if (sp->erase) {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+
+               /* Erase first figure. */
+               px = zx = (sp->splineq[sp->first][0].x +
+                          sp->splineq[sp->first][sp->points - 1].x) / 2;
+               py = zy = (sp->splineq[sp->first][0].y +
+                          sp->splineq[sp->first][sp->points - 1].y) / 2;
+               for (i = 0; i < sp->points - 1; ++i) {
+                       nx = (sp->splineq[sp->first][i + 1].x +
+                             sp->splineq[sp->first][i].x) / 2;
+                       ny = (sp->splineq[sp->first][i + 1].y +
+                             sp->splineq[sp->first][i].y) / 2;
+                       XDrawSpline(display, window, gc,
+                                   px, py, sp->splineq[sp->first][i].x,
+                                   sp->splineq[sp->first][i].y, nx, ny);
+                       px = nx;
+                       py = ny;
+               }
+
+               XDrawSpline(display, window, gc,
+                           px, py, sp->splineq[sp->first][sp->points - 1].x,
+                           sp->splineq[sp->first][sp->points - 1].y, zx, zy);
+       }
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, sp->color));
+               if (++sp->color >= MI_NPIXELS(mi))
+                       sp->color = 0;
+       } else
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+
+       /* Draw the figure. */
+       px = zx = (sp->pt[0].pos.x + sp->pt[sp->points - 1].pos.x) / 2;
+       py = zy = (sp->pt[0].pos.y + sp->pt[sp->points - 1].pos.y) / 2;
+       for (i = 0; i < sp->points - 1; ++i) {
+               nx = (sp->pt[i + 1].pos.x + sp->pt[i].pos.x) / 2;
+               ny = (sp->pt[i + 1].pos.y + sp->pt[i].pos.y) / 2;
+               XDrawSpline(display, window, gc,
+                           px, py, sp->pt[i].pos.x, sp->pt[i].pos.y, nx, ny);
+               px = nx;
+               py = ny;
+       }
+
+       XDrawSpline(display, window, gc, px, py,
+        sp->pt[sp->points - 1].pos.x, sp->pt[sp->points - 1].pos.y, zx, zy);
+
+       if (sp->erase) {
+               for (i = 0; i < sp->points; ++i) {
+                       sp->splineq[sp->last][i].x = sp->pt[i].pos.x;
+                       sp->splineq[sp->last][i].y = sp->pt[i].pos.y;
+               }
+               sp->last++;
+               if (sp->last >= sp->nsplines)
+                       sp->last = 0;
+
+               if (sp->redrawing) {
+                       int         j, k;
+
+                       sp->redrawpos++;
+                       /* This compensates for the changed sp->last
+                          since last callback */
+
+                       for (k = 0; k < REDRAWSTEP; k++) {
+                               j = (sp->last - sp->redrawpos + sp->nsplines) %
+                                       sp->nsplines;
+#ifdef BACKWARDS
+                               /* Draw backwards, probably will not see it,
+                                  but its the thought ... */
+                               px = zx = (sp->splineq[j][0].x +
+                                      sp->splineq[j][sp->points - 1].x) / 2;
+                               py = zy = (sp->splineq[j][0].y +
+                                      sp->splineq[j][sp->points - 1].y) / 2;
+                               for (i = sp->points - 1; i > 0; --i) {
+                                       nx = (sp->splineq[j][i - 1].x +
+                                             sp->splineq[j][i].x) / 2;
+                                       ny = (sp->splineq[j][i - 1].y +
+                                             sp->splineq[j][i].y) / 2;
+                                       XDrawSpline(display, window, gc,
+                                                px, py, sp->splineq[j][i].x,
+                                               sp->splineq[j][i].y, nx, ny);
+                                       px = nx;
+                                       py = ny;
+                               }
+
+                               XDrawSpline(display, window, gc,
+                                           px, py, sp->splineq[j][0].x,
+                                           sp->splineq[j][0].y, zx, zy);
+#else
+                               px = zx = (sp->splineq[j][0].x +
+                                      sp->splineq[j][sp->points - 1].x) / 2;
+                               py = zy = (sp->splineq[j][0].y +
+                                      sp->splineq[j][sp->points - 1].y) / 2;
+                               for (i = 0; i < sp->points - 1; ++i) {
+                                       nx = (sp->splineq[j][i + 1].x +
+                                             sp->splineq[j][i].x) / 2;
+                                       ny = (sp->splineq[j][i + 1].y +
+                                             sp->splineq[j][i].y) / 2;
+                                       XDrawSpline(display, window, gc,
+                                                px, py, sp->splineq[j][i].x,
+                                               sp->splineq[j][i].y, nx, ny);
+                                       px = nx;
+                                       py = ny;
+                               }
+
+                               XDrawSpline(display, window, gc,
+                                   px, py, sp->splineq[j][sp->points - 1].x,
+                                  sp->splineq[j][sp->points - 1].y, zx, zy);
+#endif
+                               if (++(sp->redrawpos) >= sp->nsplines - 1) {
+                                       sp->redrawing = 0;
+                                       break;
+                               }
+                       }
+               }
+       } else if (++sp->nsplines > MI_CYCLES(mi))
+               init_spline(mi);
+}
+
+/* X spline routine. */
+
+static void
+XDrawSpline(Display * display, Drawable d, GC gc, int x0, int y0, int x1, int y1, int x2, int y2)
+{
+       register int xa, ya, xb, yb, xc, yc, xp, yp;
+
+       xa = (x0 + x1) / 2;
+       ya = (y0 + y1) / 2;
+       xc = (x1 + x2) / 2;
+       yc = (y1 + y2) / 2;
+       xb = (xa + xc) / 2;
+       yb = (ya + yc) / 2;
+
+       xp = (x0 + xb) / 2;
+       yp = (y0 + yb) / 2;
+       if (ABS(xa - xp) + ABS(ya - yp) > SPLINE_THRESH)
+               XDrawSpline(display, d, gc, x0, y0, xa, ya, xb, yb);
+       else
+               XDrawLine(display, d, gc, x0, y0, xb, yb);
+
+       xp = (x2 + xb) / 2;
+       yp = (y2 + yb) / 2;
+       if (ABS(xc - xp) + ABS(yc - yp) > SPLINE_THRESH)
+               XDrawSpline(display, d, gc, xb, yb, xc, yc, x2, y2);
+       else
+               XDrawLine(display, d, gc, xb, yb, x2, y2);
+}
+
+void
+release_spline(ModeInfo * mi)
+{
+       if (splines != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       splinestruct *sp = &splines[screen];
+                       int         i;
+
+                       if (sp->pt)
+                               (void) free((void *) sp->pt);
+                       if (sp->splineq) {
+                               for (i = 0; i < sp->nsplines; ++i)
+                                       if (sp->splineq[i])
+                                               (void) free((void *) sp->splineq[i]);
+                               (void) free((void *) sp->splineq);
+                       }
+               }
+               (void) free((void *) splines);
+               splines = NULL;
+       }
+}
+
+void
+refresh_spline(ModeInfo * mi)
+{
+       splinestruct *sp = &splines[MI_SCREEN(mi)];
+
+       if (sp->erase) {
+               sp->redrawing = 1;
+               sp->redrawpos = 1;
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+#endif /* MODE_spline */
diff --git a/xlockmore-4.14/modes/star.c b/xlockmore-4.14/modes/star.c
new file mode 100644 (file)
index 0000000..9c71b9e
--- /dev/null
@@ -0,0 +1,744 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* star --- flying through an asteroid field */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)star.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Based on TI Explorer Lisp code by John Nguyen <johnn@hx.lcs.mit.edu>
+ * Copyright (c) 1992 by Jamie Zawinski
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-Oct-96: Renamed from rock.  Added trek and rock options.
+ *            Combined with features from star by Heath Rice
+ *            <rice@asl.dl.nec.com>.
+ *            The Enterprise flys by from a few different views.
+ *            Also have one view of a Romulan ship. 
+ *  7-Sep-96:  Fixed problems with 3d mode <theiling@coli.uni-sb.de>
+ * 8-May-96: Blue on left instead of green for 3d.  It seems more common
+ *           than green.  Use "-left3d Green" if you have the other kind.
+ * 17-Jan-96: 3D mode for star thanks to <theiling@coli.uni-sb.de>.
+ *            Get out your 3D glasses, Red on left and Blue on right.
+ * 14-Apr-95: Jeremie PETIT <petit@aurora.unice.fr> added a "move" feature.
+ * 2-Sep-93: xlock version David Bagley <bagleyd@tux.org>
+ * 1992:     xscreensaver version Jamie Zawinski <jwz@jwz.org>
+ */
+
+/*-
+ * original copyright
+ * Copyright (c) 1992 by Jamie Zawinski
+ * Permission to use, copy, modify, distribute, and sell this software and
+ * its documentation for any purpose is hereby granted without fee, provided
+ * that the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or
+ * implied warranty.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Star"
+#define HACK_INIT init_star
+#define HACK_DRAW draw_star
+#define star_opts xlockmore_opts
+#define DEFAULTS "*delay: 40000 \n" \
+ "*count: 100 \n" \
+ "*size: 100 \n" \
+ "*ncolors: 200 \n" \
+ "*use3d: False \n" \
+ "*delta3d: 1.5 \n" \
+ "*right3d: red \n" \
+ "*left3d: blue \n" \
+ "*both3d: magenta \n" \
+ "*none3d: black \n"
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+
+#endif /* STANDALONE */
+
+#ifdef MODE_star
+
+#define DEF_TREK  "50"
+#define DEF_ROCK  "False"
+#define DEF_STRAIGHT  "False"
+
+static int  trek;
+static Bool rock;
+static Bool straight;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-trek", ".star.trek", XrmoptionSepArg, (caddr_t) NULL},
+       {"-rock", ".star.rock", XrmoptionNoArg, (caddr_t) "on"},
+       {"+rock", ".star.rock", XrmoptionNoArg, (caddr_t) "off"},
+       {"-straight", ".star.straight", XrmoptionNoArg, (caddr_t) "on"},
+       {"+straight", ".star.straight", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & trek, "trek", "Trek", DEF_TREK, t_Int},
+       {(caddr_t *) & rock, "rock", "Rock", DEF_ROCK, t_Bool},
+       {(caddr_t *) & straight, "straight", "Straight", DEF_STRAIGHT, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-trek num", "chance of a Star Trek encounter"},
+       {"-/+rock", "turn on/off rocks"},
+       {"-/+straight", "turn on/off spin and shifting origin"}
+};
+
+ModeSpecOpt star_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   star_description =
+{"star", "init_star", "draw_star", "release_star",
+ "refresh_star", "init_star", NULL, &star_opts,
+ 40000, 100, 1, 100, 64, 0.3, "",
+ "Shows a star field with a twist", 0, NULL};
+
+#endif
+
+typedef struct _BitmapType {
+       int         direction, width, height;
+} BitmapType;
+
+#include "bitmaps/trek-0.xbm"  /* Enterprise SOUTH EAST */
+#include "bitmaps/trek-1.xbm"  /* Enterprise EAST */
+#ifdef ROMULAN                 /* Bitmap looks messed up to me. */
+#include "bitmaps/trek-2.xbm"  /* Romulan (cloaked?) EAST */
+#define TREKIES 3
+#else
+#define TREKIES 2
+#endif
+
+static BitmapType trekie[] =
+{
+       {3, trek0_width, trek0_height},
+       {2, trek1_width, trek1_height}
+#ifdef ROMULAN
+       ,
+       {2, trek2_width, trek2_height}
+#endif
+};
+
+/*-
+ * For 3d effect get some 3D glasses, left lens red, and right lens blue.
+ * Too bad monitors do not emit polarized light.
+ */
+
+#define MIN_STARS 1
+#define MIN_DEPTH 2            /* stars disappear when they get this close */
+#define MAX_DEPTH 60           /* this is where stars appear */
+#define MINSIZE 3              /* how small where pixmaps are not used */
+#define MAXSIZE 200            /* how big (in pixels) stars are at depth 1 */
+#define DEPTH_SCALE 100                /* how many ticks there are between depths */
+#define RESOLUTION 1000
+#define MAX_DEP 1.0            /* how far the displacement can be (percents) */
+#define DIRECTION_CHANGE_RATE 60
+#define MAX_DEP_SPEED 5                /* Maximum speed for movement */
+#define MOVE_STYLE 0           /* Only 0 and 1. Distinguishes the fact that
+                                  these are the stars that are moving (1) 
+                                  or the stars source (0). */
+
+#define GETZDIFF(z) \
+        (MI_DELTA3D(mi)*40.0*(1.0-((MAX_DEPTH*DEPTH_SCALE/2)/(z+20.0*DEPTH_SCALE))))
+ /* the compiler needs to optimize the calculations here */
+
+/*-
+  there's not much point in the above being user-customizable, but those
+  numbers might want to be tweaked for displays with an order of magnitude
+  higher resolution or compute power.
+ */
+
+#define TREKBITS(n,w,h)\
+  sp->trekPixmaps[sp->init_treks++]=\
+    XCreateBitmapFromData(display,window,(char *)n,w,h)
+
+
+typedef struct {
+       int         real_size;
+       int         r;
+       unsigned long color;
+       int         theta;
+       int         depth;
+       int         size, x, y;
+       int         diff;
+} astar;
+
+typedef struct {
+       XPoint      loc, delta, size;
+} trekstruct;
+
+typedef struct {
+       int         current_delta;      /* observer Z rotation */
+       int         new_delta;
+       int         dchange_tick;
+       int         width, height;
+       int         midx, midy;
+       int         current_dep[2];
+       int         speed_dep[2];
+       short       direction[2];
+       int         rotate_p, speed, nstars;
+       float       max_dep;
+       int         move_p;
+       int         dep_x, dep_y;
+       int         max_star_size;
+       astar      *astars;
+       Pixmap     *pixmaps;
+       Pixmap      trekPixmaps[TREKIES];
+       int         init_treks;
+       int         current_trek;
+       GC          stippledGC;
+       trekstruct  trek;
+} starstruct;
+
+static float cos_array[RESOLUTION], sin_array[RESOLUTION];
+static float depths[(MAX_DEPTH + 1) * DEPTH_SCALE];
+
+static starstruct *stars = NULL;
+
+static void star_draw(ModeInfo * mi, astar * astars, int draw_p);
+static int  compute_move(starstruct * sp, int axe);
+
+static void
+star_compute(ModeInfo * mi, astar * astars)
+{
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+       double      factor = depths[astars->depth];
+       double      rsize = astars->real_size * factor;
+
+       astars->size = (int) (rsize + 0.5);
+       astars->diff = (int) (int) GETZDIFF(astars->depth);
+       astars->x = sp->midx + (int) (cos_array[astars->theta] * astars->r * factor);
+       astars->y = sp->midy + (int) (sin_array[astars->theta] * astars->r * factor);
+       if (sp->move_p) {
+               double      move_factor = (double) (MOVE_STYLE - (double) astars->depth /
+                         (double) ((MAX_DEPTH + 1) * (double) DEPTH_SCALE));
+
+               /* move_factor is 0 when the star is close, 1 when far */
+               astars->x += (int) ((double) sp->dep_x * move_factor);
+               astars->y += (int) ((double) sp->dep_y * move_factor);
+       }
+}
+
+static void
+star_reset(ModeInfo * mi, astar * astars)
+{
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+
+       astars->real_size = sp->max_star_size;
+       astars->r = (int) (RESOLUTION * 0.7 + NRAND(30 * RESOLUTION));
+       astars->theta = NRAND(RESOLUTION);
+       astars->depth = MAX_DEPTH * DEPTH_SCALE;
+       if (MI_NPIXELS(mi) > 2)
+               astars->color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+       else
+               astars->color = MI_WHITE_PIXEL(mi);
+       star_compute(mi, astars);
+       star_draw(mi, astars, True);
+}
+
+static void
+star_tick(ModeInfo * mi, astar * astars, int d)
+{
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+
+       if (astars->depth > 0) {
+               star_draw(mi, astars, False);
+               astars->depth -= sp->speed;
+               if (sp->rotate_p)
+                       astars->theta = (astars->theta + d) % RESOLUTION;
+               while (astars->theta < 0)
+                       astars->theta += RESOLUTION;
+               if (astars->depth < (MIN_DEPTH * DEPTH_SCALE))
+                       astars->depth = 0;
+               else if (astars->depth > (MAX_DEPTH * DEPTH_SCALE))
+                       astars->depth = MAX_DEPTH * DEPTH_SCALE;
+               else {
+                       star_compute(mi, astars);
+                       star_draw(mi, astars, True);
+               }
+       } else if (!NRAND(40))
+               star_reset(mi, astars);
+}
+
+static void
+move_trek(starstruct * sp, int direction, int width, int height)
+{
+       switch (direction) {    /* Format: 0 = N, 1 = NE, etc */
+               case 2: /* EAST */
+                       sp->trek.loc.x = sp->width;
+                       sp->trek.loc.y = NRAND(sp->height);
+                       sp->trek.delta.x = -(NRAND(3) + 1);
+                       sp->trek.delta.y = NRAND(7) - 4;
+                       sp->trek.size.x = width;
+                       sp->trek.size.y = height;
+                       break;
+               case 3: /* SOUTH EAST */
+                       if (LRAND() & 1) {      /* Top to Right */
+                               sp->trek.loc.x = NRAND(sp->width);
+                               sp->trek.loc.y = -height;
+                       } else {        /* Left to Bottom */
+                               sp->trek.loc.x = -width;
+                               sp->trek.loc.y = NRAND(sp->height);
+                       }
+                       sp->trek.delta.x = NRAND(3) + 1;
+                       sp->trek.delta.y = NRAND(3) + 1;
+                       sp->trek.size.x = width;
+                       sp->trek.size.y = height;
+                       break;
+               case 4: /* SOUTH */
+                       sp->trek.loc.x = NRAND(sp->width);
+                       sp->trek.loc.y = sp->height;
+                       sp->trek.delta.x = NRAND(7) - 4;
+                       sp->trek.delta.y = -(NRAND(3) + 1);
+                       sp->trek.size.x = width;
+                       sp->trek.size.y = height;
+                       break;
+               default:
+                       (void) printf("not implemented for direction %d", direction);
+                       break;
+       }
+}
+
+static void
+draw_trek(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+       int         new_one = 0;
+
+       if (TREKIES == sp->current_trek)
+               if (NRAND(10000) < trek) {
+                       sp->current_trek = NRAND(TREKIES);
+                       new_one = 1;
+                       move_trek(sp, trekie[sp->current_trek].direction,
+                                 trekie[sp->current_trek].width, trekie[sp->current_trek].height);
+               }
+       if (TREKIES != sp->current_trek) {
+               sp->trek.loc.x += sp->trek.delta.x;
+               sp->trek.loc.y += sp->trek.delta.y;
+
+               if ((sp->trek.loc.x < -sp->trek.size.x) ||
+                   (sp->trek.loc.y < -sp->trek.size.y) ||
+                   (sp->trek.loc.y > sp->height) ||
+                   (sp->trek.loc.x > sp->width)) {
+                       sp->current_trek = TREKIES;
+                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                       XFillRectangle(display, window, gc,
+                                      sp->trek.loc.x - sp->trek.delta.x,
+                                      sp->trek.loc.y - sp->trek.delta.y,
+                                      sp->trek.size.x, sp->trek.size.y);
+               } else {
+                       XSetForeground(display, sp->stippledGC, MI_WHITE_PIXEL(mi));
+                       XSetTSOrigin(display, sp->stippledGC, sp->trek.loc.x, sp->trek.loc.y);
+                       XSetStipple(display, sp->stippledGC, sp->trekPixmaps[sp->current_trek]);
+                       XSetFillStyle(display, sp->stippledGC, FillOpaqueStippled);
+                       XFillRectangle(display, window, sp->stippledGC,
+                                      sp->trek.loc.x, sp->trek.loc.y,
+                                      sp->trek.size.x, sp->trek.size.y);
+
+                       if (!new_one) {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               ERASE_IMAGE(display, window, gc,
+                                           sp->trek.loc.x, sp->trek.loc.y,
+                                        (sp->trek.loc.x - sp->trek.delta.x),
+                                        (sp->trek.loc.y - sp->trek.delta.y),
+                                           sp->trek.size.x, sp->trek.size.y);
+
+                       }
+               }
+       }
+}
+
+static void
+star_draw(ModeInfo * mi, astar * astars, int draw_p)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+
+       if (draw_p) {
+               if (MI_IS_USE3D(mi)) {
+                       if (MI_IS_INSTALL(mi))
+                               XSetForeground(MI_DISPLAY(mi), gc, MI_NONE_COLOR(mi));
+                       else
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               } else
+                       XSetForeground(display, gc, astars->color);
+       } else
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       if (astars->x <= 0 || astars->y <= 0 ||
+           astars->x >= sp->width || astars->y >= sp->height) {
+               /* This means that if a star were to go off the screen at 12:00, but
+                  would have been visible at 3:00, it won't come back once the observer
+                  rotates around so that the star would have been visible again.
+                  Oh well.
+                */
+               if (!sp->move_p)
+                       astars->depth = 0;
+               return;
+       }
+       if (astars->size <= 1) {
+               if (MI_IS_USE3D(mi)) {
+                       if (draw_p) {
+                               if (MI_IS_INSTALL(mi))
+                                       XSetFunction(display, gc, GXor);
+                               XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+                       }
+                       XDrawPoint(display, window, gc, astars->x - astars->diff, astars->y);
+                       if (draw_p)
+                               XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+                       XDrawPoint(display, window, gc, astars->x + astars->diff, astars->y);
+                       if (draw_p && MI_IS_INSTALL(mi))
+                               XSetFunction(display, gc, GXcopy);
+               } else
+                       XDrawPoint(display, window, gc, astars->x, astars->y);
+       } else if (astars->size <= MINSIZE || !draw_p) {
+               if (MI_IS_USE3D(mi)) {
+                       if (draw_p) {
+                               if (MI_IS_INSTALL(mi))
+                                       XSetFunction(display, gc, GXor);
+                               XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+                       }
+                       XFillRectangle(display, window, gc,
+                                astars->x - astars->size / 2 - astars->diff,
+                                      astars->y - astars->size / 2,
+                                      astars->size, astars->size);
+                       if (draw_p)
+                               XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+                       XFillRectangle(display, window, gc,
+                                astars->x - astars->size / 2 + astars->diff,
+                                      astars->y - astars->size / 2,
+                                      astars->size, astars->size);
+                       if (draw_p && MI_IS_INSTALL(mi))
+                               XSetFunction(display, gc, GXcopy);
+               } else
+                       XFillRectangle(display, window, gc,
+                                      astars->x - astars->size / 2, astars->y - astars->size / 2,
+                                      astars->size, astars->size);
+       } else if (astars->size < sp->max_star_size) {
+               if (MI_IS_USE3D(mi)) {
+                       if (MI_IS_INSTALL(mi))
+                               XSetFunction(display, gc, GXor);
+                       XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+                       XCopyPlane(display, sp->pixmaps[astars->size - MINSIZE], window, gc,
+                                  0, 0, astars->size, astars->size,
+                                astars->x - astars->size / 2 - astars->diff,
+                                  astars->y - astars->size / 2,
+                                  1L);
+                       XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+                       XCopyPlane(display, sp->pixmaps[astars->size - MINSIZE], window, gc,
+                                  0, 0, astars->size, astars->size,
+                                astars->x - astars->size / 2 + astars->diff,
+                                  astars->y - astars->size / 2,
+                                  1L);
+                       if (MI_IS_INSTALL(mi))
+                               XSetFunction(display, gc, GXcopy);
+               } else
+                       XCopyPlane(display, sp->pixmaps[astars->size - MINSIZE], window, gc,
+                                  0, 0, astars->size, astars->size,
+                                  astars->x - astars->size / 2, astars->y - astars->size / 2,
+                                  1L);
+       }
+}
+
+static void
+init_pixmaps(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+       int         size = MI_SIZE(mi);
+       int         i;
+       XGCValues   gcv;
+       GC          fg_gc = 0, bg_gc = 0;
+
+       if (size < -MINSIZE)
+               sp->max_star_size = NRAND(-size - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE)
+               sp->max_star_size = MINSIZE;
+       else
+               sp->max_star_size = size;
+       if (sp->max_star_size > MAXSIZE)
+               sp->max_star_size = MAXSIZE;
+       sp->pixmaps = (Pixmap *) calloc(sp->max_star_size, sizeof (Pixmap));
+       for (i = 0; i < sp->max_star_size; i++) {
+               int         h = i + MINSIZE;
+               Pixmap      p;
+               XPoint      points[7];
+
+               if (rock)
+                       p = XCreatePixmap(display, window, h, h, 1);
+               else            /* Dunno why this is required */
+                       p = XCreatePixmap(display, window, 2 * h, 2 * h, 1);
+               sp->pixmaps[i] = p;
+               if (!p) {
+                       (void) fprintf(stderr, "Could not allocate pixmaps, in star\n");
+                       return;
+               }
+               if (!fg_gc) {   /* must use drawable of pixmap, not window (fmh) */
+                       gcv.foreground = 1;
+                       gcv.background = 0;
+                       fg_gc = XCreateGC(display, p, GCForeground | GCBackground, &gcv);
+               }
+               if (!bg_gc) {   /* must use drawable of pixmap, not window (fmh) */
+                       gcv.foreground = 0;
+                       gcv.background = 1;
+                       bg_gc = XCreateGC(display, p, GCForeground | GCBackground, &gcv);
+               }
+               XFillRectangle(display, p, bg_gc, 0, 0, h, h);
+               if (rock) {
+                       points[0].x = (int) ((double) h * 0.15);
+                       points[0].y = (int) ((double) h * 0.85);
+                       points[1].x = (int) ((double) h * 0.00);
+                       points[1].y = (int) ((double) h * 0.20);
+                       points[2].x = (int) ((double) h * 0.30);
+                       points[2].y = (int) ((double) h * 0.00);
+                       points[3].x = (int) ((double) h * 0.40);
+                       points[3].y = (int) ((double) h * 0.10);
+                       points[4].x = (int) ((double) h * 0.90);
+                       points[4].y = (int) ((double) h * 0.10);
+                       points[5].x = (int) ((double) h * 1.00);
+                       points[5].y = (int) ((double) h * 0.55);
+                       points[6].x = (int) ((double) h * 0.45);
+                       points[6].y = (int) ((double) h * 1.00);
+                       XFillPolygon(display, p, fg_gc, points, 7, Nonconvex, CoordModeOrigin);
+               } else {
+                       XFillArc(display, p, fg_gc, 0, 0, h, h, 0, 23040);
+               }
+       }
+       XFreeGC(display, fg_gc);
+       XFreeGC(display, bg_gc);
+       if (!sp->stippledGC) {
+               gcv.foreground = MI_BLACK_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               if ((sp->stippledGC = XCreateGC(display, window,
+                                GCForeground | GCBackground, &gcv)) == None)
+                       return;
+       }
+       if (!sp->init_treks && trek) {
+/* PURIFY 4.0.1 on SunOS4 reports a 3264 byte memory leak on the next line. *
+   PURIFY 4.0.1 on Solaris 2 does not report this memory leak. */
+               TREKBITS(trek0_bits, trek0_width, trek0_height);
+               TREKBITS(trek1_bits, trek1_width, trek1_height);
+#ifdef ROMULAN
+               TREKBITS(trek2_bits, trek2_width, trek2_height);
+#endif
+       }
+}
+
+static void
+tick_stars(ModeInfo * mi, int d)
+{
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+       int         i;
+
+       if (sp->move_p) {
+               sp->dep_x = compute_move(sp, 0);
+               sp->dep_y = compute_move(sp, 1);
+       }
+       for (i = 0; i < sp->nstars; i++)
+               star_tick(mi, &sp->astars[i], d);
+}
+
+static int
+compute_move(starstruct * sp, int axe)
+                               /* 0 for x, 1 for y */
+{
+       int         limit[2];
+       int         change = 0;
+
+       limit[0] = sp->midx;
+       limit[1] = sp->midy;
+
+       sp->current_dep[axe] += sp->speed_dep[axe];     /* We adjust the displacement */
+
+       if (sp->current_dep[axe] > (int) (limit[axe] * sp->max_dep)) {
+               if (sp->current_dep[axe] > limit[axe])
+                       sp->current_dep[axe] = limit[axe];
+               sp->direction[axe] = -1;
+       }                       /* This is when we reach the upper screen limit */
+       if (sp->current_dep[axe] < (int) (-limit[axe] * sp->max_dep)) {
+               if (sp->current_dep[axe] < -limit[axe])
+                       sp->current_dep[axe] = -limit[axe];
+               sp->direction[axe] = 1;
+       }                       /* This is when we reach the lower screen limit */
+       if (sp->direction[axe] == 1)    /* We adjust the sp->speed_dep */
+               sp->speed_dep[axe] += 1;
+       else if (sp->direction[axe] == -1)
+               sp->speed_dep[axe] -= 1;
+
+       if (sp->speed_dep[axe] > MAX_DEP_SPEED)
+               sp->speed_dep[axe] = MAX_DEP_SPEED;
+       else if (sp->speed_dep[axe] < -MAX_DEP_SPEED)
+               sp->speed_dep[axe] = -MAX_DEP_SPEED;
+
+       if (!straight && !NRAND(DIRECTION_CHANGE_RATE)) {
+               /* We change direction */
+               change = (int) (LRAND() & 1);
+               if (change != 1) {
+                       if (sp->direction[axe] == 0)
+                               sp->direction[axe] = change - 1;        /* 0 becomes either 1 or -1 */
+                       else
+                               sp->direction[axe] = 0;         /* -1 or 1 become 0 */
+               }
+       }
+       return (sp->current_dep[axe]);
+}
+
+void
+init_star(ModeInfo * mi)
+{
+       starstruct *sp;
+       int         i;
+       static int  first = 1;
+
+       if (stars == NULL) {
+               if ((stars = (starstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (starstruct))) == NULL)
+                       return;
+       }
+       sp = &stars[MI_SCREEN(mi)];
+
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+       sp->midx = sp->width / 2;
+       sp->midy = sp->height / 2;
+       sp->speed = 100;
+       sp->rotate_p = !straight;
+       sp->max_dep = (straight) ? 0 : MAX_DEP;
+       sp->move_p = True;
+       sp->dep_x = 0;
+       sp->dep_y = 0;
+       sp->current_trek = TREKIES;
+       sp->nstars = MI_COUNT(mi);
+       if (sp->nstars < -MIN_STARS) {
+               if (sp->astars) {
+                       (void) free((void *) sp->astars);
+                       sp->astars = NULL;
+               }
+               sp->nstars = NRAND(-sp->nstars - MIN_STARS + 1) + MIN_STARS;
+       } else if (sp->nstars < MIN_STARS)
+               sp->nstars = MIN_STARS;
+       if (sp->speed > 100)
+               sp->speed = 100;
+
+       if (first) {
+               first = 0;
+               for (i = 0; i < RESOLUTION; i++) {
+                       sin_array[i] = SINF((((float) i) / (RESOLUTION / 2.0)) * M_PI);
+                       cos_array[i] = COSF((((float) i) / (RESOLUTION / 2.0)) * M_PI);
+               }
+               /* We actually only need i/speed of these. Oh well. */
+               for (i = 1; i < (int) (sizeof (depths) / sizeof (depths[0])); i++)
+                       depths[i] = (float) atan(((double) 0.5) / (((double) i) / DEPTH_SCALE));
+               depths[0] = M_PI_2;     /* avoid division by 0 */
+       }
+       if (!sp->astars)
+               sp->astars = (astar *) calloc(sp->nstars, sizeof (astar));
+       if (!sp->pixmaps)
+               init_pixmaps(mi);
+
+       /* don't want any exposure events from XCopyPlane */
+       XSetGraphicsExposures(MI_DISPLAY(mi), MI_GC(mi), False);
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_star(ModeInfo * mi)
+{
+       starstruct *sp = &stars[MI_SCREEN(mi)];
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (sp->current_delta != sp->new_delta) {
+               if (sp->dchange_tick++ == 5) {
+                       sp->dchange_tick = 0;
+                       if (sp->current_delta < sp->new_delta)
+                               sp->current_delta++;
+                       else
+                               sp->current_delta--;
+               }
+       } else {
+               if (!NRAND(50)) {
+                       sp->new_delta = (NRAND(11) - 5);
+                       if (!NRAND(10))
+                               sp->new_delta *= 5;
+               }
+       }
+       tick_stars(mi, sp->current_delta);
+       draw_trek(mi);
+#if 0
+       /* this is for making stars go backwards, not ready for prime-time */
+       if (!NRAND(500)) {
+               sp->speed = -sp->speed;
+       }
+#endif
+}
+
+void
+release_star(ModeInfo * mi)
+{
+       if (stars != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       Display    *display = MI_DISPLAY(mi);
+                       starstruct *sp = &stars[screen];
+                       int         i;
+
+                       if (sp->astars != NULL)
+                               (void) free((void *) sp->astars);
+                       if (sp->pixmaps != NULL) {
+                               for (i = 0; i < sp->max_star_size; i++)
+                                       XFreePixmap(display, sp->pixmaps[i]);
+                               (void) free((void *) sp->pixmaps);
+                       }
+                       if (sp->stippledGC != NULL)
+                               XFreeGC(display, sp->stippledGC);
+                       for (i = 0; i < sp->init_treks; i++)
+                               XFreePixmap(display, sp->trekPixmaps[i]);
+               }
+               (void) free((void *) stars);
+               stars = NULL;
+       }
+}
+
+void
+refresh_star(ModeInfo * mi)
+{
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+#endif /* MODE_star */
diff --git a/xlockmore-4.14/modes/starfish.c b/xlockmore-4.14/modes/starfish.c
new file mode 100644 (file)
index 0000000..214fc8e
--- /dev/null
@@ -0,0 +1,626 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* starfish ---  */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)starfish.c   4.11 98/06/11 xlockmore";
+
+#endif
+
+/* xscreensaver, Copyright (c) 1997 Jamie Zawinski <jwz@jwz.org>
+
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ * 
+ * Revision History:
+ * 24-Feb-98:  xlockmore version by Jouk Jansen <joukj@hrem.stm.tudelft.nl>
+ * 1997 :    original xscreensaver version by Jamie Zawinski <jwz@jwz.org>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Starfish"
+#define HACK_INIT init_starfish
+#define HACK_DRAW draw_starfish
+#define starfish_opts xlockmore_opts
+#define DEFAULTS "*delay: 2000 \n" \
+ "*cycles: 1000 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+
+#ifdef MODE_starfish
+
+#include "spline.h"
+
+#define DEF_ROTV  "-1"
+#define DEF_THICKNESS  "-20"
+#define DEF_CYCLE "True"
+#define DEF_BLOB "False"
+#define DEF_CYCLESPEED "3"
+
+static int  cyclespeed;
+static float rotv, thickness;
+
+static Bool blob, cycle_p;
+
+static XrmOptionDescRec opts[] =
+{
+     {"-cyclespeed", "starfish.cyclespeed", XrmoptionSepArg, (caddr_t) NULL},
+       {"-rotation", "starfish.rotation", XrmoptionSepArg, (caddr_t) NULL},
+       {"-thickness", "starfish.thickness", XrmoptionSepArg, (caddr_t) NULL},
+       {"-blob", ".starfish.blob", XrmoptionNoArg, (caddr_t) "on"},
+       {"+blob", ".starfish.blob", XrmoptionNoArg, (caddr_t) "off"},
+       {"-cycle", ".starfish.cycle", XrmoptionNoArg, (caddr_t) "on"},
+       {"+cycle", ".starfish.cycle", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+{(caddr_t *) & cyclespeed, "cyclespeed", "CycleSpeed", DEF_CYCLESPEED, t_Int},
+       {(caddr_t *) & rotv, "rotation", "Rotation", DEF_ROTV, t_Float},
+ {(caddr_t *) & thickness, "thickness", "Thickness", DEF_THICKNESS, t_Float},
+       {(caddr_t *) & blob, "blob", "Blob", DEF_BLOB, t_Bool},
+       {(caddr_t *) & cycle_p, "cycle", "Cycle", DEF_CYCLE, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+       {"-cyclespeed num", "Cycling speed"},
+       {"-rotation num", "Rotation velocity"},
+       {"-thickness num", "Thickness"},
+       {"-/+blob", "turn on/off blob"},
+       {"-/+cycle", "turn on/off cycle"}
+};
+
+ModeSpecOpt starfish_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   starfish_description =
+{"starfish", "init_starfish", "draw_starfish", "release_starfish",
+ "refresh_starfish", "init_starfish", NULL, &starfish_opts,
+ 10000, 1, 1, 1, 64, 1.0, "",
+ "Shows starfish", 0, NULL};
+
+#endif
+
+#define SCALE        1000      /* fixed-point math, for sub-pixel motion */
+
+#define RAND(n) ((long) ((LRAND() & 0x7fffffff) % ((long) (n))))
+#define RANDSIGN() ((LRAND() & 1) ? 1 : -1)
+
+enum starfish_mode {
+       pulse,
+       zoom
+};
+
+
+typedef struct {
+       enum starfish_mode mode;
+       Bool        blob_p;
+       int         skip;
+       long        x, y;       /* position of midpoint */
+       double      th;         /* angle of rotation */
+       double      rotv;       /* rotational velocity */
+       double      rota;       /* rotational acceleration */
+       double      elasticity; /* how fast it deforms: radial velocity */
+       double      rot_max;
+       long        min_r, max_r;       /* radius range */
+       int         npoints;    /* control points */
+       long       *r;          /* radii */
+       spline     *splines;
+       XPoint     *prev;
+       int         n_prev;
+       GC          gc;
+       Colormap    cmap;
+       XColor     *colors;
+       int         ncolors;
+       Bool        cycle_p, mono_p, no_colors;
+       unsigned int fg_index;
+       int         size, winwidth, winheight, stage, counter;
+       float       thickness;
+       unsigned long blackpixel, whitepixel, fg, bg;
+       int         direction;
+} starfishstruct;
+
+static starfishstruct *starfishes = NULL;
+
+static void
+make_starfish(ModeInfo * mi)
+{
+       starfishstruct *sp = &starfishes[MI_SCREEN(mi)];
+       int         i;
+       int         mid;
+
+       sp->elasticity = SCALE * sp->thickness;
+
+       if (sp->elasticity == 0.0)
+               /* bell curve from 0-15, avg 7.5 */
+               sp->elasticity = RAND(5 * SCALE) + RAND(5 * SCALE) + RAND(5 * SCALE);
+
+       if (sp->rotv == -1)
+               /* bell curve from 0-12 degrees, avg 6 */
+               sp->rotv = (double) 4.0 *((double) LRAND() / (double) MAXRAND +
+                                       (double) LRAND() / (double) MAXRAND +
+                                       (double) LRAND() / (double) MAXRAND);
+
+       sp->rotv /= 360;        /* convert degrees to ratio */
+
+       if (sp->blob_p) {
+               sp->elasticity *= 3.0;
+               sp->rotv *= 3;
+       }
+       sp->rot_max = sp->rotv * 2;
+       sp->rota = 0.0004 + 0.0002 * (double) LRAND() / (double) MAXRAND;
+
+
+       if (NRAND(20) == 5)
+               sp->size = (int) (sp->size *
+                       (0.35 * ((double) LRAND() / (double) MAXRAND +
+                                (double) LRAND() / (double) MAXRAND) + 0.3));
+
+       {
+               static char skips[] =
+               {2, 2, 2, 2, 3, 3, 3, 6, 6, 12};
+
+               sp->skip = skips[LRAND() % sizeof (skips)];
+       }
+
+       if (!(LRAND() % (sp->skip == 2 ? 3 : 12)))
+               sp->mode = zoom;
+       else
+               sp->mode = pulse;
+
+       sp->winwidth *= SCALE;
+       sp->winheight *= SCALE;
+       sp->size *= SCALE;
+
+       sp->max_r = sp->size;
+       sp->min_r = 0;
+
+       if (sp->min_r < (5 * SCALE))
+               sp->min_r = (5 * SCALE);
+       mid = ((sp->min_r + sp->max_r) / 2);
+
+       sp->x = sp->winwidth / 2;
+       sp->y = sp->winheight / 2;
+
+       sp->th = 2.0 * M_PI * ((double) LRAND() / (double) MAXRAND) * RANDSIGN();
+
+       {
+               static char sizes[] =
+               {3, 3, 3, 3, 3,
+                4, 4, 4, 4, 5, 5, 5, 5, 5, 5,
+                8, 8, 8, 10, 35};
+               int         nsizes = sizeof (sizes);
+
+               if (sp->skip > 3)
+                       nsizes -= 4;
+               sp->npoints = sp->skip * sizes[LRAND() % nsizes];
+       }
+
+       if (sp->splines)
+               free_spline(sp->splines);
+       sp->splines = make_spline(sp->npoints);
+
+       if (sp->r)
+               (void) free((void *) sp->r);
+       sp->r = (long *) malloc(sizeof (*sp->r) * sp->npoints);
+
+       for (i = 0; i < sp->npoints; i++)
+               sp->r[i] = ((i % sp->skip) == 0) ? 0 : sp->size;
+}
+
+
+void
+release_starfish(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+
+       if (starfishes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       starfishstruct *sp = &starfishes[screen];
+
+                       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                               MI_WHITE_PIXEL(mi) = sp->whitepixel;
+                               MI_BLACK_PIXEL(mi) = sp->blackpixel;
+#ifndef STANDALONE
+                               MI_FG_PIXEL(mi) = sp->fg;
+                               MI_BG_PIXEL(mi) = sp->bg;
+#endif
+                               if (sp->colors && sp->ncolors && !sp->no_colors)
+                                       free_colors(display, sp->cmap, sp->colors, sp->ncolors);
+                               if (sp->colors)
+                                       (void) free((void *) sp->colors);
+                               XFreeColormap(display, sp->cmap);
+                       }
+                       if (sp->gc != NULL)
+                               XFreeGC(display, sp->gc);
+                       if (sp->splines)
+                               free_spline(sp->splines);
+                       if (sp->r)
+                               (void) free((void *) sp->r);
+                       if (sp->prev)
+                               (void) free((void *) sp->prev);
+               }
+               (void) free((void *) starfishes);
+               starfishes = NULL;
+       }
+}
+
+
+static void
+throb_starfish(starfishstruct * sp)
+{
+       int         i;
+       double      frac = ((M_PI + M_PI) / sp->npoints);
+
+       for (i = 0; i < sp->npoints; i++) {
+               double      r = sp->r[i];
+               double      ra = (r > 0.0 ? r : -r);
+               double      th = (sp->th > 0 ? sp->th : -sp->th);
+               double      x, y;
+               double      elasticity = sp->elasticity;
+
+               /* place control points evenly around perimiter, shifted by theta */
+               x = sp->x + (ra * cos(i * frac + th));
+               y = sp->y + (ra * sin(i * frac + th));
+
+               sp->splines->control_x[i] = x / SCALE;
+               sp->splines->control_y[i] = y / SCALE;
+
+               if (sp->mode == zoom && ((i % sp->skip) == 0))
+                       continue;
+
+               /* Slow down near the end points: move fastest in the middle. */
+               {
+                       double      ratio = ra / (double) (sp->max_r - sp->min_r);
+
+                       if (ratio > 0.5)
+                               ratio = 1 - ratio;      /* flip */
+                       ratio *= 2.0;   /* normalize */
+                       ratio = (ratio * 0.9) + 0.1;    /* fudge */
+                       elasticity = elasticity * ratio;
+               }
+
+
+               /* Increase/decrease radius by elasticity */
+               ra += (r >= 0.0 ? elasticity : -elasticity);
+               if ((i % sp->skip) == 0)
+                       ra += (elasticity / 2.0);
+
+               r = ra * (r >= 0.0 ? 1.0 : -1.0);
+
+               /* If we've reached the end (too long or too short) reverse direction. */
+               if ((ra > sp->max_r && r >= 0.0) ||
+                   (ra < sp->min_r && r < 0.0))
+                       r = -r;
+
+               sp->r[i] = r;
+       }
+}
+
+
+static void
+spin_starfish(starfishstruct * sp)
+{
+       double      th = sp->th;
+
+       if (th < 0)
+               th = -(th + sp->rotv);
+       else
+               th += sp->rotv;
+
+       if (th > (M_PI + M_PI))
+               th -= (M_PI + M_PI);
+       else if (th < 0)
+               th += (M_PI + M_PI);
+
+       sp->th = (sp->th > 0 ? th : -th);
+
+       sp->rotv += sp->rota;
+
+       if (sp->rotv > sp->rot_max ||
+           sp->rotv < -sp->rot_max) {
+               sp->rota = -sp->rota;
+       }
+       /* If it stops, start it going in the other direction. */
+       else if (sp->rotv < 0) {
+               if (LRAND() & 1) {
+                       /* keep going in the same direction */
+                       sp->rotv = 0;
+                       if (sp->rota < 0)
+                               sp->rota = -sp->rota;
+               } else {
+                       /* reverse gears */
+                       sp->rotv = -sp->rotv;
+                       sp->rota = -sp->rota;
+                       sp->th = -sp->th;
+               }
+       }
+       /* Alter direction of rotational acceleration randomly. */
+       if (!(LRAND() % 120))
+               sp->rota = -sp->rota;
+
+       /* Change acceleration very occasionally. */
+       if (!(LRAND() % 200)) {
+               if (LRAND() & 1)
+                       sp->rota *= 1.2;
+               else
+                       sp->rota *= 0.8;
+       }
+}
+
+
+static void
+draw1_starfish(Display * display, Drawable drawable, GC gc, starfishstruct * sp)
+{
+       compute_closed_spline(sp->splines);
+       if (sp->prev) {
+               XPoint     *points = (XPoint *)
+               malloc(sizeof (XPoint) * (sp->n_prev + sp->splines->n_points + 2));
+               int         i = sp->splines->n_points;
+               int         j = sp->n_prev;
+
+               (void) memcpy((char *) points, (char *) sp->splines->points,
+                             (i * sizeof (*points)));
+               (void) memcpy((char *) (points + i), (char *) sp->prev,
+                             (j * sizeof (*points)));
+
+               if (sp->blob_p)
+                       XClearWindow(display, drawable);
+               XFillPolygon(display, drawable, gc, points, i + j,
+                            Complex, CoordModeOrigin);
+               (void) free((void *) points);
+
+               (void) free((void *) sp->prev);
+               sp->prev = NULL;
+       }
+       sp->prev = (XPoint *) malloc(sp->splines->n_points * sizeof (XPoint));
+       (void) memcpy((char *) sp->prev, (char *) sp->splines->points,
+                     sp->splines->n_points * sizeof (XPoint));
+       sp->n_prev = sp->splines->n_points;
+
+#ifdef DEBUG
+       if (sp->blob_p) {
+               int         i;
+
+               for (i = 0; i < sp->npoints; i++)
+                       XDrawLine(display, drawable, gc, sp->x / SCALE, sp->y / SCALE,
+                       sp->splines->control_x[i], sp->splines->control_y[i]);
+       }
+#endif
+}
+
+
+void
+init_starfish(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       XGCValues   gcv;
+       starfishstruct *sp;
+
+/* initialize */
+       if (starfishes == NULL) {
+
+               if ((starfishes = (starfishstruct *) calloc(MI_NUM_SCREENS(mi),
+                                          sizeof (starfishstruct))) == NULL)
+                       return;
+       }
+       sp = &starfishes[MI_SCREEN(mi)];
+
+       if (MI_IS_FULLRANDOM(mi)) {
+               if (NRAND(10) == 9)
+                       sp->blob_p = True;
+               else
+                       sp->blob_p = False;
+               if (NRAND(8) == 7)
+                       sp->cycle_p = False;
+               else
+                       sp->cycle_p = True;
+       } else {
+               sp->blob_p = blob;
+               sp->cycle_p = cycle_p;
+       }
+       sp->rotv = (double) rotv;
+       sp->direction = (LRAND() & 1) ? 1 : -1;
+       if (thickness < 0)
+               sp->thickness = -thickness * (float) LRAND() / (float) MAXRAND;
+       else
+               sp->thickness = thickness;
+       if (sp->blob_p)
+               sp->fg_index = MI_BLACK_PIXEL(mi);
+       else
+               sp->fg_index = MI_WHITE_PIXEL(mi);
+
+       if (!sp->gc) {
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       XColor      color;
+
+#ifndef STANDALONE
+                       extern char *background;
+                       extern char *foreground;
+
+                       sp->fg = MI_FG_PIXEL(mi);
+                       sp->bg = MI_BG_PIXEL(mi);
+#endif
+                       sp->blackpixel = MI_BLACK_PIXEL(mi);
+                       sp->whitepixel = MI_WHITE_PIXEL(mi);
+                       sp->cmap =      /*MI_COLORMAP(mi); */
+                               XCreateColormap(display, window, MI_VISUAL(mi), AllocNone);
+                       XSetWindowColormap(display, window, sp->cmap);
+                       (void) XParseColor(display, sp->cmap, "black", &color);
+                       (void) XAllocColor(display, sp->cmap, &color);
+                       MI_BLACK_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, sp->cmap, "white", &color);
+                       (void) XAllocColor(display, sp->cmap, &color);
+                       MI_WHITE_PIXEL(mi) = color.pixel;
+#ifndef STANDALONE
+                       (void) XParseColor(display, sp->cmap, background, &color);
+                       (void) XAllocColor(display, sp->cmap, &color);
+                       MI_BG_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, sp->cmap, foreground, &color);
+                       (void) XAllocColor(display, sp->cmap, &color);
+                       MI_FG_PIXEL(mi) = color.pixel;
+#endif
+                       sp->colors = 0;
+                       sp->ncolors = 0;
+               }
+               gcv.foreground = sp->fg_index;
+               gcv.fill_rule = EvenOddRule;
+               sp->gc = XCreateGC(display, window, GCForeground | GCFillRule, &gcv);
+       }
+       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+/* Set up colour map */
+               if (sp->colors && sp->ncolors && !sp->no_colors)
+                       free_colors(display, sp->cmap, sp->colors, sp->ncolors);
+               if (sp->colors)
+                       (void) free((void *) sp->colors);
+               sp->colors = 0;
+               sp->ncolors = MI_NCOLORS(mi);
+               if (sp->ncolors < 2)
+                       sp->ncolors = 2;
+               if (sp->ncolors <= 2)
+                       sp->mono_p = True;
+               else
+                       sp->mono_p = False;
+
+               if (sp->mono_p)
+                       sp->colors = 0;
+               else
+                       sp->colors = (XColor *) malloc(sizeof (*sp->colors) * (sp->ncolors + 1));
+
+               if (sp->mono_p || sp->blob_p)
+                       sp->cycle_p = False;
+               if (!sp->mono_p) {
+                       if (LRAND() % 3)
+                               make_smooth_colormap(mi, sp->cmap, sp->colors, &sp->ncolors,
+                                                    True, &sp->cycle_p);
+                       else
+                               make_uniform_colormap(mi, sp->cmap, sp->colors, &sp->ncolors,
+                                                     True, &sp->cycle_p);
+               }
+               XInstallColormap(display, sp->cmap);
+               if (sp->ncolors < 2) {
+                       sp->ncolors = 2;
+                       sp->no_colors = True;
+               } else
+                       sp->no_colors = False;
+               if (sp->ncolors <= 2)
+                       sp->mono_p = True;
+
+               if (sp->mono_p)
+                       sp->cycle_p = False;
+
+               sp->fg_index = 0;
+
+/*  if (!sp->mono_p && !sp->blob_p)
+   {
+   gcv.foreground = sp->colors[sp->fg_index].pixel;
+   XSetWindowBackground (display, window, gcv.foreground);
+   } */
+
+       } else
+               sp->fg_index = NRAND(MI_NPIXELS(mi));
+
+       sp->size = (MI_WIDTH(mi) < MI_HEIGHT(mi) ? MI_WIDTH(mi) : MI_HEIGHT(mi));
+       if (sp->blob_p)
+               sp->size /= 2;
+       else
+               sp->size = (int) (sp->size * 1.3);
+       sp->winwidth = MI_WIDTH(mi);
+       sp->winheight = MI_HEIGHT(mi);
+       MI_CLEARWINDOW(mi);
+       if (sp->prev) {
+               (void) free((void *) sp->prev);
+               sp->prev = NULL;
+       }
+       sp->stage = 0;
+       sp->counter = 0;
+       make_starfish(mi);
+}
+
+static void
+run_starfish(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       starfishstruct *sp = &starfishes[MI_SCREEN(mi)];
+
+       throb_starfish(sp);
+       spin_starfish(sp);
+       draw1_starfish(display, window, sp->gc, sp);
+
+       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+               if (sp->mono_p) {
+                       if (!sp->blob_p) {
+                               sp->fg_index = (sp->fg_index == MI_BLACK_PIXEL(mi) ?
+                                   MI_BLACK_PIXEL(mi) : MI_BLACK_PIXEL(mi));
+                       }
+                       XSetForeground(display, sp->gc, sp->fg_index);
+               } else {
+                       sp->fg_index = (sp->fg_index + 1) % sp->ncolors;
+                       XSetForeground(display, sp->gc, sp->colors[sp->fg_index].pixel);
+               }
+       } else {
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, sp->gc, MI_PIXEL(mi, sp->fg_index));
+               else if (sp->fg_index)
+                       XSetForeground(display, sp->gc, MI_BLACK_PIXEL(mi));
+               else
+                       XSetForeground(display, sp->gc, MI_WHITE_PIXEL(mi));
+               if (++sp->fg_index >= (unsigned int) MI_NPIXELS(mi))
+                       sp->fg_index = 0;
+       }
+}
+
+void
+draw_starfish(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       starfishstruct *sp = &starfishes[MI_SCREEN(mi)];
+
+       if (sp->no_colors) {
+               init_starfish(mi);
+               return;
+       }
+       MI_IS_DRAWN(mi) = True;
+
+       if (!sp->stage)
+               run_starfish(mi);
+       else if (sp->cycle_p) {
+               rotate_colors(display, sp->cmap, sp->colors, sp->ncolors, sp->direction);
+
+               if (!NRAND(512))
+                       sp->direction = -sp->direction;
+       }
+       sp->stage++;
+
+       if (sp->stage > (2 * sp->blob_p + 1) * cyclespeed) {
+               sp->stage = 0;
+               sp->counter++;
+       }
+       if (sp->counter > MI_CYCLES(mi)) {
+               /* Every now and then, restart the mode */
+               init_starfish(mi);
+       }
+}
+void
+refresh_starfish(ModeInfo * mi)
+{
+       init_starfish(mi);
+}
+
+#endif /* MODE_starfish */
diff --git a/xlockmore-4.14/modes/strange.c b/xlockmore-4.14/modes/strange.c
new file mode 100644 (file)
index 0000000..8ad233e
--- /dev/null
@@ -0,0 +1,419 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* strange --- strange attractors */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)strange.c    4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by Massimino Pascal <Pascal.Massimon@ens.fr>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: jwz@jwz.org: turned into a standalone program.
+ *            Made it render into an offscreen bitmap and then copy
+ *            that onto the screen, to reduce flicker.
+ *
+ * strange attractors are not so hard to find...
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Strange"
+#define HACK_INIT init_strange
+#define HACK_DRAW draw_strange
+#define strange_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*ncolors: 100 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_strange
+
+ModeSpecOpt strange_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   strange_description =
+{"strange", "init_strange", "draw_strange", "release_strange",
+ "init_strange", "init_strange", NULL, &strange_opts,
+ 1000, 1, 1, 1, 64, 1.0, "",
+ "Shows strange attractors", 0, NULL};
+
+#endif
+
+typedef float DBL;
+typedef int PRM;
+
+#define UNIT (1<<12)
+#define UNIT2 (1<<14)
+/* #define UNIT2 (3140*UNIT/1000) */
+
+#define SKIP_FIRST      100
+#define MAX_POINTS      5500
+#define DBL_To_PRM(x)  (PRM)( (DBL)(UNIT)*(x) )
+
+
+#define DO_FOLD(a) (a)<0 ? -A->Fold[ (-(a))&(UNIT2-1) ] : A->Fold[ (a)&(UNIT2-1) ]
+
+#if 0
+#define DO_FOLD(a) (a)<-UNIT2 ? -A->Fold[(-(a))%UNIT2] : (a)<0 ? -A->Fold[ -(a) ] :\
+(a)>UNIT2 ? A->Fold[ (a)%UNIT2 ] : A->Fold[ (a) ]
+#define DO_FOLD(a) DBL_To_PRM( sin( (DBL)(a)/UNIT ) )
+#define DO_FOLD(a) (a)<0 ? DBL_To_PRM( exp( 16.0*(a)/UNIT2 ) )-1.0 : \
+DBL_To_PRM( 1.0-exp( -16.0*(a)/UNIT2 ) )
+#endif
+
+/******************************************************************/
+
+#define MAX_PRM 3*5
+
+typedef struct _ATTRACTOR {
+       DBL         Prm1[MAX_PRM], Prm2[MAX_PRM];
+       PRM         Prm[MAX_PRM], *Fold;
+       void        (*Iterate) (struct _ATTRACTOR *, PRM, PRM, PRM *, PRM *);
+       XPoint     *Buffer1, *Buffer2;
+       int         Cur_Pt, Max_Pt;
+       int         Col, Count, Speed;
+       int         Width, Height;
+       Pixmap      dbuf;       /* jwz */
+       GC          dbuf_gc;
+} ATTRACTOR;
+
+static ATTRACTOR *Root;
+
+static DBL  Amp_Prm[MAX_PRM] =
+{
+       1.0, 3.5, 3.5, 2.5, 4.7,
+       1.0, 3.5, 3.6, 2.5, 4.7,
+       1.0, 1.5, 2.2, 2.1, 3.5
+};
+static DBL  Mid_Prm[MAX_PRM] =
+{
+       0.0, 1.5, 0.0, .5, 1.5,
+       0.0, 1.5, 0.0, .5, 1.5,
+       0.0, 1.5, -1.0, -.5, 2.5,
+};
+
+static      DBL
+Gauss_Rand(DBL c, DBL A, DBL S)
+{
+       DBL         y;
+
+       y = (DBL) LRAND() / MAXRAND;
+       y = A * (1.0 - exp(-y * y * S)) / (1.0 - exp(-S));
+       if (NRAND(2))
+               return (c + y);
+       else
+               return (c - y);
+}
+
+static void
+Random_Prm(DBL * Prm)
+{
+       int         i;
+
+       for (i = 0; i < MAX_PRM; ++i)
+               Prm[i] = Gauss_Rand(Mid_Prm[i], Amp_Prm[i], 4.0);
+}
+
+/***************************************************************/
+
+   /* 2 examples of non-linear map */
+
+static void
+Iterate_X2(ATTRACTOR * A, PRM x, PRM y, PRM * xo, PRM * yo)
+{
+       PRM         xx, yy, xy, x2y, y2x, Tmp;
+
+       xx = (x * x) / UNIT;
+       x2y = (xx * y) / UNIT;
+       yy = (y * y) / UNIT;
+       y2x = (yy * x) / UNIT;
+       xy = (x * y) / UNIT;
+
+       Tmp = A->Prm[1] * xx + A->Prm[2] * xy + A->Prm[3] * yy + A->Prm[4] * x2y;
+       Tmp = A->Prm[0] - y + (Tmp / UNIT);
+       *xo = DO_FOLD(Tmp);
+       Tmp = A->Prm[6] * xx + A->Prm[7] * xy + A->Prm[8] * yy + A->Prm[9] * y2x;
+       Tmp = A->Prm[5] + x + (Tmp / UNIT);
+       *yo = DO_FOLD(Tmp);
+}
+
+static void
+Iterate_X3(ATTRACTOR * A, PRM x, PRM y, PRM * xo, PRM * yo)
+{
+       PRM         xx, yy, xy, x2y, y2x, Tmp_x, Tmp_y, Tmp_z;
+
+       xx = (x * x) / UNIT;
+       x2y = (xx * y) / UNIT;
+       yy = (y * y) / UNIT;
+       y2x = (yy * x) / UNIT;
+       xy = (x * y) / UNIT;
+
+       Tmp_x = A->Prm[1] * xx + A->Prm[2] * xy + A->Prm[3] * yy + A->Prm[4] * x2y;
+       Tmp_x = A->Prm[0] - y + (Tmp_x / UNIT);
+       Tmp_x = DO_FOLD(Tmp_x);
+
+       Tmp_y = A->Prm[6] * xx + A->Prm[7] * xy + A->Prm[8] * yy + A->Prm[9] * y2x;
+       Tmp_y = A->Prm[5] + x + (Tmp_y / UNIT);
+
+       Tmp_y = DO_FOLD(Tmp_y);
+
+       Tmp_z = A->Prm[11] * xx + A->Prm[12] * xy + A->Prm[13] * yy + A->Prm[14] * y2x;
+       Tmp_z = A->Prm[10] + x + (Tmp_z / UNIT);
+       Tmp_z = UNIT + Tmp_z * Tmp_z / UNIT;
+
+       *xo = (Tmp_x * UNIT) / Tmp_z;
+       *yo = (Tmp_y * UNIT) / Tmp_z;
+}
+
+static void (*Funcs[2]) (ATTRACTOR *, PRM, PRM, PRM *, PRM *) = {
+       Iterate_X2, Iterate_X3
+};
+
+/***************************************************************/
+
+void
+draw_strange(ModeInfo * mi)
+{
+       int         i, j, n, Cur_Pt;
+       PRM         x, y, xo, yo;
+       DBL         u;
+       XPoint     *Buf;
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       ATTRACTOR  *A = &Root[MI_SCREEN(mi)];
+       DBL         Lx, Ly;
+       void        (*Iterate) (ATTRACTOR *, PRM, PRM, PRM *, PRM *);
+       PRM         xmin, xmax, ymin, ymax;
+
+
+
+       Cur_Pt = A->Cur_Pt;
+       Iterate = A->Iterate;
+
+       u = (DBL) (A->Count) / 1000.0;
+       for (j = MAX_PRM - 1; j >= 0; --j)
+               A->Prm[j] = DBL_To_PRM((1.0 - u) * A->Prm1[j] + u * A->Prm2[j]);
+
+       x = y = DBL_To_PRM(.0);
+       for (n = SKIP_FIRST; n; --n) {
+               (*Iterate) (A, x, y, &xo, &yo);
+               x = xo + NRAND(8) - 4;
+               y = yo + NRAND(8) - 4;
+       }
+
+       xmax = 0;
+       xmin = UNIT * 4;
+       ymax = 0;
+       ymin = UNIT * 4;
+       A->Cur_Pt = 0;
+       Buf = A->Buffer2;
+       Lx = (DBL) A->Width / UNIT / 2.2;
+       Ly = (DBL) A->Height / UNIT / 2.2;
+       for (n = A->Max_Pt; n; --n) {
+               (*Iterate) (A, x, y, &xo, &yo);
+               Buf->x = (int) (Lx * (x + DBL_To_PRM(1.1)));
+               Buf->y = (int) (Ly * (DBL_To_PRM(1.1) - y));
+               /* (void) fprintf( stderr, "X,Y: %d %d    ", Buf->x, Buf->y ); */
+               Buf++;
+               A->Cur_Pt++;
+               if (xo > xmax)
+                       xmax = xo;
+               else if (xo < xmin)
+                       xmin = xo;
+               if (yo > ymax)
+                       ymax = yo;
+               else if (yo < ymin)
+                       ymin = yo;
+               x = xo + NRAND(8) - 4;
+               y = yo + NRAND(8) - 4;
+       }
+
+       MI_IS_DRAWN(mi) = True;
+
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+
+       if (A->dbuf) {          /* jwz */
+               XSetForeground(display, A->dbuf_gc, 0);
+/* XDrawPoints(display, A->dbuf, A->dbuf_gc, A->Buffer1,
+   Cur_Pt,CoordModeOrigin); */
+               XFillRectangle(display, A->dbuf, A->dbuf_gc, 0, 0, A->Width, A->Height);
+       } else
+               XDrawPoints(display, window, gc, A->Buffer1, Cur_Pt, CoordModeOrigin);
+
+       if (MI_NPIXELS(mi) < 2)
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       else
+               XSetForeground(display, gc, MI_PIXEL(mi, A->Col % MI_NPIXELS(mi)));
+
+       if (A->dbuf) {
+               XSetForeground(display, A->dbuf_gc, 1);
+               XDrawPoints(display, A->dbuf, A->dbuf_gc, A->Buffer2, A->Cur_Pt,
+                           CoordModeOrigin);
+       } else
+               XDrawPoints(display, window, gc, A->Buffer2, A->Cur_Pt, CoordModeOrigin);
+
+       if (A->dbuf)
+               XCopyPlane(display, A->dbuf, window, gc, 0, 0, A->Width, A->Height, 0, 0, 1);
+
+       Buf = A->Buffer1;
+       A->Buffer1 = A->Buffer2;
+       A->Buffer2 = Buf;
+
+       if ((xmax - xmin < DBL_To_PRM(.2)) && (ymax - ymin < DBL_To_PRM(.2)))
+               A->Count += 4 * A->Speed;
+       else
+               A->Count += A->Speed;
+       if (A->Count >= 1000) {
+               for (i = MAX_PRM - 1; i >= 0; --i)
+                       A->Prm1[i] = A->Prm2[i];
+               Random_Prm(A->Prm2);
+               A->Count = 0;
+       }
+       A->Col++;
+}
+
+
+/***************************************************************/
+
+void
+init_strange(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       ATTRACTOR  *Attractor;
+
+       if (Root == NULL) {
+               Root = (ATTRACTOR *) calloc(
+                                    MI_NUM_SCREENS(mi), sizeof (ATTRACTOR));
+               if (Root == NULL)
+                       return;
+       }
+       Attractor = &Root[MI_SCREEN(mi)];
+
+       if (Attractor->Fold == NULL) {
+               int         i;
+
+               Attractor->Fold = (PRM *) calloc(UNIT2 + 1, sizeof (PRM));
+               if (Attractor->Fold == NULL)
+                       return;
+               for (i = 0; i <= UNIT2; ++i) {
+                       DBL         x;
+
+                       /* x = ( DBL )(i)/UNIT2; */
+                       /* x = sin( M_PI/2.0*x ); */
+                       /* x = sqrt( x ); */
+                       /* x = x*x; */
+                       /* x = x*(1.0-x)*4.0; */
+                       x = (DBL) (i) / UNIT;
+                       x = sin(x);
+                       Attractor->Fold[i] = DBL_To_PRM(x);
+               }
+       }
+       if (Attractor->Buffer1 == NULL)
+               Attractor->Buffer1 = (XPoint *) calloc(MAX_POINTS, sizeof (XPoint));
+       if (Attractor->Buffer2 == NULL)
+               Attractor->Buffer2 = (XPoint *) calloc(MAX_POINTS, sizeof (XPoint));
+       if (Attractor->Buffer1 == NULL || Attractor->Buffer2 == NULL) {
+               if (Attractor->Buffer1 != NULL) {
+                       (void) free((void *) Attractor->Buffer1);
+                       Attractor->Buffer1 = NULL;
+               }
+               if (Attractor->Buffer2 != NULL) {
+                       (void) free((void *) Attractor->Buffer2);
+                       Attractor->Buffer2 = NULL;
+               }
+               Attractor->Cur_Pt = 0;
+               return;
+       }
+       Attractor->Max_Pt = MAX_POINTS;
+
+       Attractor->Width = MI_WIDTH(mi);
+       Attractor->Height = MI_HEIGHT(mi);
+       Attractor->Cur_Pt = 0;
+       Attractor->Count = 0;
+       Attractor->Col = NRAND(MI_NPIXELS(mi));
+       Attractor->Speed = 4;
+
+       Attractor->Iterate = Funcs[NRAND(2)];
+       Random_Prm(Attractor->Prm1);
+       Random_Prm(Attractor->Prm2);
+
+       if (Attractor->dbuf)
+               XFreePixmap(display, Attractor->dbuf);
+
+       Attractor->dbuf = XCreatePixmap(display, window,
+                                    Attractor->Width, Attractor->Height, 1);
+
+       /* Do not want any exposure events from XCopyPlane */
+       XSetGraphicsExposures(display, MI_GC(mi), False);
+
+       if (Attractor->dbuf) {
+               XGCValues   gcv;
+
+               gcv.foreground = 0;
+               gcv.background = 0;
+               gcv.graphics_exposures = False;
+               gcv.function = GXcopy;
+               if (Attractor->dbuf_gc)
+                       XFreeGC(display, Attractor->dbuf_gc);
+
+               Attractor->dbuf_gc = XCreateGC(display, Attractor->dbuf,
+                                              GCForeground | GCBackground | GCGraphicsExposures | GCFunction,
+                                              &gcv);
+               XFillRectangle(display, Attractor->dbuf,
+                              Attractor->dbuf_gc, 0, 0, Attractor->Width,
+                              Attractor->Height);
+               XSetBackground(display, gc, MI_BLACK_PIXEL(mi));
+               XSetFunction(display, gc, GXcopy);
+       }
+       MI_CLEARWINDOW(mi);
+}
+
+/***************************************************************/
+
+void
+release_strange(ModeInfo * mi)
+{
+       int         screen;
+
+       if (Root != NULL) {
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); ++screen) {
+                       ATTRACTOR  *Attractor = &Root[screen];
+
+                       if (Attractor->Buffer1 != NULL)
+                               (void) free((void *) Attractor->Buffer1);
+                       if (Attractor->Buffer2 != NULL)
+                               (void) free((void *) Attractor->Buffer2);
+                       if (Attractor->dbuf)
+                               XFreePixmap(MI_DISPLAY(mi), Attractor->dbuf);
+                       if (Attractor->dbuf_gc)
+                               XFreeGC(MI_DISPLAY(mi), Attractor->dbuf_gc);
+                       if (Attractor->Fold != NULL)
+                               (void) free((void *) Attractor->Fold);
+               }
+               (void) free((void *) Root);
+               Root = NULL;
+       }
+}
+
+#endif /* MODE_strange */
diff --git a/xlockmore-4.14/modes/swarm.c b/xlockmore-4.14/modes/swarm.c
new file mode 100644 (file)
index 0000000..9ccbfeb
--- /dev/null
@@ -0,0 +1,374 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* swarm --- swarm of bees */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)swarm.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 31-Aug-90: Adapted from xswarm by Jeff Butterworth <butterwo@ncsc.org>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Swarm"
+#define HACK_INIT init_swarm
+#define HACK_DRAW draw_swarm
+#define swarm_opts xlockmore_opts
+#define DEFAULTS "*delay: 15000 \n" \
+ "*count: 100 \n" \
+ "*trackmouse: False \n"
+#define BRIGHT_COLORS
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#include <X11/Xutil.h>
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+#ifdef MODE_swarm
+
+#define DEF_TRACKMOUSE  "False"
+
+static Bool trackmouse;
+
+static XrmOptionDescRec opts[] =
+{
+        {"-trackmouse", ".swarm.trackmouse", XrmoptionNoArg, (caddr_t) "on"},
+        {"+trackmouse", ".swarm.trackmouse", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+        {(caddr_t *) & trackmouse, "trackmouse", "TrackMouse", DEF_TRACKMOUSE, t_Bool}
+};
+
+static OptionStruct desc[] =
+{
+        {"-/+trackmouse", "turn on/off the tracking of the mouse"}
+};
+
+ModeSpecOpt swarm_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+
+#ifdef USE_MODULES
+ModStruct   swarm_description =
+{"swarm", "init_swarm", "draw_swarm", "release_swarm",
+ "refresh_swarm", "init_swarm", NULL, &swarm_opts,
+ 15000, 100, 1, 1, 64, 1.0, "",
+ "Shows a swarm of bees following a wasp", 0, NULL};
+
+#endif
+
+#define TIMES  4               /* number of time positions recorded */
+#define BEEACC 2               /* acceleration of bees */
+#define WASPACC 5              /* maximum acceleration of wasp */
+#define BEEVEL 12              /* maximum bee velocity */
+#define WASPVEL 10             /* maximum wasp velocity */
+
+/* Macros */
+#define X(t,b) (sp->x[(t)*sp->beecount+(b)])
+#define Y(t,b) (sp->y[(t)*sp->beecount+(b)])
+#define balance_rand(v)        ((NRAND(v))-((v)/2))    /* random number around 0 */
+
+typedef struct {
+       int         pix;
+       int         width;
+       int         height;
+       int         border;     /* wasp won't go closer than this to the edge */
+       int         beecount;   /* number of bees */
+       XSegment   *segs;       /* bee lines */
+       XSegment   *old_segs;   /* old bee lines */
+       short      *x;
+       short      *y;          /* bee positions x[time][bee#] */
+       short      *xv;
+       short      *yv;         /* bee velocities xv[bee#] */
+       short       wx[3];
+       short       wy[3];
+       short       wxv;
+       short       wyv;
+       Cursor      cursor;
+} swarmstruct;
+
+static swarmstruct *swarms = NULL;
+
+void
+init_swarm(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       swarmstruct *sp;
+       int         b;
+
+       if (swarms == NULL) {
+               if ((swarms = (swarmstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (swarmstruct))) == NULL)
+                       return;
+       }
+       sp = &swarms[MI_SCREEN(mi)];
+
+       sp->beecount = MI_COUNT(mi);
+       if (sp->beecount < 0) {
+               /* if sp->beecount is random ... the size can change */
+               if (sp->segs != NULL) {
+                       (void) free((void *) sp->segs);
+                       sp->segs = NULL;
+               }
+               if (sp->old_segs != NULL) {
+                       (void) free((void *) sp->old_segs);
+                       sp->old_segs = NULL;
+               }
+               if (sp->x != NULL) {
+                       (void) free((void *) sp->x);
+                       sp->x = NULL;
+               }
+               if (sp->y != NULL) {
+                       (void) free((void *) sp->y);
+                       sp->y = NULL;
+               }
+               if (sp->xv != NULL) {
+                       (void) free((void *) sp->xv);
+                       sp->xv = NULL;
+               }
+               if (sp->yv != NULL) {
+                       (void) free((void *) sp->yv);
+                       sp->yv = NULL;
+               }
+               sp->beecount = NRAND(-sp->beecount) + 1;        /* Add 1 so its not too boring */
+       }
+       sp->width = MI_WIDTH(mi);
+       sp->height = MI_HEIGHT(mi);
+       sp->border = (sp->width + sp->height) / 50;
+
+       if (trackmouse && !sp->cursor) {        /* Create an invisible cursor */
+               Pixmap      bit;
+               XColor      black;
+
+               black.red = 0;
+               black.green = 0;
+               black.blue = 0;
+               black.flags = DoRed | DoGreen | DoBlue;
+               bit = XCreatePixmapFromBitmapData(display, window, "\000", 1, 1,
+                                                 MI_BLACK_PIXEL(mi),
+                                                 MI_BLACK_PIXEL(mi), 1);
+               sp->cursor = XCreatePixmapCursor(display, bit, bit, &black, &black,
+                                                0, 0);
+               XFreePixmap(display, bit);
+       }
+       XDefineCursor(display, window, sp->cursor);
+
+       MI_CLEARWINDOW(mi);
+
+       /* Allocate memory. */
+
+       if (!sp->segs) {
+               sp->segs = (XSegment *) malloc(sizeof (XSegment) * sp->beecount);
+               sp->old_segs = (XSegment *) malloc(sizeof (XSegment) * sp->beecount);
+               sp->x = (short *) malloc(sizeof (short) * sp->beecount * TIMES);
+               sp->y = (short *) malloc(sizeof (short) * sp->beecount * TIMES);
+               sp->xv = (short *) malloc(sizeof (short) * sp->beecount);
+               sp->yv = (short *) malloc(sizeof (short) * sp->beecount);
+       }
+       /* Initialize point positions, velocities, etc. */
+       if (MI_NPIXELS(mi) > 2)
+               sp->pix = NRAND(MI_NPIXELS(mi));
+
+       /* wasp */
+       sp->wx[0] = sp->border + NRAND(sp->width - 2 * sp->border);
+       sp->wy[0] = sp->border + NRAND(sp->height - 2 * sp->border);
+       sp->wx[1] = sp->wx[0];
+       sp->wy[1] = sp->wy[0];
+       sp->wxv = 0;
+       sp->wyv = 0;
+
+       /* bees */
+       for (b = 0; b < sp->beecount; b++) {
+               X(0, b) = NRAND(sp->width);
+               X(1, b) = X(0, b);
+               Y(0, b) = NRAND(sp->height);
+               Y(1, b) = Y(0, b);
+               sp->xv[b] = balance_rand(7);
+               sp->yv[b] = balance_rand(7);
+       }
+}
+
+void
+draw_swarm(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       swarmstruct *sp = &swarms[MI_SCREEN(mi)];
+       int         b;
+       Bool        track_p = trackmouse;
+       int         cx, cy;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (track_p) {
+               Window      r, c;
+               int         rx, ry;
+               unsigned int m;
+
+               (void) XQueryPointer(display, window,
+                                    &r, &c, &rx, &ry, &cx, &cy, &m);
+               if (cx <= sp->border || cy <= sp->border ||
+                   cx >= MI_WIDTH(mi) - 1 - sp->border ||
+                   cy >= MI_HEIGHT(mi) - 1 - sp->border)
+                       track_p = False;
+       }
+       /* <=- Wasp -=> */
+       /* Age the arrays. */
+       sp->wx[2] = sp->wx[1];
+       sp->wx[1] = sp->wx[0];
+       sp->wy[2] = sp->wy[1];
+       sp->wy[1] = sp->wy[0];
+       if (track_p) {
+               sp->wx[0] = cx;
+               sp->wy[0] = cy;
+       } else {
+
+               /* Accelerate */
+               sp->wxv += balance_rand(WASPACC);
+               sp->wyv += balance_rand(WASPACC);
+
+               /* Speed Limit Checks */
+               if (sp->wxv > WASPVEL)
+                       sp->wxv = WASPVEL;
+               if (sp->wxv < -WASPVEL)
+                       sp->wxv = -WASPVEL;
+               if (sp->wyv > WASPVEL)
+                       sp->wyv = WASPVEL;
+               if (sp->wyv < -WASPVEL)
+                       sp->wyv = -WASPVEL;
+
+               /* Move */
+               sp->wx[0] = sp->wx[1] + sp->wxv;
+               sp->wy[0] = sp->wy[1] + sp->wyv;
+
+               /* Bounce Checks */
+               if ((sp->wx[0] < sp->border) || (sp->wx[0] > sp->width - sp->border - 1)) {
+                       sp->wxv = -sp->wxv;
+                       sp->wx[0] += sp->wxv;
+               }
+               if ((sp->wy[0] < sp->border) || (sp->wy[0] > sp->height - sp->border - 1)) {
+                       sp->wyv = -sp->wyv;
+                       sp->wy[0] += sp->wyv;
+               }
+               /* Don't let things settle down. */
+               sp->xv[NRAND(sp->beecount)] += balance_rand(3);
+               sp->yv[NRAND(sp->beecount)] += balance_rand(3);
+       }
+       /* <=- Bees -=> */
+       for (b = 0; b < sp->beecount; b++) {
+               int         distance, dx, dy;
+
+               /* Age the arrays. */
+               X(2, b) = X(1, b);
+               X(1, b) = X(0, b);
+               Y(2, b) = Y(1, b);
+               Y(1, b) = Y(0, b);
+
+               /* Accelerate */
+               dx = sp->wx[1] - X(1, b);
+               dy = sp->wy[1] - Y(1, b);
+               distance = abs(dx) + abs(dy);   /* approximation */
+               if (distance == 0)
+                       distance = 1;
+               sp->xv[b] += (dx * BEEACC) / distance;
+               sp->yv[b] += (dy * BEEACC) / distance;
+
+               /* Speed Limit Checks */
+               if (sp->xv[b] > BEEVEL)
+                       sp->xv[b] = BEEVEL;
+               if (sp->xv[b] < -BEEVEL)
+                       sp->xv[b] = -BEEVEL;
+               if (sp->yv[b] > BEEVEL)
+                       sp->yv[b] = BEEVEL;
+               if (sp->yv[b] < -BEEVEL)
+                       sp->yv[b] = -BEEVEL;
+
+               /* Move */
+               X(0, b) = X(1, b) + sp->xv[b];
+               Y(0, b) = Y(1, b) + sp->yv[b];
+
+               /* Fill the segment lists. */
+               sp->segs[b].x1 = X(0, b);
+               sp->segs[b].y1 = Y(0, b);
+               sp->segs[b].x2 = X(1, b);
+               sp->segs[b].y2 = Y(1, b);
+               sp->old_segs[b].x1 = X(1, b);
+               sp->old_segs[b].y1 = Y(1, b);
+               sp->old_segs[b].x2 = X(2, b);
+               sp->old_segs[b].y2 = Y(2, b);
+       }
+
+       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+       XDrawLine(display, window, gc,
+                 sp->wx[1], sp->wy[1], sp->wx[2], sp->wy[2]);
+       XDrawSegments(display, window, gc, sp->old_segs, sp->beecount);
+
+       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       XDrawLine(display, window, gc,
+                 sp->wx[0], sp->wy[0], sp->wx[1], sp->wy[1]);
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(display, gc, MI_PIXEL(mi, sp->pix));
+               if (++sp->pix >= MI_NPIXELS(mi))
+                       sp->pix = 0;
+       }
+       XDrawSegments(display, window, gc, sp->segs, sp->beecount);
+}
+
+void
+release_swarm(ModeInfo * mi)
+{
+       if (swarms != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       swarmstruct *sp = &swarms[screen];
+
+                       if (sp->segs != NULL)
+                               (void) free((void *) sp->segs);
+                       if (sp->old_segs != NULL)
+                               (void) free((void *) sp->old_segs);
+                       if (sp->x != NULL)
+                               (void) free((void *) sp->x);
+                       if (sp->y != NULL)
+                               (void) free((void *) sp->y);
+                       if (sp->xv != NULL)
+                               (void) free((void *) sp->xv);
+                       if (sp->yv != NULL)
+                               (void) free((void *) sp->yv);
+                       if (sp->cursor)
+                               XFreeCursor(MI_DISPLAY(mi), sp->cursor);
+               }
+               (void) free((void *) swarms);
+               swarms = NULL;
+       }
+}
+
+void
+refresh_swarm(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_swarm */
diff --git a/xlockmore-4.14/modes/swirl.c b/xlockmore-4.14/modes/swirl.c
new file mode 100644 (file)
index 0000000..c56a84b
--- /dev/null
@@ -0,0 +1,1482 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* swirl --- swirly patterns */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)swirl.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1994 M.Dobie <mrd@ecs.soton.ac.uk>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 13-May-97: jwz@jwz.org: turned into a standalone program.
+ * 21-Apr-95: improved startup time for TrueColour displays
+ *            (limited to 16bpp to save memory) S.Early <sde1000@cam.ac.uk>
+ * 09-Jan-95: fixed colour maps (more colourful) and the image now spirals
+ *            outwards from the centre with a fixed number of points drawn
+ *            every iteration. Thanks to M.Dobie <mrd@ecs.soton.ac.uk>.
+ * 1994:      written.   Copyright (c) 1994 M.Dobie <mrd@ecs.soton.ac.uk>
+ *            based on original code by R.Taylor
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Swirl"
+#define HACK_INIT init_swirl
+#define HACK_DRAW draw_swirl
+#define swirl_opts xlockmore_opts
+#define DEFAULTS "*delay: 5000 \n" \
+ "*count: 5 \n" \
+ "*ncolors: 200 \n"
+#define SMOOTH_COLORS
+#define WRITABLE_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#include <X11/Xutil.h>
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#include "color.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_swirl
+
+ModeSpecOpt swirl_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   swirl_description =
+{"swirl", "init_swirl", "draw_swirl", "release_swirl",
+ "refresh_swirl", "init_swirl", NULL, &swirl_opts,
+ 5000, 5, 1, 1, 64, 1.0, "",
+ "Shows animated swirling patterns", 0, NULL};
+
+#endif
+
+#include <time.h>
+
+#define MASS            4      /* maximum mass of a knot */
+#define MIN_RES         5      /* minimim resolution (>= MIN_RES) */
+#define MAX_RES         1      /* maximum resolution (>0) */
+#define TWO_PLANE_PCNT  30     /* probability for two plane mode (0-100) */
+#define RESTART         2500   /* number of cycles before restart */
+#define BATCH_DRAW      100    /* points to draw per iteration */
+
+/* knot types */
+typedef enum {
+       NONE = 0,
+       ORBIT = (1 << 0),
+       WHEEL = (1 << 1),
+       PICASSO = (1 << 2),
+       RAY = (1 << 3),
+       HOOK = (1 << 4),
+       ALL = (1 << 5)
+} KNOT_T;
+
+/* a knot */
+typedef struct Knot {
+       int         x, y;       /* position */
+       int         m;          /* mass */
+       KNOT_T      t;          /* type in the first (or only) plane */
+       KNOT_T      T;          /* type in second plane if there is one */
+       int         M;          /* mass in second plane if there is one */
+} KNOT     , *KNOT_P;
+
+/* a colour specification */
+typedef struct Colour {
+       unsigned short r, g, b;
+} COLOUR   , *COLOUR_P;
+
+/* drawing direction */
+typedef enum {
+       DRAW_RIGHT, DRAW_DOWN, DRAW_LEFT, DRAW_UP
+} DIR_T;
+
+/****************************************************************/
+
+/* data associated with a swirl window */
+typedef struct swirl_data {
+       /* window paramaters */
+       Window      win;        /* the window */
+       int         width, height;      /* window size */
+       int         depth;      /* depth */
+       int         rdepth;     /* real depth (for XImage) */
+       Visual     *visual;     /* visual */
+
+       /* swirl drawing parameters */
+       int         n_knots;    /* number of knots */
+       KNOT_P      knots;      /* knot details */
+       KNOT_T      knot_type;  /* general type of knots */
+       int         resolution; /* drawing resolution, 1..5 */
+       int         max_resolution;     /* maximum resolution, MAX_RES */
+       int         r;          /* pixel step */
+       Bool        two_plane;  /* two plane mode? */
+       Bool        first_plane;        /* doing first plane? */
+       int         start_again;        /* when to restart */
+
+       /* spiral drawing parameters */
+       int         x, y;       /* current point */
+       DIR_T       direction;  /* current direction */
+       int         dir_todo, dir_done;         /* how many points in current direction? */
+       int         batch_todo, batch_done;     /* how many points in this batch */
+       Bool        started, drawing;   /* are we drawing? */
+
+       /* image stuff */
+       unsigned char *image;   /* image data */
+       XImage     *ximage;
+
+       /* colours stuff */
+       int         colours;    /* how many colours possible */
+       int         dcolours;   /* how many colours for shading */
+       Colormap    cmap;       /* colour map for the window */
+       XColor     *rgb_values; /* colour definitions array */
+       Bool        off_screen;
+#ifndef STANDALONE
+       Bool        fixed_colourmap;    /* fixed colourmap? */
+       int         current_map;        /* current colour map, 0..dcolours-1 */
+       unsigned long black, white, bg, fg;     /* black and white pixel values */
+       int         shift;      /* colourmap shift */
+       int         dshift;     /* colourmap shift while drawing */
+       XColor      bgcol, fgcol;       /* foreground and background colour specs */
+#endif                         /* !STANDALONE */
+} SWIRL    , *SWIRL_P;
+
+#ifndef STANDALONE
+#define SWIRLCOLOURS 13
+/* basic colours */
+static COLOUR basic_colours[SWIRLCOLOURS];
+
+#endif /* !STANDALONE */
+
+/* an array of swirls for each screen */
+static SWIRL_P swirls = NULL;
+
+/*-
+   random_no
+
+   Return a random integer between 0 and n inclusive
+
+   -      n is the maximum number
+
+   Returns a random integer */
+
+static int
+random_no(unsigned int n)
+{
+       return ((int) ((n + 1) * (double) LRAND() / MAXRAND));
+}
+
+/****************************************************************/
+
+/*-
+   initialise_swirl
+
+   Initialise all the swirl data
+
+   -      swirl is the swirl data */
+
+static void
+initialise_swirl(SWIRL_P swirl)
+{
+       swirl->width = 0;       /* width and height of window */
+       swirl->height = 0;
+       swirl->depth = 1;
+       swirl->rdepth = 1;
+       swirl->visual = NULL;
+       swirl->resolution = MIN_RES + 1;        /* current resolution */
+       swirl->max_resolution = MAX_RES;        /* maximum resolution */
+       swirl->n_knots = 0;     /* number of knots */
+       swirl->knot_type = ALL; /* general type of knots */
+       swirl->two_plane = False;       /* two plane mode? */
+       swirl->first_plane = False;     /* doing first plane? */
+       swirl->start_again = -1;        /* restart counter */
+
+       /* drawing parameters */
+       swirl->x = 0;
+       swirl->y = 0;
+       swirl->started = False;
+       swirl->drawing = False;
+
+       /* image stuff */
+       swirl->image = NULL;    /* image data */
+       swirl->ximage = NULL;
+
+       /* colours stuff */
+       swirl->colours = 0;     /* how many colours possible */
+       swirl->dcolours = 0;    /* how many colours for shading */
+       swirl->cmap = (Colormap) NULL;
+       swirl->rgb_values = NULL;       /* colour definitions array */
+}
+
+/****************************************************************/
+
+/*-
+ * initialise_image
+ *
+ * Initialise the image for drawing to
+ *
+ * -      swirl is the swirl data
+ */
+static void
+initialise_image(Display * dpy, SWIRL_P swirl)
+{
+       unsigned int pad;
+       int         bytes_per_line;
+       int         image_depth = swirl->rdepth;
+       int         data_depth = image_depth;
+
+       /* On SGIs at least, using an XImage of depth 24 on a Visual of depth 24
+        *  requires the XImage data to use 32 bits per pixel.  I don't understand
+        *  how one is supposed to determine this -- maybe XListPixmapFormats?
+        *  But on systems that don't work this way, allocating 32 bpp instead of
+        *  24 will be wasteful but non-fatal.  -- jwz, 16-May-97.
+        */
+       if (data_depth >= 24 && data_depth < 32)
+               data_depth = 32;
+
+       /* get the bitmap pad */
+       pad = BitmapPad(dpy);
+       /* destroy the old image (destroy XImage and data) */
+       if (swirl->ximage != NULL)
+               (void) XDestroyImage(swirl->ximage);
+
+       /* how many bytes per line? (bits rounded up to pad) */
+       bytes_per_line = ((swirl->width * data_depth + pad - 1) / pad) * (pad / 8);
+
+       /* allocate space for the image */
+       swirl->image = (unsigned char *) calloc(bytes_per_line * swirl->height, 1);
+
+       /* create an ximage with this */
+       swirl->ximage = XCreateImage(dpy, swirl->visual, image_depth, ZPixmap,
+                                    0, (char *) swirl->image, swirl->width,
+                                    swirl->height, pad, bytes_per_line);
+}
+
+/****************************************************************/
+#ifndef STANDALONE
+
+/*-
+ * initialise_colours
+ *
+ * Initialise the list of colours from which the colourmaps are derived
+ *
+ * -      colours is the array to initialise
+ * -      saturation is the saturation value to use 0->grey,
+ *            1.0->full saturation
+ */
+static void
+initialise_colours(COLOUR * colours, float saturate)
+{
+       int         i;
+
+       /* start off fully saturated, medium and bright colours */
+       colours[0].r = 0xA000;
+       colours[0].g = 0x0000;
+       colours[0].b = 0x0000;
+       colours[1].r = 0xD000;
+       colours[1].g = 0x0000;
+       colours[1].b = 0x0000;
+       colours[2].r = 0x0000;
+       colours[2].g = 0x6000;
+       colours[2].b = 0x0000;
+       colours[3].r = 0x0000;
+       colours[3].g = 0x9000;
+       colours[3].b = 0x0000;
+       colours[4].r = 0x0000;
+       colours[4].g = 0x0000;
+       colours[4].b = 0xC000;
+       colours[5].r = 0x0000;
+       colours[5].g = 0x0000;
+       colours[5].b = 0xF000;
+       colours[6].r = 0xA000;
+       colours[6].g = 0x6000;
+       colours[6].b = 0x0000;
+       colours[7].r = 0xD000;
+       colours[7].g = 0x9000;
+       colours[7].b = 0x0000;
+       colours[8].r = 0xA000;
+       colours[8].g = 0x0000;
+       colours[8].b = 0xC000;
+       colours[9].r = 0xD000;
+       colours[9].g = 0x0000;
+       colours[9].b = 0xF000;
+       colours[10].r = 0x0000;
+       colours[10].g = 0x6000;
+       colours[10].b = 0xC000;
+       colours[11].r = 0x0000;
+       colours[11].g = 0x9000;
+       colours[11].b = 0xF000;
+       colours[12].r = 0xA000;
+       colours[12].g = 0xA000;
+       colours[12].b = 0xA000;
+
+       /* add white for low saturation */
+       for (i = 0; i < SWIRLCOLOURS - 1; i++) {
+               unsigned short max_rg, max;
+
+               /* what is the max intensity for this colour? */
+               max_rg = (colours[i].r > colours[i].g) ? colours[i].r : colours[i].g;
+               max = (max_rg > colours[i].b) ? max_rg : colours[i].b;
+
+               /* bring elements up to max as saturation approaches 0.0 */
+               colours[i].r += (unsigned short) ((float) (1.0 - saturate) *
+                                              ((float) max - colours[i].r));
+               colours[i].g += (unsigned short) ((float) (1.0 - saturate) *
+                                              ((float) max - colours[i].g));
+               colours[i].b += (unsigned short) ((float) (1.0 - saturate) *
+                                              ((float) max - colours[i].b));
+       }
+}
+
+/****************************************************************/
+
+/*-
+ * set_black_and_white
+ *
+ * Set the entries for foreground & background pixels and
+ * WhitePixel & BlackPixel in an array of colour specifications.
+ *
+ * -      swirl is the swirl data
+ * -      values is the array of specifications 
+ */
+static void
+set_black_and_white(SWIRL_P swirl, XColor * values)
+{
+       unsigned long white, black;
+
+       /* where is black and white? */
+       white = swirl->white;
+       black = swirl->black;
+
+       /* set black and white up */
+       values[white].flags = DoRed | DoGreen | DoBlue;
+       values[white].pixel = white;
+       values[white].red = 0xFFFF;
+       values[white].green = 0xFFFF;
+       values[white].blue = 0xFFFF;
+       values[black].flags = DoRed | DoGreen | DoBlue;
+       values[black].pixel = black;
+       values[black].red = 0;
+       values[black].green = 0;
+       values[black].blue = 0;
+
+       /* copy the colour specs from the original entries */
+       values[swirl->bg] = swirl->bgcol;
+       values[swirl->fg] = swirl->fgcol;
+}
+
+/****************************************************************/
+
+/*-
+ * set_colour
+ *
+ * Set an entry in an array of XColor specifications. The given entry will be
+ * set to the given colour. If the entry corresponds to the foreground,
+ * background, WhitePixel, or BlackPixel it is ignored and the given colour
+ * is is put in the next entry.
+ *
+ * Therefore, the given colour may be placed up to four places after the
+ * specified entry in the array, if foreground, background, white, or black
+ * intervene.
+ *
+ * -      swirl is the swirl data
+ * -      value points to a pointer to the array entry. It gets updated to
+ *            point to the next free entry.
+ * -      pixel points to the current pixel number. It gets updated.
+ * -      c points to the colour to add
+ */
+static void
+set_colour(SWIRL_P swirl, XColor ** value, unsigned long *pixel, COLOUR_P c)
+{
+       Bool        done;
+       unsigned long black, white, bg, fg;
+
+       /* where are black, white, background, foreground? */
+       black = swirl->black;
+       white = swirl->white;
+       bg = swirl->bg;
+       fg = swirl->fg;
+
+       /* haven't set it yet */
+       done = False;
+
+       /* try and set the colour */
+       while (!done) {
+               (**value).flags = DoRed | DoGreen | DoBlue;
+               (**value).pixel = *pixel;
+
+               /* white, black, bg, fg, or a colour? */
+               if ((*pixel != black) && (*pixel != white) &&
+                   (*pixel != bg) && (*pixel != fg)) {
+                       (**value).red = c->r;
+                       (**value).green = c->g;
+                       (**value).blue = c->b;
+
+                       /* now we've done it */
+                       done = True;
+               }
+               /* next pixel */
+               (*value)++;
+               (*pixel)++;
+       }
+}
+
+/****************************************************************/
+
+/*-
+ * get_colour
+ *
+ * Get an entry from an array of XColor specifications. The next colour from
+ * the array will be returned. Foreground, background, WhitePixel, or
+ * BlackPixel will be ignored.
+ *
+ * -      swirl is the swirl data
+ * -      value points the array entry. It is updated to point to the entry
+ *            following the one returned.
+ * -      c is set to the colour found
+ */
+static void
+get_colour(SWIRL_P swirl, XColor ** value, COLOUR_P c)
+{
+       Bool        done;
+       unsigned long black, white, bg, fg;
+
+       /* where is white and black? */
+       black = swirl->black;
+       white = swirl->white;
+       bg = swirl->bg;
+       fg = swirl->fg;
+
+       /* haven't set it yet */
+       done = False;
+
+       /* try and set the colour */
+       while (!done) {
+               /* black, white or a colour? */
+               if (((*value)->pixel != black) && ((*value)->pixel != white) &&
+                   ((*value)->pixel != bg) && ((*value)->pixel != fg)) {
+                       c->r = (*value)->red;
+                       c->g = (*value)->green;
+                       c->b = (*value)->blue;
+
+                       /* now we've done it */
+                       done = True;
+               }
+               /* next value */
+               (*value)++;
+       }
+}
+
+/****************************************************************/
+
+/*-
+ *  interpolate
+ *
+ * Generate n colours between c1 and c2.  n XColors at *value are set up with
+ * ascending pixel values.
+ *
+ * If the pixel range includes BlackPixel or WhitePixel they are set to black
+ * and white respectively but otherwise ignored. Therefore, up to n+2 colours
+ * may actually be set by this function.
+ *
+ * -      swirl is the swirl data
+ * -      values points a pointer to an array of XColors to update
+ * -      pixel points to the pixel number to start at
+ * -      k n is the number of colours to generate
+ * -      c1, c2 are the colours to interpolate between
+ */
+static void
+interpolate(SWIRL_P swirl, XColor ** values, unsigned long *pixel, int n, COLOUR_P c1, COLOUR_P c2)
+{
+       int         i, r, g, b;
+       COLOUR      c;
+       unsigned short maxv;
+
+       /* maximum value */
+       maxv = (255 << 8);
+
+       for (i = 0; i < n / 2 && (int) *pixel < swirl->colours; i++) {
+               /* work out the colour */
+               r = c1->r + 2 * i * ((int) c2->r) / n;
+               c.r = (r > (int) maxv) ? maxv : r;
+               g = c1->g + 2 * i * ((int) c2->g) / n;
+               c.g = (g > (int) maxv) ? maxv : g;
+               b = c1->b + 2 * i * ((int) c2->b) / n;
+               c.b = (b > (int) maxv) ? maxv : b;
+
+               /* set it up */
+               set_colour(swirl, values, pixel, &c);
+       }
+       for (i = n / 2; i >= 0 && (int) *pixel < swirl->colours; i--) {
+               r = c2->r + 2 * i * ((int) c1->r) / n;
+               c.r = (r > (int) maxv) ? maxv : r;
+               g = c2->g + 2 * i * ((int) c1->g) / n;
+               c.g = (g > (int) maxv) ? maxv : g;
+               b = c2->b + 2 * i * ((int) c1->b) / n;
+               c.b = (b > (int) maxv) ? maxv : b;
+
+               /* set it up */
+               set_colour(swirl, values, pixel, &c);
+       }
+}
+
+/****************************************************************/
+
+/*-
+ * basic_map
+ *
+ * Generate a `random' closed loop colourmap that occupies the whole colour
+ * map.
+ *
+ * -      swirl is the swirl data
+ * -      values is the array of colour definitions to set up
+ */
+static void
+basic_map(SWIRL_P swirl, XColor * values)
+{
+       COLOUR      c[3];
+       int         i;
+       unsigned short r1, g1, b1, r2, g2, b2, r3, g3, b3;
+       int         L1, L2, L3, L;
+       unsigned long pixel;
+       XColor     *value;
+
+       /* start at the beginning of the colour map */
+       pixel = 0;
+       value = values;
+
+       /* choose 3 different basic colours at random */
+       for (i = 0; i < 3;) {
+               int         j;
+               Bool        same;
+
+               /* choose colour i */
+               c[i] = basic_colours[random_no(SWIRLCOLOURS - 1)];
+
+               /* assume different */
+               same = False;
+
+               /* different from the rest? */
+               for (j = 0; j < i; j++)
+                       if ((c[i].r == c[j].r) &&
+                           (c[i].g == c[j].g) &&
+                           (c[i].b == c[j].b))
+                               same = True;
+
+               /* ready for the next colour? */
+               if (!same)
+                       i++;
+       }
+
+       /* extract components into variables */
+       r1 = c[0].r;
+       g1 = c[0].g;
+       b1 = c[0].b;
+       r2 = c[1].r;
+       g2 = c[1].g;
+       b2 = c[1].b;
+       r3 = c[2].r;
+       g3 = c[2].g;
+       b3 = c[2].b;
+
+       /* work out the lengths of each side of the triangle */
+       L1 = (int) sqrt((((double) r1 - r2) * ((double) r1 - r2) +
+                        ((double) g1 - g2) * ((double) g1 - g2) +
+                        ((double) b1 - b2) * ((double) b1 - b2)));
+
+       L2 = (int) sqrt((((double) r3 - r2) * ((double) r3 - r2) +
+                        ((double) g3 - g2) * ((double) g3 - g2) +
+                        ((double) b3 - b2) * ((double) b3 - b2)));
+
+       L3 = (int) sqrt((((double) r1 - r3) * ((double) r1 - r3) +
+                        ((double) g1 - g3) * ((double) g1 - g3) +
+                        ((double) b1 - b3) * ((double) b1 - b3)));
+
+       L = L1 + L2 + L3;
+
+       /* allocate colours in proportion to the lengths of the sides */
+       interpolate(swirl, &value, &pixel,
+                   (int) ((double) swirl->dcolours * ((double) L1 / (double) L)) + 1, c, c + 1);
+       interpolate(swirl, &value, &pixel,
+                   (int) ((double) swirl->dcolours * ((double) L2 / (double) L)) + 1, c + 1, c + 2);
+       interpolate(swirl, &value, &pixel,
+                   (int) ((double) swirl->dcolours * ((double) L3 / (double) L)) + 1, c + 2, c);
+
+       /* fill up any remaining slots (due to rounding) */
+       while ((int) pixel < swirl->colours) {
+               /* repeat the last colour */
+               set_colour(swirl, &value, &pixel, c);
+       }
+
+       /* ensure black and white are correct */
+       if (!swirl->fixed_colourmap)
+               set_black_and_white(swirl, values);
+}
+
+/****************************************************************/
+
+/*-
+ * pre_rotate
+ *
+ * Generate pre-rotated versions of the colour specifications
+ *
+ * -      swirl is the swirl data
+ * -      values is an array of colour specifications
+ */
+static void
+pre_rotate(SWIRL_P swirl, XColor * values)
+{
+       int         i, j;
+       XColor     *src, *dest;
+       int         dcolours;
+       unsigned long pixel;
+
+       /* how many colours to display? */
+       dcolours = swirl->dcolours;
+
+       /* start at the first map */
+       src = values;
+       dest = values + swirl->colours;
+
+       /* generate dcolours-1 rotated maps */
+       for (i = 0; i < dcolours - 1; i++) {
+               COLOUR      first;
+
+               /* start at the first pixel */
+               pixel = 0;
+
+               /* remember the first one and skip it */
+               get_colour(swirl, &src, &first);
+
+               /* put a rotated version of src at dest */
+               for (j = 0; j < dcolours - 1; j++) {
+                       COLOUR      c;
+
+                       /* get the source colour */
+                       get_colour(swirl, &src, &c);
+
+                       /* set the colour */
+                       set_colour(swirl, &dest, &pixel, &c);
+               }
+
+               /* put the first one at the end */
+               set_colour(swirl, &dest, &pixel, &first);
+
+               /* NB: src and dest should now be ready for the next table */
+
+               /* ensure black and white are properly set */
+               set_black_and_white(swirl, src);
+       }
+}
+
+/****************************************************************/
+
+/*-
+ * create_colourmap
+ *
+ * Create a read/write colourmap to use
+ *
+ * -      swirl is the swirl data
+ */
+
+static void
+create_colourmap(ModeInfo * mi, SWIRL_P swirl)
+{
+       Display    *display = MI_DISPLAY(mi);
+       int         preserve = 0;
+       int         n_rotations;
+       int         i;
+       Bool        truecolor;
+       unsigned long redmask, greenmask, bluemask;
+
+       swirl->fixed_colourmap = !setupColormap(mi, &(swirl->colours),
+                               &truecolor, &redmask, &greenmask, &bluemask);
+
+       /* how many colours should we animate? */
+
+       if (MI_NPIXELS(mi) < 2)
+               return;
+
+       /* how fast to shift the colourmap? */
+       swirl->shift = (swirl->colours > 64) ? swirl->colours / 64 : 1;
+       swirl->dshift = (swirl->shift > 1) ? swirl->shift * 2 : 1;
+
+       /* create a colour map */
+       if (!swirl->fixed_colourmap) {
+               swirl->current_map = 0;         /* current colour map, 0..dcolours-1 */
+
+               /* set up fg fb colour specs */
+               swirl->black = MI_BLACK_PIXEL(mi);
+               swirl->white = MI_WHITE_PIXEL(mi);
+               swirl->bg = MI_BG_PIXEL(mi);
+               swirl->fg = MI_FG_PIXEL(mi);
+               preserve = preserveColors(swirl->black, swirl->white,
+                                         swirl->bg, swirl->fg);
+               swirl->bgcol.pixel = swirl->bg;
+               swirl->fgcol.pixel = swirl->fg;
+               XQueryColor(display, MI_COLORMAP(mi), &(swirl->bgcol));
+               XQueryColor(display, MI_COLORMAP(mi), &(swirl->fgcol));
+               if (swirl->cmap) {
+                       XFreeColormap(display, swirl->cmap);
+               }
+               swirl->cmap =
+                       XCreateColormap(display, swirl->win, swirl->visual, AllocAll);
+       }
+       swirl->dcolours = (swirl->colours > preserve + 1) ?
+               swirl->colours - preserve : swirl->colours;
+       /* how may colour map rotations are there? */
+       n_rotations = (swirl->fixed_colourmap) ? 1 : swirl->dcolours;
+
+       /* allocate space for colour definitions (if not already there) */
+       if (swirl->rgb_values != NULL)
+               XFree((caddr_t) swirl->rgb_values);
+       swirl->rgb_values = (XColor *) calloc((swirl->colours + 3) * n_rotations,
+                                             sizeof (XColor));
+
+       /* select a set of colours for the colour map */
+       basic_map(swirl, swirl->rgb_values);
+
+       /* are we rotating them? */
+       if (!swirl->fixed_colourmap) {
+               /* generate rotations of the colour maps */
+               pre_rotate(swirl, swirl->rgb_values);
+
+               /* store the colours in the colour map */
+               XStoreColors(display, swirl->cmap, swirl->rgb_values, swirl->colours);
+       } else {
+               if (truecolor) {
+                       int         rsh, gsh, bsh;
+                       unsigned long int t;
+
+                       t = redmask;
+                       for (i = 0; (int) t > 0; i++, t >>= 1);
+                       rsh = 16 - i;
+                       t = greenmask;
+                       for (i = 0; (int) t > 0; i++, t >>= 1);
+                       gsh = 16 - i;
+                       t = bluemask;
+                       for (i = 0; (int) t > 0; i++, t >>= 1);
+                       bsh = 16 - i;
+                       for (i = 0; i < swirl->colours; i++)
+                               swirl->rgb_values[i].pixel =
+                                       ((rsh > 0 ? (swirl->rgb_values[i].red) >> rsh :
+                                         (swirl->rgb_values[i].red) << (-rsh)) & redmask) |
+                                       ((gsh > 0 ? (swirl->rgb_values[i].green) >> gsh :
+                                         (swirl->rgb_values[i].green) << (-gsh)) & greenmask) |
+                                       ((bsh > 0 ? (swirl->rgb_values[i].blue) >> bsh :
+                                         (swirl->rgb_values[i].blue) << (-bsh)) & bluemask);
+               } else {
+                       /* lookup the colours in the fixed colour map */
+                       for (i = 0; i < swirl->colours; i++)
+                               (void) XAllocColor(display, MI_COLORMAP(mi),
+                                                  &(swirl->rgb_values[i]));
+               }
+       }
+}
+
+/****************************************************************/
+
+/*-
+ * install_map
+ *
+ * Install a new set of colours into the colour map
+ *
+ * -      dpy is the display
+ * -      swirl is the swirl data
+ * -      shift is the amount to rotate the colour map by
+ */
+static void
+install_map(Display * dpy, SWIRL_P swirl, int shift)
+{
+       if (!swirl->fixed_colourmap) {
+               /* shift the colour map */
+               swirl->current_map = (swirl->current_map + shift) %
+                       swirl->dcolours;
+
+               /* store it */
+               XStoreColors(dpy, swirl->cmap,
+                            swirl->rgb_values +
+                            swirl->current_map * swirl->colours,
+                            swirl->colours);
+       }
+}
+
+#endif /* !STANDALONE */
+/****************************************************************/
+
+/*-
+ * create_knots
+ *
+ * Initialise the array of knot
+ *
+ * swirl is the swirl data
+ */
+static void
+create_knots(SWIRL_P swirl)
+{
+       int         k;
+       Bool        orbit, wheel, picasso, ray, hook;
+       KNOT_P      knot;
+
+       /* create array for knots */
+       if (swirl->knots)
+               (void) free((void *) swirl->knots);
+       swirl->knots = (KNOT_P) calloc(swirl->n_knots, sizeof (KNOT));
+
+       /* no knots yet */
+       orbit = wheel = picasso = ray = hook = False;
+
+       /* what types do we have? */
+       if ((int) swirl->knot_type & (int) ALL) {
+               orbit = wheel = ray = hook = True;
+       } else {
+               if ((int) swirl->knot_type & (int) ORBIT)
+                       orbit = True;
+               if ((int) swirl->knot_type & (int) WHEEL)
+                       wheel = True;
+               if ((int) swirl->knot_type & (int) PICASSO)
+                       picasso = True;
+               if ((int) swirl->knot_type & (int) RAY)
+                       ray = True;
+               if ((int) swirl->knot_type & (int) HOOK)
+                       hook = True;
+       }
+
+       /* initialise each knot */
+       knot = swirl->knots;
+       for (k = 0; k < swirl->n_knots; k++) {
+               /* position */
+               knot->x = random_no((unsigned int) swirl->width);
+               knot->y = random_no((unsigned int) swirl->height);
+
+               /* mass */
+               knot->m = random_no(MASS) + 1;
+
+               /* can be negative */
+               if (random_no(100) > 50)
+                       knot->m *= -1;
+
+               /* type */
+               knot->t = NONE;
+               while (knot->t == NONE) {
+                       /* choose a random one from the types available */
+                       switch (random_no(4)) {
+                               case 0:
+                                       if (orbit)
+                                               knot->t = ORBIT;
+                                       break;
+                               case 1:
+                                       if (wheel)
+                                               knot->t = WHEEL;
+                                       break;
+                               case 2:
+                                       if (picasso)
+                                               knot->t = PICASSO;
+                                       break;
+                               case 3:
+                                       if (ray)
+                                               knot->t = RAY;
+                                       break;
+                               case 4:
+                                       if (hook)
+                                               knot->t = HOOK;
+                                       break;
+                       }
+               }
+
+               /* if two planes, do same for second plane */
+               if (swirl->two_plane) {
+                       knot->T = NONE;
+                       while (knot->T == NONE || knot->T == knot->t) {
+                               /* choose a different type */
+                               switch (random_no(4)) {
+                                       case 0:
+                                               if (orbit)
+                                                       knot->T = ORBIT;
+                                               break;
+                                       case 1:
+                                               if (wheel)
+                                                       knot->T = WHEEL;
+                                               break;
+                                       case 2:
+                                               if (picasso)
+                                                       knot->T = PICASSO;
+                                               break;
+                                       case 3:
+                                               if (ray)
+                                                       knot->T = RAY;
+                                               break;
+                                       case 4:
+                                               if (hook)
+                                                       knot->T = HOOK;
+                                               break;
+                               }
+                       }
+               }
+               /* next knot */
+               knot++;
+       }
+}
+
+/****************************************************************/
+
+/*-
+ * do_point
+ *
+ * Work out the pixel value at i, j. Ensure it does not clash with BlackPixel
+ * or WhitePixel.
+ *
+ * -      swirl is the swirl data
+ * -      i, j is the point to calculate
+ *
+ * Returns the value of the point
+ */
+static unsigned long
+do_point(SWIRL_P swirl, int i, int j)
+{
+       int         tT, k, add, value;
+       unsigned long colour_value;
+       double      dx, dy, theta, dist;
+       int         dcolours, qcolours;
+       double      rads;
+       KNOT_P      knot;
+
+       /* how many colours? */
+       dcolours = swirl->dcolours;
+       qcolours = dcolours / 4;
+
+       /* colour step round a circle */
+       rads = (double) dcolours / (2.0 * M_PI);
+
+       /* start at zero */
+       value = 0;
+
+       /* go through all the knots */
+       knot = swirl->knots;
+       for (k = 0; k < swirl->n_knots; k++) {
+               dx = i - knot->x;
+               dy = j - knot->y;
+
+               /* in two_plane mode get the appropriate knot type */
+               if (swirl->two_plane)
+                       tT = (int) ((swirl->first_plane) ? knot->t : knot->T);
+               else
+                       tT = (int) knot->t;
+
+               /* distance from knot */
+               dist = sqrt(dx * dx + dy * dy);
+
+               /* nothing to add at first */
+               add = 0;
+
+               /* work out the contribution (if close enough) */
+               if (dist > 0.1)
+                       switch (tT) {
+                               case ORBIT:
+                                       add = (int) (dcolours / (1.0 + 0.01 * abs(knot->m) * dist));
+                                       break;
+                               case WHEEL:
+                                       /* Avoid atan2: DOMAIN error message */
+                                       if (dy == 0.0 && dx == 0.0)
+                                               theta = 1.0;
+                                       else
+                                               theta = (atan2(dy, dx) + M_PI) / M_PI;
+                                       if (theta < 1.0)
+                                               add = (int) (dcolours * theta +
+                                                 sin(0.1 * knot->m * dist) *
+                                               qcolours * exp(-0.01 * dist));
+                                       else
+                                               add = (int) (dcolours * (theta - 1.0) +
+                                                 sin(0.1 * knot->m * dist) *
+                                               qcolours * exp(-0.01 * dist));
+                                       break;
+                               case PICASSO:
+                                       add = (int) (dcolours *
+                                         fabs(cos(0.002 * knot->m * dist)));
+                                       break;
+                               case RAY:
+                                       /* Avoid atan2: DOMAIN error message */
+                                       if (dy == 0.0 && dx == 0.0)
+                                               add = 0;
+                                       else
+                                               add = (int) (dcolours * fabs(sin(2.0 * atan2(dy, dx))));
+
+                                       break;
+                               case HOOK:
+                                       /* Avoid atan2: DOMAIN error message */
+                                       if (dy == 0.0 && dx == 0.0)
+                                               add = (int) (0.05 * (abs(knot->m) - 1) * dist);
+                                       else
+                                               add = (int) (rads * atan2(dy, dx) +
+                                                            0.05 * (abs(knot->m) - 1) * dist);
+                                       break;
+                       }
+               /* for a +ve mass add on the contribution else take it off */
+               if (knot->m > 0)
+                       value += add;
+               else
+                       value -= add;
+
+               /* next knot */
+               knot++;
+       }
+
+       /* toggle plane */
+       swirl->first_plane = (!swirl->first_plane);
+
+       /* make sure we handle -ve values properly */
+       if (value >= 0)
+               colour_value = (value % dcolours) + 2;
+       else
+               colour_value = dcolours - (abs((int) value) % (dcolours - 1));
+
+#ifndef STANDALONE
+       /* if bg and fg are 0 and 1 we should be OK, but just in case */
+       while ((dcolours > 2) &&
+              (((colour_value % swirl->colours) == swirl->black) ||
+               ((colour_value % swirl->colours) == swirl->white) ||
+               ((colour_value % swirl->colours) == swirl->bg) ||
+               ((colour_value % swirl->colours) == swirl->fg))) {
+               colour_value++;
+       }
+#endif /* !STANDALONE */
+
+       /* definitely make sure it is in range */
+       colour_value = colour_value % swirl->colours;
+
+       /* lookup the pixel value if necessary */
+#ifndef STANDALONE
+       if (swirl->fixed_colourmap && swirl->dcolours > 2)
+#endif
+               colour_value = swirl->rgb_values[colour_value].pixel;
+
+       /* return it */
+       return colour_value;
+}
+
+/****************************************************************/
+
+/*-
+ * draw_block
+ *
+ * Draw a square block of points with the same value.
+ *
+ * -      ximage is the XImage to draw on.
+ * -      x, y is the top left corner
+ * -      s is the length of each side
+ * -      v is the value
+ */
+static void
+draw_block(XImage * ximage, int x, int y, int s, unsigned long v)
+{
+       int         a, b;
+
+       for (a = 0; a < s; a++)
+               for (b = 0; b < s; b++) {
+                       XPutPixel(ximage, x + b, y + a, v);
+               }
+}
+
+/****************************************************************/
+
+/*-
+ * draw_point  Draw the current point in a swirl pattern onto the XImage
+ *
+ * -    swirl is the swirl
+ * -    win is the window to update
+ */
+static void
+draw_point(ModeInfo * mi, SWIRL_P swirl)
+{
+       int         r;
+       int         x, y;
+
+       /* get current point coordinates and resolution */
+       x = swirl->x;
+       y = swirl->y;
+       r = swirl->r;
+
+       /* check we are within the window */
+       if ((x < 0) || (x > swirl->width - r) || (y < 0) || (y > swirl->height - r))
+               return;
+
+       /* what style are we drawing? */
+       if (swirl->two_plane) {
+               int         r2;
+
+               /* halve the block size */
+               r2 = r / 2;
+
+               /* interleave blocks at half r */
+               draw_block(swirl->ximage, x, y, r2, do_point(swirl, x, y));
+               draw_block(swirl->ximage, x + r2, y, r2, do_point(swirl, x + r2, y));
+               draw_block(swirl->ximage, x + r2, y + r2, r2, do_point(swirl,
+                                                           x + r2, y + r2));
+               draw_block(swirl->ximage, x, y + r2, r2, do_point(swirl, x, y + r2));
+       } else
+               draw_block(swirl->ximage, x, y, r, do_point(swirl, x, y));
+
+       /* update the screen */
+/*-
+ * PURIFY 4.0.1 on SunOS4 and on Solaris 2 reports a 256 byte memory leak on
+ * the next line. */
+       (void) XPutImage(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), swirl->ximage,
+                        x, y, x, y, r, r);
+}
+
+/****************************************************************/
+
+/*-
+ * next_point  Move to the next point in the spiral pattern
+ *  -    swirl is the swirl
+ *  -    win is the window to update
+ */
+static void
+next_point(SWIRL_P swirl)
+{
+       /* more to do in this direction? */
+       if (swirl->dir_done < swirl->dir_todo) {
+               /* move in the current direction */
+               switch (swirl->direction) {
+                       case DRAW_RIGHT:
+                               swirl->x += swirl->r;
+                               break;
+                       case DRAW_DOWN:
+                               swirl->y += swirl->r;
+                               break;
+                       case DRAW_LEFT:
+                               swirl->x -= swirl->r;
+                               break;
+                       case DRAW_UP:
+                               swirl->y -= swirl->r;
+                               break;
+               }
+
+               /* done another point */
+               swirl->dir_done++;
+       } else {
+               /* none drawn yet */
+               swirl->dir_done = 0;
+
+               /* change direction - check and record if off screen */
+               switch (swirl->direction) {
+                       case DRAW_RIGHT:
+                               swirl->direction = DRAW_DOWN;
+                               if (swirl->x > swirl->width - swirl->r) {
+                                       /* skip these points */
+                                       swirl->dir_done = swirl->dir_todo;
+                                       swirl->y += (swirl->dir_todo * swirl->r);
+
+                                       /* check for finish */
+                                       if (swirl->off_screen)
+                                               swirl->drawing = False;
+                                       swirl->off_screen = True;
+                               } else
+                                       swirl->off_screen = False;
+                               break;
+                       case DRAW_DOWN:
+                               swirl->direction = DRAW_LEFT;
+                               swirl->dir_todo++;
+                               if (swirl->y > swirl->height - swirl->r) {
+                                       /* skip these points */
+                                       swirl->dir_done = swirl->dir_todo;
+                                       swirl->x -= (swirl->dir_todo * swirl->r);
+
+                                       /* check for finish */
+                                       if (swirl->off_screen)
+                                               swirl->drawing = False;
+                                       swirl->off_screen = True;
+                               } else
+                                       swirl->off_screen = False;
+                               break;
+                       case DRAW_LEFT:
+                               swirl->direction = DRAW_UP;
+                               if (swirl->x < 0) {
+                                       /* skip these points */
+                                       swirl->dir_done = swirl->dir_todo;
+                                       swirl->y -= (swirl->dir_todo * swirl->r);
+
+                                       /* check for finish */
+                                       if (swirl->off_screen)
+                                               swirl->drawing = False;
+                                       swirl->off_screen = True;
+                               } else
+                                       swirl->off_screen = False;
+                               break;
+                       case DRAW_UP:
+                               swirl->direction = DRAW_RIGHT;
+                               swirl->dir_todo++;
+                               if (swirl->y < 0) {
+                                       /* skip these points */
+                                       swirl->dir_done = swirl->dir_todo;
+                                       swirl->x += (swirl->dir_todo * swirl->r);
+
+                                       /* check for finish */
+                                       if (swirl->off_screen)
+                                               swirl->drawing = False;
+                                       swirl->off_screen = True;
+                               } else
+                                       swirl->off_screen = False;
+                               break;
+               }
+       }
+}
+
+/****************************************************************/
+
+/*-
+ * init_swirl
+ *
+ * Initialise things for swirling
+ *
+ * -      win is the window to draw in
+ */
+void
+init_swirl(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       SWIRL_P     swirl;
+
+       /* does the swirls array exist? */
+       if (swirls == NULL) {
+               int         i;
+
+               /* allocate an array, one entry for each screen */
+               swirls = (SWIRL_P) calloc(ScreenCount(display), sizeof (SWIRL));
+
+               /* initialise them all */
+               for (i = 0; i < ScreenCount(display); i++)
+                       initialise_swirl(&swirls[i]);
+       }
+       /* get a pointer to this swirl */
+       swirl = &(swirls[MI_SCREEN(mi)]);
+
+       /* get window parameters */
+       swirl->win = window;
+       swirl->width = MI_WIDTH(mi);
+       swirl->height = MI_HEIGHT(mi);
+       swirl->depth = MI_DEPTH(mi);
+       swirl->rdepth = swirl->depth;
+       swirl->visual = MI_VISUAL(mi);
+
+       if (swirl->depth > 16)
+               swirl->depth = 16;
+
+       /* initialise image for speeding up drawing */
+       initialise_image(display, swirl);
+
+       MI_CLEARWINDOW(mi);
+
+#ifdef STANDALONE
+
+       swirl->rgb_values = mi->colors;
+       swirl->colours = mi->npixels;
+       swirl->dcolours = swirl->colours;
+/* swirl->fixed_colourmap = !mi->writable_p; */
+
+#else /* !STANDALONE */
+       /* initialise the colours from which the colourmap is derived */
+       initialise_colours(basic_colours, MI_SATURATION(mi));
+
+       /* set up the colour map */
+       create_colourmap(mi, swirl);
+
+       /* attach the colour map to the window (if we have one) */
+       if (!swirl->fixed_colourmap) {
+#if 1
+               setColormap(display, window, swirl->cmap, MI_IS_INWINDOW(mi));
+#else
+               XSetWindowColormap(display, window, swirl->cmap);
+               XSetWMColormapWindows(display, window, &window, 1);
+               XInstallColormap(display, swirl->cmap);
+#endif
+       }
+#endif /* !STANDALONE */
+
+       /* resolution starts off chunky */
+       swirl->resolution = MIN_RES + 1;
+
+       /* calculate the pixel step for this resulution */
+       swirl->r = (1 << (swirl->resolution - 1));
+
+       /* how many knots? */
+       swirl->n_knots = random_no((unsigned int) MI_COUNT(mi) / 2) +
+               MI_COUNT(mi) + 1;
+
+       /* what type of knots? */
+       swirl->knot_type = ALL; /* for now */
+
+       /* use two_plane mode occaisionally */
+       if (random_no(100) <= TWO_PLANE_PCNT) {
+               swirl->two_plane = swirl->first_plane = True;
+               swirl->max_resolution = 2;
+       } else
+               swirl->two_plane = False;
+
+       /* fix the knot values */
+       create_knots(swirl);
+
+       /* we are off */
+       swirl->started = True;
+       swirl->drawing = False;
+}
+
+/****************************************************************/
+
+/*-
+ * draw_swirl
+ *
+ * Draw one iteration of swirling
+ *
+ * -      win is the window to draw in
+ */
+void
+draw_swirl(ModeInfo * mi)
+{
+       SWIRL_P     swirl = &(swirls[MI_SCREEN(mi)]);
+
+       MI_IS_DRAWN(mi) = True;
+
+       /* are we going? */
+       if (swirl->started) {
+               /* in the middle of drawing? */
+               if (swirl->drawing) {
+#ifdef STANDALONE
+                       if (mi->writable_p)
+                               rotate_colors(MI_DISPLAY(mi), MI_COLORMAP(mi),
+                                      swirl->rgb_values, swirl->colours, 1);
+#else /* !STANDALONE */
+                       /* rotate the colours */
+                       install_map(MI_DISPLAY(mi), swirl, swirl->dshift);
+#endif /* !STANDALONE */
+
+                       /* draw a batch of points */
+                       swirl->batch_todo = BATCH_DRAW;
+                       while ((swirl->batch_todo > 0) && swirl->drawing) {
+                               /* draw a point */
+                               draw_point(mi, swirl);
+
+                               /* move to the next point */
+                               next_point(swirl);
+
+                               /* done a point */
+                               swirl->batch_todo--;
+                       }
+               } else {
+#ifdef STANDALONE
+                       if (mi->writable_p)
+                               rotate_colors(MI_DISPLAY(mi), MI_COLORMAP(mi),
+                                      swirl->rgb_values, swirl->colours, 1);
+#else /* !STANDALONE */
+                       /* rotate the colours */
+                       install_map(MI_DISPLAY(mi), swirl, swirl->shift);
+#endif /* !STANDALONE */
+
+                       /* time for a higher resolution? */
+                       if (swirl->resolution > swirl->max_resolution) {
+                               /* move to higher resolution */
+                               swirl->resolution--;
+
+                               /* calculate the pixel step for this resulution */
+                               swirl->r = (1 << (swirl->resolution - 1));
+
+                               /* start drawing again */
+                               swirl->drawing = True;
+
+                               /* start in the middle of the screen */
+                               swirl->x = (swirl->width - swirl->r) / 2;
+                               swirl->y = (swirl->height - swirl->r) / 2;
+
+                               /* initialise spiral drawing parameters */
+                               swirl->direction = DRAW_RIGHT;
+                               swirl->dir_todo = 1;
+                               swirl->dir_done = 0;
+                       } else {
+                               /* all done, decide when to restart */
+                               if (swirl->start_again == -1) {
+                                       /* start the counter */
+                                       swirl->start_again = RESTART;
+                               } else if (swirl->start_again == 0) {
+                                       /* reset the counter */
+                                       swirl->start_again = -1;
+
+#ifdef STANDALONE
+                                       /* Pick a new colormap! */
+                                       MI_CLEARWINDOW(mi);
+                                       free_colors(MI_DISPLAY(mi), MI_COLORMAP(mi),
+                                                   mi->colors, mi->npixels);
+                                       make_smooth_colormap(MI_DISPLAY(mi),
+                                                            MI_VISUAL(mi),
+                                                            MI_COLORMAP(mi),
+                                             mi->colors, &mi->npixels, True,
+                                                            &mi->writable_p);
+                                       swirl->colours = mi->npixels;
+#endif /* STANDALONE */
+
+                                       /* start again */
+                                       init_swirl(mi);
+                               } else
+                                       /* decrement the counter */
+                                       swirl->start_again--;
+                       }
+               }
+       }
+}
+
+/****************************************************************/
+
+void
+release_swirl(ModeInfo * mi)
+{
+       /* does the swirls array exist? */
+       if (swirls != NULL) {
+               int         i;
+
+               /* free them all */
+               for (i = 0; i < MI_NUM_SCREENS(mi); i++) {
+                       SWIRL_P     swirl = &(swirls[i]);
+
+                       if (swirl->cmap != None) {
+                               XFreeColormap(MI_DISPLAY(mi), swirl->cmap);
+                       }
+                       if (swirl->rgb_values != NULL)
+                               XFree((caddr_t) swirl->rgb_values);
+                       if (swirl->ximage != NULL)
+                               (void) XDestroyImage(swirl->ximage);
+                       if (swirl->knots)
+                               (void) free((void *) swirl->knots);
+               }
+               /* deallocate an array, one entry for each screen */
+               (void) free((void *) swirls);
+               swirls = NULL;
+       }
+}
+
+/****************************************************************/
+
+void
+refresh_swirl(ModeInfo * mi)
+{
+       SWIRL_P     swirl = &(swirls[MI_SCREEN(mi)]);
+
+       if (swirl->started) {
+               MI_CLEARWINDOW(mi);
+               if (swirl->drawing)
+                       swirl->resolution = swirl->resolution + 1;
+               swirl->drawing = False;
+       }
+}
+
+#endif /* MODE_swirl */
diff --git a/xlockmore-4.14/modes/tetris.c b/xlockmore-4.14/modes/tetris.c
new file mode 100644 (file)
index 0000000..ee80409
--- /dev/null
@@ -0,0 +1,932 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* tetris --- autoplaying tetris game */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)tetris.c     4.13 98/10/01 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1998 by Jouk Jansen <joukj@hrem.stm.tudelft.nl>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * The author should like to be notified if changes have been made to the
+ * routine.  Response will only be guaranteed when a VMS version of the 
+ * program is available.
+ *
+ * An autoplaying tetris mode for xlockmore
+ * David Bagley changed much of it to look more like altetris code...
+ * which a significant portion belongs to Q. Alex Zhao.
+ *
+ * Copyright (c) 1992 - 95    Q. Alex Zhao, azhao@cc.gatech.edu
+ *
+ *     All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and
+ * that both that copyright notice and this permission notice appear in
+ * supporting documentation, and that the name of the author not be
+ * used in advertising or publicity pertaining to distribution of the
+ * software without specific, written prior permission.
+ *
+ * This program is distributed in the hope that it will be "playable",
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ * 
+ * Todo list consists of (in this order):
+ *  -Removal of "full" lines
+ *  -Adding rotation/shifting
+ *  -Add option for the level of thinking the computer should perform
+ *     (i.e. dummy = do nothing ..... genius = do always the best move
+ *     possible)
+ *
+ * Revision History:
+ * 01-Oct-98: Created
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Tetris"
+#define HACK_INIT init_tetris
+#define HACK_DRAW draw_tetris
+#define tetris_opts xlockmore_opts
+#define DEFAULTS "*delay: 600000 \n" \
+ "*count: -500 \n" \
+ "*cycles: 200 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 200 \n" \
+ "*fullrandom: True \n" \
+ "*verbose: False \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#include "color.h"
+#endif /* STANDALONE */
+
+#ifdef MODE_tetris
+
+#define DEF_CYCLE "True"
+
+static Bool cycle_p;
+
+#define INTRAND(min,max) (NRAND((max+1)-(min))+(min))
+
+static XrmOptionDescRec opts[] =
+{
+       {"-cycle", ".tetris.cycle", XrmoptionNoArg, (caddr_t) "on"},
+       {"+cycle", ".tetris.cycle", XrmoptionNoArg, (caddr_t) "off"}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & cycle_p, "cycle", "Cycle", DEF_CYCLE, t_Bool}
+};
+static OptionStruct desc[] =
+{
+       {"-/+cycle", "turn on/off colour cycling"}
+};
+
+ModeSpecOpt tetris_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   tetris_description =
+{"tetris", "init_tetris", "draw_tetris", "release_tetris",
+ "refresh_tetris", "init_tetris", NULL, &tetris_opts,
+ 600000, -40, 200, 0, 64, 1.0, "",
+ "Autoplaying tetris game", 0, NULL};
+
+#endif
+
+#include       "bitmaps/rot00.xbm"
+#include       "bitmaps/rot01.xbm"
+#include       "bitmaps/rot02.xbm"
+#include       "bitmaps/rot03.xbm"
+#include       "bitmaps/rot04.xbm"
+#include       "bitmaps/rot05.xbm"
+#include       "bitmaps/rot06.xbm"
+#include       "bitmaps/rot07.xbm"
+#include       "bitmaps/rot08.xbm"
+#include       "bitmaps/rot09.xbm"
+#include       "bitmaps/rot10.xbm"
+#include       "bitmaps/rot11.xbm"
+#include       "bitmaps/rot12.xbm"
+#include       "bitmaps/rot13.xbm"
+#include       "bitmaps/rot14.xbm"
+#include       "bitmaps/rot15.xbm"
+
+#define MINGRIDSIZE 8
+#define MINSIZE 2
+#define NONE 0
+#define MAX_SIDES 4
+#define MAX_KINDS 3
+#define MAX_SQUARES 4
+#define MAX_START_POLYOMINOES 7
+#define MAX_POLYOMINOES 19
+#define NUM_FLASHES     16
+#define BITMAPS     16
+
+#define THRESHOLD(x)    ((x+1)*10)
+#define CHECKUP(x)      ((x)%8)
+#define CHECKDOWN(x)    (((x)/4)*4+(x)%2)
+
+static XImage logo[BITMAPS] =
+{
+       {0, 0, 0, XYBitmap, (char *) rot00_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot01_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot02_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot03_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot04_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot05_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot06_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot07_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot08_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot09_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot10_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot11_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot12_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot13_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot14_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) rot15_bits, LSBFirst, 8, LSBFirst, 8, 1}
+};
+
+typedef enum {FALL, DROP, LEFT, RIGHT, ROTATE, REFLECT} move_t;
+
+typedef struct {
+       int      squares, polyomino_number;
+       int      xpos, ypos;
+       int      size, color_number;
+       int      random_rotation;
+       int      bonus, random_reflection;      /* not really used yet */
+       long    random_number;
+} thing_t;
+typedef struct {
+       int      rotation;
+       int      reflection;    /* not really used yet */
+       int      start_height;
+       int      shape[MAX_SQUARES][MAX_SQUARES];
+       int      size;
+} Polyominoes;
+typedef struct {
+       int      number;
+       int      start[MAX_START_POLYOMINOES];
+} Mode;
+typedef struct {
+       Polyominoes polyomino[MAX_POLYOMINOES];
+       Mode    mode;
+} Polytris;
+typedef struct {
+  int pmid, cid;
+} fieldstruct;
+
+typedef struct {
+       Bool     painted;
+       int      object, orient;
+       GC       gc;
+       Colormap cmap;
+       Bool     cycle_p, mono_p, no_colors;
+       unsigned long blackpixel, whitepixel, fg, bg;
+       int      direction;
+       unsigned long colour;
+       int      p_type;
+
+       fieldstruct *field;
+       int      xb, yb;
+       int      xs, ys;
+       int      width, height;
+       int      pixelmode;
+       XColor     *colors;
+       int      ncolors;
+       int      ncols, nrows;
+       Polytris    tris;
+       thing_t     curPolyomino;
+} trisstruct;
+
+static trisstruct *triss = NULL;
+static int icon_width, icon_height;
+
+
+static int
+ominos[] =
+{
+       /* Side of smallest square that contains shape */
+       /* Number of orientations */
+       /* Position, Next Postion, (not used yet),
+          number_down, used_for_start?
+          Polyomino (side^2 values) */
+       2,
+       1,
+       0, 0, 0,   0, 2,   6, 3,  12, 9,
+
+       3,
+       16,
+       0, 1, 4,     1, 2,   0, 0, 0,  6, 5, 1,   8, 0, 0,
+       1, 2, 7,     0, 0,   0, 2, 0,  0, 10, 0,  0, 12, 1,
+       2, 3, 6,     1, 0,   0, 0, 0,  0, 0, 2,   4, 5, 9,
+       3, 0, 5,     0, 0,   0, 4, 3,  0, 0, 10,  0, 0, 8,
+       4, 5, 0,     1, 1,   0, 0, 0,  4, 5, 3,   0, 0, 8,
+       5, 6, 3,     0, 0,   0, 6, 1,  0, 10, 0,  0, 8, 0,
+       6, 7, 2,     1, 0,   0, 0, 0,  2, 0, 0,   12, 5, 1,
+       7, 4, 1,     0, 0,   0, 0, 2,  0, 0, 10,  0, 4, 9,
+       8, 9, 8,     1, 2,   0, 0, 0,  4, 7, 1,   0, 8, 0,
+       9, 10, 11,   0, 0,   0, 2, 0,  0, 14, 1,  0, 8, 0,
+       10, 11, 10,  1, 0,   0, 0, 0,  0, 2, 0,   4, 13, 1,
+       11, 8, 9,    0, 0,   0, 0, 2,  0, 4, 11,  0, 0, 8,
+       12, 13, 14,  1, 2,   0, 0, 0,  4, 3, 0,   0, 12, 1,
+       13, 12, 15,  0, 0,   0, 0, 2,  0, 6, 9,   0, 8, 0,
+       14, 15, 12,  1, 1,   0, 0, 0,  0, 6, 1,   4, 9, 0,
+       15, 14, 13,  0, 0,   0, 2, 0,  0, 12, 3,  0, 0, 8,
+
+       4,
+       2,
+       0, 1, 0,  2, 2,   0, 0, 0, 0,  0, 0, 0, 0,   4, 5, 5, 1,   0, 0, 0, 0,
+       1, 0, 1,  0, 0,   0, 0, 2, 0,  0, 0, 10, 0,  0, 0, 10, 0,  0, 0, 8, 0
+};
+
+static void
+readPolyominoes(trisstruct * tp)
+{
+       int      size = 0, n = 0, index = 0, sum = 0;
+       int      counter = 0, start_counter = 0;
+       int      polyomino, kinds, i, j;
+
+       tp->tris.mode.number = MAX_START_POLYOMINOES;
+       for (kinds = 0; kinds < MAX_KINDS; kinds++) {
+               size = ominos[index++];
+               n = ominos[index++];
+               for (polyomino = 0; polyomino < n; polyomino++) {
+                       sum = polyomino + counter;
+                       if (polyomino != ominos[index])
+                               (void) printf("polyomino %d, ominos[index] %d\n", polyomino, ominos[index]);
+                       index++;        /* This is only there to "read" input file  */
+                       tp->tris.polyomino[sum].rotation = ominos[index++] + counter;
+                       tp->tris.polyomino[sum].reflection = ominos[index++] + counter; /* not used */
+
+                       tp->tris.polyomino[sum].start_height = ominos[index++];
+                       if (ominos[index++] != NONE) {
+                               i = start_counter;
+                               tp->tris.mode.start[i] = sum;
+                               start_counter++;
+                       }
+                       tp->tris.polyomino[sum].size = size;
+                       for (j = 0; j < size; j++)
+                               for (i = 0; i < size; i++) {
+                                       tp->tris.polyomino[sum].shape[j][i] = ominos[index++];
+                               }
+               }
+               counter += n;
+       }
+}
+
+static void
+drawSquare(ModeInfo * mi, int pmid, int cid, int col, int row)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       long colour;
+
+       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+               if (tp->ncolors >= MAX_START_POLYOMINOES + 2)
+                       colour = cid + 2;
+               else
+                       colour = 1;     /* Just in case */
+               XSetBackground(display, tp->gc, tp->blackpixel);
+               XSetForeground(display, tp->gc, tp->colors[colour].pixel);
+       } else {
+               if (MI_NPIXELS(mi) >  MAX_START_POLYOMINOES)
+                       colour = MI_PIXEL(mi, cid * MI_NPIXELS(mi) / MAX_START_POLYOMINOES);
+               else
+                       colour = MI_WHITE_PIXEL(mi);
+               XSetForeground(display, tp->gc, colour);
+               XSetBackground(display, tp->gc, MI_BLACK_PIXEL(mi));
+       }
+  if (tp->pixelmode)
+               XFillRectangle(display, window, tp->gc,
+                       tp->xb + col * tp->xs, tp->yb + row * tp->ys, tp->xs, tp->ys);
+       else
+/*-
+ * PURIFY on SunOS4 and on Solaris 2 reports a 120 byte memory leak on
+ * the next line */
+    (void) XPutImage(display, window, tp->gc, &logo[pmid], 0, 0,
+                       tp->xb + icon_width * col, tp->yb + icon_height * row,
+                       icon_width, icon_height);
+}
+
+static void
+clearSquare(ModeInfo * mi, int col, int row)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+
+       XSetForeground(display, tp->gc, tp->blackpixel);
+       XFillRectangle(display, window, tp->gc,
+               tp->xb + col * tp->xs, tp->yb + row * tp->ys, tp->xs, tp->ys);
+}
+
+static void
+drawPolyomino(ModeInfo * mi)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       int      i, j;
+
+       for (i = 0; i < tp->curPolyomino.size; i++) {
+               for (j = 0; j < tp->curPolyomino.size; j++) {
+                       if (tp->tris.polyomino[tp->curPolyomino.polyomino_number].shape[j][i]) {
+                               drawSquare(mi, tp->tris.polyomino
+                                               [tp->curPolyomino.polyomino_number].shape[j][i],
+                                       tp->curPolyomino.color_number,
+                                       tp->curPolyomino.xpos + i, tp->curPolyomino.ypos + j);
+                       }
+               }
+       }
+}
+
+static void
+drawPolyominoDiff(ModeInfo *mi, thing_t * old)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       int      i, j, ox, oy;
+
+       for (i = 0; i < tp->curPolyomino.size; i++)
+               for (j = 0; j < tp->curPolyomino.size; j++)
+       if ((tp->curPolyomino.ypos + j >= 0) && tp->tris.polyomino
+             [tp->curPolyomino.polyomino_number].shape[j][i])
+         drawSquare(mi, tp->tris.polyomino
+                        [tp->curPolyomino.polyomino_number].shape[j][i],
+           tp->curPolyomino.color_number, tp->curPolyomino.xpos + i, tp->curPolyomino.ypos + j);
+
+       for (i = 0; i < tp->curPolyomino.size; i++)
+               for (j = 0; j < tp->curPolyomino.size; j++) {
+                       ox = old->xpos + i - tp->curPolyomino.xpos;
+                       oy = old->ypos + j - tp->curPolyomino.ypos;
+                       if (tp->tris.polyomino[old->polyomino_number].shape[j][i] &&
+                               ((ox < 0) || (ox >= tp->curPolyomino.size) ||
+                               (oy < 0) || (oy >= tp->curPolyomino.size) ||
+                               !tp->tris.polyomino
+                                       [tp->curPolyomino.polyomino_number].shape[oy][ox]))
+                               clearSquare(mi, (old->xpos + i), (old->ypos + j));
+               }
+}
+
+static void
+redoNext(ModeInfo * mi)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       int next_start, i;
+
+       next_start = tp->curPolyomino.random_number % tp->tris.mode.number;
+       tp->curPolyomino.color_number = next_start;
+
+       tp->curPolyomino.polyomino_number = tp->tris.mode.start[next_start];
+       for (i = 0; i < tp->curPolyomino.random_rotation; i++)
+               tp->curPolyomino.polyomino_number = tp->tris.polyomino
+                       [tp->curPolyomino.polyomino_number].rotation;
+       tp->curPolyomino.size = tp->tris.polyomino[tp->curPolyomino.polyomino_number].size;
+       tp->curPolyomino.xpos = NRAND(tp->ncols - tp->curPolyomino.size + 1);
+       /* tp->curPolyomino.xpos = (tp->ncols - tp->curPolyomino.size) / 2; */
+       tp->curPolyomino.ypos = -tp->tris.polyomino
+               [tp->curPolyomino.polyomino_number].start_height;
+}
+
+static void
+newPolyomino(ModeInfo * mi) {
+       Display *   display = MI_DISPLAY(mi);
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+
+       tp->curPolyomino.random_number = LRAND();
+       tp->curPolyomino.random_rotation = NRAND(MAX_SIDES);
+       /* tp->curPolyomino.random_reflection = NRAND(2); */  /* Future? */
+       /* tp->curPolyomino.bonus = bonusNow; */ /* Future? */
+
+       redoNext(mi);
+}
+
+static void
+putBox(ModeInfo * mi)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       int      i, j;
+       int      x = tp->curPolyomino.xpos, y = tp->curPolyomino.ypos, pos;
+
+       for (i = 0; i < tp->curPolyomino.size; i++)
+               for (j = 0; j < tp->curPolyomino.size; j++)
+                       if ((y + j >= 0) && tp->tris.polyomino
+                               [tp->curPolyomino.polyomino_number].shape[j][i]) {
+                               pos = (y + j) * tp->ncols + x + i;
+                               tp->field[pos].pmid = tp->tris.polyomino
+                                       [tp->curPolyomino.polyomino_number].shape[j][i] % BITMAPS;
+                               tp->field[pos].cid = tp->curPolyomino.color_number;
+                       }
+}
+
+static Bool
+overlapping(ModeInfo * mi)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       int          i, j;
+       int          x = tp->curPolyomino.xpos, y = tp->curPolyomino.ypos;
+        int gradualAppear = False;
+
+       for (i = 0; i < tp->curPolyomino.size; i++)
+               for (j = 0; j < tp->curPolyomino.size; j++)
+                       if (tp->tris.polyomino[tp->curPolyomino.polyomino_number].shape[j][i]) {
+                               if ((y + j >= tp->nrows) || (x + i < 0) || (x + i >= tp->ncols))
+                                       return True;
+if (gradualAppear) {
+/* This method one can turn polyomino to an area above of screen, also
+   part of the polyomino may not be visible initially */
+            if ((y + j >= 0) && (tp->field[(y + j) * tp->ncols + x + i].pmid >= 0))
+              return True;
+          } else {
+/* This method does not allow turning polyomino to an area above screen */
+            if ((y + j < 0) || (tp->field[(y + j) * tp->ncols + x + i].pmid >= 0))
+              return True;
+          }
+
+                       }
+       return False;
+}
+
+static Bool
+atBottom(ModeInfo * mi)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       int          i, j;
+       int          x = tp->curPolyomino.xpos, y = tp->curPolyomino.ypos;
+
+       for (i = 0; i < tp->curPolyomino.size; i++)
+               for (j = 0; j < tp->curPolyomino.size; j++)
+                       if ((y + j >= -1) && tp->tris.polyomino
+                               [tp->curPolyomino.polyomino_number].shape[j][i])
+                               if ((y + j >= tp->nrows - 1) || (x + i < 0) || (x + i >= tp->ncols) ||
+                                        (tp->field[(y + j + 1) * tp->ncols + x + i].pmid >= 0))
+                                       return True;
+       return False;
+}
+
+static void
+tryMove(ModeInfo * mi, move_t move)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       thing_t  old;
+       int          i;
+       int          cw = False; /* I am not sure if this is the original */
+
+       old = tp->curPolyomino;
+
+       switch (move) {
+               case FALL:
+                       tp->curPolyomino.ypos++;
+                       break;
+
+               case DROP:
+                       do { /* so fast you can not see it ;) */
+                               tp->curPolyomino.ypos ++;
+                       } while (!overlapping(mi));
+                       tp->curPolyomino.ypos--;
+                       break;
+
+               case LEFT:
+                       tp->curPolyomino.xpos--;
+                       break;
+
+               case RIGHT:
+                       tp->curPolyomino.xpos++;
+                       break;
+
+               case ROTATE:
+                       if (cw)
+                               for (i = 0; i < MAX_SIDES - 1; i++)
+                                       tp->curPolyomino.polyomino_number = tp->tris.polyomino
+                                               [tp->curPolyomino.polyomino_number].rotation;
+                       else /* ccw */
+                               tp->curPolyomino.polyomino_number = tp->tris.polyomino
+                                       [tp->curPolyomino.polyomino_number].rotation;
+                       tp->curPolyomino.xpos = old.xpos;
+                       tp->curPolyomino.ypos = old.ypos;
+                       break;
+
+               case REFLECT: /* reflect on y axis */
+                       tp->curPolyomino.polyomino_number = tp->tris.polyomino
+                               [tp->curPolyomino.polyomino_number].reflection;
+                       tp->curPolyomino.xpos = old.xpos;
+                       tp->curPolyomino.ypos = old.ypos;
+                       break;
+       }
+
+       if (!overlapping(mi))
+               drawPolyominoDiff(mi, &old);
+       else
+               tp->curPolyomino = old;
+}
+
+static int
+checkLines(ModeInfo *mi)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       int         *lSet, nset = 0;
+       int          i, j, y;
+
+
+       lSet = calloc(tp->nrows, sizeof (int));
+       for (j = 0; j < tp->nrows; j++) {
+               for (i = 0; i < tp->ncols; i++)
+                       if (tp->field[j * tp-> ncols + i].pmid >= 0)
+                               lSet[j]++;
+               if (lSet[j] == tp->ncols)
+                       nset++;
+       }
+
+       if (nset) {
+       for (i = 0; i < ((NUM_FLASHES / nset) % 2) * 2; i++) {
+               for (j = 0; j < tp->nrows; j++) {
+                       if (lSet[j] == tp->ncols)
+#if 0 /* Future */
+                               XFillRectangle(display, blockWin, xorGC,
+                               0, j * BOXSIZE, frameW, BOXSIZE)
+#endif
+                               ;
+               }
+               XFlush(display);
+       }
+
+       for (j = tp->nrows - 1; j >= 0; j--) {
+           if (lSet[j] == tp->ncols) {
+               for (y = j; y > 0; y--)
+                   for (i = 0; i < tp->ncols; i++)
+                       tp->field[y * tp->ncols + i] = tp->field[(y - 1) * tp->ncols + i];
+               for (i = 0; i < tp->ncols; i++)
+                   tp->field[i].pmid = -1;
+
+#if 0 /* Future */
+               XCopyArea(display, blockWin, blockWin, tinyGC,
+                       0, 0, frameW, j * BOXSIZE, 0, BOXSIZE);
+               
+               XFillRectangle(display, blockWin, revGC,
+                       0, 0, frameW, BOXSIZE);
+#endif
+
+               for (i = j; i > 0; i--)
+                   lSet[i] = lSet[i-1];
+               lSet[0] = 0;
+
+               if (j > 0)
+                   for (i = 0; i < tp->ncols; i++) {
+                       int          tmp = tp->field[j * tp->ncols + i].pmid;
+                       if ((tmp >= 0) && (tmp != CHECKDOWN(tmp))) {
+                           tp->field[j * tp->ncols + i].pmid = CHECKDOWN(tmp);
+                           drawSquare(mi, tp->field[j * tp->ncols + i].pmid, tp->field[j * tp->ncols + i].cid,
+                                      i, j);
+                       }
+                   }
+
+               j++;
+
+               if (j < tp->nrows)
+                   for (i = 0; i < tp->ncols; i++) {
+                       int          tmp = tp->field[j * tp->ncols + i].pmid;
+                       if ((tmp >= 0) && (tmp != CHECKUP(tmp))) {
+                           tp->field[j * tp->ncols + i].pmid = CHECKUP(tmp);
+                           drawSquare(mi, tp->field[j * tp->ncols + i].pmid, tp->field[j * tp->ncols + i].cid,
+                                      i, j);
+                       }
+                   }
+
+               XFlush(display);
+           }
+       }
+
+       XSync(display, False);
+    }
+
+    if (lSet)
+       (void) free((void *) lSet);
+
+
+    return nset;
+}
+
+
+static Bool
+moveOne(ModeInfo *mi, move_t move)
+{
+       Display    *display = MI_DISPLAY(mi);
+       int          lines;
+
+    if ((move == DROP) || ((move == FALL) && atBottom(mi))) {
+       putBox(mi);
+       lines = checkLines(mi);
+#if 0
+       rows += lines;
+       if (rows > THRESHOLD(level)) {
+           level++;
+           if (bonus) /* No good deed goes unpunished */
+             bonusNow = True;
+       }
+#endif
+       newPolyomino(mi);
+       XSync(display, True);   /* discard all events */
+       if (overlapping(mi)) {
+#if 0
+               gameOver();
+#endif
+               init_tetris(mi);
+               return False;
+       }
+
+       drawPolyomino(mi);
+       return True;
+    } else {
+       tryMove(mi, move);
+#if 0
+       if (rows > THRESHOLD(level)) {
+           level++;
+           if (bonus)
+             bonusNow = True;
+       }
+#endif
+       return False;
+    }
+}
+
+void
+refresh_tetris(ModeInfo * mi)
+{
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+       int col, row, pos;
+
+       if (!tp->painted)
+               return;
+       MI_CLEARWINDOW(mi);
+       for (col = 0; col < tp->ncols; col++)
+               for (row = 0; row < tp->nrows; row++) {
+                       pos = row * tp->ncols + col;
+#if 0
+                       (void) printf("pmid %d, cid %d, %d %d\n",
+                               tp->field[pos].pmid, tp->field[pos].cid, col, row);
+#endif
+                       if (tp->field[pos].pmid != -1)
+                               drawSquare(mi, tp->field[pos].pmid, tp->field[pos].cid, col, row);
+               }
+       drawPolyomino(mi);
+}
+
+void
+draw_tetris(ModeInfo * mi) {
+       Display *   display = MI_DISPLAY(mi);
+       trisstruct *tp = &triss[MI_SCREEN(mi)];
+
+       if (tp->no_colors) {
+               init_tetris(mi);
+               return;
+       }
+       tp->painted = True;
+       MI_IS_DRAWN(mi) = True;
+
+       /* Rotate colours */
+       if (tp->cycle_p) {
+               rotate_colors(display, tp->cmap, tp->colors, tp->ncolors,
+                             tp->direction);
+               if (!(LRAND() % 1000))
+                       tp->direction = -tp->direction;
+       }
+
+       moveOne(mi, FALL);
+}
+
+void
+release_tetris(ModeInfo * mi) {
+       Display *   display = MI_DISPLAY(mi);
+
+       if (triss != NULL) {
+               int      screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       trisstruct *tp = &triss[screen];
+
+                       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                               MI_WHITE_PIXEL(mi) = tp->whitepixel;
+                               MI_BLACK_PIXEL(mi) = tp->blackpixel;
+#ifndef STANDALONE
+                               MI_FG_PIXEL(mi) = tp->fg;
+                               MI_BG_PIXEL(mi) = tp->bg;
+#endif
+                               if (tp->colors && tp->ncolors && !tp->no_colors)
+                                       free_colors(display, tp->cmap, tp->colors, tp->ncolors);
+                               if (tp->colors)
+                                       (void) free((void *) tp->colors);
+                               XFreeColormap(display, tp->cmap);
+                       }
+                       if (tp->gc != NULL)
+                               XFreeGC(display, tp->gc);
+                       if (tp->field)
+                               (void) free((void *) tp->field);
+
+               }
+               (void) free((void *) triss);
+               triss = NULL;
+       }
+}
+
+void
+init_tetris(ModeInfo * mi) {
+       Display *   display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       trisstruct *tp;
+       int size = MI_SIZE(mi);
+       int      i;
+
+       if (triss == NULL) {
+               if ((triss = (trisstruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (trisstruct))) == NULL)
+                       return;
+       }
+       tp = &triss[MI_SCREEN(mi)];
+
+       if (!tp->gc) {
+               icon_width = rot00_width;
+               icon_height = rot00_height;
+               for (i = 0; i < BITMAPS; i++) {
+                       logo[i].width = icon_width;
+                       logo[i].height = icon_height;
+                       logo[i].bytes_per_line = (icon_width + 7) / 8;
+               }
+
+               readPolyominoes(tp);
+               if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+                       XColor      color;
+
+#ifndef STANDALONE
+                       extern char *background;
+                       extern char *foreground;
+
+                       tp->fg = MI_FG_PIXEL(mi);
+                       tp->bg = MI_BG_PIXEL(mi);
+#endif
+                       tp->blackpixel = MI_BLACK_PIXEL(mi);
+                       tp->whitepixel = MI_WHITE_PIXEL(mi);
+                       tp->cmap = XCreateColormap(display, window,
+                                                   MI_VISUAL(mi), AllocNone);
+                       XSetWindowColormap(display, window, tp->cmap);
+                       (void) XParseColor(display, tp->cmap, "black", &color);
+                       (void) XAllocColor(display, tp->cmap, &color);
+                       MI_BLACK_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, tp->cmap, "white", &color);
+                       (void) XAllocColor(display, tp->cmap, &color);
+                       MI_WHITE_PIXEL(mi) = color.pixel;
+#ifndef STANDALONE
+                       (void) XParseColor(display, tp->cmap, background, &color);
+                       (void) XAllocColor(display, tp->cmap, &color);
+                       MI_BG_PIXEL(mi) = color.pixel;
+                       (void) XParseColor(display, tp->cmap, foreground, &color);
+                       (void) XAllocColor(display, tp->cmap, &color);
+                       MI_FG_PIXEL(mi) = color.pixel;
+#endif
+                       tp->colors = 0;
+                       tp->ncolors = 0;
+               }
+               if ((tp->gc = XCreateGC(display, MI_WINDOW(mi),
+                            (unsigned long) 0, (XGCValues *) NULL)) == None)
+                       return;
+       }
+       MI_CLEARWINDOW(mi);
+       tp->painted = False;
+
+       tp->width = MI_WIDTH(mi);
+       tp->height = MI_HEIGHT(mi);
+
+       if (tp->width < 2)
+               tp->width = 2;
+       if (tp->height < 2)
+               tp->height = 2;
+       if (size == 0 ||
+               MINGRIDSIZE * size > tp->width || MINGRIDSIZE * size > tp->height) {
+                       if (tp->width > MINGRIDSIZE * icon_width &&
+                               tp->height > MINGRIDSIZE * icon_height) {
+                               tp->pixelmode = False;
+                               tp->xs = icon_width;
+                               tp->ys = icon_height;
+      } else {
+                               tp->pixelmode = True;
+                               tp->xs = tp->ys = MAX(MINSIZE, MIN(tp->width, tp->height) /
+                                       MINGRIDSIZE);
+                       }
+       } else {
+               tp->pixelmode = True;
+               if (size < -MINSIZE)
+                       tp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(tp->width, tp->height) /
+                               MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE)
+                       tp->ys = MINSIZE;
+               else
+                       tp->ys = MIN(size, MAX(MINSIZE, MIN(tp->width, tp->height) /
+                               MINGRIDSIZE));
+               tp->xs = tp->ys;
+       }
+       tp->ncols = MAX(tp->width / tp->xs, 2);
+       tp->nrows = MAX(tp->height / tp->ys, 2);
+       tp->xb = (tp->width - tp->xs * tp->ncols) / 2;
+       tp->yb = (tp->height - tp->ys * tp->nrows) / 2;
+
+       /* Set up tetris data */
+
+       if (tp->field)
+               (void) free((void *) tp->field);
+       tp->field = malloc(tp->ncols * tp->nrows * sizeof (fieldstruct));
+       for (i = 0; i < tp->ncols * tp->nrows; i++) {
+               tp->field[i].pmid = -1;
+               tp->field[i].cid = 0;
+       }
+
+       /* Set up colour map */
+       tp->direction = (LRAND() & 1) ? 1 : -1;
+       if (MI_IS_INSTALL(mi) && MI_NPIXELS(mi) > 2) {
+               if (tp->colors && tp->ncolors && !tp->no_colors)
+                       free_colors(display, tp->cmap, tp->colors, tp->ncolors);
+               if (tp->colors)
+                       (void) free((void *) tp->colors);
+               tp->colors = 0;
+               tp->ncolors = MI_NCOLORS(mi);
+               if (tp->ncolors < 2)
+                       tp->ncolors = 2;
+               if (tp->ncolors <= 2)
+                       tp->mono_p = True;
+               else
+                       tp->mono_p = False;
+
+               if (tp->mono_p)
+                       tp->colors = 0;
+               else
+                       tp->colors = (XColor *) malloc(sizeof (*tp->colors) * (tp->ncolors + 1));
+               tp->cycle_p = has_writable_cells(mi);
+               if (tp->cycle_p) {
+                       if (MI_IS_FULLRANDOM(mi)) {
+                               if (!NRAND(8))
+                                       tp->cycle_p = False;
+                               else
+                                       tp->cycle_p = True;
+                       } else {
+                               tp->cycle_p = cycle_p;
+                       }
+               }
+               if (!tp->mono_p) {
+                       if (!(LRAND() % 10))
+                               make_random_colormap(
+#if STANDALONE
+            MI_DISPLAY(mi), MI_WINDOW(mi),
+#else
+            mi,
+#endif
+              tp->cmap, tp->colors, &tp->ncolors,
+                                                 True, True, &tp->cycle_p);
+                       else if (!(LRAND() % 2))
+                               make_uniform_colormap(
+#if STANDALONE
+            MI_DISPLAY(mi), MI_WINDOW(mi),
+#else
+            mi,
+#endif
+                  tp->cmap, tp->colors, &tp->ncolors,
+                                                     True, &tp->cycle_p);
+                       else
+                               make_smooth_colormap(
+#if STANDALONE
+            MI_DISPLAY(mi), MI_WINDOW(mi),
+#else
+            mi,
+#endif
+                 tp->cmap, tp->colors, &tp->ncolors,
+                                                    True, &tp->cycle_p);
+               }
+               XInstallColormap(display, tp->cmap);
+               if (tp->ncolors < 2) {
+                       tp->ncolors = 2;
+                       tp->no_colors = True;
+               } else
+                       tp->no_colors = False;
+               if (tp->ncolors <= 2)
+                       tp->mono_p = True;
+
+               if (tp->mono_p)
+                       tp->cycle_p = False;
+
+       }
+       /* initialize object */
+       newPolyomino(mi);
+}
+
+#endif /* MODE_tetris */
diff --git a/xlockmore-4.14/modes/thornbird.c b/xlockmore-4.14/modes/thornbird.c
new file mode 100644 (file)
index 0000000..f36d245
--- /dev/null
@@ -0,0 +1,247 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* thornbird --- continuously varying Thornbird set */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)discrete.c 4.10 98/04/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by Tim Auckland <Tim.Auckland@Sun.COM>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * "thornbird" shows a view of the "Bird in a Thornbush" fractal,
+ * continuously varying the three free parameters.
+ *
+ * Revision History:
+ * 04-Jun-99: 3D tumble added by Tim Auckland
+ * 31-Jul-97: Adapted from discrete.c Copyright (c) 1996 by Tim Auckland
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Thornbird"
+#define HACK_INIT init_thornbird
+#define HACK_DRAW draw_thornbird
+#define thornbird_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*count: 800 \n" \
+ "*cycles: 16 \n" \
+ "*ncolors: 100 \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_thornbird
+
+ModeSpecOpt thornbird_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   thornbird_description =
+{"thornbird", "init_thornbird", "draw_thornbird", "release_thornbird",
+ "refresh_thornbird", "init_thornbird", NULL, &thornbird_opts,
+ 1000, 800, 16, 1, 64, 1.0, "",
+ "Shows an animated Bird in a Thorn Bush fractal map", 0, NULL};
+
+#endif
+
+#define balance_rand(v)        ((LRAND()/MAXRAND*(v))-((v)/2)) /* random around 0 */
+
+typedef struct {
+       int         maxx;
+       int         maxy;       /* max of the screen */
+       double      a;
+       double      b;
+       double      c;
+       double      d;
+       double      e;
+       double      i;
+       double      j;          /* thornbird parameters */
+    struct {
+         double  f1;
+         double  f2;
+       }           liss;  
+    struct {
+         double  theta;
+         double  dtheta;
+         double  phi;
+         double  dphi;
+       }           tumble;
+    int         inc;
+       int         pix;
+       int         count;
+       int         nbuffers;
+       XPoint    **pointBuffer;        /* pointer for XDrawPoints */
+} thornbirdstruct;
+
+static thornbirdstruct *thornbirds = NULL;
+
+void
+init_thornbird(ModeInfo * mi)
+{
+       thornbirdstruct *hp;
+
+       if (thornbirds == NULL) {
+               if ((thornbirds =
+                    (thornbirdstruct *) calloc(MI_NUM_SCREENS(mi),
+                                         sizeof (thornbirdstruct))) == NULL)
+                       return;
+       }
+       hp = &thornbirds[MI_SCREEN(mi)];
+
+
+       hp->maxx = MI_WIDTH(mi);
+       hp->maxy = MI_HEIGHT(mi);
+
+       hp->b = 0.1;
+       hp->i = hp->j = 0.1;
+
+       hp->pix = 0;
+       hp->inc = 0;
+
+       hp->nbuffers = MI_CYCLES(mi);
+
+       if (hp->pointBuffer == NULL)
+               hp->pointBuffer = (XPoint **) calloc(MI_CYCLES(mi), sizeof (XPoint *));
+
+       if (hp->pointBuffer[0] == NULL)
+               hp->pointBuffer[0] = (XPoint *) malloc(MI_COUNT(mi) * sizeof (XPoint));
+
+       /* select frequencies for parameter variation */
+       hp->liss.f1 = LRAND() % 5000;
+       hp->liss.f2 = LRAND() % 2000;
+
+       /* choose random 3D tumbling */
+       hp->tumble.theta = 0;
+       hp->tumble.phi = 0;
+       hp->tumble.dtheta = balance_rand(0.001);
+       hp->tumble.dphi = balance_rand(0.005);
+
+       /* Clear the background. */
+       MI_CLEARWINDOW(mi);
+
+       hp->count = 0;
+}
+
+
+void
+draw_thornbird(ModeInfo * mi)
+{
+       Display    *dsp = MI_DISPLAY(mi);
+       Window      win = MI_WINDOW(mi);
+       double      oldj, oldi;
+       int         batchcount = MI_COUNT(mi);
+
+       int         k;
+       XPoint     *xp;
+       GC          gc = MI_GC(mi);
+       thornbirdstruct *hp = &thornbirds[MI_SCREEN(mi)];
+
+       int         erase = (hp->inc + 1) % MI_CYCLES(mi);
+       int         current = hp->inc % MI_CYCLES(mi);
+
+       double      sint, cost, sinp, cosp;
+
+       k = batchcount;
+
+
+       xp = hp->pointBuffer[current];
+
+       /* vary papameters */
+       hp->a = 1.99 + (0.4 * sin(hp->inc / hp->liss.f1) + 
+                                       0.05 * cos(hp->inc / hp->liss.f2));
+       hp->c = 0.80 + (0.15 * cos(hp->inc / hp->liss.f1) +
+                                       0.05 * sin(hp->inc / hp->liss.f2));
+
+       /* vary view */
+       hp->tumble.theta += hp->tumble.dtheta;
+       hp->tumble.phi += hp->tumble.dphi;
+       sint = sin(hp->tumble.theta);
+       cost = cos(hp->tumble.theta);
+       sinp = sin(hp->tumble.phi);
+       cosp = cos(hp->tumble.phi);
+
+       while (k--) {
+               oldj = hp->j;
+               oldi = hp->i;
+
+               hp->j = oldi;
+               hp->i = (1 - hp->c) * cos(M_PI * hp->a * oldj) + hp->c * hp->b;
+               hp->b = oldj;
+
+               xp->x = (short)
+                 (hp->maxx / 2 * (1
+                                                  + sint*hp->j + cost*cosp*hp->i - cost*sinp*hp->b));
+               xp->y = (short)
+                 (hp->maxy / 2 * (1
+                                                  - cost*hp->j + sint*cosp*hp->i - sint*sinp*hp->b));
+               xp++;
+       }
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (hp->pointBuffer[erase] == NULL) {
+               hp->pointBuffer[erase] =
+                       (XPoint *) malloc(MI_COUNT(mi) * sizeof (XPoint));
+       } else {
+               XSetForeground(dsp, gc, MI_BLACK_PIXEL(mi));
+               XDrawPoints(dsp, win, gc, hp->pointBuffer[erase],
+                           batchcount, CoordModeOrigin);
+       }
+       if (MI_NPIXELS(mi) > 2) {
+               XSetForeground(dsp, gc, MI_PIXEL(mi, hp->pix));
+               if (erase == 0) /* change colours after "cycles" cycles */
+                       if (++hp->pix >= MI_NPIXELS(mi))
+                               hp->pix = 0;
+       } else
+               XSetForeground(dsp, gc, MI_WHITE_PIXEL(mi));
+
+       XDrawPoints(dsp, win, gc, hp->pointBuffer[current],
+                   batchcount, CoordModeOrigin);
+       hp->inc++;
+
+}
+
+void
+release_thornbird(ModeInfo * mi)
+{
+       if (thornbirds != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       thornbirdstruct *hp = &thornbirds[screen];
+
+                       if (hp->pointBuffer != NULL) {
+                               int         i;
+
+                               for (i = 0; i < hp->nbuffers; i++)
+                                       if (hp->pointBuffer[i] != NULL)
+                                               (void) free((void *) hp->pointBuffer[i]);
+                               (void) free((void *) hp->pointBuffer);
+                       }
+               }
+               (void) free((void *) thornbirds);
+               thornbirds = NULL;
+       }
+}
+
+void
+refresh_thornbird(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_thornbird */
diff --git a/xlockmore-4.14/modes/triangle.c b/xlockmore-4.14/modes/triangle.c
new file mode 100644 (file)
index 0000000..6353a6e
--- /dev/null
@@ -0,0 +1,368 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* triangle --- create a triangle-mountain */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)triangle.c   4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1995 by Tobias Gloth
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 22-Dec-97: Removed MI_PAUSE since it does not work on multiscreens.
+ * 10-May-97: Compatible with xscreensaver
+ * 10-Mar-96: re-arranged and re-formatted the code for appearance and
+ *            to make common subroutines.  Simplified.
+ *               Ron Hitchens <ron@idiom.com>
+ * 07-Mar-96: Removed internal delay code, set MI_PAUSE(mi) for inter-scene
+ *            delays.  No other delays are needed here.
+ *            Made pause time sensitive to value of cycles (in 10ths of a
+ *            second).  Removed (hopefully) all references to globals.
+ *               Ron Hitchens <ron@idiom.com>
+ * 27-Feb-96: Undid the changes listed below.  Added ModeInfo argument.
+ *               Implemented delay between scenes using the MI_PAUSE(mi)
+ *            scheme.  Ron Hitchens <ron@idiom.com>
+ * 27-Dec-95: Ron Hitchens <ron@idiom.com>
+ *            Modified logic of draw_triangle() to provide a delay
+ *            (sensitive to the value of cycles) between each iteration.
+ *            Because this mode is so compute intensive, when the new
+ *            event loop adjusted the delay to compensate, this mode had
+ *            almost no delay time left.  This change pauses between each
+ *            new landscape, but could still be done better (it is not
+ *            sensitive to input events while drawing, for example).
+ * 03-Nov-95: Many changes (hopefully some good ones) by David Bagley
+ * 01-Oct-95: Written by Tobias Gloth
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Triangle"
+#define HACK_INIT init_triangle
+#define HACK_DRAW draw_triangle
+#define triangle_opts xlockmore_opts
+#define DEFAULTS "*delay: 10000 \n" \
+ "*ncolors: 128 \n " \
+ "*wireframe: False \n" \
+ "*fullrandom: False \n"
+#define SMOOTH_COLORS
+                                                         /* #define UNIFORM_COLORS *//* To get blue water uncomment, but ... */
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_triangle
+
+ModeSpecOpt triangle_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   triangle_description =
+{"triangle", "init_triangle", "draw_triangle", "release_triangle",
+ "refresh_triangle", "init_triangle", NULL, &triangle_opts,
+ 10000, 1, 1, 1, 64, 1.0, "",
+ "Shows a triangle mountain range", 0, NULL};
+
+#endif
+
+#define MAX_STEPS 8
+#define MAX_SIZE  (1<<MAX_STEPS)
+#define MAX_LEVELS 1000
+
+#define DELTA  0.4
+#define LEFT   (-0.25)
+#define RIGHT  1.25
+#define TOP    0.3
+#define BOTTOM 1.0
+#define BLUE   (45 * MI_NPIXELS(mi) / 64)      /* Just the right shade of blue */
+
+#define BACKFACE_REMOVAL
+
+#define DISPLACE(h,d) ((h)/2+LRAND()/(MAXRAND/(2*(d)+1))-d)
+
+typedef struct {
+       int         width;
+       int         height;
+       int         size;
+       int         steps;
+       int         stage;
+       int         busyLoop;
+       int         fast;
+       int         i;
+       int         j;
+       int         d;
+       short       level[MAX_LEVELS];
+       int         xpos[2 * MAX_SIZE + 1];
+       int         ypos[MAX_SIZE + 1];
+       short       H[(MAX_SIZE + 1) * (MAX_SIZE + 2) / 2];
+       short      *h[MAX_SIZE + 1];
+       short       delta[MAX_STEPS];
+       Bool        wireframe;
+       Bool        joke;
+} trianglestruct;
+
+static trianglestruct *triangles = NULL;
+
+static
+void
+draw_atriangle(ModeInfo * mi, XPoint * p, int y_0, int y_1, int y_2, double dinv)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       trianglestruct *tp = &triangles[MI_SCREEN(mi)];
+
+       if (MI_NPIXELS(mi) > 2) {       /* color */
+               int         dmax, dmin;
+               long        color;
+
+               dmin = MIN(y_0, y_1);
+               dmin = MIN(dmin, y_2);
+               dmax = MAX(y_0, y_1);
+               dmax = MAX(dmax, y_2);
+
+               if (dmax == 0) {
+                       color = BLUE;
+               } else {
+                       color = MI_NPIXELS(mi) -
+                               (int) ((double) MI_NPIXELS(mi) / M_PI_2 * atan(dinv * (dmax - dmin)));
+               }
+
+               XSetForeground(display, gc, MI_PIXEL(mi, color % MI_NPIXELS(mi)));
+               if (tp->joke) {
+                       if ((Bool) (LRAND() & 1))
+                               XDrawLines(display, window, gc, p, 4, CoordModeOrigin);
+                       else
+                               XFillPolygon(display, window, gc, p, 3, Convex, CoordModeOrigin);
+               } else if (tp->wireframe) {
+                       XDrawLines(display, window, gc, p, 4, CoordModeOrigin);
+               } else {
+                       XFillPolygon(display, window, gc, p, 3, Convex, CoordModeOrigin);
+               }
+       } else {
+               /* mono */
+#ifdef BACKFACE_REMOVAL
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillPolygon(display, window, gc, p, 3, Convex, CoordModeOrigin);
+#endif
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               XDrawLines(display, window, gc, p, 4, CoordModeOrigin);
+       }
+}
+
+static
+void
+calc_points1(trianglestruct * tp, int d, int *y0_p, int *y1_p, int *y2_p, XPoint * p)
+{
+       *y0_p = tp->level[MAX(tp->h[tp->i][tp->j], 0)];
+       *y1_p = tp->level[MAX(tp->h[tp->i + d][tp->j], 0)];
+       *y2_p = tp->level[MAX(tp->h[tp->i][tp->j + d], 0)];
+
+       p[0].x = tp->xpos[2 * tp->i + tp->j];
+       p[1].x = tp->xpos[2 * (tp->i + d) + tp->j];
+       p[2].x = tp->xpos[2 * tp->i + (tp->j + d)];
+
+       p[0].y = tp->ypos[tp->j] - *y0_p;
+       p[1].y = tp->ypos[tp->j] - *y1_p;
+       p[2].y = tp->ypos[tp->j + d] - *y2_p;
+
+       p[3] = p[0];
+}
+
+static
+void
+calc_points2(trianglestruct * tp, int d, int *y0_p, int *y1_p, int *y2_p, XPoint * p)
+{
+       *y0_p = tp->level[MAX(tp->h[tp->i + d][tp->j], 0)];
+       *y1_p = tp->level[MAX(tp->h[tp->i + d][tp->j + d], 0)];
+       *y2_p = tp->level[MAX(tp->h[tp->i][tp->j + d], 0)];
+
+       p[0].x = tp->xpos[2 * (tp->i + d) + tp->j];
+       p[1].x = tp->xpos[2 * (tp->i + d) + (tp->j + d)];
+       p[2].x = tp->xpos[2 * tp->i + (tp->j + d)];
+
+       p[0].y = tp->ypos[tp->j] - *y0_p;
+       p[1].y = tp->ypos[tp->j + d] - *y1_p;
+       p[2].y = tp->ypos[tp->j + d] - *y2_p;
+
+       p[3] = p[0];
+}
+
+
+static
+void
+draw_mesh(ModeInfo * mi, trianglestruct * tp, int d, int count)
+{
+       XPoint      p[4];
+       int         first = 1;
+       int         y_0, y_1, y_2;
+       double      dinv = 0.2 / d;
+
+       if ((tp->j == 0) && (tp->i == 0)) {
+               MI_CLEARWINDOW(mi);
+       }
+       for (; (tp->j < tp->size) && (count > 0); tp->j += ((count) ? d : 0)) {
+               for (tp->i = (first) ? tp->i : 0, first = 0;
+                    (tp->i < MAX_SIZE - tp->j) && (count > 0);
+                    tp->i += d, count--) {
+                       if (tp->i + tp->j < tp->size) {
+                               calc_points1(tp, d, &y_0, &y_1, &y_2, p);
+                               draw_atriangle(mi, p, y_0, y_1, y_2, dinv);
+                       }
+                       if (tp->i + tp->j + d < tp->size) {
+                               calc_points2(tp, d, &y_0, &y_1, &y_2, p);
+                               draw_atriangle(mi, p, y_0, y_1, y_2, dinv);
+                       }
+               }
+       }
+
+       if (tp->j == tp->size) {
+               tp->busyLoop = 1;
+       }
+}
+
+void
+init_triangle(ModeInfo * mi)
+{
+       trianglestruct *tp;
+       short      *tmp;
+       int         i, dim, one;
+
+       if (triangles == NULL) {
+               if ((triangles = (trianglestruct *) calloc(MI_NUM_SCREENS(mi),
+                                          sizeof (trianglestruct))) == NULL)
+                       return;
+       }
+       tp = &triangles[MI_SCREEN(mi)];
+
+       tp->width = MI_WIDTH(mi);
+       tp->height = MI_HEIGHT(mi);
+       tp->busyLoop = -1;
+       tp->fast = 2;
+       if (MI_IS_FULLRANDOM(mi)) {
+               tp->joke = (Bool) (NRAND(10) == 0);
+               tp->wireframe = (Bool) (LRAND() & 1);
+       } else
+               tp->wireframe = MI_IS_WIREFRAME(mi);
+
+       MI_CLEARWINDOW(mi);
+
+       tp->steps = MAX_STEPS;
+       do {
+               tp->size = 1 << --tp->steps;
+       } while (tp->size * 5 > tp->width);
+       tmp = tp->H;
+       for (i = 0; i < tp->size + 1; i++) {
+               tp->h[i] = tmp;
+               tmp += (tp->size) + 1 - i;
+       }
+
+       tp->stage = -1;
+       dim = MIN(tp->width, tp->height);
+
+       for (i = 0; i < 2 * tp->size + 1; i++) {
+               tp->xpos[i] = (short) ((((double) i)
+                        / ((double) (2 * tp->size)) * (RIGHT - LEFT) + LEFT)
+                                      * dim) + (tp->width - dim) / 2;
+       }
+
+       for (i = 0; i < (tp->size + 1); i++) {
+               tp->ypos[i] = (short) ((((double) i)
+                        / ((double) tp->size) * (BOTTOM - TOP) + TOP) * dim)
+                       + (tp->height - dim) / 2;
+       }
+
+       for (i = 0; i < tp->steps; i++) {
+               tp->delta[i] = ((short) (DELTA * dim)) >> i;
+       }
+
+       one = tp->delta[0];
+
+       if (one > 0)
+               for (i = 0; i < MAX_LEVELS; i++) {
+                       tp->level[i] = (i * i) / one;
+               }
+}
+
+void
+draw_triangle(ModeInfo * mi)
+{
+       trianglestruct *tp = &triangles[MI_SCREEN(mi)];
+       int         d, d2, i, j, delta;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (tp->busyLoop > 0) {
+               if (tp->busyLoop >= 100)
+                       tp->busyLoop = -1;
+               else
+                       tp->busyLoop++;
+               return;
+       }
+       if (!tp->busyLoop) {
+               draw_mesh(mi, tp, tp->d / 2, MAX_SIZE / tp->d);
+               return;
+       }
+       if (tp->delta[0] > 0) {
+               if (!(++tp->stage)) {
+                       tp->h[0][0] = (short int) MAX(0, DISPLACE(0, tp->delta[0]));
+                       tp->h[tp->size][0] = (short int) MAX(0, DISPLACE(0, tp->delta[0]));
+                       tp->h[0][tp->size] = (short int) MAX(0, DISPLACE(0, tp->delta[0]));
+               } else {
+                       d = 2 << (tp->steps - tp->stage);
+                       d2 = d / 2;
+                       delta = tp->delta[tp->stage - 1];
+
+                       for (i = 0; i < tp->size; i += d) {
+                               for (j = 0; j < (tp->size - i); j += d) {
+                                       tp->h[i + d2][j] = (short int) DISPLACE(tp->h[i][j] +
+                                                    tp->h[i + d][j], delta);
+                                       tp->h[i][j + d2] = (short int) DISPLACE(tp->h[i][j] +
+                                                    tp->h[i][j + d], delta);
+                                       tp->h[i + d2][j + d2] = (short int) DISPLACE(tp->h[i + d][j] +
+                                                    tp->h[i][j + d], delta);
+                               }
+
+                               tp->busyLoop = 0;
+                               tp->i = 0;
+                               tp->j = 0;
+                               tp->d = d;
+                       }
+               }
+       }
+       if (tp->stage == tp->steps) {
+#ifdef STANDALONE
+               erase_full_window(MI_DISPLAY(mi), MI_WINDOW(mi));
+#endif
+               init_triangle(mi);
+       }
+}
+
+void
+release_triangle(ModeInfo * mi)
+{
+       if (triangles != NULL) {
+               (void) free((void *) triangles);
+               triangles = NULL;
+       }
+}
+
+void
+refresh_triangle(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_triangle */
diff --git a/xlockmore-4.14/modes/tube.c b/xlockmore-4.14/modes/tube.c
new file mode 100644 (file)
index 0000000..724c898
--- /dev/null
@@ -0,0 +1,354 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* tube --- animated tube */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)tube.c 4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 Dan Stromberg <strombrg@nis.acs.uci.edu>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 4-Mar-97: Memory leak fix by Tom Schmidt <tschmidt@micron.com>
+ * 7-Feb-97: Written by Dan Stromberg <strombrg@nis.acs.uci.edu>
+ */
+
+
+#ifdef STANDALONE
+#define PROGCLASS "Tube"
+#define HACK_INIT init_tube
+#define HACK_DRAW draw_tube
+#define tube_opts xlockmore_opts
+#define DEFAULTS "*delay: 25000 \n" \
+ "*cycles: 20000 \n" \
+ "*size: -200 \n" \
+ "*ncolors: 200 \n"
+#define SMOOTH_COLORS
+#define WRITABLE_COLORS
+#include "xlockmore.h"         /* from the xscreensaver distribution */
+#include <X11/Xutil.h>
+#else /* !STANDALONE */
+#include "xlock.h"             /* from the xlockmore distribution */
+#include "vis.h"
+#include "color.h"
+#endif /* !STANDALONE */
+
+#ifdef MODE_tube
+
+ModeSpecOpt tube_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   tube_description =
+{"tube", "init_tube", "draw_tube", "release_tube",
+ NULL, "init_tube", NULL, &tube_opts,
+ 25000, -9, 20000, -200, 64, 1.0, "",
+ "Shows an animated tube", 0, NULL};
+
+#endif
+
+#define MINSIZE 3
+#define MINSHAPE 1
+
+typedef struct {
+       int         dx1, dy1;
+       int         x1, y1;
+       int         width, height, average, linewidth;
+       int         shape;
+       XPoint     *pts, *proto_pts;
+       unsigned int cur_color;
+       Colormap    cmap;
+       XColor     *colors;
+       XColor      top;
+       XColor      bottom;
+       XColor      bgcol, fgcol;       /* foreground and background colour specs */
+       int         counter;
+       int         ncolors;
+       int         usable_colors;
+       Bool        fixed_colormap;
+} tubestruct;
+
+static tubestruct *tubes = NULL;
+
+void
+init_tube(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       tubestruct *tp;
+       int         screen_width, screen_height, preserve;
+       int         size = MI_SIZE(mi);
+       Bool        truecolor;
+       int         star = 1, lw;
+       unsigned long redmask, greenmask, bluemask;
+
+       if (tubes == NULL) {
+               if ((tubes = (tubestruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (tubestruct))) == NULL)
+                       return;
+       }
+       tp = &tubes[MI_SCREEN(mi)];
+
+       screen_width = MI_WIDTH(mi);
+       screen_height = MI_HEIGHT(mi);
+
+       if (size < -MINSIZE) {
+               tp->width = NRAND(MIN(-size, MAX(MINSIZE, screen_width / 2)) -
+                                 MINSIZE + 1) + MINSIZE;
+               tp->height = NRAND(MIN(-size, MAX(MINSIZE, screen_height / 2)) -
+                                  MINSIZE + 1) + MINSIZE;
+       } else if (size < MINSIZE) {
+               if (!size) {
+                       tp->width = MAX(MINSIZE, screen_width / 2);
+                       tp->height = MAX(MINSIZE, screen_height / 2);
+               } else {
+                       tp->width = MINSIZE;
+                       tp->height = MINSIZE;
+               }
+       } else {
+               tp->width = MIN(size, MAX(MINSIZE, screen_width / 2));
+               tp->height = MIN(size, MAX(MINSIZE, screen_height / 2));
+       }
+       tp->average = (tp->width + tp->height) / 2;
+
+       tp->dx1 = NRAND(2);
+       if (tp->dx1 == 0)
+               tp->dx1 = -1;
+       tp->dy1 = NRAND(2);
+       if (tp->dy1 == 0)
+               tp->dy1 = -1;
+       if (tp->pts) {
+               (void) free((void *) tp->pts);
+               tp->pts = NULL;
+       }
+       if (tp->proto_pts) {
+               (void) free((void *) tp->proto_pts);
+               tp->proto_pts = NULL;
+       }
+       tp->shape = MI_COUNT(mi);
+       if (tp->shape < -MINSHAPE) {
+               tp->shape = NRAND(-tp->shape - MINSHAPE + 1) + MINSHAPE;
+       } else if (tp->shape < MINSHAPE)
+               tp->shape = MINSHAPE;
+
+       if (tp->shape >= 3) {
+               int         i;
+               float       start;
+
+               tp->width = tp->height = tp->average;
+               tp->pts = (XPoint *) malloc((tp->shape + 1) * sizeof (XPoint));
+               tp->proto_pts = (XPoint *) malloc((tp->shape + 1) * sizeof (XPoint));
+               start = (float) NRAND(360);
+               do {
+                       star = NRAND(tp->shape / 2) + 1;        /* Not always a star but thats ok. */
+               } while ((star != 1) && (!(tp->shape % star)));
+               for (i = 0; i < tp->shape; i++) {
+                       tp->proto_pts[i].x = tp->average / 2 +
+                               (int) (cos((double) start * 2.0 * M_PI / 360.0) * tp->average / 2.0);
+                       tp->proto_pts[i].y = tp->average / 2 +
+                               (int) (sin((double) start * 2.0 * M_PI / 360.0) * tp->average / 2.0);
+                       start += star * 360 / tp->shape;
+               }
+               tp->proto_pts[tp->shape] = tp->proto_pts[0];
+       }
+       tp->linewidth = NRAND(tp->average / 6 + 1) + 1;
+       if (star > 1)           /* Make the width less */
+               tp->linewidth = NRAND(tp->linewidth / 2 + 1) + 1;
+       lw = tp->linewidth / 2;
+       tp->x1 = NRAND(screen_width - tp->width - 2 * lw) + lw;
+       tp->y1 = NRAND(screen_height - tp->height - 2 * lw) + lw;
+
+       tp->counter = 0;
+
+       MI_CLEARWINDOW(mi);
+
+#ifndef STANDALONE
+       tp->fixed_colormap = !setupColormap(mi,
+               &(tp->ncolors), &truecolor, &redmask, &greenmask, &bluemask);
+       if (!tp->fixed_colormap) {
+               preserve = preserveColors(MI_BLACK_PIXEL(mi), MI_WHITE_PIXEL(mi),
+                                         MI_BG_PIXEL(mi), MI_FG_PIXEL(mi));
+               tp->bgcol.pixel = MI_BG_PIXEL(mi);
+               tp->fgcol.pixel = MI_FG_PIXEL(mi);
+               XQueryColor(display, MI_COLORMAP(mi), &(tp->bgcol));
+               XQueryColor(display, MI_COLORMAP(mi), &(tp->fgcol));
+
+#define RANGE 65536
+#define DENOM 2
+               /* color in the bottom part */
+               tp->bottom.red = NRAND(RANGE / DENOM);
+               tp->bottom.blue = NRAND(RANGE / DENOM);
+               tp->bottom.green = NRAND(RANGE / DENOM);
+               /* color in the top part */
+               tp->top.red = RANGE - NRAND(RANGE / DENOM);
+               tp->top.blue = RANGE - NRAND(RANGE / DENOM);
+               tp->top.green = RANGE - NRAND(RANGE / DENOM);
+
+               /* allocate colormap, if needed */
+               if (tp->colors == NULL)
+                       tp->colors = (XColor *) malloc(sizeof (XColor) * tp->ncolors);
+               if (tp->cmap == None)
+                       tp->cmap = XCreateColormap(display, window,
+                                                  MI_VISUAL(mi), AllocAll);
+               tp->usable_colors = tp->ncolors - preserve;
+       }
+       tp->cur_color = NRAND(tp->ncolors);
+#endif /* !STANDALONE */
+}
+
+void
+draw_tube(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       tubestruct *tp = &tubes[MI_SCREEN(mi)];
+       unsigned int i, j;
+       int         k, lw = tp->linewidth / 2;
+
+       MI_IS_DRAWN(mi) = True;
+
+       /* advance drawing color */
+       tp->cur_color = (tp->cur_color + 1) % tp->ncolors;
+#ifndef STANDALONE
+       if (!tp->fixed_colormap && tp->usable_colors > 2) {
+               while (tp->cur_color == MI_WHITE_PIXEL(mi) ||
+                      tp->cur_color == MI_BLACK_PIXEL(mi) ||
+                      tp->cur_color == MI_BG_PIXEL(mi) ||
+                      tp->cur_color == MI_FG_PIXEL(mi)) {
+                       tp->cur_color = (tp->cur_color + 1) % tp->ncolors;
+               }
+               XSetForeground(display, gc, tp->cur_color);
+       } else
+               XSetForeground(display, gc, MI_PIXEL(mi, tp->cur_color));
+#endif /* !STANDALONE */
+
+       /* move rectangle forward, horiz */
+       tp->x1 += tp->dx1;
+       if (tp->x1 < lw) {
+               tp->x1 = lw;
+               tp->dx1 = -tp->dx1;
+       }
+       if (tp->x1 + tp->width + lw >= MI_WIDTH(mi)) {
+               tp->x1 = MI_WIDTH(mi) - tp->width - 1 - lw;
+               tp->dx1 = -tp->dx1;
+       }
+       /* move rectange forward, vert */
+       tp->y1 += tp->dy1;
+       if (tp->y1 < lw) {
+               tp->y1 = lw;
+               tp->dy1 = -tp->dy1;
+       }
+       if (tp->y1 + tp->height + lw >= MI_HEIGHT(mi)) {
+               tp->y1 = MI_HEIGHT(mi) - tp->height - 1 - lw;
+               tp->dy1 = -tp->dy1;
+       }
+       XSetLineAttributes(display, gc, tp->linewidth + (tp->shape >= 2),
+                          LineSolid, CapNotLast, JoinRound);
+       if (tp->shape < 2)
+               XDrawRectangle(display, window, gc,
+                              tp->x1, tp->y1, tp->width, tp->height);
+       else if (tp->shape == 2)
+               XDrawArc(display, window, gc,
+                        tp->x1, tp->y1, tp->width, tp->height, 0, 23040);
+       else {
+               for (i = 0; i <= (unsigned int) tp->shape; i++) {
+                       tp->pts[i].x = tp->x1 + tp->proto_pts[i].x;
+                       tp->pts[i].y = tp->y1 + tp->proto_pts[i].y;
+               }
+               XDrawLines(display, window, gc, tp->pts, tp->shape + 1,
+                          CoordModeOrigin);
+       }
+       XSetLineAttributes(display, gc, 1, LineSolid, CapNotLast, JoinRound);
+
+#ifndef STANDALONE
+       /* advance colormap */
+       if (!tp->fixed_colormap && tp->usable_colors > 2) {
+               for (i = 0, j = tp->cur_color, k = 0;
+                    i < (unsigned int) tp->ncolors; i++) {
+                       if (i == MI_WHITE_PIXEL(mi)) {
+                               tp->colors[i].pixel = i;
+                               tp->colors[i].red = 65535;
+                               tp->colors[i].blue = 65535;
+                               tp->colors[i].green = 65535;
+                               tp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                       } else if (i == MI_BLACK_PIXEL(mi)) {
+                               tp->colors[i].pixel = i;
+                               tp->colors[i].red = 0;
+                               tp->colors[i].blue = 0;
+                               tp->colors[i].green = 0;
+                               tp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                       } else if (i == MI_BG_PIXEL(mi)) {
+                               tp->colors[i] = tp->bgcol;
+                       } else if (i == MI_FG_PIXEL(mi)) {
+                               tp->colors[i] = tp->fgcol;
+                       } else {
+                               double      range;
+
+                               tp->colors[i].pixel = i;
+                               range = ((double) (tp->top.red - tp->bottom.red)) /
+                                       tp->ncolors;
+                               tp->colors[i].red = (short unsigned int) (range * j +
+                                                            tp->bottom.red);
+                               range = ((double) (tp->top.green - tp->bottom.green)) /
+                                       tp->ncolors;
+                               tp->colors[i].green = (short unsigned int) (range * j +
+                                                          tp->bottom.green);
+                               range = ((double) (tp->top.blue - tp->bottom.blue)) /
+                                       tp->ncolors;
+                               tp->colors[i].blue = (short unsigned int) (range * j +
+                                                           tp->bottom.blue);
+                               tp->colors[i].flags = DoRed | DoGreen | DoBlue;
+                               j = (j + 1) % tp->ncolors;
+                               k++;
+                       }
+               }
+               /* make the entire tube move forward */
+               XStoreColors(display, tp->cmap, tp->colors, tp->ncolors);
+               setColormap(display, window, tp->cmap, MI_IS_INWINDOW(mi));
+       }
+#endif /* !STANDALONE */
+       tp->counter++;
+       if (tp->counter > MI_CYCLES(mi)) {
+               init_tube(mi);
+       }
+}
+
+void
+release_tube(ModeInfo * mi)
+{
+       if (tubes != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       tubestruct *tp = &tubes[screen];
+
+                       if (tp->pts)
+                               (void) free((void *) tp->pts);
+                       if (tp->proto_pts)
+                               (void) free((void *) tp->proto_pts);
+                       if (tp->cmap != None)
+                               XFreeColormap(MI_DISPLAY(mi), tp->cmap);
+                       if (tp->colors != NULL)
+                               XFree((caddr_t) tp->colors);
+               }
+               (void) free((void *) tubes);
+               tubes = NULL;
+       }
+}
+
+#endif /* MODE_tube */
diff --git a/xlockmore-4.14/modes/turtle.c b/xlockmore-4.14/modes/turtle.c
new file mode 100644 (file)
index 0000000..071c33d
--- /dev/null
@@ -0,0 +1,407 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* turtle --- fractal curves */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)turtle.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 01-Dec-96: Not too proud how I hacked in 2 more curves
+ * 30-Sep-96: started with Hilbert curve, David Bagley
+ * From Fractal Programming in C by Roger T. Stevens
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Turtle"
+#define HACK_INIT init_turtle
+#define HACK_DRAW draw_turtle
+#define turtle_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000000 \n" \
+ "*cycles: 20 \n" \
+ "*ncolors: 64 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_turtle
+
+ModeSpecOpt turtle_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   turtle_description =
+{"turtle", "init_turtle", "draw_turtle", "release_turtle",
+ "init_turtle", "init_turtle", NULL, &turtle_opts,
+ 1000000, 1, 20, 1, 64, 1.0, "",
+ "Shows turtle fractals", 0, NULL};
+
+#endif
+
+#define HILBERT 0              /* Not exactly a turtle algorthm... p199 */
+#define CESARO_VAR 1           /* Telephone curve p168 */
+#define HARTER_HEIGHTWAY 2     /* Dragon curve p292 */
+#define TURTLE_CURVES 3
+
+#define POINT(x_1,y_1,x_2,y_2) (((x_2)==(x_1))?(((y_2)>(y_1))?90.0:270.0):\
+  ((x_2)>(x_1))?(atan(((y_2)-(y_1))/((x_2)-(x_1)))*(180.0/M_PI)):\
+  (atan(((y_2)-(y_1))/((x_2)-(x_1)))*(180.0/M_PI)+180.0))
+#define TURN(theta, angle) ((theta)+=(angle))
+#define STEP(x, y, r, theta) ((x)+=(r)*cos((theta)*M_PI/180.0)),\
+  ((y)+=(r)*sin((theta)*M_PI/180.0))
+
+typedef struct {
+       double      r, theta, x, y;
+} turtletype;
+
+typedef struct {
+       double      x, y;
+} complextype;
+
+typedef struct {
+       int         width, height;
+       int         time;
+       int         level;
+       int         curve;
+       int         r, maxlevel, min, dir;
+       XPoint      pt1, pt2;
+       XPoint      start;
+       turtletype  turtle;
+       int         sign;
+} turtlestruct;
+
+static turtlestruct *turtles = NULL;
+
+static void
+generate_hilbert(ModeInfo * mi, int r1, int r2)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       turtlestruct *tp = &turtles[MI_SCREEN(mi)];
+
+       tp->level--;
+
+       if (tp->level > 0)
+               generate_hilbert(mi, r2, r1);
+
+       tp->pt2.x += r1;
+       tp->pt2.y += r2;
+       XDrawLine(display, window, gc,
+                 tp->pt1.x, tp->pt1.y, tp->pt2.x, tp->pt2.y);
+       tp->pt1.x = tp->pt2.x;
+       tp->pt1.y = tp->pt2.y;
+
+       if (tp->level > 0)
+               generate_hilbert(mi, r1, r2);
+
+       tp->pt2.x += r2;
+       tp->pt2.y += r1;
+       XDrawLine(display, window, gc,
+                 tp->pt1.x, tp->pt1.y, tp->pt2.x, tp->pt2.y);
+       tp->pt1.x = tp->pt2.x;
+       tp->pt1.y = tp->pt2.y;
+
+       if (tp->level > 0)
+               generate_hilbert(mi, r1, r2);
+
+       tp->pt2.x -= r1;
+       tp->pt2.y -= r2;
+       XDrawLine(display, window, gc,
+                 tp->pt1.x, tp->pt1.y, tp->pt2.x, tp->pt2.y);
+       tp->pt1.x = tp->pt2.x;
+       tp->pt1.y = tp->pt2.y;
+
+       if (tp->level > 0)
+               generate_hilbert(mi, -r2, -r1);
+
+       tp->level++;
+}
+
+static void
+generate_cesarovar(ModeInfo * mi, double pt1x, double pt1y,
+                  double pt2x, double pt2y, int level, int sign)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       turtlestruct *tp = &turtles[MI_SCREEN(mi)];
+       complextype points[4];
+
+       level--;
+
+       tp->turtle.r = sqrt((double) ((pt2x - pt1x) * (pt2x - pt1x) +
+                                     (pt2y - pt1y) * (pt2y - pt1y))) / 2.0;
+       points[0].x = pt1x;
+       points[0].y = pt1y;
+       points[2].x = pt2x;
+       points[2].y = pt2y;
+       tp->turtle.theta = POINT(pt1x, pt1y, pt2x, pt2y);
+       tp->turtle.x = pt1x;
+       tp->turtle.y = pt1y;
+       STEP(tp->turtle.x, tp->turtle.y, tp->turtle.r, tp->turtle.theta);
+       points[3].x = tp->turtle.x;
+       points[3].y = tp->turtle.y;
+       TURN(tp->turtle.theta, 90.0 * (double) sign);
+       STEP(tp->turtle.x, tp->turtle.y, tp->turtle.r, tp->turtle.theta);
+       points[1].x = tp->turtle.x;
+       points[1].y = tp->turtle.y;
+       sign = -1;
+       if (level > 0) {
+               int         j;
+
+               for (j = 0; j < 2; j++) {
+                       pt1x = points[j].x;
+                       pt2x = points[j + 1].x;
+                       pt1y = points[j].y;
+                       pt2y = points[j + 1].y;
+                       generate_cesarovar(mi, pt1x, pt1y, pt2x, pt2y, level, sign);
+               }
+       } else {
+               XDrawLine(display, window, gc,
+                         (int) points[0].x + tp->start.x, (int) points[0].y + tp->start.y,
+                         (int) points[2].x + tp->start.x, (int) points[2].y + tp->start.y);
+               XDrawLine(display, window, gc,
+                         (int) points[1].x + tp->start.x, (int) points[1].y + tp->start.y,
+                         (int) points[3].x + tp->start.x, (int) points[3].y + tp->start.y);
+       }
+}
+
+static void
+generate_harter_heightway(ModeInfo * mi, double pt1x, double pt1y,
+                         double pt2x, double pt2y, int level, int sign)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       turtlestruct *tp = &turtles[MI_SCREEN(mi)];
+       complextype points[4];
+       int         sign2 = -1;
+
+       level--;
+
+       tp->turtle.r = sqrt((double) ((pt2x - pt1x) * (pt2x - pt1x) +
+                                     (pt2y - pt1y) * (pt2y - pt1y)) / 2.0);
+       points[0].x = pt1x;
+       points[0].y = pt1y;
+       points[2].x = pt2x;
+       points[2].y = pt2y;
+       tp->turtle.theta = POINT(pt1x, pt1y, pt2x, pt2y);
+       tp->turtle.x = pt1x;
+       tp->turtle.y = pt1y;
+       TURN(tp->turtle.theta, 45.0 * (double) sign);
+       STEP(tp->turtle.x, tp->turtle.y, tp->turtle.r, tp->turtle.theta);
+       points[1].x = tp->turtle.x;
+       points[1].y = tp->turtle.y;
+       if (level > 0) {
+               int         j;
+
+               for (j = 0; j < 2; j++) {
+                       pt1x = points[j].x;
+                       pt2x = points[j + 1].x;
+                       pt1y = points[j].y;
+                       pt2y = points[j + 1].y;
+                       generate_harter_heightway(mi, pt1x, pt1y, pt2x, pt2y, level, sign2);
+                       sign2 *= -1;
+               }
+       } else {
+               XDrawLine(display, window, gc,
+                         (int) points[0].x + tp->start.x, (int) points[0].y + tp->start.y,
+                         (int) points[1].x + tp->start.x, (int) points[1].y + tp->start.y);
+               XDrawLine(display, window, gc,
+                         (int) points[1].x + tp->start.x, (int) points[1].y + tp->start.y,
+                         (int) points[2].x + tp->start.x, (int) points[2].y + tp->start.y);
+       }
+}
+
+
+void
+init_turtle(ModeInfo * mi)
+{
+       turtlestruct *tp;
+       int         i;
+
+       if (turtles == NULL) {
+               if ((turtles = (turtlestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (turtlestruct))) == NULL)
+                       return;
+       }
+       tp = &turtles[MI_SCREEN(mi)];
+
+       tp->width = MI_WIDTH(mi);
+       tp->height = MI_HEIGHT(mi);
+       tp->min = MIN(tp->width, tp->height);
+       tp->maxlevel = 0;
+       i = tp->min;
+       do {
+               tp->r = i;
+               tp->maxlevel++;
+               i = (tp->min - 1) / (1 << tp->maxlevel);
+       } while (i > 1);
+       tp->maxlevel--;
+       tp->r = tp->min = (tp->r << tp->maxlevel);
+
+       tp->curve = NRAND(TURTLE_CURVES);
+       switch (tp->curve) {
+               case HILBERT:
+                       tp->start.x = NRAND(tp->width - tp->min);
+                       tp->start.y = NRAND(tp->height - tp->min);
+                       break;
+               case CESARO_VAR:
+                       tp->r <<= 6;
+                       tp->min = 3 * tp->min / 4;
+                       tp->start.x = tp->width / 2;
+                       tp->start.y = tp->height / 2;
+                       switch (NRAND(4)) {
+                               case 0:
+                                       tp->pt1.x = -tp->min / 2;
+                                       tp->pt1.y = 0;
+                                       tp->pt2.x = tp->min / 2;
+                                       tp->pt2.y = 0;
+                                       tp->start.y -= tp->min / 6;
+                                       break;
+                               case 1:
+                                       tp->pt1.x = 0;
+                                       tp->pt1.y = -tp->min / 2;
+                                       tp->pt2.x = 0;
+                                       tp->pt2.y = tp->min / 2;
+                                       tp->start.x += tp->min / 6;
+                                       break;
+                               case 2:
+                                       tp->pt1.x = tp->min / 2;
+                                       tp->pt1.y = 0;
+                                       tp->pt2.x = -tp->min / 2;
+                                       tp->pt2.y = 0;
+                                       tp->start.y += tp->min / 6;
+                                       break;
+                               case 3:
+                                       tp->pt1.x = 0;
+                                       tp->pt1.y = tp->min / 2;
+                                       tp->pt2.x = 0;
+                                       tp->pt2.y = -tp->min / 2;
+                                       tp->start.x -= tp->min / 6;
+                                       break;
+                       }
+                       break;
+               case HARTER_HEIGHTWAY:
+                       tp->r <<= 6;
+                       tp->min = 3 * tp->min / 4;
+                       tp->start.x = tp->width / 2;
+                       tp->start.y = tp->height / 2;
+                       switch (NRAND(4)) {
+                               case 0:
+                                       tp->pt1.x = -tp->min / 2;
+                                       tp->pt1.y = -tp->min / 12;
+                                       tp->pt2.x = tp->min / 2;
+                                       tp->pt2.y = -tp->min / 12;
+                                       break;
+                               case 1:
+                                       tp->pt1.x = tp->min / 12;
+                                       tp->pt1.y = -tp->min / 2;
+                                       tp->pt2.x = tp->min / 12;
+                                       tp->pt2.y = tp->min / 2;
+                                       break;
+                               case 2:
+                                       tp->pt1.x = tp->min / 2;
+                                       tp->pt1.y = tp->min / 12;
+                                       tp->pt2.x = -tp->min / 2;
+                                       tp->pt2.y = tp->min / 12;
+                                       break;
+                               case 3:
+                                       tp->pt1.x = -tp->min / 12;
+                                       tp->pt1.y = tp->min / 2;
+                                       tp->pt2.x = -tp->min / 12;
+                                       tp->pt2.y = -tp->min / 2;
+                                       break;
+                       }
+       }
+       tp->level = 0;
+       tp->sign = 1;
+       tp->dir = NRAND(4);
+       tp->time = 0;
+
+       MI_CLEARWINDOW(mi);
+
+       if (MI_NPIXELS(mi) <= 2)
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WHITE_PIXEL(mi));
+}
+
+void
+draw_turtle(ModeInfo * mi)
+{
+       turtlestruct *tp = &turtles[MI_SCREEN(mi)];
+
+       if (++tp->time > MI_CYCLES(mi))
+               init_turtle(mi);
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (MI_NPIXELS(mi) > 2)
+               XSetForeground(MI_DISPLAY(mi), MI_GC(mi),
+                              MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))));
+
+       tp->r = tp->r >> 1;
+       tp->level++;
+       if (tp->r > 1)
+               switch (tp->curve) {
+                       case HILBERT:
+                               switch (tp->dir) {
+                                       case 0:
+                                               tp->pt1.x = tp->pt2.x = tp->start.x + tp->r / 2;
+                                               tp->pt1.y = tp->pt2.y = tp->start.y + tp->r / 2;
+                                               generate_hilbert(mi, 0, tp->r);
+                                               break;
+                                       case 1:
+                                               tp->pt1.x = tp->pt2.x = tp->start.x + tp->min - tp->r / 2;
+                                               tp->pt1.y = tp->pt2.y = tp->start.y + tp->min - tp->r / 2;
+                                               generate_hilbert(mi, 0, -tp->r);
+                                               break;
+                                       case 2:
+                                               tp->pt1.x = tp->pt2.x = tp->start.x + tp->min - tp->r / 2;
+                                               tp->pt1.y = tp->pt2.y = tp->start.y + tp->min - tp->r / 2;
+                                               generate_hilbert(mi, -tp->r, 0);
+                                               break;
+                                       case 3:
+                                               tp->pt1.x = tp->pt2.x = tp->start.x + tp->r / 2;
+                                               tp->pt1.y = tp->pt2.y = tp->start.y + tp->r / 2;
+                                               generate_hilbert(mi, tp->r, 0);
+                               }
+                               break;
+                       case CESARO_VAR:
+                               generate_cesarovar(mi, tp->pt1.x, tp->pt1.y, tp->pt2.x, tp->pt2.y,
+                                                  tp->level, tp->sign);
+                               break;
+                       case HARTER_HEIGHTWAY:
+                               generate_harter_heightway(mi, tp->pt1.x, tp->pt1.y,
+                                 tp->pt2.x, tp->pt2.y, tp->level, tp->sign);
+                               break;
+               }
+}
+
+void
+release_turtle(ModeInfo * mi)
+{
+       if (turtles != NULL) {
+               (void) free((void *) turtles);
+               turtles = NULL;
+       }
+}
+
+#endif /* MODE_turtle */
diff --git a/xlockmore-4.14/modes/vines.c b/xlockmore-4.14/modes/vines.c
new file mode 100644 (file)
index 0000000..0ae29f1
--- /dev/null
@@ -0,0 +1,183 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* vines --- vine fractals */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)vines.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by Tracy Camp campt@hurrah.com
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * If you make a modification I would of course appreciate a copy.
+ *
+ * Revision History:
+ * 11-Jul-97: David Hansen <dhansen@metapath.com>
+ *            Changed names to vines and modified draw loop
+ *            to honor batchcount so vines can be grown or
+ *            plotted.
+ * 10-May-97: Compatible with xscreensaver
+ * 21-Mar-97: David Hansen <dhansen@metapath.com>
+ *            Updated mode to draw complete patterns on every
+ *            iteration instead of growing the vine.  Also made
+ *            adjustments to randomization and changed variable
+ *            names to make logic easier to follow.
+ */
+
+/*- 
+ * This was modifed from a 'screen saver' that a friend and I
+ * wrote on our TI-8x calculators in high school physics one day
+ * Basically another geometric pattern generator, this ones claim
+ * to fame is a pseudo-fractal looking vine like pattern that creates
+ * nifty whorls and loops.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Vines"
+#define HACK_INIT init_vines
+#define HACK_DRAW draw_vines
+#define vines_opts xlockmore_opts
+#define DEFAULTS "*delay: 200000 \n" \
+ "*count: 0 \n" \
+ "*ncolors: 64 \n" \
+ "*eraseSpeed: 400 \n" \
+ "*eraseMode: -1 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_vines
+
+ModeSpecOpt vines_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   vines_description =
+{"vines", "init_vines", "draw_vines", "release_vines",
+ "refresh_vines", "init_vines", NULL, &vines_opts,
+ 200000, 0, 1, 1, 64, 1.0, "",
+ "Shows fractals", 0, NULL};
+
+#endif
+
+typedef struct {
+       int         a;
+       int         x1;
+       int         y1;
+       int         x2;
+       int         y2;
+       int         i;
+       int         length;
+       int         iterations;
+       int         constant;
+       int         ang;
+       int         centerx;
+       int         centery;
+} vinestruct;
+
+static vinestruct *vines = NULL;
+
+void
+refresh_vines(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}                              /* refresh_vines */
+
+void
+init_vines(ModeInfo * mi)
+{
+       vinestruct *fp;
+
+       if (vines == NULL) {
+               if ((vines = (vinestruct *) calloc(MI_NUM_SCREENS(mi),
+                                            sizeof (vinestruct))) == NULL) {
+                       return;
+               }
+       }
+       fp = &vines[MI_SCREEN(mi)];
+
+       fp->i = 0;
+       fp->length = 0;
+       fp->iterations = 30 + NRAND(100);
+
+       MI_CLEARWINDOW(mi);
+}                              /* init_vines */
+
+void
+draw_vines(ModeInfo * mi)
+{
+       vinestruct *fp = &vines[MI_SCREEN(mi)];
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       int         count;
+
+       MI_IS_DRAWN(mi) = True;
+
+       if (fp->i >= fp->length) {
+               if (--(fp->iterations) == 0) {
+                       init_vines(mi);
+               }
+               fp->centerx = NRAND(MI_WIDTH(mi));
+               fp->centery = NRAND(MI_HEIGHT(mi));
+
+               fp->ang = 60 + NRAND(720);
+               fp->length = 100 + NRAND(3000);
+               fp->constant = fp->length * (10 + NRAND(10));
+
+               fp->i = 0;
+               fp->a = 0;
+               fp->x1 = 0;
+               fp->y1 = 0;
+               fp->x2 = 1;
+               fp->y2 = 0;
+
+               if (MI_NPIXELS(mi) > 2)
+                       XSetForeground(display, gc, MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))));
+               else
+                       XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+       }
+       count = fp->i + MI_COUNT(mi);
+       if ((count <= fp->i) || (count > fp->length))
+               count = fp->length;
+
+       while (fp->i < count) {
+               XDrawLine(display, MI_WINDOW(mi), gc,
+                         fp->centerx + (fp->x1 / fp->constant),
+                         fp->centery - (fp->y1 / fp->constant),
+                         fp->centerx + (fp->x2 / fp->constant),
+                         fp->centery - (fp->y2 / fp->constant));
+
+               fp->a += (fp->ang * fp->i);
+
+               fp->x1 = fp->x2;
+               fp->y1 = fp->y2;
+
+               fp->x2 += (int) (fp->i * ((cos(fp->a) * 360) / (2 * M_PI)));
+               fp->y2 += (int) (fp->i * ((sin(fp->a) * 360) / (2 * M_PI)));
+               fp->i++;
+       }
+}                              /* draw_vines */
+
+void
+release_vines(ModeInfo * mi)
+{
+       if (vines != NULL) {
+               (void) free((void *) vines);
+               vines = NULL;
+       }
+}                              /* release_vines */
+
+#endif /* MODE_vines */
diff --git a/xlockmore-4.14/modes/voters.c b/xlockmore-4.14/modes/voters.c
new file mode 100644 (file)
index 0000000..1b498d0
--- /dev/null
@@ -0,0 +1,825 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* voters --- Dewdney's Voting Simulation */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)voters.c     4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1997 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-Jun-97: Coded from A.K. Dewdney's "The Armchair Universe, Computer
+ *            Recreations from the Pages of Scientific American Magazine"
+ *            W.H. Freedman and Company, New York, 1988  (Apr 1985)
+ *            Used wator.c and demon.c as a guide.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Voters"
+#define HACK_INIT init_voters
+#define HACK_DRAW draw_voters
+#define voters_opts xlockmore_opts
+#define DEFAULTS "*delay: 1000 \n" \
+ "*cycles: 327670 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 64 \n" \
+ "*neighbors: 0 \n"
+#define UNIFORM_COLORS
+#define BRIGHT_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_voters
+
+/*-
+ * neighbors of 0 randomizes it between 3, 4, 6, 8, 9, and 12.
+ */
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+
+static int  neighbors;
+
+static XrmOptionDescRec opts[] =
+{
+        {"-neighbors", ".voters.neighbors", XrmoptionSepArg, (caddr_t) NULL}
+};
+
+static argtype vars[] =
+{
+        {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int
+}
+};
+static OptionStruct desc[] =
+{
+        {"-neighbors num", "squares 4 or 8, hexagons 6, triangles 3, 9 or 12"}
+};
+
+ModeSpecOpt voters_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+
+#ifdef USE_MODULES
+ModStruct   voters_description =
+{"voters", "init_voters", "draw_voters", "release_voters",
+ "refresh_voters", "init_voters", NULL, &voters_opts,
+ 1000, 0, 327670, 0, 64, 1.0, "",
+ "Shows Dewdney's Voters", 0, NULL};
+
+#endif
+
+/*-
+ * From far left to right, at least in the currently in the US.  By the way, I
+ * consider myself to be a proud bleeding heart liberal democrat, in
+ * case anyone wants to know....  Please, no fascist "improvements".  :)
+ */
+
+#include "bitmaps/sickle.xbm"
+#include "bitmaps/donkey.xbm"
+#include "bitmaps/elephant.xbm"
+
+#define MINPARTIES 2
+#define BITMAPS 3
+#define MINGRIDSIZE 10
+#define MINSIZE 4
+#define FACTOR 10
+#define NEIGHBORKINDS 6
+
+static XImage logo[BITMAPS] =
+{
+      {0, 0, 0, XYBitmap, (char *) sickle_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) donkey_bits, LSBFirst, 8, LSBFirst, 8, 1},
+    {0, 0, 0, XYBitmap, (char *) elephant_bits, LSBFirst, 8, LSBFirst, 8, 1},
+};
+
+/* Voter data */
+typedef struct {
+       char        kind;
+       int         age;
+       int         col, row;
+} cellstruct;
+
+/* Doublely linked list */
+typedef struct _CellList {
+       cellstruct  info;
+       struct _CellList *previous, *next;
+} CellList;
+
+typedef struct {
+       Bool        painted;
+       int         party;      /* Currently working on donkey, elephant, or sickle? */
+       int         xs, ys;     /* Size of party icon */
+       int         xb, yb;     /* Bitmap offset for party icon */
+       int         nparties;   /* 2 parties or 3 */
+       int         number_in_party[BITMAPS];   /* Good to know when one party rules */
+       int         pixelmode;
+       int         generation;
+       int         ncols, nrows;
+       int         npositions;
+       int         width, height;
+       CellList   *last, *first;
+       char       *arr;
+       int         neighbors;
+       int         busyLoop;
+       XPoint      hexagonList[6];
+       XPoint      triangleList[2][3];
+} voterstruct;
+
+static char plots[NEIGHBORKINDS] =
+{
+       3, 4, 6, 8, 9, 12       /* Neighborhoods */
+};
+
+static voterstruct *voters = NULL;
+static int  icon_width, icon_height;
+
+static void
+drawcell(ModeInfo * mi, int col, int row, unsigned long color, int bitmap,
+        Bool firstChange)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       voterstruct *vp = &voters[MI_SCREEN(mi)];
+       unsigned long colour = (MI_NPIXELS(mi) > 2) ?
+       MI_PIXEL(mi, color) : MI_WHITE_PIXEL(mi);
+
+       XSetForeground(display, gc, colour);
+       if (vp->neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               vp->hexagonList[0].x = vp->xb + ccol * vp->xs;
+               vp->hexagonList[0].y = vp->yb + crow * vp->ys;
+               if (vp->xs == 1 && vp->ys == 1)
+                       XDrawPoint(display, window, gc,
+                          vp->hexagonList[0].x, vp->hexagonList[0].y);
+               else if (bitmap == BITMAPS - 1)
+                       XFillPolygon(display, window, gc,
+                             vp->hexagonList, 6, Convex, CoordModePrevious);
+               else {
+                       if (firstChange) {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XFillPolygon(display, window, gc,
+                                            vp->hexagonList, 6, Convex, CoordModePrevious);
+                               XSetForeground(display, gc, colour);
+                       }
+                       if (vp->xs <= 6 || vp->ys <= 2)
+                               XFillRectangle(display, window, gc,
+                                      vp->hexagonList[0].x - 3 * vp->xs / 4,
+                                              vp->hexagonList[0].y + vp->ys / 4, vp->xs, vp->ys);
+                       else
+                               XFillArc(display, window, gc,
+                                    vp->xb + vp->xs * ccol - 3 * vp->xs / 4,
+                                        vp->yb + vp->ys * crow + vp->ys / 4,
+                                        2 * vp->xs - 6, 2 * vp->ys - 2,
+                                        0, 23040);
+               }
+       } else if (vp->neighbors == 4 || vp->neighbors == 8) {
+               if (vp->pixelmode) {
+                       if (bitmap == BITMAPS - 1 || (vp->xs <= 2 || vp->ys <= 2))
+                               XFillRectangle(display, window, gc,
+                               vp->xb + vp->xs * col, vp->yb + vp->ys * row,
+                               vp->xs - (vp->xs > 3), vp->ys - (vp->ys > 3));
+                       else {
+                               if (firstChange) {
+                                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                                       XFillRectangle(display, window, gc,
+                                                      vp->xb + vp->xs * col, vp->yb + vp->ys * row,
+                                                      vp->xs, vp->ys);
+                                       XSetForeground(display, gc, colour);
+                               }
+                               XFillArc(display, window, gc,
+                                        vp->xb + vp->xs * col, vp->yb + vp->ys * row,
+                                        vp->xs - 1, vp->ys - 1,
+                                        0, 23040);
+                       }
+               } else
+                       (void) XPutImage(display, window, gc,
+                                        &logo[bitmap], 0, 0,
+                               vp->xb + vp->xs * col, vp->yb + vp->ys * row,
+                                        icon_width, icon_height);
+       } else {                /* TRI */
+               int         orient = (col + row) % 2;   /* O left 1 right */
+
+               vp->triangleList[orient][0].x = vp->xb + col * vp->xs;
+               vp->triangleList[orient][0].y = vp->yb + row * vp->ys;
+               if (vp->xs <= 3 || vp->ys <= 3)
+                       XDrawPoint(display, window, gc,
+                        ((orient) ? -1 : 1) + vp->triangleList[orient][0].x,
+                                      vp->triangleList[orient][0].y);
+               else {
+                       if (orient)
+                               vp->triangleList[orient][0].x += (vp->xs / 2 - 1);
+                       else
+                               vp->triangleList[orient][0].x -= (vp->xs / 2 - 1);
+                       if (bitmap == BITMAPS - 1)
+                               XFillPolygon(display, window, gc,
+                                            vp->triangleList[orient], 3, Convex, CoordModePrevious);
+                       else {
+                               if (firstChange) {
+                                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                                       XFillPolygon(display, window, gc,
+                                                    vp->triangleList[orient], 3, Convex, CoordModePrevious);
+                                       XSetForeground(display, gc, colour);
+                               }
+                               XFillArc(display, window, gc,
+                                    vp->xb + vp->xs * col - 4 * vp->xs / 5 +
+                                   ((orient) ? vp->xs / 3 : 3 * vp->xs / 5),
+                                        vp->yb + vp->ys * row - vp->ys / 2 + 1, vp->ys - 3, vp->ys - 3,
+                                        0, 23040);
+                       }
+               }
+       }
+}
+
+static void
+init_list(voterstruct * vp)
+{
+       /* Waste some space at the beginning and end of list
+          so we do not have to complicated checks against falling off the ends. */
+       vp->last = (CellList *) malloc(sizeof (CellList));
+       vp->first = (CellList *) malloc(sizeof (CellList));
+       vp->first->previous = vp->last->next = NULL;
+       vp->first->next = vp->last->previous = NULL;
+       vp->first->next = vp->last;
+       vp->last->previous = vp->first;
+}
+
+static void
+addto_list(voterstruct * vp, cellstruct info)
+{
+       CellList   *curr;
+
+       curr = (CellList *) malloc(sizeof (CellList));
+       vp->last->previous->next = curr;
+       curr->previous = vp->last->previous;
+       curr->next = vp->last;
+       vp->last->previous = curr;
+       curr->info = info;
+}
+
+static void
+removefrom_list(CellList * ptr)
+{
+       ptr->previous->next = ptr->next;
+       ptr->next->previous = ptr->previous;
+       (void) free((void *) ptr);
+}
+
+static void
+flush_list(voterstruct * vp)
+{
+       CellList   *curr;
+
+       while (vp->last->previous != vp->first) {
+               curr = vp->last->previous;
+               curr->previous->next = vp->last;
+               vp->last->previous = curr->previous;
+               (void) free((void *) curr);
+       }
+}
+
+static char
+neighbors_opinion(voterstruct * vp, int col, int row, int dir)
+{
+       if (vp->neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                               break;
+                       case 60:
+                               if (!(row & 1))
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                               row = (!row) ? vp->nrows - 1 : row - 1;
+                               break;
+                       case 120:
+                               if (row & 1)
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                               row = (!row) ? vp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? vp->ncols - 1 : col - 1;
+                               break;
+                       case 240:
+                               if (row & 1)
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                               row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                               break;
+                       case 300:
+                               if (!(row & 1))
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else if (vp->neighbors == 4 || vp->neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                               break;
+                       case 45:
+                               col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                               row = (!row) ? vp->nrows - 1 : row - 1;
+                               break;
+                       case 90:
+                               row = (!row) ? vp->nrows - 1 : row - 1;
+                               break;
+                       case 135:
+                               col = (!col) ? vp->ncols - 1 : col - 1;
+                               row = (!row) ? vp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? vp->ncols - 1 : col - 1;
+                               break;
+                       case 225:
+                               col = (!col) ? vp->ncols - 1 : col - 1;
+                               row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                               break;
+                       case 270:
+                               row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                               break;
+                       case 315:
+                               col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {                /* TRI */
+               if ((col + row) % 2) {  /* right */
+                       switch (dir) {
+                               case 0:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 60:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       if (row + 1 == vp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == vp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (row + 1 == vp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == vp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 120:
+                                       row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 180:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? vp->nrows - 1 : row - 1;
+                                       break;
+                               case 240:
+                                       row = (!row) ? vp->nrows - 1 : row - 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (!row)
+                                               row = vp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = vp->nrows - 1;
+                                       else
+                                               row = row - 2;
+
+                                       break;
+                               case 300:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       if (!row)
+                                               row = vp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = vp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       row = (!row) ? vp->nrows - 1 : row - 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               } else {        /* left */
+                       switch (dir) {
+                               case 0:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? vp->nrows - 1 : row - 1;
+                                       break;
+                               case 60:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       if (!row)
+                                               row = vp->nrows - 2;
+                                       else if (row == 1)
+                                               row = vp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (!row)
+                                               row = vp->nrows - 2;
+                                       else if (row == 1)
+                                               row = vp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 120:
+                                       row = (!row) ? vp->nrows - 1 : row - 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       row = (!row) ? vp->nrows - 1 : row - 1;
+                                       break;
+                               case 180:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (!col) ? vp->ncols - 1 : col - 1;
+                                       row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 240:
+                                       row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (row + 1 == vp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == vp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 300:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       if (row + 1 == vp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == vp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (col + 1 == vp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == vp->nrows) ? 0 : row + 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               }
+       }
+
+       return vp->arr[row * vp->ncols + col];
+}
+
+static void
+advanceColors(ModeInfo * mi, int col, int row)
+{
+       voterstruct *vp = &voters[MI_SCREEN(mi)];
+       CellList   *curr;
+
+       curr = vp->first->next;
+       while (curr != vp->last) {
+               if (curr->info.col == col && curr->info.row == row) {
+                       curr = curr->next;
+                       removefrom_list(curr->previous);
+               } else {
+                       if (curr->info.age > 0)
+                               curr->info.age--;
+                       else if (curr->info.age < 0)
+                               curr->info.age++;
+                       drawcell(mi, curr->info.col, curr->info.row,
+                                (MI_NPIXELS(mi) + curr->info.age / FACTOR +
+                                 (MI_NPIXELS(mi) * curr->info.kind / BITMAPS)) % MI_NPIXELS(mi),
+                                curr->info.kind, False);
+                       if (curr->info.age == 0) {
+                               curr = curr->next;
+                               removefrom_list(curr->previous);
+                       } else
+                               curr = curr->next;
+               }
+       }
+}
+
+void
+refresh_voters(ModeInfo * mi)
+{
+       voterstruct *vp = &voters[MI_SCREEN(mi)];
+       int         col, row, colrow;
+
+       if (vp->painted) {
+               MI_CLEARWINDOW(mi);
+               vp->painted = False;
+               for (row = 0; row < vp->nrows; row++)
+                       for (col = 0; col < vp->ncols; col++) {
+                               colrow = col + row * vp->ncols;
+                               /* Draw all old, will get corrected soon if wrong... */
+                               drawcell(mi, col, row,
+                                        (unsigned long) (MI_NPIXELS(mi) * vp->arr[colrow] / BITMAPS),
+                                        vp->arr[colrow], False);
+                       }
+       }
+}
+
+void
+init_voters(ModeInfo * mi)
+{
+       int         size = MI_SIZE(mi);
+       voterstruct *vp;
+       int         i, col, row, colrow;
+
+       if (voters == NULL) {
+               if ((voters = (voterstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (voterstruct))) == NULL)
+                       return;
+       }
+       vp = &voters[MI_SCREEN(mi)];
+
+       vp->generation = 0;
+       if (!vp->first) {       /* Genesis of democracy */
+               icon_width = donkey_width;
+               icon_height = donkey_height;
+               init_list(vp);
+               for (i = 0; i < BITMAPS; i++) {
+                       logo[i].width = icon_width;
+                       logo[i].height = icon_height;
+                       logo[i].bytes_per_line = (icon_width + 7) / 8;
+               }
+       } else                  /* Exterminate all free thinking individuals */
+               flush_list(vp);
+
+       vp->width = MI_WIDTH(mi);
+       vp->height = MI_HEIGHT(mi);
+
+       for (i = 0; i < NEIGHBORKINDS; i++) {
+               if (neighbors == plots[i]) {
+                       vp->neighbors = neighbors;
+                       break;
+               }
+               if (i == NEIGHBORKINDS - 1) {
+#if 0
+                       vp->neighbors = plots[NRAND(NEIGHBORKINDS)];
+                       vp->neighbors = (LRAND() & 1) ? 4 : 8;
+#else
+                       vp->neighbors = 8;
+#endif
+                       break;
+               }
+       }
+
+       if (vp->neighbors == 6) {
+               int         nccols, ncrows, sides;
+
+               if (vp->width < 2)
+                       vp->width = 2;
+               if (vp->height < 4)
+                       vp->height = 4;
+               if (size < -MINSIZE)
+                       vp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(vp->width, vp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               vp->ys = MAX(MINSIZE, MIN(vp->width, vp->height) / MINGRIDSIZE);
+                       else
+                               vp->ys = MINSIZE;
+               } else
+                       vp->ys = MIN(size, MAX(MINSIZE, MIN(vp->width, vp->height) /
+                                              MINGRIDSIZE));
+               vp->xs = vp->ys;
+               vp->pixelmode = True;
+               nccols = MAX(vp->width / vp->xs - 2, 2);
+               ncrows = MAX(vp->height / vp->ys - 1, 2);
+               vp->ncols = nccols / 2;
+               vp->nrows = 2 * (ncrows / 4);
+               vp->xb = (vp->width - vp->xs * nccols) / 2 + vp->xs / 2;
+               vp->yb = (vp->height - vp->ys * (ncrows / 2) * 2) / 2 + vp->ys;
+               for (sides = 0; sides < 6; sides++) {
+                       vp->hexagonList[sides].x = (vp->xs - 1) * hexagonUnit[sides].x;
+                       vp->hexagonList[sides].y =
+                               ((vp->ys - 1) * hexagonUnit[sides].y / 2) * 4 / 3;
+               }
+       } else if (vp->neighbors == 4 || vp->neighbors == 8) {
+               if (vp->width < 2)
+                       vp->width = 2;
+               if (vp->height < 2)
+                       vp->height = 2;
+               if (size == 0 ||
+                   MINGRIDSIZE * size > vp->width || MINGRIDSIZE * size > vp->height) {
+                       if (vp->width > MINGRIDSIZE * icon_width &&
+                           vp->height > MINGRIDSIZE * icon_height) {
+                               vp->pixelmode = False;
+                               vp->xs = icon_width;
+                               vp->ys = icon_height;
+                       } else {
+                               vp->pixelmode = True;
+                               vp->xs = vp->ys = MAX(MINSIZE, MIN(vp->width, vp->height) /
+                                                     MINGRIDSIZE);
+                       }
+               } else {
+                       vp->pixelmode = True;
+                       if (size < -MINSIZE)
+                               vp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(vp->width, vp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+                       else if (size < MINSIZE)
+                               vp->ys = MINSIZE;
+                       else
+                               vp->ys = MIN(size, MAX(MINSIZE, MIN(vp->width, vp->height) /
+                                                      MINGRIDSIZE));
+                       vp->xs = vp->ys;
+               }
+               vp->ncols = MAX(vp->width / vp->xs, 2);
+               vp->nrows = MAX(vp->height / vp->ys, 2);
+               vp->xb = (vp->width - vp->xs * vp->ncols) / 2;
+               vp->yb = (vp->height - vp->ys * vp->nrows) / 2;
+       } else {                /* TRI */
+               int         orient, sides;
+
+               if (vp->width < 2)
+                       vp->width = 2;
+               if (vp->height < 2)
+                       vp->height = 2;
+               if (size < -MINSIZE)
+                       vp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(vp->width, vp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               vp->ys = MAX(MINSIZE, MIN(vp->width, vp->height) / MINGRIDSIZE);
+                       else
+                               vp->ys = MINSIZE;
+               } else
+                       vp->ys = MIN(size, MAX(MINSIZE, MIN(vp->width, vp->height) /
+                                              MINGRIDSIZE));
+               vp->xs = (int) (1.52 * vp->ys);
+               vp->pixelmode = True;
+               vp->ncols = (MAX(vp->width / vp->xs - 1, 2) / 2) * 2;
+               vp->nrows = (MAX(vp->height / vp->ys - 1, 2) / 2) * 2;
+               vp->xb = (vp->width - vp->xs * vp->ncols) / 2 + vp->xs / 2;
+               vp->yb = (vp->height - vp->ys * vp->nrows) / 2 + vp->ys / 2;
+               for (orient = 0; orient < 2; orient++) {
+                       for (sides = 0; sides < 3; sides++) {
+                               vp->triangleList[orient][sides].x =
+                                       (vp->xs - 2) * triangleUnit[orient][sides].x;
+                               vp->triangleList[orient][sides].y =
+                                       (vp->ys - 2) * triangleUnit[orient][sides].y;
+                       }
+               }
+       }
+
+       vp->npositions = vp->ncols * vp->nrows;
+       if (vp->arr != NULL)
+               (void) free((void *) vp->arr);
+       vp->arr = (char *) calloc(vp->npositions, sizeof (char));
+
+       /* Play G-d with these numbers */
+       vp->nparties = MI_COUNT(mi);
+       if (vp->nparties < MINPARTIES || vp->nparties > BITMAPS)
+               vp->nparties = NRAND(BITMAPS - MINPARTIES + 1) + MINPARTIES;
+       if (vp->pixelmode)
+               vp->nparties = 2;
+
+       vp->busyLoop = 0;
+       MI_CLEARWINDOW(mi);
+       vp->painted = False;
+
+       for (i = 0; i < BITMAPS; i++)
+               vp->number_in_party[i] = 0;
+
+       for (row = 0; row < vp->nrows; row++)
+               for (col = 0; col < vp->ncols; col++) {
+                       colrow = col + row * vp->ncols;
+                       i = NRAND(vp->nparties) + (vp->nparties == 2);
+                       vp->arr[colrow] = (char) i;
+                       drawcell(mi, col, row, (unsigned long) (MI_NPIXELS(mi) * i / BITMAPS),
+                                i, False);
+                       vp->number_in_party[i]++;
+               }
+}
+
+void
+draw_voters(ModeInfo * mi)
+{
+       voterstruct *vp = &voters[MI_SCREEN(mi)];
+       int         i, spineless_dude, neighbor_direction;
+       int         spineless_col, spineless_row;
+       int         new_opinion, old_opinion;
+       cellstruct  info;
+
+       MI_IS_DRAWN(mi) = True;
+
+       vp->painted = True;
+       if (vp->busyLoop) {
+               if (vp->busyLoop >= 5000)
+                       vp->busyLoop = 0;
+               else
+                       vp->busyLoop++;
+               return;
+       }
+       for (i = 0; i < BITMAPS; i++)
+               if (vp->number_in_party[i] == vp->npositions) {         /* The End of the WORLD */
+                       init_voters(mi);        /* Create a more interesting planet */
+               }
+       spineless_dude = NRAND(vp->npositions);
+       neighbor_direction = NRAND(vp->neighbors) * 360 / vp->neighbors;
+       spineless_col = spineless_dude % vp->ncols;
+       spineless_row = spineless_dude / vp->ncols;
+       old_opinion = vp->arr[spineless_dude];
+       new_opinion = neighbors_opinion(vp, spineless_col, spineless_row,
+                                       neighbor_direction);
+       if (old_opinion != new_opinion) {
+               vp->number_in_party[old_opinion]--;
+               vp->number_in_party[new_opinion]++;
+               vp->arr[spineless_dude] = new_opinion;
+               info.kind = new_opinion;
+               info.age = (old_opinion - new_opinion);
+               if (info.age == 2)
+                       info.age = -1;
+               if (info.age == -2)
+                       info.age = 1;
+               info.age *= (FACTOR * MI_NPIXELS(mi)) / 3;
+               info.col = spineless_col;
+               info.row = spineless_row;
+               if (MI_NPIXELS(mi) > 2) {
+                       advanceColors(mi, spineless_col, spineless_row);
+                       addto_list(vp, info);
+               }
+               drawcell(mi, spineless_col, spineless_row,
+                        (MI_NPIXELS(mi) + info.age / FACTOR +
+                 (MI_NPIXELS(mi) * new_opinion / BITMAPS)) % MI_NPIXELS(mi),
+                        new_opinion, True);
+       } else if (MI_NPIXELS(mi) > 2)
+               advanceColors(mi, -1, -1);
+       vp->generation++;
+       for (i = 0; i < BITMAPS; i++)
+               if (vp->number_in_party[i] == vp->npositions) {         /* The End of the WORLD */
+                       vp->busyLoop = 1;
+                       refresh_voters(mi);
+               }
+}
+
+void
+release_voters(ModeInfo * mi)
+{
+       if (voters != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       voterstruct *vp = &voters[screen];
+
+                       if (vp->first)
+                               flush_list(vp);
+                       if (vp->last)
+                               (void) free((void *) vp->last);
+                       if (vp->first)
+                               (void) free((void *) vp->first);
+                       if (vp->arr != NULL)
+                               (void) free((void *) vp->arr);
+               }
+               (void) free((void *) voters);
+               voters = NULL;
+       }
+}
+
+#endif /* MODE_voters */
diff --git a/xlockmore-4.14/modes/wator.c b/xlockmore-4.14/modes/wator.c
new file mode 100644 (file)
index 0000000..3bca2e7
--- /dev/null
@@ -0,0 +1,997 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* wator --- Dewdney's Wa-Tor, water torus simulation */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)wator.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1994 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 29-Aug-95: Efficiency improvements.
+ * 12-Dec-94: Coded from A.K. Dewdney's "The Armchair Universe, Computer 
+ *            Recreations from the Pages of Scientific American Magazine"
+ *            W.H. Freedman and Company, New York, 1988  (Dec 1984 and
+ *            June 1985) also used life.c as a guide.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Wator"
+#define HACK_INIT init_wator
+#define HACK_DRAW draw_wator
+#define wator_opts xlockmore_opts
+#define DEFAULTS "*delay: 750000 \n" \
+ "*cycles: 32767 \n" \
+ "*size: 0 \n" \
+ "*ncolors: 200 \n" \
+ "*neighbors: 0 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_wator
+
+/*-
+ * neighbors of 0 randomizes it between 3, 4, 6, 8, 9, and 12.
+ */
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+
+static int  neighbors;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".wator.neighbors", XrmoptionSepArg, (caddr_t) NULL}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int
+}
+};
+
+static OptionStruct desc[] =
+{
+       {"-neighbors num", "squares 4 or 8, hexagons 6, triangles 3, 9 or 12"}
+};
+
+ModeSpecOpt wator_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   wator_description =
+{"wator", "init_wator", "draw_wator", "release_wator",
+ "refresh_wator", "init_wator", NULL, &wator_opts,
+ 750000, 1, 32767, 0, 64, 1.0, "",
+ "Shows Dewdney's Water-Torus planet of fish and sharks", 0, NULL};
+
+#endif
+
+#include "bitmaps/fish-0.xbm"
+#include "bitmaps/fish-1.xbm"
+#include "bitmaps/fish-2.xbm"
+#include "bitmaps/fish-3.xbm"
+#include "bitmaps/fish-4.xbm"
+#include "bitmaps/fish-5.xbm"
+#include "bitmaps/fish-6.xbm"
+#include "bitmaps/fish-7.xbm"
+#include "bitmaps/shark-0.xbm"
+#include "bitmaps/shark-1.xbm"
+#include "bitmaps/shark-2.xbm"
+#include "bitmaps/shark-3.xbm"
+#include "bitmaps/shark-4.xbm"
+#include "bitmaps/shark-5.xbm"
+#include "bitmaps/shark-6.xbm"
+#include "bitmaps/shark-7.xbm"
+
+#define FISH 0
+#define SHARK 1
+#define KINDS 2
+#define ORIENTS 4
+#define REFLECTS 2
+#define BITMAPS (ORIENTS*REFLECTS*KINDS)
+#define KINDBITMAPS (ORIENTS*REFLECTS)
+#define MINGRIDSIZE 10         /* It is possible for the fish to take over with 3 */
+#define MINSIZE 4
+#define NEIGHBORKINDS 6
+
+static XImage logo[BITMAPS] =
+{
+       {0, 0, 0, XYBitmap, (char *) fish0_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) fish1_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) fish2_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) fish3_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) fish4_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) fish5_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) fish6_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {0, 0, 0, XYBitmap, (char *) fish7_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark0_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark1_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark2_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark3_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark4_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark5_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark6_bits, LSBFirst, 8, LSBFirst, 8, 1},
+      {0, 0, 0, XYBitmap, (char *) shark7_bits, LSBFirst, 8, LSBFirst, 8, 1},
+};
+
+/* Fish and shark data */
+typedef struct {
+       char        kind, age, food, direction;
+       unsigned long color;
+       int         col, row;
+} cellstruct;
+
+/* Doublely linked list */
+typedef struct _CellList {
+       cellstruct  info;
+       struct _CellList *previous, *next;
+} CellList;
+
+typedef struct {
+       Bool        painted;
+       int         nkind[KINDS];       /* Number of fish and sharks */
+       int         breed[KINDS];       /* Breeding time of fish and sharks */
+       int         sstarve;    /* Time the sharks starve if they dont find a fish */
+       int         kind;       /* Currently working on fish or sharks? */
+       int         xs, ys;     /* Size of fish and sharks */
+       int         xb, yb;     /* Bitmap offset for fish and sharks */
+       int         pixelmode;
+       int         generation;
+       int         ncols, nrows, positions;
+       int         width, height;
+       CellList   *currkind, *babykind, *lastkind[KINDS + 1], *firstkind[KINDS + 1];
+       CellList  **arr;        /* 0=empty or pts to a fish or shark */
+       int         neighbors;
+       union {
+               XPoint      hexagon[6];
+               XPoint      triangle[2][3];
+       } shape;
+} watorstruct;
+
+static char plots[NEIGHBORKINDS] =
+{
+       3, 4, 6, 8, 9, 12       /* Neighborhoods */
+};
+
+static watorstruct *wators = NULL;
+static int  icon_width, icon_height;
+
+#if 0
+/*-
+ * shape either a bitmap or 0 for circle and 1 for polygon
+ * (if triangle shape:  -1, 0, 2 or 3 to differentiate left and right)
+ */
+drawshape(ModeInfo * mi, int x, int y, int sizex, int sizey,
+         int sides, int shape)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+
+       if (sides == 4 && sizex == 0 && sizey == 0) {
+               (void) XPutImage(display, window, gc, &logo[shape], 0, 0,
+               x - icon_width, y - icon_height / 2, icon_width, icon_height);
+       } else if (sizex < 3 || sizey < 3 || (sides == 4 && shape == 1)) {
+               XFillRectangle(display, window, gc,
+                       x - sizex / 2, y - sizey / 2,
+                       sizex - (sizey > 3), sizey - (sizey > 3));
+       } else if (sides == 4 && shape == 0) {
+       } else if (sides == 6 && shape == 1) {
+       } else if (sides == 6 && shape == 0) {
+       } else if (sides == 3 && shape == 1) {
+       } else if (sides == 3 && shape == 2) {
+       } else if (sides == 3 && shape == -1) {
+       } else if (sides == 3 && shape == 0) {
+       }
+}
+#endif
+
+static void
+drawcell(ModeInfo * mi, int col, int row, unsigned long color, int bitmap,
+        Bool alive)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       watorstruct *wp = &wators[MI_SCREEN(mi)];
+       unsigned long colour;
+
+       if (!alive)
+               colour = MI_BLACK_PIXEL(mi);
+       else if (MI_NPIXELS(mi) > 2)
+               colour = MI_PIXEL(mi, color);
+       else
+               colour = MI_WHITE_PIXEL(mi);
+       XSetForeground(display, gc, colour);
+       if (wp->neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               wp->shape.hexagon[0].x = wp->xb + ccol * wp->xs;
+               wp->shape.hexagon[0].y = wp->yb + crow * wp->ys;
+               if (wp->xs == 1 && wp->ys == 1)
+                       XDrawPoint(display, window, gc,
+                       wp->shape.hexagon[0].x, wp->shape.hexagon[0].y);
+               else if (bitmap >= KINDBITMAPS || !alive)
+                       XFillPolygon(display, window, gc,
+                           wp->shape.hexagon, 6, Convex, CoordModePrevious);
+               else {
+                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                       XFillPolygon(display, window, gc,
+                           wp->shape.hexagon, 6, Convex, CoordModePrevious);
+                       XSetForeground(display, gc, colour);
+                       if (wp->xs <= 6 || wp->ys <= 2)
+                               XFillRectangle(display, window, gc,
+                                    wp->shape.hexagon[0].x - 3 * wp->xs / 4,
+                                    wp->shape.hexagon[0].y + wp->ys / 4, wp->xs, wp->ys);
+                       else
+                               XFillArc(display, window, gc,
+                                    wp->xb + wp->xs * ccol - 3 * wp->xs / 4,
+                                        wp->yb + wp->ys * crow + wp->ys / 4,
+                                        2 * wp->xs - 6, 2 * wp->ys - 2,
+                                        0, 23040);
+               }
+       } else if (wp->neighbors == 4 || wp->neighbors == 8) {
+               if (wp->pixelmode) {
+                       if (bitmap >= KINDBITMAPS || (wp->xs <= 2 || wp->ys <= 2) || !alive)
+                               XFillRectangle(display, window, gc,
+                               wp->xb + wp->xs * col, wp->yb + wp->ys * row,
+                               wp->xs - (wp->xs > 3), wp->ys - (wp->ys > 3));
+                       else {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XFillRectangle(display, window, gc,
+                               wp->xb + wp->xs * col, wp->yb + wp->ys * row,
+                                              wp->xs, wp->ys);
+                               XSetForeground(display, gc, colour);
+                               XFillArc(display, window, gc,
+                                        wp->xb + wp->xs * col, wp->yb + wp->ys * row,
+                                        wp->xs - 1, wp->ys - 1,
+                                        0, 23040);
+                       }
+               } else
+                       (void) XPutImage(display, window, gc,
+                                        &logo[bitmap], 0, 0,
+                               wp->xb + wp->xs * col, wp->yb + wp->ys * row,
+                                        icon_width, icon_height);
+       } else {                /* TRI */
+               int         orient = (col + row) % 2;   /* O left 1 right */
+
+               wp->shape.triangle[orient][0].x = wp->xb + col * wp->xs;
+               wp->shape.triangle[orient][0].y = wp->yb + row * wp->ys;
+               if (wp->xs <= 3 || wp->ys <= 3)
+                       XDrawPoint(display, window, gc,
+                       ((orient) ? -1 : 1) + wp->shape.triangle[orient][0].x,
+                                      wp->shape.triangle[orient][0].y);
+               else {
+                       if (orient)
+                               wp->shape.triangle[orient][0].x += (wp->xs / 2 - 1);
+                       else
+                               wp->shape.triangle[orient][0].x -= (wp->xs / 2 - 1);
+                       if (bitmap >= KINDBITMAPS || !alive)
+                               XFillPolygon(display, window, gc,
+                                            wp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+                       else {
+                               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+                               XFillPolygon(display, window, gc,
+                                            wp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+                               XSetForeground(display, gc, colour);
+                               XFillArc(display, window, gc,
+                                    wp->xb + wp->xs * col - 4 * wp->xs / 5 +
+                                   ((orient) ? wp->xs / 3 : 3 * wp->xs / 5),
+                                        wp->yb + wp->ys * row - wp->ys / 2 + 1, wp->ys - 3, wp->ys - 3,
+                                        0, 23040);
+                       }
+               }
+       }
+}
+
+static void
+init_kindlist(watorstruct * wp, int kind)
+{
+       /* Waste some space at the beginning and end of list
+          so we do not have to complicated checks against falling off the ends. */
+       wp->lastkind[kind] = (CellList *) malloc(sizeof (CellList));
+       wp->firstkind[kind] = (CellList *) malloc(sizeof (CellList));
+       wp->firstkind[kind]->previous = wp->lastkind[kind]->next = NULL;
+       wp->firstkind[kind]->next = wp->lastkind[kind]->previous = NULL;
+       wp->firstkind[kind]->next = wp->lastkind[kind];
+       wp->lastkind[kind]->previous = wp->firstkind[kind];
+}
+
+static void
+addto_kindlist(watorstruct * wp, int kind, cellstruct info)
+{
+       wp->currkind = (CellList *) malloc(sizeof (CellList));
+       wp->lastkind[kind]->previous->next = wp->currkind;
+       wp->currkind->previous = wp->lastkind[kind]->previous;
+       wp->currkind->next = wp->lastkind[kind];
+       wp->lastkind[kind]->previous = wp->currkind;
+       wp->currkind->info = info;
+}
+
+static void
+removefrom_kindlist(watorstruct * wp, CellList * ptr)
+{
+       ptr->previous->next = ptr->next;
+       ptr->next->previous = ptr->previous;
+       wp->arr[ptr->info.col + ptr->info.row * wp->ncols] = 0;
+       (void) free((void *) ptr);
+}
+
+static void
+dupin_kindlist(watorstruct * wp)
+{
+       CellList   *temp;
+
+       temp = (CellList *) malloc(sizeof (CellList));
+       temp->previous = wp->babykind;
+       temp->next = wp->babykind->next;
+       wp->babykind->next = temp;
+       temp->next->previous = temp;
+       temp->info = wp->babykind->info;
+       wp->babykind = temp;
+}
+
+/*-
+ * new fish at end of list, this rotates who goes first, young fish go last
+ * this most likely will not change the feel to any real degree
+ */
+static void
+cutfrom_kindlist(watorstruct * wp)
+{
+       wp->babykind = wp->currkind;
+       wp->currkind = wp->currkind->previous;
+       wp->currkind->next = wp->babykind->next;
+       wp->babykind->next->previous = wp->currkind;
+       wp->babykind->next = wp->lastkind[KINDS];
+       wp->babykind->previous = wp->lastkind[KINDS]->previous;
+       wp->babykind->previous->next = wp->babykind;
+       wp->babykind->next->previous = wp->babykind;
+}
+
+static void
+reattach_kindlist(watorstruct * wp, int kind)
+{
+       wp->currkind = wp->lastkind[kind]->previous;
+       wp->currkind->next = wp->firstkind[KINDS]->next;
+       wp->currkind->next->previous = wp->currkind;
+       wp->lastkind[kind]->previous = wp->lastkind[KINDS]->previous;
+       wp->lastkind[KINDS]->previous->next = wp->lastkind[kind];
+       wp->lastkind[KINDS]->previous = wp->firstkind[KINDS];
+       wp->firstkind[KINDS]->next = wp->lastkind[KINDS];
+}
+
+static void
+flush_kindlist(watorstruct * wp, int kind)
+{
+       while (wp->lastkind[kind]->previous != wp->firstkind[kind]) {
+               wp->currkind = wp->lastkind[kind]->previous;
+               wp->currkind->previous->next = wp->lastkind[kind];
+               wp->lastkind[kind]->previous = wp->currkind->previous;
+               /* wp->arr[wp->currkind->info.col + wp->currkind->info.row * wp->ncols] = 0; */
+               (void) free((void *) wp->currkind);
+       }
+}
+
+static int
+neighbor_position(watorstruct * wp, int col, int row, int dir)
+{
+       if (wp->neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                               break;
+                       case 60:
+                               if (!(row & 1))
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                               row = (!row) ? wp->nrows - 1 : row - 1;
+                               break;
+                       case 120:
+                               if (row & 1)
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                               row = (!row) ? wp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? wp->ncols - 1 : col - 1;
+                               break;
+                       case 240:
+                               if (row & 1)
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                               row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                               break;
+                       case 300:
+                               if (!(row & 1))
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else if (wp->neighbors == 4 || wp->neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                               break;
+                       case 45:
+                               col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                               row = (!row) ? wp->nrows - 1 : row - 1;
+                               break;
+                       case 90:
+                               row = (!row) ? wp->nrows - 1 : row - 1;
+                               break;
+                       case 135:
+                               col = (!col) ? wp->ncols - 1 : col - 1;
+                               row = (!row) ? wp->nrows - 1 : row - 1;
+                               break;
+                       case 180:
+                               col = (!col) ? wp->ncols - 1 : col - 1;
+                               break;
+                       case 225:
+                               col = (!col) ? wp->ncols - 1 : col - 1;
+                               row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                               break;
+                       case 270:
+                               row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                               break;
+                       case 315:
+                               col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                               row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {                /* TRI */
+               if ((col + row) % 2) {  /* right */
+                       switch (dir) {
+                               case 0:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 60:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       if (row + 1 == wp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == wp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (row + 1 == wp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == wp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 120:
+                                       row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 180:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? wp->nrows - 1 : row - 1;
+                                       break;
+                               case 240:
+                                       row = (!row) ? wp->nrows - 1 : row - 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (!row)
+                                               row = wp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = wp->nrows - 1;
+                                       else
+                                               row = row - 2;
+
+                                       break;
+                               case 300:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       if (!row)
+                                               row = wp->nrows - 2;
+                                       else if (!(row - 1))
+                                               row = wp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       row = (!row) ? wp->nrows - 1 : row - 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               } else {        /* left */
+                       switch (dir) {
+                               case 0:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       row = (!row) ? wp->nrows - 1 : row - 1;
+                                       break;
+                               case 60:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       if (!row)
+                                               row = wp->nrows - 2;
+                                       else if (row == 1)
+                                               row = wp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       if (!row)
+                                               row = wp->nrows - 2;
+                                       else if (row == 1)
+                                               row = wp->nrows - 1;
+                                       else
+                                               row = row - 2;
+                                       break;
+                               case 120:
+                                       row = (!row) ? wp->nrows - 1 : row - 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       row = (!row) ? wp->nrows - 1 : row - 1;
+                                       break;
+                               case 180:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = (!col) ? wp->ncols - 1 : col - 1;
+                                       row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 240:
+                                       row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       if (row + 1 == wp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == wp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 300:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       if (row + 1 == wp->nrows)
+                                               row = 1;
+                                       else if (row + 2 == wp->nrows)
+                                               row = 0;
+                                       else
+                                               row = row + 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = (col + 1 == wp->ncols) ? 0 : col + 1;
+                                       row = (row + 1 == wp->nrows) ? 0 : row + 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               }
+       }
+       return row * wp->ncols + col;
+}
+
+void
+init_wator(ModeInfo * mi)
+{
+       int         size = MI_SIZE(mi);
+       watorstruct *wp;
+       int         i, col, row, colrow, kind;
+       cellstruct  info;
+
+       if (wators == NULL) {
+               if ((wators = (watorstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (watorstruct))) == NULL)
+                       return;
+       }
+       wp = &wators[MI_SCREEN(mi)];
+
+       wp->generation = 0;
+       if (!wp->firstkind[0]) {        /* Genesis */
+               icon_width = fish0_width;
+               icon_height = fish0_height;
+               /* Set up what will be a 'triply' linked list.
+                  doubly linked list, doubly linked to an array */
+               for (kind = FISH; kind <= KINDS; kind++)
+                       init_kindlist(wp, kind);
+               for (i = 0; i < BITMAPS; i++) {
+                       logo[i].width = icon_width;
+                       logo[i].height = icon_height;
+                       logo[i].bytes_per_line = (icon_width + 7) / 8;
+               }
+       } else                  /* Exterminate all  */
+               for (i = FISH; i <= KINDS; i++)
+                       flush_kindlist(wp, i);
+
+       wp->width = MI_WIDTH(mi);
+       wp->height = MI_HEIGHT(mi);
+       if (wp->width < 2)
+               wp->width = 2;
+       if (wp->height < 2)
+               wp->height = 2;
+
+       for (i = 0; i < NEIGHBORKINDS; i++) {
+               if (neighbors == plots[i]) {
+                       wp->neighbors = neighbors;
+                       break;
+               }
+               if (i == NEIGHBORKINDS - 1) {
+#if 0
+                       wp->neighbors = plots[NRAND(NEIGHBORKINDS)];
+                       wp->neighbors = (LRAND() & 1) ? 4 : 8;
+#else
+                       wp->neighbors = 4;
+#endif
+                       break;
+               }
+       }
+
+       if (wp->neighbors == 6) {
+               int         nccols, ncrows, sides;
+
+               if (wp->width < 2)
+                       wp->width = 2;
+               if (wp->height < 4)
+                       wp->height = 4;
+               if (size < -MINSIZE)
+                       wp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               wp->ys = MAX(MINSIZE, MIN(wp->width, wp->height) / MINGRIDSIZE);
+                       else
+                               wp->ys = MINSIZE;
+               } else
+                       wp->ys = MIN(size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                              MINGRIDSIZE));
+               wp->xs = wp->ys;
+               wp->pixelmode = True;
+               nccols = MAX(wp->width / wp->xs - 2, 2);
+               ncrows = MAX(wp->height / wp->ys - 1, 2);
+               wp->ncols = nccols / 2;
+               wp->nrows = 2 * (ncrows / 4);
+               wp->xb = (wp->width - wp->xs * nccols) / 2 + wp->xs / 2;
+               wp->yb = (wp->height - wp->ys * (ncrows / 2) * 2) / 2 + wp->ys;
+               for (sides = 0; sides < 6; sides++) {
+                       wp->shape.hexagon[sides].x = (wp->xs - 1) * hexagonUnit[sides].x;
+                       wp->shape.hexagon[sides].y =
+                               ((wp->ys - 1) * hexagonUnit[sides].y / 2) * 4 / 3;
+               }
+       } else if (wp->neighbors == 4 || wp->neighbors == 8) {
+               if (wp->width < 2)
+                       wp->width = 2;
+               if (wp->height < 2)
+                       wp->height = 2;
+               if (size == 0 ||
+                   MINGRIDSIZE * size > wp->width || MINGRIDSIZE * size > wp->height) {
+                       if (wp->width > MINGRIDSIZE * icon_width &&
+                           wp->height > MINGRIDSIZE * icon_height) {
+                               wp->pixelmode = False;
+                               wp->xs = icon_width;
+                               wp->ys = icon_height;
+                       } else {
+                               wp->pixelmode = True;
+                               wp->xs = wp->ys = MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                                     MINGRIDSIZE);
+                       }
+               } else {
+                       wp->pixelmode = True;
+                       if (size < -MINSIZE)
+                               wp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+                       else if (size < MINSIZE)
+                               wp->ys = MINSIZE;
+                       else
+                               wp->ys = MIN(size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                                      MINGRIDSIZE));
+                       wp->xs = wp->ys;
+               }
+               wp->ncols = MAX(wp->width / wp->xs, 2);
+               wp->nrows = MAX(wp->height / wp->ys, 2);
+               wp->xb = (wp->width - wp->xs * wp->ncols) / 2;
+               wp->yb = (wp->height - wp->ys * wp->nrows) / 2;
+       } else {                /* TRI */
+               int         orient, sides;
+
+               if (wp->width < 2)
+                       wp->width = 2;
+               if (wp->height < 2)
+                       wp->height = 2;
+               if (size < -MINSIZE)
+                       wp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               wp->ys = MAX(MINSIZE, MIN(wp->width, wp->height) / MINGRIDSIZE);
+                       else
+                               wp->ys = MINSIZE;
+               } else
+                       wp->ys = MIN(size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                              MINGRIDSIZE));
+               wp->xs = (int) (1.52 * wp->ys);
+               wp->pixelmode = True;
+               wp->ncols = (MAX(wp->width / wp->xs - 1, 2) / 2) * 2;
+               wp->nrows = (MAX(wp->height / wp->ys - 1, 2) / 2) * 2;
+               wp->xb = (wp->width - wp->xs * wp->ncols) / 2 + wp->xs / 2;
+               wp->yb = (wp->height - wp->ys * wp->nrows) / 2 + wp->ys / 2;
+               for (orient = 0; orient < 2; orient++) {
+                       for (sides = 0; sides < 3; sides++) {
+                               wp->shape.triangle[orient][sides].x =
+                                       (wp->xs - 2) * triangleUnit[orient][sides].x;
+                               wp->shape.triangle[orient][sides].y =
+                                       (wp->ys - 2) * triangleUnit[orient][sides].y;
+                       }
+               }
+       }
+
+       wp->positions = wp->ncols * wp->nrows;
+
+       if (wp->arr != NULL)
+               (void) free((void *) wp->arr);
+       wp->arr = (CellList **) calloc(wp->positions, sizeof (CellList *));
+
+       /* Play G-d with these numbers */
+       wp->nkind[FISH] = wp->positions / 3;
+       wp->nkind[SHARK] = wp->nkind[FISH] / 10;
+       wp->kind = FISH;
+       if (!wp->nkind[SHARK])
+               wp->nkind[SHARK] = 1;
+       wp->breed[FISH] = MI_COUNT(mi);
+       wp->breed[SHARK] = 10;
+       if (wp->breed[FISH] < 1)
+               wp->breed[FISH] = 1;
+       else if (wp->breed[FISH] > wp->breed[SHARK])
+               wp->breed[FISH] = 4;
+       wp->sstarve = 3;
+
+       MI_CLEARWINDOW(mi);
+       wp->painted = False;
+
+       for (kind = FISH; kind <= SHARK; kind++) {
+               i = 0;
+               while (i < wp->nkind[kind]) {
+                       col = NRAND(wp->ncols);
+                       row = NRAND(wp->nrows);
+                       colrow = col + row * wp->ncols;
+                       if (!wp->arr[colrow]) {
+                               i++;
+                               info.kind = kind;
+                               info.age = NRAND(wp->breed[kind]);
+                               info.food = NRAND(wp->sstarve);
+                               info.direction = NRAND(KINDBITMAPS) + kind * KINDBITMAPS;
+                               if (MI_NPIXELS(mi) > 2)
+                                       info.color = NRAND(MI_NPIXELS(mi));
+                               else
+                                       info.color = 0;
+                               info.col = col;
+                               info.row = row;
+                               addto_kindlist(wp, kind, info);
+                               wp->arr[colrow] = wp->currkind;
+                               drawcell(mi, col, row,
+                                        wp->currkind->info.color, wp->currkind->info.direction, True);
+                       }
+               }
+       }
+}
+
+void
+draw_wator(ModeInfo * mi)
+{
+       watorstruct *wp = &wators[MI_SCREEN(mi)];
+       int         col, row;
+       int         colrow, cr, position;
+       int         i, numok;
+
+       struct {
+               int         pos, dir;
+       } acell[12];
+
+
+       MI_IS_DRAWN(mi) = True;
+
+       wp->painted = True;
+       /* Alternate updates, fish and sharks live out of phase with each other */
+       wp->kind = (wp->kind + 1) % KINDS;
+       {
+               wp->currkind = wp->firstkind[wp->kind]->next;
+
+               while (wp->currkind != wp->lastkind[wp->kind]) {
+                       col = wp->currkind->info.col;
+                       row = wp->currkind->info.row;
+                       colrow = col + row * wp->ncols;
+                       numok = 0;
+                       if (wp->kind == SHARK) {        /* Scan for fish */
+                               for (i = 0; i < wp->neighbors; i++) {
+                                       position = neighbor_position(wp, col, row, i * 360 / wp->neighbors);
+                                       if (wp->arr[position] && wp->arr[position]->info.kind == FISH) {
+                                               acell[numok].pos = position;
+                                               acell[numok++].dir = i;
+                                       }
+                               }
+                               if (numok) {    /* No thanks, I'm a vegetarian */
+                                       i = NRAND(numok);
+                                       wp->nkind[FISH]--;
+                                       cr = acell[i].pos;
+                                       removefrom_kindlist(wp, wp->arr[cr]);
+                                       wp->arr[cr] = wp->currkind;
+                                       if (wp->neighbors == 4) {
+                                               wp->currkind->info.direction = (5 - acell[i].dir) % ORIENTS +
+                                                       ((NRAND(REFLECTS)) ? 0 : ORIENTS) + wp->kind * KINDBITMAPS;
+                                       } else if (wp->neighbors == 8) {
+                                               wp->currkind->info.direction = (char) (5 - (acell[i].dir / 2 +
+                                                                                           ((acell[i].dir % 2) ? LRAND() & 1 : 0))) % ORIENTS +
+                                                       ((NRAND(REFLECTS)) ? 0 : ORIENTS) + wp->kind * KINDBITMAPS;
+                                       } else
+                                               wp->currkind->info.direction = wp->kind * KINDBITMAPS;
+                                       wp->currkind->info.col = acell[i].pos % wp->ncols;
+                                       wp->currkind->info.row = acell[i].pos / wp->ncols;
+                                       wp->currkind->info.food = wp->sstarve;
+                                       drawcell(mi, wp->currkind->info.col, wp->currkind->info.row,
+                                                wp->currkind->info.color, wp->currkind->info.direction, True);
+                                       if (++(wp->currkind->info.age) >= wp->breed[wp->kind]) {        /* breed */
+                                               cutfrom_kindlist(wp);   /* This rotates out who goes first */
+                                               wp->babykind->info.age = 0;
+                                               dupin_kindlist(wp);
+                                               wp->arr[colrow] = wp->babykind;
+                                               wp->babykind->info.col = col;
+                                               wp->babykind->info.row = row;
+                                               wp->babykind->info.age = -1;    /* Make one a little younger */
+#if 0
+                                               if (MI_NPIXELS(mi) > 2 && (LRAND() & 1))
+                                                       /* A color mutation */
+                                                       if (++(wp->babykind->info.color) >= MI_NPIXELS(mi))
+                                                               wp->babykind->info.color = 0;
+#endif
+                                               wp->nkind[wp->kind]++;
+                                       } else {
+                                               wp->arr[colrow] = 0;
+                                               drawcell(mi, col, row, 0, 0, False);
+                                       }
+                               } else {
+                                       if (wp->currkind->info.food-- < 0) {    /* Time to die, Jaws */
+                                               /* back up one or else in void */
+                                               wp->currkind = wp->currkind->previous;
+                                               removefrom_kindlist(wp, wp->arr[colrow]);
+                                               wp->arr[colrow] = 0;
+                                               drawcell(mi, col, row, 0, 0, False);
+                                               wp->nkind[wp->kind]--;
+                                               numok = -1;     /* Want to escape from next if */
+                                       }
+                               }
+                       }
+                       if (!numok) {   /* Fish or shark search for a place to go */
+                               for (i = 0; i < wp->neighbors; i++) {
+                                       position = neighbor_position(wp, col, row, i * 360 / wp->neighbors);
+                                       if (!wp->arr[position]) {       /* Found an empty spot */
+                                               acell[numok].pos = position;
+                                               acell[numok++].dir = i;
+                                       }
+                               }
+                               if (numok) {    /* Found a place to go */
+                                       i = NRAND(numok);
+                                       wp->arr[acell[i].pos] = wp->currkind;
+                                       if (wp->neighbors == 4) {
+                                               wp->currkind->info.direction = (5 - acell[i].dir) % ORIENTS +
+                                                       ((NRAND(REFLECTS)) ? 0 : ORIENTS) + wp->kind * KINDBITMAPS;
+                                       } else if (wp->neighbors == 8) {
+                                               wp->currkind->info.direction = (char) (5 - (acell[i].dir / 2 +
+                                                                                           ((acell[i].dir % 2) ? LRAND() & 1 : 0))) % ORIENTS +
+                                                       ((NRAND(REFLECTS)) ? 0 : ORIENTS) + wp->kind * KINDBITMAPS;
+                                       } else
+                                               wp->currkind->info.direction = wp->kind * KINDBITMAPS;
+                                       wp->currkind->info.col = acell[i].pos % wp->ncols;
+                                       wp->currkind->info.row = acell[i].pos / wp->ncols;
+                                       drawcell(mi,
+                                                wp->currkind->info.col, wp->currkind->info.row,
+                                                wp->currkind->info.color, wp->currkind->info.direction, True);
+                                       if (++(wp->currkind->info.age) >= wp->breed[wp->kind]) {        /* breed */
+                                               cutfrom_kindlist(wp);   /* This rotates out who goes first */
+                                               wp->babykind->info.age = 0;
+                                               dupin_kindlist(wp);
+                                               wp->arr[colrow] = wp->babykind;
+                                               wp->babykind->info.col = col;
+                                               wp->babykind->info.row = row;
+                                               wp->babykind->info.age = -1;    /* Make one a little younger */
+                                               wp->nkind[wp->kind]++;
+                                       } else {
+                                               wp->arr[colrow] = 0;
+                                               drawcell(mi, col, row, 0, 0, False);
+                                       }
+                               } else {
+                                       /* I'll just sit here and wave my tail so you know I am alive */
+                                       wp->currkind->info.direction =
+                                               (wp->currkind->info.direction + ORIENTS) % KINDBITMAPS +
+                                               wp->kind * KINDBITMAPS;
+                                       drawcell(mi, col, row, wp->currkind->info.color,
+                                        wp->currkind->info.direction, True);
+                               }
+                       }
+                       wp->currkind = wp->currkind->next;
+               }
+               reattach_kindlist(wp, wp->kind);
+       }
+
+       if ((wp->nkind[FISH] >= wp->positions) ||
+           (!wp->nkind[FISH] && !wp->nkind[SHARK]) ||
+           wp->generation >= MI_CYCLES(mi)) {
+               init_wator(mi);
+       }
+       if (wp->kind == SHARK)
+               wp->generation++;
+}
+
+void
+release_wator(ModeInfo * mi)
+{
+       if (wators != NULL) {
+               int         screen, kind;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       watorstruct *wp = &wators[screen];
+
+                       for (kind = 0; kind <= KINDS; kind++) {
+                               if (wp->firstkind[0])
+                                       flush_kindlist(wp, kind);
+                               if (wp->lastkind[kind])
+                                       (void) free((void *) wp->lastkind[kind]);
+                               if (wp->firstkind[kind])
+                                       (void) free((void *) wp->firstkind[kind]);
+                       }
+                       if (wp->arr != NULL)
+                               (void) free((void *) wp->arr);
+               }
+               (void) free((void *) wators);
+               wators = NULL;
+       }
+}
+
+void
+refresh_wator(ModeInfo * mi)
+{
+       watorstruct *wp = &wators[MI_SCREEN(mi)];
+
+       if (wp->painted) {
+               MI_CLEARWINDOW(mi);
+               wp->painted = False;
+       }
+}
+
+#endif /* MODE_wator */
diff --git a/xlockmore-4.14/modes/wire.c b/xlockmore-4.14/modes/wire.c
new file mode 100644 (file)
index 0000000..482a185
--- /dev/null
@@ -0,0 +1,992 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* wire --- logical circuits based on simple state-changes (wireworld) */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)wire.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1996 by David Bagley.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 05-Dec-97: neighbors option added. 
+ * 10-May-97: Compatible with xscreensaver
+ * 14-Jun-96: Coded from A.K. Dewdney's "Computer Recreations", Scientific
+ *            American Magazine" Jan 1990 pp 146-148.  Used ant.c as an
+ *            example.  do_gen() based on code by Kevin Dahlhausen
+ *            <ap096@po.cwru.edu> and Stefan Strack
+ *            <stst@vuse.vanderbilt.edu>.
+ */
+
+/*-
+ * OR gate is protected by diodes
+ *           XX     XX
+ * Input ->XXX XX XX XXX<- Input
+ *           XX  X  XX
+ *               X
+ *               X
+ *               |
+ *               V
+ *             Output
+ *
+ *   ->XXXoOXXX-> Electron moving in a wire
+ *
+ * memory element, about to forget 1 and remember 0
+ *         Remember 0
+ *             o
+ *            X O XX XX   Memory Loop
+ *            X  XX X XXXX
+ *            X   XX XX   X oOX-> 1 Output
+ * Inputs ->XX        X    X
+ *                X   X XX o
+ * Inputs ->XXXXXXX XX X XO Memory of 1
+ *                XX    XX
+ *         Remember 1
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Wire"
+#define HACK_INIT init_wire
+#define HACK_DRAW draw_wire
+#define wire_opts xlockmore_opts
+#define DEFAULTS "*delay: 500000 \n" \
+ "*count: 1000 \n" \
+ "*cycles: 150 \n" \
+ "*size: -8 \n" \
+ "*ncolors: 64 \n" \
+ "*neighbors: 0 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+#include "automata.h"
+
+#ifdef MODE_wire
+
+/*-
+ * neighbors of 0 randomizes it between 3, 4, 6, 8, 9, and 12.
+ */
+#define DEF_NEIGHBORS  "0"      /* choose random value */
+
+static int  neighbors;
+
+static XrmOptionDescRec opts[] =
+{
+       {"-neighbors", ".wire.neighbors", XrmoptionSepArg, (caddr_t) NULL}
+};
+
+static argtype vars[] =
+{
+       {(caddr_t *) & neighbors, "neighbors", "Neighbors", DEF_NEIGHBORS, t_Int
+}
+};
+static OptionStruct desc[] =
+{
+       {"-neighbors num", "squares 4 or 8, hexagons 6, triangles 3, 9 or 12"}
+};
+
+ModeSpecOpt wire_opts =
+{sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0], vars, desc};
+
+#ifdef USE_MODULES
+ModStruct   wire_description =
+{"wire", "init_wire", "draw_wire", "release_wire",
+ "refresh_wire", "init_wire", NULL, &wire_opts,
+ 500000, 1000, 150, -8, 64, 1.0, "",
+ "Shows a random circuit with 2 electrons", 0, NULL};
+
+#endif
+
+#define WIREBITS(n,w,h)\
+  wp->pixmaps[wp->init_bits++]=\
+  XCreatePixmapFromBitmapData(display,window,(char *)n,w,h,1,0,1)
+
+#define COLORS 4
+#define MINWIRES 32
+#define MINGRIDSIZE 24
+#define MINSIZE 3
+#define ANGLES 360
+#define NEIGHBORKINDS 6
+
+#define SPACE 0
+#define WIRE 1                 /* Normal wire */
+#define HEAD 2                 /* electron head */
+#define TAIL 3                 /* electron tail */
+
+#define REDRAWSTEP 2000                /* How much wire to draw per cycle */
+
+/* Singly linked list */
+typedef struct _CellList {
+       XPoint      pt;
+       struct _CellList *next;
+} CellList;
+
+typedef struct {
+       int         init_bits;
+       int         neighbors;
+       int         generation;
+       int         xs, ys;
+       int         xb, yb;
+       int         nrows, ncols;
+       int         bnrows, bncols;
+       int         mincol, minrow, maxcol, maxrow;
+       int         width, height;
+       int         redrawing, redrawpos;
+       unsigned char *oldcells, *newcells;
+       int         ncells[COLORS - 1];
+       CellList   *cellList[COLORS - 1];
+       unsigned char colors[COLORS - 1];
+       GC          stippledGC;
+       Pixmap      pixmaps[COLORS - 1];
+       int         prob_array[12];
+       union {
+               XPoint      hexagon[6];
+               XPoint      triangle[2][3];
+       } shape;
+} circuitstruct;
+
+static char plots[NEIGHBORKINDS] =
+{3, 4, 6, 8, 9, 12};           /* Neighborhoods */
+
+static circuitstruct *circuits = NULL;
+
+static void
+position_of_neighbor(circuitstruct * wp, int dir, int *pcol, int *prow)
+{
+       int         col = *pcol, row = *prow;
+
+       /* NO WRAPING */
+
+       if (wp->neighbors == 6) {
+               switch (dir) {
+                       case 0:
+                               col = col + 1;
+                               break;
+                       case 60:
+                               if (!(row & 1))
+                                       col = col + 1;
+                               row = row - 1;
+                               break;
+                       case 120:
+                               if (row & 1)
+                                       col = col - 1;
+                               row = row - 1;
+                               break;
+                       case 180:
+                               col = col - 1;
+                               break;
+                       case 240:
+                               if (row & 1)
+                                       col = col - 1;
+                               row = row + 1;
+                               break;
+                       case 300:
+                               if (!(row & 1))
+                                       col = col + 1;
+                               row = row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else if (wp->neighbors == 4 || wp->neighbors == 8) {
+               switch (dir) {
+                       case 0:
+                               col = col + 1;
+                               break;
+                       case 45:
+                               col = col + 1;
+                               row = row - 1;
+                               break;
+                       case 90:
+                               row = row - 1;
+                               break;
+                       case 135:
+                               col = col - 1;
+                               row = row - 1;
+                               break;
+                       case 180:
+                               col = col - 1;
+                               break;
+                       case 225:
+                               col = col - 1;
+                               row = row + 1;
+                               break;
+                       case 270:
+                               row = row + 1;
+                               break;
+                       case 315:
+                               col = col + 1;
+                               row = row + 1;
+                               break;
+                       default:
+                               (void) fprintf(stderr, "wrong direction %d\n", dir);
+               }
+       } else {                /* TRI */
+               if ((col + row) % 2) {  /* right */
+                       switch (dir) {
+                               case 0:
+                                       col = col - 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = col - 1;
+                                       row = row - 1;
+                                       break;
+                               case 60:
+                                       col = col - 1;
+                                       row = row - 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       row = row - 2;
+                                       break;
+                               case 120:
+                                       row = row - 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = col + 1;
+                                       row = row - 1;
+                                       break;
+                               case 180:
+                                       col = col + 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = col + 1;
+                                       row = row + 1;
+                                       break;
+                               case 240:
+                                       row = row + 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       row = row + 2;
+                                       break;
+                               case 300:
+                                       col = col - 1;
+                                       row = row + 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = col - 1;
+                                       row = row + 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               } else {        /* left */
+                       switch (dir) {
+                               case 0:
+                                       col = col + 1;
+                                       break;
+                               case 30:
+                               case 40:
+                                       col = col + 1;
+                                       row = row + 1;
+                                       break;
+                               case 60:
+                                       col = col + 1;
+                                       row = row + 2;
+                                       break;
+                               case 80:
+                               case 90:
+                                       row = row + 2;
+                                       break;
+                               case 120:
+                                       row = row + 1;
+                                       break;
+                               case 150:
+                               case 160:
+                                       col = col - 1;
+                                       row = row + 1;
+                                       break;
+                               case 180:
+                                       col = col - 1;
+                                       break;
+                               case 200:
+                               case 210:
+                                       col = col - 1;
+                                       row = row - 1;
+                                       break;
+                               case 240:
+                                       row = row - 1;
+                                       break;
+                               case 270:
+                               case 280:
+                                       row = row - 2;
+                                       break;
+                               case 300:
+                                       col = col + 1;
+                                       row = row - 2;
+                                       break;
+                               case 320:
+                               case 330:
+                                       col = col + 1;
+                                       row = row - 1;
+                                       break;
+                               default:
+                                       (void) fprintf(stderr, "wrong direction %d\n", dir);
+                       }
+               }
+       }
+       *pcol = col;
+       *prow = row;
+}
+
+static      Bool
+withinBounds(circuitstruct * wp, int col, int row)
+{
+       return (row >= 2 && row < wp->bnrows - 2 &&
+               col >= 2 && col < wp->bncols - 2 - (wp->neighbors == 6 && !(row % 2)));
+}
+
+static void
+fillcell(ModeInfo * mi, GC gc, int col, int row)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+
+       if (wp->neighbors == 6) {
+               int         ccol = 2 * col + !(row & 1), crow = 2 * row;
+
+               wp->shape.hexagon[0].x = wp->xb + ccol * wp->xs;
+               wp->shape.hexagon[0].y = wp->yb + crow * wp->ys;
+               if (wp->xs == 1 && wp->ys == 1)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                       wp->shape.hexagon[0].x, wp->shape.hexagon[0].y);
+               else
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                           wp->shape.hexagon, 6, Convex, CoordModePrevious);
+       } else if (wp->neighbors == 4 || wp->neighbors == 8) {
+               XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+               wp->xb + wp->xs * col, wp->yb + wp->ys * row,
+               wp->xs - (wp->xs > 3), wp->ys - (wp->ys > 3));
+       } else {                /* TRI */
+               int         orient = (col + row) % 2;   /* O left 1 right */
+
+               wp->shape.triangle[orient][0].x = wp->xb + col * wp->xs;
+               wp->shape.triangle[orient][0].y = wp->yb + row * wp->ys;
+               if (wp->xs <= 3 || wp->ys <= 3)
+                       XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                       ((orient) ? -1 : 1) + wp->shape.triangle[orient][0].x,
+                                      wp->shape.triangle[orient][0].y);
+               else {
+                       if (orient)
+                               wp->shape.triangle[orient][0].x += (wp->xs / 2 - 1);
+                       else
+                               wp->shape.triangle[orient][0].x -= (wp->xs / 2 - 1);
+                       XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                    wp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+               }
+       }
+}
+
+static void
+drawcell(ModeInfo * mi, int col, int row, unsigned char state)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+       GC          gc;
+
+       if (MI_NPIXELS(mi) > 2) {
+               gc = MI_GC(mi);
+               XSetForeground(MI_DISPLAY(mi), gc, MI_PIXEL(mi, wp->colors[state]));
+       } else {
+               XGCValues   gcv;
+
+               gcv.stipple = wp->pixmaps[state];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), wp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = wp->stippledGC;
+       }
+       fillcell(mi, gc, col, row);
+}
+
+#if 0
+static void
+drawcell_notused(ModeInfo * mi, int col, int row, unsigned char state)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+       XGCValues   gcv;
+       GC          gc;
+
+       if (MI_NPIXELS(mi) > 2) {
+               gc = MI_GC(mi);
+               XSetForeground(MI_DISPLAY(mi), gc, MI_PIXEL(mi, wp->colors[state]));
+       } else {
+               gcv.stipple = wp->pixmaps[state];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), wp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = wp->stippledGC;
+       }
+       XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi),
+              wp->xb + wp->xs * col, wp->yb + wp->ys * row,
+               wp->xs - (wp->xs > 3), wp->ys - (wp->ys > 3));
+}
+#endif
+
+static void
+addtolist(ModeInfo * mi, int col, int row, unsigned char state)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+       CellList   *current = wp->cellList[state];
+
+       wp->cellList[state] = NULL;
+       if ((wp->cellList[state] = (CellList *) malloc(sizeof (CellList))) == NULL) {
+               wp->cellList[state] = current;
+               return;
+       }
+       wp->cellList[state]->pt.x = col;
+       wp->cellList[state]->pt.y = row;
+       wp->cellList[state]->next = current;
+       wp->ncells[state]++;
+}
+
+#ifdef DEBUG
+static void
+print_state(ModeInfo * mi, int state)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+       CellList   *locallist = wp->cellList[state];
+       int         i = 0;
+
+       (void) printf("state %d\n", state);
+       while (locallist) {
+               (void) printf("%d x %d, y %d\n", i,
+                             locallist->pt.x, locallist->pt.y);
+               locallist = locallist->next;
+               i++;
+       }
+}
+
+#endif
+
+static void
+free_state(circuitstruct * wp, int state)
+{
+       CellList   *current;
+
+       while (wp->cellList[state]) {
+               current = wp->cellList[state];
+               wp->cellList[state] = wp->cellList[state]->next;
+               (void) free((void *) current);
+       }
+       wp->ncells[state] = 0;
+}
+
+static void
+draw_state(ModeInfo * mi, int state)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+       GC          gc;
+       XGCValues   gcv;
+       CellList   *current = wp->cellList[state];
+
+       if (MI_NPIXELS(mi) > 2) {
+               gc = MI_GC(mi);
+               XSetForeground(MI_DISPLAY(mi), gc, MI_PIXEL(mi, wp->colors[state]));
+       } else {
+               gcv.stipple = wp->pixmaps[state];
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               XChangeGC(MI_DISPLAY(mi), wp->stippledGC,
+                         GCStipple | GCForeground | GCBackground, &gcv);
+               gc = wp->stippledGC;
+       }
+
+       if (wp->neighbors == 6) {       /* Draw right away, slow */
+               while (current) {
+                       int         col, row, ccol, crow;
+
+                       col = current->pt.x;
+                       row = current->pt.y;
+                       ccol = 2 * col + !(row & 1), crow = 2 * row;
+                       wp->shape.hexagon[0].x = wp->xb + ccol * wp->xs;
+                       wp->shape.hexagon[0].y = wp->yb + crow * wp->ys;
+                       if (wp->xs == 1 && wp->ys == 1)
+                               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi),
+                                              gc, wp->shape.hexagon[0].x, wp->shape.hexagon[0].y);
+                       else
+                               XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                            wp->shape.hexagon, 6, Convex, CoordModePrevious);
+                       current = current->next;
+               }
+       } else if (wp->neighbors == 4 || wp->neighbors == 8) {
+               XRectangle *rects = NULL;
+               /* Take advantage of XFillRectangles */
+               int         nrects = 0;
+
+               /* Create Rectangle list from part of the cellList */
+               if ((rects = (XRectangle *) malloc(wp->ncells[state] * sizeof (XRectangle))) == NULL) {
+                       return;
+    }
+
+               while (current) {
+                       rects[nrects].x = wp->xb + current->pt.x * wp->xs;
+                       rects[nrects].y = wp->yb + current->pt.y * wp->ys;
+                       rects[nrects].width = wp->xs - (wp->xs > 3);
+                       rects[nrects].height = wp->ys - (wp->ys > 3);
+                       current = current->next;
+                       nrects++;
+               }
+               /* Finally get to draw */
+               XFillRectangles(MI_DISPLAY(mi), MI_WINDOW(mi), gc, rects, nrects);
+               /* Free up rects list and the appropriate part of the cellList */
+               (void) free((void *) rects);
+       } else {                /* TRI */
+               while (current) {
+                       int         col, row, orient;
+
+                       col = current->pt.x;
+                       row = current->pt.y;
+                       orient = (col + row) % 2;       /* O left 1 right */
+                       wp->shape.triangle[orient][0].x = wp->xb + col * wp->xs;
+                       wp->shape.triangle[orient][0].y = wp->yb + row * wp->ys;
+                       if (wp->xs <= 3 || wp->ys <= 3)
+                               XDrawPoint(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                              ((orient) ? -1 : 1) + wp->shape.triangle[orient][0].x,
+                                     wp->shape.triangle[orient][0].y);
+                       else {
+                               if (orient)
+                                       wp->shape.triangle[orient][0].x += (wp->xs / 2 - 1);
+                               else
+                                       wp->shape.triangle[orient][0].x -= (wp->xs / 2 - 1);
+                               XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc,
+                                            wp->shape.triangle[orient], 3, Convex, CoordModePrevious);
+                       }
+                       current = current->next;
+               }
+       }
+       free_state(wp, state);
+       XFlush(MI_DISPLAY(mi));
+}
+
+#if 0
+static void
+RandomSoup(circuitstruct * wp)
+{
+       int         i, j;
+
+       for (j = 2; j < wp->bnrows - 2; j++)
+               for (i = 2; i < wp->bncols - 2; i++) {
+                       *(wp->newcells + i + j * wp->bncols) =
+                               (NRAND(100) > wp->n) ? SPACE : (NRAND(4)) ? WIRE : (NRAND(2)) ?
+                               HEAD : TAIL;
+               }
+}
+
+#endif
+
+static void
+create_path(circuitstruct * wp, int n)
+{
+       int         col, row;
+       int         count = 0;
+       int         dir, prob;
+       int         nextcol = 0, nextrow = 0, i;
+
+#ifdef RANDOMSTART
+       /* Path usually "mushed" in a corner */
+       col = NRAND(wp->ncols) + 1;
+       row = NRAND(wp->nrows) + 1;
+#else
+       /* Start from center */
+       col = wp->ncols / 2;
+       row = wp->nrows / 2;
+#endif
+       wp->mincol = col - 1, wp->minrow = row - 2;
+       wp->maxcol = col + 1, wp->maxrow = row + 2;
+       dir = NRAND(wp->neighbors) * ANGLES / wp->neighbors;
+       *(wp->newcells + col + row * wp->bncols) = HEAD;
+       while (++count < n) {
+               prob = NRAND(wp->prob_array[wp->neighbors - 1]);
+               i = 0;
+               while (prob > wp->prob_array[i])
+                       i++;
+               dir = ((dir * wp->neighbors / ANGLES + i) %
+                      wp->neighbors) * ANGLES / wp->neighbors;
+               nextcol = col;
+               nextrow = row;
+               position_of_neighbor(wp, dir, &nextcol, &nextrow);
+               if (withinBounds(wp, nextcol, nextrow)) {
+                       col = nextcol;
+                       row = nextrow;
+                       if (col == wp->mincol && col > 2)
+                               wp->mincol--;
+                       if (row == wp->minrow && row > 2)
+                               wp->minrow--;
+                       else if (row == wp->minrow - 1 && row > 3)
+                               wp->minrow -= 2;
+                       if (col == wp->maxcol && col < wp->bncols - 3)
+                               wp->maxcol++;
+                       if (row == wp->maxrow && row < wp->bnrows - 3)
+                               wp->maxrow++;
+                       else if (row == wp->maxrow + 1 && row < wp->bnrows - 4)
+                               wp->maxrow += 2;
+
+                       if (!*(wp->newcells + col + row * wp->bncols))
+                               *(wp->newcells + col + row * wp->bncols) = WIRE;
+               } else {
+                       if (wp->neighbors == 3)
+                               break;  /* There is no reverse step */
+                       dir = ((dir * wp->neighbors / ANGLES + wp->neighbors / 2) %
+                              wp->neighbors) * ANGLES / wp->neighbors;
+               }
+       }
+       *(wp->newcells + col + row * wp->bncols) = HEAD;
+}
+
+static void
+do_gen(circuitstruct * wp)
+{
+       int         i, j, k;
+       unsigned char *z;
+       int         count;
+
+#define LOC(X, Y) (*(wp->oldcells + (X) + ((Y) * wp->bncols)))
+#define ADD(X, Y) if (LOC((X), (Y)) == HEAD) count++
+
+       for (j = wp->minrow; j <= wp->maxrow; j++) {
+               for (i = wp->mincol; i <= wp->maxcol; i++) {
+                       z = wp->newcells + i + j * wp->bncols;
+                       switch (LOC(i, j)) {
+                               case SPACE:
+                                       *z = SPACE;
+                                       break;
+                               case TAIL:
+                                       *z = WIRE;
+                                       break;
+                               case HEAD:
+                                       *z = TAIL;
+                                       break;
+                               case WIRE:
+                                       count = 0;
+                                       for (k = 0; k < wp->neighbors; k++) {
+                                               int         newi = i, newj = j;
+
+                                               position_of_neighbor(wp, k * ANGLES / wp->neighbors, &newi, &newj);
+                                               ADD(newi, newj);
+                                       }
+                                       if (count == 1 || count == 2)
+                                               *z = HEAD;
+                                       else
+                                               *z = WIRE;
+                                       break;
+                               default:
+                                       {
+                                               (void) fprintf(stderr,
+                                                              "bad internal character %d at %d,%d\n",
+                                                     (int) LOC(i, j), i, j);
+                                       }
+                       }
+               }
+       }
+}
+
+static void
+free_list(circuitstruct * wp)
+{
+       int         state;
+
+       for (state = 0; state < COLORS - 1; state++)
+               free_state(wp, state);
+}
+
+void
+release_wire(ModeInfo * mi)
+{
+       if (circuits != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       circuitstruct *wp = &circuits[screen];
+                       int         shade;
+
+                       for (shade = 0; shade < wp->init_bits; shade++)
+                               if (wp->pixmaps[shade] != None)
+                                       XFreePixmap(MI_DISPLAY(mi), wp->pixmaps[shade]);
+                       if (wp->stippledGC != None)
+                               XFreeGC(MI_DISPLAY(mi), wp->stippledGC);
+                       if (wp->oldcells != NULL)
+                               (void) free((void *) wp->oldcells);
+                       if (wp->newcells != NULL)
+                               (void) free((void *) wp->newcells);
+                       free_list(wp);
+               }
+               (void) free((void *) circuits);
+               circuits = NULL;
+       }
+}
+
+void
+init_wire(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       int         i, size = MI_SIZE(mi), n;
+       circuitstruct *wp;
+       XGCValues   gcv;
+
+       if (circuits == NULL) {
+               if ((circuits = (circuitstruct *) calloc(MI_NUM_SCREENS(mi),
+                                           sizeof (circuitstruct))) == NULL)
+                       return;
+       }
+       wp = &circuits[MI_SCREEN(mi)];
+
+       wp->redrawing = 0;
+
+       if ((MI_NPIXELS(mi) <= 2) && (wp->init_bits == 0)) {
+               if (wp->stippledGC == None) {
+                       gcv.fill_style = FillOpaqueStippled;
+                       wp->stippledGC = XCreateGC(display, window, GCFillStyle, &gcv);
+                       if (wp->stippledGC == None) {
+                               release_wire(mi);
+                               return;
+                       }
+               }
+               WIREBITS(stipples[NUMSTIPPLES - 1], STIPPLESIZE, STIPPLESIZE);
+               WIREBITS(stipples[NUMSTIPPLES - 3], STIPPLESIZE, STIPPLESIZE);
+               WIREBITS(stipples[2], STIPPLESIZE, STIPPLESIZE);
+               if (wp->pixmaps[2] == None) { 
+                       release_wire(mi);
+                       return;
+               }
+       }
+       if (MI_NPIXELS(mi) > 2) {
+               wp->colors[0] = (NRAND(MI_NPIXELS(mi)));
+               wp->colors[1] = (wp->colors[0] + MI_NPIXELS(mi) / 6 +
+                            NRAND(MI_NPIXELS(mi) / 4 + 1)) % MI_NPIXELS(mi);
+               wp->colors[2] = (wp->colors[1] + MI_NPIXELS(mi) / 6 +
+                            NRAND(MI_NPIXELS(mi) / 4 + 1)) % MI_NPIXELS(mi);
+       }
+       free_list(wp);
+       wp->generation = 0;
+       wp->width = MI_WIDTH(mi);
+       wp->height = MI_HEIGHT(mi);
+
+       for (i = 0; i < NEIGHBORKINDS; i++) {
+               if (neighbors == plots[i]) {
+                       wp->neighbors = plots[i];
+                       break;
+               }
+               if (i == NEIGHBORKINDS - 1) {
+                       i = NRAND(NEIGHBORKINDS - 3) + 1;       /* Skip triangular ones */
+                       wp->neighbors = plots[i];
+                       break;
+               }
+       }
+
+       wp->prob_array[wp->neighbors - 1] = 100;
+       if (wp->neighbors == 3) {
+               wp->prob_array[1] = 67;
+               wp->prob_array[0] = 33;
+       } else {
+               int         incr = 24 / wp->neighbors;
+
+               for (i = wp->neighbors - 2; i >= 0; i--) {
+                       wp->prob_array[i] = wp->prob_array[i + 1] - incr -
+                               incr * ((i + 1) != wp->neighbors / 2);
+               }
+       }
+
+       if (wp->neighbors == 6) {
+               int         nccols, ncrows;
+
+               if (wp->width < 4)
+                       wp->width = 4;
+               if (wp->height < 4)
+                       wp->height = 4;
+               if (size < -MINSIZE)
+                       wp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               wp->ys = MAX(MINSIZE, MIN(wp->width, wp->height) / MINGRIDSIZE);
+                       else
+                               wp->ys = MINSIZE;
+               } else
+                       wp->ys = MIN(size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                              MINGRIDSIZE));
+               wp->xs = wp->ys;
+               nccols = MAX(wp->width / wp->xs - 2, 2);
+               ncrows = MAX(wp->height / wp->ys - 1, 2);
+               wp->ncols = nccols / 2;
+               wp->nrows = ncrows / 2;
+               wp->nrows -= !(wp->nrows & 1);  /* Must be odd */
+               wp->xb = (wp->width - wp->xs * nccols) / 2 + wp->xs;
+               wp->yb = (wp->height - wp->ys * ncrows) / 2 + wp->ys;
+               for (i = 0; i < 6; i++) {
+                       wp->shape.hexagon[i].x = (wp->xs - 1) * hexagonUnit[i].x;
+                       wp->shape.hexagon[i].y = ((wp->ys - 1) * hexagonUnit[i].y / 2) * 4 / 3;
+               }
+       } else if (wp->neighbors == 4 || wp->neighbors == 8) {
+               if (size < -MINSIZE)
+                       wp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               wp->ys = MAX(MINSIZE, MIN(wp->width, wp->height) / MINGRIDSIZE);
+                       else
+                               wp->ys = MINSIZE;
+               } else
+                       wp->ys = MIN(size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                              MINGRIDSIZE));
+               wp->xs = wp->ys;
+               wp->ncols = MAX(wp->width / wp->xs, 2);
+               wp->nrows = MAX(wp->height / wp->ys, 2);
+               wp->xb = (wp->width - wp->xs * wp->ncols) / 2;
+               wp->yb = (wp->height - wp->ys * wp->nrows) / 2;
+       } else {                /* TRI */
+               int         orient;
+
+               if (wp->width < 4)
+                       wp->width = 4;
+               if (wp->height < 2)
+                       wp->height = 2;
+               if (size < -MINSIZE)
+                       wp->ys = NRAND(MIN(-size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                     MINGRIDSIZE)) - MINSIZE + 1) + MINSIZE;
+               else if (size < MINSIZE) {
+                       if (!size)
+                               wp->ys = MAX(MINSIZE, MIN(wp->width, wp->height) / MINGRIDSIZE);
+                       else
+                               wp->ys = MINSIZE;
+               } else
+                       wp->ys = MIN(size, MAX(MINSIZE, MIN(wp->width, wp->height) /
+                                              MINGRIDSIZE));
+               wp->xs = (int) (1.52 * wp->ys);
+               wp->ncols = (MAX(wp->width / wp->xs - 1, 4) / 2) * 2;
+               wp->nrows = (MAX(wp->height / wp->ys - 1, 2) / 2) * 2 - 1;
+               wp->xb = (wp->width - wp->xs * wp->ncols) / 2 + wp->xs / 2;
+               wp->yb = (wp->height - wp->ys * wp->nrows) / 2 + wp->ys;
+               for (orient = 0; orient < 2; orient++) {
+                       for (i = 0; i < 3; i++) {
+                               wp->shape.triangle[orient][i].x =
+                                       (wp->xs - 2) * triangleUnit[orient][i].x;
+                               wp->shape.triangle[orient][i].y =
+                                       (wp->ys - 2) * triangleUnit[orient][i].y;
+                       }
+               }
+       }
+
+       /*
+        * I am being a bit naughty here wasting a little bit of memory
+        * but it will give me a real headache to figure out the logic
+        * and to refigure the mappings to save a few bytes
+        * ncols should only need a border of 2 and nrows should only need
+        * a border of 4 when in the neighbors = 9 or 12
+        */
+       wp->bncols = wp->ncols + 4;
+       wp->bnrows = wp->nrows + 4;
+
+       MI_CLEARWINDOW(mi);
+
+       if (wp->oldcells != NULL) {
+               (void) free((void *) wp->oldcells);
+               wp->oldcells = NULL;
+       }
+       if ((wp->oldcells = (unsigned char *) calloc(wp->bncols * wp->bnrows, sizeof (unsigned char))) == NULL) {
+               release_wire(mi);
+               return;
+       }
+
+       if (wp->newcells != NULL) {
+               (void) free((void *) wp->newcells);
+               wp->newcells = NULL;
+       }
+       if ((wp->newcells = (unsigned char *) calloc(wp->bncols * wp->bnrows, sizeof (unsigned char))) == NULL) {
+               release_wire(mi);
+               return;
+       }
+
+       n = MI_COUNT(mi);
+       i = (1 + (wp->neighbors == 6)) * wp->ncols * wp->nrows / 4;
+       if (n < -MINWIRES && i > MINWIRES) {
+               n = NRAND(MIN(-n, i) - MINWIRES + 1) + MINWIRES;
+       } else if (n < MINWIRES) {
+               n = MINWIRES;
+       } else if (n > i) {
+               n = MAX(MINWIRES, i);
+       }
+       create_path(wp, n);
+}
+
+void
+draw_wire(ModeInfo * mi)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+       int         offset, i, j;
+       unsigned char *z, *znew;
+
+       if (circuits == NULL) {
+               init_wire(mi);
+               return;
+       }
+       MI_IS_DRAWN(mi) = True;
+
+       /* wires do not grow so min max stuff does not change */
+       for (j = wp->minrow; j <= wp->maxrow; j++) {
+               for (i = wp->mincol; i <= wp->maxcol; i++) {
+                       offset = j * wp->bncols + i;
+                       z = wp->oldcells + offset;
+                       znew = wp->newcells + offset;
+                       if (*z != *znew) {      /* Counting on once a space always a space */
+                               *z = *znew;
+                               addtolist(mi, i - 2, j - 2, *znew - 1);
+                       }
+               }
+       }
+       for (i = 0; i < COLORS - 1; i++)
+               draw_state(mi, i);
+       if (++wp->generation > MI_CYCLES(mi)) {
+               init_wire(mi);
+               return;
+       } else
+               do_gen(wp);
+
+       if (wp->redrawing) {
+               for (i = 0; i < REDRAWSTEP; i++) {
+                       if ((*(wp->oldcells + wp->redrawpos))) {
+                               drawcell(mi, wp->redrawpos % wp->bncols - 2,
+                                        wp->redrawpos / wp->bncols - 2, *(wp->oldcells + wp->redrawpos) - 1);
+                       }
+                       if (++(wp->redrawpos) >= wp->bncols * (wp->bnrows - 2)) {
+                               wp->redrawing = 0;
+                               break;
+                       }
+               }
+       }
+}
+
+void
+refresh_wire(ModeInfo * mi)
+{
+       circuitstruct *wp = &circuits[MI_SCREEN(mi)];
+
+       if (circuits == NULL) {
+               init_wire(mi);
+               return;
+       }
+       MI_CLEARWINDOW(mi);
+       wp->redrawing = 1;
+       wp->redrawpos = 2 * wp->ncols + 2;
+}
+
+#endif /* MODE_wire */
diff --git a/xlockmore-4.14/modes/world.c b/xlockmore-4.14/modes/world.c
new file mode 100644 (file)
index 0000000..1e15033
--- /dev/null
@@ -0,0 +1,286 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* world --- world spinner */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)world.c      4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1993 Matthew Moyle-Croft <mmc@cs.adelaide.edu.au>
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 04-Oct-95: multiscreen patch, thanks to Grant McDorman <grant@isgtec.com>.
+ * 10-Jul-95: Backward spinning jump fixed by Neale Pickett <zephyr@nmt.edu>.
+ * 17-Jul-94: Got batchcount to work.
+ * 09-Jan-94: Written [ Modified from image.c ]
+ * 29-Jul-90: image.c written. Copyright (c) 1991 by Patrick J. Naughton.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "World"
+#define HACK_INIT init_world
+#define HACK_DRAW draw_world
+#define world_opts xlockmore_opts
+#define DEFAULTS "*delay: 100000 \n" \
+ "*count: -16 \n" \
+ "*ncolors: 200 \n"
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_world
+
+ModeSpecOpt world_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   world_description =
+{"world", "init_world", "draw_world", "release_world",
+ "refresh_world", "init_world", NULL, &world_opts,
+ 100000, -16, 1, 1, 64, 0.3, "",
+ "Shows spinning Earths", 0, NULL};
+
+#endif
+
+#include "bitmaps/terra-00.xbm"
+#include "bitmaps/terra-01.xbm"
+#include "bitmaps/terra-02.xbm"
+#include "bitmaps/terra-03.xbm"
+#include "bitmaps/terra-04.xbm"
+#include "bitmaps/terra-05.xbm"
+#include "bitmaps/terra-06.xbm"
+#include "bitmaps/terra-07.xbm"
+#include "bitmaps/terra-08.xbm"
+#include "bitmaps/terra-09.xbm"
+#include "bitmaps/terra-10.xbm"
+#include "bitmaps/terra-11.xbm"
+#include "bitmaps/terra-12.xbm"
+#include "bitmaps/terra-13.xbm"
+#include "bitmaps/terra-14.xbm"
+#include "bitmaps/terra-15.xbm"
+#include "bitmaps/terra-16.xbm"
+#include "bitmaps/terra-17.xbm"
+#include "bitmaps/terra-18.xbm"
+#include "bitmaps/terra-19.xbm"
+#include "bitmaps/terra-20.xbm"
+#include "bitmaps/terra-21.xbm"
+#include "bitmaps/terra-22.xbm"
+#include "bitmaps/terra-23.xbm"
+#include "bitmaps/terra-24.xbm"
+#include "bitmaps/terra-25.xbm"
+#include "bitmaps/terra-26.xbm"
+#include "bitmaps/terra-27.xbm"
+#include "bitmaps/terra-28.xbm"
+#include "bitmaps/terra-29.xbm"
+
+#define NUM_EARTHS 30
+#define SIZE_X terra00_width   /* 64 */
+#define SIZE_Y terra00_height  /* 64 */
+#define NUM_REV 4
+#define MINWORLDS 1
+
+static XImage Earths[NUM_EARTHS] =
+{
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra00_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra01_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra02_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra03_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra04_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra05_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra06_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra07_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra08_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra09_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra10_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra11_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra12_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra13_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra14_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra15_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra16_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra17_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra18_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra19_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra20_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra21_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra22_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra23_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra24_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra25_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra26_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra27_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra28_bits, LSBFirst, 8, LSBFirst, 8, 1},
+       {SIZE_X, SIZE_Y, 0, XYBitmap, (char *) terra29_bits, LSBFirst, 8, LSBFirst, 8, 1}};
+
+typedef struct {
+       int         x;
+       int         y;
+       unsigned long color;
+       int         frame;
+       int         direction;
+} planetstruct;
+
+typedef struct {
+       int         width;
+       int         height;
+       int         nrows;
+       int         ncols;
+       int         xb;
+       int         yb;
+       int         frame_num;
+       int         nplanets;
+       planetstruct *planets;
+} worldstruct;
+
+static worldstruct *worlds = NULL;
+
+void
+init_world(ModeInfo * mi)
+{
+       worldstruct *wp;
+       int         i;
+
+       if (worlds == NULL) {
+               if ((worlds = (worldstruct *) calloc(MI_NUM_SCREENS(mi),
+                                             sizeof (worldstruct))) == NULL)
+                       return;
+       }
+       wp = &worlds[MI_SCREEN(mi)];
+       wp->frame_num = NUM_EARTHS * NUM_REV;
+       for (i = 0; i < NUM_EARTHS; i++)
+               Earths[i].bytes_per_line = 8;
+       wp->width = MI_WIDTH(mi);
+       wp->height = MI_HEIGHT(mi);
+       wp->ncols = wp->width / SIZE_X;
+       if (!wp->ncols)
+               wp->ncols = 1;
+       wp->nrows = wp->height / SIZE_Y;
+       if (!wp->nrows)
+               wp->nrows = 1;
+       wp->xb = (wp->width - SIZE_X * wp->ncols) / 2;
+       wp->yb = (wp->height - SIZE_Y * wp->nrows) / 2;
+       wp->nplanets = MI_COUNT(mi);
+       if (wp->nplanets < -MINWORLDS)
+               wp->nplanets = NRAND(-wp->nplanets - MINWORLDS + 1) + MINWORLDS;
+       else if (wp->nplanets < MINWORLDS)
+               wp->nplanets = MINWORLDS;
+
+       if (wp->nplanets > wp->ncols * wp->nrows)
+               wp->nplanets = wp->ncols * wp->nrows;
+#ifndef NOFLASH
+       if (wp->nplanets > wp->ncols)
+               wp->nplanets = wp->ncols;
+#endif
+       if (wp->planets != NULL)
+               (void) free((void *) wp->planets);
+       wp->planets = (planetstruct *) malloc(wp->nplanets * sizeof (planetstruct));
+       for (i = 0; i < wp->nplanets; i++)
+               wp->planets[i].x = wp->planets[i].y = -1;
+
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_world(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       GC          gc = MI_GC(mi);
+       worldstruct *wp = &worlds[MI_SCREEN(mi)];
+       int         i;
+
+#ifndef NOFLASH
+       int        *col, j;
+
+       if ((col = (int *) calloc(wp->ncols, sizeof (int))) == NULL)
+                           return;
+
+#endif
+       MI_IS_DRAWN(mi) = True;
+
+       if (wp->frame_num == NUM_EARTHS * NUM_REV) {
+               wp->frame_num = 0;
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               for (i = 0; i < wp->nplanets; i++) {
+                       if ((wp->ncols > wp->nplanets || wp->nrows < 2) &&
+                           wp->planets[i].x >= 0 && wp->planets[i].y >= 0)
+                               XFillRectangle(display, MI_WINDOW(mi), gc,
+                                         wp->xb + SIZE_X * wp->planets[i].x,
+                                         wp->yb + SIZE_Y * wp->planets[i].y,
+                                              SIZE_X, SIZE_Y);
+#ifdef NOFLASH
+                       wp->planets[i].x = NRAND(wp->ncols);
+#else
+                       do {
+                               j = NRAND(wp->ncols);
+                               if (!col[j])
+                                       wp->planets[i].x = j;
+                               col[j]++;
+                       } while (col[j] > 1);
+#endif
+                       wp->planets[i].y = NRAND(wp->nrows);
+                       wp->planets[i].direction = (int) (LRAND() & 1);
+                       wp->planets[i].frame = NRAND(NUM_EARTHS);
+                       if (MI_NPIXELS(mi) > 2)
+                               wp->planets[i].color = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi)));
+                       else
+                               wp->planets[i].color = MI_WHITE_PIXEL(mi);
+               }
+       }
+#ifndef NOFLASH
+       (void) free((void *) col);
+#endif
+       for (i = 0; i < wp->nplanets; i++) {
+               XSetForeground(display, gc, wp->planets[i].color);
+               if (wp->planets[i].frame == NUM_EARTHS)
+                       wp->planets[i].frame = 0;
+               else {
+                       if ((wp->planets[i].frame < 0) && wp->planets[i].direction == 0)
+                               wp->planets[i].frame = NUM_EARTHS - 1;
+               }
+               (void) XPutImage(display, MI_WINDOW(mi), gc,
+                                (Earths + wp->planets[i].frame), 0, 0,
+                                wp->xb + SIZE_X * wp->planets[i].x,
+                                wp->yb + SIZE_Y * wp->planets[i].y,
+                                SIZE_X, SIZE_Y);
+
+               (wp->planets[i].direction) ? wp->planets[i].frame++ : wp->planets[i].frame--;
+       }
+       wp->frame_num++;
+}
+
+void
+release_world(ModeInfo * mi)
+{
+       if (worlds != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++)
+                       if (worlds[screen].planets != NULL)
+                               (void) free((void *) worlds[screen].planets);
+               (void) free((void *) worlds);
+               worlds = NULL;
+       }
+}
+
+void
+refresh_world(ModeInfo * mi)
+{
+       MI_CLEARWINDOW(mi);
+}
+
+#endif /* MODE_world */
diff --git a/xlockmore-4.14/modes/worm.c b/xlockmore-4.14/modes/worm.c
new file mode 100644 (file)
index 0000000..22adbb5
--- /dev/null
@@ -0,0 +1,456 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* worm --- draw wiggly worms */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)worm.c       4.07 97/11/24 xlockmore";
+
+#endif
+
+/*-
+ * Copyright (c) 1991 by Patrick J. Naughton.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and that
+ * both that copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * This file is provided AS IS with no warranties of any kind.  The author
+ * shall have no liability with respect to the infringement of copyrights,
+ * trade secrets or any patents by this file or any part thereof.  In no
+ * event will the author be liable for any lost revenue or profits or
+ * other special, indirect and consequential damages.
+ *
+ * Revision History:
+ * 10-May-97: Compatible with xscreensaver
+ * 03-Sep-96: fixed bug in allocation of space for worms, added 3d support
+ *            Henrik Theiling <theiling@coli.uni-sb.de>
+ * 27-Sep-95: put back malloc
+ * 23-Sep-93: got rid of "rint". (David Bagley)
+ * 27-Sep-91: got rid of all malloc calls since there were no calls to free().
+ * 25-Sep-91: Integrated into X11R5 contrib xlock.
+ *
+ * Adapted from a concept in the Dec 87 issue of Scientific American p. 142.
+ *
+ * SunView version: Brad Taylor <brad@sun.com>
+ * X11 version: Dave Lemke <lemke@ncd.com>
+ * xlock version: Boris Putanec <bp@cs.brown.edu>
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "Worm"
+#define HACK_INIT init_worm
+#define HACK_DRAW draw_worm
+#define worm_opts xlockmore_opts
+#define DEFAULTS "*delay: 17000 \n" \
+ "*count: -20 \n" \
+ "*cycles: 10 \n" \
+ "*size: -3 \n" \
+ "*ncolors: 200 \n" \
+ "*use3d: False \n" \
+ "*delta3d: 1.5 \n" \
+ "*right3d: red \n" \
+ "*left3d: blue \n" \
+ "*both3d: magenta \n" \
+ "*none3d: black \n"
+#define SMOOTH_COLORS
+#include "xlockmore.h"         /* in xscreensaver distribution */
+#else /* STANDALONE */
+#include "xlock.h"             /* in xlockmore distribution */
+#endif /* STANDALONE */
+
+#ifdef MODE_worm
+
+ModeSpecOpt worm_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct   worm_description =
+{"worm", "init_worm", "draw_worm", "release_worm",
+ "refresh_worm", "init_worm", NULL, &worm_opts,
+ 17000, -20, 10, -3, 64, 1.0, "",
+ "Shows wiggly worms", 0, NULL};
+
+#endif
+
+#define MINSIZE 1
+
+#define SEGMENTS  36
+#define MINWORMS 1
+
+#define MAXZ      750
+#define MINZ      100
+#define SCREENZ   200
+#define GETZDIFF(z) (MI_DELTA3D(mi)*20.0*(1.0-(SCREENZ)/((float)(z)+MINZ)))
+#define IRINT(x) ((int)(((x)>0.0)?(x)+0.5:(x)-0.5))
+
+/* How many segments to draw per cycle when redrawing */
+#define REDRAWSTEP 3
+
+typedef struct {
+       XPoint     *circ;
+       int        *diffcirc;
+       int         dir, dir2;
+       int         tail;
+       int         x, y, z;
+       int         redrawing, redrawpos;
+} wormstuff;
+
+typedef struct {
+       int         xsize, ysize, zsize;
+       int         wormlength;
+       int         nc;
+       int         nw;
+       int         circsize;
+       wormstuff  *worm;
+       XRectangle *rects;
+       int         maxsize;
+       int        *size;
+       unsigned int chromo;
+} wormstruct;
+
+static float sintab[SEGMENTS];
+static float costab[SEGMENTS];
+static int  init_table = 0;
+
+static wormstruct *worms = NULL;
+
+static void
+worm_doit(ModeInfo * mi, int which, unsigned long color)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       wormstruct *wp = &worms[MI_SCREEN(mi)];
+       wormstuff  *ws = &wp->worm[which];
+       int         x, y, z;
+       int         diff;
+
+       ws->tail++;
+       if (ws->tail == wp->wormlength)
+               ws->tail = 0;
+
+       x = ws->circ[ws->tail].x;
+       y = ws->circ[ws->tail].y;
+
+       if (MI_IS_USE3D(mi)) {
+               diff = ws->diffcirc[ws->tail];
+               if (MI_IS_INSTALL(mi)) {
+                       XSetForeground(display, gc, MI_NONE_COLOR(mi));
+               } else {
+                       XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               }
+               XFillRectangle(display, window, gc, x - diff, y,
+                              wp->circsize, wp->circsize);
+               XFillRectangle(display, window, gc, x + diff, y,
+                              wp->circsize, wp->circsize);
+       } else {
+               XSetForeground(display, gc, MI_BLACK_PIXEL(mi));
+               XFillRectangle(display, window, gc, x, y, wp->circsize, wp->circsize);
+       }
+
+       if (LRAND() & 1)
+               ws->dir = (ws->dir + 1) % SEGMENTS;
+       else
+               ws->dir = (ws->dir + SEGMENTS - 1) % SEGMENTS;
+
+       x = (ws->x + IRINT((float) wp->circsize * costab[ws->dir]) +
+            wp->xsize) % wp->xsize;
+       y = (ws->y + IRINT((float) wp->circsize * sintab[ws->dir]) +
+            wp->ysize) % wp->ysize;
+
+       ws->circ[ws->tail].x = x;
+       ws->circ[ws->tail].y = y;
+       ws->x = x;
+       ws->y = y;
+
+       if (MI_IS_USE3D(mi)) {
+               if (LRAND() & 1)
+                       ws->dir2 = (ws->dir2 + 1) % SEGMENTS;
+               else
+                       ws->dir2 = (ws->dir2 + SEGMENTS - 1) % SEGMENTS;
+               /* for the z-axis the wrap-around looks bad,
+                  * so worms should just turn around.
+                */
+               z = (int) (ws->z + wp->circsize * sintab[ws->dir2]);
+               if (z < 0 || z >= wp->zsize)
+                       z = (int) (ws->z - wp->circsize * sintab[ws->dir2]);
+
+               diff = (int) (GETZDIFF(z) + 0.5);       /* ROUND */
+               ws->diffcirc[ws->tail] = diff;
+
+               ws->z = z;
+
+               /* right eye */
+               color = 0;
+               wp->rects[color * wp->maxsize + wp->size[color]].x = x + diff;
+               wp->rects[color * wp->maxsize + wp->size[color]].y = y;
+               wp->size[color]++;
+
+               /* left eye */
+               color = 1;
+               wp->rects[color * wp->maxsize + wp->size[color]].x = x - diff;
+               wp->rects[color * wp->maxsize + wp->size[color]].y = y;
+               wp->size[color]++;
+
+#if 0
+               if (ws->redrawing) {    /* Too hard for now */
+                       int         j;
+
+                       for (j = 0; j < REDRAWSTEP; j++) {
+                               int         k = (ws->tail - ws->redrawpos + wp->wormlength)
+                               % wp->wormlength;
+
+                               color = 0;
+                               wp->rects[color * wp->maxsize + wp->size[color]].x =
+                                       ws->circ[k].x + ws->diffcirc[k];
+                               wp->rects[color * wp->maxsize + wp->size[color]].y =
+                                       ws->circ[k].y;
+                               wp->size[color]++;
+
+                               color = 1;
+                               wp->rects[color * wp->maxsize + wp->size[color]].x =
+                                       ws->circ[k].x - ws->diffcirc[k];
+                               wp->rects[color * wp->maxsize + wp->size[color]].y =
+                                       ws->circ[k].y;
+                               wp->size[color]++;
+
+                               if (++(ws->redrawpos) >= wp->wormlength) {
+                                       ws->redrawing = 0;
+                                       break;
+                               }
+                       }
+               }
+#endif
+
+       } else {
+
+               wp->rects[color * wp->maxsize + wp->size[color]].x = x;
+               wp->rects[color * wp->maxsize + wp->size[color]].y = y;
+               wp->size[color]++;
+               if (ws->redrawing) {
+                       int         j;
+
+                       ws->redrawpos++;
+                       /* Compensates for the changed ws->tail
+                          since the last callback. */
+
+                       for (j = 0; j < REDRAWSTEP; j++) {
+                               int         k = (ws->tail - ws->redrawpos + wp->wormlength)
+                               % wp->wormlength;
+
+                               wp->rects[color * wp->maxsize + wp->size[color]].x = ws->circ[k].x;
+                               wp->rects[color * wp->maxsize + wp->size[color]].y = ws->circ[k].y;
+                               wp->size[color]++;
+
+                               if (++(ws->redrawpos) >= wp->wormlength) {
+                                       ws->redrawing = 0;
+                                       break;
+                               }
+                       }
+               }
+       }
+}
+
+static void
+free_worms(wormstruct * wp)
+{
+       int         wn;
+
+       if (wp->worm) {
+               for (wn = 0; wn < wp->nw; wn++) {
+                       if (wp->worm[wn].circ)
+                               (void) free((void *) wp->worm[wn].circ);
+                       if (wp->worm[wn].diffcirc)
+                               (void) free((void *) wp->worm[wn].diffcirc);
+               }
+               (void) free((void *) wp->worm);
+               wp->worm = NULL;
+       }
+       if (wp->rects) {
+               (void) free((void *) wp->rects);
+               wp->rects = NULL;
+       }
+       if (wp->size) {
+               (void) free((void *) wp->size);
+               wp->size = NULL;
+       }
+}
+
+void
+init_worm(ModeInfo * mi)
+{
+       wormstruct *wp;
+       int         size = MI_SIZE(mi);
+       int         i, j;
+
+       if (worms == NULL) {
+               if ((worms = (wormstruct *) calloc(MI_NUM_SCREENS(mi),
+                                              sizeof (wormstruct))) == NULL)
+                       return;
+       }
+       wp = &worms[MI_SCREEN(mi)];
+       if (MI_NPIXELS(mi) <= 2 || MI_IS_USE3D(mi))
+               wp->nc = 2;
+       else
+               wp->nc = MI_NPIXELS(mi);
+
+       free_worms(wp);
+       wp->nw = MI_COUNT(mi);
+       if (wp->nw < -MINWORMS)
+               wp->nw = NRAND(-wp->nw - MINWORMS + 1) + MINWORMS;
+       else if (wp->nw < MINWORMS)
+               wp->nw = MINWORMS;
+       if (!wp->worm)
+               wp->worm = (wormstuff *) malloc(wp->nw * sizeof (wormstuff));
+
+       if (!wp->size)
+               wp->size = (int *) malloc(MI_NPIXELS(mi) * sizeof (int));
+
+       wp->maxsize = (REDRAWSTEP + 1) * wp->nw;        /*  / wp->nc + 1; */
+       if (!wp->rects)
+               wp->rects =
+                       (XRectangle *) malloc(wp->maxsize * MI_NPIXELS(mi) * sizeof (XRectangle));
+
+
+       if (!init_table) {
+               init_table = 1;
+               for (i = 0; i < SEGMENTS; i++) {
+                       sintab[i] = SINF(i * 2.0 * M_PI / SEGMENTS);
+                       costab[i] = COSF(i * 2.0 * M_PI / SEGMENTS);
+               }
+       }
+       wp->xsize = MI_WIDTH(mi);
+       wp->ysize = MI_HEIGHT(mi);
+       wp->zsize = MAXZ - MINZ + 1;
+       if (MI_NPIXELS(mi) > 2)
+               wp->chromo = NRAND(MI_NPIXELS(mi));
+
+       if (size < -MINSIZE)
+               wp->circsize = NRAND(-size - MINSIZE + 1) + MINSIZE;
+       else if (size < MINSIZE)
+               wp->circsize = MINSIZE;
+       else
+               wp->circsize = size;
+
+       for (i = 0; i < wp->nc; i++) {
+               for (j = 0; j < wp->maxsize; j++) {
+                       wp->rects[i * wp->maxsize + j].width = wp->circsize;
+                       wp->rects[i * wp->maxsize + j].height = wp->circsize;
+
+               }
+       }
+       (void) memset((char *) wp->size, 0, wp->nc * sizeof (int));
+
+       wp->wormlength = (int) sqrt(wp->xsize + wp->ysize) *
+               MI_CYCLES(mi) / 8;      /* Fudge this to something reasonable */
+       for (i = 0; i < wp->nw; i++) {
+               wp->worm[i].circ = (XPoint *) malloc(wp->wormlength * sizeof (XPoint));
+               wp->worm[i].diffcirc = (int *) malloc(wp->wormlength * sizeof (int));
+
+               for (j = 0; j < wp->wormlength; j++) {
+                       wp->worm[i].circ[j].x = wp->xsize / 2;
+                       wp->worm[i].circ[j].y = wp->ysize / 2;
+                       if (MI_IS_USE3D(mi))
+                               wp->worm[i].diffcirc[j] = 0;
+               }
+               wp->worm[i].dir = NRAND(SEGMENTS);
+               wp->worm[i].dir2 = NRAND(SEGMENTS);
+               wp->worm[i].tail = 0;
+               wp->worm[i].x = wp->xsize / 2;
+               wp->worm[i].y = wp->ysize / 2;
+               wp->worm[i].z = SCREENZ - MINZ;
+               wp->worm[i].redrawing = 0;
+       }
+
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+}
+
+void
+draw_worm(ModeInfo * mi)
+{
+       Display    *display = MI_DISPLAY(mi);
+       Window      window = MI_WINDOW(mi);
+       GC          gc = MI_GC(mi);
+       wormstruct *wp = &worms[MI_SCREEN(mi)];
+       unsigned long wcolor;
+       int         i;
+
+       (void) memset((char *) wp->size, 0, wp->nc * sizeof (int));
+
+       MI_IS_DRAWN(mi) = True;
+
+       for (i = 0; i < wp->nw; i++) {
+               if (MI_NPIXELS(mi) > 2) {
+                       wcolor = (i + wp->chromo) % wp->nc;
+
+                       worm_doit(mi, i, wcolor);
+               } else
+                       worm_doit(mi, i, (unsigned long) 0);
+       }
+
+       if (MI_IS_USE3D(mi)) {
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXor);
+               XSetForeground(display, gc, MI_RIGHT_COLOR(mi));
+               XFillRectangles(display, window, gc, &(wp->rects[0]), wp->size[0]);
+
+               XSetForeground(display, gc, MI_LEFT_COLOR(mi));
+               XFillRectangles(display, window, gc, &(wp->rects[wp->maxsize]), wp->size[1]);
+               if (MI_IS_INSTALL(mi))
+                       XSetFunction(display, gc, GXcopy);
+       } else if (MI_NPIXELS(mi) > 2) {
+               for (i = 0; i < wp->nc; i++) {
+                       XSetForeground(display, gc, MI_PIXEL(mi, i));
+                       XFillRectangles(display, window, gc, &(wp->rects[i * wp->maxsize]), wp->size[i]);
+               }
+       } else {
+               XSetForeground(display, gc, MI_WHITE_PIXEL(mi));
+               XFillRectangles(display, window, gc,
+                               &(wp->rects[0]), wp->size[0]);
+       }
+
+       if (++wp->chromo == (unsigned long) wp->nc)
+               wp->chromo = 0;
+}
+
+void
+release_worm(ModeInfo * mi)
+{
+       if (worms != NULL) {
+               int         screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++)
+                       free_worms(&worms[screen]);
+               (void) free((void *) worms);
+               worms = NULL;
+       }
+}
+
+void
+refresh_worm(ModeInfo * mi)
+{
+       if (MI_IS_INSTALL(mi) && MI_IS_USE3D(mi)) {
+               MI_CLEARWINDOWCOLOR(mi, MI_NONE_COLOR(mi));
+       } else {
+               MI_CLEARWINDOW(mi);
+       }
+       /* The 3D code does drawing&clearing by XORing.  We do not
+          want to go to too much trouble here to make it redraw
+          correctly. */
+       if (!MI_IS_USE3D(mi) && worms != NULL) {
+               wormstruct *wp = &worms[MI_SCREEN(mi)];
+               int         i;
+
+               for (i = 0; i < wp->nw; i++) {
+                       wp->worm[i].redrawing = 1;
+                       wp->worm[i].redrawpos = 0;
+               }
+       }
+}
+
+#endif /* MODE_worm */
diff --git a/xlockmore-4.14/modes/xjack.c b/xlockmore-4.14/modes/xjack.c
new file mode 100644 (file)
index 0000000..4fe45fc
--- /dev/null
@@ -0,0 +1,452 @@
+/* -*- Mode: C; tab-width: 4 -*- */
+/* xjack -- Jack having one of those days */
+
+#if !defined( lint ) && !defined( SABER )
+static const char sccsid[] = "@(#)xjack.c      4.13 98/10/10 xlockmore";
+
+#endif
+
+/* xscreensaver, Copyright (c) 1997 Jamie Zawinski <jwz@jwz.org>
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation.  No representations are made about the suitability of this
+ * software for any purpose.  It is provided "as is" without express or 
+ * implied warranty.
+ *
+ * Wendy, let me explain something to you.  Whenever you come in here and
+ * interrupt me, you're BREAKING my CONCENTRATION.  You're DISTRACTING me!
+ * And it will then take me time to get back to where I was. You understand?
+ * Now, we're going to make a new rule.        When you come in here and you hear
+ * me typing, or whether you DON'T hear me typing, or whatever the FUCK you
+ * hear me doing; when I'm in here, it means that I am working, THAT means
+ * don't come in!  Now, do you think you can handle that?
+ *
+ * Revision History:
+ * 10-Oct-98: revision history edited.
+ */
+
+#ifdef STANDALONE
+#define PROGCLASS "XJack"
+#define HACK_INIT init_xjack
+#define HACK_DRAW draw_xjack
+#define xjack_opts xlockmore_opts
+#define DEFAULTS "*delay: 50000 \n" \
+ "*font: \n" \
+ "*text: \n" \
+ "*fullrandom: True \n"
+#define DEF_FONT "-*-courier-medium-r-*-*-*-240-*-*-m-*-*-*",
+#define DEF_TEXT "All work and no play makes Jack a dull boy.  ";
+#include "xlockmore.h"  /* in xscreensaver distribution */
+
+#else /* STANDALONE */
+#include "xlock.h"     /* in xlockmore distribution */
+#endif
+#include "iostuff.h"
+
+#ifdef MODE_xjack
+
+ModeSpecOpt xjack_opts =
+{0, NULL, 0, NULL, NULL};
+
+#ifdef USE_MODULES
+ModStruct       xjack_description =
+{"xjack", "init_xjack", "draw_xjack", "release_xjack",
+ "init_xjack", "init_xjack", NULL, &xjack_opts,
+ 50000, 1, 1, 1, 64, 1.0, "",
+ "Shows Jack having one of those days", 0, NULL};
+
+#endif
+
+#define font_height(f) ((f==None)?8:f->ascent + f->descent)
+
+extern XFontStruct *getFont(Display * display);
+
+typedef struct {
+       int   word_length;
+       int   sentences;
+       int   paras;
+       Bool  caps;
+       Bool  break_para;
+       int   mode, stage, busyloop;
+       int   left, right;      /* characters */
+       int   x, y;             /* characters */
+       int   hspace, vspace;   /* pixels */
+       int   ascent;
+       int   height;
+       int   win_width, win_height;
+       int   columns, rows;    /* characters */
+       int   char_width, line_height;  /* pixels */
+       const char *s;
+       GC    gc;
+} jackstruct;
+
+static jackstruct *jacks = NULL;
+
+static XFontStruct *mode_font = None;
+static const char *source = "All work and no play makes Jack a dull boy.  ";
+static const char *source_message;
+
+extern char *message;
+
+void
+init_xjack(ModeInfo * mi)
+{
+       Display         *display = MI_DISPLAY(mi);
+       jackstruct *jp;
+       XGCValues gcv;
+
+
+       if (jacks == NULL) {
+               if ((jacks = (jackstruct *) calloc(MI_NUM_SCREENS(mi),
+                        sizeof (jackstruct))) == NULL)
+                       return;
+       }
+       jp = &jacks[MI_SCREEN(mi)];
+       if (mode_font == None)
+               mode_font = getFont(display);
+       if (jp->gc == NULL && mode_font != None) {
+               gcv.font = mode_font->fid;
+               XSetFont(display, MI_GC(mi), mode_font->fid);
+               gcv.graphics_exposures = False;
+               gcv.foreground = MI_WHITE_PIXEL(mi);
+               gcv.background = MI_BLACK_PIXEL(mi);
+               jp->gc = XCreateGC(display, MI_WINDOW(mi),
+                                        GCForeground | GCBackground | GCGraphicsExposures | GCFont, &gcv);
+               jp->ascent = mode_font->ascent;
+               jp->height = font_height(mode_font);
+       }
+
+       jp->win_width = MI_WIDTH(mi);
+       jp->win_height = MI_HEIGHT(mi);
+
+       jp->hspace = jp->vspace = 15;  /* pixels */
+       jp->char_width = (mode_font->per_char
+                               ? mode_font->per_char['n' - mode_font->min_char_or_byte2].rbearing
+                               : mode_font->min_bounds.rbearing);
+  if (!jp->char_width)
+               jp->char_width = 1;
+       jp->line_height = jp->height + 1;
+
+       jp->columns = (jp->win_width - jp->hspace - jp->hspace) / jp->char_width;
+       jp->rows = (MI_HEIGHT(mi) - jp->vspace - jp->vspace) / jp->line_height;
+
+       jp->left = 0xFF & (NRAND((jp->columns / 2) + 1));
+       if ( jp->columns - jp->left != 10 )
+               jp->right = jp->left + (0xFF & (NRAND(jp->columns - jp->left - 10) + 10));
+       else
+               jp->right = jp->left + 10;
+       jp->x = 0;
+       jp->y = 0;
+       jp->sentences = 0;
+       jp->paras = 0;
+       jp->caps = False;
+       jp->break_para = True;
+       jp->mode = 0;
+       jp->stage = 0;
+       jp->busyloop = 0;
+       if (!message || !*message)
+               source_message = source;
+       else
+               source_message = message;
+       jp->s = source_message;
+       MI_CLEARWINDOW(mi);
+}
+
+void
+draw_xjack(ModeInfo * mi)
+{
+       Display         *display = MI_DISPLAY(mi);
+       Window                  window = MI_WINDOW(mi);
+       jackstruct *jp = &jacks[MI_SCREEN(mi)];
+       const char *s2;
+
+       jp->word_length = 0;
+       for (s2 = jp->s; *s2 && *s2 != ' '; s2++)
+               jp->word_length++;
+
+       if (jp->break_para || (*(jp->s) != ' ' &&
+                (jp->x + jp->word_length) >= jp->right)) {
+               jp->x = jp->left;
+               jp->y++;
+
+               if (jp->break_para)
+                       jp->y++;
+
+               if (jp->mode == 1 || jp->mode == 2) {
+                       /* 1 = left margin goes southwest; 2 = southeast */
+                       jp->left += (jp->mode == 1 ? 1 : -1);
+                       if (jp->left >= jp->right - 10) {
+                               if ((jp->right < (jp->columns - 10)) && (LRAND() & 1))
+                                       jp->right += (0xFF & (NRAND(jp->columns - jp->right)));
+                               else
+                                       jp->mode = 2;
+                       } else if (jp->left <= 0) {
+                               jp->left = 0;
+                               jp->mode = 1;
+                       }
+               } else if (jp->mode == 3 || jp->mode == 4) {
+                       /* 3 = right margin goes southeast; 4 = southwest */
+                       jp->right += (jp->mode == 3 ? 1 : -1);
+                       if (jp->right >= jp->columns) {
+                               jp->right = jp->columns;
+                               jp->mode = 4;
+                       } else if (jp->right <= jp->left + 10)
+                               jp->mode = 3;
+                       }
+
+                       if (jp->y >= jp->rows) {  /* bottom of page */
+                               /* scroll by 1-5 lines */
+                               int lines = ((NRAND(5)) ? 0 : (0xFF & (NRAND(5)))) + 1;
+
+                               if (jp->break_para)
+                                       lines++;
+
+                               /* but sometimes scroll by a whole page */
+                               if (!NRAND(100))
+                                       lines += jp->rows;
+
+                               while (lines > 0) {
+                                       XCopyArea(display, window, window, jp->gc,
+                                                               0, jp->hspace + jp->line_height,
+                                                               jp->win_width,
+                                                               jp->win_height - jp->vspace - jp->vspace - jp->line_height,
+                                                               0, jp->vspace);
+                                       XClearArea(display, window,
+                                                               0,      jp->win_height - jp->vspace - jp->line_height,
+                                                               jp->win_width,
+                                                               jp->line_height + jp->vspace + jp->vspace,
+                                                               False);
+                                       XClearArea(display, window, 0, 0,       jp->win_width, jp->vspace, False);
+                                       /* See? It's OK. He saw it on the television. */
+                                       XClearArea(display, window, 0, 0, jp->hspace, jp->win_height, False);
+                                       XClearArea(display, window,     jp->win_width - jp->vspace, 0,
+                                                               jp->hspace, jp->win_height, False);
+                                       jp->y--;
+                                       lines--;
+#if 0
+                                       XSync (display, True);
+                                       if (delay)
+                                                usleep (delay * 10);
+#endif
+                               }
+                               if (jp->y < 0)
+                                       jp->y = 0;
+                       }
+
+                       jp->break_para = False;
+               }
+
+               if (*(jp->s) != ' ') {
+                       char c = *(jp->s);
+                       int xshift = 0, yshift = 0;
+
+                       if (!NRAND(50)) {
+                               xshift = NRAND((jp->char_width / 3) + 1);  /* mis-strike */
+                               yshift = NRAND((jp->line_height / 6) + 1);
+                               if (!NRAND(3))
+                                       yshift *= 2;
+                               if (LRAND() & 1)
+                                       xshift = -xshift;
+                               if (LRAND() & 1)
+                                       yshift = -yshift;
+                       }
+
+                       if (!NRAND(250)) {  /* introduce adjascent-key typo */
+                               static const char * const typo[] = {
+                                       "asqwz", "bghnv", "cdfvx", "dcefsrx", "edrsw34",
+                                       "fcdegrtv", "gbfhtvy", "hbgjnuy", "ijkou89", "jhikmnu",
+                                       "kijolm,", "lkop;.,", "mjkn,", "nbhjm", "oiklp09",
+                                       "plo;[-0", "qasw12", "redft45", "sadewxz", "tfgry56",
+                                       "uhijy78", "vbcfg", "waeqs23", "xcdsz", "yuhgt67",
+                                       "zasx", ".l,;/",
+                                       "ASQWZ", "BGHNV", "CDFVX", "DCEFSRX", "EDRSW#$",
+                                       "FCDEGRTV", "GBFHTVY", "HBGJNUY", "IJKOU*(", "JHIKMNU",
+                                       "KIJOLM,", "LKOP:><", "MJKN<", "NBHJM", "OIKLP)(",
+                                       "PLO:{_)", "QASW!@", "REDFT$%", "SADEWXZ", "TFGRY%^",
+                                       "UHIJY&*", "VBCFG", "WAEQS@#", "XCDSZ", "YUHGT^&",
+                                       "ZASX", 0 };
+                               int i = 0;
+
+                               while (typo[i] && typo[i][0] != c)
+                                       i++;
+                               if (typo[i])
+                                       c = typo[i][0xFF & (NRAND(strlen(typo[i]+1)))];
+                       }
+
+                       /* caps typo */
+                       if (c >= 'a' && c <= 'z' && (jp->caps || !NRAND(350))) {
+                               c -= ('a' - 'A');
+                               if (c == 'O' && LRAND() & 1)
+                                       c = '0';
+                       }
+
+                       {
+                               Bool overstrike;
+
+                               do {
+                                       XDrawString (display, window, jp->gc,
+                                                       (jp->x * jp->char_width) + jp->hspace + xshift,
+                                                       (jp->y * jp->line_height) + jp->vspace + mode_font->ascent + yshift,
+                                                       &c, 1);
+                                       overstrike = (xshift == 0 && yshift == 0 &&
+                                               (0 == (LRAND() & 3000)));
+                                       if (overstrike) {
+                                               if (LRAND() & 1)
+                                                       xshift--;
+                                               else
+                                                       yshift--;
+                                       }
+                               } while (overstrike);
+                       }
+                       if ((tolower(c) != tolower(*(jp->s)))
+                                       ? (!NRAND(10))      /* backup to correct */
+                                       : (!NRAND(400))) {  /* fail to advance */
+                               jp->x--;
+                               jp->s--;
+#if 0
+                               XSync (display, True);
+                               if (delay)
+                                        usleep (0xFFFF & (delay + (NRAND(delay * 10))));
+#endif
+                       }
+               }
+
+               jp->x++;
+               jp->s++;
+
+               if (!NRAND(200)) {
+                       if (LRAND() & 1 && jp->s != source_message)
+                               jp->s--;   /* duplicate character */
+                       else if (*(jp->s))
+                               jp->s++;   /* skip character */
+               }
+
+               if (*(jp->s) == 0) {
+                       jp->sentences++;
+                       jp->caps = (!NRAND(40));  /* capitalize sentence */
+
+                       if (!NRAND(10) ||         /* randomly break paragraph */
+                                       (jp->mode == 0 && (NRAND(10) || jp->sentences > 20))) {
+                               jp->break_para = True;
+                               jp->sentences = 0;
+                               jp->paras++;
+
+                               if (LRAND() & 1)       /* mode=0 50% of the time */
+                                       jp->mode = 0;
+                               else
+                                       jp->mode = (0xFF & NRAND(5));
+
+                       if (LRAND() & 1) {         /* re-pick margins */
+                               if (jp->columns < 3)
+                                       jp->columns = 3;        
+                               jp->left = 0xFF & (NRAND(jp->columns / 3));
+                               jp->right = jp->columns - (0xFF & (NRAND(jp->columns / 3)));
+
+                               if (!NRAND(3))        /* sometimes be wide */
+                                       jp->right = jp->left + ((jp->right - jp->left) / 2);
+                       }
+
+                       if (jp->right - jp->left <= 10) {  /* introduce sanity */
+                               jp->left = 0;
+                               jp->right = jp->columns;
+                       }
+
+                       if (jp->right - jp->left > 50) {   /* if wide, shrink and move */
+                               jp->left += (0xFF & (NRAND((jp->columns - 50) + 1)));
+                               jp->right = jp->left + (0xFF & (NRAND(40) + 10));
+                       }
+
+                       /* oh, gag. */
+                       if (jp->mode == 0 && jp->right - jp->left < 25 && jp->columns > 40) {
+                               jp->right += 20;
+                               if (jp->right > jp->columns)
+                                       jp->left -= (jp->right - jp->columns);
+                       }
+               }
+               jp->s = source_message;
+       }
+
+#if 0
+       XSync (display, True);
+       if (delay) {
+               usleep (delay);
+               if (!NRAND(3))
+                       usleep(0xFFFFFF & ((NRAND(delay * 5)) + 1));
+
+               if (jp->break_para)
+                       usleep(0xFFFFFF & ((NRAND(delay * 15)) + 1));
+       }
+#endif 
+
+#ifdef NFS_COMPLAINTS
+       if (jp->paras > 5 && (!NRAND(1000)) && jp->y < jp->rows-5) {
+               int i;
+               int n = NRAND(3);
+
+               jp->y++;
+               for (i = 0; i < n; i++) {
+                       /* See also http://catalog.com/hopkins/unix-haters/login.html */
+                       const char *n1 =
+                                       "NFS server overlook not responding, still trying...";
+                       const char *n2 = "NFS server overlook ok.";
+
+                       while (*n1) {
+                               XDrawString (display, window, jp->gc,
+                                                                       (jp->x * jp->char_width) + jp->hspace,
+                                                                       (jp->y * jp->line_height) + jp->vspace + mode_font->ascent,
+                                                                       n1, 1);
+                               jp->x++;
+                               if (jp->x >= jp->columns)
+                                       jp->x = 0, jp->y++;
+                               n1++;
+                       }
+#if 0
+                       XSync (display, True);
+                       usleep (5000000);
+#endif
+                       while (*n2) {
+                               XDrawString (display, window, jp->gc,
+                                                               (jp->x * jp->char_width) + jp->hspace,
+                                                               (jp->y * jp->line_height) + jp->vspace + mode_font->ascent,
+                                                               n2, 1);
+                               jp->x++;
+                               if (jp->x >= jp->columns)
+                                       jp->x = 0, jp->y++;
+                               n2++;
+                       }
+                       jp->y++;
+#if 0
+                       XSync (display, True);
+                       usleep (500000);
+#endif
+               }
+       }
+#endif
+}
+
+void
+release_xjack(ModeInfo * mi)
+{
+       if (jacks != NULL) {
+               int                              screen;
+
+               for (screen = 0; screen < MI_NUM_SCREENS(mi); screen++) {
+                       jackstruct *jp = &jacks[screen];
+                       Display         *display = MI_DISPLAY(mi);
+
+                       if (jp->gc)
+                               XFreeGC(display, jp->gc);
+               }
+               (void) free((void *) jacks);
+               jacks = NULL;
+       }
+       if (mode_font != None) {
+               XFreeFont(MI_DISPLAY(mi), mode_font);
+               mode_font = None;
+       }
+}
+
+#endif /* MODE_xjack */
diff --git a/xlockmore-4.14/pixmaps/bat-0.xpm b/xlockmore-4.14/pixmaps/bat-0.xpm
new file mode 100644 (file)
index 0000000..81ae384
--- /dev/null
@@ -0,0 +1,178 @@
+/* XPM */
+static char * bat0[] = {
+"147 108 67 1",
+"      c #000000000000",
+".     c #090909090909",
+"X     c #969696969696",
+"o     c #9C9C9C9C9C9C",
+"O     c #1E1E1E1E1E1E",
+"+     c #F0F0F0F0F0F0",
+"@     c #FFFFFFFFFFFF",
+"#     c #C6C6C6C6C6C6",
+"$     c #474747474747",
+"%     c #212121212121",
+"&     c #E2E2E2E2E2E2",
+"*     c #414141414141",
+"=     c #0C0C0C0C0C0C",
+"-     c #272727272727",
+";     c #AAAAAAAAAAAA",
+":     c #808080808080",
+">     c #B4B4B4B4B4B4",
+",     c #1A1A1A1A1A1A",
+"<     c #DDDDDDDDDDDD",
+"1     c #EDEDEDEDEDED",
+"2     c #2A2A2A2A2A2A",
+"3     c #D7D7D7D7D7D7",
+"4     c #2C2C2C2C2C2C",
+"5     c #999999999999",
+"6     c #FBFBFBFBFBFB",
+"7     c #4A4A4A4A4A4A",
+"8     c #BDBDBDBDBDBD",
+"9     c #B2B2B2B2B2B2",
+"0     c #585858585858",
+"q     c #C8C8C8C8C8C8",
+"w     c #101010101010",
+"e     c #151515151515",
+"r     c #6C6C6C6C6C6C",
+"t     c #C0C0C0C0C0C0",
+"y     c #7F7F7F7F7F7F",
+"u     c #3F3F3F3F3F3F",
+"i     c #6B6B6B6B6B6B",
+"p     c #868686868686",
+"a     c #353535353535",
+"s     c #F4F4F4F4F4F4",
+"d     c #4D4D4D4D4D4D",
+"f     c #5D5D5D5D5D5D",
+"g     c #050505050505",
+"h     c #EBEBEBEBEBEB",
+"j     c #606060606060",
+"k     c #A2A2A2A2A2A2",
+"l     c #FFFF00000000",
+"L     c #FFFF77777777",
+"z     c #656565656565",
+"x     c #7A7A7A7A7A7A",
+"c     c #919191919191",
+"v     c #6E6E70707070",
+"b     c #A5A5A5A5A5A5",
+"n     c #CECECECECECE",
+"m     c #727272727272",
+"M     c #515151515151",
+"N     c #E6E6E6E6E6E6",
+"B     c #D0D0D0D0D0D0",
+"V     c #3B3B3B3B3B3B",
+"C     c #BABABABABABA",
+"Z     c #555555555555",
+"A     c #888888888888",
+"S     c #313131313131",
+"D     c #ACACACACACAC",
+"F     c #757575757575",
+"G     c #8C8C8C8C8C8C",
+"H     c #DADADADADADA",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                   .Xo                                                                             ",
+"                                                                   O+@#$                                                                           ",
+"                                                                    %&@@*        %=                                                                ",
+"                                                                     -&@;      .:@>                                                                ",
+"                                                                      ,<1     23@@2                                                                ",
+"                                                                       4@2   5@@67                                                                 ",
+"                                                                        89 0&@@@q                                                                  ",
+"                                                          w=eee         r@t@@@@>%                                                                  ",
+"                                                       %y9@@@@@@<u ipua=%@@@@@s df                                                                 ",
+"                                                     gy@@h5ffffjki<@@@@@3@@@3l@zx@t=                                                               ",
+"                                                    =9@c%=vvvvvve<+llll9@@@bllln.m@t,                                                              ",
+"                                                   a+@Mvvvvvvvvv.N3lLLll@@BlLLl@t u+@2                                                             ",
+"                                                  f@<avvvvvvvvO% m@lLLlq@1hlLLl>@, ,t@V                                                            ",
+"                                                 M@Cevvvvvv=Z#6@t061lll@ZA@llll;@,   3+2                                                           ",
+"                                                O+nvvvvvvvz@@@5c@@@3@@64 Z@&lll1&V;   #&                                                           ",
+"                                               ,s&,vvvvvvz@N0g   S% t@@z D@@@1N@iF@7 .-sG                                                          ",
+"                                               5@4vvvvvvv3s-        t@@q h@@@++5g=@n %$j@%                                                         ",
+"                                              f@Zvvvvvvvw@>         :@sZ @@&=     j@y 0=B#                                                         ",
+"                                             ghCvvvvvvvvv6>         r@; O+3;       b6 -02@f                                                        ",
+"                                             i@2vvvvvvMxm&B         x@k 7N<m       2@uvm bs                                                        ",
+"                                             skvvvvvvx@@@@@M        t@b X#qV        &5v*aO@z                                                       ",
+"                                            G@%vvvvvw1h2e<@F        #@G >X#4        Dovvr Dhg                                                      ",
+"                                           .1bvvvvvv7@i  4*g        t@0 hj<4        D8vvFg-@u                                                      ",
+"                                           u@OvvvvvvX@              t@7g@V3         CNgv7M &C                                                      ",
+"                                           ;&vvvvvvvnN             =&@4%@u&        .1>vvwf rs,                                                     ",
+"                                          ,@5vvvvvvvsD             O+@ 7#f9        %@0vvvrge@0                                                     ",
+"                                          Ss-vvvvvvw@o             a@@ AxDX        ;@vvvva% #t                                                     ",
+"                                          D<vvvvvvvvsZ             Z@n q$#j     io;@ivvvve$ :@                                                     ",
+"                                          B5vvvvvvvv6Z             x@# Be@S    ,6@@C.vvvvv- 4@S                                                    ",
+"                                          6ivvvvvvvvs0             D@:eBO+.     D@N=vvvvvv-g=+j                                                    ",
+"                                         w@2vvvvvvvvsk             #@j,ny<g     w1Hvvvvvvvvvv#5                                                    ",
+"                                         7@%vvvvvvvvh>             @@2%n>k       o@*vvvvvvvuv>H                                                    ",
+"                                         01vvvvvvvvvo@             @1 jtNd       a@yvvvvvvv-vm1                                                    ",
+"                                         bNvvvvv=.vv:@g           4@& f1@$        HXvvvvvvvdv2@%                                                   ",
+"                                         bNgv,vvOgvv*@V           m@; 0@@g        q3vvvvvvv2w @j                                                   ",
+"                                         ;#vvgvuvvvv.hD           jH- r@H         qHvvvvvvv.d 39                                                   ",
+"                                         DkvvvOgvvvvvD@,           g  5@p         3kvvvvvvvvi ;q                                                   ",
+"                                         Dbvvvz.0r0ev*@j              =0.         @mvvvvvvvvf=yn                                                   ",
+"                                         Dkvvm@@@@@@o-Nt                         a@%vvvvvvvv-%i6,                                                  ",
+"                                         Dkv.@@;2e7C@+h@V                        chvvvvvvvvv,*21e                                                  ",
+"                                         Dkvy@x     *<@@k                        #8vvvvvvvvv%c-@2                                                  ",
+"                                         DovsH       .b@@2                      e@MvvvvvvvvvgF=@Z                                                  ",
+"                                         DD-@d         B@t                      j@vvvvvvvvvvvk @M                                                  ",
+"                                         ;Ha@%         -N@S                     C6vvvvvvvvvvvA sf                                                  ",
+"                                         x3:@           A@3.                   ,@DvvvvvvvvvvvX 6c                                                  ",
+"                                         dHi@           a@q.                   f@Zvvvvvvvvvvvx #D                                                  ",
+"                                         d&4@            u,                    DhgvvvvvvvvvvvXS59                                                  ",
+"                                         71a@e                                 @pvvvvvvvvvvvvZek9                                                  ",
+"                                         .@X@V                                F@evvvvvvvvvvvv0,o9                                                  ",
+"                                          @C@iOX                             %@Bvvvvvvvvvvvvvm4oC                                                  ",
+"                                          @B@5S@                             o@fvvvvvvvvvvvvv5wA@                                                  ",
+"                                          #tG3S@                            ,+1vvvvvvvvvvvvvvm*Z@                                                  ",
+"                                          :Hu@7@                           -n@8udM*gvvvvvvvvvi7$@                                                  ",
+"                                          a@m@i@   m=                     gH@@@@@@@@+nk*vvvvvXpa@-                                                 ",
+"                                          -@N@t@   @-                      o@+:aO,fFG36@sAOvvr8S@a                                                 ",
+"                                          .&@@@@   @O                      =ja        ,d9@6uvCyOsa                                                 ",
+"                                           y@@@@  46                                     S3@VbzZNV                                                 ",
+"                                           .9@@6  Xk                                      -@<krfNa                                                 ",
+"                                            ,@@@ w@*                                       $@@D5@a                                                 ",
+"                                             o@@;tH                                         d@@1@S                                                 ",
+"                                             a@@@hS                                          k@H@0                                                 ",
+"                                             u@6AO     ge                                    -@@@k                                                 ",
+"                                              +:       cC                              f.     t@@q                                                 ",
+"                                              r@a     $N*                             gH0   7C@@@p                                                 ",
+"                                               F@x,=0>1*                               x<dMC@18@@4                                                 ",
+"                                                *n+sn:                                  D6hqf i@;                                                  ",
+"                                                  gg                                     .    8@M                                                  ",
+"                                                                                             ,@@4                                                  ",
+"                                                                                            %+@q                                                   ",
+"                                                                                        f-  8#3y                                                   ",
+"                                                                                       ,@$%8+46Z                                                   ",
+"                                                                                       d@@@9 c+                                                    ",
+"                                                                                        ZiO  47                                                    "};
diff --git a/xlockmore-4.14/pixmaps/bat-1.xpm b/xlockmore-4.14/pixmaps/bat-1.xpm
new file mode 100644 (file)
index 0000000..a5c2074
--- /dev/null
@@ -0,0 +1,178 @@
+/* XPM */
+static char * bat1[] = {
+"147 108 67 1",
+"      c #000000000000",
+".     c #1A1A1A1A1A1A",
+"X     c #1C1C1C1C1C1C",
+"o     c #A9A9A9A9A9A9",
+"O     c #FFFFFFFFFFFF",
+"+     c #A1A1A1A1A1A1",
+"@     c #F9F9F9F9F9F9",
+"#     c #3E3E3E3E3E3E",
+"$     c #AEAEAEAEAEAE",
+"%     c #A7A7A7A7A7A7",
+"&     c #3B3B3B3B3B3B",
+"*     c #B9B9B9B9B9B9",
+"=     c #E7E7E7E7E7E7",
+"-     c #E8E8E8E8E8E8",
+";     c #2E2E2E2E2E2E",
+":     c #7F7F7F7F7F7F",
+">     c #797979797979",
+",     c #B7B7B7B7B7B7",
+"<     c #656565656565",
+"1     c #262626262626",
+"2     c #BFBFBFBFBFBF",
+"3     c #B3B3B3B3B3B3",
+"4     c #515151515151",
+"5     c #0B0B0B0B0B0B",
+"6     c #171717171717",
+"7     c #D9D9D9D9D9D9",
+"8     c #4F4F4F4F4F4F",
+"9     c #050505050505",
+"0     c #EDEDEDEDEDED",
+"q     c #373737373737",
+"w     c #4A4A4A4A4A4A",
+"e     c #C6C6C6C6C6C6",
+"r     c #131313131313",
+"t     c #8F8F8F8F8F8F",
+"y     c #E1E1E1E1E1E1",
+"u     c #636363636363",
+"i     c #6B6B6B6B6B6B",
+"p     c #585858585858",
+"a     c #2B2B2B2B2B2B",
+"s     c #737373737373",
+"d     c #808080808080",
+"f     c #8B8B8B8B8B8B",
+"g     c #464646464646",
+"h     c #9E9E9E9E9E9E",
+"j     c #575757575757",
+"k     c #202020202020",
+"l     c #757575757575",
+"z     c #CCCCCCCCCCCC",
+"x     c #CBCBCBCBCBCB",
+"c     c #F0F0F0F0F0F0",
+"v     c #D6D6D6D6D6D6",
+"b     c #999999999999",
+"n     c #858585858585",
+"m     c #404040404040",
+"M     c #FFFF00000000",
+"L     c #FFFF77777777",
+"N     c #0E0E0E0E0E0E",
+"B     c #DFDFDFDFDFDF",
+"V     c #C1C1C1C1C1C1",
+"C     c #959595959595",
+"Z     c #878784848181",
+"A     c #919191919191",
+"S     c #5F5F5F5F5F5F",
+"D     c #313131313131",
+"F     c #6C6C6C6C6C6C",
+"G     c #F6F6F6F6F6F6",
+"H     c #D1D1D1D1D1D1",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                          .X                                                                       ",
+"                                                                          oO+                                                                      ",
+"                                                                           X@#                                                                     ",
+"                                                                            $%                                                                     ",
+"                                                                      &*=-; $:                                                                     ",
+"                                                                     >,<1+2 34                                                                     ",
+"                                                                    5;   5O678          9                                                          ",
+"                                                                          0q=w        qe2                                                          ",
+"                                                                          *$O      rtOyu9                                                          ",
+"                                                                          i@O     p0OOa                                                            ",
+"                                                                          sO=   u7OOOOd                                                            ",
+"                                                             r..66w$-,3fg hO, j=OOO@-o.                                                            ",
+"                                                   9kql>2zxxx0c00cOO2+h0O:3O7,OOOOx1r                                                              ",
+"                                               6wf%v-3bnm#&#&qqaeOMM  NBOOOVOOOOOO+                                                                ",
+"                                         rquh%xCsuX9ZZZZZZZZZZZ9O+MMMMMi%OOOOO+sOOO&                                                               ",
+"                                     9kd,h+swkNZZZZZZZZZZZZZZZZrOMMLLMM .OOOha tcOO&                                                               ",
+"                                  1j+3tirZZZZZZZZZZZZZZZ.Z.94AZZzMNLLMMM;OOOMMM  SOp.g4X                                                           ",
+"                             NqSCC>w.ZZZZZZZZZZZZZZZZZZZZZmv@,j .OcsMMMM*OyMMLLMMDO89#>*7%8X                                                       ",
+"                          .F%ft#k9ZZZZZZZZZZZZZZZZZZZZZZZmOVa    mVOOOGOcGcuMLLMrxONZZZZ;SheoS5                                                    ",
+"                       ;h$ds6ZZZZZZZZZZZZZZZZZZZZZZZZZZZFOl        9a<Fkf0OOMMM,O-ZZZZZZZZZZX>zha                                                  ",
+"                    a<*Aw9ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ&OF          9+  eOA$Oe-2S9 ZZZZZZZZZZZZsH%k                                                ",
+"                 Ng+3p6ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ5xi           jh  BO;eV N    ZZZZZZZZZZZZZZi2n6                                              ",
+"               9>0%&ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ2A            $8 1OO =<      ZZZZZZZZZZZZZZZZlyt                                             ",
+"514#9        Nt2>NZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZf*             Vr f0%1-. 5D2OOhXZZZZZZZZZZZZZZZ9s$i                                           ",
+"8h,=Hq      gA>NZZZZN#ZZZ5rZZZZZZZZZZZZZZZZZZZZZZZZZ6=;            m,  oVj%: X*3l48%co9ZZZZZZZZZZZZZZZkdzp                                         ",
+"    lO.   #V2 .ZZZZZZrZZZZ9ZZZZZZZZZZZZZZZZZZZZZZZZZ7+             Cu 4lvDOX fm     X2@pZZZZZZZZZZZZZZZZqV*;                                       ",
+"     Fv  u>mjCht8m6ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ#OX             Br5vj*l+           8c39ZZZZZZZZZZZZZZZZ#*o1                                     ",
+"      GA+OBcOOGGOOGV8NZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ+o             .7 uobnyX            ;7xXZZZZZZZZZZZZZZZZZ>7F                                    ",
+"      oOOO%1     5<bBO=A1ZZZZZZZZZZZZZZZZZZZZZZZZZ1O;             4f VDvA$               %OwZZZZZZZZZZZZZZZZZ1zx1                                  ",
+"     kOOOi           rivO%&ZZZZZZZZZZZ6rNZZZZZZZZZ>G              hXpH;B=D                +-NZZZZZZZZZZZZZZZZZZgHfN                                ",
+"    ;=OOO#              #,@VmZZZZZZrsvcGc2n.ZZ4ZZZvC             6e znCH2                 .@*ZZZZZZZZZZZZZZZZZZZ6+=j                               ",
+"   k=x9$G                 rCOywZZZZ,O7tfn*OO+Z+rZkOp             gd;Oavv4                  nO5ZZZZZZZZZZZZZZZZZZZZ&H%5                             ",
+"   7f  Nvd                  6COt9ZlOo     9>Ozu;ZpOD             AD%$.B%6                  aOXZZZZZZZZZZZZZZZZZZZZZZj2S                            ",
+"  FB    acor                  4Oeacy5       jOFNZsO.             $&OX<O%                   wO.ZZZZZZZZZZZZZZZZZZZZZZZ;e35                          ",
+" 9V5      f@+g.5               8OyOl         H*ZZ:B             &Ctv vOa                   d=ZZZZZZZZZZZZZZZZZZZZZZZZZZi=g                         ",
+" ;n        X>2=i                COOD         sONZee             CuBSaO=                   .@:ZZZZZZZZZZZZZZZZZZZZZZZZZZZ1e+                        ",
+" lg           69                wOOD         6OmZv:             $p= sOo                   lOZZZZZZZZZZZZZZZZZZZZZZZZZZZZZNo3r                      ",
+" tN                             &O0r          =+Z=s            .zeA VOw                  .-tZZZZZZNZZZZ95ZZZZZZZZZZZZZZZZZZty;                     ",
+" %.                             N7o           +vZOF            wOOD O@.                  HOaZZZ.X5&5ZZ9a;5ZZZ9qZZ1ZZZZZZZZZZuyg                    ",
+" N                               r9           j0XO&            FOv <O7           ap  96FzOdNZZZZZZZZZZZZZZZZZZ9ZZ6ZZZZZZ99ZZZlOk                   ",
+"                                              1@hO.            ,O< eOF          NyO0xOOOo.ZZZZZZZZZZZZZZZZZZZZZZZ5ZZZZZZZZZXZZhH6                  ",
+"                                              9cOOX           9BO1 @@X          X@OOOcaZZZZZZZZZZZZZZZZZZZZZZZ1ZZk.wA+x@G0+#ZZ#Oe                  ",
+"                                               yOOX           kOB kOV            8hjh@z4ZZZZZZZZZZZZZZZZZZZZZZ5ZsHc=**lpp%OOBd;wGs                 ",
+"                                               zOOk           XOd lOj                9AOerZZZZZZZZZZZZZZZZZZZ#b@e8N        rm+OBVO1                ",
+"                                               AO05            SXrc-                   ;2Ot9ZZZZZZZZZZZZZZZD2=fX              XhOO$                ",
+"                                               sOV               NhS                     sO%ZZZZZZZZkXZZZ1oc:N                  jO@k 9             ",
+"                                               #O;                                        sOAZZZZZN9.ZZZlOf                      yO=OOH            ",
+"                                               91                                          FO<ZZZZk9ZZ1v7q                  9 5r;dOO%$Oi           ",
+"                                                                                            $c.ZN5ZZZ#0,N                   4z-0OOOO; *2           ",
+"                                                                                            rce9ZZZZ;@u                      61   bO6 ,x           ",
+"                                                                                             gO:ZZZkHS                            CO  B:           ",
+"                                                                                             N0oZZN=h                            9-H #ON           ",
+"                                                                                              FO5ZB%                            mOyX hh            ",
+"                                                                                              6Oq:79                            8lr  .N            ",
+"                                                                                              9Ov0.                                                ",
+"                                                                                               zOl                                                 ",
+"                                                                                               zB9                                                 ",
+"                                                                                               =z                                                  ",
+"                                                                                              DO*                                                  ",
+"                                                                                              hOl                                                  ",
+"                                                                                              vOq                                                  ",
+"                                                                                             qOb                                                   ",
+"                                                                                             fOm                                                   ",
+"                                                                                             8OF                                                   ",
+"                                                                                              wOa                                                  ",
+"                                                                                               %n                                                  ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   "};
diff --git a/xlockmore-4.14/pixmaps/bat-2.xpm b/xlockmore-4.14/pixmaps/bat-2.xpm
new file mode 100644 (file)
index 0000000..dff03b4
--- /dev/null
@@ -0,0 +1,178 @@
+/* XPM */
+static char * bat2[] = {
+"147 108 67 1",
+"      c #000000000000",
+".     c #060606060606",
+"X     c #B4B4B4B4B4B4",
+"o     c #929292929292",
+"O     c #BABABABABABA",
+"+     c #FFFFFFFFFFFF",
+"@     c #D6D6D6D6D6D6",
+"#     c #131313131313",
+"$     c #222222222222",
+"%     c #DFDFDFDFDFDF",
+"&     c #BFBFBFBFBFBF",
+"*     c #565656565656",
+"=     c #A1A1A1A1A1A1",
+"-     c #9D9D9D9D9D9D",
+";     c #616161616161",
+":     c #A5A5A5A5A5A5",
+">     c #C9C9C9C9C9C9",
+",     c #E6E6E6E6E6E6",
+"<     c #E3E3E3E3E3E3",
+"1     c #848484848484",
+"2     c #EFEFEFEFEFEF",
+"3     c #F0F0F0F0F0F0",
+"4     c #3F3F3F3F3F3F",
+"5     c #1B1B1B1B1B1B",
+"6     c #8B8B8B8B8B8B",
+"7     c #696969696969",
+"8     c #4B4B4B4B4B4B",
+"9     c #F5F5F5F5F5F5",
+"0     c #151515151515",
+"q     c #8D8D8D8D8D8D",
+"w     c #D9D9D9D9D9D9",
+"e     c #949494949494",
+"r     c #343434343434",
+"t     c #3A3A3A3A3A3A",
+"y     c #CECECECECECE",
+"u     c #454545454545",
+"i     c #0A0A0A0A0A0A",
+"p     c #747474747474",
+"a     c #595959595959",
+"s     c #C7C7C7C7C7C7",
+"d     c #515151515151",
+"f     c #5D5D5D5D5D5D",
+"g     c #C3C3C3C3C3C3",
+"h     c #F8F8F8F8F8F8",
+"j     c #E8E8E8E8E8E8",
+"k     c #838383838383",
+"l     c #0E0E0E0E0E0E",
+"z     c #B2B2B2B2B2B2",
+"x     c #414141414141",
+"c     c #737373737373",
+"v     c #D2D2D2D2D2D2",
+"b     c #878784848181",
+"n     c #A8A8A8A8A8A8",
+"m     c #646464646464",
+"M     c #6D6D6D6D6D6D",
+"N     c #303030303030",
+"B     c #292929292929",
+"V     c #262626262626",
+"C     c #7A7A7A7A7A7A",
+"Z     c #7F7F7F7F7F7F",
+"A     c #4C4C4C4C4C4C",
+"S     c #1E1E1E1E1E1E",
+"D     c #AEAEAEAEAEAE",
+"F     c #FFFF00000000",
+"L     c #FFFF77777777",
+"G     c #989898989898",
+"H     c #2D2D2D2D2D2D",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                         .Xo.                                                                                                                      ",
+"                          O+@#                                                                                                                     ",
+"                           $%&                                                                                                                     ",
+"                        *=-#;+                                                                                                                     ",
+"                       :+>,+<+*                                                                                                                    ",
+"                      12$ .>++3;                                                                                                                   ",
+"                     4,5 *,+++++6                                                                                                                  ",
+"                     &7 8+6o++++90                                                                                                                 ",
+"                    .q. we  rty+9%u                                                                                                                ",
+"                     i  +$    8+p3+a                                                                                                               ",
+"                    .0  2#     wsd<+d                                                                                                              ",
+"                        +*     f+oog+*                                                                                                             ",
+"                        df     #hjklq+o                                                                                                            ",
+"                                u++O k+oi                                                                                                          ",
+"                                 z++8 *+%t                                                                                                         ",
+"                                 x++20 d<+c                                                                                                        ",
+"                                  X+vXibb7+6                                                                                                       ",
+"                                  4+1oybbb4ys$                                                                                                     ",
+"                                   &X gnbbb.z+a                      il                                                                            ",
+"                                   8+ibzmbbbbf3-.                   $++M                                                                           ",
+"                                   l+Nb41#$bbb8+@B                  chMjB                                                                 V7V      ",
+"                                    9CbbmfxVbbbNwhM                 8h Zz                                                                 2++A     ",
+"                                    ewbb.a5Blbbb.e+yB                a 5+i                                                               e+dn+N    ",
+"                                    A90bbbflbbbbbbt@+nS                 sa                                                              l+1  yg    ",
+"                                    i,rbbbl5bbbbbbbbm2+oi               *g       5d.                                                    M+$  53t   ",
+"                                     sqbbbbbbbbbSbbbbbZh+ai             49i  .0az++N                                                    Dw 00 dhV  ",
+"                                     12bbbbbbbbbbbbbbbbB:+2-dl     if&e$V+xlZ@2++wx                                                i#umayh&3hwX&5  ",
+"                                     x+.bbbbbbbbbbbbbbbbbro@++,Dpxn+++++&+++++++hB                                         NNM1Zsww+++++++++q1&hk  ",
+"                                     i9Abbbbbbbbbbbbbbbbbbbb.x19+++&FVSX+++++jy++@7f8AAAA40000i    00000000000000000048cn2++++++2O:ao+++32+3   u+r ",
+"                                      @Gbbbbbbbbbbbbbbbi0ibbbbbl,+FFLLFB++++6F$+9+++++++++93hh2yg@@h3hhhh92h9hh9h999h+++9DCaCz@m  $>3@cuS$f+8   y6 ",
+"                                      z=bbbbbbbbbbbbbbbbb#b#bbbb2%FFLLFo+-h%FFFF#%%NHNS5rxxuk1kO&GD-A1111;Hmakk1=k&ekxN0 #V5#$l iz+=H   .h.sX   k, ",
+"                                      q@bbbbbbbbbbbbbbbbbbbib#SO++FFFF%+@l9,FLLFS+= l #bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb#$S  V. C3@t     M+8Ds   8+5",
+"                                      a3.bbbbbbbbbbbbbbbbbbbbbc+o++vgh+<r.j+FLLFG++GA S.bbbbb5.bb5V5bbbbbbbbbbbbbbbbb00ibbV4 #&+;.      z+rXo   #2d",
+"                                      S3bbbbbbbbbbbbbbbbbbbbbbO+ 4e,+,%l  s++FF<+ww++s4bbbbbbbbbbbbbbbbbbbbbbbbbbbbbb.bbbb#ix+O5        #S gC    M:",
+"                                      #+Vbbbbbbbbbbbbbbbbbbbbbgw   A2-z   vh+j,X;  0M9+Dbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb#o+c            .<t      ",
+"                                      V+Bbbbbbbbbbbbbbbbbbbbbbgj   Awoo  S9w%Si      #o+-lbbbbbbbbbbbbbbbbbbbbbbbbbbbbb.bx3@8             Bhl      ",
+"                                       +HbbbbbbbbbbbbbbbbbbHubz+0  ;<-a  $j>,.         m+@Vbbbbbbbbbbbbbbbbbbbbbbbbbbbb.c+Z               Zs       ",
+"                                      B+lbbbbbbbbbbbbbbbbVZ@+D<+G. f<-f  $,k<.          x3+*bbbbbbbbbbbbbbbbbbbbbbbbbixO34                Zk       ",
+"                                      83.bbbbbbbbbbbbbbbNh+h+++++@Hd@-f  $%Dz            N2+cbbbbbbbbbbbbbbbbbbbbbbb.Aj%N                          ",
+"                                      a,bb#.bbbbbbbbbbb03+7  l*+++%mq-f  4w>f             l3+rbbbbbbbbbbbbbbbbbbbbbbBXh                            ",
+"                                      D:bbNbbbbbbbbbbbb8+c     =++h=oga  t++H              d+Obbbbbbbbbbbbbbbbbbbbb0424                            ",
+"                                      wmbbp$l.bbbbbbbbbd+.     lG,fpaw*  f++                9sbbbbbbbbbbbbbbbbbbbb#0g=                             ",
+"                                     5+Hbc++++gm#bbbbbb=3          Ct<H  f++                9nbbbbbbbbbbbbbbbbbbbbbS+$                             ",
+"                                     N+ C+3O&&v++nNbbbb:D          Z83.  f++               N+:bbbbbbbbbbbbbbbbbbbbbD-                              ",
+"                                     t+Z+>S    V6h+vdlbgD          &M+   f+>               p+abbbbbbbbbbbbbbbbbbbb5+5                              ",
+"                                     Z++z         7,+%bw:          OGy   :+g               j%.bbbbbbbbbbbbbbbbb#Vbcj                               ",
+"                                     1+9B           C+X3&          -nq   O+g              6+7.###bbbbbbbbbbbbbbx.bv*                               ",
+"                                     >+e             ;++3          G@Z   X+6           iuD++23333%OC8.bbbbbbbbblbA2.                               ",
+"                                    B++5              7+3          23d   O+m         $2+++hvD68t*eD<++<oNbbbbbbbb&g                                ",
+"                                    k++                v+4         ++B   X+7         S9++pi         lAZ@+jcbbbbbV+a                                ",
+"                                    g+9                4+6        #+2.   O+M          7Dr               H=+=bbbbq,.                                ",
+"                                    fwk                 >3        r+v    X+N                              7+Mbbbwk                                 ",
+"                                                        C+B       m+o    ,+V                               O+*b#+$                                 ",
+"                                                        0+D       q+f    +90                               $9%ba3                                  ",
+"                                                         g+4      6+$   t+@                                 M+Npv                                  ",
+"                                                         d+yi     g%.   e++$                                .,:&q                                  ",
+"                                                         t++C    S+D    8+si                                 C++7                                  ",
+"                                                          =<*     4#                                         N++B                                  ",
+"                                                                                                              ++B                                  ",
+"                                                                                                              ++V                                  ",
+"                                                                                                              ++f                                  ",
+"                                                                                                              v+;                                  ",
+"                                                                                                              ix                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   "};
diff --git a/xlockmore-4.14/pixmaps/bat-3.xpm b/xlockmore-4.14/pixmaps/bat-3.xpm
new file mode 100644 (file)
index 0000000..ec071e2
--- /dev/null
@@ -0,0 +1,165 @@
+/* XPM */
+static char * bat3[] = {
+"147 108 54 1",
+"      c #010101010101",
+".     c #1C1C1C1C1C1C",
+"X     c #A7A7A7A7A7A7",
+"o     c #FFFFFFFFFFFF",
+"O     c #9A9A9A9A9A9A",
+"+     c #DDDDDDDDDDDD",
+"@     c #D3D3D3D3D3D3",
+"#     c #3F3F3F3F3F3F",
+"$     c #F5F5F5F5F5F5",
+"%     c #BABABABABABA",
+"&     c #9E9E9E9E9E9E",
+"*     c #EDEDEDEDEDED",
+"=     c #121212121212",
+"-     c #4E4E4E4E4E4E",
+";     c #919191919191",
+":     c #5D5D5D5D5D5D",
+">     c #F2F2F2F2F2F2",
+",     c #797979797979",
+"<     c #C4C4C4C4C4C4",
+"1     c #767676767676",
+"2     c #0E0E0E0E0E0E",
+"3     c #2A2A2A2A2A2A",
+"4     c #888888888888",
+"5     c #2E2E2E2E2E2E",
+"6     c #434343434343",
+"7     c #969696969696",
+"8     c #B2B2B2B2B2B2",
+"9     c #050505050505",
+"0     c #ACACACACACAC",
+"q     c #272727272727",
+"w     c #D9D9D9D9D9D9",
+"e     c #6B6B6B6B6B6B",
+"r     c #474747474747",
+"t     c #090909090909",
+"y     c #8F8F8F8F8F8F",
+"u     c #373737373737",
+"i     c #646464646464",
+"p     c #BEBEBEBEBEBE",
+"a     c #575757575757",
+"s     c #CECECECECECE",
+"d     c #323232323232",
+"f     c #181818181818",
+"g     c #7E7E7E7E7E7E",
+"h     c #818181818181",
+"j     c #CACACACACACA",
+"k     c #E1E1E1E1E1E1",
+"l     c #5A5A5A5A5A5A",
+"z     c #494949494949",
+"x     c #A3A3A3A3A3A3",
+"c     c #3A3A3A3A3A3A",
+"v     c #878784848181",
+"b     c #707070707070",
+"n     c #FFFF00000000",
+"L     c #FFFF77777777",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                    .XoO                                                                                                           ",
+"                                   .+@#.                                                                                                           ",
+"                                   $%                                                                                                              ",
+"                                  &*=                                                                                                              ",
+"                                 -o;                                                                                                               ",
+"                                 ;o$.                                                                                                              ",
+"                                .:+o>#    .,<12                                                                                                    ",
+"                               3oO 4*o5  6$@7o4                                                                                                    ",
+"                               8<3   4o,9*0  .q                                                                                                    ",
+"                              9wo*3   &ooo3                                                                                                        ",
+"                               Ooe     1ooq                                                               ret                                      ",
+"                               qooy    uooq                                                               oo<                                      ",
+"                                tiwop1asooq                                                               deoq                                     ",
+"                                   i0***ood                                                                toa                                     ",
+"                                       .oo1                                                                foa   3                                 ",
+"                                       9+o7                                                         q<o*og ao9  h<                                 ",
+"                                        <o<                                                        f*jq=eo3<0 9h*q                                 ",
+"                                        Ookt                                                       ,$=   @wo:ek*5                                  ",
+"                                        -o$q                                                       4j    8ooooh                                    ",
+"                                        qo$q                                                       5l   iooo+3                                     ",
+"                                         oo1                                                            Ooooa                                      ",
+"                                         >op                                                            .o@k .=                                    ",
+"                                         <oo                                                            &&;*.oj                                    ",
+"                                         <ooz                                                          r+ a$=x:                                    ",
+"                                         <$<j                                                          @cr#oq                                      ",
+"                                         8o,oq                                                        1x x=>i                                      ",
+"                                         8oaox                                                       3*= 8vs0                                      ",
+"                                         1wrOoc                                                     2s-v97v,>                                      ",
+"                                         %O1v%@                                                     &Ovvf1vuo=                                     ",
+"                                         @Xxv3oX                                                   ,%vvvu4vv>g                                     ",
+"                                         wh8vvao89                                                i@2vvvi;vvhk9                                    ",
+"                                         o-&vvvbop2                                              akfvvvv74vvqod                                    ",
+"                                         ofc#vvvuoj.                                            5*zvvvvv%1vvvk4                                    ",
+"                                        .>9t-vvvv3+$a                 t                        d*#vvvvvcOOvvve>9                                   ",
+"                                        a<vv#9vvvvtjo4               f%=                      u+zvvvvvv&-ecvvq>b                                   ",
+"                                        &;vva2v9vvv94opq           9u %c                     3*-vvvvvvv*z.yvvv4ot                                  ",
+"                                        k6tda2vf9vvvvi>o7f        .+$s4,                    -*6vvvvvvvc>qv;3vv=kx                                  ",
+"                                       .ovvvu.vvvvvvvvq%o*i       td=7$<                   b*6vvvvvvvv4;tv-yvvvao:                                 ",
+"                                       bwvvvu3vvvvvvvvvvu+o%q         Oo                  hkcvvvvvvvv9Xevvv8qvvv;oq                                ",
+"                                       wiv=tuuvv=qvvvvvvv9,$o&.       to-      .xf      =08=vvvvvvvvv#11vvv.gvvvv<+                                ",
+"                                      rk9vvv.lvvvv9vvvvvvvvf@o$19      X0    f:jo#     .sgvvvvvvvvvvvbdavvvv;avvvqoX                               ",
+"                                      j4vvvv9cvvv9uvvvvvvvvvvz@o+c     4*9 5<ooo;     ro:vvvvvvvvvvvf;cevvvvv4.vvvqoy                              ",
+"                                      o=vvvvv-vvvv.fvvvvvvvvvvvz<o#tcq go3eooo$b     4w3vvvvvvvvvvvvaru3vvvvv30vvvv1ox                             ",
+"                                     4%vvq.vv:tvvvvu9vvvvvvvvvvvv.lwo*7josooook2   =%%.vvvvvvvvvvvvv7tl.vvvvvvb1vvvvgol                            ",
+"                                    t>qvva2vvc2vvvv=.vvvvvvvvvvvvco@8ooooooon4o0 .&o,vvvvvvvvvvvvvv-; 7vvvvvvvvu;fvvv1o0                           ",
+"                                    1%vvtcvvvqqvvvvvv.vvv.lxXXi6qwknnnf%ooonn &o,01=vvvvvvvvvvvvvvvO. ;vvvvvvvvv:%avvvc$sf                         ",
+"                                   =@qvtivvvvf6vvvvvvz.v2*oooooo*oonLLn,nLLnn 8*2vvvvvvvvvvvvvvvvvfOv=bvvvvvvvvvv.<ivvv6o*r                        ",
+"                                   8;vv:uvvvvvqvvvvvvvqvho-    56>$nLLn%nLLnn w<vvvvvvvvvvvvvvvvvvezvqivvvvvvvvvvvvgytvv9+o4                       ",
+"                                  .$fv.#vvvvvv6vvvvvvvv.ox       zo$nnnnonnnnnozvvvvvvvvvvvvvvvvvf%vvu#vvvvvvvvvvvvvzp6vvv4o@6                     ",
+"                                  pbvv-vvvvvvv:vvvvvvvv=oi        ,oooo@*o*ooo4ul=vvvvvvvvvvvvvvv-evvarvvvvvvvvvvvvvvfg4tvvd*o4                    ",
+"                                 a$vvifvvvvvvv-vvvvvvvv9o:        ro%oj:w*so1f0ooooXqvvvvvvvvvvvt02vvidvvvvvvvvvvvvvvvvqgh#2v1o<d                  ",
+"                                f*-v=3vvvvvvvv3tvv9dh+;6o;        q*io6 <X<0  u62-7oozvvvvvvvvvv46vvvl.vvvvvvvvvvvvvvvvvvqq2vv5woi                 ",
+"                                <0 .lvvvvvvvvv.vvvpoooooo+t       aoaoq og@h       q*$qvvvvvvvv=xvvvv-=vvvvvvvvvvvvvvvvvvvvv2ttq&o4                ",
+"                               x% =rvvvvvvvvvva=vpo:u%4>ooa       :$#*t ol+z        3o@vvvvvvvv0qvvvv;9vvvvvvvvvvvvvvvv=zO<*ooooooo4               ",
+"                              0*6h%ok%uvvvvvvv-9aol    ioo@       :*q*t o5*r         iozvvvvvvz,vvvvvivvvvvvvvvvvvvv9r<o*<hb5f=ae<ool              ",
+"                           2:0oooop08$o;tvvvvv- %@      rad       :*5<  o5*9          +w9vvvvv0.vvvv.4vvvvvvvvvvvvvlwo;r2         d1k9             ",
+"                           qooox5     io+vvvvvz.o:                i@6p  o5>           :o-vvvv,,vvvvvdlvvvvvvvvvvvb**hf              zq             ",
+"                            1+d        qk+uvvv6-*2                e;48  *3o           to,vvv=X9vvvvv:avvvvvvvvv6+o7                                ",
+"                             .          fj>dvv#O@                 1yyi  *5+            w<vvv;cvvvvvv4uvvvvvvv=0o7q                                 ",
+"                                          %ovvqkx                 %;<z 6kb<            swvvdXvvvvvvv&qvvvvvvuokq                                   ",
+"                                          9%@t @1                 %Ok9 6+&g            y+vveuvvvvvvv,9vvvvv1o&t                                    ",
+"                                           fo; wl                 %%o9 6*+1            0>v.1vvvvvvv9Ovvvvvbog                                      ",
+"                                            rou*.                 8s@  #*+c            @<vgcvvvvvvv3ivvvvboi                                       ",
+"                                             &ko-                 0oj  #oo3            ohv6vvvvvvvvl:vvvbou                                        ",
+"                                             .*o1                 so0  ao>f           dor63vt2vvvvvg.vveor                                         ",
+"                                              goe                 oob  7o@            Oo*ooooo;vvvvb9v3o,                                          ",
+"                                              to&                 ooc  7o7            :*y...q;o<vvva 9*4                                           ",
+"                                               &k                5oof  @oe             9      goevv1t4>9                                           ",
+"                                               col               co+   wod                     &o.v9coc                                            ",
+"                                               tow               uoj   wo3                     =ohvv@&                                             ",
+"                                                +o.              #o;   +*9                      X>tdoq                                             ",
+"                                                4oh               @O   +*t                      qo5x%                                              ",
+"                                                #o*               <O  9**2                       >x>c                                              ",
+"                                                q$oq              zq   a6                        0o*                                               ",
+"                                                 %oi                                             &o0                                               ",
+"                                                 -o8                                             &o-                                               ",
+"                                                  kk9                                            xo.                                               ",
+"                                                  bo;                                            js                                                ",
+"                                                  .oo6                                           oX                                                ",
+"                                                   *8                                           qob                                                ",
+"                                                   *4                                           aor                                                ",
+"                                                   0ou                                          #oz                                                ",
+"                                                   Xou                                          doz                                                ",
+"                                                   5b                                           .oi                                                ",
+"                                                                                                 g4                                                ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   "};
diff --git a/xlockmore-4.14/pixmaps/bat-4.xpm b/xlockmore-4.14/pixmaps/bat-4.xpm
new file mode 100644 (file)
index 0000000..8e701cf
--- /dev/null
@@ -0,0 +1,165 @@
+/* XPM */
+static char * bat4[] = {
+"147 108 54 1",
+"      c #010101010101",
+".     c #AEAEAEAEAEAE",
+"X     c #292929292929",
+"o     c #7A7A7A7A7A7A",
+"O     c #FFFFFFFFFFFF",
+"+     c #0C0C0C0C0C0C",
+"@     c #646464646464",
+"#     c #737373737373",
+"$     c #C8C8C8C8C8C8",
+"%     c #C4C4C4C4C4C4",
+"&     c #101010101010",
+"*     c #9D9D9D9D9D9D",
+"=     c #E4E4E4E4E4E4",
+"-     c #F2F2F2F2F2F2",
+";     c #A3A3A3A3A3A3",
+":     c #909090909090",
+">     c #D7D7D7D7D7D7",
+",     c #DADADADADADA",
+"<     c #171717171717",
+"1     c #3D3D3D3D3D3D",
+"2     c #989898989898",
+"3     c #8B8B8B8B8B8B",
+"4     c #A9A9A9A9A9A9",
+"5     c #202020202020",
+"6     c #A6A6A6A6A6A6",
+"7     c #5F5F5F5F5F5F",
+"8     c #868686868686",
+"9     c #E9E9E9E9E9E9",
+"0     c #DFDFDFDFDFDF",
+"q     c #CFCFCFCFCFCF",
+"w     c #060606060606",
+"e     c #D2D2D2D2D2D2",
+"r     c #575757575757",
+"t     c #252525252525",
+"y     c #B1B1B1B1B1B1",
+"u     c #4C4C4C4C4C4C",
+"i     c #484848484848",
+"p     c #B5B5B5B5B5B5",
+"a     c #434343434343",
+"s     c #1B1B1B1B1B1B",
+"d     c #6E6E6E6E6E6E",
+"f     c #878784848181",
+"g     c #2D2D2D2D2D2D",
+"h     c #BCBCBCBCBCBC",
+"j     c #7E7E7E7E7E7E",
+"k     c #5B5B5B5B5B5B",
+"l     c #313131313131",
+"z     c #6B6B6B6B6B6B",
+"x     c #525252525252",
+"c     c #F0F0F0F0F0F0",
+"v     c #FFFF00000000",
+"L     c #FFFF77777777",
+"b     c #F8F8F8F8F8F8",
+"n     c #383838383838",
+"                                                                             .X                                                                    ",
+"                                                                            oO+                                                                    ",
+"                                                                           @O#@$%@&                                                                ",
+"                                                                           *O=-;:>,X                                                               ",
+"                                                                      <1o234OO5   #6                                                               ",
+"                                                                   +7>OOOOOOOO                                                                     ",
+"                                                                  890.OOO=$qOO*w                                                                   ",
+"                                                                1eOrt,Oyu   1;Oi                                                                   ",
+"                                                              X,Op tO=1  &    q3                                                                   ",
+"                                                             8O4Xa&>=&  se>5  e8                                                                   ",
+"                                                            dO@fXaq=<    1-q  q8                                                                   ",
+"                                                           5O:ffuoOg       O1 9o                                                                   ",
+"                                                           e;ffi:Oo     oqhO# O1                                                                   ",
+"                                                          rO&ffj9q      pOOOOp9s                                                                   ",
+"                                                         5Ouffi6-X   w2OOOOOOO91                                                                   ",
+"                                                         h>ffwu9:    uO31-OOOOO-a                                                                  ",
+"                                                        oO1ffk:OX    2- 1O75k-OOOo                                                                 ",
+"                                                       +O@ffl@qy     p* @-   &99:O2w                                                               ",
+"                                                       8=ff&t1O1     #4 d$    X=q6O%&                                                              ",
+"                                                      aO1ffs<q9      @- #2     X-98O-X                                                             ",
+"                                                     +93ffg gO1      5-&7p      &%=u--a                                                            ",
+"                                                     *,&fsu ;>        .o5=       598w,Ok                                                           ",
+"                                                    1O5fw1 &Od        lOw=l       iO <6Oy<                                                         ",
+"                                                   5-kff&& h=+         1 d8       +-aff1-O4X                                                       ",
+"                                                   q;ffs&fsOo            wt        :hfffsjOO.X                                                     ",
+"                                                  yqwffXwfoOl                      5O<ffff&8-O21                                                   ",
+"                                                 #=+ffffff$9                        e*fffffffr0O=@s                                                ",
+"                                                dO1ffs+ff1Oy                        zOufffffffwi6OOhzt5                                            ",
+"                                               1Oxff5XfffoO@                        &O.ffffffffff<d>-OO9>2ag                                       ",
+"                                              tOoff+5ffffoOs                         oOffff&+ffffffff&rk2qOOOeyz5&                                 ",
+"                                             g98ffwiwffff:O                          sOafffwffffffffffffff5a#*0OOOe3g                              ",
+"                                            t-:fffa5fffffhq                           %.ffffffffffffffffffffffffi8$-O9;i&                          ",
+"                                           X-7fff+sffffffO;                           :9fffffffff<ffffffffffffffffffrpOOOh@a1                      ",
+"                                          @9ufffffffffff&O;                           x9fffffffff+ffffffffffffffw180--OOOOOO0+                     ",
+"                                        &$=gfff+ffffffff1O:                           r9ffffffffffffffffffffff1;OOO$jooo#2,O2                      ",
+"                                       19.&ffftgffffffffXOu                           x-fffffffffffffffffff&z9O9:1         5                       ",
+"                                      r9jfffwl&ffffffffffO3                           uO5fffffffffffffffffXeO.a+                                   ",
+"                                    w69gfffa1ffffffffffff.4                           @OtffffffffffffffffkO9l                                      ",
+"                                   &qpfff<71fffffffffffff4.                           yqfffffffffffffff+2O6w                                       ",
+"                                  g=:ffws&&ffffffffffffffd9                           qoXffffffffffffff2Oj                                         ",
+"                                 @OiffffwffffffffffffffffuO                          <O1ufffffffffffffuO#                                          ",
+"                                h01ffffffffffffffffffffffxO+                         1OfaffffffffffffXO2                                           ",
+"                              &h0sffffffffffffffffffffffftOl                         o,f1ffffffffffffye                                            ",
+"                             a>6fffl111<fffffffffffffffff+-o                         9of@wffffffffffrOg                                            ",
+"                          tx6O=2$OOOOcOO-:x&ffffffffffffff.e                        @Ogfk+ffffffffff9h                                             ",
+"                          9OOOOOe@u5s&tu2eO91fffffffffffffiOw                       >pffaffffffffffuO1                                             ",
+"                          qO$d1+          16O2ffffffffffff+O1        1s            5Ouf&uffffffffff:-w                                             ",
+"                           &                xO.ffffffffffff$y       jOOa           2O+f&xffffffffff,*                                              ",
+"                                             #Oxfffffffffff89w      pko,          1Okff57fffffffff&O@                                              ",
+"                                              :O&ffffffffff1Ou        &O&      *d $$fff1lfffffffff&O5                                              ",
+"                                               98fffffffffffq,         $#    5$O2@OXfffutffffffwwfkO&                                              ",
+"                                               o9fffffff5fffaOx        @h   o-O-uO:ffffr&ffffff+tf@O&                                              ",
+"                                               5O1ffffffsffff2Oa    51 l9 5,OO4l,=+ffff8&fffffffwf@O&                                              ",
+"                                                ,2ffffffsfffffpOX  aOO98O;OOOq&%OsfffffjffffffffffxOs                                              ",
+"                                                @-ffffffwffffff9>+t9=@=OOOOOO9=O7ffffff7ffldyh;@5fiOx                                              ",
+"                                                sO@ffffffffffffiO-99v&&=OOOqOOOg x:e*ok:&:OOO90OOhiO8                                              ",
+"                                                 ;,fffffffffffffs8OvvvvjOOvvadO%>O=h-OOOOOh1   a2OOO,w                                             ",
+"                                                 1O&fffflwfffffff1-vLLv;OvLLv O-:l  +l,OO8       1,OO1                                             ",
+"                                                  9@ffff5ffffffff1-vLLvOvvLLvdOx      :O=w        +yO2                                             ",
+"                                                  :effff&wfw@%Opf -vvvvhvvvvvO;       w:i           >Ou                                            ",
+"                                                  7O<fffw 1,O-*8w kObOO**O99O*                      1O-s                                           ",
+"                                                  5Olffffs-O1      +p8-ujO0Oz                       w,Oy                                           ",
+"                                                   0:ffff2O@        240 kO4O&                        3O8                                           ",
+"                                                   6hffff2Og        200 kO@9w                         5                                            ",
+"                                                   oOffffaOx        uO0 59r-w                                                                      ",
+"                                                   nOgp-O-O.        1O0 59r-+                                                                      ",
+"                                                   &-OO0;,OOX       lO0 59k-w                                                                      ",
+"                                                    qOk   dO,&       O. t9i-+                                                                      ",
+"                                                    h$    +OO1       O0 5-1-w                                                                      ",
+"                                                   &-4     ;4        O= s-5-+                                                                      ",
+"                                                   tOp               q= +=<-+                                                                      ",
+"                                                   aO8               h9  ,<-+                                                                      ",
+"                                                   aO8               q9  es-+                                                                      ",
+"                                                   7O8               p9  e<9+                                                                      ",
+"                                                   aO8               h9  >89+                                                                      ",
+"                                                   aO8               pO5 ey9w                                                                      ",
+"                                                   aO8               #Ot 4O0+                                                                      ",
+"                                                   1O3               kO1 oO=+                                                                      ",
+"                                                   @O-&              7Od #O9&                                                                      ",
+"                                                   dO-               gOd XOO<                                                                      ",
+"                                                    1u               7O: &Ob&                                                                      ",
+"                                                                     X,@ w0-+                                                                      ",
+"                                                                          1#                                                                       ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   ",
+"                                                                                                                                                   "};
diff --git a/xlockmore-4.14/pixmaps/m-axp.xpm b/xlockmore-4.14/pixmaps/m-axp.xpm
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/xlockmore-4.14/pixmaps/m-blank.xpm b/xlockmore-4.14/pixmaps/m-blank.xpm
new file mode 100644 (file)
index 0000000..3e025ea
--- /dev/null
@@ -0,0 +1,56 @@
+/* XPM */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 8 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c gray85",
+"o     c gray50",
+"O     c red",
+"+     c darkolivegreen",
+"@     c white",
+"#     c black",
+"                                                                ",
+"                                                                ",
+"                          ...........................           ",
+"                         .XXXXXXXXXXXXXXXXXXXXXXXXXXX.          ",
+"                        .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXoo        ",
+"                        .XX+++++++++++++++++++++++XXXXoo        ",
+"                        .XX++++++++++++++++++++++++XXXooo       ",
+"                        .XX++@@+@++@+@@@@++@+++++++XXXooo       ",
+"                        .XX++++++++++++++++++++++++XXXoooo      ",
+"                        .XX++@@@@+@@+@@@+++++++++++XXXoooo      ",
+"                        .XX++++++++++++++++++++++++XXXooooo     ",
+"                        .XX++@@@@@@@@@@+@@@@@++++++XXXooooo     ",
+"                        .XX++++++++++++++++++++++++XXXooooo     ",
+"                        .XX++@@@+@@@@+@@++@@@++++++XXXooooo     ",
+"                        .XX++++++++++++++++++++++++XXXooooo     ",
+"                        .XX++@+++++++++++++++++++++XXXooooo     ",
+"                        .XX++++++++++++++++++++++++XXXooooo     ",
+"                        .XX++@@@@+@+@@@+@++++++++++XXXooooo     ",
+"                        .XX++++++++++++++++++++++++XXXooooo     ",
+"                        .XX++@+@@@@++++++++++++++++XXXooooo     ",
+"                        .XXX++++++++++++++++++++++XXXXoooo      ",
+"                        .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXooo       ",
+"                         .XXXXXXXXXXXXXXXXXXXXXXXXXXXooo        ",
+"                            ooooooooooooooooooooooooo...oo      ",
+"                             ..........................ooo      ",
+"                            oooooooooooooooooooooooooooooo      ",
+"                          oXXXXXXXXXXXXXXXXXXXXXXXXXXXoooo.. .. ",
+"                          oXXXXXXXXXXXXXXXXXX#######XXoooo  .  .",
+"                        oooooooooooooooooooooooooooXXXooo     . ",
+"                       oXXXXXXXXXXXXXXXXXXXXXXXXXXooooo      .  ",
+"                      oXXXXXXXXXXXXXXXXXXXXXXXXXXoo      oooooo ",
+"                      oXX@@@@@@@@@@@@@@@@@@@XXXXXoo   ooooo...o ",
+"                     oXXXXXXXXXXXXXXXXXXXXXXXXXXoo   ooXXXoo..o ",
+"                    oXX@@@@@@@@@@@@@@@@@@@@XXXXoo    oXXXXX..o  ",
+"                   oXXXXXXXXXXXXXXXXXXXXXXXXXXoo     o.....oo   ",
+"                   oooooooooooooooooooooooooooo      ooooooo    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-bsd.xpm b/xlockmore-4.14/pixmaps/m-bsd.xpm
new file mode 100644 (file)
index 0000000..d51cf70
--- /dev/null
@@ -0,0 +1,62 @@
+/* XPM */
+/*
+ * BSD daemon
+ * The original BSD daemon is Copyright (c) 1988 Marshall Kirk McKusick.
+ * All Rights Reserved.  Reproduced with permission.
+ */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 9 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c gray85",
+"o     c gray50",
+"-      c gray10",
+"O     c red",
+"+     c darkolivegreen",
+"@     c white",
+"#     c black",
+"                                                                ",
+"                     OO                                         ",
+"                      OO  ...........................           ",
+"          O           OOO.XXXXXXXXXXXXXXXXXXXXXXXXXXX.          ",
+"         OO     OOOOOO OOXXXXXXXXXXXXXXXXXXXXXXXXXXXXXoo        ",
+"         OO    OOOOOOOO OXX+++++++++++++++++++++++XXXXoo        ",
+"        OOO  OOOOOOOO OO.XX++++++++++++++++++++++++XXXooo       ",
+"        OOOO OOOO OO O O.XX++@@+@++@+@@@@++@+++++++XXXooo       ",
+"         OOOOOOO O OO  O.XX++++++++++++++++++++++++XXXoooo      ",
+"          OOOOOOO  OO  OOXX++@@@@+@@+@@@+++++++++++XXXoooo      ",
+"            OOOOO  OOOOOOXX++++++++++++++++++++++++XXXooooo     ",
+"             OOOOOOOO OOOOX++@@@@@@@@@@+@@@@@++++++XXXooooo     ",
+"             OOOOOOO  OOOOX++++++++++++++++++++++++XXXooooo     ",
+"             OOOOOOOOOO OOX+-@@@+@@@@+@@++@@@++++++XXXooooo     ",
+"             OOOOO OOO OOXX--+--+++++++++++++++++++XXXooooo     ",
+"              OOOOO   OOOXX----++++++++++++++++++++XXXooooo     ",
+"               OOOOOOOO .XX---++-++++++++++++++++++XXXooooo     ",
+"                 OOOOOO .XX------+@+@@@+@++++++++++XXXooooo     ",
+"                O O OO  OO-++++++++++++++++++++++++XXXooooo     ",
+"                OOOOOO OOOO++@+@@@@++++++++++++++++XXXooooo     ",
+"                OOOOO O-OOOX++++++++++++++++++++++XXXXoooo      ",
+"                OOO  O- OOXXXXXXXXXXXXXXXXXXXXXXXXXXXXooo       ",
+"                OOOOO-O  .XXXXXXXXXXXXXXXXXXXXXXXXXXXooo        ",
+"                OOOO-OO     ooooooooooooooooooooooooo...oo      ",
+"                OOOOOO O     ..........................ooo      ",
+"                OO    OO    oooooooooooooooooooooooooooooo      ",
+"              OOOO OOOOO  oXXXXXXXXXXXXXXXXXXXXXXXXXXXoooo.. .. ",
+"            OOOOO OOOOO   oXXXXXXXXXXXXXXXXXX#######XXoooo  .  .",
+"        OOOOOOOOOOOOOOO oooooooooooooooooooooooooooXXXooo     . ",
+"     OOOOOO    OOOOO OOOOXXXXXXXXXXXXXXXXXXXXXXXXXooooo      .  ",
+"    OOO        OOOOO OOOOOOXXXXXXXXXXXXXXXXXXXXXXoo      oooooo ",
+"    OO         OOOOOO OOOOOOO@@@@@@@@@@@@@@@XXXXXoo   ooooo...o ",
+"    O OO       OOOOOOO OOOOOXXXXXXXXXXXXXXXXXXXXoo   ooXXXoo..o ",
+"     OOOO       OOOOOOO OOO@@@@@@@@@@@@@@@@XXXXoo    oXXXXX..o  ",
+"                  OOOXXXXXXXXXXXXXXXXXXXXXXXXXoo     o.....oo   ",
+"                   oooooooooooooooooooooooooooo      ooooooo    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-dec.xpm b/xlockmore-4.14/pixmaps/m-dec.xpm
new file mode 100644 (file)
index 0000000..40dd35d
--- /dev/null
@@ -0,0 +1,57 @@
+/* XPM */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 9 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c gray85",
+"o     c gray50",
+"-     c #a00000",
+"O     c white",
+"+     c darkolivegreen",
+"@     c white",
+"#     c black",
+"                                                                ",
+"                                                                ",
+"                          ...........................           ",
+"                         .XXXXXXXXXXXXXXXXXXXXXXXXXXX.          ",
+"                        .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXoo        ",
+"                        .XX+++++++++++++++++++++++XXXXoo        ",
+"                        .XX++++++++++++++++++++++++XXXooo       ",
+"-----------------------------------@+@@@@++@+++++++XXXooo       ",
+"----OO-OO--------OO---O---------OO-++++++++++++++++XXXoooo      ",
+"----OO-OO--------OO--OO---------OO-@+@@@+++++++++++XXXoooo      ",
+"----OO---------------OO---------OO-++++++++++++++++XXXooooo     ",
+"-OOOOO-OO--OOO-O-OO-OOOO-XOOO-O-OO-@@@@+@@@@@++++++XXXooooo     ",
+"OOOOOO-OO-OOOOOO-OO-OOOO-OOOOOO-OO-++++++++++++++++XXXooooo     ",
+"OO--OO-OO-OO--OO-OO--OO--OO--OO-OO-@@+@@++@@@++++++XXXooooo     ",
+"OO--OO-OO-OO--OO-OO--OO--OO--OO-OO-++++++++++++++++XXXooooo     ",
+"OO--OO-OO-OO--OO-OO--OO--OO--OO-OO-++++++++++++++++XXXooooo     ",
+"OO--OO-OO-OOOOOO-OO--OOO-OOOOOO-OO-++++++++++++++++XXXooooo     ",
+"-OOOOO-OO--OOOOO-OO---OO-XOOOOO-OO-+@@@+@++++++++++XXXooooo     ",
+"--------------OO-------------------++++++++++++++++XXXooooo     ",
+"----------OOOOOO-------------------++++++++++++++++XXXooooo     ",
+"-----------OOOO--------------------+++++++++++++++XXXXoooo      ",
+"-----------------------------------XXXXXXXXXXXXXXXXXXXooo       ",
+"                         .XXXXXXXXXXXXXXXXXXXXXXXXXXXooo        ",
+"                            ooooooooooooooooooooooooo...oo      ",
+"                             ..........................ooo      ",
+"                            oooooooooooooooooooooooooooooo      ",
+"                          oXXXXXXXXXXXXXXXXXXXXXXXXXXXoooo.. .. ",
+"                          oXXXXXXXXXXXXXXXXXX#######XXoooo  .  .",
+"                        oooooooooooooooooooooooooooXXXooo     . ",
+"                       oXXXXXXXXXXXXXXXXXXXXXXXXXXooooo      .  ",
+"                      oXXXXXXXXXXXXXXXXXXXXXXXXXXoo      oooooo ",
+"                      oXX@@@@@@@@@@@@@@@@@@@XXXXXoo   ooooo...o ",
+"                     oXXXXXXXXXXXXXXXXXXXXXXXXXXoo   ooXXXoo..o ",
+"                    oXX@@@@@@@@@@@@@@@@@@@@XXXXoo    oXXXXX..o  ",
+"                   oXXXXXXXXXXXXXXXXXXXXXXXXXXoo     o.....oo   ",
+"                   oooooooooooooooooooooooooooo      ooooooo    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-hp.xpm b/xlockmore-4.14/pixmaps/m-hp.xpm
new file mode 100644 (file)
index 0000000..113a477
--- /dev/null
@@ -0,0 +1,56 @@
+/* XPM */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 8 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c gray85",
+"o     c gray50",
+"O     c red",
+"+     c darkolivegreen",
+"@     c white",
+"#     c black",
+"                                                                ",
+"                                                                ",
+"                          ...........................           ",
+"                         .XXXXXXXXXXXXXXXXXXXXXXXXXXX.          ",
+"           OOOOO O OOOOOOOXXXXXXXXXXXXXXXXXXXXXXXXXXXXoo        ",
+"           OOOOO O  OOOOOOX+++++++++++++++++++++++XXXXoo        ",
+"          OOOOOO O   OOOOOO++++++++++++++++++++++++XXXooo       ",
+"          OOOOO  O    OOOOO++@@+@++@+@@@@++@+++++++XXXooo       ",
+"          OOOO  OO     OOOO++++++++++++++++++++++++XXXoooo      ",
+"          OOOO  O      OOOO++@@@@+@@+@@@+++++++++++XXXoooo      ",
+"          OOOO  O      OOOO++++++++++++++++++++++++XXXooooo     ",
+"          OOOO  OO  OO OOOO++@@@@@@@@@@+@@@@@++++++XXXooooo     ",
+"          OOO  OOO OOO  OOO++++++++++++++++++++++++XXXooooo     ",
+"          OOO  OOO O O  OOO++@@@+@@@@+@@++@@@++++++XXXooooo     ",
+"          OOO  O O O O  OOO++++++++++++++++++++++++XXXooooo     ",
+"          OOO  O O O O  OOO++@+++++++++++++++++++++XXXooooo     ",
+"          OOO  O O O O  OOO++++++++++++++++++++++++XXXooooo     ",
+"          OOOO O O OOO OOOO++@@@@+@+@@@+@++++++++++XXXooooo     ",
+"          OOOO     OO  OOOO++++++++++++++++++++++++XXXooooo     ",
+"          OOOO     O   OOOO++@+@@@@++++++++++++++++XXXooooo     ",
+"          OOOO     O   OOOOX++++++++++++++++++++++XXXXoooo      ",
+"          OOOOO   OO  OOOOOXXXXXXXXXXXXXXXXXXXXXXXXXXXooo       ",
+"          OOOOOO  O  OOOOOOXXXXXXXXXXXXXXXXXXXXXXXXXXooo        ",
+"           OOOOOO O OOOOOO  ooooooooooooooooooooooooo...oo      ",
+"           OOOOOO O OOOOOO   ..........................ooo      ",
+"                            oooooooooooooooooooooooooooooo      ",
+"                          oXXXXXXXXXXXXXXXXXXXXXXXXXXXoooo.. .. ",
+"                          oXXXXXXXXXXXXXXXXXX#######XXoooo  .  .",
+"                        oooooooooooooooooooooooooooXXXooo     . ",
+"                       oXXXXXXXXXXXXXXXXXXXXXXXXXXooooo      .  ",
+"                      oXXXXXXXXXXXXXXXXXXXXXXXXXXoo      oooooo ",
+"                      oXX@@@@@@@@@@@@@@@@@@@XXXXXoo   ooooo...o ",
+"                     oXXXXXXXXXXXXXXXXXXXXXXXXXXoo   ooXXXoo..o ",
+"                    oXX@@@@@@@@@@@@@@@@@@@@XXXXoo    oXXXXX..o  ",
+"                   oXXXXXXXXXXXXXXXXXXXXXXXXXXoo     o.....oo   ",
+"                   oooooooooooooooooooooooooooo      ooooooo    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-linux.xpm b/xlockmore-4.14/pixmaps/m-linux.xpm
new file mode 100644 (file)
index 0000000..dee19d6
--- /dev/null
@@ -0,0 +1,181 @@
+/* XPM */
+/* Linux Penguin from logo.gif and logo.txt /usr/src/linux/Documentation
+This is the full-colour version of the currenly unofficial Linux logo
+("currently unofficial" just means that there has been no paperwork and
+that I haven't really announced it yet).  It was created by Larry Ewing,
+and is freely usable as long as you acknowledge Larry as the original
+artist. 
+
+Note that there are black-and-white versions of this available that
+scale down to smaller sizes and are better for letterheads or whatever
+you want to use it for: for the full range of logos take a look at
+Larry's web-page:
+
+        http://www.isc.tamu.edu/~lewing/linux/
+ */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char *image_name[] = {
+/* width height num_colors chars_per_pixel */
+"    64    38      117            2",
+/* colors */
+".. c #000000",
+"#X c #f0f0f0",
+".# c #b3b3b3",
+".a c #d9d9d9",
+".b c #7f7f7f",
+".c c #556b2f",
+".d c #ffffff",
+".e c #000000",
+".f c #f8f8f8",
+".g c #f0c814",
+".h c #503800",
+".i c #eccc38",
+".j c #d09010",
+".k c #805800",
+".l c #f8c838",
+".m c #f0cc20",
+".n c #a87c1c",
+".o c #e4cc20",
+".p c #a4803c",
+".q c #e8b010",
+".r c #606060",
+".s c #c08010",
+".t c #a8a8a8",
+".u c #685030",
+".v c #a0a0a0",
+".w c #583800",
+".x c #585858",
+".y c #707070",
+".z c #e0c808",
+".A c #888888",
+".B c #484848",
+".C c #a07008",
+".D c #f8cc14",
+".E c #e8a810",
+".F c #986800",
+".G c #606068",
+".H c #704800",
+".I c #b0b0b0",
+".J c #f4d028",
+".K c #707078",
+".L c #404040",
+".M c #704808",
+".N c #906000",
+".O c #e8b808",
+".P c #c08008",
+".Q c #e0b008",
+".R c #986808",
+".S c #383838",
+".T c #e8a800",
+".U c #e8a808",
+".V c #505050",
+".W c #989898",
+".X c #303030",
+".Y c #808080",
+".Z c #a8a8b0",
+".0 c #c88c10",
+".1 c #d09810",
+".2 c #282828",
+".3 c #906008",
+".4 c #885808",
+".5 c #a87000",
+".6 c #181818",
+".7 c #c08800",
+".8 c #e0d08c",
+".9 c #e8e8e8",
+"#. c #a06808",
+"## c #d8d8d8",
+"#a c #a87008",
+"#b c #a06008",
+"#c c #f0d008",
+"#d c #d89810",
+"#e c #b08004",
+"#f c #c89008",
+"#g c #e0e0e0",
+"#h c #101010",
+"#i c #d89010",
+"#j c #402800",
+"#k c #a0a0ac",
+"#l c #d09800",
+"#m c #b88008",
+"#n c #986008",
+"#o c #d09808",
+"#p c #202020",
+"#q c #080004",
+"#r c #b07004",
+"#s c #c08808",
+"#t c #d0d0d0",
+"#u c #f0f0e8",
+"#v c #b07808",
+"#w c #080808",
+"#x c #c4a474",
+"#y c #d8a000",
+"#z c #d8a008",
+"#A c #c0c0c0",
+"#B c #f8cc08",
+"#C c #d09008",
+"#D c #bc8c3c",
+"#E c #c88808",
+"#F c #e0a008",
+"#G c #e8b008",
+"#H c #e0a808",
+"#I c #d89808",
+"#J c #f0b010",
+"#K c #2c2404",
+"#L c #b8b8b8",
+"#M c #f0b808",
+"#N c #f0c008",
+"#O c #b87808",
+"#P c #e8c008",
+"#Q c #c8c8c8",
+"#R c #947404",
+"#S c #f8a808",
+"#T c #f0b810",
+"#U c #f8b810",
+"#V c #c0c0e0",
+"#W c #f8c008",
+"#Y c #404040",
+/* pixels */
+"............................#Y#Y#Y#Y#Y#Y#Y#Y....................................................................................",
+"..........................#Y..............#Y....................................................................................",
+"........................#Y.............6.G#w..#Y.....#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#......................",
+"......................#Y..............#p.X#h..#Y...#.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.#....................",
+"......................#Y........................#Y.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.b.b................",
+"......................#Y..#h#p....#w.....y......#Y.a.a.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.a.b.b................",
+"......................#Y..#k.I.6...A.t#Q.v#h....#Y.a.a.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b..............",
+"......................#Y..#h.2.y#h#u.f.W.f......#Y.a.a.c.c.d.d.c.d.c.c.d.c.d.d.d.d.c.c.d.c.c.c.c.c.c.c.a.a.a.b.b.b..............",
+"......................#Y...6.W.x..#Q....#A......#Y.a.a.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b............",
+"......................#Y...f#v#W.z.o.D.u.f......#Y.a.a.c.c.d.d.d.d.c.d.d.c.d.d.d.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b............",
+"......................#Y...n#M#N.z.i.o.z.o......#Y.a.a.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"......................#Y..#f#W#B.8.z.o#o#z........#Y.a.c.c.d.d.d.d.d.d.d.d.d.d.c.d.d.d.d.d.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"......................#Y..#Q.h#R.w#I#I.0.Z.....Y#q#Y.a.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"......................#Y..#L#n#z#I.s.s#Q#t#Q...Y..#Y.a.c.c.d.d.d.c.d.d.d.d.c.d.d.c.c.d.d.d.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"......................#Y..#X#A#k#Q#A#V#X.f.f........#Y.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"....................#Y.....f.f#L#A.f.f.f.f.f.A........#Y.c.d.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"..................#Y.....f.f.f.f.f.f.f.f.f.f.f..........#Y.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"..................#Y...K.f.f.f.f.f.f.f.f.f.f.f............#Y.d.d.d.c.d.c.d.d.d.c.d.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"..............#Y.......v#t.f.f#g.f.f.f#X#Q#A#A.f..........#Y.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"..............#Y......#X.f.f.f.f.f.f.f.f.f.f#X#A.....B......#Y.d.d.d.d.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.b.b.b.b.b..........",
+"..............#Y.....f.f.f.f.f.f.f.f.f.f.f.f.f.f.f#h.S.2....#Y.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.a.a.a.a.b.b.b.b............",
+"............#Y.......f.f.f.f.f.f.f.f.f.f.f.f.f.f.f.6.6........#Y.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.b.b.b..............",
+"............#Y#q..#X.f.f.f.f#X.f.f.f.f.f.f.f.f.f.f............#Y.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.b.b.b................",
+"..........#Y...S...f.f.f.f.f#g.f.f.f.f.f.f.f.f.f.f............#Y.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.#.#.#.b.b............",
+"..........#Y...Y#A.f.f.f.f.f##.f.f.f.f.f.f.f.f.f.f............#Y.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.#.b.b.b............",
+"........#Y.....V#A.f.f.f.f.f##.f.f.f.f.f.f.f.f.f.f....#h......#Y.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b............",
+"........#Y....#h#Q.f.f.f.f.f##.f.f.f.f.f.f.f.f.f.f.....S......#Y.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.b.b.b.b.#.#...#.#..",
+"..........#Y#W#W.t.f.f.f.f.f##.f.f.f.f.f.f.f.f.f.f#p..........#Y.a.a.a.a.a.a.a.a.a.a.a.a.a.e.e.e.e.e.e.e.a.a.b.b.b.b.....#.....#",
+"........#Y#d.D#W.q...f.f.f.f#g.f.f.f.f.f.f.f.f#d.z.p.......6.o.D#Y.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.a.a.a.b.b.b...........#..",
+"......#Y#E.q.g#U#W#W..#t.f.f.f.f.f.f.f.f.f.f.f#D#N#a......#R#N#S#Y.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.b.b.b.b.b.............#....",
+"#Y#b#J.q.q#W#W#U#W#W#w...S.f.f.f.f.f.f.f.f.f#t#x.O#C.P#v#e.Q#U.g#Y.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.b.b.............b.b.b.b.b.b..",
+"#Y#H#W#F.g.J.g.g#W.m#c.....L.f.f.f.f.f.f.f.f.9.p.U.T#H#z#H.m.m#F.m#Y.d.d.d.d.d.d.d.d.d.d.a.a.a.a.a.b.b.......b.b.b.b.b.#.#.#.b..",
+"#Y.1#W.g#F.g#F.m#F#W#W.E...r.f.f.f.f.f.f.f.f.f.3#y#M#U#M#N#W#F#W.g.D.a.a.a.a.a.a.a.a.a.a.a.a.a.a.b.b.......b.b.a.a.a.b.b.#.#.b..",
+"#Y.0#U#U.g.D.m#W.g.g#F#P#b.f.f.f.f.f.f.f.f.f...4#H#W.g.g#W.D#U#U#F.D.d.d.d.d.d.d.d.d.d.a.a.a.a.b.b.........b.a.a.a.a.a.#.#.b....",
+"#Y#i#W#F.l#W.g.g#W.g.g.O#o.f.f.f.f.f.f.f.......F#H.g.g#U#F#W#W.J#U#d.a.a.a.a.a.a.a.a.a.a.a.a.b.b...........b.#.#.#.#.#.b.b......",
+"#d#I#H#G#T#U#W.g.m#U#F#W.1#j...................5#H.g#U#U.g#F#U#d#Y.b.b.b.b.b.b.b.b.b.b.b.b.b.b.............b.b.b.b.b.b.b........",
+"#Y.3.n#s#f#C#z#H.g.g#U.U#O.M...................N#l#G#T#G#H.j#Y..................................................................",
+"........#Y.M.R#.#m#s#s#v.k#K#Y#Y#Y#Y#Y#Y#Y#Y#Y.H#r#s#f.7.C#Y...................................................................."
+};
diff --git a/xlockmore-4.14/pixmaps/m-sgi.xpm b/xlockmore-4.14/pixmaps/m-sgi.xpm
new file mode 100644 (file)
index 0000000..c37ca75
--- /dev/null
@@ -0,0 +1,56 @@
+/* XPM */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 8 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c #71717171C6C6",
+"o     c gray85",
+"O     c gray50",
+"+     c darkolivegreen",
+"@     c white",
+"#     c black",
+"                                                                ",
+"                                                                ",
+"                          ...........................           ",
+"                  XX XX  .ooooooooooooooooooooooooooo.          ",
+"                 XXX XXX.oooooooooooooooooooooooooooooOO        ",
+"                XX X X XXoo+++++++++++++++++++++++ooooOO        ",
+"               XX  X X  XXo++++++++++++++++++++++++oooOOO       ",
+"               XX  X X  XXo++@@+@++@+@@@@++@+++++++oooOOO       ",
+"             XX XX X X XXoXX+++++++++++++++++++++++oooOOOO      ",
+"            XXXX XXX XXX.XXXX@@@@+@@+@@@+++++++++++oooOOOO      ",
+"            XX XX XXXXX XXoXX++++++++++++++++++++++oooOOOOO     ",
+"            XX  XXXXXXXXXooXX@@@@@@@@@@+@@@@@++++++oooOOOOO     ",
+"            XX  XXXXXXXXXooXX++++++++++++++++++++++oooOOOOO     ",
+"            XX XX XXXXX XXoXX@@@+@@@@+@@++@@@++++++oooOOOOO     ",
+"            XXXX XXX XXX.XXXX++++++++++++++++++++++oooOOOOO     ",
+"             XX XX X X XXoXX+@+++++++++++++++++++++oooOOOOO     ",
+"               XX  X X  XXo++++++++++++++++++++++++oooOOOOO     ",
+"               XX  X X  XXo++@@@@+@+@@@+@++++++++++oooOOOOO     ",
+"                XX X X XXoo++++++++++++++++++++++++oooOOOOO     ",
+"                 XXX XXX.oo++@+@@@@++++++++++++++++oooOOOOO     ",
+"                  XX XX .ooo++++++++++++++++++++++ooooOOOO      ",
+"                        .oooooooooooooooooooooooooooooOOO       ",
+"                         .oooooooooooooooooooooooooooOOO        ",
+"                            OOOOOOOOOOOOOOOOOOOOOOOOO...OO      ",
+"                             ..........................OOO      ",
+"                            OOOOOOOOOOOOOOOOOOOOOOOOOOOOOO      ",
+"                          OoooooooooooooooooooooooooooOOOO.. .. ",
+"                          Ooooooooooooooooooo#######ooOOOO  .  .",
+"                        OOOOOOOOOOOOOOOOOOOOOOOOOOOoooOOO     . ",
+"                       OooooooooooooooooooooooooooOOOOO      .  ",
+"                      OooooooooooooooooooooooooooOO      OOOOOO ",
+"                      Ooo@@@@@@@@@@@@@@@@@@@oooooOO   OOOOO...O ",
+"                     OooooooooooooooooooooooooooOO   OOoooOO..O ",
+"                    Ooo@@@@@@@@@@@@@@@@@@@@ooooOO    Oooooo..O  ",
+"                   OooooooooooooooooooooooooooOO     O.....OO   ",
+"                   OOOOOOOOOOOOOOOOOOOOOOOOOOOO      OOOOOOO    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-sol.xpm b/xlockmore-4.14/pixmaps/m-sol.xpm
new file mode 100644 (file)
index 0000000..605cdfc
--- /dev/null
@@ -0,0 +1,56 @@
+/* XPM */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 8 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c white",
+"o     c red",
+"O     c black",
+"+     c gray85",
+"@     c gray50",
+"#     c darkolivegreen",
+"                                                                ",
+"                      .                                         ",
+"          XXXXoOO.OOO..   ...........................           ",
+"        oXXXXXoOO.OOO.O  .+++++++++++++++++++++++++++.          ",
+"       XXoXXXXXOO.OOO.OOO+++++++++++++++++++++++++++++@@        ",
+"      XXXXXXXXXO...O...O.O+#######################++++@@        ",
+"     XXXXXXXXXX.......O..O+#.######################+++@@@       ",
+"    XXXXXXXXXXX.........O.O.#XX#X##X#XXXX##X#######+++@@@       ",
+"   XoXXXXXXXXXXooooooooo...O#######################+++@@@@      ",
+"   XXoXXXXXXX..XXooooooo..OO#XXXX#XX#XXX###########+++@@@@      ",
+"  XXXXXXXX.....XXXXXoooo...OO######################+++@@@@@     ",
+"  XXXXXXX......XXXXXXooo.....XXXXXXXXXX#XXXXX######+++@@@@@     ",
+"  XXXXXX.......XXXXXXXoo...OO######################+++@@@@@     ",
+"  XXXXXX.......XXXXXXXoo..OOO..X#XXXX#XX##XXX######+++@@@@@     ",
+"  ooXXXX.......XXXXXXXoo.....######################+++@@@@@     ",
+" XXXXXXX.......XXXXXXXoo.....X#####################+++@@@@@     ",
+"  XXXXXX.......XXXXXXXoo...OO######################+++@@@@@     ",
+"  XXXXXX.......XXXXXXXoo..OOOXXXX#X#XXX#X##########+++@@@@@     ",
+"  XXXXXX.......XXXXXXXoo....O######################+++@@@@@     ",
+"  XXXXXXX......XXXXXXooo.....X#XXXX################+++@@@@@     ",
+"  XXOXXXXX.....XXXXXoooo....O#####################++++@@@@      ",
+"   OXXXXXXXXX..XXooooooo.O.O++++++++++++++++++++++++++@@@       ",
+"   XXXXXXXXXXXXooooooooo..OO+++++++++++++++++++++++++@@@        ",
+"    XXXXXXXXXXX...........O @@@@@@@@@@@@@@@@@@@@@@@@@...@@      ",
+"     XXXOXXXXXX........................................@@@      ",
+"      XOXXXXXXX....O...O.O  @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@      ",
+"       XXXXXXXX...OOO..OO @+++++++++++++++++++++++++++@@@@.. .. ",
+"        XXXOXXXO.OOOO..   @++++++++++++++++++OOOOOOO++@@@@  .  .",
+"          XOXXXO.OOO  . @@@@@@@@@@@@@@@@@@@@@@@@@@@+++@@@     . ",
+"                       .++++++++++++++++++++++++++@@@@@      .  ",
+"                      @++++++++++++++++++++++++++@@      @@@@@@ ",
+"                      @++XXXXXXXXXXXXXXXXXXX+++++@@   @@@@@...@ ",
+"                     @++++++++++++++++++++++++++@@   @@+++@@..@ ",
+"                    @++XXXXXXXXXXXXXXXXXXXX++++@@    @+++++..@  ",
+"                   @++++++++++++++++++++++++++@@     @.....@@   ",
+"                   @@@@@@@@@@@@@@@@@@@@@@@@@@@@      @@@@@@@    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-sun.xpm b/xlockmore-4.14/pixmaps/m-sun.xpm
new file mode 100644 (file)
index 0000000..6f36d58
--- /dev/null
@@ -0,0 +1,56 @@
+/* XPM */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 8 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c gray85",
+"o     c gray50",
+"O     c #4000bf",
+"+     c darkolivegreen",
+"@     c white",
+"#     c black",
+"                                                                ",
+"               OOO                                              ",
+"              OOOOO       ...........................           ",
+"              OO OOO     .XXXXXXXXXXXXXXXXXXXXXXXXXXX.          ",
+"            O OOO OOO   .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXoo        ",
+"           OOO OOO OOO  .XX+++++++++++++++++++++++XXXXoo        ",
+"          O OOO OOO OOO .XX++++++++++++++++++++++++XXXooo       ",
+"         OOO OOO OOO OOO.XX++@@+@++@+@@@@++@+++++++XXXooo       ",
+"        O OOO OOO OOO O OXX++++++++++++++++++++++++XXXoooo      ",
+"       OOO OOO OOO OOO OOOX++@@@@+@@+@@@+++++++++++XXXoooo      ",
+"      OOO O OOO OOO O OOOXO++++++++++++++++++++++++XXXooooo     ",
+"     OOO OOO OOO OO  OOO.OOO+@@@@@@@@@@+@@@@@++++++XXXooooo     ",
+"    OOO OOO   OOOOO OOO OOO++++++++++++++++++++++++XXXooooo     ",
+"   OOO OOO OOO OOO OOO OOOXOOO@@+@@@@+@@++@@@++++++XXXooooo     ",
+"  OOO OOO OOOOO   OOO OOOXOOOOO++++++++++++++++++++XXXooooo     ",
+"  OO OOO OOO OO   OO OOO.OOO+OO++++++++++++++++++++XXXooooo     ",
+"  OOOOO OOO OOO   OOOOO OOO+OOO++++++++++++++++++++XXXooooo     ",
+"   OOO OOO OOO OOO OOO OOOXOOO@@@+@+@@@+@++++++++++XXXooooo     ",
+"      OOO OOO OOOOO   OOOXOOO++++++++++++++++++++++XXXooooo     ",
+"     OOO OOO  OO OOO OOO.OOO+@+@@@@++++++++++++++++XXXooooo     ",
+"      O OOO O OOO OOO O OOOX++++++++++++++++++++++XXXXoooo      ",
+"       OOO OOO OOO OOO OOOXXXXXXXXXXXXXXXXXXXXXXXXXXXXooo       ",
+"        O O OOO OOO OOO O.XXXXXXXXXXXXXXXXXXXXXXXXXXXooo        ",
+"         OOO OOO OOO OOO    ooooooooooooooooooooooooo...oo      ",
+"          OOO OOO OOO O      ..........................ooo      ",
+"           OOO OOO OOO      oooooooooooooooooooooooooooooo      ",
+"            OOO OOO O     oXXXXXXXXXXXXXXXXXXXXXXXXXXXoooo.. .. ",
+"             OOO OO       oXXXXXXXXXXXXXXXXXX#######XXoooo  .  .",
+"              OOOOO     oooooooooooooooooooooooooooXXXooo     . ",
+"               OOO     oXXXXXXXXXXXXXXXXXXXXXXXXXXooooo      .  ",
+"                      oXXXXXXXXXXXXXXXXXXXXXXXXXXoo      oooooo ",
+"                      oXX@@@@@@@@@@@@@@@@@@@XXXXXoo   ooooo...o ",
+"                     oXXXXXXXXXXXXXXXXXXXXXXXXXXoo   ooXXXoo..o ",
+"                    oXX@@@@@@@@@@@@@@@@@@@@XXXXoo    oXXXXX..o  ",
+"                   oXXXXXXXXXXXXXXXXXXXXXXXXXXoo     o.....oo   ",
+"                   oooooooooooooooooooooooooooo      ooooooo    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-x11.xpm b/xlockmore-4.14/pixmaps/m-x11.xpm
new file mode 100644 (file)
index 0000000..fd9bf9a
--- /dev/null
@@ -0,0 +1,56 @@
+/* XPM */
+/*****************************************************************************/
+/**       This pixmap is kindly offered by Ion Cionca - 1992 -              **/
+/**       Swiss Federal Institute of Technology                             **/
+/**       Central Computing Service                                         **/
+/*****************************************************************************/
+static char * image_name [] = {
+/**/
+"64 38 8 1",
+/**/
+"      s mask  c black",
+".     c gray70",
+"X     c gray85",
+"o     c gray50",
+"O     c red",
+"+     c darkolivegreen",
+"@     c white",
+"#     c black",
+"                                                                ",
+"                                                                ",
+"                          ...........................           ",
+"                         .XXXXXXXXXXXXXXXXXXXXXXXXXXX.          ",
+"                        .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXoo        ",
+" OOOOOOOOOO             .XXOOO++++++++++++++++++++XXXXoo        ",
+"  OOOOOOOOOO            .XOOO++++++++++++++++++++++XXXooo       ",
+"   OOOOOOOOOO           .OOO+@@+@++@+@@@@++@+++++++XXXooo       ",
+"    OOOOOOOOOO          OOO++++++++++++++++++++++++XXXoooo      ",
+"     OOOOOOOOOO        OOOX++@@@@+@@+@@@+++++++++++XXXoooo      ",
+"      OOOOOOOOOO      OOOXX++++++++++++++++++++++++XXXooooo     ",
+"       OOOOOOOOOO    OOO.XX++@@@@@@@@@@+@@@@@++++++XXXooooo     ",
+"        OOOOOOOOOO  OOO .XX++++++++++++++++++++++++XXXooooo     ",
+"         OOOOOOOOO OOO  .XX++@@@+@@@@+@@++@@@++++++XXXooooo     ",
+"          OOOOOOO OOO   .XX++++++++++++++++++++++++XXXooooo     ",
+"           OOOOO OOOO   .XX++@+++++++++++++++++++++XXXooooo     ",
+"            OOO OOOOOO  .XX++++++++++++++++++++++++XXXooooo     ",
+"           OOO OOOOOOOO .XX++@@@@+@+@@@+@++++++++++XXXooooo     ",
+"          OOO OOOOOOOOOO.XX++++++++++++++++++++++++XXXooooo     ",
+"         OOO   OOOOOOOOOOXX++@+@@@@++++++++++++++++XXXooooo     ",
+"        OOO     OOOOOOOOOOXX++++++++++++++++++++++XXXXoooo      ",
+"       OOO       OOOOOOOOOOXXXXXXXXXXXXXXXXXXXXXXXXXXXooo       ",
+"      OOO         OOOOOOOOOOXXXXXXXXXXXXXXXXXXXXXXXXXooo        ",
+"     OOO           OOOOOOOOOOoooooooooooooooooooooooo...oo      ",
+"    OOO             OOOOOOOOOO.........................ooo      ",
+"   OOO               OOOOOOOOOOooooooooooooooooooooooooooo      ",
+"  OOO                 OOOOOOOOOOXXXXXXXXXXXXXXXXXXXXXXoooo.. .. ",
+" OOO                      oXXXXXXXXXXXXXXXXXX#######XXoooo  .  .",
+"                        oooooooooooooooooooooooooooXXXooo     . ",
+"                       oXXXXXXXXXXXXXXXXXXXXXXXXXXooooo      .  ",
+"                      oXXXXXXXXXXXXXXXXXXXXXXXXXXoo      oooooo ",
+"                      oXX@@@@@@@@@@@@@@@@@@@XXXXXoo   ooooo...o ",
+"                     oXXXXXXXXXXXXXXXXXXXXXXXXXXoo   ooXXXoo..o ",
+"                    oXX@@@@@@@@@@@@@@@@@@@@XXXXoo    oXXXXX..o  ",
+"                   oXXXXXXXXXXXXXXXXXXXXXXXXXXoo     o.....oo   ",
+"                   oooooooooooooooooooooooooooo      ooooooo    ",
+"                                                                ",
+"                                                                "};
diff --git a/xlockmore-4.14/pixmaps/m-xlock.xpm b/xlockmore-4.14/pixmaps/m-xlock.xpm
new file mode 100644 (file)
index 0000000..661406e
--- /dev/null
@@ -0,0 +1,34 @@
+/* XPM */
+static char * image_name[] = {
+/* width height num_colors chars_per_pixel */
+"    50    24        4            1",
+/* colors */
+". c Black",
+"* c White",
+"# c Red",
+"a c SteelBlue",
+/* pixels */
+"..................................................",
+".##########................###....................",
+"..##########..............###.....................",
+"...##########............###......................",
+"....##########..........###............aaaaa......",
+".....##########........###...........aaaaaaaaa....",
+"......##########......###............aaaaaaaaa....",
+".......##########....###............aaaa...aaaa...",
+"........##########..###.............aaa.....aaa...",
+".........#########.###..............aaa.....aaa...",
+"..........#######.###...............aaa.....aaa...",
+"...........#####.####.......................aaa...",
+"............###.######............aaaaaaaaaaaaaaa.",
+"...........###.########...........aaaaaaaaaaaaaaa.",
+"..........###.##########..........aaaaa.aaa.aaaaa.",
+".........###...##########.........aa.aa.....aa.aa.",
+"........###.....##########........aa.aa.aaa.aa.aa.",
+".......###.......##########.......aa.aa.....aa.aa.",
+"......###.........##########......aa.aa.aaa.aa.aa.",
+".....###...........##########.....aa.aa.....aa.aa.",
+"....###.............##########....aa.aa.aaa.aa.aa.",
+"...###...............##########...aaaaaaaaaaaaaaa.",
+"..###.................##########..aaaaaaaaaaaaaaa.",
+".................................................."};